Hi Peter,
On Mar 30, 2012, at 12:43 AM, Peter K wrote:
>
>> I agree that the capacity is not needed and data.length is sufficient to
>> represent the capacity of the node. If the node is full, based on the quad
>> tree insertion algorithm, the node should be split and data should be
>> redistributed accordingly.
>>
>> Best,
>> Nga
>
> But then one needs to be carefull with null values and exporting the raw
> array might not be wise, no?
Agreed, this would be a useful improvement. Again, if you would file a JIRA
issue, I'd certainly appreciate it, or I can do it or someone else can if you
don't
get around to it.
> Because the 'dataCount' limit is not always correctly used, e.g. in
> QuadTree in method 'isSimilarQuad' there the array length is used instead.
+1.
>
> Also in L. 171 might be a bug regarding that 'capacity' thing:
> if (u.getCount() < this.capacity) {
> u.addData(data);
Some, would be great for another patch here :)
Cheers,
Chris
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Chris Mattmann, Ph.D.
Senior Computer Scientist
NASA Jet Propulsion Laboratory Pasadena, CA 91109 USA
Office: 171-266B, Mailstop: 171-246
Email: [email protected]
WWW: http://sunset.usc.edu/~mattmann/
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Adjunct Assistant Professor, Computer Science Department
University of Southern California, Los Angeles, CA 90089 USA
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++