go home Home | Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Data Structures | File List | Namespace Members | Data Fields | Globals | Related Pages
xoutrow.h
Go to the documentation of this file.
1 /*=========================================================================
2  *
3  * Copyright UMC Utrecht and contributors
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 #ifndef __xoutrow_h
19 #define __xoutrow_h
20 
21 #include "xoutbase.h"
22 #include "xoutcell.h"
23 #include <sstream>
24 
25 namespace xoutlibrary
26 {
27 using namespace std;
28 
41 template< class charT, class traits = char_traits< charT > >
42 class xoutrow : public xoutbase< charT, traits >
43 {
44 public:
45 
46  typedef xoutrow Self;
48 
51  typedef typename Superclass::char_type char_type;
52  typedef typename Superclass::int_type int_type;
53  typedef typename Superclass::pos_type pos_type;
54  typedef typename Superclass::off_type off_type;
56  typedef typename Superclass::ios_type ios_type;
57 
64 
67 
69  xoutrow();
70 
72  virtual ~xoutrow();
73 
77  virtual void WriteBufferedData( void );
78 
83  virtual void WriteHeaders( void );
84 
86  virtual int AddTargetCell( const char * name );
87 
89  virtual int RemoveTargetCell( const char * name );
90 
94  virtual void SetTargetCells( const XStreamMapType & cellmap );
95 
100  virtual int AddOutput( const char * name, ostream_type * output );
101 
102  virtual int AddOutput( const char * name, Superclass * output );
103 
104  virtual int RemoveOutput( const char * name );
105 
106  virtual void SetOutputs( const CStreamMapType & outputmap );
107 
108  virtual void SetOutputs( const XStreamMapType & outputmap );
109 
110 protected:
111 
116  virtual Superclass & SelectXCell( const char * name );
117 
118  XStreamMapType m_CellMap;
119 
120 };
121 
122 } // end namespace xoutlibrary
123 
124 #include "xoutrow.hxx"
125 
126 #endif // end #ifndef __xoutrow_h
Superclass::XStreamMapEntryType XStreamMapEntryType
Definition: xoutrow.h:63
XStreamMapType::value_type XStreamMapEntryType
Definition: xoutbase.h:67
Superclass::CStreamMapIteratorType CStreamMapIteratorType
Definition: xoutrow.h:60
Superclass::char_type char_type
Definition: xoutrow.h:51
The xoutrow class can easily generate tables.
Definition: xoutrow.h:42
Superclass::XStreamMapIteratorType XStreamMapIteratorType
Definition: xoutrow.h:61
basic_ostream< charT, traits > ostream_type
Definition: xoutbase.h:59
CStreamMapType::value_type CStreamMapEntryType
Definition: xoutbase.h:66
xoutcell< charT, traits > XOutCellType
Definition: xoutrow.h:66
Superclass::ostream_type ostream_type
Definition: xoutrow.h:55
Superclass::CStreamMapEntryType CStreamMapEntryType
Definition: xoutrow.h:62
Superclass::ios_type ios_type
Definition: xoutrow.h:56
Superclass::int_type int_type
Definition: xoutrow.h:52
traits::pos_type pos_type
Definition: xoutbase.h:57
XStreamMapType m_CellMap
Definition: xoutrow.h:118
Superclass::XStreamMapType XStreamMapType
Definition: xoutrow.h:59
XStreamMapType::iterator XStreamMapIteratorType
Definition: xoutbase.h:65
Base class for xout.
Definition: xoutbase.h:47
xoutbase< charT, traits > Superclass
Definition: xoutrow.h:47
Superclass::traits_type traits_type
Definition: xoutrow.h:50
Superclass::off_type off_type
Definition: xoutrow.h:54
traits::int_type int_type
Definition: xoutbase.h:56
std::map< std::string, Self * > XStreamMapType
Definition: xoutbase.h:63
std::map< std::string, ostream_type * > CStreamMapType
Definition: xoutbase.h:62
Superclass::pos_type pos_type
Definition: xoutrow.h:53
traits::off_type off_type
Definition: xoutbase.h:58
CStreamMapType::iterator CStreamMapIteratorType
Definition: xoutbase.h:64
Superclass::CStreamMapType CStreamMapType
Definition: xoutrow.h:58
Stores the input in a string stream.
Definition: xoutcell.h:39
basic_ios< charT, traits > ios_type
Definition: xoutbase.h:60


Generated on 04-09-2015 for elastix by doxygen 1.8.9.1 elastix logo