It's following the same pattern as the rest of the Geometry classes. The
reason for using a CoordinateSequence is to allow the client to supply
alternate representations for the coordinate storage (e.g. by backing the
CS with some other external structure, such as some other geometry API, or
perhaps a blob of compressed storage of some kind).
Agreed that this make Point quite heavy, however. This is an issue of Java
vs say C++ (in which language implementation details like this can be
"compiled away").
A goal of the next rev of the JTS API is to make the Geometry types
interfaces. That should allow much lightweight implementations.
On Tue, Nov 5, 2013 at 8:55 AM, Smiley, David W. <[email protected]> wrote:
> The Point class seems unnecessarily heavyweight. It holds a reference to
> a CoordinateSequence which in turn has the Coordinate. Why doesn't Point
> simply wrap Coordinate directly?
>
> ~ David
>
>
> ------------------------------------------------------------------------------
> November Webinars for C, C++, Fortran Developers
> Accelerate application performance with scalable programming models.
> Explore
> techniques for threading, error checking, porting, and tuning. Get the most
> from the latest Intel processors and coprocessors. See abstracts and
> register
> http://pubads.g.doubleclick.net/gampad/clk?id=60136231&iu=/4140/ostg.clktrk
> _______________________________________________
> Jts-topo-suite-user mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/jts-topo-suite-user
>
>
------------------------------------------------------------------------------
November Webinars for C, C++, Fortran Developers
Accelerate application performance with scalable programming models. Explore
techniques for threading, error checking, porting, and tuning. Get the most
from the latest Intel processors and coprocessors. See abstracts and register
http://pubads.g.doubleclick.net/gampad/clk?id=60136231&iu=/4140/ostg.clktrk
_______________________________________________
Jts-topo-suite-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jts-topo-suite-user