This class provides a hashtable that will
employ content protection on the values stored
in the hashtable. Note that it does NOT protect
the keys in the hashtable.
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.
ContentProtectedHashtable()
Creates a new, empty ContentProtectedHashtable using the default capacity
and automatically protects the values in the hashtable.
ContentProtectedHashtable(boolean protect)
Creates a new, empty ContentProtectedHashtable using the default capacity.
ContentProtectedHashtable(Hashtable hashtable,
boolean protect)
Creates a new ContentProtectedHashtable with the contents currently
found in the Hashtable passed into this method.
ContentProtectedHashtable(int initialCapacity)
Creates a new, empty ContentProtectedHashtable using the initial capacity
and automatically protects the values in the hashtable.
ContentProtectedHashtable(int initialCapacity,
boolean protect)
Creates a new, empty ContentProtectedHashtable.
Method Summary
boolean
checkCrypt()
This method will return a boolean indicating if the protection setting of this hashtable
matches that of the user's content protection settings.
boolean
contains(Object value)
Determines if some key maps into the specified value in this hashtable.
isProtected()
This method will return a boolean indicating if the values
in this hashtable are currently being protected by content
protection.
void
persistentContentModeChanged(int generation)
Invoked when the persistent content mode changes, i.e., the Content Protection/Compression security
settings on the device change.
void
persistentContentStateChanged(int state)
Invoked when the persistent content state changes (e.g., the device changes from locked to unlocked).
Creates a new, empty ContentProtectedHashtable using the default capacity
and automatically protects the values in the hashtable.
Since:
JDE 4.0.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.
ContentProtectedHashtable
public ContentProtectedHashtable(boolean protect)
Creates a new, empty ContentProtectedHashtable using the default capacity.
Parameters:
protect - a boolean indicating whether or not the values to be
stored in the hashtable should be encrypted when placed in the hashtable
or only when it is deemed necessary via the reCrypt call.
Since:
JDE 4.0.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.
ContentProtectedHashtable
public ContentProtectedHashtable(Hashtable hashtable,
boolean protect)
Creates a new ContentProtectedHashtable with the contents currently
found in the Hashtable passed into this method.
Parameters:
hashtable - the hashtable to use for populating the ContentProtectedHashtable.
protect - a boolean indicating whether or not to encrypt the values
of the hashtable.
Since:
JDE 4.0.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.
ContentProtectedHashtable
public ContentProtectedHashtable(int initialCapacity)
Creates a new, empty ContentProtectedHashtable using the initial capacity
and automatically protects the values in the hashtable.
Parameters:
initialCapacity - the initial capacity of the hashtable.
Since:
JDE 4.0.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.
ContentProtectedHashtable
public ContentProtectedHashtable(int initialCapacity,
boolean protect)
Creates a new, empty ContentProtectedHashtable.
Parameters:
initialCapacity - the initial capacity of the hashtable.
protect - a boolean indicating whether or not the values to be
stored in the hashtable should be encrypted when placed in the hashtable
or only when it is deemed necessary via the reCrypt call.
Since:
JDE 4.0.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
checkCrypt
public boolean checkCrypt()
This method will return a boolean indicating if the protection setting of this hashtable
matches that of the user's content protection settings.
Returns:
true if the values are being protected according to the user's settings and false otherwise.
Since:
JDE 4.0.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.
Determines if some key maps into the specified value in this hashtable.
Note if protection is enabled and value is a byte array, then contains() will return false.
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.
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.
Object value associated with provided key, or null if no object
associated with the key.
Since:
JDE 4.0.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.
isProtected
public boolean isProtected()
This method will return a boolean indicating if the values
in this hashtable are currently being protected by content
protection.
Returns:
true if the values are being protected and false otherwise.
Since:
JDE 4.0.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.
persistentContentModeChanged
public void persistentContentModeChanged(int generation)
Listeners should periodically compare the generation parameter to
PersistentContent.getModeGeneration(). If they are different, then
the listeners should terminate their checkEncoding/reEncoding loops because the
security settings on the device have changed and they will have to be rechecked
and/or re-encoded anyway.
generation - Used to determine if the user has changed the content
protection settings since the listener was notified.
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.
persistentContentStateChanged
public void persistentContentStateChanged(int state)
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.
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.
reCrypt
public void reCrypt()
This method will enable protection and cause all the current contents to be encrypted according to the user's
content protection settings.
Since:
JDE 4.0.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.
Copyright 1999-2007 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.