本文整理汇总了Java中com.sun.org.apache.xerces.internal.xni.parser.XMLComponentManager类的典型用法代码示例。如果您正苦于以下问题:Java XMLComponentManager类的具体用法?Java XMLComponentManager怎么用?Java XMLComponentManager使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
XMLComponentManager类属于com.sun.org.apache.xerces.internal.xni.parser包,在下文中一共展示了XMLComponentManager类的12个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。
示例1: XMLGrammarCachingConfiguration
import com.sun.org.apache.xerces.internal.xni.parser.XMLComponentManager; //导入依赖的package包/类
/**
* Constructs a parser configuration using the specified symbol table,
* grammar pool, and parent settings.
* <p>
* <strong>REVISIT:</strong>
* Grammar pool will be updated when the new validation engine is
* implemented.
*
* @param symbolTable The symbol table to use.
* @param grammarPool The grammar pool to use.
* @param parentSettings The parent settings.
*/
public XMLGrammarCachingConfiguration(SymbolTable symbolTable,
XMLGrammarPool grammarPool,
XMLComponentManager parentSettings) {
super(symbolTable, grammarPool, parentSettings);
// REVISIT: may need to add some features/properties
// specific to this configuration at some point...
// add default recognized features
// set state for default features
// add default recognized properties
// create and register missing components
fSchemaLoader = new XMLSchemaLoader(fSymbolTable);
fSchemaLoader.setProperty(XMLGRAMMAR_POOL, fGrammarPool);
// and set up the DTD loader too:
fDTDLoader = new XMLDTDLoader(fSymbolTable, fGrammarPool);
}
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:31,代码来源:XMLGrammarCachingConfiguration.java
示例2: SchemaValidatorConfiguration
import com.sun.org.apache.xerces.internal.xni.parser.XMLComponentManager; //导入依赖的package包/类
public SchemaValidatorConfiguration(XMLComponentManager parentManager,
XSGrammarPoolContainer grammarContainer, ValidationManager validationManager) {
fParentComponentManager = parentManager;
fGrammarPool = grammarContainer.getGrammarPool();
fUseGrammarPoolOnly = grammarContainer.isFullyComposed();
fValidationManager = validationManager;
// add schema message formatter to error reporter
try {
XMLErrorReporter errorReporter = (XMLErrorReporter) fParentComponentManager.getProperty(ERROR_REPORTER);
if (errorReporter != null) {
errorReporter.putMessageFormatter(XSMessageFormatter.SCHEMA_DOMAIN, new XSMessageFormatter());
}
}
// Ignore exception.
catch (XMLConfigurationException exc) {}
}
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:17,代码来源:SchemaValidatorConfiguration.java
示例3: reset
import com.sun.org.apache.xerces.internal.xni.parser.XMLComponentManager; //导入依赖的package包/类
/**
* Resets the component. The component can query the component manager
* about any features and properties that affect the operation of the
* component.
*
* @param componentManager The component manager.
*
* @throws 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.
*/
public void reset(XMLComponentManager componentManager)
throws XMLConfigurationException {
//System.out.println(" this is being called");
// xerces features
fAllowJavaEncodings = componentManager.getFeature(ALLOW_JAVA_ENCODINGS, false);
//xerces properties
fSymbolTable = (SymbolTable)componentManager.getProperty(SYMBOL_TABLE);
fErrorReporter = (XMLErrorReporter)componentManager.getProperty(ERROR_REPORTER);
fCurrentEntity = null;
whiteSpaceLen = 0;
whiteSpaceInfoNeeded = true;
listeners.clear();
}
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:30,代码来源:XMLEntityScanner.java
示例4: copyFeatures1
import com.sun.org.apache.xerces.internal.xni.parser.XMLComponentManager; //导入依赖的package包/类
private void copyFeatures1(
Enumeration features,
String featurePrefix,
XMLComponentManager from,
ParserConfigurationSettings to) {
while (features.hasMoreElements()) {
String featureId = featurePrefix + (String)features.nextElement();
to.addRecognizedFeatures(new String[] { featureId });
try {
to.setFeature(featureId, from.getFeature(featureId));
}
catch (XMLConfigurationException e) {
// componentManager doesn't support this feature,
// so we won't worry about it
}
}
}
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:20,代码来源:XIncludeHandler.java
示例5: XPointerParserConfiguration
import com.sun.org.apache.xerces.internal.xni.parser.XMLComponentManager; //导入依赖的package包/类
/**
* Constructs a parser configuration using the specified symbol table,
* grammar pool, and parent settings.
* <p>
*
* @param symbolTable The symbol table to use.
* @param grammarPool The grammar pool to use.
* @param parentSettings The parent settings.
*/
public XPointerParserConfiguration(
SymbolTable symbolTable,
XMLGrammarPool grammarPool,
XMLComponentManager parentSettings) {
super(symbolTable, grammarPool, parentSettings);
fXIncludeHandler = new XIncludeHandler();
addCommonComponent(fXIncludeHandler);
fXPointerHandler = new XPointerHandler();
addCommonComponent(fXPointerHandler);
final String[] recognizedFeatures = {
ALLOW_UE_AND_NOTATION_EVENTS,
XINCLUDE_FIXUP_BASE_URIS,
XINCLUDE_FIXUP_LANGUAGE
};
addRecognizedFeatures(recognizedFeatures);
// add default recognized properties
final String[] recognizedProperties =
{ XINCLUDE_HANDLER, XPOINTER_HANDLER, NAMESPACE_CONTEXT };
addRecognizedProperties(recognizedProperties);
setFeature(ALLOW_UE_AND_NOTATION_EVENTS, true);
setFeature(XINCLUDE_FIXUP_BASE_URIS, true);
setFeature(XINCLUDE_FIXUP_LANGUAGE, true);
setProperty(XINCLUDE_HANDLER, fXIncludeHandler);
setProperty(XPOINTER_HANDLER, fXPointerHandler);
setProperty(NAMESPACE_CONTEXT, new XIncludeNamespaceSupport());
}
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:44,代码来源:XPointerParserConfiguration.java
示例6: XIncludeParserConfiguration
import com.sun.org.apache.xerces.internal.xni.parser.XMLComponentManager; //导入依赖的package包/类
/**
* Constructs a parser configuration using the specified symbol table,
* grammar pool, and parent settings.
* <p>
*
* @param symbolTable The symbol table to use.
* @param grammarPool The grammar pool to use.
* @param parentSettings The parent settings.
*/
public XIncludeParserConfiguration(
SymbolTable symbolTable,
XMLGrammarPool grammarPool,
XMLComponentManager parentSettings) {
super(symbolTable, grammarPool, parentSettings);
fXIncludeHandler = new XIncludeHandler();
addCommonComponent(fXIncludeHandler);
final String[] recognizedFeatures = {
ALLOW_UE_AND_NOTATION_EVENTS,
XINCLUDE_FIXUP_BASE_URIS,
XINCLUDE_FIXUP_LANGUAGE
};
addRecognizedFeatures(recognizedFeatures);
// add default recognized properties
final String[] recognizedProperties =
{ XINCLUDE_HANDLER, NAMESPACE_CONTEXT };
addRecognizedProperties(recognizedProperties);
setFeature(ALLOW_UE_AND_NOTATION_EVENTS, true);
setFeature(XINCLUDE_FIXUP_BASE_URIS, true);
setFeature(XINCLUDE_FIXUP_LANGUAGE, true);
setProperty(XINCLUDE_HANDLER, fXIncludeHandler);
setProperty(NAMESPACE_CONTEXT, new XIncludeNamespaceSupport());
}
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:38,代码来源:XIncludeParserConfiguration.java
示例7: XIncludeAwareParserConfiguration
import com.sun.org.apache.xerces.internal.xni.parser.XMLComponentManager; //导入依赖的package包/类
/**
* Constructs a parser configuration using the specified symbol table,
* grammar pool, and parent settings.
* <p>
*
* @param symbolTable The symbol table to use.
* @param grammarPool The grammar pool to use.
* @param parentSettings The parent settings.
*/
public XIncludeAwareParserConfiguration(
SymbolTable symbolTable,
XMLGrammarPool grammarPool,
XMLComponentManager parentSettings) {
super(symbolTable, grammarPool, parentSettings);
final String[] recognizedFeatures = {
ALLOW_UE_AND_NOTATION_EVENTS,
XINCLUDE_FIXUP_BASE_URIS,
XINCLUDE_FIXUP_LANGUAGE
};
addRecognizedFeatures(recognizedFeatures);
// add default recognized properties
final String[] recognizedProperties =
{ XINCLUDE_HANDLER, NAMESPACE_CONTEXT };
addRecognizedProperties(recognizedProperties);
setFeature(ALLOW_UE_AND_NOTATION_EVENTS, true);
setFeature(XINCLUDE_FIXUP_BASE_URIS, true);
setFeature(XINCLUDE_FIXUP_LANGUAGE, true);
fNonXIncludeNSContext = new NamespaceSupport();
fCurrentNSContext = fNonXIncludeNSContext;
setProperty(NAMESPACE_CONTEXT, fNonXIncludeNSContext);
}
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:36,代码来源:XIncludeAwareParserConfiguration.java
示例8: IntegratedParserConfiguration
import com.sun.org.apache.xerces.internal.xni.parser.XMLComponentManager; //导入依赖的package包/类
/**
* Constructs a parser configuration using the specified symbol table,
* grammar pool, and parent settings.
* <p>
* <strong>REVISIT:</strong>
* Grammar pool will be updated when the new validation engine is
* implemented.
*
* @param symbolTable The symbol table to use.
* @param grammarPool The grammar pool to use.
* @param parentSettings The parent settings.
*/
public IntegratedParserConfiguration(SymbolTable symbolTable,
XMLGrammarPool grammarPool,
XMLComponentManager parentSettings) {
super(symbolTable, grammarPool, parentSettings);
// create components
fNonNSScanner = new XMLDocumentScannerImpl();
fNonNSDTDValidator = new XMLDTDValidator();
// add components
addComponent((XMLComponent)fNonNSScanner);
addComponent((XMLComponent)fNonNSDTDValidator);
}
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:27,代码来源:IntegratedParserConfiguration.java
示例9: reset
import com.sun.org.apache.xerces.internal.xni.parser.XMLComponentManager; //导入依赖的package包/类
public void reset(XMLComponentManager componentManager) throws XMLConfigurationException {
// obtain references from the manager
fSymbolTable = (SymbolTable)componentManager.getProperty(SYMBOL_TABLE);
fErrorReporter = (XMLErrorReporter)componentManager.getProperty(ERROR_REPORTER);
try {
fEntityResolver = (XMLEntityResolver) componentManager.getProperty(ENTITY_MANAGER);
}
catch (XMLConfigurationException e) {
fEntityResolver = null;
}
}
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:12,代码来源:JAXPValidatorComponent.java
示例10: ParserConfigurationSettings
import com.sun.org.apache.xerces.internal.xni.parser.XMLComponentManager; //导入依赖的package包/类
/**
* Constructs a parser configuration settings object with a
* parent settings object.
*/
public ParserConfigurationSettings(XMLComponentManager parent) {
// create storage for recognized features and properties
fRecognizedFeatures = new HashSet<String>();
fRecognizedProperties = new HashSet<String>();
// create table for features and properties
fFeatures = new HashMap<String, Boolean>();
fProperties = new HashMap<String, Object>();
// save parent
fParentSettings = parent;
}
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:19,代码来源:ParserConfigurationSettings.java
示例11: reset
import com.sun.org.apache.xerces.internal.xni.parser.XMLComponentManager; //导入依赖的package包/类
/**
*
*
* @param componentManager The component manager.
*
* @throws SAXException Throws exception if required features and
* properties cannot be found.
*/
public void reset(XMLComponentManager componentManager)
throws XMLConfigurationException {
fParserSettings = componentManager.getFeature(PARSER_SETTINGS, true);
if (!fParserSettings) {
// parser settings have not been changed
init();
return;
}
// Xerces properties
fSymbolTable = (SymbolTable)componentManager.getProperty(SYMBOL_TABLE);
fErrorReporter = (XMLErrorReporter)componentManager.getProperty(ERROR_REPORTER);
fEntityManager = (XMLEntityManager)componentManager.getProperty(ENTITY_MANAGER);
fSecurityManager = (XMLSecurityManager)componentManager.getProperty(SECURITY_MANAGER);
//this step is extra because we have separated the storage of entity
fEntityStore = fEntityManager.getEntityStore() ;
// sax features
fValidation = componentManager.getFeature(VALIDATION, false);
fNamespaces = componentManager.getFeature(NAMESPACES, true);
fNotifyCharRefs = componentManager.getFeature(NOTIFY_CHAR_REFS, false);
init();
}
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:37,代码来源:XMLScanner.java
示例12: reset
import com.sun.org.apache.xerces.internal.xni.parser.XMLComponentManager; //导入依赖的package包/类
/**
*
*
* @param componentManager The component manager.
*
* @throws SAXException Throws exception if required features and
* properties cannot be found.
*/
public void reset(XMLComponentManager componentManager)
throws XMLConfigurationException {
// Xerces properties
fSymbolTable = (SymbolTable)componentManager.getProperty(SYMBOL_TABLE);
fErrorReporter = (XMLErrorReporter)componentManager.getProperty(ERROR_REPORTER);
fEntityManager = (XMLEntityManager)componentManager.getProperty(ENTITY_MANAGER);
for(int i=14; i<fExpectedVersionString.length; i++ )
fExpectedVersionString[i] = ' ';
}
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:19,代码来源:XMLVersionDetector.java
注:本文中的com.sun.org.apache.xerces.internal.xni.parser.XMLComponentManager类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论