01: /*
02: * GeoTools - OpenSource mapping toolkit
03: * http://geotools.org
04: *
05: * (C) 2003-2006, Geotools Project Managment Committee (PMC)
06: * (C) 2001, Institut de Recherche pour le Développement
07: *
08: * This library is free software; you can redistribute it and/or
09: * modify it under the terms of the GNU Lesser General Public
10: * License as published by the Free Software Foundation; either
11: * version 2.1 of the License, or (at your option) any later version.
12: *
13: * This library is distributed in the hope that it will be useful,
14: * but WITHOUT ANY WARRANTY; without even the implied warranty of
15: * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16: * Lesser General Public License for more details.
17: */
18: package org.geotools.referencing.operation.transform;
19:
20: // OpenGIS dependencies
21: import org.opengis.referencing.operation.MathTransform;
22: import org.opengis.referencing.operation.MathTransform2D;
23:
24: /**
25: * Concatenated transform in which the resulting transform is two-dimensional.
26: *
27: * @since 2.0
28: * @source $URL: http://svn.geotools.org/geotools/tags/2.4.1/modules/library/referencing/src/main/java/org/geotools/referencing/operation/transform/ConcatenatedTransform2D.java $
29: * @version $Id: ConcatenatedTransform2D.java 20874 2006-08-07 10:00:01Z jgarnett $
30: * @author Martin Desruisseaux
31: */
32: final class ConcatenatedTransform2D extends ConcatenatedTransform
33: implements MathTransform2D {
34: /**
35: * Serial number for interoperability with different versions.
36: */
37: private static final long serialVersionUID = -7307709788564866500L;
38:
39: /**
40: * Constructs a concatenated transform.
41: */
42: public ConcatenatedTransform2D(final MathTransform transform1,
43: final MathTransform transform2) {
44: super (transform1, transform2);
45: }
46:
47: /**
48: * Check if transforms are compatibles with this implementation.
49: */
50: boolean isValid() {
51: return super .isValid() && getSourceDimensions() == 2
52: && getTargetDimensions() == 2;
53: }
54: }
|