Spatial Information Systems
  1. Spatial Information Systems
  2. SIS-39

Capacity is not used and memory waste in QuadTreeNode

    Details

    • Type: Bug Bug
    • Status: In Progress
    • Priority: Major Major
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: 0.5
    • Component/s: Storage
    • Labels:
      None

      Description

      Either 'capacity' should be properly used. Or null checks are necessary in all places where the raw 'data' array is used. Also what happens if the data array is full? addData should at least throw an exception then:

        public void addData(QuadTreeData data) {
          if (this.dataCount < this.capacity) {
            this.data[dataCount] = data;
            this.dataCount++;
          }
        }
      

        Activity

          People

          • Assignee:
            Chris A. Mattmann
            Reporter:
            Peter Karich
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:

              Development