22 typedef void Datarep_extent_function(
const Datatype& datatype,
23 Aint& file_extent,
void* extra_state);
24 typedef void Datarep_conversion_function(
void* userbuf,
Datatype& datatype,
25 int count,
void* filebuf,
26 Offset position,
void* extra_state);
29 void Register_datarep(
const char* datarep,
30 Datarep_conversion_function* read_conversion_fn,
31 Datarep_conversion_function* write_conversion_fn,
32 Datarep_extent_function* dtype_file_extent_fn,
36 void Register_datarep(
const char* datarep,
37 MPI_Datarep_conversion_function* read_conversion_fn,
38 Datarep_conversion_function* write_conversion_fn,
39 Datarep_extent_function* dtype_file_extent_fn,
43 void Register_datarep(
const char* datarep,
44 Datarep_conversion_function* read_conversion_fn,
45 MPI_Datarep_conversion_function* write_conversion_fn,
46 Datarep_extent_function* dtype_file_extent_fn,
50 void Register_datarep(
const char* datarep,
51 MPI_Datarep_conversion_function* read_conversion_fn,
52 MPI_Datarep_conversion_function* write_conversion_fn,
53 Datarep_extent_function* dtype_file_extent_fn,
61 friend class MPI::Comm;
62 friend class MPI::Request;
73 File(
const File& data) : pmpi_file(data.pmpi_file) { }
77 File& operator=(
const File& data) {
78 pmpi_file = data.pmpi_file;
return *
this; }
83 File& operator= (
const MPI_File &i) {
84 pmpi_file = i;
return *
this; }
85 operator MPI_File ()
const {
return pmpi_file; }
87 operator const PMPI::File&()
const {
return pmpi_file; }
91 File() : mpi_file(MPI_FILE_NULL) { }
93 File(
const File& data) : mpi_file(data.mpi_file) { }
99 File& operator=(
const File& data) {
100 mpi_file = data.mpi_file;
return *
this; }
105 File& operator= (
const MPI_File &i) {
106 mpi_file = i;
return *
this; }
107 operator MPI_File ()
const {
return mpi_file; }
116 static void Delete(
const char* filename,
const MPI::Info& info);
118 int Get_amode()
const;
120 bool Get_atomicity()
const;
122 MPI::Offset Get_byte_offset(
const MPI::Offset disp)
const;
124 MPI::Group Get_group()
const;
126 MPI::Info Get_info()
const;
128 MPI::Offset Get_position()
const;
130 MPI::Offset Get_position_shared()
const;
132 MPI::Offset Get_size()
const;
134 MPI::Aint Get_type_extent(
const MPI::Datatype& datatype)
const;
136 void Get_view(MPI::Offset& disp, MPI::Datatype& etype,
137 MPI::Datatype& filetype,
char* datarep)
const;
139 MPI::Request Iread(
void* buf,
int count,
140 const MPI::Datatype& datatype);
142 MPI::Request Iread_at(MPI::Offset offset,
void* buf,
int count,
143 const MPI::Datatype& datatype);
145 MPI::Request Iread_shared(
void* buf,
int count,
146 const MPI::Datatype& datatype);
148 MPI::Request Iwrite(
const void* buf,
int count,
149 const MPI::Datatype& datatype);
151 MPI::Request Iwrite_at(MPI::Offset offset,
const void* buf,
152 int count,
const MPI::Datatype& datatype);
154 MPI::Request Iwrite_shared(
const void* buf,
int count,
155 const MPI::Datatype& datatype);
157 static MPI::File Open(
const MPI::Intracomm& comm,
158 const char* filename,
int amode,
159 const MPI::Info& info);
161 void Preallocate(MPI::Offset size);
163 void Read(
void* buf,
int count,
const MPI::Datatype& datatype);
165 void Read(
void* buf,
int count,
const MPI::Datatype& datatype,
166 MPI::Status& status);
168 void Read_all(
void* buf,
int count,
const MPI::Datatype& datatype);
170 void Read_all(
void* buf,
int count,
const MPI::Datatype& datatype,
171 MPI::Status& status);
173 void Read_all_begin(
void* buf,
int count,
174 const MPI::Datatype& datatype);
176 void Read_all_end(
void* buf);
178 void Read_all_end(
void* buf, MPI::Status& status);
180 void Read_at(MPI::Offset offset,
181 void* buf,
int count,
const MPI::Datatype& datatype);
183 void Read_at(MPI::Offset offset,
void* buf,
int count,
184 const MPI::Datatype& datatype, MPI::Status& status);
186 void Read_at_all(MPI::Offset offset,
void* buf,
int count,
187 const MPI::Datatype& datatype);
189 void Read_at_all(MPI::Offset offset,
void* buf,
int count,
190 const MPI::Datatype& datatype, MPI::Status& status);
192 void Read_at_all_begin(MPI::Offset offset,
void* buf,
int count,
193 const MPI::Datatype& datatype);
195 void Read_at_all_end(
void* buf);
197 void Read_at_all_end(
void* buf, MPI::Status& status);
199 void Read_ordered(
void* buf,
int count,
200 const MPI::Datatype& datatype);
202 void Read_ordered(
void* buf,
int count,
203 const MPI::Datatype& datatype,
204 MPI::Status& status);
206 void Read_ordered_begin(
void* buf,
int count,
207 const MPI::Datatype& datatype);
209 void Read_ordered_end(
void* buf);
211 void Read_ordered_end(
void* buf, MPI::Status& status);
213 void Read_shared(
void* buf,
int count,
214 const MPI::Datatype& datatype);
216 void Read_shared(
void* buf,
int count,
217 const MPI::Datatype& datatype, MPI::Status& status);
219 void Seek(MPI::Offset offset,
int whence);
221 void Seek_shared(MPI::Offset offset,
int whence);
223 void Set_atomicity(
bool flag);
225 void Set_info(
const MPI::Info& info);
227 void Set_size(MPI::Offset size);
229 void Set_view(MPI::Offset disp,
const MPI::Datatype& etype,
230 const MPI::Datatype& filetype,
const char* datarep,
231 const MPI::Info& info);
235 void Write(
const void* buf,
int count,
236 const MPI::Datatype& datatype);
238 void Write(
const void* buf,
int count,
239 const MPI::Datatype& datatype, MPI::Status& status);
241 void Write_all(
const void* buf,
int count,
242 const MPI::Datatype& datatype);
244 void Write_all(
const void* buf,
int count,
245 const MPI::Datatype& datatype, MPI::Status& status);
247 void Write_all_begin(
const void* buf,
int count,
248 const MPI::Datatype& datatype);
250 void Write_all_end(
const void* buf);
252 void Write_all_end(
const void* buf, MPI::Status& status);
254 void Write_at(MPI::Offset offset,
const void* buf,
int count,
255 const MPI::Datatype& datatype);
257 void Write_at(MPI::Offset offset,
const void* buf,
int count,
258 const MPI::Datatype& datatype, MPI::Status& status);
260 void Write_at_all(MPI::Offset offset,
const void* buf,
int count,
261 const MPI::Datatype& datatype);
263 void Write_at_all(MPI::Offset offset,
const void* buf,
int count,
264 const MPI::Datatype& datatype,
265 MPI::Status& status);
267 void Write_at_all_begin(MPI::Offset offset,
const void* buf,
268 int count,
const MPI::Datatype& datatype);
270 void Write_at_all_end(
const void* buf);
272 void Write_at_all_end(
const void* buf, MPI::Status& status);
274 void Write_ordered(
const void* buf,
int count,
275 const MPI::Datatype& datatype);
277 void Write_ordered(
const void* buf,
int count,
278 const MPI::Datatype& datatype, MPI::Status& status);
280 void Write_ordered_begin(
const void* buf,
int count,
281 const MPI::Datatype& datatype);
283 void Write_ordered_end(
const void* buf);
285 void Write_ordered_end(
const void* buf, MPI::Status& status);
287 void Write_shared(
const void* buf,
int count,
288 const MPI::Datatype& datatype);
290 void Write_shared(
const void* buf,
int count,
291 const MPI::Datatype& datatype, MPI::Status& status);
296 typedef void Errhandler_function(MPI::File &,
int *, ... );
297 typedef Errhandler_function Errhandler_fn
298 __mpi_interface_deprecated__(
"MPI::File::Errhandler_fn was deprecated in MPI-2.2; use MPI::File::Errhandler_function instead");
300 static MPI::Errhandler Create_errhandler(Errhandler_function*
function);
302 MPI::Errhandler Get_errhandler()
const;
304 void Set_errhandler(
const MPI::Errhandler& errhandler)
const;
306 void Call_errhandler(
int errorcode)
const;
310 PMPI::File pmpi_file;
Definition: datatype.h:24
Back-end structure for MPI_File.
Definition: file.h:42