You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by Nino Saturnino Martinez Vazquez Wael <ni...@jayway.dk> on 2008/11/12 20:45:00 UTC
gmap2 and helper classes / methods?
Hi
I seem to be lacking some helper methods for finding out if a glatlng
are in a gbounds etc.. Are there someone out there who has implemented
anything or do I need to roll my own, and if the latter I guess I should
provide a patch?
--
-Wicket for love
Nino Martinez Wael
Java Specialist @ Jayway DK
http://www.jayway.dk
+45 2936 7684
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org
Re: gmap2 and helper classes / methods?
Posted by Antony Stubbs <an...@gmail.com>.
patched - http://wicketstuff.org/jira/browse/WSGMAPP-7
Nino.Martinez wrote:
>
> Hmmm, I got so far:
>
> public boolean isWithInBounds(GLatLngBounds bounds, GLatLng point) {
>
> // if (pointlat < maxY && pointlat > minY && pointlng > minX &&
> pointlng < maxX) { //execute script }
>
>
> if (bounds.getSW().getLat() < point.getLat()
> && bounds.getSW().getLng() < point.getLng()
> && bounds.getNE().getLat() > point.getLat()
> && bounds.getNE().getLng() > point.getLng()) {
> return true;
> }
>
> return false;
> }
>
> But im pretty sure that it's faulty. When I discovered spartial
> hibernate, which can be used with JPA. And in my case it's just what I
> need. And JTS( http://www.vividsolutions.com/jts/main.htm ) that
> provides more than enough for me... So if anything should be done it
> should be either direct integration between JTS and gmap or helper
> classes that will translate from gmap to JTS... I will think on if this
> could be something that the openlayers integration should support..
>
> Martin Funk wrote:
>> 2008/11/12 Nino Saturnino Martinez Vazquez Wael <ni...@jayway.dk>
>>
>>
>>> Hi
>>>
>>> I seem to be lacking some helper methods for finding out if a glatlng
>>> are
>>> in a gbounds etc.. Are there someone out there who has implemented
>>> anything
>>> or do I need to roll my own, and if the latter I guess I should provide
>>> a
>>> patch?
>>>
>>
>> go ahead and commit something,
>> I'll be happy to unclutter.
>>
>> mf
>>
>>
>>> --
>>> -Wicket for love
>>>
>>> Nino Martinez Wael
>>> Java Specialist @ Jayway DK
>>> http://www.jayway.dk
>>> +45 2936 7684
>>>
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
>>> For additional commands, e-mail: users-help@wicket.apache.org
>>>
>>>
>>>
>>
>>
>
> --
> -Wicket for love
>
> Nino Martinez Wael
> Java Specialist @ Jayway DK
> http://www.jayway.dk
> +45 2936 7684
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>
>
>
-----
___________________________
http://stubbisms.wordpress.com http://stubbisms.wordpress.com
--
View this message in context: http://www.nabble.com/gmap2-and-helper-classes---methods--tp20468014p22259981.html
Sent from the Wicket - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org
Re: gmap2 and helper classes / methods?
Posted by Nino Saturnino Martinez Vazquez Wael <ni...@jayway.dk>.
Hmmm, I got so far:
public boolean isWithInBounds(GLatLngBounds bounds, GLatLng point) {
// if (pointlat < maxY && pointlat > minY && pointlng > minX &&
pointlng < maxX) { //execute script }
if (bounds.getSW().getLat() < point.getLat()
&& bounds.getSW().getLng() < point.getLng()
&& bounds.getNE().getLat() > point.getLat()
&& bounds.getNE().getLng() > point.getLng()) {
return true;
}
return false;
}
But im pretty sure that it's faulty. When I discovered spartial
hibernate, which can be used with JPA. And in my case it's just what I
need. And JTS( http://www.vividsolutions.com/jts/main.htm ) that
provides more than enough for me... So if anything should be done it
should be either direct integration between JTS and gmap or helper
classes that will translate from gmap to JTS... I will think on if this
could be something that the openlayers integration should support..
Martin Funk wrote:
> 2008/11/12 Nino Saturnino Martinez Vazquez Wael <ni...@jayway.dk>
>
>
>> Hi
>>
>> I seem to be lacking some helper methods for finding out if a glatlng are
>> in a gbounds etc.. Are there someone out there who has implemented anything
>> or do I need to roll my own, and if the latter I guess I should provide a
>> patch?
>>
>
> go ahead and commit something,
> I'll be happy to unclutter.
>
> mf
>
>
>> --
>> -Wicket for love
>>
>> Nino Martinez Wael
>> Java Specialist @ Jayway DK
>> http://www.jayway.dk
>> +45 2936 7684
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
>> For additional commands, e-mail: users-help@wicket.apache.org
>>
>>
>>
>
>
--
-Wicket for love
Nino Martinez Wael
Java Specialist @ Jayway DK
http://www.jayway.dk
+45 2936 7684
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org
Re: gmap2 and helper classes / methods?
Posted by Martin Funk <ma...@googlemail.com>.
2008/11/12 Nino Saturnino Martinez Vazquez Wael <ni...@jayway.dk>
> Hi
>
> I seem to be lacking some helper methods for finding out if a glatlng are
> in a gbounds etc.. Are there someone out there who has implemented anything
> or do I need to roll my own, and if the latter I guess I should provide a
> patch?
go ahead and commit something,
I'll be happy to unclutter.
mf
>
>
> --
> -Wicket for love
>
> Nino Martinez Wael
> Java Specialist @ Jayway DK
> http://www.jayway.dk
> +45 2936 7684
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>
>
Re: gmap2 and helper classes / methods?
Posted by Jeremy Thomerson <je...@wickettraining.com>.
I haven't, but if you find it, I could definitely use it, too. I just
haven't had time to move on it. So be sure to submit a patch!
Thanks Nino!
--
Jeremy Thomerson
http://www.wickettraining.com
On Wed, Nov 12, 2008 at 1:45 PM, Nino Saturnino Martinez Vazquez Wael <
nino.martinez@jayway.dk> wrote:
> Hi
>
> I seem to be lacking some helper methods for finding out if a glatlng are
> in a gbounds etc.. Are there someone out there who has implemented anything
> or do I need to roll my own, and if the latter I guess I should provide a
> patch?
>
> --
> -Wicket for love
>
> Nino Martinez Wael
> Java Specialist @ Jayway DK
> http://www.jayway.dk
> +45 2936 7684
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>
>