Source Code Cross Referenced for EsriExtension.java in  » GIS » GeoTools-2.4.1 » org » geotools » referencing » factory » epsg » 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.epsg 
Source Cross Referenced  Class Diagram Java Document (Java Doc) 


001:        /*
002:         *    GeoTools - OpenSource mapping toolkit
003:         *    http://geotools.org
004:         *    (C) 2005-2006, GeoTools Project Managment Committee (PMC)
005:         *   
006:         *    This library is free software; you can redistribute it and/or
007:         *    modify it under the terms of the GNU Lesser General Public
008:         *    License as published by the Free Software Foundation;
009:         *    version 2.1 of the License.
010:         *
011:         *    This library is distributed in the hope that it will be useful,
012:         *    but WITHOUT ANY WARRANTY; without even the implied warranty of
013:         *    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
014:         *    Lesser General Public License for more details.
015:         */
016:        package org.geotools.referencing.factory.epsg;
017:
018:        // J2SE dependencies
019:        import java.net.URL;
020:
021:        // OpenGIS dependencies
022:        import org.opengis.metadata.citation.Citation;
023:        import org.opengis.referencing.FactoryException;
024:
025:        // Geotools dependencies
026:        import org.geotools.factory.Hints;
027:        import org.geotools.metadata.iso.citation.Citations;
028:
029:        /**
030:         * Extends the EPSG database with {@linkplain CoordinateReferenceSystem Coordinate Reference Systems}
031:         * defined by ESRI. Those CRS will be registered both in {@code "ESRI"} and {@code "EPSG"} name space.
032:         *
033:         * @since 2.4
034:         * @source $URL: http://svn.geotools.org/geotools/tags/2.4.1/modules/plugin/epsg-extension/src/main/java/org/geotools/referencing/factory/epsg/EsriExtension.java $
035:         * @version $Id: EsriExtension.java 25668 2007-05-29 13:44:16Z desruisseaux $
036:         * @author Martin Desruisseaux
037:         */
038:        public class EsriExtension extends FactoryUsingWKT {
039:            /**
040:             * The default filename to read. This file will be searched in the
041:             * {@code org/geotools/referencing/factory/espg} directory in the
042:             * classpath or in a JAR file.
043:             *
044:             * @see #getDefinitionsURL
045:             */
046:            public static final String FILENAME = "esri.properties";
047:
048:            /**
049:             * Constructs an authority factory using the default set of factories.
050:             */
051:            public EsriExtension() {
052:                this (null);
053:            }
054:
055:            /**
056:             * Constructs an authority factory using a set of factories created from the specified hints.
057:             * This constructor recognizes the {@link Hints#CRS_FACTORY CRS}, {@link Hints#CS_FACTORY CS},
058:             * {@link Hints#DATUM_FACTORY DATUM} and {@link Hints#MATH_TRANSFORM_FACTORY MATH_TRANSFORM}
059:             * {@code FACTORY} hints.
060:             */
061:            public EsriExtension(final Hints hints) {
062:                super (hints, DEFAULT_PRIORITY - 5);
063:            }
064:
065:            /**
066:             * Returns the set of authorities to use as identifiers for the CRS to be created.
067:             * The default implementation returns {@linkplain Citations#ESRI ESRI} and
068:             * {@linkplain Citations#EPSG EPSG} authorities.
069:             */
070:            //@Override
071:            protected Citation[] getAuthorities() {
072:                return new Citation[] { Citations.ESRI, Citations.EPSG };
073:            }
074:
075:            /**
076:             * Returns the URL to the property file that contains CRS definitions.
077:             * The default implementation returns the URL to the {@value #FILENAME} file.
078:             *
079:             * @return The URL, or {@code null} if none.
080:             */
081:            protected URL getDefinitionsURL() {
082:                return EsriExtension.class.getResource(FILENAME);
083:            }
084:
085:            /**
086:             * Prints a list of codes that duplicate the ones provided in the {@link DefaultFactory}.
087:             * The factory tested is the one registered in {@link ReferencingFactoryFinder}.  By default, this
088:             * is this {@code EsriExtension} class backed by the {@value #FILENAME} property file.
089:             * This method can be invoked from the command line in order to check the content of the
090:             * property file. Valid arguments are:
091:             * <p>
092:             * <table>
093:             *   <tr><td>{@code -test}</td><td>Try to instantiate all CRS and reports any failure
094:             *       to do so.</td></tr>
095:             *   <tr><td>{@code -duplicated}</td><td>List all codes from the WKT factory that are
096:             *       duplicating a code from the SQL factory.</td></tr>
097:             * </table>
098:             *
099:             * @param  args Command line arguments.
100:             * @throws FactoryException if an error occured.
101:             */
102:            public static void main(final String[] args)
103:                    throws FactoryException {
104:                main(args, EsriExtension.class);
105:            }
106:        }
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.