|
Isis Developer Reference
|
Go to the documentation of this file. 1 #ifndef ImportPdsTable_h
2 #define ImportPdsTable_h
12 #include <QStringList>
105 const QString &pdsTabFile=
"",
106 const QString &pdsTableName =
"TABLE");
109 QString
name()
const;
115 void load(
const QString &pdsLabFile,
const QString &pdsTabFile =
"",
116 const QString &pdsTableName =
"TABLE");
118 bool hasColumn(
const QString &colName)
const;
120 const bool &formatted =
true)
const;
124 QString
getType(
const QString &colName)
const;
125 bool setType(
const QString &colName,
const QString &dataType);
129 const QString &isisTableName);
131 const QString &isisTableName);
157 const QString &delimiter =
"")
const;
160 const QString &delimiter =
"")
const;
165 virtual bool processRow(
const int &row,
const QString &rowdata);
171 void loadLabel(
const QString &labfile, QString &tblfile,
172 const QString &tblname =
"");
173 void loadTable(
const QString &tabfile);
180 void setPdsByteOrder(QString byteOrder);
195 QString m_pdsTableType;
199 QString m_pdsTableFile;
QString getColumnName(const unsigned int &index=0, const bool &formatted=true) const
Returns the name of the specifed column.
Definition: ImportPdsTable.cpp:211
QStringList Columns
Definition: ImportPdsTable.h:147
Contains Pvl Groups and Pvl Objects.
Definition: PvlObject.h:61
Import a PDS table file with a label description.
Definition: ImportPdsTable.h:101
void load(const QString &pdsLabFile, const QString &pdsTabFile="", const QString &pdsTableName="TABLE")
Loads a PDS table label and (optional) data file.
Definition: ImportPdsTable.cpp:132
QString name() const
Returns the name of the file excluding the path and the attributes in the file name.
Definition: FileName.cpp:162
int m_items
Number of items in column.
Definition: ImportPdsTable.h:142
File name manipulation and expansion.
Definition: FileName.h:100
bool fileExists() const
Returns true if the file exists; false otherwise.
Definition: FileName.cpp:449
Definition: ImportPdsTable.h:135
const ColumnDescr & getColumnDescriptor(const int &nth) const
Retrieve a column description by index.
Definition: ImportPdsTable.cpp:614
int m_colnum
Column number.
Definition: ImportPdsTable.h:137
virtual bool processRow(const int &row, const QString &rowdata)
Process a freshly read PDS table line of data.
Definition: ImportPdsTable.cpp:1212
int m_startByte
Starting byte of data.
Definition: ImportPdsTable.h:139
int m_numBytes
Number bytes in column.
Definition: ImportPdsTable.h:140
int Fields() const
Returns the number of fields that are currently in the record.
Definition: TableRecord.cpp:78
Container for cube-like labels.
Definition: Pvl.h:119
int rows() const
Returns the number of rows in the table.
Definition: ImportPdsTable.cpp:1011
QString getFormattedName(const QString &colname) const
Converts a column name to a camel-case after it has been cleansed.
Definition: ImportPdsTable.cpp:759
QString getGenericType(const QString &ttype) const
Determine generic data type of a column.
Definition: ImportPdsTable.cpp:798
Definition: TableRecord.h:38
QString getColumnValue(const QString &tline, const ColumnDescr &cdesc, const QString &delimiter="") const
Extracts a column from a QString based upon a description.
Definition: ImportPdsTable.cpp:690
QString toString(bool boolToConvert)
Global function to convert a boolean to a string.
Definition: IString.cpp:211
ImportPdsTable()
Default constructor.
Definition: ImportPdsTable.cpp:43
virtual ~ImportPdsTable()
Destructs the ImportPdsTable object.
Definition: ImportPdsTable.cpp:84
QList< Columns > Rows
Definition: ImportPdsTable.h:148
bool setType(const QString &colName, const QString &dataType)
Change the datatype for a column.
Definition: ImportPdsTable.cpp:295
QString baseName() const
Returns the name of the file without the path and without extensions.
Definition: FileName.cpp:145
QString expanded() const
Returns a QString of the full file name including the file path, excluding the attributes.
Definition: FileName.cpp:196
@ Double
Definition: PixelType.h:36
#define _FILEINFO_
Macro for the filename and line number.
Definition: IException.h:24
int toInt(const QString &string)
Global function to convert from a string to an integer.
Definition: IString.cpp:93
Class for storing Table blobs information.
Definition: Table.h:61
Isis exception class.
Definition: IException.h:91
QStringList getColumnNames(const bool &formatted=true) const
Return the names of all the columns.
Definition: ImportPdsTable.cpp:242
Namespace for the standard library.
QString m_name
Name of column.
Definition: ImportPdsTable.h:136
QString m_dataType
PDS table DATA_TYPE of column.
Definition: ImportPdsTable.h:138
QStringList getColumnFields(const QString &tline, const ColumnDescr &cdesc, const QString &delimiter="") const
Extracts column fields from a QString based upon a description.
Definition: ImportPdsTable.cpp:712
Byte swapper.
Definition: EndianSwapper.h:38
Table importTable(const QString &isisTableName)
Populate a Table object with the PDS table and return it.
Definition: ImportPdsTable.cpp:318
QString name() const
Return the name of the PDS table.
Definition: ImportPdsTable.cpp:89
Adds specific functionality to C++ strings.
Definition: IString.h:165
bool hasColumn(const QString &colName) const
This method determines whether the PDS table has a column with the given name.
Definition: ImportPdsTable.cpp:186
ColumnDescr * findColumn(const QString &colName)
Searches internal column descriptors for a named column.
Definition: ImportPdsTable.cpp:642
int m_itemBytes
Number bytes per item.
Definition: ImportPdsTable.h:141
void setName(const QString &name="TABLE")
Set the name of the PDS table object.
Definition: ImportPdsTable.cpp:98
QString path() const
Returns the path of the file name.
Definition: FileName.cpp:103
This is free and unencumbered software released into the public domain.
Definition: Apollo.h:16
QString getType(const QString &colName) const
Get the type associated with the specified column.
Definition: ImportPdsTable.cpp:268
int columns() const
Returns the number of columns in the table.
Definition: ImportPdsTable.cpp:999
@ Real
Definition: PixelType.h:35
Class for storing an Isis::Table's field information.
Definition: TableField.h:47
QList< ColumnDescr > ColumnTypes
Definition: ImportPdsTable.h:146