Examples of MetadataMap


Examples of org.geoserver.catalog.MetadataMap

    }
   
    protected void resolve(GeoServerInfo info) {
        GeoServerInfoImpl global = (GeoServerInfoImpl) info;
        if(global.getMetadata() == null) {
            global.setMetadata(new MetadataMap());
        }
        if(global.getClientProperties() == null) {
            global.setClientProperties(new HashMap<Object, Object>());
        }
        if (global.getCoverageAccess() == null) {
View Full Code Here

Examples of org.geoserver.catalog.MetadataMap

            if (id != null) {
                OwsUtils.set(entity, "id", null);
            }
        }
        try {
            MetadataMap md = (MetadataMap) OwsUtils.get(entity, "metadata");
            if (md != null) {
                md.setId(null);
            }
        }
        catch(IllegalArgumentException e1) {}
        catch(ClassCastException e2) {}
       
View Full Code Here

Examples of org.geoserver.catalog.MetadataMap

        assertEquals( 1, l.added.size() );
        assertEquals( ft, l.added.get(0).getSource() );
       
        ft = catalog.getFeatureTypeByName("ftName");
        ft.getMetadata().put("newValue", "abcd");
        MetadataMap newMetadata  = new MetadataMap(ft.getMetadata());
        catalog.save(ft);
        assertEquals( 1, l.modified.size() );
        assertEquals( ft, l.modified.get(0).getSource() );
        assertTrue( l.modified.get(0).getPropertyNames().contains( "metadata"));
        assertTrue( l.modified.get(0).getOldValues().contains( new MetadataMap() ));
        assertTrue( l.modified.get(0).getNewValues().contains( newMetadata ));
    }
View Full Code Here

Examples of org.geoserver.catalog.MetadataMap

            }
            if (impl.getKeywords() == null) {
                impl.setKeywords(new ArrayList());
            }
            if (impl.getMetadata() == null) {
                impl.setMetadata(new MetadataMap());
            }
            if (impl.getVersions() == null) {
                impl.setVersions(new ArrayList());
            }
        }
View Full Code Here

Examples of org.geoserver.catalog.MetadataMap

       
        Map<String, ?> formatOptions = request.getFormatOptions();
        final String requestedPrjFileFormat = (String) formatOptions.get("PRJFILEFORMAT");
        if (null == requestedPrjFileFormat) {
            WFSInfo bean = gs.getService(WFSInfo.class);
            MetadataMap metadata = bean.getMetadata();
            Boolean defaultIsEsri = metadata.get(SHAPE_ZIP_DEFAULT_PRJ_IS_ESRI, Boolean.class);
            useEsriFormat = defaultIsEsri != null && defaultIsEsri.booleanValue();
        }else{
            useEsriFormat = "ESRI".equalsIgnoreCase(requestedPrjFileFormat);
        }
       
View Full Code Here

Examples of org.geoserver.catalog.MetadataMap

        org.geoserver.data.util.IOUtils.copy(input, file);
    }

    private void setupESRIFormatByDefault(GeoServer geoServer, Boolean value) throws IOException {
        WFSInfo wfsInfo = geoServer.getService(WFSInfo.class);
        MetadataMap metadata = wfsInfo.getMetadata();
        metadata.put(ShapeZipOutputFormat.SHAPE_ZIP_DEFAULT_PRJ_IS_ESRI, value);
        geoServer.save(wfsInfo);
    }
View Full Code Here

Examples of org.geoserver.catalog.MetadataMap

       
        Map<String, ?> formatOptions = request.getFormatOptions();
        final String requestedPrjFileFormat = (String) formatOptions.get("PRJFILEFORMAT");
        if (null == requestedPrjFileFormat) {
            WFSInfo bean = gs.getService(WFSInfo.class);
            MetadataMap metadata = bean.getMetadata();
            Boolean defaultIsEsri = metadata.get(SHAPE_ZIP_DEFAULT_PRJ_IS_ESRI, Boolean.class);
            useEsriFormat = defaultIsEsri != null && defaultIsEsri.booleanValue();
        }else{
            useEsriFormat = "ESRI".equalsIgnoreCase(requestedPrjFileFormat);
        }
       
View Full Code Here

Examples of org.geoserver.catalog.MetadataMap

        }
        if ( service.getExceptionFormats() == null ) {
            ((WPSInfoImpl)service).setExceptionFormats( new ArrayList() );
        }
        if ( service.getMetadata() == null ) {
            ((WPSInfoImpl)service).setMetadata( new MetadataMap() );
        }
        if ( service.getClientProperties() == null ) {
            ((WPSInfoImpl)service).setClientProperties( new HashMap() );
        }
        if ( service.getVersions() == null ) {
View Full Code Here

Examples of org.geoserver.catalog.MetadataMap

    }
   
    protected void resolve(GeoServerInfo info) {
        GeoServerInfoImpl global = (GeoServerInfoImpl) info;
        if(global.getMetadata() == null) {
            global.setMetadata(new MetadataMap());
        }
        if(global.getClientProperties() == null) {
            global.setClientProperties(new HashMap<Object, Object>());
        }
        if (global.getCoverageAccess() == null) {
View Full Code Here

Examples of org.geoserver.catalog.MetadataMap

            StoreInfo store = (StoreInfo) super.doUnmarshal(result, reader, context);
           
            // 2.1.3+ backwards compatibility check
            if (store instanceof WMSStoreInfo) {
                WMSStoreInfo wmsStore = (WMSStoreInfo) store;
                MetadataMap metadata = wmsStore.getMetadata();
                Integer maxConnections = null;
                Integer connectTimeout = null;
                Integer readTimeout = null;
                if (metadata != null) {
                    maxConnections = metadata.get("maxConnections", Integer.class);
                    connectTimeout = metadata.get("connectTimeout", Integer.class);
                    readTimeout = metadata.get("readTimeout", Integer.class);
                    metadata.remove("maxConnections");
                    metadata.remove("connectTimeout");
                    metadata.remove("readTimeout");
                }
                if (wmsStore.getMaxConnections() <= 0) {
                    wmsStore.setMaxConnections(maxConnections != null
                            && maxConnections.intValue() > 0 ? maxConnections
                            : WMSStoreInfoImpl.DEFAULT_MAX_CONNECTIONS);
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.