EleFits  4.0.0
A modern C++ API on top of CFitsIO
Public Member Functions | List of all members
Euclid::Fits::VecColumn< T > Class Template Reference

#include <Column.h>

Class Description

template<typename T>
class Euclid::Fits::VecColumn< T >

Column which stores internally the data.

Use it (via move semantics) if you don't need your data after the write operation.

See also
Data classes
Examples
EleFitsTutorial.cpp.
Inheritance diagram for Euclid::Fits::VecColumn< T >:
[legend]

Public Member Functions

virtual ~VecColumn ()=default
 Destructor.
 
 VecColumn (const VecColumn &)=default
 Copy constructor.
 
 VecColumn (VecColumn &&)=default
 Move constructor.
 
VecColumnoperator= (const VecColumn &)=default
 Copy assignment.
 
VecColumnoperator= (VecColumn &&)=default
 Move assignment.
 
 VecColumn ()
 Create an empty VecColumn.
 
 VecColumn (ColumnInfo< std::decay_t< T >> info, std::vector< T > vec)
 Crate a VecColumn with given data and metadata. More...
 
 VecColumn (ColumnInfo< std::decay_t< T >> info, long rowCount)
 Create a VecColumn with given metadata.
 
const std::vector< T > & vector () const
 Const reference to the vector data.
 
std::vector< std::decay_t< T > > & moveTo (std::vector< std::decay_t< T >> &destination)
 Move the vector outside the column. More...
 
- Public Member Functions inherited from Euclid::Fits::Column< T >
 Column (ColumnInfo< std::decay_t< T >> info)
 Create a column with given metadata.
 
virtual ~Column ()=default
 Destructor.
 
const ColumnInfo< std::decay_t< T > > & info () const
 Get the column metadata.
 
void rename (const std::string &name)
 Change the column name.
 
void reshape (long repeatCount=1)
 Change the column repeat count (fold/unfold). More...
 
long elementCount () const
 Number of elements in the column, i.e. repeat count * number of rows. More...
 
long rowCount () const
 Number of rows in the column.
 
const T * data () const
 Const pointer to the first data element. More...
 
T * data ()
 Pointer to the first data element.
 
const T & operator() (long row, long repeat=0) const
 Access the value at given row and repeat indices.
 
T & operator() (long row, long repeat=0)
 Access the value at given row and repeat indices. More...
 
const T & at (long row, long repeat=0) const
 Access the value at given row and repeat indices. More...
 
T & at (long row, long repeat=0)
 Access the value at given row and repeat indices. More...
 
const PtrColumn< const T > slice (const Segment &rows) const
 Get a view on contiguous rows.
 
PtrColumn< T > slice (const Segment &rows)
 Get a view on contiguous rows. More...
 

Additional Inherited Members

- Public Types inherited from Euclid::Fits::Column< T >
using Value = T
 The element value type.
 

The documentation for this class was generated from the following file:
std::move
T move(T... args)
std::vector
STL class.
Euclid::Fits::Column::info
const ColumnInfo< std::decay_t< T > > & info() const
Get the column metadata.
Euclid::Fits::VecColumn::VecColumn
VecColumn()
Create an empty VecColumn.
Euclid::Fits::Column::data
const T * data() const
Const pointer to the first data element.