public class IDataValueCollection extends IDataElementCollection
Collection
"-based API for accessing the values in a
WmRecord
. IDataValueCollection
is created and returned by the
WmRecord.values()
method and should not be created by adapter writers. The items
in IDataValueCollection
are the value objects in the WmRecord
.
IDataValueCollection
supports element removal, using the
Collection.clear()
, Collection.remove(java.lang.Object)
,
and Iterator.remove()
methods.
These methods will remove the value object from this Collection
and remove the key/value pair from the corresponding WmRecord
.
IDataValueCollection
does not support the
Collection.add(E)
,
Collection.addAll(java.util.Collection<? extends E>)
,
Collection.retainAll(java.util.Collection<?>)
methods. All other methods from Collection
are supported.
WmRecord.values()
elementCursor, iData
Constructor and Description |
---|
IDataValueCollection(com.wm.data.IData iData)
Constructs a
IDataValueCollection . |
Modifier and Type | Method and Description |
---|---|
boolean |
contains(java.lang.Object o)
Returns
true if this Collection contains the specified value. |
boolean |
containsAll(java.util.Collection collection)
Returns
true if this Colleciton contains all values
specified in the given collection. |
java.util.Iterator |
iterator()
Returns an
Iterator object for the value elements in this
Collection . |
boolean |
remove(java.lang.Object value)
Removes the specified value object from this
Collection ,
and removes its associated key/value from the corresponding WmRecord . |
boolean |
retainAll(java.util.Collection c)
Retains only the elements in this set that are contained in the specified collection.
|
java.lang.Object[] |
toArray()
Returns an array containing all of the values in this
Collection . |
add, addAll, clear, finalize, isEmpty, removeAll, size, toArray, toVector
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
public IDataValueCollection(com.wm.data.IData iData)
IDataValueCollection
.iData
- IData
object to wrap in this collection instance.public boolean contains(java.lang.Object o)
true
if this Collection
contains the specified value.
Note: Because this method must iterate through all of the elements in this collection to fulfill its purpose, you should consider the potential overhead involved in such an operation, especially when dealing with large collections.
contains
in interface java.util.Collection
contains
in class IDataElementCollection
o
- the value object to search for.true
if this Collection
(and its corresponding
WmRecord
) contains the value.public boolean containsAll(java.util.Collection collection)
true
if this Colleciton
contains all values
specified in the given collection.
Note: Because this method must iterate through all of the elements in this collection to fulfill its purpose, you should consider the potential overhead involved in such an operation, especially when dealing with large collections.
containsAll
in interface java.util.Collection
containsAll
in class IDataElementCollection
collection
- A Collection
of value objects.true
if all the values specified are in this Collection
.IDataElementCollection.contains(Object)
public java.util.Iterator iterator()
Iterator
object for the value elements in this
Collection
.iterator
in interface java.lang.Iterable
iterator
in interface java.util.Collection
iterator
in class IDataElementCollection
IDataValueIterator
IDataValueIterator
public boolean remove(java.lang.Object value)
Collection
,
and removes its associated key/value from the corresponding WmRecord
.
If the Collection
contains more than one of the same value objects,
this method removes only the first value object from the Collection
.remove
in interface java.util.Collection
remove
in class IDataElementCollection
value
- value to remove from this Collection.true
if the value object was removed from this
Collection
and the associated key/value removed from the
corresponding WmRecord
public boolean retainAll(java.util.Collection c)
retainAll
in interface java.util.Collection
retainAll
in class IDataElementCollection
c
- Collection of String object representing the record keyspublic java.lang.Object[] toArray()
Collection
.toArray
in interface java.util.Collection
toArray
in class IDataElementCollection
Copyright © 2003 - 2021 Software AG, Darmstadt, Germany and/or Software AG USA Inc., Reston, VA, USA, and/or its subsidiaries and/or its affiliates and/or their licensors.