STIR  6.2.0
Public Types | Public Member Functions | Protected Member Functions | List of all members
stir::InputFileFormat< DataT > Class Template Referenceabstract

Base-class for file-formats for reading. More...

#include "stir/IO/InputFileFormat.h"

Inheritance diagram for stir::InputFileFormat< DataT >:
Inheritance graph
[legend]

Public Types

typedef DataT data_type
 

Public Member Functions

virtual bool can_read (const FileSignature &signature, std::istream &input) const
 
virtual bool can_read (const FileSignature &signature, const std::string &filename) const
 
virtual unique_ptr< DataT > read_from_file (std::istream &input) const =0
 read data from a stream More...
 
virtual unique_ptr< DataT > read_from_file (const std::string &filename) const
 read data from a filename More...
 
virtual const std::string get_name () const =0
 

Protected Member Functions

virtual bool actual_can_read (const FileSignature &signature, std::istream &input) const =0
 

Detailed Description

template<class DataT>
class stir::InputFileFormat< DataT >

Base-class for file-formats for reading.


Preliminary

Todo:

should be able to open for input-output maybe

there is overlap between function having filenames or istreams. This is a bit of a mess. Also, some file formats we might only have an API for using C-style FILE.

Member Function Documentation

◆ read_from_file() [1/2]

template<class DataT>
virtual unique_ptr<DataT> stir::InputFileFormat< DataT >::read_from_file ( std::istream &  input) const
pure virtual

◆ read_from_file() [2/2]

template<class DataT>
virtual unique_ptr<DataT> stir::InputFileFormat< DataT >::read_from_file ( const std::string &  filename) const
inlinevirtual

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