OPAL (Object Oriented Parallel Accelerator Library)
2024.1
OPAL
Main Page
Related Pages
Modules
Namespaces
Classes
Files
File List
File Members
ippl
src
DataSource
FileFieldDataSource.h
Go to the documentation of this file.
1
// -*- C++ -*-
2
/***************************************************************************
3
*
4
* The IPPL Framework
5
*
6
*
7
* Visit http://people.web.psi.ch/adelmann/ for more details
8
*
9
***************************************************************************/
10
11
#ifndef FILE_FIELD_DATA_SOURCE_H
12
#define FILE_FIELD_DATA_SOURCE_H
13
14
/***********************************************************************
15
*
16
* class FileFieldDataSource
17
*
18
* FileFieldDataSource is a specific version of DataSourceObject which takes
19
* the data for a given Field and writes it to a file using a DiscField
20
* object.
21
*
22
***********************************************************************/
23
24
// include files
25
#include "
DataSource/DataSourceObject.h
"
26
#include "
Field/Field.h
"
27
#include "
Utility/DiscField.h
"
28
29
30
template
<
class
T,
unsigned
Dim,
class
M,
class
C>
31
class
FileFieldDataSource
:
public
DataSourceObject
{
32
33
public
:
34
35
// constructor: the name, the connection, the transfer method,
36
// the field to connect, and the parent node.
37
FileFieldDataSource
(
const
char
*,
DataConnect
*,
int
,
Field<T,Dim,M,C>
&);
38
39
// destructor
40
virtual
~FileFieldDataSource
();
41
42
//
43
// virtual function interface.
44
//
45
46
// Update the object, that is, make sure the receiver of the data has a
47
// current and consistent snapshot of the current state. Return success.
48
virtual
bool
update
();
49
50
// Indicate to the receiver that we're allowing them time to manipulate the
51
// data (e.g., for a viz program, to rotate it, change representation, etc.)
52
// This should only return when the manipulation is done.
53
virtual
void
interact
(
const
char
* = 0);
54
55
private
:
56
// the DiscField object, which read/writes the data
57
DiscField<Dim>
*
DF
;
58
59
// the Field to read into (or write from)
60
Field<T,Dim,M,C>
&
myField
;
61
62
// which field are we in the file?
63
int
FieldID
;
64
65
// the number of frames we have read or written (i.e. or current record)
66
int
counter
;
67
};
68
69
#include "
DataSource/FileFieldDataSource.hpp
"
70
71
#endif // FILE_FIELD_DATA_SOURCE_H
72
73
/***************************************************************************
74
* $RCSfile: FileFieldDataSource.h,v $ $Author: adelmann $
75
* $Revision: 1.1.1.1 $ $Date: 2003/01/23 07:40:25 $
76
* IPPL_VERSION_ID: $Id: FileFieldDataSource.h,v 1.1.1.1 2003/01/23 07:40:25 adelmann Exp $
77
***************************************************************************/
DiscField.h
FileFieldDataSource::~FileFieldDataSource
virtual ~FileFieldDataSource()
Definition:
FileFieldDataSource.hpp:84
DataConnect
Definition:
DataConnect.h:32
DiscField
Definition:
DiscField.h:49
FileFieldDataSource.hpp
FileFieldDataSource
Definition:
FileFieldDataSource.h:31
FileFieldDataSource::update
virtual bool update()
Definition:
FileFieldDataSource.hpp:97
FileFieldDataSource::FieldID
int FieldID
Definition:
FileFieldDataSource.h:63
FileFieldDataSource::FileFieldDataSource
FileFieldDataSource(const char *, DataConnect *, int, Field< T, Dim, M, C > &)
Definition:
FileFieldDataSource.hpp:38
FileFieldDataSource::DF
DiscField< Dim > * DF
Definition:
FileFieldDataSource.h:57
FileFieldDataSource::counter
int counter
Definition:
FileFieldDataSource.h:66
DataSourceObject.h
DataSourceObject
Definition:
DataSourceObject.h:53
Field< T, Dim, M, C >
FileFieldDataSource::interact
virtual void interact(const char *=0)
Definition:
FileFieldDataSource.hpp:115
Field.h
FileFieldDataSource::myField
Field< T, Dim, M, C > & myField
Definition:
FileFieldDataSource.h:60
Generated on Tue Jul 2 2024 15:05:13 for OPAL (Object Oriented Parallel Accelerator Library) by
1.8.5