Function: Compile()
Less than 1 minute
AspectJS • Docs
Function: Compile()
Compile(...
args
):MethodDecorator
Annotation to declare an advice to be applied at compile time, when a symnol is read bu the interpreter.
The Compile annotation is used to apply compile advice to a symbol. Compile advices are executed once, when the decorators are evaluated by the interpreter.
Parameters
• ...args: PointcutExpression
<PointcutKind
>[]
Returns
MethodDecorator
An ES decorator representing the Compile annotation.
Example
import { Compile, on } from '@aspectjs/core';
class MyClass {
@Compile(on.classes.withAnnotations(SomeAnnotation))
myMethod() {
// Method implementation
}
}
Defined in
packages/core/src/advices/compile/compile.annotation.ts:29