Class ModuleInfo
java.lang.Object
com.inductiveautomation.ignition.common.modules.ModuleInfo
- All Implemented Interfaces:
Serializable
Contains meta information about a module, such as its id, name description, required versions, hook classes, and jar
file information
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic class
static class
Contains meta information about a module's jar file, such as its scope and native lib parameters, and path within the module package.static class
static class
-
Method Summary
Modifier and TypeMethodDescriptionboolean
long
getCrc()
The module file's crc is calculated when the modl file is loaded in the Gateway.getDependencies
(int scope) The root of the module's documentation, expected to be an HTML file and must be stored under a folder named "doc"getHooks()
getId()
The location of the module on the local file system.getJars()
The name of an HTML-formatted license file to be found in the module's *.modl filegetName()
int
int
int
hashCode()
boolean
isFree()
boolean
boolean
boolean
Returns true if the module is not marked as a free module AND either the module's license state is not set or the license state is a trial licensestatic ModuleInfo.Builder
void
setCrc
(long crc) void
setFree()
Set to true when modules implement GatewayModuleHook.isFreeModule() to return truevoid
setInstallPath
(String installPath) Sets the location of the module on the local file system.void
setLicenseState
(LicenseState newState) void
void
Setter needs to exist so that the Marketplace can add the selfsigned=true property to a module.xml when a user is signing their own module.void
setVendorInfo
(int vendorId, String vendorName, String vendorContactInfo) Setter needs to exist so that the Marketplace can add the vendor info to module.xml when uploading a customer's module.static List<ModuleInfo>
sortDependencyOrder
(List<ModuleInfo> list, int scope, boolean reverse) Sorts the list of module infos in correct dependency order.toString()
toXML()
-
Method Details
-
newBuilder
-
getId
- Returns:
- The id for this module. Must be unique.
-
getName
- Returns:
- Human-readable name for the module
-
getDescription
-
getVendorId
public int getVendorId() -
getVendorName
-
getVendorContactInfo
-
setVendorInfo
Setter needs to exist so that the Marketplace can add the vendor info to module.xml when uploading a customer's module. -
getLicenseFile
The name of an HTML-formatted license file to be found in the module's *.modl file -
getDocumentationRoot
The root of the module's documentation, expected to be an HTML file and must be stored under a folder named "doc" -
getVersion
-
getRequiredIgnitionVersion
-
getRequiredFrameworkVersion
public int getRequiredFrameworkVersion() -
getHooks
-
getJars
-
getExports
-
getLibsRequired
-
getDependencies
-
getDependencies
-
isFree
public boolean isFree() -
isSelfSigned
public boolean isSelfSigned() -
setFree
public void setFree()Set to true when modules implement GatewayModuleHook.isFreeModule() to return true -
isMakerEditionCompatible
public boolean isMakerEditionCompatible() -
setMakerEditionCompatible
public void setMakerEditionCompatible() -
setSelfSigned
public void setSelfSigned()Setter needs to exist so that the Marketplace can add the selfsigned=true property to a module.xml when a user is signing their own module. -
isTrialMode
public boolean isTrialMode()Returns true if the module is not marked as a free module AND either the module's license state is not set or the license state is a trial license -
equals
-
hashCode
public int hashCode() -
getLicenseState
-
setLicenseState
-
getCrc
public long getCrc()The module file's crc is calculated when the modl file is loaded in the Gateway. -
setCrc
public void setCrc(long crc) -
getInstallPath
The location of the module on the local file system. The value should be an absolute path. Intentionally left out of XML generation since the install path has no meaning outside the local system. -
setInstallPath
Sets the location of the module on the local file system. The value should be an absolute path. -
toString
-
toXML
-
sortDependencyOrder
public static List<ModuleInfo> sortDependencyOrder(List<ModuleInfo> list, int scope, boolean reverse) throws DependencyCycleException Sorts the list of module infos in correct dependency order. Uses a digraph to sort the modules. Will ignore missing dependencies.- Throws:
DependencyCycleException
- If a dependency cycle is detected
-