Top Description Fields Constructors Methods
org.eclipse.persistence.internal.helper

public Class NonSynchronizedProperties

extends Properties
Class Inheritance
Imports
java.util.*, .Map.Entry

Properties subclass that removes the synchronization.

Field Summary

Modifier and TypeField and Description
protected Map<Object, Object>
Inherited from java.util.Properties:
defaults

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public void
clear()

Overrides java.util.Properties.clear.

Implements java.util.Map.clear.

Clears this hashtable so that it contains no keys.
public Object
clone()

Overrides java.util.Properties.clone.

Creates a shallow copy of this hashtable.
public boolean
contains(Object
a value to search for
value
)

Overrides java.util.Properties.contains.

Tests if some key maps into the specified value in this hashtable.
public boolean
containsKey(Object
possible key
key
)

Overrides java.util.Properties.containsKey.

Implements java.util.Map.containsKey.

Tests if the specified object is a key in this hashtable.
public boolean
containsValue(Object
value whose presence in this hashtable is to be tested
value
)

Overrides java.util.Properties.containsValue.

Implements java.util.Map.containsValue.

Returns true if this hashtable maps one or more keys to this value.
public Enumeration<Object>
elements()

Overrides java.util.Properties.elements.

Returns an enumeration of the values in this hashtable.
public Set<Map.Entry<Object, Object>>
entrySet()

Overrides java.util.Properties.entrySet.

Implements java.util.Map.entrySet.

Returns a Set view of the mappings contained in this map.
public boolean
equals(Object
object to be compared for equality with this hashtable
o
)

Overrides java.util.Properties.equals.

Implements java.util.Map.equals.

Compares the specified Object with this Map for equality, as per the definition in the Map interface.
public Object
get(Object
the key whose associated value is to be returned
key
)

Overrides java.util.Properties.get.

Implements java.util.Map.get.

Returns the value to which the specified key is mapped, or null if this map contains no mapping for the key.
public String
getProperty(String
the hashtable key.
key
,
String
a default value.
defaultValue
)

Overrides java.util.Properties.getProperty.

Searches for the property with the specified key in this property list.
public String
getProperty(String
the property key.
key
)

Overrides java.util.Properties.getProperty.

Searches for the property with the specified key in this property list.
public int
hashCode()

Overrides java.util.Properties.hashCode.

Implements java.util.Map.hashCode.

Returns the hash code value for this Map as per the definition in the Map interface.
public boolean
isEmpty()

Overrides java.util.Properties.isEmpty.

Implements java.util.Map.isEmpty.

Tests if this hashtable maps no keys to values.
public Enumeration<Object>
keys()

Overrides java.util.Properties.keys.

Returns an enumeration of the keys in this hashtable.
public Set<Object>
keySet()

Overrides java.util.Properties.keySet.

Implements java.util.Map.keySet.

Returns a Set view of the keys contained in this map.
public Object
put(Object
the hashtable key
key
,
Object
the value
value
)

Overrides java.util.Properties.put.

Implements java.util.Map.put.

Maps the specified key to the specified value in this hashtable.
public void
putAll(Map<?, ?>
mappings to be stored in this map
t
)

Overrides java.util.Properties.putAll.

Implements java.util.Map.putAll.

Copies all of the mappings from the specified map to this hashtable.
public Object
remove(Object
the key that needs to be removed
key
)

Overrides java.util.Properties.remove.

Implements java.util.Map.remove.

Removes the key (and its corresponding value) from this hashtable.
public Object
setProperty(String
the key to be placed into this property list.
key
,
String
the value corresponding to key.
value
)

Overrides java.util.Properties.setProperty.

Calls the Hashtable method put.
public int
size()

Overrides java.util.Properties.size.

Implements java.util.Map.size.

Returns the number of keys in this hashtable.
public String
toString()

Overrides java.util.Properties.toString.

Returns a string representation of this Hashtable object in the form of a set of entries, enclosed in braces and separated by the ASCII characters " , " (comma and space).
public Collection<Object>
values()

Overrides java.util.Properties.values.

Implements java.util.Map.values.

Returns a Collection view of the values contained in this map.
Inherited from java.util.Properties:
computecomputeIfAbsentcomputeIfPresentforEachgetOrDefaultlistlistloadloadloadFromXMLmergepropertyNamesputIfAbsentrehashremovereplacereplacereplaceAllsavestorestorestoreToXMLstoreToXMLstoreToXMLstringPropertyNames

Field Detail

valuesback to summary
protected Map<Object, Object> values

Hides java.util.Hashtable.values.

Constructor Detail

NonSynchronizedPropertiesback to summary
public NonSynchronizedProperties(int size)

Method Detail

clearback to summary
public void clear()

Overrides java.util.Properties.clear.

Implements java.util.Map.clear.

Doc from java.util.Hashtable.clear.

Clears this hashtable so that it contains no keys.

Annotations
@Override
cloneback to summary
public Object clone()

Overrides java.util.Properties.clone.

Doc from java.util.Hashtable.clone.

Creates a shallow copy of this hashtable. All the structure of the hashtable itself is copied, but the keys and values are not cloned. This is a relatively expensive operation.

Returns:Object

a clone of the hashtable

Annotations
@Override
containsback to summary
public boolean contains(Object value)

Overrides java.util.Properties.contains.

Doc from java.util.Hashtable.contains.

Tests if some key maps into the specified value in this hashtable. This operation is more expensive than the containsKey method.

Note that this method is identical in functionality to containsValue, (which is part of the Map interface in the collections framework).

Parameters
value:Object

a value to search for

Returns:boolean

true if and only if some key maps to the value argument in this hashtable as determined by the equals method; false otherwise.

Annotations
@Override
containsKeyback to summary
public boolean containsKey(Object key)

Overrides java.util.Properties.containsKey.

Implements java.util.Map.containsKey.

Doc from java.util.Hashtable.containsKey.

Tests if the specified object is a key in this hashtable.

Parameters
key:Object

possible key

Returns:boolean

true if and only if the specified object is a key in this hashtable, as determined by the equals method; false otherwise.

Annotations
@Override
containsValueback to summary
public boolean containsValue(Object value)

Overrides java.util.Properties.containsValue.

Implements java.util.Map.containsValue.

Doc from java.util.Hashtable.containsValue.

Returns true if this hashtable maps one or more keys to this value.

Note that this method is identical in functionality to contains (which predates the Map interface).

Parameters
value:Object

value whose presence in this hashtable is to be tested

Returns:boolean

true if this map maps one or more keys to the specified value

Annotations
@Override
elementsback to summary
public Enumeration<Object> elements()

Overrides java.util.Properties.elements.

Doc from java.util.Hashtable.elements.

Returns an enumeration of the values in this hashtable. Use the Enumeration methods on the returned object to fetch the elements sequentially. If the hashtable is structurally modified while enumerating over the values then the results of enumerating are undefined.

Returns:Enumeration<Object>

an enumeration of the values in this hashtable.

Annotations
@Override
entrySetback to summary
public Set<Map.Entry<Object, Object>> entrySet()

Overrides java.util.Properties.entrySet.

Implements java.util.Map.entrySet.

Doc from java.util.Hashtable.entrySet.

Returns a Set view of the mappings contained in this map. The set is backed by the map, so changes to the map are reflected in the set, and vice-versa. If the map is modified while an iteration over the set is in progress (except through the iterator's own remove operation, or through the setValue operation on a map entry returned by the iterator) the results of the iteration are undefined. The set supports element removal, which removes the corresponding mapping from the map, via the Iterator.remove, Set.remove, removeAll, retainAll and clear operations. It does not support the add or addAll operations.

Returns:Set<Map.Entry<Object, Object>>

Doc from java.util.Map.entrySet.

a set view of the mappings contained in this map

Annotations
@Override
equalsback to summary
public boolean equals(Object o)

Overrides java.util.Properties.equals.

Implements java.util.Map.equals.

Doc from java.util.Hashtable.equals.

Compares the specified Object with this Map for equality, as per the definition in the Map interface.

Parameters
o:Object

object to be compared for equality with this hashtable

Returns:boolean

true if the specified Object is equal to this Map

Annotations
@Override
getback to summary
public Object get(Object key)

Overrides java.util.Properties.get.

Implements java.util.Map.get.

Doc from java.util.Hashtable.get.

Returns the value to which the specified key is mapped, or null if this map contains no mapping for the key.

More formally, if this map contains a mapping from a key k to a value v such that (key.equals(k)), then this method returns v; otherwise it returns null. (There can be at most one such mapping.)

Parameters
key:Object

the key whose associated value is to be returned

Returns:Object

the value to which the specified key is mapped, or null if this map contains no mapping for the key

Annotations
@Override
getPropertyback to summary
public String getProperty(String key, String defaultValue)

Overrides java.util.Properties.getProperty.

Doc from java.util.Properties.getProperty.

Searches for the property with the specified key in this property list. If the key is not found in this property list, the default property list, and its defaults, recursively, are then checked. The method returns the default value argument if the property is not found.

Parameters
key:String

the hashtable key.

defaultValue:String

a default value.

Returns:String

the value in this property list with the specified key value.

Annotations
@Override
getPropertyback to summary
public String getProperty(String key)

Overrides java.util.Properties.getProperty.

Doc from java.util.Properties.getProperty.

Searches for the property with the specified key in this property list. If the key is not found in this property list, the default property list, and its defaults, recursively, are then checked. The method returns null if the property is not found.

Parameters
key:String

the property key.

Returns:String

the value in this property list with the specified key value.

Annotations
@Override
hashCodeback to summary
public int hashCode()

Overrides java.util.Properties.hashCode.

Implements java.util.Map.hashCode.

Doc from java.util.Hashtable.hashCode.

Returns the hash code value for this Map as per the definition in the Map interface.

Returns:int

Doc from java.util.Map.hashCode.

the hash code value for this map

Annotations
@Override
isEmptyback to summary
public boolean isEmpty()

Overrides java.util.Properties.isEmpty.

Implements java.util.Map.isEmpty.

Doc from java.util.Hashtable.isEmpty.

Tests if this hashtable maps no keys to values.

Returns:boolean

true if this hashtable maps no keys to values; false otherwise.

Annotations
@Override
keysback to summary
public Enumeration<Object> keys()

Overrides java.util.Properties.keys.

Doc from java.util.Hashtable.keys.

Returns an enumeration of the keys in this hashtable. Use the Enumeration methods on the returned object to fetch the keys sequentially. If the hashtable is structurally modified while enumerating over the keys then the results of enumerating are undefined.

Returns:Enumeration<Object>

an enumeration of the keys in this hashtable.

Annotations
@Override
keySetback to summary
public Set<Object> keySet()

Overrides java.util.Properties.keySet.

Implements java.util.Map.keySet.

Doc from java.util.Hashtable.keySet.

Returns a Set view of the keys contained in this map. The set is backed by the map, so changes to the map are reflected in the set, and vice-versa. If the map is modified while an iteration over the set is in progress (except through the iterator's own remove operation), the results of the iteration are undefined. The set supports element removal, which removes the corresponding mapping from the map, via the Iterator.remove, Set.remove, removeAll, retainAll, and clear operations. It does not support the add or addAll operations.

Returns:Set<Object>

Doc from java.util.Map.keySet.

a set view of the keys contained in this map

Annotations
@Override
putback to summary
public Object put(Object key, Object value)

Overrides java.util.Properties.put.

Implements java.util.Map.put.

Doc from java.util.Hashtable.put.

Maps the specified key to the specified value in this hashtable. Neither the key nor the value can be null.

The value can be retrieved by calling the get method with a key that is equal to the original key.

Parameters
key:Object

the hashtable key

value:Object

the value

Returns:Object

the previous value of the specified key in this hashtable, or null if it did not have one

Annotations
@Override
putAllback to summary
public void putAll(Map<?, ?> t)

Overrides java.util.Properties.putAll.

Implements java.util.Map.putAll.

Doc from java.util.Hashtable.putAll.

Copies all of the mappings from the specified map to this hashtable. These mappings will replace any mappings that this hashtable had for any of the keys currently in the specified map.

Parameters
t:Map<?, ?>

mappings to be stored in this map

Annotations
@Override
removeback to summary
public Object remove(Object key)

Overrides java.util.Properties.remove.

Implements java.util.Map.remove.

Doc from java.util.Hashtable.remove.

Removes the key (and its corresponding value) from this hashtable. This method does nothing if the key is not in the hashtable.

Parameters
key:Object

the key that needs to be removed

Returns:Object

the value to which the key had been mapped in this hashtable, or null if the key did not have a mapping

Annotations
@Override
setPropertyback to summary
public Object setProperty(String key, String value)

Overrides java.util.Properties.setProperty.

Doc from java.util.Properties.setProperty.

Calls the Hashtable method put. Provided for parallelism with the getProperty method. Enforces use of strings for property keys and values. The value returned is the result of the Hashtable call to put.

Parameters
key:String

the key to be placed into this property list.

value:String

the value corresponding to key.

Returns:Object

the previous value of the specified key in this property list, or null if it did not have one.

Annotations
@Override
sizeback to summary
public int size()

Overrides java.util.Properties.size.

Implements java.util.Map.size.

Doc from java.util.Hashtable.size.

Returns the number of keys in this hashtable.

Returns:int

the number of keys in this hashtable.

Annotations
@Override
toStringback to summary
public String toString()

Overrides java.util.Properties.toString.

Doc from java.util.Hashtable.toString.

Returns a string representation of this Hashtable object in the form of a set of entries, enclosed in braces and separated by the ASCII characters " , " (comma and space). Each entry is rendered as the key, an equals sign =, and the associated element, where the toString method is used to convert the key and element to strings.

Returns:String

a string representation of this hashtable

Annotations
@Override
valuesback to summary
public Collection<Object> values()

Overrides java.util.Properties.values.

Implements java.util.Map.values.

Doc from java.util.Hashtable.values.

Returns a Collection view of the values contained in this map. The collection is backed by the map, so changes to the map are reflected in the collection, and vice-versa. If the map is modified while an iteration over the collection is in progress (except through the iterator's own remove operation), the results of the iteration are undefined. The collection supports element removal, which removes the corresponding mapping from the map, via the Iterator.remove, Collection.remove, removeAll, retainAll and clear operations. It does not support the add or addAll operations.

Returns:Collection<Object>

Doc from java.util.Map.values.

a collection view of the values contained in this map

Annotations
@Override