/[escript]/trunk/weipa/src/VisItData.h
ViewVC logotype

Contents of /trunk/weipa/src/VisItData.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 6939 - (show annotations)
Mon Jan 20 03:37:18 2020 UTC (10 months, 1 week ago) by uqaeller
File MIME type: text/plain
File size: 2006 byte(s)
Updated the copyright header.


1
2 /*****************************************************************************
3 *
4 * Copyright (c) 2003-2020 by The University of Queensland
5 * http://www.uq.edu.au
6 *
7 * Primary Business: Queensland, Australia
8 * Licensed under the Apache License, version 2.0
9 * http://www.apache.org/licenses/LICENSE-2.0
10 *
11 * Development until 2012 by Earth Systems Science Computational Center (ESSCC)
12 * Development 2012-2013 by School of Earth Sciences
13 * Development from 2014-2017 by Centre for Geoscience Computing (GeoComp)
14 * Development from 2019 by School of Earth and Environmental Sciences
15 **
16 *****************************************************************************/
17
18 #ifndef __WEIPA_VISITDATA_H__
19 #define __WEIPA_VISITDATA_H__
20
21 #include <escript/AbstractDomain.h>
22 #include <escript/Data.h>
23 #include <weipa/EscriptDataset.h>
24
25 #include <VisItInterfaceTypes_V2.h>
26
27 namespace weipa {
28
29 class VisItData {
30
31 public:
32 VisItData() : runFlag(false) {}
33
34 void publishData(EscriptDataset_ptr ds) { dataset=ds; }
35 void setCommandNames(std::vector<std::string> names) { cmdNames=names; }
36 void setSimulationStatus(bool running) { runFlag=running; }
37
38 visit_handle getDomainList();
39 visit_handle getMesh(const char* name);
40 visit_handle getSimMetaData();
41 visit_handle getVariable(const char* name);
42
43 private:
44 void addExpressionMetadata(visit_handle smd, const std::string& name,
45 const std::string& def, int type);
46 void addMeshMetadata(visit_handle smd, const std::string& name,
47 int dim, int numDoms);
48 void addVariableMetadata(visit_handle smd, const std::string& name,
49 const std::string& meshName, int centering,
50 int rank);
51
52 bool runFlag;
53 EscriptDataset_ptr dataset;
54 std::vector<std::string> cmdNames;
55 std::map<std::string, DataVar_ptr> variables;
56 };
57
58 typedef boost::shared_ptr<VisItData> VisItData_ptr;
59
60
61 } // namespace weipa
62
63 #endif // __WEIPA_VISITDATA_H__
64

  ViewVC Help
Powered by ViewVC 1.1.26