/*
* Geotoolkit - An Open Source Java GIS Toolkit
* http://www.geotoolkit.org
*
* (C) 2011, Geomatys
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation;
* version 2.1 of the License.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*/
package org.geotoolkit.processing.vector.affinetransform;
import org.apache.sis.parameter.ParameterBuilder;
import org.geotoolkit.process.ProcessDescriptor;
import org.geotoolkit.process.Process;
import org.geotoolkit.processing.vector.VectorDescriptor;
import org.opengis.parameter.ParameterDescriptor;
import org.opengis.parameter.ParameterDescriptorGroup;
import org.opengis.parameter.ParameterValueGroup;
/**
* Parameters description of AffineTransform process.
* name of the process : "affinetransform"
* inputs :
* <ul>
* <li>FEATURE_IN "feature_in" FeatureCollection source</li>
* <li>TRANSFORM_IN "transform_in" AffineTransform</li>
* </ul>
* outputs :
* <ul>
* <li>FEATURE_OUT "feature_out" resulting FeatureCollection</li>
* </ul>
* @author Quentin Boileau
* @module
*/
public final class AffineTransformDescriptor extends VectorDescriptor {
/**Process name : affinetransform */
public static final String NAME = "affinetransform";
/**
* Mandatory - Feature Collection for clipping
*/
public static final ParameterDescriptor<java.awt.geom.AffineTransform> TRANSFORM_IN = new ParameterBuilder()
.addName("transform_in")
.setRemarks("The affine transformation to apply on Features geometries")
.setRequired(true)
.create(java.awt.geom.AffineTransform.class, null);
/** Input Parameters */
public static final ParameterDescriptorGroup INPUT_DESC =
new ParameterBuilder().addName("InputParameters").createGroup(FEATURE_IN, TRANSFORM_IN);
/** Ouput Parameters */
public static final ParameterDescriptorGroup OUTPUT_DESC =
new ParameterBuilder().addName("OutputParameters").createGroup(FEATURE_OUT);
/** Instance */
public static final ProcessDescriptor INSTANCE = new AffineTransformDescriptor();
/**
* Default constructor
*/
private AffineTransformDescriptor() {
super(NAME, "Apply an affine transformation in Features geometries", INPUT_DESC, OUTPUT_DESC);
}
/**
* {@inheritDoc }
*/
@Override
public Process createProcess(final ParameterValueGroup input) {
return new AffineTransformProcess(input);
}
}