@Override public ParameterValueGroup getReadParameters() { HashMap<String, String> info = new HashMap<String, String>(); info.put("name", getName()); info.put("description", getDescription()); info.put("vendor", getVendor()); info.put("docURL", getDocURL()); info.put("version", getVersion()); List<GeneralParameterDescriptor> delegateFormatParams = new ArrayList<GeneralParameterDescriptor>(); delegateFormatParams.addAll( delegateFormat.getReadParameters().getDescriptor().descriptors()); // add bands parameter descriptor only if the delegate reader doesn't have it // already if (!checkIfDelegateReaderSupportsBands()) { delegateFormatParams.add(AbstractGridFormat.BANDS); } return new ParameterGroup( new DefaultParameterDescriptorGroup( info, delegateFormatParams.toArray( new GeneralParameterDescriptor [delegateFormatParams.size()]))); }
public CustomFormat() { this.mInfo = new HashMap<String, String>(); this.mInfo.put("name", TYPE_NAME); this.mInfo.put( "description", "Test custom coverage format - only visible with test jars in the classpath"); this.mInfo.put("docURL", ""); this.mInfo.put("version", "1.0"); // writing parameters this.writeParameters = null; // reading parameters this.readParameters = new ParameterGroup( new DefaultParameterDescriptorGroup( this.mInfo, new GeneralParameterDescriptor[] { READ_GRIDGEOMETRY2D, INPUT_TRANSPARENT_COLOR, CUSTOM_DIMENSION })); }
/** Constructs an {@code "Interpolate"} operation. */ public Interpolate() { super( new DefaultParameterDescriptorGroup( Citations.OGC, "Interpolate", new ParameterDescriptor[] {SOURCE_0, TYPE})); }
/** Constructs a default {@code "SelectSampleDimension"} operation. */ public SelectSampleDimension() { super( new DefaultParameterDescriptorGroup( "SelectSampleDimension", new ParameterDescriptor[] { SOURCE_0, SAMPLE_DIMENSIONS, VISIBLE_SAMPLE_DIMENSION })); }
/** Constructs a {@code "Resample"} operation. */ public Resample() { super( new DefaultParameterDescriptorGroup( Citations.OGC, "Resample", new ParameterDescriptor[] { SOURCE_0, INTERPOLATION_TYPE, COORDINATE_REFERENCE_SYSTEM, GRID_GEOMETRY, BACKGROUND_VALUES })); }
/** Constructs a default {@code "Crop"} operation. */ public Crop() { super( new DefaultParameterDescriptorGroup( Citations.JAI, "CoverageCrop", new ParameterDescriptor[] { SOURCE_0, CROP_ENVELOPE, CROP_ROI, ROI_OPTIMISATION_TOLERANCE, FORCE_MOSAIC, NODATA, DEST_NODATA })); }
/** * Return a ParameterGroup with default General Parameter Descriptors. * * @param mInfo Set of properties info * @return a {@link ParameterGroup} with Default {@link GeneralParameterDescriptors}. */ protected static ParameterGroup getDefaultParameterGroup(Map<String, String> mInfo) { return new ParameterGroup(new DefaultParameterDescriptorGroup(mInfo, PARAM_DESCRIPTOR)); }
/** Creates an instance and sets the metadata. */ public GrassCoverageFormat() { mInfo = new HashMap<String, String>(); mInfo.put("name", "grass"); mInfo.put("description", "Grass Coverage Format"); mInfo.put("vendor", "Geotools"); // reading parameters readParameters = new ParameterGroup( new DefaultParameterDescriptorGroup( mInfo, new GeneralParameterDescriptor[] {READ_GRIDGEOMETRY2D})); // reading parameters writeParameters = new ParameterGroup( new DefaultParameterDescriptorGroup( mInfo, new GeneralParameterDescriptor[] {GEOTOOLS_WRITE_PARAMS})); }
/** Sets the metadata information. */ private void setInfo() { HashMap<String, String> info = new HashMap<String, String>(); info.put("name", "ArcGrid"); info.put("description", "ARC/INFO ASCII GRID Coverage Format"); info.put("vendor", "Geotools"); info.put("docURL", "http://gdal.velocet.ca/projects/aigrid/index.html"); info.put("version", "1.0"); mInfo = info; // writing parameters writeParameters = new ParameterGroup( new DefaultParameterDescriptorGroup( mInfo, new GeneralParameterDescriptor[] { GRASS, GEOTOOLS_WRITE_PARAMS, FORCE_CELLSIZE })); // reading parameters readParameters = new ParameterGroup( new DefaultParameterDescriptorGroup( mInfo, new GeneralParameterDescriptor[] {READ_GRIDGEOMETRY2D})); }
private void setInfo() { // information for this format HashMap<String, String> info = new HashMap<String, String>(); info.put("name", "WorldImage"); info.put("description", "A raster file accompanied by a spatial data file"); info.put("vendor", "Geotools"); info.put("docURL", "http://www.geotools.org/WorldImageReader+formats"); info.put("version", "1.0"); mInfo = info; // reading parameters readParameters = new ParameterGroup( new DefaultParameterDescriptorGroup( mInfo, new GeneralParameterDescriptor[] { READ_GRIDGEOMETRY2D, })); // writing parameters writeParameters = new ParameterGroup( new DefaultParameterDescriptorGroup( mInfo, new GeneralParameterDescriptor[] {FORMAT})); }
/** Sets the metadata information. */ private void setInfo() { final HashMap<String, String> info = new HashMap<String, String>(); info.put("name", "GRIB"); info.put("description", "GRIB store plugin"); info.put("vendor", "Geotools"); info.put("docURL", ""); info.put("version", "1.0"); mInfo = info; // reading parameters readParameters = new ParameterGroup( new DefaultParameterDescriptorGroup( mInfo, new GeneralParameterDescriptor[] { READ_GRIDGEOMETRY2D, TIME, ELEVATION, FILTER, })); // reading parameters writeParameters = null; }
/** Sets the metadata information. */ private void setInfo() { HashMap<String, String> info = new HashMap<String, String>(); info.put("name", "ImageMosaicJDBC"); info.put("description", "Image mosaicking/pyramidal jdbc plugin"); info.put("vendor", "Geotools"); info.put("docURL", ""); info.put("version", "1.0"); mInfo = info; // reading parameters readParameters = new ParameterGroup( new DefaultParameterDescriptorGroup( mInfo, new GeneralParameterDescriptor[] { READ_GRIDGEOMETRY2D, OUTPUT_TRANSPARENT_COLOR, BACKGROUND_COLOR })); // reading parameters writeParameters = null; }
/** Sets the metadata information. */ protected void setInfo() { HashMap<String, String> info = new HashMap<String, String>(); info.put("name", "JP2K (Direct) "); info.put("description", "JP2K (Direct) Coverage Format"); info.put("vendor", "Geotools"); info.put("docURL", ""); // TODO: set something info.put("version", "1.0"); mInfo = info; // writing parameters writeParameters = null; readParameters = new ParameterGroup( new DefaultParameterDescriptorGroup( mInfo, new GeneralParameterDescriptor[] { READ_GRIDGEOMETRY2D, INPUT_TRANSPARENT_COLOR, USE_JAI_IMAGEREAD, USE_MULTITHREADING, SUGGESTED_TILE_SIZE, })); }
new DefaultParameterDescriptorGroup( mInfo, new GeneralParameterDescriptor[] {
/** Sets the metadata information. */ private void setInfo() { Map<String, String> info = new HashMap<String, String>(); info.put("name", "ArcSDE Raster"); info.put("description", "ArcSDE Raster Format"); info.put("vendor", "Geotools "); info.put("docURL", ""); info.put("version", GeoTools.getVersion().toString()); mInfo = info; readParameters = new ParameterGroup( new DefaultParameterDescriptorGroup( mInfo, new GeneralParameterDescriptor[] { READ_GRIDGEOMETRY2D, OVERVIEW_POLICY })); }
/** * Constructs a parameter group from a set of alias. The parameter group is identified by codes * provided by one or more authorities. Common authorities are {@link Citations#OGC OGC} and * {@link Citations#EPSG EPSG} for example. * * <p>Special rules: * * <ul> * <li>The first entry in the {@code identifiers} array is the {@linkplain * ParameterDescriptorGroup#getName primary name}. * <li>If a an entry do not implements the {@link GenericName} interface, it is an {@linkplain * ParameterDescriptorGroup#getIdentifiers identifiers}. * <li>All others are {@linkplain ParameterDescriptorGroup#getAlias aliases}. * </ul> * * @param identifiers The operation identifiers. Most contains at least one entry. * @param parameters The set of parameters, or {@code null} or an empty array if none. * @return The descriptor for the given identifiers. */ protected static ParameterDescriptorGroup createDescriptorGroup( final ReferenceIdentifier[] identifiers, final GeneralParameterDescriptor[] parameters) { return new DefaultParameterDescriptorGroup(toMap(identifiers), parameters); }
public ParameterDescriptorGroup getParameters() { Param params[] = getParametersInfo(); DefaultParameterDescriptor parameters[] = new DefaultParameterDescriptor[params.length]; for (int i = 0; i < params.length; i++) { parameters[i] = new ParamDescriptor(params[i]); } Map properties = new HashMap(); properties.put("name", getDisplayName()); properties.put("remarks", getDescription()); return new DefaultParameterDescriptorGroup(properties, parameters); }
/** Sets the metadata information for this format */ private void setInfo() { HashMap<String, String> info = new HashMap<String, String>(); info.put("name", "ImagePyramid"); info.put("description", "Image pyramidal plugin"); info.put("vendor", "Geotools"); info.put("docURL", ""); info.put("version", "1.0"); mInfo = info; // reading parameters. Inheriting them from the ImageMosaic final ImageMosaicFormat formatForParameters = new ImageMosaicFormat(); final ParameterValueGroup readParams = formatForParameters.getReadParameters(); final DefaultParameterDescriptorGroup descriptor = (DefaultParameterDescriptorGroup) readParams.getDescriptor(); List<GeneralParameterDescriptor> descriptors = descriptor.descriptors(); GeneralParameterDescriptor[] descriptorArray = new GeneralParameterDescriptor[descriptors.size()]; descriptorArray = descriptors.toArray(descriptorArray); readParameters = new ParameterGroup(new DefaultParameterDescriptorGroup(mInfo, descriptorArray)); // writing parameters writeParameters = null; }
@Override public ParameterValueGroup getReadParameters() { HashMap<String, String> info = new HashMap<String, String>(); info.put("name", "bandTester"); info.put("description", "desc"); info.put("vendor", "vendor"); info.put("docURL", "http://www.geotools.org"); info.put("version", "1.0"); List<GeneralParameterDescriptor> params = new ArrayList<GeneralParameterDescriptor>(); params.add(AbstractGridFormat.BANDS); return new ParameterGroup( new DefaultParameterDescriptorGroup( info, params.toArray(new GeneralParameterDescriptor[params.size()]))); } };
@Override public ParameterValueGroup getReadParameters() { HashMap<String, String> info = new HashMap<String, String>(); info.put("name", "bandTester"); info.put("description", "desc"); info.put("vendor", "vendor"); info.put("docURL", "http://www.geotools.org"); info.put("version", "1.0"); List<GeneralParameterDescriptor> params = new ArrayList<GeneralParameterDescriptor>(); params.add(AbstractGridFormat.BANDS); return new ParameterGroup( new DefaultParameterDescriptorGroup( info, params.toArray(new GeneralParameterDescriptor[params.size()]))); } };