Class ClientConfigurationImpl
java.lang.Object
fr.gouv.vitam.common.external.client.configuration.ClientConfigurationImpl
- All Implemented Interfaces:
ClientConfiguration
- Direct Known Subclasses:
SecureClientConfigurationImpl
ClientConfiguration interface's implementation
-
Constructor Summary
ConstructorDescriptionEmpty ClientConfiguration constructor for YAMLFactoryClientConfigurationImpl
(String serverHost, int serverPort) ClientConfiguration constructor -
Method Summary
Modifier and TypeMethodDescriptionMust return the value of a 'serverHost' attributeint
Must return the value of a 'serverPort' attributeboolean
isSecure()
Must return the value of a 'secure' attributesetServerHost
(String serverHost) setServerPort
(int serverPort)
-
Constructor Details
-
ClientConfigurationImpl
public ClientConfigurationImpl()Empty ClientConfiguration constructor for YAMLFactory -
ClientConfigurationImpl
ClientConfiguration constructor- Parameters:
serverHost
- server IP addressserverPort
- server port- Throws:
IllegalArgumentException
- if serverHost is null or empty or serverPort <= 0
-
-
Method Details
-
getServerHost
Description copied from interface:ClientConfiguration
Must return the value of a 'serverHost' attribute- Specified by:
getServerHost
in interfaceClientConfiguration
- Returns:
- the server host value
-
getServerPort
public int getServerPort()Description copied from interface:ClientConfiguration
Must return the value of a 'serverPort' attribute- Specified by:
getServerPort
in interfaceClientConfiguration
- Returns:
- the server port value
-
setServerHost
- Specified by:
setServerHost
in interfaceClientConfiguration
- Parameters:
serverHost
- the server host- Returns:
- this
-
setServerPort
- Specified by:
setServerPort
in interfaceClientConfiguration
- Parameters:
serverPort
- the server port- Returns:
- this
-
isSecure
public boolean isSecure()Description copied from interface:ClientConfiguration
Must return the value of a 'secure' attribute- Specified by:
isSecure
in interfaceClientConfiguration
- Returns:
- secure = false : HTTP, secure = true : HTTPS
-