Class FieldActor

All Implemented Interfaces:
EventListener, IGProp<GProp<?>[]>, IPropCnr, Cloneable

public class FieldActor extends MethodReference2
The VirtualSpace Field Actor property holds the reference, and the annotation values for implementing Operations, and Source and Target classes for Conversion.

Two variants are supported:

  1. As for classic MethodReference:
    a Java class reference "ClassReference" is held by a parent container in the tree, and this method reference is a simple name without '.' and is the method in the class.
  2. a static method reference in a class, where this name is the fully qualified class name with the method name last.
Author:
Christopher Mindus
  • Constructor Details

    • FieldActor

      public FieldActor()
      Creates a new instance with no name and with a null value.
    • FieldActor

      public FieldActor(Atom propertyAtom)
      Creates a new instance with the specified name with a null value.
      Parameters:
      propertyAtom - the property atom.
    • FieldActor

      public FieldActor(Atom propertyAtom, String reference)
      Creates a new instance with the specified name and value.
      Parameters:
      propertyAtom - the property atom.
      reference - the reference string.
  • Method Details

    • getDescription

      public String getDescription()
      Gets the runtime description of the annotated method as declared in its Java class.
      Returns:
      The descr="" entry from the annotation of the method, (none) when not defined.
    • onPrepare

      protected void onPrepare(IAppOwner appOwner, IModuleOwner moduleOwner, boolean isPostCall, List<Throwable> errors) throws PropException
      Called when the application is being prepared. The order of onPrepare calls is always parent first, the children. The method is called twice, first time with isPostCall set to false, then a second time with true.

      This method checks the annotation and retrieves the Operations, Source and Target conversion classes.

      Overrides:
      onPrepare in class MethodReference2
      Parameters:
      appOwner - The application owner.
      moduleOwner - The Module owner.
      isPostCall - Flag indicating this is a post-call.
      errors - A list of errors that occurred but did not cause an abort.
      Throws:
      PropException - For property errors during the application preparation to need to abort.