Class ClientGatewayConnection
- java.lang.Object
-
- com.inductiveautomation.ignition.client.gateway_interface.AbstractGatewayConnection
-
- com.inductiveautomation.factorypmi.application.runtime.ClientGatewayConnection
-
- All Implemented Interfaces:
GatewayConnection
,GatewayInterface.GatewayExceptionMonitor
,PushNotificationListener
,GatewayConstants
,java.util.EventListener
public class ClientGatewayConnection extends AbstractGatewayConnection
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.inductiveautomation.ignition.client.gateway_interface.AbstractGatewayConnection
AbstractGatewayConnection.UnrecoverableIdpAuthSessionException
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
ORIGINATING_LICENSE_ATTRIBUTE_KEY
-
Fields inherited from class com.inductiveautomation.ignition.client.gateway_interface.AbstractGatewayConnection
changeSupport, CONNECT_FAIL, CONNECT_SUCCESS, CONNECT_UNKNOWN, CONNECTING, connectTimeout, currentAddress, gatewayAddresses, gatewayNodeRole, gatewayTimeZone, GET_ADDRESSES_ERROR, hash, httpConcurrency, INDEPENDENT, launchContext, listenerList, log, LOGGER_STATUS_LOOKUP, NEW_ADDRESSES, NO_NEW_ADDRESSES, NON_ACTIVE, opcBrowseTimeout, REDUNDANT_BACKUP, REDUNDANT_MASTER, RELOGIN, socketTimeout, STATUS_CONNECT_FAIL, STATUS_CONNECT_INACTIVE, STATUS_CONNECT_UNKNOWN, STATUS_CONNECT_WARNING, STATUS_CONNECTED, STATUS_CONNECTED_INCOMPATIBLE, STATUS_CONNECTING
-
Fields inherited from interface com.inductiveautomation.ignition.common.gateway.GatewayConstants
_DATE_FORMATTER, ARG_MESSAGETYPE, ARG_MODULEID, ATR_INDEX, ATR_LENGTH, ATR_NAME, ATR_TYPE, booleanNull, byteNull, charNull, DATE_FORMAT_STRING, doubleNull, ELM_ARG, ELM_COLLIST, ELM_COLUMN, ELM_COMPRESSEDROWS, ELM_DATA, ELM_ERRORCODE, ELM_ERRORMESSAGE, ELM_EXCLS, ELM_EXMSG, ELM_EXOVERRIDES_TOSTRING, ELM_EXSTRING, ELM_MBODY, ELM_MESSAGE, ELM_MTYPE, ELM_NOTIFICATION, ELM_NOTIFICATIONS, ELM_RESPONSE, ELM_ROW, ELM_ROWS, ELM_SERIALIZED_RESPONSE, ELM_SETCOOKIE, ELM_STACKTRACE, ELM_STELM, ELM_STELM_DECL, ELM_STELM_FILE, ELM_STELM_LINE, ELM_STELM_METH, ERRNO_ASYNC_CALL, ERRNO_ASYNC_CALL_CANCELED, ERRNO_ASYNC_CALL_FAILED, ERRNO_BROWSE_ERROR, ERRNO_COMM_ERROR, ERRNO_CONNECTION_MODE, ERRNO_DBCONNECTION_NAMING, ERRNO_DBCONNECTION_SQL, ERRNO_HISTORY_QUERY_ERROR, ERRNO_INTERNAL, ERRNO_INVALIDARGS, ERRNO_INVOCATION_EXCEPTION, ERRNO_LICENE_RESTRICTED, ERRNO_LOGIN_FAILED, ERRNO_LOGIN_FAILED_LICENSING, ERRNO_NAMING, ERRNO_NO_SESSION, ERRNO_NON_ACTIVE_NODE, ERRNO_NON_MASTER_NODE, ERRNO_NOT_AUTHORIZED, ERRNO_NOTIMP, ERRNO_OK, ERRNO_PARSE, ERRNO_PASSWORD_EXPIRED, ERRNO_PONG, ERRNO_POST_ERROR, ERRNO_PROJECT_PULL, ERRNO_PROJECT_PUSH, ERRNO_RUNTIME_EXPIRED, ERRNO_SQL, ERRNO_SQLTAGS_PROVIDER_DISABLED, ERRNO_SQLTAGS_PROVIDER_FAULTED, ERRNO_SQLTAGS_PROVIDER_LOADING, ERRNO_SQLTAGS_PROVIDER_MISSING, ERRNO_SQLTAGS_SEND_TAGS, ERRNO_SSL_REQUIRED, ERRNO_TIMEOUT, ERRNO_TRIAL_EXPIRED, ERRNO_VERSION_INCOMPATABILITY, ERROR_MESSAGE_TYPE, floatNull, intNull, longNull, MODE_DISCONNECTED, MODE_FULL, MODE_READ_ONLY, MTYPE_COPY_IMAGE, MTYPE_CREATE_IMAGE_FOLDER, MTYPE_DBTEST, MTYPE_GET_NEW_RESOURCEID, MTYPE_INVALID, MTYPE_INVOKE_FUNCTION, MTYPE_LIST_AUTHS, MTYPE_LIST_COLS, MTYPE_LIST_DBS, MTYPE_LIST_IDPS, MTYPE_LIST_IMAGES, MTYPE_LIST_MODULES, MTYPE_LIST_ROLES, MTYPE_LIST_SECURITY_LEVELS, MTYPE_LIST_SQLTAG_PROVIDERS, MTYPE_LIST_TABLES, MTYPE_LIST_ZONES, MTYPE_PING, MTYPE_PLATFORM_EDITION, MTYPE_PUBLIC_PING, MTYPE_REMOVE_IMAGE, MTYPE_RENAME_IMAGE_FOLDER, MTYPE_REPORT_ERROR, MTYPE_SEND_EMAIL, MTYPE_SQLTAGS_ADD_SCANCLASS, MTYPE_SQLTAGS_ADD_TAGS, MTYPE_SQLTAGS_EDIT_SCANCLASS, MTYPE_SQLTAGS_EDIT_TAGS, MTYPE_SQLTAGS_ERROR_LIST, MTYPE_SQLTAGS_FSQL_BROWSE, MTYPE_SQLTAGS_FSQL_LIST, MTYPE_SQLTAGS_GET_SCANCLASS, MTYPE_SQLTAGS_LIST, MTYPE_SQLTAGS_META_LIST, MTYPE_SQLTAGS_POLL, MTYPE_SQLTAGS_REMOVE_SCANCLASS, MTYPE_SQLTAGS_REMOVE_TAGS, MTYPE_SQLTAGS_WRITE, MTYPE_STATUS_POLL, MTYPE_UPLOAD_IMAGE, MTYPE_VERSION_CHECK, PROTECT_DIALOG_TYPE, shortNull, WARNING_MESSAGE_TYPE
-
-
Constructor Summary
Constructors Constructor Description ClientGatewayConnection(LaunchContext launchContext)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description AuthenticatedUser
doIdpLoginFinish(java.lang.String projectName)
protected AuthenticatedUser
doLogin(GatewayInterface gatewayInterface, java.lang.String projectName, AuthChallenge challenge)
protected int
getScope()
Returns the scope for this connection.java.net.URI
idpLoginStart(java.lang.String projectName)
protected void
onUnrecoverableIdpAuthSession()
protected void
onVersionMismatch()
Called when the version is detected to have changed on the gateway.void
setClientPanel(ClientPanel clientPanel)
protected boolean
tryToLogin()
void
updateGatewayMetaInfo()
Updates the gateway timezone and role info-
Methods inherited from class com.inductiveautomation.ignition.client.gateway_interface.AbstractGatewayConnection
addConnectionListener, addConnectionStatusListener, addPropertyChangeListener, addPropertyChangeListener, addPushNotificationListener, connect, disconnect, fireConnectionEvent, fireConnectionEvent, fireConnectionEvent, firePushNotification, fishForAliveServer, getAllAddresses, getAuthChallenge, getConnectionMode, getConnectTimeout, getEdgeProjectName, getGatewayAddress, getGatewayInterface, getGatewayNodeRole, getGatewayTimeZone, getGatewayWebURL, getHttpConcurrency, getOpcBrowseTimeout, getPlatformEdition, getProjectName, getRoles, getScheme, getSecurityZones, getSocketTimeout, getUsername, idpLoginFinish, isConnected, isConnectionRelated, isConnectionUp, isLoggedIn, isSessionValid, login, logout, newGatewayInterface, notifyGatewayException, receiveNotification, removeConnectionListener, removeConnectionStatusListener, removePropertyChangeListener, removePropertyChangeListener, removePushNotificationListener, removePushNotificationListeners, setConnected, setConnectionMode, setConnectionUp, setConnectTimeout, setGatewayInterface, setHttpConcurrency, setIndependentAddressList, setOpcBrowseTimeout, setProjectName, setSocketTimeout, toString, triggerConnectionStatusListeners, updateBackupAddresses, updateMasterAddresses
-
-
-
-
Field Detail
-
ORIGINATING_LICENSE_ATTRIBUTE_KEY
public static final java.lang.String ORIGINATING_LICENSE_ATTRIBUTE_KEY
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
ClientGatewayConnection
public ClientGatewayConnection(LaunchContext launchContext)
-
-
Method Detail
-
getScope
protected int getScope()
Description copied from class:AbstractGatewayConnection
Returns the scope for this connection. Used to create an accurate version hash.- Specified by:
getScope
in classAbstractGatewayConnection
-
doLogin
protected AuthenticatedUser doLogin(GatewayInterface gatewayInterface, java.lang.String projectName, AuthChallenge challenge) throws GatewayException
- Specified by:
doLogin
in classAbstractGatewayConnection
- Throws:
GatewayException
-
updateGatewayMetaInfo
public void updateGatewayMetaInfo()
Description copied from class:AbstractGatewayConnection
Updates the gateway timezone and role info- Overrides:
updateGatewayMetaInfo
in classAbstractGatewayConnection
-
tryToLogin
protected boolean tryToLogin() throws AbstractGatewayConnection.UnrecoverableIdpAuthSessionException
- Overrides:
tryToLogin
in classAbstractGatewayConnection
- Throws:
AbstractGatewayConnection.UnrecoverableIdpAuthSessionException
-
onVersionMismatch
protected void onVersionMismatch()
Description copied from class:AbstractGatewayConnection
Called when the version is detected to have changed on the gateway. Connection will be closed at this point.- Specified by:
onVersionMismatch
in classAbstractGatewayConnection
-
onUnrecoverableIdpAuthSession
protected void onUnrecoverableIdpAuthSession()
- Specified by:
onUnrecoverableIdpAuthSession
in classAbstractGatewayConnection
-
setClientPanel
public void setClientPanel(ClientPanel clientPanel)
-
idpLoginStart
@Nullable public java.net.URI idpLoginStart(java.lang.String projectName) throws GatewayException
- Throws:
GatewayException
-
doIdpLoginFinish
public AuthenticatedUser doIdpLoginFinish(java.lang.String projectName) throws GatewayException
- Specified by:
doIdpLoginFinish
in classAbstractGatewayConnection
- Throws:
GatewayException
-
-