Package org.geotools.xs

Examples of org.geotools.xs.XSConfiguration


        this.xsd = xsd;
        dependencies = Collections.synchronizedList(new ArrayList());

        //bootstrap check
        if (!(this instanceof XSConfiguration)) {
            dependencies.add(new XSConfiguration());
        }

        properties = Collections.synchronizedSet(new HashSet());
        context = new DefaultPicoContainer();
    }
View Full Code Here


        doc.getDocumentElement()
           .setAttributeNS("http://www.w3.org/2001/XMLSchema-instance", "schemaLocation",
            schemaLocation);

        DOMParser parser = new DOMParser(new XSConfiguration(), doc);
        Object o = parser.parse();
        assertTrue(o instanceof List);

        List list = (List) o;
        assertEquals(3, list.size());
View Full Code Here

        doc.getDocumentElement()
           .setAttributeNS("http://www.w3.org/2001/XMLSchema-instance", "schemaLocation",
            schemaLocation);

        DOMParser parser = new DOMParser(new XSConfiguration(), doc);
        String s = (String) parser.parse();

        assertEquals("this is a normal string with some whitespace and some new lines", s);
    }
View Full Code Here

    private static class TestConfiguration extends Configuration {

        public TestConfiguration() {
            super(new TEST());
            addDependency(new XSConfiguration());
        }
View Full Code Here

    Parser p;

    @Override
    protected void setUp() throws Exception {
        XSConfiguration xs = new XSConfiguration();
        p = new Parser(xs);
    }
View Full Code Here

    XSD xsd = new org.geotools.gml2.ApplicationSchemaXSD(namespaceURI, uri);
   
    // Step 2: custom configuration
    Configuration configuration = new Configuration(xsd) {
        {
            addDependency(new XSConfiguration());
            addDependency(new org.geotools.gml2.GMLConfiguration());
        }
        protected void registerBindings(java.util.Map bindings) {
            // we have no special bindings
        }
View Full Code Here

            String uri = schemaLocation.toExternalForm();

            XSD xsd = new org.geotools.gml2.ApplicationSchemaXSD(namespaceURI, uri);
            Configuration configuration = new Configuration(xsd) {
                {
                    addDependency(new XSConfiguration());
                    addDependency(gmlConfiguration); // use our GML configuration
                }

                protected void registerBindings(java.util.Map bindings) {
                    // we have no special bindings
View Full Code Here

* @since 2.4
*/
public class ApplicationSchemaConfiguration extends Configuration {
    public ApplicationSchemaConfiguration(String namespace, String schemaLocation) {
        super(new ApplicationSchemaXSD(namespace, schemaLocation));
        addDependency(new XSConfiguration());
        addDependency(new GMLConfiguration());
    }
View Full Code Here

    }

    public void testDependencies() {
        assertEquals(2, configuration.getDependencies().size());
        assertTrue(configuration.getDependencies().contains(new XLINKConfiguration()));
        assertTrue(configuration.getDependencies().contains(new XSConfiguration()));
    }
View Full Code Here

public class ComplexConfiguration extends Configuration {
   
    public ComplexConfiguration(String namespace, String schemaLocation) {
        super(new ResolvingApplicationSchemaXSD(namespace, schemaLocation));
        addDependency(new XSConfiguration());
        addDependency(new GMLConfiguration());
    }
View Full Code Here

TOP

Related Classes of org.geotools.xs.XSConfiguration

Copyright © 2018 www.massapicom. 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.