Class GatewayInterface
java.lang.Object
com.inductiveautomation.ignition.client.gateway_interface.GatewayInterface
- All Implemented Interfaces:
GatewayConstants
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from interface com.inductiveautomation.ignition.common.gateway.GatewayConstants
GatewayConstants.ClientAuthChallengeDeserializer
-
Field Summary
Fields inherited from interface com.inductiveautomation.ignition.common.gateway.GatewayConstants
BUILD_NUMBER, CONNECT_TIMEOUT, ERRNO_BROWSE_ERROR, ERRNO_COMM_ERROR, ERRNO_CONNECTION_MODE, ERRNO_DBCONNECTION_SQL, ERRNO_INTERNAL, ERRNO_INVALIDARGS, ERRNO_INVOCATION_EXCEPTION, ERRNO_LICENSE_RESTRICTED, ERRNO_LOGIN_CANCELLED, ERRNO_LOGIN_FAILED, ERRNO_LOGIN_FAILED_LICENSING, ERRNO_NO_SESSION, ERRNO_NON_ACTIVE_NODE, ERRNO_NON_MASTER_NODE, ERRNO_NOT_AUTHORIZED, ERRNO_OK, ERRNO_PARSE, ERRNO_PASSWORD_EXPIRED, ERRNO_SQL, ERRNO_TRIAL_EXPIRED, ERRNO_VERSION_INCOMPATIBILITY, ERROR_MESSAGE_TYPE, FUNCTION_NAME, GSON, LOCALE_LIST, MODE_DISCONNECTED, MODE_FULL, MODE_READ_ONLY, MODULE_ID, MTYPE_PUBLIC_PING, OPC_BROWSE_TIMEOUT, PACKAGE_ID, PROJECT_NAME, REMOTE_HOST, SCOPE_HEADER, SESSION_ID_HEADER, SOCKET_TIMEOUT, TIMEZONE_ID, WARNING_MESSAGE_TYPE
-
Constructor Summary
ConstructorsConstructorDescriptionGatewayInterface
(org.eclipse.jetty.client.HttpClient httpClient, ScopeVersionHash version, HttpURL gatewayUrl, int connectTimeout, int socketTimeout, int concurrencyLevel, int opcBrowseTimeout) -
Method Summary
Modifier and TypeMethodDescriptionorg.eclipse.jetty.http.HttpCookieStore
<T> T
invoke
(ClientRpcSerializer serializer, RpcCall call, int timeoutMillis, @NotNull Object... parameters) invokeRaw
(RpcCall call, int timeoutMillis, FragileConsumer<OutputStream, IOException> parameterWriter) boolean
isSSL()
Logs in to the gateway.void
org.eclipse.jetty.client.Request
newHttpRequest
(org.eclipse.jetty.http.HttpMethod method, String... pathComponents) Create a new HTTP request against the gateway with the given method and path parameters, appended to this gateway interface's known base URL and protocol.void
reportError
(String message, String details, String sysProps, String userDescription, String userName, String userContact) void
setConnectTimeout
(int connectTimeout) void
setHttpConcurrency
(int concurrencyLevel) void
setOpcBrowseTimeout
(int opcBrowseTimeout) void
setSocketTimeout
(int socketTimeout) void
setSSL
(boolean ssl) void
void
simulateDisconnect
(int seconds)
-
Constructor Details
-
GatewayInterface
public GatewayInterface(org.eclipse.jetty.client.HttpClient httpClient, ScopeVersionHash version, HttpURL gatewayUrl, int connectTimeout, int socketTimeout, int concurrencyLevel, int opcBrowseTimeout)
-
-
Method Details
-
getCookieStore
public org.eclipse.jetty.http.HttpCookieStore getCookieStore() -
newHttpRequest
public org.eclipse.jetty.client.Request newHttpRequest(org.eclipse.jetty.http.HttpMethod method, String... pathComponents) Create a new HTTP request against the gateway with the given method and path parameters, appended to this gateway interface's known base URL and protocol. The request will automatically include session ID and scope headers.- Parameters:
pathComponents
- path components to append to the base URL - will be joined automatically with slashes
-
handshake
-
login
public LoginResult login(Consumer<org.eclipse.jetty.client.Request> requestConsumer, String... pathComponents) throws GatewayException Logs in to the gateway. As a side effect, updates the cookie for this connection based on the result.- Throws:
GatewayException
-
idpStart
- Throws:
GatewayException
-
setThroughputMonitor
-
getGatewayAddress
-
isSSL
public boolean isSSL() -
setSSL
public void setSSL(boolean ssl) -
simulateDisconnect
public void simulateDisconnect(int seconds) -
invoke
public <T> T invoke(ClientRpcSerializer serializer, RpcCall call, int timeoutMillis, @NotNull @NotNull Object... parameters) throws Exception - Throws:
Exception
-
invokeRaw
public InputStream invokeRaw(RpcCall call, int timeoutMillis, FragileConsumer<OutputStream, IOException> parameterWriter) throws Exception- Throws:
Exception
-
getCookie
-
getModules
- Throws:
GatewayException
-
logout
-
reportError
public void reportError(String message, String details, String sysProps, String userDescription, String userName, String userContact) throws Exception - Throws:
Exception
-
setConnectTimeout
public void setConnectTimeout(int connectTimeout) -
setSocketTimeout
public void setSocketTimeout(int socketTimeout) -
setOpcBrowseTimeout
public void setOpcBrowseTimeout(int opcBrowseTimeout) -
setHttpConcurrency
public void setHttpConcurrency(int concurrencyLevel)
-