import 'package:equatable/equatable.dart'; /// Encapsulates framerate. class Framerate extends Comparable with EquatableMixin { /// Framerate as frames per second final num framesPerSecond; /// Initialize an instance of [Framerate] Framerate(this.framesPerSecond); /// bool operator >(Framerate other) => framesPerSecond > other.framesPerSecond; /// bool operator <(Framerate other) => framesPerSecond < other.framesPerSecond; @override String toString() => '$framesPerSecond FPS'; @override List get props => [framesPerSecond]; @override int compareTo(Framerate other) => framesPerSecond.compareTo(other.framesPerSecond); }