You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lucene.apache.org by Ignacio Vera Sequeiros <iv...@eso.org> on 2017/05/26 08:46:48 UTC
Request to change visibility of classes in geo3d
Hi,
I am creating my own spatial context by wrapping the objects in lucene geo3d library and implement my own query which mixes the recursive and the serialized strategy to add precision to searches.
I had the following issue specially with polygons: The factory for creating polygons is slow and when serializing shapes, I already know if I am dealing with convex or concave polygons (in my case they are always concave). So when de-serializing a polygon I do not want to go through the factory to decide the type of polygon to create.
Wouldn't make sense to add the possibility to create a type of polygon directly? you cannot create the polygons directly as they are protected in the package. My suggestion request would be either to add methods in the polygon factory to create a type of polygons with no checking (e.g. makeConcavePolygon(...)) or change the visibility of the classes so that they can be instantiated directly.
I hope it makes sense.
Cheers,
Ignacio
Re: Request to change visibility of classes in geo3d
Posted by Karl Wright <da...@gmail.com>.
You could also solve this by adding additional unchecked factory methods,
no? I'm afraid Robert will not be too pleased with generally opening
things up.
Karl
On Fri, May 26, 2017 at 6:17 AM, Ignacio Vera Sequeiros <iv...@eso.org>
wrote:
> Done.
>
>
>
> Cheers,
>
>
>
> Ignacio Vera
>
>
>
> *From:* Michael McCandless [mailto:lucene@mikemccandless.com]
> *Sent:* Friday, May 26, 2017 11:02 AM
> *To:* Lucene/Solr dev <de...@lucene.apache.org>; Ignacio Vera Sequeiros <
> ivera@eso.org>
> *Subject:* Re: Request to change visibility of classes in geo3d
>
>
>
> I think that makes sense; can you open a Jira issue? Thanks.
>
>
> Mike McCandless
>
> http://blog.mikemccandless.com
>
>
>
> On Fri, May 26, 2017 at 4:46 AM, Ignacio Vera Sequeiros <iv...@eso.org>
> wrote:
>
> Hi,
>
>
>
> I am creating my own spatial context by wrapping the objects in lucene
> geo3d library and implement my own query which mixes the recursive and the
> serialized strategy to add precision to searches.
>
>
>
> I had the following issue specially with polygons: The factory for
> creating polygons is slow and when serializing shapes, I already know if I
> am dealing with convex or concave polygons (in my case they are always
> concave). So when de-serializing a polygon I do not want to go through the
> factory to decide the type of polygon to create.
>
>
>
> Wouldn't make sense to add the possibility to create a type of polygon
> directly? you cannot create the polygons directly as they are protected in
> the package. My suggestion request would be either to add methods in the
> polygon factory to create a type of polygons with no checking (e.g.
> makeConcavePolygon(…)) or change the visibility of the classes so that they
> can be instantiated directly.
>
>
>
> I hope it makes sense.
>
>
>
> Cheers,
>
>
>
> Ignacio
>
>
>
>
>
RE: Request to change visibility of classes in geo3d
Posted by Ignacio Vera Sequeiros <iv...@eso.org>.
Done.
Cheers,
Ignacio Vera
From: Michael McCandless [mailto:lucene@mikemccandless.com]
Sent: Friday, May 26, 2017 11:02 AM
To: Lucene/Solr dev <de...@lucene.apache.org>; Ignacio Vera Sequeiros <iv...@eso.org>
Subject: Re: Request to change visibility of classes in geo3d
I think that makes sense; can you open a Jira issue? Thanks.
Mike McCandless
http://blog.mikemccandless.com
On Fri, May 26, 2017 at 4:46 AM, Ignacio Vera Sequeiros <iv...@eso.org>> wrote:
Hi,
I am creating my own spatial context by wrapping the objects in lucene geo3d library and implement my own query which mixes the recursive and the serialized strategy to add precision to searches.
I had the following issue specially with polygons: The factory for creating polygons is slow and when serializing shapes, I already know if I am dealing with convex or concave polygons (in my case they are always concave). So when de-serializing a polygon I do not want to go through the factory to decide the type of polygon to create.
Wouldn't make sense to add the possibility to create a type of polygon directly? you cannot create the polygons directly as they are protected in the package. My suggestion request would be either to add methods in the polygon factory to create a type of polygons with no checking (e.g. makeConcavePolygon(…)) or change the visibility of the classes so that they can be instantiated directly.
I hope it makes sense.
Cheers,
Ignacio
Re: Request to change visibility of classes in geo3d
Posted by Michael McCandless <lu...@mikemccandless.com>.
I think that makes sense; can you open a Jira issue? Thanks.
Mike McCandless
http://blog.mikemccandless.com
On Fri, May 26, 2017 at 4:46 AM, Ignacio Vera Sequeiros <iv...@eso.org>
wrote:
> Hi,
>
>
>
> I am creating my own spatial context by wrapping the objects in lucene
> geo3d library and implement my own query which mixes the recursive and the
> serialized strategy to add precision to searches.
>
>
>
> I had the following issue specially with polygons: The factory for
> creating polygons is slow and when serializing shapes, I already know if I
> am dealing with convex or concave polygons (in my case they are always
> concave). So when de-serializing a polygon I do not want to go through the
> factory to decide the type of polygon to create.
>
>
>
> Wouldn't make sense to add the possibility to create a type of polygon
> directly? you cannot create the polygons directly as they are protected in
> the package. My suggestion request would be either to add methods in the
> polygon factory to create a type of polygons with no checking (e.g.
> makeConcavePolygon(…)) or change the visibility of the classes so that they
> can be instantiated directly.
>
>
>
> I hope it makes sense.
>
>
>
> Cheers,
>
>
>
> Ignacio
>
>
>