|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectchoco.kernel.memory.copy.RcLongVector
public class RcLongVector
Created by IntelliJ IDEA. User: julien Date: May 6, 2010 Time: 1:06:07 PM
Field Summary | |
---|---|
static int |
MIN_CAPACITY
Minimal capacity of a vector |
Fields inherited from interface choco.kernel.memory.IStateLongVector |
---|
LOGGER |
Fields inherited from interface choco.kernel.memory.copy.RecomputableElement |
---|
BOOL, DOUBLE, DOUBLEVECTOR, INT, INTVECTOR, LONG, LONGVECTOR, NB_TYPE, OBJECT, VECTOR |
Constructor Summary | |
---|---|
RcLongVector(EnvironmentCopying env)
Constructs an empty stored search vector. |
|
RcLongVector(EnvironmentCopying env,
int initialSize,
long initialValue)
Constructs a stored search vector with an initial size, and initial values. |
|
RcLongVector(EnvironmentCopying env,
long[] entries)
|
Method Summary | |
---|---|
void |
_set(long[] vals)
|
void |
_set(long[] vals,
int timeStamp)
|
void |
add(long i)
Adds a new search at the end of the vector. |
boolean |
contain(long val)
|
long[] |
deepCopy()
|
void |
ensureCapacity(int minCapacity)
Checks if the capacity is great enough, else the capacity is extended. |
long |
get(int index)
Returns the index th element of the vector. |
DisposableIntIterator |
getIterator()
|
int |
getTimeStamp()
|
int |
getType()
|
boolean |
isEmpty()
Checks if the vector is empty. |
long |
quickGet(int index)
access an element without any bound check |
long |
quickSet(int index,
long val)
Assigns a new value val to the element indexth and return the old value without bound check |
void |
remove(int i)
Removes an int. |
void |
removeLast()
removes the search at the end of the vector. |
long |
set(int index,
long val)
Assigns a new value val to the element index . |
int |
size()
Returns the current size of the stored search vector. |
int[] |
toArray(int[] tab)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final int MIN_CAPACITY
Constructor Detail |
---|
public RcLongVector(EnvironmentCopying env, int initialSize, long initialValue)
env
- The current environment.initialSize
- The initial size.initialValue
- The initial common value.public RcLongVector(EnvironmentCopying env, long[] entries)
public RcLongVector(EnvironmentCopying env)
env
- The current environment.Method Detail |
---|
public int size()
size
in interface IStateLongVector
public boolean isEmpty()
isEmpty
in interface IStateLongVector
public void ensureCapacity(int minCapacity)
minCapacity
- the necessary capacity.public void add(long i)
add
in interface IStateLongVector
i
- The search to add.public void removeLast()
removeLast
in interface IStateLongVector
public long get(int index)
index
th element of the vector.
get
in interface IStateLongVector
public long quickGet(int index)
IStateLongVector
quickGet
in interface IStateLongVector
public boolean contain(long val)
contain
in interface IStateLongVector
public long set(int index, long val)
val
to the element index
.
set
in interface IStateLongVector
public long quickSet(int index, long val)
IStateLongVector
quickSet
in interface IStateLongVector
index
- the index where the value is modifiedval
- the new value
public int[] toArray(int[] tab)
public void remove(int i)
IStateLongVector
remove
in interface IStateLongVector
i
- The search to remove.public void _set(long[] vals)
public void _set(long[] vals, int timeStamp)
public long[] deepCopy()
public int getType()
getType
in interface RecomputableElement
public int getTimeStamp()
getTimeStamp
in interface RecomputableElement
public DisposableIntIterator getIterator()
getIterator
in interface IStateLongVector
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |