Methods Summary |
---|
public boolean | addInto(java.lang.Object key, java.lang.Object element, java.lang.Object container)INTERNAL:
Add element into a container which implements the Collection interface.
try {
return ((Collection)container).add(element);
} catch (ClassCastException ex1) {
throw QueryException.cannotAddElement(element, container, ex1);
} catch (IllegalArgumentException ex2) {
throw QueryException.cannotAddElement(element, container, ex2);
} catch (UnsupportedOperationException ex3) {
throw QueryException.cannotAddElement(element, container, ex3);
}
|
public java.lang.Object | buildContainerFromVector(java.util.Vector vector, oracle.toplink.essentials.internal.sessions.AbstractSession session)INTERNAL:
Return a container populated with the contents of the specified Vector.
if ((getContainerClass() == vector.getClass()) && (!hasElementDescriptor())) {
return vector;
} else {
return super.buildContainerFromVector(vector, session);
}
|
public void | clear(java.lang.Object container)INTERNAL:
Remove all the elements from container.
try {
((Collection)container).clear();
} catch (UnsupportedOperationException ex) {
throw QueryException.methodNotValid(container, "clear()");
}
|
protected boolean | contains(java.lang.Object element, java.lang.Object container)INTERNAL:
Return the true if element exists in container.
return ((Collection)container).contains(element);
|
public java.lang.Class | getInterfaceType()
return ClassConstants.Collection_Class;
|
public boolean | hasOrder()INTERNAL:
Return whether the collection has order.
SortedSets cannot be indexed, but they are order-sensitive.
return Helper.classImplementsInterface(this.getContainerClass(), ClassConstants.SortedSet_Class);
|
public boolean | isCollectionPolicy()
return true;
|
public boolean | isValidContainer(java.lang.Object container)INTERNAL:
Validate the container type.
// PERF: Use instanceof which is inlined, not isAssignable which is very inefficent.
return container instanceof Collection;
|
public java.lang.Object | iteratorFor(java.lang.Object container)INTERNAL:
Return an iterator for the given container.
return ((Collection)container).iterator();
|
protected boolean | removeFrom(java.lang.Object key, java.lang.Object element, java.lang.Object container)INTERNAL:
Remove element from container which implements the Collection interface.
try {
return ((Collection)container).remove(element);
} catch (UnsupportedOperationException ex) {
throw QueryException.methodNotValid(element, "remove(Object element)");
}
|
public int | sizeFor(java.lang.Object container)INTERNAL:
Return the size of container.
return ((Collection)container).size();
|