Acknowledged

API docs state that Arrays are fixed size, but they aren't

Both the Connect IQ Reference Manual and the api-docs (CIQ 7.4.3) state that "Array objects are fixed size...", but this isn't true. Arrays have methods that allow you to change their size.

  • > From my understanding it is by creating a new array of a different size then copying the items inside the array. Which makes them expensive operations.

    I'm not so sure. If you have an array A of 1000 elements and do

    A.add("another element");

    it would be much more efficient to do this without making a new copy.

  • From my understanding it is by creating a new array of a different size then copying the items inside the array. Which makes them expensive operations.