|
org.netbeans.api.xml/1 1.14 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.netbeans.spi.xml.cookies.CheckXMLSupport
public class CheckXMLSupport
CheckXMLCookie implementation support simplifing cookie providers
based on InputSources representing XML documents and entities.
Primary use case in a DataObject subclass (which primary file is XML):
CookieSet cookies = getCookieSet(); InputSource in = DataObjectAdapters.inputSource(this); CheckXMLSupport cookieImpl = new CheckXMLSupport(in); cookies.add(cookieImpl);
Secondary use case: Subclasses can customize the class by customization protected methods. The customized subclass can be used according to primary use case.
| Field Summary | |
|---|---|
static int |
CHECK_ENTITY_MODE
General parsed entity strategy. |
static int |
CHECK_PARAMETER_ENTITY_MODE
Parameter parsed entity strategy. |
static int |
DOCUMENT_MODE
XML document entity strategy. |
| Constructor Summary | |
|---|---|
CheckXMLSupport(InputSource inputSource)
Create new CheckXMLSupport for given data object using DOCUMENT_MODE strategy. |
|
CheckXMLSupport(InputSource inputSource,
int strategy)
Create new CheckXMLSupport for given data object. |
|
| Method Summary | |
|---|---|
boolean |
checkXML(CookieObserver l)
Check XML parsed entity for syntax wellformedness. |
protected EntityResolver |
createEntityResolver()
Parametrizes default parser creatin process. |
protected InputSource |
createInputSource()
Create InputSource to be checked. |
protected XMLReader |
createParser(boolean validate)
Create and preconfigure new parser. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final int CHECK_ENTITY_MODE
public static final int CHECK_PARAMETER_ENTITY_MODE
public static final int DOCUMENT_MODE
| Constructor Detail |
|---|
public CheckXMLSupport(InputSource inputSource)
inputSource - Supported data object.public CheckXMLSupport(InputSource inputSource, int strategy)
inputSource - Supported data object.strategy - One of *_MODE constants.| Method Detail |
|---|
public boolean checkXML(CookieObserver l)
CheckXMLCookie
checkXML in interface CheckXMLCookiel - optional listener (null allowed)
giving judgement details via XMLProcessorDetails.
true if syntax check passesprotected EntityResolver createEntityResolver()
nullprotected InputSource createInputSource() throws IOException
null
IOException - if I/O error occurs.protected XMLReader createParser(boolean validate)
validate - true if validation module is required
nullcreateEntityResolver()
|
org.netbeans.api.xml/1 1.14 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||