user105033
user105033

Reputation: 19608

is there a C library for validating XML against a XML schema?

See question. Also any links to example code or example code on how to validate an xml file against multiple schemas would be helpful.

EDT: Sorry forgot to mention that this is for LINUX

Upvotes: 3

Views: 2406

Answers (2)

Phil Booth
Phil Booth

Reputation: 4897

libxml2 is portable, pure C and implements XML Schema. It is also open-source (MIT license) and has an active developer community.

Upvotes: 4

Dathan
Dathan

Reputation: 7456

If you're targeting Windows platforms, you can use MSXML, but your use case has to allow COM.

EDIT: Apache has an open-source XML library called Xerces-C++ that supports schema validation. It's not C-compatible, but if you can get away with using C++, it should do what you need.

Upvotes: 2

Related Questions