casacore
MaskArrIO.h
Go to the documentation of this file.
1 //# MaskArrIO.h: Write out an ascii representation of a MaskedArray.
2 //# Copyright (C) 1993,1994,1995,1999,2000,2001
3 //# Associated Universities, Inc. Washington DC, USA.
4 //#
5 //# This library is free software; you can redistribute it and/or modify it
6 //# under the terms of the GNU Library General Public License as published by
7 //# the Free Software Foundation; either version 2 of the License, or (at your
8 //# option) any later version.
9 //#
10 //# This library is distributed in the hope that it will be useful, but WITHOUT
11 //# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
12 //# FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library General Public
13 //# License for more details.
14 //#
15 //# You should have received a copy of the GNU Library General Public License
16 //# along with this library; if not, write to the Free Software Foundation,
17 //# Inc., 675 Massachusetts Ave, Cambridge, MA 02139, USA.
18 //#
19 //# Correspondence concerning AIPS++ should be addressed as follows:
20 //# Internet email: aips2-request@nrao.edu.
21 //# Postal address: AIPS++ Project Office
22 //# National Radio Astronomy Observatory
23 //# 520 Edgemont Road
24 //# Charlottesville, VA 22903-2475 USA
25 //#
26 //# $Id$
27 
28 #ifndef CASA_MASKARRIO_2_H
29 #define CASA_MASKARRIO_2_H
30 
31 namespace casacore { //# NAMESPACE CASACORE - BEGIN
32 
33 template<typename T, typename ArrayAlloc, typename MaskAlloc>
34 class MaskedArray;
35 
36 // <summary>
37 // Ascii input/output operations for MaskedArrays.
38 // </summary>
39 // <reviewed reviewer="UNKNOWN" date="before2004/08/25" tests="tMaskArrIO">
40 //
41 // <prerequisite>
42 // <li> <linkto class=Array>Array</linkto>
43 // <li> <linkto class=MaskedArray>MaskedArray</linkto>
44 // <li> <linkto group="ArrayIO.h#Array IO">ArrayIO</linkto>
45 // </prerequisite>
46 //
47 // <etymology>
48 // MaskArrIO is short for MaskedArrayIO, which is too long by the old
49 // AIPS++ file naming conventions. This file contains global functions
50 // for writing out ascii representations of masked arrays.
51 // </etymology>
52 //
53 // <synopsis>
54 // These functions write out masked arrays in ascii representation.
55 // They simply write out the Array and the LogicalArray which is the mask
56 // using the ascii output functions for these objects.
57 // </synopsis>
58 //
59 // <example>
60 // <srcblock>
61 // Vector<int> a(10);
62 // LogicalVector b(10);
63 // MaskedArray m (a,b);
64 // . . .
65 // cout << m;
66 // </srcblock>
67 // This example writes out m in ascii. It writes first a and then
68 // the mask constructed from b.
69 // </example>
70 //
71 // <motivation>
72 // These are primarily for debugging, so that one can examine the MaskedArray.
73 // Since MaskedArrays are manipulators of Arrays, it was not thought to
74 // be necessary, or even a good idea, to have other kinds of IO defined
75 // for them.
76 // </motivation>
77 //
78 // <linkfrom anchor="MaskedArray IO" classes="MaskedArray">
79 // <here>MaskedArray IO</here> -- Ascii input/output operations
80 // for MaskedArrays.
81 // </linkfrom>
82 //
83 // <group name="MaskedArray IO">
84 
85 
86 //
87 // Write out an ascii representation of a MaskedArray.
88 // The component Array and LogicalArray are written out sequentially.
89 template<typename T, typename ArrayAlloc, typename MaskAlloc>
90 std::ostream & operator<< (std::ostream &, const MaskedArray<T, ArrayAlloc, MaskAlloc> &);
91 
92 
93 // </group>
94 template<typename T, typename ArrayAlloc, typename MaskAlloc>
96 
97 } //# NAMESPACE CASACORE - END
98 
99 
100 #include "MaskArrIO.tcc"
101 
102 #endif
this file contains all the compiler specific defines
Definition: mainpage.dox:28
std::string to_string(const IPosition &ip)
ostream & operator<<(ostream &os, const IComplex &)
Show on ostream.