54 if ((
t =
new i3_array[static_cast<unsigned int>(hsu - hsl + 1)]) == 0)
56 cerr <<
" Error: i4_array unable to allocate t in "
57 <<
"i4_array::allocate(int, int).\n";
62 cerr <<
" Error: i4_array unable to allocate shape in "
63 <<
"i4_array::allocate(int, int).\n";
67 for (
int i = hsl; i <= hsu; ++i)
82 allocate(hsl,hsu,sl,sh,nrl,nrh,ncl,nch);
103 allocate(hsl, hsu, sl, sh, nrl, nrh, ncl, nch);
154 static_cast<unsigned int>(hsu < hsl ? 0 : hsu - hsl + 1);
159 cerr <<
" Error: i4_array unable to allocate memory in "
160 << __FILE__ <<
':' << __LINE__ <<
'\n';
165 cerr <<
" Error: i4_array unable to allocate memory in "
166 << __FILE__ <<
':' << __LINE__ <<
'\n';
170 for (
int i = hsl; i <= hsu; ++i)
205 cerr <<
"Warning -- Unable to shallow copy an unallocated i4_array.\n";
235 cerr <<
"Warning -- Unable to deallocate an unallocated i4_array.\n";
Uses polymorphism to get index information from various data types to be used in constructing and all...
Description not yet available.
int allocated(const ivector &v)
Author: David Fournier Copyright (c) 2008-2012 Regents of the University of California.
void * get_truepointer(void)
Returns address of first element in the vector.
void allocate(int sl, int sh, int nrl, int nrh, const ivector &nc)
Description not yet available.
void deallocate(void)
Deallocate i4_array memory.
Array of integers(int) with indexes from index_min to indexmax.
void shallow_copy(const i4_array &)
Shallow copy other data structure pointers.
Author: David Fournier Copyright (c) 2008-2012 Regents of the University of California.
i4_array()
Default constructor.
unsigned int ncopies
Copy counter to enable shallow copies.
void allocate(void)
Author: David Fournier Copyright (c) 2008-2012 Regents of the University of California.
Holds "shape" information for vector objects.
void initialize(int sl, int sh, int nrl, const ivector &nrh, int ncl, const ivector &nch)
void initialize()
Initializes elements of i4_array to zero.
Description not yet available.