Class DiscoveryServiceConfigurationProvider
-
- All Implemented Interfaces:
-
com.sap.cloud.mobile.foundation.configurationprovider.ConfigurationProvider
public class DiscoveryServiceConfigurationProvider implements ConfigurationProvider
One of the default ConfigurationProviders, it obtains configuration data from the Discovery Service.
Under normal usage, it would not be instantiated directly, but consumed through the Loader.
-
-
Field Summary
Fields Modifier and Type Field Description public final static String
EMAIL_ADDRESS
-
Constructor Summary
Constructors Constructor Description DiscoveryServiceConfigurationProvider(Context context)
Retrieves configuration data from the Discovery Service. DiscoveryServiceConfigurationProvider(String applicationId)
Retrieves configuration data from the Discovery Service using the supplied ApplicationID
-
Method Summary
Modifier and Type Method Description ProviderIdentifier
getProviderIdentifier()
Retrieve the ProviderIdentifier for this Provider. ProviderInputs
getExpectedInput()
Reports what input(s) are required for operation. ProviderConfiguration
provideConfiguration(@NonNull() ProviderInputs input)
Used by the loader, normally not used directly. -
-
Constructor Detail
-
DiscoveryServiceConfigurationProvider
DiscoveryServiceConfigurationProvider(Context context)
Retrieves configuration data from the Discovery Service.- Parameters:
context
- A context, providing access to the applicationID.
-
DiscoveryServiceConfigurationProvider
DiscoveryServiceConfigurationProvider(String applicationId)
Retrieves configuration data from the Discovery Service using the supplied ApplicationID- Parameters:
applicationId
- The app identifier to use for web requests to the Discovery Service.
-
-
Method Detail
-
getProviderIdentifier
@NonNull() ProviderIdentifier getProviderIdentifier()
Retrieve the ProviderIdentifier for this Provider.
-
getExpectedInput
@NonNull() ProviderInputs getExpectedInput()
Reports what input(s) are required for operation. The value for this class is ProviderInputs containing the key "email_address" and the value for the key.
- Returns:
-
provideConfiguration
@NonNull() ProviderConfiguration provideConfiguration(@NonNull() ProviderInputs input)
Used by the loader, normally not used directly.
- Parameters:
input
- data supplied by app in response to getExpectedInput
-
-
-
-