Class DeploymentDescriptor

  • All Implemented Interfaces:
    Copyable<ModuleDescriptor>, CopyableDescriptor<ModuleDescriptor>

    public class DeploymentDescriptor
    extends ModuleDescriptor
    The descriptor handle which corresponds to the already deployed module (not a project one). Contains additionally (strangely enough we extend ModuleDescriptor) to the default persisted properties in the ModuleDescriptor several properties. This type of descriptor currently makes sense only for languages (for the time being) in the light of separating the packaged modules into executable and sources parts. Common packaging for a language 'myLang' incorporates 'myLang.jar' and 'myLang-src.jar' See the common layout of the module descriptor files below: -------------------------------------------- lang-dir/myLang.jar/META-INF/MANIFEST.MF lang-dir/myLang.jar/META-INF/module.xml lang-dir/myLang.jar/<...> lang-dir/myLang-src.jar/module/myLang.mpl lang-dir/myLang-src.jar/<...> -------------------------------------------- Here the source descriptor is 'myLang.mpl' and the executable (deployed) descriptor is 'module.xml'

    TODO merge javadoc from above with doc below:

     Layout of deployed module:
     Jar:
       module.jar/
         META-INF/module.xml
         resources/
         classes/my/package/One.class
           or
         my/package/One.class
         my/package/msg.properties
       aux-library.jar
    
     Folder:
       module-dir/
         META-INF/module.xml
         resources/my/package/msg.properties
         classes/my/package/One.class
    
     module.jar and module-dir are referred to as 'module home'
     

    See Also:
    AP
    • Field Detail

      • TYPE_LANGUAGE

        public static String TYPE_LANGUAGE
      • TYPE_GENERATOR

        public static String TYPE_GENERATOR
      • TYPE_SOLUTION

        public static String TYPE_SOLUTION
    • Constructor Detail

      • DeploymentDescriptor

        public DeploymentDescriptor()
    • Method Detail

      • getSourcesJar

        public final String getSourcesJar()
      • setSourcesJar

        public final void setSourcesJar​(String sourcesJar)
      • getDescriptorFile

        public final String getDescriptorFile()
      • setDescriptorFile

        public final void setDescriptorFile​(String descriptorFile)
      • getType

        public final String getType()
      • setType

        public final void setType​(String type)
      • getLibraries

        @NotNull
        public final List<String> getLibraries()
        Deployed modules may expose own class files, as well as redistribute (or reuse redistributed otherwise) jar libraries required for their operation. Library location starting with "/" indicates distribution-relative path, any other location is relative to distributed module home (which is either parent directory of a .jar file, if module distributed as a jar, or directory with META-INF/ if module isn't in a jar).
        Returns:
        collection of jar files, as written in the deployment descriptor (with no path unwrap/expand done).
      • getClasspath

        @NotNull
        public List<String> getClasspath()
        Locations with module's own classes, relative to module home. Value "." indicates module home itself. Empty value means there are no classes in the module (however, classes still could be loaded through libraries). XXX not sure whether we shall keep libraries and classpath distinct, perhaps, one is enough (provided ModulesMiner#loadDeploymentDescriptor doesn't expose libraries as stubs)
        Returns:
        Locations with module's own classes