Examples of CatalogResolver


Examples of org.apache.commons.configuration.resolver.CatalogResolver

    /**
     * Tests modifying an XML document and saving it with schema validation enabled.
     */
    public void testSaveWithValidation() throws Exception
    {
        CatalogResolver resolver = new CatalogResolver();
        resolver.setCatalogFiles(CATALOG_FILES);
        conf = new XMLConfiguration();
        conf.setEntityResolver(resolver);
        conf.setFileName(testFile2);
        conf.setSchemaValidation(true);
        conf.load();
View Full Code Here

Examples of org.apache.commons.configuration.resolver.CatalogResolver

    /**
     * Tests modifying an XML document and validating it against the schema.
     */
    public void testSaveWithValidationFailure() throws Exception
    {
        CatalogResolver resolver = new CatalogResolver();
        resolver.setCatalogFiles(CATALOG_FILES);
        conf = new XMLConfiguration();
        conf.setEntityResolver(resolver);
        conf.setFileName(testFile2);
        conf.setSchemaValidation(true);
        conf.load();
View Full Code Here

Examples of org.apache.commons.configuration.resolver.CatalogResolver

    private CatalogResolver resolver;
    private XMLConfiguration config;

    protected void setUp() throws Exception
    {
        resolver = new CatalogResolver();
        resolver.setCatalogFiles(CATALOG_FILES);
        // resolver.setDebug(true);
        config = new XMLConfiguration();
        config.setEntityResolver(resolver);
    }
View Full Code Here

Examples of org.apache.commons.configuration.resolver.CatalogResolver

     * Tests modifying an XML document and saving it with schema validation enabled.
     */
    @Test
    public void testSaveWithValidation() throws Exception
    {
        CatalogResolver resolver = new CatalogResolver();
        resolver.setCatalogFiles(CATALOG_FILES);
        conf = new XMLConfiguration();
        conf.setEntityResolver(resolver);
        conf.setFileName(testFile2);
        conf.setSchemaValidation(true);
        conf.load();
View Full Code Here

Examples of org.apache.commons.configuration.resolver.CatalogResolver

     * Tests modifying an XML document and validating it against the schema.
     */
    @Test
    public void testSaveWithValidationFailure() throws Exception
    {
        CatalogResolver resolver = new CatalogResolver();
        resolver.setCatalogFiles(CATALOG_FILES);
        conf = new XMLConfiguration();
        conf.setEntityResolver(resolver);
        conf.setFileName(testFile2);
        conf.setSchemaValidation(true);
        conf.load();
View Full Code Here

Examples of org.apache.commons.configuration2.resolver.CatalogResolver

    private XMLConfiguration config;

    @Before
    public void setUp() throws Exception
    {
        resolver = new CatalogResolver();
        resolver.setCatalogFiles(CATALOG_FILES);
        // resolver.setDebug(true);
        config = new XMLConfiguration();
        config.setEntityResolver(resolver);
    }
View Full Code Here

Examples of org.apache.commons.configuration2.resolver.CatalogResolver

     * Tests modifying an XML document and saving it with schema validation enabled.
     */
    @Test
    public void testSaveWithValidation() throws Exception
    {
        CatalogResolver resolver = new CatalogResolver();
        resolver.setCatalogFiles(CATALOG_FILES);
        conf = new XMLConfiguration();
        conf.setEntityResolver(resolver);
        conf.setSchemaValidation(true);
        load(conf, testFile2);
        conf.setProperty("Employee.SSN", "123456789");
View Full Code Here

Examples of org.apache.commons.configuration2.resolver.CatalogResolver

     * Tests modifying an XML document and validating it against the schema.
     */
    @Test
    public void testSaveWithValidationFailure() throws Exception
    {
        CatalogResolver resolver = new CatalogResolver();
        resolver.setCatalogFiles(CATALOG_FILES);
        conf = new XMLConfiguration();
        conf.setEntityResolver(resolver);
        conf.setSchemaValidation(true);
        load(conf, testFile2);
        conf.setProperty("Employee.Email", "JohnDoe@apache.org");
View Full Code Here

Examples of org.apache.xml.resolver.tools.CatalogResolver

  public File processSources(Map<String, Object> map) throws MojoExecutionException {
    final String[] included = scanIncludedFiles();
    // configure a resolver for catalog files
    final CatalogManager catalogManager = createCatalogManager();
    final CatalogResolver catalogResolver = new CatalogResolver(catalogManager);
    // configure a resolver for urn:dockbx:stylesheet
    final URIResolver uriResolver = createStyleSheetResolver(catalogResolver);

    // configure a resolver for xml entities
    final InjectingEntityResolver injectingResolver = createEntityResolver(catalogResolver);
View Full Code Here

Examples of org.apache.xml.resolver.tools.CatalogResolver

    public static DocumentBuilder createBuilder() throws ParserConfigurationException {
        DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
        factory.setNamespaceAware(true);
        DocumentBuilder builder = factory.newDocumentBuilder();   

    CatalogResolver cr = new CatalogResolver();
    builder.setEntityResolver(cr);
        return builder;
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.