public class ClientRuntime extends Object
This class provides client info that will be sent to the servers as part of each request.
Modifier and Type | Method and Description |
---|---|
String |
getClientInfo()
The SDK client info to send.
|
static ClientRuntime |
getRuntime()
Get the ClientRuntime instance.
|
String |
getUserAgent()
The user agent to send.
|
static void |
setClientUserAgent(String clientUserAgent)
Sets an extra piece of information into the user-agent header passed to the server.
|
public static ClientRuntime getRuntime()
Get the ClientRuntime instance.
public static void setClientUserAgent(String clientUserAgent)
Sets an extra piece of information into the user-agent header passed to the server. The format is (by convention) “Application/Version”, ex “MyApp/1.3.5”.
Note, this must be called BEFORE any service calls are ever made, and once set, cannot be changed after a call has been made.
public String getUserAgent()
The user agent to send.
The agent will include runtime information, ex: Oracle-JavaSDK/1.0.0 (Linux/3.10.0-229.el7.x86_64; Java/1.8.0_60; Java HotSpot(TM) 64-Bit Server VM/25.60-b23)
public String getClientInfo()
The SDK client info to send.
Copyright © 2016–2019. All rights reserved.