Package iip.impl

Class SimpleDataSourceImpl

java.lang.Object
de.iip_ecosphere.platform.services.environment.AbstractService
de.iip_ecosphere.platform.services.environment.DefaultServiceImpl
iip.impl.SimpleDataSourceImpl
All Implemented Interfaces:
de.iip_ecosphere.platform.services.environment.ParameterConfigurerProvider, de.iip_ecosphere.platform.services.environment.Service, de.iip_ecosphere.platform.services.environment.switching.ServiceBase, SimpleDataSourceInterface

public abstract class SimpleDataSourceImpl extends de.iip_ecosphere.platform.services.environment.DefaultServiceImpl implements SimpleDataSourceInterface
IIP-Ecosphere supporting service implementation for 'Simple Data Source'. Generated by: EASy-Producer.
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    private Map<String,de.iip_ecosphere.platform.services.environment.ParameterConfigurer<?>>
     
    private List<de.iip_ecosphere.platform.services.environment.DataIngestor<Rec1>>
     

    Fields inherited from interface de.iip_ecosphere.platform.services.environment.switching.ServiceBase

    APPLICATION_SEPARATOR, DEFAULT_APPLICATION_INSTANCE_ID

    Fields inherited from interface iip.interfaces.SimpleDataSourceInterface

    SERVICE_ID
  • Constructor Summary

    Constructors
    Modifier
    Constructor
    Description
    protected
    SimpleDataSourceImpl(de.iip_ecosphere.platform.services.environment.ServiceKind kind)
    Fallback constructor setting most fields to "empty" default values.
    protected
    SimpleDataSourceImpl(de.iip_ecosphere.platform.services.environment.YamlService yaml)
    Creates a service instance from YAML information.
    protected
    SimpleDataSourceImpl(String serviceId, de.iip_ecosphere.platform.services.environment.ServiceKind kind)
    Fallback constructor setting most fields to "empty" default values.
    protected
    Creates a service instance from a service id and a YAML artifact.
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    attachRec1Ingestor(de.iip_ecosphere.platform.services.environment.DataIngestor<Rec1> ingestor)
    Attaches a return value ingestor for asynchronous processing.
    Creates an actual instance of the output type Rec1.
    de.iip_ecosphere.platform.services.environment.ParameterConfigurer<?>
     
     
    protected boolean
    Returns whether there are registered Rec1 ingestors.
    protected int
    Returns the number of registered Rec1 ingestors.
    protected void
    Sends data to all registered Rec1 ingestors.
    protected void
    Registers the configurers.

    Methods inherited from class de.iip_ecosphere.platform.services.environment.DefaultServiceImpl

    migrate, switchTo, update

    Methods inherited from class de.iip_ecosphere.platform.services.environment.AbstractService

    activate, addConfigurer, addConfigurer, addConfigurer, addTypeSubstitution, createInstance, createInstance, createInstance, getDescription, getId, getKind, getName, getNetMgtKeyAddress, getResourceAsStream, getState, getSubstitutedType, getTypeCreator, getTypeSubstitutions, getVersion, initializeFrom, isDeployable, isTopLevel, notifyReconfigured, passivate, reconf, reconfigure, reconfigure, rollbackReconfigurationOnFailure, setLibJars, setState, start, stop, transferData

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface de.iip_ecosphere.platform.services.environment.Service

    activate, addTypeSubstitution, createType, createType, getDescription, getKind, getName, getNetMgtKeyAddress, getSubstitutedType, getTypeCreator, getTypeSubstitutions, getVersion, isDeployable, isTopLevel, migrate, passivate, reconfigure, switchTo, update

    Methods inherited from interface de.iip_ecosphere.platform.services.environment.switching.ServiceBase

    getId, getState, setState
  • Field Details

    • rec1Ingestors

      private List<de.iip_ecosphere.platform.services.environment.DataIngestor<Rec1>> rec1Ingestors
    • paramConfigurers

      private Map<String,de.iip_ecosphere.platform.services.environment.ParameterConfigurer<?>> paramConfigurers
  • Constructor Details

    • SimpleDataSourceImpl

      protected SimpleDataSourceImpl(de.iip_ecosphere.platform.services.environment.ServiceKind kind)
      Fallback constructor setting most fields to "empty" default values.
      Parameters:
      kind - the service kind
    • SimpleDataSourceImpl

      protected SimpleDataSourceImpl(String serviceId, de.iip_ecosphere.platform.services.environment.ServiceKind kind)
      Fallback constructor setting most fields to "empty" default values.
      Parameters:
      serviceId - the id of the service
      kind - the service kind
    • SimpleDataSourceImpl

      protected SimpleDataSourceImpl(de.iip_ecosphere.platform.services.environment.YamlService yaml)
      Creates a service instance from YAML information.
      Parameters:
      yaml - the service information as read from YAML
    • SimpleDataSourceImpl

      protected SimpleDataSourceImpl(String serviceId, InputStream ymlFile)
      Creates a service instance from a service id and a YAML artifact.
      Parameters:
      serviceId - the id of the service
      ymlFile - the YML file containing the YAML artifact with the service descriptor
  • Method Details

    • getParameterConfigurer

      public de.iip_ecosphere.platform.services.environment.ParameterConfigurer<?> getParameterConfigurer(String paramName)
      Specified by:
      getParameterConfigurer in interface de.iip_ecosphere.platform.services.environment.ParameterConfigurerProvider
      Specified by:
      getParameterConfigurer in interface de.iip_ecosphere.platform.services.environment.Service
    • getParameterNames

      public Set<String> getParameterNames()
      Specified by:
      getParameterNames in interface de.iip_ecosphere.platform.services.environment.ParameterConfigurerProvider
      Specified by:
      getParameterNames in interface de.iip_ecosphere.platform.services.environment.Service
    • registerParameterConfigurers

      protected void registerParameterConfigurers()
      Registers the configurers.
    • attachRec1Ingestor

      public void attachRec1Ingestor(de.iip_ecosphere.platform.services.environment.DataIngestor<Rec1> ingestor)
      Description copied from interface: SimpleDataSourceInterface
      Attaches a return value ingestor for asynchronous processing.
      Specified by:
      attachRec1Ingestor in interface SimpleDataSourceInterface
      Parameters:
      ingestor - the ingestor instance
    • hasRec1Ingestor

      protected boolean hasRec1Ingestor()
      Returns whether there are registered Rec1 ingestors.
      Returns:
      true if there are Rec1 ingestors, false else
    • hasRec1IngestorCount

      protected int hasRec1IngestorCount()
      Returns the number of registered Rec1 ingestors.
      Returns:
      the number of Rec1 ingestors
    • ingestRec1

      protected void ingestRec1(Rec1 data)
      Sends data to all registered Rec1 ingestors.
      Parameters:
      data - the data to be sent
    • createRec1

      public Rec1 createRec1()
      Creates an actual instance of the output type Rec1.