swap abstract method

void swap(
  1. int a,
  2. int b
)

Swaps the positions of two view model instances in the list at indices a and b.

Example:

final list = viewModelInstance.list("list");
list.swap(2, 3);

Throws a RangeError if the a or b is out of bounds.

Implementation

void swap(int a, int b);