-
Notifications
You must be signed in to change notification settings - Fork 1
srcML/srcSAX
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
srcML SAX2Framework Framework provides a simplified sax2 interface built off of libxml2 library for srcML documents. The framework automatically handles srcML archives and non-archives. srcMLControlHandler provides the control mechanism inwhich to setup and parse a srcML file. User specific handling is specified through inheriting from the srcMLHandler which is supplied to the parse method. SAX2srcMLHandler implements the actual libxml2 parts and calls the necessary handler functions from srcMLHandler. startDocument and endDocument are called exactly once. startRoot and endRoot are also called exactly once for the begining and ending of the root element. startUnit and endUnit are called once each for each inner unit. All other open and closing tags are handled by startElementNs and endElementNs. Character data is handled by charactersRoot called for characters that occur directly within a root tag between units, and charactersUnit which is called for all character data occuring within a unit. Two additional function comment and cdataBlock are called when their XML equivalents are encountered, however, these are not generally included in srcML documents. Overide methods to get the intended behaviour. Parsing can be stopped at any point by calling stop_parser. For usage examples, including running in a separate thread see examples. Author: Michael John Decker Email: [email protected]
About
Simple API for XML (SAX) implementation specialized for srcML
Resources
Stars
Watchers
Forks
Releases
No releases published
Packages 0
No packages published