Java Doc for OrderedAxisAuthorityFactory.java in  » GIS » GeoTools-2.4.1 » org » geotools » referencing » factory » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » GIS » GeoTools 2.4.1 » org.geotools.referencing.factory 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


org.geotools.referencing.factory.ReferencingFactory
   org.geotools.referencing.factory.AbstractAuthorityFactory
      org.geotools.referencing.factory.AuthorityFactoryAdapter
         org.geotools.referencing.factory.TransformedAuthorityFactory
            org.geotools.referencing.factory.OrderedAxisAuthorityFactory

OrderedAxisAuthorityFactory
public class OrderedAxisAuthorityFactory extends TransformedAuthorityFactory implements CSAuthorityFactory,CRSAuthorityFactory,Comparator(Code)
An authority factory which delegates all the work to an other factory, and reorder the axis in some pre-determined order. This factory is mostly used by application expecting geographic coordinates in (longitude, latitude) order, while most geographic CRS specified in the EPSG database use the opposite axis order.

It is better to avoid this class if you can. This class exists primarily for compatibility with external data or applications that assume (longitude, latitude) axis order no matter what the EPSG database said, for example Shapefiles.

The axis order can be specified at construction time as an array of . If no such array is explicitly specified, then the default order is , , , , , , , , , , , , and . This means that, for example, axis with East or West direction will be placed before any axis with North or South direction. Axis directions not specified in the table (for example AxisDirection.OTHER OTHER ) will be ordered last. This is somewhat equivalent to the ordering of Double.NaN NaN values in an array of double .

Notes:

  • This class compares only the " " axis directions, so North and South are considered equivalent.
  • The default direction order may changes in future Geotools version in order to fit what appears to be the most common usage on the market.
  • The actual axis ordering is determined by the OrderedAxisAuthorityFactory.compare compare method implementation. Subclasses may override this method if the want to provide a more sophesticated axis ordering.

For some authority factories, an instance of this class can be obtained by passing a Hints.FORCE_LONGITUDE_FIRST_AXIS_ORDER FORCE_LONGITUDE_FIRST_AXIS_ORDER hint to the (...) method. Whatever this hint is supported or not is authority dependent. Example:

 Hints                   hints = new Hints(Hints.FORCE_LONGITUDE_FIRST_AXIS_ORDER, Boolean.TRUE);
 CRSAuthorityFactory   factory = FactoryFinder.getCRSAuthorityFactory("EPSG", hints);
 CoordinateReferenceSystem crs = factory.createCoordinateReferenceSystem("EPSG:4326");
 
This class is named ordered axis authority factory instead of something like longitude first axis order because the axis order can be user-supplied. The (longitude, latitude) order just appears to be the default one.
since:
   2.2
version:
   $Id: OrderedAxisAuthorityFactory.java 25406 2007-05-03 18:08:10Z desruisseaux $
author:
   Martin Desruisseaux
See Also:   Hints.FORCE_LONGITUDE_FIRST_AXIS_ORDER
See Also:   Hints.FORCE_STANDARD_AXIS_UNITS


Field Summary
final protected  booleanforceStandardDirections
     true if this authority factory should also force the axis to their standard direction.
final protected  booleanforceStandardUnits
     true if this authority factory should also force all angular units to decimal degrees and linear units to meters.

Constructor Summary
public  OrderedAxisAuthorityFactory(String authority, Hints userHints, AxisDirection[] axisOrder)
     Creates a factory which will reorder the axis of all objects created by the default authority factories.
public  OrderedAxisAuthorityFactory(AbstractAuthorityFactory factory, Hints userHints, AxisDirection[] axisOrder)
     Creates a factory which will reorder the axis of all objects created by the supplied factory.

Method Summary
public  intcompare(Object axis1, Object axis2)
     Compares two axis for order.
protected  Unitreplace(Unit units)
     Replaces the specified unit, if applicable.
protected  AxisDirectionreplace(AxisDirection direction)
     Replaces the specified direction, if applicable.

Field Detail
forceStandardDirections
final protected boolean forceStandardDirections(Code)
true if this authority factory should also force the axis to their standard direction. For example if true , then axis with increasing values toward South will be converted to axis with increasing values toward North. The default value is false .
See Also:   Hints.FORCE_STANDARD_AXIS_DIRECTIONS
since:
   2.3



forceStandardUnits
final protected boolean forceStandardUnits(Code)
true if this authority factory should also force all angular units to decimal degrees and linear units to meters. The default value is false .
See Also:   Hints.FORCE_STANDARD_AXIS_UNITS
since:
   2.3




Constructor Detail
OrderedAxisAuthorityFactory
public OrderedAxisAuthorityFactory(String authority, Hints userHints, AxisDirection[] axisOrder) throws FactoryRegistryException, IllegalArgumentException(Code)
Creates a factory which will reorder the axis of all objects created by the default authority factories. The factories are fetched using ReferencingFactoryFinder . This constructor accepts the following hints:


Parameters:
  authority - The authority to wraps (example: "EPSG" ). If null ,then all authority factories must be explicitly specified in the set of hints.
Parameters:
  userHints - An optional set of hints, or null if none.
Parameters:
  axisOrder - An array of axis directions that determine the axis order wanted,or null for the default axis order.
throws:
  FactoryRegistryException - if at least one factory can not be obtained.
throws:
  IllegalArgumentException - If at least two axis directions are colinear.
since:
   2.3



OrderedAxisAuthorityFactory
public OrderedAxisAuthorityFactory(AbstractAuthorityFactory factory, Hints userHints, AxisDirection[] axisOrder) throws IllegalArgumentException(Code)
Creates a factory which will reorder the axis of all objects created by the supplied factory. This constructor accepts the following optional hints:


Parameters:
  factory - The factory that produces objects using arbitrary axis order.
Parameters:
  userHints - An optional set of hints, or null if none.
Parameters:
  axisOrder - An array of axis directions that determine the axis order wanted,or null for the default axis order.
throws:
  IllegalArgumentException - If at least two axis directions are colinear.
since:
   2.3




Method Detail
compare
public int compare(Object axis1, Object axis2)(Code)
Compares two axis for order. This method is invoked automatically by the OrderedAxisAuthorityFactory.replace(CoordinateSystem) replace method for ordering the axis in a coordinate system. The default implementation orders the axis according their , using the direction table given at (see also the class description). Subclasses may override this method if they want to define a more sophesticated axis ordering.
Parameters:
  axis1 - The first axis to compare.
Parameters:
  axis2 - The second axis to compare. A negative integer if axis1 should appears before axis2 , or apositive number if axis2 should appears before axis1 , or 0 ifthe two axis are unordered one relative to the other.CoordinateSystemAxis
since:
   2.3



replace
protected Unit replace(Unit units)(Code)
Replaces the specified unit, if applicable. This method is invoked automatically by the OrderedAxisAuthorityFactory.replace(CoordinateSystem) method. The default implementation replaces the unit only if the Hints.FORCE_STANDARD_AXIS_UNITS FORCE_STANDARD_AXIS_UNITS hint was specified as Boolean.TRUE TRUE at construction time. In such case, the default substitution table is:

  • Any linear units converted to
  • and converted to

This default substitution table may be expanded in future Geotools versions.
since:
   2.3




replace
protected AxisDirection replace(AxisDirection direction)(Code)
Replaces the specified direction, if applicable. This method is invoked automatically by the OrderedAxisAuthorityFactory.replace(CoordinateSystem) method. The default implementation replaces the direction only if the Hints.FORCE_STANDARD_AXIS_DIRECTIONS FORCE_STANDARD_AXIS_DIRECTIONS hint was specified as Boolean.TRUE TRUE at construction time. In such case, the default substitution table is as specified in the AxisDirection.absolute method. Subclasses may override this method if they want to use a different substitution table.
since:
   2.3



Methods inherited from org.geotools.referencing.factory.TransformedAuthorityFactory
public Set createFromCoordinateReferenceSystemCodes(String sourceCode, String targetCode) throws FactoryException(Code)(Java Doc)
public synchronized void dispose() throws FactoryException(Code)(Java Doc)
public int getPriority()(Code)(Java Doc)
protected Unit replace(Unit units) throws FactoryException(Code)(Java Doc)
protected AxisDirection replace(AxisDirection direction) throws FactoryException(Code)(Java Doc)
protected CoordinateSystemAxis replace(CoordinateSystemAxis axis) throws FactoryException(Code)(Java Doc)
protected CoordinateSystem replace(CoordinateSystem cs) throws FactoryException(Code)(Java Doc)
protected Datum replace(Datum datum) throws FactoryException(Code)(Java Doc)
protected CoordinateReferenceSystem replace(CoordinateReferenceSystem crs) throws FactoryException(Code)(Java Doc)
protected CoordinateOperation replace(CoordinateOperation operation) throws FactoryException(Code)(Java Doc)

Fields inherited from org.geotools.referencing.factory.AuthorityFactoryAdapter
final protected CRSAuthorityFactory crsFactory(Code)(Java Doc)
final protected CSAuthorityFactory csFactory(Code)(Java Doc)
final protected DatumAuthorityFactory datumFactory(Code)(Java Doc)
final protected CoordinateOperationAuthorityFactory operationFactory(Code)(Java Doc)

Methods inherited from org.geotools.referencing.factory.AuthorityFactoryAdapter
public CartesianCS createCartesianCS(String code) throws FactoryException(Code)(Java Doc)
public CompoundCRS createCompoundCRS(String code) throws FactoryException(Code)(Java Doc)
public CoordinateOperation createCoordinateOperation(String code) throws FactoryException(Code)(Java Doc)
public CoordinateReferenceSystem createCoordinateReferenceSystem(String code) throws FactoryException(Code)(Java Doc)
public CoordinateSystem createCoordinateSystem(String code) throws FactoryException(Code)(Java Doc)
public CoordinateSystemAxis createCoordinateSystemAxis(String code) throws FactoryException(Code)(Java Doc)
public CylindricalCS createCylindricalCS(String code) throws FactoryException(Code)(Java Doc)
public Datum createDatum(String code) throws FactoryException(Code)(Java Doc)
public DerivedCRS createDerivedCRS(String code) throws FactoryException(Code)(Java Doc)
public Ellipsoid createEllipsoid(String code) throws FactoryException(Code)(Java Doc)
public EllipsoidalCS createEllipsoidalCS(String code) throws FactoryException(Code)(Java Doc)
public EngineeringCRS createEngineeringCRS(String code) throws FactoryException(Code)(Java Doc)
public EngineeringDatum createEngineeringDatum(String code) throws FactoryException(Code)(Java Doc)
public Extent createExtent(String code) throws FactoryException(Code)(Java Doc)
public Set createFromCoordinateReferenceSystemCodes(String sourceCode, String targetCode) throws FactoryException(Code)(Java Doc)
public GeocentricCRS createGeocentricCRS(String code) throws FactoryException(Code)(Java Doc)
public GeodeticDatum createGeodeticDatum(String code) throws FactoryException(Code)(Java Doc)
public GeographicCRS createGeographicCRS(String code) throws FactoryException(Code)(Java Doc)
public ImageCRS createImageCRS(String code) throws FactoryException(Code)(Java Doc)
public ImageDatum createImageDatum(String code) throws FactoryException(Code)(Java Doc)
public IdentifiedObject createObject(String code) throws FactoryException(Code)(Java Doc)
public OperationMethod createOperationMethod(String code) throws FactoryException(Code)(Java Doc)
public ParameterDescriptor createParameterDescriptor(String code) throws FactoryException(Code)(Java Doc)
public PolarCS createPolarCS(String code) throws FactoryException(Code)(Java Doc)
public PrimeMeridian createPrimeMeridian(String code) throws FactoryException(Code)(Java Doc)
public ProjectedCRS createProjectedCRS(String code) throws FactoryException(Code)(Java Doc)
public SphericalCS createSphericalCS(String code) throws FactoryException(Code)(Java Doc)
public TemporalCRS createTemporalCRS(String code) throws FactoryException(Code)(Java Doc)
public TemporalDatum createTemporalDatum(String code) throws FactoryException(Code)(Java Doc)
public TimeCS createTimeCS(String code) throws FactoryException(Code)(Java Doc)
public Unit createUnit(String code) throws FactoryException(Code)(Java Doc)
public VerticalCRS createVerticalCRS(String code) throws FactoryException(Code)(Java Doc)
public VerticalCS createVerticalCS(String code) throws FactoryException(Code)(Java Doc)
public VerticalDatum createVerticalDatum(String code) throws FactoryException(Code)(Java Doc)
Collection dependencies()(Code)(Java Doc)
public Citation getAuthority()(Code)(Java Doc)
public Set getAuthorityCodes(Class type) throws FactoryException(Code)(Java Doc)
AuthorityFactory getAuthorityFactory(Class type, String code) throws FactoryException(Code)(Java Doc)
protected AuthorityFactory getAuthorityFactory(String code) throws FactoryException(Code)(Java Doc)
public String getBackingStoreDescription() throws FactoryException(Code)(Java Doc)
protected CRSAuthorityFactory getCRSAuthorityFactory(String code) throws FactoryException(Code)(Java Doc)
protected CSAuthorityFactory getCSAuthorityFactory(String code) throws FactoryException(Code)(Java Doc)
protected CoordinateOperationAuthorityFactory getCoordinateOperationAuthorityFactory(String code) throws FactoryException(Code)(Java Doc)
final CoordinateOperationFactory getCoordinateOperationFactory() throws FactoryException(Code)(Java Doc)
protected DatumAuthorityFactory getDatumAuthorityFactory(String code) throws FactoryException(Code)(Java Doc)
public InternationalString getDescriptionText(String code) throws FactoryException(Code)(Java Doc)
final ReferencingFactoryContainer getFactoryContainer(boolean crs)(Code)(Java Doc)
public IdentifiedObjectFinder getIdentifiedObjectFinder(Class type) throws FactoryException(Code)(Java Doc)
public Citation getVendor()(Code)(Java Doc)
public boolean isAvailable()(Code)(Java Doc)
final boolean isCodeMethodOverriden()(Code)(Java Doc)
Unit replace(Unit units) throws FactoryException(Code)(Java Doc)
CoordinateSystemAxis replace(CoordinateSystemAxis axis) throws FactoryException(Code)(Java Doc)
CoordinateSystem replace(CoordinateSystem cs) throws FactoryException(Code)(Java Doc)
Datum replace(Datum datum) throws FactoryException(Code)(Java Doc)
CoordinateReferenceSystem replace(CoordinateReferenceSystem crs) throws FactoryException(Code)(Java Doc)
CoordinateOperation replace(CoordinateOperation operation) throws FactoryException(Code)(Java Doc)
boolean sameAuthorityCodes(AuthorityFactory factory)(Code)(Java Doc)
static boolean sameAuthorityCodes(AuthorityFactory backingStore, AuthorityFactory factory)(Code)(Java Doc)
protected String toBackingFactoryCode(String code) throws FactoryException(Code)(Java Doc)

Methods inherited from org.geotools.referencing.factory.AbstractAuthorityFactory
public CartesianCS createCartesianCS(String code) throws FactoryException(Code)(Java Doc)
public CompoundCRS createCompoundCRS(String code) throws FactoryException(Code)(Java Doc)
public CoordinateOperation createCoordinateOperation(String code) throws FactoryException(Code)(Java Doc)
public CoordinateReferenceSystem createCoordinateReferenceSystem(String code) throws FactoryException(Code)(Java Doc)
public CoordinateSystem createCoordinateSystem(String code) throws FactoryException(Code)(Java Doc)
public CoordinateSystemAxis createCoordinateSystemAxis(String code) throws FactoryException(Code)(Java Doc)
public CylindricalCS createCylindricalCS(String code) throws FactoryException(Code)(Java Doc)
public Datum createDatum(String code) throws FactoryException(Code)(Java Doc)
public DerivedCRS createDerivedCRS(String code) throws FactoryException(Code)(Java Doc)
public Ellipsoid createEllipsoid(String code) throws FactoryException(Code)(Java Doc)
public EllipsoidalCS createEllipsoidalCS(String code) throws FactoryException(Code)(Java Doc)
public EngineeringCRS createEngineeringCRS(String code) throws FactoryException(Code)(Java Doc)
public EngineeringDatum createEngineeringDatum(String code) throws FactoryException(Code)(Java Doc)
public Extent createExtent(String code) throws FactoryException(Code)(Java Doc)
public Set createFromCoordinateReferenceSystemCodes(String sourceCode, String targetCode) throws FactoryException(Code)(Java Doc)
public GeocentricCRS createGeocentricCRS(String code) throws FactoryException(Code)(Java Doc)
public GeodeticDatum createGeodeticDatum(String code) throws FactoryException(Code)(Java Doc)
public GeographicCRS createGeographicCRS(String code) throws FactoryException(Code)(Java Doc)
public ImageCRS createImageCRS(String code) throws FactoryException(Code)(Java Doc)
public ImageDatum createImageDatum(String code) throws FactoryException(Code)(Java Doc)
public IdentifiedObject createObject(String code) throws FactoryException(Code)(Java Doc)
public OperationMethod createOperationMethod(String code) throws FactoryException(Code)(Java Doc)
public ParameterDescriptor createParameterDescriptor(String code) throws FactoryException(Code)(Java Doc)
public PolarCS createPolarCS(String code) throws FactoryException(Code)(Java Doc)
public PrimeMeridian createPrimeMeridian(String code) throws FactoryException(Code)(Java Doc)
public ProjectedCRS createProjectedCRS(String code) throws FactoryException(Code)(Java Doc)
public SphericalCS createSphericalCS(String code) throws FactoryException(Code)(Java Doc)
public TemporalCRS createTemporalCRS(String code) throws FactoryException(Code)(Java Doc)
public TemporalDatum createTemporalDatum(String code) throws FactoryException(Code)(Java Doc)
public TimeCS createTimeCS(String code) throws FactoryException(Code)(Java Doc)
public Unit createUnit(String code) throws FactoryException(Code)(Java Doc)
public VerticalCRS createVerticalCRS(String code) throws FactoryException(Code)(Java Doc)
public VerticalCS createVerticalCS(String code) throws FactoryException(Code)(Java Doc)
public VerticalDatum createVerticalDatum(String code) throws FactoryException(Code)(Java Doc)
public void dispose() throws FactoryException(Code)(Java Doc)
abstract public Citation getAuthority()(Code)(Java Doc)
public String getBackingStoreDescription() throws FactoryException(Code)(Java Doc)
public IdentifiedObjectFinder getIdentifiedObjectFinder(Class type) throws FactoryException(Code)(Java Doc)
boolean isAvailable()(Code)(Java Doc)
final protected NoSuchAuthorityCodeException noSuchAuthorityCode(Class type, String code)(Code)(Java Doc)
boolean sameAuthorityCodes(AuthorityFactory factory)(Code)(Java Doc)
protected String trimAuthority(String code)(Code)(Java Doc)

Fields inherited from org.geotools.referencing.factory.ReferencingFactory
final static Citation ALL(Code)(Java Doc)
final public static Logger LOGGER(Code)(Java Doc)

Methods inherited from org.geotools.referencing.factory.ReferencingFactory
Collection dependencies()(Code)(Java Doc)
protected static void ensureNonNull(String name, Object object) throws InvalidParameterValueException(Code)(Java Doc)
public Citation getVendor()(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.