labplot  2.8.2
About: LabPlot is an application for plotting and analysis of 2D and 3D functions and data. It is a complete rewrite of LabPlot1 and lacks in the first release a lot of features available in the predecessor. On the other hand, the GUI and the usability is more superior.
  Fossies Dox: labplot-2.8.2.tar.gz  ("unofficial" and yet experimental doxygen-generated source code documentation)  

AbstractFileFilter Class Referenceabstract

Interface for the input/output file filters. More...

#include <AbstractFileFilter.h>

Inheritance diagram for AbstractFileFilter:
[legend]
Collaboration diagram for AbstractFileFilter:
[legend]

Public Types

enum class  FileType {
  Ascii , Binary , Image , HDF5 ,
  NETCDF , FITS , JSON , ROOT ,
  NgspiceRawAscii , NgspiceRawBinary
}
 
enum class  ImportMode { Append , Prepend , Replace }
 

Signals

void completed (int) const
 int ranging from 0 to 100 notifies about the status of a read/write process More...
 

Public Member Functions

 AbstractFileFilter (FileType type)
 
 ~AbstractFileFilter () override=default
 
virtual void readDataFromFile (const QString &fileName, AbstractDataSource *=nullptr, ImportMode=ImportMode::Replace)=0
 
virtual void write (const QString &fileName, AbstractDataSource *)=0
 
virtual void loadFilterSettings (const QString &filterName)=0
 
virtual void saveFilterSettings (const QString &filterName) const =0
 
virtual void save (QXmlStreamWriter *) const =0
 
virtual bool load (XmlStreamReader *)=0
 
FileType type () const
 

Static Public Member Functions

static bool isNan (const QString &)
 
static AbstractColumn::ColumnMode columnMode (const QString &valueString, const QString &dateTimeFormat, QLocale::Language)
 
static AbstractColumn::ColumnMode columnMode (const QString &valueString, const QString &dateTimeFormat, const QLocale &=QLocale())
 
static QString dateTimeFormat (const QString &valueString)
 
static QStringList numberFormats ()
 
static AbstractFileFilter::FileType fileType (const QString &)
 
static QStringList fileTypes ()
 

Protected Attributes

const FileType m_type
 

Detailed Description

Interface for the input/output file filters.

Definition at line 41 of file AbstractFileFilter.h.

Member Enumeration Documentation

◆ FileType

Enumerator
Ascii 
Binary 
Image 
HDF5 
NETCDF 
FITS 
JSON 
ROOT 
NgspiceRawAscii 
NgspiceRawBinary 

Definition at line 47 of file AbstractFileFilter.h.

◆ ImportMode

Enumerator
Append 
Prepend 
Replace 

Definition at line 48 of file AbstractFileFilter.h.

Constructor & Destructor Documentation

◆ AbstractFileFilter()

AbstractFileFilter::AbstractFileFilter ( FileType  type)
inlineexplicit

Definition at line 50 of file AbstractFileFilter.h.

◆ ~AbstractFileFilter()

AbstractFileFilter::~AbstractFileFilter ( )
overridedefault

Member Function Documentation

◆ columnMode() [1/2]

AbstractColumn::ColumnMode AbstractFileFilter::columnMode ( const QString &  valueString,
const QString &  dateTimeFormat,
const QLocale &  locale = QLocale() 
)
static

return the column mode for the given value string and settings dateTimeFormat and locale. in case dateTimeFormat is empty, all possible datetime formats are tried out to determine the valid datetime object.

Definition at line 56 of file AbstractFileFilter.cpp.

References AbstractColumn::BigInt, AbstractColumn::DateTime, dateTimeFormat(), AbstractColumn::dateTimeFormats(), DEBUG, AbstractColumn::Integer, isNan(), nsl_smooth_check::mode, AbstractColumn::Numeric, STDSTRING, and AbstractColumn::Text.

◆ columnMode() [2/2]

AbstractColumn::ColumnMode AbstractFileFilter::columnMode ( const QString &  valueString,
const QString &  dateTimeFormat,
QLocale::Language  lang 
)
static

◆ completed

◆ dateTimeFormat()

QString AbstractFileFilter::dateTimeFormat ( const QString &  valueString)
static

◆ fileType()

◆ fileTypes()

QStringList AbstractFileFilter::fileTypes ( )
static

returns the list of all supported data file formats

Definition at line 203 of file AbstractFileFilter.cpp.

References i18n.

◆ isNan()

bool AbstractFileFilter::isNan ( const QString &  s)
static

File : AbstractFileFilter.h Project : LabPlot

Description : file I/O-filter related interface

Copyright : (C) 2009-2017 Alexander Semke (alexa.nosp@m.nder.nosp@m..semk.nosp@m.e@we.nosp@m.b.de) Copyright : (C) 2017 Stefan Gerlach (stefa.nosp@m.n.ge.nosp@m.rlach.nosp@m.@uni.nosp@m..kn)

  • This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. *
  • This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. *
  • You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, * Boston, MA 02110-1301 USA *

Definition at line 40 of file AbstractFileFilter.cpp.

Referenced by columnMode().

◆ load()

virtual bool AbstractFileFilter::load ( XmlStreamReader )
pure virtual

◆ loadFilterSettings()

virtual void AbstractFileFilter::loadFilterSettings ( const QString &  filterName)
pure virtual

◆ numberFormats()

QStringList AbstractFileFilter::numberFormats ( )
static

◆ readDataFromFile()

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

◆ save()

virtual void AbstractFileFilter::save ( QXmlStreamWriter *  ) const
pure virtual

◆ saveFilterSettings()

virtual void AbstractFileFilter::saveFilterSettings ( const QString &  filterName) const
pure virtual

◆ type()

FileType AbstractFileFilter::type ( ) const
inline

◆ write()

virtual void AbstractFileFilter::write ( const QString &  fileName,
AbstractDataSource  
)
pure virtual

Member Data Documentation

◆ m_type

const FileType AbstractFileFilter::m_type
protected

Definition at line 76 of file AbstractFileFilter.h.

Referenced by type().


The documentation for this class was generated from the following files: