Skip to content

Commit

Permalink
Add doc comment for GalException
Browse files Browse the repository at this point in the history
  • Loading branch information
natsuk4ze committed Dec 19, 2023
1 parent 16ebc2b commit 05c07a9
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion lib/src/gal_exception.dart
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,16 @@ class GalException implements Exception {
String toString() => "[GalException/${type.code}]: ${type.message}";
}

/// Types of [GalException]
///
/// Except for [accessDenied] is best effort and is not always
/// classified and may return [unexpected].
/// In that case, you can get support by submitting
/// an [issue](https://github.com/natsuk4ze/gal/issues)
/// including all values of [GalException.platformException]
/// and [GalException.stackTrace].
enum GalExceptionType {

/// When has no permission to access gallery app.
/// See: https://github.com/natsuk4ze/gal/wiki/Permissions
accessDenied,
Expand All @@ -43,7 +52,7 @@ enum GalExceptionType {
/// See: https://github.com/natsuk4ze/gal/wiki/Formats
notSupportedFormat,

/// When an error occurs with unexpected.
/// When an error occurs with unexpected (could not classified).
unexpected;

String get code => switch (this) {
Expand Down

0 comments on commit 05c07a9

Please sign in to comment.