Class AspectProxyInstr
java.lang.Object
org.ek9lang.compiler.ir.instructions.IRInstr
org.ek9lang.compiler.ir.instructions.AspectProxyInstr
- All Implemented Interfaces:
INode
High-level IR instruction for creating an aspect-woven proxy.
This instruction tells the backend to generate a synthetic proxy class that wraps a delegate component with ordered aspect instances. The proxy extends the base type and, for each public non-operator method, generates a wrapped version with before/after advice chains.
All instance construction (delegate, aspects, their dependencies) happens via normal CALL/RETAIN/SCOPE_REGISTER instructions before this instruction. This instruction takes the pre-constructed instances and returns a wired proxy.
The backend is responsible for:
- Generating a proxy class extending baseType
- Creating fields for delegate and aspect instances
- For each public non-operator method: JoinPoint creation, before-chain, delegate call (with try/finally), after-chain (reverse order)
- Proxy naming via source token hash
-
Method Summary
Modifier and TypeMethodDescriptionstatic AspectProxyInstrcreateAspectProxy(AspectProxyDetails details) Create an aspect proxy instruction from details.toString()Methods inherited from class IRInstr
accept, addOperand, addOperands, equals, getDebugInfo, getEscapeMetaData, getOpcode, getOperands, getResult, hasEscapeMetaData, hashCode, hasResult, isControlFlow, isLabel, isMemoryManagement, isMethodCall, setEscapeMetaData
-
Method Details
-
createAspectProxy
Create an aspect proxy instruction from details. -
getBaseTypeFqn
-
getDelegateTypeFqn
-
getDelegateTemp
-
getAspectTemps
-
getAspectTypeFqns
-
getProxyMethods
-
getSourceToken
-
toString
-