Class AbstractVersion

    • Constructor Detail

      • AbstractVersion

        protected AbstractVersion​(String versionHandlerId,
                                  String componentId)
        Create a version to be stored
        Parameters:
        versionHandlerId - id of the VersionHandler
        componentId - id of the component
      • AbstractVersion

        protected AbstractVersion​(String versionHandlerId,
                                  String componentId,
                                  String versionNumber,
                                  Instant executionInstant,
                                  String comment)
        Create a version to be stored
        Parameters:
        versionHandlerId - id of the VersionHandler
        componentId - id of the component
        versionNumber - version number of the upgrade that created this version
        executionInstant - time of the application of this version
        comment - comment stored about this version
      • AbstractVersion

        protected AbstractVersion​(ActionData actionData)
        Create a version from the data of an ActionData and its associated version.
        Parameters:
        actionData - The action data
    • Method Detail

      • getComment

        public String getComment()
        Description copied from interface: Version
        Get the comment about this version
        Specified by:
        getComment in interface Version
        Returns:
        The comment about this version
      • setVersionNumber

        public void setVersionNumber​(String versionNumber)
        Description copied from interface: Version
        Set the number of the version Should only be used in initialization actions, so the version contains the version to reach, not the version to start (which should be null in the case of initialization)
        Specified by:
        setVersionNumber in interface Version
        Parameters:
        versionNumber - number to set for this version
      • setExecutionInstant

        public void setExecutionInstant​(Instant executionInstant)
        Description copied from interface: Version
        Set the execution date of this version (only to be used when creating a new version after cloning an old version)
        Specified by:
        setExecutionInstant in interface Version
        Parameters:
        executionInstant - instant to set
      • setComment

        public void setComment​(String comment)
        Description copied from interface: Version
        Change the comment of the version
        Specified by:
        setComment in interface Version
        Parameters:
        comment - comment to set
      • addAdditionalValue

        public Object addAdditionalValue​(String key,
                                         Object value)
        Description copied from interface: Version
        Add a parameter that will be replaced in the script with the value
        Specified by:
        addAdditionalValue in interface Version
        Parameters:
        key - key to replace
        value - value that will be inserted
        Returns:
        the previous value associated with key, or null if there was no mapping for key.