[ 
https://issues.apache.org/jira/browse/SIS-337?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15840132#comment-15840132
 ] 

Martin Desruisseaux commented on SIS-337:
-----------------------------------------

In order to try to address the need better, I would like to know: for 
applications that need an embedded EPSG database, is there a need for the full 
EPSG database or do such applications typically know in advance the EPSG codes 
they are interested on?

I was wondering if it would be useful to have a mechanism like that (the 
{{@PrefetchCRS}} annotation does not exist yet - this part of the proposal for 
which I would like to evaluate the interest):

{code:java}
@PrefetchCRS("EPSG:3395")
CoordinateReferenceSystem myCRS;
{code}

An annotation processing tool provided by Apache SIS would inject automatically 
the necessary code for initializing {{myCRS}} to the EPSG:3395 Coordinate 
Reference System. The developer would need the EPSG database at build time, but 
not at runtime; the CRS definition would be copied for example using Java 
object serialization. If there is any {{CoordinateOperation}} explicitly 
defined in the EPSG database for some pair of CRS declared in different 
{{@PrefetchCRS}} annotation, they would also be copied.

Of course this approach would be useful only if an application is interest in a 
relatively small set of CRS known at build time.


> Package EPSG Derby DB in ​sis-epsg jar, eliminating the need for external 
> SIS_DATA dir
> --------------------------------------------------------------------------------------
>
>                 Key: SIS-337
>                 URL: https://issues.apache.org/jira/browse/SIS-337
>             Project: Spatial Information Systems
>          Issue Type: Wish
>          Components: Referencing
>    Affects Versions: 0.7
>            Reporter: Kevin Mehall
>
> Since [Derby 
> supports|https://db.apache.org/derby/docs/10.7/devguide/cdevdeploy11201.html] 
> read-only databases in .jar files, is there a reason that the 
> `org.apache.sis.non-free:​sis-epsg` package includes SQL source to create an 
> external database, rather than the database itself?
> It would make deployment much easier if there were no need for a SIS_DATA 
> directory and environment variable, and adding the dependency were the only 
> thing necessary.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to