Go to the documentation of this file.
79 const T*
begin(
void)
const;
83 const T*
end(
void)
const;
137 int size(
void)
const;
167 template<
class Char,
class Traits,
class T>
168 std::basic_ostream<Char,Traits>&
198 assert((
i>=0) && (
i<
n));
205 assert((
i>=0) && (
i<
n));
257 assert(
object() == NULL);
264 assert(
object() != NULL);
265 return (*
static_cast<SAO*
>(
object()))[
i];
271 assert(
object() != NULL);
272 return (*
static_cast<SAO*
>(
object()))[
i];
280 if (
object()==sa.
object())
283 if ((*
this)[
i] != sa[
i])
293 for (
int i=0;
i<
a.size();
i++)
300 assert(
object() != NULL);
301 return static_cast<SAO*
>(object())->
size();
307 assert(
object() != NULL);
308 return static_cast<SAO*
>(object())->begin();
314 assert(
object() != NULL);
315 return static_cast<SAO*
>(object())->begin();
321 assert(
object() != NULL);
322 return static_cast<SAO*
>(object())->end();
328 assert(
object() != NULL);
329 return static_cast<SAO*
>(object())->end();
335 assert(
object() != NULL);
342 assert(
object() != NULL);
349 assert(
object() != NULL);
356 assert(
object() != NULL);
360 template<
class Char,
class Traits,
class T>
361 std::basic_ostream<Char,Traits>&
364 std::basic_ostringstream<Char,Traits> s;
365 s.copyfmt(os); s.width(0);
369 for (
int i=1;
i<
x.size();
i++)
373 return os << s.str();
Post propagator for SetVar x
const typedef T * const_pointer
Type of a read-only pointer to the value type.
T & reference
Type of a reference to the value type.
unsigned int size(I &i)
Size of all ranges of range iterator i.
int size(void) const
Return number of elements.
const typedef T * const_iterator
Type of the iterator used to iterate read-only through this array's elements.
std::reverse_iterator< T * > reverse_iterator
Type of the iterator used to iterate backwards through this array's elements.
std::reverse_iterator< const T * > const_reverse_iterator
Type of the iterator used to iterate backwards and read-only through this array's elements.
T * begin(void)
Return beginning of array (for iterators)
T * iterator
Type of the iterator used to iterate through this array's elements.
virtual ~SAO(void)
Delete object.
SharedHandle::Object * object(void) const
Access to the shared object.
reverse_iterator rend(void)
Return a reverse iterator past the beginning of the array.
SharedArray(void)
Construct as not yet intialized.
T * alloc(long unsigned int n)
Allocate block of n objects of type T from heap.
Gecode toplevel namespace
iterator begin(void)
Return an iterator at the beginning of the array.
void init(int n)
Initialize as array with n elements.
std::basic_ostream< Char, Traits > & operator<<(std::basic_ostream< Char, Traits > &os, const FloatView &x)
Print float variable view.
Node * x
Pointer to corresponding Boolean expression node.
T & operator[](int i)
Access element at position i.
reverse_iterator rbegin(void)
Return a reverse iterator at the end of the array.
T * end(void)
Return end of array (for iterators)
Base-class for argument arrays.
bool operator==(const SharedArray< T > &sa) const
Test equality with sa.
struct Gecode::@602::NNF::@65::@67 a
For atomic nodes.
Heap heap
The single global heap.
T & operator[](int i)
Access element at position i.
SAO(int n)
Allocate for n elements.
void free(T *b, long unsigned int n)
Delete n objects starting at b.
int size(void) const
Return number of elements.
iterator end(void)
Return an iterator past the end of the array.
T * pointer
Type of a pointer to the value type.
Shared array with arbitrary number of elements.
int n
Number of negative literals for node type.
Gecode::IntArgs i({1, 2, 3, 4})
Implementation of object for shared arrays.
Archive & operator<<(Archive &e, FloatNumBranch nl)
T value_type
Type of the view stored in this array.
const typedef T & const_reference
Type of a constant reference to the value type.
bool operator==(const FloatVal &x, const FloatVal &y)