STIR  6.2.0
ECAT7OutputFileFormat.h
Go to the documentation of this file.
1 //
2 //
3 /*
4  Copyright (C) 2002-2007, Hammersmith Imanet Ltd
5  This file is part of STIR.
6 
7  SPDX-License-Identifier: Apache-2.0
8 
9  See STIR/LICENSE.txt for details
10 */
21 #ifndef __stir_IO_ECAT7OutputFileFormat_H__
22 #define __stir_IO_ECAT7OutputFileFormat_H__
23 
26 // include for namespace macros
28 #include <string>
29 
30 START_NAMESPACE_STIR
31 
32 template <int num_dimensions, typename elemT>
33 class DiscretisedDensity;
34 
35 START_NAMESPACE_ECAT
36 START_NAMESPACE_ECAT7
37 
46 class ECAT7OutputFileFormat : public RegisteredParsingObject<ECAT7OutputFileFormat,
47  OutputFileFormat<DiscretisedDensity<3, float>>,
48  OutputFileFormat<DiscretisedDensity<3, float>>>
49 {
50 private:
53  OutputFileFormat<DiscretisedDensity<3, float>>>
54  base_type;
55 
56 public:
58  static const char* const registered_name;
59 
60  ECAT7OutputFileFormat(const NumericType& = NumericType::SHORT, const ByteOrder& = ByteOrder::native);
61 
63 
64  virtual NumericType set_type_of_numbers(const NumericType&, const bool warn = false);
66 
67  virtual ByteOrder set_byte_order(const ByteOrder&, const bool warn = false);
68  // virtual ByteOrder set_byte_order_and_type_of_numbers(ByteOrder&, NumericType&, const bool warn = false);
69 public:
70  std::string default_scanner_name;
71 
72 protected:
73  virtual Succeeded actual_write_to_file(std::string& output_filename, const DiscretisedDensity<3, float>& density) const;
74 
75  virtual void set_defaults();
76  virtual void initialise_keymap();
77  virtual bool post_processing();
78 };
79 
80 END_NAMESPACE_ECAT7
81 END_NAMESPACE_ECAT
82 END_NAMESPACE_STIR
83 
84 #endif
Implementation of OutputFileFormat paradigm for the ECAT7 format.
Definition: ECAT7OutputFileFormat.h:46
This class provides member functions to find out what byte-order your machine is and to swap numbers...
Definition: ByteOrder.h:99
Declaration of class stir::OutputFileFormat.
static const char *const registered_name
Name which will be used when parsing an OutputFileFormat object.
Definition: ECAT7OutputFileFormat.h:58
Parent class for all leaves in a RegisteredObject hierarchy that do parsing of parameter files...
Definition: RegisteredParsingObject.h:77
provides names for some numeric types and methods for finding their properties.
Definition: NumericType.h:54
a class containing an enumeration type that can be used by functions to signal successful operation o...
Definition: Succeeded.h:43
Declaration of class stir::RegisteredParsingObject.
Base class for classes that create output files.
Definition: OutputFileFormat.h:55
Declaration of routines which convert ECAT things into our building blocks and vice versa...