Aspects Class

From The Oxygene Language Wiki

Jump to:navigation, search

This is a Language topic
Feel free to add your notes to this topic below.


Aspects = public static class

The Aspects class is a dummy class that is recognized by the compiler. When the compiler encounters calls to methods on this class inside an anonymous method that is assigned to a StatementDelegate Class, it replaces them with the calls to the actual code required to insert these things.

Namespace: Cirrus


Members

Method
Description
ClassName: StringWhen used in an anonymous aspect body, this will be replaced with the name of the current class
GetParameters: array of ObjectWhen used in an anonymous aspect body, this will be replaced with an array of objects that contain the current parameters as values.
MethodName: StringWhen used in an anonymous aspect body, this will be replaced with the name of the current method
OriginalBody Insert the body of original method at the place this method is called.
RequireLocal: ObjectWhen used in an anonymous aspect body and assigned to an inline local, it will require this local to exist at runtime and be of the type T. Any change to the local variable will be reflected to the actual local.
RequireLocal<T>: TWhen used in an anonymous aspect body and assigned to an inline local, it will require this local to exist at runtime, be of the type T. Any change to the local variable will be reflected to the actual local. This overload enforces the type.
RequireParameter: ObjectWhen used in an anonymous aspect body and assigned to an inline local, it will require this parameter to exist at runtime and be of the type T. Any change to the local variable will be reflected to the actual parameter.
RequireParameter<T>: T When used in an anonymous aspect body and assigned to an inline local, it will require this parameter to exist at runtime and be of the type T. Any change to the local variable will be reflected to the actual parameter. This overload enforces the type.
RequireResult: ObjectWhen used in an anonymous aspect body and assigned to an inline local, it will require the function to have a result and be of the type T. Any change to the local variable will be reflected to the actual result.
RequireResult<T>: TWhen used in an anonymous aspect body and assigned to an inline local, it will require the function to have a result and be of the type T. Any change to the local variable will be reflected to the actual result. This overload enforces the type.


See Also


Oxygene-48.png

Area: Oxygene Language
Compiler version: Oxygene 5

Language GlossaryKeywordsTypesFAQHow To

Navigation
Areas
More
Toolbox