Interface ConfigurationManager
- All Superinterfaces:
ResourceCollectionManager
The ConfigurationManager is the primary interface for interacting with the configuration of a Gateway. It provides
access to the various configuration collections, as well as the ability to add resources to the configuration.
When reading configuration, always read from the "local" collection. Because of the inheritance chain set up by this manager, this ensures you will be reading the correct version of any configured resource.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final String
static final String
static final String
static final String
Fields inherited from interface com.inductiveautomation.ignition.gateway.resourcecollection.ResourceCollectionManager
DEFAULT_NAME_PATTERN
-
Method Summary
Modifier and TypeMethodDescriptionvoid
addSystemResources
(List<Resource> resources) Adds a collection of resources to the "system" resource collection - the ancestor of all other configuration collections.default ResourceCollection
Get the resource collection that represents this gateway's configuration, for the currently active mode.getConfigCollection
(ResourceFilter filter) Get the resource collection that represents this gateway's configuration, for the currently active mode.getModes()
Get the names of the configuration modes that have been defined.getNamedResource
(ResourceType resourceType, String resourceName) Looks for the active definition of a named resource of the given type and name.getResource
(ResourcePath path) Looks for the active definition of a resource at the given path.getResources
(ResourceType resourceType) getSingletonResource
(ResourceType resourceType) Looks for the active definition of a singleton resource of the given type.boolean
Methods inherited from interface com.inductiveautomation.ignition.gateway.resourcecollection.ResourceCollectionManager
addListener, copy, create, createOrReplace, createSafe, createSafe, delete, export, find, find, find, getDefiningCollectionNames, getManifests, getNames, getResource, isMutable, pull, pull, push, push, pushPartial, removeListener, requestScan
-
Field Details
-
SYSTEM
- See Also:
-
EXTERNAL
- See Also:
-
CORE
- See Also:
-
LOCAL
- See Also:
-
-
Method Details
-
getConfigCollection
Get the resource collection that represents this gateway's configuration, for the currently active mode. This is equivalent to callinggetConfigCollection(ResourceFilter.ALL_RESOURCES)
Technically speaking, this reads from the "local" collection, which is the bottom of the inheritance chain.
-
isNewConfiguration
boolean isNewConfiguration()- Returns:
- true if the configuration collection was created during this gateway's startup. Indicates a fresh install, or an upgrade from 8.1 to 8.3+.
-
addSystemResources
Adds a collection of resources to the "system" resource collection - the ancestor of all other configuration collections. -
getSingletonResource
Looks for the active definition of a singleton resource of the given type. The "active" definition is the one that is currently in effect, taking into account the inheritance structure and configuration mode. -
getNamedResource
Looks for the active definition of a named resource of the given type and name. The "active" definition is the one that is currently in effect, taking into account the inheritance structure and configuration mode. -
getResource
Looks for the active definition of a resource at the given path. The "active" definition is the one that is currently in effect, taking into account the inheritance structure and configuration mode. -
getResources
-
getConfigCollection
Get the resource collection that represents this gateway's configuration, for the currently active mode.- Parameters:
filter
- The filter to apply to the resources in the collection.
-
getActiveMode
- Returns:
- The name of the currently active configuration mode, or an empty Optional if no mode is active.
-
getModes
Get the names of the configuration modes that have been defined. Omits the "core", "local", and "external" modes. -
getResourceTypeMetaRegistry
ResourceTypeMetaRegistry getResourceTypeMetaRegistry() -
getMigrationStrategyRegistry
MigrationStrategyRegistry getMigrationStrategyRegistry()
-