SHOW Signed

net.rim.device.api.crypto.keystore
Class CombinedKeyStore

java.lang.Object
  |
  +--net.rim.device.api.crypto.keystore.CombinedKeyStore
All Implemented Interfaces:
Collection, CollectionEventSource, KeyStore

public class CombinedKeyStore
extends Object
implements KeyStore

This class allows a developer to combine several keystores into what looks like one keystore.

This is useful when you have several keystores that might contain the key you are looking for. You can combine these keystores temporarily and search through them.

Note: It should be noted that some operations do not make sense to operate on a collection of keystores. For example, the set method would add a new key to a keystore. It does not make sense to add the new key automatically to all of the keystores. So, the concept of a preferred keystore exists to enable those kinds of operations to be performed on one of the keystores. Any operation that only operates on a preferred key store is denoted as such. Ensure that you check the javadocs for each function you are calling so you know exactly what operations are being performed.

For sample code on how to use a key store see: here

Category:
Signed: This element is only accessible by signed clients. If you intend to use this element, please contact RIM to establish the necessary agreements that will allow you to have your COD files signed. Signing is only required for use on the device, development under the JDE can occur without signing the CODs.

Since:
JDE 3.6.0

Fields inherited from interface net.rim.device.api.crypto.keystore.KeyStore
SECURITY_LEVEL_HIGH, SECURITY_LEVEL_LOW, SECURITY_LEVEL_MEDIUM, SECURITY_LEVEL_NOT_APPLICABLE
 
Constructor Summary
 Category: Signed CombinedKeyStore(KeyStore[] keyStores)
          Initializes the combined keystore with an array of underlying keystores.
 Category: Signed CombinedKeyStore(KeyStore[] keyStores, int preferredKeyStore)
          Initializes the combined keystore with an array of underlying keystores.
 
Method Summary
 Category: Signed  void addCollectionListener(Object listener)
          This method is called when the developer wants to listen in on when records are added and removed to/from a particular keystore.
 Category: Signed  boolean addIndex(KeyStoreIndex index)
          Adds an index to all of the information currently in the key store.
 Category: Signed  void addIndices(KeyStoreIndex[] indices)
          Adds an array of indices to all of the information currently in the key store.
 Category: Signed  void addKeyStores(KeyStore[] keyStores)
          Allows for the addition of more keystores to the combined key store.
 Category: Signed  void changePreferredKeyStore(int newPreferredKeyStore)
          Allows you to change the preferred key store.
 Category: Signed  boolean checkTicket(KeyStoreTicket ticket)
          Calls the checkTicket method on the preferred key store.
 Category: Signed  Enumeration elements()
          Returns an enumeration of the KeyStoreData that are stored in the KeyStore.
 Category: Signed  Enumeration elements(boolean backingKeyStore)
          Returns an enumeration of the KeyStoreData that are stored in the KeyStore.
 Category: Signed  Enumeration elements(long index)
          Returns an enumeration of the elements (KeyStoreData) inside the key store according to the index provided with the parameter.
 Category: Signed  Enumeration elements(long index, boolean backingKeyStore)
          Returns an enumeration of the elements (KeyStoreData) inside the key store according to the index provided with the parameter.
 Category: Signed  Enumeration elements(long index, Object associatedData)
          Returns an array of keystore information that contains the certificates, keys and other data associated with this alias.
 Category: Signed  Enumeration elements(long index, Object associatedData, boolean backingKeyStore)
          Returns an array of keystore information that contains the certificates, keys and other data associated with this alias.
 Category: Signed  boolean exists(long index, Object associatedData)
          Returns a boolean denoting whether an object exists with the given alias and the given index class.
 Category: Signed  boolean existsIndex(long index)
          Returns a boolean denoting whether this index already exists in the key store.
 Category: Signed  KeyStore getBackingKeyStore()
          This method returns the backing keystore for the preferred keystore currently set in the combined keystore.
 Category: Signed  KeyStore getKeyStore(int index)
          This method returns the KeyStore associated with the index specified as the only parameter.
 Category: Signed  String getName()
          Returns the name of the preferred key store.
 Category: Signed  int getNumKeyStores()
          This method returns the number of keystores that are currently contained in the CombinedKeyStore.
 Category: Signed  KeyStoreTicket getTicket()
          Calls the getTicket method on the preferred key store.
 Category: Signed  KeyStoreTicket getTicket(String prompt)
          Calls the getTicket method on the preferred key store.
 Category: Signed  boolean isMember(byte[] certificateEncoding)
          Returns a boolean dictating whether or not this certificate is contained inside the KeyStore.
 Category: Signed  boolean isMember(Certificate certificate)
          Returns a boolean dictating whether or not this certificate is contained inside the KeyStore.
 Category: Signed  boolean isMember(Key key)
          Returns a boolean dictating whether or not this key is contained inside the KeyStore.
 Category: Signed  boolean isMember(KeyStoreData data)
          Returns a boolean dictating whether or not this KeyStoreData is contained inside the KeyStore.
 Category: Signed  void removeCollectionListener(Object listener)
          This method is called when the developer wants to remove the listener from this keystore.
 Category: Signed  void removeIndex(long index)
          Removes an index from all of the keystores in the combined keystore.
 Category: Signed  void removeKey(KeyStoreData data, KeyStoreTicket ticket)
          Remove the key from the preferred keystore.
 Category: Signed  void removeKeyStore(int index)
          Allows you to remove a keystore from the combined keystore.
 Category: Signed  KeyStoreData set(AssociatedData[] associatedData, String label, Certificate certificate, CertificateStatus certStatus, KeyStoreTicket ticket)
          Sets a new key into the preferred keystore.
 Category: Signed  KeyStoreData set(AssociatedData[] associatedData, String label, PrivateKey privateKey, String privateKeyEncodingAlgorithm, int securityLevel, Certificate certificate, CertificateStatus certStatus, KeyStoreTicket ticket)
          Sets a new key into the preferred keystore.
 Category: Signed  KeyStoreData set(AssociatedData[] associatedData, String label, PrivateKey privateKey, String privateKeyEncodingAlgorithm, int securityLevel, KeyStoreTicket ticket)
          Sets a new key into the preferred keystore.
 Category: Signed  KeyStoreData set(AssociatedData[] associatedData, String label, PrivateKey privateKey, String privateKeyEncodingAlgorithm, int securityLevel, PublicKey publicKey, long keyUsage, KeyStoreTicket ticket)
          Sets a new key into the preferred keystore.
 Category: Signed  KeyStoreData set(AssociatedData[] associatedData, String label, PublicKey publicKey, long keyUsage, KeyStoreTicket ticket)
          Sets a new key into the preferred keystore.
 Category: Signed  KeyStoreData set(AssociatedData[] associatedData, String label, SymmetricKey symmetricKey, String symmetricKeyEncodingAlgorithm, int securityLevel, KeyStoreTicket ticket)
          Sets a new key into the preferred keystore.
 Category: Signed  int size()
          Returns the number of elements inside the key store.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CombinedKeyStore

public CombinedKeyStore(KeyStore[] keyStores)
Initializes the combined keystore with an array of underlying keystores.

You can also add to this array later on if desired. It should be noted that by default the preferred keystore will be the first keystore given in the array unless otherwise specified.

Parameters:
keyStores - The array of keystores that you want as part of the combined keystore.
Since:
JDE 3.6.0
Category:
Signed: This element is only accessible by signed clients. If you intend to use this element, please contact RIM to establish the necessary agreements that will allow you to have your COD files signed. Signing is only required for use on the device, development under the JDE can occur without signing the CODs.

CombinedKeyStore

public CombinedKeyStore(KeyStore[] keyStores,
                        int preferredKeyStore)
Initializes the combined keystore with an array of underlying keystores.

You can also add to this array later on if desired.

Parameters:
keyStores - The array of keystores that you want as part of the combined keystore.
preferredKeyStore - An integer representing the index within the array of keystores that will be considered the preferred keystore. The preferred keystore will be the keystore that new keys are added to and other operations that are not obviously made for multiple key stores. (i.e. anything that causes a change in the state of a keystore). Remember that arrays are indexed at zero. Hence, if you want the very first keystore to be the preferred keystore it would have an index of 0.
Since:
JDE 3.6.0
Category:
Signed: This element is only accessible by signed clients. If you intend to use this element, please contact RIM to establish the necessary agreements that will allow you to have your COD files signed. Signing is only required for use on the device, development under the JDE can occur without signing the CODs.
Method Detail

set

public KeyStoreData set(AssociatedData[] associatedData,
                        String label,
                        PrivateKey privateKey,
                        String privateKeyEncodingAlgorithm,
                        int securityLevel,
                        KeyStoreTicket ticket)
                 throws NoSuchAlgorithmException,
                        InvalidKeyEncodingException,
                        CryptoTokenException,
                        CryptoUnsupportedOperationException,
                        KeyStoreCancelException,
                        InvalidKeyException
Sets a new key into the preferred keystore.

The new key exists exactly as it did in the original keystore implementation.

Since:
JDE 4.0.2
Category:
Signed: This element is only accessible by signed clients. If you intend to use this element, please contact RIM to establish the necessary agreements that will allow you to have your COD files signed. Signing is only required for use on the device, development under the JDE can occur without signing the CODs.

set

public KeyStoreData set(AssociatedData[] associatedData,
                        String label,
                        PrivateKey privateKey,
                        String privateKeyEncodingAlgorithm,
                        int securityLevel,
                        PublicKey publicKey,
                        long keyUsage,
                        KeyStoreTicket ticket)
                 throws NoSuchAlgorithmException,
                        InvalidKeyEncodingException,
                        CryptoTokenException,
                        CryptoUnsupportedOperationException,
                        KeyStoreCancelException,
                        InvalidKeyException
Sets a new key into the preferred keystore.

The new key exists exactly as it did in the original keystore implementation.

Since:
JDE 4.0.2
Category:
Signed: This element is only accessible by signed clients. If you intend to use this element, please contact RIM to establish the necessary agreements that will allow you to have your COD files signed. Signing is only required for use on the device, development under the JDE can occur without signing the CODs.

set

public KeyStoreData set(AssociatedData[] associatedData,
                        String label,
                        PrivateKey privateKey,
                        String privateKeyEncodingAlgorithm,
                        int securityLevel,
                        Certificate certificate,
                        CertificateStatus certStatus,
                        KeyStoreTicket ticket)
                 throws NoSuchAlgorithmException,
                        InvalidKeyEncodingException,
                        InvalidKeyException,
                        CryptoTokenException,
                        CryptoUnsupportedOperationException,
                        KeyStoreCancelException
Sets a new key into the preferred keystore.

The new key exists exactly as it did in the original keystore implementation.

Since:
JDE 4.0.2
Category:
Signed: This element is only accessible by signed clients. If you intend to use this element, please contact RIM to establish the necessary agreements that will allow you to have your COD files signed. Signing is only required for use on the device, development under the JDE can occur without signing the CODs.

set

public KeyStoreData set(AssociatedData[] associatedData,
                        String label,
                        PublicKey publicKey,
                        long keyUsage,
                        KeyStoreTicket ticket)
                 throws NoSuchAlgorithmException,
                        InvalidKeyEncodingException,
                        InvalidKeyException,
                        CryptoTokenException,
                        CryptoUnsupportedOperationException,
                        KeyStoreCancelException
Sets a new key into the preferred keystore.

The new key exists exactly as it did in the original keystore implementation.

Since:
JDE 4.0.2
Category:
Signed: This element is only accessible by signed clients. If you intend to use this element, please contact RIM to establish the necessary agreements that will allow you to have your COD files signed. Signing is only required for use on the device, development under the JDE can occur without signing the CODs.

set

public KeyStoreData set(AssociatedData[] associatedData,
                        String label,
                        Certificate certificate,
                        CertificateStatus certStatus,
                        KeyStoreTicket ticket)
                 throws NoSuchAlgorithmException,
                        InvalidKeyEncodingException,
                        InvalidKeyException,
                        CryptoTokenException,
                        CryptoUnsupportedOperationException,
                        KeyStoreCancelException
Sets a new key into the preferred keystore.

The new key exists exactly as it did in the original keystore implementation.

Since:
JDE 4.0.2
Category:
Signed: This element is only accessible by signed clients. If you intend to use this element, please contact RIM to establish the necessary agreements that will allow you to have your COD files signed. Signing is only required for use on the device, development under the JDE can occur without signing the CODs.

set

public KeyStoreData set(AssociatedData[] associatedData,
                        String label,
                        SymmetricKey symmetricKey,
                        String symmetricKeyEncodingAlgorithm,
                        int securityLevel,
                        KeyStoreTicket ticket)
                 throws NoSuchAlgorithmException,
                        InvalidKeyEncodingException,
                        InvalidKeyException,
                        CryptoTokenException,
                        CryptoUnsupportedOperationException,
                        KeyStoreCancelException
Sets a new key into the preferred keystore.

The new key exists exactly as it did in the original keystore implementation.

Since:
JDE 4.0.2
Category:
Signed: This element is only accessible by signed clients. If you intend to use this element, please contact RIM to establish the necessary agreements that will allow you to have your COD files signed. Signing is only required for use on the device, development under the JDE can occur without signing the CODs.

elements

public Enumeration elements(long index,
                            Object associatedData)
Returns an array of keystore information that contains the certificates, keys and other data associated with this alias.

Parameters:
index - A long representing the Index class that denotes where to find the associatedData and how it is used.
associatedData - An object denoting which key store information should be returned.
Returns:
An enumeration of all of the keystore data objects ( KeyStoreData ) that fit the description given by the index and alias.
Since:
JDE 4.0.2
Category:
Signed: This element is only accessible by signed clients. If you intend to use this element, please contact RIM to establish the necessary agreements that will allow you to have your COD files signed. Signing is only required for use on the device, development under the JDE can occur without signing the CODs.

elements

public Enumeration elements(long index,
                            Object associatedData,
                            boolean backingKeyStore)
Returns an array of keystore information that contains the certificates, keys and other data associated with this alias.

Parameters:
index - A long representing the Index class that denotes where to find the associatedData and how it is used.
associatedData - An object denoting which key store information should be returned.
Returns:
An enumeration of all of the keystore data objects ( KeyStoreData ) that fit the description given by the index and alias.
Since:
JDE 4.0.2
Category:
Signed: This element is only accessible by signed clients. If you intend to use this element, please contact RIM to establish the necessary agreements that will allow you to have your COD files signed. Signing is only required for use on the device, development under the JDE can occur without signing the CODs.

removeKey

public void removeKey(KeyStoreData data,
                      KeyStoreTicket ticket)
               throws KeyStoreCancelException
Remove the key from the preferred keystore.
Since:
JDE 4.0.2
Category:
Signed: This element is only accessible by signed clients. If you intend to use this element, please contact RIM to establish the necessary agreements that will allow you to have your COD files signed. Signing is only required for use on the device, development under the JDE can occur without signing the CODs.

elements

public Enumeration elements()
Returns an enumeration of the KeyStoreData that are stored in the KeyStore. Note that this is akin to retrieving an enumeration of all the keys in every keystore in the combined keystore. Note that this function will not return any KeyStoreData records from the backing keystore.

Returns:
An enumeration of keystore data objects ( KeyStoreData ).
Since:
JDE 3.6.0
Category:
Signed: This element is only accessible by signed clients. If you intend to use this element, please contact RIM to establish the necessary agreements that will allow you to have your COD files signed. Signing is only required for use on the device, development under the JDE can occur without signing the CODs.

elements

public Enumeration elements(boolean backingKeyStore)
Returns an enumeration of the KeyStoreData that are stored in the KeyStore. Note that this is akin to retrieving an enumeration of all the keys in every keystore in the combined keystore.
Parameters:
backingKeyStore - if true this method will return the elements from the backing key store as well.

Returns:
An enumeration of keystore data objects ( KeyStoreData ).
Since:
JDE 4.0.2
Category:
Signed: This element is only accessible by signed clients. If you intend to use this element, please contact RIM to establish the necessary agreements that will allow you to have your COD files signed. Signing is only required for use on the device, development under the JDE can occur without signing the CODs.

elements

public Enumeration elements(long index)
Returns an enumeration of the elements (KeyStoreData) inside the key store according to the index provided with the parameter.

Parameters:
index - A long representing what index to return an enumeration of the elements for.
Returns:
An enumeration of keystore data objects ( KeyStoreData ).
Since:
JDE 4.0.2
Category:
Signed: This element is only accessible by signed clients. If you intend to use this element, please contact RIM to establish the necessary agreements that will allow you to have your COD files signed. Signing is only required for use on the device, development under the JDE can occur without signing the CODs.

elements

public Enumeration elements(long index,
                            boolean backingKeyStore)
Returns an enumeration of the elements (KeyStoreData) inside the key store according to the index provided with the parameter.

Parameters:
index - A long representing what index to return an enumeration of the elements for.
Returns:
An enumeration of keystore data objects ( KeyStoreData ).
Since:
JDE 4.0.2
Category:
Signed: This element is only accessible by signed clients. If you intend to use this element, please contact RIM to establish the necessary agreements that will allow you to have your COD files signed. Signing is only required for use on the device, development under the JDE can occur without signing the CODs.

exists

public boolean exists(long index,
                      Object associatedData)
Returns a boolean denoting whether an object exists with the given alias and the given index class.

Parameters:
index - The long denoting the index class.
associatedData - An object representing the associated data to the key store information.
Returns:
A boolean that indicates if the object exists.
Since:
JDE 4.0.2
Category:
Signed: This element is only accessible by signed clients. If you intend to use this element, please contact RIM to establish the necessary agreements that will allow you to have your COD files signed. Signing is only required for use on the device, development under the JDE can occur without signing the CODs.

addIndex

public boolean addIndex(KeyStoreIndex index)
Adds an index to all of the information currently in the key store.

This enables the developer to access information in the key store according to this new associatedData field. For a combined key store this will add the index to all of the underlying keystores.

Parameters:
index - An Index class that is implemented by the developer. It denotes the key store information is indexed according to fields currently contained in key store objects such as certificates.
Returns:
A boolean denoting if the index was added correctly. Return false if the index already exists. This method may return false if the index exists in one of the many keystores in the combined keystore. It will however be added to any of the keystores that this index is not already added to even if it returns false.
Since:
JDE 4.0.2
Category:
Signed: This element is only accessible by signed clients. If you intend to use this element, please contact RIM to establish the necessary agreements that will allow you to have your COD files signed. Signing is only required for use on the device, development under the JDE can occur without signing the CODs.

addIndices

public void addIndices(KeyStoreIndex[] indices)
Adds an array of indices to all of the information currently in the key store.

This enables the developer to access information in the key store according to this new associatedData field. For a combined key store this will add the index to all of the underlying keystores.

Parameters:
indices - A KeyStoreIndex class that is implemented by the developer. It denotes the key store information is indexed according to fields currently contained in key store objects such as certificates.
Since:
JDE 4.0.2
Category:
Signed: This element is only accessible by signed clients. If you intend to use this element, please contact RIM to establish the necessary agreements that will allow you to have your COD files signed. Signing is only required for use on the device, development under the JDE can occur without signing the CODs.

removeIndex

public void removeIndex(long index)
Removes an index from all of the keystores in the combined keystore.
Parameters:
index - the long representing the ID of the index to remove.
Since:
JDE 4.0.2
Category:
Signed: This element is only accessible by signed clients. If you intend to use this element, please contact RIM to establish the necessary agreements that will allow you to have your COD files signed. Signing is only required for use on the device, development under the JDE can occur without signing the CODs.

existsIndex

public boolean existsIndex(long index)
Returns a boolean denoting whether this index already exists in the key store. In the combined keystore this will return a boolean if and only if all of the keystores underlying the combined keystore have an index specified as the parameter.
Since:
JDE 4.0.2
Category:
Signed: This element is only accessible by signed clients. If you intend to use this element, please contact RIM to establish the necessary agreements that will allow you to have your COD files signed. Signing is only required for use on the device, development under the JDE can occur without signing the CODs.

size

public int size()
Returns the number of elements inside the key store.

For the combined key store this returns the number of elements in all of the keystores added together. That is, if you had five elements in one key store and six elements in a second key store then this would return 11 elements.

Since:
JDE 3.6.0
Category:
Signed: This element is only accessible by signed clients. If you intend to use this element, please contact RIM to establish the necessary agreements that will allow you to have your COD files signed. Signing is only required for use on the device, development under the JDE can occur without signing the CODs.

addKeyStores

public void addKeyStores(KeyStore[] keyStores)
Allows for the addition of more keystores to the combined key store.

Note This will not make the distinction of checking to see if a keystore has already been added to the combined keystore. This is left to the developer since there is no real way to uniquely identify a keystore.

Parameters:
keyStores - An array of additional key stores that will be added to the combined key store.
Since:
JDE 4.0.2
Category:
Signed: This element is only accessible by signed clients. If you intend to use this element, please contact RIM to establish the necessary agreements that will allow you to have your COD files signed. Signing is only required for use on the device, development under the JDE can occur without signing the CODs.

removeKeyStore

public void removeKeyStore(int index)
                    throws IllegalArgumentException
Allows you to remove a keystore from the combined keystore.
Parameters:
index - the index into the array of keystores that you would like to remove.
Throws:
IllegalArgumentException - Thrown if the integer is not in the following range 0 < x < size where x is the new preferred key store and size is the number of keystores currently in the combined key store.
Since:
JDE 4.0.2
Category:
Signed: This element is only accessible by signed clients. If you intend to use this element, please contact RIM to establish the necessary agreements that will allow you to have your COD files signed. Signing is only required for use on the device, development under the JDE can occur without signing the CODs.

changePreferredKeyStore

public void changePreferredKeyStore(int newPreferredKeyStore)
                             throws IllegalArgumentException
Allows you to change the preferred key store. This will now be the keystore that will have all of the modifying operations performed on it.

Parameters:
newPreferredKeyStore - A new key store index that will be used to index into the array of stored keystores.
Throws:
IllegalArgumentException - Thrown if the integer is not in the following range 0 < x < size where x is the new preferred key store and size is the number of keystores currently in the combined key store.
Since:
JDE 4.0.2
Category:
Signed: This element is only accessible by signed clients. If you intend to use this element, please contact RIM to establish the necessary agreements that will allow you to have your COD files signed. Signing is only required for use on the device, development under the JDE can occur without signing the CODs.

getTicket

public KeyStoreTicket getTicket()
                         throws KeyStoreCancelException
Calls the getTicket method on the preferred key store.
Since:
JDE 3.6.0
Category:
Signed: This element is only accessible by signed clients. If you intend to use this element, please contact RIM to establish the necessary agreements that will allow you to have your COD files signed. Signing is only required for use on the device, development under the JDE can occur without signing the CODs.

getTicket

public KeyStoreTicket getTicket(String prompt)
                         throws KeyStoreCancelException
Calls the getTicket method on the preferred key store.
Since:
JDE 4.0.2
Category:
Signed: This element is only accessible by signed clients. If you intend to use this element, please contact RIM to establish the necessary agreements that will allow you to have your COD files signed. Signing is only required for use on the device, development under the JDE can occur without signing the CODs.

checkTicket

public boolean checkTicket(KeyStoreTicket ticket)
Calls the checkTicket method on the preferred key store.
Since:
JDE 4.0.2
Category:
Signed: This element is only accessible by signed clients. If you intend to use this element, please contact RIM to establish the necessary agreements that will allow you to have your COD files signed. Signing is only required for use on the device, development under the JDE can occur without signing the CODs.

getName

public String getName()
Returns the name of the preferred key store.
Since:
JDE 3.6.0
Category:
Signed: This element is only accessible by signed clients. If you intend to use this element, please contact RIM to establish the necessary agreements that will allow you to have your COD files signed. Signing is only required for use on the device, development under the JDE can occur without signing the CODs.

isMember

public boolean isMember(Certificate certificate)
Returns a boolean dictating whether or not this certificate is contained inside the KeyStore.
Since:
JDE 4.0.2
Category:
Signed: This element is only accessible by signed clients. If you intend to use this element, please contact RIM to establish the necessary agreements that will allow you to have your COD files signed. Signing is only required for use on the device, development under the JDE can occur without signing the CODs.

isMember

public boolean isMember(byte[] certificateEncoding)
Returns a boolean dictating whether or not this certificate is contained inside the KeyStore.
Since:
JDE 4.0.2
Category:
Signed: This element is only accessible by signed clients. If you intend to use this element, please contact RIM to establish the necessary agreements that will allow you to have your COD files signed. Signing is only required for use on the device, development under the JDE can occur without signing the CODs.

isMember

public boolean isMember(Key key)
Returns a boolean dictating whether or not this key is contained inside the KeyStore.
Since:
JDE 4.0.2
Category:
Signed: This element is only accessible by signed clients. If you intend to use this element, please contact RIM to establish the necessary agreements that will allow you to have your COD files signed. Signing is only required for use on the device, development under the JDE can occur without signing the CODs.

isMember

public boolean isMember(KeyStoreData data)
Returns a boolean dictating whether or not this KeyStoreData is contained inside the KeyStore.
Since:
JDE 4.0.2
Category:
Signed: This element is only accessible by signed clients. If you intend to use this element, please contact RIM to establish the necessary agreements that will allow you to have your COD files signed. Signing is only required for use on the device, development under the JDE can occur without signing the CODs.

addCollectionListener

public void addCollectionListener(Object listener)
This method is called when the developer wants to listen in on when records are added and removed to/from a particular keystore. This method will add a collection listener to all of the keystores in this combined keystore. Note: This does not add the listener to the underlying keystore.

Parameters:
listener - The KeyStoreListener interface that must be implemented by the calling class which will be called when a record is added or removed.
Since:
JDE 4.0.2
Category:
Signed: This element is only accessible by signed clients. If you intend to use this element, please contact RIM to establish the necessary agreements that will allow you to have your COD files signed. Signing is only required for use on the device, development under the JDE can occur without signing the CODs.

removeCollectionListener

public void removeCollectionListener(Object listener)
This method is called when the developer wants to remove the listener from this keystore. This method will add a collection listener to all of the keystores in this combined keystore. Note: This does not remove the listener from the underlying keystore.

Parameters:
listener - The KeyStoreListener to be removed.
Since:
JDE 4.0.2
Category:
Signed: This element is only accessible by signed clients. If you intend to use this element, please contact RIM to establish the necessary agreements that will allow you to have your COD files signed. Signing is only required for use on the device, development under the JDE can occur without signing the CODs.

getBackingKeyStore

public KeyStore getBackingKeyStore()
This method returns the backing keystore for the preferred keystore currently set in the combined keystore.
Since:
JDE 3.6.0
Category:
Signed: This element is only accessible by signed clients. If you intend to use this element, please contact RIM to establish the necessary agreements that will allow you to have your COD files signed. Signing is only required for use on the device, development under the JDE can occur without signing the CODs.

getNumKeyStores

public int getNumKeyStores()
This method returns the number of keystores that are currently contained in the CombinedKeyStore. This allows one to find out exactly which KeyStores are contained in the CombinedKeyStore.
Returns:
the number of KeyStores contained in the CombinedKeyStore.
Since:
JDE 3.6.0
Category:
Signed: This element is only accessible by signed clients. If you intend to use this element, please contact RIM to establish the necessary agreements that will allow you to have your COD files signed. Signing is only required for use on the device, development under the JDE can occur without signing the CODs.

getKeyStore

public KeyStore getKeyStore(int index)
                     throws IllegalArgumentException
This method returns the KeyStore associated with the index specified as the only parameter. If this index is less than 0 or greater than the number of keystores then this will throw an IllegalArgumentException.
Parameters:
index - the index into the array of KeyStores that we should return.
Returns:
the KeyStore associated with the index passed into the method.
Throws:
IllegalArgumentException - if the index is invalid.
Since:
JDE 4.0.2
Category:
Signed: This element is only accessible by signed clients. If you intend to use this element, please contact RIM to establish the necessary agreements that will allow you to have your COD files signed. Signing is only required for use on the device, development under the JDE can occur without signing the CODs.


Copyright 1999-2004 Research In Motion Limited. 295 Phillip Street, Waterloo, Ontario, Canada, N2L 3W8. All Rights Reserved.
Copyright 1993-2003 Sun Microsystems, Inc. 901 San Antonio Road, Palo Alto, California, 94303, U.S.A.
Copyright 2002-2003 Nokia Corporation All Rights Reserved.
Java is a trademark or registered trademark of Sun Microsystems, Inc. in the US and other countries.