|
Isis 3.0 Object Programmers' Reference |
Home |
#include <CubeAttribute.h>
Inheritance diagram for Isis::CubeAttributeOutput:


This class provides parsing and manipulation of attributes associated with output cube filenames. Output cube filenames can have an attributes of "minimum:maximum", "pixel type", "file format", "byte order", and "label placement"
For internal use only.
Definition at line 368 of file CubeAttribute.h.
Public Member Functions | |
| CubeAttributeOutput () | |
| Constructs an empty CubeAttributeOutput. | |
| CubeAttributeOutput (const Isis::iString &att) | |
| Constructs a CubeAttributeOutput and initialized it with the contents of the string parameter. | |
| ~CubeAttributeOutput () | |
| Destroys the object. | |
| bool | PropagatePixelType () const |
| Return true if the pixel type is to be propagated from an input cube. | |
| bool | PropagateMinimumMaximum () const |
| Return true if the min/max are to be propagated from an input cube. | |
| void | Set (const std::string &att) |
| Set the output attributes according to the argument. | |
| void | Reset () |
| Set the output attributes to the default state. | |
| std::string | FileFormatStr () const |
| Return the file format as a string. | |
| Isis::CubeFormat | FileFormat () const |
| Return the file format an Isis::CubeFormat. | |
| void | Format (const Isis::CubeFormat fmt) |
| Set the format to the fmt parameter. | |
| std::string | ByteOrderStr () const |
| Return the byte order as a string. | |
| Isis::ByteOrder | ByteOrder () const |
| Return the byte order as an Isis::ByteOrder. | |
| void | Order (const Isis::ByteOrder order) |
| Set the order according to the parameter order. | |
| double | Minimum () const |
| Return the output cube attribute minimum. | |
| double | Maximum () const |
| Return the output cube attribute maximum. | |
| void | Minimum (const double min) |
| Set the output cube attribute minimum. | |
| void | Maximum (const double max) |
| Set the output cube attribute maximum. | |
| Isis::PixelType | PixelType () const |
| Return the pixel type as an Isis::PixelType. | |
| void | Label (Isis::LabelAttachment attachment) |
| Set the label attachment type to the parameter value. | |
| bool | AttachedLabel () const |
| Return true if the attachement type is "Attached". | |
| bool | DetachedLabel () const |
| Return true if the attachement type is "Detached". | |
| void | PixelType (const Isis::PixelType type) |
| Set the pixel type to that given by the parameter. | |
| void | Write (std::ostream &ostr) const |
| Write the output attributes to a stream. | |
| void | Write (std::string &str) const |
| Write the output attributes to a string. | |
| void | Write (Isis::Pvl &pvl) const |
| Write the output attributes to a Pvl. | |
Protected Attributes | |
| Isis::iString | p_attribute |
| Contains the unparsed attributes with the filename stripped. | |
Private Member Functions | |
| void | Parse (const std::string &att) |
| Parse the string parameter and populate the private member variables accordingly. | |
| void | Initialize () |
| Initialize the output cube attribute to default values. | |
Private Attributes | |
| Isis::PixelType | p_pixelType |
| Stores the pixel type. | |
| std::string | p_pixelTypeDef |
| Stores weather the p_pixelType has been set or should be propagated from an input cube. | |
| Isis::RangeType | p_rangeType |
| Stores weather the pixel range has been set or should be propagated from an input cube. | |
| double | p_minimum |
| Stores the minimum for the output cube attribute. | |
| double | p_maximum |
| Stores the maximum for the output cube attribute. | |
| Isis::CubeFormat | p_format |
| Store the cube format. | |
| Isis::ByteOrder | p_order |
| Store the byte order for the cube attribute. | |
| Isis::LabelAttachment | p_labelAttachment |
| Store the type of label attachment. | |
| Isis::CubeAttributeOutput::CubeAttributeOutput | ( | ) |
Constructs an empty CubeAttributeOutput.
Definition at line 215 of file CubeAttribute.cpp.
References Initialize().
| Isis::CubeAttributeOutput::CubeAttributeOutput | ( | const Isis::iString & | att | ) |
Constructs a CubeAttributeOutput and initialized it with the contents of the string parameter.
The string is parased to obtain any min/max, pixel type, byte order, file format or label placement. Any attribute information that is not valie for an output cube will throw an error.
| att | A string containing the file attributes. All characters before the first "+" are assumed to be the filename and are ignored. |
Definition at line 220 of file CubeAttribute.cpp.
References Initialize(), Isis::CubeAttribute::p_attribute, and Parse().
| Isis::CubeAttributeOutput::~CubeAttributeOutput | ( | ) |
| bool Isis::CubeAttributeOutput::AttachedLabel | ( | ) | const [inline] |
Return true if the attachement type is "Attached".
Definition at line 464 of file CubeAttribute.h.
References Isis::AttachedLabel, and p_labelAttachment.
Referenced by Isis::GuiOutputAttribute::SetAttributes(), and Isis::Process::SetOutputCube().
| Isis::ByteOrder Isis::CubeAttributeOutput::ByteOrder | ( | ) | const |
Return the byte order as an Isis::ByteOrder.
Definition at line 302 of file CubeAttribute.cpp.
References p_order.
Referenced by Isis::GuiOutputAttribute::SetAttributes(), and Isis::Process::SetOutputCube().
| string Isis::CubeAttributeOutput::ByteOrderStr | ( | ) | const |
Return the byte order as a string.
Definition at line 297 of file CubeAttribute.cpp.
References Isis::ByteOrderName(), and p_order.
Referenced by Write().
| bool Isis::CubeAttributeOutput::DetachedLabel | ( | ) | const [inline] |
Return true if the attachement type is "Detached".
Definition at line 467 of file CubeAttribute.h.
References Isis::DetachedLabel, and p_labelAttachment.
Referenced by Isis::Process::SetOutputCube().
| Isis::CubeFormat Isis::CubeAttributeOutput::FileFormat | ( | ) | const |
Return the file format an Isis::CubeFormat.
Definition at line 242 of file CubeAttribute.cpp.
References p_format.
Referenced by Isis::GuiOutputAttribute::SetAttributes(), and Isis::Process::SetOutputCube().
| string Isis::CubeAttributeOutput::FileFormatStr | ( | ) | const |
Return the file format as a string.
Definition at line 237 of file CubeAttribute.cpp.
References Isis::CubeFormatName(), and p_format.
Referenced by Write().
| void Isis::CubeAttributeOutput::Format | ( | const Isis::CubeFormat | fmt | ) |
Set the format to the fmt parameter.
Definition at line 247 of file CubeAttribute.cpp.
References p_format.
| void Isis::CubeAttributeOutput::Initialize | ( | ) | [private] |
Initialize the output cube attribute to default values.
Definition at line 449 of file CubeAttribute.cpp.
References Isis::PvlObject::FindGroup(), Isis::IsLsb(), Isis::LabelAttachmentEnumeration(), p_format, p_labelAttachment, p_maximum, p_minimum, p_order, p_pixelType, p_pixelTypeDef, p_rangeType, Isis::Preference::Preferences(), and Isis::PropagateRange.
Referenced by CubeAttributeOutput(), and Reset().
| void Isis::CubeAttributeOutput::Label | ( | Isis::LabelAttachment | attachment | ) | [inline] |
Set the label attachment type to the parameter value.
Definition at line 461 of file CubeAttribute.h.
References p_labelAttachment.
| void Isis::CubeAttributeOutput::Maximum | ( | const double | max | ) |
Set the output cube attribute maximum.
Definition at line 268 of file CubeAttribute.cpp.
References p_maximum, p_rangeType, and Isis::RangeSet.
| double Isis::CubeAttributeOutput::Maximum | ( | ) | const |
Return the output cube attribute maximum.
Definition at line 257 of file CubeAttribute.cpp.
References p_maximum.
Referenced by Isis::GuiOutputAttribute::SetAttributes(), Isis::ProcessImport::SetOutputCube(), and Isis::Process::SetOutputCube().
| void Isis::CubeAttributeOutput::Minimum | ( | const double | min | ) |
Set the output cube attribute minimum.
Definition at line 262 of file CubeAttribute.cpp.
References p_minimum, p_rangeType, and Isis::RangeSet.
| double Isis::CubeAttributeOutput::Minimum | ( | ) | const |
Return the output cube attribute minimum.
Definition at line 252 of file CubeAttribute.cpp.
References p_minimum.
Referenced by Isis::GuiOutputAttribute::SetAttributes(), Isis::ProcessImport::SetOutputCube(), and Isis::Process::SetOutputCube().
| void Isis::CubeAttributeOutput::Order | ( | const Isis::ByteOrder | order | ) |
Set the order according to the parameter order.
Definition at line 307 of file CubeAttribute.cpp.
References p_order.
| void Isis::CubeAttributeOutput::Parse | ( | const std::string & | att | ) | [private] |
Parse the string parameter and populate the private member variables accordingly.
| att |
Definition at line 356 of file CubeAttribute.cpp.
References Isis::AttachedLabel, Isis::DetachedLabel, p_format, p_labelAttachment, p_maximum, p_minimum, p_order, p_pixelType, p_pixelTypeDef, p_rangeType, pos, Isis::RangeSet, str, Isis::iString::ToDouble(), and Isis::iString::Token().
Referenced by CubeAttributeOutput(), and Set().
| void Isis::CubeAttributeOutput::PixelType | ( | const Isis::PixelType | type | ) |
Set the pixel type to that given by the parameter.
Definition at line 286 of file CubeAttribute.cpp.
References p_pixelType, and p_pixelTypeDef.
| Isis::PixelType Isis::CubeAttributeOutput::PixelType | ( | ) | const |
Return the pixel type as an Isis::PixelType.
Definition at line 274 of file CubeAttribute.cpp.
References _FILEINFO_, Isis::iException::Message(), and p_pixelType.
Referenced by Isis::GuiOutputAttribute::SetAttributes(), Isis::ProcessImport::SetOutputCube(), and Isis::Process::SetOutputCube().
| bool Isis::CubeAttributeOutput::PropagateMinimumMaximum | ( | ) | const [inline] |
Return true if the min/max are to be propagated from an input cube.
Definition at line 402 of file CubeAttribute.h.
References p_rangeType, and Isis::PropagateRange.
Referenced by Isis::GuiOutputAttribute::SetAttributes(), Isis::ProcessImport::SetOutputCube(), and Isis::Process::SetOutputCube().
| bool Isis::CubeAttributeOutput::PropagatePixelType | ( | ) | const [inline] |
Return true if the pixel type is to be propagated from an input cube.
Definition at line 394 of file CubeAttribute.h.
References p_pixelTypeDef.
Referenced by Isis::GuiOutputAttribute::SetAttributes(), Isis::ProcessImport::SetOutputCube(), and Isis::Process::SetOutputCube().
| void Isis::CubeAttributeOutput::Reset | ( | ) |
Set the output attributes to the default state.
Definition at line 351 of file CubeAttribute.cpp.
References Initialize().
Referenced by IsisAml::Clear(), and IsisAml::GetOutputAttribute().
| void Isis::CubeAttributeOutput::Set | ( | const std::string & | att | ) |
Set the output attributes according to the argument.
Note: the attributes are not initialized prior to parsing the argument. This means that multipal invocations will be cumulative.
| att | A string containing the file attributes. All characters before the first "+" are assumed to be the filename and are ignored. |
Definition at line 232 of file CubeAttribute.cpp.
References Parse().
Referenced by IsisAml::Clear(), and IsisAml::GetOutputAttribute().
| void Isis::CubeAttributeOutput::Write | ( | Isis::Pvl & | pvl | ) | const [virtual] |
Write the output attributes to a Pvl.
Reimplemented from Isis::CubeAttribute.
Definition at line 333 of file CubeAttribute.cpp.
References ByteOrderStr(), FileFormatStr(), Isis::LabelAttachmentName(), p_labelAttachment, p_maximum, p_minimum, p_pixelType, p_pixelTypeDef, Isis::PixelTypeName(), and pvl().
| void Isis::CubeAttributeOutput::Write | ( | std::string & | str | ) | const [virtual] |
Write the output attributes to a string.
Reimplemented from Isis::CubeAttribute.
Definition at line 319 of file CubeAttribute.cpp.
References ByteOrderStr(), FileFormatStr(), Isis::LabelAttachmentName(), p_labelAttachment, p_maximum, p_minimum, p_pixelType, p_pixelTypeDef, and Isis::PixelTypeName().
| void Isis::CubeAttributeOutput::Write | ( | std::ostream & | ostr | ) | const [virtual] |
Write the output attributes to a stream.
Reimplemented from Isis::CubeAttribute.
Definition at line 312 of file CubeAttribute.cpp.
References st.
Referenced by Isis::GuiOutputAttribute::GetAttributes().
Isis::iString Isis::CubeAttribute::p_attribute [protected, inherited] |
Contains the unparsed attributes with the filename stripped.
Definition at line 220 of file CubeAttribute.h.
Referenced by Isis::CubeAttribute::CubeAttribute(), Isis::CubeAttributeInput::CubeAttributeInput(), CubeAttributeOutput(), and Isis::CubeAttribute::Write().
Store the cube format.
Definition at line 499 of file CubeAttribute.h.
Referenced by FileFormat(), FileFormatStr(), Format(), Initialize(), and Parse().
Store the type of label attachment.
Definition at line 501 of file CubeAttribute.h.
Referenced by AttachedLabel(), DetachedLabel(), Initialize(), Label(), Parse(), and Write().
double Isis::CubeAttributeOutput::p_maximum [private] |
Stores the maximum for the output cube attribute.
Definition at line 498 of file CubeAttribute.h.
Referenced by Initialize(), Maximum(), Parse(), and Write().
double Isis::CubeAttributeOutput::p_minimum [private] |
Stores the minimum for the output cube attribute.
Definition at line 497 of file CubeAttribute.h.
Referenced by Initialize(), Minimum(), Parse(), and Write().
Store the byte order for the cube attribute.
Definition at line 500 of file CubeAttribute.h.
Referenced by ByteOrder(), ByteOrderStr(), Initialize(), Order(), and Parse().
Stores the pixel type.
Definition at line 483 of file CubeAttribute.h.
Referenced by Initialize(), Parse(), PixelType(), and Write().
std::string Isis::CubeAttributeOutput::p_pixelTypeDef [private] |
Stores weather the p_pixelType has been set or should be propagated from an input cube.
Definition at line 489 of file CubeAttribute.h.
Referenced by Initialize(), Parse(), PixelType(), PropagatePixelType(), and Write().
Stores weather the pixel range has been set or should be propagated from an input cube.
Definition at line 495 of file CubeAttribute.h.
Referenced by Initialize(), Maximum(), Minimum(), Parse(), and PropagateMinimumMaximum().