RTK  1.4.0
Reconstruction Toolkit
rtkImagXImageIO.h
Go to the documentation of this file.
1 /*=========================================================================
2  *
3  * Copyright RTK Consortium
4  *
5  * Licensed under the Apache License, Version 2.0 (the "License");
6  * you may not use this file except in compliance with the License.
7  * You may obtain a copy of the License at
8  *
9  * http://www.apache.org/licenses/LICENSE-2.0.txt
10  *
11  * Unless required by applicable law or agreed to in writing, software
12  * distributed under the License is distributed on an "AS IS" BASIS,
13  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14  * See the License for the specific language governing permissions and
15  * limitations under the License.
16  *
17  *=========================================================================*/
18 
19 #ifndef rtkImagXImageIO_h
20 #define rtkImagXImageIO_h
21 
22 #include <itkImageIOBase.h>
23 #include <fstream>
24 #include <string.h>
25 
26 #include "rtkMacro.h"
27 
28 namespace rtk
29 {
30 
38 {
39 public:
41  typedef ImagXImageIO Self;
44 
45  ImagXImageIO() : Superclass() {}
46 
48  itkNewMacro(Self);
49 
51  itkTypeMacro(ImagXImageIO, ImageIOBase);
52 
53  /*-------- This part of the interface deals with reading data. ------ */
54  void ReadImageInformation() ITK_OVERRIDE;
55 
56  bool CanReadFile( const char* FileNameToRead ) ITK_OVERRIDE;
57 
58  void Read(void * buffer) ITK_OVERRIDE;
59 
60  /*-------- This part of the interfaces deals with writing data. ----- */
61  virtual void WriteImageInformation(bool keepOfStream);
62 
63  void WriteImageInformation() ITK_OVERRIDE { WriteImageInformation(false); }
64  bool CanWriteFile(const char* filename) ITK_OVERRIDE;
65 
66  void Write(const void* buffer) ITK_OVERRIDE;
67 
68 protected:
69  std::string m_RawFileName;
70 };
71 
72 } // end namespace
73 
74 #endif
void Write(const void *buffer) override
void Read(void *buffer) override
ImagXImageIO Self
void WriteImageInformation() override
itk::ImageIOBase Superclass
std::string m_RawFileName
void ReadImageInformation() override
bool CanWriteFile(const char *filename) override
bool CanReadFile(const char *FileNameToRead) override
itk::SmartPointer< Self > Pointer