casa  5.7.0-16
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Member Functions | Private Member Functions | Private Attributes | List of all members
casacore::ColumnSlicer Class Reference

#include <ArrayColumn.h>

Public Member Functions

 ColumnSlicer (const IPosition &shape, Vector< Slicer * > dataSlicers, Vector< Slicer * > destinationSlicers)
 Create a ColumnSlicer for use in one of the overloads of ArrayColumn::getColumnCells. More...
 
 ~ColumnSlicer ()
 Kill off the Slicer objects. More...
 
const Vector< Slicer * > & getDataSlicers () const
 Accessor that returns the dataSlicers. More...
 
const Vector< Slicer * > & getDestinationSlicers () const
 Accessor that returns the desintation slicers. More...
 
const IPositionshape () const
 Accessor that returns the shape. More...
 

Private Member Functions

void freeSlicers ()
 
String validateParameters ()
 

Private Attributes

Vector< Slicer * > dataSlicers_p
 
Vector< Slicer * > destinationSlicers_p
 
IPosition shape_p
 

Detailed Description

Definition at line 499 of file ArrayColumn.h.

Constructor & Destructor Documentation

casacore::ColumnSlicer::ColumnSlicer ( const IPosition shape,
Vector< Slicer * >  dataSlicers,
Vector< Slicer * >  destinationSlicers 
)
inline

Create a ColumnSlicer for use in one of the overloads of ArrayColumn::getColumnCells.

That method takes a potentially complex select of data out of a column cell (e.g., multiple slices along each axis) and then puts them into a selection of a destination array. This is most easily represnted as a set of source,destination slicers where one is applied to the cell and the other to the destination array.

The shape paramter is the shape of the destination excluding the row axis.

The Slicer objects provided (by pointer) will be owned by the ColumnSlicer object which will delete them in its destructor.

Definition at line 517 of file ArrayColumn.h.

References casacore::String::empty(), freeSlicers(), and validateParameters().

casacore::ColumnSlicer::~ColumnSlicer ( )
inline

Kill off the Slicer objects.

Definition at line 533 of file ArrayColumn.h.

References freeSlicers().

Member Function Documentation

void casacore::ColumnSlicer::freeSlicers ( )
inlineprivate

The two Vectors contain pointers to objects so they need to be freed. They should have the same length normally, but during validation it's possible that they have different lengths.

Definition at line 561 of file ArrayColumn.h.

References dataSlicers_p, and destinationSlicers_p.

Referenced by ColumnSlicer(), and ~ColumnSlicer().

const Vector<Slicer *>& casacore::ColumnSlicer::getDataSlicers ( ) const
inline

Accessor that returns the dataSlicers.

Definition at line 540 of file ArrayColumn.h.

References dataSlicers_p.

const Vector<Slicer *>& casacore::ColumnSlicer::getDestinationSlicers ( ) const
inline

Accessor that returns the desintation slicers.

Definition at line 547 of file ArrayColumn.h.

References destinationSlicers_p.

const IPosition& casacore::ColumnSlicer::shape ( ) const
inline

Accessor that returns the shape.

Definition at line 554 of file ArrayColumn.h.

References shape_p.

String casacore::ColumnSlicer::validateParameters ( )
inlineprivate

Validate the contruction parameters to see if they are consistent.

Definition at line 576 of file ArrayColumn.h.

References dataSlicers_p, destinationSlicers_p, casacore::String::format(), casacore::length(), and casacore::toString().

Referenced by ColumnSlicer().

Member Data Documentation

Vector<Slicer *> casacore::ColumnSlicer::dataSlicers_p
private

Definition at line 603 of file ArrayColumn.h.

Referenced by freeSlicers(), getDataSlicers(), and validateParameters().

Vector<Slicer *> casacore::ColumnSlicer::destinationSlicers_p
private

Definition at line 604 of file ArrayColumn.h.

Referenced by freeSlicers(), getDestinationSlicers(), and validateParameters().

IPosition casacore::ColumnSlicer::shape_p
private

Definition at line 605 of file ArrayColumn.h.

Referenced by shape().


The documentation for this class was generated from the following file: