public final class MutableArrayValueData
extends java.lang.Object
| Modifier and Type | Field and Description |
|---|---|
DBField |
field
the base field.
|
DBObjectHelper |
helper
the helper
|
DBObject |
obj
the base object
|
| Constructor and Description |
|---|
MutableArrayValueData(DBObject obj,
DBField field,
StoredArrayValue store,
DBObjectHelper helper,
DBObjectHelper copyFrom)
create a mutable array value based on another.
|
| Modifier and Type | Method and Description |
|---|---|
void |
add(MutableArrayValue mav,
int index,
java.lang.Object element) |
boolean |
add(MutableArrayValue mav,
java.lang.Object e) |
boolean |
addAll(MutableArrayValue mav,
java.util.Collection c) |
boolean |
addAll(MutableArrayValue mav,
int index,
java.util.Collection c) |
void |
clear(MutableArrayValue mav) |
boolean |
contains(java.lang.Object o) |
static MutableArrayValueData |
find(DBObjectHelper helper,
DBField field,
StoredArrayValue store) |
java.lang.Object |
get(int pos)
get the object at the position
|
DBObject |
getDBObject()
get the base object
|
int |
getOriginalSeq(int pos)
get the original sequence number.
|
boolean |
hasChanged()
Has this been changed ?
|
int |
indexOf(java.lang.Object o) |
int |
lastIndexOf(java.lang.Object o) |
java.util.ListIterator |
listIterator(int index)
list iterator
|
java.util.ListIterator |
listIterator(MutableArrayValue mav) |
void |
markAsSaved() |
java.lang.Object |
rawGet(int pos)
get the object at the position
|
static MutableArrayValueData |
reloadData(DBObject obj,
DBField field,
DBObjectHelper helper,
StoredArrayValue store)
reload the data
|
java.lang.Object |
remove(MutableArrayValue mav,
int index) |
boolean |
remove(MutableArrayValue mav,
java.lang.Object o) |
boolean |
removeAll(java.util.Collection c) |
boolean |
retainAll(java.util.Collection c) |
java.lang.Object |
set(MutableArrayValue mav,
int pos,
java.lang.Object inValue)
set the value
|
int |
size() |
java.util.List |
subList(int fromIndex,
int toIndex)
sub list
|
java.lang.Object[] |
toArray() |
java.lang.Object[] |
toArray(java.lang.Object[] array)
make a array
|
java.lang.String |
toString()
to String
|
public final DBObjectHelper helper
public final DBObject obj
public final DBField field
public MutableArrayValueData(@Nonnull
DBObject obj,
@Nonnull
DBField field,
@Nullable
StoredArrayValue store,
@Nonnull
DBObjectHelper helper,
@Nullable
DBObjectHelper copyFrom)
obj - the objectfield - the fieldhelper - the helperstore - the store to be based on.copyFrom - copy from@CheckReturnValue @Nonnull public DBObject getDBObject()
@CheckReturnValue public boolean hasChanged()
@CheckReturnValue
public int getOriginalSeq(@Nonnegative
int pos)
pos - the position to fetch.@Nonnull @CheckReturnValue public static MutableArrayValueData reloadData(DBObject obj, DBField field, DBObjectHelper helper, StoredArrayValue store)
obj - the objectfield - the fieldhelper - the helperstore - the store@Nullable @CheckReturnValue public static MutableArrayValueData find(@Nonnull DBObjectHelper helper, @Nonnull DBField field, StoredArrayValue store)
helper - the helperfield - the fieldstore - the store@Nullable
@CheckReturnValue
public java.lang.Object get(@Nonnegative
int pos)
pos - the position@Nullable
@CheckReturnValue
public java.lang.Object rawGet(@Nonnegative
int pos)
pos - the position@Nullable public java.lang.Object set(MutableArrayValue mav, @Nonnegative int pos, @Nonnull java.lang.Object inValue)
mav - the real array valuepos - the positioninValue - the valuepublic void markAsSaved()
@CheckReturnValue @Nonnegative public int size()
@CheckReturnValue public boolean contains(java.lang.Object o)
o - object to check@CheckReturnValue @Nonnull public java.lang.Object[] toArray()
@CheckReturnValue @Nonnull public java.lang.String toString()
toString in class java.lang.Objectpublic boolean add(MutableArrayValue mav, java.lang.Object e)
mav - the base mutable array valuee - the objectpublic boolean remove(MutableArrayValue mav, java.lang.Object o)
mav - the base mutable array valueo - the object to removepublic boolean addAll(MutableArrayValue mav, java.util.Collection c)
mav - the base mutable array valuec - the collectionpublic boolean addAll(MutableArrayValue mav, @Nonnegative int index, java.util.Collection c)
mav - the base mutable array valueindex - the placec - the collectionpublic boolean removeAll(java.util.Collection c)
c - the collectionpublic boolean retainAll(java.util.Collection c)
c - the collectionpublic void clear(MutableArrayValue mav)
mav - the base mutable array valuepublic void add(MutableArrayValue mav, @Nonnegative int index, java.lang.Object element)
mav - the base mutable array valueindex - to locationelement - the element to addpublic java.lang.Object remove(MutableArrayValue mav, @Nonnegative int index)
mav - the base mutable array valueindex - from locationpublic int indexOf(java.lang.Object o)
o - the object to checkpublic int lastIndexOf(java.lang.Object o)
o - object to checkpublic java.util.ListIterator listIterator(MutableArrayValue mav)
mav - the base mutable array valuepublic java.util.ListIterator listIterator(int index)
index - frompublic java.util.List subList(int fromIndex,
int toIndex)
fromIndex - fromtoIndex - to@CheckReturnValue
@Nonnull
public java.lang.Object[] toArray(@Nonnull
java.lang.Object[] array)
array - the target arraystSoftware Copyright © 2001-2014 stSoftware All Rights Reserved.