|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.xerces.impl.XMLScanner
org.apache.xerces.impl.XMLDocumentFragmentScannerImpl
public class XMLDocumentFragmentScannerImpl
This class is responsible for scanning the structure and content of document fragments. The scanner acts as the source for the document information which is communicated to the document handler.
This component requires the following features and properties from the component manager that uses it:
| Constructor Summary | |
|---|---|
XMLDocumentFragmentScannerImpl()
Default constructor. |
|
| Method Summary | |
|---|---|
void |
endEntity(java.lang.String name,
Augmentations augs)
This method notifies the end of an entity. |
java.lang.String |
getDispatcherName(org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.Dispatcher dispatcher)
Returns the dispatcher name. |
XMLDocumentHandler |
getDocumentHandler()
Returns the document handler |
java.lang.Boolean |
getFeatureDefault(java.lang.String featureId)
Returns the default state for a feature, or null if this component does not want to report a default value for this feature. |
java.lang.Object |
getPropertyDefault(java.lang.String propertyId)
Returns the default state for a property, or null if this component does not want to report a default value for this property. |
java.lang.String[] |
getRecognizedFeatures()
Returns a list of feature identifiers that are recognized by this component. |
java.lang.String[] |
getRecognizedProperties()
Returns a list of property identifiers that are recognized by this component. |
void |
reset(XMLComponentManager componentManager)
Resets the component. |
boolean |
scanDocument(boolean complete)
Scans a document. |
void |
setDocumentHandler(XMLDocumentHandler documentHandler)
setDocumentHandler |
void |
setFeature(java.lang.String featureId,
boolean state)
Sets the state of a feature. |
void |
setInputSource(XMLInputSource inputSource)
Sets the input source. |
void |
setProperty(java.lang.String propertyId,
java.lang.Object value)
Sets the value of a property. |
void |
startEntity(java.lang.String name,
XMLResourceIdentifier identifier,
java.lang.String encoding,
Augmentations augs)
This method notifies of the start of an entity. |
| Methods inherited from class org.apache.xerces.impl.XMLScanner |
|---|
getFeature, scanPseudoAttribute |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public XMLDocumentFragmentScannerImpl()
| Method Detail |
|---|
public void setInputSource(XMLInputSource inputSource)
throws java.io.IOException
setInputSource in interface XMLDocumentScannerinputSource - The input source.
java.io.IOException - Thrown on i/o error.
public boolean scanDocument(boolean complete)
throws java.io.IOException,
XNIException
scanDocument in interface XMLDocumentScannercomplete - True if the scanner should scan the document
completely, pushing all events to the registered
document handler. A value of false indicates that
that the scanner should only scan the next portion
of the document and return. A scanner instance is
permitted to completely scan a document if it does
not support this "pull" scanning model.
java.io.IOException
XNIException
public void reset(XMLComponentManager componentManager)
throws XMLConfigurationException
reset in interface XMLComponentreset in class XMLScannercomponentManager - The component manager.
SAXException - Thrown by component on initialization error.
For example, if a feature or property is
required for the operation of the component, the
component manager may throw a
SAXNotRecognizedException or a
SAXNotSupportedException.
XMLConfigurationExceptionpublic java.lang.String[] getRecognizedFeatures()
getRecognizedFeatures in interface XMLComponent
public void setFeature(java.lang.String featureId,
boolean state)
throws XMLConfigurationException
Note: Components should silently ignore features that do not affect the operation of the component.
setFeature in interface XMLComponentsetFeature in class XMLScannerfeatureId - The feature identifier.state - The state of the feature.
SAXNotRecognizedException - The component should not throw
this exception.
SAXNotSupportedException - The component should not throw
this exception.
XMLConfigurationException - Thrown for configuration error.
In general, components should
only throw this exception if
it is really
a critical error.public java.lang.String[] getRecognizedProperties()
getRecognizedProperties in interface XMLComponent
public void setProperty(java.lang.String propertyId,
java.lang.Object value)
throws XMLConfigurationException
Note: Components should silently ignore properties that do not affect the operation of the component.
setProperty in interface XMLComponentsetProperty in class XMLScannerpropertyId - The property identifier.value - The value of the property.
SAXNotRecognizedException - The component should not throw
this exception.
SAXNotSupportedException - The component should not throw
this exception.
XMLConfigurationException - Thrown for configuration error.
In general, components should
only throw this exception if
it is really
a critical error.public java.lang.Boolean getFeatureDefault(java.lang.String featureId)
getFeatureDefault in interface XMLComponentfeatureId - The feature identifier.public java.lang.Object getPropertyDefault(java.lang.String propertyId)
getPropertyDefault in interface XMLComponentpropertyId - The property identifier.public void setDocumentHandler(XMLDocumentHandler documentHandler)
setDocumentHandler in interface XMLDocumentSourcedocumentHandler - public XMLDocumentHandler getDocumentHandler()
getDocumentHandler in interface XMLDocumentSource
public void startEntity(java.lang.String name,
XMLResourceIdentifier identifier,
java.lang.String encoding,
Augmentations augs)
throws XNIException
startEntity in interface XMLEntityHandlerstartEntity in class XMLScannername - The name of the entity.identifier - The resource identifier.encoding - The auto-detected IANA encoding name of the entity
stream. This value will be null in those situations
where the entity encoding is not auto-detected (e.g.
internal entities or a document entity that is
parsed from a java.io.Reader).augs - Additional information that may include infoset augmentations
XNIException - Thrown by handler to signal an error.
public void endEntity(java.lang.String name,
Augmentations augs)
throws XNIException
endEntity in interface XMLEntityHandlerendEntity in class XMLScannername - The name of the entity.augs - Additional information that may include infoset augmentations
XNIException - Thrown by handler to signal an error.public java.lang.String getDispatcherName(org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.Dispatcher dispatcher)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||