|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnu.validator.xml.PrudentHttpEntityResolver
public class PrudentHttpEntityResolver
Field Summary | |
---|---|
private boolean |
acceptAllKnownXmlTypes
|
private boolean |
allowGenericXml
|
private boolean |
allowHtml
|
private boolean |
allowRnc
|
private boolean |
allowXhtml
|
private static org.apache.commons.httpclient.HttpClient |
client
|
private ContentTypeParser |
contentTypeParser
|
private ErrorHandler |
errorHandler
|
private com.hp.hpl.jena.iri.IRIFactory |
iriFactory
|
private boolean |
laxContentType
|
private static org.apache.log4j.Logger |
log4j
|
private static org.apache.commons.httpclient.MultiThreadedHttpConnectionManager |
manager
|
private static int |
maxRequests
|
private int |
requestsLeft
|
private int |
sizeLimit
|
Constructor Summary | |
---|---|
PrudentHttpEntityResolver(int sizeLimit,
boolean laxContentType,
ErrorHandler errorHandler)
|
Method Summary | |
---|---|
private String |
buildAccept()
|
boolean |
isAcceptAllKnownXmlTypes()
Returns the acceptAllKnownXmlTypes. |
boolean |
isAllowGenericXml()
Returns the allowGenericXml. |
boolean |
isAllowHtml()
Returns the allowHtml. |
boolean |
isAllowRnc()
|
boolean |
isAllowXhtml()
Returns the allowXhtml. |
boolean |
isOnlyHtmlAllowed()
|
InputSource |
resolveEntity(String publicId,
String systemId)
|
void |
setAcceptAllKnownXmlTypes(boolean acceptAllKnownXmlTypes)
Sets the acceptAllKnownXmlTypes. |
void |
setAllowGenericXml(boolean allowGenericXml)
Sets the allowGenericXml. |
void |
setAllowHtml(boolean allowHtml)
|
void |
setAllowRnc(boolean allowRnc)
|
void |
setAllowXhtml(boolean allowXhtml)
Sets the allowXhtml. |
static void |
setParams(int connectionTimeout,
int socketTimeout,
int maxRequests)
Sets the timeouts of the HTTP client. |
static void |
setUserAgent(String ua)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private static final org.apache.log4j.Logger log4j
private static final org.apache.commons.httpclient.MultiThreadedHttpConnectionManager manager
private static final org.apache.commons.httpclient.HttpClient client
private static int maxRequests
private int sizeLimit
private final ErrorHandler errorHandler
private int requestsLeft
private boolean laxContentType
private boolean allowRnc
private boolean allowHtml
private boolean allowXhtml
private boolean acceptAllKnownXmlTypes
private boolean allowGenericXml
private final com.hp.hpl.jena.iri.IRIFactory iriFactory
private final ContentTypeParser contentTypeParser
Constructor Detail |
---|
public PrudentHttpEntityResolver(int sizeLimit, boolean laxContentType, ErrorHandler errorHandler)
connectionTimeout
- socketTimeout
- sizeLimit
- Method Detail |
---|
public static void setParams(int connectionTimeout, int socketTimeout, int maxRequests)
connectionTimeout
- timeout until connection established in milliseconds. Zero
means no timeout.socketTimeout
- timeout for waiting for data in milliseconds. Zero means no
timeout.public static void setUserAgent(String ua)
public InputSource resolveEntity(String publicId, String systemId) throws SAXException, IOException
resolveEntity
in interface EntityResolver
SAXException
IOException
EntityResolver.resolveEntity(java.lang.String,
java.lang.String)
public boolean isAllowRnc()
public void setAllowRnc(boolean allowRnc)
allowRnc
- The allowRnc to set.public void setAllowHtml(boolean allowHtml)
b
- public boolean isAcceptAllKnownXmlTypes()
public void setAcceptAllKnownXmlTypes(boolean acceptAllKnownXmlTypes)
acceptAllKnownXmlTypes
- the acceptAllKnownXmlTypes to setpublic boolean isAllowGenericXml()
public void setAllowGenericXml(boolean allowGenericXml)
allowGenericXml
- the allowGenericXml to setpublic boolean isAllowXhtml()
public void setAllowXhtml(boolean allowXhtml)
allowXhtml
- the allowXhtml to setprivate String buildAccept()
public boolean isAllowHtml()
public boolean isOnlyHtmlAllowed()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |