Class InputProps

All Implemented Interfaces:
EventListener, IClassInstantiationAtResolve, IGProp<GProp<?>[]>, IPropCnr, IReferrerParticipant, IVSAccessor, IVSParticipant, Cloneable
Direct Known Subclasses:
EditorInputProps

public class InputProps extends VSVariables implements IVSParticipant, IClassInstantiationAtResolve
Input Properties that ties the input to the execution of an SQL query statement to VirtualSpace.
Author:
Christopher Mindus
  • Constructor Details

    • InputProps

      public InputProps()
      Creates a Input Properties container with the specified name with a null value.
    • InputProps

      public InputProps(Atom propertyAtom)
      Creates a Input Properties container with the specified name with a null value.
      Parameters:
      propertyAtom - the property atom.
  • Method Details

    • clone

      public InputProps clone()
      Clones these Input Properties.
      Overrides:
      clone in class VSVariables
    • getDatabaseProps

      public DatabaseProps getDatabaseProps()
      Gets the Database Transaction properties.
      Returns:
      The Database Transaction properties, or null if this property is orphaned.
    • getDescription

      public String getDescription()
      Gets the input properties description.
      Returns:
      A description, or null for none.
    • getInputVariables

      public InputVariable[] getInputVariables()
      Gets the input variables.
      Returns:
      An array of input variables.
    • getInputVariable

      public InputVariable getInputVariable(String sqlHostVariableName)
      Gets the input variable by name.
      Parameters:
      sqlHostVariableName - The name of the SQL host variable to look-up.
      Returns:
      The input variable property, or null if the variable is not found.
    • getParticipantDescription

      public String getParticipantDescription()
      Returns the given description of the referrer participant.
      Specified by:
      getParticipantDescription in interface IReferrerParticipant
    • getParticipantType

      public String getParticipantType()
      Returns the given type of the referrer participant.
      Specified by:
      getParticipantType in interface IReferrerParticipant
    • getVSReference

      public VSParticipant getVSReference(Atom refAtom)
      Gets a VSReference instance from the container or any parent containers. The method is used by VSRelativeReference to look up the VSReference instance in order to resolve the relative path to the target property.
      Specified by:
      getVSReference in interface IGProp<GProp<?>[]>
      Overrides:
      getVSReference in class PropCnr
      Parameters:
      refAtom - The property atom of the requesting relative reference property.
      Returns:
      The instance of the VSReference or null if unassigned.
    • getVirtualSpace

      public VirtualSpace getVirtualSpace()
      Gets the VirtualSpace.
      Specified by:
      getVirtualSpace in interface IVSAccessor
      Returns:
      The VirtualSpace connected to the result set, or null for none.
    • getInputVSParticipant

      public VSParticipant getInputVSParticipant()
      Gets the input VirtualSpace participant for output data.
      Returns:
      The input VirtualSpace participating with the output data, null for none.
    • bind

      Binds the variables from the InputProps and a virtualized VirtualSpace from the application session to the statement.
      Parameters:
      appGyro - The application session gyro instance.
      statement - The named statement.
      Returns:
      An array with all variable names that were not bound because the input properties did not map them to VSField's.
      Throws:
      SQLException - If the statement could not be created or if there are missing variable definitions.
      ValueConversionException - For value conversion errors.
    • getClassReference

      public ClassReference getClassReference()
      The Java class associated with input variables.
      Returns:
      The ClassReference instance, or null for none.
    • getInputProvider

      public IQueryStatementInput getInputProvider()
      Gets the instance of the IQueryStatementInput.
      Returns:
      The instance of IQueryStatementInput, or null for none.
    • onVirtualSpaceVirtualized

      public void onVirtualSpaceVirtualized(IAppSessionGyro appGyro, VirtualSpace virtualizedVirtualSpace)
      Called when the VirtualSpace has been virtualized, giving the opportunity for e.g. data connectors to prepare it's virtualized counterparts if this is required.

      This call is done to the non-virtualized instance of the VirtualSpace participant.

      Specified by:
      onVirtualSpaceVirtualized in interface IVSParticipant
      Parameters:
      appGyro - The application gyro instance.
      virtualizedVirtualSpace - The virtualized VirtualSpace instance.