const T & operator[](const int &i) const
get the i-th element Assert in (i>-1) Assert in (i
Definition: CORE_Array.h:121
T * getCompleteValues(int &s)
get the values of the complete vector
Definition: CORE_Array.h:403
int getCapacityFactor() const
get the capacity factor
Definition: CORE_Array.h:216
#define tBoolean
Definition: types.h:35
CORE_Array< tString > CORE_StringArray
Definition: CORE_Array.h:613
tBoolean exists(const T &obj) const
exists
Definition: CORE_Array.h:511
void setValues(const int &n, const T *array)
copy an array of T
Definition: CORE_Array.h:297
T * getValues(int &s)
get the values of the util vector
Definition: CORE_Array.h:389
int insert(const T &obj)
insert the object in increasing order
Definition: CORE_Array.h:449
CORE_Array< double > CORE_DoubleArray
Definition: CORE_Array.h:604
T & operator+=(const T &f)
operator +=
Definition: CORE_Array.h:166
#define null
Definition: types.h:13
const T * getCompleteValues(int &s) const
get the values of the complete vector
Definition: CORE_Array.h:396
CORE_Array< tCharacter > CORE_CharacterArray
Definition: CORE_Array.h:605
T & operator-=(const T &f)
operator -=
Definition: CORE_Array.h:172
CORE_Array< tDoubleComplex > CORE_DoubleComplexArray
Definition: CORE_Array.h:610
void reverse()
reverse the vector
Definition: CORE_Array.hpp:494
void append(const CORE_Array< T > &array)
merge the array in this
Definition: CORE_Array.h:465
void add(const T &obj)
add an element at the end re-allocate the array if capacity too small
Definition: CORE_Array.hpp:157
CORE_Array< tFlag > CORE_FlagArray
Definition: CORE_Array.h:611
static int search(const T *values, const int &n, const T &value, const tString &order)
search the value in values array ordered in order
Definition: CORE_Array.hpp:666
void setSize(const int &n)
set the size of the array
Definition: CORE_Array.hpp:141
T & operator=(const CORE_Array< T > &f)
operator =
Definition: CORE_Array.h:147
T norm2() const
get the norm
Definition: CORE_Array.h:567
void copy(const CORE_Array< T > *src)
void copy
Definition: CORE_Array.h:240
T norm() const
get the norm squared
Definition: CORE_Array.h:578
CORE_Array< tReal > CORE_RealArray
Definition: CORE_Array.h:608
CORE_Array< tBoolean > CORE_BooleanArray
Definition: CORE_Array.h:607
int size() const
return the size of the array
Definition: CORE_Array.h:223
virtual ~CORE_Array()
destroy an array of T*
Definition: CORE_Array.hpp:57
this class describes an array
Definition: CORE_Array.h:18
int insertInOrder(const T &obj, const tBoolean &evenIfEqual)
insert the object in increasing order
Definition: CORE_Array.hpp:337
CORE_Array< tRelativeInteger > CORE_RelativeIntegerArray
Definition: CORE_Array.h:615
int getStartIndex() const
get start index
Definition: CORE_Array.h:220
int getSize() const
return the size of the array
Definition: CORE_Array.h:226
void setValue(const int &i, const T &obj)
set the object at the index i
Definition: CORE_Array.h:346
const T * getValues(int &s) const
get the values of the util vector
Definition: CORE_Array.h:371
void getSharedPointer(SP::CORE_Object &p)
get the shared pointer of this class into p
Definition: CORE_Object.h:65
void setValuesByReference(const int &n, T *&array, const tBoolean &hasToBeDeleted)
set the the values by reference the values is destroyed at the end if hasToBeDeleted is true ...
Definition: CORE_Array.h:304
void sort()
sort the array in an increasing order
Definition: CORE_Array.h:540
T & operator*=(const T &f)
operator *=
Definition: CORE_Array.h:160
void copy(const CORE_Array< T > &src)
void copy
Definition: CORE_Array.hpp:64
CORE_Array()
build an array of T*
Definition: CORE_Array.hpp:29
const T & getValue(const int &i) const
get the value at index i Assert in (i>-1) Assert in (i
Definition: CORE_Array.h:199
CORE_Array< tInteger > CORE_IntegerArray
Definition: CORE_Array.h:614
int getInfIndex(const T &v) const
get the inf index of value return -1 if no value less than v
Definition: CORE_Array.hpp:404
tString toString() const
turn the array into string
Definition: CORE_Array.hpp:544
int insert(const int &i, const T &obj)
insert the object at index i re-allocate the array if capacity too small
Definition: CORE_Array.hpp:308
CORE_Array< int > CORE_IntArray
Definition: CORE_Array.h:606
void getSharedPointer(boost::shared_ptr< const CORE_Array< T > > &p) const
return the shared pointer corresponding to the class whith casting
Definition: CORE_Array.h:71
void initValues(const T &v)
init all values to v
Definition: CORE_Array.h:351
#define tString
Definition: types.h:36
T & operator/=(const T &f)
operator /=
Definition: CORE_Array.h:154
void sort(const tString &order)
sort the array
Definition: CORE_Array.h:545
void merge(const CORE_Array< T > &array)
merge the array in this
Definition: CORE_Array.hpp:507
void setCapacityFactor(const int &n)
set the capacity factor
Definition: CORE_Array.h:266
CORE_Array< tShort > CORE_ShortArray
Definition: CORE_Array.h:612
void resize()
resize the array to the util size
Definition: CORE_Array.hpp:107
T & operator()(const size_t &i)
Definition: CORE_Array.h:136
int getIndex(const T &v) const
get the index of value return -1 if no value in index
Definition: CORE_Array.hpp:380
CORE_Array< tComplex > CORE_ComplexArray
Definition: CORE_Array.h:609
void setValues(const tString &str)
Definition: CORE_Array.h:333
void setCapacity(const int &c)
set the capacity of the vector
Definition: CORE_Array.hpp:76
TYPEDEF_SVPTR(CORE_BooleanArray)
void setValues(const CORE_Array< T > &array, const int &fromIndex)
Definition: CORE_Array.hpp:201
CORE_Array< tLong > CORE_LongArray
Definition: CORE_Array.h:616
void setValues(const vector< T > &array)
Definition: CORE_Array.h:322
const T & operator()(const size_t &i) const
Definition: CORE_Array.h:140
#define ASSERT_IN(a)
Definition: types.h:82
void contractToLastElements(const int &n)
keep only the last n elements of the array and set its capacity also to n
Definition: CORE_Array.hpp:289
tBoolean removeAtIndex(const int &i)
Definition: CORE_Array.hpp:278
static boost::shared_ptr< CORE_Array< T > > New(const int &n)
return a CORE_Array shared pointer
Definition: CORE_Array.h:106
class Free introduced for deleting a smart pointer
Definition: CORE_Object.h:106
void addAfterIndices(const CORE_Array< int > &indices, CORE_SharedPointersList< CORE_Array< T > > &values)
add alements after indices
Definition: CORE_Array.hpp:568