NetCDFFilter

Manages the import/export of data from/to a NetCDF file.

Public Methods

void

NetCDFFilter()

const QString&

currentVarName() const

int

endColumn() const

int

endRow() const

QString

fileCDLString(const QString &)

QString

fileInfoString(const QString &)

bool

load(XmlStreamReader *) override

void

parse(const QString &fileName, QTreeWidgetItem *rootItem)

QString

readAttribute(const QString &fileName, const QString &name, const QString &varName)

QVector< QStringList >

readCurrentVar(const QString &fileName, AbstractDataSource *=nullptr, ImportMode=ImportMode::Replace, int lines=-1)

void

readDataFromFile(const QString &fileName, AbstractDataSource *=nullptr, ImportMode=ImportMode::Replace) override

void

save(QXmlStreamWriter *) const override

void

setCurrentVarName(const QString &)

void

setEndColumn(const int)

void

setEndRow(const int)

void

setStartColumn(const int)

void

setStartRow(const int)

int

startColumn() const

int

startRow() const

void

write(const QString &fileName, AbstractDataSource *) override

Detailed Description

class NetCDFFilter : public AbstractFileFilter

Manages the import/export of data from/to a NetCDF file.

Public Functions

void parse(const QString &fileName, QTreeWidgetItem *rootItem)

parses the content of the file ileName.

virtual void readDataFromFile(const QString &fileName, AbstractDataSource* = nullptr, ImportMode = ImportMode::Replace) override

reads the content of the file fileName to the data source dataSource.

QString readAttribute(const QString &fileName, const QString &name, const QString &varName)

reads the content of the selected attribute from file fileName.

QVector<QStringList> readCurrentVar(const QString &fileName, AbstractDataSource* = nullptr, ImportMode = ImportMode::Replace, int lines = -1)

reads the content of the current variable from file fileName.

virtual void write(const QString &fileName, AbstractDataSource*) override

writes the content of the data source dataSource to the file fileName.

virtual void save(QXmlStreamWriter*) const override

Saves as XML.

virtual bool load(XmlStreamReader*) override

Loads from XML.

Public Static Functions

static QString fileCDLString(const QString&)

Get file content in CDL (Common Data form Language) format uses “ncdump”