diff options
| author | Carl Hetherington <cth@carlh.net> | 2012-07-30 23:47:57 +0100 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2012-07-30 23:47:57 +0100 |
| commit | 9a9d4e014c16be88d72914a9480343445bc785a5 (patch) | |
| tree | 1857fcdd8963d51ac50f1467d9ae81d4d9be5f8e /src/pkl.cc | |
| parent | 34a25d89b16a33b5f619ae0eaaa03c17f93980af (diff) | |
Various.
Diffstat (limited to 'src/pkl.cc')
| -rw-r--r-- | src/pkl.cc | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/src/pkl.cc b/src/pkl.cc new file mode 100644 index 00000000..b41fc185 --- /dev/null +++ b/src/pkl.cc @@ -0,0 +1,32 @@ +#include "pkl.h" + +using namespace std; +using namespace libdcp; + +PKL::PKL (string file) + : XMLFile (file, "PackingList") +{ + id = string_node ("Id"); + annotation_text = string_node ("AnnotationText"); + issue_date = string_node ("IssueDate"); + issuer = string_node ("Issuer"); + creator = string_node ("Creator"); + asset_list = sub_node<PKLAssetList> ("AssetList"); +} + +PKLAssetList::PKLAssetList (xmlpp::Node const * node) + : XMLNode (node) +{ + assets = sub_nodes<PKLAsset> ("Asset"); +} + +PKLAsset::PKLAsset (xmlpp::Node const * node) + : XMLNode (node) +{ + id = string_node ("Id"); + annotation_text = optional_string_node ("AnnotationText"); + hash = string_node ("Hash"); + size = int_node ("Size"); + type = string_node ("Type"); +} + |
