Class Module
java.lang.Object
org.eclipse.jetty.start.Module
- All Implemented Interfaces:
Comparable<Module>
Represents a Module metadata, as defined in Jetty.
A module consists of:
- A set of jar files, directories and/or jar file patterns to be added to the classpath
- A list of XML configuration files
- Properties set either directly or via a file of properties
- A set of modules names (or capability names) that this module depends on.
- A set of capability names that this module provides (including it's own name).
- Licence details for using the module
${jetty.home}/modules and
${jetty.home}/modules directories. A module may refer to
non-discovered dynamic module in a subdirectory, using a property as part or
all of the name.
A module may be enabled, either directly by name or transiently via a dependency
from another module by name or provided capability.-
Field Summary
FieldsModifier and TypeFieldDescriptionList of default configDependencies from[depends]sectionThe module descriptionprivate final booleanIs the module dynamic - ie referenced rather than discoveredList of selections for this ModuleList of files for this ModuleList of ini template linesList of JPMS options for this ModuleList of jvm ArgsList of library options for this ModuleLicense linesprivate final StringThe name of the moduleprivate booleanBoolean true if directly enabled, false if all selections are transitiveOptional dependencies from[optional]section are structural in nature.private final PathThe file of the moduleList of provides for this Moduleprivate booleanSkip File Validation (default: false)List of tags for this ModuleList of xml configurations for this Module(package private) static Pattern(package private) static Patternprivate VersionThe version of Jetty the module supportsprivate static final String -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanintbooleanbooleanvoidexpandDependencies(Props props) getFiles()getJPMS()getLibs()getName()getTags()getXmls()booleanbooleaninthashCode()booleanbooleanstatic booleanisConditionalDependency(String depends) booleanIndicates a module that is dynamic in naturebooleanbooleanbooleanstatic StringnormalizeModuleName(String name) voidvoidsetSkipFilesValidation(boolean skipFilesValidation) toString()voidwriteIniSection(BufferedWriter writer, Props props)
-
Field Details
-
VERSION_UNSPECIFIED
- See Also:
-
MOD_NAME
-
SET_PROPERTY
-
_path
The file of the module -
_name
The name of the module -
_dynamic
private final boolean _dynamicIs the module dynamic - ie referenced rather than discovered -
version
The version of Jetty the module supports -
_description
-
_xmls
-
_iniTemplate
-
_defaultConfig
-
_libs
-
_jpms
-
_files
-
_enables
-
_provides
-
_tags
-
_notTransitive
private boolean _notTransitiveBoolean true if directly enabled, false if all selections are transitive -
_skipFilesValidation
private boolean _skipFilesValidationSkip File Validation (default: false) -
_jvmArgs
-
_license
-
_depends
-
_optional
-
-
Constructor Details
-
Module
- Throws:
IOException
-
-
Method Details
-
isConditionalDependency
-
normalizeModuleName
-
getName
-
equals
-
expandDependencies
-
getDefaultConfig
-
getIniTemplate
-
getFiles
-
isSkipFilesValidation
public boolean isSkipFilesValidation() -
getJvmArgs
-
getLibs
-
getLicense
-
getXmls
-
getJPMS
-
getVersion
-
hasDefaultConfig
public boolean hasDefaultConfig() -
hasIniTemplate
public boolean hasIniTemplate() -
hashCode
-
hasLicense
public boolean hasLicense() -
isDynamic
public boolean isDynamic()Indicates a module that is dynamic in nature- Returns:
- a module where the name is not in the top level of the modules directory
-
hasFiles
-
process
- Throws:
IOException
-
clearTransitiveEnable
public boolean clearTransitiveEnable() -
setSkipFilesValidation
public void setSkipFilesValidation(boolean skipFilesValidation) -
toString
-
getDepends
-
getProvides
-
getOptional
-
getDescription
-
getTags
-
getPrimaryTag
-
isEnabled
public boolean isEnabled() -
getEnableSources
-
enable
- Parameters:
source- String describing where the module was enabled fromtransitive- True if the enable is transitive- Returns:
- true if the module was not previously enabled
-
isTransitive
public boolean isTransitive() -
writeIniSection
-
compareTo
- Specified by:
compareToin interfaceComparable<Module>
-