2021-07-24 14:05:49 +08:00
// GENERATED CODE - DO NOT MODIFY BY HAND
2021-07-28 13:41:39 +08:00
// ignore_for_file: unused_element, deprecated_member_use, deprecated_member_use_from_same_package, use_function_type_syntax_for_parameters, unnecessary_const, avoid_init_to_null, invalid_override_different_default_values_named, prefer_expression_function_bodies, annotate_overrides, invalid_annotation_target
2021-07-24 14:05:49 +08:00
part of ' view_bloc.dart ' ;
// **************************************************************************
// FreezedGenerator
// **************************************************************************
T _ $identity < T > ( T value ) = > value ;
final _privateConstructorUsedError = UnsupportedError (
' It seems like you constructed your class using `MyClass._()`. This constructor is only meant to be used by freezed and you are not supposed to need it nor use it. \n Please check the documentation here for more informations: https://github.com/rrousselGit/freezed#custom-getters-and-methods ' ) ;
/// @nodoc
class _ $ViewEventTearOff {
const _ $ViewEventTearOff ( ) ;
2021-10-12 14:55:54 +08:00
Initial initial ( ) {
return const Initial ( ) ;
2021-10-12 13:07:41 +08:00
}
SetEditing setIsEditing ( bool isEditing ) {
return SetEditing (
isEditing ,
) ;
}
2021-10-12 14:55:54 +08:00
Rename rename ( String newName ) {
return Rename (
newName ,
) ;
}
Delete delete ( ) {
return const Delete ( ) ;
}
2021-10-20 22:19:01 +08:00
Duplicate duplicate ( ) {
return const Duplicate ( ) ;
}
2021-10-12 14:55:54 +08:00
ViewDidUpdate viewDidUpdate ( Either < View , WorkspaceError > result ) {
return ViewDidUpdate (
result ,
2021-10-12 13:07:41 +08:00
) ;
2021-07-24 14:05:49 +08:00
}
}
/// @nodoc
const $ViewEvent = _ $ViewEventTearOff ( ) ;
/// @nodoc
mixin _ $ViewEvent {
@ optionalTypeArgs
TResult when < TResult extends Object ? > ( {
2021-10-12 14:55:54 +08:00
required TResult Function ( ) initial ,
2021-10-12 13:07:41 +08:00
required TResult Function ( bool isEditing ) setIsEditing ,
2021-10-12 14:55:54 +08:00
required TResult Function ( String newName ) rename ,
required TResult Function ( ) delete ,
2021-10-20 22:19:01 +08:00
required TResult Function ( ) duplicate ,
2021-10-12 14:55:54 +08:00
required TResult Function ( Either < View , WorkspaceError > result )
viewDidUpdate ,
2021-07-24 14:05:49 +08:00
} ) = >
throw _privateConstructorUsedError ;
@ optionalTypeArgs
TResult maybeWhen < TResult extends Object ? > ( {
2021-10-12 14:55:54 +08:00
TResult Function ( ) ? initial ,
2021-10-12 13:07:41 +08:00
TResult Function ( bool isEditing ) ? setIsEditing ,
2021-10-12 14:55:54 +08:00
TResult Function ( String newName ) ? rename ,
TResult Function ( ) ? delete ,
2021-10-20 22:19:01 +08:00
TResult Function ( ) ? duplicate ,
2021-10-12 14:55:54 +08:00
TResult Function ( Either < View , WorkspaceError > result ) ? viewDidUpdate ,
2021-07-24 14:05:49 +08:00
required TResult orElse ( ) ,
} ) = >
throw _privateConstructorUsedError ;
@ optionalTypeArgs
TResult map < TResult extends Object ? > ( {
2021-10-12 14:55:54 +08:00
required TResult Function ( Initial value ) initial ,
2021-10-12 13:07:41 +08:00
required TResult Function ( SetEditing value ) setIsEditing ,
2021-10-12 14:55:54 +08:00
required TResult Function ( Rename value ) rename ,
required TResult Function ( Delete value ) delete ,
2021-10-20 22:19:01 +08:00
required TResult Function ( Duplicate value ) duplicate ,
2021-10-12 14:55:54 +08:00
required TResult Function ( ViewDidUpdate value ) viewDidUpdate ,
2021-07-24 14:05:49 +08:00
} ) = >
throw _privateConstructorUsedError ;
@ optionalTypeArgs
TResult maybeMap < TResult extends Object ? > ( {
2021-10-12 14:55:54 +08:00
TResult Function ( Initial value ) ? initial ,
2021-10-12 13:07:41 +08:00
TResult Function ( SetEditing value ) ? setIsEditing ,
2021-10-12 14:55:54 +08:00
TResult Function ( Rename value ) ? rename ,
TResult Function ( Delete value ) ? delete ,
2021-10-20 22:19:01 +08:00
TResult Function ( Duplicate value ) ? duplicate ,
2021-10-12 14:55:54 +08:00
TResult Function ( ViewDidUpdate value ) ? viewDidUpdate ,
2021-07-24 14:05:49 +08:00
required TResult orElse ( ) ,
} ) = >
throw _privateConstructorUsedError ;
}
/// @nodoc
abstract class $ViewEventCopyWith < $Res > {
factory $ViewEventCopyWith ( ViewEvent value , $Res Function ( ViewEvent ) then ) =
_ $ViewEventCopyWithImpl < $Res > ;
}
/// @nodoc
class _ $ViewEventCopyWithImpl < $Res > implements $ViewEventCopyWith < $Res > {
_ $ViewEventCopyWithImpl ( this . _value , this . _then ) ;
final ViewEvent _value ;
// ignore: unused_field
final $Res Function ( ViewEvent ) _then ;
}
/// @nodoc
2021-10-12 14:55:54 +08:00
abstract class $InitialCopyWith < $Res > {
factory $InitialCopyWith ( Initial value , $Res Function ( Initial ) then ) =
_ $InitialCopyWithImpl < $Res > ;
2021-10-12 13:07:41 +08:00
}
/// @nodoc
2021-10-12 14:55:54 +08:00
class _ $InitialCopyWithImpl < $Res > extends _ $ViewEventCopyWithImpl < $Res >
implements $InitialCopyWith < $Res > {
_ $InitialCopyWithImpl ( Initial _value , $Res Function ( Initial ) _then )
: super ( _value , ( v ) = > _then ( v as Initial ) ) ;
2021-10-12 13:07:41 +08:00
@ override
2021-10-12 14:55:54 +08:00
Initial get _value = > super . _value as Initial ;
2021-10-12 13:07:41 +08:00
}
/// @nodoc
2021-10-12 14:55:54 +08:00
class _ $Initial implements Initial {
const _ $Initial ( ) ;
2021-10-12 13:07:41 +08:00
@ override
String toString ( ) {
2021-10-12 14:55:54 +08:00
return ' ViewEvent.initial() ' ;
2021-10-12 13:07:41 +08:00
}
@ override
bool operator = = ( dynamic other ) {
2021-10-12 14:55:54 +08:00
return identical ( this , other ) | | ( other is Initial ) ;
2021-10-12 13:07:41 +08:00
}
@ override
2021-10-12 14:55:54 +08:00
int get hashCode = > runtimeType . hashCode ;
2021-10-12 13:07:41 +08:00
@ override
@ optionalTypeArgs
TResult when < TResult extends Object ? > ( {
2021-10-12 14:55:54 +08:00
required TResult Function ( ) initial ,
2021-10-12 13:07:41 +08:00
required TResult Function ( bool isEditing ) setIsEditing ,
2021-10-12 14:55:54 +08:00
required TResult Function ( String newName ) rename ,
required TResult Function ( ) delete ,
2021-10-20 22:19:01 +08:00
required TResult Function ( ) duplicate ,
2021-10-12 14:55:54 +08:00
required TResult Function ( Either < View , WorkspaceError > result )
viewDidUpdate ,
2021-10-12 13:07:41 +08:00
} ) {
2021-10-12 14:55:54 +08:00
return initial ( ) ;
2021-10-12 13:07:41 +08:00
}
@ override
@ optionalTypeArgs
TResult maybeWhen < TResult extends Object ? > ( {
2021-10-12 14:55:54 +08:00
TResult Function ( ) ? initial ,
2021-10-12 13:07:41 +08:00
TResult Function ( bool isEditing ) ? setIsEditing ,
2021-10-12 14:55:54 +08:00
TResult Function ( String newName ) ? rename ,
TResult Function ( ) ? delete ,
2021-10-20 22:19:01 +08:00
TResult Function ( ) ? duplicate ,
2021-10-12 14:55:54 +08:00
TResult Function ( Either < View , WorkspaceError > result ) ? viewDidUpdate ,
2021-10-12 13:07:41 +08:00
required TResult orElse ( ) ,
} ) {
2021-10-12 14:55:54 +08:00
if ( initial ! = null ) {
return initial ( ) ;
2021-10-12 13:07:41 +08:00
}
return orElse ( ) ;
}
@ override
@ optionalTypeArgs
TResult map < TResult extends Object ? > ( {
2021-10-12 14:55:54 +08:00
required TResult Function ( Initial value ) initial ,
2021-10-12 13:07:41 +08:00
required TResult Function ( SetEditing value ) setIsEditing ,
2021-10-12 14:55:54 +08:00
required TResult Function ( Rename value ) rename ,
required TResult Function ( Delete value ) delete ,
2021-10-20 22:19:01 +08:00
required TResult Function ( Duplicate value ) duplicate ,
2021-10-12 14:55:54 +08:00
required TResult Function ( ViewDidUpdate value ) viewDidUpdate ,
2021-10-12 13:07:41 +08:00
} ) {
2021-10-12 14:55:54 +08:00
return initial ( this ) ;
2021-10-12 13:07:41 +08:00
}
@ override
@ optionalTypeArgs
TResult maybeMap < TResult extends Object ? > ( {
2021-10-12 14:55:54 +08:00
TResult Function ( Initial value ) ? initial ,
2021-10-12 13:07:41 +08:00
TResult Function ( SetEditing value ) ? setIsEditing ,
2021-10-12 14:55:54 +08:00
TResult Function ( Rename value ) ? rename ,
TResult Function ( Delete value ) ? delete ,
2021-10-20 22:19:01 +08:00
TResult Function ( Duplicate value ) ? duplicate ,
2021-10-12 14:55:54 +08:00
TResult Function ( ViewDidUpdate value ) ? viewDidUpdate ,
2021-10-12 13:07:41 +08:00
required TResult orElse ( ) ,
} ) {
2021-10-12 14:55:54 +08:00
if ( initial ! = null ) {
return initial ( this ) ;
2021-10-12 13:07:41 +08:00
}
return orElse ( ) ;
}
}
2021-10-12 14:55:54 +08:00
abstract class Initial implements ViewEvent {
const factory Initial ( ) = _ $Initial ;
2021-10-12 13:07:41 +08:00
}
/// @nodoc
abstract class $SetEditingCopyWith < $Res > {
factory $SetEditingCopyWith (
SetEditing value , $Res Function ( SetEditing ) then ) =
_ $SetEditingCopyWithImpl < $Res > ;
$Res call ( { bool isEditing } ) ;
}
/// @nodoc
class _ $SetEditingCopyWithImpl < $Res > extends _ $ViewEventCopyWithImpl < $Res >
implements $SetEditingCopyWith < $Res > {
_ $SetEditingCopyWithImpl ( SetEditing _value , $Res Function ( SetEditing ) _then )
: super ( _value , ( v ) = > _then ( v as SetEditing ) ) ;
@ override
SetEditing get _value = > super . _value as SetEditing ;
@ override
$Res call ( {
Object ? isEditing = freezed ,
} ) {
return _then ( SetEditing (
isEditing = = freezed
? _value . isEditing
: isEditing // ignore: cast_nullable_to_non_nullable
as bool ,
) ) ;
}
}
/// @nodoc
class _ $SetEditing implements SetEditing {
const _ $SetEditing ( this . isEditing ) ;
@ override
final bool isEditing ;
@ override
String toString ( ) {
return ' ViewEvent.setIsEditing(isEditing: $ isEditing ) ' ;
}
@ override
bool operator = = ( dynamic other ) {
return identical ( this , other ) | |
( other is SetEditing & &
( identical ( other . isEditing , isEditing ) | |
const DeepCollectionEquality ( )
. equals ( other . isEditing , isEditing ) ) ) ;
}
@ override
int get hashCode = >
runtimeType . hashCode ^ const DeepCollectionEquality ( ) . hash ( isEditing ) ;
@ JsonKey ( ignore: true )
@ override
$SetEditingCopyWith < SetEditing > get copyWith = >
_ $SetEditingCopyWithImpl < SetEditing > ( this , _ $identity ) ;
@ override
@ optionalTypeArgs
TResult when < TResult extends Object ? > ( {
2021-10-12 14:55:54 +08:00
required TResult Function ( ) initial ,
2021-10-12 13:07:41 +08:00
required TResult Function ( bool isEditing ) setIsEditing ,
2021-10-12 14:55:54 +08:00
required TResult Function ( String newName ) rename ,
required TResult Function ( ) delete ,
2021-10-20 22:19:01 +08:00
required TResult Function ( ) duplicate ,
2021-10-12 14:55:54 +08:00
required TResult Function ( Either < View , WorkspaceError > result )
viewDidUpdate ,
2021-10-12 13:07:41 +08:00
} ) {
return setIsEditing ( isEditing ) ;
}
@ override
@ optionalTypeArgs
TResult maybeWhen < TResult extends Object ? > ( {
2021-10-12 14:55:54 +08:00
TResult Function ( ) ? initial ,
2021-10-12 13:07:41 +08:00
TResult Function ( bool isEditing ) ? setIsEditing ,
2021-10-12 14:55:54 +08:00
TResult Function ( String newName ) ? rename ,
TResult Function ( ) ? delete ,
2021-10-20 22:19:01 +08:00
TResult Function ( ) ? duplicate ,
2021-10-12 14:55:54 +08:00
TResult Function ( Either < View , WorkspaceError > result ) ? viewDidUpdate ,
2021-10-12 13:07:41 +08:00
required TResult orElse ( ) ,
} ) {
if ( setIsEditing ! = null ) {
return setIsEditing ( isEditing ) ;
}
return orElse ( ) ;
}
@ override
@ optionalTypeArgs
TResult map < TResult extends Object ? > ( {
2021-10-12 14:55:54 +08:00
required TResult Function ( Initial value ) initial ,
2021-10-12 13:07:41 +08:00
required TResult Function ( SetEditing value ) setIsEditing ,
2021-10-12 14:55:54 +08:00
required TResult Function ( Rename value ) rename ,
required TResult Function ( Delete value ) delete ,
2021-10-20 22:19:01 +08:00
required TResult Function ( Duplicate value ) duplicate ,
2021-10-12 14:55:54 +08:00
required TResult Function ( ViewDidUpdate value ) viewDidUpdate ,
2021-10-12 13:07:41 +08:00
} ) {
return setIsEditing ( this ) ;
}
@ override
@ optionalTypeArgs
TResult maybeMap < TResult extends Object ? > ( {
2021-10-12 14:55:54 +08:00
TResult Function ( Initial value ) ? initial ,
2021-10-12 13:07:41 +08:00
TResult Function ( SetEditing value ) ? setIsEditing ,
2021-10-12 14:55:54 +08:00
TResult Function ( Rename value ) ? rename ,
TResult Function ( Delete value ) ? delete ,
2021-10-20 22:19:01 +08:00
TResult Function ( Duplicate value ) ? duplicate ,
2021-10-12 14:55:54 +08:00
TResult Function ( ViewDidUpdate value ) ? viewDidUpdate ,
2021-10-12 13:07:41 +08:00
required TResult orElse ( ) ,
} ) {
if ( setIsEditing ! = null ) {
return setIsEditing ( this ) ;
}
return orElse ( ) ;
}
}
abstract class SetEditing implements ViewEvent {
const factory SetEditing ( bool isEditing ) = _ $SetEditing ;
bool get isEditing = > throw _privateConstructorUsedError ;
@ JsonKey ( ignore: true )
$SetEditingCopyWith < SetEditing > get copyWith = >
throw _privateConstructorUsedError ;
}
/// @nodoc
2021-10-12 14:55:54 +08:00
abstract class $RenameCopyWith < $Res > {
factory $RenameCopyWith ( Rename value , $Res Function ( Rename ) then ) =
_ $RenameCopyWithImpl < $Res > ;
$Res call ( { String newName } ) ;
}
/// @nodoc
class _ $RenameCopyWithImpl < $Res > extends _ $ViewEventCopyWithImpl < $Res >
implements $RenameCopyWith < $Res > {
_ $RenameCopyWithImpl ( Rename _value , $Res Function ( Rename ) _then )
: super ( _value , ( v ) = > _then ( v as Rename ) ) ;
@ override
Rename get _value = > super . _value as Rename ;
@ override
$Res call ( {
Object ? newName = freezed ,
} ) {
return _then ( Rename (
newName = = freezed
? _value . newName
: newName // ignore: cast_nullable_to_non_nullable
as String ,
) ) ;
}
}
/// @nodoc
class _ $Rename implements Rename {
const _ $Rename ( this . newName ) ;
@ override
final String newName ;
@ override
String toString ( ) {
return ' ViewEvent.rename(newName: $ newName ) ' ;
}
@ override
bool operator = = ( dynamic other ) {
return identical ( this , other ) | |
( other is Rename & &
( identical ( other . newName , newName ) | |
const DeepCollectionEquality ( ) . equals ( other . newName , newName ) ) ) ;
}
@ override
int get hashCode = >
runtimeType . hashCode ^ const DeepCollectionEquality ( ) . hash ( newName ) ;
@ JsonKey ( ignore: true )
@ override
$RenameCopyWith < Rename > get copyWith = >
_ $RenameCopyWithImpl < Rename > ( this , _ $identity ) ;
@ override
@ optionalTypeArgs
TResult when < TResult extends Object ? > ( {
required TResult Function ( ) initial ,
required TResult Function ( bool isEditing ) setIsEditing ,
required TResult Function ( String newName ) rename ,
required TResult Function ( ) delete ,
2021-10-20 22:19:01 +08:00
required TResult Function ( ) duplicate ,
2021-10-12 14:55:54 +08:00
required TResult Function ( Either < View , WorkspaceError > result )
viewDidUpdate ,
} ) {
return rename ( newName ) ;
}
@ override
@ optionalTypeArgs
TResult maybeWhen < TResult extends Object ? > ( {
TResult Function ( ) ? initial ,
TResult Function ( bool isEditing ) ? setIsEditing ,
TResult Function ( String newName ) ? rename ,
TResult Function ( ) ? delete ,
2021-10-20 22:19:01 +08:00
TResult Function ( ) ? duplicate ,
2021-10-12 14:55:54 +08:00
TResult Function ( Either < View , WorkspaceError > result ) ? viewDidUpdate ,
required TResult orElse ( ) ,
} ) {
if ( rename ! = null ) {
return rename ( newName ) ;
}
return orElse ( ) ;
}
@ override
@ optionalTypeArgs
TResult map < TResult extends Object ? > ( {
required TResult Function ( Initial value ) initial ,
required TResult Function ( SetEditing value ) setIsEditing ,
required TResult Function ( Rename value ) rename ,
required TResult Function ( Delete value ) delete ,
2021-10-20 22:19:01 +08:00
required TResult Function ( Duplicate value ) duplicate ,
2021-10-12 14:55:54 +08:00
required TResult Function ( ViewDidUpdate value ) viewDidUpdate ,
} ) {
return rename ( this ) ;
}
@ override
@ optionalTypeArgs
TResult maybeMap < TResult extends Object ? > ( {
TResult Function ( Initial value ) ? initial ,
TResult Function ( SetEditing value ) ? setIsEditing ,
TResult Function ( Rename value ) ? rename ,
TResult Function ( Delete value ) ? delete ,
2021-10-20 22:19:01 +08:00
TResult Function ( Duplicate value ) ? duplicate ,
2021-10-12 14:55:54 +08:00
TResult Function ( ViewDidUpdate value ) ? viewDidUpdate ,
required TResult orElse ( ) ,
} ) {
if ( rename ! = null ) {
return rename ( this ) ;
}
return orElse ( ) ;
}
}
abstract class Rename implements ViewEvent {
const factory Rename ( String newName ) = _ $Rename ;
String get newName = > throw _privateConstructorUsedError ;
@ JsonKey ( ignore: true )
$RenameCopyWith < Rename > get copyWith = > throw _privateConstructorUsedError ;
}
/// @nodoc
abstract class $DeleteCopyWith < $Res > {
factory $DeleteCopyWith ( Delete value , $Res Function ( Delete ) then ) =
_ $DeleteCopyWithImpl < $Res > ;
2021-07-24 14:05:49 +08:00
}
/// @nodoc
2021-10-12 14:55:54 +08:00
class _ $DeleteCopyWithImpl < $Res > extends _ $ViewEventCopyWithImpl < $Res >
implements $DeleteCopyWith < $Res > {
_ $DeleteCopyWithImpl ( Delete _value , $Res Function ( Delete ) _then )
: super ( _value , ( v ) = > _then ( v as Delete ) ) ;
2021-10-12 13:07:41 +08:00
@ override
2021-10-12 14:55:54 +08:00
Delete get _value = > super . _value as Delete ;
}
/// @nodoc
class _ $Delete implements Delete {
const _ $Delete ( ) ;
@ override
String toString ( ) {
return ' ViewEvent.delete() ' ;
}
@ override
bool operator = = ( dynamic other ) {
return identical ( this , other ) | | ( other is Delete ) ;
}
@ override
int get hashCode = > runtimeType . hashCode ;
@ override
@ optionalTypeArgs
TResult when < TResult extends Object ? > ( {
required TResult Function ( ) initial ,
required TResult Function ( bool isEditing ) setIsEditing ,
required TResult Function ( String newName ) rename ,
required TResult Function ( ) delete ,
2021-10-20 22:19:01 +08:00
required TResult Function ( ) duplicate ,
2021-10-12 14:55:54 +08:00
required TResult Function ( Either < View , WorkspaceError > result )
viewDidUpdate ,
} ) {
return delete ( ) ;
}
@ override
@ optionalTypeArgs
TResult maybeWhen < TResult extends Object ? > ( {
TResult Function ( ) ? initial ,
TResult Function ( bool isEditing ) ? setIsEditing ,
TResult Function ( String newName ) ? rename ,
TResult Function ( ) ? delete ,
2021-10-20 22:19:01 +08:00
TResult Function ( ) ? duplicate ,
2021-10-12 14:55:54 +08:00
TResult Function ( Either < View , WorkspaceError > result ) ? viewDidUpdate ,
required TResult orElse ( ) ,
} ) {
if ( delete ! = null ) {
return delete ( ) ;
}
return orElse ( ) ;
}
@ override
@ optionalTypeArgs
TResult map < TResult extends Object ? > ( {
required TResult Function ( Initial value ) initial ,
required TResult Function ( SetEditing value ) setIsEditing ,
required TResult Function ( Rename value ) rename ,
required TResult Function ( Delete value ) delete ,
2021-10-20 22:19:01 +08:00
required TResult Function ( Duplicate value ) duplicate ,
2021-10-12 14:55:54 +08:00
required TResult Function ( ViewDidUpdate value ) viewDidUpdate ,
} ) {
return delete ( this ) ;
}
@ override
@ optionalTypeArgs
TResult maybeMap < TResult extends Object ? > ( {
TResult Function ( Initial value ) ? initial ,
TResult Function ( SetEditing value ) ? setIsEditing ,
TResult Function ( Rename value ) ? rename ,
TResult Function ( Delete value ) ? delete ,
2021-10-20 22:19:01 +08:00
TResult Function ( Duplicate value ) ? duplicate ,
2021-10-12 14:55:54 +08:00
TResult Function ( ViewDidUpdate value ) ? viewDidUpdate ,
required TResult orElse ( ) ,
} ) {
if ( delete ! = null ) {
return delete ( this ) ;
}
return orElse ( ) ;
}
}
abstract class Delete implements ViewEvent {
const factory Delete ( ) = _ $Delete ;
}
2021-10-20 22:19:01 +08:00
/// @nodoc
abstract class $DuplicateCopyWith < $Res > {
factory $DuplicateCopyWith ( Duplicate value , $Res Function ( Duplicate ) then ) =
_ $DuplicateCopyWithImpl < $Res > ;
}
/// @nodoc
class _ $DuplicateCopyWithImpl < $Res > extends _ $ViewEventCopyWithImpl < $Res >
implements $DuplicateCopyWith < $Res > {
_ $DuplicateCopyWithImpl ( Duplicate _value , $Res Function ( Duplicate ) _then )
: super ( _value , ( v ) = > _then ( v as Duplicate ) ) ;
@ override
Duplicate get _value = > super . _value as Duplicate ;
}
/// @nodoc
class _ $Duplicate implements Duplicate {
const _ $Duplicate ( ) ;
@ override
String toString ( ) {
return ' ViewEvent.duplicate() ' ;
}
@ override
bool operator = = ( dynamic other ) {
return identical ( this , other ) | | ( other is Duplicate ) ;
}
@ override
int get hashCode = > runtimeType . hashCode ;
@ override
@ optionalTypeArgs
TResult when < TResult extends Object ? > ( {
required TResult Function ( ) initial ,
required TResult Function ( bool isEditing ) setIsEditing ,
required TResult Function ( String newName ) rename ,
required TResult Function ( ) delete ,
required TResult Function ( ) duplicate ,
required TResult Function ( Either < View , WorkspaceError > result )
viewDidUpdate ,
} ) {
return duplicate ( ) ;
}
@ override
@ optionalTypeArgs
TResult maybeWhen < TResult extends Object ? > ( {
TResult Function ( ) ? initial ,
TResult Function ( bool isEditing ) ? setIsEditing ,
TResult Function ( String newName ) ? rename ,
TResult Function ( ) ? delete ,
TResult Function ( ) ? duplicate ,
TResult Function ( Either < View , WorkspaceError > result ) ? viewDidUpdate ,
required TResult orElse ( ) ,
} ) {
if ( duplicate ! = null ) {
return duplicate ( ) ;
}
return orElse ( ) ;
}
@ override
@ optionalTypeArgs
TResult map < TResult extends Object ? > ( {
required TResult Function ( Initial value ) initial ,
required TResult Function ( SetEditing value ) setIsEditing ,
required TResult Function ( Rename value ) rename ,
required TResult Function ( Delete value ) delete ,
required TResult Function ( Duplicate value ) duplicate ,
required TResult Function ( ViewDidUpdate value ) viewDidUpdate ,
} ) {
return duplicate ( this ) ;
}
@ override
@ optionalTypeArgs
TResult maybeMap < TResult extends Object ? > ( {
TResult Function ( Initial value ) ? initial ,
TResult Function ( SetEditing value ) ? setIsEditing ,
TResult Function ( Rename value ) ? rename ,
TResult Function ( Delete value ) ? delete ,
TResult Function ( Duplicate value ) ? duplicate ,
TResult Function ( ViewDidUpdate value ) ? viewDidUpdate ,
required TResult orElse ( ) ,
} ) {
if ( duplicate ! = null ) {
return duplicate ( this ) ;
}
return orElse ( ) ;
}
}
abstract class Duplicate implements ViewEvent {
const factory Duplicate ( ) = _ $Duplicate ;
}
2021-10-12 14:55:54 +08:00
/// @nodoc
abstract class $ViewDidUpdateCopyWith < $Res > {
factory $ViewDidUpdateCopyWith (
ViewDidUpdate value , $Res Function ( ViewDidUpdate ) then ) =
_ $ViewDidUpdateCopyWithImpl < $Res > ;
$Res call ( { Either < View , WorkspaceError > result } ) ;
}
/// @nodoc
class _ $ViewDidUpdateCopyWithImpl < $Res > extends _ $ViewEventCopyWithImpl < $Res >
implements $ViewDidUpdateCopyWith < $Res > {
_ $ViewDidUpdateCopyWithImpl (
ViewDidUpdate _value , $Res Function ( ViewDidUpdate ) _then )
: super ( _value , ( v ) = > _then ( v as ViewDidUpdate ) ) ;
@ override
ViewDidUpdate get _value = > super . _value as ViewDidUpdate ;
2021-07-24 14:05:49 +08:00
@ override
2021-10-12 13:07:41 +08:00
$Res call ( {
2021-10-12 14:55:54 +08:00
Object ? result = freezed ,
2021-10-12 13:07:41 +08:00
} ) {
2021-10-12 14:55:54 +08:00
return _then ( ViewDidUpdate (
result = = freezed
? _value . result
: result // ignore: cast_nullable_to_non_nullable
as Either < View , WorkspaceError > ,
2021-10-12 13:07:41 +08:00
) ) ;
}
2021-07-24 14:05:49 +08:00
}
/// @nodoc
2021-10-12 14:55:54 +08:00
class _ $ViewDidUpdate implements ViewDidUpdate {
const _ $ViewDidUpdate ( this . result ) ;
2021-10-12 13:07:41 +08:00
@ override
2021-10-12 14:55:54 +08:00
final Either < View , WorkspaceError > result ;
2021-07-24 14:05:49 +08:00
@ override
String toString ( ) {
2021-10-12 14:55:54 +08:00
return ' ViewEvent.viewDidUpdate(result: $ result ) ' ;
2021-07-24 14:05:49 +08:00
}
@ override
bool operator = = ( dynamic other ) {
2021-10-12 13:07:41 +08:00
return identical ( this , other ) | |
2021-10-12 14:55:54 +08:00
( other is ViewDidUpdate & &
( identical ( other . result , result ) | |
const DeepCollectionEquality ( ) . equals ( other . result , result ) ) ) ;
2021-07-24 14:05:49 +08:00
}
@ override
2021-10-12 13:07:41 +08:00
int get hashCode = >
2021-10-12 14:55:54 +08:00
runtimeType . hashCode ^ const DeepCollectionEquality ( ) . hash ( result ) ;
2021-10-12 13:07:41 +08:00
@ JsonKey ( ignore: true )
@ override
2021-10-12 14:55:54 +08:00
$ViewDidUpdateCopyWith < ViewDidUpdate > get copyWith = >
_ $ViewDidUpdateCopyWithImpl < ViewDidUpdate > ( this , _ $identity ) ;
2021-07-24 14:05:49 +08:00
@ override
@ optionalTypeArgs
TResult when < TResult extends Object ? > ( {
2021-10-12 14:55:54 +08:00
required TResult Function ( ) initial ,
2021-10-12 13:07:41 +08:00
required TResult Function ( bool isEditing ) setIsEditing ,
2021-10-12 14:55:54 +08:00
required TResult Function ( String newName ) rename ,
required TResult Function ( ) delete ,
2021-10-20 22:19:01 +08:00
required TResult Function ( ) duplicate ,
2021-10-12 14:55:54 +08:00
required TResult Function ( Either < View , WorkspaceError > result )
viewDidUpdate ,
2021-07-24 14:05:49 +08:00
} ) {
2021-10-12 14:55:54 +08:00
return viewDidUpdate ( result ) ;
2021-07-24 14:05:49 +08:00
}
@ override
@ optionalTypeArgs
TResult maybeWhen < TResult extends Object ? > ( {
2021-10-12 14:55:54 +08:00
TResult Function ( ) ? initial ,
2021-10-12 13:07:41 +08:00
TResult Function ( bool isEditing ) ? setIsEditing ,
2021-10-12 14:55:54 +08:00
TResult Function ( String newName ) ? rename ,
TResult Function ( ) ? delete ,
2021-10-20 22:19:01 +08:00
TResult Function ( ) ? duplicate ,
2021-10-12 14:55:54 +08:00
TResult Function ( Either < View , WorkspaceError > result ) ? viewDidUpdate ,
2021-07-24 14:05:49 +08:00
required TResult orElse ( ) ,
} ) {
2021-10-12 14:55:54 +08:00
if ( viewDidUpdate ! = null ) {
return viewDidUpdate ( result ) ;
2021-07-24 14:05:49 +08:00
}
return orElse ( ) ;
}
@ override
@ optionalTypeArgs
TResult map < TResult extends Object ? > ( {
2021-10-12 14:55:54 +08:00
required TResult Function ( Initial value ) initial ,
2021-10-12 13:07:41 +08:00
required TResult Function ( SetEditing value ) setIsEditing ,
2021-10-12 14:55:54 +08:00
required TResult Function ( Rename value ) rename ,
required TResult Function ( Delete value ) delete ,
2021-10-20 22:19:01 +08:00
required TResult Function ( Duplicate value ) duplicate ,
2021-10-12 14:55:54 +08:00
required TResult Function ( ViewDidUpdate value ) viewDidUpdate ,
2021-07-24 14:05:49 +08:00
} ) {
2021-10-12 14:55:54 +08:00
return viewDidUpdate ( this ) ;
2021-07-24 14:05:49 +08:00
}
@ override
@ optionalTypeArgs
TResult maybeMap < TResult extends Object ? > ( {
2021-10-12 14:55:54 +08:00
TResult Function ( Initial value ) ? initial ,
2021-10-12 13:07:41 +08:00
TResult Function ( SetEditing value ) ? setIsEditing ,
2021-10-12 14:55:54 +08:00
TResult Function ( Rename value ) ? rename ,
TResult Function ( Delete value ) ? delete ,
2021-10-20 22:19:01 +08:00
TResult Function ( Duplicate value ) ? duplicate ,
2021-10-12 14:55:54 +08:00
TResult Function ( ViewDidUpdate value ) ? viewDidUpdate ,
2021-07-24 14:05:49 +08:00
required TResult orElse ( ) ,
} ) {
2021-10-12 14:55:54 +08:00
if ( viewDidUpdate ! = null ) {
return viewDidUpdate ( this ) ;
2021-07-24 14:05:49 +08:00
}
return orElse ( ) ;
}
}
2021-10-12 14:55:54 +08:00
abstract class ViewDidUpdate implements ViewEvent {
const factory ViewDidUpdate ( Either < View , WorkspaceError > result ) =
_ $ViewDidUpdate ;
2021-10-12 13:07:41 +08:00
2021-10-12 14:55:54 +08:00
Either < View , WorkspaceError > get result = > throw _privateConstructorUsedError ;
2021-10-12 13:07:41 +08:00
@ JsonKey ( ignore: true )
2021-10-12 14:55:54 +08:00
$ViewDidUpdateCopyWith < ViewDidUpdate > get copyWith = >
2021-10-12 13:07:41 +08:00
throw _privateConstructorUsedError ;
2021-07-24 14:05:49 +08:00
}
/// @nodoc
class _ $ViewStateTearOff {
const _ $ViewStateTearOff ( ) ;
_ViewState call (
2021-10-12 13:07:41 +08:00
{ required View view ,
required bool isEditing ,
2021-07-24 14:05:49 +08:00
required Either < Unit , WorkspaceError > successOrFailure } ) {
return _ViewState (
view: view ,
2021-10-12 13:07:41 +08:00
isEditing: isEditing ,
2021-07-24 14:05:49 +08:00
successOrFailure: successOrFailure ,
) ;
}
}
/// @nodoc
const $ViewState = _ $ViewStateTearOff ( ) ;
/// @nodoc
mixin _ $ViewState {
2021-10-12 13:07:41 +08:00
View get view = > throw _privateConstructorUsedError ;
bool get isEditing = > throw _privateConstructorUsedError ;
2021-07-24 14:05:49 +08:00
Either < Unit , WorkspaceError > get successOrFailure = >
throw _privateConstructorUsedError ;
@ JsonKey ( ignore: true )
$ViewStateCopyWith < ViewState > get copyWith = >
throw _privateConstructorUsedError ;
}
/// @nodoc
abstract class $ViewStateCopyWith < $Res > {
factory $ViewStateCopyWith ( ViewState value , $Res Function ( ViewState ) then ) =
_ $ViewStateCopyWithImpl < $Res > ;
$Res call (
2021-10-12 13:07:41 +08:00
{ View view ,
bool isEditing ,
2021-07-24 14:05:49 +08:00
Either < Unit , WorkspaceError > successOrFailure } ) ;
}
/// @nodoc
class _ $ViewStateCopyWithImpl < $Res > implements $ViewStateCopyWith < $Res > {
_ $ViewStateCopyWithImpl ( this . _value , this . _then ) ;
final ViewState _value ;
// ignore: unused_field
final $Res Function ( ViewState ) _then ;
@ override
$Res call ( {
Object ? view = freezed ,
2021-10-12 13:07:41 +08:00
Object ? isEditing = freezed ,
2021-07-24 14:05:49 +08:00
Object ? successOrFailure = freezed ,
} ) {
return _then ( _value . copyWith (
view: view = = freezed
? _value . view
: view // ignore: cast_nullable_to_non_nullable
2021-10-12 13:07:41 +08:00
as View ,
isEditing: isEditing = = freezed
? _value . isEditing
: isEditing // ignore: cast_nullable_to_non_nullable
as bool ,
2021-07-24 14:05:49 +08:00
successOrFailure: successOrFailure = = freezed
? _value . successOrFailure
: successOrFailure // ignore: cast_nullable_to_non_nullable
as Either < Unit , WorkspaceError > ,
) ) ;
}
}
/// @nodoc
abstract class _ $ViewStateCopyWith < $Res > implements $ViewStateCopyWith < $Res > {
factory _ $ViewStateCopyWith (
_ViewState value , $Res Function ( _ViewState ) then ) =
__ $ViewStateCopyWithImpl < $Res > ;
@ override
$Res call (
2021-10-12 13:07:41 +08:00
{ View view ,
bool isEditing ,
2021-07-24 14:05:49 +08:00
Either < Unit , WorkspaceError > successOrFailure } ) ;
}
/// @nodoc
class __ $ViewStateCopyWithImpl < $Res > extends _ $ViewStateCopyWithImpl < $Res >
implements _ $ViewStateCopyWith < $Res > {
__ $ViewStateCopyWithImpl ( _ViewState _value , $Res Function ( _ViewState ) _then )
: super ( _value , ( v ) = > _then ( v as _ViewState ) ) ;
@ override
_ViewState get _value = > super . _value as _ViewState ;
@ override
$Res call ( {
Object ? view = freezed ,
2021-10-12 13:07:41 +08:00
Object ? isEditing = freezed ,
2021-07-24 14:05:49 +08:00
Object ? successOrFailure = freezed ,
} ) {
return _then ( _ViewState (
view: view = = freezed
? _value . view
: view // ignore: cast_nullable_to_non_nullable
2021-10-12 13:07:41 +08:00
as View ,
isEditing: isEditing = = freezed
? _value . isEditing
: isEditing // ignore: cast_nullable_to_non_nullable
as bool ,
2021-07-24 14:05:49 +08:00
successOrFailure: successOrFailure = = freezed
? _value . successOrFailure
: successOrFailure // ignore: cast_nullable_to_non_nullable
as Either < Unit , WorkspaceError > ,
) ) ;
}
}
/// @nodoc
class _ $_ViewState implements _ViewState {
const _ $_ViewState (
2021-10-12 13:07:41 +08:00
{ required this . view ,
required this . isEditing ,
2021-07-24 14:05:49 +08:00
required this . successOrFailure } ) ;
@ override
2021-10-12 13:07:41 +08:00
final View view ;
@ override
final bool isEditing ;
2021-07-24 14:05:49 +08:00
@ override
final Either < Unit , WorkspaceError > successOrFailure ;
@ override
String toString ( ) {
2021-10-12 14:55:54 +08:00
return ' ViewState(view: $ view , isEditing: $ isEditing , successOrFailure: $ successOrFailure ) ' ;
2021-07-24 14:05:49 +08:00
}
@ override
bool operator = = ( dynamic other ) {
return identical ( this , other ) | |
( other is _ViewState & &
( identical ( other . view , view ) | |
const DeepCollectionEquality ( ) . equals ( other . view , view ) ) & &
2021-10-12 13:07:41 +08:00
( identical ( other . isEditing , isEditing ) | |
const DeepCollectionEquality ( )
. equals ( other . isEditing , isEditing ) ) & &
2021-07-24 14:05:49 +08:00
( identical ( other . successOrFailure , successOrFailure ) | |
const DeepCollectionEquality ( )
. equals ( other . successOrFailure , successOrFailure ) ) ) ;
}
@ override
int get hashCode = >
runtimeType . hashCode ^
const DeepCollectionEquality ( ) . hash ( view ) ^
2021-10-12 13:07:41 +08:00
const DeepCollectionEquality ( ) . hash ( isEditing ) ^
2021-07-24 14:05:49 +08:00
const DeepCollectionEquality ( ) . hash ( successOrFailure ) ;
@ JsonKey ( ignore: true )
@ override
_ $ViewStateCopyWith < _ViewState > get copyWith = >
__ $ViewStateCopyWithImpl < _ViewState > ( this , _ $identity ) ;
}
abstract class _ViewState implements ViewState {
const factory _ViewState (
2021-10-12 13:07:41 +08:00
{ required View view ,
required bool isEditing ,
2021-07-24 14:05:49 +08:00
required Either < Unit , WorkspaceError > successOrFailure } ) = _ $_ViewState ;
@ override
2021-10-12 13:07:41 +08:00
View get view = > throw _privateConstructorUsedError ;
@ override
bool get isEditing = > throw _privateConstructorUsedError ;
2021-07-24 14:05:49 +08:00
@ override
Either < Unit , WorkspaceError > get successOrFailure = >
throw _privateConstructorUsedError ;
@ override
@ JsonKey ( ignore: true )
_ $ViewStateCopyWith < _ViewState > get copyWith = >
throw _privateConstructorUsedError ;
}