Interface TokenSetter
- All Known Implementing Classes:
TokenSetterImpl
public interface TokenSetter
Defines methods implemented by classes taking care of the 1st step when building configuration - setting the token.
-
Method Summary
Modifier and TypeMethodDescriptionSets the general configuration properties to values read from configuration file.Sets the general configuration properties to values read from configuration file.setAccessToken(String token) Sets the access token used to access feed resources (AMQP broker, Sports API, ...)Sets the access token used to access feed resources (AMQP broker, Sports API, ...) to value read from the application.yml The YAML file should be named "application.properties" and localed in the application resources folderSets the access token used to access feed resources (AMQP broker, Sports API, ...) to value read from the sdk properties The properties file should be named "UFSdkConfiguration.properties" and localed in the application resources folderSets the access token used to access feed resources (AMQP broker, Sports API, ...) to value read from system variable "uf.accesstoken"
-
Method Details
-
setAccessToken
Sets the access token used to access feed resources (AMQP broker, Sports API, ...)- Parameters:
token- the access token used to access feed resources- Returns:
- the
EnvironmentSelectorinstance allowing the selection of target environment
-
setAccessTokenFromSdkProperties
EnvironmentSelector setAccessTokenFromSdkProperties()Sets the access token used to access feed resources (AMQP broker, Sports API, ...) to value read from the sdk properties The properties file should be named "UFSdkConfiguration.properties" and localed in the application resources folder- Returns:
- the
EnvironmentSelectorinstance allowing the selection of target environment
-
setAccessTokenFromApplicationYaml
EnvironmentSelector setAccessTokenFromApplicationYaml()Sets the access token used to access feed resources (AMQP broker, Sports API, ...) to value read from the application.yml The YAML file should be named "application.properties" and localed in the application resources folder- Returns:
- the
EnvironmentSelectorinstance allowing the selection of target environment
-
setAccessTokenFromSystemVar
EnvironmentSelector setAccessTokenFromSystemVar()Sets the access token used to access feed resources (AMQP broker, Sports API, ...) to value read from system variable "uf.accesstoken"You can set the access token with the following JVM argument -Duf.accesstoken=your-access-token
- Returns:
- the
EnvironmentSelectorinstance allowing the selection of target environment
-
buildConfigFromSdkProperties
UofConfiguration buildConfigFromSdkProperties()Sets the general configuration properties to values read from configuration file. Only value which can be set throughConfigurationBuilderBasemethods are set. Any values already set by methods on the current instance are overridden. Builds and returns aUofConfigurationinstance The properties file should be named "UFSdkConfiguration.properties" and localed in the application resources folder- Returns:
- builds and returns a
UofConfigurationinstance
-
buildConfigFromApplicationYml
UofConfiguration buildConfigFromApplicationYml()Sets the general configuration properties to values read from configuration file. Only value which can be set throughConfigurationBuilderBasemethods are set. Any values already set by methods on the current instance are overridden. Builds and returns aUofConfigurationinstance The YAML file should be named "application.yml" and localed in the application resources folder- Returns:
- builds and returns a
UofConfigurationinstance
-