duration property

int get duration

Transition to the scene within the time frame given by duration.

Throws NegativeValueException if duration is less than 0.

Implementation

int get duration => _duration;
set duration (int duration)

Implementation

set duration(int duration) {
  if (duration >= 0) {
    _duration = duration;
  } else {
    throw NegativeValueException.withValue(duration);
  }
}