If I understand your case, it sounds like in the ideal world you could
make the "hidden" Geometry class implement the JTS Geometry interface.
However... it's not an ideal world, and JTS doesn't support a Geometry
interface (although I recognize that this would be a nice thing to have).
On the other hand, often you can't change the definition of a
pre-existing Geometry class - so this approach would be a non-starter
anyway.
As David points out, the next best thing is to construct a new JTS
Geometry around CoordinateSequences which map directly onto the
_Geometry. You can then "interact" with the JTS Geometry "wrapper"
object.
Do this help?
Rushforth, Peter wrote:
Hi,
I've got an object which is hiding some geometry information
(OK it's a NodeInfo object with a realized gml:_Geometry in it).
I want to interact with that NodeInfo object via the JTS Geometry
API.
How should I approach this? Is there some standard programming pattern
that I should use, or is there a standard programming method that
JTS developers would use in this regard?
Any advice appreciated (except for "hire a real programmer"-type stuff
;-)).
Cheers and thanks!
Peter
_______________________________________________
jts-devel mailing list
[email protected]
http://lists.refractions.net/mailman/listinfo/jts-devel
--
Martin Davis
Senior Technical Architect
Refractions Research, Inc.
(250) 383-3022
_______________________________________________
jts-devel mailing list
[email protected]
http://lists.refractions.net/mailman/listinfo/jts-devel