Go to the documentation of this file.
47 class Array :
public std::vector<base>
51 Array() : std::vector<base>() { };
78 std::fill(this->begin(),this->end(),fill);
86 std::fill(this->begin(),this->end(),x);
104 if ( 0==this->size() )
105 this->resize(A.size());
107 assert( this->size()==A.size() );
109 std::copy( A.begin(), A.end(), this->begin() );
117 size_t s = this->size();
119 return static_cast<INDEX
>(s);
129 return std::vector<base>::operator[](n);
139 return std::vector<base>::operator[](n);
157 for ( ; i!=end; ++i )
159 os <<
"\n" << setw(3) << *i;
175 for ( ; xi!=xe ; ++xi )
194 for ( ; xi!=xe ; ++xi )
base & operator[](Index n)
Non-constant index operator.
void copy(ConstIterator1D origin, const ConstIterator1D &end, Iterator1D target)
Copy data between begin and end to target.
This can be used to make arrays out of anything.
const base & operator[](Index n) const
Constant index operator.
Array & operator=(base x)
Assignment from base type (fill entire Array with this value).
INDEX Index
The type to use for all integer numbers and indices.
base max(const Array< base > &x)
Max function.
std::ostream & operator<<(std::ostream &os, const Array< base > &v)
Output operator.
Array & operator=(const Array< base > &A)
Assignment from another Array.
Array(const Array< base > &A)
Array(Index n, const base &fill)
Constructor filling with constant value.
base min(const Array< base > &x)
Min function.
Index nelem() const
Number of elements.
The global header file for ARTS.