站内搜索: 请输入搜索关键词
当前页面: 在线文档首页 > JBoss 3.2.7 system API Documentation 英文版文档

JBossEntityResolver (JBoss System API) - JBoss 3.2.7 system API Documentation 英文版文档


org.jboss.deployment
Class JBossEntityResolver

java.lang.Object
  extended byorg.jboss.deployment.JBossEntityResolver
All Implemented Interfaces:
EntityResolver

public class JBossEntityResolver
extends Object
implements EntityResolver

Local entity resolver to handle standard J2EE DTDs as well as JBoss specific DTDs. Function boolean hadDTD() is here to avoid validation errors in descriptors that do not have a DOCTYPE declaration.

Version:
$Revision: 1.3.2.6 $
Author:
Scott.Stark@jboss.org

Constructor Summary
JBossEntityResolver()
          Register the mapping of the DOCTYPE public ID names to the DTD file
 
Method Summary
 boolean hasDTD()
          Returns the boolean value to inform id DTD was found in the XML file or not
static void registerDTD(String publicId, String dtdFileName)
          Register the mapping from the public id to the dtd file name.
 InputSource resolveEntity(String publicId, String systemId)
          Returns DTD inputSource.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JBossEntityResolver

public JBossEntityResolver()
Register the mapping of the DOCTYPE public ID names to the DTD file

Method Detail

registerDTD

public static void registerDTD(String publicId,
                               String dtdFileName)
Register the mapping from the public id to the dtd file name.

Parameters:
publicId - the DOCTYPE public id, "-//Sun Microsystems, Inc.//DTD Enterprise JavaBeans 1.1//EN"
dtdFileName - the simple dtd file name, "ejb-jar.dtd"

resolveEntity

public InputSource resolveEntity(String publicId,
                                 String systemId)
Returns DTD inputSource. If DTD was found in the hashtable and inputSource was created flag hasDTD is set to true.

Specified by:
resolveEntity in interface EntityResolver
Parameters:
publicId - - Public ID of DTD
systemId - - the system ID of DTD
Returns:
InputSource of DTD

hasDTD

public boolean hasDTD()
Returns the boolean value to inform id DTD was found in the XML file or not

Returns:
boolean - true if DTD was found in XML


Copyright © 2002 JBoss Group, LLC. All Rights Reserved.