Class AbstractYamlService

  • Direct Known Subclasses:
    YamlService

    public abstract class AbstractYamlService
    extends java.lang.Object
    Basic information about a service, abstract because template-based service objects do not work with SnakeYaml. By default, reference types are created based on the attribute definition in the class. As soon as mechanisms are available to handle this, these additional classes may collapse into a more simple hierarchy.
    Author:
    Holger Eichelberger, SSE
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.String getApplicationId()
      Returns the application id this service is assigned to (without application instance id).
      java.lang.String getApplicationInstanceId()
      Returns the application instance id this service is running within.
      java.lang.String getDescription()
      Returns the description of the service.
      java.lang.String getId()
      Returns the unique id of the service.
      ServiceKind getKind()
      Sets the service kind.
      java.lang.String getName()
      Returns the name of the service.
      java.lang.String getNetMgtKey()
      Returns the network management key of a service instance this service is relying on.
      java.lang.String getServiceId()
      Returns the service id of the service, i.e.
      java.lang.String getTransportChannel()
      Returns the transport channel to utilize via getNetMgtKey().
      de.iip_ecosphere.platform.support.iip_aas.Version getVersion()
      Returns the version of the service.
      boolean isDeployable()
      Returns whether this service is decentrally deployable.
      boolean isTopLevel()
      Returns whether this service is top-level.
      void setApplicationId​(java.lang.String applicationId)
      Defines the application id this service is assigned to.
      void setDeployable​(boolean deployable)
      Sets whether this service is decentrally deployable.
      void setDescription​(java.lang.String description)
      Defines the description of the service.
      void setId​(java.lang.String id)
      Defines the id of the service.
      void setKind​(ServiceKind kind)
      Sets the service kind.
      void setName​(java.lang.String name)
      Defines the name of the service.
      void setNetMgtKey​(java.lang.String netMgtKey)
      Defines the network management key of a service instance this service is relying on.
      void setTopLevel​(boolean topLevel)
      Sets whether this service is a top-level service.
      void setTransportChannel​(java.lang.String transportChannel)
      Defines the transport channel to utilize via getNetMgtKey().
      void setVersion​(de.iip_ecosphere.platform.support.iip_aas.Version version)
      Defines the version of the service.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • id

        private java.lang.String id
      • applicationId

        private java.lang.String applicationId
      • name

        private java.lang.String name
      • version

        private de.iip_ecosphere.platform.support.iip_aas.Version version
      • description

        private java.lang.String description
      • deployable

        private boolean deployable
      • topLevel

        private boolean topLevel
      • netMgtKey

        private java.lang.String netMgtKey
      • transportChannel

        private java.lang.String transportChannel
    • Constructor Detail

      • AbstractYamlService

        public AbstractYamlService()
    • Method Detail

      • getApplicationId

        public java.lang.String getApplicationId()
        Returns the application id this service is assigned to (without application instance id).
        Returns:
        the application id
      • getApplicationInstanceId

        public java.lang.String getApplicationInstanceId()
        Returns the application instance id this service is running within. Usually, the application id shall be a prefix of this id.
        Returns:
        the application instance id (may be empty for the default application instance)
      • getNetMgtKey

        public java.lang.String getNetMgtKey()
        Returns the network management key of a service instance this service is relying on.
        Returns:
        the network management key, may be empty or null for none
      • getTransportChannel

        public java.lang.String getTransportChannel()
        Returns the transport channel to utilize via getNetMgtKey().
        Returns:
        the transport channel, may be empty or null for none if the service uses an own mechanism (discouraged if getNetMgtKey() is given)
      • getName

        public java.lang.String getName()
        Returns the name of the service.
        Returns:
        the name
      • getVersion

        public de.iip_ecosphere.platform.support.iip_aas.Version getVersion()
        Returns the version of the service.
        Returns:
        the version
      • getDescription

        public java.lang.String getDescription()
        Returns the description of the service.
        Returns:
        the description
      • getKind

        public ServiceKind getKind()
        Sets the service kind.
        Returns:
        the service kind
      • isDeployable

        public boolean isDeployable()
        Returns whether this service is decentrally deployable.
        Returns:
        true for deployable, false for not deployable
      • isTopLevel

        public boolean isTopLevel()
        Returns whether this service is top-level.
        Returns:
        true for top-level, false for nested
      • setId

        public void setId​(java.lang.String id)
        Defines the id of the service. [required by SnakeYaml]
        Parameters:
        id - the id (may contain the application id if specified)
      • setName

        public void setName​(java.lang.String name)
        Defines the name of the service. [required by SnakeYaml]
        Parameters:
        name - the name
      • setApplicationId

        public void setApplicationId​(java.lang.String applicationId)
        Defines the application id this service is assigned to. [required by SnakeYaml]
        Parameters:
        applicationId - the application id
      • setNetMgtKey

        public void setNetMgtKey​(java.lang.String netMgtKey)
        Defines the network management key of a service instance this service is relying on.
        Parameters:
        netMgtKey - the network management key, may be empty or null for none
      • setTransportChannel

        public void setTransportChannel​(java.lang.String transportChannel)
        Defines the transport channel to utilize via getNetMgtKey().
        Parameters:
        transportChannel - the transport channel, may be empty or null for none if the service uses an own mechanism (discouraged if getNetMgtKey() is given)
      • setVersion

        public void setVersion​(de.iip_ecosphere.platform.support.iip_aas.Version version)
        Defines the version of the service. [required by SnakeYaml]
        Parameters:
        version - the version
      • setDescription

        public void setDescription​(java.lang.String description)
        Defines the description of the service. [required by SnakeYaml]
        Parameters:
        description - the description (null is ignored, default is empty)
      • setDeployable

        public void setDeployable​(boolean deployable)
        Sets whether this service is decentrally deployable.
        Parameters:
        deployable - true for deployable, false for not deployable
      • setTopLevel

        public void setTopLevel​(boolean topLevel)
        Sets whether this service is a top-level service.
        Parameters:
        topLevel - true for topLevel, false for nested
      • setKind

        public void setKind​(ServiceKind kind)
        Sets the service kind. [required by SnakeYaml]
        Parameters:
        kind - the service kind