SheafSystem  0.0.0.0
attributes_record_set.h
1 
2 //
3 // Copyright (c) 2014 Limit Point Systems, Inc.
4 //
5 // Licensed under the Apache License, Version 2.0 (the "License");
6 // you may not use this file except in compliance with the License.
7 // You may obtain a copy of the License at
8 //
9 // http://www.apache.org/licenses/LICENSE-2.0
10 //
11 // Unless required by applicable law or agreed to in writing, software
12 // distributed under the License is distributed on an "AS IS" BASIS,
13 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 // See the License for the specific language governing permissions and
15 // limitations under the License.
16 //
17 
18 // Interface for class attributes_record_set
19 
20 #ifndef ATTRIBUTES_RECORD_SET_H
21 #define ATTRIBUTES_RECORD_SET_H
22 
23 #ifndef SHEAF_DLL_SPEC_H
24 #include "SheafSystem/sheaf_dll_spec.h"
25 #endif
26 
27 #ifndef DOF_TUPLE_CLASS_NAMES_RECORD_H
28 #include "SheafSystem/dof_tuple_class_names_record.h"
29 #endif
30 
31 #ifndef DOF_TUPLE_COL_BOUNDS_RECORD_H
32 #include "SheafSystem/dof_tuple_col_bounds_record.h"
33 #endif
34 
35 #ifndef DOF_TUPLE_DOMAIN_OFFSETS_RECORD_H
36 #include "SheafSystem/dof_tuple_domain_offsets_record.h"
37 #endif
38 
39 #ifndef DOF_TUPLE_SCHEMA_IDS_RECORD_H
40 #include "SheafSystem/dof_tuple_schema_ids_record.h"
41 #endif
42 
43 #ifndef DOF_TUPLE_SCHEMA_VERSIONS_RECORD_H
44 #include "SheafSystem/dof_tuple_schema_versions_record.h"
45 #endif
46 
47 #ifndef DOF_TUPLE_TYPES_RECORD_H
48 #include "SheafSystem/dof_tuple_types_record.h"
49 #endif
50 
51 #ifndef ID_SPACE_NAMES_RECORD_H
52 #include "SheafSystem/id_space_names_record.h"
53 #endif
54 
55 #ifndef RECORD_SET_H
56 #include "SheafSystem/record_set.h"
57 #endif
58 
59 #ifndef MEMBER_NAMES_RECORD_H
60 #include "SheafSystem/member_names_record.h"
61 #endif
62 
63 #ifndef MEMBER_CLASS_NAMES_RECORD_H
64 #include "SheafSystem/member_class_names_record.h"
65 #endif
66 
67 #ifndef POSET_GENERAL_RECORD_H
68 #include "SheafSystem/poset_general_record.h"
69 #endif
70 
71 #ifndef SUBPOSET_NAMES_RECORD_H
72 #include "SheafSystem/subposet_names_record.h"
73 #endif
74 
75 #ifndef TABLE_DOF_TUPLE_RECORD_H
76 #include "SheafSystem/table_dof_tuple_record.h"
77 #endif
78 
79 namespace sheaf
80 {
81 
85 class SHEAF_DLL_SPEC attributes_record_set : public record_set
86 {
87 
88 public:
89 
90  // CANONICAL MEMBERS
91 
97 
103  virtual attributes_record_set* clone() const;
104 
108  virtual ~attributes_record_set();
109 
113  virtual bool invariant() const;
114 
118  virtual bool is_ancestor_of(const any* other) const;
119 
120  // ATTRIBUTES_RECORD_SET INTERFACE
121 
128  attributes_record_set(const sheaf_file& xfile, const poset_scaffold& xscaffold);
129 
133  virtual const std::string& suffix() const;
134 
138  void internalize();
139 
143  void externalize();
144 
145 protected:
146 
147  // Default constructor;
148  // not supported because can not initialize reference data members.
149  // attributes_record_set();
150 
154  virtual hid_t create_dataset();
155 
159  virtual void create_int_data_type();
160 
164  virtual void read_dataset_attributes();
165 
169  virtual void write_dataset_attributes();
170 
174  static const char* TOC_BOUNDS_ATTRIBUTE_NAME();
175 
179  static const hsize_t TOC_BOUNDS_EXTENT;
180 
184  virtual void read_toc_bounds_attribute();
185 
189  virtual void write_toc_bounds_attribute();
190 
191 private:
192 
196  void read_selection();
197 
201  void write_selection();
202 
206  typedef attributes_record::hdf_buf_type hdf_buf_type;
207 
211  hdf_buf_type* _hdf_bufs;
212 
216  poset_general_record _general_attributes;
217 
221  table_dof_tuple_record _table_dof_tuple;
222 
226  member_names_record _member_names;
227 
231  member_class_names_record _member_class_names;
232 
236  subposet_names_record _subposet_names;
237 
241  id_space_names_record _id_space_names;
242 
246  dof_tuple_types_record _dof_tuple_types;
247 
251  dof_tuple_class_names_record _dof_tuple_class_names;
252 
256  dof_tuple_schema_versions_record _dof_tuple_schema_versions;
257 
261  dof_tuple_schema_ids_record _dof_tuple_schema_ids;
262 
266  dof_tuple_col_bounds_record _dof_tuple_col_bounds;
267 
271  dof_tuple_domain_offsets_record _dof_tuple_domain_offsets;
272 };
273 
274 } // namespace sheaf
275 
276 #endif // ifndef ATTRIBUTES_RECORD_SET_H
277 
278 
279 
280 
281 
282 
An encapsulation of an HDF file containing sheaf data.
Definition: sheaf_file.h:49
A wrapper/adapter for the table dof tuple record. Intended for transferring data between the kernel a...
A wrapper/adapter for the dof tuple schema versions record. Intended for transferring index-version m...
A wrapper/adapter for the dof tuple class names record. Intended for transferring index-name map data...
A wrapper/adapter for the subposet names record. Intended for transferring subposet name data between...
A wrapper/adapter for the dof type types record. Intended for transferring dof tuple type id data bet...
Abstract base class with useful features for all objects.
Definition: any.h:39
A wrapper/adapter for the dof tuple schema ids record. Intended for transferring index-id map data be...
A wrapper/adapter for the member names record. Intended for transferring index-name map data between ...
char * hdf_buf_type
The type of hdf buffer.
A wrapper/adapter for the id space names record. Intended for transferring id map data between the ke...
An abstract, indexed collection of records on secondary storage.
Definition: record_set.h:150
A wrapper/adapter for the poset general attributes record. Intended for transferring data between the...
static const hsize_t TOC_BOUNDS_EXTENT
The extent of the table of contents lower bound attribute dataspace.
A record set for storing various poset attributes.
A wrapper/adapter for the dof tuple column bounds record. Intended for transferring index-bounds map ...
A wrapper/adapter for the member class names record. Intended for transferring index-name map data be...
Namespace for the sheaves component of the sheaf system.
A poset specific collection of data converters, various buffers and other data used while transferrin...
A wrapper/adapter for the dof tuple domain offsets record. Intended for transferring index-offsets ma...