-
Notifications
You must be signed in to change notification settings - Fork 0
/
BOVVectorImage.h
71 lines (55 loc) · 1.55 KB
/
BOVVectorImage.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
/*
____ _ __ ____ __ ____
/ __/___(_) / ___ ____/ __ \__ _____ ___ / /_ / _/__ ____
_\ \/ __/ / _ \/ -_) __/ /_/ / // / -_|_-</ __/ _/ // _ \/ __/
/___/\__/_/_.__/\__/_/ \___\_\_,_/\__/___/\__/ /___/_//_/\__(_)
Copyright 2012 SciberQuest Inc.
*/
#ifndef BOVVectorImage_h
#define BOVVectorImage_h
#include "BOVScalarImage.h"
#include <iostream>
using std::ostream;
using std::endl;
#include <vector>
using std::vector;
#include <string>
using std::string;
#ifdef SQTK_WITHOUT_MPI
typedef void * MPI_Comm;
typedef void * MPI_Info;
typedef void * MPI_File;
#else
#include <mpi.h>
#endif
/// Handle to the files comprising a multi-component vector.
class BOVVectorImage
{
public:
BOVVectorImage(){};
~BOVVectorImage();
void Clear();
void SetComponentFile(
int i,
MPI_Comm comm,
MPI_Info hints,
const char *fileName,
int mode);
MPI_File GetComponentFile(int i) const
{
return this->ComponentFiles[i]->GetFile();
}
void SetNumberOfComponents(int nComps);
int GetNumberOfComponents() const { return this->ComponentFiles.size(); }
void SetName(const char *name){ this->Name=name; }
const char *GetName() const { return this->Name.c_str(); }
private:
string Name;
vector<BOVScalarImage *> ComponentFiles;
private:
friend ostream &operator<<(ostream &os, const BOVVectorImage &si);
const BOVVectorImage &operator=(const BOVVectorImage &other);
BOVVectorImage(const BOVVectorImage &other);
};
ostream &operator<<(ostream &os, const BOVVectorImage &vi);
#endif