本文整理汇总了Java中javax.xml.validation.ValidatorHandler.getProperty方法的典型用法代码示例。如果您正苦于以下问题:Java ValidatorHandler.getProperty方法的具体用法?Java ValidatorHandler.getProperty怎么用?Java ValidatorHandler.getProperty使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类javax.xml.validation.ValidatorHandler
的用法示例。
在下文中一共展示了ValidatorHandler.getProperty方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: test1
import javax.xml.validation.ValidatorHandler; //导入方法依赖的package包/类
@Test
public void test1() throws SAXException {
try {
ValidatorHandler validatorHandler = schemaFactory.newSchema().newValidatorHandler();
validatorHandler.getProperty("unknown1234");
Assert.fail("SAXNotRecognizedException was not thrown.");
} catch (SAXNotRecognizedException e) {
}
}
示例2: testGetNullProperty
import javax.xml.validation.ValidatorHandler; //导入方法依赖的package包/类
@Test(expectedExceptions = NullPointerException.class)
public void testGetNullProperty() throws SAXNotRecognizedException, SAXNotSupportedException {
ValidatorHandler validatorHandler = getValidatorHandler();
assertNotNull(validatorHandler);
validatorHandler.getProperty(null);
}
示例3: testGetUnrecognizedProperty
import javax.xml.validation.ValidatorHandler; //导入方法依赖的package包/类
@Test(expectedExceptions = SAXNotRecognizedException.class)
public void testGetUnrecognizedProperty() throws SAXNotRecognizedException, SAXNotSupportedException {
ValidatorHandler validatorHandler = getValidatorHandler();
validatorHandler.getProperty(FEATURE_NAME);
}