diff options
| author | jhurst <jhurst@cinecert.com> | 2010-02-23 19:27:43 +0000 |
|---|---|---|
| committer | jhurst <> | 2010-02-23 19:27:43 +0000 |
| commit | 7ef0e51f98ee95e28dfa18e163ca52e2278bdb00 (patch) | |
| tree | dd3a79dc9042b71684e50f4cf4ae4d447c4bd3cc /src | |
| parent | ca98d36fa24505430bdd26011838809e906b23ec (diff) | |
xercesC 3.x support
Diffstat (limited to 'src')
| -rwxr-xr-x | src/AS_DCP.h | 12 | ||||
| -rw-r--r-- | src/KM_xml.cpp | 8 | ||||
| -rw-r--r-- | src/Makefile.am | 2 |
3 files changed, 20 insertions, 2 deletions
diff --git a/src/AS_DCP.h b/src/AS_DCP.h index 9c9165f..a9f8b44 100755 --- a/src/AS_DCP.h +++ b/src/AS_DCP.h @@ -246,6 +246,18 @@ namespace ASDCP { inline bool operator!=(const Rational& rhs) const { return ( rhs.Numerator != Numerator || rhs.Denominator != Denominator ); } + + inline bool operator<(const Rational& rhs) { + if ( Numerator < rhs.Numerator ) return true; + if ( Numerator == rhs.Numerator && Denominator < rhs.Denominator ) return true; + return false; + } + + inline bool operator>(const Rational& rhs) { + if ( Numerator > rhs.Numerator ) return true; + if ( Numerator == rhs.Numerator && Denominator > rhs.Denominator ) return true; + return false; + } }; // common edit rates, use these instead of hard coded constants diff --git a/src/KM_xml.cpp b/src/KM_xml.cpp index 6f2092f..298a55f 100644 --- a/src/KM_xml.cpp +++ b/src/KM_xml.cpp @@ -762,7 +762,13 @@ Kumu::XMLElement::ParseString(const std::string& document) int errorCount = 0; SAXParser* parser = new SAXParser(); - parser->setDoValidation(true); + +// #if XERCES_VERSION_MAJOR < 3 +// parser->setDoValidation(true); +// #else + parser->setValidationScheme(SAXParser::Val_Always); +// #endif + parser->setDoNamespaces(true); // optional MyTreeHandler* docHandler = new MyTreeHandler(this); diff --git a/src/Makefile.am b/src/Makefile.am index 336867e..d718fc8 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -90,7 +90,7 @@ nodist_libpyasdcp_la_SOURCES = \ asdcp_python.cpp asdcp_python.h \ asdcp_python_descriptor.cpp \ asdcp_python_misc.cpp asdcp_python_writerinfo.h \ - asdcp_wrappers.h asdcp_python_mxf.cpp + asdcp_wrappers.h asdcp_python_mxf.cpp asdcp_python_mxf_text.cpp # asdcp_python_reader.cpp asdcp_python_writer.cpp |
