[geos-devel]createEmptyGeometry()

Mateusz Łoskot mateusz at loskot.net
Sat Apr 1 22:01:08 EST 2006


strk at refractions.net wrote:
> On Fri, Mar 31, 2006 at 12:35:12PM +0200, strk at refractions.net wrote:
>
>> Note that the same happens with JTS. Example:
>>
>>   public Coordinate[] getCoordinates() {
>>     return points.toCoordinateArray();
>>  }
>>
>> 'points' is not checked for being NULL.
>> In other places it is.
> 
> ...
> 
> Sorry, I had a closer look, at it seems that
> LineString refuses to be contructed with a NULL
> CoordinateSequence. It creates an *empty*
> CoordinateSequence when passed NULL as arg.
> 
> Yet another useless waste of memory, similar
> to the NULL Envelope and NULL Coordinate representations...

Hmm, what is the plan to fix/handle those cases?

Cheers
-- 
Mateusz Łoskot
http://mateusz.loskot.net



More information about the geos-devel mailing list