diff options
| author | Carl Hetherington <cth@carlh.net> | 2015-05-29 19:13:28 +0100 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2015-05-29 19:13:28 +0100 |
| commit | b7cc4f18961bd067d8d23df854c245bd99b2deeb (patch) | |
| tree | 7c97e960b94953bc40b357bf3735f3bcec446ee3 | |
| parent | 52ec7394f0d7cbfb3063ff91b415245936d84b13 (diff) | |
Use markdown for README.
| -rw-r--r-- | README | 38 | ||||
| -rw-r--r-- | README.md | 38 |
2 files changed, 38 insertions, 38 deletions
@@ -1,38 +0,0 @@ -libcxml -------- - -This is a very small library which provides a slightly tidier -C++ API than libxml++ for parsing HTML. - -For example: - -cxml::Document doc ("RootNodeName"); -doc.read ("foo.xml"); - -/* Get the contents of child node <Fred>, throwing an - * exception if it does not exist - */ -string s = doc.string_child ("Fred"); - -/* Get the contents of child node <Jim>, or 42 if it - * does not exist - */ -int i = doc.optional_number_child<int> ("Jim").get_value_or (42); - -/* Get the contents of <Roger> within <Sheila>, - * throwing an exception if either node - * is not present. - */ -double d = doc.node_child("Sheila").number_child<double> ("Roger"); - -For full details, see src/cxml.h - -To build: -./waf configure -./waf build -sudo ./waf install - -Bug reports and queries to Carl Hetherington <cth@carlh.net> - - - diff --git a/README.md b/README.md new file mode 100644 index 0000000..3d4da80 --- /dev/null +++ b/README.md @@ -0,0 +1,38 @@ +libcxml +======= + +This is a very small library which provides a slightly tidier +C++ API than libxml++ for parsing HTML. + +For example: + + cxml::Document doc ("RootNodeName"); + doc.read ("foo.xml"); + + /* Get the contents of child node <Fred>, throwing an + * exception if it does not exist + */ + string s = doc.string_child ("Fred"); + + /* Get the contents of child node <Jim>, or 42 if it + * does not exist + */ + int i = doc.optional_number_child<int> ("Jim").get_value_or (42); + + /* Get the contents of <Roger> within <Sheila>, + * throwing an exception if either node + * is not present. + */ + double d = doc.node_child("Sheila").number_child<double> ("Roger"); + +For full details, see src/cxml.h + +To build: +./waf configure +./waf build +sudo ./waf install + +Bug reports and queries to Carl Hetherington <cth@carlh.net> + + + |
