32 #include <casacore/casa/aips.h> 33 #include <casacore/tables/TaQL/MArrayBase.h> 69 class MArray:
public MArrayBase
116 itsArray.reference (other.itsArray);
132 template <
typename U>
136 convertArray (
itsArray, from.array());
143 template <
typename U>
172 mask()(start, end, stride));
197 " of output buffer is too small");
211 iter!=iterEnd; ++iter, ++miter) {
212 if (!*miter) out[nr++] = *iter;
218 iter!=iterEnd; ++iter, ++miter) {
219 if (!*miter) out[nr++] = *iter;
A Vector of integers, for indexing into Array<T> objects.
Bool isNull() const
Is the array null?
A 1-D Specialization of the Array class.
MArray< T > operator()(const IPosition &start, const IPosition &end, const IPosition &stride)
Get a subset of the array.
MArray(const Array< T > &array, const MArrayBase &marray)
Construct from an array with the mask and null from another MArray.
Class to handle an Array with an optional mask.
void resizeBase(const ArrayBase &arr, Bool useMask)
Set the array shape and resize the mask.
MArray(const MArray< T > &array, const MArray< Bool > &mask)
Construct from two MArrays, one the array, the other the mask.
const IPosition & shape() const
The length of each axis.
Vector< T > flatten() const
Flatten the unmasked elements of the array to a vector.
MArray(const Array< T > &array)
Construct from an array without a mask.
The base class for all Array exception classes.
void reference(const MArray< T > &other)
Reference another array.
iterator begin()
Get the begin iterator object for any array.
TableExprNode marray(const TableExprNode &array, const TableExprNode &mask)
Form a masked array.
void setBase(const ArrayBase &arr, const Array< Bool > &mask)
Reference the mask and set the shape.
contiter cbegin()
Get the begin iterator object for a contiguous array.
const Array< Bool > & mask() const
Get the mask.
T * data()
Get a pointer to the beginning of the array.
Int64 nvalid() const
Return the number of valid array values, thus unflagged elements.
Bool contiguousStorage() const
Are the array data contiguous? If they are not contiguous, getStorage (see below) needs to make a cop...
const Array< T > & array() const
Get access to the array.
bool Bool
Define the standard types used by Casacore.
MArray(const Array< T > &array, const Array< Bool > &mask, Bool isNull=False)
Construct from an array and a mask.
void referenceBase(const MArrayBase &other)
Reference another MArray.
size_t size() const
Get the size.
void resize(const IPosition &shape, Bool useMask)
Resize the array and optionally the mask.
template <class T, class U> class vector;
const IPosition & shape() const
Get the shape.
Share means that the Array will just use the pointer (no copy), however the Array will NOT delete it ...
Bool hasMask() const
Is there a mask?
void fill(const MArray< U > &from)
Copy the array data and possible mask from another one.
Base class for an array with an optional mask.
void fill(const Array< U > &from)
Copy the array from a normal Array.
MArray()
Default constructor creates a null array.
this file contains all the compiler specific defines
static String toString(const T &value)
Convert a value to a String.