88 template<
class T>
class Vector :
public Array<T>
99 Vector(
const IPosition&
Length, ArrayInitPolicy initPolicy);
113 explicit Vector(
const Block<T> &other);
116 Vector(
const Vector<T> &other);
122 Vector(
const Array<T> &other);
137 template <
class U,
class V>
138 Vector(
const vector<U, V> &other);
146 template<
typename Iterator>
154 virtual void assign (
const Array<T>& other);
157 virtual void reference(
const Array<T> &other);
166 using Array<T>::resize;
213 #if defined(AIPS_ARRAY_INDEX_CHECK)
221 #if defined(AIPS_ARRAY_INDEX_CHECK)
316 extern template class Vector<Bool>;
317 extern template class Vector<Char>;
318 extern template class Vector<Short>;
319 extern template class Vector<uShort>;
320 extern template class Vector<Int>;
321 extern template class Vector<uInt>;
322 extern template class Vector<Int64>;
323 extern template class Vector<Float>;
324 extern template class Vector<Double>;
325 extern template class Vector<Complex>;
326 extern template class Vector<DComplex>;
327 extern template class Vector<String>;
332 #ifndef CASACORE_NO_AUTO_TEMPLATES
333 #include <casacore/casa/Arrays/Vector.tcc>
334 #include <casacore/casa/Arrays/Vector2.tcc>
335 #endif //# CASACORE_NO_AUTO_TEMPLATES
Bool contiguous_p
Are the data contiguous?
A Vector of integers, for indexing into Array<T> objects.
T & operator[](size_t index)
Single-pixel addressing.
A 1-D Specialization of the Array class.
long long Int64
Define the extra non-standard types used by Casacore (like proposed uSize, Size)
std::vector< double > Vector
Vector()
A zero-length Vector.
const T & operator[](size_t index) const
size_t nelements() const
How many elements does this array have? Product of all axis lengths.
LatticeExprNode mask(const LatticeExprNode &expr)
This function returns the mask of the given expression.
TableExprNode marray(const TableExprNode &array, const TableExprNode &mask)
Form a masked array.
A global enum used by some Array/Block constructors.
IPosition length_p
Used to hold the shape, increment into the underlying storage and originalLength of the array...
Array< T > operator()(const IPosition &blc, const IPosition &trc)
virtual void doNonDegenerate(const Array< T > &other, const IPosition &ignoreAxes)
Remove the degenerate axes from other and store result in this vector.
const Array< T > operator()(const IPosition &blc, const IPosition &trc) const
Class for masking an Array for operations on that Array.
void validateIndex(const IPosition &) const
void toBlock(Block< T > &other) const
Convert a Vector to a Block, resizing the block and copying values.
Array< T > & operator=(const T &val)
Set every element of this Vector to Val.
Array< T > operator()(const IPosition &blc, const IPosition &trc, const IPosition &incr)
Slice using IPositions.
Vector< T > & operator=(const Vector< T > &other)
Assign to this Vector.
virtual void assign(const Array< T > &other)
Assign the other array (which must be of dimension one) to this vector.
define a (start,length,increment) along an axis
virtual Array< T > & operator=(const Array< T > &other)
Copy the values in other to this.
const IPosition & shape() const
The length of the Vector.
void initVector(const Block< T > &, Int64 nr)
Helper functions for constructors.
T & operator()(const IPosition &)
Access a single element of the array.
T & operator()(size_t index)
bool Bool
Define the standard types used by Casacore.
virtual ~Vector()
Define a destructor, otherwise the compiler makes a static one.
virtual void resize()
Make this array a different shape.
T * begin_p
This pointer is adjusted to point to the first element of the array.
virtual void preTakeStorage(const IPosition &shape)
pre/post processing hook of takeStorage() for subclasses.
template <class T, class U> class vector;
Array< T > operator()(const Slicer &slicer)
Specify which elements to extract from an n-dimensional array.
virtual Bool ok() const
Verify that dimensionality is 1 and then call Array<T>::ok()
const T & operator()(const IPosition &i) const
void resize(size_t len, Bool copyValues, ArrayInitPolicy policy)
COPY is used when an internal copy of the storage is to be made.
StorageInitPolicy
A global enum used by some Array constructors.
void resize(size_t len, Bool copyValues=False)
virtual void reference(const Array< T > &other)
Create a reference to "other", which must be of dimension one.
const T & operator()(size_t index) const
Class for those physical parameters having dimensions of Length [L].
T & operator()(const IPosition &i)
const Array< T > operator()(const IPosition &blc, const IPosition &trc, const IPosition &incr) const
const Array< T > operator()(const Slicer &slicer) const
void shape(Int &Shape) const
#define casacore
<X11/Intrinsic.h> #defines true, false, casacore::Bool, and String.