Added in [API level 26](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels) Summary: [Ctors](https://developer.android.com/reference/java/security/DomainLoadStoreParameter#pubctors) \| [Methods](https://developer.android.com/reference/java/security/DomainLoadStoreParameter#pubmethods) \| [Inherited Methods](https://developer.android.com/reference/java/security/DomainLoadStoreParameter#inhmethods)

# DomainLoadStoreParameter


`
public

final

class
DomainLoadStoreParameter
`


`

extends https://developer.android.com/reference/java/lang/Object


`

`


implements

https://developer.android.com/reference/java/security/KeyStore.LoadStoreParameter


`

|---|---|
| [java.lang.Object](https://developer.android.com/reference/java/lang/Object) ||
| ↳ | java.security.DomainLoadStoreParameter |

<br />

*** ** * ** ***

Configuration data that specifies the keystores in a keystore domain.
A keystore domain is a collection of keystores that are presented as a
single logical keystore. The configuration data is used during
`KeyStore`
`https://developer.android.com/reference/java/security/KeyStore#load(java.security.KeyStore.LoadStoreParameter)` and
`https://developer.android.com/reference/java/security/KeyStore#store(java.security.KeyStore.LoadStoreParameter)` operations.


The following syntax is supported for configuration data:

    domain <domainName> [<property> ...] {
            keystore <keystoreName> [<property> ...] ;
            ...
        };
        ...

where `domainName` and `keystoreName` are identifiers and `property` is a key/value pairing. The key and value are separated by an 'equals' symbol and the value is enclosed in double quotes. A property value may be either a printable string or a binary string of colon-separated pairs of hexadecimal digits. Multi-valued properties are represented as a comma-separated list of values, enclosed in square brackets. See `https://developer.android.com/reference/java/util/Arrays#toString(java.lang.Object[])`.


To ensure that keystore entries are uniquely identified, each
entry's alias is prefixed by its `keystoreName` followed
by the entry name separator and each `keystoreName` must be
unique within its domain. Entry name prefixes are omitted when
storing a keystore.


Properties are context-sensitive: properties that apply to
all the keystores in a domain are located in the domain clause,
and properties that apply only to a specific keystore are located
in that keystore's clause.
Unless otherwise specified, a property in a keystore clause overrides
a property of the same name in the domain clause. All property names
are case-insensitive. The following properties are supported:

`keystoreType="<type>"`
:   The keystore type.

`keystoreURI="<url>"`
:   The keystore location.

`keystoreProviderName="<name>"`
:   The name of the keystore's JCE provider.

`keystorePasswordEnv="<environment-variable>"`
:   The environment variable that stores a keystore password.
    Alternatively, passwords may be supplied to the constructor
    method in a `Map<String, ProtectionParameter>`.

`entryNameSeparator="<separator>"`
:   The separator between a keystore name prefix and an entry name.
    When specified, it applies to all the entries in a domain.
    Its default value is a space.


For example, configuration data for a simple keystore domain
comprising three keystores is shown below:

```
domain app1 {
    keystore app1-truststore
        keystoreURI="file:///app1/etc/truststore.jks";

    keystore system-truststore
        keystoreURI="${java.home}/lib/security/cacerts";

    keystore app1-keystore
        keystoreType="PKCS12"
        keystoreURI="file:///app1/etc/keystore.p12";
};

```

<br />

## Summary

| ### Public constructors ||
|---|---|
| ` https://developer.android.com/reference/java/security/DomainLoadStoreParameter#DomainLoadStoreParameter(java.net.URI,%20java.util.Map<java.lang.String,java.security.KeyStore.ProtectionParameter>)(https://developer.android.com/reference/java/net/URI configuration, https://developer.android.com/reference/java/util/Map<https://developer.android.com/reference/java/lang/String, https://developer.android.com/reference/java/security/KeyStore.ProtectionParameter> protectionParams) ` Constructs a DomainLoadStoreParameter for a keystore domain with the parameters used to protect keystore data. |

| ### Public methods ||
|---|---|
| ` https://developer.android.com/reference/java/net/URI` | ` https://developer.android.com/reference/java/security/DomainLoadStoreParameter#getConfiguration()() ` Gets the identifier for the domain configuration data. |
| ` https://developer.android.com/reference/java/security/KeyStore.ProtectionParameter` | ` https://developer.android.com/reference/java/security/DomainLoadStoreParameter#getProtectionParameter()() ` Gets the keystore protection parameters for this domain. |
| ` https://developer.android.com/reference/java/util/Map<https://developer.android.com/reference/java/lang/String, https://developer.android.com/reference/java/security/KeyStore.ProtectionParameter>` | ` https://developer.android.com/reference/java/security/DomainLoadStoreParameter#getProtectionParams()() ` Gets the keystore protection parameters for keystores in this domain. |

| ### Inherited methods |
|---|---|
| From class ` https://developer.android.com/reference/java/lang/Object ` |---|---| | ` https://developer.android.com/reference/java/lang/Object` | ` https://developer.android.com/reference/java/lang/Object#clone()() ` Creates and returns a copy of this object. | | ` boolean` | ` https://developer.android.com/reference/java/lang/Object#equals(java.lang.Object)(https://developer.android.com/reference/java/lang/Object obj) ` Indicates whether some other object is "equal to" this one. | | ` void` | ` https://developer.android.com/reference/java/lang/Object#finalize()() ` Called by the garbage collector on an object when garbage collection determines that there are no more references to the object. | | ` final https://developer.android.com/reference/java/lang/Class<?>` | ` https://developer.android.com/reference/java/lang/Object#getClass()() ` Returns the runtime class of this `Object`. | | ` int` | ` https://developer.android.com/reference/java/lang/Object#hashCode()() ` Returns a hash code value for the object. | | ` final void` | ` https://developer.android.com/reference/java/lang/Object#notify()() ` Wakes up a single thread that is waiting on this object's monitor. | | ` final void` | ` https://developer.android.com/reference/java/lang/Object#notifyAll()() ` Wakes up all threads that are waiting on this object's monitor. | | ` https://developer.android.com/reference/java/lang/String` | ` https://developer.android.com/reference/java/lang/Object#toString()() ` Returns a string representation of the object. | | ` final void` | ` https://developer.android.com/reference/java/lang/Object#wait(long,%20int)(long timeoutMillis, int nanos) ` Causes the current thread to wait until it is awakened, typically by being *notified* or *interrupted*, or until a certain amount of real time has elapsed. | | ` final void` | ` https://developer.android.com/reference/java/lang/Object#wait(long)(long timeoutMillis) ` Causes the current thread to wait until it is awakened, typically by being *notified* or *interrupted*, or until a certain amount of real time has elapsed. | | ` final void` | ` https://developer.android.com/reference/java/lang/Object#wait()() ` Causes the current thread to wait until it is awakened, typically by being *notified* or *interrupted*. | ||
| From interface ` https://developer.android.com/reference/java/security/KeyStore.LoadStoreParameter ` |---|---| | ` abstract https://developer.android.com/reference/java/security/KeyStore.ProtectionParameter` | ` https://developer.android.com/reference/java/security/KeyStore.LoadStoreParameter#getProtectionParameter()() ` Gets the parameter used to protect keystore data. | ||

## Public constructors

### DomainLoadStoreParameter

Added in [API level 26](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public DomainLoadStoreParameter (URI configuration, 
                Map<String, KeyStore.ProtectionParameter> protectionParams)
```

Constructs a DomainLoadStoreParameter for a keystore domain with
the parameters used to protect keystore data.

<br />

| Parameters ||
|---|---|
| `configuration` | `URI`: identifier for the domain configuration data. The name of the target domain should be specified in the `java.net.URI` fragment component when it is necessary to distinguish between several domain configurations at the same location. <br /> |
| `protectionParams` | `Map`: the map from keystore name to the parameter used to protect keystore data. A `java.util.Collections.EMPTY_MAP` should be used when protection parameters are not required or when they have been specified by properties in the domain configuration data. It is cloned to prevent subsequent modification. <br /> |

| Throws ||
|---|---|
| `https://developer.android.com/reference/java/lang/NullPointerException` | if `configuration` or `protectionParams` is `null` |

## Public methods

### getConfiguration

Added in [API level 26](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public URI getConfiguration ()
```

Gets the identifier for the domain configuration data.

<br />

| Returns ||
|---|---|
| `https://developer.android.com/reference/java/net/URI` | the identifier for the configuration data <br /> |

### getProtectionParameter

Added in [API level 26](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public KeyStore.ProtectionParameter getProtectionParameter ()
```

Gets the keystore protection parameters for this domain.
Keystore domains do not support a protection parameter.

<br />

| Returns ||
|---|---|
| `https://developer.android.com/reference/java/security/KeyStore.ProtectionParameter` | always returns `null` <br /> |

### getProtectionParams

Added in [API level 26](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public Map<String, KeyStore.ProtectionParameter> getProtectionParams ()
```

Gets the keystore protection parameters for keystores in this
domain.

<br />

| Returns ||
|---|---|
| `https://developer.android.com/reference/java/util/Map<https://developer.android.com/reference/java/lang/String, https://developer.android.com/reference/java/security/KeyStore.ProtectionParameter>` | an unmodifiable map of keystore names to protection parameters <br /> |