From a15cf65c44d5c224169c32ef5495b68c758134b7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Frings-F=C3=BCrst?= Date: Sun, 18 May 2014 16:08:14 +0200 Subject: Imported Upstream version 3.3.0.2 --- .../cxx/parser/multiroot/protocol-pimpl.cxx | 47 ++++++++++++++++++++++ 1 file changed, 47 insertions(+) create mode 100644 xsd/examples/cxx/parser/multiroot/protocol-pimpl.cxx (limited to 'xsd/examples/cxx/parser/multiroot/protocol-pimpl.cxx') diff --git a/xsd/examples/cxx/parser/multiroot/protocol-pimpl.cxx b/xsd/examples/cxx/parser/multiroot/protocol-pimpl.cxx new file mode 100644 index 0000000..09a04b3 --- /dev/null +++ b/xsd/examples/cxx/parser/multiroot/protocol-pimpl.cxx @@ -0,0 +1,47 @@ +// file : examples/cxx/parser/multiroot/protocol-pimpl.cxx +// author : Boris Kolpackov +// copyright : not copyrighted - public domain + +#include "protocol-pimpl.hxx" + +namespace protocol +{ + // request_pimpl + // + void request_pimpl:: + account (unsigned int account) + { + account_ = account; + } + + request* request_pimpl:: + post_request () + { + // This parser is never used directly. + // + return 0; + } + + // balance_pimpl + // + balance* balance_pimpl:: + post_balance () + { + return new balance (account_); + } + + // withdraw_pimpl + // + void withdraw_pimpl:: + amount (unsigned int amount) + { + amount_ = amount; + } + + withdraw* withdraw_pimpl:: + post_withdraw () + { + return new withdraw (account_, amount_); + } +} + -- cgit v1.2.3