Associate the specified location with the XSD document in the specified schema stream. Return 0 on success and non-zero on error. This method may be called more than once to add multiple location-schema associations to a pre-resolved schema cache. During XML validation, a reference to a schema with a specific location will be looked up in the schema cache. Only if this resolution fails, is the schema resolver used to find the external schema. (See setResolver in the Reader base class.) The effects of calling this method when the reader is already open is not specified and a derived class implementation may treat it as an error. The behavior is undefined unless schema is a repositionable stream (i.e., it must be possible to read from the stream, then seek to the beginning of the stream and read the same bytes again.)
Declared in <balxml_validatingreader.h>
virtual
int
addSchema(
char const* location,
std::streambuf* schema) = 0;