Line data Source code
1 : /// An exception thrown when trying to convert a unknown permission into 2 : /// the LocationPermission enum. 3 : class InvalidPermissionException implements Exception { 4 : /// Constructs the [InvalidPermissionException] 5 2 : const InvalidPermissionException(this.valueToConvert); 6 : 7 : /// The [valueToConvert] contains the value that was tried to be converted 8 : /// into a LocationPermission. 9 : final int valueToConvert; 10 : 11 1 : @override 12 : String toString() { 13 : // ignore: lines_longer_than_80_chars 14 2 : return 'Unable to convert the value "$valueToConvert" into a LocationPermission.'; 15 : } 16 : }