congrats Icon
New! Tabnine Pro 14-day free trial
Start a free trial
Tabnine Logo
Process
Code IndexAdd Tabnine to your IDE (free)

How to use
Process
in
org.geotools.process

Best Java code snippets using org.geotools.process.Process (Showing top 20 results out of 315)

origin: geotools/geotools

  @Override
  public Map<String, Object> call() throws Exception {
    return process.execute(input, new CallableProgressListener());
  }
};
origin: geotools/geotools

void innerRun() {
  if (!compareAndSetState(0, RUNNING)) {
    return;
  }
  try {
    runningThread = Thread.currentThread();
    innerSet(process.execute(input, this));
  } catch (Throwable ex) {
    innerSetException(ex);
  }
}
origin: geotools/geotools

boolean innerRunAndReset() {
  if (!compareAndSetState(0, RUNNING)) {
    return false;
  }
  try {
    runningThread = Thread.currentThread();
    process.execute(input, this); // don't set the result
    runningThread = null;
    return compareAndSetState(RUNNING, 0);
  } catch (Throwable ex) {
    innerSetException(ex);
    return false;
  }
}
origin: geotools/geotools

public Object evaluate(Object object) {
  Map<String, Object> processInputs = evaluateInputs(object);
  // execute the process
  try {
    ExceptionProgressListener listener = new ExceptionProgressListener();
    Map<String, Object> results = process.execute(processInputs, listener);
    // some processes have the bad habit of not throwing exceptions, but to
    // report them to the listener
    if (listener.getExceptions().size() > 0) {
      // uh oh, an exception occurred during processing
      Throwable t = listener.getExceptions().get(0);
      throw new RuntimeException(
          "Failed to evaluate process function, error is: " + t.getMessage(), t);
    }
    return getResult(results, processInputs);
  } catch (ProcessException e) {
    throw new RuntimeException(
        "Failed to evaluate the process function, error is: " + e.getMessage(), e);
  }
}
origin: geotools/geotools

Map<String, Object> resultMap = process.execute(paramMap, progress);
origin: org.geotools/gt-process

  @Override
  public Map<String, Object> call() throws Exception {                
    return process.execute( input, new CallableProgressListener() );
  }            
};
origin: org.geoserver.extension/gs-wps-core

  @Override
  public Map<String, Object> execute(Map<String, Object> input, ProgressListener monitor)
      throws ProcessException {
    if (monitor != null) {
      monitor.started();
      monitor =
          new DelegateProgressListener(monitor) {
            @Override
            public void started() {
              // do not pass over, we already called "started"
            }
          };
    }
    return delegate.execute(input, monitor);
  }
}
origin: mapplus/spatial_statistics_for_geotools_udig

public static GridCoverage2D process(GridCoverage2D inputCoverage, ProgressListener monitor) {
  Map<String, Object> map = new HashMap<String, Object>();
  map.put(RasterAspectProcessFactory.inputCoverage.key, inputCoverage);
  Process process = new RasterAspectProcess(null);
  Map<String, Object> resultMap;
  try {
    resultMap = process.execute(map, monitor);
    return (GridCoverage2D) resultMap.get(RasterAspectProcessFactory.RESULT.key);
  } catch (ProcessException e) {
    LOGGER.log(Level.FINER, e.getMessage(), e);
  }
  return null;
}
origin: mapplus/spatial_statistics_for_geotools_udig

public static GridCoverage2D process(GridCoverage2D inputCoverage, ProgressListener monitor) {
  Map<String, Object> map = new HashMap<String, Object>();
  map.put(RasterFlipProcessFactory.inputCoverage.key, inputCoverage);
  Process process = new RasterFlipProcess(null);
  Map<String, Object> resultMap;
  try {
    resultMap = process.execute(map, monitor);
    return (GridCoverage2D) resultMap.get(RasterFlipProcessFactory.RESULT.key);
  } catch (ProcessException e) {
    LOGGER.log(Level.FINER, e.getMessage(), e);
  }
  return null;
}
origin: mapplus/spatial_statistics_for_geotools_udig

public static GridCoverage2D process(GridCoverage2D inputCoverage, ProgressListener monitor) {
  Map<String, Object> map = new HashMap<String, Object>();
  map.put(RasterTRIProcessFactory.inputCoverage.key, inputCoverage);
  Process process = new RasterTRIProcess(null);
  Map<String, Object> resultMap;
  try {
    resultMap = process.execute(map, monitor);
    return (GridCoverage2D) resultMap.get(RasterTRIProcessFactory.RESULT.key);
  } catch (ProcessException e) {
    LOGGER.log(Level.FINER, e.getMessage(), e);
  }
  return null;
}
origin: mapplus/spatial_statistics_for_geotools_udig

public static GridCoverage2D process(GridCoverage2D inputCoverage, ProgressListener monitor) {
  Map<String, Object> map = new HashMap<String, Object>();
  map.put(RasterRoughnessProcessFactory.inputCoverage.key, inputCoverage);
  Process process = new RasterRoughnessProcess(null);
  Map<String, Object> resultMap;
  try {
    resultMap = process.execute(map, monitor);
    return (GridCoverage2D) resultMap.get(RasterRoughnessProcessFactory.RESULT.key);
  } catch (ProcessException e) {
    LOGGER.log(Level.FINER, e.getMessage(), e);
  }
  return null;
}
origin: mapplus/spatial_statistics_for_geotools_udig

public static GridCoverage2D process(GridCoverage2D inputCoverage, ProgressListener monitor) {
  Map<String, Object> map = new HashMap<String, Object>();
  map.put(RasterTPIProcessFactory.inputCoverage.key, inputCoverage);
  Process process = new RasterTPIProcess(null);
  Map<String, Object> resultMap;
  try {
    resultMap = process.execute(map, monitor);
    return (GridCoverage2D) resultMap.get(RasterTPIProcessFactory.RESULT.key);
  } catch (ProcessException e) {
    LOGGER.log(Level.FINER, e.getMessage(), e);
  }
  return null;
}
origin: mapplus/spatial_statistics_for_geotools_udig

public static GridCoverage2D process(GridCoverage2D inputCoverage, ProgressListener monitor) {
  Map<String, Object> map = new HashMap<String, Object>();
  map.put(RasterMirrorProcessFactory.inputCoverage.key, inputCoverage);
  Process process = new RasterMirrorProcess(null);
  Map<String, Object> resultMap;
  try {
    resultMap = process.execute(map, monitor);
    return (GridCoverage2D) resultMap.get(RasterMirrorProcessFactory.RESULT.key);
  } catch (ProcessException e) {
    LOGGER.log(Level.FINER, e.getMessage(), e);
  }
  return null;
}
origin: mapplus/spatial_statistics_for_geotools_udig

public static SimpleFeatureCollection process(SimpleFeatureCollection polygonFeatures,
    ProgressListener monitor) {
  Map<String, Object> map = new HashMap<String, Object>();
  map.put(UnionPolygonProcessFactory.polygonFeatures.key, polygonFeatures);
  Process process = new UnionPolygonProcess(null);
  Map<String, Object> resultMap;
  try {
    resultMap = process.execute(map, monitor);
    return (SimpleFeatureCollection) resultMap.get(UnionPolygonProcessFactory.RESULT.key);
  } catch (ProcessException e) {
    LOGGER.log(Level.FINER, e.getMessage(), e);
  }
  return null;
}
origin: mapplus/spatial_statistics_for_geotools_udig

public static SimpleFeatureCollection process(SimpleFeatureCollection inputFeatures,
    ProgressListener monitor) {
  Map<String, Object> map = new HashMap<String, Object>();
  map.put(RepairGeometryProcessFactory.inputFeatures.key, inputFeatures);
  Process process = new RepairGeometryProcess(null);
  Map<String, Object> resultMap;
  try {
    resultMap = process.execute(map, monitor);
    return (SimpleFeatureCollection) resultMap.get(RepairGeometryProcessFactory.RESULT.key);
  } catch (ProcessException e) {
    LOGGER.log(Level.FINER, e.getMessage(), e);
  }
  return null;
}
origin: mapplus/spatial_statistics_for_geotools_udig

public static PearsonResult process(SimpleFeatureCollection inputFeatures, String inputFields,
    ProgressListener monitor) {
  Map<String, Object> map = new HashMap<String, Object>();
  map.put(PearsonCorrelationProcessFactory.inputFeatures.key, inputFeatures);
  map.put(PearsonCorrelationProcessFactory.inputFields.key, inputFields);
  Process process = new PearsonCorrelationProcess(null);
  Map<String, Object> resultMap;
  try {
    resultMap = process.execute(map, monitor);
    return (PearsonResult) resultMap.get(PearsonCorrelationProcessFactory.RESULT.key);
  } catch (ProcessException e) {
    LOGGER.log(Level.FINER, e.getMessage(), e);
  }
  return null;
}
origin: mapplus/spatial_statistics_for_geotools_udig

public static SimpleFeatureCollection process(SimpleFeatureCollection inputFeatures,
    SimpleFeatureCollection differenceFeatures, ProgressListener monitor) {
  Map<String, Object> map = new HashMap<String, Object>();
  map.put(SymDifferenceProcessFactory.inputFeatures.key, inputFeatures);
  map.put(SymDifferenceProcessFactory.differenceFeatures.key, differenceFeatures);
  Process process = new SymDifferenceProcess(null);
  Map<String, Object> resultMap;
  try {
    resultMap = process.execute(map, monitor);
    return (SimpleFeatureCollection) resultMap.get(SymDifferenceProcessFactory.RESULT.key);
  } catch (ProcessException e) {
    LOGGER.log(Level.FINER, e.getMessage(), e);
  }
  return null;
}
origin: mapplus/spatial_statistics_for_geotools_udig

public static GridCoverage2D process(GridCoverage2D inputCoverage, double zFactor,
    ProgressListener monitor) {
  Map<String, Object> map = new HashMap<String, Object>();
  map.put(RasterCurvatureProcessFactory.inputCoverage.key, inputCoverage);
  map.put(RasterCurvatureProcessFactory.zFactor.key, zFactor);
  Process process = new RasterCurvatureProcess(null);
  Map<String, Object> resultMap;
  try {
    resultMap = process.execute(map, monitor);
    return (GridCoverage2D) resultMap.get(RasterCurvatureProcessFactory.RESULT.key);
  } catch (ProcessException e) {
    LOGGER.log(Level.FINER, e.getMessage(), e);
  }
  return null;
}
origin: mapplus/spatial_statistics_for_geotools_udig

public static SimpleFeatureCollection process(SimpleFeatureCollection inputFeatures,
    Expression tolerance, ProgressListener monitor) {
  Map<String, Object> map = new HashMap<String, Object>();
  map.put(DensifyProcessFactory.inputFeatures.key, inputFeatures);
  map.put(DensifyProcessFactory.tolerance.key, tolerance);
  Process process = new DensifyProcess(null);
  Map<String, Object> resultMap;
  try {
    resultMap = process.execute(map, monitor);
    return (SimpleFeatureCollection) resultMap.get(DensifyProcessFactory.RESULT.key);
  } catch (ProcessException e) {
    LOGGER.log(Level.FINER, e.getMessage(), e);
  }
  return null;
}
origin: mapplus/spatial_statistics_for_geotools_udig

public static SimpleFeatureCollection process(SimpleFeatureCollection inputFeatures,
    Expression minimumArea, ProgressListener monitor) {
  Map<String, Object> map = new HashMap<String, Object>();
  map.put(RemoveHolesProcessFactory.inputFeatures.key, inputFeatures);
  map.put(RemoveHolesProcessFactory.minimumArea.key, minimumArea);
  Process process = new RemoveHolesProcess(null);
  Map<String, Object> resultMap;
  try {
    resultMap = process.execute(map, monitor);
    return (SimpleFeatureCollection) resultMap.get(RemoveHolesProcessFactory.RESULT.key);
  } catch (ProcessException e) {
    LOGGER.log(Level.FINER, e.getMessage(), e);
  }
  return null;
}
org.geotools.processProcess

Javadoc

A Process that returns a result and reports progress. Implementors define a single method called execute that accepts the inputs to process and a ProgressListener.

The Process interface is similar to java.lang.Callable, in that both are designed for classes whose instances are potentially executed by another thread. A Callable, however, does not report progress.

The Executors class contains utility methods to convert from other common forms to Callable classes.

Most used methods

  • execute
    Execute this process with the provided inputs.

Popular in Java

  • Finding current android device location
  • startActivity (Activity)
  • getSharedPreferences (Context)
  • requestLocationUpdates (LocationManager)
  • Table (com.google.common.collect)
    A collection that associates an ordered pair of keys, called a row key and a column key, with a sing
  • Color (java.awt)
    The Color class is used to encapsulate colors in the default sRGB color space or colors in arbitrary
  • ByteBuffer (java.nio)
    A buffer for bytes. A byte buffer can be created in either one of the following ways: * #allocate
  • Calendar (java.util)
    Calendar is an abstract base class for converting between a Date object and a set of integer fields
  • Handler (java.util.logging)
    A Handler object accepts a logging request and exports the desired messages to a target, for example
  • JTextField (javax.swing)
  • PhpStorm for WordPress
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyStudentsTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now