PandoraApiResponse class

Implementers
Annotations

Constructors

PandoraApiResponse.fail({@JsonKey(name: 'code', fromJson: PandoraApiErrorCode.fromCode) required PandoraApiErrorCode code, @JsonKey(name: 'message') required String message})
const
factory
PandoraApiResponse.fromJson(Map<String, dynamic> json)
factory
PandoraApiResponse.ok({@JsonKey(name: 'result') Object? result})
const
factory

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

map<TResult extends Object?>({required TResult ok(SuccessfulPandoraApiResponse value), required TResult fail(PandoraApiException value)}) → TResult
inherited
mapOrNull<TResult extends Object?>({TResult? ok(SuccessfulPandoraApiResponse value)?, TResult? fail(PandoraApiException value)?}) → TResult?
inherited
maybeMap<TResult extends Object?>({TResult ok(SuccessfulPandoraApiResponse value)?, TResult fail(PandoraApiException value)?, required TResult orElse()}) → TResult
inherited
maybeWhen<TResult extends Object?>({TResult ok(Object? result)?, TResult fail(PandoraApiErrorCode code, String message)?, required TResult orElse()}) → TResult
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJson() Map<String, dynamic>
Serializes this PandoraApiResponse to a JSON map.
inherited
toString() String
A string representation of this object.
inherited
when<TResult extends Object?>({required TResult ok(Object? result), required TResult fail(PandoraApiErrorCode code, String message)}) → TResult
inherited
whenOrNull<TResult extends Object?>({TResult? ok(Object? result)?, TResult? fail(PandoraApiErrorCode code, String message)?}) → TResult?
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited