12 #ifndef CXFILEREADERWRITERSERVICE_H 13 #define CXFILEREADERWRITERSERVICE_H 16 #include "cxResourceExport.h" 17 #include "boost/shared_ptr.hpp" 20 #define FileReaderWriterService_iid "cx::FileReaderWriterService" 22 class ctkPluginContext;
34 static FileReaderWriterServicePtr getNullObject();
37 virtual bool isNull() = 0;
39 virtual QString getName()
const = 0;
40 virtual QString getFileSuffix()
const = 0;
43 virtual QString canReadDataType()
const = 0;
44 virtual bool canRead(
const QString& type,
const QString& filename) = 0;
46 virtual std::vector<DataPtr> read(
const QString& filename) = 0;
49 virtual DataPtr read(
const QString& uid,
const QString& filename) = 0;
50 virtual bool readInto(
DataPtr data, QString path) = 0;
54 virtual QString canWriteDataType()
const = 0;
55 virtual bool canWrite(
const QString& type,
const QString& filename)
const = 0;
56 virtual void write(
DataPtr data,
const QString& filename) = 0;
78 virtual QString getName()
const;
79 virtual QString getFileSuffix()
const;
85 bool canReadInternal(
const QString& type,
const QString& filename)
const;
86 bool canWriteInternal(
const QString& type,
const QString& filename)
const;
88 DataPtr createData(QString type, QString filename, QString name =
"")
const;
94 QString mCanReadDataType;
95 QString mCanWriteDataType;
107 #endif // CXFILEREADERWRITERSERVICE_H
virtual vtkPolyDataPtr loadVtkPolyData(QString filename)
boost::shared_ptr< class Data > DataPtr
boost::shared_ptr< class FileReaderWriterService > FileReaderWriterServicePtr
boost::shared_ptr< class PatientModelService > PatientModelServicePtr
vtkSmartPointer< vtkPolyData > vtkPolyDataPtr
virtual ~FileReaderWriterService()
virtual vtkImageDataPtr loadVtkImageData(QString filename)
#define FileReaderWriterService_iid
Namespace for all CustusX production code.