#include <librets/RetsXmlParser.h>
Public Member Functions | |
virtual | ~RetsXmlParser () |
virtual bool | HasNext ()=0 |
Indicates whether or not there are additional element to be parsed in this data stream. | |
virtual RetsXmlEventPtr | GetNextEvent ()=0 |
Returns next XML event, blocking if necessary. | |
RetsXmlEventListPtr | GetEventList () |
Returns all remaining events as a vector. | |
RetsXmlEventPtr | GetNextSkippingEmptyText () |
RetsXmlEventListPtr | GetEventListSkippingEmptyText () |
Returns all remaining events as a vector, ingoring all empty text events. | |
RetsXmlStartElementEventPtr | AssertNextIsStartEvent (std::string prefix="") |
Assert that the next event is a start element event. | |
RetsXmlEndElementEventPtr | AssertNextIsEndEvent (std::string prefix="") |
Assert that the next event is an end element event. | |
RetsXmlTextEventPtr | AssertNextIsTextEvent (std::string prefix="") |
Assert that the next event is a text element event. | |
RetsXmlEndDocumentEventPtr | AssertNextIsEndDocumentEvent (std::string prefix="") |
Assert that the next event is the end document event. | |
Static Public Member Functions | |
static RetsXmlParserPtr | CreateDefault (istreamPtr inputStream) |
Create a default XML parser around the speicified input stream. | |
static RetsXmlStartElementEventPtr | AssertStartEvent (RetsXmlEventPtr event, std::string prefix="") |
Assert that the event is a start element event. | |
static RetsXmlEndElementEventPtr | AssertEndEvent (RetsXmlEventPtr event, std::string prefix="") |
Assert that the event is an end element event. | |
static RetsXmlTextEventPtr | AssertTextEvent (RetsXmlEventPtr event, std::string prefix="") |
Assert that the event is a text element event. | |
static RetsXmlEndDocumentEventPtr | AssertEndDocumentEvent (RetsXmlEventPtr event, std::string prefix="") |
Assert that the event is the end document event. |
virtual ~RetsXmlParser | ( | ) | [virtual] |
static RetsXmlEndDocumentEventPtr AssertEndDocumentEvent | ( | RetsXmlEventPtr | event, | |
std::string | prefix = "" | |||
) | [static] |
Assert that the event is the end document event.
event | A pointer to the object containing the event. | |
prefix | A string to be included when reporting errors. |
RetsException | If the element is not the end document event. |
static RetsXmlEndElementEventPtr AssertEndEvent | ( | RetsXmlEventPtr | event, | |
std::string | prefix = "" | |||
) | [static] |
Assert that the event is an end element event.
event | A pointer to the object containing the event. | |
prefix | A string to be included when reporting errors. |
RetsException | If the next element is not an end event. |
RetsXmlEndDocumentEventPtr AssertNextIsEndDocumentEvent | ( | std::string | prefix = "" |
) |
Assert that the next event is the end document event.
A side effect of this call is that the next element in the input stream is parsed.
prefix | A string to be included when reporting errors. |
RetsException | if the next element is not the end document event. |
RetsXmlEndElementEventPtr AssertNextIsEndEvent | ( | std::string | prefix = "" |
) |
Assert that the next event is an end element event.
A side effect of this call is that the next element in the input stream is parsed.
prefix | A string to be included when reporting errors. |
RetsException | if the next element is not an end event. |
RetsXmlStartElementEventPtr AssertNextIsStartEvent | ( | std::string | prefix = "" |
) |
Assert that the next event is a start element event.
A side effect of this call is that the next element in the input stream is parsed.
prefix | A string to be included when reporting errors. |
RetsException | if the next element is not a start event. |
RetsXmlTextEventPtr AssertNextIsTextEvent | ( | std::string | prefix = "" |
) |
Assert that the next event is a text element event.
A side effect of this call is that the next element in the input stream is parsed.
prefix | A string to be included when reporting errors. |
RetsException | if the next element is not a text event. |
static RetsXmlStartElementEventPtr AssertStartEvent | ( | RetsXmlEventPtr | event, | |
std::string | prefix = "" | |||
) | [static] |
Assert that the event is a start element event.
event | A pointer to the object containing the event. | |
prefix | A string to be included when reporting errors. |
RetsException | if the element is not a start event. |
static RetsXmlTextEventPtr AssertTextEvent | ( | RetsXmlEventPtr | event, | |
std::string | prefix = "" | |||
) | [static] |
Assert that the event is a text element event.
event | A pointer to the object containing the event. | |
prefix | A string to be included when reporting errors. |
RetsException | If the element is not a text event. |
static RetsXmlParserPtr CreateDefault | ( | istreamPtr | inputStream | ) | [static] |
Create a default XML parser around the speicified input stream.
inputStream | A pointer to the input stream to be parsed. |
RetsXmlEventListPtr GetEventList | ( | ) |
Returns all remaining events as a vector.
RetsXmlEventListPtr GetEventListSkippingEmptyText | ( | ) |
Returns all remaining events as a vector, ingoring all empty text events.
virtual RetsXmlEventPtr GetNextEvent | ( | ) | [pure virtual] |
Returns next XML event, blocking if necessary.
RetsException |
Implemented in ExpatXmlParser.
RetsXmlEventPtr GetNextSkippingEmptyText | ( | ) |
virtual bool HasNext | ( | ) | [pure virtual] |
Indicates whether or not there are additional element to be parsed in this data stream.
Implemented in ExpatXmlParser.