Package org.geotools.util

Examples of org.geotools.util.NullProgressListener


    public final static int CANCEL_ID = 38;

    StyleLayer selectedLayer;

    public ProgressListener getProgressListener() {
        ProgressListener cancelProgress = new NullProgressListener();
        return cancelProgress ;
    }
View Full Code Here


                    //count the number of unique attributes
                    int uniqueCount = -1;
                    try {
                        Expression attr = ff.property(attribute);
                        UniqueVisitor uniques = new UniqueVisitor(attr);
                        ProgressListener progress = new NullProgressListener();
                        collection.accepts(uniques, progress);
                        uniqueCount = uniques.getUnique().size();
                    } catch (IOException e1) {
                        SLDPlugin.log("unique values calculation failed", e1); //$NON-NLS-1$
                    }
View Full Code Here

                    CoverageInfo coverageInfo = mli.getCoverage();

                    // it much safer to wrap a reader rather than a coverage in most cases, OOM can
                    // occur otherwise
                    final AbstractGridCoverage2DReader reader = (AbstractGridCoverage2DReader) coverageInfo
                            .getGridCoverageReader(new NullProgressListener(), GeoTools
                                    .getDefaultHints());
                    final FeatureCollection<SimpleFeatureType, SimpleFeature> feature = FeatureUtilities
                            .wrapGridCoverageReader(reader, null);
                    request.setLayer(feature.getSchema());
                }
View Full Code Here

                    metas.add(layerInfo);

                    //}
                } else {
                    final CoverageInfo cinfo = requestedLayers[i].getCoverage();
                    final AbstractGridCoverage2DReader reader=(AbstractGridCoverage2DReader) cinfo.getGridCoverageReader(new NullProgressListener(),GeoTools.getDefaultHints());
                    final ParameterValueGroup params = reader.getFormat().getReadParameters();
                    final GeneralParameterValue[] parameters = CoverageUtils.getParameters(params, requestedLayers[i].getCoverage().getParameters(),true);
                    //get the original grid geometry
                    final GridGeometry2D coverageGeometry=(GridGeometry2D) cinfo.getGrid();
                    // set the requested position in model space for this request
View Full Code Here

        final Catalog catalog = getCatalog();

        DataAccess<? extends FeatureType, ? extends Feature> dataStore;
        try {
            // REVISIT: this may need to be done after saveing the DataStoreInfo
            dataStore = info.getDataStore(new NullProgressListener());
            dataStore.dispose();
        } catch (IOException e) {
            LOGGER.log(Level.WARNING, "Error obtaining new data store", e);
            String message = e.getMessage();
            if (message == null && e.getCause() != null) {
View Full Code Here

        }

        public Map<String, Object> execute(Map<String, Object> inputs,
                ProgressListener monitor) throws ProcessException {
            if (monitor == null) {
                monitor = new NullProgressListener();
            }
            Scriptable outputsObj;
            Map<String, Object> outputs = null;
            Context cx = Context.enter();
            Scriptable scope = runFunc.getParentScope();
View Full Code Here

            info.setType(name);
           
            // connect and defaults
            info.setCapabilitiesURL(params.str("url"));
            try {
                WebMapServer service = info.getWebMapServer(new NullProgressListener());
                info.setDescription( service.getInfo().getDescription() );
                info.setEnabled(true);
            } catch (Throwable e) {
                info.setError(e);
                info.setEnabled(false);
View Full Code Here

        obj.put("name", name);
        if(store instanceof DataStoreInfo){
            DataStoreInfo data = (DataStoreInfo) store;
           
            @SuppressWarnings("rawtypes")
            DataAccess dataStore = data.getDataStore(new NullProgressListener());
            FeatureType schema;
            org.geotools.data.ResourceInfo info;
            if (dataStore instanceof DataStore) {
                schema = ((DataStore) dataStore).getSchema(name);
                info = ((DataStore) dataStore).getFeatureSource(name).getInfo();
View Full Code Here

    }

    public CoverageSource access( Name name, Map<String, Serializable> params, AccessType accessType, Hints hints,
            ProgressListener listener ) throws IOException {
        if (listener == null) {
            listener = new NullProgressListener();
        }
        listener.started();
        try {
            return new NetCDFSource((NetCDFImageReader)reader, /*nameToVarMap.get(name)*/ name);
        } catch (Throwable e) {
View Full Code Here

    }

    @Override
    public ServiceInfo getInfo( ProgressListener listener ) {
        if (listener == null){
            listener = new NullProgressListener();
        }
        listener.started();
        final DefaultServiceInfo info = new DefaultServiceInfo();

        // Fix that
View Full Code Here

TOP

Related Classes of org.geotools.util.NullProgressListener

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.