|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.xml.sax.helpers.XMLFilterImpl nbi.xmlsec.biocase.protocol.filter.ProtocolFilter nbi.xmlsec.biocase.protocol.filter.DiagnosticsFilter
This class parses a BioCASE diagnostics from a SAX stream.
All SAX events are forwarded to the defined ContentHandler. The parsed
Diagnostics
may be retrieved with
getDiagnostics()
.
Field Summary | |
(package private) Diagnostics |
diagnostics
The parsed BioCASE diagnostics |
private boolean |
firstElement
Signals if the first diagnostic subelement has been written |
static String |
LN_DIAGNOSTIC
Local name of the element diagnostic |
static String |
LN_DIAGNOSTIC_CODE
Local name of the attribute code of the element
diagnostic |
static String |
LN_DIAGNOSTIC_SEVERITY
Local name of the attribute severity of the element
diagnostic |
static String |
LN_ROOT
Local name of the root element diagnostics |
(package private) static int |
trackMode
Track mode for the filter stack |
Fields inherited from class nbi.xmlsec.biocase.protocol.filter.ProtocolFilter |
elementStack, filterMode, FILTERMODE_FILTER, FILTERMODE_NONE, FILTERMODE_PARSER, filterRoot, logger, PROT_URI_13, PROT_URI_20 |
Fields inherited from class org.xml.sax.helpers.XMLFilterImpl |
|
Constructor Summary | |
DiagnosticsFilter(String protocolURI,
int filterMode)
Inits the filter instance. |
|
DiagnosticsFilter(XMLReader parent,
String protocolURI,
int filterMode)
Inits the filter instance with specified parent. |
Method Summary | |
Diagnostics |
addDiagnostics(Diagnostics diagnostics)
Adds diagnostics, and creates them when null. |
protected nbi.xml.sax.SAXElement |
filterElement(nbi.xml.sax.SAXElement element)
Writes predefined Diagnostics to the content handler. |
Diagnostics |
getDiagnostics()
Gets the diagnostics |
protected void |
initSubFilter()
Registers subfilters for subelements. |
protected nbi.xml.sax.SAXElement |
parseElement(nbi.xml.sax.SAXElement element)
Parses a Diagnostic treeElements and adds it to the Diagnostics. |
protected nbi.xml.sax.SAXElement |
parseInit(nbi.xml.sax.SAXElement element)
Initialises Diagnostics |
void |
writeDiagnostics()
Write diagnostics to the content handler. |
Methods inherited from class nbi.xmlsec.biocase.protocol.filter.ProtocolFilter |
characters, checkFilterParameter, endElement, filterCharacters, getFilterMode, getFilterParameter, getProtocolURI, isParsingComplete, parseComplete, registerSubFilter, setFilterParameter, setProtocolURI, startElement, unregisterSubFilter |
Methods inherited from class org.xml.sax.helpers.XMLFilterImpl |
endDocument, endPrefixMapping, error, fatalError, getContentHandler, getDTDHandler, getEntityResolver, getErrorHandler, getFeature, getParent, getProperty, ignorableWhitespace, notationDecl, parse, parse, processingInstruction, resolveEntity, setContentHandler, setDocumentLocator, setDTDHandler, setEntityResolver, setErrorHandler, setFeature, setParent, setProperty, skippedEntity, startDocument, startPrefixMapping, unparsedEntityDecl, warning |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static String LN_ROOT
diagnostics
public static final String LN_DIAGNOSTIC
diagnostic
public static final String LN_DIAGNOSTIC_CODE
code
of the element
diagnostic
public static final String LN_DIAGNOSTIC_SEVERITY
severity
of the element
diagnostic
static final int trackMode
Diagnostics diagnostics
private boolean firstElement
Constructor Detail |
public DiagnosticsFilter(String protocolURI, int filterMode)
protocolURI
- protocol version URI of this filter.filterMode
- filterMode of this filter
ProtocolFilter.filterMode
.public DiagnosticsFilter(XMLReader parent, String protocolURI, int filterMode)
parent
- parent reader.protocolURI
- protocol version URI of this filter.filterMode
- filterMode of this filter
ProtocolFilter.filterMode
.Method Detail |
protected void initSubFilter()
protected nbi.xml.sax.SAXElement filterElement(nbi.xml.sax.SAXElement element) throws SAXException
filterElement
in class ProtocolFilter
element
- The element corresponding to the startElement event.
SAXException
- If any parsing error occurs.ProtocolFilter.filterElement(SAXElement)
protected nbi.xml.sax.SAXElement parseElement(nbi.xml.sax.SAXElement element) throws SAXException
parseElement
in class ProtocolFilter
element
- The element corresponding to the endElement event.
SAXException
- If any parsing error occurs.ProtocolFilter.parseElement(SAXElement)
protected nbi.xml.sax.SAXElement parseInit(nbi.xml.sax.SAXElement element) throws SAXException
parseInit
in class ProtocolFilter
element
- The element of the startElement event (contains no value).
SAXException
- If any parsing error occurs.ProtocolFilter.parseInit(SAXElement)
public Diagnostics getDiagnostics()
public Diagnostics addDiagnostics(Diagnostics diagnostics)
public void writeDiagnostics() throws SAXException
SAXException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |