#include <DataTypeChanger.h>
Public Member Functions | |
DataTypeChanger (CDMDataType oldType) | |
DataTypeChanger (CDMDataType oldType, double oldFill, double oldScale, double oldOffset, CDMDataType newType, double newFill, double newScale, double newOffset, double unitScale=1., double unitOffset=0.) | |
virtual | ~DataTypeChanger () |
boost::shared_ptr< Data > | convertData (boost::shared_ptr< Data >) const throw (CDMException) |
CDMDataType | getDataType () const |
MetNoFimex::DataTypeChanger::DataTypeChanger | ( | CDMDataType | oldType | ) | [explicit] |
initialize data with the oldType convertData will do nothing in this case
MetNoFimex::DataTypeChanger::DataTypeChanger | ( | CDMDataType | oldType, | |
double | oldFill, | |||
double | oldScale, | |||
double | oldOffset, | |||
CDMDataType | newType, | |||
double | newFill, | |||
double | newScale, | |||
double | newOffset, | |||
double | unitScale = 1. , |
|||
double | unitOffset = 0. | |||
) | [explicit] |
initialize with the old and new settings
oldType | datatype of original data | |
oldFill | fill value of the original data | |
oldScale | scale_factor of the original data | |
oldOffset | scale_factor of the original data | |
newType | datatype of converted data | |
newFill | fill value of converted data | |
newScale | scale_factor of the converted data | |
newOffset | add_offset of the converted data | |
unitScale | scale_factor for the unpacked data, i.e. for unit changes, default 1. | |
unitOffset | offset for the unpacked data, i.e. for unit changes, default 0. |
virtual MetNoFimex::DataTypeChanger::~DataTypeChanger | ( | ) | [virtual] |
boost::shared_ptr<Data> MetNoFimex::DataTypeChanger::convertData | ( | boost::shared_ptr< Data > | ) | const throw (CDMException) |
convert the data to the new scale/fill/offset
CDMDataType MetNoFimex::DataTypeChanger::getDataType | ( | ) | const |
return the datatype of the converted data