JSONConfigurationProvider
open class JSONConfigurationProvider : ConfigurationProviding
Built-in configuration provider that obtains data supplied via application defined user interaction.
-
Default class initializer.
Declaration
Swift
public init()
-
A read-only property. The value for this class is
com.sap.configuration.provider.json
.Declaration
Swift
public var providerIdentifier: String { get }
-
Reports what input(s) are required for operation. The value for this class is a
Dictionary
containing the keyConfigurationProviderInputKeys.JSONstring
and a value for the key. For example, aDictionary
structured as so:var example: [String: Any] = [ConfigurationProviderInputKeys.JSONstring.rawValue : "{"name":"sap.com","messages":["msg 1","msg 2","msg 3"],"age":100}"]
Declaration
Swift
public var expectedInput: [String : Any] { get }
-
Declaration
Swift
public func provideConfiguration(input: [String : Any] = [:]) -> (providerSuccess: Bool, configuration: NSDictionary, returnError: Error?)
Parameters
input
Data supplied by app in response to
expectedInput
dictionary.Return Value
A tuple consisting of
providerSuccess
(success/fail result),configuration
if available, andreturnError
if applicable.