Class JavaTransferExecutor<T>

java.lang.Object
org.eso.ias.asce.transfer.TransferExecutor
org.eso.ias.asce.transfer.JavaTransferExecutor<T>
Direct Known Subclasses:
MinMaxThresholdTFJava, PythonExecutorTF

public abstract class JavaTransferExecutor<T> extends TransferExecutor
The JavaTransferExecutor provides the interface for java implementators of the transfer function as java data structs differ from scala ones.
Author:
acaproni
  • Constructor Details

    • JavaTransferExecutor

      public JavaTransferExecutor(String cEleId, String cEleRunningId, long validityTimeFrame, Properties props)
      Constructor
      Parameters:
      cEleId - : The id of the ASCE
      cEleRunningId - : the running ID of the ASCE
      validityTimeFrame - : The time frame (msec) to invalidate monitor points
      props - : The properties for the executor
  • Method Details

    • getValue

      protected final IasIOJ<?> getValue(Map<String,IasIOJ<?>> inputs, String id, Optional<Integer> instance)
      This method is mostly to get templated input instances for which the instance, not known to the ACSE, must be passed. If the instance is empty, it delegates to getValue(Map, String).
      Parameters:
      inputs - the map of the inputs
      id - The (non templated) identifier of the value
      instance - The instance defined for templated input instances
      Returns:
      the IASValue of the given ID or null if a IASValue with the passed id is not in the map
    • getValue

      protected final IasIOJ<?> getValue(Map<String,IasIOJ<?>> inputs, String id)
      This method transparently return a value from the passed ID, being the ASCE templated or not. If the ASCE is not templated, this method delegates to Map.get(Object). If the ASCE is generated out of a template, its inputs can or cannot be generated out of the same template. In the latter, their identifiers must be enriched with the number of the instance.
      Parameters:
      inputs - the map of the inputs
      id - The (non templated) identifier of the value
      Returns:
      the IASValue of the given ID or null if a IASValue with the passed id is not in the map
    • eval

      public abstract IasIOJ<T> eval(Map<String,IasIOJ<?>> compInputs, IasIOJ<T> actualOutput) throws Exception
      Produces the output of the component by evaluating the inputs. IMPLEMENTATION NOTE The IASValue is immutable. The easiest way to produce the output to return is to execute the methods of the actualOutput that return a new IASValue.
      Parameters:
      compInputs - : the inputs to the ASCE
      actualOutput - : the actual output of the ASCE
      Returns:
      the computed value to set as output of the ASCE
      Throws:
      Exception - in case of error
    • initialize

      public abstract void initialize(Set<org.eso.ias.asce.transfer.IasioInfo> inputsInfo, org.eso.ias.asce.transfer.IasioInfo outputInfo) throws Exception
      Initialize the transfer function
      Parameters:
      inputsInfo - The IDs and types of the inputs
      outputInfo - The Id and type of thr output
      Throws:
      Exception - in case of errors