Class PackageDefinitionStrategy.Definition.Simple

    • Field Summary

      Fields 
      Modifier and Type Field Description
      private java.lang.String implementationTitle
      The package implementation's title or null if no such title exists.
      private java.lang.String implementationVendor
      The package implementation's vendor or null if no such vendor exists.
      private java.lang.String implementationVersion
      The package implementation's version or null if no such version exists.
      protected java.net.URL sealBase
      The seal base or null if the package is not sealed.
      private java.lang.String specificationTitle
      The package specification's title or null if no such title exists.
      private java.lang.String specificationVendor
      The package specification's vendor or null if no such vendor exists.
      private java.lang.String specificationVersion
      The package specification's version or null if no such version exists.
    • Constructor Summary

      Constructors 
      Constructor Description
      Simple​(java.lang.String specificationTitle, java.lang.String specificationVersion, java.lang.String specificationVendor, java.lang.String implementationTitle, java.lang.String implementationVersion, java.lang.String implementationVendor, java.net.URL sealBase)
      Creates a new simple package definition.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      boolean equals​(java.lang.Object other)  
      java.lang.String getImplementationTitle()
      Returns the package implementation's title or null if no such title exists.
      java.lang.String getImplementationVendor()
      Returns the package implementation's vendor or null if no such vendor exists.
      java.lang.String getImplementationVersion()
      Returns the package implementation's version or null if no such version exists.
      java.net.URL getSealBase()
      The URL representing the seal base.
      java.lang.String getSpecificationTitle()
      Returns the package specification's title or null if no such title exists.
      java.lang.String getSpecificationVendor()
      Returns the package specification's vendor or null if no such vendor exists.
      java.lang.String getSpecificationVersion()
      Returns the package specification's version or null if no such version exists.
      int hashCode()  
      boolean isCompatibleTo​(java.lang.Package definedPackage)
      Validates that this package definition is compatible to a previously defined package.
      boolean isDefined()
      Indicates if a package should be defined at all.
      • Methods inherited from class java.lang.Object

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

      • sealBase

        protected final java.net.URL sealBase
        The seal base or null if the package is not sealed.
      • specificationTitle

        private final java.lang.String specificationTitle
        The package specification's title or null if no such title exists.
      • specificationVersion

        private final java.lang.String specificationVersion
        The package specification's version or null if no such version exists.
      • specificationVendor

        private final java.lang.String specificationVendor
        The package specification's vendor or null if no such vendor exists.
      • implementationTitle

        private final java.lang.String implementationTitle
        The package implementation's title or null if no such title exists.
      • implementationVersion

        private final java.lang.String implementationVersion
        The package implementation's version or null if no such version exists.
      • implementationVendor

        private final java.lang.String implementationVendor
        The package implementation's vendor or null if no such vendor exists.
    • Constructor Detail

      • Simple

        public Simple​(java.lang.String specificationTitle,
                      java.lang.String specificationVersion,
                      java.lang.String specificationVendor,
                      java.lang.String implementationTitle,
                      java.lang.String implementationVersion,
                      java.lang.String implementationVendor,
                      java.net.URL sealBase)
        Creates a new simple package definition.
        Parameters:
        specificationTitle - The package specification's title or null if no such title exists.
        specificationVersion - The package specification's version or null if no such version exists.
        specificationVendor - The package specification's vendor or null if no such vendor exists.
        implementationTitle - The package implementation's title or null if no such title exists.
        implementationVersion - The package implementation's version or null if no such version exists.
        implementationVendor - The package implementation's vendor or null if no such vendor exists.
        sealBase - The seal base or null if the package is not sealed.
    • Method Detail

      • getSpecificationTitle

        public java.lang.String getSpecificationTitle()
        Returns the package specification's title or null if no such title exists. This method must only be called for defined package definitions.
        Specified by:
        getSpecificationTitle in interface PackageDefinitionStrategy.Definition
        Returns:
        The package specification's title.
      • getSpecificationVersion

        public java.lang.String getSpecificationVersion()
        Returns the package specification's version or null if no such version exists. This method must only be called for defined package definitions.
        Specified by:
        getSpecificationVersion in interface PackageDefinitionStrategy.Definition
        Returns:
        The package specification's version.
      • getSpecificationVendor

        public java.lang.String getSpecificationVendor()
        Returns the package specification's vendor or null if no such vendor exists. This method must only be called for defined package definitions.
        Specified by:
        getSpecificationVendor in interface PackageDefinitionStrategy.Definition
        Returns:
        The package specification's vendor.
      • getImplementationTitle

        public java.lang.String getImplementationTitle()
        Returns the package implementation's title or null if no such title exists. This method must only be called for defined package definitions.
        Specified by:
        getImplementationTitle in interface PackageDefinitionStrategy.Definition
        Returns:
        The package implementation's title.
      • getImplementationVersion

        public java.lang.String getImplementationVersion()
        Returns the package implementation's version or null if no such version exists. This method must only be called for defined package definitions.
        Specified by:
        getImplementationVersion in interface PackageDefinitionStrategy.Definition
        Returns:
        The package implementation's version.
      • getImplementationVendor

        public java.lang.String getImplementationVendor()
        Returns the package implementation's vendor or null if no such vendor exists. This method must only be called for defined package definitions.
        Specified by:
        getImplementationVendor in interface PackageDefinitionStrategy.Definition
        Returns:
        The package implementation's vendor.
      • getSealBase

        public java.net.URL getSealBase()
        The URL representing the seal base. This method must only be called for defined package definitions.
        Specified by:
        getSealBase in interface PackageDefinitionStrategy.Definition
        Returns:
        The seal base of the package.
      • isCompatibleTo

        public boolean isCompatibleTo​(java.lang.Package definedPackage)
        Validates that this package definition is compatible to a previously defined package. This method must only be called for defined package definitions.
        Specified by:
        isCompatibleTo in interface PackageDefinitionStrategy.Definition
        Parameters:
        definedPackage - The previously defined package.
        Returns:
        false if this package and the defined package's sealing information are not compatible.
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object
      • equals

        public boolean equals​(java.lang.Object other)
        Overrides:
        equals in class java.lang.Object