67 template<
template<
class Level,
class Type>
class Container,
68 template<
class Type>
class Level,
class TypeList>
85 std::vector<std::map<std::string, std::string>>
m_params;
101 Grid(
unsigned int count,
102 unsigned int blockLength[],
103 unsigned long displacements[],
113 #endif // ASAGI_NOMPI
120 void setParam(
const char* name,
const char* value,
unsigned int level = 0);
139 double getDelta(
unsigned int n,
unsigned int level = 0)
const
149 unsigned char getByte(
const double* pos,
unsigned int level = 0)
157 int getInt(
const double* pos,
unsigned int level = 0)
165 long getLong(
const double* pos,
unsigned int level = 0)
173 float getFloat(
const double* pos,
unsigned int level = 0)
181 double getDouble(
const double* pos,
unsigned int level = 0)
189 void getBuf(
void* buf,
const double* pos,
unsigned int level = 0)
194 unsigned long getCounter(
const char* name,
unsigned int level = 0);
212 T
param(
const char* name, T defaultValue,
unsigned int level = 0)
const;
232 template<
template<
class Level,
class Type>
class Container,
233 template<
class Type>
class Level>
234 class Grid::TypeSelector<Container, Level, magic::NullType>
245 #endif // GRID_GRID_H
unsigned char getByte(const double *pos, unsigned int level=0)
float getFloat(const double *pos, unsigned int level=0)
asagi::Grid::Error setComm(MPI_Comm comm=MPI_COMM_WORLD)
asagi::Grid::Error init(MPI_Comm comm)
void getBuf(void *buf, const double *pos, unsigned int level=0)
asagi::Grid::Error setThreads(unsigned int threads)
unsigned int getVarSize() const
std::vector< Container * > m_containers
threads::Once m_resizeOnce
unsigned int getDimensions() const
Returns the number of dimensions loaded from the file.
double getMax(unsigned int n) const
int getInt(const double *pos, unsigned int level=0)
void setParam(const char *name, const char *value, unsigned int level=0)
Changes a grid parameter.
double getDelta(unsigned int n, unsigned int level=0) const
static grid::Container * createContainer(Grid &grid)
asagi::Grid::Error setThreads(unsigned int threads)
Sets the number of threads in the application.
unsigned long getCounter(const char *name, unsigned int level=0)
Include file for C and C++ API.
C++ Interface for ASAGI grids.
std::vector< std::map< std::string, std::string > > m_params
double getMin(unsigned int n) const
T param(const char *name, T defaultValue, unsigned int level=0) const
double getDouble(const double *pos, unsigned int level=0)
unsigned int domainId() const
virtual unsigned int size() const =0
static fortran::PointerArray< Grid > m_pointers
long getLong(const double *pos, unsigned int level=0)
asagi::Grid::Error open(const char *filename, unsigned int level=0)
Loads values from a NetCDF file.
Grid(asagi::Grid::Type type, bool isArray=false)