sourceAt method

int sourceAt(
  1. int index
)

Implementation

int sourceAt(int index) {
  if (sourceIndices.isEmpty) return 0;
  final int safe = index < 0 ? 0 : (index >= sourceIndices.length ? sourceIndices.length - 1 : index);
  return sourceIndices[safe];
}