copyIntoArray method

  1. @override
List<double> copyIntoArray([
  1. List<double>? array,
  2. int offset = 0
])
override

Implementation

@override
List<double> copyIntoArray([List<double>? array, int offset = 0]) {
  if (array == null) {
    array = List<double>.filled(offset + 3, 0);
  } else {
    while (array.length < offset + 3) {
      array.add(0.0);
    }
  }

  array[offset] = x;
  array[offset + 1] = y;
  array[offset + 2] = z;

  return array;
}