casa
5.7.0-16
|
VBRemappers remap VisBuffers. More...
#include <VBRemapper.h>
Public Member Functions | |
VBRemapper () | |
Defaults to no remapping. More... | |
VBRemapper (const std::map< VisBufferComponents::EnumType, std::map< casacore::Int, casacore::Int > > &inToOutMaps) | |
Copy construct | VBRemapper (const VBRemapper &gw) |
Destructor *virtual | ~VBRemapper () |
virtual Assignment VBRemapper & | operator= (const VBRemapper &gw) |
*const std::map < VisBufferComponents::EnumType, std::map< casacore::Int, casacore::Int > > & | getMaps () const |
void | setMaps (const std::map< VisBufferComponents::EnumType, std::map< casacore::Int, casacore::Int > > &maps) |
casacore::Bool | remap (VisBuffer &vb, const casacore::Bool squawk=true) const |
Remaps vb and returns its success value. More... | |
Protected Member Functions | |
casacore::Bool | remapScalar (casacore::Int &colref, const std::map< casacore::Int, casacore::Int > &mapper) const |
Remaps col using mapper. More... | |
casacore::Bool | remapVector (casacore::Vector< casacore::Int > &col, const std::map< casacore::Int, casacore::Int > &mapper) const |
Protected Attributes | |
std::map < VisBufferComponents::EnumType, std::map< casacore::Int, casacore::Int > > | inToOutMaps_p |
Set of maps from input ID to output ID, keyed by VisBufferComponent. More... | |
VBRemappers remap VisBuffers.
Public interface
VBRemappers remap VisBuffers.
When selected parts of an casacore::MS are written to a new casacore::MS, it may be necessary to remap metadata indices like Field ID, DDID, ObservationID, etc..
DDIDs 1, 4, and 7, and field ID 3 is selected. They should become 0, 1, and 2, and 0, in the output.
Definition at line 67 of file VBRemapper.h.
casa::VBRemapper::VBRemapper | ( | ) |
Defaults to no remapping.
casa::VBRemapper::VBRemapper | ( | const std::map< VisBufferComponents::EnumType, std::map< casacore::Int, casacore::Int > > & | inToOutMaps | ) |
|
inline |
Definition at line 77 of file VBRemapper.h.
|
inlinevirtual |
Definition at line 80 of file VBRemapper.h.
|
inline |
Definition at line 85 of file VBRemapper.h.
References inToOutMaps_p.
|
inlinevirtual |
Definition at line 83 of file VBRemapper.h.
casacore::Bool casa::VBRemapper::remap | ( | VisBuffer & | vb, |
const casacore::Bool | squawk = true |
||
) | const |
Remaps vb and returns its success value.
|
protected |
Remaps col using mapper.
Returns false if col has a value that is not in mapper's keys (those values are left unchanged), true otherwise.
|
protected |
|
inline |
Definition at line 90 of file VBRemapper.h.
References inToOutMaps_p.
|
protected |
Set of maps from input ID to output ID, keyed by VisBufferComponent.
Definition at line 106 of file VBRemapper.h.