Package org.geotools.xml.transform

Examples of org.geotools.xml.transform.TransformerBase$TranslatorSupport$Comment


        GetCapabilitiesType request = factory.createGetCapabilitiesType();
        request.setService("WFS");
        request.setAcceptVersions(owsFactory.createAcceptVersionsType());
        request.getAcceptVersions().getVersion().add("1.1.1");

        TransformerBase tx = getCaps.run(GetCapabilitiesRequest.adapt(request));
        assertTrue(tx instanceof CapabilitiesTransformer.WFS1_1);
    }
View Full Code Here


        GetCapabilitiesType request = factory.createGetCapabilitiesType();
        request.setService("WFS");
        request.setAcceptVersions(owsFactory.createAcceptVersionsType());
        request.getAcceptVersions().getVersion().add("1.0.5");

        TransformerBase tx = getCaps.run(GetCapabilitiesRequest.adapt(request));
        assertTrue(tx instanceof CapabilitiesTransformer.WFS1_0);
    }
View Full Code Here

        return "application/xml";
    }

    public void write(Object value, OutputStream output, Operation operation)
        throws IOException {
        TransformerBase tx = (TransformerBase) value;

        try {
            tx.transform(operation.getParameters()[0], output);
        } catch (TransformerException e) {
            throw (IOException) new IOException().initCause(e);
        }
    }
View Full Code Here

     * @throws Exception
     */
    @Test
    public void testCachedLegendURLSize() throws Exception {
       
        TransformerBase tr = createTransformer();
        tr.setIndentation(2);
        Document dom = WMSTestSupport.transform(req, tr);
       
        NodeList legendURLs = XPATH.getMatchingNodes(
                getLegendURLXPath("cite:BasicPolygons"), dom);
        assertEquals(1, legendURLs.getLength());
View Full Code Here

        GeoServerResourceLoader loader = GeoServerExtensions.bean(GeoServerResourceLoader.class);
       
        File samplesFolder = new File(loader.getBaseDirectory().getAbsolutePath() + File.separator
                + LegendSampleImpl.LEGEND_SAMPLES_FOLDER);
        removeFileOrFolder(samplesFolder);
        TransformerBase tr = createTransformer();
        tr.setIndentation(2);
        Document dom = WMSTestSupport.transform(req, tr);
       
        assertTrue(samplesFolder.exists());
    }
View Full Code Here

     * @throws Exception
     */
    @Test
    public void testCreatedLegendURLSize() throws Exception {
       
        TransformerBase tr = createTransformer();
        tr.setIndentation(2);
        Document dom = WMSTestSupport.transform(req, tr);
       

        NodeList legendURLs = XPATH.getMatchingNodes(
                getLegendURLXPath("cite:squares"), dom);
View Full Code Here

     * @throws Exception
     */
    @Test
    public void testCreatedLegendURLFromWorkspaceSize() throws Exception {
       
        TransformerBase tr = createTransformer();
        tr.setIndentation(2);
        Document dom = WMSTestSupport.transform(req, tr);
       

        NodeList legendURLs = XPATH.getMatchingNodes(
                getLegendURLXPath("cite:states"), dom);
View Full Code Here

        sldResource.file().setLastModified(lastTime + 1000);
       
        // force cleaning of samples cache, to get updates on files
        ((LegendSampleImpl)GeoServerExtensions.bean(LegendSample.class)).reloaded();
       
        TransformerBase tr = createTransformer();
        tr.setIndentation(2);
        Document dom = WMSTestSupport.transform(req, tr);
       
        NodeList legendURLs = XPATH.getMatchingNodes(
                getLegendURLXPath("cite:Bridges"), dom);
        assertEquals(1, legendURLs.getLength());
View Full Code Here

        long previousTime = sldResource.lastmodified();
        sldResource.file().setLastModified(lastTime + 1000);
       
        catalog.firePostModified(catalog.getStyleByName("Bridges"));
       
        TransformerBase tr = createTransformer();
        tr.setIndentation(2);
        Document dom = WMSTestSupport.transform(req, tr);
       
        NodeList legendURLs = XPATH.getMatchingNodes(
                getLegendURLXPath("cite:Bridges"), dom);
        assertEquals(1, legendURLs.getLength());
View Full Code Here

     * @throws Exception
     */
    @Test
    public void testOnlineResourceWidthHeight() throws Exception {
       
        TransformerBase tr = createTransformer();
        tr.setIndentation(2);
        Document dom = WMSTestSupport.transform(req, tr);
       
        NodeList onlineResources = XPATH.getMatchingNodes(
                getOnlineResourceXPath("cite:BasicPolygons"), dom);
        assertEquals(1, onlineResources.getLength());
View Full Code Here

TOP

Related Classes of org.geotools.xml.transform.TransformerBase$TranslatorSupport$Comment

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.