Class GatewayContextDecorator
- java.lang.Object
- 
- com.inductiveautomation.ignition.gateway.model.GatewayContextDecorator
 
- 
- All Implemented Interfaces:
- ExecutionManagerFactory,- CommonContext,- GatewayContext
 
 public abstract class GatewayContextDecorator extends java.lang.Object implements GatewayContext Simple abstract decorator forGatewayContext
- 
- 
Field Summary- 
Fields inherited from interface com.inductiveautomation.ignition.gateway.model.GatewayContextSERVLET_CONTEXT_KEY
 
- 
 - 
Constructor SummaryConstructors Constructor Description GatewayContextDecorator(GatewayContext gatewayContext)
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description javax.sql.DataSourcecreateDataSource(java.util.Properties connectionProps)Will create a javax.sql.DataSource that uses connection pooling through apache's DBCP2XMLDeserializercreateDeserializer()Returns an instance of the XMLDeserializer that can be used to deserialize project resources.ExecutionManagercreateExecutionManager(java.lang.String name, int threadCount)Creates a new, private execution engine.ExecutionManagercreateExecutionManager(java.lang.String name, int threadCount, java.util.concurrent.ThreadFactory factory)AlarmManagergetAlarmManager()The alarm manager is the central hub for alarming.AuditManagergetAuditManager()DatasourceManagergetDatasourceManager()java.util.List<EdgeEdition>getEdgeEditions()Returns a list of currently available Edge editions (either licensed or in trial).EdgeSystemPropertiesRecordgetEdgeSystemProperties()Convenience function to look up the EdgeSystemPropertiesRecord.com.google.common.eventbus.EventBusgetEventBus()This is a generic event bus that can be used by any part of Ignition within a single scope (jvm)ExecutionManagergetExecutionManager()Returns the shared execution manager for the gateway.java.util.concurrent.ExecutorServicegetExecutorService()FunctionFactorygetExpressionFunctionFactory()Returns the core function factory used by expressions.GatewayNetworkManagergetGatewayAreaNetworkManager()GatewaySessionManagergetGatewaySessionManager()HistoryManagergetHistoryManager()HttpClientManagergetHttpClientManager()IdpAdapterManagergetIdpAdapterManager()ImageManagergetImageManager()java.util.UUIDgetInstanceToken()Returns a UUID that is generated fresh every time the context starts up.LaunchManagergetLaunchManager()LicenseManagergetLicenseManager()LicenseStategetLicenseState(java.lang.String moduleId)Returns the license state for the given moduleDBInterfacegetLocalDBInterface()PersistenceInterfacegetLocalPersistenceInterface()Returns an interface to the persistence system that bypasses redundancy, and goes directly to the internal database.GatewayLoggingManagergetLoggingManager()MessageDispatchManagergetMessageDispatchManager()The MessageDispatchManager is used to send script messages to message handlers running on clients and the Gateway.MetricHistoryManagergetMetricHistoryManager()Returns the MetricHistoryManager, which allows system metric history to be stored for a limited amount of time.com.codahale.metrics.MetricRegistrygetMetricRegistry()Returns the Gateway MetricRegistry, where various metrics like meters and gauges can be accessed.MetricsDashboardsManagergetMetricsDashboardsManager()java.lang.ObjectgetModule(java.lang.String id)Returns the hook class for another module, used for modules that deal with each other's models.ModuleManagergetModuleManager()ModuleServicesManagergetModuleServicesManager()NamedQueryManagergetNamedQueryManager()Returns the appropriate named query rpc for the context.NativeLibraryManagergetNativeLibraryManager()TheNativeLibraryManagercan be used to load gateway-scoped native libraries on a ClassLoader that is reachable by all modules.OpcConnectionManagergetOpcManager()PerformanceMonitorgetPerformanceMonitor()PersistenceInterfacegetPersistenceInterface()Returns an interface to the internal database persistence system.GatewayProgressManagergetProgressManager()ProjectManagergetProjectManager()RedundancyManagergetRedundancyManager()java.util.concurrent.ScheduledExecutorServicegetScheduledExecutorService()ScheduleManagergetScheduleManager()Get the manager that holds all of the defined schedules.SchemaUpdatergetSchemaUpdater()ScriptManagergetScriptManager()Returns the ScriptManager that can be used to execute Python scripts.SecurityLevelManagergetSecurityLevelManager()SecurityZoneManagergetSecurityZoneManager()SmtpManagergetSmtpManager()ContextStategetState()java.lang.StringgetStateMessage()May return a string describing why the context is in its current stateSyncManagergetSyncManager()SystemManagergetSystemManager()SystemPropertiesRecordgetSystemProperties()Convenience function to look up the SystemPropertiesRecord.GatewayTagHistoryManagergetTagHistoryManager()GatewayTagManagergetTagManager()Returns the manager that provides access to Ignition's tag system.TaskManagergetTaskManager()TelemetryManagergetTelemetryManager()UserSourceManagergetUserSourceManager()This manager holds all of the configured user sources in the system.java.util.Optional<WebAuthStrategyAdapter>getWebAuthStrategyAdapter(java.lang.String type)Get theWebAuthStrategyAdapterregistered with the given typeWebResourceManagergetWebResourceManager()- 
Methods inherited from class java.lang.Objectclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 - 
Methods inherited from interface com.inductiveautomation.ignition.gateway.model.GatewayContextgetDiagnosticsManager
 
- 
 
- 
- 
- 
Constructor Detail- 
GatewayContextDecoratorpublic GatewayContextDecorator(@Nonnull GatewayContext gatewayContext)
 
- 
 - 
Method Detail- 
getDatasourceManagerpublic DatasourceManager getDatasourceManager() - Specified by:
- getDatasourceManagerin interface- GatewayContext
 
 - 
getUserSourceManagerpublic UserSourceManager getUserSourceManager() Description copied from interface:GatewayContextThis manager holds all of the configured user sources in the system. User sources are used for authentication and managing users' contact info, schedules, etc.- Specified by:
- getUserSourceManagerin interface- GatewayContext
 
 - 
getSecurityZoneManagerpublic SecurityZoneManager getSecurityZoneManager() - Specified by:
- getSecurityZoneManagerin interface- GatewayContext
 
 - 
getScheduleManagerpublic ScheduleManager getScheduleManager() Description copied from interface:GatewayContextGet the manager that holds all of the defined schedules. Schedules are used in alarm notification.- Specified by:
- getScheduleManagerin interface- GatewayContext
 
 - 
getAuditManagerpublic AuditManager getAuditManager() - Specified by:
- getAuditManagerin interface- GatewayContext
 
 - 
getAlarmManagerpublic AlarmManager getAlarmManager() Description copied from interface:GatewayContextThe alarm manager is the central hub for alarming. It is generally used for querying, both status and historical, but can also be used to register new alarm events, and subscribe to alarm events.- Specified by:
- getAlarmManagerin interface- GatewayContext
 
 - 
getInstanceTokenpublic java.util.UUID getInstanceToken() Description copied from interface:GatewayContextReturns a UUID that is generated fresh every time the context starts up.- Specified by:
- getInstanceTokenin interface- GatewayContext
 
 - 
getLocalDBInterfacepublic DBInterface getLocalDBInterface() - Specified by:
- getLocalDBInterfacein interface- GatewayContext
 
 - 
getPersistenceInterfacepublic PersistenceInterface getPersistenceInterface() Description copied from interface:GatewayContextReturns an interface to the internal database persistence system. This version of the function (as compared to getLocalPersistenceInterface()) handles additional tasks, such as replicating data to the redundant backup, and is the version that should be used for most tasks.- Specified by:
- getPersistenceInterfacein interface- GatewayContext
 
 - 
getLocalPersistenceInterfacepublic PersistenceInterface getLocalPersistenceInterface() Description copied from interface:GatewayContextReturns an interface to the persistence system that bypasses redundancy, and goes directly to the internal database. In general, this should NOT be used. Instead, most module authors will want to use getPersistenceInterface(). This- Specified by:
- getLocalPersistenceInterfacein interface- GatewayContext
 
 - 
createDataSourcepublic javax.sql.DataSource createDataSource(java.util.Properties connectionProps) throws java.lang.ExceptionDescription copied from interface:GatewayContextWill create a javax.sql.DataSource that uses connection pooling through apache's DBCP2- Specified by:
- createDataSourcein interface- GatewayContext
- Throws:
- java.lang.Exception
 
 - 
getSchemaUpdaterpublic SchemaUpdater getSchemaUpdater() - Specified by:
- getSchemaUpdaterin interface- GatewayContext
 
 - 
getExecutionManagerpublic ExecutionManager getExecutionManager() Description copied from interface:GatewayContextReturns the shared execution manager for the gateway. Only schedule tasks in here that will not block, which could cause thread starvation.- Specified by:
- getExecutionManagerin interface- GatewayContext
 
 - 
getExecutorServicepublic java.util.concurrent.ExecutorService getExecutorService() - Specified by:
- getExecutorServicein interface- GatewayContext
 
 - 
getScheduledExecutorServicepublic java.util.concurrent.ScheduledExecutorService getScheduledExecutorService() - Specified by:
- getScheduledExecutorServicein interface- GatewayContext
 
 - 
getRedundancyManagerpublic RedundancyManager getRedundancyManager() - Specified by:
- getRedundancyManagerin interface- GatewayContext
 
 - 
getGatewaySessionManagerpublic GatewaySessionManager getGatewaySessionManager() - Specified by:
- getGatewaySessionManagerin interface- GatewayContext
 
 - 
getModuleServicesManagerpublic ModuleServicesManager getModuleServicesManager() - Specified by:
- getModuleServicesManagerin interface- GatewayContext
 
 - 
getSystemPropertiespublic SystemPropertiesRecord getSystemProperties() Description copied from interface:GatewayContextConvenience function to look up the SystemPropertiesRecord. Make sure not to call this if you already have a session open, because you can't open 2 sessions in the same thread. Instead, just use:session.find(SystemPropertiesRecord.META, SQueryMode.SBASIC, 0L); - Specified by:
- getSystemPropertiesin interface- GatewayContext
 
 - 
getOpcManagerpublic OpcConnectionManager getOpcManager() - Specified by:
- getOpcManagerin interface- GatewayContext
 
 - 
getTagHistoryManagerpublic GatewayTagHistoryManager getTagHistoryManager() - Specified by:
- getTagHistoryManagerin interface- GatewayContext
 
 - 
getHistoryManagerpublic HistoryManager getHistoryManager() - Specified by:
- getHistoryManagerin interface- GatewayContext
 
 - 
getSmtpManagerpublic SmtpManager getSmtpManager() - Specified by:
- getSmtpManagerin interface- GatewayContext
 
 - 
getImageManagerpublic ImageManager getImageManager() - Specified by:
- getImageManagerin interface- GatewayContext
 
 - 
getNamedQueryManagerpublic NamedQueryManager getNamedQueryManager() Description copied from interface:GatewayContextReturns the appropriate named query rpc for the context. In the gateway and client, we only want to use named queries that have been saved. In the designer, we want to use the current version so that reports and bindings can be seen and used for testing before the project is saved.- Specified by:
- getNamedQueryManagerin interface- GatewayContext
- Returns:
- The correct NamedQueryManager implementation for the scope.
 
 - 
getStatepublic ContextState getState() - Specified by:
- getStatein interface- GatewayContext
 
 - 
getStateMessagepublic java.lang.String getStateMessage() Description copied from interface:GatewayContextMay return a string describing why the context is in its current state- Specified by:
- getStateMessagein interface- GatewayContext
 
 - 
getProjectManagerpublic ProjectManager getProjectManager() - Specified by:
- getProjectManagerin interface- GatewayContext
 
 - 
getModuleManagerpublic ModuleManager getModuleManager() - Specified by:
- getModuleManagerin interface- GatewayContext
 
 - 
getLicenseManagerpublic LicenseManager getLicenseManager() - Specified by:
- getLicenseManagerin interface- GatewayContext
 
 - 
getLaunchManagerpublic LaunchManager getLaunchManager() - Specified by:
- getLaunchManagerin interface- GatewayContext
 
 - 
getPerformanceMonitorpublic PerformanceMonitor getPerformanceMonitor() - Specified by:
- getPerformanceMonitorin interface- GatewayContext
 
 - 
getProgressManagerpublic GatewayProgressManager getProgressManager() - Specified by:
- getProgressManagerin interface- GatewayContext
 
 - 
getNativeLibraryManagerpublic NativeLibraryManager getNativeLibraryManager() Description copied from interface:GatewayContextTheNativeLibraryManagercan be used to load gateway-scoped native libraries on a ClassLoader that is reachable by all modules.- Specified by:
- getNativeLibraryManagerin interface- GatewayContext
- Returns:
- The NativeLibraryManager.
 
 - 
getMessageDispatchManagerpublic MessageDispatchManager getMessageDispatchManager() Description copied from interface:GatewayContextThe MessageDispatchManager is used to send script messages to message handlers running on clients and the Gateway.- Specified by:
- getMessageDispatchManagerin interface- GatewayContext
 
 - 
getGatewayAreaNetworkManagerpublic GatewayNetworkManager getGatewayAreaNetworkManager() - Specified by:
- getGatewayAreaNetworkManagerin interface- GatewayContext
 
 - 
getTaskManagerpublic TaskManager getTaskManager() - Specified by:
- getTaskManagerin interface- GatewayContext
 
 - 
getLoggingManagerpublic GatewayLoggingManager getLoggingManager() - Specified by:
- getLoggingManagerin interface- CommonContext
- Specified by:
- getLoggingManagerin interface- GatewayContext
 
 - 
getMetricRegistrypublic com.codahale.metrics.MetricRegistry getMetricRegistry() Description copied from interface:GatewayContextReturns the Gateway MetricRegistry, where various metrics like meters and gauges can be accessed. *NOTE* if you have registered a metric in MetricHistoryManager, do not delete it directly from MetricRegistry! Use MetricHistoryManager.unregister() instead.- Specified by:
- getMetricRegistryin interface- GatewayContext
 
 - 
getMetricHistoryManagerpublic MetricHistoryManager getMetricHistoryManager() Description copied from interface:GatewayContextReturns the MetricHistoryManager, which allows system metric history to be stored for a limited amount of time.- Specified by:
- getMetricHistoryManagerin interface- GatewayContext
 
 - 
getScriptManagerpublic ScriptManager getScriptManager() Description copied from interface:CommonContextReturns the ScriptManager that can be used to execute Python scripts.- Specified by:
- getScriptManagerin interface- CommonContext
 
 - 
createDeserializerpublic XMLDeserializer createDeserializer() Description copied from interface:CommonContextReturns an instance of the XMLDeserializer that can be used to deserialize project resources. Note that this is the only safe way to obtain an instance of XMLDeserializer, because the context will pass the new deserializer around to all loaded modules, giving them a chance to initialize any custom deserialization deletes on it first.- Specified by:
- createDeserializerin interface- CommonContext
 
 - 
getExpressionFunctionFactorypublic FunctionFactory getExpressionFunctionFactory() Description copied from interface:CommonContextReturns the core function factory used by expressions. Includes extension functions registered by modules.- Specified by:
- getExpressionFunctionFactoryin interface- CommonContext
 
 - 
getModulepublic java.lang.Object getModule(java.lang.String id) Description copied from interface:CommonContextReturns the hook class for another module, used for modules that deal with each other's models. Example: The reporting plugin's designer hook uses this to get FactoryPMI's palette.- Specified by:
- getModulein interface- CommonContext
 
 - 
getLicenseStatepublic LicenseState getLicenseState(java.lang.String moduleId) Description copied from interface:CommonContextReturns the license state for the given module- Specified by:
- getLicenseStatein interface- CommonContext
 
 - 
getEventBuspublic com.google.common.eventbus.EventBus getEventBus() Description copied from interface:CommonContextThis is a generic event bus that can be used by any part of Ignition within a single scope (jvm)- Specified by:
- getEventBusin interface- CommonContext
 
 - 
createExecutionManagerpublic ExecutionManager createExecutionManager(java.lang.String name, int threadCount) Description copied from interface:ExecutionManagerFactoryCreates a new, private execution engine. Use this if you have tasks that may block waiting for other things to complete, so that you don't clog up the shared execution engine.- Specified by:
- createExecutionManagerin interface- ExecutionManagerFactory
 
 - 
createExecutionManagerpublic ExecutionManager createExecutionManager(java.lang.String name, int threadCount, java.util.concurrent.ThreadFactory factory) - Specified by:
- createExecutionManagerin interface- ExecutionManagerFactory
 
 - 
getTagManagerpublic GatewayTagManager getTagManager() Description copied from interface:CommonContextReturns the manager that provides access to Ignition's tag system.- Specified by:
- getTagManagerin interface- CommonContext
- Specified by:
- getTagManagerin interface- GatewayContext
 
 - 
getSystemManagerpublic SystemManager getSystemManager() - Specified by:
- getSystemManagerin interface- GatewayContext
 
 - 
getWebResourceManagerpublic WebResourceManager getWebResourceManager() - Specified by:
- getWebResourceManagerin interface- GatewayContext
 
 - 
getHttpClientManagerpublic HttpClientManager getHttpClientManager() - Specified by:
- getHttpClientManagerin interface- GatewayContext
- Returns:
- the HttpClientManager
 
 - 
getSecurityLevelManagerpublic SecurityLevelManager getSecurityLevelManager() - Specified by:
- getSecurityLevelManagerin interface- GatewayContext
- Returns:
- the SecurityLevelManager
 
 - 
getIdpAdapterManagerpublic IdpAdapterManager getIdpAdapterManager() - Specified by:
- getIdpAdapterManagerin interface- GatewayContext
- Returns:
- the IdpAdapterManager
 
 - 
getWebAuthStrategyAdapterpublic java.util.Optional<WebAuthStrategyAdapter> getWebAuthStrategyAdapter(@Nonnull java.lang.String type) Description copied from interface:GatewayContextGet theWebAuthStrategyAdapterregistered with the given type- Specified by:
- getWebAuthStrategyAdapterin interface- GatewayContext
- Parameters:
- type- the registered adapter type string
- Returns:
- An Optionalcontaining theWebAuthStrategyAdapterregistered with the given type or an empty Optional if there exists no adapter registered with the given type
 
 - 
getEdgeSystemPropertiespublic EdgeSystemPropertiesRecord getEdgeSystemProperties() Description copied from interface:GatewayContextConvenience function to look up the EdgeSystemPropertiesRecord. Make sure not to call this if you already have a session open, because you can't open 2 sessions in the same thread. Instead, just use:session.find(EdgeSystemPropertiesRecord.META, SQueryMode.SBASIC, 0L); - Specified by:
- getEdgeSystemPropertiesin interface- GatewayContext
 
 - 
getSyncManagerpublic SyncManager getSyncManager() - Specified by:
- getSyncManagerin interface- GatewayContext
- Returns:
- the SyncManagerthat handles syncing data between two systems.
 
 - 
getEdgeEditionspublic java.util.List<EdgeEdition> getEdgeEditions() Description copied from interface:CommonContextReturns a list of currently available Edge editions (either licensed or in trial). Does not check if any required modules are installed and running.- Specified by:
- getEdgeEditionsin interface- CommonContext
 
 - 
getTelemetryManagerpublic TelemetryManager getTelemetryManager() - Specified by:
- getTelemetryManagerin interface- GatewayContext
- Returns:
- the TelemetryManager used to gather statistics about the os, vm, and Ignition configuration.
 
 - 
getMetricsDashboardsManagerpublic MetricsDashboardsManager getMetricsDashboardsManager() - Specified by:
- getMetricsDashboardsManagerin interface- GatewayContext
 
 
- 
 
-