Package com.mongodb
Class BasicDBList
- All Implemented Interfaces:
DBObject,Serializable,Cloneable,Iterable<Object>,Collection<Object>,List<Object>,RandomAccess,BSONObject
An implementation of List that reflects the way BSON lists work.
- See Also:
-
Field Summary
Fields inherited from class java.util.AbstractList
modCount -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncopy()Copies this instance into a new Object.booleanWhetherDBObject.markAsPartialObject()was ever called only matters if you are going to upsert and do not want to risk losing fields.voidIf this object was retrieved with only some fields (using a field filter) this method will be called to mark it as such.Methods inherited from class org.bson.types.BasicBSONList
containsField, get, keySet, put, put, putAll, putAll, removeField, toMapMethods inherited from class java.util.ArrayList
add, add, addAll, addAll, clear, clone, contains, ensureCapacity, equals, forEach, get, hashCode, indexOf, isEmpty, iterator, lastIndexOf, listIterator, listIterator, remove, remove, removeAll, removeIf, removeRange, replaceAll, retainAll, set, size, sort, spliterator, subList, toArray, toArray, trimToSizeMethods inherited from class java.util.AbstractCollection
containsAll, toStringMethods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface org.bson.BSONObject
containsField, get, keySet, put, putAll, putAll, removeField, toMapMethods inherited from interface java.util.Collection
parallelStream, stream, toArrayMethods inherited from interface java.util.List
containsAll
-
Constructor Details
-
BasicDBList
public BasicDBList()
-
-
Method Details
-
isPartialObject
public boolean isPartialObject()Description copied from interface:DBObjectWhetherDBObject.markAsPartialObject()was ever called only matters if you are going to upsert and do not want to risk losing fields.- Specified by:
isPartialObjectin interfaceDBObject- Returns:
- true if this has been marked as a partial object
-
markAsPartialObject
public void markAsPartialObject()Description copied from interface:DBObjectIf this object was retrieved with only some fields (using a field filter) this method will be called to mark it as such.- Specified by:
markAsPartialObjectin interfaceDBObject
-
copy
Copies this instance into a new Object.- Returns:
- a new BasicDBList with the same values as this instance
-