Package com.thingworx.common.utils
Class HttpUtilities
java.lang.Object
com.thingworx.common.utils.HttpUtilities
@ThingworxExtensionApiClass(since={6,6},
canInstantiate=true)
public final class HttpUtilities
extends Object
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic org.apache.http.impl.client.CloseableHttpClient
createHttpClient
(String username, byte[] password, Boolean ignoreSSLErrors, Double timeout, Boolean useNTLM, String workstation, String domain, Boolean useProxy, String proxyHost, Integer proxyPort, String proxyScheme) static org.apache.http.impl.client.CloseableHttpClient
createHttpClient
(String username, String password, Boolean ignoreSSLErrors, Double timeout, Boolean useNTLM, String workstation, String domain, Boolean useProxy, String proxyHost, Integer proxyPort, String proxyScheme) Deprecated.static void
validateDomainWithoutProtocol
(String domain)
Validate the domain name against the white list of domains, if the validation is enabled.
-
Field Details
-
RESPONSE_STATUS
- See Also:
-
RESPONSE_HEADERS
- See Also:
-
REASON_PHRASE
- See Also:
-
STATUS_CODE
- See Also:
-
PROTOCOL_VERSION
- See Also:
-
TRUSTED_DOMAINS
-
ignoreTrustedDomains
public static boolean ignoreTrustedDomains
-
-
Constructor Details
-
HttpUtilities
public HttpUtilities()
-
-
Method Details
-
createHttpClient
@Deprecated @ThingworxExtensionApiMethod(since={6,6}, deprecatedSince={8,4}) public static org.apache.http.impl.client.CloseableHttpClient createHttpClient(String username, String password, Boolean ignoreSSLErrors, Double timeout, Boolean useNTLM, String workstation, String domain, Boolean useProxy, String proxyHost, Integer proxyPort, String proxyScheme) Deprecated. -
createHttpClient
@ThingworxExtensionApiMethod(since={8,4}) public static org.apache.http.impl.client.CloseableHttpClient createHttpClient(String username, byte[] password, Boolean ignoreSSLErrors, Double timeout, Boolean useNTLM, String workstation, String domain, Boolean useProxy, String proxyHost, Integer proxyPort, String proxyScheme) -
validateDomainWithoutProtocol
@ThingworxExtensionApiMethod(since={9,3}) public static void validateDomainWithoutProtocol(String domain) throws IllegalAccessException
Validate the domain name against the white list of domains, if the validation is enabled.- Parameters:
domain
- - Domain name to validate- Throws:
IllegalAccessException
-