Oracle® XML API Reference
10g Release 1 (10.1) Part No. B10789-01 |
|
Table 18-3 summarizes the methods of available through the GParser
interface.
Table 18-3 Summary of GParser Methods; Parser Package
Function | Summary |
---|---|
SetWarnDuplicateEntity
|
Specifies if multiple entity declarations result in a warning. |
getBaseURI
|
Returns the base URI for the document. |
getDiscardWhitespaces
|
Checks if whitespaces between elements are discarded. |
getExpandCharRefs
|
Checks if character references are expanded. |
getSchemaLocation
|
Get schema location for this document. |
getStopOnWarning
|
Get if document processing stops on warnings. |
getWarnDuplicateEntity
|
Get if multiple entity declarations cause a warning. |
setBaseURI
|
Sets the base URI for the document. |
setDiscardWhitespaces
|
Sets if formatting whitespaces should be discarded. |
setExpandCharRefs
|
Get if character references are expanded. |
setSchemaLocation
|
Set schema location for this document. |
setStopOnWarning
|
Sets if document processing stops on warnings. |
Specifies if entities that are declared more than once will cause warnings to be issued.
void setWarnDuplicateEntity( boolean par_bool);
Parameter | Description |
---|---|
par_bool |
TRUE if multiple entity declarations cause a warning
|
Returns the base URI for the document. Usually only documents loaded from a URI will automatically have a base URI. Documents loaded from other sources (stdin
, buffer, and so on) will not naturally have a base URI, but a base URI may have been set for them using setBaseURI
, for the purposes of resolving relative URIs in inclusion.
oratext* getBaseURI() const;
(oratext *)
current document's base URI [or NULL
]
Checks if formatting whitespaces between elements, such as newlines and indentation in input documents are discarded. By default, all input characters are preserved.
boolean getDiscardWhitespaces() const;
(boolean)
TRUE
if whitespace between elements are discarded
Checks if character references are expanded in the DOM data. By default, character references are replaced by the character they represent. However, when a document is saved those characters entities do not reappear. To ensure they remain through load and save, they should not be expanded.
boolean getExpandCharRefs() const;
(boolean)
TRUE
if character references are expanded
Gets schema location for this document. It is used to figure out the optimal layout when loading documents into a database.
oratext* getSchemaLocation() const;
(oratext*)
schema location
When TRUE
is returned, warnings are treated the same as errors and cause parsing, validation, and so on, to stop immediately. By default, warnings are issued but the processing continues.
boolean getStopOnWarning() const;
(boolean)
TRUE
if document processing stops on warnings
Get if entities which are declared more than once will cause warnings to be issued.
boolean getWarnDuplicateEntity() const;
(boolean)
TRUE
if multiple entity declarations cause a warning
Sets the base URI for the document. Usually only documents that were loaded from a URI will automatically have a base URI. Documents loaded from other sources (stdin, buffer, and so on) will not naturally have a base URI, but a base URI may have been set for them using setBaseURI, for the purposes of resolving relative URIs in inclusion.
void setBaseURI( oratext* par);
Parameter | Description |
---|---|
par |
base URI |
Sets if formatting whitespaces between elements (newlines and indentation) in input documents are discarded. By default, ALL input characters are preserved.
void setDiscardWhitespaces( boolean par_bool);
Parameter | Description |
---|---|
par_bool |
TRUE if whitespaces should be discarded
|
Sets if character references should be expanded in the DOM data. Ordinarily, character references are replaced by the character they represent. However, when a document is saved those characters entities do not reappear. To ensure they remain through load and save is to not expand them.
void setExpandCharRefs( boolean par_bool);
Parameter | Description |
---|---|
par_bool |
TRUE if character references should be discarded
|
Sets schema location for this document. It is used to figure out the optimal layout when loading documents into a database.
void setSchemaLocation( oratext* par);
Parameter | Description |
---|---|
par |
schema location |
When TRUE
is set, warnings are treated the same as errors and cause parsing, validation, and so on, to stop immediately. By default, warnings are issued but the processing continues.
void setStopOnWarning( boolean par_bool);
Parameter | Description |
---|---|
par_bool |
TRUE if document processing should stop on warnings
|