diff options
Diffstat (limited to 'odb/context.hxx')
-rw-r--r-- | odb/context.hxx | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/odb/context.hxx b/odb/context.hxx index fe9b533..d148a97 100644 --- a/odb/context.hxx +++ b/odb/context.hxx @@ -257,6 +257,15 @@ struct member_access // necessarily mean that it is by reference. }; +// +// +struct model_version +{ + unsigned long long base; + unsigned long long current; + bool open; +}; + class context { public: @@ -581,6 +590,20 @@ public: return c.get<semantics::data_member*> ("discriminator", 0); } + // Model version. + // + bool + versioned () const + { + return unit.count ("model-version") != 0; + } + + model_version const& + version () const + { + return unit.get<model_version> ("model-version"); + } + // // typedef ::class_kind class_kind_type; |