com.jscape.util.keystore

## Class KeyPairMap

- java.lang.Object
- - com.jscape.util.keystore.KeyPairMap

-     public class KeyPairMap
      extends java.lang.Object

  Maps key pairs (private and public keys) to aliases.

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `KeyPairMap()`
    `KeyPairMap(KeyPairMap that)`
    `KeyPairMap(java.util.Map<java.lang.String,KeyPairRecord> entries)`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `clear()` Clears all key pair aliases.
    `boolean` | `contains(java.lang.String alias)` Checks if key pair for given alias exists.
    `KeyPairRecord` | `get(java.lang.String alias)` Gets key pair for given alias.
    `java.lang.String[]` | `getAliases()` Gets aliases for all key pairs.
    `java.lang.String[]` | `getAliases(java.lang.String algorithm)` Gets all aliases for key pairs using defined algorithm.
    `java.util.Map<java.lang.String,KeyPairRecord>` | `getEntries()`
    `void` | `remove(java.lang.String alias)` Removes key pair for given alias.
    `void` | `set(java.lang.String alias, KeyPairRecord entry)` Sets key pair for given alias.
    `void` | `setEntries(java.util.Map<java.lang.String,KeyPairRecord> value)`
    `int` | `size()`
    `java.lang.String` | `toString()`

    - ### Methods inherited from class java.lang.Object

      `equals, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- - ### Constructor Detail

    - #### KeyPairMap

          public KeyPairMap(java.util.Map<java.lang.String,KeyPairRecord> entries)

    - #### KeyPairMap

          public KeyPairMap(KeyPairMap that)

    - #### KeyPairMap

          public KeyPairMap()

  - ### Method Detail

    - #### getEntries

          public java.util.Map<java.lang.String,KeyPairRecord> getEntries()

    - #### setEntries

          public void setEntries(java.util.Map<java.lang.String,KeyPairRecord> value)

    - #### getAliases

          public java.lang.String[] getAliases()

      Gets aliases for all key pairs.
      Returns:
        all aliases in map

    - #### getAliases

          public java.lang.String[] getAliases(java.lang.String algorithm)

      Gets all aliases for key pairs using defined algorithm.
      Parameters:
        `algorithm` - key pair algorithm
      Returns:
        found aliases

    - #### contains

          public boolean contains(java.lang.String alias)

      Checks if key pair for given alias exists.
      Parameters:
        `alias` - a key pair alias
      Returns:
        `true` if key pair exists; `false` otherwise

    - #### get

          public KeyPairRecord get(java.lang.String alias)

      Gets key pair for given alias.
      Parameters:
        `alias` - key pair alias
      Returns:
        key pair record

    - #### set

          public void set(java.lang.String alias,
                          KeyPairRecord entry)

      Sets key pair for given alias.
      Parameters:
        `alias` - key pair record alias
        `entry` - associated key pair record

    - #### remove

          public void remove(java.lang.String alias)

      Removes key pair for given alias.
      Parameters:
        `alias` - key pai record alias

    - #### clear

          public void clear()

      Clears all key pair aliases.

    - #### size

          public int size()

    - #### toString

          public java.lang.String toString()

      Overrides:
        `toString` in class `java.lang.Object`

Copyright © JSCAPE LLC. 1999-2018. All Rights Reserved