SheafSystem  0.0.0.0
standard_version_index.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 // Declarations for standard_version_index facet of namespace sheaf.
19 
20 #ifndef STANDARD_VERSION_INDEX_H
21 #define STANDARD_VERSION_INDEX_H
22 
23 #ifndef SHEAF_DLL_SPEC_H
24 #include "SheafSystem/sheaf_dll_spec.h"
25 #endif
26 
27 #ifndef STD_CLIMITS_H
28 #include "SheafSystem/std_climits.h"
29 #endif
30 
31 #ifndef POD_TYPES_H
32 #include "SheafSystem/pod_types.h"
33 #endif
34 
35 namespace sheaf
36 {
37 
42 {
43  STANDARD_VERSION_INDEX_BEGIN = -4, // Must be same a first std id.
44  CURRENT_MEMBER_VERSION = -4,
45  CURRENT_HOST_VERSION, // -3
46  COARSEST_COMMON_REFINEMENT_VERSION, // -2
47  STANDARD_VERSION_INDEX_END, // Must be one more than last std id.
48  NOT_A_STANDARD_VERSION_INDEX = INT_MAX
49 };
50 
55 
59 SHEAF_DLL_SPEC const std::string& standard_version_index_to_name(standard_version_index xpt);
60 
64 SHEAF_DLL_SPEC standard_version_index standard_version_index_from_name(const std::string& xname);
65 
70 
74 SHEAF_DLL_SPEC bool is_standard_version_index(pod_index_type xindex);
75 
76 } // namespace sheaf
77 
78 #endif // ifndef STANDARD_VERSION_INDEX_H
79 
80 
81 
82 
83 
84 
SHEAF_DLL_SPEC const std::string & standard_version_index_to_name(standard_version_index xpt)
The name of the enumerator xpt.
SHEAF_DLL_SPEC bool is_standard_version_index(pod_index_type xindex)
True if xindex is a valid primitive index.
standard_version_index
Ids for standard poset versions.
int_type pod_index_type
The plain old data index type.
Definition: pod_types.h:49
SHEAF_DLL_SPEC standard_version_index standard_version_index_from_index(pod_index_type xindex)
The enumerator corresponding to primitive index xindex.
Namespace for the sheaves component of the sheaf system.
SHEAF_DLL_SPEC namespace_member_index & operator++(namespace_member_index &x)
Prefix increment operator for namespace_member_index.
SHEAF_DLL_SPEC standard_version_index standard_version_index_from_name(const std::string &xname)
The enumerator with name xname.