Java Doc for DataSource.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 Reference  Class Diagram Java Document (Java Doc) 


org.geotools.referencing.factory.epsg.DataSource

All known Subclasses:   org.geotools.referencing.factory.epsg.HSQLDataSource,  org.geotools.referencing.factory.epsg.AccessDataSource,  org.geotools.referencing.factory.epsg.SimpleDataSource,  org.geotools.referencing.factory.epsg.PostgreDataSource,
DataSource
public interface DataSource extends javax.sql.DataSource(Code)
A marker interface for data source to an EPSG database. This sub-interface of J2SE's DataSource is used as a category for javax.imageio.spi.ServiceRegistry . EPSG data sources should be registered in the following file:
META-INF/services/org.geotools.referencing.factory.epsg.DataSource
For an example, see org.geotools.referencing.factory.epsg.AccessDataSource and its META-INF/services/ registration in the plugin/epsg-access module. This is a very small module which can be used as a starting point for custom EPSG data sources.

How EPSG factory are found

By default, only one ThreadedEpsgFactory is registered and returned by ReferencingFactoryFinder . We don't need to register any other implementation for an EPSG factory backed by a SQL database. However, ThreadedEpsgFactory alone is not suffisient for querying the database. It needs one more "plugable" information: the connection to the EPSG database. This DataSource interface is there for providing such connection to ThreadedEpsgFactory .

Some time after ThreadedEpsgFactory is registered as an EPSG factory, it looks for a DataSource using the same plugins mechanism than for factories. In other words, DataSource is a second level of plugins used internally by ThreadedEpsgFactory .
since:
   2.1
version:
   $Id: DataSource.java 25972 2007-06-21 13:38:35Z desruisseaux $
author:
   Martin Desruisseaux javax.sql.DataSource ThreadedEpsgFactoryThreadedEpsgFactory META-INF/services



Field Summary
 intMAXIMUM_PRIORITY
     The maximum priority for a data source, which is .
 intMINIMUM_PRIORITY
     The minimum priority for a data source, which is .
 intNORMAL_PRIORITY
     The default priority, which is .


Method Summary
 AbstractAuthorityFactorycreateFactory(Hints hints)
     Opens a connection and creates an EPSG factory for it.
 intgetPriority()
     Returns the priority for this data source, as a number between DataSource.MINIMUM_PRIORITY and DataSource.MAXIMUM_PRIORITY inclusive.

Field Detail
MAXIMUM_PRIORITY
int MAXIMUM_PRIORITY(Code)
The maximum priority for a data source, which is . Data sources with highest priority will be preferred to any other data sources.



MINIMUM_PRIORITY
int MINIMUM_PRIORITY(Code)
The minimum priority for a data source, which is . Data sources with lowest priority will be used only if there is no other source available.



NORMAL_PRIORITY
int NORMAL_PRIORITY(Code)
The default priority, which is .





Method Detail
createFactory
AbstractAuthorityFactory createFactory(Hints hints) throws SQLException(Code)
Opens a connection and creates an EPSG factory for it. This method may returns a sub-class of DirectEpsgFactory if it wants to use slightly different SQL queries.
Parameters:
  hints - A map of hints, including the low-level factories to use for CRS creation.This argument should be given unchanged to DirectEpsgFactory constructor. The using SQL queries appropriatefor this data source.
throws:
  SQLException - if connection to the database failed.



getPriority
int getPriority()(Code)
Returns the priority for this data source, as a number between DataSource.MINIMUM_PRIORITY and DataSource.MAXIMUM_PRIORITY inclusive.



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