diff options
author | Boris Kolpackov <boris@codesynthesis.com> | 2009-03-16 08:16:43 +0200 |
---|---|---|
committer | Boris Kolpackov <boris@codesynthesis.com> | 2009-03-16 08:16:43 +0200 |
commit | bce9d5a76072ec697ef69021818aa68709036da5 (patch) | |
tree | 9ec56eff60abacaea121d1602a1e48388ca34216 /examples/cxx/hybrid/custom/wildcard/body.cxx | |
parent | be19f3aae4e16b4dc9c980cb9b53e807616662ef (diff) |
Add support for type customization in C++/Hybrid
examples/cxx/hybrid/custom/wildcard/: new example
Diffstat (limited to 'examples/cxx/hybrid/custom/wildcard/body.cxx')
-rw-r--r-- | examples/cxx/hybrid/custom/wildcard/body.cxx | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/examples/cxx/hybrid/custom/wildcard/body.cxx b/examples/cxx/hybrid/custom/wildcard/body.cxx new file mode 100644 index 0000000..170aba3 --- /dev/null +++ b/examples/cxx/hybrid/custom/wildcard/body.cxx @@ -0,0 +1,20 @@ +// file : examples/cxx/hybrid/custom/wildcard/body.cxx +// author : Boris Kolpackov <boris@codesynthesis.com> +// copyright : not copyrighted - public domain + +#include "body.hxx" + +namespace email +{ + void body:: + body_type (body::type t) + { + if (body_type_ == type_binary) + { + delete binary_; + binary_ = 0; + } + + body_type_ = t; + } +} |