Hi Travis,
the filter system does not have an official extension point for a store
specific functionality.
However, there's way that we already used for Oracle in order to handle a
KNN search that cannot
be made available as a filter (like, it does not have a semantic matching
any of the existing filters).
It has been implemented as an empty geotools function:
https://github.com/geotools/geotools/blob/7353125d50adff57fbfc3548a7426b67e2ff13db/modules/plugin/jdbc/jdbc-oracle/src/main/java/org/geotools/filter/function/FilterFunction_sdonn.java
Then the encoder knows what to do with it:
https://github.com/geotools/geotools/blob/7353125d50adff57fbfc3548a7426b67e2ff13db/modules/plugin/jdbc/jdbc-oracle/src/main/java/org/geotools/data/oracle/OracleFilterToSQL.java#L166
The function unfortunately shows up as a generic one, but if you try to use
it against anything but Oracle it fails
(the name should help with that "SDO" should be known to Oracle users, and
the function only shows up if the Oracle module is plugged in).
Hope this helps
Cheers
Andrea
On Mon, Nov 27, 2017 at 7:29 PM, Travis Brundage <[email protected]
> wrote:
> Greetings all,
>
> I've been working on developing a new JDBC DataStore for HP Vertica
> databases. Thus far, I seem to be successful in getting a new connection
> and ability to import data, but now I've been trying to work on getting the
> database's custom commands used by GeoServer. I'm a bit ignorant in how
> this works.
>
> Currently, I have a custom FilterToSQL class, VerticaFilterToSQL, which
> interprets an "Intersects" filter to write out an ST_Intersects command, in
> accordance with the database's specifications. This part makes sense, as it
> is a binary spatial operator comparing two geometries.
>
> However, I am attempting to write a custom function called STV_Intersects
> <https://my.vertica.com/docs/8.1.x/HTML/index.htm#Authoring/AnalyzingData/Geospatial/GeospatialAnalytics/STV_IntersectScalarFunctionVs.TransformFunction.htm>
> (documentation linked - there's actually two versions but my question is
> general for both). This function does not simply compare two geometries,
> but actually looks at the entire table for intersecting polygons.
>
> The best I have come up with thus far is that perhaps I need to write a
> custom visitor, as it does not fall under visitBinarySpatialOperator.
>
> Would anyone have any suggestions or pointers in the right direction for
> me regarding how to write a custom function like this?
>
> Cheers,
> Travis
>
> --
> Travis Brundage
> Software Engineer | Boundless
> [email protected]
> 250.888.2820 <(250)%20888-2820>
> @boundlessgeo
>
>
> ------------------------------------------------------------
> ------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> _______________________________________________
> GeoTools-Devel mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/geotools-devel
>
>
--
Regards,
Andrea Aime
==
GeoServer Professional Services from the experts! Visit http://goo.gl/it488V
for more information.
==
Ing. Andrea Aime
@geowolf
Technical Lead
GeoSolutions S.A.S.
Via di Montramito 3/A
55054 Massarosa (LU)
phone: +39 0584 962313
fax: +39 0584 1660272
mob: +39 339 8844549
http://www.geo-solutions.it
http://twitter.com/geosolutions_it
AVVERTENZE AI SENSI DEL D.Lgs. 196/2003
Le informazioni contenute in questo messaggio di posta elettronica e/o
nel/i file/s allegato/i sono da considerarsi strettamente riservate. Il
loro utilizzo è consentito esclusivamente al destinatario del messaggio,
per le finalità indicate nel messaggio stesso. Qualora riceviate questo
messaggio senza esserne il destinatario, Vi preghiamo cortesemente di
darcene notizia via e-mail e di procedere alla distruzione del messaggio
stesso, cancellandolo dal Vostro sistema. Conservare il messaggio stesso,
divulgarlo anche in parte, distribuirlo ad altri soggetti, copiarlo, od
utilizzarlo per finalità diverse, costituisce comportamento contrario ai
principi dettati dal D.Lgs. 196/2003.
The information in this message and/or attachments, is intended solely for
the attention and use of the named addressee(s) and may be confidential or
proprietary in nature or covered by the provisions of privacy act
(Legislative Decree June, 30 2003, no.196 - Italy's New Data Protection
Code).Any use not in accord with its purpose, any disclosure, reproduction,
copying, distribution, or either dissemination, either whole or partial, is
strictly forbidden except previous formal approval of the named
addressee(s). If you are not the intended recipient, please contact
immediately the sender by telephone, fax or e-mail and delete the
information in this message that has been received in error. The sender
does not give any warranty or accept liability as the content, accuracy or
completeness of sent messages and accepts no responsibility for changes
made after they were sent or for other risks which arise as a result of
e-mail transmission, viruses, etc.
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
GeoTools-Devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geotools-devel