diff options
author | Boris Kolpackov <boris@codesynthesis.com> | 2010-09-15 18:13:58 +0200 |
---|---|---|
committer | Boris Kolpackov <boris@codesynthesis.com> | 2010-09-15 18:13:58 +0200 |
commit | 9cfb5dcf71a5cb40b0b2fa6e7b8b633ba0ed5336 (patch) | |
tree | 226579119af69fba3bb93ba76edca1b916c49962 /hello/person.hxx | |
parent | 87991ad75cf0a33b2503dbb8725c3c6609254961 (diff) |
Expand the hello example
Diffstat (limited to 'hello/person.hxx')
-rw-r--r-- | hello/person.hxx | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/hello/person.hxx b/hello/person.hxx index 4730ff0..7a939c7 100644 --- a/hello/person.hxx +++ b/hello/person.hxx @@ -10,8 +10,9 @@ #include <odb/core.hxx> #pragma db object -struct person +class person { +public: person (const std::string& first, const std::string& last, unsigned short age) @@ -37,6 +38,12 @@ struct person return age_; } + void + age (unsigned short age) + { + age_ = age; + } + public: unsigned long id () const |