From 8837066d73c01e0af06068c617760dce0fed1d79 Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Tue, 20 Dec 2022 11:23:03 -0500 Subject: [PATCH 01/47] fix(authentication): handle empty provider list (closes #113) --- .../lib/src/data/models/account_model_firebase.dart | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/packages/wyatt_authentication_bloc/lib/src/data/models/account_model_firebase.dart b/packages/wyatt_authentication_bloc/lib/src/data/models/account_model_firebase.dart index 22313043..d6a70ba5 100644 --- a/packages/wyatt_authentication_bloc/lib/src/data/models/account_model_firebase.dart +++ b/packages/wyatt_authentication_bloc/lib/src/data/models/account_model_firebase.dart @@ -33,11 +33,13 @@ class AccountModelFirebase extends AccountModel { factory AccountModelFirebase.fromFirebaseUser(User? user) { if (user != null) { + final providerId = + (user.providerData.isEmpty) ? '' : user.providerData.first.providerId; return AccountModelFirebase._( uid: user.uid, emailVerified: user.emailVerified, isAnonymous: user.isAnonymous, - providerId: user.providerData.first.providerId, + providerId: providerId, creationTime: user.metadata.creationTime, lastSignInTime: user.metadata.lastSignInTime, isNewUser: (user.metadata.creationTime != null && -- 2.47.2 From 222b650bd28e5f8b518822b81bc1d76bf4af2b09 Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Tue, 20 Dec 2022 19:14:42 -0500 Subject: [PATCH 02/47] fix(authentication): stream on null account --- .../remote/authentication_firebase_data_source_impl.dart | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/authentication_firebase_data_source_impl.dart b/packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/authentication_firebase_data_source_impl.dart index 8a4ce432..a0344195 100644 --- a/packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/authentication_firebase_data_source_impl.dart +++ b/packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/authentication_firebase_data_source_impl.dart @@ -101,9 +101,12 @@ class AuthenticationFirebaseDataSourceImpl @override Stream streamAccount() => _firebaseAuth.userChanges().map((user) { + if (user.isNull) { + return null; + } try { return AccountModelFirebase.fromFirebaseUser(user); - } on FirebaseAuthException { + } on Exception { return null; } }); -- 2.47.2 From fe4ce3cbbc63150a60726927915aad6a4249f108 Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Wed, 28 Dec 2022 18:27:23 +0100 Subject: [PATCH 03/47] refactor: make signup/in, passwordreset cubit extendable --- .../authentication_repository_impl.dart | 11 ++++++ .../cubit/authentication_cubit.dart | 18 +++++----- .../cubit/email_verification_cubit.dart | 14 ++++---- .../cubit/password_reset_cubit.dart | 26 +++++++------- .../features/sign_in/cubit/sign_in_cubit.dart | 34 +++++++++---------- .../features/sign_up/cubit/sign_up_cubit.dart | 30 ++++++++-------- 6 files changed, 69 insertions(+), 64 deletions(-) diff --git a/packages/wyatt_authentication_bloc/lib/src/data/repositories/authentication_repository_impl.dart b/packages/wyatt_authentication_bloc/lib/src/data/repositories/authentication_repository_impl.dart index e2687ea8..287b4171 100644 --- a/packages/wyatt_authentication_bloc/lib/src/data/repositories/authentication_repository_impl.dart +++ b/packages/wyatt_authentication_bloc/lib/src/data/repositories/authentication_repository_impl.dart @@ -91,6 +91,17 @@ class AuthenticationRepositoryImpl ], name: AuthFormName.signUpForm, ), + ) + ..registerForm( + WyattFormImpl( + [ + FormInput( + AuthFormField.email, + customEmailValidator ?? const Email.pure(), + ), + ], + name: AuthFormName.passwordResetForm, + ), ); } final AuthenticationCacheDataSource _authenticationLocalDataSource; diff --git a/packages/wyatt_authentication_bloc/lib/src/features/authentication/cubit/authentication_cubit.dart b/packages/wyatt_authentication_bloc/lib/src/features/authentication/cubit/authentication_cubit.dart index eab1ffbb..32b00997 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/authentication/cubit/authentication_cubit.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/authentication/cubit/authentication_cubit.dart @@ -27,27 +27,26 @@ part 'authentication_state.dart'; class AuthenticationCubit extends Cubit> { AuthenticationCubit({ - required AuthenticationRepository authenticationRepository, - }) : _authenticationRepository = authenticationRepository, - super(const AuthenticationState.unknown()) { + required this.authenticationRepository, + }) : super(const AuthenticationState.unknown()) { _listenForAuthenticationChanges(); } - final AuthenticationRepository _authenticationRepository; + final AuthenticationRepository authenticationRepository; void _listenForAuthenticationChanges() { - _authenticationRepository.streamAccount().listen((accountFutureResult) { + authenticationRepository.streamAccount().listen((accountFutureResult) { accountFutureResult.fold( (value) { if (value.account.isNotNull) { emit(AuthenticationState.authenticated(value)); return; } - _authenticationRepository.destroyCache(); + authenticationRepository.destroyCache(); emit(AuthenticationState.unauthenticated()); return; }, (error) { - _authenticationRepository.destroyCache(); + authenticationRepository.destroyCache(); emit(AuthenticationState.unauthenticated()); return; }, @@ -58,7 +57,7 @@ class AuthenticationCubit extends Cubit> { /// If authenticated, re-emits state with data freshly loaded from cache. FutureOr reloadCache() async { if (state.status == AuthenticationStatus.authenticated) { - final data = await _authenticationRepository.getCache(); + final data = await authenticationRepository.getCache(); emit( data.fold( AuthenticationState.authenticated, @@ -69,7 +68,6 @@ class AuthenticationCubit extends Cubit> { } FutureOr signOut() { - // TODO(hpcl): maybe force unauthenticated by emitting an event - _authenticationRepository.signOut(); + authenticationRepository.signOut(); } } diff --git a/packages/wyatt_authentication_bloc/lib/src/features/email_verification/cubit/email_verification_cubit.dart b/packages/wyatt_authentication_bloc/lib/src/features/email_verification/cubit/email_verification_cubit.dart index 132dafd2..bb40411b 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/email_verification/cubit/email_verification_cubit.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/email_verification/cubit/email_verification_cubit.dart @@ -25,14 +25,14 @@ part 'email_verification_state.dart'; class EmailVerificationCubit extends Cubit { EmailVerificationCubit({ - required AuthenticationRepository authenticationRepository, - }) : _authenticationRepository = authenticationRepository, - super(const EmailVerificationState()); - final AuthenticationRepository _authenticationRepository; + required this.authenticationRepository, + }) : super(const EmailVerificationState()); + + final AuthenticationRepository authenticationRepository; FutureOr sendEmailVerification() async { emit(state.copyWith(status: FormStatus.submissionInProgress)); - final response = await _authenticationRepository.sendEmailVerification(); + final response = await authenticationRepository.sendEmailVerification(); emit( response.fold( (value) => state.copyWith(status: FormStatus.submissionSuccess), @@ -47,7 +47,7 @@ class EmailVerificationCubit extends Cubit { FutureOr checkEmailVerification() async { emit(state.copyWith(status: FormStatus.submissionInProgress)); - final refresh = await _authenticationRepository.refresh(); + final refresh = await authenticationRepository.refresh(); if (refresh.isErr) { final refreshError = refresh.err!; emit( @@ -59,7 +59,7 @@ class EmailVerificationCubit extends Cubit { return; } - final currentAccount = await _authenticationRepository.getAccount(); + final currentAccount = await authenticationRepository.getAccount(); emit( currentAccount.fold( (value) => state.copyWith( diff --git a/packages/wyatt_authentication_bloc/lib/src/features/password_reset/cubit/password_reset_cubit.dart b/packages/wyatt_authentication_bloc/lib/src/features/password_reset/cubit/password_reset_cubit.dart index 9ecfe309..fd942bdf 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/password_reset/cubit/password_reset_cubit.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/password_reset/cubit/password_reset_cubit.dart @@ -26,17 +26,17 @@ part 'password_reset_state.dart'; class PasswordResetCubit extends FormDataCubit { PasswordResetCubit({ - required AuthenticationRepository authenticationRepository, - }) : _authenticationRepository = authenticationRepository, + required this.authenticationRepository, + }) : super( PasswordResetState( form: authenticationRepository.formRepository .accessForm(AuthFormName.passwordResetForm), ), ); - final AuthenticationRepository _authenticationRepository; - FormRepository get _formRepository => - _authenticationRepository.formRepository; + final AuthenticationRepository authenticationRepository; + FormRepository get formRepository => + authenticationRepository.formRepository; @override String get formName => AuthFormName.passwordResetForm; @@ -51,11 +51,11 @@ class PasswordResetCubit extends FormDataCubit { String key, FormInputValidator dirtyValue, ) { - final form = _formRepository.accessForm(formName).clone(); + final form = formRepository.accessForm(formName).clone(); try { form.updateValidator(key, dirtyValue); - _formRepository.updateForm(form); + formRepository.updateForm(form); } catch (e) { rethrow; } @@ -68,7 +68,7 @@ class PasswordResetCubit extends FormDataCubit { @override FutureOr reset() { final form = state.form.reset(); - _formRepository.updateForm(form); + formRepository.updateForm(form); emit( state.copyWith(form: form, status: form.validate()), ); @@ -82,7 +82,7 @@ class PasswordResetCubit extends FormDataCubit { emit(state.copyWith(status: FormStatus.submissionInProgress)); - final form = _formRepository.accessForm(formName); + final form = formRepository.accessForm(formName); final email = form.valueOf(AuthFormField.email); if (email.isNullOrEmpty) { @@ -94,7 +94,7 @@ class PasswordResetCubit extends FormDataCubit { ); } - final response = await _authenticationRepository.sendPasswordResetEmail( + final response = await authenticationRepository.sendPasswordResetEmail( email: email!, ); @@ -114,9 +114,9 @@ class PasswordResetCubit extends FormDataCubit { WyattForm form, { SetOperation operation = SetOperation.replace, }) { - final WyattForm current = _formRepository.accessForm(formName).clone(); + final WyattForm current = formRepository.accessForm(formName).clone(); final WyattForm newForm = operation.operation.call(current, form); - _formRepository.updateForm(newForm); + formRepository.updateForm(newForm); emit( state.copyWith( @@ -130,7 +130,7 @@ class PasswordResetCubit extends FormDataCubit { FutureOr validate() { emit( state.copyWith( - status: _formRepository.accessForm(formName).validate(), + status: formRepository.accessForm(formName).validate(), ), ); } diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/sign_in_cubit.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/sign_in_cubit.dart index 91262ce3..5c7e460c 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/sign_in_cubit.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/sign_in_cubit.dart @@ -24,23 +24,21 @@ part 'sign_in_state.dart'; class SignInCubit extends FormDataCubit { SignInCubit({ - required AuthenticationRepository authenticationRepository, - }) : _authenticationRepository = authenticationRepository, - super( + required this.authenticationRepository, + }) : super( SignInState( form: authenticationRepository.formRepository .accessForm(AuthFormName.signInForm), ), ); - final AuthenticationRepository _authenticationRepository; - FormRepository get _formRepository => - _authenticationRepository.formRepository; + final AuthenticationRepository authenticationRepository; + FormRepository get formRepository => authenticationRepository.formRepository; @override String get formName => AuthFormName.signInForm; void emailChanged(String value) { - final emailValidatorType = _formRepository + final emailValidatorType = formRepository .accessForm(formName) .validatorOf(AuthFormField.email) .runtimeType; @@ -54,7 +52,7 @@ class SignInCubit extends FormDataCubit { } void passwordChanged(String value) { - final passwordValidatorType = _formRepository + final passwordValidatorType = formRepository .accessForm(formName) .validatorOf(AuthFormField.password) .runtimeType; @@ -91,11 +89,11 @@ class SignInCubit extends FormDataCubit { String key, FormInputValidator dirtyValue, ) { - final form = _formRepository.accessForm(formName).clone(); + final form = formRepository.accessForm(formName).clone(); try { form.updateValidator(key, dirtyValue); - _formRepository.updateForm(form); + formRepository.updateForm(form); } catch (e) { rethrow; } @@ -108,7 +106,7 @@ class SignInCubit extends FormDataCubit { @override FutureOr reset() { final form = state.form.reset(); - _formRepository.updateForm(form); + formRepository.updateForm(form); emit( state.copyWith(form: form, status: form.validate()), ); @@ -125,9 +123,9 @@ class SignInCubit extends FormDataCubit { WyattForm form, { SetOperation operation = SetOperation.replace, }) { - final WyattForm current = _formRepository.accessForm(formName).clone(); + final WyattForm current = formRepository.accessForm(formName).clone(); final WyattForm newForm = operation.operation.call(current, form); - _formRepository.updateForm(newForm); + formRepository.updateForm(newForm); emit( state.copyWith( @@ -141,7 +139,7 @@ class SignInCubit extends FormDataCubit { FutureOr validate() { emit( state.copyWith( - status: _formRepository.accessForm(formName).validate(), + status: formRepository.accessForm(formName).validate(), ), ); } @@ -157,7 +155,7 @@ class SignInCubit extends FormDataCubit { emit(state.copyWith(status: FormStatus.submissionInProgress)); - final form = _formRepository.accessForm(formName); + final form = formRepository.accessForm(formName); final email = form.valueOf(AuthFormField.email); final password = form.valueOf(AuthFormField.password); @@ -170,7 +168,7 @@ class SignInCubit extends FormDataCubit { ); } - final uid = await _authenticationRepository.signInWithEmailAndPassword( + final uid = await authenticationRepository.signInWithEmailAndPassword( email: email!, password: password!, ); @@ -193,7 +191,7 @@ class SignInCubit extends FormDataCubit { emit(state.copyWith(status: FormStatus.submissionInProgress)); - final uid = await _authenticationRepository.signInAnonymously(); + final uid = await authenticationRepository.signInAnonymously(); emit( uid.fold( @@ -213,7 +211,7 @@ class SignInCubit extends FormDataCubit { // TODO(wyatt): maybe emit new state (to not carry an old errorMessage) emit(state.copyWith(status: FormStatus.submissionInProgress)); - final uid = await _authenticationRepository.signInWithGoogle(); + final uid = await authenticationRepository.signInWithGoogle(); emit( uid.fold( diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/sign_up_cubit.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/sign_up_cubit.dart index 2d7ed28b..8d41b000 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/sign_up_cubit.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/sign_up_cubit.dart @@ -26,23 +26,21 @@ part 'sign_up_state.dart'; class SignUpCubit extends FormDataCubit { SignUpCubit({ - required AuthenticationRepository authenticationRepository, - }) : _authenticationRepository = authenticationRepository, - super( + required this.authenticationRepository, + }) : super( SignUpState( form: authenticationRepository.formRepository .accessForm(AuthFormName.signUpForm), ), ); - final AuthenticationRepository _authenticationRepository; - FormRepository get _formRepository => - _authenticationRepository.formRepository; + final AuthenticationRepository authenticationRepository; + FormRepository get formRepository => authenticationRepository.formRepository; @override String get formName => AuthFormName.signUpForm; void emailChanged(String value) { - final emailValidatorType = _formRepository + final emailValidatorType = formRepository .accessForm(formName) .validatorOf(AuthFormField.email) .runtimeType; @@ -56,7 +54,7 @@ class SignUpCubit extends FormDataCubit { } void passwordChanged(String value) { - final passwordValidatorType = _formRepository + final passwordValidatorType = formRepository .accessForm(formName) .validatorOf(AuthFormField.password) .runtimeType; @@ -93,11 +91,11 @@ class SignUpCubit extends FormDataCubit { String key, FormInputValidator dirtyValue, ) { - final form = _formRepository.accessForm(formName).clone(); + final form = formRepository.accessForm(formName).clone(); try { form.updateValidator(key, dirtyValue); - _formRepository.updateForm(form); + formRepository.updateForm(form); } catch (e) { rethrow; } @@ -110,7 +108,7 @@ class SignUpCubit extends FormDataCubit { @override FutureOr reset() { final form = state.form.reset(); - _formRepository.updateForm(form); + formRepository.updateForm(form); emit( state.copyWith(form: form, status: form.validate()), ); @@ -124,7 +122,7 @@ class SignUpCubit extends FormDataCubit { emit(state.copyWith(status: FormStatus.submissionInProgress)); - final form = _formRepository.accessForm(formName); + final form = formRepository.accessForm(formName); final email = form.valueOf(AuthFormField.email); final password = form.valueOf(AuthFormField.password); @@ -137,7 +135,7 @@ class SignUpCubit extends FormDataCubit { ); } - final uid = await _authenticationRepository.signUp( + final uid = await authenticationRepository.signUp( email: email!, password: password!, ); @@ -158,9 +156,9 @@ class SignUpCubit extends FormDataCubit { WyattForm form, { SetOperation operation = SetOperation.replace, }) { - final WyattForm current = _formRepository.accessForm(formName).clone(); + final WyattForm current = formRepository.accessForm(formName).clone(); final WyattForm newForm = operation.operation.call(current, form); - _formRepository.updateForm(newForm); + formRepository.updateForm(newForm); emit( state.copyWith( @@ -174,7 +172,7 @@ class SignUpCubit extends FormDataCubit { FutureOr validate() { emit( state.copyWith( - status: _formRepository.accessForm(formName).validate(), + status: formRepository.accessForm(formName).validate(), ), ); } -- 2.47.2 From adcd98f47b48a40c91b473667a271bfc46d69141 Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Thu, 29 Dec 2022 17:03:35 +0100 Subject: [PATCH 04/47] feat(authentication)!: add event type on auth change --- .../authentication_repository_impl.dart | 182 +++++++++--------- .../domain/entities/auth_change_event.dart | 43 +++++ .../lib/src/domain/entities/entities.dart | 1 + .../authentication_repository.dart | 23 +++ 4 files changed, 161 insertions(+), 88 deletions(-) create mode 100644 packages/wyatt_authentication_bloc/lib/src/domain/entities/auth_change_event.dart diff --git a/packages/wyatt_authentication_bloc/lib/src/data/repositories/authentication_repository_impl.dart b/packages/wyatt_authentication_bloc/lib/src/data/repositories/authentication_repository_impl.dart index 287b4171..67648935 100644 --- a/packages/wyatt_authentication_bloc/lib/src/data/repositories/authentication_repository_impl.dart +++ b/packages/wyatt_authentication_bloc/lib/src/data/repositories/authentication_repository_impl.dart @@ -16,7 +16,6 @@ import 'dart:async'; -import 'package:rxdart/rxdart.dart'; import 'package:wyatt_architecture/wyatt_architecture.dart'; import 'package:wyatt_authentication_bloc/src/core/constants/form_field.dart'; import 'package:wyatt_authentication_bloc/src/core/constants/form_name.dart'; @@ -25,37 +24,25 @@ import 'package:wyatt_authentication_bloc/src/domain/data_sources/local/authenti import 'package:wyatt_authentication_bloc/src/domain/data_sources/remote/authentication_remote_data_source.dart'; import 'package:wyatt_authentication_bloc/src/domain/entities/account.dart'; import 'package:wyatt_authentication_bloc/src/domain/entities/account_wrapper.dart'; +import 'package:wyatt_authentication_bloc/src/domain/entities/auth_change_event.dart'; import 'package:wyatt_authentication_bloc/src/domain/repositories/authentication_repository.dart'; import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; import 'package:wyatt_type_utils/wyatt_type_utils.dart'; -typedef OnSignUpSuccess = FutureOrResult Function( - AuthenticationRepository repo, - Account? account, - WyattForm form, -); - -typedef OnAuthChange = FutureOrResult Function( - AuthenticationRepository repo, - Account? account, -); - class AuthenticationRepositoryImpl extends AuthenticationRepository { AuthenticationRepositoryImpl({ - required AuthenticationCacheDataSource authenticationCacheDataSource, - required AuthenticationRemoteDataSource authenticationRemoteDataSource, + required this.authenticationCacheDataSource, + required this.authenticationRemoteDataSource, FormRepository? formRepository, // ignore: strict_raw_type List? extraSignUpInputs, FormInputValidator? customEmailValidator, FormInputValidator? customPasswordValidator, - OnSignUpSuccess? onSignUpSuccess, - OnAuthChange? onAuthChange, - }) : _authenticationLocalDataSource = authenticationCacheDataSource, - _authenticationRemoteDataSource = authenticationRemoteDataSource, - _onSignUpSuccess = onSignUpSuccess, - _onAccountChanges = onAuthChange { + AuthChangeListener? onAuthChange, + AccountStreamTransformer? accountStreamTransformer, + }) : _authChangeListener = onAuthChange, + _accountStreamTransformer = accountStreamTransformer { _formRepository = formRepository ?? FormRepositoryImpl(); if (formRepository != null) { return; @@ -103,23 +90,34 @@ class AuthenticationRepositoryImpl name: AuthFormName.passwordResetForm, ), ); + _accountStreamTransformer ??= (input) => input + .where((event) => event is! SignUpAuthChangeEvent) + .map>>((event) async { + if (listener == null) { + return Ok(AccountWrapperModel(event.account, null)); + } + // Handle sign in, sign out and refresh + final dataResult = await listener!.call(this, event); + return dataResult.map((data) { + authenticationCacheDataSource.storeData(data); + return AccountWrapperModel(event.account, data); + }); + }); } - final AuthenticationCacheDataSource _authenticationLocalDataSource; - final AuthenticationRemoteDataSource _authenticationRemoteDataSource; + final AuthenticationCacheDataSource authenticationCacheDataSource; + final AuthenticationRemoteDataSource authenticationRemoteDataSource; late FormRepository _formRepository; - final OnSignUpSuccess? _onSignUpSuccess; - - final OnAuthChange? _onAccountChanges; - final StreamController>> _signUpStream = - StreamController(); - - bool _pause = false; + AuthChangeListener? _authChangeListener; + AccountStreamTransformer? _accountStreamTransformer; @override FormRepository get formRepository => _formRepository; + @override + AuthChangeListener? get listener => _authChangeListener; + @override FutureOrResult signInWithEmailAndPassword({ required String email, @@ -128,11 +126,11 @@ class AuthenticationRepositoryImpl Result.tryCatchAsync( () async { final account = - await _authenticationRemoteDataSource.signInWithEmailAndPassword( + await authenticationRemoteDataSource.signInWithEmailAndPassword( email: email, password: password, ); - await _authenticationLocalDataSource.storeAccount(account); + await authenticationCacheDataSource.storeAccount(account); return account; }, (error) => error, @@ -142,8 +140,8 @@ class AuthenticationRepositoryImpl FutureOrResult signOut() => Result.tryCatchAsync( () async { - await _authenticationRemoteDataSource.signOut(); - await _authenticationLocalDataSource.destroy(); + await authenticationRemoteDataSource.signOut(); + await authenticationCacheDataSource.destroy(); }, (error) => error, ); @@ -155,54 +153,34 @@ class AuthenticationRepositoryImpl }) => Result.tryCatchAsync( () async { - _pause = true; - final account = await _authenticationRemoteDataSource.signUp( + final account = await authenticationRemoteDataSource.signUp( email: email, password: password, ); - await _authenticationLocalDataSource.storeAccount(account); - if (_onSignUpSuccess.isNotNull) { - final dataResult = await _onSignUpSuccess!.call( - this, - account, - _formRepository.accessForm(AuthFormName.signUpForm).clone(), - ); - await dataResult.foldAsync( - (data) async { - await _authenticationLocalDataSource.storeData(data); - _signUpStream - .add(Future.value(Ok(AccountWrapperModel(account, data)))); - }, - (error) async => error, - ); - } - _pause = false; + await authenticationCacheDataSource.storeAccount(account); return account; }, - (error) { - _pause = false; - return error; - }, + (error) => error, ); @override FutureOrResult destroyCache() => Result.tryCatchAsync( - _authenticationLocalDataSource.destroy, + authenticationCacheDataSource.destroy, (error) => error, ); @override FutureOrResult> getCache() => Result.tryCatchAsync, AppException, AppException>( - _authenticationLocalDataSource.load, + authenticationCacheDataSource.load, (error) => error, ); @override FutureOrResult getAccount() => Result.tryCatchAsync( - _authenticationLocalDataSource.loadAccount, + authenticationCacheDataSource.loadAccount, (error) => error, ); @@ -212,7 +190,7 @@ class AuthenticationRepositoryImpl ) => Result.tryCatchAsync( () async { - await _authenticationLocalDataSource.storeAccount(account); + await authenticationCacheDataSource.storeAccount(account); }, (error) => error, ); @@ -220,7 +198,7 @@ class AuthenticationRepositoryImpl @override FutureOrResult getData() => Result.tryCatchAsync( - _authenticationLocalDataSource.loadData, + authenticationCacheDataSource.loadData, (error) => error, ); @@ -230,7 +208,7 @@ class AuthenticationRepositoryImpl ) => Result.tryCatchAsync( () async { - await _authenticationLocalDataSource.storeData(data); + await authenticationCacheDataSource.storeData(data); }, (error) => error, ); @@ -238,26 +216,13 @@ class AuthenticationRepositoryImpl @override FutureOrResult getIdentityToken() => Result.tryCatchAsync( - _authenticationRemoteDataSource.getIdentityToken, + authenticationRemoteDataSource.getIdentityToken, (error) => error, ); @override - Stream>> streamAccount() => MergeStream([ - _signUpStream.stream.asBroadcastStream(), - _authenticationRemoteDataSource.streamAccount().map((account) async { - if (_onAccountChanges.isNotNull && !_pause) { - final dataResult = await _onAccountChanges!.call(this, account); - return dataResult.map((data) { - _authenticationLocalDataSource.storeData(data); - return AccountWrapperModel(account, data); - }); - } - return Ok, AppException>( - AccountWrapperModel(account, null), - ); - }) - ]); + Stream>> streamAccount() => + _accountStreamTransformer!.call(changes()); @override FutureOrResult confirmPasswordReset({ @@ -266,7 +231,7 @@ class AuthenticationRepositoryImpl }) => Result.tryCatchAsync( () async { - await _authenticationRemoteDataSource.confirmPasswordReset( + await authenticationRemoteDataSource.confirmPasswordReset( code: code, newPassword: newPassword, ); @@ -278,7 +243,7 @@ class AuthenticationRepositoryImpl FutureOrResult sendEmailVerification() => Result.tryCatchAsync( () async { - await _authenticationRemoteDataSource.sendEmailVerification(); + await authenticationRemoteDataSource.sendEmailVerification(); }, (error) => error, ); @@ -287,7 +252,7 @@ class AuthenticationRepositoryImpl FutureOrResult sendPasswordResetEmail({required String email}) => Result.tryCatchAsync( () async { - await _authenticationRemoteDataSource.sendPasswordResetEmail( + await authenticationRemoteDataSource.sendPasswordResetEmail( email: email, ); }, @@ -299,7 +264,7 @@ class AuthenticationRepositoryImpl Result.tryCatchAsync( () async { final account = - await _authenticationRemoteDataSource.signInAnonymously(); + await authenticationRemoteDataSource.signInAnonymously(); return account; }, (error) => error, @@ -310,7 +275,7 @@ class AuthenticationRepositoryImpl Result.tryCatchAsync( () async { final account = - await _authenticationRemoteDataSource.signInWithGoogle(); + await authenticationRemoteDataSource.signInWithGoogle(); return account; }, (error) => error, @@ -320,7 +285,7 @@ class AuthenticationRepositoryImpl FutureOrResult verifyPasswordResetCode({required String code}) => Result.tryCatchAsync( () async { - final response = await _authenticationRemoteDataSource + final response = await authenticationRemoteDataSource .verifyPasswordResetCode(code: code); return response; }, @@ -331,7 +296,7 @@ class AuthenticationRepositoryImpl FutureOrResult refresh() => Result.tryCatchAsync( () async { - await _authenticationRemoteDataSource.refresh(); + await authenticationRemoteDataSource.refresh(); }, (error) => error, ); @@ -340,7 +305,7 @@ class AuthenticationRepositoryImpl FutureOrResult reauthenticateWithCredential() => Result.tryCatchAsync( () async { - final account = await _authenticationRemoteDataSource + final account = await authenticationRemoteDataSource .reauthenticateWithCredential(); return account; }, @@ -352,7 +317,7 @@ class AuthenticationRepositoryImpl Result.tryCatchAsync( () async { final account = - await _authenticationRemoteDataSource.updateEmail(email: email); + await authenticationRemoteDataSource.updateEmail(email: email); return account; }, (error) => error, @@ -362,11 +327,52 @@ class AuthenticationRepositoryImpl FutureOrResult updatePassword({required String password}) => Result.tryCatchAsync( () async { - final account = await _authenticationRemoteDataSource.updatePassword( + final account = await authenticationRemoteDataSource.updatePassword( password: password, ); return account; }, (error) => error, ); + + Account? _lastChange; + + @override + Stream changes() => authenticationRemoteDataSource + .streamAccount() + .map((account) { + if (_lastChange != null && account == null) { + _lastChange = null; + return SignOutAuthChangeEvent(); + } + if (_lastChange == null && account != null) { + _lastChange = account; + if (account.isNewUser ?? false) { + return SignUpAuthChangeEvent(account); + } + return SignInAuthChangeEvent(account); + } + if (_lastChange != null && account != null) { + _lastChange = account; + return RefreshAuthChangeEvent(account); + } + if (_lastChange == null && account == null) { + _lastChange = account; + return StillUnauthenticatedAuthChangeEvent(); + } + _lastChange = account; + return RefreshAuthChangeEvent(account); + }); + + @override + FutureOrResult addAuthChangeListener(AuthChangeListener listener) { + _authChangeListener = listener; + return const Ok(null); + } + + @override + FutureOrResult removeAuthChangeListener() { + _authChangeListener = null; + return const Ok(null); + } } diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/entities/auth_change_event.dart b/packages/wyatt_authentication_bloc/lib/src/domain/entities/auth_change_event.dart new file mode 100644 index 00000000..71a311a3 --- /dev/null +++ b/packages/wyatt_authentication_bloc/lib/src/domain/entities/auth_change_event.dart @@ -0,0 +1,43 @@ +// Copyright (C) 2022 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +import 'package:wyatt_authentication_bloc/src/domain/entities/account.dart'; + +abstract class AuthChangeEvent { + AuthChangeEvent(this.account); + + final Account? account; +} + +class SignInAuthChangeEvent extends AuthChangeEvent { + SignInAuthChangeEvent(super.account); +} + +class SignUpAuthChangeEvent extends AuthChangeEvent { + SignUpAuthChangeEvent(super.account); +} + +class RefreshAuthChangeEvent extends AuthChangeEvent { + RefreshAuthChangeEvent(super.account); +} + +class StillUnauthenticatedAuthChangeEvent extends AuthChangeEvent { + StillUnauthenticatedAuthChangeEvent() : super(null); +} + +class SignOutAuthChangeEvent extends AuthChangeEvent { + SignOutAuthChangeEvent() : super(null); +} diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/entities/entities.dart b/packages/wyatt_authentication_bloc/lib/src/domain/entities/entities.dart index e9a858fe..9c83225f 100644 --- a/packages/wyatt_authentication_bloc/lib/src/domain/entities/entities.dart +++ b/packages/wyatt_authentication_bloc/lib/src/domain/entities/entities.dart @@ -16,3 +16,4 @@ export 'account.dart'; export 'account_wrapper.dart'; +export 'auth_change_event.dart'; diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/repositories/authentication_repository.dart b/packages/wyatt_authentication_bloc/lib/src/domain/repositories/authentication_repository.dart index 027c7525..3e958f78 100644 --- a/packages/wyatt_authentication_bloc/lib/src/domain/repositories/authentication_repository.dart +++ b/packages/wyatt_authentication_bloc/lib/src/domain/repositories/authentication_repository.dart @@ -17,10 +17,28 @@ import 'package:wyatt_architecture/wyatt_architecture.dart'; import 'package:wyatt_authentication_bloc/src/domain/entities/account.dart'; import 'package:wyatt_authentication_bloc/src/domain/entities/account_wrapper.dart'; +import 'package:wyatt_authentication_bloc/src/domain/entities/auth_change_event.dart'; import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; +typedef SignUpCallback = FutureOrResult Function( + AuthenticationRepository repo, + Account? account, + WyattForm form, +); + +typedef AuthChangeListener = FutureOrResult Function( + AuthenticationRepository repo, + AuthChangeEvent? authEvent, +); + +typedef AccountStreamTransformer + = Stream>> Function( + Stream input, +); + abstract class AuthenticationRepository extends BaseRepository { FormRepository get formRepository; + AuthChangeListener? get listener; /// {@template signup} /// Creates a new user with the provided [email] and [password]. @@ -141,6 +159,8 @@ abstract class AuthenticationRepository extends BaseRepository { /// {@endtemplate} Stream>> streamAccount(); + Stream changes(); + FutureOrResult getIdentityToken(); FutureOrResult getAccount(); @@ -151,4 +171,7 @@ abstract class AuthenticationRepository extends BaseRepository { FutureOrResult> getCache(); FutureOrResult destroyCache(); + + FutureOrResult addAuthChangeListener(AuthChangeListener listener); + FutureOrResult removeAuthChangeListener(); } -- 2.47.2 From 33cb4f6f06803c6079d200163327fbf441ae506c Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Thu, 29 Dec 2022 17:04:26 +0100 Subject: [PATCH 05/47] refactor(authentication)!: use mixins, and remove use of onSignUpSuccess --- .../sign_in/cubit/base_sign_in_cubit.dart | 97 ++++++++ .../cubit/mixin/sign_in_anonymously.dart | 66 ++++++ .../mixin/sign_in_with_email_password.dart | 139 +++++++++++ .../cubit/mixin/sign_in_with_google.dart | 65 +++++ .../features/sign_in/cubit/sign_in_cubit.dart | 222 +++--------------- .../sign_up/cubit/base_sign_up_cubit.dart | 101 ++++++++ .../mixin/sign_up_with_email_password.dart | 137 +++++++++++ .../features/sign_up/cubit/sign_up_cubit.dart | 162 +------------ .../lib/wyatt_authentication_bloc.dart | 2 + 9 files changed, 646 insertions(+), 345 deletions(-) create mode 100644 packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/base_sign_in_cubit.dart create mode 100644 packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_anonymously.dart create mode 100644 packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_with_email_password.dart create mode 100644 packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_with_google.dart create mode 100644 packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/base_sign_up_cubit.dart create mode 100644 packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/mixin/sign_up_with_email_password.dart diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/base_sign_in_cubit.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/base_sign_in_cubit.dart new file mode 100644 index 00000000..b1446b36 --- /dev/null +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/base_sign_in_cubit.dart @@ -0,0 +1,97 @@ +// Copyright (C) 2022 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +part of 'sign_in_cubit.dart'; + +abstract class BaseSignInCubit extends FormDataCubit { + BaseSignInCubit({ + required this.authenticationRepository, + }) : super( + SignInState( + form: authenticationRepository.formRepository + .accessForm(AuthFormName.signInForm), + ), + ); + final AuthenticationRepository authenticationRepository; + FormRepository get formRepository => authenticationRepository.formRepository; + + @override + String get formName => AuthFormName.signInForm; + + @override + FutureOr dataChanged( + String key, + FormInputValidator dirtyValue, + ) { + final form = formRepository.accessForm(formName).clone(); + + try { + form.updateValidator(key, dirtyValue); + formRepository.updateForm(form); + } catch (e) { + rethrow; + } + + emit( + SignInState(form: form, status: form.validate()), + ); + } + + @override + FutureOr reset() { + final form = state.form.reset(); + formRepository.updateForm(form); + emit( + SignInState(form: form, status: form.validate()), + ); + } + + @override + FutureOr update( + WyattForm form, { + SetOperation operation = SetOperation.replace, + }) { + final WyattForm current = formRepository.accessForm(formName).clone(); + final WyattForm newForm = operation.operation.call(current, form); + formRepository.updateForm(newForm); + + emit( + SignInState(form: newForm, status: newForm.validate()), + ); + } + + @override + FutureOr validate() { + final WyattForm form = formRepository.accessForm(formName); + emit( + SignInState(form: form, status: form.validate()), + ); + } + + @override + FutureOr submit() async { + final WyattForm form = formRepository.accessForm(formName); + const error = '`submit()` is not implemented for BaseSignUpCubit, ' + 'please use `signUpWithEmailAndPassword()`.'; + emit( + SignInState( + form: form, + errorMessage: error, + status: FormStatus.submissionFailure, + ), + ); + } +} diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_anonymously.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_anonymously.dart new file mode 100644 index 00000000..486ed946 --- /dev/null +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_anonymously.dart @@ -0,0 +1,66 @@ +// Copyright (C) 2022 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +import 'dart:async'; + +import 'package:wyatt_architecture/wyatt_architecture.dart'; +import 'package:wyatt_authentication_bloc/src/domain/entities/account.dart'; +import 'package:wyatt_authentication_bloc/src/features/sign_in/cubit/sign_in_cubit.dart'; +import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; +import 'package:wyatt_type_utils/wyatt_type_utils.dart'; + +mixin SignInAnonymously on BaseSignInCubit { + FutureOrResult onSignInAnonymously( + Result result, + WyattForm form, + ); + + FutureOr signInAnonymously() async { + if (state.status.isSubmissionInProgress) { + return; + } + + final form = formRepository.accessForm(formName); + emit(SignInState(form: form, status: FormStatus.submissionInProgress)); + + final result = await authenticationRepository.signInAnonymously(); + + // Here custom code + final callbackResponse = await onSignInAnonymously(result, form); + if (callbackResponse.isErr) { + final error = callbackResponse.err!; + emit( + SignInState( + form: form, + errorMessage: error.message, + status: FormStatus.submissionFailure, + ), + ); + } + + emit( + result.fold( + (value) => + SignInState(form: form, status: FormStatus.submissionSuccess), + (error) => SignInState( + form: form, + errorMessage: error.message, + status: FormStatus.submissionFailure, + ), + ), + ); + } +} diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_with_email_password.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_with_email_password.dart new file mode 100644 index 00000000..9a1d66e3 --- /dev/null +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_with_email_password.dart @@ -0,0 +1,139 @@ +// Copyright (C) 2022 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +import 'dart:async'; + +import 'package:wyatt_architecture/wyatt_architecture.dart'; +import 'package:wyatt_authentication_bloc/src/core/constants/form_field.dart'; +import 'package:wyatt_authentication_bloc/src/domain/entities/account.dart'; +import 'package:wyatt_authentication_bloc/src/features/sign_in/cubit/sign_in_cubit.dart'; +import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; +import 'package:wyatt_type_utils/wyatt_type_utils.dart'; + +mixin SignInWithEmailPassword on BaseSignInCubit { + FutureOrResult onSignInWithEmailAndPassword( + Result result, + WyattForm form, + ); + + void emailChanged(String value) { + final emailValidatorType = formRepository + .accessForm(formName) + .validatorOf(AuthFormField.email) + .runtimeType; + assert( + emailValidatorType == Email, + 'Use emailCustomChanged(...) with validator $emailValidatorType', + ); + + final Email email = Email.dirty(value); + dataChanged(AuthFormField.email, email); + } + + void passwordChanged(String value) { + final passwordValidatorType = formRepository + .accessForm(formName) + .validatorOf(AuthFormField.password) + .runtimeType; + assert( + passwordValidatorType == Password, + 'Use passwordCustomChanged(...) with validator $passwordValidatorType', + ); + final Password password = Password.dirty(value); + dataChanged(AuthFormField.password, password); + } + + /// Same as [emailChanged] but with a custom [Validator]. + /// + /// Sort of short hand for [dataChanged]. + void emailCustomChanged< + Validator extends FormInputValidator>( + Validator validator, + ) { + dataChanged(AuthFormField.email, validator); + } + + /// Same as [passwordChanged] but with a custom [Validator]. + /// + /// Sort of short hand for [dataChanged]. + void passwordCustomChanged< + Validator extends FormInputValidator>( + Validator validator, + ) { + dataChanged(AuthFormField.password, validator); + } + + FutureOr signInWithEmailAndPassword() async { + if (state.status.isSubmissionInProgress) { + return; + } + + if (!state.status.isValidated) { + return; + } + + final form = formRepository.accessForm(formName); + emit( + SignInState( + form: form, + status: FormStatus.submissionInProgress, + ), + ); + + final email = form.valueOf(AuthFormField.email); + final password = form.valueOf(AuthFormField.password); + + if (email.isNullOrEmpty || password.isNullOrEmpty) { + emit( + SignInState( + form: form, + errorMessage: 'An error occured while retrieving data from the form.', + status: FormStatus.submissionFailure, + ), + ); + } + + final result = await authenticationRepository.signInWithEmailAndPassword( + email: email!, + password: password!, + ); + + // Here custom code + final callbackResponse = await onSignInWithEmailAndPassword(result, form); + if (callbackResponse.isErr) { + final error = callbackResponse.err!; + emit( + SignInState( + form: form, + errorMessage: error.message, + status: FormStatus.submissionFailure, + ), + ); + } + + emit( + result.fold( + (value) => + SignInState(form: form, status: FormStatus.submissionSuccess), + (error) => SignInState( + form: form, + errorMessage: error.message, + status: FormStatus.submissionFailure, + ), + ), + ); + } +} diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_with_google.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_with_google.dart new file mode 100644 index 00000000..b625534a --- /dev/null +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_with_google.dart @@ -0,0 +1,65 @@ +// Copyright (C) 2022 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +import 'dart:async'; + +import 'package:wyatt_architecture/wyatt_architecture.dart'; +import 'package:wyatt_authentication_bloc/src/domain/entities/account.dart'; +import 'package:wyatt_authentication_bloc/src/features/sign_in/cubit/sign_in_cubit.dart'; +import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; +import 'package:wyatt_type_utils/wyatt_type_utils.dart'; + +mixin SignInWithGoogle on BaseSignInCubit { + FutureOrResult onSignInWithGoogle( + Result result, + WyattForm form, + ); + + FutureOr signInWithGoogle() async { + if (state.status.isSubmissionInProgress) { + return; + } + final form = formRepository.accessForm(formName); + emit(SignInState(form: form, status: FormStatus.submissionInProgress)); + + final result = await authenticationRepository.signInWithGoogle(); + + // Here custom code + final callbackResponse = await onSignInWithGoogle(result, form); + if (callbackResponse.isErr) { + final error = callbackResponse.err!; + emit( + SignInState( + form: form, + errorMessage: error.message, + status: FormStatus.submissionFailure, + ), + ); + } + + emit( + result.fold( + (value) => + SignInState(form: form, status: FormStatus.submissionSuccess), + (error) => SignInState( + form: form, + errorMessage: error.message, + status: FormStatus.submissionFailure, + ), + ), + ); + } +} diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/sign_in_cubit.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/sign_in_cubit.dart index 5c7e460c..3d171f9d 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/sign_in_cubit.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/sign_in_cubit.dart @@ -14,213 +14,45 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . + import 'dart:async'; +import 'package:wyatt_architecture/wyatt_architecture.dart'; +import 'package:wyatt_authentication_bloc/src/features/sign_in/cubit/mixin/sign_in_anonymously.dart'; +import 'package:wyatt_authentication_bloc/src/features/sign_in/cubit/mixin/sign_in_with_email_password.dart'; +import 'package:wyatt_authentication_bloc/src/features/sign_in/cubit/mixin/sign_in_with_google.dart'; import 'package:wyatt_authentication_bloc/wyatt_authentication_bloc.dart'; import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; import 'package:wyatt_type_utils/wyatt_type_utils.dart'; +part 'base_sign_in_cubit.dart'; part 'sign_in_state.dart'; -class SignInCubit extends FormDataCubit { - SignInCubit({ - required this.authenticationRepository, - }) : super( - SignInState( - form: authenticationRepository.formRepository - .accessForm(AuthFormName.signInForm), - ), - ); - final AuthenticationRepository authenticationRepository; - FormRepository get formRepository => authenticationRepository.formRepository; +class SignInCubit extends BaseSignInCubit + with + SignInAnonymously, + SignInWithEmailPassword, + SignInWithGoogle { + SignInCubit({required super.authenticationRepository}); @override - String get formName => AuthFormName.signInForm; - - void emailChanged(String value) { - final emailValidatorType = formRepository - .accessForm(formName) - .validatorOf(AuthFormField.email) - .runtimeType; - assert( - emailValidatorType == Email, - 'Use emailCustomChanged(...) with validator $emailValidatorType', - ); - - final Email email = Email.dirty(value); - dataChanged(AuthFormField.email, email); - } - - void passwordChanged(String value) { - final passwordValidatorType = formRepository - .accessForm(formName) - .validatorOf(AuthFormField.password) - .runtimeType; - assert( - passwordValidatorType == Password, - 'Use passwordCustomChanged(...) with validator $passwordValidatorType', - ); - final Password password = Password.dirty(value); - dataChanged(AuthFormField.password, password); - } - - /// Same as [emailChanged] but with a custom [Validator]. - /// - /// Sort of short hand for [dataChanged]. - void emailCustomChanged< - Validator extends FormInputValidator>( - Validator validator, - ) { - dataChanged(AuthFormField.email, validator); - } - - /// Same as [passwordChanged] but with a custom [Validator]. - /// - /// Sort of short hand for [dataChanged]. - void passwordCustomChanged< - Validator extends FormInputValidator>( - Validator validator, - ) { - dataChanged(AuthFormField.password, validator); - } + FutureOrResult onSignInAnonymously( + Result result, + WyattForm form, + ) => + const Ok(null); @override - FutureOr dataChanged( - String key, - FormInputValidator dirtyValue, - ) { - final form = formRepository.accessForm(formName).clone(); - - try { - form.updateValidator(key, dirtyValue); - formRepository.updateForm(form); - } catch (e) { - rethrow; - } - - emit( - state.copyWith(form: form, status: form.validate()), - ); - } + FutureOrResult onSignInWithEmailAndPassword( + Result result, + WyattForm form, + ) => + const Ok(null); @override - FutureOr reset() { - final form = state.form.reset(); - formRepository.updateForm(form); - emit( - state.copyWith(form: form, status: form.validate()), - ); - } - - @override - FutureOr submit() async { - throw UnimplementedError('`submit()` is not implemented for SignInCubit, ' - 'please use `signInWithEmailAndPassword()` or `signInAnonymously()`'); - } - - @override - FutureOr update( - WyattForm form, { - SetOperation operation = SetOperation.replace, - }) { - final WyattForm current = formRepository.accessForm(formName).clone(); - final WyattForm newForm = operation.operation.call(current, form); - formRepository.updateForm(newForm); - - emit( - state.copyWith( - form: newForm, - status: newForm.validate(), - ), - ); - } - - @override - FutureOr validate() { - emit( - state.copyWith( - status: formRepository.accessForm(formName).validate(), - ), - ); - } - - FutureOr signInWithEmailAndPassword() async { - if (state.status.isSubmissionInProgress) { - return; - } - - if (!state.status.isValidated) { - return; - } - - emit(state.copyWith(status: FormStatus.submissionInProgress)); - - final form = formRepository.accessForm(formName); - final email = form.valueOf(AuthFormField.email); - final password = form.valueOf(AuthFormField.password); - - if (email.isNullOrEmpty || password.isNullOrEmpty) { - emit( - state.copyWith( - errorMessage: 'An error occured while retrieving data from the form.', - status: FormStatus.submissionFailure, - ), - ); - } - - final uid = await authenticationRepository.signInWithEmailAndPassword( - email: email!, - password: password!, - ); - - emit( - uid.fold( - (value) => state.copyWith(status: FormStatus.submissionSuccess), - (error) => state.copyWith( - errorMessage: error.message, - status: FormStatus.submissionFailure, - ), - ), - ); - } - - FutureOr signInAnonymously() async { - if (state.status.isSubmissionInProgress) { - return; - } - - emit(state.copyWith(status: FormStatus.submissionInProgress)); - - final uid = await authenticationRepository.signInAnonymously(); - - emit( - uid.fold( - (value) => state.copyWith(status: FormStatus.submissionSuccess), - (error) => state.copyWith( - errorMessage: error.message, - status: FormStatus.submissionFailure, - ), - ), - ); - } - - FutureOr signInWithGoogle() async { - if (state.status.isSubmissionInProgress) { - return; - } - // TODO(wyatt): maybe emit new state (to not carry an old errorMessage) - emit(state.copyWith(status: FormStatus.submissionInProgress)); - - final uid = await authenticationRepository.signInWithGoogle(); - - emit( - uid.fold( - (value) => state.copyWith(status: FormStatus.submissionSuccess), - (error) => state.copyWith( - errorMessage: error.message, - status: FormStatus.submissionFailure, - ), - ), - ); - } + FutureOrResult onSignInWithGoogle( + Result result, + WyattForm form, + ) => + const Ok(null); } diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/base_sign_up_cubit.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/base_sign_up_cubit.dart new file mode 100644 index 00000000..9aaad484 --- /dev/null +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/base_sign_up_cubit.dart @@ -0,0 +1,101 @@ +// Copyright (C) 2022 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +part of 'sign_up_cubit.dart'; + +abstract class BaseSignUpCubit extends FormDataCubit { + BaseSignUpCubit({ + required this.authenticationRepository, + }) : super( + SignUpState( + form: authenticationRepository.formRepository + .accessForm(AuthFormName.signUpForm), + ), + ); + final AuthenticationRepository authenticationRepository; + FormRepository get formRepository => authenticationRepository.formRepository; + + @override + String get formName => AuthFormName.signUpForm; + + @override + FutureOr dataChanged( + String key, + FormInputValidator dirtyValue, + ) { + final form = formRepository.accessForm(formName).clone(); + + try { + form.updateValidator(key, dirtyValue); + formRepository.updateForm(form); + } catch (e) { + rethrow; + } + + emit( + SignUpState(form: form, status: form.validate()), + ); + } + + @override + FutureOr reset() { + final form = state.form.reset(); + formRepository.updateForm(form); + emit( + SignUpState(form: form, status: form.validate()), + ); + } + + @override + FutureOr update( + WyattForm form, { + SetOperation operation = SetOperation.replace, + }) { + final WyattForm current = formRepository.accessForm(formName).clone(); + final WyattForm newForm = operation.operation.call(current, form); + formRepository.updateForm(newForm); + + emit( + SignUpState( + form: newForm, + status: newForm.validate(), + ), + ); + } + + @override + FutureOr validate() { + final WyattForm form = formRepository.accessForm(formName); + emit( + SignUpState(form: form, status: form.validate()), + ); + } + + @override + FutureOr submit() async { + final WyattForm form = formRepository.accessForm(formName); + const error = '`submit()` is not implemented for BaseSignUpCubit, ' + 'please use `signUpWithEmailAndPassword()`.'; + emit( + SignUpState( + form: form, + errorMessage: error, + status: FormStatus.submissionFailure, + ), + ); + throw UnimplementedError(error); + } +} diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/mixin/sign_up_with_email_password.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/mixin/sign_up_with_email_password.dart new file mode 100644 index 00000000..6952a01c --- /dev/null +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/mixin/sign_up_with_email_password.dart @@ -0,0 +1,137 @@ +// Copyright (C) 2022 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +import 'dart:async'; + +import 'package:wyatt_architecture/wyatt_architecture.dart'; +import 'package:wyatt_authentication_bloc/src/core/constants/form_field.dart'; +import 'package:wyatt_authentication_bloc/src/domain/entities/account.dart'; +import 'package:wyatt_authentication_bloc/src/features/sign_up/cubit/sign_up_cubit.dart'; +import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; +import 'package:wyatt_type_utils/wyatt_type_utils.dart'; + +mixin SignUpWithEmailPassword on BaseSignUpCubit { + FutureOrResult onSignUpWithEmailAndPassword( + Result result, + WyattForm form, + ); + + void emailChanged(String value) { + final emailValidatorType = formRepository + .accessForm(formName) + .validatorOf(AuthFormField.email) + .runtimeType; + assert( + emailValidatorType == Email, + 'Use emailCustomChanged(...) with validator $emailValidatorType', + ); + + final Email email = Email.dirty(value); + dataChanged(AuthFormField.email, email); + } + + void passwordChanged(String value) { + final passwordValidatorType = formRepository + .accessForm(formName) + .validatorOf(AuthFormField.password) + .runtimeType; + assert( + passwordValidatorType == Password, + 'Use passwordCustomChanged(...) with validator $passwordValidatorType', + ); + final Password password = Password.dirty(value); + dataChanged(AuthFormField.password, password); + } + + /// Same as [emailChanged] but with a custom [Validator]. + /// + /// Sort of short hand for [dataChanged]. + void emailCustomChanged< + Validator extends FormInputValidator>( + Validator validator, + ) { + dataChanged(AuthFormField.email, validator); + } + + /// Same as [passwordChanged] but with a custom [Validator]. + /// + /// Sort of short hand for [dataChanged]. + void passwordCustomChanged< + Validator extends FormInputValidator>( + Validator validator, + ) { + dataChanged(AuthFormField.password, validator); + } + + FutureOr signUpWithEmailPassword() async { + if (!state.status.isValidated) { + return; + } + + final form = formRepository.accessForm(formName); + emit(SignUpState(form: form, status: FormStatus.submissionInProgress)); + + final email = form.valueOf(AuthFormField.email); + final password = form.valueOf(AuthFormField.password); + + if (email.isNullOrEmpty || password.isNullOrEmpty) { + emit( + SignUpState( + form: form, + errorMessage: 'An error occured while retrieving data from the form.', + status: FormStatus.submissionFailure, + ), + ); + } + + final result = await authenticationRepository.signUp( + email: email!, + password: password!, + ); + + // Here custom code on sign up + final callbackResponse = await onSignUpWithEmailAndPassword(result, form); + if (callbackResponse.isErr) { + final error = callbackResponse.err!; + emit( + SignUpState( + form: form, + errorMessage: error.message, + status: FormStatus.submissionFailure, + ), + ); + } + + await authenticationRepository.signInWithEmailAndPassword( + email: email, + password: password, + ); + + emit( + result.fold( + (value) => SignUpState( + form: form, + status: FormStatus.submissionSuccess, + ), + (error) => SignUpState( + form: form, + errorMessage: error.message, + status: FormStatus.submissionFailure, + ), + ), + ); + } +} diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/sign_up_cubit.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/sign_up_cubit.dart index 8d41b000..df2766ac 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/sign_up_cubit.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/sign_up_cubit.dart @@ -16,164 +16,26 @@ import 'dart:async'; +import 'package:wyatt_architecture/wyatt_architecture.dart'; import 'package:wyatt_authentication_bloc/src/core/constants/form_field.dart'; import 'package:wyatt_authentication_bloc/src/core/constants/form_name.dart'; +import 'package:wyatt_authentication_bloc/src/domain/entities/account.dart'; import 'package:wyatt_authentication_bloc/src/domain/repositories/authentication_repository.dart'; +import 'package:wyatt_authentication_bloc/src/features/sign_up/cubit/mixin/sign_up_with_email_password.dart'; import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; import 'package:wyatt_type_utils/wyatt_type_utils.dart'; +part 'base_sign_up_cubit.dart'; part 'sign_up_state.dart'; -class SignUpCubit extends FormDataCubit { - SignUpCubit({ - required this.authenticationRepository, - }) : super( - SignUpState( - form: authenticationRepository.formRepository - .accessForm(AuthFormName.signUpForm), - ), - ); - final AuthenticationRepository authenticationRepository; - FormRepository get formRepository => authenticationRepository.formRepository; +class SignUpCubit extends BaseSignUpCubit + with SignUpWithEmailPassword { + SignUpCubit({required super.authenticationRepository}); @override - String get formName => AuthFormName.signUpForm; - - void emailChanged(String value) { - final emailValidatorType = formRepository - .accessForm(formName) - .validatorOf(AuthFormField.email) - .runtimeType; - assert( - emailValidatorType == Email, - 'Use emailCustomChanged(...) with validator $emailValidatorType', - ); - - final Email email = Email.dirty(value); - dataChanged(AuthFormField.email, email); - } - - void passwordChanged(String value) { - final passwordValidatorType = formRepository - .accessForm(formName) - .validatorOf(AuthFormField.password) - .runtimeType; - assert( - passwordValidatorType == Password, - 'Use passwordCustomChanged(...) with validator $passwordValidatorType', - ); - final Password password = Password.dirty(value); - dataChanged(AuthFormField.password, password); - } - - /// Same as [emailChanged] but with a custom [Validator]. - /// - /// Sort of short hand for [dataChanged]. - void emailCustomChanged< - Validator extends FormInputValidator>( - Validator validator, - ) { - dataChanged(AuthFormField.email, validator); - } - - /// Same as [passwordChanged] but with a custom [Validator]. - /// - /// Sort of short hand for [dataChanged]. - void passwordCustomChanged< - Validator extends FormInputValidator>( - Validator validator, - ) { - dataChanged(AuthFormField.password, validator); - } - - @override - FutureOr dataChanged( - String key, - FormInputValidator dirtyValue, - ) { - final form = formRepository.accessForm(formName).clone(); - - try { - form.updateValidator(key, dirtyValue); - formRepository.updateForm(form); - } catch (e) { - rethrow; - } - - emit( - state.copyWith(form: form, status: form.validate()), - ); - } - - @override - FutureOr reset() { - final form = state.form.reset(); - formRepository.updateForm(form); - emit( - state.copyWith(form: form, status: form.validate()), - ); - } - - @override - FutureOr submit() async { - if (!state.status.isValidated) { - return; - } - - emit(state.copyWith(status: FormStatus.submissionInProgress)); - - final form = formRepository.accessForm(formName); - final email = form.valueOf(AuthFormField.email); - final password = form.valueOf(AuthFormField.password); - - if (email.isNullOrEmpty || password.isNullOrEmpty) { - emit( - state.copyWith( - errorMessage: 'An error occured while retrieving data from the form.', - status: FormStatus.submissionFailure, - ), - ); - } - - final uid = await authenticationRepository.signUp( - email: email!, - password: password!, - ); - - emit( - uid.fold( - (value) => state.copyWith(status: FormStatus.submissionSuccess), - (error) => state.copyWith( - errorMessage: error.message, - status: FormStatus.submissionFailure, - ), - ), - ); - } - - @override - FutureOr update( - WyattForm form, { - SetOperation operation = SetOperation.replace, - }) { - final WyattForm current = formRepository.accessForm(formName).clone(); - final WyattForm newForm = operation.operation.call(current, form); - formRepository.updateForm(newForm); - - emit( - state.copyWith( - form: newForm, - status: newForm.validate(), - ), - ); - } - - @override - FutureOr validate() { - emit( - state.copyWith( - status: formRepository.accessForm(formName).validate(), - ), - ); - } + FutureOrResult onSignUpWithEmailAndPassword( + Result result, + WyattForm form, + ) => + const Ok(null); } diff --git a/packages/wyatt_authentication_bloc/lib/wyatt_authentication_bloc.dart b/packages/wyatt_authentication_bloc/lib/wyatt_authentication_bloc.dart index a010cfa4..d853a49b 100644 --- a/packages/wyatt_authentication_bloc/lib/wyatt_authentication_bloc.dart +++ b/packages/wyatt_authentication_bloc/lib/wyatt_authentication_bloc.dart @@ -17,7 +17,9 @@ /// An authentication library for BLoC. library wyatt_authentication_bloc; +/// {@nodoc} export 'package:firebase_auth/firebase_auth.dart'; +/// {@nodoc} export 'package:google_sign_in/google_sign_in.dart'; export 'src/src.dart'; -- 2.47.2 From 828c1ace6f25c3db437db7df2fb4dc69ae6599a5 Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Thu, 29 Dec 2022 17:04:57 +0100 Subject: [PATCH 06/47] docs(authentication): update example --- .../example/.firebaserc | 5 ++ .../example/firebase.json | 13 ++++++ .../example/ios/firebase_app_id_file.json | 6 +-- .../example/lib/bootstrap.dart | 2 + .../lib/core/dependency_injection/get_it.dart | 1 + .../example/lib/firebase_options.dart | 31 +++++++------ .../lib/presentation/features/app/app.dart | 34 +++++--------- .../sign_up/blocs/custom_sign_up_cubit.dart | 46 +++++++++++++++++++ .../sign_up/widgets/sign_up_form.dart | 2 +- 9 files changed, 101 insertions(+), 39 deletions(-) create mode 100644 packages/wyatt_authentication_bloc/example/.firebaserc create mode 100644 packages/wyatt_authentication_bloc/example/firebase.json create mode 100644 packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_up/blocs/custom_sign_up_cubit.dart diff --git a/packages/wyatt_authentication_bloc/example/.firebaserc b/packages/wyatt_authentication_bloc/example/.firebaserc new file mode 100644 index 00000000..54e8fe84 --- /dev/null +++ b/packages/wyatt_authentication_bloc/example/.firebaserc @@ -0,0 +1,5 @@ +{ + "projects": { + "default": "tchat-beta" + } +} diff --git a/packages/wyatt_authentication_bloc/example/firebase.json b/packages/wyatt_authentication_bloc/example/firebase.json new file mode 100644 index 00000000..cdcf8e18 --- /dev/null +++ b/packages/wyatt_authentication_bloc/example/firebase.json @@ -0,0 +1,13 @@ +{ + "emulators": { + "auth": { + "port": 9099 + }, + "firestore": { + "port": 8080 + }, + "ui": { + "enabled": true + } + } +} diff --git a/packages/wyatt_authentication_bloc/example/ios/firebase_app_id_file.json b/packages/wyatt_authentication_bloc/example/ios/firebase_app_id_file.json index 2a145385..17445d1d 100644 --- a/packages/wyatt_authentication_bloc/example/ios/firebase_app_id_file.json +++ b/packages/wyatt_authentication_bloc/example/ios/firebase_app_id_file.json @@ -1,7 +1,7 @@ { "file_generated_by": "FlutterFire CLI", "purpose": "FirebaseAppID & ProjectID for this Firebase app in this directory", - "GOOGLE_APP_ID": "1:405351917235:ios:869f0ad8ace08db899f2c6", - "FIREBASE_PROJECT_ID": "meerabel-dev", - "GCM_SENDER_ID": "405351917235" + "GOOGLE_APP_ID": "1:136771801992:ios:bcdca68d2b7d227097203d", + "FIREBASE_PROJECT_ID": "tchat-beta", + "GCM_SENDER_ID": "136771801992" } \ No newline at end of file diff --git a/packages/wyatt_authentication_bloc/example/lib/bootstrap.dart b/packages/wyatt_authentication_bloc/example/lib/bootstrap.dart index 0f64001a..8cf305fd 100644 --- a/packages/wyatt_authentication_bloc/example/lib/bootstrap.dart +++ b/packages/wyatt_authentication_bloc/example/lib/bootstrap.dart @@ -22,6 +22,7 @@ import 'package:example_router/firebase_options.dart'; import 'package:firebase_core/firebase_core.dart'; import 'package:flutter/widgets.dart'; import 'package:flutter_bloc/flutter_bloc.dart'; +import 'package:wyatt_authentication_bloc/wyatt_authentication_bloc.dart'; class MockSettings { static MockSettings? _instance; @@ -73,6 +74,7 @@ Future bootstrap(FutureOr Function() builder) async { await Firebase.initializeApp( options: DefaultFirebaseOptions.currentPlatform, ); + await FirebaseAuth.instance.useAuthEmulator('localhost', 9099); } await GetItInitializer.init(); diff --git a/packages/wyatt_authentication_bloc/example/lib/core/dependency_injection/get_it.dart b/packages/wyatt_authentication_bloc/example/lib/core/dependency_injection/get_it.dart index d1cb33ab..2528fa87 100644 --- a/packages/wyatt_authentication_bloc/example/lib/core/dependency_injection/get_it.dart +++ b/packages/wyatt_authentication_bloc/example/lib/core/dependency_injection/get_it.dart @@ -50,6 +50,7 @@ abstract class GetItInitializer { ), ]) : () => AuthenticationFirebaseDataSourceImpl( + firebaseAuth: FirebaseAuth.instance, googleSignIn: GoogleSignIn( clientId: DefaultFirebaseOptions.ios.iosClientId)), ) diff --git a/packages/wyatt_authentication_bloc/example/lib/firebase_options.dart b/packages/wyatt_authentication_bloc/example/lib/firebase_options.dart index 10987933..dcf7c17e 100644 --- a/packages/wyatt_authentication_bloc/example/lib/firebase_options.dart +++ b/packages/wyatt_authentication_bloc/example/lib/firebase_options.dart @@ -24,10 +24,7 @@ class DefaultFirebaseOptions { } switch (defaultTargetPlatform) { case TargetPlatform.android: - throw UnsupportedError( - 'DefaultFirebaseOptions have not been configured for android - ' - 'you can reconfigure this by running the FlutterFire CLI again.', - ); + return android; case TargetPlatform.iOS: return ios; case TargetPlatform.macOS: @@ -52,16 +49,24 @@ class DefaultFirebaseOptions { } } + static const FirebaseOptions android = FirebaseOptions( + apiKey: 'AIzaSyAYS14uXupkS158Q5QAFP1864UrUN_yDSk', + appId: '1:136771801992:android:ac3cfeb99fb0763e97203d', + messagingSenderId: '136771801992', + projectId: 'tchat-beta', + databaseURL: 'https://tchat-beta.firebaseio.com', + storageBucket: 'tchat-beta.appspot.com', + ); + static const FirebaseOptions ios = FirebaseOptions( - apiKey: 'AIzaSyDDmtf0KN7Xw12_pqUsxoBfAxMuvCMmMmk', - appId: '1:405351917235:ios:869f0ad8ace08db899f2c6', - messagingSenderId: '405351917235', - projectId: 'meerabel-dev', - storageBucket: 'meerabel-dev.appspot.com', - androidClientId: - '405351917235-4g1dh3475tq6t1sa2qoh7ol60nf4ta05.apps.googleusercontent.com', - iosClientId: - '405351917235-2jv4ff02kovoim58f8d6d0rsa14apgkj.apps.googleusercontent.com', + apiKey: 'AIzaSyCDbbhjbFrQwLXuIANdJzjkDk8uOETnn7w', + appId: '1:136771801992:ios:bcdca68d2b7d227097203d', + messagingSenderId: '136771801992', + projectId: 'tchat-beta', + databaseURL: 'https://tchat-beta.firebaseio.com', + storageBucket: 'tchat-beta.appspot.com', + androidClientId: '136771801992-n2pq8oqutvrqj58e05hbavvc7n1jdfjb.apps.googleusercontent.com', + iosClientId: '136771801992-p629tpo9bk3hcm2955s5ahivdla57ln9.apps.googleusercontent.com', iosBundleId: 'com.example.exampleRouter', ); } diff --git a/packages/wyatt_authentication_bloc/example/lib/presentation/features/app/app.dart b/packages/wyatt_authentication_bloc/example/lib/presentation/features/app/app.dart index 99d1d999..db27b90e 100644 --- a/packages/wyatt_authentication_bloc/example/lib/presentation/features/app/app.dart +++ b/packages/wyatt_authentication_bloc/example/lib/presentation/features/app/app.dart @@ -22,6 +22,7 @@ import 'package:example_router/core/dependency_injection/get_it.dart'; import 'package:example_router/core/routes/router.dart'; import 'package:example_router/core/utils/custom_password.dart'; import 'package:example_router/core/utils/forms.dart'; +import 'package:example_router/presentation/features/sign_up/blocs/custom_sign_up_cubit.dart'; import 'package:flutter/material.dart'; import 'package:flutter_bloc/flutter_bloc.dart'; import 'package:go_router/go_router.dart'; @@ -30,30 +31,20 @@ import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; import 'package:wyatt_type_utils/wyatt_type_utils.dart'; import 'package:wyatt_architecture/wyatt_architecture.dart'; -FutureOrResult onSignUpSuccess( - AuthenticationRepository repo, - Account? account, - WyattForm form, -) async { - const id = -1; - final confirmedPassword = - form.valueOf(AppFormField.confirmedPassword); - - debugPrint( - 'onSignUpSuccess: $account, generatedId: $id, extraFormData: $confirmedPassword'); - return const Ok(id); -} - FutureOrResult onAccountChanges( AuthenticationRepository repo, - Account? account, + AuthChangeEvent? authEvent, ) async { - final id = Random().nextInt(1000); - final token = - await repo.getIdentityToken().fold((value) => value, (error) => 'null'); + if (authEvent is SignInAuthChangeEvent || authEvent is RefreshAuthChangeEvent) { + final id = Random().nextInt(1000); + final token = + await repo.getIdentityToken().fold((value) => value, (error) => 'null'); - debugPrint('onAccountChanges: $account, token: $token, generatedId: $id'); - return Ok(id); + debugPrint('onAccountChanges: ${authEvent?.account}, type: ${authEvent.runtimeType}, token: $token, generatedId: $id'); + return Ok(id); + } else { + return Err(ClientException('Not supported auth change logic')); + } } class App extends StatelessWidget { @@ -61,7 +52,6 @@ class App extends StatelessWidget { AuthenticationRepositoryImpl( authenticationCacheDataSource: getIt>(), authenticationRemoteDataSource: getIt(), - onSignUpSuccess: onSignUpSuccess, onAuthChange: onAccountChanges, customPasswordValidator: const CustomPassword.pure(), extraSignUpInputs: [ @@ -127,7 +117,7 @@ class App extends StatelessWidget { value: authenticationCubit, ), BlocProvider>( - create: (_) => SignUpCubit( + create: (_) => CustomSignUpCubit( authenticationRepository: authenticationRepository, ), ), diff --git a/packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_up/blocs/custom_sign_up_cubit.dart b/packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_up/blocs/custom_sign_up_cubit.dart new file mode 100644 index 00000000..7e5f1e6d --- /dev/null +++ b/packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_up/blocs/custom_sign_up_cubit.dart @@ -0,0 +1,46 @@ +// Copyright (C) 2022 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +import 'dart:async'; + +import 'package:example_router/core/constants/form_field.dart'; +import 'package:flutter/foundation.dart'; +import 'package:wyatt_architecture/wyatt_architecture.dart'; +import 'package:wyatt_authentication_bloc/wyatt_authentication_bloc.dart'; +import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; +import 'package:wyatt_type_utils/wyatt_type_utils.dart'; + +class CustomSignUpCubit extends SignUpCubit{ + CustomSignUpCubit({ + required super.authenticationRepository, + }); + + @override + FutureOrResult onSignUpWithEmailAndPassword( + Result result, WyattForm form) async { + if (result.isOk) { + await Future.delayed(const Duration(seconds: 3)); + const id = -1; + final confirmedPassword = + form.valueOf(AppFormField.confirmedPassword); + + debugPrint( + 'onSignUpSuccess: ${result.ok}, generatedId: $id, intFormData: $confirmedPassword'); + return const Ok(id); + } + return const Ok(null); + } +} diff --git a/packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_up/widgets/sign_up_form.dart b/packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_up/widgets/sign_up_form.dart index bb3ebceb..a4f44a48 100644 --- a/packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_up/widgets/sign_up_form.dart +++ b/packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_up/widgets/sign_up_form.dart @@ -106,7 +106,7 @@ class _SignUpButton extends StatelessWidget { return status.isSubmissionInProgress ? const CircularProgressIndicator() : ElevatedButton( - onPressed: status.isValidated ? () => cubit.submit() : null, + onPressed: status.isValidated ? () => cubit.signUpWithEmailPassword() : null, child: const Text('Sign up'), ); }), -- 2.47.2 From 13fc4aa875ca6af657d37b54948adf335fc17511 Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Thu, 29 Dec 2022 17:38:37 +0100 Subject: [PATCH 07/47] fix(authentication): initialize account stream transformer --- .../authentication_repository_impl.dart | 26 +++++++++---------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/packages/wyatt_authentication_bloc/lib/src/data/repositories/authentication_repository_impl.dart b/packages/wyatt_authentication_bloc/lib/src/data/repositories/authentication_repository_impl.dart index 67648935..d5514589 100644 --- a/packages/wyatt_authentication_bloc/lib/src/data/repositories/authentication_repository_impl.dart +++ b/packages/wyatt_authentication_bloc/lib/src/data/repositories/authentication_repository_impl.dart @@ -44,6 +44,19 @@ class AuthenticationRepositoryImpl }) : _authChangeListener = onAuthChange, _accountStreamTransformer = accountStreamTransformer { _formRepository = formRepository ?? FormRepositoryImpl(); + _accountStreamTransformer ??= (input) => input + .where((event) => event is! SignUpAuthChangeEvent) + .map>>((event) async { + if (listener == null) { + return Ok(AccountWrapperModel(event.account, null)); + } + // Handle sign in, sign out and refresh + final dataResult = await listener!.call(this, event); + return dataResult.map((data) { + authenticationCacheDataSource.storeData(data); + return AccountWrapperModel(event.account, data); + }); + }); if (formRepository != null) { return; } @@ -90,19 +103,6 @@ class AuthenticationRepositoryImpl name: AuthFormName.passwordResetForm, ), ); - _accountStreamTransformer ??= (input) => input - .where((event) => event is! SignUpAuthChangeEvent) - .map>>((event) async { - if (listener == null) { - return Ok(AccountWrapperModel(event.account, null)); - } - // Handle sign in, sign out and refresh - final dataResult = await listener!.call(this, event); - return dataResult.map((data) { - authenticationCacheDataSource.storeData(data); - return AccountWrapperModel(event.account, data); - }); - }); } final AuthenticationCacheDataSource authenticationCacheDataSource; final AuthenticationRemoteDataSource authenticationRemoteDataSource; -- 2.47.2 From 6779a8b650f5a0eb9ad391947f7e1c7719ef9fda Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Fri, 30 Dec 2022 16:15:34 +0100 Subject: [PATCH 08/47] refactor(authentication): use custom user changes stream --- ...hentication_firebase_data_source_impl.dart | 76 ++++++++++++------- .../data/models/account_model_firebase.dart | 35 +++++++-- 2 files changed, 77 insertions(+), 34 deletions(-) diff --git a/packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/authentication_firebase_data_source_impl.dart b/packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/authentication_firebase_data_source_impl.dart index a0344195..5bc23a2d 100644 --- a/packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/authentication_firebase_data_source_impl.dart +++ b/packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/authentication_firebase_data_source_impl.dart @@ -14,6 +14,9 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . +import 'dart:async'; + +import 'package:rxdart/subjects.dart'; import 'package:wyatt_authentication_bloc/src/data/models/account_model_firebase.dart'; import 'package:wyatt_authentication_bloc/wyatt_authentication_bloc.dart'; import 'package:wyatt_type_utils/wyatt_type_utils.dart'; @@ -24,7 +27,17 @@ class AuthenticationFirebaseDataSourceImpl FirebaseAuth? firebaseAuth, GoogleSignIn? googleSignIn, }) : _firebaseAuth = firebaseAuth ?? FirebaseAuth.instance, - _googleSignIn = googleSignIn ?? GoogleSignIn(); + _googleSignIn = googleSignIn ?? GoogleSignIn() { + // _accountStream = StreamController(); + _accountStream = BehaviorSubject(); + // Check for account in memory (persistence) + final currentAccount = (_firebaseAuth.currentUser != null) + ? AccountModelFirebase.fromFirebaseUser(_firebaseAuth.currentUser) + : null; + _accountStream.add(currentAccount); + } + + late StreamController _accountStream; final FirebaseAuth _firebaseAuth; final GoogleSignIn _googleSignIn; @@ -41,8 +54,10 @@ class AuthenticationFirebaseDataSourceImpl password: password, ); _latestCreds = userCredential; - final user = userCredential.user; - return AccountModelFirebase.fromFirebaseUser(user); + final account = + AccountModelFirebase.fromFirebaseUserCredential(userCredential); + _accountStream.add(account); + return account; } on FirebaseAuthException catch (e) { throw SignInWithEmailAndPasswordFailureFirebase.fromCode(e.code); } catch (_) { @@ -50,9 +65,8 @@ class AuthenticationFirebaseDataSourceImpl } } - @override - /// {@macro signup} + @override Future signUp({ required String email, required String password, @@ -63,8 +77,10 @@ class AuthenticationFirebaseDataSourceImpl password: password, ); _latestCreds = userCredential; - final user = userCredential.user; - return AccountModelFirebase.fromFirebaseUser(user); + final account = + AccountModelFirebase.fromFirebaseUserCredential(userCredential); + _accountStream.add(account); + return account; } on FirebaseAuthException catch (e) { throw SignUpWithEmailAndPasswordFailureFirebase.fromCode(e.code); } catch (_) { @@ -77,6 +93,7 @@ class AuthenticationFirebaseDataSourceImpl try { _latestCreds = null; await _firebaseAuth.signOut(); + _accountStream.add(null); } catch (_) { throw SignOutFailureFirebase(); } @@ -99,17 +116,7 @@ class AuthenticationFirebaseDataSourceImpl } @override - Stream streamAccount() => - _firebaseAuth.userChanges().map((user) { - if (user.isNull) { - return null; - } - try { - return AccountModelFirebase.fromFirebaseUser(user); - } on Exception { - return null; - } - }); + Stream streamAccount() => _accountStream.stream.asBroadcastStream(); @override Future confirmPasswordReset({ @@ -155,8 +162,10 @@ class AuthenticationFirebaseDataSourceImpl try { final userCredential = await _firebaseAuth.signInAnonymously(); _latestCreds = userCredential; - final user = userCredential.user; - return AccountModelFirebase.fromFirebaseUser(user); + final account = + AccountModelFirebase.fromFirebaseUserCredential(userCredential); + _accountStream.add(account); + return account; } on FirebaseAuthException catch (e) { throw SignInAnonymouslyFailureFirebase.fromCode(e.code); } catch (_) { @@ -184,8 +193,10 @@ class AuthenticationFirebaseDataSourceImpl await _firebaseAuth.signInWithCredential(credential); _latestCreds = userCredential; - final user = userCredential.user; - return AccountModelFirebase.fromFirebaseUser(user); + final account = + AccountModelFirebase.fromFirebaseUserCredential(userCredential); + _accountStream.add(account); + return account; } on FirebaseAuthException catch (e) { throw SignInWithGoogleFailureFirebase.fromCode(e.code); } catch (_) { @@ -209,6 +220,9 @@ class AuthenticationFirebaseDataSourceImpl Future refresh() async { try { await _firebaseAuth.currentUser!.reload(); + final account = + AccountModelFirebase.fromFirebaseUser(_firebaseAuth.currentUser); + _accountStream.add(account); } on FirebaseAuthException catch (e) { throw RefreshFailureFirebase.fromCode(e.code); } catch (_) { @@ -225,8 +239,10 @@ class AuthenticationFirebaseDataSourceImpl } else { throw Exception(); // Get caught just after. } - final user = _firebaseAuth.currentUser; - return AccountModelFirebase.fromFirebaseUser(user); + final account = + AccountModelFirebase.fromFirebaseUser(_firebaseAuth.currentUser); + _accountStream.add(account); + return account; } on FirebaseAuthException catch (e) { throw ReauthenticateFailureFirebase.fromCode(e.code); } catch (_) { @@ -238,8 +254,10 @@ class AuthenticationFirebaseDataSourceImpl Future updateEmail({required String email}) async { try { await _firebaseAuth.currentUser!.updateEmail(email); - final user = _firebaseAuth.currentUser; - return AccountModelFirebase.fromFirebaseUser(user); + final account = + AccountModelFirebase.fromFirebaseUser(_firebaseAuth.currentUser); + _accountStream.add(account); + return account; } on FirebaseAuthException catch (e) { throw UpdateEmailFailureFirebase.fromCode(e.code); } catch (_) { @@ -251,8 +269,10 @@ class AuthenticationFirebaseDataSourceImpl Future updatePassword({required String password}) async { try { await _firebaseAuth.currentUser!.updatePassword(password); - final user = _firebaseAuth.currentUser; - return AccountModelFirebase.fromFirebaseUser(user); + final account = + AccountModelFirebase.fromFirebaseUser(_firebaseAuth.currentUser); + _accountStream.add(account); + return account; } on FirebaseAuthException catch (e) { throw UpdatePasswordFailureFirebase.fromCode(e.code); } catch (_) { diff --git a/packages/wyatt_authentication_bloc/lib/src/data/models/account_model_firebase.dart b/packages/wyatt_authentication_bloc/lib/src/data/models/account_model_firebase.dart index d6a70ba5..07e5b5a0 100644 --- a/packages/wyatt_authentication_bloc/lib/src/data/models/account_model_firebase.dart +++ b/packages/wyatt_authentication_bloc/lib/src/data/models/account_model_firebase.dart @@ -15,7 +15,9 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . -import 'package:wyatt_authentication_bloc/wyatt_authentication_bloc.dart'; +import 'package:firebase_auth/firebase_auth.dart'; +import 'package:wyatt_authentication_bloc/src/core/exceptions/exceptions.dart'; +import 'package:wyatt_authentication_bloc/src/data/models/account_model.dart'; class AccountModelFirebase extends AccountModel { AccountModelFirebase._({ @@ -42,16 +44,37 @@ class AccountModelFirebase extends AccountModel { providerId: providerId, creationTime: user.metadata.creationTime, lastSignInTime: user.metadata.lastSignInTime, - isNewUser: (user.metadata.creationTime != null && - user.metadata.lastSignInTime != null) - ? user.metadata.lastSignInTime! == user.metadata.creationTime! - : null, + isNewUser: false, email: user.email, phoneNumber: user.phoneNumber, photoURL: user.photoURL, ); } else { - throw ModelParsingFailureFirebase('null-user', 'User cannot be null!'); + throw ModelParsingFailureFirebase('null-user', 'User cannot be null'); + } + } + + factory AccountModelFirebase.fromFirebaseUserCredential( + UserCredential? userCredential, + ) { + final user = userCredential?.user; + if (user != null) { + final providerId = + (user.providerData.isEmpty) ? '' : user.providerData.first.providerId; + return AccountModelFirebase._( + uid: user.uid, + emailVerified: user.emailVerified, + isAnonymous: user.isAnonymous, + providerId: providerId, + creationTime: user.metadata.creationTime, + lastSignInTime: user.metadata.lastSignInTime, + isNewUser: userCredential?.additionalUserInfo?.isNewUser, + email: user.email, + phoneNumber: user.phoneNumber, + photoURL: user.photoURL, + ); + } else { + throw ModelParsingFailureFirebase('null-user', 'User cannot be null'); } } } -- 2.47.2 From 9ff7b73aeb676121a32d026c39e7e475d2f9c330 Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Fri, 30 Dec 2022 17:03:29 +0100 Subject: [PATCH 09/47] fix(authentication): anonymous sign in event --- .../data/repositories/authentication_repository_impl.dart | 3 +++ .../lib/src/domain/entities/auth_change_event.dart | 8 ++++++++ 2 files changed, 11 insertions(+) diff --git a/packages/wyatt_authentication_bloc/lib/src/data/repositories/authentication_repository_impl.dart b/packages/wyatt_authentication_bloc/lib/src/data/repositories/authentication_repository_impl.dart index d5514589..686be61a 100644 --- a/packages/wyatt_authentication_bloc/lib/src/data/repositories/authentication_repository_impl.dart +++ b/packages/wyatt_authentication_bloc/lib/src/data/repositories/authentication_repository_impl.dart @@ -348,6 +348,9 @@ class AuthenticationRepositoryImpl if (_lastChange == null && account != null) { _lastChange = account; if (account.isNewUser ?? false) { + if (account.isAnonymous) { + return AnonymousSignInAuthChangeEvent(account); + } return SignUpAuthChangeEvent(account); } return SignInAuthChangeEvent(account); diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/entities/auth_change_event.dart b/packages/wyatt_authentication_bloc/lib/src/domain/entities/auth_change_event.dart index 71a311a3..d2e38a33 100644 --- a/packages/wyatt_authentication_bloc/lib/src/domain/entities/auth_change_event.dart +++ b/packages/wyatt_authentication_bloc/lib/src/domain/entities/auth_change_event.dart @@ -26,6 +26,14 @@ class SignInAuthChangeEvent extends AuthChangeEvent { SignInAuthChangeEvent(super.account); } +class AnonymousSignInAuthChangeEvent extends AuthChangeEvent { + AnonymousSignInAuthChangeEvent(super.account); +} + +class ProviderSignInAuthChangeEvent extends AuthChangeEvent { + ProviderSignInAuthChangeEvent(super.account); +} + class SignUpAuthChangeEvent extends AuthChangeEvent { SignUpAuthChangeEvent(super.account); } -- 2.47.2 From 1451240f1a31f0002396a3eb724d3078ecc2a296 Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Fri, 30 Dec 2022 17:03:56 +0100 Subject: [PATCH 10/47] test(authentication): fix tests --- .../lib/presentation/features/app/app.dart | 17 +++++++---------- .../test/sign_in/sign_in_cubit_test.dart | 16 ++++++++-------- .../test/sign_up/sign_up_cubit_test.dart | 17 ++++++++++++----- 3 files changed, 27 insertions(+), 23 deletions(-) diff --git a/packages/wyatt_authentication_bloc/example/lib/presentation/features/app/app.dart b/packages/wyatt_authentication_bloc/example/lib/presentation/features/app/app.dart index db27b90e..9fa89f49 100644 --- a/packages/wyatt_authentication_bloc/example/lib/presentation/features/app/app.dart +++ b/packages/wyatt_authentication_bloc/example/lib/presentation/features/app/app.dart @@ -26,25 +26,22 @@ import 'package:example_router/presentation/features/sign_up/blocs/custom_sign_u import 'package:flutter/material.dart'; import 'package:flutter_bloc/flutter_bloc.dart'; import 'package:go_router/go_router.dart'; +import 'package:wyatt_architecture/wyatt_architecture.dart'; import 'package:wyatt_authentication_bloc/wyatt_authentication_bloc.dart'; import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; import 'package:wyatt_type_utils/wyatt_type_utils.dart'; -import 'package:wyatt_architecture/wyatt_architecture.dart'; FutureOrResult onAccountChanges( AuthenticationRepository repo, AuthChangeEvent? authEvent, ) async { - if (authEvent is SignInAuthChangeEvent || authEvent is RefreshAuthChangeEvent) { - final id = Random().nextInt(1000); - final token = - await repo.getIdentityToken().fold((value) => value, (error) => 'null'); + final id = Random().nextInt(1000); + final token = + await repo.getIdentityToken().fold((value) => value, (error) => 'null'); - debugPrint('onAccountChanges: ${authEvent?.account}, type: ${authEvent.runtimeType}, token: $token, generatedId: $id'); - return Ok(id); - } else { - return Err(ClientException('Not supported auth change logic')); - } + debugPrint( + 'onAccountChanges: ${authEvent?.account}, type: ${authEvent.runtimeType}, token: $token, generatedId: $id'); + return Ok(id); } class App extends StatelessWidget { diff --git a/packages/wyatt_authentication_bloc/test/sign_in/sign_in_cubit_test.dart b/packages/wyatt_authentication_bloc/test/sign_in/sign_in_cubit_test.dart index 622bfb79..466ea3a0 100644 --- a/packages/wyatt_authentication_bloc/test/sign_in/sign_in_cubit_test.dart +++ b/packages/wyatt_authentication_bloc/test/sign_in/sign_in_cubit_test.dart @@ -579,11 +579,11 @@ void main() { [ FormInput( AuthFormField.email, - const Email.dirty(validEmailString), + const Email.pure(), ), FormInput( AuthFormField.password, - const Password.dirty(validPasswordString), + const Password.pure(), ) ], name: AuthFormName.signInForm, @@ -595,11 +595,11 @@ void main() { [ FormInput( AuthFormField.email, - const Email.dirty(validEmailString), + const Email.pure(), ), FormInput( AuthFormField.password, - const Password.dirty(validPasswordString), + const Password.pure(), ) ], name: AuthFormName.signInForm, @@ -643,11 +643,11 @@ void main() { [ FormInput( AuthFormField.email, - const Email.dirty(validEmailString), + const Email.pure(), ), FormInput( AuthFormField.password, - const Password.dirty(validPasswordString), + const Password.pure(), ) ], name: AuthFormName.signInForm, @@ -659,11 +659,11 @@ void main() { [ FormInput( AuthFormField.email, - const Email.dirty(validEmailString), + const Email.pure(), ), FormInput( AuthFormField.password, - const Password.dirty(validPasswordString), + const Password.pure(), ) ], name: AuthFormName.signInForm, diff --git a/packages/wyatt_authentication_bloc/test/sign_up/sign_up_cubit_test.dart b/packages/wyatt_authentication_bloc/test/sign_up/sign_up_cubit_test.dart index cc966202..d2c9811b 100644 --- a/packages/wyatt_authentication_bloc/test/sign_up/sign_up_cubit_test.dart +++ b/packages/wyatt_authentication_bloc/test/sign_up/sign_up_cubit_test.dart @@ -65,6 +65,13 @@ void main() { ), ).thenAnswer((_) async => Ok(account)); + when( + () => authenticationRepository.signInWithEmailAndPassword( + email: any(named: 'email'), + password: any(named: 'password'), + ), + ).thenAnswer((_) async => Ok(account)); + when( () => authenticationRepository.formRepository, ).thenAnswer((_) => formRepository); @@ -258,13 +265,13 @@ void main() { ); }); - group('submit', () { + group('signUpWithEmailPassword', () { blocTest, SignUpState>( 'does nothing when status is not validated', build: () => SignUpCubit( authenticationRepository: authenticationRepository, ), - act: (cubit) => cubit.submit(), + act: (cubit) => cubit.signUpWithEmailPassword(), expect: () => const [], ); @@ -308,7 +315,7 @@ void main() { ), status: FormStatus.valid, ), - act: (cubit) => cubit.submit(), + act: (cubit) => cubit.signUpWithEmailPassword(), verify: (_) { verify( () => authenticationRepository.signUp( @@ -360,7 +367,7 @@ void main() { ), status: FormStatus.valid, ), - act: (cubit) => cubit.submit(), + act: (cubit) => cubit.signUpWithEmailPassword(), expect: () => [ SignUpState( form: WyattFormImpl( @@ -444,7 +451,7 @@ void main() { ), status: FormStatus.valid, ), - act: (cubit) => cubit.submit(), + act: (cubit) => cubit.signUpWithEmailPassword(), expect: () => [ SignUpState( form: WyattFormImpl( -- 2.47.2 From eafe4dc7c6b72b3a94cf8811a5034e292b343552 Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Mon, 6 Feb 2023 16:46:28 +0100 Subject: [PATCH 11/47] feat(authentication): add full event support --- .../example/firebase.json | 3 +- .../ios/Runner.xcodeproj/project.pbxproj | 4 +- .../example/lib/bootstrap.dart | 2 +- .../lib/core/constants/form_field.dart | 2 +- .../example/lib/core/constants/form_name.dart | 2 +- .../lib/core/dependency_injection/get_it.dart | 43 +- .../example/lib/core/routes/router.dart | 12 +- .../lib/core/utils/app_bloc_observer.dart | 2 +- .../lib/core/utils/custom_password.dart | 2 +- .../example/lib/core/utils/forms.dart | 2 +- .../example/lib/main.dart | 2 +- .../example/lib/main_firebase.dart | 2 +- .../lib/presentation/features/app/app.dart | 39 +- .../authentication/authentication_cubit.dart} | 52 +-- .../blocs/edit_profile_cubit.dart | 74 --- .../edit_profile/edit_profile_page.dart | 61 --- .../widgets/edit_profile_form.dart | 136 ------ .../presentation/features/home/home_page.dart | 17 +- .../sign_in/blocs/custom_sign_in_cubit.dart | 48 ++ .../features/sign_in/sign_in_page.dart | 2 +- .../sign_in/widgets/sign_in_form.dart | 2 +- .../sign_up/blocs/custom_sign_up_cubit.dart | 37 +- .../features/sign_up/sign_up_page.dart | 2 +- .../sign_up/widgets/sign_up_form.dart | 2 +- .../presentation/features/sub/sub_page.dart | 2 +- .../features/welcome/welcome_page.dart | 2 +- .../lib/src/core/constants/form_field.dart | 5 +- .../lib/src/core/constants/form_name.dart | 6 +- .../lib/src/core/core.dart | 4 +- .../src/core/enums/authentication_status.dart | 6 +- .../lib/src/core/enums/enums.dart | 2 +- .../lib/src/core/exceptions/exceptions.dart | 32 +- .../core/exceptions/exceptions_firebase.dart | 48 +- .../extensions/build_context_extension.dart | 42 ++ .../lib/src/core/utils/custom_routine.dart | 62 +++ .../lib/src/data/data.dart | 2 +- .../src/data/data_sources/data_sources.dart | 4 +- ...hentication_firebase_data_source_impl.dart | 436 ++++++++++-------- .../authentication_mock_data_source_impl.dart | 271 ----------- .../lib/src/data/models/account_model.dart | 134 +++--- .../data/models/account_model_firebase.dart | 80 ---- .../lib/src/data/models/models.dart | 3 +- .../authentication_repository_impl.dart | 337 +++++--------- .../src/data/repositories/repositories.dart | 2 +- .../src/domain/data_sources/data_sources.dart | 3 +- .../authentication_remote_data_source.dart | 45 +- .../lib/src/domain/domain.dart | 2 +- .../lib/src/domain/entities/account.dart | 81 ++-- .../domain/entities/auth_change_event.dart | 51 -- .../authentication_change_event.dart} | 32 +- .../deleted_event.dart | 22 + .../reauthenticated_event.dart} | 30 +- .../refreshed_event.dart | 28 ++ .../signed_in_event.dart | 27 ++ .../signed_in_from_cache_event.dart | 27 ++ .../signed_out_event.dart | 22 + .../signed_up_event.dart | 27 ++ .../unknown_authentication_event.dart | 22 + .../updated_event.dart | 27 ++ .../lib/src/domain/entities/entities.dart | 7 +- .../{account_wrapper.dart => session.dart} | 20 +- .../src/domain/entities/session_wrapper.dart | 38 ++ .../authentication_repository.dart | 214 ++++----- .../src/domain/repositories/repositories.dart | 2 +- .../authentication/authentication.dart | 2 +- .../builder/authentication_builder.dart | 14 +- .../cubit/authentication_cubit.dart | 236 ++++++++-- .../cubit/authentication_state.dart | 26 +- .../builder/email_verification_builder.dart | 2 +- .../cubit/email_verification_cubit.dart | 30 +- .../cubit/email_verification_state.dart | 2 +- .../email_verification.dart | 2 +- .../lib/src/features/features.dart | 2 +- .../cubit/password_reset_cubit.dart | 2 +- .../cubit/password_reset_state.dart | 2 +- .../password_reset/password_reset.dart | 2 +- .../sign_in/cubit/base_sign_in_cubit.dart | 6 +- .../cubit/mixin/sign_in_anonymously.dart | 42 +- .../mixin/sign_in_with_email_password.dart | 45 +- .../cubit/mixin/sign_in_with_google.dart | 45 +- .../features/sign_in/cubit/sign_in_cubit.dart | 22 +- .../features/sign_in/cubit/sign_in_state.dart | 2 +- .../sign_in/listener/sign_in_listener.dart | 2 +- .../lib/src/features/sign_in/sign_in.dart | 5 +- .../sign_up/cubit/base_sign_up_cubit.dart | 6 +- .../mixin/sign_up_with_email_password.dart | 48 +- .../features/sign_up/cubit/sign_up_cubit.dart | 8 +- .../features/sign_up/cubit/sign_up_state.dart | 2 +- .../sign_up/listener/sign_up_listener.dart | 2 +- .../lib/src/features/sign_up/sign_up.dart | 3 +- .../lib/src/src.dart | 2 +- .../lib/wyatt_authentication_bloc.dart | 2 +- .../authentication_cubit_test.dart | 2 +- .../authentication_state_test.dart | 2 +- .../email_verification_cubit_test.dart | 2 +- .../email_verification_state_test.dart | 2 +- .../password_reset_cubit_test.dart | 2 +- .../password_reset_state_test.dart | 2 +- .../test/sign_in/sign_in_cubit_test.dart | 2 +- .../test/sign_in/sign_in_state_test.dart | 2 +- .../test/sign_up/sign_up_cubit_test.dart | 2 +- .../test/sign_up/sign_up_state_test.dart | 2 +- 102 files changed, 1677 insertions(+), 1664 deletions(-) rename packages/wyatt_authentication_bloc/{lib/src/data/data_sources/local/authentication_cache_data_source_impl.dart => example/lib/presentation/features/authentication/authentication_cubit.dart} (50%) delete mode 100644 packages/wyatt_authentication_bloc/example/lib/presentation/features/edit_profile/blocs/edit_profile_cubit.dart delete mode 100644 packages/wyatt_authentication_bloc/example/lib/presentation/features/edit_profile/edit_profile_page.dart delete mode 100644 packages/wyatt_authentication_bloc/example/lib/presentation/features/edit_profile/widgets/edit_profile_form.dart create mode 100644 packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_in/blocs/custom_sign_in_cubit.dart create mode 100644 packages/wyatt_authentication_bloc/lib/src/core/extensions/build_context_extension.dart create mode 100644 packages/wyatt_authentication_bloc/lib/src/core/utils/custom_routine.dart delete mode 100644 packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/authentication_mock_data_source_impl.dart delete mode 100644 packages/wyatt_authentication_bloc/lib/src/data/models/account_model_firebase.dart delete mode 100644 packages/wyatt_authentication_bloc/lib/src/domain/entities/auth_change_event.dart rename packages/wyatt_authentication_bloc/lib/src/domain/{data_sources/local/authentication_cache_data_source.dart => entities/authentication_change_event/authentication_change_event.dart} (55%) create mode 100644 packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/deleted_event.dart rename packages/wyatt_authentication_bloc/lib/src/{data/models/account_wrapper_model.dart => domain/entities/authentication_change_event/reauthenticated_event.dart} (53%) create mode 100644 packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/refreshed_event.dart create mode 100644 packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/signed_in_event.dart create mode 100644 packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/signed_in_from_cache_event.dart create mode 100644 packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/signed_out_event.dart create mode 100644 packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/signed_up_event.dart create mode 100644 packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/unknown_authentication_event.dart create mode 100644 packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/updated_event.dart rename packages/wyatt_authentication_bloc/lib/src/domain/entities/{account_wrapper.dart => session.dart} (70%) create mode 100644 packages/wyatt_authentication_bloc/lib/src/domain/entities/session_wrapper.dart diff --git a/packages/wyatt_authentication_bloc/example/firebase.json b/packages/wyatt_authentication_bloc/example/firebase.json index cdcf8e18..c8738c2c 100644 --- a/packages/wyatt_authentication_bloc/example/firebase.json +++ b/packages/wyatt_authentication_bloc/example/firebase.json @@ -8,6 +8,7 @@ }, "ui": { "enabled": true - } + }, + "singleProjectMode": true } } diff --git a/packages/wyatt_authentication_bloc/example/ios/Runner.xcodeproj/project.pbxproj b/packages/wyatt_authentication_bloc/example/ios/Runner.xcodeproj/project.pbxproj index 11d0d0ad..85497888 100644 --- a/packages/wyatt_authentication_bloc/example/ios/Runner.xcodeproj/project.pbxproj +++ b/packages/wyatt_authentication_bloc/example/ios/Runner.xcodeproj/project.pbxproj @@ -3,7 +3,7 @@ archiveVersion = 1; classes = { }; - objectVersion = 50; + objectVersion = 54; objects = { /* Begin PBXBuildFile section */ @@ -200,6 +200,7 @@ /* Begin PBXShellScriptBuildPhase section */ 3B06AD1E1E4923F5004D2608 /* Thin Binary */ = { isa = PBXShellScriptBuildPhase; + alwaysOutOfDate = 1; buildActionMask = 2147483647; files = ( ); @@ -236,6 +237,7 @@ }; 9740EEB61CF901F6004384FC /* Run Script */ = { isa = PBXShellScriptBuildPhase; + alwaysOutOfDate = 1; buildActionMask = 2147483647; files = ( ); diff --git a/packages/wyatt_authentication_bloc/example/lib/bootstrap.dart b/packages/wyatt_authentication_bloc/example/lib/bootstrap.dart index 8cf305fd..05ee6358 100644 --- a/packages/wyatt_authentication_bloc/example/lib/bootstrap.dart +++ b/packages/wyatt_authentication_bloc/example/lib/bootstrap.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify diff --git a/packages/wyatt_authentication_bloc/example/lib/core/constants/form_field.dart b/packages/wyatt_authentication_bloc/example/lib/core/constants/form_field.dart index 917131da..d111abaf 100644 --- a/packages/wyatt_authentication_bloc/example/lib/core/constants/form_field.dart +++ b/packages/wyatt_authentication_bloc/example/lib/core/constants/form_field.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify diff --git a/packages/wyatt_authentication_bloc/example/lib/core/constants/form_name.dart b/packages/wyatt_authentication_bloc/example/lib/core/constants/form_name.dart index b41b7335..1ff68488 100644 --- a/packages/wyatt_authentication_bloc/example/lib/core/constants/form_name.dart +++ b/packages/wyatt_authentication_bloc/example/lib/core/constants/form_name.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify diff --git a/packages/wyatt_authentication_bloc/example/lib/core/dependency_injection/get_it.dart b/packages/wyatt_authentication_bloc/example/lib/core/dependency_injection/get_it.dart index 2528fa87..1490523f 100644 --- a/packages/wyatt_authentication_bloc/example/lib/core/dependency_injection/get_it.dart +++ b/packages/wyatt_authentication_bloc/example/lib/core/dependency_injection/get_it.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify @@ -14,49 +14,20 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . -import 'package:example_router/bootstrap.dart'; import 'package:example_router/firebase_options.dart'; import 'package:get_it/get_it.dart'; import 'package:wyatt_authentication_bloc/wyatt_authentication_bloc.dart'; -import 'package:wyatt_type_utils/wyatt_type_utils.dart'; final getIt = GetIt.I; abstract class GetItInitializer { static Future init() async { - getIt - ..registerLazySingleton( - MockSettings.isEnable() - ? () => AuthenticationMockDataSourceImpl(registeredAccounts: [ - Pair( - AccountModel( - uid: '1', - emailVerified: true, - isAnonymous: false, - providerId: 'wyatt', - email: 'toto@test.fr', - ), - 'toto1234', - ), - Pair( - AccountModel( - uid: '2', - emailVerified: false, - isAnonymous: false, - providerId: 'wyatt', - email: 'tata@test.fr', - ), - 'tata1234', - ), - ]) - : () => AuthenticationFirebaseDataSourceImpl( - firebaseAuth: FirebaseAuth.instance, - googleSignIn: GoogleSignIn( - clientId: DefaultFirebaseOptions.ios.iosClientId)), - ) - ..registerLazySingleton>( - () => AuthenticationCacheDataSourceImpl(), - ); + getIt.registerLazySingleton>( + () => AuthenticationFirebaseDataSourceImpl( + firebaseAuth: FirebaseAuth.instance, + googleSignIn: + GoogleSignIn(clientId: DefaultFirebaseOptions.ios.iosClientId)), + ); await getIt.allReady(); } diff --git a/packages/wyatt_authentication_bloc/example/lib/core/routes/router.dart b/packages/wyatt_authentication_bloc/example/lib/core/routes/router.dart index 657d3917..51297a01 100644 --- a/packages/wyatt_authentication_bloc/example/lib/core/routes/router.dart +++ b/packages/wyatt_authentication_bloc/example/lib/core/routes/router.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify @@ -14,7 +14,6 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . -import 'package:example_router/presentation/features/edit_profile/edit_profile_page.dart'; import 'package:example_router/presentation/features/home/home_page.dart'; import 'package:example_router/presentation/features/sign_in/sign_in_page.dart'; import 'package:example_router/presentation/features/sign_up/sign_up_page.dart'; @@ -83,14 +82,5 @@ class AppRouter { const SubPage(), ), ), - GoRoute( - path: '/home/edit', - name: EditProfilePage.pageName, - pageBuilder: (context, state) => defaultTransition( - context, - state, - const EditProfilePage(), - ), - ), ]; } diff --git a/packages/wyatt_authentication_bloc/example/lib/core/utils/app_bloc_observer.dart b/packages/wyatt_authentication_bloc/example/lib/core/utils/app_bloc_observer.dart index 1a25acfd..abc209cb 100644 --- a/packages/wyatt_authentication_bloc/example/lib/core/utils/app_bloc_observer.dart +++ b/packages/wyatt_authentication_bloc/example/lib/core/utils/app_bloc_observer.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify diff --git a/packages/wyatt_authentication_bloc/example/lib/core/utils/custom_password.dart b/packages/wyatt_authentication_bloc/example/lib/core/utils/custom_password.dart index d80b6d3e..a7e1c7c8 100644 --- a/packages/wyatt_authentication_bloc/example/lib/core/utils/custom_password.dart +++ b/packages/wyatt_authentication_bloc/example/lib/core/utils/custom_password.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify diff --git a/packages/wyatt_authentication_bloc/example/lib/core/utils/forms.dart b/packages/wyatt_authentication_bloc/example/lib/core/utils/forms.dart index abfc6857..49fdfa9a 100644 --- a/packages/wyatt_authentication_bloc/example/lib/core/utils/forms.dart +++ b/packages/wyatt_authentication_bloc/example/lib/core/utils/forms.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify diff --git a/packages/wyatt_authentication_bloc/example/lib/main.dart b/packages/wyatt_authentication_bloc/example/lib/main.dart index ddc4cb52..a7967932 100644 --- a/packages/wyatt_authentication_bloc/example/lib/main.dart +++ b/packages/wyatt_authentication_bloc/example/lib/main.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify diff --git a/packages/wyatt_authentication_bloc/example/lib/main_firebase.dart b/packages/wyatt_authentication_bloc/example/lib/main_firebase.dart index d53f0050..62ee35ec 100644 --- a/packages/wyatt_authentication_bloc/example/lib/main_firebase.dart +++ b/packages/wyatt_authentication_bloc/example/lib/main_firebase.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify diff --git a/packages/wyatt_authentication_bloc/example/lib/presentation/features/app/app.dart b/packages/wyatt_authentication_bloc/example/lib/presentation/features/app/app.dart index 9fa89f49..1264aa73 100644 --- a/packages/wyatt_authentication_bloc/example/lib/presentation/features/app/app.dart +++ b/packages/wyatt_authentication_bloc/example/lib/presentation/features/app/app.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify @@ -15,41 +15,39 @@ // along with this program. If not, see . import 'dart:async'; -import 'dart:math'; import 'package:example_router/core/constants/form_field.dart'; import 'package:example_router/core/dependency_injection/get_it.dart'; import 'package:example_router/core/routes/router.dart'; import 'package:example_router/core/utils/custom_password.dart'; import 'package:example_router/core/utils/forms.dart'; +import 'package:example_router/presentation/features/authentication/authentication_cubit.dart'; +import 'package:example_router/presentation/features/sign_in/blocs/custom_sign_in_cubit.dart'; import 'package:example_router/presentation/features/sign_up/blocs/custom_sign_up_cubit.dart'; import 'package:flutter/material.dart'; import 'package:flutter_bloc/flutter_bloc.dart'; import 'package:go_router/go_router.dart'; -import 'package:wyatt_architecture/wyatt_architecture.dart'; import 'package:wyatt_authentication_bloc/wyatt_authentication_bloc.dart'; import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; -import 'package:wyatt_type_utils/wyatt_type_utils.dart'; -FutureOrResult onAccountChanges( - AuthenticationRepository repo, - AuthChangeEvent? authEvent, -) async { - final id = Random().nextInt(1000); - final token = - await repo.getIdentityToken().fold((value) => value, (error) => 'null'); +// FutureOrResult onAccountChanges( +// AuthenticationRepository repo, +// AuthChangeEvent? authEvent, +// ) async { +// final id = Random().nextInt(1000); +// final token = +// await repo.getIdentityToken().fold((value) => value, (error) => 'null'); - debugPrint( - 'onAccountChanges: ${authEvent?.account}, type: ${authEvent.runtimeType}, token: $token, generatedId: $id'); - return Ok(id); -} +// debugPrint( +// 'onAccountChanges: ${authEvent?.account}, type: ${authEvent.runtimeType}, token: $token, generatedId: $id'); +// return Ok(id); +// } class App extends StatelessWidget { final AuthenticationRepository authenticationRepository = AuthenticationRepositoryImpl( - authenticationCacheDataSource: getIt>(), - authenticationRemoteDataSource: getIt(), - onAuthChange: onAccountChanges, + authenticationRemoteDataSource: + getIt>(), customPasswordValidator: const CustomPassword.pure(), extraSignUpInputs: [ FormInput( @@ -66,8 +64,7 @@ class App extends StatelessWidget { Widget build(BuildContext context) { AuthenticationState? previous; - final AuthenticationCubit authenticationCubit = - AuthenticationCubit(authenticationRepository: authenticationRepository); + final AuthenticationCubit authenticationCubit = ExampleAuthenticationCubit(authenticationRepository: authenticationRepository); final GoRouter router = GoRouter( initialLocation: '/', @@ -119,7 +116,7 @@ class App extends StatelessWidget { ), ), BlocProvider>( - create: (_) => SignInCubit( + create: (_) => CustomSignInCubit( authenticationRepository: authenticationRepository, ), ), diff --git a/packages/wyatt_authentication_bloc/lib/src/data/data_sources/local/authentication_cache_data_source_impl.dart b/packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/authentication_cubit.dart similarity index 50% rename from packages/wyatt_authentication_bloc/lib/src/data/data_sources/local/authentication_cache_data_source_impl.dart rename to packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/authentication_cubit.dart index abcb673a..869be269 100644 --- a/packages/wyatt_authentication_bloc/lib/src/data/data_sources/local/authentication_cache_data_source_impl.dart +++ b/packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/authentication_cubit.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify @@ -18,49 +18,35 @@ import 'package:wyatt_architecture/wyatt_architecture.dart'; import 'package:wyatt_authentication_bloc/wyatt_authentication_bloc.dart'; import 'package:wyatt_type_utils/wyatt_type_utils.dart'; -class AuthenticationCacheDataSourceImpl - extends AuthenticationCacheDataSource { - AuthenticationCacheDataSourceImpl(); - Account? _account; - T? _data; +class ExampleAuthenticationCubit extends AuthenticationCubit { + ExampleAuthenticationCubit({required super.authenticationRepository}); @override - Future storeAccount(Account? account) async { - _account = account; + FutureOrResult onReauthenticate( + Result result) async { + print('onReauthenticate'); + + return const Ok(1); } @override - Future storeData(T? data) async { - _data = data; + FutureOrResult onRefresh(Result result) { + print('onRefresh'); + + return const Ok(1); } @override - Future loadAccount() async { - if (_account.isNotNull) { - return _account!; - } - throw ClientException('Cached account is invalid'); + FutureOrResult onSignInFromCache(SessionWrapper wrapper) { + print('onSignInFromCache'); + + return const Ok(1); } @override - Future loadData() async { - if (_data.isNotNull) { - return _data!; - } - throw ClientException('Cached data is invalid'); - } + FutureOrResult onSignOut() { + print('onSignOut'); - @override - Future destroy() async { - _data = null; - _account = null; - } - - @override - Future> load() async { - if (_account.isNull) { - throw ClientException('Cached account is invalid'); - } - return AccountWrapperModel(_account, _data); + return const Ok(null); } } diff --git a/packages/wyatt_authentication_bloc/example/lib/presentation/features/edit_profile/blocs/edit_profile_cubit.dart b/packages/wyatt_authentication_bloc/example/lib/presentation/features/edit_profile/blocs/edit_profile_cubit.dart deleted file mode 100644 index 40063f4c..00000000 --- a/packages/wyatt_authentication_bloc/example/lib/presentation/features/edit_profile/blocs/edit_profile_cubit.dart +++ /dev/null @@ -1,74 +0,0 @@ -// Copyright (C) 2022 WYATT GROUP -// Please see the AUTHORS file for details. -// -// This program is free software: you can redistribute it and/or modify -// it under the terms of the GNU General Public License as published by -// the Free Software Foundation, either version 3 of the License, or -// any later version. -// -// This program is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with this program. If not, see . - -import 'package:example_router/core/constants/form_field.dart'; -import 'package:wyatt_authentication_bloc/wyatt_authentication_bloc.dart'; -import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; -import 'package:wyatt_type_utils/wyatt_type_utils.dart'; - -class EditProfileCubit extends FormDataCubitImpl { - final AuthenticationRepository authenticationRepository; - - EditProfileCubit( - super._formRepository, - super._formName, { - required this.authenticationRepository, - }) : super(); - - @override - Future submit() async { - emit( - state.copyWith( - status: FormStatus.submissionInProgress, - ), - ); - // final user = (await authenticationRepository.getAccount()).ok; - - final form = state.form; - final email = form.valueOf(AuthFormField.email); - final oldPassword = form.valueOf(AppFormField.oldPassword); - final newPassword = form.valueOf(AuthFormField.password); - - if (email.isNullOrEmpty || - oldPassword.isNullOrEmpty || - newPassword.isNullOrEmpty) { - emit( - state.copyWith( - errorMessage: 'An error occured while retrieving data from the form.', - status: FormStatus.submissionFailure, - ), - ); - } - - try { - // await authenticationRepository.signInWithEmailAndPassword( - // email: user?.email ?? '', - // password: oldPassword ?? '', - // ); - // await authenticationRepository.reauthenticateWithCredential(); - await authenticationRepository.updateEmail(email: email!); - await authenticationRepository.updatePassword(password: newPassword!); - } on Exception catch (e) { - emit( - state.copyWith( - status: FormStatus.submissionFailure, - errorMessage: e.toString(), - ), - ); - } - emit(state.copyWith(status: FormStatus.submissionSuccess)); - } -} diff --git a/packages/wyatt_authentication_bloc/example/lib/presentation/features/edit_profile/edit_profile_page.dart b/packages/wyatt_authentication_bloc/example/lib/presentation/features/edit_profile/edit_profile_page.dart deleted file mode 100644 index a557d338..00000000 --- a/packages/wyatt_authentication_bloc/example/lib/presentation/features/edit_profile/edit_profile_page.dart +++ /dev/null @@ -1,61 +0,0 @@ -// Copyright (C) 2022 WYATT GROUP -// Please see the AUTHORS file for details. -// -// This program is free software: you can redistribute it and/or modify -// it under the terms of the GNU General Public License as published by -// the Free Software Foundation, either version 3 of the License, or -// any later version. -// -// This program is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with this program. If not, see . - -import 'package:example_router/core/constants/form_name.dart'; -import 'package:example_router/presentation/features/edit_profile/blocs/edit_profile_cubit.dart'; -import 'package:example_router/presentation/features/edit_profile/widgets/edit_profile_form.dart'; -import 'package:flutter/material.dart'; -import 'package:flutter_bloc/flutter_bloc.dart'; -import 'package:wyatt_authentication_bloc/wyatt_authentication_bloc.dart'; -import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; - -class EditProfilePage extends StatelessWidget { - const EditProfilePage({Key? key}) : super(key: key); - - static String pageName = 'EditProfile'; - - @override - Widget build(BuildContext context) { - return Scaffold( - appBar: AppBar(title: const Text('Edit Profile')), - body: Padding( - padding: const EdgeInsets.all(8), - child: SingleChildScrollView( - child: BlocProvider( - create: (context) => EditProfileCubit( - context.read(), - AppFormName.editProfile, - authenticationRepository: - context.read>(), - )..dataChanged( - AuthFormField.email, - Email.dirty( - context - .read>() - .state - .accountWrapper - ?.account - ?.email ?? - '', - ), - ), - child: const EditProfileForm(), - ), - ), - ), - ); - } -} diff --git a/packages/wyatt_authentication_bloc/example/lib/presentation/features/edit_profile/widgets/edit_profile_form.dart b/packages/wyatt_authentication_bloc/example/lib/presentation/features/edit_profile/widgets/edit_profile_form.dart deleted file mode 100644 index 726e51a4..00000000 --- a/packages/wyatt_authentication_bloc/example/lib/presentation/features/edit_profile/widgets/edit_profile_form.dart +++ /dev/null @@ -1,136 +0,0 @@ -// Copyright (C) 2022 WYATT GROUP -// Please see the AUTHORS file for details. -// -// This program is free software: you can redistribute it and/or modify -// it under the terms of the GNU General Public License as published by -// the Free Software Foundation, either version 3 of the License, or -// any later version. -// -// This program is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with this program. If not, see . - -import 'package:example_router/core/constants/form_field.dart'; -import 'package:example_router/core/utils/custom_password.dart'; -import 'package:example_router/presentation/features/edit_profile/blocs/edit_profile_cubit.dart'; -import 'package:flutter/material.dart'; -import 'package:flutter_bloc/flutter_bloc.dart'; -import 'package:wyatt_authentication_bloc/wyatt_authentication_bloc.dart'; -import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; - -class _EmailInput extends StatelessWidget { - @override - Widget build(BuildContext context) { - return InputBuilderTextController( - field: AuthFormField.email, - builder: ((context, cubit, state, field, input, controller, extra) { - return TextField( - onChanged: (email) => cubit.dataChanged( - AuthFormField.email, Email.dirty(email)), - keyboardType: TextInputType.emailAddress, - controller: controller, - decoration: InputDecoration( - labelText: 'Email', - helperText: '', - errorText: input.validator.invalid ? 'Invalid email' : null, - ), - ); - }), - ); - } -} - -class _OldPasswordInput extends StatelessWidget { - @override - Widget build(BuildContext context) { - return InputBuilder( - field: AppFormField.oldPassword, - builder: ((context, cubit, state, field, input) { - return TextField( - onChanged: (pwd) => cubit.dataChanged( - AppFormField.oldPassword, CustomPassword.dirty(pwd)), - obscureText: true, - decoration: InputDecoration( - labelText: 'Old Password', - helperText: '', - errorText: input.validator.invalid ? 'Invalid password' : null, - ), - ); - }), - ); - } -} - -class _NewPasswordInput extends StatelessWidget { - @override - Widget build(BuildContext context) { - return InputBuilder( - field: AuthFormField.password, - builder: ((context, cubit, state, field, input) { - return TextField( - onChanged: (pwd) => cubit.dataChanged( - AuthFormField.password, CustomPassword.dirty(pwd)), - obscureText: true, - decoration: InputDecoration( - labelText: 'New Password', - helperText: '', - errorText: input.validator.invalid ? 'Invalid password' : null, - ), - ); - }), - ); - } -} - -class _EditButton extends StatelessWidget { - @override - Widget build(BuildContext context) { - return SubmitBuilder( - builder: ((context, cubit, status) { - return status.isSubmissionInProgress - ? const CircularProgressIndicator() - : ElevatedButton( - onPressed: status.isValidated ? () => cubit.submit() : null, - child: const Text('Edit profile'), - ); - }), - ); - } -} - -class EditProfileForm extends StatelessWidget { - const EditProfileForm({Key? key}) : super(key: key); - - @override - Widget build(BuildContext context) { - return BlocListener( - listener: (context, state) { - if (state.status == FormStatus.submissionFailure) { - ScaffoldMessenger.of(context) - ..hideCurrentSnackBar() - ..showSnackBar( - SnackBar(content: Text(state.errorMessage ?? 'Edit Failure')), - ); - } - }, - child: SingleChildScrollView( - child: Column( - crossAxisAlignment: CrossAxisAlignment.center, - children: [ - _EmailInput(), - const SizedBox(height: 8), - _OldPasswordInput(), - const SizedBox(height: 8), - _NewPasswordInput(), - const SizedBox(height: 16), - _EditButton(), - ], - ), - ), - ); - } -} diff --git a/packages/wyatt_authentication_bloc/example/lib/presentation/features/home/home_page.dart b/packages/wyatt_authentication_bloc/example/lib/presentation/features/home/home_page.dart index a015690b..a66a38a0 100644 --- a/packages/wyatt_authentication_bloc/example/lib/presentation/features/home/home_page.dart +++ b/packages/wyatt_authentication_bloc/example/lib/presentation/features/home/home_page.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify @@ -14,7 +14,6 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . -import 'package:example_router/presentation/features/edit_profile/edit_profile_page.dart'; import 'package:example_router/presentation/features/sub/sub_page.dart'; import 'package:flutter/material.dart'; import 'package:flutter_bloc/flutter_bloc.dart'; @@ -30,7 +29,7 @@ class HomePage extends StatelessWidget { Widget build(BuildContext context) { return Scaffold( appBar: AppBar( - title: const Text('Home'), + title: Text('Home | ${context.account, int>()?.email}'), actions: [ IconButton( onPressed: () => @@ -44,8 +43,8 @@ class HomePage extends StatelessWidget { child: Column( children: [ AuthenticationBuilder( - authenticated: (context, accountWrapper) => Text( - 'Logged as ${accountWrapper.account?.email} | GeneratedId is ${accountWrapper.data}'), + authenticated: (context, sessionWrapper) => Text( + 'Logged as ${sessionWrapper.session?.account.email} | GeneratedId is ${sessionWrapper.session?.data}'), unauthenticated: (context) => const Text('Not logged (unauthenticated)'), unknown: (context) => const Text('Not logged (unknown)'), @@ -57,10 +56,10 @@ class HomePage extends StatelessWidget { onPressed: () => context.pushNamed(SubPage.pageName), child: const Text('Go to sub page'), ), - ElevatedButton( - onPressed: () => context.pushNamed(EditProfilePage.pageName), - child: const Text('Go to edit profile page'), - ), + // ElevatedButton( + // onPressed: () => context.pushNamed(EditProfilePage.pageName), + // child: const Text('Go to edit profile page'), + // ), ], ), ), diff --git a/packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_in/blocs/custom_sign_in_cubit.dart b/packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_in/blocs/custom_sign_in_cubit.dart new file mode 100644 index 00000000..882cfd35 --- /dev/null +++ b/packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_in/blocs/custom_sign_in_cubit.dart @@ -0,0 +1,48 @@ +// Copyright (C) 2023 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +import 'package:wyatt_architecture/src/domain/usecases/usecase.dart'; +import 'package:wyatt_architecture/src/core/exceptions/exceptions.dart'; +import 'package:wyatt_authentication_bloc/wyatt_authentication_bloc.dart'; +import 'package:wyatt_type_utils/src/either/either_base.dart'; +import 'package:wyatt_form_bloc/src/domain/form/wyatt_form.dart'; + +class CustomSignInCubit extends SignInCubit { + CustomSignInCubit({ + required super.authenticationRepository, + }); + + @override + FutureOrResult onSignInWithEmailAndPassword(Result result, WyattForm form) { + print('onSignInWithEmailAndPassword'); + + return const Ok(1); + } + + @override + FutureOrResult onSignInAnonymously(Result result, WyattForm form) { + print('onSignInAnonymously'); + + return const Ok(1); + } + + @override + FutureOrResult onSignInWithGoogle(Result result, WyattForm form) { + print('onSignInWithGoogle'); + + return const Ok(1); + } +} diff --git a/packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_in/sign_in_page.dart b/packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_in/sign_in_page.dart index 19dfd0b6..5ac3770b 100644 --- a/packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_in/sign_in_page.dart +++ b/packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_in/sign_in_page.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify diff --git a/packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_in/widgets/sign_in_form.dart b/packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_in/widgets/sign_in_form.dart index f0e1dfa9..bf39991c 100644 --- a/packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_in/widgets/sign_in_form.dart +++ b/packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_in/widgets/sign_in_form.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify diff --git a/packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_up/blocs/custom_sign_up_cubit.dart b/packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_up/blocs/custom_sign_up_cubit.dart index 7e5f1e6d..d49e6056 100644 --- a/packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_up/blocs/custom_sign_up_cubit.dart +++ b/packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_up/blocs/custom_sign_up_cubit.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify @@ -14,33 +14,34 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . -import 'dart:async'; -import 'package:example_router/core/constants/form_field.dart'; -import 'package:flutter/foundation.dart'; import 'package:wyatt_architecture/wyatt_architecture.dart'; import 'package:wyatt_authentication_bloc/wyatt_authentication_bloc.dart'; import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; import 'package:wyatt_type_utils/wyatt_type_utils.dart'; -class CustomSignUpCubit extends SignUpCubit{ +class CustomSignUpCubit extends SignUpCubit { CustomSignUpCubit({ required super.authenticationRepository, }); - + @override - FutureOrResult onSignUpWithEmailAndPassword( - Result result, WyattForm form) async { - if (result.isOk) { - await Future.delayed(const Duration(seconds: 3)); - const id = -1; - final confirmedPassword = - form.valueOf(AppFormField.confirmedPassword); + FutureOrResult onSignUpWithEmailAndPassword(Result result, WyattForm form) async { + // if (result.isOk) { + // await Future.delayed(const Duration(seconds: 3)); + // const id = -1; + // final confirmedPassword = + // form.valueOf(AppFormField.confirmedPassword); - debugPrint( - 'onSignUpSuccess: ${result.ok}, generatedId: $id, intFormData: $confirmedPassword'); - return const Ok(id); - } - return const Ok(null); + // debugPrint( + // 'onSignUpSuccess: ${result.ok}, generatedId: $id, intFormData: $confirmedPassword'); + // return const Ok(id); + // } + // return const Ok(null); + print('onSignUpWithEmailAndPassword'); + + return const Ok(1); } + + } diff --git a/packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_up/sign_up_page.dart b/packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_up/sign_up_page.dart index ff232348..2f0f6ce5 100644 --- a/packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_up/sign_up_page.dart +++ b/packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_up/sign_up_page.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify diff --git a/packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_up/widgets/sign_up_form.dart b/packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_up/widgets/sign_up_form.dart index a4f44a48..23b9884d 100644 --- a/packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_up/widgets/sign_up_form.dart +++ b/packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_up/widgets/sign_up_form.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify diff --git a/packages/wyatt_authentication_bloc/example/lib/presentation/features/sub/sub_page.dart b/packages/wyatt_authentication_bloc/example/lib/presentation/features/sub/sub_page.dart index a5c8a6b6..9cdfad53 100644 --- a/packages/wyatt_authentication_bloc/example/lib/presentation/features/sub/sub_page.dart +++ b/packages/wyatt_authentication_bloc/example/lib/presentation/features/sub/sub_page.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify diff --git a/packages/wyatt_authentication_bloc/example/lib/presentation/features/welcome/welcome_page.dart b/packages/wyatt_authentication_bloc/example/lib/presentation/features/welcome/welcome_page.dart index 10d5c0cc..29e97aa4 100644 --- a/packages/wyatt_authentication_bloc/example/lib/presentation/features/welcome/welcome_page.dart +++ b/packages/wyatt_authentication_bloc/example/lib/presentation/features/welcome/welcome_page.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify diff --git a/packages/wyatt_authentication_bloc/lib/src/core/constants/form_field.dart b/packages/wyatt_authentication_bloc/lib/src/core/constants/form_field.dart index 295cfc2f..aa1ed36a 100644 --- a/packages/wyatt_authentication_bloc/lib/src/core/constants/form_field.dart +++ b/packages/wyatt_authentication_bloc/lib/src/core/constants/form_field.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify @@ -14,7 +14,10 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . +/// Default authentication form fields name abstract class AuthFormField { + /// Email field: `wyattEmailField` static const email = 'wyattEmailField'; + /// Password field: `wyattPasswordField` static const password = 'wyattPasswordField'; } diff --git a/packages/wyatt_authentication_bloc/lib/src/core/constants/form_name.dart b/packages/wyatt_authentication_bloc/lib/src/core/constants/form_name.dart index af623e70..3eca89e0 100644 --- a/packages/wyatt_authentication_bloc/lib/src/core/constants/form_name.dart +++ b/packages/wyatt_authentication_bloc/lib/src/core/constants/form_name.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify @@ -14,8 +14,12 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . +/// Default authentication form name abstract class AuthFormName { + /// Sign Up form: `wyattSignUpForm` static const String signUpForm = 'wyattSignUpForm'; + /// Sign In form: `wyattSignInForm` static const String signInForm = 'wyattSignInForm'; + /// Password reset form: `wyattPasswordResetForm` static const String passwordResetForm = 'wyattPasswordResetForm'; } diff --git a/packages/wyatt_authentication_bloc/lib/src/core/core.dart b/packages/wyatt_authentication_bloc/lib/src/core/core.dart index 2d4165fc..da22baa1 100644 --- a/packages/wyatt_authentication_bloc/lib/src/core/core.dart +++ b/packages/wyatt_authentication_bloc/lib/src/core/core.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify @@ -18,3 +18,5 @@ export 'constants/form_field.dart'; export 'constants/form_name.dart'; export 'enums/enums.dart'; export 'exceptions/exceptions.dart'; +export 'extensions/build_context_extension.dart'; +export 'utils/custom_routine.dart'; diff --git a/packages/wyatt_authentication_bloc/lib/src/core/enums/authentication_status.dart b/packages/wyatt_authentication_bloc/lib/src/core/enums/authentication_status.dart index 11386588..b88a7407 100644 --- a/packages/wyatt_authentication_bloc/lib/src/core/enums/authentication_status.dart +++ b/packages/wyatt_authentication_bloc/lib/src/core/enums/authentication_status.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify @@ -14,8 +14,12 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . +/// Different authentication status enum AuthenticationStatus { + /// At the application launch. unknown, + /// When the user is logged authenticated, + /// When the user is not logged unauthenticated, } diff --git a/packages/wyatt_authentication_bloc/lib/src/core/enums/enums.dart b/packages/wyatt_authentication_bloc/lib/src/core/enums/enums.dart index db37d714..de021091 100644 --- a/packages/wyatt_authentication_bloc/lib/src/core/enums/enums.dart +++ b/packages/wyatt_authentication_bloc/lib/src/core/enums/enums.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify diff --git a/packages/wyatt_authentication_bloc/lib/src/core/exceptions/exceptions.dart b/packages/wyatt_authentication_bloc/lib/src/core/exceptions/exceptions.dart index f60c915e..e10faebe 100644 --- a/packages/wyatt_authentication_bloc/lib/src/core/exceptions/exceptions.dart +++ b/packages/wyatt_authentication_bloc/lib/src/core/exceptions/exceptions.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify @@ -18,6 +18,7 @@ import 'package:wyatt_architecture/wyatt_architecture.dart'; part 'exceptions_firebase.dart'; +/// Base exception used in Wyatt Authentication abstract class AuthenticationFailureInterface extends AppException implements Exception { AuthenticationFailureInterface(this.code, this.msg); @@ -249,13 +250,9 @@ abstract class SignOutFailureInterface extends AuthenticationFailureInterface { SignOutFailureInterface.fromCode(super.code) : super.fromCode(); } -abstract class GetIdTokenFailureInterface - extends AuthenticationFailureInterface { - GetIdTokenFailureInterface(super.code, super.msg); - - GetIdTokenFailureInterface.fromCode(super.code) : super.fromCode(); -} - +/// {@template reauthenticate_failure} +/// Thrown during the reauthentication process if a failure occurs. +/// {@endtemplate} abstract class ReauthenticateFailureInterface extends AuthenticationFailureInterface { ReauthenticateFailureInterface(super.code, super.msg); @@ -263,6 +260,9 @@ abstract class ReauthenticateFailureInterface ReauthenticateFailureInterface.fromCode(super.code) : super.fromCode(); } +/// {@template update_email_failure} +/// Thrown during the email modification process if a failure occurs. +/// {@endtemplate} abstract class UpdateEmailFailureInterface extends AuthenticationFailureInterface { UpdateEmailFailureInterface(super.code, super.msg); @@ -270,6 +270,9 @@ abstract class UpdateEmailFailureInterface UpdateEmailFailureInterface.fromCode(super.code) : super.fromCode(); } +/// {@template update_password_failure} +/// Thrown during the password modification process if a failure occurs. +/// {@endtemplate} abstract class UpdatePasswordFailureInterface extends AuthenticationFailureInterface { UpdatePasswordFailureInterface(super.code, super.msg); @@ -277,9 +280,22 @@ abstract class UpdatePasswordFailureInterface UpdatePasswordFailureInterface.fromCode(super.code) : super.fromCode(); } +/// {@template model_parsing_failure} +/// Thrown during the model parsing process if a failure occurs. +/// {@endtemplate} abstract class ModelParsingFailureInterface extends AuthenticationFailureInterface { ModelParsingFailureInterface(super.code, super.msg); ModelParsingFailureInterface.fromCode(super.code) : super.fromCode(); } + +/// {@template delete_account_failure} +/// Thrown during the account deletion if a failure occurs. +/// {@endtemplate} +abstract class DeleteAccountFailureInterface + extends AuthenticationFailureInterface { + DeleteAccountFailureInterface(super.code, super.msg); + + DeleteAccountFailureInterface.fromCode(super.code) : super.fromCode(); +} diff --git a/packages/wyatt_authentication_bloc/lib/src/core/exceptions/exceptions_firebase.dart b/packages/wyatt_authentication_bloc/lib/src/core/exceptions/exceptions_firebase.dart index 58e3c409..7b17e606 100644 --- a/packages/wyatt_authentication_bloc/lib/src/core/exceptions/exceptions_firebase.dart +++ b/packages/wyatt_authentication_bloc/lib/src/core/exceptions/exceptions_firebase.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify @@ -16,6 +16,7 @@ part of 'exceptions.dart'; +/// {@macro apply_action_code_failure} class ApplyActionCodeFailureFirebase extends ApplyActionCodeFailureInterface { ApplyActionCodeFailureFirebase([String? code, String? msg]) : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); @@ -41,6 +42,7 @@ class ApplyActionCodeFailureFirebase extends ApplyActionCodeFailureInterface { } } +/// {@macro sign_up_with_email_and_password_failure} class SignUpWithEmailAndPasswordFailureFirebase extends SignUpWithEmailAndPasswordFailureInterface { SignUpWithEmailAndPasswordFailureFirebase([String? code, String? msg]) @@ -70,6 +72,7 @@ class SignUpWithEmailAndPasswordFailureFirebase } } +/// {@macro fetch_sign_in_methods_failure} class FetchSignInMethodsForEmailFailureFirebase extends FetchSignInMethodsForEmailFailureInterface { FetchSignInMethodsForEmailFailureFirebase([String? code, String? msg]) @@ -87,6 +90,7 @@ class FetchSignInMethodsForEmailFailureFirebase } } +/// {@macro sign_in_anonymously_failure} class SignInAnonymouslyFailureFirebase extends SignInAnonymouslyFailureInterface { SignInAnonymouslyFailureFirebase([String? code, String? msg]) @@ -104,6 +108,7 @@ class SignInAnonymouslyFailureFirebase } } +/// {@macro sign_in_with_credential_failure} class SignInWithCredentialFailureFirebase extends SignInWithCredentialFailureInterface { SignInWithCredentialFailureFirebase([String? code, String? msg]) @@ -142,6 +147,7 @@ class SignInWithCredentialFailureFirebase } } +/// {@macro sign_in_with_google_failure} class SignInWithGoogleFailureFirebase extends SignInWithCredentialFailureFirebase implements SignInWithGoogleFailureInterface { @@ -149,6 +155,7 @@ class SignInWithGoogleFailureFirebase SignInWithGoogleFailureFirebase.fromCode(super.code) : super.fromCode(); } +/// {@macro sign_in_with_facebook_failure} class SignInWithFacebookFailureFirebase extends SignInWithCredentialFailureFirebase implements SignInWithFacebookFailureInterface { @@ -156,12 +163,14 @@ class SignInWithFacebookFailureFirebase SignInWithFacebookFailureFirebase.fromCode(super.code) : super.fromCode(); } +/// {@macro sign_in_with_apple_failure} class SignInWithAppleFailureFirebase extends SignInWithCredentialFailureFirebase implements SignInWithAppleFailureInterface { SignInWithAppleFailureFirebase([super.code, super.msg]); SignInWithAppleFailureFirebase.fromCode(super.code) : super.fromCode(); } +/// {@macro sign_in_with_twitter_failure} class SignInWithTwitterFailureFirebase extends SignInWithCredentialFailureFirebase implements SignInWithAppleFailureInterface { @@ -169,6 +178,7 @@ class SignInWithTwitterFailureFirebase SignInWithTwitterFailureFirebase.fromCode(super.code) : super.fromCode(); } +/// {@macro sign_in_with_email_link_failure} class SignInWithEmailLinkFailureFirebase extends SignInWithEmailLinkFailureInterface { SignInWithEmailLinkFailureFirebase([String? code, String? msg]) @@ -192,6 +202,7 @@ class SignInWithEmailLinkFailureFirebase } } +/// {@macro sign_in_with_email_and_password_failure} class SignInWithEmailAndPasswordFailureFirebase extends SignInWithEmailAndPasswordFailureInterface { SignInWithEmailAndPasswordFailureFirebase([String? code, String? msg]) @@ -218,6 +229,7 @@ class SignInWithEmailAndPasswordFailureFirebase } } +/// {@macro send_email_verification_failure} class SendEmailVerificationFailureFirebase extends SendEmailVerificationFailureInterface { SendEmailVerificationFailureFirebase([String? code, String? msg]) @@ -226,6 +238,7 @@ class SendEmailVerificationFailureFirebase SendEmailVerificationFailureFirebase.fromCode(super.code) : super.fromCode(); } +/// {@macro send_password_reset_email_failure} class SendPasswordResetEmailFailureFirebase extends SendPasswordResetEmailFailureInterface { SendPasswordResetEmailFailureFirebase([String? code, String? msg]) @@ -233,6 +246,7 @@ class SendPasswordResetEmailFailureFirebase SendPasswordResetEmailFailureFirebase.fromCode(super.code) : super.fromCode(); } +/// {@macro send_sign_in_link_email_failure} class SendSignInLinkEmailFailureFirebase extends SendSignInLinkEmailFailureInterface { SendSignInLinkEmailFailureFirebase([String? code, String? msg]) @@ -241,6 +255,7 @@ class SendSignInLinkEmailFailureFirebase SendSignInLinkEmailFailureFirebase.fromCode(super.code) : super.fromCode(); } +/// {@macro confirm_password_reset_failure} class ConfirmPasswordResetFailureFirebase extends ConfirmPasswordResetFailureInterface { ConfirmPasswordResetFailureFirebase([String? code, String? msg]) @@ -249,6 +264,7 @@ class ConfirmPasswordResetFailureFirebase ConfirmPasswordResetFailureFirebase.fromCode(super.code) : super.fromCode(); } +/// {@macro verify_password_reset_code_failure} class VerifyPasswordResetCodeFailureFirebase extends VerifyPasswordResetCodeFailureInterface { VerifyPasswordResetCodeFailureFirebase([String? code, String? msg]) @@ -258,12 +274,14 @@ class VerifyPasswordResetCodeFailureFirebase : super.fromCode(); } +/// {@macro refresh_failure} class RefreshFailureFirebase extends RefreshFailureInterface { RefreshFailureFirebase([String? code, String? msg]) : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); RefreshFailureFirebase.fromCode(super.code) : super.fromCode(); } +/// {@macro sign_out_failure} class SignOutFailureFirebase extends SignOutFailureInterface { SignOutFailureFirebase([String? code, String? msg]) : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); @@ -271,13 +289,7 @@ class SignOutFailureFirebase extends SignOutFailureInterface { SignOutFailureFirebase.fromCode(super.code) : super.fromCode(); } -class GetIdTokenFailureFirebase extends GetIdTokenFailureInterface { - GetIdTokenFailureFirebase([String? code, String? msg]) - : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); - - GetIdTokenFailureFirebase.fromCode(super.code) : super.fromCode(); -} - +/// {@macro reauthenticate_failure} class ReauthenticateFailureFirebase extends ReauthenticateFailureInterface { ReauthenticateFailureFirebase([String? code, String? msg]) : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); @@ -311,6 +323,7 @@ class ReauthenticateFailureFirebase extends ReauthenticateFailureInterface { } } +/// {@macro update_email_failure} class UpdateEmailFailureFirebase extends UpdateEmailFailureInterface { UpdateEmailFailureFirebase([String? code, String? msg]) : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); @@ -332,6 +345,7 @@ class UpdateEmailFailureFirebase extends UpdateEmailFailureInterface { } } +/// {@macro update_password_failure} class UpdatePasswordFailureFirebase extends UpdatePasswordFailureInterface { UpdatePasswordFailureFirebase([String? code, String? msg]) : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); @@ -350,9 +364,27 @@ class UpdatePasswordFailureFirebase extends UpdatePasswordFailureInterface { } } +/// {@macro model_parsing_failure} class ModelParsingFailureFirebase extends ModelParsingFailureInterface { ModelParsingFailureFirebase([String? code, String? msg]) : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); ModelParsingFailureFirebase.fromCode(super.code) : super.fromCode(); } + +/// {@macro delete_account_failure} +class DeleteAccountFailureFirebase extends DeleteAccountFailureInterface { + DeleteAccountFailureFirebase([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); + + DeleteAccountFailureFirebase.fromCode(String code) : super.fromCode(code) { + switch (code) { + case 'requires-recent-login': + msg = "User's last sign-in time does not meet the security threshold."; + break; + default: + this.code = 'unknown'; + msg = 'An unknown error occurred.'; + } + } +} diff --git a/packages/wyatt_authentication_bloc/lib/src/core/extensions/build_context_extension.dart b/packages/wyatt_authentication_bloc/lib/src/core/extensions/build_context_extension.dart new file mode 100644 index 00000000..c7753da4 --- /dev/null +++ b/packages/wyatt_authentication_bloc/lib/src/core/extensions/build_context_extension.dart @@ -0,0 +1,42 @@ +// Copyright (C) 2023 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +import 'package:flutter/widgets.dart'; +import 'package:flutter_bloc/flutter_bloc.dart'; +import 'package:wyatt_authentication_bloc/src/domain/entities/account.dart'; +import 'package:wyatt_authentication_bloc/src/domain/entities/session.dart'; +import 'package:wyatt_authentication_bloc/src/domain/entities/session_wrapper.dart'; +import 'package:wyatt_authentication_bloc/src/features/authentication/cubit/authentication_cubit.dart'; + +/// Extension that helps to quickly access useful resources like wrapper, +/// session, account or data. +extension BuildContextExtension on BuildContext { + /// Returns session wrapper + SessionWrapper? wrapper, Data>() => + watch().currentSession(); + + /// Returns session + Session? session, Data>() => + watch().currentSession()?.session; + + /// Returns account + Account? account, Data>() => + watch().currentSession()?.session?.account; + + /// Returns associated data + Data? data, Data>() => + watch().currentSession()?.session?.data; +} diff --git a/packages/wyatt_authentication_bloc/lib/src/core/utils/custom_routine.dart b/packages/wyatt_authentication_bloc/lib/src/core/utils/custom_routine.dart new file mode 100644 index 00000000..db8b4265 --- /dev/null +++ b/packages/wyatt_authentication_bloc/lib/src/core/utils/custom_routine.dart @@ -0,0 +1,62 @@ +// ignore_for_file: public_member_api_docs, sort_constructors_first +// Copyright (C) 2023 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +import 'dart:async'; + +import 'package:wyatt_architecture/wyatt_architecture.dart'; +import 'package:wyatt_type_utils/wyatt_type_utils.dart'; + +/// Calls on each cubit action of this package. +/// +/// Useful to register custom logic on pre-implemented logic. +class CustomRoutine { + const CustomRoutine({ + required this.routine, + required this.attachedLogic, + required this.onError, + required this.onSuccess, + }); + + final FutureOr> Function() routine; + final FutureOr> Function( + Result routineResult, + ) attachedLogic; + final void Function(AppException? exception) onError; + final void Function(R result, Data? data) onSuccess; + + FutureOr call() async { + final result = await routine.call(); + + // Call custom logic + final customRoutineResult = await attachedLogic.call(result); + + // Check for errors + if (result.isErr) { + onError.call(result.err); + + return; + } + if (customRoutineResult.isErr) { + onError.call(customRoutineResult.err); + + return; + } + + // If no error + return onSuccess.call(result.ok as Input, customRoutineResult.ok); + } +} diff --git a/packages/wyatt_authentication_bloc/lib/src/data/data.dart b/packages/wyatt_authentication_bloc/lib/src/data/data.dart index 35d3fdd1..581cd9c5 100644 --- a/packages/wyatt_authentication_bloc/lib/src/data/data.dart +++ b/packages/wyatt_authentication_bloc/lib/src/data/data.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify diff --git a/packages/wyatt_authentication_bloc/lib/src/data/data_sources/data_sources.dart b/packages/wyatt_authentication_bloc/lib/src/data/data_sources/data_sources.dart index 24eff56f..65cebddf 100644 --- a/packages/wyatt_authentication_bloc/lib/src/data/data_sources/data_sources.dart +++ b/packages/wyatt_authentication_bloc/lib/src/data/data_sources/data_sources.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify @@ -14,6 +14,4 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . -export 'local/authentication_cache_data_source_impl.dart'; export 'remote/authentication_firebase_data_source_impl.dart'; -export 'remote/authentication_mock_data_source_impl.dart'; diff --git a/packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/authentication_firebase_data_source_impl.dart b/packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/authentication_firebase_data_source_impl.dart index 5bc23a2d..2d75d36a 100644 --- a/packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/authentication_firebase_data_source_impl.dart +++ b/packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/authentication_firebase_data_source_impl.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify @@ -16,33 +16,109 @@ import 'dart:async'; +import 'package:firebase_auth/firebase_auth.dart'; +import 'package:google_sign_in/google_sign_in.dart'; import 'package:rxdart/subjects.dart'; -import 'package:wyatt_authentication_bloc/src/data/models/account_model_firebase.dart'; -import 'package:wyatt_authentication_bloc/wyatt_authentication_bloc.dart'; +import 'package:wyatt_authentication_bloc/src/core/exceptions/exceptions.dart'; +import 'package:wyatt_authentication_bloc/src/data/models/models.dart'; +import 'package:wyatt_authentication_bloc/src/domain/data_sources/remote/authentication_remote_data_source.dart'; +import 'package:wyatt_authentication_bloc/src/domain/entities/account.dart'; +import 'package:wyatt_authentication_bloc/src/domain/entities/authentication_change_event/authentication_change_event.dart'; +import 'package:wyatt_authentication_bloc/src/domain/entities/session_wrapper.dart'; import 'package:wyatt_type_utils/wyatt_type_utils.dart'; -class AuthenticationFirebaseDataSourceImpl - extends AuthenticationRemoteDataSource { +class AuthenticationFirebaseDataSourceImpl + extends AuthenticationRemoteDataSource { AuthenticationFirebaseDataSourceImpl({ FirebaseAuth? firebaseAuth, GoogleSignIn? googleSignIn, }) : _firebaseAuth = firebaseAuth ?? FirebaseAuth.instance, _googleSignIn = googleSignIn ?? GoogleSignIn() { - // _accountStream = StreamController(); - _accountStream = BehaviorSubject(); + _latestCredentials = BehaviorSubject(); + _sessionStream = BehaviorSubject(); + // Check for account in memory (persistence) - final currentAccount = (_firebaseAuth.currentUser != null) - ? AccountModelFirebase.fromFirebaseUser(_firebaseAuth.currentUser) - : null; - _accountStream.add(currentAccount); + _checkForCachedAccount(); } - late StreamController _accountStream; + late StreamController> _sessionStream; + late StreamController _latestCredentials; final FirebaseAuth _firebaseAuth; final GoogleSignIn _googleSignIn; - UserCredential? _latestCreds; + Future _checkForCachedAccount() async { + final currentUser = _firebaseAuth.currentUser; + + if (currentUser == null) { + _sessionStream + .add(const SessionWrapper(event: UnknownAuthenticationEvent())); + return; + } + + final jwt = await currentUser.getIdToken(true); + final currentAccount = AccountModel.fromFirebaseUser( + currentUser, + accessToken: jwt, + ); + _sessionStream.add( + SessionWrapper(event: SignedInFromCacheEvent(account: currentAccount)), + ); + return; + } + + Account _addToStream( + UserCredential userCredential, + AuthenticationChangeEvent Function(Account account) eventBuilder, + ) { + final account = AccountModel.fromFirebaseUserCredential(userCredential); + + _latestCredentials.add(userCredential); + + return account; + } + + // Stream related methods =================================================== + + /// {@macro add_session} + @override + void addSession(SessionWrapper wrapper) { + _sessionStream.add(wrapper); + } + + /// {@macro session_stream} + @override + Stream> sessionStream() => + _sessionStream.stream.asBroadcastStream(); + + // SignUp/SignIn methods ==================================================== + + /// {@macro signup_pwd} + @override + Future signUpWithEmailAndPassword({ + required String email, + required String password, + }) async { + try { + final userCredential = await _firebaseAuth.createUserWithEmailAndPassword( + email: email, + password: password, + ); + + return _addToStream( + userCredential, + (account) => SignedUpEvent( + account: account, + ), + ); + } on FirebaseAuthException catch (e) { + throw SignUpWithEmailAndPasswordFailureFirebase.fromCode(e.code); + } catch (_) { + throw SignUpWithEmailAndPasswordFailureFirebase(); + } + } + + /// {@macro signin_pwd} @override Future signInWithEmailAndPassword({ required String email, @@ -53,11 +129,13 @@ class AuthenticationFirebaseDataSourceImpl email: email, password: password, ); - _latestCreds = userCredential; - final account = - AccountModelFirebase.fromFirebaseUserCredential(userCredential); - _accountStream.add(account); - return account; + + return _addToStream( + userCredential, + (account) => SignedInEvent( + account: account, + ), + ); } on FirebaseAuthException catch (e) { throw SignInWithEmailAndPasswordFailureFirebase.fromCode(e.code); } catch (_) { @@ -65,107 +143,18 @@ class AuthenticationFirebaseDataSourceImpl } } - /// {@macro signup} - @override - Future signUp({ - required String email, - required String password, - }) async { - try { - final userCredential = await _firebaseAuth.createUserWithEmailAndPassword( - email: email, - password: password, - ); - _latestCreds = userCredential; - final account = - AccountModelFirebase.fromFirebaseUserCredential(userCredential); - _accountStream.add(account); - return account; - } on FirebaseAuthException catch (e) { - throw SignUpWithEmailAndPasswordFailureFirebase.fromCode(e.code); - } catch (_) { - throw SignUpWithEmailAndPasswordFailureFirebase(); - } - } - - @override - Future signOut() async { - try { - _latestCreds = null; - await _firebaseAuth.signOut(); - _accountStream.add(null); - } catch (_) { - throw SignOutFailureFirebase(); - } - } - - @override - Future getIdentityToken() async { - try { - final token = await _firebaseAuth.currentUser?.getIdToken(); - if (token.isNotNull) { - return token!; - } else { - throw Exception(); // Get caught just after. - } - } on FirebaseAuthException catch (e) { - throw GetIdTokenFailureFirebase.fromCode(e.code); - } catch (_) { - throw GetIdTokenFailureFirebase(); - } - } - - @override - Stream streamAccount() => _accountStream.stream.asBroadcastStream(); - - @override - Future confirmPasswordReset({ - required String code, - required String newPassword, - }) async { - try { - await _firebaseAuth.confirmPasswordReset( - code: code, - newPassword: newPassword, - ); - } on FirebaseAuthException catch (e) { - throw ConfirmPasswordResetFailureFirebase.fromCode(e.code); - } catch (_) { - throw ConfirmPasswordResetFailureFirebase(); - } - } - - @override - Future sendEmailVerification() async { - try { - await _firebaseAuth.currentUser!.sendEmailVerification(); - } on FirebaseAuthException catch (e) { - throw SendEmailVerificationFailureFirebase.fromCode(e.code); - } catch (_) { - throw SendEmailVerificationFailureFirebase(); - } - } - - @override - Future sendPasswordResetEmail({required String email}) async { - try { - await _firebaseAuth.sendPasswordResetEmail(email: email); - } on FirebaseAuthException catch (e) { - throw SendPasswordResetEmailFailureFirebase.fromCode(e.code); - } catch (_) { - throw SendPasswordResetEmailFailureFirebase(); - } - } - + /// {@macro signin_anom} @override Future signInAnonymously() async { try { final userCredential = await _firebaseAuth.signInAnonymously(); - _latestCreds = userCredential; - final account = - AccountModelFirebase.fromFirebaseUserCredential(userCredential); - _accountStream.add(account); - return account; + + return _addToStream( + userCredential, + (account) => SignedInEvent( + account: account, + ), + ); } on FirebaseAuthException catch (e) { throw SignInAnonymouslyFailureFirebase.fromCode(e.code); } catch (_) { @@ -173,6 +162,7 @@ class AuthenticationFirebaseDataSourceImpl } } + /// {@macro signin_google} @override Future signInWithGoogle() async { try { @@ -192,11 +182,12 @@ class AuthenticationFirebaseDataSourceImpl final userCredential = await _firebaseAuth.signInWithCredential(credential); - _latestCreds = userCredential; - final account = - AccountModelFirebase.fromFirebaseUserCredential(userCredential); - _accountStream.add(account); - return account; + return _addToStream( + userCredential, + (account) => SignedInEvent( + account: account, + ), + ); } on FirebaseAuthException catch (e) { throw SignInWithGoogleFailureFirebase.fromCode(e.code); } catch (_) { @@ -204,6 +195,147 @@ class AuthenticationFirebaseDataSourceImpl } } + /// {@macro signout} + @override + Future signOut() async { + try { + _latestCredentials.add(null); + await _firebaseAuth.signOut(); + } catch (_) { + throw SignOutFailureFirebase(); + } + } + + // Account management methods =============================================== + + /// {@macro refresh} + @override + Future refresh() async { + try { + final jwt = await _firebaseAuth.currentUser?.getIdToken(true); + final account = AccountModel.fromFirebaseUser( + _firebaseAuth.currentUser, + accessToken: jwt, + ); + + return account; + } on FirebaseAuthException catch (e) { + throw RefreshFailureFirebase.fromCode(e.code); + } catch (_) { + throw RefreshFailureFirebase(); + } + } + + /// {@macro reauthenticate} + @override + Future reauthenticate() async { + final latestCreds = + await _latestCredentials.stream.asBroadcastStream().last; + try { + if (latestCreds?.credential != null) { + await _firebaseAuth.currentUser + ?.reauthenticateWithCredential(latestCreds!.credential!); + } else { + throw Exception(); // Get caught just after. + } + + final account = AccountModel.fromFirebaseUser(_firebaseAuth.currentUser); + + return account; + } on FirebaseAuthException catch (e) { + throw ReauthenticateFailureFirebase.fromCode(e.code); + } catch (_) { + throw ReauthenticateFailureFirebase(); + } + } + + /// {@macro update_email} + @override + Future updateEmail({required String email}) async { + try { + await _firebaseAuth.currentUser!.updateEmail(email); + final account = AccountModel.fromFirebaseUser(_firebaseAuth.currentUser); + + return account; + } on FirebaseAuthException catch (e) { + throw UpdateEmailFailureFirebase.fromCode(e.code); + } catch (_) { + throw UpdateEmailFailureFirebase(); + } + } + + /// {@macro update_password} + @override + Future updatePassword({required String password}) async { + try { + await _firebaseAuth.currentUser!.updatePassword(password); + final account = AccountModel.fromFirebaseUser(_firebaseAuth.currentUser); + + return account; + } on FirebaseAuthException catch (e) { + throw UpdatePasswordFailureFirebase.fromCode(e.code); + } catch (_) { + throw UpdatePasswordFailureFirebase(); + } + } + + /// {@macro delete} + @override + Future delete() async { + try { + await _firebaseAuth.currentUser!.delete(); + } on FirebaseAuthException catch (e) { + throw DeleteAccountFailureFirebase.fromCode(e.code); + } catch (_) { + throw DeleteAccountFailureFirebase(); + } + } + + // Email related stuff ====================================================== + + /// {@macro send_email_verification} + @override + Future sendEmailVerification() async { + try { + await _firebaseAuth.currentUser!.sendEmailVerification(); + } on FirebaseAuthException catch (e) { + throw SendEmailVerificationFailureFirebase.fromCode(e.code); + } catch (_) { + throw SendEmailVerificationFailureFirebase(); + } + } + + /// {@macro send_password_reset_email} + @override + Future sendPasswordResetEmail({required String email}) async { + try { + await _firebaseAuth.sendPasswordResetEmail(email: email); + } on FirebaseAuthException catch (e) { + throw SendPasswordResetEmailFailureFirebase.fromCode(e.code); + } catch (_) { + throw SendPasswordResetEmailFailureFirebase(); + } + } + + /// {@macro confirm_password_reset} + @override + Future confirmPasswordReset({ + required String code, + required String newPassword, + }) async { + try { + await _firebaseAuth.confirmPasswordReset( + code: code, + newPassword: newPassword, + ); + } on FirebaseAuthException catch (e) { + throw ConfirmPasswordResetFailureFirebase.fromCode(e.code); + } catch (_) { + throw ConfirmPasswordResetFailureFirebase(); + } + } + + /// {@macro verify_password_reset_code} @override Future verifyPasswordResetCode({required String code}) async { try { @@ -215,68 +347,4 @@ class AuthenticationFirebaseDataSourceImpl throw VerifyPasswordResetCodeFailureFirebase(); } } - - @override - Future refresh() async { - try { - await _firebaseAuth.currentUser!.reload(); - final account = - AccountModelFirebase.fromFirebaseUser(_firebaseAuth.currentUser); - _accountStream.add(account); - } on FirebaseAuthException catch (e) { - throw RefreshFailureFirebase.fromCode(e.code); - } catch (_) { - throw RefreshFailureFirebase(); - } - } - - @override - Future reauthenticateWithCredential() async { - try { - if (_latestCreds?.credential != null) { - await _firebaseAuth.currentUser - ?.reauthenticateWithCredential(_latestCreds!.credential!); - } else { - throw Exception(); // Get caught just after. - } - final account = - AccountModelFirebase.fromFirebaseUser(_firebaseAuth.currentUser); - _accountStream.add(account); - return account; - } on FirebaseAuthException catch (e) { - throw ReauthenticateFailureFirebase.fromCode(e.code); - } catch (_) { - throw ReauthenticateFailureFirebase(); - } - } - - @override - Future updateEmail({required String email}) async { - try { - await _firebaseAuth.currentUser!.updateEmail(email); - final account = - AccountModelFirebase.fromFirebaseUser(_firebaseAuth.currentUser); - _accountStream.add(account); - return account; - } on FirebaseAuthException catch (e) { - throw UpdateEmailFailureFirebase.fromCode(e.code); - } catch (_) { - throw UpdateEmailFailureFirebase(); - } - } - - @override - Future updatePassword({required String password}) async { - try { - await _firebaseAuth.currentUser!.updatePassword(password); - final account = - AccountModelFirebase.fromFirebaseUser(_firebaseAuth.currentUser); - _accountStream.add(account); - return account; - } on FirebaseAuthException catch (e) { - throw UpdatePasswordFailureFirebase.fromCode(e.code); - } catch (_) { - throw UpdatePasswordFailureFirebase(); - } - } } diff --git a/packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/authentication_mock_data_source_impl.dart b/packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/authentication_mock_data_source_impl.dart deleted file mode 100644 index 1ee3a767..00000000 --- a/packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/authentication_mock_data_source_impl.dart +++ /dev/null @@ -1,271 +0,0 @@ -// Copyright (C) 2022 WYATT GROUP -// Please see the AUTHORS file for details. -// -// This program is free software: you can redistribute it and/or modify -// it under the terms of the GNU General Public License as published by -// the Free Software Foundation, either version 3 of the License, or -// any later version. -// -// This program is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with this program. If not, see . - -import 'dart:async'; -import 'dart:math'; - -import 'package:wyatt_authentication_bloc/wyatt_authentication_bloc.dart'; -import 'package:wyatt_type_utils/wyatt_type_utils.dart'; - -class AuthenticationMockDataSourceImpl extends AuthenticationRemoteDataSource { - AuthenticationMockDataSourceImpl({ - this.idToken = 'fake-id-token', - this.registeredAccounts, - }); - Pair? _connectedMock; - Pair? _registeredMock; - DateTime _lastSignInTime = DateTime.now(); - final StreamController _streamAccount = StreamController() - ..add(null); - - final List>? registeredAccounts; - final String idToken; - - Future _randomDelay() async { - await Future.delayed( - Duration(milliseconds: Random().nextInt(400) + 200), - ); - return; - } - - @override - Future confirmPasswordReset({ - required String code, - required String newPassword, - }) async { - await _randomDelay(); - } - - @override - Future getIdentityToken() async { - await _randomDelay(); - return idToken; - } - - @override - Future refresh() async { - await _randomDelay(); - if (_connectedMock.isNull) { - throw RefreshFailureFirebase(); - } - final refresh = DateTime.now(); - final mock = (_connectedMock?.left as AccountModel?) - ?.copyWith(lastSignInTime: refresh); - _connectedMock = _connectedMock?.copyWith(left: mock); - _streamAccount.add(mock); - } - - @override - Future sendEmailVerification() async { - await _randomDelay(); - if (_connectedMock.isNotNull) { - final refresh = DateTime.now(); - final mock = (_connectedMock?.left as AccountModel?)?.copyWith( - emailVerified: false, - lastSignInTime: refresh, - ); - _streamAccount.add(mock); - _connectedMock = _connectedMock?.copyWith(left: mock); - return; - } - throw SendEmailVerificationFailureFirebase(); - } - - @override - Future sendPasswordResetEmail({required String email}) async { - await _randomDelay(); - if (registeredAccounts.isNotNull) { - final accounts = - registeredAccounts?.where((pair) => pair.left?.email == email); - if (accounts.isNotNullOrEmpty) { - return; - } - } - if (_registeredMock.isNotNull) { - if (_registeredMock?.left?.email != email) { - throw SendPasswordResetEmailFailureFirebase(); - } - return; - } - throw SendPasswordResetEmailFailureFirebase(); - } - - @override - Future signInAnonymously() async { - await _randomDelay(); - final creation = DateTime.now(); - final mock = AccountModel( - uid: 'mock-id-anom', - emailVerified: false, - isAnonymous: true, - providerId: 'wyatt-studio.fr', - creationTime: creation, - lastSignInTime: creation, - isNewUser: creation == creation, - ); - _streamAccount.add(mock); - _connectedMock = _connectedMock?.copyWith(left: mock); - _lastSignInTime = DateTime.now(); - return Future.value(mock); - } - - @override - Future signInWithGoogle() async { - await _randomDelay(); - final creation = DateTime.now(); - final mock = AccountModel( - uid: 'mock-id-google', - emailVerified: true, - isAnonymous: false, - providerId: 'google.com', - creationTime: creation, - lastSignInTime: creation, - isNewUser: creation == creation, - ); - _streamAccount.add(mock); - _connectedMock = _connectedMock?.copyWith(left: mock); - _lastSignInTime = DateTime.now(); - return Future.value(mock); - } - - @override - Future signInWithEmailAndPassword({ - required String email, - required String password, - }) async { - await _randomDelay(); - if (registeredAccounts.isNotNull) { - final accounts = - registeredAccounts?.where((pair) => pair.left?.email == email); - if (accounts.isNotNullOrEmpty) { - final account = accounts?.first; - if (account?.right != password) { - throw SignInWithCredentialFailureFirebase.fromCode('wrong-password'); - } - _streamAccount.add(account!.left); - _connectedMock = account.copyWith(); - return account.left!; - } - } - if (_registeredMock.isNotNull) { - if (_registeredMock?.left?.email != email) { - throw SignInWithCredentialFailureFirebase.fromCode('user-not-found'); - } - if (_registeredMock?.right != password) { - throw SignInWithCredentialFailureFirebase.fromCode('wrong-password'); - } - _streamAccount.add(_registeredMock!.left); - _connectedMock = _registeredMock!.copyWith(); - _lastSignInTime = DateTime.now(); - return _registeredMock!.left!; - } - throw SignInWithCredentialFailureFirebase(); - } - - @override - Future signOut() async { - _connectedMock = null; - _streamAccount.add(null); - } - - @override - Future signUp({ - required String email, - required String password, - }) async { - await _randomDelay(); - if (registeredAccounts.isNotNull) { - final accounts = - registeredAccounts?.where((pair) => pair.left?.email == email); - if (accounts.isNotNullOrEmpty) { - throw SignUpWithEmailAndPasswordFailureFirebase.fromCode( - 'email-already-in-use', - ); - } - } - if (_registeredMock?.left?.email == email) { - throw SignUpWithEmailAndPasswordFailureFirebase.fromCode( - 'email-already-in-use', - ); - } - final creation = DateTime.now(); - final mock = AccountModel( - uid: 'mock-id-email', - emailVerified: false, - isAnonymous: false, - providerId: 'wyatt', - email: email, - creationTime: creation, - lastSignInTime: creation, - isNewUser: creation == creation, - ); - _streamAccount.add(mock); - _registeredMock = Pair(mock, password); - _connectedMock = _registeredMock!.copyWith(); - _lastSignInTime = DateTime.now(); - return Future.value(mock); - } - - @override - Stream streamAccount() => _streamAccount.stream.asBroadcastStream(); - - @override - Future verifyPasswordResetCode({required String code}) async { - await _randomDelay(); - return true; - } - - @override - Future reauthenticateWithCredential() async { - await _randomDelay(); - if (_connectedMock.isNull) { - throw ReauthenticateFailureFirebase(); - } - await refresh(); - _lastSignInTime = DateTime.now(); - return Future.value(_connectedMock?.left); - } - - @override - Future updateEmail({required String email}) { - final before = DateTime.now().subtract(const Duration(seconds: 10)); - if (_lastSignInTime.isBefore(before)) { - throw UpdateEmailFailureFirebase('requires-recent-login'); - } - final refresh = DateTime.now(); - final mock = (_connectedMock?.left as AccountModel?) - ?.copyWith(lastSignInTime: refresh, email: email); - _connectedMock = _connectedMock?.copyWith(left: mock); - _registeredMock = _registeredMock?.copyWith(left: mock); - _streamAccount.add(mock); - return Future.value(_connectedMock?.left); - } - - @override - Future updatePassword({required String password}) { - final before = DateTime.now().subtract(const Duration(seconds: 10)); - if (_lastSignInTime.isBefore(before)) { - throw UpdatePasswordFailureFirebase('requires-recent-login'); - } - final refresh = DateTime.now(); - final mock = (_connectedMock?.left as AccountModel?) - ?.copyWith(lastSignInTime: refresh); - _connectedMock = _connectedMock?.copyWith(left: mock, right: password); - _registeredMock = _registeredMock?.copyWith(left: mock, right: password); - _streamAccount.add(mock); - return Future.value(_connectedMock?.left); - } -} diff --git a/packages/wyatt_authentication_bloc/lib/src/data/models/account_model.dart b/packages/wyatt_authentication_bloc/lib/src/data/models/account_model.dart index 0077378b..c79d54e8 100644 --- a/packages/wyatt_authentication_bloc/lib/src/data/models/account_model.dart +++ b/packages/wyatt_authentication_bloc/lib/src/data/models/account_model.dart @@ -1,5 +1,4 @@ -// ignore_for_file: public_member_api_docs, sort_constructors_first -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify @@ -15,74 +14,77 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . +import 'package:firebase_auth/firebase_auth.dart'; +import 'package:wyatt_authentication_bloc/src/core/exceptions/exceptions.dart'; import 'package:wyatt_authentication_bloc/src/domain/entities/account.dart'; +/// Account Model to parse Firebase User data class AccountModel extends Account { - @override - final String uid; + factory AccountModel.fromFirebaseUserCredential( + UserCredential? userCredential, + ) { + final user = userCredential?.user; + if (user != null) { + final providerId = + (user.providerData.isEmpty) ? '' : user.providerData.first.providerId; + return AccountModel._( + user: user, + id: user.uid, + emailVerified: user.emailVerified, + isAnonymous: user.isAnonymous, + providerId: providerId, + creationTime: user.metadata.creationTime, + lastSignInTime: user.metadata.lastSignInTime, + isNewUser: userCredential?.additionalUserInfo?.isNewUser, + email: user.email, + phoneNumber: user.phoneNumber, + photoURL: user.photoURL, + accessToken: userCredential?.credential?.accessToken, + ); + } else { + throw ModelParsingFailureFirebase('null-user', 'User cannot be null'); + } + } - @override - final String? email; - - @override - final DateTime? creationTime; - - @override - final bool emailVerified; - - @override - final bool isAnonymous; - - @override - final bool? isNewUser; - - @override - final DateTime? lastSignInTime; - - @override - final String? phoneNumber; - - @override - final String? photoURL; - - @override - final String providerId; - - AccountModel({ - required this.uid, - required this.emailVerified, - required this.isAnonymous, - required this.providerId, - this.lastSignInTime, - this.creationTime, - this.isNewUser, - this.email, - this.phoneNumber, - this.photoURL, + factory AccountModel.fromFirebaseUser(User? user, {String? accessToken}) { + if (user != null) { + final providerId = + (user.providerData.isEmpty) ? '' : user.providerData.first.providerId; + return AccountModel._( + user: user, + id: user.uid, + emailVerified: user.emailVerified, + isAnonymous: user.isAnonymous, + providerId: providerId, + creationTime: user.metadata.creationTime, + lastSignInTime: user.metadata.lastSignInTime, + isNewUser: false, + email: user.email, + phoneNumber: user.phoneNumber, + photoURL: user.photoURL, + accessToken: accessToken, + ); + } else { + throw ModelParsingFailureFirebase('null-user', 'User cannot be null'); + } + } + const AccountModel._({ + required this.user, + required super.id, + required super.emailVerified, + required super.isAnonymous, + required super.providerId, + super.lastSignInTime, + super.creationTime, + super.isNewUser, + super.email, + super.phoneNumber, + super.photoURL, + super.accessToken, }); - AccountModel copyWith({ - String? uid, - String? email, - DateTime? creationTime, - bool? emailVerified, - bool? isAnonymous, - bool? isNewUser, - DateTime? lastSignInTime, - String? phoneNumber, - String? photoURL, - String? providerId, - }) => - AccountModel( - uid: uid ?? this.uid, - email: email ?? this.email, - creationTime: creationTime ?? this.creationTime, - emailVerified: emailVerified ?? this.emailVerified, - isAnonymous: isAnonymous ?? this.isAnonymous, - isNewUser: isNewUser ?? this.isNewUser, - lastSignInTime: lastSignInTime ?? this.lastSignInTime, - phoneNumber: phoneNumber ?? this.phoneNumber, - photoURL: photoURL ?? this.photoURL, - providerId: providerId ?? this.providerId, - ); + final User? user; + + @override + String? get refreshToken => user?.refreshToken; } diff --git a/packages/wyatt_authentication_bloc/lib/src/data/models/account_model_firebase.dart b/packages/wyatt_authentication_bloc/lib/src/data/models/account_model_firebase.dart deleted file mode 100644 index 07e5b5a0..00000000 --- a/packages/wyatt_authentication_bloc/lib/src/data/models/account_model_firebase.dart +++ /dev/null @@ -1,80 +0,0 @@ -// ignore_for_file: public_member_api_docs, sort_constructors_first -// Copyright (C) 2022 WYATT GROUP -// Please see the AUTHORS file for details. -// -// This program is free software: you can redistribute it and/or modify -// it under the terms of the GNU General Public License as published by -// the Free Software Foundation, either version 3 of the License, or -// any later version. -// -// This program is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with this program. If not, see . - -import 'package:firebase_auth/firebase_auth.dart'; -import 'package:wyatt_authentication_bloc/src/core/exceptions/exceptions.dart'; -import 'package:wyatt_authentication_bloc/src/data/models/account_model.dart'; - -class AccountModelFirebase extends AccountModel { - AccountModelFirebase._({ - required super.uid, - required super.emailVerified, - required super.isAnonymous, - required super.providerId, - super.lastSignInTime, - super.creationTime, - super.isNewUser, - super.email, - super.phoneNumber, - super.photoURL, - }); - - factory AccountModelFirebase.fromFirebaseUser(User? user) { - if (user != null) { - final providerId = - (user.providerData.isEmpty) ? '' : user.providerData.first.providerId; - return AccountModelFirebase._( - uid: user.uid, - emailVerified: user.emailVerified, - isAnonymous: user.isAnonymous, - providerId: providerId, - creationTime: user.metadata.creationTime, - lastSignInTime: user.metadata.lastSignInTime, - isNewUser: false, - email: user.email, - phoneNumber: user.phoneNumber, - photoURL: user.photoURL, - ); - } else { - throw ModelParsingFailureFirebase('null-user', 'User cannot be null'); - } - } - - factory AccountModelFirebase.fromFirebaseUserCredential( - UserCredential? userCredential, - ) { - final user = userCredential?.user; - if (user != null) { - final providerId = - (user.providerData.isEmpty) ? '' : user.providerData.first.providerId; - return AccountModelFirebase._( - uid: user.uid, - emailVerified: user.emailVerified, - isAnonymous: user.isAnonymous, - providerId: providerId, - creationTime: user.metadata.creationTime, - lastSignInTime: user.metadata.lastSignInTime, - isNewUser: userCredential?.additionalUserInfo?.isNewUser, - email: user.email, - phoneNumber: user.phoneNumber, - photoURL: user.photoURL, - ); - } else { - throw ModelParsingFailureFirebase('null-user', 'User cannot be null'); - } - } -} diff --git a/packages/wyatt_authentication_bloc/lib/src/data/models/models.dart b/packages/wyatt_authentication_bloc/lib/src/data/models/models.dart index 14f991fe..3efbdbc0 100644 --- a/packages/wyatt_authentication_bloc/lib/src/data/models/models.dart +++ b/packages/wyatt_authentication_bloc/lib/src/data/models/models.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify @@ -15,4 +15,3 @@ // along with this program. If not, see . export 'account_model.dart'; -export 'account_wrapper_model.dart'; diff --git a/packages/wyatt_authentication_bloc/lib/src/data/repositories/authentication_repository_impl.dart b/packages/wyatt_authentication_bloc/lib/src/data/repositories/authentication_repository_impl.dart index 686be61a..2c25e1bc 100644 --- a/packages/wyatt_authentication_bloc/lib/src/data/repositories/authentication_repository_impl.dart +++ b/packages/wyatt_authentication_bloc/lib/src/data/repositories/authentication_repository_impl.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify @@ -14,49 +14,28 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . -import 'dart:async'; - import 'package:wyatt_architecture/wyatt_architecture.dart'; import 'package:wyatt_authentication_bloc/src/core/constants/form_field.dart'; import 'package:wyatt_authentication_bloc/src/core/constants/form_name.dart'; -import 'package:wyatt_authentication_bloc/src/data/models/account_wrapper_model.dart'; -import 'package:wyatt_authentication_bloc/src/domain/data_sources/local/authentication_cache_data_source.dart'; import 'package:wyatt_authentication_bloc/src/domain/data_sources/remote/authentication_remote_data_source.dart'; import 'package:wyatt_authentication_bloc/src/domain/entities/account.dart'; -import 'package:wyatt_authentication_bloc/src/domain/entities/account_wrapper.dart'; -import 'package:wyatt_authentication_bloc/src/domain/entities/auth_change_event.dart'; +import 'package:wyatt_authentication_bloc/src/domain/entities/session_wrapper.dart'; import 'package:wyatt_authentication_bloc/src/domain/repositories/authentication_repository.dart'; import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; import 'package:wyatt_type_utils/wyatt_type_utils.dart'; -class AuthenticationRepositoryImpl - extends AuthenticationRepository { +class AuthenticationRepositoryImpl + extends AuthenticationRepository { AuthenticationRepositoryImpl({ - required this.authenticationCacheDataSource, required this.authenticationRemoteDataSource, FormRepository? formRepository, // ignore: strict_raw_type List? extraSignUpInputs, FormInputValidator? customEmailValidator, FormInputValidator? customPasswordValidator, - AuthChangeListener? onAuthChange, - AccountStreamTransformer? accountStreamTransformer, - }) : _authChangeListener = onAuthChange, - _accountStreamTransformer = accountStreamTransformer { + }) { _formRepository = formRepository ?? FormRepositoryImpl(); - _accountStreamTransformer ??= (input) => input - .where((event) => event is! SignUpAuthChangeEvent) - .map>>((event) async { - if (listener == null) { - return Ok(AccountWrapperModel(event.account, null)); - } - // Handle sign in, sign out and refresh - final dataResult = await listener!.call(this, event); - return dataResult.map((data) { - authenticationCacheDataSource.storeData(data); - return AccountWrapperModel(event.account, data); - }); - }); + if (formRepository != null) { return; } @@ -104,20 +83,47 @@ class AuthenticationRepositoryImpl ), ); } - final AuthenticationCacheDataSource authenticationCacheDataSource; - final AuthenticationRemoteDataSource authenticationRemoteDataSource; + final AuthenticationRemoteDataSource authenticationRemoteDataSource; late FormRepository _formRepository; - AuthChangeListener? _authChangeListener; - AccountStreamTransformer? _accountStreamTransformer; - + /// {@macro form_repo} @override FormRepository get formRepository => _formRepository; - @override - AuthChangeListener? get listener => _authChangeListener; + // Stream related methods =================================================== + /// {@macro add_session} + @override + void addSession(SessionWrapper wrapper) => + authenticationRemoteDataSource.addSession(wrapper); + + /// {@macro session_stream} + @override + Stream> sessionStream() => + authenticationRemoteDataSource.sessionStream(); + + // SignUp/SignIn methods ==================================================== + + /// {@macro signup_pwd} + @override + FutureOrResult signUpWithEmailAndPassword({ + required String email, + required String password, + }) => + Result.tryCatchAsync( + () async { + final account = + await authenticationRemoteDataSource.signUpWithEmailAndPassword( + email: email, + password: password, + ); + return account; + }, + (error) => error, + ); + + /// {@macro signin_pwd} @override FutureOrResult signInWithEmailAndPassword({ required String email, @@ -130,100 +136,127 @@ class AuthenticationRepositoryImpl email: email, password: password, ); - await authenticationCacheDataSource.storeAccount(account); return account; }, (error) => error, ); + /// {@macro signin_anom} + @override + FutureOrResult signInAnonymously() => + Result.tryCatchAsync( + () async { + final account = + await authenticationRemoteDataSource.signInAnonymously(); + return account; + }, + (error) => error, + ); + + /// {@macro signin_google} + @override + FutureOrResult signInWithGoogle() => + Result.tryCatchAsync( + () async { + final account = + await authenticationRemoteDataSource.signInWithGoogle(); + return account; + }, + (error) => error, + ); + + /// {@macro signout} @override FutureOrResult signOut() => Result.tryCatchAsync( () async { await authenticationRemoteDataSource.signOut(); - await authenticationCacheDataSource.destroy(); }, (error) => error, ); + // Account management methods =============================================== + + /// {@macro refresh} @override - FutureOrResult signUp({ - required String email, - required String password, - }) => + FutureOrResult refresh() => Result.tryCatchAsync( () async { - final account = await authenticationRemoteDataSource.signUp( - email: email, - password: password, - ); - await authenticationCacheDataSource.storeAccount(account); + final account = await authenticationRemoteDataSource.refresh(); return account; }, (error) => error, ); + /// {@macro reauthenticate} @override - FutureOrResult destroyCache() => - Result.tryCatchAsync( - authenticationCacheDataSource.destroy, - (error) => error, - ); - - @override - FutureOrResult> getCache() => - Result.tryCatchAsync, AppException, AppException>( - authenticationCacheDataSource.load, - (error) => error, - ); - - @override - FutureOrResult getAccount() => + FutureOrResult reauthenticate() => Result.tryCatchAsync( - authenticationCacheDataSource.loadAccount, - (error) => error, - ); - - @override - FutureOrResult setAccount( - Account account, - ) => - Result.tryCatchAsync( () async { - await authenticationCacheDataSource.storeAccount(account); + final account = await authenticationRemoteDataSource.reauthenticate(); + return account; }, (error) => error, ); + /// {@macro update_email} @override - FutureOrResult getData() => - Result.tryCatchAsync( - authenticationCacheDataSource.loadData, - (error) => error, - ); - - @override - FutureOrResult setData( - T? data, - ) => - Result.tryCatchAsync( + FutureOrResult updateEmail({required String email}) => + Result.tryCatchAsync( () async { - await authenticationCacheDataSource.storeData(data); + final account = + await authenticationRemoteDataSource.updateEmail(email: email); + return account; }, (error) => error, ); + /// {@macro update_password} @override - FutureOrResult getIdentityToken() => - Result.tryCatchAsync( - authenticationRemoteDataSource.getIdentityToken, + FutureOrResult updatePassword({required String password}) => + Result.tryCatchAsync( + () async { + final account = await authenticationRemoteDataSource.updatePassword( + password: password, + ); + return account; + }, (error) => error, ); + /// {@macro delete} @override - Stream>> streamAccount() => - _accountStreamTransformer!.call(changes()); + FutureOrResult delete() => + Result.tryCatchAsync( + () async => authenticationRemoteDataSource.delete(), + (error) => error, + ); + // Email related stuff ====================================================== + + /// {@macro send_email_verification} + @override + FutureOrResult sendEmailVerification() => + Result.tryCatchAsync( + () async { + await authenticationRemoteDataSource.sendEmailVerification(); + }, + (error) => error, + ); + + /// {@macro send_password_reset_email} + @override + FutureOrResult sendPasswordResetEmail({required String email}) => + Result.tryCatchAsync( + () async { + await authenticationRemoteDataSource.sendPasswordResetEmail( + email: email, + ); + }, + (error) => error, + ); + + /// {@macro confirm_password_reset} @override FutureOrResult confirmPasswordReset({ required String code, @@ -239,48 +272,7 @@ class AuthenticationRepositoryImpl (error) => error, ); - @override - FutureOrResult sendEmailVerification() => - Result.tryCatchAsync( - () async { - await authenticationRemoteDataSource.sendEmailVerification(); - }, - (error) => error, - ); - - @override - FutureOrResult sendPasswordResetEmail({required String email}) => - Result.tryCatchAsync( - () async { - await authenticationRemoteDataSource.sendPasswordResetEmail( - email: email, - ); - }, - (error) => error, - ); - - @override - FutureOrResult signInAnonymously() => - Result.tryCatchAsync( - () async { - final account = - await authenticationRemoteDataSource.signInAnonymously(); - return account; - }, - (error) => error, - ); - - @override - FutureOrResult signInWithGoogle() => - Result.tryCatchAsync( - () async { - final account = - await authenticationRemoteDataSource.signInWithGoogle(); - return account; - }, - (error) => error, - ); - + /// {@macro verify_password_reset_code} @override FutureOrResult verifyPasswordResetCode({required String code}) => Result.tryCatchAsync( @@ -291,91 +283,4 @@ class AuthenticationRepositoryImpl }, (error) => error, ); - - @override - FutureOrResult refresh() => - Result.tryCatchAsync( - () async { - await authenticationRemoteDataSource.refresh(); - }, - (error) => error, - ); - - @override - FutureOrResult reauthenticateWithCredential() => - Result.tryCatchAsync( - () async { - final account = await authenticationRemoteDataSource - .reauthenticateWithCredential(); - return account; - }, - (error) => error, - ); - - @override - FutureOrResult updateEmail({required String email}) => - Result.tryCatchAsync( - () async { - final account = - await authenticationRemoteDataSource.updateEmail(email: email); - return account; - }, - (error) => error, - ); - - @override - FutureOrResult updatePassword({required String password}) => - Result.tryCatchAsync( - () async { - final account = await authenticationRemoteDataSource.updatePassword( - password: password, - ); - return account; - }, - (error) => error, - ); - - Account? _lastChange; - - @override - Stream changes() => authenticationRemoteDataSource - .streamAccount() - .map((account) { - if (_lastChange != null && account == null) { - _lastChange = null; - return SignOutAuthChangeEvent(); - } - if (_lastChange == null && account != null) { - _lastChange = account; - if (account.isNewUser ?? false) { - if (account.isAnonymous) { - return AnonymousSignInAuthChangeEvent(account); - } - return SignUpAuthChangeEvent(account); - } - return SignInAuthChangeEvent(account); - } - if (_lastChange != null && account != null) { - _lastChange = account; - return RefreshAuthChangeEvent(account); - } - if (_lastChange == null && account == null) { - _lastChange = account; - return StillUnauthenticatedAuthChangeEvent(); - } - _lastChange = account; - return RefreshAuthChangeEvent(account); - }); - - @override - FutureOrResult addAuthChangeListener(AuthChangeListener listener) { - _authChangeListener = listener; - return const Ok(null); - } - - @override - FutureOrResult removeAuthChangeListener() { - _authChangeListener = null; - return const Ok(null); - } } diff --git a/packages/wyatt_authentication_bloc/lib/src/data/repositories/repositories.dart b/packages/wyatt_authentication_bloc/lib/src/data/repositories/repositories.dart index d5979688..0081a38c 100644 --- a/packages/wyatt_authentication_bloc/lib/src/data/repositories/repositories.dart +++ b/packages/wyatt_authentication_bloc/lib/src/data/repositories/repositories.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/data_sources/data_sources.dart b/packages/wyatt_authentication_bloc/lib/src/domain/data_sources/data_sources.dart index 11efe02d..4a8f3011 100644 --- a/packages/wyatt_authentication_bloc/lib/src/domain/data_sources/data_sources.dart +++ b/packages/wyatt_authentication_bloc/lib/src/domain/data_sources/data_sources.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify @@ -14,5 +14,4 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . -export 'local/authentication_cache_data_source.dart'; export 'remote/authentication_remote_data_source.dart'; diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/data_sources/remote/authentication_remote_data_source.dart b/packages/wyatt_authentication_bloc/lib/src/domain/data_sources/remote/authentication_remote_data_source.dart index 8205bd8d..6bec3426 100644 --- a/packages/wyatt_authentication_bloc/lib/src/domain/data_sources/remote/authentication_remote_data_source.dart +++ b/packages/wyatt_authentication_bloc/lib/src/domain/data_sources/remote/authentication_remote_data_source.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify @@ -16,9 +16,20 @@ import 'package:wyatt_architecture/wyatt_architecture.dart'; import 'package:wyatt_authentication_bloc/src/domain/entities/account.dart'; +import 'package:wyatt_authentication_bloc/src/domain/entities/session_wrapper.dart'; -abstract class AuthenticationRemoteDataSource extends BaseRemoteDataSource { - Future signUp({ +/// Is responsible for abstracting the provenance of the data. +abstract class AuthenticationRemoteDataSource + extends BaseRemoteDataSource { + // Stream related methods =================================================== + + void addSession(SessionWrapper wrapper); + + Stream> sessionStream(); + + // SignUp/SignIn methods ==================================================== + + Future signUpWithEmailAndPassword({ required String email, required String password, }); @@ -27,33 +38,27 @@ abstract class AuthenticationRemoteDataSource extends BaseRemoteDataSource { required String email, required String password, }); + Future signInAnonymously(); + Future signInWithGoogle(); Future signOut(); - Future refresh(); + // Account management methods =============================================== + + // Future linkCurrentUserWith(AuthenticationProvider anotherProvider); + Future refresh(); + Future reauthenticate(); + Future updateEmail({required String email}); + Future updatePassword({required String password}); + Future delete(); - Stream streamAccount(); - - Future getIdentityToken(); + // Email related stuff ====================================================== Future sendEmailVerification(); - Future sendPasswordResetEmail({required String email}); - Future confirmPasswordReset({ required String code, required String newPassword, }); - Future verifyPasswordResetCode({required String code}); - - Future signInAnonymously(); - - Future signInWithGoogle(); - - Future updateEmail({required String email}); - - Future updatePassword({required String password}); - - Future reauthenticateWithCredential(); } diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/domain.dart b/packages/wyatt_authentication_bloc/lib/src/domain/domain.dart index 6f4ec438..25af7843 100644 --- a/packages/wyatt_authentication_bloc/lib/src/domain/domain.dart +++ b/packages/wyatt_authentication_bloc/lib/src/domain/domain.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/entities/account.dart b/packages/wyatt_authentication_bloc/lib/src/domain/entities/account.dart index 5723d3a5..ee6cd353 100644 --- a/packages/wyatt_authentication_bloc/lib/src/domain/entities/account.dart +++ b/packages/wyatt_authentication_bloc/lib/src/domain/entities/account.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify @@ -17,67 +17,88 @@ import 'package:equatable/equatable.dart'; import 'package:wyatt_architecture/wyatt_architecture.dart'; -abstract class Account extends Equatable implements Entity { +/// Represents a user [Account] in the +/// various identity provisioning systems. +class Account extends Equatable implements Entity { + const Account({ + required this.id, + required this.isAnonymous, + required this.emailVerified, + required this.providerId, + this.email, + this.phoneNumber, + this.photoURL, + this.creationTime, + this.lastSignInTime, + this.isNewUser, + this.accessToken, + this.refreshToken, + }); + /// The user's unique ID. - String get uid; + final String id; + + /// Returns whether the user is a anonymous. + final bool isAnonymous; /// The users email address. /// /// Will be `null` if signing in anonymously. - String? get email; + final String? email; /// Returns whether the users email address has been verified. /// /// To send a verification email, see `SendEmailVerification`. - bool get emailVerified; - - /// Returns whether the user is a anonymous. - bool get isAnonymous; - - /// Returns the users account creation time. - /// - /// When this account was created as dictated by the server clock. - DateTime? get creationTime; - - /// When the user last signed in as dictated by the server clock. - DateTime? get lastSignInTime; + final bool emailVerified; /// Returns the users phone number. /// /// This property will be `null` if the user has not signed in or been has /// their phone number linked. - String? get phoneNumber; + final String? phoneNumber; /// Returns a photo URL for the user. /// /// This property will be populated if the user has signed in or been linked /// with a 3rd party OAuth provider (such as Google). - String? get photoURL; + final String? photoURL; - /// The provider ID for the user. - String get providerId; + /// Returns the users account creation time. + /// + /// When this account was created as dictated by the server clock. + final DateTime? creationTime; + + /// When the user last signed in as dictated by the server clock. + final DateTime? lastSignInTime; /// Whether the user account has been recently created. - bool? get isNewUser; + final bool? isNewUser; + + /// The provider ID for the user. + final String providerId; + + /// The user access token + final String? accessToken; + + /// The user refresh token + final String? refreshToken; @override List get props => [ - uid, + id, + isAnonymous, email, emailVerified, - isAnonymous, - creationTime, - lastSignInTime, phoneNumber, photoURL, + creationTime, + lastSignInTime, providerId, isNewUser, + accessToken, + refreshToken, ]; @override - String toString() => 'AccountModel(uid: $uid, email: $email, ' - 'creationTime: $creationTime, emailVerified: $emailVerified, ' - 'isAnonymous: $isAnonymous, isNewUser: $isNewUser, lastSignInTime: ' - '$lastSignInTime, phoneNumber: $phoneNumber, photoURL: $photoURL, ' - 'providerId: $providerId)'; + bool get stringify => true; } diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/entities/auth_change_event.dart b/packages/wyatt_authentication_bloc/lib/src/domain/entities/auth_change_event.dart deleted file mode 100644 index d2e38a33..00000000 --- a/packages/wyatt_authentication_bloc/lib/src/domain/entities/auth_change_event.dart +++ /dev/null @@ -1,51 +0,0 @@ -// Copyright (C) 2022 WYATT GROUP -// Please see the AUTHORS file for details. -// -// This program is free software: you can redistribute it and/or modify -// it under the terms of the GNU General Public License as published by -// the Free Software Foundation, either version 3 of the License, or -// any later version. -// -// This program is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with this program. If not, see . - -import 'package:wyatt_authentication_bloc/src/domain/entities/account.dart'; - -abstract class AuthChangeEvent { - AuthChangeEvent(this.account); - - final Account? account; -} - -class SignInAuthChangeEvent extends AuthChangeEvent { - SignInAuthChangeEvent(super.account); -} - -class AnonymousSignInAuthChangeEvent extends AuthChangeEvent { - AnonymousSignInAuthChangeEvent(super.account); -} - -class ProviderSignInAuthChangeEvent extends AuthChangeEvent { - ProviderSignInAuthChangeEvent(super.account); -} - -class SignUpAuthChangeEvent extends AuthChangeEvent { - SignUpAuthChangeEvent(super.account); -} - -class RefreshAuthChangeEvent extends AuthChangeEvent { - RefreshAuthChangeEvent(super.account); -} - -class StillUnauthenticatedAuthChangeEvent extends AuthChangeEvent { - StillUnauthenticatedAuthChangeEvent() : super(null); -} - -class SignOutAuthChangeEvent extends AuthChangeEvent { - SignOutAuthChangeEvent() : super(null); -} diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/data_sources/local/authentication_cache_data_source.dart b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/authentication_change_event.dart similarity index 55% rename from packages/wyatt_authentication_bloc/lib/src/domain/data_sources/local/authentication_cache_data_source.dart rename to packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/authentication_change_event.dart index c4d357e5..51d6e511 100644 --- a/packages/wyatt_authentication_bloc/lib/src/domain/data_sources/local/authentication_cache_data_source.dart +++ b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/authentication_change_event.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify @@ -14,16 +14,28 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . +import 'package:equatable/equatable.dart'; import 'package:wyatt_architecture/wyatt_architecture.dart'; import 'package:wyatt_authentication_bloc/src/domain/entities/account.dart'; -import 'package:wyatt_authentication_bloc/src/domain/entities/account_wrapper.dart'; -abstract class AuthenticationCacheDataSource - extends BaseLocalDataSource { - Future storeAccount(Account? account); - Future storeData(T? data); - Future loadAccount(); - Future loadData(); - Future> load(); - Future destroy(); +part 'signed_in_event.dart'; +part 'signed_out_event.dart'; +part 'signed_up_event.dart'; +part 'refreshed_event.dart'; +part 'reauthenticated_event.dart'; +part 'updated_event.dart'; +part 'unknown_authentication_event.dart'; +part 'signed_in_from_cache_event.dart'; +part 'deleted_event.dart'; + +/// Represents an event initiated by a change in +/// the user's authentication status. +abstract class AuthenticationChangeEvent extends Equatable implements Entity { + const AuthenticationChangeEvent(); + + @override + List get props => []; + + @override + bool get stringify => true; } diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/deleted_event.dart b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/deleted_event.dart new file mode 100644 index 00000000..2eff8187 --- /dev/null +++ b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/deleted_event.dart @@ -0,0 +1,22 @@ +// Copyright (C) 2023 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +part of 'authentication_change_event.dart'; + +/// When a user deleted his account. +class DeletedEvent extends AuthenticationChangeEvent { + const DeletedEvent(); +} diff --git a/packages/wyatt_authentication_bloc/lib/src/data/models/account_wrapper_model.dart b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/reauthenticated_event.dart similarity index 53% rename from packages/wyatt_authentication_bloc/lib/src/data/models/account_wrapper_model.dart rename to packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/reauthenticated_event.dart index 4dae7f6b..2ad9c96f 100644 --- a/packages/wyatt_authentication_bloc/lib/src/data/models/account_wrapper_model.dart +++ b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/reauthenticated_event.dart @@ -1,5 +1,4 @@ -// ignore_for_file: public_member_api_docs, sort_constructors_first -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify @@ -15,23 +14,16 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . -import 'package:wyatt_authentication_bloc/src/domain/entities/account.dart'; -import 'package:wyatt_authentication_bloc/src/domain/entities/account_wrapper.dart'; +part of 'authentication_change_event.dart'; + +/// When a user re-authenticates (from the logged in state to the +/// logged in state with a different and fresh access +/// token and a different login time) +class ReauthenticatedEvent extends AuthenticationChangeEvent { + const ReauthenticatedEvent({required this.account}); + + final Account account; -class AccountWrapperModel extends AccountWrapper { @override - final Account? account; - @override - final T? data; - - AccountWrapperModel(this.account, this.data); - - AccountWrapperModel copyWith({ - Account? account, - T? data, - }) => - AccountWrapperModel( - account ?? this.account, - data ?? this.data, - ); + List get props => [account]; } diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/refreshed_event.dart b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/refreshed_event.dart new file mode 100644 index 00000000..ce8651d3 --- /dev/null +++ b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/refreshed_event.dart @@ -0,0 +1,28 @@ +// Copyright (C) 2023 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +part of 'authentication_change_event.dart'; + +/// When a user access token is refreshed (from the logged in state to the +/// logged in state with a different access token) +class RefreshedEvent extends AuthenticationChangeEvent { + const RefreshedEvent({required this.account}); + + final Account account; + + @override + List get props => [account]; +} diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/signed_in_event.dart b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/signed_in_event.dart new file mode 100644 index 00000000..22cd6296 --- /dev/null +++ b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/signed_in_event.dart @@ -0,0 +1,27 @@ +// Copyright (C) 2023 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +part of 'authentication_change_event.dart'; + +/// When a user authenticates (from not logged in to logged in). +class SignedInEvent extends AuthenticationChangeEvent { + const SignedInEvent({required this.account}); + + final Account account; + + @override + List get props => [account]; +} diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/signed_in_from_cache_event.dart b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/signed_in_from_cache_event.dart new file mode 100644 index 00000000..b32f098a --- /dev/null +++ b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/signed_in_from_cache_event.dart @@ -0,0 +1,27 @@ +// Copyright (C) 2023 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +part of 'authentication_change_event.dart'; + +/// When a user authenticates automatically (from not logged in to logged in). +class SignedInFromCacheEvent extends AuthenticationChangeEvent { + const SignedInFromCacheEvent({required this.account}); + + final Account account; + + @override + List get props => [account]; +} diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/signed_out_event.dart b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/signed_out_event.dart new file mode 100644 index 00000000..e7579097 --- /dev/null +++ b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/signed_out_event.dart @@ -0,0 +1,22 @@ +// Copyright (C) 2023 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +part of 'authentication_change_event.dart'; + +/// When a user logs out. +class SignedOutEvent extends AuthenticationChangeEvent { + const SignedOutEvent(); +} diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/signed_up_event.dart b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/signed_up_event.dart new file mode 100644 index 00000000..6683e0fa --- /dev/null +++ b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/signed_up_event.dart @@ -0,0 +1,27 @@ +// Copyright (C) 2023 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +part of 'authentication_change_event.dart'; + +/// When a user creates an account. +class SignedUpEvent extends AuthenticationChangeEvent { + const SignedUpEvent({required this.account}); + + final Account account; + + @override + List get props => [account]; +} diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/unknown_authentication_event.dart b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/unknown_authentication_event.dart new file mode 100644 index 00000000..93c56dec --- /dev/null +++ b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/unknown_authentication_event.dart @@ -0,0 +1,22 @@ +// Copyright (C) 2023 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +part of 'authentication_change_event.dart'; + +/// When a user's login status is unknown. +class UnknownAuthenticationEvent extends AuthenticationChangeEvent { + const UnknownAuthenticationEvent(); +} diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/updated_event.dart b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/updated_event.dart new file mode 100644 index 00000000..f64e6c74 --- /dev/null +++ b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/updated_event.dart @@ -0,0 +1,27 @@ +// Copyright (C) 2023 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +part of 'authentication_change_event.dart'; + +/// When the user's account has been updated. +class UpdatedEvent extends AuthenticationChangeEvent { + const UpdatedEvent({required this.account}); + + final Account account; + + @override + List get props => [account]; +} diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/entities/entities.dart b/packages/wyatt_authentication_bloc/lib/src/domain/entities/entities.dart index 9c83225f..a466a036 100644 --- a/packages/wyatt_authentication_bloc/lib/src/domain/entities/entities.dart +++ b/packages/wyatt_authentication_bloc/lib/src/domain/entities/entities.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify @@ -15,5 +15,6 @@ // along with this program. If not, see . export 'account.dart'; -export 'account_wrapper.dart'; -export 'auth_change_event.dart'; +export 'authentication_change_event/authentication_change_event.dart'; +export 'session.dart'; +export 'session_wrapper.dart'; diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/entities/account_wrapper.dart b/packages/wyatt_authentication_bloc/lib/src/domain/entities/session.dart similarity index 70% rename from packages/wyatt_authentication_bloc/lib/src/domain/entities/account_wrapper.dart rename to packages/wyatt_authentication_bloc/lib/src/domain/entities/session.dart index 0788e03e..61162ee8 100644 --- a/packages/wyatt_authentication_bloc/lib/src/domain/entities/account_wrapper.dart +++ b/packages/wyatt_authentication_bloc/lib/src/domain/entities/session.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify @@ -15,16 +15,22 @@ // along with this program. If not, see . import 'package:equatable/equatable.dart'; -import 'package:wyatt_architecture/wyatt_architecture.dart'; import 'package:wyatt_authentication_bloc/src/domain/entities/account.dart'; -abstract class AccountWrapper extends Equatable implements Entity { - Account? get account; - T? get data; - +/// The [Session] object is used to transport and propagate +/// the connected user [Account] and personalized [Data] in the application. +class Session extends Equatable { + const Session({ + required this.account, + this.data, + }); + + final Account account; + final Data? data; + @override List get props => [account, data]; @override - String toString() => 'AccountWrapper($account, data: $data)'; + bool? get stringify => true; } diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/entities/session_wrapper.dart b/packages/wyatt_authentication_bloc/lib/src/domain/entities/session_wrapper.dart new file mode 100644 index 00000000..4fa2b924 --- /dev/null +++ b/packages/wyatt_authentication_bloc/lib/src/domain/entities/session_wrapper.dart @@ -0,0 +1,38 @@ +// Copyright (C) 2023 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +import 'package:equatable/equatable.dart'; +import 'package:wyatt_architecture/wyatt_architecture.dart'; +import 'package:wyatt_authentication_bloc/src/domain/entities/authentication_change_event/authentication_change_event.dart'; +import 'package:wyatt_authentication_bloc/src/domain/entities/session.dart'; + +/// Contains the [AuthenticationChangeEvent] initiating the state +/// change and the current [Session]. +class SessionWrapper extends Equatable implements Entity { + const SessionWrapper({ + required this.event, + this.session, + }); + + final AuthenticationChangeEvent event; + final Session? session; + + @override + List get props => [event, session]; + + @override + bool get stringify => true; +} diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/repositories/authentication_repository.dart b/packages/wyatt_authentication_bloc/lib/src/domain/repositories/authentication_repository.dart index 3e958f78..1eb6fc25 100644 --- a/packages/wyatt_authentication_bloc/lib/src/domain/repositories/authentication_repository.dart +++ b/packages/wyatt_authentication_bloc/lib/src/domain/repositories/authentication_repository.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify @@ -16,31 +16,30 @@ import 'package:wyatt_architecture/wyatt_architecture.dart'; import 'package:wyatt_authentication_bloc/src/domain/entities/account.dart'; -import 'package:wyatt_authentication_bloc/src/domain/entities/account_wrapper.dart'; -import 'package:wyatt_authentication_bloc/src/domain/entities/auth_change_event.dart'; +import 'package:wyatt_authentication_bloc/src/domain/entities/session_wrapper.dart'; import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; -typedef SignUpCallback = FutureOrResult Function( - AuthenticationRepository repo, - Account? account, - WyattForm form, -); - -typedef AuthChangeListener = FutureOrResult Function( - AuthenticationRepository repo, - AuthChangeEvent? authEvent, -); - -typedef AccountStreamTransformer - = Stream>> Function( - Stream input, -); - -abstract class AuthenticationRepository extends BaseRepository { +abstract class AuthenticationRepository extends BaseRepository { + /// {@template form_repo} + /// Form repository used in different authentication cubits/blocs + /// {@endtemplate} FormRepository get formRepository; - AuthChangeListener? get listener; - /// {@template signup} + // Stream related methods =================================================== + + /// {@template add_session} + /// Add a new authentication event. + /// {@endtemplate} + void addSession(SessionWrapper wrapper); + + /// {@template session_stream} + /// Authentication state change event stream. + /// {@endtemplate} + Stream> sessionStream(); + + // SignUp/SignIn methods ==================================================== + + /// {@template signup_pwd} /// Creates a new user with the provided [email] and [password]. /// /// Returns the newly created user's unique identifier. @@ -48,11 +47,89 @@ abstract class AuthenticationRepository extends BaseRepository { /// Throws a SignUpWithEmailAndPasswordFailureInterface if /// an exception occurs. /// {@endtemplate} - FutureOrResult signUp({ + FutureOrResult signUpWithEmailAndPassword({ required String email, required String password, }); + /// {@template signin_pwd} + /// Signs in with the provided [email] and [password]. + /// + /// Throws a SignInWithEmailAndPasswordFailureInterface if + /// an exception occurs. + /// {@endtemplate} + FutureOrResult signInWithEmailAndPassword({ + required String email, + required String password, + }); + + /// {@template signin_anom} + /// Sign in anonymously. + /// + /// Throws a SignInAnonymouslyFailureInterface if an exception occurs. + /// {@endtemplate} + FutureOrResult signInAnonymously(); + + /// {@template signin_google} + /// Starts the Sign In with Google Flow. + /// + /// Throws a SignInWithGoogleFailureInterface if an exception occurs. + /// {@endtemplate} + FutureOrResult signInWithGoogle(); + + /// {@template signout} + /// Signs out the current user. + /// It also clears the cache and the associated data. + /// {@endtemplate} + FutureOrResult signOut(); + + // Account management methods =============================================== + + /// {@template refresh} + /// Refreshes the current user, if signed in. + /// {@endtemplate} + FutureOrResult refresh(); + + /// {@template reauthenticate} + /// Some security-sensitive actions—such as deleting an account, + /// setting a primary email address, and changing a password—require that + /// the user has recently signed in. + /// + /// Throws a ReauthenticateFailureInterface if + /// an exception occurs. + /// {@endtemplate} + FutureOrResult reauthenticate(); + + /// {@template update_email} + /// Update or add [email]. + /// + /// Throws a UpdateEmailFailureInterface if + /// an exception occurs. + /// {@endtemplate} + FutureOrResult updateEmail({ + required String email, + }); + + /// {@template update_password} + /// Update or add [password]. + /// + /// Throws a UpdatePasswordFailureInterface if + /// an exception occurs. + /// {@endtemplate} + FutureOrResult updatePassword({ + required String password, + }); + + /// {@template delete} + /// Delete account. + /// + /// Throws a DeleteAccountFailureInterface if + /// an exception occurs. + /// {@endtemplate} + FutureOrResult delete(); + + // Email related stuff ====================================================== + /// {@template send_email_verification} /// Sends verification email to the account email. /// @@ -83,95 +160,4 @@ abstract class AuthenticationRepository extends BaseRepository { /// Throws a VerifyPasswordResetCodeFailureInterface if an exception occurs. /// {@endtemplate} FutureOrResult verifyPasswordResetCode({required String code}); - - /// {@template signin_anom} - /// Sign in anonymously. - /// - /// Throws a SignInAnonymouslyFailureInterface if an exception occurs. - /// {@endtemplate} - FutureOrResult signInAnonymously(); - - /// {@template signin_google} - /// Starts the Sign In with Google Flow. - /// - /// Throws a SignInWithGoogleFailureInterface if an exception occurs. - /// {@endtemplate} - FutureOrResult signInWithGoogle(); - - /// {@template signin_pwd} - /// Signs in with the provided [email] and [password]. - /// - /// Throws a SignInWithEmailAndPasswordFailureInterface if - /// an exception occurs. - /// {@endtemplate} - FutureOrResult signInWithEmailAndPassword({ - required String email, - required String password, - }); - - /// {@template update_email} - /// Update or add [email]. - /// - /// Throws a UpdateEmailFailureInterface if - /// an exception occurs. - /// {@endtemplate} - FutureOrResult updateEmail({ - required String email, - }); - - /// {@template update_password} - /// Update or add [password]. - /// - /// Throws a UpdatePasswordFailureInterface if - /// an exception occurs. - /// {@endtemplate} - FutureOrResult updatePassword({ - required String password, - }); - - /// {@template reauthenticate} - /// Some security-sensitive actions—such as deleting an account, - /// setting a primary email address, and changing a password—require that - /// the user has recently signed in. - /// - /// Throws a ReauthenticateFailureInterface if - /// an exception occurs. - /// {@endtemplate} - FutureOrResult reauthenticateWithCredential(); - - /// {@template signout} - /// Signs out the current user. - /// It also clears the cache and the associated data. - /// {@endtemplate} - FutureOrResult signOut(); - - /// {@template refresh} - /// Refreshes the current user, if signed in. - /// {@endtemplate} - FutureOrResult refresh(); - - /// {@template stream_account} - /// Stream of [AccountWrapper] which will emit the current account when - /// the authentication state changes. - /// - /// Emits [AccountWrapper] with null [Account] if the user is not - /// authenticated. - /// {@endtemplate} - Stream>> streamAccount(); - - Stream changes(); - - FutureOrResult getIdentityToken(); - - FutureOrResult getAccount(); - FutureOrResult setAccount(Account account); - - FutureOrResult getData(); - FutureOrResult setData(T? data); - - FutureOrResult> getCache(); - FutureOrResult destroyCache(); - - FutureOrResult addAuthChangeListener(AuthChangeListener listener); - FutureOrResult removeAuthChangeListener(); } diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/repositories/repositories.dart b/packages/wyatt_authentication_bloc/lib/src/domain/repositories/repositories.dart index 8ff4eae1..8565338e 100644 --- a/packages/wyatt_authentication_bloc/lib/src/domain/repositories/repositories.dart +++ b/packages/wyatt_authentication_bloc/lib/src/domain/repositories/repositories.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify diff --git a/packages/wyatt_authentication_bloc/lib/src/features/authentication/authentication.dart b/packages/wyatt_authentication_bloc/lib/src/features/authentication/authentication.dart index 95e85224..478b8ad0 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/authentication/authentication.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/authentication/authentication.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify diff --git a/packages/wyatt_authentication_bloc/lib/src/features/authentication/builder/authentication_builder.dart b/packages/wyatt_authentication_bloc/lib/src/features/authentication/builder/authentication_builder.dart index 4a19e6a9..19e77c20 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/authentication/builder/authentication_builder.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/authentication/builder/authentication_builder.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify @@ -17,10 +17,10 @@ import 'package:flutter/material.dart'; import 'package:flutter_bloc/flutter_bloc.dart'; import 'package:wyatt_authentication_bloc/src/core/enums/authentication_status.dart'; -import 'package:wyatt_authentication_bloc/src/domain/entities/account_wrapper.dart'; +import 'package:wyatt_authentication_bloc/src/domain/entities/session_wrapper.dart'; import 'package:wyatt_authentication_bloc/src/features/authentication/cubit/authentication_cubit.dart'; -class AuthenticationBuilder extends StatelessWidget { +class AuthenticationBuilder extends StatelessWidget { const AuthenticationBuilder({ required this.authenticated, required this.unauthenticated, @@ -30,18 +30,18 @@ class AuthenticationBuilder extends StatelessWidget { final Widget Function( BuildContext context, - AccountWrapper accountWrapper, + SessionWrapper sessionWrapper, ) authenticated; final Widget Function(BuildContext context) unauthenticated; final Widget Function(BuildContext context) unknown; @override Widget build(BuildContext context) => - BlocBuilder, AuthenticationState>( + BlocBuilder, AuthenticationState>( builder: (context, state) { if (state.status == AuthenticationStatus.authenticated) { - if (state.accountWrapper != null) { - return authenticated(context, state.accountWrapper!); + if (state.wrapper != null) { + return authenticated(context, state.wrapper!); } else { return unauthenticated(context); } diff --git a/packages/wyatt_authentication_bloc/lib/src/features/authentication/cubit/authentication_cubit.dart b/packages/wyatt_authentication_bloc/lib/src/features/authentication/cubit/authentication_cubit.dart index 32b00997..8a7dc406 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/authentication/cubit/authentication_cubit.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/authentication/cubit/authentication_cubit.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify @@ -18,56 +18,230 @@ import 'dart:async'; import 'package:equatable/equatable.dart'; import 'package:flutter_bloc/flutter_bloc.dart'; +import 'package:wyatt_architecture/wyatt_architecture.dart'; import 'package:wyatt_authentication_bloc/src/core/enums/authentication_status.dart'; -import 'package:wyatt_authentication_bloc/src/domain/entities/account_wrapper.dart'; +import 'package:wyatt_authentication_bloc/src/core/utils/custom_routine.dart'; +import 'package:wyatt_authentication_bloc/src/domain/entities/entities.dart'; import 'package:wyatt_authentication_bloc/src/domain/repositories/authentication_repository.dart'; import 'package:wyatt_type_utils/wyatt_type_utils.dart'; part 'authentication_state.dart'; -class AuthenticationCubit extends Cubit> { +/// Abstract authentication cubit class needs to be implemented in application. +/// +/// This cubit is in charge of managing the global authentication state of +/// the application. +/// +/// Its here you can override every callbacks and add your custom logic. +abstract class AuthenticationCubit + extends Cubit> { AuthenticationCubit({ required this.authenticationRepository, }) : super(const AuthenticationState.unknown()) { _listenForAuthenticationChanges(); } - final AuthenticationRepository authenticationRepository; + final AuthenticationRepository authenticationRepository; + + SessionWrapper? latestSession; void _listenForAuthenticationChanges() { - authenticationRepository.streamAccount().listen((accountFutureResult) { - accountFutureResult.fold( - (value) { - if (value.account.isNotNull) { - emit(AuthenticationState.authenticated(value)); - return; - } - authenticationRepository.destroyCache(); - emit(AuthenticationState.unauthenticated()); - return; - }, - (error) { - authenticationRepository.destroyCache(); - emit(AuthenticationState.unauthenticated()); - return; - }, - ); + authenticationRepository.sessionStream().asyncMap((wrapper) async { + final event = wrapper.event; + if (event is SignedInFromCacheEvent) { + final customRoutineResult = await onSignInFromCache(wrapper); + + if (customRoutineResult.isOk) { + final account = event.account; + final sessionData = customRoutineResult.ok; + + final signedInSession = SessionWrapper( + event: SignedInFromCacheEvent(account: account), + session: Session( + account: account, + data: sessionData, + ), + ); + + return signedInSession; + } + } + return wrapper; + }).listen((wrapper) async { + latestSession = wrapper; + final session = wrapper.session; + if (session != null) { + emit(AuthenticationState.authenticated(wrapper)); + return; + } + emit(AuthenticationState.unauthenticated()); + return; }); } - /// If authenticated, re-emits state with data freshly loaded from cache. - FutureOr reloadCache() async { - if (state.status == AuthenticationStatus.authenticated) { - final data = await authenticationRepository.getCache(); - emit( - data.fold( - AuthenticationState.authenticated, - (error) => state, + /// {@macro refresh} + FutureOr refresh() async { + final refreshedAccount = await authenticationRepository.refresh(); + final customRoutineResult = await onRefresh(refreshedAccount); + + if (refreshedAccount.isOk && customRoutineResult.isOk) { + final account = refreshedAccount.ok!; + final sessionData = customRoutineResult.ok; + + final refreshedSession = SessionWrapper( + event: RefreshedEvent(account: account), + session: Session( + account: account, + data: sessionData, ), ); + + authenticationRepository.addSession(refreshedSession); + + return; + } + + if (refreshedAccount.isErr) { + addError(refreshedAccount.err!); + + return; + } + + if (customRoutineResult.isErr) { + addError(customRoutineResult.err!); + + return; } } - FutureOr signOut() { - authenticationRepository.signOut(); + /// {@macro reauthenticate} + FutureOr reauthenticate() async { + final reauthenticatedAccount = + await authenticationRepository.reauthenticate(); + final customRoutineResult = await onReauthenticate(reauthenticatedAccount); + + if (reauthenticatedAccount.isOk && customRoutineResult.isOk) { + final account = reauthenticatedAccount.ok!; + final sessionData = customRoutineResult.ok; + + final reauthenticatedSession = SessionWrapper( + event: ReauthenticatedEvent(account: account), + session: Session( + account: account, + data: sessionData, + ), + ); + + authenticationRepository.addSession(reauthenticatedSession); + + return; + } + + if (reauthenticatedAccount.isErr) { + addError(reauthenticatedAccount.err!); + + return; + } + + if (customRoutineResult.isErr) { + addError(customRoutineResult.err!); + + return; + } } + + /// {@macro signout} + FutureOr signOut() async { + final customRoutine = CustomRoutine( + // ignore: unnecessary_lambdas + routine: () => authenticationRepository.signOut(), + attachedLogic: (routineResult) => onSignOut(), + onError: (error) => addError(error!), + onSuccess: (result, data) => authenticationRepository + .addSession(const SessionWrapper(event: SignedOutEvent())), + ); + + customRoutine.call(); + + final signOut = await authenticationRepository.signOut(); + + final customRoutineResult = await onSignOut(); + + if (signOut.isOk && customRoutineResult.isOk) { + authenticationRepository + .addSession(const SessionWrapper(event: SignedOutEvent())); + + return; + } + + if (signOut.isErr) { + addError(signOut.err!); + + return; + } + + if (customRoutineResult.isErr) { + addError(customRoutineResult.err!); + + return; + } + } + + /// {@macro delete} + FutureOr delete() async { + final signOut = await authenticationRepository.delete(); + + final customRoutineResult = await onDelete(); + + if (signOut.isOk && customRoutineResult.isOk) { + authenticationRepository + .addSession(const SessionWrapper(event: DeletedEvent())); + + return; + } + + if (signOut.isErr) { + addError(signOut.err!); + + return; + } + + if (customRoutineResult.isErr) { + addError(customRoutineResult.err!); + + return; + } + } + + /// Returns latest session wrapper. + /// + /// Contains latest event and latest session data (account + extra data) + SessionWrapper? currentSession() => latestSession; + + /// This callback is triggered when the user is automaticcaly logged in from + /// the cache. + /// + /// For example: when the user is sign in from the Firebase cache. + FutureOrResult onSignInFromCache(SessionWrapper wrapper); + + /// This callback is triggered when the account is refreshed. + /// + /// For example: when the access token is refreshed. + FutureOrResult onRefresh(Result result); + + /// This callback is triggered when the account is re-authenticated + /// + /// For example: when the user is logged in and sign in + /// from an another provider + FutureOrResult onReauthenticate(Result result); + + /// This callback is triggered when the user is logged out. + /// + /// For example: when the user clicks on the logout button. + FutureOrResult onSignOut(); + + /// This callback is triggered when the current account is deleted from + /// the remote. + /// + /// For example: when the user wants to delete his account from Firebase + FutureOrResult onDelete(); } diff --git a/packages/wyatt_authentication_bloc/lib/src/features/authentication/cubit/authentication_state.dart b/packages/wyatt_authentication_bloc/lib/src/features/authentication/cubit/authentication_state.dart index a5733bf2..cf672a4c 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/authentication/cubit/authentication_state.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/authentication/cubit/authentication_state.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify @@ -16,27 +16,27 @@ part of 'authentication_cubit.dart'; -class AuthenticationState extends Equatable { - const AuthenticationState.unauthenticated() - : this._(status: AuthenticationStatus.unauthenticated); +class AuthenticationState extends Equatable { + const AuthenticationState._(this.status, this.wrapper); - const AuthenticationState.authenticated(AccountWrapper accountWrapper) + const AuthenticationState.unauthenticated() + : this._(AuthenticationStatus.unauthenticated, null); + + const AuthenticationState.authenticated(SessionWrapper sessionWrapper) : this._( - status: AuthenticationStatus.authenticated, - accountWrapper: accountWrapper, + AuthenticationStatus.authenticated, + sessionWrapper, ); const AuthenticationState.unknown() - : this._(status: AuthenticationStatus.unknown); + : this._(AuthenticationStatus.unknown, null); - const AuthenticationState._({required this.status, this.accountWrapper}); final AuthenticationStatus status; - final AccountWrapper? accountWrapper; + final SessionWrapper? wrapper; @override - List get props => [status, accountWrapper]; + List get props => [status, wrapper]; @override - String toString() => - 'AuthenticationState(status: $status, accountWrapper: $accountWrapper)'; + bool? get stringify => true; } diff --git a/packages/wyatt_authentication_bloc/lib/src/features/email_verification/builder/email_verification_builder.dart b/packages/wyatt_authentication_bloc/lib/src/features/email_verification/builder/email_verification_builder.dart index 2bb77e9c..0de3bdf3 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/email_verification/builder/email_verification_builder.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/email_verification/builder/email_verification_builder.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify diff --git a/packages/wyatt_authentication_bloc/lib/src/features/email_verification/cubit/email_verification_cubit.dart b/packages/wyatt_authentication_bloc/lib/src/features/email_verification/cubit/email_verification_cubit.dart index bb40411b..986b2bc9 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/email_verification/cubit/email_verification_cubit.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/email_verification/cubit/email_verification_cubit.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify @@ -23,12 +23,12 @@ import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; part 'email_verification_state.dart'; -class EmailVerificationCubit extends Cubit { +class EmailVerificationCubit extends Cubit { EmailVerificationCubit({ required this.authenticationRepository, }) : super(const EmailVerificationState()); - final AuthenticationRepository authenticationRepository; + final AuthenticationRepository authenticationRepository; FutureOr sendEmailVerification() async { emit(state.copyWith(status: FormStatus.submissionInProgress)); @@ -59,18 +59,20 @@ class EmailVerificationCubit extends Cubit { return; } - final currentAccount = await authenticationRepository.getAccount(); - emit( - currentAccount.fold( - (value) => state.copyWith( - isVerified: value.emailVerified, + final wrapper = await authenticationRepository.sessionStream().last; + final currentAccount = wrapper.session?.account; + if (currentAccount != null) { + emit( + state.copyWith( + isVerified: currentAccount.emailVerified, status: FormStatus.submissionSuccess, ), - (error) => EmailVerificationState( - errorMessage: error.message, - status: FormStatus.submissionFailure, - ), - ), - ); + ); + } else { + const EmailVerificationState( + errorMessage: 'No current session', + status: FormStatus.submissionFailure, + ); + } } } diff --git a/packages/wyatt_authentication_bloc/lib/src/features/email_verification/cubit/email_verification_state.dart b/packages/wyatt_authentication_bloc/lib/src/features/email_verification/cubit/email_verification_state.dart index 5f9382ac..c78db5b7 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/email_verification/cubit/email_verification_state.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/email_verification/cubit/email_verification_state.dart @@ -1,5 +1,5 @@ // ignore_for_file: public_member_api_docs, sort_constructors_first -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify diff --git a/packages/wyatt_authentication_bloc/lib/src/features/email_verification/email_verification.dart b/packages/wyatt_authentication_bloc/lib/src/features/email_verification/email_verification.dart index 5624d94e..13ff15c5 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/email_verification/email_verification.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/email_verification/email_verification.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify diff --git a/packages/wyatt_authentication_bloc/lib/src/features/features.dart b/packages/wyatt_authentication_bloc/lib/src/features/features.dart index bd39a7f6..435d4d30 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/features.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/features.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify diff --git a/packages/wyatt_authentication_bloc/lib/src/features/password_reset/cubit/password_reset_cubit.dart b/packages/wyatt_authentication_bloc/lib/src/features/password_reset/cubit/password_reset_cubit.dart index fd942bdf..160f10db 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/password_reset/cubit/password_reset_cubit.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/password_reset/cubit/password_reset_cubit.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify diff --git a/packages/wyatt_authentication_bloc/lib/src/features/password_reset/cubit/password_reset_state.dart b/packages/wyatt_authentication_bloc/lib/src/features/password_reset/cubit/password_reset_state.dart index 5c5205dd..cace663f 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/password_reset/cubit/password_reset_state.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/password_reset/cubit/password_reset_state.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify diff --git a/packages/wyatt_authentication_bloc/lib/src/features/password_reset/password_reset.dart b/packages/wyatt_authentication_bloc/lib/src/features/password_reset/password_reset.dart index 43919e02..f9039274 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/password_reset/password_reset.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/password_reset/password_reset.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/base_sign_in_cubit.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/base_sign_in_cubit.dart index b1446b36..03392126 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/base_sign_in_cubit.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/base_sign_in_cubit.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify @@ -16,7 +16,7 @@ part of 'sign_in_cubit.dart'; -abstract class BaseSignInCubit extends FormDataCubit { +abstract class BaseSignInCubit extends FormDataCubit { BaseSignInCubit({ required this.authenticationRepository, }) : super( @@ -25,7 +25,7 @@ abstract class BaseSignInCubit extends FormDataCubit { .accessForm(AuthFormName.signInForm), ), ); - final AuthenticationRepository authenticationRepository; + final AuthenticationRepository authenticationRepository; FormRepository get formRepository => authenticationRepository.formRepository; @override diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_anonymously.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_anonymously.dart index 486ed946..97df97e0 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_anonymously.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_anonymously.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify @@ -17,13 +17,13 @@ import 'dart:async'; import 'package:wyatt_architecture/wyatt_architecture.dart'; -import 'package:wyatt_authentication_bloc/src/domain/entities/account.dart'; +import 'package:wyatt_authentication_bloc/src/domain/entities/entities.dart'; import 'package:wyatt_authentication_bloc/src/features/sign_in/cubit/sign_in_cubit.dart'; import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; import 'package:wyatt_type_utils/wyatt_type_utils.dart'; -mixin SignInAnonymously on BaseSignInCubit { - FutureOrResult onSignInAnonymously( +mixin SignInAnonymously on BaseSignInCubit { + FutureOrResult onSignInAnonymously( Result result, WyattForm form, ); @@ -38,10 +38,10 @@ mixin SignInAnonymously on BaseSignInCubit { final result = await authenticationRepository.signInAnonymously(); - // Here custom code - final callbackResponse = await onSignInAnonymously(result, form); - if (callbackResponse.isErr) { - final error = callbackResponse.err!; + // Custom routine + final customRoutineResult = await onSignInAnonymously(result, form); + if (customRoutineResult.isErr) { + final error = customRoutineResult.err!; emit( SignInState( form: form, @@ -49,8 +49,34 @@ mixin SignInAnonymously on BaseSignInCubit { status: FormStatus.submissionFailure, ), ); + addError(error); } + // Check result + if (result.isErr) { + final error = result.err!; + emit( + SignInState( + form: form, + errorMessage: error.message, + status: FormStatus.submissionFailure, + ), + ); + addError(error); + } + + final account = result.ok!; + + final signedInSession = SessionWrapper( + event: SignedInEvent(account: account), + session: Session( + account: account, + data: customRoutineResult.ok, + ), + ); + + authenticationRepository.addSession(signedInSession); + emit( result.fold( (value) => diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_with_email_password.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_with_email_password.dart index 9a1d66e3..4c868911 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_with_email_password.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_with_email_password.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify @@ -18,13 +18,13 @@ import 'dart:async'; import 'package:wyatt_architecture/wyatt_architecture.dart'; import 'package:wyatt_authentication_bloc/src/core/constants/form_field.dart'; -import 'package:wyatt_authentication_bloc/src/domain/entities/account.dart'; +import 'package:wyatt_authentication_bloc/src/domain/domain.dart'; import 'package:wyatt_authentication_bloc/src/features/sign_in/cubit/sign_in_cubit.dart'; import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; import 'package:wyatt_type_utils/wyatt_type_utils.dart'; -mixin SignInWithEmailPassword on BaseSignInCubit { - FutureOrResult onSignInWithEmailAndPassword( +mixin SignInWithEmailPassword on BaseSignInCubit { + FutureOrResult onSignInWithEmailAndPassword( Result result, WyattForm form, ); @@ -111,10 +111,13 @@ mixin SignInWithEmailPassword on BaseSignInCubit { password: password!, ); - // Here custom code - final callbackResponse = await onSignInWithEmailAndPassword(result, form); - if (callbackResponse.isErr) { - final error = callbackResponse.err!; + // Custom routine + final customRoutineResult = await onSignInWithEmailAndPassword( + result, + form, + ); + if (customRoutineResult.isErr) { + final error = customRoutineResult.err!; emit( SignInState( form: form, @@ -122,8 +125,34 @@ mixin SignInWithEmailPassword on BaseSignInCubit { status: FormStatus.submissionFailure, ), ); + addError(error); } + // Check result + if (result.isErr) { + final error = result.err!; + emit( + SignInState( + form: form, + errorMessage: error.message, + status: FormStatus.submissionFailure, + ), + ); + addError(error); + } + + final account = result.ok!; + + final signedInSession = SessionWrapper( + event: SignedInEvent(account: account), + session: Session( + account: account, + data: customRoutineResult.ok, + ), + ); + + authenticationRepository.addSession(signedInSession); + emit( result.fold( (value) => diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_with_google.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_with_google.dart index b625534a..444e35c3 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_with_google.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_with_google.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify @@ -17,13 +17,13 @@ import 'dart:async'; import 'package:wyatt_architecture/wyatt_architecture.dart'; -import 'package:wyatt_authentication_bloc/src/domain/entities/account.dart'; +import 'package:wyatt_authentication_bloc/src/domain/entities/entities.dart'; import 'package:wyatt_authentication_bloc/src/features/sign_in/cubit/sign_in_cubit.dart'; import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; import 'package:wyatt_type_utils/wyatt_type_utils.dart'; -mixin SignInWithGoogle on BaseSignInCubit { - FutureOrResult onSignInWithGoogle( +mixin SignInWithGoogle on BaseSignInCubit { + FutureOrResult onSignInWithGoogle( Result result, WyattForm form, ); @@ -37,10 +37,13 @@ mixin SignInWithGoogle on BaseSignInCubit { final result = await authenticationRepository.signInWithGoogle(); - // Here custom code - final callbackResponse = await onSignInWithGoogle(result, form); - if (callbackResponse.isErr) { - final error = callbackResponse.err!; + // Custom routine + final customRoutineResult = await onSignInWithGoogle( + result, + form, + ); + if (customRoutineResult.isErr) { + final error = customRoutineResult.err!; emit( SignInState( form: form, @@ -48,8 +51,34 @@ mixin SignInWithGoogle on BaseSignInCubit { status: FormStatus.submissionFailure, ), ); + addError(error); } + // Check result + if (result.isErr) { + final error = result.err!; + emit( + SignInState( + form: form, + errorMessage: error.message, + status: FormStatus.submissionFailure, + ), + ); + addError(error); + } + + final account = result.ok!; + + final signedInSession = SessionWrapper( + event: SignedInEvent(account: account), + session: Session( + account: account, + data: customRoutineResult.ok, + ), + ); + + authenticationRepository.addSession(signedInSession); + emit( result.fold( (value) => diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/sign_in_cubit.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/sign_in_cubit.dart index 3d171f9d..b67f4db6 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/sign_in_cubit.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/sign_in_cubit.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify @@ -18,39 +18,43 @@ import 'dart:async'; import 'package:wyatt_architecture/wyatt_architecture.dart'; +import 'package:wyatt_authentication_bloc/src/core/constants/form_field.dart'; +import 'package:wyatt_authentication_bloc/src/core/constants/form_name.dart'; +import 'package:wyatt_authentication_bloc/src/domain/entities/account.dart'; +import 'package:wyatt_authentication_bloc/src/domain/repositories/authentication_repository.dart'; import 'package:wyatt_authentication_bloc/src/features/sign_in/cubit/mixin/sign_in_anonymously.dart'; import 'package:wyatt_authentication_bloc/src/features/sign_in/cubit/mixin/sign_in_with_email_password.dart'; import 'package:wyatt_authentication_bloc/src/features/sign_in/cubit/mixin/sign_in_with_google.dart'; -import 'package:wyatt_authentication_bloc/wyatt_authentication_bloc.dart'; import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; import 'package:wyatt_type_utils/wyatt_type_utils.dart'; part 'base_sign_in_cubit.dart'; part 'sign_in_state.dart'; -class SignInCubit extends BaseSignInCubit +/// Fully featured sign in cubit. +class SignInCubit extends BaseSignInCubit with - SignInAnonymously, - SignInWithEmailPassword, - SignInWithGoogle { + SignInAnonymously, + SignInWithEmailPassword, + SignInWithGoogle { SignInCubit({required super.authenticationRepository}); @override - FutureOrResult onSignInAnonymously( + FutureOrResult onSignInAnonymously( Result result, WyattForm form, ) => const Ok(null); @override - FutureOrResult onSignInWithEmailAndPassword( + FutureOrResult onSignInWithEmailAndPassword( Result result, WyattForm form, ) => const Ok(null); @override - FutureOrResult onSignInWithGoogle( + FutureOrResult onSignInWithGoogle( Result result, WyattForm form, ) => diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/sign_in_state.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/sign_in_state.dart index d98472ad..18f5b6da 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/sign_in_state.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/sign_in_state.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/listener/sign_in_listener.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/listener/sign_in_listener.dart index e51a1edd..d399142e 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/listener/sign_in_listener.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/listener/sign_in_listener.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/sign_in.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/sign_in.dart index 88fb9a39..37336de7 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/sign_in.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/sign_in.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify @@ -14,5 +14,8 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . +export 'cubit/mixin/sign_in_anonymously.dart'; +export 'cubit/mixin/sign_in_with_email_password.dart'; +export 'cubit/mixin/sign_in_with_google.dart'; export 'cubit/sign_in_cubit.dart'; export 'listener/sign_in_listener.dart'; diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/base_sign_up_cubit.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/base_sign_up_cubit.dart index 9aaad484..3040d1ab 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/base_sign_up_cubit.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/base_sign_up_cubit.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify @@ -16,7 +16,7 @@ part of 'sign_up_cubit.dart'; -abstract class BaseSignUpCubit extends FormDataCubit { +abstract class BaseSignUpCubit extends FormDataCubit { BaseSignUpCubit({ required this.authenticationRepository, }) : super( @@ -25,7 +25,7 @@ abstract class BaseSignUpCubit extends FormDataCubit { .accessForm(AuthFormName.signUpForm), ), ); - final AuthenticationRepository authenticationRepository; + final AuthenticationRepository authenticationRepository; FormRepository get formRepository => authenticationRepository.formRepository; @override diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/mixin/sign_up_with_email_password.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/mixin/sign_up_with_email_password.dart index 6952a01c..9c17deac 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/mixin/sign_up_with_email_password.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/mixin/sign_up_with_email_password.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify @@ -18,13 +18,13 @@ import 'dart:async'; import 'package:wyatt_architecture/wyatt_architecture.dart'; import 'package:wyatt_authentication_bloc/src/core/constants/form_field.dart'; -import 'package:wyatt_authentication_bloc/src/domain/entities/account.dart'; +import 'package:wyatt_authentication_bloc/src/domain/entities/entities.dart'; import 'package:wyatt_authentication_bloc/src/features/sign_up/cubit/sign_up_cubit.dart'; import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; import 'package:wyatt_type_utils/wyatt_type_utils.dart'; -mixin SignUpWithEmailPassword on BaseSignUpCubit { - FutureOrResult onSignUpWithEmailAndPassword( +mixin SignUpWithEmailPassword on BaseSignUpCubit { + FutureOrResult onSignUpWithEmailAndPassword( Result result, WyattForm form, ); @@ -97,15 +97,18 @@ mixin SignUpWithEmailPassword on BaseSignUpCubit { ); } - final result = await authenticationRepository.signUp( + final result = await authenticationRepository.signUpWithEmailAndPassword( email: email!, password: password!, ); - // Here custom code on sign up - final callbackResponse = await onSignUpWithEmailAndPassword(result, form); - if (callbackResponse.isErr) { - final error = callbackResponse.err!; + // Custom routine + final customRoutineResult = await onSignUpWithEmailAndPassword( + result, + form, + ); + if (customRoutineResult.isErr) { + final error = customRoutineResult.err!; emit( SignUpState( form: form, @@ -113,13 +116,34 @@ mixin SignUpWithEmailPassword on BaseSignUpCubit { status: FormStatus.submissionFailure, ), ); + addError(error); } - await authenticationRepository.signInWithEmailAndPassword( - email: email, - password: password, + // Check result + if (result.isErr) { + final error = result.err!; + emit( + SignUpState( + form: form, + errorMessage: error.message, + status: FormStatus.submissionFailure, + ), + ); + addError(error); + } + + final account = result.ok!; + + final signedUpSession = SessionWrapper( + event: SignedUpEvent(account: account), + session: Session( + account: account, + data: customRoutineResult.ok, + ), ); + authenticationRepository.addSession(signedUpSession); + emit( result.fold( (value) => SignUpState( diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/sign_up_cubit.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/sign_up_cubit.dart index df2766ac..49052a16 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/sign_up_cubit.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/sign_up_cubit.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify @@ -28,12 +28,12 @@ import 'package:wyatt_type_utils/wyatt_type_utils.dart'; part 'base_sign_up_cubit.dart'; part 'sign_up_state.dart'; -class SignUpCubit extends BaseSignUpCubit - with SignUpWithEmailPassword { +class SignUpCubit extends BaseSignUpCubit + with SignUpWithEmailPassword { SignUpCubit({required super.authenticationRepository}); @override - FutureOrResult onSignUpWithEmailAndPassword( + FutureOrResult onSignUpWithEmailAndPassword( Result result, WyattForm form, ) => diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/sign_up_state.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/sign_up_state.dart index 40c870c5..3edd1fe5 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/sign_up_state.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/sign_up_state.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_up/listener/sign_up_listener.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_up/listener/sign_up_listener.dart index 925f0294..1e4cc616 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/sign_up/listener/sign_up_listener.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_up/listener/sign_up_listener.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_up/sign_up.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_up/sign_up.dart index 0eb01f0e..21c5895e 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/sign_up/sign_up.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_up/sign_up.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify @@ -14,5 +14,6 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . +export 'cubit/mixin/sign_up_with_email_password.dart'; export 'cubit/sign_up_cubit.dart'; export 'listener/sign_up_listener.dart'; diff --git a/packages/wyatt_authentication_bloc/lib/src/src.dart b/packages/wyatt_authentication_bloc/lib/src/src.dart index 3a660ea4..18df157b 100644 --- a/packages/wyatt_authentication_bloc/lib/src/src.dart +++ b/packages/wyatt_authentication_bloc/lib/src/src.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify diff --git a/packages/wyatt_authentication_bloc/lib/wyatt_authentication_bloc.dart b/packages/wyatt_authentication_bloc/lib/wyatt_authentication_bloc.dart index d853a49b..f8151ff0 100644 --- a/packages/wyatt_authentication_bloc/lib/wyatt_authentication_bloc.dart +++ b/packages/wyatt_authentication_bloc/lib/wyatt_authentication_bloc.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify diff --git a/packages/wyatt_authentication_bloc/test/authentication/authentication_cubit_test.dart b/packages/wyatt_authentication_bloc/test/authentication/authentication_cubit_test.dart index e836bd4f..45f478ba 100644 --- a/packages/wyatt_authentication_bloc/test/authentication/authentication_cubit_test.dart +++ b/packages/wyatt_authentication_bloc/test/authentication/authentication_cubit_test.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify diff --git a/packages/wyatt_authentication_bloc/test/authentication/authentication_state_test.dart b/packages/wyatt_authentication_bloc/test/authentication/authentication_state_test.dart index a85c7998..8f9897f2 100644 --- a/packages/wyatt_authentication_bloc/test/authentication/authentication_state_test.dart +++ b/packages/wyatt_authentication_bloc/test/authentication/authentication_state_test.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify diff --git a/packages/wyatt_authentication_bloc/test/email_verification/email_verification_cubit_test.dart b/packages/wyatt_authentication_bloc/test/email_verification/email_verification_cubit_test.dart index 05ea7a74..9b6c1096 100644 --- a/packages/wyatt_authentication_bloc/test/email_verification/email_verification_cubit_test.dart +++ b/packages/wyatt_authentication_bloc/test/email_verification/email_verification_cubit_test.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify diff --git a/packages/wyatt_authentication_bloc/test/email_verification/email_verification_state_test.dart b/packages/wyatt_authentication_bloc/test/email_verification/email_verification_state_test.dart index 37e030b4..cf779daa 100644 --- a/packages/wyatt_authentication_bloc/test/email_verification/email_verification_state_test.dart +++ b/packages/wyatt_authentication_bloc/test/email_verification/email_verification_state_test.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify diff --git a/packages/wyatt_authentication_bloc/test/password_reset/password_reset_cubit_test.dart b/packages/wyatt_authentication_bloc/test/password_reset/password_reset_cubit_test.dart index ab37fcd3..a668a948 100644 --- a/packages/wyatt_authentication_bloc/test/password_reset/password_reset_cubit_test.dart +++ b/packages/wyatt_authentication_bloc/test/password_reset/password_reset_cubit_test.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify diff --git a/packages/wyatt_authentication_bloc/test/password_reset/password_reset_state_test.dart b/packages/wyatt_authentication_bloc/test/password_reset/password_reset_state_test.dart index 661ea241..518be2dc 100644 --- a/packages/wyatt_authentication_bloc/test/password_reset/password_reset_state_test.dart +++ b/packages/wyatt_authentication_bloc/test/password_reset/password_reset_state_test.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify diff --git a/packages/wyatt_authentication_bloc/test/sign_in/sign_in_cubit_test.dart b/packages/wyatt_authentication_bloc/test/sign_in/sign_in_cubit_test.dart index 466ea3a0..62d9d5b9 100644 --- a/packages/wyatt_authentication_bloc/test/sign_in/sign_in_cubit_test.dart +++ b/packages/wyatt_authentication_bloc/test/sign_in/sign_in_cubit_test.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify diff --git a/packages/wyatt_authentication_bloc/test/sign_in/sign_in_state_test.dart b/packages/wyatt_authentication_bloc/test/sign_in/sign_in_state_test.dart index e55d92bd..30f40cb7 100644 --- a/packages/wyatt_authentication_bloc/test/sign_in/sign_in_state_test.dart +++ b/packages/wyatt_authentication_bloc/test/sign_in/sign_in_state_test.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify diff --git a/packages/wyatt_authentication_bloc/test/sign_up/sign_up_cubit_test.dart b/packages/wyatt_authentication_bloc/test/sign_up/sign_up_cubit_test.dart index d2c9811b..650e44ca 100644 --- a/packages/wyatt_authentication_bloc/test/sign_up/sign_up_cubit_test.dart +++ b/packages/wyatt_authentication_bloc/test/sign_up/sign_up_cubit_test.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify diff --git a/packages/wyatt_authentication_bloc/test/sign_up/sign_up_state_test.dart b/packages/wyatt_authentication_bloc/test/sign_up/sign_up_state_test.dart index 6e67399a..89380d66 100644 --- a/packages/wyatt_authentication_bloc/test/sign_up/sign_up_state_test.dart +++ b/packages/wyatt_authentication_bloc/test/sign_up/sign_up_state_test.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify -- 2.47.2 From 3faceeebb6382fe9955ff8a693a477b5a71b4751 Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Mon, 6 Feb 2023 18:54:45 +0100 Subject: [PATCH 12/47] feat(authentication): add custom routine, and documentation --- .../example/lib/core/routes/router.dart | 35 ++-- .../lib/presentation/features/app/app.dart | 19 +- .../authentication/authentication_cubit.dart | 7 + .../presentation/features/sub/sub_page.dart | 16 +- .../lib/src/core/utils/custom_routine.dart | 8 +- .../cubit/authentication_cubit.dart | 170 +++++------------- .../cubit/password_reset_cubit.dart | 81 +++++---- .../sign_in/cubit/base_sign_in_cubit.dart | 2 + .../cubit/mixin/sign_in_anonymously.dart | 93 +++++----- .../mixin/sign_in_with_email_password.dart | 100 +++++------ .../cubit/mixin/sign_in_with_google.dart | 96 +++++----- .../features/sign_in/cubit/sign_in_cubit.dart | 2 + .../features/sign_in/cubit/sign_in_state.dart | 1 + .../sign_in/listener/sign_in_listener.dart | 6 +- .../sign_up/cubit/base_sign_up_cubit.dart | 2 + .../mixin/sign_up_with_email_password.dart | 107 +++++------ .../features/sign_up/cubit/sign_up_cubit.dart | 3 + .../features/sign_up/cubit/sign_up_state.dart | 1 + .../sign_up/listener/sign_up_listener.dart | 6 +- 19 files changed, 331 insertions(+), 424 deletions(-) diff --git a/packages/wyatt_authentication_bloc/example/lib/core/routes/router.dart b/packages/wyatt_authentication_bloc/example/lib/core/routes/router.dart index 51297a01..dea8429c 100644 --- a/packages/wyatt_authentication_bloc/example/lib/core/routes/router.dart +++ b/packages/wyatt_authentication_bloc/example/lib/core/routes/router.dart @@ -65,22 +65,23 @@ class AppRouter { ), ), GoRoute( - path: '/home', - name: HomePage.pageName, - pageBuilder: (context, state) => defaultTransition( - context, - state, - const HomePage(), - ), - ), - GoRoute( - path: '/home/sub', - name: SubPage.pageName, - pageBuilder: (context, state) => defaultTransition( - context, - state, - const SubPage(), - ), - ), + path: '/home', + name: HomePage.pageName, + pageBuilder: (context, state) => defaultTransition( + context, + state, + const HomePage(), + ), + routes: [ + GoRoute( + path: 'sub', + name: SubPage.pageName, + pageBuilder: (context, state) => defaultTransition( + context, + state, + const SubPage(), + ), + ), + ]), ]; } diff --git a/packages/wyatt_authentication_bloc/example/lib/presentation/features/app/app.dart b/packages/wyatt_authentication_bloc/example/lib/presentation/features/app/app.dart index 1264aa73..75388b5e 100644 --- a/packages/wyatt_authentication_bloc/example/lib/presentation/features/app/app.dart +++ b/packages/wyatt_authentication_bloc/example/lib/presentation/features/app/app.dart @@ -30,19 +30,6 @@ import 'package:go_router/go_router.dart'; import 'package:wyatt_authentication_bloc/wyatt_authentication_bloc.dart'; import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; -// FutureOrResult onAccountChanges( -// AuthenticationRepository repo, -// AuthChangeEvent? authEvent, -// ) async { -// final id = Random().nextInt(1000); -// final token = -// await repo.getIdentityToken().fold((value) => value, (error) => 'null'); - -// debugPrint( -// 'onAccountChanges: ${authEvent?.account}, type: ${authEvent.runtimeType}, token: $token, generatedId: $id'); -// return Ok(id); -// } - class App extends StatelessWidget { final AuthenticationRepository authenticationRepository = AuthenticationRepositoryImpl( @@ -64,7 +51,9 @@ class App extends StatelessWidget { Widget build(BuildContext context) { AuthenticationState? previous; - final AuthenticationCubit authenticationCubit = ExampleAuthenticationCubit(authenticationRepository: authenticationRepository); + final AuthenticationCubit authenticationCubit = + ExampleAuthenticationCubit( + authenticationRepository: authenticationRepository); final GoRouter router = GoRouter( initialLocation: '/', @@ -91,7 +80,7 @@ class App extends StatelessWidget { return '/home'; } } - return null; + return state.name; }, ); diff --git a/packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/authentication_cubit.dart b/packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/authentication_cubit.dart index 869be269..5f03c2f7 100644 --- a/packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/authentication_cubit.dart +++ b/packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/authentication_cubit.dart @@ -49,4 +49,11 @@ class ExampleAuthenticationCubit extends AuthenticationCubit { return const Ok(null); } + + @override + FutureOrResult onDelete() { + print('onDelete'); + + return const Ok(null); + } } diff --git a/packages/wyatt_authentication_bloc/example/lib/presentation/features/sub/sub_page.dart b/packages/wyatt_authentication_bloc/example/lib/presentation/features/sub/sub_page.dart index 9cdfad53..9c0f4ece 100644 --- a/packages/wyatt_authentication_bloc/example/lib/presentation/features/sub/sub_page.dart +++ b/packages/wyatt_authentication_bloc/example/lib/presentation/features/sub/sub_page.dart @@ -35,14 +35,20 @@ class SubPage extends StatelessWidget { icon: const Icon(Icons.logout_rounded)), IconButton( onPressed: () => - context.read>().refresh(), + context.read>().refresh(), icon: const Icon(Icons.refresh)) ], ), - body: const Padding( - padding: EdgeInsets.all(8), - child: SingleChildScrollView( - child: Text('Another page'), + body: Padding( + padding: const EdgeInsets.all(8), + child: ListView( + children: [ + const Text('Another page'), + ElevatedButton( + onPressed: () => context.read>().delete(), + child: const Text('Delete account'), + ), + ], ), ), ); diff --git a/packages/wyatt_authentication_bloc/lib/src/core/utils/custom_routine.dart b/packages/wyatt_authentication_bloc/lib/src/core/utils/custom_routine.dart index db8b4265..bdd1eb7a 100644 --- a/packages/wyatt_authentication_bloc/lib/src/core/utils/custom_routine.dart +++ b/packages/wyatt_authentication_bloc/lib/src/core/utils/custom_routine.dart @@ -35,7 +35,7 @@ class CustomRoutine { final FutureOr> Function( Result routineResult, ) attachedLogic; - final void Function(AppException? exception) onError; + final void Function(AppException exception) onError; final void Function(R result, Data? data) onSuccess; FutureOr call() async { @@ -46,17 +46,17 @@ class CustomRoutine { // Check for errors if (result.isErr) { - onError.call(result.err); + onError.call(result.err!); return; } if (customRoutineResult.isErr) { - onError.call(customRoutineResult.err); + onError.call(customRoutineResult.err!); return; } // If no error - return onSuccess.call(result.ok as Input, customRoutineResult.ok); + return onSuccess.call(result.ok as R, customRoutineResult.ok); } } diff --git a/packages/wyatt_authentication_bloc/lib/src/features/authentication/cubit/authentication_cubit.dart b/packages/wyatt_authentication_bloc/lib/src/features/authentication/cubit/authentication_cubit.dart index 8a7dc406..c90ab44f 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/authentication/cubit/authentication_cubit.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/authentication/cubit/authentication_cubit.dart @@ -42,7 +42,7 @@ abstract class AuthenticationCubit } final AuthenticationRepository authenticationRepository; - SessionWrapper? latestSession; + SessionWrapper? _latestSession; void _listenForAuthenticationChanges() { authenticationRepository.sessionStream().asyncMap((wrapper) async { @@ -67,7 +67,7 @@ abstract class AuthenticationCubit } return wrapper; }).listen((wrapper) async { - latestSession = wrapper; + _latestSession = wrapper; final session = wrapper.session; if (session != null) { emit(AuthenticationState.authenticated(wrapper)); @@ -79,143 +79,59 @@ abstract class AuthenticationCubit } /// {@macro refresh} - FutureOr refresh() async { - final refreshedAccount = await authenticationRepository.refresh(); - final customRoutineResult = await onRefresh(refreshedAccount); - - if (refreshedAccount.isOk && customRoutineResult.isOk) { - final account = refreshedAccount.ok!; - final sessionData = customRoutineResult.ok; - - final refreshedSession = SessionWrapper( - event: RefreshedEvent(account: account), - session: Session( - account: account, - data: sessionData, + FutureOr refresh() async => CustomRoutine( + routine: authenticationRepository.refresh, + attachedLogic: onRefresh, + onError: addError, + onSuccess: (result, data) => authenticationRepository.addSession( + SessionWrapper( + event: RefreshedEvent(account: result), + session: Session( + account: result, + data: data, + ), ), - ); - - authenticationRepository.addSession(refreshedSession); - - return; - } - - if (refreshedAccount.isErr) { - addError(refreshedAccount.err!); - - return; - } - - if (customRoutineResult.isErr) { - addError(customRoutineResult.err!); - - return; - } - } + ), + ).call(); /// {@macro reauthenticate} - FutureOr reauthenticate() async { - final reauthenticatedAccount = - await authenticationRepository.reauthenticate(); - final customRoutineResult = await onReauthenticate(reauthenticatedAccount); - - if (reauthenticatedAccount.isOk && customRoutineResult.isOk) { - final account = reauthenticatedAccount.ok!; - final sessionData = customRoutineResult.ok; - - final reauthenticatedSession = SessionWrapper( - event: ReauthenticatedEvent(account: account), - session: Session( - account: account, - data: sessionData, + FutureOr reauthenticate() async => CustomRoutine( + routine: authenticationRepository.reauthenticate, + attachedLogic: onReauthenticate, + onError: addError, + onSuccess: (result, data) => authenticationRepository.addSession( + SessionWrapper( + event: ReauthenticatedEvent(account: result), + session: Session( + account: result, + data: data, + ), + ), ), - ); - - authenticationRepository.addSession(reauthenticatedSession); - - return; - } - - if (reauthenticatedAccount.isErr) { - addError(reauthenticatedAccount.err!); - - return; - } - - if (customRoutineResult.isErr) { - addError(customRoutineResult.err!); - - return; - } - } + ).call(); /// {@macro signout} - FutureOr signOut() async { - final customRoutine = CustomRoutine( - // ignore: unnecessary_lambdas - routine: () => authenticationRepository.signOut(), - attachedLogic: (routineResult) => onSignOut(), - onError: (error) => addError(error!), - onSuccess: (result, data) => authenticationRepository - .addSession(const SessionWrapper(event: SignedOutEvent())), - ); - - customRoutine.call(); - - final signOut = await authenticationRepository.signOut(); - - final customRoutineResult = await onSignOut(); - - if (signOut.isOk && customRoutineResult.isOk) { - authenticationRepository - .addSession(const SessionWrapper(event: SignedOutEvent())); - - return; - } - - if (signOut.isErr) { - addError(signOut.err!); - - return; - } - - if (customRoutineResult.isErr) { - addError(customRoutineResult.err!); - - return; - } - } + FutureOr signOut() async => CustomRoutine( + routine: authenticationRepository.signOut, + attachedLogic: (routineResult) => onSignOut(), + onError: addError, + onSuccess: (result, data) => authenticationRepository + .addSession(SessionWrapper(event: const SignedOutEvent())), + ).call(); /// {@macro delete} - FutureOr delete() async { - final signOut = await authenticationRepository.delete(); - - final customRoutineResult = await onDelete(); - - if (signOut.isOk && customRoutineResult.isOk) { - authenticationRepository - .addSession(const SessionWrapper(event: DeletedEvent())); - - return; - } - - if (signOut.isErr) { - addError(signOut.err!); - - return; - } - - if (customRoutineResult.isErr) { - addError(customRoutineResult.err!); - - return; - } - } + FutureOr delete() async => CustomRoutine( + routine: authenticationRepository.delete, + attachedLogic: (routineResult) => onDelete(), + onError: addError, + onSuccess: (result, data) => authenticationRepository + .addSession(SessionWrapper(event: const DeletedEvent())), + ).call(); /// Returns latest session wrapper. /// /// Contains latest event and latest session data (account + extra data) - SessionWrapper? currentSession() => latestSession; + SessionWrapper? currentSession() => _latestSession; /// This callback is triggered when the user is automaticcaly logged in from /// the cache. diff --git a/packages/wyatt_authentication_bloc/lib/src/features/password_reset/cubit/password_reset_cubit.dart b/packages/wyatt_authentication_bloc/lib/src/features/password_reset/cubit/password_reset_cubit.dart index 160f10db..c8624fc6 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/password_reset/cubit/password_reset_cubit.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/password_reset/cubit/password_reset_cubit.dart @@ -24,28 +24,22 @@ import 'package:wyatt_type_utils/wyatt_type_utils.dart'; part 'password_reset_state.dart'; +/// Cubit that allows user to reset his password class PasswordResetCubit extends FormDataCubit { PasswordResetCubit({ required this.authenticationRepository, - }) : - super( + }) : super( PasswordResetState( form: authenticationRepository.formRepository .accessForm(AuthFormName.passwordResetForm), ), ); final AuthenticationRepository authenticationRepository; - FormRepository get formRepository => - authenticationRepository.formRepository; + FormRepository get formRepository => authenticationRepository.formRepository; @override String get formName => AuthFormName.passwordResetForm; - void emailChanged(String value) { - final Email email = Email.dirty(value); - dataChanged(AuthFormField.email, email); - } - @override FutureOr dataChanged( String key, @@ -74,6 +68,33 @@ class PasswordResetCubit extends FormDataCubit { ); } + @override + FutureOr update( + WyattForm form, { + SetOperation operation = SetOperation.replace, + }) { + final WyattForm current = formRepository.accessForm(formName).clone(); + final WyattForm newForm = operation.operation.call(current, form); + formRepository.updateForm(newForm); + + emit( + state.copyWith( + form: newForm, + status: newForm.validate(), + ), + ); + } + + @override + FutureOr validate() { + emit( + state.copyWith( + status: formRepository.accessForm(formName).validate(), + ), + ); + } + + /// Sends a password reset email to the user @override FutureOr submit() async { if (!state.status.isValidated) { @@ -109,29 +130,29 @@ class PasswordResetCubit extends FormDataCubit { ); } - @override - FutureOr update( - WyattForm form, { - SetOperation operation = SetOperation.replace, - }) { - final WyattForm current = formRepository.accessForm(formName).clone(); - final WyattForm newForm = operation.operation.call(current, form); - formRepository.updateForm(newForm); - - emit( - state.copyWith( - form: newForm, - status: newForm.validate(), - ), + void emailChanged(String value) { + final emailValidatorType = formRepository + .accessForm(formName) + .validatorOf(AuthFormField.email) + .runtimeType; + assert( + emailValidatorType == Email, + 'Use emailCustomChanged(...) with validator $emailValidatorType', ); + + final Email email = Email.dirty(value); + dataChanged(AuthFormField.email, email); } - @override - FutureOr validate() { - emit( - state.copyWith( - status: formRepository.accessForm(formName).validate(), - ), - ); + /// Same as [emailChanged] but with a custom [Validator]. + /// + /// Sort of short hand for [dataChanged]. + void emailCustomChanged< + Validator extends FormInputValidator>( + Validator validator, + ) { + dataChanged(AuthFormField.email, validator); } + + // TODO(wyatt): create base_password_reset_cubit and create mixins } diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/base_sign_in_cubit.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/base_sign_in_cubit.dart index 03392126..636a2786 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/base_sign_in_cubit.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/base_sign_in_cubit.dart @@ -16,6 +16,8 @@ part of 'sign_in_cubit.dart'; +/// Abstract sign in cubit useful for implementing a cubit with fine +/// granularity by adding only the required mixins. abstract class BaseSignInCubit extends FormDataCubit { BaseSignInCubit({ required this.authenticationRepository, diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_anonymously.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_anonymously.dart index 97df97e0..2adf2f2f 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_anonymously.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_anonymously.dart @@ -17,17 +17,26 @@ import 'dart:async'; import 'package:wyatt_architecture/wyatt_architecture.dart'; +import 'package:wyatt_authentication_bloc/src/core/utils/custom_routine.dart'; import 'package:wyatt_authentication_bloc/src/domain/entities/entities.dart'; import 'package:wyatt_authentication_bloc/src/features/sign_in/cubit/sign_in_cubit.dart'; import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; import 'package:wyatt_type_utils/wyatt_type_utils.dart'; +/// Sign in mixin. +/// +/// Allows the user to sign in anonymously +/// +/// Gives access to the `signInAnonymously` method and +/// `onSignInAnonymously` callback. mixin SignInAnonymously on BaseSignInCubit { + /// This callback is triggered when a user signs in anonymously. FutureOrResult onSignInAnonymously( Result result, WyattForm form, ); + /// {@macro signin_anom} FutureOr signInAnonymously() async { if (state.status.isSubmissionInProgress) { return; @@ -36,57 +45,39 @@ mixin SignInAnonymously on BaseSignInCubit { final form = formRepository.accessForm(formName); emit(SignInState(form: form, status: FormStatus.submissionInProgress)); - final result = await authenticationRepository.signInAnonymously(); - - // Custom routine - final customRoutineResult = await onSignInAnonymously(result, form); - if (customRoutineResult.isErr) { - final error = customRoutineResult.err!; - emit( - SignInState( - form: form, - errorMessage: error.message, - status: FormStatus.submissionFailure, - ), - ); - addError(error); - } - - // Check result - if (result.isErr) { - final error = result.err!; - emit( - SignInState( - form: form, - errorMessage: error.message, - status: FormStatus.submissionFailure, - ), - ); - addError(error); - } - - final account = result.ok!; - - final signedInSession = SessionWrapper( - event: SignedInEvent(account: account), - session: Session( - account: account, - data: customRoutineResult.ok, + return CustomRoutine( + routine: authenticationRepository.signInAnonymously, + attachedLogic: (routineResult) => onSignInAnonymously( + routineResult, + form, ), - ); - - authenticationRepository.addSession(signedInSession); - - emit( - result.fold( - (value) => - SignInState(form: form, status: FormStatus.submissionSuccess), - (error) => SignInState( - form: form, - errorMessage: error.message, - status: FormStatus.submissionFailure, - ), - ), - ); + onError: (error) { + emit( + SignInState( + form: form, + errorMessage: error.message, + status: FormStatus.submissionFailure, + ), + ); + addError(error); + }, + onSuccess: (account, data) { + authenticationRepository.addSession( + SessionWrapper( + event: SignedInEvent(account: account), + session: Session( + account: account, + data: data, + ), + ), + ); + emit( + SignInState( + form: form, + status: FormStatus.submissionSuccess, + ), + ); + }, + ).call(); } } diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_with_email_password.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_with_email_password.dart index 4c868911..36e7372b 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_with_email_password.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_with_email_password.dart @@ -18,12 +18,20 @@ import 'dart:async'; import 'package:wyatt_architecture/wyatt_architecture.dart'; import 'package:wyatt_authentication_bloc/src/core/constants/form_field.dart'; +import 'package:wyatt_authentication_bloc/src/core/utils/custom_routine.dart'; import 'package:wyatt_authentication_bloc/src/domain/domain.dart'; import 'package:wyatt_authentication_bloc/src/features/sign_in/cubit/sign_in_cubit.dart'; import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; import 'package:wyatt_type_utils/wyatt_type_utils.dart'; +/// Sign in mixin. +/// +/// Allows the user to sign in with email and password +/// +/// Gives access to the `signInWithEmailAndPassword` method and +/// `onSignInWithEmailAndPassword` callback. mixin SignInWithEmailPassword on BaseSignInCubit { + /// This callback is triggered when a user signs in with email and password. FutureOrResult onSignInWithEmailAndPassword( Result result, WyattForm form, @@ -76,6 +84,7 @@ mixin SignInWithEmailPassword on BaseSignInCubit { dataChanged(AuthFormField.password, validator); } + /// {@macro signin_pwd} FutureOr signInWithEmailAndPassword() async { if (state.status.isSubmissionInProgress) { return; @@ -106,63 +115,42 @@ mixin SignInWithEmailPassword on BaseSignInCubit { ); } - final result = await authenticationRepository.signInWithEmailAndPassword( - email: email!, - password: password!, - ); - - // Custom routine - final customRoutineResult = await onSignInWithEmailAndPassword( - result, - form, - ); - if (customRoutineResult.isErr) { - final error = customRoutineResult.err!; - emit( - SignInState( - form: form, - errorMessage: error.message, - status: FormStatus.submissionFailure, - ), - ); - addError(error); - } - - // Check result - if (result.isErr) { - final error = result.err!; - emit( - SignInState( - form: form, - errorMessage: error.message, - status: FormStatus.submissionFailure, - ), - ); - addError(error); - } - - final account = result.ok!; - - final signedInSession = SessionWrapper( - event: SignedInEvent(account: account), - session: Session( - account: account, - data: customRoutineResult.ok, + return CustomRoutine( + routine: () => authenticationRepository.signInWithEmailAndPassword( + email: email!, + password: password!, ), - ); - - authenticationRepository.addSession(signedInSession); - - emit( - result.fold( - (value) => - SignInState(form: form, status: FormStatus.submissionSuccess), - (error) => SignInState( - form: form, - errorMessage: error.message, - status: FormStatus.submissionFailure, - ), + attachedLogic: (routineResult) => onSignInWithEmailAndPassword( + routineResult, + form, ), - ); + onError: (error) { + emit( + SignInState( + form: form, + errorMessage: error.message, + status: FormStatus.submissionFailure, + ), + ); + addError(error); + }, + onSuccess: (account, data) { + authenticationRepository.addSession( + SessionWrapper( + event: SignedInEvent(account: account), + session: Session( + account: account, + data: data, + ), + ), + ); + emit( + SignInState( + form: form, + status: FormStatus.submissionSuccess, + ), + ); + }, + ).call(); } } diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_with_google.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_with_google.dart index 444e35c3..458844fe 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_with_google.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_with_google.dart @@ -17,17 +17,26 @@ import 'dart:async'; import 'package:wyatt_architecture/wyatt_architecture.dart'; +import 'package:wyatt_authentication_bloc/src/core/utils/custom_routine.dart'; import 'package:wyatt_authentication_bloc/src/domain/entities/entities.dart'; import 'package:wyatt_authentication_bloc/src/features/sign_in/cubit/sign_in_cubit.dart'; import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; import 'package:wyatt_type_utils/wyatt_type_utils.dart'; +/// Sign in mixin. +/// +/// Allows the user to sign in with google +/// +/// Gives access to the `signInWithGoogle` method and +/// `onSignInWithGoogle` callback. mixin SignInWithGoogle on BaseSignInCubit { + /// This callback is triggered when a user signs in with google. FutureOrResult onSignInWithGoogle( Result result, WyattForm form, ); + /// {@macro signin_google} FutureOr signInWithGoogle() async { if (state.status.isSubmissionInProgress) { return; @@ -35,60 +44,39 @@ mixin SignInWithGoogle on BaseSignInCubit { final form = formRepository.accessForm(formName); emit(SignInState(form: form, status: FormStatus.submissionInProgress)); - final result = await authenticationRepository.signInWithGoogle(); - - // Custom routine - final customRoutineResult = await onSignInWithGoogle( - result, - form, - ); - if (customRoutineResult.isErr) { - final error = customRoutineResult.err!; - emit( - SignInState( - form: form, - errorMessage: error.message, - status: FormStatus.submissionFailure, - ), - ); - addError(error); - } - - // Check result - if (result.isErr) { - final error = result.err!; - emit( - SignInState( - form: form, - errorMessage: error.message, - status: FormStatus.submissionFailure, - ), - ); - addError(error); - } - - final account = result.ok!; - - final signedInSession = SessionWrapper( - event: SignedInEvent(account: account), - session: Session( - account: account, - data: customRoutineResult.ok, + return CustomRoutine( + routine: authenticationRepository.signInWithGoogle, + attachedLogic: (routineResult) => onSignInWithGoogle( + routineResult, + form, ), - ); - - authenticationRepository.addSession(signedInSession); - - emit( - result.fold( - (value) => - SignInState(form: form, status: FormStatus.submissionSuccess), - (error) => SignInState( - form: form, - errorMessage: error.message, - status: FormStatus.submissionFailure, - ), - ), - ); + onError: (error) { + emit( + SignInState( + form: form, + errorMessage: error.message, + status: FormStatus.submissionFailure, + ), + ); + addError(error); + }, + onSuccess: (account, data) { + authenticationRepository.addSession( + SessionWrapper( + event: SignedInEvent(account: account), + session: Session( + account: account, + data: data, + ), + ), + ); + emit( + SignInState( + form: form, + status: FormStatus.submissionSuccess, + ), + ); + }, + ).call(); } } diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/sign_in_cubit.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/sign_in_cubit.dart index b67f4db6..f1f3ccd5 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/sign_in_cubit.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/sign_in_cubit.dart @@ -32,6 +32,8 @@ part 'base_sign_in_cubit.dart'; part 'sign_in_state.dart'; /// Fully featured sign in cubit. +/// +/// Sufficient in most cases. (Where fine granularity is not required.) class SignInCubit extends BaseSignInCubit with SignInAnonymously, diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/sign_in_state.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/sign_in_state.dart index 18f5b6da..acb975b5 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/sign_in_state.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/sign_in_state.dart @@ -16,6 +16,7 @@ part of 'sign_in_cubit.dart'; +/// Sign in cubit state to manage the form. class SignInState extends FormDataState { const SignInState({ required super.form, diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/listener/sign_in_listener.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/listener/sign_in_listener.dart index d399142e..cc66ac36 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/listener/sign_in_listener.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/listener/sign_in_listener.dart @@ -19,7 +19,9 @@ import 'package:flutter_bloc/flutter_bloc.dart'; import 'package:wyatt_authentication_bloc/src/features/sign_in/sign_in.dart'; import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; -class SignInListener extends StatelessWidget { +/// Widget that listens and builds a child based on the state of +/// the sign in cubit +class SignInListener extends StatelessWidget { const SignInListener({ required this.child, this.onProgress, @@ -41,7 +43,7 @@ class SignInListener extends StatelessWidget { @override Widget build(BuildContext context) => - BlocListener, SignInState>( + BlocListener, SignInState>( listener: (context, state) { if (customBuilder != null) { return customBuilder!(context, state); diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/base_sign_up_cubit.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/base_sign_up_cubit.dart index 3040d1ab..42747ce3 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/base_sign_up_cubit.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/base_sign_up_cubit.dart @@ -16,6 +16,8 @@ part of 'sign_up_cubit.dart'; +/// Abstract sign up cubit useful for implementing a cubit with fine +/// granularity by adding only the required mixins. abstract class BaseSignUpCubit extends FormDataCubit { BaseSignUpCubit({ required this.authenticationRepository, diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/mixin/sign_up_with_email_password.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/mixin/sign_up_with_email_password.dart index 9c17deac..7c2f39f0 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/mixin/sign_up_with_email_password.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/mixin/sign_up_with_email_password.dart @@ -17,13 +17,20 @@ import 'dart:async'; import 'package:wyatt_architecture/wyatt_architecture.dart'; -import 'package:wyatt_authentication_bloc/src/core/constants/form_field.dart'; -import 'package:wyatt_authentication_bloc/src/domain/entities/entities.dart'; -import 'package:wyatt_authentication_bloc/src/features/sign_up/cubit/sign_up_cubit.dart'; +import 'package:wyatt_authentication_bloc/wyatt_authentication_bloc.dart'; import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; import 'package:wyatt_type_utils/wyatt_type_utils.dart'; +/// Sign up mixin. +/// +/// Allows the user to register with an email and a password. +/// +/// Gives access to the `signUpWithEmailPassword` method and +/// `onSignUpWithEmailAndPassword` callback. mixin SignUpWithEmailPassword on BaseSignUpCubit { + /// This callback is triggered when a user creates an account. + /// + /// For example: when a user sign up in firebase. FutureOrResult onSignUpWithEmailAndPassword( Result result, WyattForm form, @@ -76,6 +83,7 @@ mixin SignUpWithEmailPassword on BaseSignUpCubit { dataChanged(AuthFormField.password, validator); } + /// {@macro signup_pwd} FutureOr signUpWithEmailPassword() async { if (!state.status.isValidated) { return; @@ -97,65 +105,42 @@ mixin SignUpWithEmailPassword on BaseSignUpCubit { ); } - final result = await authenticationRepository.signUpWithEmailAndPassword( - email: email!, - password: password!, - ); - - // Custom routine - final customRoutineResult = await onSignUpWithEmailAndPassword( - result, - form, - ); - if (customRoutineResult.isErr) { - final error = customRoutineResult.err!; - emit( - SignUpState( - form: form, - errorMessage: error.message, - status: FormStatus.submissionFailure, - ), - ); - addError(error); - } - - // Check result - if (result.isErr) { - final error = result.err!; - emit( - SignUpState( - form: form, - errorMessage: error.message, - status: FormStatus.submissionFailure, - ), - ); - addError(error); - } - - final account = result.ok!; - - final signedUpSession = SessionWrapper( - event: SignedUpEvent(account: account), - session: Session( - account: account, - data: customRoutineResult.ok, + return CustomRoutine( + routine: () => authenticationRepository.signUpWithEmailAndPassword( + email: email!, + password: password!, ), - ); - - authenticationRepository.addSession(signedUpSession); - - emit( - result.fold( - (value) => SignUpState( - form: form, - status: FormStatus.submissionSuccess, - ), - (error) => SignUpState( - form: form, - errorMessage: error.message, - status: FormStatus.submissionFailure, - ), + attachedLogic: (routineResult) => onSignUpWithEmailAndPassword( + routineResult, + form, ), - ); + onError: (error) { + emit( + SignUpState( + form: form, + errorMessage: error.message, + status: FormStatus.submissionFailure, + ), + ); + addError(error); + }, + onSuccess: (account, data) { + authenticationRepository.addSession( + SessionWrapper( + event: SignedUpEvent(account: account), + session: Session( + account: account, + data: data, + ), + ), + ); + emit( + SignUpState( + form: form, + status: FormStatus.submissionSuccess, + ), + ); + }, + ).call(); } } diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/sign_up_cubit.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/sign_up_cubit.dart index 49052a16..75c285cf 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/sign_up_cubit.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/sign_up_cubit.dart @@ -28,6 +28,9 @@ import 'package:wyatt_type_utils/wyatt_type_utils.dart'; part 'base_sign_up_cubit.dart'; part 'sign_up_state.dart'; +/// Fully featured sign up cubit. +/// +/// Sufficient in most cases. (Where fine granularity is not required.) class SignUpCubit extends BaseSignUpCubit with SignUpWithEmailPassword { SignUpCubit({required super.authenticationRepository}); diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/sign_up_state.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/sign_up_state.dart index 3edd1fe5..a66a3693 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/sign_up_state.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/sign_up_state.dart @@ -16,6 +16,7 @@ part of 'sign_up_cubit.dart'; +/// Sign up cubit state to manage the form. class SignUpState extends FormDataState { const SignUpState({ required super.form, diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_up/listener/sign_up_listener.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_up/listener/sign_up_listener.dart index 1e4cc616..1493df64 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/sign_up/listener/sign_up_listener.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_up/listener/sign_up_listener.dart @@ -19,7 +19,9 @@ import 'package:flutter_bloc/flutter_bloc.dart'; import 'package:wyatt_authentication_bloc/src/features/sign_up/cubit/sign_up_cubit.dart'; import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; -class SignUpListener extends StatelessWidget { +/// Widget that listens and builds a child based on the state of +/// the sign up cubit +class SignUpListener extends StatelessWidget { const SignUpListener({ required this.child, this.onProgress, @@ -41,7 +43,7 @@ class SignUpListener extends StatelessWidget { @override Widget build(BuildContext context) => - BlocListener, SignUpState>( + BlocListener, SignUpState>( listener: (context, state) { if (customBuilder != null) { return customBuilder!(context, state); -- 2.47.2 From 1c5a6ce9ebf03ec483cdbbf0a139fd6911484086 Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Mon, 6 Feb 2023 21:23:22 +0100 Subject: [PATCH 13/47] feat(authentication): add account edit cubit --- .../lib/src/core/constants/form_field.dart | 2 + .../lib/src/core/constants/form_name.dart | 2 + .../lib/src/core/utils/forms.dart | 96 +++++++++++++ ...hentication_firebase_data_source_impl.dart | 12 +- .../authentication_repository_impl.dart | 52 +++---- .../cubit/base_edit_account_cubit.dart | 100 +++++++++++++ .../cubit/edit_account_cubit.dart | 51 +++++++ .../cubit/edit_account_state.dart | 48 +++++++ .../edit_account/cubit/mixin/edit_email.dart | 131 ++++++++++++++++++ .../cubit/mixin/edit_password.dart | 130 +++++++++++++++++ .../features/edit_account/edit_account.dart | 20 +++ .../listener/edit_account_listener.dart | 69 +++++++++ .../lib/src/features/features.dart | 1 + .../sign_in/cubit/base_sign_in_cubit.dart | 2 +- 14 files changed, 678 insertions(+), 38 deletions(-) create mode 100644 packages/wyatt_authentication_bloc/lib/src/core/utils/forms.dart create mode 100644 packages/wyatt_authentication_bloc/lib/src/features/edit_account/cubit/base_edit_account_cubit.dart create mode 100644 packages/wyatt_authentication_bloc/lib/src/features/edit_account/cubit/edit_account_cubit.dart create mode 100644 packages/wyatt_authentication_bloc/lib/src/features/edit_account/cubit/edit_account_state.dart create mode 100644 packages/wyatt_authentication_bloc/lib/src/features/edit_account/cubit/mixin/edit_email.dart create mode 100644 packages/wyatt_authentication_bloc/lib/src/features/edit_account/cubit/mixin/edit_password.dart create mode 100644 packages/wyatt_authentication_bloc/lib/src/features/edit_account/edit_account.dart create mode 100644 packages/wyatt_authentication_bloc/lib/src/features/edit_account/listener/edit_account_listener.dart diff --git a/packages/wyatt_authentication_bloc/lib/src/core/constants/form_field.dart b/packages/wyatt_authentication_bloc/lib/src/core/constants/form_field.dart index aa1ed36a..bbfc22e8 100644 --- a/packages/wyatt_authentication_bloc/lib/src/core/constants/form_field.dart +++ b/packages/wyatt_authentication_bloc/lib/src/core/constants/form_field.dart @@ -20,4 +20,6 @@ abstract class AuthFormField { static const email = 'wyattEmailField'; /// Password field: `wyattPasswordField` static const password = 'wyattPasswordField'; + /// Confirm Password field: `wyattConfirmPasswordField` + static const confirmPassword = 'wyattConfirmPasswordField'; } diff --git a/packages/wyatt_authentication_bloc/lib/src/core/constants/form_name.dart b/packages/wyatt_authentication_bloc/lib/src/core/constants/form_name.dart index 3eca89e0..16f58cf0 100644 --- a/packages/wyatt_authentication_bloc/lib/src/core/constants/form_name.dart +++ b/packages/wyatt_authentication_bloc/lib/src/core/constants/form_name.dart @@ -22,4 +22,6 @@ abstract class AuthFormName { static const String signInForm = 'wyattSignInForm'; /// Password reset form: `wyattPasswordResetForm` static const String passwordResetForm = 'wyattPasswordResetForm'; + /// Edit account form: `wyattEditAccountForm` + static const String editAccountForm = 'wyattEditAccountForm'; } diff --git a/packages/wyatt_authentication_bloc/lib/src/core/utils/forms.dart b/packages/wyatt_authentication_bloc/lib/src/core/utils/forms.dart new file mode 100644 index 00000000..f8f8bf17 --- /dev/null +++ b/packages/wyatt_authentication_bloc/lib/src/core/utils/forms.dart @@ -0,0 +1,96 @@ +// Copyright (C) 2023 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +import 'package:wyatt_authentication_bloc/wyatt_authentication_bloc.dart'; +import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; + +abstract class Forms { + static WyattForm buildSignInForm( + FormInputValidator? customEmailValidator, + FormInputValidator? customPasswordValidator, + ) => + WyattFormImpl( + [ + FormInput( + AuthFormField.email, + customEmailValidator ?? const Email.pure(), + ), + FormInput( + AuthFormField.password, + customPasswordValidator ?? const Password.pure(), + ) + ], + name: AuthFormName.signInForm, + ); + + static WyattForm buildSignUpForm( + FormInputValidator? customEmailValidator, + FormInputValidator? customPasswordValidator, + // ignore: strict_raw_type + List? extraSignUpInputs, + ) => + WyattFormImpl( + [ + FormInput( + AuthFormField.email, + customEmailValidator ?? const Email.pure(), + ), + FormInput( + AuthFormField.password, + customPasswordValidator ?? const Password.pure(), + ), + ...extraSignUpInputs ?? [] + ], + name: AuthFormName.signUpForm, + ); + + static WyattForm buildPasswordResetForm( + FormInputValidator? customEmailValidator, + ) => + WyattFormImpl( + [ + FormInput( + AuthFormField.email, + customEmailValidator ?? const Email.pure(), + ), + ], + name: AuthFormName.passwordResetForm, + ); + + static WyattForm buildEditAccountForm( + FormInputValidator? customEmailValidator, + FormInputValidator? customPasswordValidator, + // ignore: strict_raw_type + List? extraEditAccountInputs, + ) => + WyattFormImpl( + [ + FormInput( + AuthFormField.email, + customEmailValidator ?? const Email.pure(), + metadata: const FormInputMetadata(isRequired: false), + ), + FormInput( + AuthFormField.password, + customPasswordValidator ?? const Password.pure(), + metadata: const FormInputMetadata(isRequired: false), + ), + ...extraEditAccountInputs ?? [] + ], + validationStrategy: const OnlyRequiredInputValidator(), + name: AuthFormName.editAccountForm, + ); +} diff --git a/packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/authentication_firebase_data_source_impl.dart b/packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/authentication_firebase_data_source_impl.dart index 2d75d36a..b2c9d4f2 100644 --- a/packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/authentication_firebase_data_source_impl.dart +++ b/packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/authentication_firebase_data_source_impl.dart @@ -254,7 +254,11 @@ class AuthenticationFirebaseDataSourceImpl Future updateEmail({required String email}) async { try { await _firebaseAuth.currentUser!.updateEmail(email); - final account = AccountModel.fromFirebaseUser(_firebaseAuth.currentUser); + final jwt = await _firebaseAuth.currentUser!.getIdToken(true); + final account = AccountModel.fromFirebaseUser( + _firebaseAuth.currentUser, + accessToken: jwt, + ); return account; } on FirebaseAuthException catch (e) { @@ -269,7 +273,11 @@ class AuthenticationFirebaseDataSourceImpl Future updatePassword({required String password}) async { try { await _firebaseAuth.currentUser!.updatePassword(password); - final account = AccountModel.fromFirebaseUser(_firebaseAuth.currentUser); + final jwt = await _firebaseAuth.currentUser!.getIdToken(true); + final account = AccountModel.fromFirebaseUser( + _firebaseAuth.currentUser, + accessToken: jwt, + ); return account; } on FirebaseAuthException catch (e) { diff --git a/packages/wyatt_authentication_bloc/lib/src/data/repositories/authentication_repository_impl.dart b/packages/wyatt_authentication_bloc/lib/src/data/repositories/authentication_repository_impl.dart index 2c25e1bc..4d3a3f4e 100644 --- a/packages/wyatt_authentication_bloc/lib/src/data/repositories/authentication_repository_impl.dart +++ b/packages/wyatt_authentication_bloc/lib/src/data/repositories/authentication_repository_impl.dart @@ -15,8 +15,7 @@ // along with this program. If not, see . import 'package:wyatt_architecture/wyatt_architecture.dart'; -import 'package:wyatt_authentication_bloc/src/core/constants/form_field.dart'; -import 'package:wyatt_authentication_bloc/src/core/constants/form_name.dart'; +import 'package:wyatt_authentication_bloc/src/core/utils/forms.dart'; import 'package:wyatt_authentication_bloc/src/domain/data_sources/remote/authentication_remote_data_source.dart'; import 'package:wyatt_authentication_bloc/src/domain/entities/account.dart'; import 'package:wyatt_authentication_bloc/src/domain/entities/session_wrapper.dart'; @@ -31,6 +30,8 @@ class AuthenticationRepositoryImpl FormRepository? formRepository, // ignore: strict_raw_type List? extraSignUpInputs, + // ignore: strict_raw_type + List? extraEditAccountInputs, FormInputValidator? customEmailValidator, FormInputValidator? customPasswordValidator, }) { @@ -41,45 +42,26 @@ class AuthenticationRepositoryImpl } _formRepository ..registerForm( - WyattFormImpl( - [ - FormInput( - AuthFormField.email, - customEmailValidator ?? const Email.pure(), - ), - FormInput( - AuthFormField.password, - customPasswordValidator ?? const Password.pure(), - ) - ], - name: AuthFormName.signInForm, + Forms.buildSignUpForm( + customEmailValidator, + customPasswordValidator, + extraSignUpInputs, ), ) ..registerForm( - WyattFormImpl( - [ - FormInput( - AuthFormField.email, - customEmailValidator ?? const Email.pure(), - ), - FormInput( - AuthFormField.password, - customPasswordValidator ?? const Password.pure(), - ), - ...extraSignUpInputs ?? [] - ], - name: AuthFormName.signUpForm, + Forms.buildSignInForm( + customEmailValidator, + customPasswordValidator, ), ) ..registerForm( - WyattFormImpl( - [ - FormInput( - AuthFormField.email, - customEmailValidator ?? const Email.pure(), - ), - ], - name: AuthFormName.passwordResetForm, + Forms.buildPasswordResetForm(customEmailValidator), + ) + ..registerForm( + Forms.buildEditAccountForm( + customEmailValidator, + customPasswordValidator, + extraEditAccountInputs, ), ); } diff --git a/packages/wyatt_authentication_bloc/lib/src/features/edit_account/cubit/base_edit_account_cubit.dart b/packages/wyatt_authentication_bloc/lib/src/features/edit_account/cubit/base_edit_account_cubit.dart new file mode 100644 index 00000000..3d6ba12d --- /dev/null +++ b/packages/wyatt_authentication_bloc/lib/src/features/edit_account/cubit/base_edit_account_cubit.dart @@ -0,0 +1,100 @@ +// Copyright (C) 2023 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +part of 'edit_account_cubit.dart'; + +/// Abstract edit account cubit useful for implementing a cubit with fine +/// granularity by adding only the required mixins. +abstract class BaseEditAccountCubit + extends FormDataCubit { + BaseEditAccountCubit({ + required this.authenticationRepository, + }) : super( + EditAccountState( + form: authenticationRepository.formRepository + .accessForm(AuthFormName.signInForm), + ), + ); + final AuthenticationRepository authenticationRepository; + FormRepository get formRepository => authenticationRepository.formRepository; + + @override + String get formName => AuthFormName.signInForm; + + @override + FutureOr dataChanged( + String key, + FormInputValidator dirtyValue, + ) { + final form = formRepository.accessForm(formName).clone(); + + try { + form.updateValidator(key, dirtyValue); + formRepository.updateForm(form); + } catch (e) { + rethrow; + } + + emit( + EditAccountState(form: form, status: form.validate()), + ); + } + + @override + FutureOr reset() { + final form = state.form.reset(); + formRepository.updateForm(form); + emit( + EditAccountState(form: form, status: form.validate()), + ); + } + + @override + FutureOr update( + WyattForm form, { + SetOperation operation = SetOperation.replace, + }) { + final WyattForm current = formRepository.accessForm(formName).clone(); + final WyattForm newForm = operation.operation.call(current, form); + formRepository.updateForm(newForm); + + emit( + EditAccountState(form: newForm, status: newForm.validate()), + ); + } + + @override + FutureOr validate() { + final WyattForm form = formRepository.accessForm(formName); + emit( + EditAccountState(form: form, status: form.validate()), + ); + } + + @override + FutureOr submit() async { + final WyattForm form = formRepository.accessForm(formName); + const error = '`submit()` is not implemented for BaseEditAccountCubit, ' + 'please use `updateEmail()` or `updatePassword()`.'; + emit( + EditAccountState( + form: form, + errorMessage: error, + status: FormStatus.submissionFailure, + ), + ); + } +} diff --git a/packages/wyatt_authentication_bloc/lib/src/features/edit_account/cubit/edit_account_cubit.dart b/packages/wyatt_authentication_bloc/lib/src/features/edit_account/cubit/edit_account_cubit.dart new file mode 100644 index 00000000..b3fcc2b2 --- /dev/null +++ b/packages/wyatt_authentication_bloc/lib/src/features/edit_account/cubit/edit_account_cubit.dart @@ -0,0 +1,51 @@ +// Copyright (C) 2023 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +import 'dart:async'; + +import 'package:wyatt_architecture/wyatt_architecture.dart'; +import 'package:wyatt_authentication_bloc/src/core/constants/form_field.dart'; +import 'package:wyatt_authentication_bloc/src/core/constants/form_name.dart'; +import 'package:wyatt_authentication_bloc/src/domain/entities/account.dart'; +import 'package:wyatt_authentication_bloc/src/domain/repositories/authentication_repository.dart'; +import 'package:wyatt_authentication_bloc/src/features/edit_account/edit_account.dart'; +import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; +import 'package:wyatt_type_utils/wyatt_type_utils.dart'; + +part 'base_edit_account_cubit.dart'; +part 'edit_account_state.dart'; + +/// Fully featured edit account cubit. +/// +/// Sufficient in most cases. (Where fine granularity is not required.) +class EditAccountCubit extends BaseEditAccountCubit + with UpdateEmail, UpdatePassword { + EditAccountCubit({required super.authenticationRepository}); + + @override + FutureOrResult onEmailUpdated( + Result result, + WyattForm form, + ) => + const Ok(null); + + @override + FutureOrResult onPasswordUpdated( + Result result, + WyattForm form, + ) => + const Ok(null); +} diff --git a/packages/wyatt_authentication_bloc/lib/src/features/edit_account/cubit/edit_account_state.dart b/packages/wyatt_authentication_bloc/lib/src/features/edit_account/cubit/edit_account_state.dart new file mode 100644 index 00000000..0c8fbfba --- /dev/null +++ b/packages/wyatt_authentication_bloc/lib/src/features/edit_account/cubit/edit_account_state.dart @@ -0,0 +1,48 @@ +// Copyright (C) 2023 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +part of 'edit_account_cubit.dart'; + +/// Edit account cubit state to manage the form. +class EditAccountState extends FormDataState { + const EditAccountState({ + required super.form, + super.status = FormStatus.pure, + super.errorMessage, + }); + FormInputValidator get email => + form.validatorOf(AuthFormField.email); + FormInputValidator get password => + form.validatorOf(AuthFormField.password); + + EditAccountState copyWith({ + WyattForm? form, + FormStatus? status, + String? errorMessage, + }) => + EditAccountState( + form: form ?? this.form, + status: status ?? this.status, + errorMessage: errorMessage ?? this.errorMessage, + ); + + @override + List get props => [email, password, status]; + + @override + String toString() => 'EditAccountState(status: ${status.name} ' + '${(errorMessage != null) ? " [$errorMessage]" : ""}, $form)'; +} diff --git a/packages/wyatt_authentication_bloc/lib/src/features/edit_account/cubit/mixin/edit_email.dart b/packages/wyatt_authentication_bloc/lib/src/features/edit_account/cubit/mixin/edit_email.dart new file mode 100644 index 00000000..47aecb30 --- /dev/null +++ b/packages/wyatt_authentication_bloc/lib/src/features/edit_account/cubit/mixin/edit_email.dart @@ -0,0 +1,131 @@ +// Copyright (C) 2023 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +import 'dart:async'; + +import 'package:wyatt_architecture/wyatt_architecture.dart'; +import 'package:wyatt_authentication_bloc/src/core/constants/form_field.dart'; +import 'package:wyatt_authentication_bloc/src/core/utils/custom_routine.dart'; +import 'package:wyatt_authentication_bloc/src/domain/domain.dart'; +import 'package:wyatt_authentication_bloc/src/features/edit_account/cubit/edit_account_cubit.dart'; +import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; +import 'package:wyatt_type_utils/wyatt_type_utils.dart'; + +/// Edit account mixin. +/// +/// Allows the user to edit his email +/// +/// Gives access to the `updateEmail` method and +/// `onEmailUpdated` callback. +mixin UpdateEmail on BaseEditAccountCubit { + /// This callback is triggered when user updates his email + FutureOrResult onEmailUpdated( + Result result, + WyattForm form, + ); + + void emailChanged(String value) { + final emailValidatorType = formRepository + .accessForm(formName) + .validatorOf(AuthFormField.email) + .runtimeType; + assert( + emailValidatorType == Email, + 'Use emailCustomChanged(...) with validator $emailValidatorType', + ); + + final Email email = Email.dirty(value); + dataChanged(AuthFormField.email, email); + } + + /// Same as [emailChanged] but with a custom [Validator]. + /// + /// Sort of short hand for [dataChanged]. + void emailCustomChanged< + Validator extends FormInputValidator>( + Validator validator, + ) { + dataChanged(AuthFormField.email, validator); + } + + /// {@macro update_email} + FutureOr updateEmail() async { + if (state.status.isSubmissionInProgress) { + return; + } + + if (!state.status.isValidated) { + return; + } + + final form = formRepository.accessForm(formName); + emit( + EditAccountState( + form: form, + status: FormStatus.submissionInProgress, + ), + ); + + final email = form.valueOf(AuthFormField.email); + + if (email.isNullOrEmpty) { + emit( + EditAccountState( + form: form, + errorMessage: 'An error occured while retrieving data from the form.', + status: FormStatus.submissionFailure, + ), + ); + } + + return CustomRoutine( + routine: () => authenticationRepository.updateEmail( + email: email!, + ), + attachedLogic: (routineResult) => onEmailUpdated( + routineResult, + form, + ), + onError: (error) { + emit( + EditAccountState( + form: form, + errorMessage: error.message, + status: FormStatus.submissionFailure, + ), + ); + addError(error); + }, + onSuccess: (account, data) { + authenticationRepository.addSession( + SessionWrapper( + event: UpdatedEvent(account: account), + session: Session( + account: account, + data: data, + ), + ), + ); + emit( + EditAccountState( + form: form, + status: FormStatus.submissionSuccess, + ), + ); + }, + ).call(); + } +} diff --git a/packages/wyatt_authentication_bloc/lib/src/features/edit_account/cubit/mixin/edit_password.dart b/packages/wyatt_authentication_bloc/lib/src/features/edit_account/cubit/mixin/edit_password.dart new file mode 100644 index 00000000..3b270800 --- /dev/null +++ b/packages/wyatt_authentication_bloc/lib/src/features/edit_account/cubit/mixin/edit_password.dart @@ -0,0 +1,130 @@ +// Copyright (C) 2023 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +import 'dart:async'; + +import 'package:wyatt_architecture/wyatt_architecture.dart'; +import 'package:wyatt_authentication_bloc/src/core/constants/form_field.dart'; +import 'package:wyatt_authentication_bloc/src/core/utils/custom_routine.dart'; +import 'package:wyatt_authentication_bloc/src/domain/domain.dart'; +import 'package:wyatt_authentication_bloc/src/features/edit_account/cubit/edit_account_cubit.dart'; +import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; +import 'package:wyatt_type_utils/wyatt_type_utils.dart'; + +/// Edit account mixin. +/// +/// Allows the user to edit his password +/// +/// Gives access to the `updatePassword` method and +/// `onPasswordUpdated` callback. +mixin UpdatePassword on BaseEditAccountCubit { + /// This callback is triggered when a user edits his password. + FutureOrResult onPasswordUpdated( + Result result, + WyattForm form, + ); + + void passwordChanged(String value) { + final passwordValidatorType = formRepository + .accessForm(formName) + .validatorOf(AuthFormField.password) + .runtimeType; + assert( + passwordValidatorType == Password, + 'Use passwordCustomChanged(...) with validator $passwordValidatorType', + ); + final Password password = Password.dirty(value); + dataChanged(AuthFormField.password, password); + } + + /// Same as [passwordChanged] but with a custom [Validator]. + /// + /// Sort of short hand for [dataChanged]. + void passwordCustomChanged< + Validator extends FormInputValidator>( + Validator validator, + ) { + dataChanged(AuthFormField.password, validator); + } + + /// {@macro update_password} + FutureOr updatePassword() async { + if (state.status.isSubmissionInProgress) { + return; + } + + if (!state.status.isValidated) { + return; + } + + final form = formRepository.accessForm(formName); + emit( + EditAccountState( + form: form, + status: FormStatus.submissionInProgress, + ), + ); + + final password = form.valueOf(AuthFormField.password); + + if (password.isNullOrEmpty) { + emit( + EditAccountState( + form: form, + errorMessage: 'An error occured while retrieving data from the form.', + status: FormStatus.submissionFailure, + ), + ); + } + + return CustomRoutine( + routine: () => authenticationRepository.updatePassword( + password: password!, + ), + attachedLogic: (routineResult) => onPasswordUpdated( + routineResult, + form, + ), + onError: (error) { + emit( + EditAccountState( + form: form, + errorMessage: error.message, + status: FormStatus.submissionFailure, + ), + ); + addError(error); + }, + onSuccess: (account, data) { + authenticationRepository.addSession( + SessionWrapper( + event: SignedInEvent(account: account), + session: Session( + account: account, + data: data, + ), + ), + ); + emit( + EditAccountState( + form: form, + status: FormStatus.submissionSuccess, + ), + ); + }, + ).call(); + } +} diff --git a/packages/wyatt_authentication_bloc/lib/src/features/edit_account/edit_account.dart b/packages/wyatt_authentication_bloc/lib/src/features/edit_account/edit_account.dart new file mode 100644 index 00000000..1040179f --- /dev/null +++ b/packages/wyatt_authentication_bloc/lib/src/features/edit_account/edit_account.dart @@ -0,0 +1,20 @@ +// Copyright (C) 2023 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +export 'cubit/edit_account_cubit.dart'; +export 'cubit/mixin/edit_email.dart'; +export 'cubit/mixin/edit_password.dart'; +export 'listener/edit_account_listener.dart'; diff --git a/packages/wyatt_authentication_bloc/lib/src/features/edit_account/listener/edit_account_listener.dart b/packages/wyatt_authentication_bloc/lib/src/features/edit_account/listener/edit_account_listener.dart new file mode 100644 index 00000000..62134eb5 --- /dev/null +++ b/packages/wyatt_authentication_bloc/lib/src/features/edit_account/listener/edit_account_listener.dart @@ -0,0 +1,69 @@ +// Copyright (C) 2023 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +import 'package:flutter/material.dart'; +import 'package:flutter_bloc/flutter_bloc.dart'; +import 'package:wyatt_authentication_bloc/src/features/edit_account/cubit/edit_account_cubit.dart'; +import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; + +/// Widget that listens and builds a child based on the state of +/// the edit account cubit +class EditAccountListener extends StatelessWidget { + const EditAccountListener({ + required this.child, + this.onProgress, + this.onSuccess, + this.onError, + this.customBuilder, + super.key, + }); + + final void Function(BuildContext context)? onProgress; + final void Function(BuildContext context)? onSuccess; + final void Function( + BuildContext context, + FormStatus status, + String? errorMessage, + )? onError; + final void Function(BuildContext context, EditAccountState state)? + customBuilder; + final Widget child; + + @override + Widget build(BuildContext context) => + BlocListener, EditAccountState>( + listener: (context, state) { + if (customBuilder != null) { + return customBuilder!(context, state); + } + + if (onSuccess != null && + state.status == FormStatus.submissionSuccess) { + return onSuccess!(context); + } + if (onProgress != null && + state.status == FormStatus.submissionInProgress) { + return onProgress!(context); + } + if (onError != null && + (state.status == FormStatus.submissionCanceled || + state.status == FormStatus.submissionFailure)) { + return onError!(context, state.status, state.errorMessage); + } + }, + child: child, + ); +} diff --git a/packages/wyatt_authentication_bloc/lib/src/features/features.dart b/packages/wyatt_authentication_bloc/lib/src/features/features.dart index 435d4d30..cbdaf015 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/features.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/features.dart @@ -15,6 +15,7 @@ // along with this program. If not, see . export 'authentication/authentication.dart'; +export 'edit_account/edit_account.dart'; export 'email_verification/email_verification.dart'; export 'password_reset/password_reset.dart'; export 'sign_in/sign_in.dart'; diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/base_sign_in_cubit.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/base_sign_in_cubit.dart index 636a2786..bc55b6a8 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/base_sign_in_cubit.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/base_sign_in_cubit.dart @@ -86,7 +86,7 @@ abstract class BaseSignInCubit extends FormDataCubit { @override FutureOr submit() async { final WyattForm form = formRepository.accessForm(formName); - const error = '`submit()` is not implemented for BaseSignUpCubit, ' + const error = '`submit()` is not implemented for BaseSignInCubit, ' 'please use `signUpWithEmailAndPassword()`.'; emit( SignInState( -- 2.47.2 From 1de922f6446be06628025264065101c80bd59027 Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Mon, 6 Feb 2023 21:24:00 +0100 Subject: [PATCH 14/47] docs(authentication): update example --- .../example/lib/core/constants/form_name.dart | 19 --- .../example/lib/core/routes/router.dart | 14 +- .../lib/presentation/features/app/app.dart | 23 +-- .../sign_in/blocs/sign_in_cubit.dart} | 20 +-- .../sign_in/sign_in_page.dart | 2 +- .../sign_in/widgets/sign_in_form.dart | 28 ++-- .../sign_up/blocs/sign_up_cubit.dart} | 23 +-- .../sign_up/sign_up_page.dart | 2 +- .../sign_up/widgets/sign_up_form.dart | 34 ++-- .../blocs/edit_account_cubit.dart} | 32 ++-- .../edit_account/edit_account_page.dart} | 23 ++- .../widgets/edit_account_form.dart | 151 ++++++++++++++++++ .../presentation/features/home/home_page.dart | 48 +++--- .../features/welcome/welcome_page.dart | 24 +-- 14 files changed, 302 insertions(+), 141 deletions(-) delete mode 100644 packages/wyatt_authentication_bloc/example/lib/core/constants/form_name.dart rename packages/wyatt_authentication_bloc/example/lib/presentation/features/{sign_in/blocs/custom_sign_in_cubit.dart => authentication/sign_in/blocs/sign_in_cubit.dart} (62%) rename packages/wyatt_authentication_bloc/example/lib/presentation/features/{ => authentication}/sign_in/sign_in_page.dart (91%) rename packages/wyatt_authentication_bloc/example/lib/presentation/features/{ => authentication}/sign_in/widgets/sign_in_form.dart (89%) rename packages/wyatt_authentication_bloc/example/lib/presentation/features/{sign_up/blocs/custom_sign_up_cubit.dart => authentication/sign_up/blocs/sign_up_cubit.dart} (64%) rename packages/wyatt_authentication_bloc/example/lib/presentation/features/{ => authentication}/sign_up/sign_up_page.dart (91%) rename packages/wyatt_authentication_bloc/example/lib/presentation/features/{ => authentication}/sign_up/widgets/sign_up_form.dart (85%) rename packages/wyatt_authentication_bloc/example/lib/{core/utils/forms.dart => presentation/features/edit_account/blocs/edit_account_cubit.dart} (58%) rename packages/wyatt_authentication_bloc/example/lib/{core/constants/form_field.dart => presentation/features/edit_account/edit_account_page.dart} (54%) create mode 100644 packages/wyatt_authentication_bloc/example/lib/presentation/features/edit_account/widgets/edit_account_form.dart diff --git a/packages/wyatt_authentication_bloc/example/lib/core/constants/form_name.dart b/packages/wyatt_authentication_bloc/example/lib/core/constants/form_name.dart deleted file mode 100644 index 1ff68488..00000000 --- a/packages/wyatt_authentication_bloc/example/lib/core/constants/form_name.dart +++ /dev/null @@ -1,19 +0,0 @@ -// Copyright (C) 2023 WYATT GROUP -// Please see the AUTHORS file for details. -// -// This program is free software: you can redistribute it and/or modify -// it under the terms of the GNU General Public License as published by -// the Free Software Foundation, either version 3 of the License, or -// any later version. -// -// This program is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with this program. If not, see . - -abstract class AppFormName { - static const editProfile = 'editProfile'; -} diff --git a/packages/wyatt_authentication_bloc/example/lib/core/routes/router.dart b/packages/wyatt_authentication_bloc/example/lib/core/routes/router.dart index dea8429c..f38047f3 100644 --- a/packages/wyatt_authentication_bloc/example/lib/core/routes/router.dart +++ b/packages/wyatt_authentication_bloc/example/lib/core/routes/router.dart @@ -14,9 +14,10 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . +import 'package:example_router/presentation/features/authentication/sign_in/sign_in_page.dart'; +import 'package:example_router/presentation/features/authentication/sign_up/sign_up_page.dart'; +import 'package:example_router/presentation/features/edit_account/edit_account_page.dart'; import 'package:example_router/presentation/features/home/home_page.dart'; -import 'package:example_router/presentation/features/sign_in/sign_in_page.dart'; -import 'package:example_router/presentation/features/sign_up/sign_up_page.dart'; import 'package:example_router/presentation/features/sub/sub_page.dart'; import 'package:example_router/presentation/features/welcome/welcome_page.dart'; import 'package:flutter/cupertino.dart'; @@ -82,6 +83,15 @@ class AppRouter { const SubPage(), ), ), + GoRoute( + path: 'edit_account', + name: EditAccountPage.pageName, + pageBuilder: (context, state) => defaultTransition( + context, + state, + const EditAccountPage(), + ), + ), ]), ]; } diff --git a/packages/wyatt_authentication_bloc/example/lib/presentation/features/app/app.dart b/packages/wyatt_authentication_bloc/example/lib/presentation/features/app/app.dart index 75388b5e..5285f63d 100644 --- a/packages/wyatt_authentication_bloc/example/lib/presentation/features/app/app.dart +++ b/packages/wyatt_authentication_bloc/example/lib/presentation/features/app/app.dart @@ -16,14 +16,13 @@ import 'dart:async'; -import 'package:example_router/core/constants/form_field.dart'; import 'package:example_router/core/dependency_injection/get_it.dart'; import 'package:example_router/core/routes/router.dart'; import 'package:example_router/core/utils/custom_password.dart'; -import 'package:example_router/core/utils/forms.dart'; import 'package:example_router/presentation/features/authentication/authentication_cubit.dart'; -import 'package:example_router/presentation/features/sign_in/blocs/custom_sign_in_cubit.dart'; -import 'package:example_router/presentation/features/sign_up/blocs/custom_sign_up_cubit.dart'; +import 'package:example_router/presentation/features/authentication/sign_in/blocs/sign_in_cubit.dart'; +import 'package:example_router/presentation/features/authentication/sign_up/blocs/sign_up_cubit.dart'; +import 'package:example_router/presentation/features/edit_account/blocs/edit_account_cubit.dart'; import 'package:flutter/material.dart'; import 'package:flutter_bloc/flutter_bloc.dart'; import 'package:go_router/go_router.dart'; @@ -38,7 +37,7 @@ class App extends StatelessWidget { customPasswordValidator: const CustomPassword.pure(), extraSignUpInputs: [ FormInput( - AppFormField.confirmedPassword, + AuthFormField.confirmPassword, const ConfirmedPassword.pure(), metadata: const FormInputMetadata(export: false), ), @@ -90,9 +89,8 @@ class App extends StatelessWidget { value: authenticationRepository, ), RepositoryProvider( - create: (context) => - FormRepositoryImpl()..registerForm(AppForms.getEditProfileForm()), - ), + create: (context) => FormRepositoryImpl(), + ) ], child: MultiBlocProvider( providers: [ @@ -100,12 +98,17 @@ class App extends StatelessWidget { value: authenticationCubit, ), BlocProvider>( - create: (_) => CustomSignUpCubit( + create: (_) => ExampleSignUpCubit( authenticationRepository: authenticationRepository, ), ), BlocProvider>( - create: (_) => CustomSignInCubit( + create: (_) => ExampleSignInCubit( + authenticationRepository: authenticationRepository, + ), + ), + BlocProvider>( + create: (_) => ExampleEditAccountCubit( authenticationRepository: authenticationRepository, ), ), diff --git a/packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_in/blocs/custom_sign_in_cubit.dart b/packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/sign_in/blocs/sign_in_cubit.dart similarity index 62% rename from packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_in/blocs/custom_sign_in_cubit.dart rename to packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/sign_in/blocs/sign_in_cubit.dart index 882cfd35..947295c2 100644 --- a/packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_in/blocs/custom_sign_in_cubit.dart +++ b/packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/sign_in/blocs/sign_in_cubit.dart @@ -14,33 +14,35 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . -import 'package:wyatt_architecture/src/domain/usecases/usecase.dart'; -import 'package:wyatt_architecture/src/core/exceptions/exceptions.dart'; +import 'package:wyatt_architecture/wyatt_architecture.dart'; import 'package:wyatt_authentication_bloc/wyatt_authentication_bloc.dart'; -import 'package:wyatt_type_utils/src/either/either_base.dart'; -import 'package:wyatt_form_bloc/src/domain/form/wyatt_form.dart'; +import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; +import 'package:wyatt_type_utils/wyatt_type_utils.dart'; -class CustomSignInCubit extends SignInCubit { - CustomSignInCubit({ +class ExampleSignInCubit extends SignInCubit { + ExampleSignInCubit({ required super.authenticationRepository, }); @override - FutureOrResult onSignInWithEmailAndPassword(Result result, WyattForm form) { + FutureOrResult onSignInWithEmailAndPassword( + Result result, WyattForm form) { print('onSignInWithEmailAndPassword'); return const Ok(1); } @override - FutureOrResult onSignInAnonymously(Result result, WyattForm form) { + FutureOrResult onSignInAnonymously( + Result result, WyattForm form) { print('onSignInAnonymously'); return const Ok(1); } @override - FutureOrResult onSignInWithGoogle(Result result, WyattForm form) { + FutureOrResult onSignInWithGoogle( + Result result, WyattForm form) { print('onSignInWithGoogle'); return const Ok(1); diff --git a/packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_in/sign_in_page.dart b/packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/sign_in/sign_in_page.dart similarity index 91% rename from packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_in/sign_in_page.dart rename to packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/sign_in/sign_in_page.dart index 5ac3770b..5294fed0 100644 --- a/packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_in/sign_in_page.dart +++ b/packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/sign_in/sign_in_page.dart @@ -14,7 +14,7 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . -import 'package:example_router/presentation/features/sign_in/widgets/sign_in_form.dart'; +import 'package:example_router/presentation/features/authentication/sign_in/widgets/sign_in_form.dart'; import 'package:flutter/material.dart'; class SignInPage extends StatelessWidget { diff --git a/packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_in/widgets/sign_in_form.dart b/packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/sign_in/widgets/sign_in_form.dart similarity index 89% rename from packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_in/widgets/sign_in_form.dart rename to packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/sign_in/widgets/sign_in_form.dart index bf39991c..ebb65583 100644 --- a/packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_in/widgets/sign_in_form.dart +++ b/packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/sign_in/widgets/sign_in_form.dart @@ -121,21 +121,19 @@ class SignInForm extends StatelessWidget { ..showSnackBar( SnackBar(content: Text(errorMessage ?? 'Sign In Failure')), ), - child: SingleChildScrollView( - child: Column( - crossAxisAlignment: CrossAxisAlignment.center, - children: [ - _EmailInput(), - const SizedBox(height: 8), - _PasswordInput(), - const SizedBox(height: 16), - _SignInButton(), - const SizedBox(height: 16), - _SignInAnonymouslyButton(), - const SizedBox(height: 16), - _SignInWithGoogleButton(), - ], - ), + child: ListView( + shrinkWrap: true, + children: [ + _EmailInput(), + const SizedBox(height: 8), + _PasswordInput(), + const SizedBox(height: 16), + _SignInButton(), + const SizedBox(height: 16), + _SignInAnonymouslyButton(), + const SizedBox(height: 16), + _SignInWithGoogleButton(), + ], ), ); } diff --git a/packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_up/blocs/custom_sign_up_cubit.dart b/packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/sign_up/blocs/sign_up_cubit.dart similarity index 64% rename from packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_up/blocs/custom_sign_up_cubit.dart rename to packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/sign_up/blocs/sign_up_cubit.dart index d49e6056..3f5bb9a1 100644 --- a/packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_up/blocs/custom_sign_up_cubit.dart +++ b/packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/sign_up/blocs/sign_up_cubit.dart @@ -14,34 +14,21 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . - import 'package:wyatt_architecture/wyatt_architecture.dart'; import 'package:wyatt_authentication_bloc/wyatt_authentication_bloc.dart'; import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; import 'package:wyatt_type_utils/wyatt_type_utils.dart'; -class CustomSignUpCubit extends SignUpCubit { - CustomSignUpCubit({ +class ExampleSignUpCubit extends SignUpCubit { + ExampleSignUpCubit({ required super.authenticationRepository, }); - - @override - FutureOrResult onSignUpWithEmailAndPassword(Result result, WyattForm form) async { - // if (result.isOk) { - // await Future.delayed(const Duration(seconds: 3)); - // const id = -1; - // final confirmedPassword = - // form.valueOf(AppFormField.confirmedPassword); - // debugPrint( - // 'onSignUpSuccess: ${result.ok}, generatedId: $id, intFormData: $confirmedPassword'); - // return const Ok(id); - // } - // return const Ok(null); + @override + FutureOrResult onSignUpWithEmailAndPassword( + Result result, WyattForm form) async { print('onSignUpWithEmailAndPassword'); return const Ok(1); } - - } diff --git a/packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_up/sign_up_page.dart b/packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/sign_up/sign_up_page.dart similarity index 91% rename from packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_up/sign_up_page.dart rename to packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/sign_up/sign_up_page.dart index 2f0f6ce5..d9963142 100644 --- a/packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_up/sign_up_page.dart +++ b/packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/sign_up/sign_up_page.dart @@ -14,7 +14,7 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . -import 'package:example_router/presentation/features/sign_up/widgets/sign_up_form.dart'; +import 'package:example_router/presentation/features/authentication/sign_up/widgets/sign_up_form.dart'; import 'package:flutter/material.dart'; class SignUpPage extends StatelessWidget { diff --git a/packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_up/widgets/sign_up_form.dart b/packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/sign_up/widgets/sign_up_form.dart similarity index 85% rename from packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_up/widgets/sign_up_form.dart rename to packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/sign_up/widgets/sign_up_form.dart index 23b9884d..4c13a491 100644 --- a/packages/wyatt_authentication_bloc/example/lib/presentation/features/sign_up/widgets/sign_up_form.dart +++ b/packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/sign_up/widgets/sign_up_form.dart @@ -14,7 +14,6 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . -import 'package:example_router/core/constants/form_field.dart'; import 'package:example_router/core/utils/custom_password.dart'; import 'package:flutter/material.dart' hide FormField; import 'package:wyatt_authentication_bloc/wyatt_authentication_bloc.dart'; @@ -51,11 +50,11 @@ class _PasswordInput extends StatelessWidget { cubit.passwordCustomChanged( CustomPassword.dirty(pwd)); cubit.dataChanged( - AppFormField.confirmedPassword, + AuthFormField.confirmPassword, ConfirmedPassword.dirty( password: pwd, value: state.form - .valueOf(AppFormField.confirmedPassword))); + .valueOf(AuthFormField.confirmPassword))); }, obscureText: true, decoration: InputDecoration( @@ -73,7 +72,7 @@ class _ConfirmPasswordInput extends StatelessWidget { @override Widget build(BuildContext context) { return InputBuilder>( - field: AppFormField.confirmedPassword, + field: AuthFormField.confirmPassword, builder: ((context, cubit, state, field, input) { return TextField( onChanged: (pwd) { @@ -106,7 +105,9 @@ class _SignUpButton extends StatelessWidget { return status.isSubmissionInProgress ? const CircularProgressIndicator() : ElevatedButton( - onPressed: status.isValidated ? () => cubit.signUpWithEmailPassword() : null, + onPressed: status.isValidated + ? () => cubit.signUpWithEmailPassword() + : null, child: const Text('Sign up'), ); }), @@ -126,18 +127,17 @@ class SignUpForm extends StatelessWidget { ..showSnackBar( SnackBar(content: Text(errorMessage ?? 'Sign Up Failure')), ), - child: SingleChildScrollView( - child: Column( - children: [ - _EmailInput(), - const SizedBox(height: 8), - _PasswordInput(), - const SizedBox(height: 8), - _ConfirmPasswordInput(), - const SizedBox(height: 16), - _SignUpButton(), - ], - ), + child: ListView( + shrinkWrap: true, + children: [ + _EmailInput(), + const SizedBox(height: 8), + _PasswordInput(), + const SizedBox(height: 8), + _ConfirmPasswordInput(), + const SizedBox(height: 16), + _SignUpButton(), + ], )); } } diff --git a/packages/wyatt_authentication_bloc/example/lib/core/utils/forms.dart b/packages/wyatt_authentication_bloc/example/lib/presentation/features/edit_account/blocs/edit_account_cubit.dart similarity index 58% rename from packages/wyatt_authentication_bloc/example/lib/core/utils/forms.dart rename to packages/wyatt_authentication_bloc/example/lib/presentation/features/edit_account/blocs/edit_account_cubit.dart index 49fdfa9a..1a5d2b8c 100644 --- a/packages/wyatt_authentication_bloc/example/lib/core/utils/forms.dart +++ b/packages/wyatt_authentication_bloc/example/lib/presentation/features/edit_account/blocs/edit_account_cubit.dart @@ -14,19 +14,27 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . -import 'package:example_router/core/constants/form_field.dart'; -import 'package:example_router/core/constants/form_name.dart'; -import 'package:example_router/core/utils/custom_password.dart'; +import 'package:wyatt_architecture/wyatt_architecture.dart'; import 'package:wyatt_authentication_bloc/wyatt_authentication_bloc.dart'; import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; +import 'package:wyatt_type_utils/wyatt_type_utils.dart'; -abstract class AppForms { - static WyattForm getEditProfileForm() => WyattFormImpl( - [ - FormInput(AuthFormField.email, const Email.pure()), - FormInput(AuthFormField.password, const CustomPassword.pure()), - FormInput(AppFormField.oldPassword, const CustomPassword.pure()), - ], - name: AppFormName.editProfile, - ); +class ExampleEditAccountCubit extends EditAccountCubit { + ExampleEditAccountCubit({required super.authenticationRepository}); + + @override + FutureOrResult onEmailUpdated( + Result result, WyattForm form) async { + print('onEmailUpdated'); + + return const Ok(1); + } + + @override + FutureOrResult onPasswordUpdated( + Result result, WyattForm form) async { + print('onPasswordUpdated'); + + return const Ok(1); + } } diff --git a/packages/wyatt_authentication_bloc/example/lib/core/constants/form_field.dart b/packages/wyatt_authentication_bloc/example/lib/presentation/features/edit_account/edit_account_page.dart similarity index 54% rename from packages/wyatt_authentication_bloc/example/lib/core/constants/form_field.dart rename to packages/wyatt_authentication_bloc/example/lib/presentation/features/edit_account/edit_account_page.dart index d111abaf..11b0f987 100644 --- a/packages/wyatt_authentication_bloc/example/lib/core/constants/form_field.dart +++ b/packages/wyatt_authentication_bloc/example/lib/presentation/features/edit_account/edit_account_page.dart @@ -14,7 +14,24 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . -abstract class AppFormField { - static const oldPassword = 'oldPassword'; - static const confirmedPassword = 'confirmedPassword'; +import 'package:example_router/presentation/features/edit_account/widgets/edit_account_form.dart'; +import 'package:flutter/material.dart'; + +class EditAccountPage extends StatelessWidget { + const EditAccountPage({Key? key}) : super(key: key); + + static String pageName = 'EditAccount'; + + @override + Widget build(BuildContext context) { + return Scaffold( + appBar: AppBar(title: const Text('Edit Account')), + body: const Padding( + padding: EdgeInsets.all(8), + child: SingleChildScrollView( + child: EditAccountForm(), + ), + ), + ); + } } diff --git a/packages/wyatt_authentication_bloc/example/lib/presentation/features/edit_account/widgets/edit_account_form.dart b/packages/wyatt_authentication_bloc/example/lib/presentation/features/edit_account/widgets/edit_account_form.dart new file mode 100644 index 00000000..c80439a9 --- /dev/null +++ b/packages/wyatt_authentication_bloc/example/lib/presentation/features/edit_account/widgets/edit_account_form.dart @@ -0,0 +1,151 @@ +// Copyright (C) 2023 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +import 'package:example_router/core/utils/custom_password.dart'; +import 'package:flutter/material.dart'; +import 'package:wyatt_authentication_bloc/wyatt_authentication_bloc.dart'; +import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; + +class _EmailInput extends StatelessWidget { + @override + Widget build(BuildContext context) { + return InputBuilder>( + field: AuthFormField.email, + builder: ((context, cubit, state, field, input) { + return TextField( + onChanged: (email) => cubit.emailChanged(email), + keyboardType: TextInputType.emailAddress, + decoration: InputDecoration( + labelText: 'Email', + helperText: '', + errorText: input.validator.invalid ? 'Invalid email' : null, + ), + ); + }), + ); + } +} + +class _PasswordInput extends StatelessWidget { + @override + Widget build(BuildContext context) { + return InputBuilder>( + field: AuthFormField.password, + builder: ((context, cubit, state, field, input) { + return TextField( + onChanged: (pwd) => cubit + .passwordCustomChanged(CustomPassword.dirty(pwd)), + obscureText: true, + decoration: InputDecoration( + labelText: 'Password', + helperText: '', + errorText: input.validator.invalid ? 'Invalid password' : null, + ), + ); + }), + ); + } +} + +class _EditAccountButton extends StatelessWidget { + @override + Widget build(BuildContext context) { + return SubmitBuilder>( + builder: ((context, cubit, status) { + return status.isSubmissionInProgress + ? const CircularProgressIndicator() + : ElevatedButton( + onPressed: status.isValidated + ? () { + cubit.updateEmail(); + cubit.updatePassword(); + } + : null, + child: const Text('Update Account'), + ); + }), + ); + } +} + +class _EditAccountEmailButton extends StatelessWidget { + @override + Widget build(BuildContext context) { + return SubmitBuilder>( + builder: ((context, cubit, status) { + return status.isSubmissionInProgress + ? const CircularProgressIndicator() + : ElevatedButton( + onPressed: status.isValidated + ? () { + cubit.updateEmail(); + } + : null, + child: const Text('Update Account Email'), + ); + }), + ); + } +} + +class _EditAccountPasswordButton extends StatelessWidget { + @override + Widget build(BuildContext context) { + return SubmitBuilder>( + builder: ((context, cubit, status) { + return status.isSubmissionInProgress + ? const CircularProgressIndicator() + : ElevatedButton( + onPressed: status.isValidated + ? () { + cubit.updatePassword(); + } + : null, + child: const Text('Update Account Password'), + ); + }), + ); + } +} + +class EditAccountForm extends StatelessWidget { + const EditAccountForm({Key? key}) : super(key: key); + + @override + Widget build(BuildContext context) { + return EditAccountListener( + onError: (context, status, errorMessage) => ScaffoldMessenger.of(context) + ..hideCurrentSnackBar() + ..showSnackBar( + SnackBar(content: Text(errorMessage ?? 'Account edition Failure')), + ), + child: ListView( + shrinkWrap: true, + children: [ + _EmailInput(), + const SizedBox(height: 8), + _PasswordInput(), + const SizedBox(height: 16), + _EditAccountButton(), + const SizedBox(height: 16), + _EditAccountEmailButton(), + const SizedBox(height: 16), + _EditAccountPasswordButton(), + ], + ), + ); + } +} diff --git a/packages/wyatt_authentication_bloc/example/lib/presentation/features/home/home_page.dart b/packages/wyatt_authentication_bloc/example/lib/presentation/features/home/home_page.dart index a66a38a0..dade25b8 100644 --- a/packages/wyatt_authentication_bloc/example/lib/presentation/features/home/home_page.dart +++ b/packages/wyatt_authentication_bloc/example/lib/presentation/features/home/home_page.dart @@ -14,6 +14,7 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . +import 'package:example_router/presentation/features/edit_account/edit_account_page.dart'; import 'package:example_router/presentation/features/sub/sub_page.dart'; import 'package:flutter/material.dart'; import 'package:flutter_bloc/flutter_bloc.dart'; @@ -29,7 +30,8 @@ class HomePage extends StatelessWidget { Widget build(BuildContext context) { return Scaffold( appBar: AppBar( - title: Text('Home | ${context.account, int>()?.email}'), + title: Text( + 'Home | ${context.account, int>()?.email}'), actions: [ IconButton( onPressed: () => @@ -39,29 +41,27 @@ class HomePage extends StatelessWidget { ), body: Padding( padding: const EdgeInsets.all(8), - child: SingleChildScrollView( - child: Column( - children: [ - AuthenticationBuilder( - authenticated: (context, sessionWrapper) => Text( - 'Logged as ${sessionWrapper.session?.account.email} | GeneratedId is ${sessionWrapper.session?.data}'), - unauthenticated: (context) => - const Text('Not logged (unauthenticated)'), - unknown: (context) => const Text('Not logged (unknown)'), - ), - const SizedBox( - height: 8, - ), - ElevatedButton( - onPressed: () => context.pushNamed(SubPage.pageName), - child: const Text('Go to sub page'), - ), - // ElevatedButton( - // onPressed: () => context.pushNamed(EditProfilePage.pageName), - // child: const Text('Go to edit profile page'), - // ), - ], - ), + child: ListView( + children: [ + AuthenticationBuilder( + authenticated: (context, sessionWrapper) => Text( + 'Logged as ${sessionWrapper.session?.account.email} | GeneratedId is ${sessionWrapper.session?.data}'), + unauthenticated: (context) => + const Text('Not logged (unauthenticated)'), + unknown: (context) => const Text('Not logged (unknown)'), + ), + const SizedBox( + height: 8, + ), + ElevatedButton( + onPressed: () => context.pushNamed(SubPage.pageName), + child: const Text('Go to sub page'), + ), + ElevatedButton( + onPressed: () => context.pushNamed(EditAccountPage.pageName), + child: const Text('Go to edit account page'), + ), + ], ), ), ); diff --git a/packages/wyatt_authentication_bloc/example/lib/presentation/features/welcome/welcome_page.dart b/packages/wyatt_authentication_bloc/example/lib/presentation/features/welcome/welcome_page.dart index 29e97aa4..2d2ab4bc 100644 --- a/packages/wyatt_authentication_bloc/example/lib/presentation/features/welcome/welcome_page.dart +++ b/packages/wyatt_authentication_bloc/example/lib/presentation/features/welcome/welcome_page.dart @@ -14,8 +14,8 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . -import 'package:example_router/presentation/features/sign_in/sign_in_page.dart'; -import 'package:example_router/presentation/features/sign_up/sign_up_page.dart'; +import 'package:example_router/presentation/features/authentication/sign_in/sign_in_page.dart'; +import 'package:example_router/presentation/features/authentication/sign_up/sign_up_page.dart'; import 'package:flutter/material.dart'; import 'package:go_router/go_router.dart'; @@ -30,22 +30,26 @@ class WelcomePage extends StatelessWidget { appBar: AppBar( title: const Text('Welcome'), ), - body: SingleChildScrollView( - child: Column( - children: [ - ElevatedButton( + body: ListView( + children: [ + Padding( + padding: const EdgeInsets.all(8.0), + child: ElevatedButton( onPressed: () => context.pushNamed(SignUpPage.pageName), child: const Text('Sign Up')), - ElevatedButton( + ), + Padding( + padding: const EdgeInsets.all(8.0), + child: ElevatedButton( onPressed: () => context.pushNamed(SignInPage.pageName), style: ButtonStyle( backgroundColor: MaterialStateProperty.all(Colors.white), foregroundColor: MaterialStateProperty.all(Colors.blue)), - child: const Text('Sign In')) - ], - ), + child: const Text('Sign In')), + ) + ], ), ); } -- 2.47.2 From 87c557263d587400d38f6899fc0f058e915af985 Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Tue, 7 Feb 2023 10:45:08 +0100 Subject: [PATCH 15/47] docs(authentication): add wiki script --- .gitmodules | 3 +++ packages/wyatt_authentication_bloc/docs.sh | 18 ++++++++++++++++++ .../lib/wyatt_authentication_bloc.dart | 2 -- wiki | 1 + 4 files changed, 22 insertions(+), 2 deletions(-) create mode 100644 .gitmodules create mode 100755 packages/wyatt_authentication_bloc/docs.sh create mode 160000 wiki diff --git a/.gitmodules b/.gitmodules new file mode 100644 index 00000000..1c915584 --- /dev/null +++ b/.gitmodules @@ -0,0 +1,3 @@ +[submodule "wiki"] + path = wiki + url = ssh://git@git.wyatt-studio.fr:993/Wyatt-FOSS/wyatt-packages.wiki.git diff --git a/packages/wyatt_authentication_bloc/docs.sh b/packages/wyatt_authentication_bloc/docs.sh new file mode 100755 index 00000000..ec3f7ebb --- /dev/null +++ b/packages/wyatt_authentication_bloc/docs.sh @@ -0,0 +1,18 @@ +sed -i -e "s/export 'package:firebase_auth\/firebase_auth.dart';/\/\/export 'package:firebase_auth\/firebase_auth.dart';/g" lib/wyatt_authentication_bloc.dart +sed -i -e "s/export 'package:google_sign_in\/google_sign_in.dart';/\/\/export 'package:google_sign_in\/google_sign_in.dart';/g" lib/wyatt_authentication_bloc.dart + +dart pub global activate dartdoc +dart pub global run dartdoc --format md \ + --exclude package:firebase_auth,package:google_sign_in, \ + dart:async,dart:collection,dart:convert,dart:core,dart:developer, \ + dart:io,dart:isolate,dart:math,dart:typed_data,dart:ui,dart:ffi, \ + dart:html,dart:js,dart:js_util \ + --no-auto-include-dependencies \ + --no-validate-links \ + --show-progress \ + --output "/Users/hpcl/Work/Wyatt/wyatt-packages/wiki/wyatt_authentication_bloc/" + +sed -i -e "s/\/\/export 'package:firebase_auth\/firebase_auth.dart';/export 'package:firebase_auth\/firebase_auth.dart';/g" lib/wyatt_authentication_bloc.dart +sed -i -e "s/\/\/export 'package:google_sign_in\/google_sign_in.dart';/export 'package:google_sign_in\/google_sign_in.dart';/g" lib/wyatt_authentication_bloc.dart + +rm lib/wyatt_authentication_bloc.dart-e \ No newline at end of file diff --git a/packages/wyatt_authentication_bloc/lib/wyatt_authentication_bloc.dart b/packages/wyatt_authentication_bloc/lib/wyatt_authentication_bloc.dart index f8151ff0..b8c28dca 100644 --- a/packages/wyatt_authentication_bloc/lib/wyatt_authentication_bloc.dart +++ b/packages/wyatt_authentication_bloc/lib/wyatt_authentication_bloc.dart @@ -17,9 +17,7 @@ /// An authentication library for BLoC. library wyatt_authentication_bloc; -/// {@nodoc} export 'package:firebase_auth/firebase_auth.dart'; -/// {@nodoc} export 'package:google_sign_in/google_sign_in.dart'; export 'src/src.dart'; diff --git a/wiki b/wiki new file mode 160000 index 00000000..f5a9066a --- /dev/null +++ b/wiki @@ -0,0 +1 @@ +Subproject commit f5a9066a571ee6f9359ad58e9fd6afafc06703d0 -- 2.47.2 From 0c876e829e5736057442edeaabcd96f1b28694a5 Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Tue, 7 Feb 2023 11:36:47 +0100 Subject: [PATCH 16/47] docs: roolback and remove wiki --- .gitmodules | 3 --- wiki | 1 - 2 files changed, 4 deletions(-) delete mode 100644 .gitmodules delete mode 160000 wiki diff --git a/.gitmodules b/.gitmodules deleted file mode 100644 index 1c915584..00000000 --- a/.gitmodules +++ /dev/null @@ -1,3 +0,0 @@ -[submodule "wiki"] - path = wiki - url = ssh://git@git.wyatt-studio.fr:993/Wyatt-FOSS/wyatt-packages.wiki.git diff --git a/wiki b/wiki deleted file mode 160000 index f5a9066a..00000000 --- a/wiki +++ /dev/null @@ -1 +0,0 @@ -Subproject commit f5a9066a571ee6f9359ad58e9fd6afafc06703d0 -- 2.47.2 From 8ed9e86db2e805849868aaee38253a708946e7d1 Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Tue, 7 Feb 2023 13:59:01 +0100 Subject: [PATCH 17/47] test(authentication): update tests --- packages/wyatt_authentication_bloc/README.md | 216 +++++++++++++++--- packages/wyatt_authentication_bloc/docs.sh | 1 - .../authentication_cubit_test.dart | 85 ++++--- .../authentication_state_test.dart | 18 +- .../email_verification_cubit_test.dart | 46 ++-- .../test/sign_up/sign_up_cubit_test.dart | 13 +- 6 files changed, 255 insertions(+), 124 deletions(-) diff --git a/packages/wyatt_authentication_bloc/README.md b/packages/wyatt_authentication_bloc/README.md index 755c77e0..04f0f236 100644 --- a/packages/wyatt_authentication_bloc/README.md +++ b/packages/wyatt_authentication_bloc/README.md @@ -1,5 +1,5 @@ +

Flutter - Authentication BLoC

+ Style: Wyatt Analysis + SDK: Flutter +

+

Authentication Bloc for Flutter.

+

Features

+
    +
  • 🧐 Wyatt Architecture
  • +
  • 🧱 Entities +
      +
    • Account -> Contains account information from provider.
    • +
    • Session -> Contains account and associated data retrieved from an external source.
    • +
    • AuthenticationChangeEvent -> Describes an event in authentication change (sign in, sign up, sign out, etc...)
    • +
    • SessionWrapper -> Contains latest authentication change event and session.
    • +
    +
  • +
  • 🔑 Powerful and secured authentication repository
  • +
  • 🔥 Multiple data sources +
      +
    • Mock
    • +
    • Firebase
    • +
    +
  • +
  • 🧊 Cubits, why make it complicated when you can make it simple? +
      +
    • Goes to the essential.
    • +
    +
  • +
  • 📐 Consistent +
      +
    • Every class have same naming convention
    • +
    +
  • +
  • 🧪 Tested
  • +
  • 📚 Documented: available here
  • +
+

Getting started

+

Simply add wyatt_authentication_bloc in pubspec.yaml , then

+
import 'package:wyatt_authentication_bloc/wyatt_authentication_bloc.dart';
+
+

Data source

+

The first step is to provide a data source.

+
getIt.registerLazySingleton<AuthenticationRemoteDataSource<int>>(
+    () => AuthenticationFirebaseDataSourceImpl<int>(
+        firebaseAuth: FirebaseAuth.instance,
+        googleSignIn:
+            GoogleSignIn(clientId: DefaultFirebaseOptions.ios.iosClientId)),
+);
+
+
+

Here we use GetIt (see example project)

+
+

Repository

+

Then you can configure your repository.

+
final AuthenticationRepository<int> authenticationRepository = AuthenticationRepositoryImpl(
+    authenticationRemoteDataSource:
+        getIt<AuthenticationRemoteDataSource<int>>(),
+    customPasswordValidator: const CustomPassword.pure(),
+    extraSignUpInputs: [
+        FormInput(
+        AuthFormField.confirmPassword,
+        const ConfirmedPassword.pure(),
+        metadata: const FormInputMetadata<void>(export: false),
+        ),
+    ],
+);
+
+
+

Here we pass some extra inputs for the sign up, and a custom password validator.

+
+

Cubits

+

It is necessary to implement each cubit. Don't panic, most of the work is already done 😊 you just have to customize the logic of these.

+

In each of these cubits it is necessary to overload the various callbacks.

+
+

Here the associated data Data is a int

+
+

Authentication

+

In the authentication are managed, the refresh, the deletion of account or the disconnection.

+
class ExampleAuthenticationCubit extends AuthenticationCubit<int> {
+  ExampleAuthenticationCubit({required super.authenticationRepository});
+
+  @override
+  FutureOrResult<int?> onReauthenticate(Result<Account, AppException> result) async {
+    // TODO
+  }
+
+  @override
+  FutureOrResult<int?> onRefresh(Result<Account, AppException> result) {
+    // TODO
+  }
+
+  @override
+  FutureOrResult<int?> onSignInFromCache(SessionWrapper<int> wrapper) {
+    // TODO
+  }
+
+  @override
+  FutureOrResult<void> onSignOut() {
+    // TODO
+  }
+
+  @override
+  FutureOrResult<void> onDelete() {
+    // TODO
+  }
+}
+
+

Sign Up

+
class ExampleSignUpCubit extends SignUpCubit<int> {
+  ExampleSignUpCubit({
+    required super.authenticationRepository,
+  });
+
+  @override
+  FutureOrResult<int?> onSignUpWithEmailAndPassword(Result<Account, AppException> result, WyattForm form) async {
+    // TODO
+  }
+}
+
+
+

Sign In

+
class ExampleSignInCubit extends SignInCubit<int> {
+  ExampleSignInCubit({
+    required super.authenticationRepository,
+  });
+
+  @override
+  FutureOrResult<int?> onSignInWithEmailAndPassword(Result<Account, AppException> result, WyattForm form) {
+    // TODO
+  }
+
+  @override
+  FutureOrResult<int?> onSignInAnonymously(Result<Account, AppException> result, WyattForm form) {
+    // TODO
+  }
+
+  @override
+  FutureOrResult<int?> onSignInWithGoogle(Result<Account, AppException> result, WyattForm form) {
+    // TODO
+  }
+}
+
+

After setting up all these cubits you can provide them in the application. And that's it!

+
BlocProvider<SignUpCubit<int>>(
+    create: (_) => ExampleSignUpCubit(
+        authenticationRepository: authenticationRepository,
+    ),
+),
+BlocProvider<SignInCubit<int>>(
+    create: (_) => ExampleSignInCubit(
+        authenticationRepository: authenticationRepository,
+    ),
+),
+
+

Widgets

+

Widgets are provided to make your life easier. Starting with the AuthenticationBuilder which allows you to build according to the authentication state.

+
AuthenticationBuilder<int>(
+    authenticated: (context, sessionWrapper) => Text(
+        'Logged as ${sessionWrapper.session?.account.email} | GeneratedId is ${sessionWrapper.session?.data}'),
+    unauthenticated: (context) =>
+        const Text('Not logged (unauthenticated)'),
+    unknown: (context) => const Text('Not logged (unknown)'),
+),
+
+

A BuildContext extension is also available to access certain attributes more quickly.

+
Text('Home | ${context.account<AuthenticationCubit<int>, int>()?.email}'),
+
+

Listeners are used to listen to the status of the sign in and sign up forms.

+
return SignInListener<int>(
+    onError: (context, status, errorMessage) => ScaffoldMessenger.of(context)
+    ..hideCurrentSnackBar()
+    ..showSnackBar(
+        SnackBar(content: Text(errorMessage ?? 'Sign In Failure')),
+    ),
+    child: ...
+);
+
+ + +## Libraries + +##### [wyatt_authentication_bloc](wyatt_authentication_bloc/wyatt_authentication_bloc-library.md) +An authentication library for BLoC. + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/search.md b/packages/wyatt_authentication_bloc/doc/api/search.md new file mode 100644 index 00000000..0fedbdcf --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/search.md @@ -0,0 +1,6 @@ +# 404 + +Oops, something's gone wrong :-( + +You've tried to visit a page that doesn't exist. Luckily this site has other +[pages](index.md). diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account-class.md new file mode 100644 index 00000000..f52d7482 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account-class.md @@ -0,0 +1,237 @@ + + + +# Account class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Represents a user Account in the +various identity provisioning systems.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [Equatable](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable-class.html) +- Account + + + +**Implementers** + +- [AccountModel](../wyatt_authentication_bloc/AccountModel-class.md) + + + + + +## Constructors + +[Account](../wyatt_authentication_bloc/Account/Account.md) ({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) id, required [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) isAnonymous, required [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) emailVerified, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) providerId, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? email, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? phoneNumber, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? photoURL, [DateTime](https://api.flutter.dev/flutter/dart-core/DateTime-class.html)? creationTime, [DateTime](https://api.flutter.dev/flutter/dart-core/DateTime-class.html)? lastSignInTime, [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)? isNewUser, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? accessToken, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? refreshToken}) + + _const_ + + +## Properties + +##### [accessToken](../wyatt_authentication_bloc/Account/accessToken.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? + + + +The user access token +_final_ + + + +##### [creationTime](../wyatt_authentication_bloc/Account/creationTime.md) → [DateTime](https://api.flutter.dev/flutter/dart-core/DateTime-class.html)? + + + +Returns the users account creation time. +_final_ + + + +##### [email](../wyatt_authentication_bloc/Account/email.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? + + + +The users email address. +_final_ + + + +##### [emailVerified](../wyatt_authentication_bloc/Account/emailVerified.md) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +Returns whether the users email address has been verified. +_final_ + + + +##### [hashCode](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [id](../wyatt_authentication_bloc/Account/id.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +The user's unique ID. +_final_ + + + +##### [isAnonymous](../wyatt_authentication_bloc/Account/isAnonymous.md) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +Returns whether the user is a anonymous. +_final_ + + + +##### [isNewUser](../wyatt_authentication_bloc/Account/isNewUser.md) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)? + + + +Whether the user account has been recently created. +_final_ + + + +##### [lastSignInTime](../wyatt_authentication_bloc/Account/lastSignInTime.md) → [DateTime](https://api.flutter.dev/flutter/dart-core/DateTime-class.html)? + + + +When the user last signed in as dictated by the server clock. +_final_ + + + +##### [phoneNumber](../wyatt_authentication_bloc/Account/phoneNumber.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? + + + +Returns the users phone number. +_final_ + + + +##### [photoURL](../wyatt_authentication_bloc/Account/photoURL.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? + + + +Returns a photo URL for the user. +_final_ + + + +##### [props](../wyatt_authentication_bloc/Account/props.md) → [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> + + + +The list of properties that will be used to determine whether +two instances are equal. +_read-onlyoverride_ + + + +##### [providerId](../wyatt_authentication_bloc/Account/providerId.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +The provider ID for the user. +_final_ + + + +##### [refreshToken](../wyatt_authentication_bloc/Account/refreshToken.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? + + + +The user refresh token +_final_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + +##### [stringify](../wyatt_authentication_bloc/Account/stringify.md) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +If set to true, the toString method will be overridden to output +this instance's props. +_read-onlyoverride_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/Account.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/Account.md new file mode 100644 index 00000000..22006c3c --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/Account.md @@ -0,0 +1,43 @@ + + + +# Account constructor + + + + + *[](https://dart.dev/null-safety)* + + +const +Account({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) id, required [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) isAnonymous, required [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) emailVerified, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) providerId, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? email, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? phoneNumber, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? photoURL, [DateTime](https://api.flutter.dev/flutter/dart-core/DateTime-class.html)? creationTime, [DateTime](https://api.flutter.dev/flutter/dart-core/DateTime-class.html)? lastSignInTime, [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)? isNewUser, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? accessToken, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? refreshToken}) + + + + + +## Implementation + +```dart +const Account({ + required this.id, + required this.isAnonymous, + required this.emailVerified, + required this.providerId, + this.email, + this.phoneNumber, + this.photoURL, + this.creationTime, + this.lastSignInTime, + this.isNewUser, + this.accessToken, + this.refreshToken, +}); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/accessToken.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/accessToken.md new file mode 100644 index 00000000..0ceb6c2e --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/accessToken.md @@ -0,0 +1,34 @@ + + + +# accessToken property + + + + + *[](https://dart.dev/null-safety)* + + + +[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? accessToken + +_final_ + + + +

The user access token

+ + + +## Implementation + +```dart +final String? accessToken; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/creationTime.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/creationTime.md new file mode 100644 index 00000000..cf5dfe5c --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/creationTime.md @@ -0,0 +1,35 @@ + + + +# creationTime property + + + + + *[](https://dart.dev/null-safety)* + + + +[DateTime](https://api.flutter.dev/flutter/dart-core/DateTime-class.html)? creationTime + +_final_ + + + +

Returns the users account creation time.

+

When this account was created as dictated by the server clock.

+ + + +## Implementation + +```dart +final DateTime? creationTime; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/email.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/email.md new file mode 100644 index 00000000..2d007ce3 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/email.md @@ -0,0 +1,35 @@ + + + +# email property + + + + + *[](https://dart.dev/null-safety)* + + + +[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? email + +_final_ + + + +

The users email address.

+

Will be null if signing in anonymously.

+ + + +## Implementation + +```dart +final String? email; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/emailVerified.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/emailVerified.md new file mode 100644 index 00000000..e4e36b29 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/emailVerified.md @@ -0,0 +1,35 @@ + + + +# emailVerified property + + + + + *[](https://dart.dev/null-safety)* + + + +[bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) emailVerified + +_final_ + + + +

Returns whether the users email address has been verified.

+

To send a verification email, see SendEmailVerification.

+ + + +## Implementation + +```dart +final bool emailVerified; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/id.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/id.md new file mode 100644 index 00000000..4796ed2f --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/id.md @@ -0,0 +1,34 @@ + + + +# id property + + + + + *[](https://dart.dev/null-safety)* + + + +[String](https://api.flutter.dev/flutter/dart-core/String-class.html) id + +_final_ + + + +

The user's unique ID.

+ + + +## Implementation + +```dart +final String id; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/isAnonymous.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/isAnonymous.md new file mode 100644 index 00000000..324b4fda --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/isAnonymous.md @@ -0,0 +1,34 @@ + + + +# isAnonymous property + + + + + *[](https://dart.dev/null-safety)* + + + +[bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) isAnonymous + +_final_ + + + +

Returns whether the user is a anonymous.

+ + + +## Implementation + +```dart +final bool isAnonymous; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/isNewUser.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/isNewUser.md new file mode 100644 index 00000000..f96ab918 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/isNewUser.md @@ -0,0 +1,34 @@ + + + +# isNewUser property + + + + + *[](https://dart.dev/null-safety)* + + + +[bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)? isNewUser + +_final_ + + + +

Whether the user account has been recently created.

+ + + +## Implementation + +```dart +final bool? isNewUser; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/lastSignInTime.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/lastSignInTime.md new file mode 100644 index 00000000..0f257f63 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/lastSignInTime.md @@ -0,0 +1,34 @@ + + + +# lastSignInTime property + + + + + *[](https://dart.dev/null-safety)* + + + +[DateTime](https://api.flutter.dev/flutter/dart-core/DateTime-class.html)? lastSignInTime + +_final_ + + + +

When the user last signed in as dictated by the server clock.

+ + + +## Implementation + +```dart +final DateTime? lastSignInTime; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/phoneNumber.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/phoneNumber.md new file mode 100644 index 00000000..7b33f623 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/phoneNumber.md @@ -0,0 +1,36 @@ + + + +# phoneNumber property + + + + + *[](https://dart.dev/null-safety)* + + + +[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? phoneNumber + +_final_ + + + +

Returns the users phone number.

+

This property will be null if the user has not signed in or been has +their phone number linked.

+ + + +## Implementation + +```dart +final String? phoneNumber; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/photoURL.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/photoURL.md new file mode 100644 index 00000000..c76a2896 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/photoURL.md @@ -0,0 +1,36 @@ + + + +# photoURL property + + + + + *[](https://dart.dev/null-safety)* + + + +[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? photoURL + +_final_ + + + +

Returns a photo URL for the user.

+

This property will be populated if the user has signed in or been linked +with a 3rd party OAuth provider (such as Google).

+ + + +## Implementation + +```dart +final String? photoURL; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/props.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/props.md new file mode 100644 index 00000000..619e2501 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/props.md @@ -0,0 +1,55 @@ + + + +# props property + + + + + *[](https://dart.dev/null-safety)* + + + + + +**Annotations** + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) +[List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> props + +_override_ + + + +

The list of properties that will be used to determine whether +two instances are equal.

+ + + +## Implementation + +```dart +@override +List get props => [ + id, + isAnonymous, + email, + emailVerified, + phoneNumber, + photoURL, + creationTime, + lastSignInTime, + providerId, + isNewUser, + accessToken, + refreshToken, + ]; +``` + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/providerId.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/providerId.md new file mode 100644 index 00000000..a539b552 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/providerId.md @@ -0,0 +1,34 @@ + + + +# providerId property + + + + + *[](https://dart.dev/null-safety)* + + + +[String](https://api.flutter.dev/flutter/dart-core/String-class.html) providerId + +_final_ + + + +

The provider ID for the user.

+ + + +## Implementation + +```dart +final String providerId; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/refreshToken.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/refreshToken.md new file mode 100644 index 00000000..781948d8 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/refreshToken.md @@ -0,0 +1,34 @@ + + + +# refreshToken property + + + + + *[](https://dart.dev/null-safety)* + + + +[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? refreshToken + +_final_ + + + +

The user refresh token

+ + + +## Implementation + +```dart +final String? refreshToken; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/stringify.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/stringify.md new file mode 100644 index 00000000..8df8a404 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/stringify.md @@ -0,0 +1,47 @@ + + + +# stringify property + + + + + *[](https://dart.dev/null-safety)* + + + + + +**Annotations** + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) +[bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) stringify + +_override_ + + + +

If set to true, the toString method will be overridden to output +this instance's props.

+

A global default value for stringify can be set using +EquatableConfig.stringify.

+

If this instance's stringify is set to null, the value of +EquatableConfig.stringify will be used instead. This defaults to +false.

+ + + +## Implementation + +```dart +@override +bool get stringify => true; +``` + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AccountModel-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AccountModel-class.md new file mode 100644 index 00000000..68088ea5 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AccountModel-class.md @@ -0,0 +1,247 @@ + + + +# AccountModel class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Account Model to parse Firebase User data

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [Equatable](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable-class.html) +- [Account](../wyatt_authentication_bloc/Account-class.md) +- AccountModel + + + + + + + + +## Constructors + +[AccountModel.fromFirebaseUser](../wyatt_authentication_bloc/AccountModel/AccountModel.fromFirebaseUser.md) ([User](https://pub.dev/documentation/firebase_auth/4.2.0/firebase_auth/User-class.html)? user, {[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? accessToken}) + + _factory_ + +[AccountModel.fromFirebaseUserCredential](../wyatt_authentication_bloc/AccountModel/AccountModel.fromFirebaseUserCredential.md) ([UserCredential](https://pub.dev/documentation/firebase_auth/4.2.0/firebase_auth/UserCredential-class.html)? userCredential) + + _factory_ + + +## Properties + +##### [accessToken](../wyatt_authentication_bloc/Account/accessToken.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? + + + +The user access token +_finalinherited_ + + + +##### [creationTime](../wyatt_authentication_bloc/Account/creationTime.md) → [DateTime](https://api.flutter.dev/flutter/dart-core/DateTime-class.html)? + + + +Returns the users account creation time. +_finalinherited_ + + + +##### [email](../wyatt_authentication_bloc/Account/email.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? + + + +The users email address. +_finalinherited_ + + + +##### [emailVerified](../wyatt_authentication_bloc/Account/emailVerified.md) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +Returns whether the users email address has been verified. +_finalinherited_ + + + +##### [hashCode](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [id](../wyatt_authentication_bloc/Account/id.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +The user's unique ID. +_finalinherited_ + + + +##### [isAnonymous](../wyatt_authentication_bloc/Account/isAnonymous.md) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +Returns whether the user is a anonymous. +_finalinherited_ + + + +##### [isNewUser](../wyatt_authentication_bloc/Account/isNewUser.md) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)? + + + +Whether the user account has been recently created. +_finalinherited_ + + + +##### [lastSignInTime](../wyatt_authentication_bloc/Account/lastSignInTime.md) → [DateTime](https://api.flutter.dev/flutter/dart-core/DateTime-class.html)? + + + +When the user last signed in as dictated by the server clock. +_finalinherited_ + + + +##### [phoneNumber](../wyatt_authentication_bloc/Account/phoneNumber.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? + + + +Returns the users phone number. +_finalinherited_ + + + +##### [photoURL](../wyatt_authentication_bloc/Account/photoURL.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? + + + +Returns a photo URL for the user. +_finalinherited_ + + + +##### [props](../wyatt_authentication_bloc/Account/props.md) → [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> + + + +The list of properties that will be used to determine whether +two instances are equal. +_read-onlyinherited_ + + + +##### [providerId](../wyatt_authentication_bloc/Account/providerId.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +The provider ID for the user. +_finalinherited_ + + + +##### [refreshToken](../wyatt_authentication_bloc/AccountModel/refreshToken.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? + + + +The user refresh token +_read-onlyoverride_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + +##### [stringify](../wyatt_authentication_bloc/Account/stringify.md) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +If set to true, the toString method will be overridden to output +this instance's props. +_read-onlyinherited_ + + + +##### [user](../wyatt_authentication_bloc/AccountModel/user.md) → [User](https://pub.dev/documentation/firebase_auth/4.2.0/firebase_auth/User-class.html)? + + + + +_final_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AccountModel/AccountModel.fromFirebaseUser.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AccountModel/AccountModel.fromFirebaseUser.md new file mode 100644 index 00000000..f040be39 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AccountModel/AccountModel.fromFirebaseUser.md @@ -0,0 +1,51 @@ + + + +# AccountModel.fromFirebaseUser constructor + + + + + *[](https://dart.dev/null-safety)* + + + +AccountModel.fromFirebaseUser([User](https://pub.dev/documentation/firebase_auth/4.2.0/firebase_auth/User-class.html)? user, {[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? accessToken}) + + + + + +## Implementation + +```dart +factory AccountModel.fromFirebaseUser(User? user, {String? accessToken}) { + if (user != null) { + final providerId = + (user.providerData.isEmpty) ? '' : user.providerData.first.providerId; + return AccountModel._( + user: user, + id: user.uid, + emailVerified: user.emailVerified, + isAnonymous: user.isAnonymous, + providerId: providerId, + creationTime: user.metadata.creationTime, + lastSignInTime: user.metadata.lastSignInTime, + isNewUser: false, + email: user.email, + phoneNumber: user.phoneNumber, + photoURL: user.photoURL, + accessToken: accessToken, + ); + } else { + throw ModelParsingFailureFirebase('null-user', 'User cannot be null'); + } +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AccountModel/AccountModel.fromFirebaseUserCredential.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AccountModel/AccountModel.fromFirebaseUserCredential.md new file mode 100644 index 00000000..ac8c078e --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AccountModel/AccountModel.fromFirebaseUserCredential.md @@ -0,0 +1,54 @@ + + + +# AccountModel.fromFirebaseUserCredential constructor + + + + + *[](https://dart.dev/null-safety)* + + + +AccountModel.fromFirebaseUserCredential([UserCredential](https://pub.dev/documentation/firebase_auth/4.2.0/firebase_auth/UserCredential-class.html)? userCredential) + + + + + +## Implementation + +```dart +factory AccountModel.fromFirebaseUserCredential( + UserCredential? userCredential, +) { + final user = userCredential?.user; + if (user != null) { + final providerId = + (user.providerData.isEmpty) ? '' : user.providerData.first.providerId; + return AccountModel._( + user: user, + id: user.uid, + emailVerified: user.emailVerified, + isAnonymous: user.isAnonymous, + providerId: providerId, + creationTime: user.metadata.creationTime, + lastSignInTime: user.metadata.lastSignInTime, + isNewUser: userCredential?.additionalUserInfo?.isNewUser, + email: user.email, + phoneNumber: user.phoneNumber, + photoURL: user.photoURL, + accessToken: userCredential?.credential?.accessToken, + ); + } else { + throw ModelParsingFailureFirebase('null-user', 'User cannot be null'); + } +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AccountModel/refreshToken.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AccountModel/refreshToken.md new file mode 100644 index 00000000..f8863731 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AccountModel/refreshToken.md @@ -0,0 +1,41 @@ + + + +# refreshToken property + + + + + *[](https://dart.dev/null-safety)* + + + + + +**Annotations** + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) +[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? refreshToken + +_override_ + + + +

The user refresh token

+ + + +## Implementation + +```dart +@override +String? get refreshToken => user?.refreshToken; +``` + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AccountModel/user.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AccountModel/user.md new file mode 100644 index 00000000..e0146cab --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AccountModel/user.md @@ -0,0 +1,33 @@ + + + +# user property + + + + + *[](https://dart.dev/null-safety)* + + + +[User](https://pub.dev/documentation/firebase_auth/4.2.0/firebase_auth/User-class.html)? user + +_final_ + + + + + + +## Implementation + +```dart +final User? user; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ApplyActionCodeFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ApplyActionCodeFailureFirebase-class.md new file mode 100644 index 00000000..451ed5dd --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ApplyActionCodeFailureFirebase-class.md @@ -0,0 +1,137 @@ + + + +# ApplyActionCodeFailureFirebase class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown if during the apply action code process if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- [ApplyActionCodeFailureInterface](../wyatt_authentication_bloc/ApplyActionCodeFailureInterface-class.md) +- ApplyActionCodeFailureFirebase + + + + + + + + +## Constructors + +[ApplyActionCodeFailureFirebase](../wyatt_authentication_bloc/ApplyActionCodeFailureFirebase/ApplyActionCodeFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + +[ApplyActionCodeFailureFirebase.fromCode](../wyatt_authentication_bloc/ApplyActionCodeFailureFirebase/ApplyActionCodeFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ApplyActionCodeFailureFirebase/ApplyActionCodeFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ApplyActionCodeFailureFirebase/ApplyActionCodeFailureFirebase.fromCode.md new file mode 100644 index 00000000..1c261bc6 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ApplyActionCodeFailureFirebase/ApplyActionCodeFailureFirebase.fromCode.md @@ -0,0 +1,49 @@ + + + +# ApplyActionCodeFailureFirebase.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +ApplyActionCodeFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + + +## Implementation + +```dart +ApplyActionCodeFailureFirebase.fromCode(String code) : super.fromCode(code) { + switch (code) { + case 'expired-action-code': + msg = 'Action code has expired.'; + break; + case 'invalid-action-code': + msg = 'Action code is invalid.'; + break; + case 'user-disabled': + msg = 'This user has been disabled. Please contact support for help.'; + break; + case 'user-not-found': + msg = 'Email is not found, please create an account.'; + break; + + default: + this.code = 'unknown'; + msg = 'An unknown error occurred.'; + } +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ApplyActionCodeFailureFirebase/ApplyActionCodeFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ApplyActionCodeFailureFirebase/ApplyActionCodeFailureFirebase.md new file mode 100644 index 00000000..2e03e5ae --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ApplyActionCodeFailureFirebase/ApplyActionCodeFailureFirebase.md @@ -0,0 +1,31 @@ + + + +# ApplyActionCodeFailureFirebase constructor + + + + + *[](https://dart.dev/null-safety)* + + + +ApplyActionCodeFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + + + +## Implementation + +```dart +ApplyActionCodeFailureFirebase([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ApplyActionCodeFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ApplyActionCodeFailureInterface-class.md new file mode 100644 index 00000000..487660fd --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ApplyActionCodeFailureInterface-class.md @@ -0,0 +1,139 @@ + + + +# ApplyActionCodeFailureInterface class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown if during the apply action code process if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- ApplyActionCodeFailureInterface + + + +**Implementers** + +- [ApplyActionCodeFailureFirebase](../wyatt_authentication_bloc/ApplyActionCodeFailureFirebase-class.md) + + + + + +## Constructors + +[ApplyActionCodeFailureInterface](../wyatt_authentication_bloc/ApplyActionCodeFailureInterface/ApplyActionCodeFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + +Thrown if during the apply action code process if a failure occurs. + +[ApplyActionCodeFailureInterface.fromCode](../wyatt_authentication_bloc/ApplyActionCodeFailureInterface/ApplyActionCodeFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + +Thrown if during the apply action code process if a failure occurs. + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ApplyActionCodeFailureInterface/ApplyActionCodeFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ApplyActionCodeFailureInterface/ApplyActionCodeFailureInterface.fromCode.md new file mode 100644 index 00000000..72b11f2d --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ApplyActionCodeFailureInterface/ApplyActionCodeFailureInterface.fromCode.md @@ -0,0 +1,31 @@ + + + +# ApplyActionCodeFailureInterface.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +ApplyActionCodeFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + +

Thrown if during the apply action code process if a failure occurs.

+ + + +## Implementation + +```dart +ApplyActionCodeFailureInterface.fromCode(super.code) : super.fromCode(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ApplyActionCodeFailureInterface/ApplyActionCodeFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ApplyActionCodeFailureInterface/ApplyActionCodeFailureInterface.md new file mode 100644 index 00000000..0fb17fe9 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ApplyActionCodeFailureInterface/ApplyActionCodeFailureInterface.md @@ -0,0 +1,31 @@ + + + +# ApplyActionCodeFailureInterface constructor + + + + + *[](https://dart.dev/null-safety)* + + + +ApplyActionCodeFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + + +

Thrown if during the apply action code process if a failure occurs.

+ + + +## Implementation + +```dart +ApplyActionCodeFailureInterface(super.code, super.msg); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormField-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormField-class.md new file mode 100644 index 00000000..9ccd48b3 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormField-class.md @@ -0,0 +1,122 @@ + + + +# AuthFormField class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Default authentication form fields name

+ + + + +## Constructors + +[AuthFormField](../wyatt_authentication_bloc/AuthFormField/AuthFormField.md) () + + + + +## Properties + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + +## Constants + +##### [confirmPassword](../wyatt_authentication_bloc/AuthFormField/confirmPassword-constant.md) const [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +Confirm Password field: wyattConfirmPasswordField + + + + +##### [email](../wyatt_authentication_bloc/AuthFormField/email-constant.md) const [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +Email field: wyattEmailField + + + + +##### [password](../wyatt_authentication_bloc/AuthFormField/password-constant.md) const [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +Password field: wyattPasswordField + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormField/AuthFormField.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormField/AuthFormField.md new file mode 100644 index 00000000..ab98b830 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormField/AuthFormField.md @@ -0,0 +1,25 @@ + + + +# AuthFormField constructor + + + + + *[](https://dart.dev/null-safety)* + + + +AuthFormField() + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormField/confirmPassword-constant.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormField/confirmPassword-constant.md new file mode 100644 index 00000000..7b7ac157 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormField/confirmPassword-constant.md @@ -0,0 +1,34 @@ + + + +# confirmPassword constant + + + + + *[](https://dart.dev/null-safety)* + + + +[String](https://api.flutter.dev/flutter/dart-core/String-class.html) const confirmPassword + + + + + +

Confirm Password field: wyattConfirmPasswordField

+ + + +## Implementation + +```dart +static const confirmPassword = 'wyattConfirmPasswordField'; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormField/email-constant.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormField/email-constant.md new file mode 100644 index 00000000..9d842070 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormField/email-constant.md @@ -0,0 +1,34 @@ + + + +# email constant + + + + + *[](https://dart.dev/null-safety)* + + + +[String](https://api.flutter.dev/flutter/dart-core/String-class.html) const email + + + + + +

Email field: wyattEmailField

+ + + +## Implementation + +```dart +static const email = 'wyattEmailField'; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormField/password-constant.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormField/password-constant.md new file mode 100644 index 00000000..00dbfc9d --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormField/password-constant.md @@ -0,0 +1,34 @@ + + + +# password constant + + + + + *[](https://dart.dev/null-safety)* + + + +[String](https://api.flutter.dev/flutter/dart-core/String-class.html) const password + + + + + +

Password field: wyattPasswordField

+ + + +## Implementation + +```dart +static const password = 'wyattPasswordField'; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormName-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormName-class.md new file mode 100644 index 00000000..f1c34250 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormName-class.md @@ -0,0 +1,131 @@ + + + +# AuthFormName class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Default authentication form name

+ + + + +## Constructors + +[AuthFormName](../wyatt_authentication_bloc/AuthFormName/AuthFormName.md) () + + + + +## Properties + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + +## Constants + +##### [editAccountForm](../wyatt_authentication_bloc/AuthFormName/editAccountForm-constant.md) const [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +Edit account form: wyattEditAccountForm + + + + +##### [passwordResetForm](../wyatt_authentication_bloc/AuthFormName/passwordResetForm-constant.md) const [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +Password reset form: wyattPasswordResetForm + + + + +##### [signInForm](../wyatt_authentication_bloc/AuthFormName/signInForm-constant.md) const [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +Sign In form: wyattSignInForm + + + + +##### [signUpForm](../wyatt_authentication_bloc/AuthFormName/signUpForm-constant.md) const [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +Sign Up form: wyattSignUpForm + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormName/AuthFormName.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormName/AuthFormName.md new file mode 100644 index 00000000..060a09c7 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormName/AuthFormName.md @@ -0,0 +1,25 @@ + + + +# AuthFormName constructor + + + + + *[](https://dart.dev/null-safety)* + + + +AuthFormName() + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormName/editAccountForm-constant.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormName/editAccountForm-constant.md new file mode 100644 index 00000000..87add4b3 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormName/editAccountForm-constant.md @@ -0,0 +1,34 @@ + + + +# editAccountForm constant + + + + + *[](https://dart.dev/null-safety)* + + + +[String](https://api.flutter.dev/flutter/dart-core/String-class.html) const editAccountForm + + + + + +

Edit account form: wyattEditAccountForm

+ + + +## Implementation + +```dart +static const String editAccountForm = 'wyattEditAccountForm'; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormName/passwordResetForm-constant.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormName/passwordResetForm-constant.md new file mode 100644 index 00000000..0732203c --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormName/passwordResetForm-constant.md @@ -0,0 +1,34 @@ + + + +# passwordResetForm constant + + + + + *[](https://dart.dev/null-safety)* + + + +[String](https://api.flutter.dev/flutter/dart-core/String-class.html) const passwordResetForm + + + + + +

Password reset form: wyattPasswordResetForm

+ + + +## Implementation + +```dart +static const String passwordResetForm = 'wyattPasswordResetForm'; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormName/signInForm-constant.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormName/signInForm-constant.md new file mode 100644 index 00000000..b5863475 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormName/signInForm-constant.md @@ -0,0 +1,34 @@ + + + +# signInForm constant + + + + + *[](https://dart.dev/null-safety)* + + + +[String](https://api.flutter.dev/flutter/dart-core/String-class.html) const signInForm + + + + + +

Sign In form: wyattSignInForm

+ + + +## Implementation + +```dart +static const String signInForm = 'wyattSignInForm'; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormName/signUpForm-constant.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormName/signUpForm-constant.md new file mode 100644 index 00000000..83820763 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormName/signUpForm-constant.md @@ -0,0 +1,34 @@ + + + +# signUpForm constant + + + + + *[](https://dart.dev/null-safety)* + + + +[String](https://api.flutter.dev/flutter/dart-core/String-class.html) const signUpForm + + + + + +

Sign Up form: wyattSignUpForm

+ + + +## Implementation + +```dart +static const String signUpForm = 'wyattSignUpForm'; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationBuilder-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationBuilder-class.md new file mode 100644 index 00000000..ba5fe7a2 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationBuilder-class.md @@ -0,0 +1,216 @@ + + + +# AuthenticationBuilder<Data> class + + + + + + + *[](https://dart.dev/null-safety)* + + + + + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [DiagnosticableTree](https://api.flutter.dev/flutter/foundation/DiagnosticableTree-class.html) +- [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) +- [StatelessWidget](https://api.flutter.dev/flutter/widgets/StatelessWidget-class.html) +- AuthenticationBuilder + + + + + + + + +## Constructors + +[AuthenticationBuilder](../wyatt_authentication_bloc/AuthenticationBuilder/AuthenticationBuilder.md) ({required [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) authenticated([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, [SessionWrapper](../wyatt_authentication_bloc/SessionWrapper-class.md)<Data> sessionWrapper), required [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) unauthenticated([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context), required [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) unknown([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context), [Key](https://api.flutter.dev/flutter/foundation/Key-class.html)? key}) + + _const_ + + +## Properties + +##### [authenticated](../wyatt_authentication_bloc/AuthenticationBuilder/authenticated.md) → [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, [SessionWrapper](../wyatt_authentication_bloc/SessionWrapper-class.md)<Data> sessionWrapper) + + + + +_final_ + + + +##### [hashCode](https://api.flutter.dev/flutter/widgets/Widget/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [key](https://api.flutter.dev/flutter/widgets/Widget/key.html) → [Key](https://api.flutter.dev/flutter/foundation/Key-class.html)? + + + +Controls how one widget replaces another widget in the tree. +_finalinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + +##### [unauthenticated](../wyatt_authentication_bloc/AuthenticationBuilder/unauthenticated.md) → [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context) + + + + +_final_ + + + +##### [unknown](../wyatt_authentication_bloc/AuthenticationBuilder/unknown.md) → [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context) + + + + +_final_ + + + + + +## Methods + +##### [build](../wyatt_authentication_bloc/AuthenticationBuilder/build.md)([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context) [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) + + + +Describes the part of the user interface represented by this widget. +_override_ + + + +##### [createElement](https://api.flutter.dev/flutter/widgets/StatelessWidget/createElement.html)() [StatelessElement](https://api.flutter.dev/flutter/widgets/StatelessElement-class.html) + + + +Creates a StatelessElement to manage this widget's location in the tree. +_inherited_ + + + +##### [debugDescribeChildren](https://api.flutter.dev/flutter/foundation/DiagnosticableTree/debugDescribeChildren.html)() [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[DiagnosticsNode](https://api.flutter.dev/flutter/foundation/DiagnosticsNode-class.html)> + + + +Returns a list of DiagnosticsNode objects describing this node's +children. +_inherited_ + + + +##### [debugFillProperties](https://api.flutter.dev/flutter/widgets/Widget/debugFillProperties.html)([DiagnosticPropertiesBuilder](https://api.flutter.dev/flutter/foundation/DiagnosticPropertiesBuilder-class.html) properties) void + + + +Add additional properties associated with the node. +_inherited_ + + + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toDiagnosticsNode](https://api.flutter.dev/flutter/foundation/DiagnosticableTree/toDiagnosticsNode.html)({[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? name, [DiagnosticsTreeStyle](https://api.flutter.dev/flutter/foundation/DiagnosticsTreeStyle.html)? style}) [DiagnosticsNode](https://api.flutter.dev/flutter/foundation/DiagnosticsNode-class.html) + + + +Returns a debug representation of the object that is used by debugging +tools and by DiagnosticsNode.toStringDeep. +_inherited_ + + + +##### [toString](https://api.flutter.dev/flutter/foundation/Diagnosticable/toString.html)({[DiagnosticLevel](https://api.flutter.dev/flutter/foundation/DiagnosticLevel.html) minLevel = DiagnosticLevel.info}) [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + +##### [toStringDeep](https://api.flutter.dev/flutter/foundation/DiagnosticableTree/toStringDeep.html)({[String](https://api.flutter.dev/flutter/dart-core/String-class.html) prefixLineOne = '', [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? prefixOtherLines, [DiagnosticLevel](https://api.flutter.dev/flutter/foundation/DiagnosticLevel.html) minLevel = DiagnosticLevel.debug}) [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +Returns a string representation of this node and its descendants. +_inherited_ + + + +##### [toStringShallow](https://api.flutter.dev/flutter/foundation/DiagnosticableTree/toStringShallow.html)({[String](https://api.flutter.dev/flutter/dart-core/String-class.html) joiner = ', ', [DiagnosticLevel](https://api.flutter.dev/flutter/foundation/DiagnosticLevel.html) minLevel = DiagnosticLevel.debug}) [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +Returns a one-line detailed description of the object. +_inherited_ + + + +##### [toStringShort](https://api.flutter.dev/flutter/widgets/Widget/toStringShort.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A short, textual description of this widget. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/widgets/Widget/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationBuilder/AuthenticationBuilder.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationBuilder/AuthenticationBuilder.md new file mode 100644 index 00000000..6fa6aa7d --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationBuilder/AuthenticationBuilder.md @@ -0,0 +1,35 @@ + + + +# AuthenticationBuilder<Data> constructor + + + + + *[](https://dart.dev/null-safety)* + + +const +AuthenticationBuilder<Data>({required [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) authenticated([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, [SessionWrapper](../../wyatt_authentication_bloc/SessionWrapper-class.md)<Data> sessionWrapper), required [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) unauthenticated([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context), required [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) unknown([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context), [Key](https://api.flutter.dev/flutter/foundation/Key-class.html)? key}) + + + + + +## Implementation + +```dart +const AuthenticationBuilder({ + required this.authenticated, + required this.unauthenticated, + required this.unknown, + super.key, +}); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationBuilder/authenticated.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationBuilder/authenticated.md new file mode 100644 index 00000000..421ea1b9 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationBuilder/authenticated.md @@ -0,0 +1,36 @@ + + + +# authenticated property + + + + + *[](https://dart.dev/null-safety)* + + + +[Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, [SessionWrapper](../../wyatt_authentication_bloc/SessionWrapper-class.md)<Data> sessionWrapper) authenticated + +_final_ + + + + + + +## Implementation + +```dart +final Widget Function( + BuildContext context, + SessionWrapper sessionWrapper, +) authenticated; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationBuilder/build.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationBuilder/build.md new file mode 100644 index 00000000..5b5680da --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationBuilder/build.md @@ -0,0 +1,85 @@ + + + +# build method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) build +([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context) + +_override_ + + + +

Describes the part of the user interface represented by this widget.

+

The framework calls this method when this widget is inserted into the tree +in a given BuildContext and when the dependencies of this widget change +(e.g., an InheritedWidget referenced by this widget changes). This +method can potentially be called in every frame and should not have any side +effects beyond building a widget.

+

The framework replaces the subtree below this widget with the widget +returned by this method, either by updating the existing subtree or by +removing the subtree and inflating a new subtree, depending on whether the +widget returned by this method can update the root of the existing +subtree, as determined by calling Widget.canUpdate.

+

Typically implementations return a newly created constellation of widgets +that are configured with information from this widget's constructor and +from the given BuildContext.

+

The given BuildContext contains information about the location in the +tree at which this widget is being built. For example, the context +provides the set of inherited widgets for this location in the tree. A +given widget might be built with multiple different BuildContext +arguments over time if the widget is moved around the tree or if the +widget is inserted into the tree in multiple places at once.

+

The implementation of this method must only depend on:

+ +

If a widget's build method is to depend on anything else, use a +StatefulWidget instead.

+

See also:

+
    +
  • StatelessWidget, which contains the discussion on performance considerations.
  • +
+ + + +## Implementation + +```dart +@override +Widget build(BuildContext context) => + BlocBuilder, AuthenticationState>( + builder: (context, state) { + if (state.status == AuthenticationStatus.authenticated) { + if (state.wrapper != null) { + return authenticated(context, state.wrapper!); + } else { + return unauthenticated(context); + } + } else if (state.status == AuthenticationStatus.unauthenticated) { + return unauthenticated(context); + } else { + return unknown(context); + } + }, + ); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationBuilder/unauthenticated.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationBuilder/unauthenticated.md new file mode 100644 index 00000000..09ac9fe3 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationBuilder/unauthenticated.md @@ -0,0 +1,33 @@ + + + +# unauthenticated property + + + + + *[](https://dart.dev/null-safety)* + + + +[Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context) unauthenticated + +_final_ + + + + + + +## Implementation + +```dart +final Widget Function(BuildContext context) unauthenticated; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationBuilder/unknown.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationBuilder/unknown.md new file mode 100644 index 00000000..4573308e --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationBuilder/unknown.md @@ -0,0 +1,33 @@ + + + +# unknown property + + + + + *[](https://dart.dev/null-safety)* + + + +[Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context) unknown + +_final_ + + + + + + +## Implementation + +```dart +final Widget Function(BuildContext context) unknown; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationChangeEvent-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationChangeEvent-class.md new file mode 100644 index 00000000..4cb045d8 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationChangeEvent-class.md @@ -0,0 +1,137 @@ + + + +# AuthenticationChangeEvent class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Represents an event initiated by a change in +the user's authentication status.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [Equatable](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable-class.html) +- AuthenticationChangeEvent + + + +**Implementers** + +- [DeletedEvent](../wyatt_authentication_bloc/DeletedEvent-class.md) +- [ReauthenticatedEvent](../wyatt_authentication_bloc/ReauthenticatedEvent-class.md) +- [RefreshedEvent](../wyatt_authentication_bloc/RefreshedEvent-class.md) +- [SignedInEvent](../wyatt_authentication_bloc/SignedInEvent-class.md) +- [SignedInFromCacheEvent](../wyatt_authentication_bloc/SignedInFromCacheEvent-class.md) +- [SignedOutEvent](../wyatt_authentication_bloc/SignedOutEvent-class.md) +- [SignedUpEvent](../wyatt_authentication_bloc/SignedUpEvent-class.md) +- [UnknownAuthenticationEvent](../wyatt_authentication_bloc/UnknownAuthenticationEvent-class.md) +- [UpdatedEvent](../wyatt_authentication_bloc/UpdatedEvent-class.md) + + + + + +## Constructors + +[AuthenticationChangeEvent](../wyatt_authentication_bloc/AuthenticationChangeEvent/AuthenticationChangeEvent.md) () + + _const_ + + +## Properties + +##### [hashCode](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [props](../wyatt_authentication_bloc/AuthenticationChangeEvent/props.md) → [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> + + + +The list of properties that will be used to determine whether +two instances are equal. +_read-onlyoverride_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + +##### [stringify](../wyatt_authentication_bloc/AuthenticationChangeEvent/stringify.md) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +If set to true, the toString method will be overridden to output +this instance's props. +_read-onlyoverride_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationChangeEvent/AuthenticationChangeEvent.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationChangeEvent/AuthenticationChangeEvent.md new file mode 100644 index 00000000..82567010 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationChangeEvent/AuthenticationChangeEvent.md @@ -0,0 +1,30 @@ + + + +# AuthenticationChangeEvent constructor + + + + + *[](https://dart.dev/null-safety)* + + +const +AuthenticationChangeEvent() + + + + + +## Implementation + +```dart +const AuthenticationChangeEvent(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationChangeEvent/props.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationChangeEvent/props.md new file mode 100644 index 00000000..35d92209 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationChangeEvent/props.md @@ -0,0 +1,42 @@ + + + +# props property + + + + + *[](https://dart.dev/null-safety)* + + + + + +**Annotations** + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) +[List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> props + +_override_ + + + +

The list of properties that will be used to determine whether +two instances are equal.

+ + + +## Implementation + +```dart +@override +List get props => []; +``` + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationChangeEvent/stringify.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationChangeEvent/stringify.md new file mode 100644 index 00000000..a2e1620f --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationChangeEvent/stringify.md @@ -0,0 +1,47 @@ + + + +# stringify property + + + + + *[](https://dart.dev/null-safety)* + + + + + +**Annotations** + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) +[bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) stringify + +_override_ + + + +

If set to true, the toString method will be overridden to output +this instance's props.

+

A global default value for stringify can be set using +EquatableConfig.stringify.

+

If this instance's stringify is set to null, the value of +EquatableConfig.stringify will be used instead. This defaults to +false.

+ + + +## Implementation + +```dart +@override +bool get stringify => true; +``` + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit-class.md new file mode 100644 index 00000000..3758c56f --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit-class.md @@ -0,0 +1,292 @@ + + + +# AuthenticationCubit<Data> class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Abstract authentication cubit class needs to be implemented in application.

+

This cubit is in charge of managing the global authentication state of +the application.

+

Its here you can override every callbacks and add your custom logic.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [BlocBase](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase-class.html)<[AuthenticationState](../wyatt_authentication_bloc/AuthenticationState-class.md)<Data>> +- [Cubit](https://pub.dev/documentation/bloc/8.1.0/bloc/Cubit-class.html)<[AuthenticationState](../wyatt_authentication_bloc/AuthenticationState-class.md)<Data>> +- AuthenticationCubit + + + + + + + + +## Constructors + +[AuthenticationCubit](../wyatt_authentication_bloc/AuthenticationCubit/AuthenticationCubit.md) ({required [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> authenticationRepository}) + + + + +## Properties + +##### [authenticationRepository](../wyatt_authentication_bloc/AuthenticationCubit/authenticationRepository.md) → [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> + + + + +_final_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [isClosed](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/isClosed.html) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +Whether the bloc is closed. +_read-onlyinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + +##### [state](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/state.html) → [AuthenticationState](../wyatt_authentication_bloc/AuthenticationState-class.md)<Data> + + + +The current state. +_read-onlyinherited_ + + + +##### [stream](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/stream.html) → [Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[AuthenticationState](../wyatt_authentication_bloc/AuthenticationState-class.md)<Data>> + + + +The current stream of states. +_read-onlyinherited_ + + + + + +## Methods + +##### [addError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/addError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [[StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html)? stackTrace]) void + + + +Reports an error which triggers onError with an optional StackTrace. +_inherited_ + + + +##### [close](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/close.html)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> + + + +Closes the instance. +This method should be called when the instance is no longer needed. +Once close is called, the instance can no longer be used. +_inherited_ + + + +##### [currentSession](../wyatt_authentication_bloc/AuthenticationCubit/currentSession.md)() [SessionWrapper](../wyatt_authentication_bloc/SessionWrapper-class.md)<Data>? + + + +Returns latest session wrapper. + + + + +##### [delete](../wyatt_authentication_bloc/AuthenticationCubit/delete.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + +Delete account. + + + + +##### [emit](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/emit.html)([AuthenticationState](../wyatt_authentication_bloc/AuthenticationState-class.md)<Data> state) void + + + +Updates the state to the provided state. +emit does nothing if the state being emitted +is equal to the current state. +_inherited_ + + + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [onChange](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onChange.html)([Change](https://pub.dev/documentation/bloc/8.1.0/bloc/Change-class.html)<[AuthenticationState](../wyatt_authentication_bloc/AuthenticationState-class.md)<Data>> change) void + + + +Called whenever a change occurs with the given change. +A change occurs when a new state is emitted. +onChange is called before the state of the cubit is updated. +onChange is a great spot to add logging/analytics for a specific cubit. +_inherited_ + + + +##### [onDelete](../wyatt_authentication_bloc/AuthenticationCubit/onDelete.md)() FutureOrResult<void> + + + +This callback is triggered when the current account is deleted from +the remote. + + + + +##### [onError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html) stackTrace) void + + + +Called whenever an error occurs and notifies BlocObserver.onError. +_inherited_ + + + +##### [onReauthenticate](../wyatt_authentication_bloc/AuthenticationCubit/onReauthenticate.md)(Result<[Account](../wyatt_authentication_bloc/Account-class.md), AppException> result) FutureOrResult<Data?> + + + +This callback is triggered when the account is re-authenticated + + + + +##### [onRefresh](../wyatt_authentication_bloc/AuthenticationCubit/onRefresh.md)(Result<[Account](../wyatt_authentication_bloc/Account-class.md), AppException> result) FutureOrResult<Data?> + + + +This callback is triggered when the account is refreshed. + + + + +##### [onSignInFromCache](../wyatt_authentication_bloc/AuthenticationCubit/onSignInFromCache.md)([SessionWrapper](../wyatt_authentication_bloc/SessionWrapper-class.md)<Data> wrapper) FutureOrResult<Data?> + + + +This callback is triggered when the user is automaticcaly logged in from +the cache. + + + + +##### [onSignOut](../wyatt_authentication_bloc/AuthenticationCubit/onSignOut.md)() FutureOrResult<void> + + + +This callback is triggered when the user is logged out. + + + + +##### [reauthenticate](../wyatt_authentication_bloc/AuthenticationCubit/reauthenticate.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + +Some security-sensitive actions—such as deleting an account, +setting a primary email address, and changing a password—require that +the user has recently signed in. + + + + +##### [refresh](../wyatt_authentication_bloc/AuthenticationCubit/refresh.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + +Refreshes the current user, if signed in. + + + + +##### [signOut](../wyatt_authentication_bloc/AuthenticationCubit/signOut.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + +Signs out the current user. +It also clears the cache and the associated data. + + + + +##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/AuthenticationCubit.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/AuthenticationCubit.md new file mode 100644 index 00000000..8a689e53 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/AuthenticationCubit.md @@ -0,0 +1,34 @@ + + + +# AuthenticationCubit<Data> constructor + + + + + *[](https://dart.dev/null-safety)* + + + +AuthenticationCubit<Data>({required [AuthenticationRepository](../../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> authenticationRepository}) + + + + + +## Implementation + +```dart +AuthenticationCubit({ + required this.authenticationRepository, +}) : super(const AuthenticationState.unknown()) { + _listenForAuthenticationChanges(); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/authenticationRepository.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/authenticationRepository.md new file mode 100644 index 00000000..32cdfa2a --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/authenticationRepository.md @@ -0,0 +1,33 @@ + + + +# authenticationRepository property + + + + + *[](https://dart.dev/null-safety)* + + + +[AuthenticationRepository](../../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> authenticationRepository + +_final_ + + + + + + +## Implementation + +```dart +final AuthenticationRepository authenticationRepository; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/currentSession.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/currentSession.md new file mode 100644 index 00000000..855d8d0e --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/currentSession.md @@ -0,0 +1,37 @@ + + + +# currentSession method + + + + + *[](https://dart.dev/null-safety)* + + + + +[SessionWrapper](../../wyatt_authentication_bloc/SessionWrapper-class.md)<Data>? currentSession +() + + + + + +

Returns latest session wrapper.

+

Contains latest event and latest session data (account + extra data)

+ + + +## Implementation + +```dart +SessionWrapper? currentSession() => _latestSession; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/delete.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/delete.md new file mode 100644 index 00000000..849e1aca --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/delete.md @@ -0,0 +1,44 @@ + + + +# delete method + + + + + *[](https://dart.dev/null-safety)* + + + + +[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> delete +() + + + + + +

Delete account.

+

Throws a DeleteAccountFailureInterface if +an exception occurs.

+ + + +## Implementation + +```dart +FutureOr delete() async => CustomRoutine( + routine: authenticationRepository.delete, + attachedLogic: (routineResult) => onDelete(), + onError: addError, + onSuccess: (result, data) => authenticationRepository + .addSession(SessionWrapper(event: const DeletedEvent())), + ).call(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/onDelete.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/onDelete.md new file mode 100644 index 00000000..b5fd50a4 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/onDelete.md @@ -0,0 +1,38 @@ + + + +# onDelete method + + + + + *[](https://dart.dev/null-safety)* + + + + +FutureOrResult<void> onDelete +() + + + + + +

This callback is triggered when the current account is deleted from +the remote.

+

For example: when the user wants to delete his account from Firebase

+ + + +## Implementation + +```dart +FutureOrResult onDelete(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/onReauthenticate.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/onReauthenticate.md new file mode 100644 index 00000000..434c5de1 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/onReauthenticate.md @@ -0,0 +1,38 @@ + + + +# onReauthenticate method + + + + + *[](https://dart.dev/null-safety)* + + + + +FutureOrResult<Data?> onReauthenticate +(Result<[Account](../../wyatt_authentication_bloc/Account-class.md), AppException> result) + + + + + +

This callback is triggered when the account is re-authenticated

+

For example: when the user is logged in and sign in +from an another provider

+ + + +## Implementation + +```dart +FutureOrResult onReauthenticate(Result result); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/onRefresh.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/onRefresh.md new file mode 100644 index 00000000..b3812fa8 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/onRefresh.md @@ -0,0 +1,37 @@ + + + +# onRefresh method + + + + + *[](https://dart.dev/null-safety)* + + + + +FutureOrResult<Data?> onRefresh +(Result<[Account](../../wyatt_authentication_bloc/Account-class.md), AppException> result) + + + + + +

This callback is triggered when the account is refreshed.

+

For example: when the access token is refreshed.

+ + + +## Implementation + +```dart +FutureOrResult onRefresh(Result result); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/onSignInFromCache.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/onSignInFromCache.md new file mode 100644 index 00000000..3f0ccf94 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/onSignInFromCache.md @@ -0,0 +1,38 @@ + + + +# onSignInFromCache method + + + + + *[](https://dart.dev/null-safety)* + + + + +FutureOrResult<Data?> onSignInFromCache +([SessionWrapper](../../wyatt_authentication_bloc/SessionWrapper-class.md)<Data> wrapper) + + + + + +

This callback is triggered when the user is automaticcaly logged in from +the cache.

+

For example: when the user is sign in from the Firebase cache.

+ + + +## Implementation + +```dart +FutureOrResult onSignInFromCache(SessionWrapper wrapper); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/onSignOut.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/onSignOut.md new file mode 100644 index 00000000..930d66b7 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/onSignOut.md @@ -0,0 +1,37 @@ + + + +# onSignOut method + + + + + *[](https://dart.dev/null-safety)* + + + + +FutureOrResult<void> onSignOut +() + + + + + +

This callback is triggered when the user is logged out.

+

For example: when the user clicks on the logout button.

+ + + +## Implementation + +```dart +FutureOrResult onSignOut(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/reauthenticate.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/reauthenticate.md new file mode 100644 index 00000000..b2eeb9c5 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/reauthenticate.md @@ -0,0 +1,53 @@ + + + +# reauthenticate method + + + + + *[](https://dart.dev/null-safety)* + + + + +[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> reauthenticate +() + + + + + +

Some security-sensitive actions—such as deleting an account, +setting a primary email address, and changing a password—require that +the user has recently signed in.

+

Throws a ReauthenticateFailureInterface if +an exception occurs.

+ + + +## Implementation + +```dart +FutureOr reauthenticate() async => CustomRoutine( + routine: authenticationRepository.reauthenticate, + attachedLogic: onReauthenticate, + onError: addError, + onSuccess: (result, data) => authenticationRepository.addSession( + SessionWrapper( + event: ReauthenticatedEvent(account: result), + session: Session( + account: result, + data: data, + ), + ), + ), + ).call(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/refresh.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/refresh.md new file mode 100644 index 00000000..be643224 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/refresh.md @@ -0,0 +1,49 @@ + + + +# refresh method + + + + + *[](https://dart.dev/null-safety)* + + + + +[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> refresh +() + + + + + +

Refreshes the current user, if signed in.

+ + + +## Implementation + +```dart +FutureOr refresh() async => CustomRoutine( + routine: authenticationRepository.refresh, + attachedLogic: onRefresh, + onError: addError, + onSuccess: (result, data) => authenticationRepository.addSession( + SessionWrapper( + event: RefreshedEvent(account: result), + session: Session( + account: result, + data: data, + ), + ), + ), + ).call(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/signOut.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/signOut.md new file mode 100644 index 00000000..f2634117 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/signOut.md @@ -0,0 +1,43 @@ + + + +# signOut method + + + + + *[](https://dart.dev/null-safety)* + + + + +[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> signOut +() + + + + + +

Signs out the current user. +It also clears the cache and the associated data.

+ + + +## Implementation + +```dart +FutureOr signOut() async => CustomRoutine( + routine: authenticationRepository.signOut, + attachedLogic: (routineResult) => onSignOut(), + onError: addError, + onSuccess: (result, data) => authenticationRepository + .addSession(SessionWrapper(event: const SignedOutEvent())), + ).call(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface-class.md new file mode 100644 index 00000000..36c265c0 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface-class.md @@ -0,0 +1,159 @@ + + + +# AuthenticationFailureInterface class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Base exception used in Wyatt Authentication

+ + + + +**Implemented types** + +- [Exception](https://api.flutter.dev/flutter/dart-core/Exception-class.html) + + +**Implementers** + +- [ApplyActionCodeFailureInterface](../wyatt_authentication_bloc/ApplyActionCodeFailureInterface-class.md) +- [ConfirmPasswordResetFailureInterface](../wyatt_authentication_bloc/ConfirmPasswordResetFailureInterface-class.md) +- [DeleteAccountFailureInterface](../wyatt_authentication_bloc/DeleteAccountFailureInterface-class.md) +- [FetchSignInMethodsForEmailFailureInterface](../wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureInterface-class.md) +- [ModelParsingFailureInterface](../wyatt_authentication_bloc/ModelParsingFailureInterface-class.md) +- [ReauthenticateFailureInterface](../wyatt_authentication_bloc/ReauthenticateFailureInterface-class.md) +- [RefreshFailureInterface](../wyatt_authentication_bloc/RefreshFailureInterface-class.md) +- [SendEmailVerificationFailureInterface](../wyatt_authentication_bloc/SendEmailVerificationFailureInterface-class.md) +- [SendPasswordResetEmailFailureInterface](../wyatt_authentication_bloc/SendPasswordResetEmailFailureInterface-class.md) +- [SendSignInLinkEmailFailureInterface](../wyatt_authentication_bloc/SendSignInLinkEmailFailureInterface-class.md) +- [SignInAnonymouslyFailureInterface](../wyatt_authentication_bloc/SignInAnonymouslyFailureInterface-class.md) +- [SignInWithAppleFailureInterface](../wyatt_authentication_bloc/SignInWithAppleFailureInterface-class.md) +- [SignInWithCredentialFailureInterface](../wyatt_authentication_bloc/SignInWithCredentialFailureInterface-class.md) +- [SignInWithEmailAndPasswordFailureInterface](../wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureInterface-class.md) +- [SignInWithEmailLinkFailureInterface](../wyatt_authentication_bloc/SignInWithEmailLinkFailureInterface-class.md) +- [SignInWithFacebookFailureInterface](../wyatt_authentication_bloc/SignInWithFacebookFailureInterface-class.md) +- [SignInWithGoogleFailureInterface](../wyatt_authentication_bloc/SignInWithGoogleFailureInterface-class.md) +- [SignInWithTwitterFailureInterface](../wyatt_authentication_bloc/SignInWithTwitterFailureInterface-class.md) +- [SignOutFailureInterface](../wyatt_authentication_bloc/SignOutFailureInterface-class.md) +- [SignUpWithEmailAndPasswordFailureInterface](../wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureInterface-class.md) +- [UpdateEmailFailureInterface](../wyatt_authentication_bloc/UpdateEmailFailureInterface-class.md) +- [UpdatePasswordFailureInterface](../wyatt_authentication_bloc/UpdatePasswordFailureInterface-class.md) +- [VerifyPasswordResetCodeFailureInterface](../wyatt_authentication_bloc/VerifyPasswordResetCodeFailureInterface-class.md) + + + + + +## Constructors + +[AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface/AuthenticationFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + + + +[AuthenticationFailureInterface.fromCode](../wyatt_authentication_bloc/AuthenticationFailureInterface/AuthenticationFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / write_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-only_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / write_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface/AuthenticationFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface/AuthenticationFailureInterface.fromCode.md new file mode 100644 index 00000000..96605d88 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface/AuthenticationFailureInterface.fromCode.md @@ -0,0 +1,31 @@ + + + +# AuthenticationFailureInterface.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +AuthenticationFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + + +## Implementation + +```dart +AuthenticationFailureInterface.fromCode(this.code) + : msg = 'An unknown error occurred.'; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface/AuthenticationFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface/AuthenticationFailureInterface.md new file mode 100644 index 00000000..b64683e8 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface/AuthenticationFailureInterface.md @@ -0,0 +1,30 @@ + + + +# AuthenticationFailureInterface constructor + + + + + *[](https://dart.dev/null-safety)* + + + +AuthenticationFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + + + + + +## Implementation + +```dart +AuthenticationFailureInterface(this.code, this.msg); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface/code.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface/code.md new file mode 100644 index 00000000..7d6e8996 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface/code.md @@ -0,0 +1,33 @@ + + + +# code property + + + + + *[](https://dart.dev/null-safety)* + + + +[String](https://api.flutter.dev/flutter/dart-core/String-class.html) code + +_read / write_ + + + + + + +## Implementation + +```dart +String code; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface/message.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface/message.md new file mode 100644 index 00000000..fed51258 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface/message.md @@ -0,0 +1,40 @@ + + + +# message property + + + + + *[](https://dart.dev/null-safety)* + + + + + +**Annotations** + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) +[String](https://api.flutter.dev/flutter/dart-core/String-class.html) message + + + + + + + + +## Implementation + +```dart +@override +String get message => msg; +``` + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md new file mode 100644 index 00000000..820911a4 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md @@ -0,0 +1,33 @@ + + + +# msg property + + + + + *[](https://dart.dev/null-safety)* + + + +[String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg + +_read / write_ + + + + + + +## Implementation + +```dart +String msg; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md new file mode 100644 index 00000000..adf014b9 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md @@ -0,0 +1,53 @@ + + + +# toString method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[String](https://api.flutter.dev/flutter/dart-core/String-class.html) toString +() + +_inherited_ + + + +

A string representation of this object.

+

Some classes have a default textual representation, +often paired with a static parse function (like int.parse). +These classes will provide the textual representation as +their string representation.

+

Other classes have no meaningful textual representation +that a program will care about. +Such classes will typically override toString to provide +useful information when inspecting the object, +mainly for debugging or logging.

+ + + +## Implementation + +```dart +@override +String toString() { + if (message.isNotNullOrEmpty) { + return '$runtimeType: $message'; + } else { + return '$runtimeType: An exception occured'; + } +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl-class.md new file mode 100644 index 00000000..39635ba2 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl-class.md @@ -0,0 +1,251 @@ + + + +# AuthenticationFirebaseDataSourceImpl<Data> class + + + + + + + *[](https://dart.dev/null-safety)* + + + + + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationRemoteDataSource](../wyatt_authentication_bloc/AuthenticationRemoteDataSource-class.md)<Data> +- AuthenticationFirebaseDataSourceImpl + + + + + + + + +## Constructors + +[AuthenticationFirebaseDataSourceImpl](../wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/AuthenticationFirebaseDataSourceImpl.md) ({[FirebaseAuth](https://pub.dev/documentation/firebase_auth/4.2.0/firebase_auth/FirebaseAuth-class.html)? firebaseAuth, [GoogleSignIn](https://pub.dev/documentation/google_sign_in/5.4.2/google_sign_in/GoogleSignIn-class.html)? googleSignIn}) + + + + +## Properties + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [addSession](../wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/addSession.md)([SessionWrapper](../wyatt_authentication_bloc/SessionWrapper-class.md)<Data> wrapper) void + + + +Add a new authentication event. +_override_ + + + +##### [confirmPasswordReset](../wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/confirmPasswordReset.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) newPassword}) [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> + + + +Confirms the password reset with the provided newPassword and code. +_override_ + + + +##### [delete](../wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/delete.md)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> + + + +Delete account. +_override_ + + + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [reauthenticate](../wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/reauthenticate.md)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../wyatt_authentication_bloc/Account-class.md)> + + + +Some security-sensitive actions—such as deleting an account, +setting a primary email address, and changing a password—require that +the user has recently signed in. +_override_ + + + +##### [refresh](../wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/refresh.md)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../wyatt_authentication_bloc/Account-class.md)> + + + +Refreshes the current user, if signed in. +_override_ + + + +##### [sendEmailVerification](../wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/sendEmailVerification.md)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> + + + +Sends verification email to the account email. +_override_ + + + +##### [sendPasswordResetEmail](../wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/sendPasswordResetEmail.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email}) [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> + + + +Sends a password reset email to the provided email. +_override_ + + + +##### [sessionStream](../wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/sessionStream.md)() [Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[SessionWrapper](../wyatt_authentication_bloc/SessionWrapper-class.md)<Data>> + + + +Authentication state change event stream. +_override_ + + + +##### [signInAnonymously](../wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signInAnonymously.md)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../wyatt_authentication_bloc/Account-class.md)> + + + +Sign in anonymously. +_override_ + + + +##### [signInWithEmailAndPassword](../wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signInWithEmailAndPassword.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../wyatt_authentication_bloc/Account-class.md)> + + + +Signs in with the provided email and password. +_override_ + + + +##### [signInWithGoogle](../wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signInWithGoogle.md)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../wyatt_authentication_bloc/Account-class.md)> + + + +Starts the Sign In with Google Flow. +_override_ + + + +##### [signOut](../wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signOut.md)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> + + + +Signs out the current user. +It also clears the cache and the associated data. +_override_ + + + +##### [signUpWithEmailAndPassword](../wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signUpWithEmailAndPassword.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../wyatt_authentication_bloc/Account-class.md)> + + + +Creates a new user with the provided email and password. +_override_ + + + +##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + +##### [updateEmail](../wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/updateEmail.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email}) [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../wyatt_authentication_bloc/Account-class.md)> + + + +Update or add email. +_override_ + + + +##### [updatePassword](../wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/updatePassword.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../wyatt_authentication_bloc/Account-class.md)> + + + +Update or add password. +_override_ + + + +##### [verifyPasswordResetCode](../wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/verifyPasswordResetCode.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) code}) [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)> + + + +Verify password reset code. +_override_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/AuthenticationFirebaseDataSourceImpl.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/AuthenticationFirebaseDataSourceImpl.md new file mode 100644 index 00000000..d6364dcf --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/AuthenticationFirebaseDataSourceImpl.md @@ -0,0 +1,40 @@ + + + +# AuthenticationFirebaseDataSourceImpl<Data> constructor + + + + + *[](https://dart.dev/null-safety)* + + + +AuthenticationFirebaseDataSourceImpl<Data>({[FirebaseAuth](https://pub.dev/documentation/firebase_auth/4.2.0/firebase_auth/FirebaseAuth-class.html)? firebaseAuth, [GoogleSignIn](https://pub.dev/documentation/google_sign_in/5.4.2/google_sign_in/GoogleSignIn-class.html)? googleSignIn}) + + + + + +## Implementation + +```dart +AuthenticationFirebaseDataSourceImpl({ + FirebaseAuth? firebaseAuth, + GoogleSignIn? googleSignIn, +}) : _firebaseAuth = firebaseAuth ?? FirebaseAuth.instance, + _googleSignIn = googleSignIn ?? GoogleSignIn() { + _latestCredentials = BehaviorSubject(); + _sessionStream = BehaviorSubject(); + + // Check for account in memory (persistence) + _checkForCachedAccount(); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/addSession.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/addSession.md new file mode 100644 index 00000000..adb9c34d --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/addSession.md @@ -0,0 +1,40 @@ + + + +# addSession method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +void addSession +([SessionWrapper](../../wyatt_authentication_bloc/SessionWrapper-class.md)<Data> wrapper) + +_override_ + + + +

Add a new authentication event.

+ + + +## Implementation + +```dart +@override +void addSession(SessionWrapper wrapper) { + _sessionStream.add(wrapper); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/confirmPasswordReset.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/confirmPasswordReset.md new file mode 100644 index 00000000..5be2ed73 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/confirmPasswordReset.md @@ -0,0 +1,53 @@ + + + +# confirmPasswordReset method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> confirmPasswordReset +({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) newPassword}) + +_override_ + + + +

Confirms the password reset with the provided newPassword and code.

+

Throws a ConfirmPasswordResetFailureInterface if an exception occurs.

+ + + +## Implementation + +```dart +@override +Future confirmPasswordReset({ + required String code, + required String newPassword, +}) async { + try { + await _firebaseAuth.confirmPasswordReset( + code: code, + newPassword: newPassword, + ); + } on FirebaseAuthException catch (e) { + throw ConfirmPasswordResetFailureFirebase.fromCode(e.code); + } catch (_) { + throw ConfirmPasswordResetFailureFirebase(); + } +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/delete.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/delete.md new file mode 100644 index 00000000..64729914 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/delete.md @@ -0,0 +1,48 @@ + + + +# delete method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> delete +() + +_override_ + + + +

Delete account.

+

Throws a DeleteAccountFailureInterface if +an exception occurs.

+ + + +## Implementation + +```dart +@override +Future delete() async { + try { + await _firebaseAuth.currentUser!.delete(); + } on FirebaseAuthException catch (e) { + throw DeleteAccountFailureFirebase.fromCode(e.code); + } catch (_) { + throw DeleteAccountFailureFirebase(); + } +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/reauthenticate.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/reauthenticate.md new file mode 100644 index 00000000..244efea5 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/reauthenticate.md @@ -0,0 +1,61 @@ + + + +# reauthenticate method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../../wyatt_authentication_bloc/Account-class.md)> reauthenticate +() + +_override_ + + + +

Some security-sensitive actions—such as deleting an account, +setting a primary email address, and changing a password—require that +the user has recently signed in.

+

Throws a ReauthenticateFailureInterface if +an exception occurs.

+ + + +## Implementation + +```dart +@override +Future reauthenticate() async { + final latestCreds = + await _latestCredentials.stream.asBroadcastStream().last; + try { + if (latestCreds?.credential != null) { + await _firebaseAuth.currentUser + ?.reauthenticateWithCredential(latestCreds!.credential!); + } else { + throw Exception(); // Get caught just after. + } + + final account = AccountModel.fromFirebaseUser(_firebaseAuth.currentUser); + + return account; + } on FirebaseAuthException catch (e) { + throw ReauthenticateFailureFirebase.fromCode(e.code); + } catch (_) { + throw ReauthenticateFailureFirebase(); + } +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/refresh.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/refresh.md new file mode 100644 index 00000000..323f75a1 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/refresh.md @@ -0,0 +1,52 @@ + + + +# refresh method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../../wyatt_authentication_bloc/Account-class.md)> refresh +() + +_override_ + + + +

Refreshes the current user, if signed in.

+ + + +## Implementation + +```dart +@override +Future refresh() async { + try { + final jwt = await _firebaseAuth.currentUser?.getIdToken(true); + final account = AccountModel.fromFirebaseUser( + _firebaseAuth.currentUser, + accessToken: jwt, + ); + + return account; + } on FirebaseAuthException catch (e) { + throw RefreshFailureFirebase.fromCode(e.code); + } catch (_) { + throw RefreshFailureFirebase(); + } +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/sendEmailVerification.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/sendEmailVerification.md new file mode 100644 index 00000000..36e3bde4 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/sendEmailVerification.md @@ -0,0 +1,47 @@ + + + +# sendEmailVerification method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> sendEmailVerification +() + +_override_ + + + +

Sends verification email to the account email.

+

Throws a SendEmailVerificationFailureInterface if an exception occurs.

+ + + +## Implementation + +```dart +@override +Future sendEmailVerification() async { + try { + await _firebaseAuth.currentUser!.sendEmailVerification(); + } on FirebaseAuthException catch (e) { + throw SendEmailVerificationFailureFirebase.fromCode(e.code); + } catch (_) { + throw SendEmailVerificationFailureFirebase(); + } +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/sendPasswordResetEmail.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/sendPasswordResetEmail.md new file mode 100644 index 00000000..44ab9cd1 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/sendPasswordResetEmail.md @@ -0,0 +1,47 @@ + + + +# sendPasswordResetEmail method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> sendPasswordResetEmail +({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email}) + +_override_ + + + +

Sends a password reset email to the provided email.

+

Throws a SendPasswordResetEmailFailureInterface if an exception occurs.

+ + + +## Implementation + +```dart +@override +Future sendPasswordResetEmail({required String email}) async { + try { + await _firebaseAuth.sendPasswordResetEmail(email: email); + } on FirebaseAuthException catch (e) { + throw SendPasswordResetEmailFailureFirebase.fromCode(e.code); + } catch (_) { + throw SendPasswordResetEmailFailureFirebase(); + } +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/sessionStream.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/sessionStream.md new file mode 100644 index 00000000..d2bd33ab --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/sessionStream.md @@ -0,0 +1,39 @@ + + + +# sessionStream method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[SessionWrapper](../../wyatt_authentication_bloc/SessionWrapper-class.md)<Data>> sessionStream +() + +_override_ + + + +

Authentication state change event stream.

+ + + +## Implementation + +```dart +@override +Stream> sessionStream() => + _sessionStream.stream.asBroadcastStream(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signInAnonymously.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signInAnonymously.md new file mode 100644 index 00000000..80bef88a --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signInAnonymously.md @@ -0,0 +1,54 @@ + + + +# signInAnonymously method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../../wyatt_authentication_bloc/Account-class.md)> signInAnonymously +() + +_override_ + + + +

Sign in anonymously.

+

Throws a SignInAnonymouslyFailureInterface if an exception occurs.

+ + + +## Implementation + +```dart +@override +Future signInAnonymously() async { + try { + final userCredential = await _firebaseAuth.signInAnonymously(); + + return _addToStream( + userCredential, + (account) => SignedInEvent( + account: account, + ), + ); + } on FirebaseAuthException catch (e) { + throw SignInAnonymouslyFailureFirebase.fromCode(e.code); + } catch (_) { + throw SignInAnonymouslyFailureFirebase(); + } +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signInWithEmailAndPassword.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signInWithEmailAndPassword.md new file mode 100644 index 00000000..0303cc78 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signInWithEmailAndPassword.md @@ -0,0 +1,61 @@ + + + +# signInWithEmailAndPassword method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../../wyatt_authentication_bloc/Account-class.md)> signInWithEmailAndPassword +({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) + +_override_ + + + +

Signs in with the provided email and password.

+

Throws a SignInWithEmailAndPasswordFailureInterface if +an exception occurs.

+ + + +## Implementation + +```dart +@override +Future signInWithEmailAndPassword({ + required String email, + required String password, +}) async { + try { + final userCredential = await _firebaseAuth.signInWithEmailAndPassword( + email: email, + password: password, + ); + + return _addToStream( + userCredential, + (account) => SignedInEvent( + account: account, + ), + ); + } on FirebaseAuthException catch (e) { + throw SignInWithEmailAndPasswordFailureFirebase.fromCode(e.code); + } catch (_) { + throw SignInWithEmailAndPasswordFailureFirebase(); + } +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signInWithGoogle.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signInWithGoogle.md new file mode 100644 index 00000000..a8e00d8f --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signInWithGoogle.md @@ -0,0 +1,68 @@ + + + +# signInWithGoogle method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../../wyatt_authentication_bloc/Account-class.md)> signInWithGoogle +() + +_override_ + + + +

Starts the Sign In with Google Flow.

+

Throws a SignInWithGoogleFailureInterface if an exception occurs.

+ + + +## Implementation + +```dart +@override +Future signInWithGoogle() async { + try { + // Trigger the authentication flow + final GoogleSignInAccount? googleUser = await _googleSignIn.signIn(); + + // Obtain the auth details from the request + final GoogleSignInAuthentication? googleAuth = + await googleUser?.authentication; + + // Create a new credential + final credential = GoogleAuthProvider.credential( + accessToken: googleAuth?.accessToken, + idToken: googleAuth?.idToken, + ); + + final userCredential = + await _firebaseAuth.signInWithCredential(credential); + + return _addToStream( + userCredential, + (account) => SignedInEvent( + account: account, + ), + ); + } on FirebaseAuthException catch (e) { + throw SignInWithGoogleFailureFirebase.fromCode(e.code); + } catch (_) { + throw SignInWithGoogleFailureFirebase(); + } +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signOut.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signOut.md new file mode 100644 index 00000000..8e648e71 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signOut.md @@ -0,0 +1,46 @@ + + + +# signOut method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> signOut +() + +_override_ + + + +

Signs out the current user. +It also clears the cache and the associated data.

+ + + +## Implementation + +```dart +@override +Future signOut() async { + try { + _latestCredentials.add(null); + await _firebaseAuth.signOut(); + } catch (_) { + throw SignOutFailureFirebase(); + } +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signUpWithEmailAndPassword.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signUpWithEmailAndPassword.md new file mode 100644 index 00000000..4c81f5e2 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signUpWithEmailAndPassword.md @@ -0,0 +1,62 @@ + + + +# signUpWithEmailAndPassword method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../../wyatt_authentication_bloc/Account-class.md)> signUpWithEmailAndPassword +({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) + +_override_ + + + +

Creates a new user with the provided email and password.

+

Returns the newly created user's unique identifier.

+

Throws a SignUpWithEmailAndPasswordFailureInterface if +an exception occurs.

+ + + +## Implementation + +```dart +@override +Future signUpWithEmailAndPassword({ + required String email, + required String password, +}) async { + try { + final userCredential = await _firebaseAuth.createUserWithEmailAndPassword( + email: email, + password: password, + ); + + return _addToStream( + userCredential, + (account) => SignedUpEvent( + account: account, + ), + ); + } on FirebaseAuthException catch (e) { + throw SignUpWithEmailAndPasswordFailureFirebase.fromCode(e.code); + } catch (_) { + throw SignUpWithEmailAndPasswordFailureFirebase(); + } +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/updateEmail.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/updateEmail.md new file mode 100644 index 00000000..11399787 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/updateEmail.md @@ -0,0 +1,55 @@ + + + +# updateEmail method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../../wyatt_authentication_bloc/Account-class.md)> updateEmail +({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email}) + +_override_ + + + +

Update or add email.

+

Throws a UpdateEmailFailureInterface if +an exception occurs.

+ + + +## Implementation + +```dart +@override +Future updateEmail({required String email}) async { + try { + await _firebaseAuth.currentUser!.updateEmail(email); + final jwt = await _firebaseAuth.currentUser!.getIdToken(true); + final account = AccountModel.fromFirebaseUser( + _firebaseAuth.currentUser, + accessToken: jwt, + ); + + return account; + } on FirebaseAuthException catch (e) { + throw UpdateEmailFailureFirebase.fromCode(e.code); + } catch (_) { + throw UpdateEmailFailureFirebase(); + } +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/updatePassword.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/updatePassword.md new file mode 100644 index 00000000..be85ed32 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/updatePassword.md @@ -0,0 +1,55 @@ + + + +# updatePassword method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../../wyatt_authentication_bloc/Account-class.md)> updatePassword +({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) + +_override_ + + + +

Update or add password.

+

Throws a UpdatePasswordFailureInterface if +an exception occurs.

+ + + +## Implementation + +```dart +@override +Future updatePassword({required String password}) async { + try { + await _firebaseAuth.currentUser!.updatePassword(password); + final jwt = await _firebaseAuth.currentUser!.getIdToken(true); + final account = AccountModel.fromFirebaseUser( + _firebaseAuth.currentUser, + accessToken: jwt, + ); + + return account; + } on FirebaseAuthException catch (e) { + throw UpdatePasswordFailureFirebase.fromCode(e.code); + } catch (_) { + throw UpdatePasswordFailureFirebase(); + } +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/verifyPasswordResetCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/verifyPasswordResetCode.md new file mode 100644 index 00000000..887564d5 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/verifyPasswordResetCode.md @@ -0,0 +1,48 @@ + + + +# verifyPasswordResetCode method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)> verifyPasswordResetCode +({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) code}) + +_override_ + + + +

Verify password reset code.

+

Throws a VerifyPasswordResetCodeFailureInterface if an exception occurs.

+ + + +## Implementation + +```dart +@override +Future verifyPasswordResetCode({required String code}) async { + try { + final email = await _firebaseAuth.verifyPasswordResetCode(code); + return email.isNotNullOrEmpty; + } on FirebaseAuthException catch (e) { + throw VerifyPasswordResetCodeFailureFirebase.fromCode(e.code); + } catch (_) { + throw VerifyPasswordResetCodeFailureFirebase(); + } +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource-class.md new file mode 100644 index 00000000..29bfc2f7 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource-class.md @@ -0,0 +1,247 @@ + + + +# AuthenticationRemoteDataSource<Data> class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Is responsible for abstracting the provenance of the data.

+ + + + + + +**Implementers** + +- [AuthenticationFirebaseDataSourceImpl](../wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl-class.md) + + + + + +## Constructors + +[AuthenticationRemoteDataSource](../wyatt_authentication_bloc/AuthenticationRemoteDataSource/AuthenticationRemoteDataSource.md) () + + + + +## Properties + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [addSession](../wyatt_authentication_bloc/AuthenticationRemoteDataSource/addSession.md)([SessionWrapper](../wyatt_authentication_bloc/SessionWrapper-class.md)<Data> wrapper) void + + + + + + + + +##### [confirmPasswordReset](../wyatt_authentication_bloc/AuthenticationRemoteDataSource/confirmPasswordReset.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) newPassword}) [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> + + + + + + + + +##### [delete](../wyatt_authentication_bloc/AuthenticationRemoteDataSource/delete.md)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> + + + + + + + + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [reauthenticate](../wyatt_authentication_bloc/AuthenticationRemoteDataSource/reauthenticate.md)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../wyatt_authentication_bloc/Account-class.md)> + + + + + + + + +##### [refresh](../wyatt_authentication_bloc/AuthenticationRemoteDataSource/refresh.md)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../wyatt_authentication_bloc/Account-class.md)> + + + + + + + + +##### [sendEmailVerification](../wyatt_authentication_bloc/AuthenticationRemoteDataSource/sendEmailVerification.md)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> + + + + + + + + +##### [sendPasswordResetEmail](../wyatt_authentication_bloc/AuthenticationRemoteDataSource/sendPasswordResetEmail.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email}) [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> + + + + + + + + +##### [sessionStream](../wyatt_authentication_bloc/AuthenticationRemoteDataSource/sessionStream.md)() [Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[SessionWrapper](../wyatt_authentication_bloc/SessionWrapper-class.md)<Data>> + + + + + + + + +##### [signInAnonymously](../wyatt_authentication_bloc/AuthenticationRemoteDataSource/signInAnonymously.md)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../wyatt_authentication_bloc/Account-class.md)> + + + + + + + + +##### [signInWithEmailAndPassword](../wyatt_authentication_bloc/AuthenticationRemoteDataSource/signInWithEmailAndPassword.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../wyatt_authentication_bloc/Account-class.md)> + + + + + + + + +##### [signInWithGoogle](../wyatt_authentication_bloc/AuthenticationRemoteDataSource/signInWithGoogle.md)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../wyatt_authentication_bloc/Account-class.md)> + + + + + + + + +##### [signOut](../wyatt_authentication_bloc/AuthenticationRemoteDataSource/signOut.md)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> + + + + + + + + +##### [signUpWithEmailAndPassword](../wyatt_authentication_bloc/AuthenticationRemoteDataSource/signUpWithEmailAndPassword.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../wyatt_authentication_bloc/Account-class.md)> + + + + + + + + +##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + +##### [updateEmail](../wyatt_authentication_bloc/AuthenticationRemoteDataSource/updateEmail.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email}) [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../wyatt_authentication_bloc/Account-class.md)> + + + + + + + + +##### [updatePassword](../wyatt_authentication_bloc/AuthenticationRemoteDataSource/updatePassword.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../wyatt_authentication_bloc/Account-class.md)> + + + + + + + + +##### [verifyPasswordResetCode](../wyatt_authentication_bloc/AuthenticationRemoteDataSource/verifyPasswordResetCode.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) code}) [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)> + + + + + + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/AuthenticationRemoteDataSource.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/AuthenticationRemoteDataSource.md new file mode 100644 index 00000000..9552fade --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/AuthenticationRemoteDataSource.md @@ -0,0 +1,25 @@ + + + +# AuthenticationRemoteDataSource<Data> constructor + + + + + *[](https://dart.dev/null-safety)* + + + +AuthenticationRemoteDataSource<Data>() + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/addSession.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/addSession.md new file mode 100644 index 00000000..f1567da2 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/addSession.md @@ -0,0 +1,35 @@ + + + +# addSession method + + + + + *[](https://dart.dev/null-safety)* + + + + +void addSession +([SessionWrapper](../../wyatt_authentication_bloc/SessionWrapper-class.md)<Data> wrapper) + + + + + + + + +## Implementation + +```dart +void addSession(SessionWrapper wrapper); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/confirmPasswordReset.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/confirmPasswordReset.md new file mode 100644 index 00000000..785714a8 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/confirmPasswordReset.md @@ -0,0 +1,38 @@ + + + +# confirmPasswordReset method + + + + + *[](https://dart.dev/null-safety)* + + + + +[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> confirmPasswordReset +({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) newPassword}) + + + + + + + + +## Implementation + +```dart +Future confirmPasswordReset({ + required String code, + required String newPassword, +}); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/delete.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/delete.md new file mode 100644 index 00000000..aad9ff7b --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/delete.md @@ -0,0 +1,35 @@ + + + +# delete method + + + + + *[](https://dart.dev/null-safety)* + + + + +[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> delete +() + + + + + + + + +## Implementation + +```dart +Future delete(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/reauthenticate.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/reauthenticate.md new file mode 100644 index 00000000..7f369a4c --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/reauthenticate.md @@ -0,0 +1,35 @@ + + + +# reauthenticate method + + + + + *[](https://dart.dev/null-safety)* + + + + +[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../../wyatt_authentication_bloc/Account-class.md)> reauthenticate +() + + + + + + + + +## Implementation + +```dart +Future reauthenticate(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/refresh.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/refresh.md new file mode 100644 index 00000000..104a6bc0 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/refresh.md @@ -0,0 +1,35 @@ + + + +# refresh method + + + + + *[](https://dart.dev/null-safety)* + + + + +[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../../wyatt_authentication_bloc/Account-class.md)> refresh +() + + + + + + + + +## Implementation + +```dart +Future refresh(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/sendEmailVerification.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/sendEmailVerification.md new file mode 100644 index 00000000..8ee8fe82 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/sendEmailVerification.md @@ -0,0 +1,35 @@ + + + +# sendEmailVerification method + + + + + *[](https://dart.dev/null-safety)* + + + + +[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> sendEmailVerification +() + + + + + + + + +## Implementation + +```dart +Future sendEmailVerification(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/sendPasswordResetEmail.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/sendPasswordResetEmail.md new file mode 100644 index 00000000..86a6aae2 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/sendPasswordResetEmail.md @@ -0,0 +1,35 @@ + + + +# sendPasswordResetEmail method + + + + + *[](https://dart.dev/null-safety)* + + + + +[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> sendPasswordResetEmail +({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email}) + + + + + + + + +## Implementation + +```dart +Future sendPasswordResetEmail({required String email}); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/sessionStream.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/sessionStream.md new file mode 100644 index 00000000..9d8739aa --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/sessionStream.md @@ -0,0 +1,35 @@ + + + +# sessionStream method + + + + + *[](https://dart.dev/null-safety)* + + + + +[Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[SessionWrapper](../../wyatt_authentication_bloc/SessionWrapper-class.md)<Data>> sessionStream +() + + + + + + + + +## Implementation + +```dart +Stream> sessionStream(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/signInAnonymously.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/signInAnonymously.md new file mode 100644 index 00000000..ac7985b1 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/signInAnonymously.md @@ -0,0 +1,35 @@ + + + +# signInAnonymously method + + + + + *[](https://dart.dev/null-safety)* + + + + +[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../../wyatt_authentication_bloc/Account-class.md)> signInAnonymously +() + + + + + + + + +## Implementation + +```dart +Future signInAnonymously(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/signInWithEmailAndPassword.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/signInWithEmailAndPassword.md new file mode 100644 index 00000000..394754c5 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/signInWithEmailAndPassword.md @@ -0,0 +1,38 @@ + + + +# signInWithEmailAndPassword method + + + + + *[](https://dart.dev/null-safety)* + + + + +[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../../wyatt_authentication_bloc/Account-class.md)> signInWithEmailAndPassword +({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) + + + + + + + + +## Implementation + +```dart +Future signInWithEmailAndPassword({ + required String email, + required String password, +}); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/signInWithGoogle.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/signInWithGoogle.md new file mode 100644 index 00000000..4713504f --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/signInWithGoogle.md @@ -0,0 +1,35 @@ + + + +# signInWithGoogle method + + + + + *[](https://dart.dev/null-safety)* + + + + +[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../../wyatt_authentication_bloc/Account-class.md)> signInWithGoogle +() + + + + + + + + +## Implementation + +```dart +Future signInWithGoogle(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/signOut.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/signOut.md new file mode 100644 index 00000000..f650758c --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/signOut.md @@ -0,0 +1,35 @@ + + + +# signOut method + + + + + *[](https://dart.dev/null-safety)* + + + + +[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> signOut +() + + + + + + + + +## Implementation + +```dart +Future signOut(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/signUpWithEmailAndPassword.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/signUpWithEmailAndPassword.md new file mode 100644 index 00000000..6d55af4c --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/signUpWithEmailAndPassword.md @@ -0,0 +1,38 @@ + + + +# signUpWithEmailAndPassword method + + + + + *[](https://dart.dev/null-safety)* + + + + +[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../../wyatt_authentication_bloc/Account-class.md)> signUpWithEmailAndPassword +({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) + + + + + + + + +## Implementation + +```dart +Future signUpWithEmailAndPassword({ + required String email, + required String password, +}); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/updateEmail.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/updateEmail.md new file mode 100644 index 00000000..07110bcb --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/updateEmail.md @@ -0,0 +1,35 @@ + + + +# updateEmail method + + + + + *[](https://dart.dev/null-safety)* + + + + +[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../../wyatt_authentication_bloc/Account-class.md)> updateEmail +({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email}) + + + + + + + + +## Implementation + +```dart +Future updateEmail({required String email}); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/updatePassword.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/updatePassword.md new file mode 100644 index 00000000..043a101f --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/updatePassword.md @@ -0,0 +1,35 @@ + + + +# updatePassword method + + + + + *[](https://dart.dev/null-safety)* + + + + +[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../../wyatt_authentication_bloc/Account-class.md)> updatePassword +({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) + + + + + + + + +## Implementation + +```dart +Future updatePassword({required String password}); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/verifyPasswordResetCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/verifyPasswordResetCode.md new file mode 100644 index 00000000..bee09e13 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/verifyPasswordResetCode.md @@ -0,0 +1,35 @@ + + + +# verifyPasswordResetCode method + + + + + *[](https://dart.dev/null-safety)* + + + + +[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)> verifyPasswordResetCode +({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) code}) + + + + + + + + +## Implementation + +```dart +Future verifyPasswordResetCode({required String code}); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository-class.md new file mode 100644 index 00000000..80cf4ff5 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository-class.md @@ -0,0 +1,258 @@ + + + +# AuthenticationRepository<Data> class + + + + + + + *[](https://dart.dev/null-safety)* + + + + + + + + + +**Implementers** + +- [AuthenticationRepositoryImpl](../wyatt_authentication_bloc/AuthenticationRepositoryImpl-class.md) + + + + + +## Constructors + +[AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository/AuthenticationRepository.md) () + + + + +## Properties + +##### [formRepository](../wyatt_authentication_bloc/AuthenticationRepository/formRepository.md) → FormRepository + + + +Form repository used in different authentication cubits/blocs +_read-only_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [addSession](../wyatt_authentication_bloc/AuthenticationRepository/addSession.md)([SessionWrapper](../wyatt_authentication_bloc/SessionWrapper-class.md)<Data> wrapper) void + + + +Add a new authentication event. + + + + +##### [confirmPasswordReset](../wyatt_authentication_bloc/AuthenticationRepository/confirmPasswordReset.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) newPassword}) FutureOrResult<void> + + + +Confirms the password reset with the provided newPassword and code. + + + + +##### [delete](../wyatt_authentication_bloc/AuthenticationRepository/delete.md)() FutureOrResult<void> + + + +Delete account. + + + + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [reauthenticate](../wyatt_authentication_bloc/AuthenticationRepository/reauthenticate.md)() FutureOrResult<[Account](../wyatt_authentication_bloc/Account-class.md)> + + + +Some security-sensitive actions—such as deleting an account, +setting a primary email address, and changing a password—require that +the user has recently signed in. + + + + +##### [refresh](../wyatt_authentication_bloc/AuthenticationRepository/refresh.md)() FutureOrResult<[Account](../wyatt_authentication_bloc/Account-class.md)> + + + +Refreshes the current user, if signed in. + + + + +##### [sendEmailVerification](../wyatt_authentication_bloc/AuthenticationRepository/sendEmailVerification.md)() FutureOrResult<void> + + + +Sends verification email to the account email. + + + + +##### [sendPasswordResetEmail](../wyatt_authentication_bloc/AuthenticationRepository/sendPasswordResetEmail.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email}) FutureOrResult<void> + + + +Sends a password reset email to the provided email. + + + + +##### [sessionStream](../wyatt_authentication_bloc/AuthenticationRepository/sessionStream.md)() [Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[SessionWrapper](../wyatt_authentication_bloc/SessionWrapper-class.md)<Data>> + + + +Authentication state change event stream. + + + + +##### [signInAnonymously](../wyatt_authentication_bloc/AuthenticationRepository/signInAnonymously.md)() FutureOrResult<[Account](../wyatt_authentication_bloc/Account-class.md)> + + + +Sign in anonymously. + + + + +##### [signInWithEmailAndPassword](../wyatt_authentication_bloc/AuthenticationRepository/signInWithEmailAndPassword.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) FutureOrResult<[Account](../wyatt_authentication_bloc/Account-class.md)> + + + +Signs in with the provided email and password. + + + + +##### [signInWithGoogle](../wyatt_authentication_bloc/AuthenticationRepository/signInWithGoogle.md)() FutureOrResult<[Account](../wyatt_authentication_bloc/Account-class.md)> + + + +Starts the Sign In with Google Flow. + + + + +##### [signOut](../wyatt_authentication_bloc/AuthenticationRepository/signOut.md)() FutureOrResult<void> + + + +Signs out the current user. +It also clears the cache and the associated data. + + + + +##### [signUpWithEmailAndPassword](../wyatt_authentication_bloc/AuthenticationRepository/signUpWithEmailAndPassword.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) FutureOrResult<[Account](../wyatt_authentication_bloc/Account-class.md)> + + + +Creates a new user with the provided email and password. + + + + +##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + +##### [updateEmail](../wyatt_authentication_bloc/AuthenticationRepository/updateEmail.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email}) FutureOrResult<[Account](../wyatt_authentication_bloc/Account-class.md)> + + + +Update or add email. + + + + +##### [updatePassword](../wyatt_authentication_bloc/AuthenticationRepository/updatePassword.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) FutureOrResult<[Account](../wyatt_authentication_bloc/Account-class.md)> + + + +Update or add password. + + + + +##### [verifyPasswordResetCode](../wyatt_authentication_bloc/AuthenticationRepository/verifyPasswordResetCode.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) code}) FutureOrResult<[bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)> + + + +Verify password reset code. + + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/AuthenticationRepository.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/AuthenticationRepository.md new file mode 100644 index 00000000..da6e6d1d --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/AuthenticationRepository.md @@ -0,0 +1,25 @@ + + + +# AuthenticationRepository<Data> constructor + + + + + *[](https://dart.dev/null-safety)* + + + +AuthenticationRepository<Data>() + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/addSession.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/addSession.md new file mode 100644 index 00000000..dd5755bd --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/addSession.md @@ -0,0 +1,36 @@ + + + +# addSession method + + + + + *[](https://dart.dev/null-safety)* + + + + +void addSession +([SessionWrapper](../../wyatt_authentication_bloc/SessionWrapper-class.md)<Data> wrapper) + + + + + +

Add a new authentication event.

+ + + +## Implementation + +```dart +void addSession(SessionWrapper wrapper); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/confirmPasswordReset.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/confirmPasswordReset.md new file mode 100644 index 00000000..43531c88 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/confirmPasswordReset.md @@ -0,0 +1,40 @@ + + + +# confirmPasswordReset method + + + + + *[](https://dart.dev/null-safety)* + + + + +FutureOrResult<void> confirmPasswordReset +({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) newPassword}) + + + + + +

Confirms the password reset with the provided newPassword and code.

+

Throws a ConfirmPasswordResetFailureInterface if an exception occurs.

+ + + +## Implementation + +```dart +FutureOrResult confirmPasswordReset({ + required String code, + required String newPassword, +}); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/delete.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/delete.md new file mode 100644 index 00000000..05b49493 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/delete.md @@ -0,0 +1,38 @@ + + + +# delete method + + + + + *[](https://dart.dev/null-safety)* + + + + +FutureOrResult<void> delete +() + + + + + +

Delete account.

+

Throws a DeleteAccountFailureInterface if +an exception occurs.

+ + + +## Implementation + +```dart +FutureOrResult delete(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/formRepository.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/formRepository.md new file mode 100644 index 00000000..0bded545 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/formRepository.md @@ -0,0 +1,37 @@ + + + +# formRepository property + + + + + *[](https://dart.dev/null-safety)* + + + + + +FormRepository formRepository + + + + + +

Form repository used in different authentication cubits/blocs

+ + + +## Implementation + +```dart +FormRepository get formRepository; +``` + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/reauthenticate.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/reauthenticate.md new file mode 100644 index 00000000..809974fe --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/reauthenticate.md @@ -0,0 +1,40 @@ + + + +# reauthenticate method + + + + + *[](https://dart.dev/null-safety)* + + + + +FutureOrResult<[Account](../../wyatt_authentication_bloc/Account-class.md)> reauthenticate +() + + + + + +

Some security-sensitive actions—such as deleting an account, +setting a primary email address, and changing a password—require that +the user has recently signed in.

+

Throws a ReauthenticateFailureInterface if +an exception occurs.

+ + + +## Implementation + +```dart +FutureOrResult reauthenticate(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/refresh.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/refresh.md new file mode 100644 index 00000000..5f3413e3 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/refresh.md @@ -0,0 +1,36 @@ + + + +# refresh method + + + + + *[](https://dart.dev/null-safety)* + + + + +FutureOrResult<[Account](../../wyatt_authentication_bloc/Account-class.md)> refresh +() + + + + + +

Refreshes the current user, if signed in.

+ + + +## Implementation + +```dart +FutureOrResult refresh(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/sendEmailVerification.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/sendEmailVerification.md new file mode 100644 index 00000000..184e510c --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/sendEmailVerification.md @@ -0,0 +1,37 @@ + + + +# sendEmailVerification method + + + + + *[](https://dart.dev/null-safety)* + + + + +FutureOrResult<void> sendEmailVerification +() + + + + + +

Sends verification email to the account email.

+

Throws a SendEmailVerificationFailureInterface if an exception occurs.

+ + + +## Implementation + +```dart +FutureOrResult sendEmailVerification(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/sendPasswordResetEmail.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/sendPasswordResetEmail.md new file mode 100644 index 00000000..5778307e --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/sendPasswordResetEmail.md @@ -0,0 +1,37 @@ + + + +# sendPasswordResetEmail method + + + + + *[](https://dart.dev/null-safety)* + + + + +FutureOrResult<void> sendPasswordResetEmail +({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email}) + + + + + +

Sends a password reset email to the provided email.

+

Throws a SendPasswordResetEmailFailureInterface if an exception occurs.

+ + + +## Implementation + +```dart +FutureOrResult sendPasswordResetEmail({required String email}); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/sessionStream.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/sessionStream.md new file mode 100644 index 00000000..d911cb8d --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/sessionStream.md @@ -0,0 +1,36 @@ + + + +# sessionStream method + + + + + *[](https://dart.dev/null-safety)* + + + + +[Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[SessionWrapper](../../wyatt_authentication_bloc/SessionWrapper-class.md)<Data>> sessionStream +() + + + + + +

Authentication state change event stream.

+ + + +## Implementation + +```dart +Stream> sessionStream(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/signInAnonymously.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/signInAnonymously.md new file mode 100644 index 00000000..03d3f774 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/signInAnonymously.md @@ -0,0 +1,37 @@ + + + +# signInAnonymously method + + + + + *[](https://dart.dev/null-safety)* + + + + +FutureOrResult<[Account](../../wyatt_authentication_bloc/Account-class.md)> signInAnonymously +() + + + + + +

Sign in anonymously.

+

Throws a SignInAnonymouslyFailureInterface if an exception occurs.

+ + + +## Implementation + +```dart +FutureOrResult signInAnonymously(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/signInWithEmailAndPassword.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/signInWithEmailAndPassword.md new file mode 100644 index 00000000..5ae7989f --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/signInWithEmailAndPassword.md @@ -0,0 +1,41 @@ + + + +# signInWithEmailAndPassword method + + + + + *[](https://dart.dev/null-safety)* + + + + +FutureOrResult<[Account](../../wyatt_authentication_bloc/Account-class.md)> signInWithEmailAndPassword +({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) + + + + + +

Signs in with the provided email and password.

+

Throws a SignInWithEmailAndPasswordFailureInterface if +an exception occurs.

+ + + +## Implementation + +```dart +FutureOrResult signInWithEmailAndPassword({ + required String email, + required String password, +}); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/signInWithGoogle.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/signInWithGoogle.md new file mode 100644 index 00000000..18a8989b --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/signInWithGoogle.md @@ -0,0 +1,37 @@ + + + +# signInWithGoogle method + + + + + *[](https://dart.dev/null-safety)* + + + + +FutureOrResult<[Account](../../wyatt_authentication_bloc/Account-class.md)> signInWithGoogle +() + + + + + +

Starts the Sign In with Google Flow.

+

Throws a SignInWithGoogleFailureInterface if an exception occurs.

+ + + +## Implementation + +```dart +FutureOrResult signInWithGoogle(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/signOut.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/signOut.md new file mode 100644 index 00000000..7dad6c4b --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/signOut.md @@ -0,0 +1,37 @@ + + + +# signOut method + + + + + *[](https://dart.dev/null-safety)* + + + + +FutureOrResult<void> signOut +() + + + + + +

Signs out the current user. +It also clears the cache and the associated data.

+ + + +## Implementation + +```dart +FutureOrResult signOut(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/signUpWithEmailAndPassword.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/signUpWithEmailAndPassword.md new file mode 100644 index 00000000..7a99a749 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/signUpWithEmailAndPassword.md @@ -0,0 +1,42 @@ + + + +# signUpWithEmailAndPassword method + + + + + *[](https://dart.dev/null-safety)* + + + + +FutureOrResult<[Account](../../wyatt_authentication_bloc/Account-class.md)> signUpWithEmailAndPassword +({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) + + + + + +

Creates a new user with the provided email and password.

+

Returns the newly created user's unique identifier.

+

Throws a SignUpWithEmailAndPasswordFailureInterface if +an exception occurs.

+ + + +## Implementation + +```dart +FutureOrResult signUpWithEmailAndPassword({ + required String email, + required String password, +}); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/updateEmail.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/updateEmail.md new file mode 100644 index 00000000..e324d7ad --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/updateEmail.md @@ -0,0 +1,40 @@ + + + +# updateEmail method + + + + + *[](https://dart.dev/null-safety)* + + + + +FutureOrResult<[Account](../../wyatt_authentication_bloc/Account-class.md)> updateEmail +({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email}) + + + + + +

Update or add email.

+

Throws a UpdateEmailFailureInterface if +an exception occurs.

+ + + +## Implementation + +```dart +FutureOrResult updateEmail({ + required String email, +}); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/updatePassword.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/updatePassword.md new file mode 100644 index 00000000..ac90a4a9 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/updatePassword.md @@ -0,0 +1,40 @@ + + + +# updatePassword method + + + + + *[](https://dart.dev/null-safety)* + + + + +FutureOrResult<[Account](../../wyatt_authentication_bloc/Account-class.md)> updatePassword +({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) + + + + + +

Update or add password.

+

Throws a UpdatePasswordFailureInterface if +an exception occurs.

+ + + +## Implementation + +```dart +FutureOrResult updatePassword({ + required String password, +}); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/verifyPasswordResetCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/verifyPasswordResetCode.md new file mode 100644 index 00000000..73463137 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/verifyPasswordResetCode.md @@ -0,0 +1,37 @@ + + + +# verifyPasswordResetCode method + + + + + *[](https://dart.dev/null-safety)* + + + + +FutureOrResult<[bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)> verifyPasswordResetCode +({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) code}) + + + + + +

Verify password reset code.

+

Throws a VerifyPasswordResetCodeFailureInterface if an exception occurs.

+ + + +## Implementation + +```dart +FutureOrResult verifyPasswordResetCode({required String code}); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl-class.md new file mode 100644 index 00000000..5ec57c81 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl-class.md @@ -0,0 +1,269 @@ + + + +# AuthenticationRepositoryImpl<Data extends Object> class + + + + + + + *[](https://dart.dev/null-safety)* + + + + + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> +- AuthenticationRepositoryImpl + + + + + + + + +## Constructors + +[AuthenticationRepositoryImpl](../wyatt_authentication_bloc/AuthenticationRepositoryImpl/AuthenticationRepositoryImpl.md) ({required [AuthenticationRemoteDataSource](../wyatt_authentication_bloc/AuthenticationRemoteDataSource-class.md)<Data> authenticationRemoteDataSource, FormRepository? formRepository, [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<FormInput<dynamic, FormInputValidator<dynamic, ValidationError>, dynamic>>? extraSignUpInputs, [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<FormInput<dynamic, FormInputValidator<dynamic, ValidationError>, dynamic>>? extraEditAccountInputs, FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError>? customEmailValidator, FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError>? customPasswordValidator}) + + + + +## Properties + +##### [authenticationRemoteDataSource](../wyatt_authentication_bloc/AuthenticationRepositoryImpl/authenticationRemoteDataSource.md) → [AuthenticationRemoteDataSource](../wyatt_authentication_bloc/AuthenticationRemoteDataSource-class.md)<Data> + + + + +_final_ + + + +##### [formRepository](../wyatt_authentication_bloc/AuthenticationRepositoryImpl/formRepository.md) → FormRepository + + + +Form repository used in different authentication cubits/blocs +_read-onlyoverride_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [addSession](../wyatt_authentication_bloc/AuthenticationRepositoryImpl/addSession.md)([SessionWrapper](../wyatt_authentication_bloc/SessionWrapper-class.md)<Data> wrapper) void + + + +Add a new authentication event. +_override_ + + + +##### [confirmPasswordReset](../wyatt_authentication_bloc/AuthenticationRepositoryImpl/confirmPasswordReset.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) newPassword}) FutureOrResult<void> + + + +Confirms the password reset with the provided newPassword and code. +_override_ + + + +##### [delete](../wyatt_authentication_bloc/AuthenticationRepositoryImpl/delete.md)() FutureOrResult<void> + + + +Delete account. +_override_ + + + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [reauthenticate](../wyatt_authentication_bloc/AuthenticationRepositoryImpl/reauthenticate.md)() FutureOrResult<[Account](../wyatt_authentication_bloc/Account-class.md)> + + + +Some security-sensitive actions—such as deleting an account, +setting a primary email address, and changing a password—require that +the user has recently signed in. +_override_ + + + +##### [refresh](../wyatt_authentication_bloc/AuthenticationRepositoryImpl/refresh.md)() FutureOrResult<[Account](../wyatt_authentication_bloc/Account-class.md)> + + + +Refreshes the current user, if signed in. +_override_ + + + +##### [sendEmailVerification](../wyatt_authentication_bloc/AuthenticationRepositoryImpl/sendEmailVerification.md)() FutureOrResult<void> + + + +Sends verification email to the account email. +_override_ + + + +##### [sendPasswordResetEmail](../wyatt_authentication_bloc/AuthenticationRepositoryImpl/sendPasswordResetEmail.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email}) FutureOrResult<void> + + + +Sends a password reset email to the provided email. +_override_ + + + +##### [sessionStream](../wyatt_authentication_bloc/AuthenticationRepositoryImpl/sessionStream.md)() [Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[SessionWrapper](../wyatt_authentication_bloc/SessionWrapper-class.md)<Data>> + + + +Authentication state change event stream. +_override_ + + + +##### [signInAnonymously](../wyatt_authentication_bloc/AuthenticationRepositoryImpl/signInAnonymously.md)() FutureOrResult<[Account](../wyatt_authentication_bloc/Account-class.md)> + + + +Sign in anonymously. +_override_ + + + +##### [signInWithEmailAndPassword](../wyatt_authentication_bloc/AuthenticationRepositoryImpl/signInWithEmailAndPassword.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) FutureOrResult<[Account](../wyatt_authentication_bloc/Account-class.md)> + + + +Signs in with the provided email and password. +_override_ + + + +##### [signInWithGoogle](../wyatt_authentication_bloc/AuthenticationRepositoryImpl/signInWithGoogle.md)() FutureOrResult<[Account](../wyatt_authentication_bloc/Account-class.md)> + + + +Starts the Sign In with Google Flow. +_override_ + + + +##### [signOut](../wyatt_authentication_bloc/AuthenticationRepositoryImpl/signOut.md)() FutureOrResult<void> + + + +Signs out the current user. +It also clears the cache and the associated data. +_override_ + + + +##### [signUpWithEmailAndPassword](../wyatt_authentication_bloc/AuthenticationRepositoryImpl/signUpWithEmailAndPassword.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) FutureOrResult<[Account](../wyatt_authentication_bloc/Account-class.md)> + + + +Creates a new user with the provided email and password. +_override_ + + + +##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + +##### [updateEmail](../wyatt_authentication_bloc/AuthenticationRepositoryImpl/updateEmail.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email}) FutureOrResult<[Account](../wyatt_authentication_bloc/Account-class.md)> + + + +Update or add email. +_override_ + + + +##### [updatePassword](../wyatt_authentication_bloc/AuthenticationRepositoryImpl/updatePassword.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) FutureOrResult<[Account](../wyatt_authentication_bloc/Account-class.md)> + + + +Update or add password. +_override_ + + + +##### [verifyPasswordResetCode](../wyatt_authentication_bloc/AuthenticationRepositoryImpl/verifyPasswordResetCode.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) code}) FutureOrResult<[bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)> + + + +Verify password reset code. +_override_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/AuthenticationRepositoryImpl.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/AuthenticationRepositoryImpl.md new file mode 100644 index 00000000..5fd00e8a --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/AuthenticationRepositoryImpl.md @@ -0,0 +1,69 @@ + + + +# AuthenticationRepositoryImpl<Data extends Object> constructor + + + + + *[](https://dart.dev/null-safety)* + + + +AuthenticationRepositoryImpl<Data extends Object>({required [AuthenticationRemoteDataSource](../../wyatt_authentication_bloc/AuthenticationRemoteDataSource-class.md)<Data> authenticationRemoteDataSource, FormRepository? formRepository, [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<FormInput<dynamic, FormInputValidator<dynamic, ValidationError>, dynamic>>? extraSignUpInputs, [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<FormInput<dynamic, FormInputValidator<dynamic, ValidationError>, dynamic>>? extraEditAccountInputs, FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError>? customEmailValidator, FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError>? customPasswordValidator}) + + + + + +## Implementation + +```dart +AuthenticationRepositoryImpl({ + required this.authenticationRemoteDataSource, + FormRepository? formRepository, + // ignore: strict_raw_type + List? extraSignUpInputs, + // ignore: strict_raw_type + List? extraEditAccountInputs, + FormInputValidator? customEmailValidator, + FormInputValidator? customPasswordValidator, +}) { + _formRepository = formRepository ?? FormRepositoryImpl(); + + if (formRepository != null) { + return; + } + _formRepository + ..registerForm( + Forms.buildSignUpForm( + customEmailValidator, + customPasswordValidator, + extraSignUpInputs, + ), + ) + ..registerForm( + Forms.buildSignInForm( + customEmailValidator, + customPasswordValidator, + ), + ) + ..registerForm( + Forms.buildPasswordResetForm(customEmailValidator), + ) + ..registerForm( + Forms.buildEditAccountForm( + customEmailValidator, + customPasswordValidator, + extraEditAccountInputs, + ), + ); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/addSession.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/addSession.md new file mode 100644 index 00000000..24fac35a --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/addSession.md @@ -0,0 +1,39 @@ + + + +# addSession method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +void addSession +([SessionWrapper](../../wyatt_authentication_bloc/SessionWrapper-class.md)<Data> wrapper) + +_override_ + + + +

Add a new authentication event.

+ + + +## Implementation + +```dart +@override +void addSession(SessionWrapper wrapper) => + authenticationRemoteDataSource.addSession(wrapper); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/authenticationRemoteDataSource.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/authenticationRemoteDataSource.md new file mode 100644 index 00000000..c5a64a53 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/authenticationRemoteDataSource.md @@ -0,0 +1,33 @@ + + + +# authenticationRemoteDataSource property + + + + + *[](https://dart.dev/null-safety)* + + + +[AuthenticationRemoteDataSource](../../wyatt_authentication_bloc/AuthenticationRemoteDataSource-class.md)<Data> authenticationRemoteDataSource + +_final_ + + + + + + +## Implementation + +```dart +final AuthenticationRemoteDataSource authenticationRemoteDataSource; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/confirmPasswordReset.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/confirmPasswordReset.md new file mode 100644 index 00000000..1d7641ae --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/confirmPasswordReset.md @@ -0,0 +1,51 @@ + + + +# confirmPasswordReset method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +FutureOrResult<void> confirmPasswordReset +({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) newPassword}) + +_override_ + + + +

Confirms the password reset with the provided newPassword and code.

+

Throws a ConfirmPasswordResetFailureInterface if an exception occurs.

+ + + +## Implementation + +```dart +@override +FutureOrResult confirmPasswordReset({ + required String code, + required String newPassword, +}) => + Result.tryCatchAsync( + () async { + await authenticationRemoteDataSource.confirmPasswordReset( + code: code, + newPassword: newPassword, + ); + }, + (error) => error, + ); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/delete.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/delete.md new file mode 100644 index 00000000..2275ccde --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/delete.md @@ -0,0 +1,44 @@ + + + +# delete method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +FutureOrResult<void> delete +() + +_override_ + + + +

Delete account.

+

Throws a DeleteAccountFailureInterface if +an exception occurs.

+ + + +## Implementation + +```dart +@override +FutureOrResult delete() => + Result.tryCatchAsync( + () async => authenticationRemoteDataSource.delete(), + (error) => error, + ); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/formRepository.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/formRepository.md new file mode 100644 index 00000000..d38908fe --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/formRepository.md @@ -0,0 +1,41 @@ + + + +# formRepository property + + + + + *[](https://dart.dev/null-safety)* + + + + + +**Annotations** + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) +FormRepository formRepository + +_override_ + + + +

Form repository used in different authentication cubits/blocs

+ + + +## Implementation + +```dart +@override +FormRepository get formRepository => _formRepository; +``` + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/reauthenticate.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/reauthenticate.md new file mode 100644 index 00000000..251168fb --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/reauthenticate.md @@ -0,0 +1,49 @@ + + + +# reauthenticate method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +FutureOrResult<[Account](../../wyatt_authentication_bloc/Account-class.md)> reauthenticate +() + +_override_ + + + +

Some security-sensitive actions—such as deleting an account, +setting a primary email address, and changing a password—require that +the user has recently signed in.

+

Throws a ReauthenticateFailureInterface if +an exception occurs.

+ + + +## Implementation + +```dart +@override +FutureOrResult reauthenticate() => + Result.tryCatchAsync( + () async { + final account = await authenticationRemoteDataSource.reauthenticate(); + return account; + }, + (error) => error, + ); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/refresh.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/refresh.md new file mode 100644 index 00000000..744850b4 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/refresh.md @@ -0,0 +1,45 @@ + + + +# refresh method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +FutureOrResult<[Account](../../wyatt_authentication_bloc/Account-class.md)> refresh +() + +_override_ + + + +

Refreshes the current user, if signed in.

+ + + +## Implementation + +```dart +@override +FutureOrResult refresh() => + Result.tryCatchAsync( + () async { + final account = await authenticationRemoteDataSource.refresh(); + return account; + }, + (error) => error, + ); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/sendEmailVerification.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/sendEmailVerification.md new file mode 100644 index 00000000..3b70fe5d --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/sendEmailVerification.md @@ -0,0 +1,45 @@ + + + +# sendEmailVerification method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +FutureOrResult<void> sendEmailVerification +() + +_override_ + + + +

Sends verification email to the account email.

+

Throws a SendEmailVerificationFailureInterface if an exception occurs.

+ + + +## Implementation + +```dart +@override +FutureOrResult sendEmailVerification() => + Result.tryCatchAsync( + () async { + await authenticationRemoteDataSource.sendEmailVerification(); + }, + (error) => error, + ); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/sendPasswordResetEmail.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/sendPasswordResetEmail.md new file mode 100644 index 00000000..df9cbe89 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/sendPasswordResetEmail.md @@ -0,0 +1,47 @@ + + + +# sendPasswordResetEmail method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +FutureOrResult<void> sendPasswordResetEmail +({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email}) + +_override_ + + + +

Sends a password reset email to the provided email.

+

Throws a SendPasswordResetEmailFailureInterface if an exception occurs.

+ + + +## Implementation + +```dart +@override +FutureOrResult sendPasswordResetEmail({required String email}) => + Result.tryCatchAsync( + () async { + await authenticationRemoteDataSource.sendPasswordResetEmail( + email: email, + ); + }, + (error) => error, + ); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/sessionStream.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/sessionStream.md new file mode 100644 index 00000000..33cab460 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/sessionStream.md @@ -0,0 +1,39 @@ + + + +# sessionStream method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[SessionWrapper](../../wyatt_authentication_bloc/SessionWrapper-class.md)<Data>> sessionStream +() + +_override_ + + + +

Authentication state change event stream.

+ + + +## Implementation + +```dart +@override +Stream> sessionStream() => + authenticationRemoteDataSource.sessionStream(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/signInAnonymously.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/signInAnonymously.md new file mode 100644 index 00000000..8dfc8cea --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/signInAnonymously.md @@ -0,0 +1,47 @@ + + + +# signInAnonymously method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +FutureOrResult<[Account](../../wyatt_authentication_bloc/Account-class.md)> signInAnonymously +() + +_override_ + + + +

Sign in anonymously.

+

Throws a SignInAnonymouslyFailureInterface if an exception occurs.

+ + + +## Implementation + +```dart +@override +FutureOrResult signInAnonymously() => + Result.tryCatchAsync( + () async { + final account = + await authenticationRemoteDataSource.signInAnonymously(); + return account; + }, + (error) => error, + ); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/signInWithEmailAndPassword.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/signInWithEmailAndPassword.md new file mode 100644 index 00000000..a42a7bab --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/signInWithEmailAndPassword.md @@ -0,0 +1,54 @@ + + + +# signInWithEmailAndPassword method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +FutureOrResult<[Account](../../wyatt_authentication_bloc/Account-class.md)> signInWithEmailAndPassword +({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) + +_override_ + + + +

Signs in with the provided email and password.

+

Throws a SignInWithEmailAndPasswordFailureInterface if +an exception occurs.

+ + + +## Implementation + +```dart +@override +FutureOrResult signInWithEmailAndPassword({ + required String email, + required String password, +}) => + Result.tryCatchAsync( + () async { + final account = + await authenticationRemoteDataSource.signInWithEmailAndPassword( + email: email, + password: password, + ); + return account; + }, + (error) => error, + ); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/signInWithGoogle.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/signInWithGoogle.md new file mode 100644 index 00000000..e6e5095d --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/signInWithGoogle.md @@ -0,0 +1,47 @@ + + + +# signInWithGoogle method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +FutureOrResult<[Account](../../wyatt_authentication_bloc/Account-class.md)> signInWithGoogle +() + +_override_ + + + +

Starts the Sign In with Google Flow.

+

Throws a SignInWithGoogleFailureInterface if an exception occurs.

+ + + +## Implementation + +```dart +@override +FutureOrResult signInWithGoogle() => + Result.tryCatchAsync( + () async { + final account = + await authenticationRemoteDataSource.signInWithGoogle(); + return account; + }, + (error) => error, + ); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/signOut.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/signOut.md new file mode 100644 index 00000000..5b83c76a --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/signOut.md @@ -0,0 +1,45 @@ + + + +# signOut method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +FutureOrResult<void> signOut +() + +_override_ + + + +

Signs out the current user. +It also clears the cache and the associated data.

+ + + +## Implementation + +```dart +@override +FutureOrResult signOut() => + Result.tryCatchAsync( + () async { + await authenticationRemoteDataSource.signOut(); + }, + (error) => error, + ); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/signUpWithEmailAndPassword.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/signUpWithEmailAndPassword.md new file mode 100644 index 00000000..5a0ce347 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/signUpWithEmailAndPassword.md @@ -0,0 +1,55 @@ + + + +# signUpWithEmailAndPassword method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +FutureOrResult<[Account](../../wyatt_authentication_bloc/Account-class.md)> signUpWithEmailAndPassword +({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) + +_override_ + + + +

Creates a new user with the provided email and password.

+

Returns the newly created user's unique identifier.

+

Throws a SignUpWithEmailAndPasswordFailureInterface if +an exception occurs.

+ + + +## Implementation + +```dart +@override +FutureOrResult signUpWithEmailAndPassword({ + required String email, + required String password, +}) => + Result.tryCatchAsync( + () async { + final account = + await authenticationRemoteDataSource.signUpWithEmailAndPassword( + email: email, + password: password, + ); + return account; + }, + (error) => error, + ); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/updateEmail.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/updateEmail.md new file mode 100644 index 00000000..89647f63 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/updateEmail.md @@ -0,0 +1,48 @@ + + + +# updateEmail method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +FutureOrResult<[Account](../../wyatt_authentication_bloc/Account-class.md)> updateEmail +({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email}) + +_override_ + + + +

Update or add email.

+

Throws a UpdateEmailFailureInterface if +an exception occurs.

+ + + +## Implementation + +```dart +@override +FutureOrResult updateEmail({required String email}) => + Result.tryCatchAsync( + () async { + final account = + await authenticationRemoteDataSource.updateEmail(email: email); + return account; + }, + (error) => error, + ); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/updatePassword.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/updatePassword.md new file mode 100644 index 00000000..3e839532 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/updatePassword.md @@ -0,0 +1,49 @@ + + + +# updatePassword method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +FutureOrResult<[Account](../../wyatt_authentication_bloc/Account-class.md)> updatePassword +({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) + +_override_ + + + +

Update or add password.

+

Throws a UpdatePasswordFailureInterface if +an exception occurs.

+ + + +## Implementation + +```dart +@override +FutureOrResult updatePassword({required String password}) => + Result.tryCatchAsync( + () async { + final account = await authenticationRemoteDataSource.updatePassword( + password: password, + ); + return account; + }, + (error) => error, + ); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/verifyPasswordResetCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/verifyPasswordResetCode.md new file mode 100644 index 00000000..6a2eae13 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/verifyPasswordResetCode.md @@ -0,0 +1,47 @@ + + + +# verifyPasswordResetCode method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +FutureOrResult<[bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)> verifyPasswordResetCode +({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) code}) + +_override_ + + + +

Verify password reset code.

+

Throws a VerifyPasswordResetCodeFailureInterface if an exception occurs.

+ + + +## Implementation + +```dart +@override +FutureOrResult verifyPasswordResetCode({required String code}) => + Result.tryCatchAsync( + () async { + final response = await authenticationRemoteDataSource + .verifyPasswordResetCode(code: code); + return response; + }, + (error) => error, + ); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState-class.md new file mode 100644 index 00000000..8b0c36ea --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState-class.md @@ -0,0 +1,150 @@ + + + +# AuthenticationState<Data> class + + + + + + + *[](https://dart.dev/null-safety)* + + + + + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [Equatable](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable-class.html) +- AuthenticationState + + + + + + + + +## Constructors + +[AuthenticationState.authenticated](../wyatt_authentication_bloc/AuthenticationState/AuthenticationState.authenticated.md) ([SessionWrapper](../wyatt_authentication_bloc/SessionWrapper-class.md)<Data> sessionWrapper) + + _const_ + +[AuthenticationState.unauthenticated](../wyatt_authentication_bloc/AuthenticationState/AuthenticationState.unauthenticated.md) () + + _const_ + +[AuthenticationState.unknown](../wyatt_authentication_bloc/AuthenticationState/AuthenticationState.unknown.md) () + + _const_ + + +## Properties + +##### [hashCode](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [props](../wyatt_authentication_bloc/AuthenticationState/props.md) → [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> + + + +The list of properties that will be used to determine whether +two instances are equal. +_read-onlyoverride_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + +##### [status](../wyatt_authentication_bloc/AuthenticationState/status.md) → [AuthenticationStatus](../wyatt_authentication_bloc/AuthenticationStatus.md) + + + + +_final_ + + + +##### [stringify](../wyatt_authentication_bloc/AuthenticationState/stringify.md) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)? + + + +If set to true, the toString method will be overridden to output +this instance's props. +_read-onlyoverride_ + + + +##### [wrapper](../wyatt_authentication_bloc/AuthenticationState/wrapper.md) → [SessionWrapper](../wyatt_authentication_bloc/SessionWrapper-class.md)<Data>? + + + + +_final_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/AuthenticationState.authenticated.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/AuthenticationState.authenticated.md new file mode 100644 index 00000000..d9f91abf --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/AuthenticationState.authenticated.md @@ -0,0 +1,34 @@ + + + +# AuthenticationState<Data>.authenticated constructor + + + + + *[](https://dart.dev/null-safety)* + + +const +AuthenticationState<Data>.authenticated([SessionWrapper](../../wyatt_authentication_bloc/SessionWrapper-class.md)<Data> sessionWrapper) + + + + + +## Implementation + +```dart +const AuthenticationState.authenticated(SessionWrapper sessionWrapper) + : this._( + AuthenticationStatus.authenticated, + sessionWrapper, + ); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/AuthenticationState.unauthenticated.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/AuthenticationState.unauthenticated.md new file mode 100644 index 00000000..e2bddab6 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/AuthenticationState.unauthenticated.md @@ -0,0 +1,31 @@ + + + +# AuthenticationState<Data>.unauthenticated constructor + + + + + *[](https://dart.dev/null-safety)* + + +const +AuthenticationState<Data>.unauthenticated() + + + + + +## Implementation + +```dart +const AuthenticationState.unauthenticated() + : this._(AuthenticationStatus.unauthenticated, null); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/AuthenticationState.unknown.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/AuthenticationState.unknown.md new file mode 100644 index 00000000..09ff10d9 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/AuthenticationState.unknown.md @@ -0,0 +1,31 @@ + + + +# AuthenticationState<Data>.unknown constructor + + + + + *[](https://dart.dev/null-safety)* + + +const +AuthenticationState<Data>.unknown() + + + + + +## Implementation + +```dart +const AuthenticationState.unknown() + : this._(AuthenticationStatus.unknown, null); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/props.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/props.md new file mode 100644 index 00000000..908ab81c --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/props.md @@ -0,0 +1,42 @@ + + + +# props property + + + + + *[](https://dart.dev/null-safety)* + + + + + +**Annotations** + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) +[List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> props + +_override_ + + + +

The list of properties that will be used to determine whether +two instances are equal.

+ + + +## Implementation + +```dart +@override +List get props => [status, wrapper]; +``` + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/status.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/status.md new file mode 100644 index 00000000..40efc5ec --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/status.md @@ -0,0 +1,33 @@ + + + +# status property + + + + + *[](https://dart.dev/null-safety)* + + + +[AuthenticationStatus](../../wyatt_authentication_bloc/AuthenticationStatus.md) status + +_final_ + + + + + + +## Implementation + +```dart +final AuthenticationStatus status; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/stringify.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/stringify.md new file mode 100644 index 00000000..d226dc33 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/stringify.md @@ -0,0 +1,47 @@ + + + +# stringify property + + + + + *[](https://dart.dev/null-safety)* + + + + + +**Annotations** + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) +[bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)? stringify + +_override_ + + + +

If set to true, the toString method will be overridden to output +this instance's props.

+

A global default value for stringify can be set using +EquatableConfig.stringify.

+

If this instance's stringify is set to null, the value of +EquatableConfig.stringify will be used instead. This defaults to +false.

+ + + +## Implementation + +```dart +@override +bool? get stringify => true; +``` + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/wrapper.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/wrapper.md new file mode 100644 index 00000000..cab7f3c8 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/wrapper.md @@ -0,0 +1,33 @@ + + + +# wrapper property + + + + + *[](https://dart.dev/null-safety)* + + + +[SessionWrapper](../../wyatt_authentication_bloc/SessionWrapper-class.md)<Data>? wrapper + +_final_ + + + + + + +## Implementation + +```dart +final SessionWrapper? wrapper; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationStatus.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationStatus.md new file mode 100644 index 00000000..2e76c5aa --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationStatus.md @@ -0,0 +1,151 @@ + + + +# AuthenticationStatus enum + + + + + *[](https://dart.dev/null-safety)* + + + +

Different authentication status

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [Enum](https://api.flutter.dev/flutter/dart-core/Enum-class.html) +- AuthenticationStatus + + + + + + +## Constructors + +[AuthenticationStatus](../wyatt_authentication_bloc/AuthenticationStatus/AuthenticationStatus.md) () + + _const_ + + +## Values + +##### [unknown](../wyatt_authentication_bloc/AuthenticationStatus.md) const [AuthenticationStatus](../wyatt_authentication_bloc/AuthenticationStatus.md) + + + +

At the application launch.

+ + + + +##### [authenticated](../wyatt_authentication_bloc/AuthenticationStatus.md) const [AuthenticationStatus](../wyatt_authentication_bloc/AuthenticationStatus.md) + + + +

When the user is logged

+ + + + +##### [unauthenticated](../wyatt_authentication_bloc/AuthenticationStatus.md) const [AuthenticationStatus](../wyatt_authentication_bloc/AuthenticationStatus.md) + + + +

When the user is not logged

+ + + + + +## Properties + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [index](https://api.flutter.dev/flutter/dart-core/Enum/index.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +A numeric identifier for the enumerated value. +_read-onlyinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + +## Constants + +##### [values](../wyatt_authentication_bloc/AuthenticationStatus/values-constant.md) const [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[AuthenticationStatus](../wyatt_authentication_bloc/AuthenticationStatus.md)> + + + +A constant List of the values in this enum, in order of their declaration. + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationStatus/AuthenticationStatus.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationStatus/AuthenticationStatus.md new file mode 100644 index 00000000..be2e4631 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationStatus/AuthenticationStatus.md @@ -0,0 +1,25 @@ + + + +# AuthenticationStatus constructor + + + + + *[](https://dart.dev/null-safety)* + + +const +AuthenticationStatus() + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationStatus/values-constant.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationStatus/values-constant.md new file mode 100644 index 00000000..9639a71a --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationStatus/values-constant.md @@ -0,0 +1,29 @@ + + + +# values constant + + + + + *[](https://dart.dev/null-safety)* + + + +[List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[AuthenticationStatus](../../wyatt_authentication_bloc/AuthenticationStatus.md)> const values + + + + + +

A constant List of the values in this enum, in order of their declaration.

+ + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit-class.md new file mode 100644 index 00000000..a1d6b8f8 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit-class.md @@ -0,0 +1,261 @@ + + + +# BaseEditAccountCubit<Data> class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Abstract edit account cubit useful for implementing a cubit with fine +granularity by adding only the required mixins.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [BlocBase](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase-class.html)<[EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md)> +- [Cubit](https://pub.dev/documentation/bloc/8.1.0/bloc/Cubit-class.html)<[EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md)> +- BaseEditAccountCubit + + + +**Implementers** + +- [EditAccountCubit](../wyatt_authentication_bloc/EditAccountCubit-class.md) + + + + + +## Constructors + +[BaseEditAccountCubit](../wyatt_authentication_bloc/BaseEditAccountCubit/BaseEditAccountCubit.md) ({required [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> authenticationRepository}) + + + + +## Properties + +##### [authenticationRepository](../wyatt_authentication_bloc/BaseEditAccountCubit/authenticationRepository.md) → [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> + + + + +_final_ + + + +##### [formName](../wyatt_authentication_bloc/BaseEditAccountCubit/formName.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-only_ + + + +##### [formRepository](../wyatt_authentication_bloc/BaseEditAccountCubit/formRepository.md) → FormRepository + + + + +_read-only_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [isClosed](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/isClosed.html) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +Whether the bloc is closed. +_read-onlyinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + +##### [state](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/state.html) → [EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md) + + + +The current state. +_read-onlyinherited_ + + + +##### [stream](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/stream.html) → [Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md)> + + + +The current stream of states. +_read-onlyinherited_ + + + + + +## Methods + +##### [addError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/addError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [[StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html)? stackTrace]) void + + + +Reports an error which triggers onError with an optional StackTrace. +_inherited_ + + + +##### [close](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/close.html)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> + + + +Closes the instance. +This method should be called when the instance is no longer needed. +Once close is called, the instance can no longer be used. +_inherited_ + + + +##### [dataChanged](../wyatt_authentication_bloc/BaseEditAccountCubit/dataChanged.md)<Value>([String](https://api.flutter.dev/flutter/dart-core/String-class.html) key, FormInputValidator<Value, ValidationError> dirtyValue) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + + + + + +##### [emit](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/emit.html)([EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md) state) void + + + +Updates the state to the provided state. +emit does nothing if the state being emitted +is equal to the current state. +_inherited_ + + + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [onChange](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onChange.html)([Change](https://pub.dev/documentation/bloc/8.1.0/bloc/Change-class.html)<[EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md)> change) void + + + +Called whenever a change occurs with the given change. +A change occurs when a new state is emitted. +onChange is called before the state of the cubit is updated. +onChange is a great spot to add logging/analytics for a specific cubit. +_inherited_ + + + +##### [onError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html) stackTrace) void + + + +Called whenever an error occurs and notifies BlocObserver.onError. +_inherited_ + + + +##### [reset](../wyatt_authentication_bloc/BaseEditAccountCubit/reset.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + + + + + +##### [submit](../wyatt_authentication_bloc/BaseEditAccountCubit/submit.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + + + + + +##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + +##### [update](../wyatt_authentication_bloc/BaseEditAccountCubit/update.md)(WyattForm form, {SetOperation operation = SetOperation.replace}) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + + + + + +##### [validate](../wyatt_authentication_bloc/BaseEditAccountCubit/validate.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + + + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/BaseEditAccountCubit.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/BaseEditAccountCubit.md new file mode 100644 index 00000000..8f85be67 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/BaseEditAccountCubit.md @@ -0,0 +1,37 @@ + + + +# BaseEditAccountCubit<Data> constructor + + + + + *[](https://dart.dev/null-safety)* + + + +BaseEditAccountCubit<Data>({required [AuthenticationRepository](../../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> authenticationRepository}) + + + + + +## Implementation + +```dart +BaseEditAccountCubit({ + required this.authenticationRepository, +}) : super( + EditAccountState( + form: authenticationRepository.formRepository + .accessForm(AuthFormName.signInForm), + ), + ); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/authenticationRepository.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/authenticationRepository.md new file mode 100644 index 00000000..32cdfa2a --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/authenticationRepository.md @@ -0,0 +1,33 @@ + + + +# authenticationRepository property + + + + + *[](https://dart.dev/null-safety)* + + + +[AuthenticationRepository](../../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> authenticationRepository + +_final_ + + + + + + +## Implementation + +```dart +final AuthenticationRepository authenticationRepository; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/dataChanged.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/dataChanged.md new file mode 100644 index 00000000..1748061e --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/dataChanged.md @@ -0,0 +1,53 @@ + + + +# dataChanged<Value> method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> dataChanged +<Value>([String](https://api.flutter.dev/flutter/dart-core/String-class.html) key, FormInputValidator<Value, ValidationError> dirtyValue) + + + + + + + + +## Implementation + +```dart +@override +FutureOr dataChanged( + String key, + FormInputValidator dirtyValue, +) { + final form = formRepository.accessForm(formName).clone(); + + try { + form.updateValidator(key, dirtyValue); + formRepository.updateForm(form); + } catch (e) { + rethrow; + } + + emit( + EditAccountState(form: form, status: form.validate()), + ); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/formName.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/formName.md new file mode 100644 index 00000000..3196e650 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/formName.md @@ -0,0 +1,40 @@ + + + +# formName property + + + + + *[](https://dart.dev/null-safety)* + + + + + +**Annotations** + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) +[String](https://api.flutter.dev/flutter/dart-core/String-class.html) formName + + + + + + + + +## Implementation + +```dart +@override +String get formName => AuthFormName.signInForm; +``` + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/formRepository.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/formRepository.md new file mode 100644 index 00000000..db8665dd --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/formRepository.md @@ -0,0 +1,36 @@ + + + +# formRepository property + + + + + *[](https://dart.dev/null-safety)* + + + + + +FormRepository formRepository + + + + + + + + +## Implementation + +```dart +FormRepository get formRepository => authenticationRepository.formRepository; +``` + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/reset.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/reset.md new file mode 100644 index 00000000..5344b5c4 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/reset.md @@ -0,0 +1,43 @@ + + + +# reset method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> reset +() + + + + + + + + +## Implementation + +```dart +@override +FutureOr reset() { + final form = state.form.reset(); + formRepository.updateForm(form); + emit( + EditAccountState(form: form, status: form.validate()), + ); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/submit.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/submit.md new file mode 100644 index 00000000..4ae4a062 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/submit.md @@ -0,0 +1,48 @@ + + + +# submit method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> submit +() + + + + + + + + +## Implementation + +```dart +@override +FutureOr submit() async { + final WyattForm form = formRepository.accessForm(formName); + const error = '`submit()` is not implemented for BaseEditAccountCubit, ' + 'please use `updateEmail()` or `updatePassword()`.'; + emit( + EditAccountState( + form: form, + errorMessage: error, + status: FormStatus.submissionFailure, + ), + ); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/update.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/update.md new file mode 100644 index 00000000..f0bb65a1 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/update.md @@ -0,0 +1,48 @@ + + + +# update method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> update +(WyattForm form, {SetOperation operation = SetOperation.replace}) + + + + + + + + +## Implementation + +```dart +@override +FutureOr update( + WyattForm form, { + SetOperation operation = SetOperation.replace, +}) { + final WyattForm current = formRepository.accessForm(formName).clone(); + final WyattForm newForm = operation.operation.call(current, form); + formRepository.updateForm(newForm); + + emit( + EditAccountState(form: newForm, status: newForm.validate()), + ); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/validate.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/validate.md new file mode 100644 index 00000000..73e17324 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/validate.md @@ -0,0 +1,42 @@ + + + +# validate method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> validate +() + + + + + + + + +## Implementation + +```dart +@override +FutureOr validate() { + final WyattForm form = formRepository.accessForm(formName); + emit( + EditAccountState(form: form, status: form.validate()), + ); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit-class.md new file mode 100644 index 00000000..d56382ff --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit-class.md @@ -0,0 +1,261 @@ + + + +# BaseSignInCubit<Data> class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Abstract sign in cubit useful for implementing a cubit with fine +granularity by adding only the required mixins.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [BlocBase](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase-class.html)<[SignInState](../wyatt_authentication_bloc/SignInState-class.md)> +- [Cubit](https://pub.dev/documentation/bloc/8.1.0/bloc/Cubit-class.html)<[SignInState](../wyatt_authentication_bloc/SignInState-class.md)> +- BaseSignInCubit + + + +**Implementers** + +- [SignInCubit](../wyatt_authentication_bloc/SignInCubit-class.md) + + + + + +## Constructors + +[BaseSignInCubit](../wyatt_authentication_bloc/BaseSignInCubit/BaseSignInCubit.md) ({required [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> authenticationRepository}) + + + + +## Properties + +##### [authenticationRepository](../wyatt_authentication_bloc/BaseSignInCubit/authenticationRepository.md) → [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> + + + + +_final_ + + + +##### [formName](../wyatt_authentication_bloc/BaseSignInCubit/formName.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-only_ + + + +##### [formRepository](../wyatt_authentication_bloc/BaseSignInCubit/formRepository.md) → FormRepository + + + + +_read-only_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [isClosed](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/isClosed.html) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +Whether the bloc is closed. +_read-onlyinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + +##### [state](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/state.html) → [SignInState](../wyatt_authentication_bloc/SignInState-class.md) + + + +The current state. +_read-onlyinherited_ + + + +##### [stream](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/stream.html) → [Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[SignInState](../wyatt_authentication_bloc/SignInState-class.md)> + + + +The current stream of states. +_read-onlyinherited_ + + + + + +## Methods + +##### [addError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/addError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [[StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html)? stackTrace]) void + + + +Reports an error which triggers onError with an optional StackTrace. +_inherited_ + + + +##### [close](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/close.html)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> + + + +Closes the instance. +This method should be called when the instance is no longer needed. +Once close is called, the instance can no longer be used. +_inherited_ + + + +##### [dataChanged](../wyatt_authentication_bloc/BaseSignInCubit/dataChanged.md)<Value>([String](https://api.flutter.dev/flutter/dart-core/String-class.html) key, FormInputValidator<Value, ValidationError> dirtyValue) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + + + + + +##### [emit](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/emit.html)([SignInState](../wyatt_authentication_bloc/SignInState-class.md) state) void + + + +Updates the state to the provided state. +emit does nothing if the state being emitted +is equal to the current state. +_inherited_ + + + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [onChange](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onChange.html)([Change](https://pub.dev/documentation/bloc/8.1.0/bloc/Change-class.html)<[SignInState](../wyatt_authentication_bloc/SignInState-class.md)> change) void + + + +Called whenever a change occurs with the given change. +A change occurs when a new state is emitted. +onChange is called before the state of the cubit is updated. +onChange is a great spot to add logging/analytics for a specific cubit. +_inherited_ + + + +##### [onError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html) stackTrace) void + + + +Called whenever an error occurs and notifies BlocObserver.onError. +_inherited_ + + + +##### [reset](../wyatt_authentication_bloc/BaseSignInCubit/reset.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + + + + + +##### [submit](../wyatt_authentication_bloc/BaseSignInCubit/submit.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + + + + + +##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + +##### [update](../wyatt_authentication_bloc/BaseSignInCubit/update.md)(WyattForm form, {SetOperation operation = SetOperation.replace}) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + + + + + +##### [validate](../wyatt_authentication_bloc/BaseSignInCubit/validate.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + + + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/BaseSignInCubit.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/BaseSignInCubit.md new file mode 100644 index 00000000..11cb730f --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/BaseSignInCubit.md @@ -0,0 +1,37 @@ + + + +# BaseSignInCubit<Data> constructor + + + + + *[](https://dart.dev/null-safety)* + + + +BaseSignInCubit<Data>({required [AuthenticationRepository](../../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> authenticationRepository}) + + + + + +## Implementation + +```dart +BaseSignInCubit({ + required this.authenticationRepository, +}) : super( + SignInState( + form: authenticationRepository.formRepository + .accessForm(AuthFormName.signInForm), + ), + ); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/authenticationRepository.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/authenticationRepository.md new file mode 100644 index 00000000..32cdfa2a --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/authenticationRepository.md @@ -0,0 +1,33 @@ + + + +# authenticationRepository property + + + + + *[](https://dart.dev/null-safety)* + + + +[AuthenticationRepository](../../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> authenticationRepository + +_final_ + + + + + + +## Implementation + +```dart +final AuthenticationRepository authenticationRepository; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/dataChanged.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/dataChanged.md new file mode 100644 index 00000000..2c85a80b --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/dataChanged.md @@ -0,0 +1,53 @@ + + + +# dataChanged<Value> method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> dataChanged +<Value>([String](https://api.flutter.dev/flutter/dart-core/String-class.html) key, FormInputValidator<Value, ValidationError> dirtyValue) + + + + + + + + +## Implementation + +```dart +@override +FutureOr dataChanged( + String key, + FormInputValidator dirtyValue, +) { + final form = formRepository.accessForm(formName).clone(); + + try { + form.updateValidator(key, dirtyValue); + formRepository.updateForm(form); + } catch (e) { + rethrow; + } + + emit( + SignInState(form: form, status: form.validate()), + ); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/formName.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/formName.md new file mode 100644 index 00000000..3196e650 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/formName.md @@ -0,0 +1,40 @@ + + + +# formName property + + + + + *[](https://dart.dev/null-safety)* + + + + + +**Annotations** + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) +[String](https://api.flutter.dev/flutter/dart-core/String-class.html) formName + + + + + + + + +## Implementation + +```dart +@override +String get formName => AuthFormName.signInForm; +``` + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/formRepository.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/formRepository.md new file mode 100644 index 00000000..db8665dd --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/formRepository.md @@ -0,0 +1,36 @@ + + + +# formRepository property + + + + + *[](https://dart.dev/null-safety)* + + + + + +FormRepository formRepository + + + + + + + + +## Implementation + +```dart +FormRepository get formRepository => authenticationRepository.formRepository; +``` + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/reset.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/reset.md new file mode 100644 index 00000000..5d78a829 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/reset.md @@ -0,0 +1,43 @@ + + + +# reset method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> reset +() + + + + + + + + +## Implementation + +```dart +@override +FutureOr reset() { + final form = state.form.reset(); + formRepository.updateForm(form); + emit( + SignInState(form: form, status: form.validate()), + ); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/submit.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/submit.md new file mode 100644 index 00000000..69de04c2 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/submit.md @@ -0,0 +1,48 @@ + + + +# submit method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> submit +() + + + + + + + + +## Implementation + +```dart +@override +FutureOr submit() async { + final WyattForm form = formRepository.accessForm(formName); + const error = '`submit()` is not implemented for BaseSignInCubit, ' + 'please use `signUpWithEmailAndPassword()`.'; + emit( + SignInState( + form: form, + errorMessage: error, + status: FormStatus.submissionFailure, + ), + ); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/update.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/update.md new file mode 100644 index 00000000..d37c336c --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/update.md @@ -0,0 +1,48 @@ + + + +# update method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> update +(WyattForm form, {SetOperation operation = SetOperation.replace}) + + + + + + + + +## Implementation + +```dart +@override +FutureOr update( + WyattForm form, { + SetOperation operation = SetOperation.replace, +}) { + final WyattForm current = formRepository.accessForm(formName).clone(); + final WyattForm newForm = operation.operation.call(current, form); + formRepository.updateForm(newForm); + + emit( + SignInState(form: newForm, status: newForm.validate()), + ); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/validate.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/validate.md new file mode 100644 index 00000000..8dbc20d1 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/validate.md @@ -0,0 +1,42 @@ + + + +# validate method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> validate +() + + + + + + + + +## Implementation + +```dart +@override +FutureOr validate() { + final WyattForm form = formRepository.accessForm(formName); + emit( + SignInState(form: form, status: form.validate()), + ); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit-class.md new file mode 100644 index 00000000..4bf08947 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit-class.md @@ -0,0 +1,261 @@ + + + +# BaseSignUpCubit<Data> class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Abstract sign up cubit useful for implementing a cubit with fine +granularity by adding only the required mixins.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [BlocBase](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase-class.html)<[SignUpState](../wyatt_authentication_bloc/SignUpState-class.md)> +- [Cubit](https://pub.dev/documentation/bloc/8.1.0/bloc/Cubit-class.html)<[SignUpState](../wyatt_authentication_bloc/SignUpState-class.md)> +- BaseSignUpCubit + + + +**Implementers** + +- [SignUpCubit](../wyatt_authentication_bloc/SignUpCubit-class.md) + + + + + +## Constructors + +[BaseSignUpCubit](../wyatt_authentication_bloc/BaseSignUpCubit/BaseSignUpCubit.md) ({required [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> authenticationRepository}) + + + + +## Properties + +##### [authenticationRepository](../wyatt_authentication_bloc/BaseSignUpCubit/authenticationRepository.md) → [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> + + + + +_final_ + + + +##### [formName](../wyatt_authentication_bloc/BaseSignUpCubit/formName.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-only_ + + + +##### [formRepository](../wyatt_authentication_bloc/BaseSignUpCubit/formRepository.md) → FormRepository + + + + +_read-only_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [isClosed](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/isClosed.html) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +Whether the bloc is closed. +_read-onlyinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + +##### [state](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/state.html) → [SignUpState](../wyatt_authentication_bloc/SignUpState-class.md) + + + +The current state. +_read-onlyinherited_ + + + +##### [stream](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/stream.html) → [Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[SignUpState](../wyatt_authentication_bloc/SignUpState-class.md)> + + + +The current stream of states. +_read-onlyinherited_ + + + + + +## Methods + +##### [addError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/addError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [[StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html)? stackTrace]) void + + + +Reports an error which triggers onError with an optional StackTrace. +_inherited_ + + + +##### [close](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/close.html)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> + + + +Closes the instance. +This method should be called when the instance is no longer needed. +Once close is called, the instance can no longer be used. +_inherited_ + + + +##### [dataChanged](../wyatt_authentication_bloc/BaseSignUpCubit/dataChanged.md)<Value>([String](https://api.flutter.dev/flutter/dart-core/String-class.html) key, FormInputValidator<Value, ValidationError> dirtyValue) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + + + + + +##### [emit](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/emit.html)([SignUpState](../wyatt_authentication_bloc/SignUpState-class.md) state) void + + + +Updates the state to the provided state. +emit does nothing if the state being emitted +is equal to the current state. +_inherited_ + + + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [onChange](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onChange.html)([Change](https://pub.dev/documentation/bloc/8.1.0/bloc/Change-class.html)<[SignUpState](../wyatt_authentication_bloc/SignUpState-class.md)> change) void + + + +Called whenever a change occurs with the given change. +A change occurs when a new state is emitted. +onChange is called before the state of the cubit is updated. +onChange is a great spot to add logging/analytics for a specific cubit. +_inherited_ + + + +##### [onError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html) stackTrace) void + + + +Called whenever an error occurs and notifies BlocObserver.onError. +_inherited_ + + + +##### [reset](../wyatt_authentication_bloc/BaseSignUpCubit/reset.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + + + + + +##### [submit](../wyatt_authentication_bloc/BaseSignUpCubit/submit.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + + + + + +##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + +##### [update](../wyatt_authentication_bloc/BaseSignUpCubit/update.md)(WyattForm form, {SetOperation operation = SetOperation.replace}) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + + + + + +##### [validate](../wyatt_authentication_bloc/BaseSignUpCubit/validate.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + + + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/BaseSignUpCubit.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/BaseSignUpCubit.md new file mode 100644 index 00000000..00958987 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/BaseSignUpCubit.md @@ -0,0 +1,37 @@ + + + +# BaseSignUpCubit<Data> constructor + + + + + *[](https://dart.dev/null-safety)* + + + +BaseSignUpCubit<Data>({required [AuthenticationRepository](../../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> authenticationRepository}) + + + + + +## Implementation + +```dart +BaseSignUpCubit({ + required this.authenticationRepository, +}) : super( + SignUpState( + form: authenticationRepository.formRepository + .accessForm(AuthFormName.signUpForm), + ), + ); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/authenticationRepository.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/authenticationRepository.md new file mode 100644 index 00000000..32cdfa2a --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/authenticationRepository.md @@ -0,0 +1,33 @@ + + + +# authenticationRepository property + + + + + *[](https://dart.dev/null-safety)* + + + +[AuthenticationRepository](../../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> authenticationRepository + +_final_ + + + + + + +## Implementation + +```dart +final AuthenticationRepository authenticationRepository; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/dataChanged.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/dataChanged.md new file mode 100644 index 00000000..8583e9da --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/dataChanged.md @@ -0,0 +1,53 @@ + + + +# dataChanged<Value> method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> dataChanged +<Value>([String](https://api.flutter.dev/flutter/dart-core/String-class.html) key, FormInputValidator<Value, ValidationError> dirtyValue) + + + + + + + + +## Implementation + +```dart +@override +FutureOr dataChanged( + String key, + FormInputValidator dirtyValue, +) { + final form = formRepository.accessForm(formName).clone(); + + try { + form.updateValidator(key, dirtyValue); + formRepository.updateForm(form); + } catch (e) { + rethrow; + } + + emit( + SignUpState(form: form, status: form.validate()), + ); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/formName.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/formName.md new file mode 100644 index 00000000..f79689dd --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/formName.md @@ -0,0 +1,40 @@ + + + +# formName property + + + + + *[](https://dart.dev/null-safety)* + + + + + +**Annotations** + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) +[String](https://api.flutter.dev/flutter/dart-core/String-class.html) formName + + + + + + + + +## Implementation + +```dart +@override +String get formName => AuthFormName.signUpForm; +``` + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/formRepository.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/formRepository.md new file mode 100644 index 00000000..db8665dd --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/formRepository.md @@ -0,0 +1,36 @@ + + + +# formRepository property + + + + + *[](https://dart.dev/null-safety)* + + + + + +FormRepository formRepository + + + + + + + + +## Implementation + +```dart +FormRepository get formRepository => authenticationRepository.formRepository; +``` + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/reset.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/reset.md new file mode 100644 index 00000000..621867ee --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/reset.md @@ -0,0 +1,43 @@ + + + +# reset method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> reset +() + + + + + + + + +## Implementation + +```dart +@override +FutureOr reset() { + final form = state.form.reset(); + formRepository.updateForm(form); + emit( + SignUpState(form: form, status: form.validate()), + ); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/submit.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/submit.md new file mode 100644 index 00000000..b9699be7 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/submit.md @@ -0,0 +1,49 @@ + + + +# submit method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> submit +() + + + + + + + + +## Implementation + +```dart +@override +FutureOr submit() async { + final WyattForm form = formRepository.accessForm(formName); + const error = '`submit()` is not implemented for BaseSignUpCubit, ' + 'please use `signUpWithEmailAndPassword()`.'; + emit( + SignUpState( + form: form, + errorMessage: error, + status: FormStatus.submissionFailure, + ), + ); + throw UnimplementedError(error); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/update.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/update.md new file mode 100644 index 00000000..9cd644a4 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/update.md @@ -0,0 +1,51 @@ + + + +# update method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> update +(WyattForm form, {SetOperation operation = SetOperation.replace}) + + + + + + + + +## Implementation + +```dart +@override +FutureOr update( + WyattForm form, { + SetOperation operation = SetOperation.replace, +}) { + final WyattForm current = formRepository.accessForm(formName).clone(); + final WyattForm newForm = operation.operation.call(current, form); + formRepository.updateForm(newForm); + + emit( + SignUpState( + form: newForm, + status: newForm.validate(), + ), + ); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/validate.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/validate.md new file mode 100644 index 00000000..1eeceb04 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/validate.md @@ -0,0 +1,42 @@ + + + +# validate method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> validate +() + + + + + + + + +## Implementation + +```dart +@override +FutureOr validate() { + final WyattForm form = formRepository.accessForm(formName); + emit( + SignUpState(form: form, status: form.validate()), + ); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BuildContextExtension.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BuildContextExtension.md new file mode 100644 index 00000000..6ee49aa0 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BuildContextExtension.md @@ -0,0 +1,76 @@ + + + +# BuildContextExtension extension +on [BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) + + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Extension that helps to quickly access useful resources like wrapper, +session, account or data.

+ + + + + + +## Methods + +##### [account](../wyatt_authentication_bloc/BuildContextExtension/account.md)<T extends [AuthenticationCubit](../wyatt_authentication_bloc/AuthenticationCubit-class.md)<Data>, Data>() [Account](../wyatt_authentication_bloc/Account-class.md)? + + + +Returns account + + + + +##### [data](../wyatt_authentication_bloc/BuildContextExtension/data.md)<T extends [AuthenticationCubit](../wyatt_authentication_bloc/AuthenticationCubit-class.md)<Data>, Data>() Data? + + + +Returns associated data + + + + +##### [session](../wyatt_authentication_bloc/BuildContextExtension/session.md)<T extends [AuthenticationCubit](../wyatt_authentication_bloc/AuthenticationCubit-class.md)<Data>, Data>() [Session](../wyatt_authentication_bloc/Session-class.md)<Data>? + + + +Returns session + + + + +##### [wrapper](../wyatt_authentication_bloc/BuildContextExtension/wrapper.md)<T extends [AuthenticationCubit](../wyatt_authentication_bloc/AuthenticationCubit-class.md)<Data>, Data>() [SessionWrapper](../wyatt_authentication_bloc/SessionWrapper-class.md)<Data>? + + + +Returns session wrapper + + + + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BuildContextExtension/account.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BuildContextExtension/account.md new file mode 100644 index 00000000..d0f51a1f --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BuildContextExtension/account.md @@ -0,0 +1,37 @@ + + + +# account<T extends AuthenticationCubit<Data>, Data> method + + + + + *[](https://dart.dev/null-safety)* + + + + +[Account](../../wyatt_authentication_bloc/Account-class.md)? account +<T extends AuthenticationCubit<Data>, Data>() + + + + + +

Returns account

+ + + +## Implementation + +```dart +Account? account, Data>() => + watch().currentSession()?.session?.account; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BuildContextExtension/data.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BuildContextExtension/data.md new file mode 100644 index 00000000..1958e209 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BuildContextExtension/data.md @@ -0,0 +1,37 @@ + + + +# data<T extends AuthenticationCubit<Data>, Data> method + + + + + *[](https://dart.dev/null-safety)* + + + + +Data? data +<T extends AuthenticationCubit<Data>, Data>() + + + + + +

Returns associated data

+ + + +## Implementation + +```dart +Data? data, Data>() => + watch().currentSession()?.session?.data; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BuildContextExtension/session.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BuildContextExtension/session.md new file mode 100644 index 00000000..2d5d16b1 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BuildContextExtension/session.md @@ -0,0 +1,37 @@ + + + +# session<T extends AuthenticationCubit<Data>, Data> method + + + + + *[](https://dart.dev/null-safety)* + + + + +[Session](../../wyatt_authentication_bloc/Session-class.md)<Data>? session +<T extends AuthenticationCubit<Data>, Data>() + + + + + +

Returns session

+ + + +## Implementation + +```dart +Session? session, Data>() => + watch().currentSession()?.session; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BuildContextExtension/wrapper.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BuildContextExtension/wrapper.md new file mode 100644 index 00000000..edeb2c9e --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BuildContextExtension/wrapper.md @@ -0,0 +1,37 @@ + + + +# wrapper<T extends AuthenticationCubit<Data>, Data> method + + + + + *[](https://dart.dev/null-safety)* + + + + +[SessionWrapper](../../wyatt_authentication_bloc/SessionWrapper-class.md)<Data>? wrapper +<T extends AuthenticationCubit<Data>, Data>() + + + + + +

Returns session wrapper

+ + + +## Implementation + +```dart +SessionWrapper? wrapper, Data>() => + watch().currentSession(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ConfirmPasswordResetFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ConfirmPasswordResetFailureFirebase-class.md new file mode 100644 index 00000000..a9608f3c --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ConfirmPasswordResetFailureFirebase-class.md @@ -0,0 +1,137 @@ + + + +# ConfirmPasswordResetFailureFirebase class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown during the password reset process if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- [ConfirmPasswordResetFailureInterface](../wyatt_authentication_bloc/ConfirmPasswordResetFailureInterface-class.md) +- ConfirmPasswordResetFailureFirebase + + + + + + + + +## Constructors + +[ConfirmPasswordResetFailureFirebase](../wyatt_authentication_bloc/ConfirmPasswordResetFailureFirebase/ConfirmPasswordResetFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + +[ConfirmPasswordResetFailureFirebase.fromCode](../wyatt_authentication_bloc/ConfirmPasswordResetFailureFirebase/ConfirmPasswordResetFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ConfirmPasswordResetFailureFirebase/ConfirmPasswordResetFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ConfirmPasswordResetFailureFirebase/ConfirmPasswordResetFailureFirebase.fromCode.md new file mode 100644 index 00000000..4d51aa2d --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ConfirmPasswordResetFailureFirebase/ConfirmPasswordResetFailureFirebase.fromCode.md @@ -0,0 +1,30 @@ + + + +# ConfirmPasswordResetFailureFirebase.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +ConfirmPasswordResetFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + + +## Implementation + +```dart +ConfirmPasswordResetFailureFirebase.fromCode(super.code) : super.fromCode(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ConfirmPasswordResetFailureFirebase/ConfirmPasswordResetFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ConfirmPasswordResetFailureFirebase/ConfirmPasswordResetFailureFirebase.md new file mode 100644 index 00000000..97e8c31a --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ConfirmPasswordResetFailureFirebase/ConfirmPasswordResetFailureFirebase.md @@ -0,0 +1,31 @@ + + + +# ConfirmPasswordResetFailureFirebase constructor + + + + + *[](https://dart.dev/null-safety)* + + + +ConfirmPasswordResetFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + + + +## Implementation + +```dart +ConfirmPasswordResetFailureFirebase([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ConfirmPasswordResetFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ConfirmPasswordResetFailureInterface-class.md new file mode 100644 index 00000000..29578d9c --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ConfirmPasswordResetFailureInterface-class.md @@ -0,0 +1,139 @@ + + + +# ConfirmPasswordResetFailureInterface class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown during the password reset process if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- ConfirmPasswordResetFailureInterface + + + +**Implementers** + +- [ConfirmPasswordResetFailureFirebase](../wyatt_authentication_bloc/ConfirmPasswordResetFailureFirebase-class.md) + + + + + +## Constructors + +[ConfirmPasswordResetFailureInterface](../wyatt_authentication_bloc/ConfirmPasswordResetFailureInterface/ConfirmPasswordResetFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + +Thrown during the password reset process if a failure occurs. + +[ConfirmPasswordResetFailureInterface.fromCode](../wyatt_authentication_bloc/ConfirmPasswordResetFailureInterface/ConfirmPasswordResetFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + +Thrown during the password reset process if a failure occurs. + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ConfirmPasswordResetFailureInterface/ConfirmPasswordResetFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ConfirmPasswordResetFailureInterface/ConfirmPasswordResetFailureInterface.fromCode.md new file mode 100644 index 00000000..c0177f60 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ConfirmPasswordResetFailureInterface/ConfirmPasswordResetFailureInterface.fromCode.md @@ -0,0 +1,31 @@ + + + +# ConfirmPasswordResetFailureInterface.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +ConfirmPasswordResetFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + +

Thrown during the password reset process if a failure occurs.

+ + + +## Implementation + +```dart +ConfirmPasswordResetFailureInterface.fromCode(super.code) : super.fromCode(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ConfirmPasswordResetFailureInterface/ConfirmPasswordResetFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ConfirmPasswordResetFailureInterface/ConfirmPasswordResetFailureInterface.md new file mode 100644 index 00000000..585e23fc --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ConfirmPasswordResetFailureInterface/ConfirmPasswordResetFailureInterface.md @@ -0,0 +1,31 @@ + + + +# ConfirmPasswordResetFailureInterface constructor + + + + + *[](https://dart.dev/null-safety)* + + + +ConfirmPasswordResetFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + + +

Thrown during the password reset process if a failure occurs.

+ + + +## Implementation + +```dart +ConfirmPasswordResetFailureInterface(super.code, super.msg); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine-class.md new file mode 100644 index 00000000..8d140161 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine-class.md @@ -0,0 +1,139 @@ + + + +# CustomRoutine<R, Data> class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Calls on each cubit action of this package.

+

Useful to register custom logic on pre-implemented logic.

+ + + + +## Constructors + +[CustomRoutine](../wyatt_authentication_bloc/CustomRoutine/CustomRoutine.md) ({required [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<Result<R, AppException>> routine(), required [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<Result<Data?, AppException>> attachedLogic(Result<R, AppException> routineResult), required void onError(AppException exception), required void onSuccess(R result, Data? data)}) + + _const_ + + +## Properties + +##### [attachedLogic](../wyatt_authentication_bloc/CustomRoutine/attachedLogic.md) → [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<Result<Data?, AppException>> Function(Result<R, AppException> routineResult) + + + + +_final_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [onError](../wyatt_authentication_bloc/CustomRoutine/onError.md) → void Function(AppException exception) + + + + +_final_ + + + +##### [onSuccess](../wyatt_authentication_bloc/CustomRoutine/onSuccess.md) → void Function(R result, Data? data) + + + + +_final_ + + + +##### [routine](../wyatt_authentication_bloc/CustomRoutine/routine.md) → [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<Result<R, AppException>> Function() + + + + +_final_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [call](../wyatt_authentication_bloc/CustomRoutine/call.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + + + + + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine/CustomRoutine.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine/CustomRoutine.md new file mode 100644 index 00000000..4e771554 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine/CustomRoutine.md @@ -0,0 +1,35 @@ + + + +# CustomRoutine<R, Data> constructor + + + + + *[](https://dart.dev/null-safety)* + + +const +CustomRoutine<R, Data>({required [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<Result<R, AppException>> routine(), required [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<Result<Data?, AppException>> attachedLogic(Result<R, AppException> routineResult), required void onError(AppException exception), required void onSuccess(R result, Data? data)}) + + + + + +## Implementation + +```dart +const CustomRoutine({ + required this.routine, + required this.attachedLogic, + required this.onError, + required this.onSuccess, +}); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine/attachedLogic.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine/attachedLogic.md new file mode 100644 index 00000000..0486eb86 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine/attachedLogic.md @@ -0,0 +1,35 @@ + + + +# attachedLogic property + + + + + *[](https://dart.dev/null-safety)* + + + +[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<Result<Data?, AppException>> Function(Result<R, AppException> routineResult) attachedLogic + +_final_ + + + + + + +## Implementation + +```dart +final FutureOr> Function( + Result routineResult, +) attachedLogic; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine/call.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine/call.md new file mode 100644 index 00000000..a03b3b8b --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine/call.md @@ -0,0 +1,55 @@ + + + +# call method + + + + + *[](https://dart.dev/null-safety)* + + + + +[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> call +() + + + + + + + + +## Implementation + +```dart +FutureOr call() async { + final result = await routine.call(); + + // Call custom logic + final customRoutineResult = await attachedLogic.call(result); + + // Check for errors + if (result.isErr) { + onError.call(result.err!); + + return; + } + if (customRoutineResult.isErr) { + onError.call(customRoutineResult.err!); + + return; + } + + // If no error + return onSuccess.call(result.ok as R, customRoutineResult.ok); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine/onError.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine/onError.md new file mode 100644 index 00000000..540b3834 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine/onError.md @@ -0,0 +1,33 @@ + + + +# onError property + + + + + *[](https://dart.dev/null-safety)* + + + +void Function(AppException exception) onError + +_final_ + + + + + + +## Implementation + +```dart +final void Function(AppException exception) onError; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine/onSuccess.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine/onSuccess.md new file mode 100644 index 00000000..0232c8c7 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine/onSuccess.md @@ -0,0 +1,33 @@ + + + +# onSuccess property + + + + + *[](https://dart.dev/null-safety)* + + + +void Function(R result, Data? data) onSuccess + +_final_ + + + + + + +## Implementation + +```dart +final void Function(R result, Data? data) onSuccess; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine/routine.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine/routine.md new file mode 100644 index 00000000..9359edea --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine/routine.md @@ -0,0 +1,33 @@ + + + +# routine property + + + + + *[](https://dart.dev/null-safety)* + + + +[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<Result<R, AppException>> Function() routine + +_final_ + + + + + + +## Implementation + +```dart +final FutureOr> Function() routine; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeleteAccountFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeleteAccountFailureFirebase-class.md new file mode 100644 index 00000000..b7283c93 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeleteAccountFailureFirebase-class.md @@ -0,0 +1,137 @@ + + + +# DeleteAccountFailureFirebase class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown during the account deletion if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- [DeleteAccountFailureInterface](../wyatt_authentication_bloc/DeleteAccountFailureInterface-class.md) +- DeleteAccountFailureFirebase + + + + + + + + +## Constructors + +[DeleteAccountFailureFirebase](../wyatt_authentication_bloc/DeleteAccountFailureFirebase/DeleteAccountFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + +[DeleteAccountFailureFirebase.fromCode](../wyatt_authentication_bloc/DeleteAccountFailureFirebase/DeleteAccountFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeleteAccountFailureFirebase/DeleteAccountFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeleteAccountFailureFirebase/DeleteAccountFailureFirebase.fromCode.md new file mode 100644 index 00000000..8c43e144 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeleteAccountFailureFirebase/DeleteAccountFailureFirebase.fromCode.md @@ -0,0 +1,39 @@ + + + +# DeleteAccountFailureFirebase.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +DeleteAccountFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + + +## Implementation + +```dart +DeleteAccountFailureFirebase.fromCode(String code) : super.fromCode(code) { + switch (code) { + case 'requires-recent-login': + msg = "User's last sign-in time does not meet the security threshold."; + break; + default: + this.code = 'unknown'; + msg = 'An unknown error occurred.'; + } +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeleteAccountFailureFirebase/DeleteAccountFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeleteAccountFailureFirebase/DeleteAccountFailureFirebase.md new file mode 100644 index 00000000..e9be7130 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeleteAccountFailureFirebase/DeleteAccountFailureFirebase.md @@ -0,0 +1,31 @@ + + + +# DeleteAccountFailureFirebase constructor + + + + + *[](https://dart.dev/null-safety)* + + + +DeleteAccountFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + + + +## Implementation + +```dart +DeleteAccountFailureFirebase([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeleteAccountFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeleteAccountFailureInterface-class.md new file mode 100644 index 00000000..78a6a6f7 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeleteAccountFailureInterface-class.md @@ -0,0 +1,139 @@ + + + +# DeleteAccountFailureInterface class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown during the account deletion if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- DeleteAccountFailureInterface + + + +**Implementers** + +- [DeleteAccountFailureFirebase](../wyatt_authentication_bloc/DeleteAccountFailureFirebase-class.md) + + + + + +## Constructors + +[DeleteAccountFailureInterface](../wyatt_authentication_bloc/DeleteAccountFailureInterface/DeleteAccountFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + + + +[DeleteAccountFailureInterface.fromCode](../wyatt_authentication_bloc/DeleteAccountFailureInterface/DeleteAccountFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeleteAccountFailureInterface/DeleteAccountFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeleteAccountFailureInterface/DeleteAccountFailureInterface.fromCode.md new file mode 100644 index 00000000..7e18dc37 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeleteAccountFailureInterface/DeleteAccountFailureInterface.fromCode.md @@ -0,0 +1,30 @@ + + + +# DeleteAccountFailureInterface.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +DeleteAccountFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + + +## Implementation + +```dart +DeleteAccountFailureInterface.fromCode(super.code) : super.fromCode(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeleteAccountFailureInterface/DeleteAccountFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeleteAccountFailureInterface/DeleteAccountFailureInterface.md new file mode 100644 index 00000000..09759d9d --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeleteAccountFailureInterface/DeleteAccountFailureInterface.md @@ -0,0 +1,30 @@ + + + +# DeleteAccountFailureInterface constructor + + + + + *[](https://dart.dev/null-safety)* + + + +DeleteAccountFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + + + + + +## Implementation + +```dart +DeleteAccountFailureInterface(super.code, super.msg); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeletedEvent-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeletedEvent-class.md new file mode 100644 index 00000000..9ada8b22 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeletedEvent-class.md @@ -0,0 +1,126 @@ + + + +# DeletedEvent class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

When a user deleted his account.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [Equatable](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable-class.html) +- [AuthenticationChangeEvent](../wyatt_authentication_bloc/AuthenticationChangeEvent-class.md) +- DeletedEvent + + + + + + + + +## Constructors + +[DeletedEvent](../wyatt_authentication_bloc/DeletedEvent/DeletedEvent.md) () + + _const_ + + +## Properties + +##### [hashCode](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [props](../wyatt_authentication_bloc/AuthenticationChangeEvent/props.md) → [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> + + + +The list of properties that will be used to determine whether +two instances are equal. +_read-onlyinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + +##### [stringify](../wyatt_authentication_bloc/AuthenticationChangeEvent/stringify.md) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +If set to true, the toString method will be overridden to output +this instance's props. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeletedEvent/DeletedEvent.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeletedEvent/DeletedEvent.md new file mode 100644 index 00000000..3d031272 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeletedEvent/DeletedEvent.md @@ -0,0 +1,30 @@ + + + +# DeletedEvent constructor + + + + + *[](https://dart.dev/null-safety)* + + +const +DeletedEvent() + + + + + +## Implementation + +```dart +const DeletedEvent(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountCubit-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountCubit-class.md new file mode 100644 index 00000000..34e20299 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountCubit-class.md @@ -0,0 +1,335 @@ + + + +# EditAccountCubit<Data> class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Fully featured edit account cubit.

+

Sufficient in most cases. (Where fine granularity is not required.)

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [BlocBase](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase-class.html)<[EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md)> +- [Cubit](https://pub.dev/documentation/bloc/8.1.0/bloc/Cubit-class.html)<[EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md)> +- [BaseEditAccountCubit](../wyatt_authentication_bloc/BaseEditAccountCubit-class.md)<Data> +- EditAccountCubit + + +**Mixed in types** + +- [UpdateEmail](../wyatt_authentication_bloc/UpdateEmail-mixin.md)<Data> +- [UpdatePassword](../wyatt_authentication_bloc/UpdatePassword-mixin.md)<Data> + + + + + + +## Constructors + +[EditAccountCubit](../wyatt_authentication_bloc/EditAccountCubit/EditAccountCubit.md) ({required [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> authenticationRepository}) + + + + +## Properties + +##### [authenticationRepository](../wyatt_authentication_bloc/BaseEditAccountCubit/authenticationRepository.md) → [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> + + + + +_finalinherited_ + + + +##### [formName](../wyatt_authentication_bloc/BaseEditAccountCubit/formName.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [formRepository](../wyatt_authentication_bloc/BaseEditAccountCubit/formRepository.md) → FormRepository + + + + +_read-onlyinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [isClosed](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/isClosed.html) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +Whether the bloc is closed. +_read-onlyinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + +##### [state](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/state.html) → [EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md) + + + +The current state. +_read-onlyinherited_ + + + +##### [stream](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/stream.html) → [Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md)> + + + +The current stream of states. +_read-onlyinherited_ + + + + + +## Methods + +##### [addError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/addError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [[StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html)? stackTrace]) void + + + +Reports an error which triggers onError with an optional StackTrace. +_inherited_ + + + +##### [close](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/close.html)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> + + + +Closes the instance. +This method should be called when the instance is no longer needed. +Once close is called, the instance can no longer be used. +_inherited_ + + + +##### [dataChanged](../wyatt_authentication_bloc/BaseEditAccountCubit/dataChanged.md)<Value>([String](https://api.flutter.dev/flutter/dart-core/String-class.html) key, FormInputValidator<Value, ValidationError> dirtyValue) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + +##### [emailChanged](../wyatt_authentication_bloc/UpdateEmail/emailChanged.md)([String](https://api.flutter.dev/flutter/dart-core/String-class.html) value) void + + + + +_inherited_ + + + +##### [emailCustomChanged](../wyatt_authentication_bloc/UpdateEmail/emailCustomChanged.md)<Validator extends FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError>>(Validator validator) void + + + +Same as emailChanged but with a custom Validator. +_inherited_ + + + +##### [emit](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/emit.html)([EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md) state) void + + + +Updates the state to the provided state. +emit does nothing if the state being emitted +is equal to the current state. +_inherited_ + + + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [onChange](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onChange.html)([Change](https://pub.dev/documentation/bloc/8.1.0/bloc/Change-class.html)<[EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md)> change) void + + + +Called whenever a change occurs with the given change. +A change occurs when a new state is emitted. +onChange is called before the state of the cubit is updated. +onChange is a great spot to add logging/analytics for a specific cubit. +_inherited_ + + + +##### [onEmailUpdated](../wyatt_authentication_bloc/EditAccountCubit/onEmailUpdated.md)(Result<[Account](../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) FutureOrResult<Data?> + + + +This callback is triggered when user updates his email +_override_ + + + +##### [onError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html) stackTrace) void + + + +Called whenever an error occurs and notifies BlocObserver.onError. +_inherited_ + + + +##### [onPasswordUpdated](../wyatt_authentication_bloc/EditAccountCubit/onPasswordUpdated.md)(Result<[Account](../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) FutureOrResult<Data?> + + + +This callback is triggered when a user edits his password. +_override_ + + + +##### [passwordChanged](../wyatt_authentication_bloc/UpdatePassword/passwordChanged.md)([String](https://api.flutter.dev/flutter/dart-core/String-class.html) value) void + + + + +_inherited_ + + + +##### [passwordCustomChanged](../wyatt_authentication_bloc/UpdatePassword/passwordCustomChanged.md)<Validator extends FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError>>(Validator validator) void + + + +Same as passwordChanged but with a custom Validator. +_inherited_ + + + +##### [reset](../wyatt_authentication_bloc/BaseEditAccountCubit/reset.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + +##### [submit](../wyatt_authentication_bloc/BaseEditAccountCubit/submit.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + +##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + +##### [update](../wyatt_authentication_bloc/BaseEditAccountCubit/update.md)(WyattForm form, {SetOperation operation = SetOperation.replace}) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + +##### [updateEmail](../wyatt_authentication_bloc/UpdateEmail/updateEmail.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + +Update or add email. +_inherited_ + + + +##### [updatePassword](../wyatt_authentication_bloc/UpdatePassword/updatePassword.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + +Update or add password. +_inherited_ + + + +##### [validate](../wyatt_authentication_bloc/BaseEditAccountCubit/validate.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountCubit/EditAccountCubit.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountCubit/EditAccountCubit.md new file mode 100644 index 00000000..801c095c --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountCubit/EditAccountCubit.md @@ -0,0 +1,30 @@ + + + +# EditAccountCubit<Data> constructor + + + + + *[](https://dart.dev/null-safety)* + + + +EditAccountCubit<Data>({required [AuthenticationRepository](../../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> authenticationRepository}) + + + + + +## Implementation + +```dart +EditAccountCubit({required super.authenticationRepository}); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountCubit/onEmailUpdated.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountCubit/onEmailUpdated.md new file mode 100644 index 00000000..bc18c4b1 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountCubit/onEmailUpdated.md @@ -0,0 +1,42 @@ + + + +# onEmailUpdated method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +FutureOrResult<Data?> onEmailUpdated +(Result<[Account](../../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) + +_override_ + + + +

This callback is triggered when user updates his email

+ + + +## Implementation + +```dart +@override +FutureOrResult onEmailUpdated( + Result result, + WyattForm form, +) => + const Ok(null); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountCubit/onPasswordUpdated.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountCubit/onPasswordUpdated.md new file mode 100644 index 00000000..c506f486 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountCubit/onPasswordUpdated.md @@ -0,0 +1,42 @@ + + + +# onPasswordUpdated method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +FutureOrResult<Data?> onPasswordUpdated +(Result<[Account](../../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) + +_override_ + + + +

This callback is triggered when a user edits his password.

+ + + +## Implementation + +```dart +@override +FutureOrResult onPasswordUpdated( + Result result, + WyattForm form, +) => + const Ok(null); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener-class.md new file mode 100644 index 00000000..a6da474c --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener-class.md @@ -0,0 +1,236 @@ + + + +# EditAccountListener<Data> class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Widget that listens and builds a child based on the state of +the edit account cubit

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [DiagnosticableTree](https://api.flutter.dev/flutter/foundation/DiagnosticableTree-class.html) +- [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) +- [StatelessWidget](https://api.flutter.dev/flutter/widgets/StatelessWidget-class.html) +- EditAccountListener + + + + + + + + +## Constructors + +[EditAccountListener](../wyatt_authentication_bloc/EditAccountListener/EditAccountListener.md) ({required [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) child, void onProgress([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?, void onSuccess([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?, void onError([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, FormStatus status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage)?, void customBuilder([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, [EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md) state)?, [Key](https://api.flutter.dev/flutter/foundation/Key-class.html)? key}) + + _const_ + + +## Properties + +##### [child](../wyatt_authentication_bloc/EditAccountListener/child.md) → [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) + + + + +_final_ + + + +##### [customBuilder](../wyatt_authentication_bloc/EditAccountListener/customBuilder.md) → (void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, [EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md) state)?) + + + + +_final_ + + + +##### [hashCode](https://api.flutter.dev/flutter/widgets/Widget/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [key](https://api.flutter.dev/flutter/widgets/Widget/key.html) → [Key](https://api.flutter.dev/flutter/foundation/Key-class.html)? + + + +Controls how one widget replaces another widget in the tree. +_finalinherited_ + + + +##### [onError](../wyatt_authentication_bloc/EditAccountListener/onError.md) → (void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, FormStatus status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage)?) + + + + +_final_ + + + +##### [onProgress](../wyatt_authentication_bloc/EditAccountListener/onProgress.md) → (void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?) + + + + +_final_ + + + +##### [onSuccess](../wyatt_authentication_bloc/EditAccountListener/onSuccess.md) → (void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?) + + + + +_final_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [build](../wyatt_authentication_bloc/EditAccountListener/build.md)([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context) [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) + + + +Describes the part of the user interface represented by this widget. +_override_ + + + +##### [createElement](https://api.flutter.dev/flutter/widgets/StatelessWidget/createElement.html)() [StatelessElement](https://api.flutter.dev/flutter/widgets/StatelessElement-class.html) + + + +Creates a StatelessElement to manage this widget's location in the tree. +_inherited_ + + + +##### [debugDescribeChildren](https://api.flutter.dev/flutter/foundation/DiagnosticableTree/debugDescribeChildren.html)() [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[DiagnosticsNode](https://api.flutter.dev/flutter/foundation/DiagnosticsNode-class.html)> + + + +Returns a list of DiagnosticsNode objects describing this node's +children. +_inherited_ + + + +##### [debugFillProperties](https://api.flutter.dev/flutter/widgets/Widget/debugFillProperties.html)([DiagnosticPropertiesBuilder](https://api.flutter.dev/flutter/foundation/DiagnosticPropertiesBuilder-class.html) properties) void + + + +Add additional properties associated with the node. +_inherited_ + + + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toDiagnosticsNode](https://api.flutter.dev/flutter/foundation/DiagnosticableTree/toDiagnosticsNode.html)({[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? name, [DiagnosticsTreeStyle](https://api.flutter.dev/flutter/foundation/DiagnosticsTreeStyle.html)? style}) [DiagnosticsNode](https://api.flutter.dev/flutter/foundation/DiagnosticsNode-class.html) + + + +Returns a debug representation of the object that is used by debugging +tools and by DiagnosticsNode.toStringDeep. +_inherited_ + + + +##### [toString](https://api.flutter.dev/flutter/foundation/Diagnosticable/toString.html)({[DiagnosticLevel](https://api.flutter.dev/flutter/foundation/DiagnosticLevel.html) minLevel = DiagnosticLevel.info}) [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + +##### [toStringDeep](https://api.flutter.dev/flutter/foundation/DiagnosticableTree/toStringDeep.html)({[String](https://api.flutter.dev/flutter/dart-core/String-class.html) prefixLineOne = '', [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? prefixOtherLines, [DiagnosticLevel](https://api.flutter.dev/flutter/foundation/DiagnosticLevel.html) minLevel = DiagnosticLevel.debug}) [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +Returns a string representation of this node and its descendants. +_inherited_ + + + +##### [toStringShallow](https://api.flutter.dev/flutter/foundation/DiagnosticableTree/toStringShallow.html)({[String](https://api.flutter.dev/flutter/dart-core/String-class.html) joiner = ', ', [DiagnosticLevel](https://api.flutter.dev/flutter/foundation/DiagnosticLevel.html) minLevel = DiagnosticLevel.debug}) [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +Returns a one-line detailed description of the object. +_inherited_ + + + +##### [toStringShort](https://api.flutter.dev/flutter/widgets/Widget/toStringShort.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A short, textual description of this widget. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/widgets/Widget/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/EditAccountListener.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/EditAccountListener.md new file mode 100644 index 00000000..ec51cd1d --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/EditAccountListener.md @@ -0,0 +1,37 @@ + + + +# EditAccountListener<Data> constructor + + + + + *[](https://dart.dev/null-safety)* + + +const +EditAccountListener<Data>({required [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) child, void onProgress([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?, void onSuccess([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?, void onError([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, FormStatus status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage)?, void customBuilder([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, [EditAccountState](../../wyatt_authentication_bloc/EditAccountState-class.md) state)?, [Key](https://api.flutter.dev/flutter/foundation/Key-class.html)? key}) + + + + + +## Implementation + +```dart +const EditAccountListener({ + required this.child, + this.onProgress, + this.onSuccess, + this.onError, + this.customBuilder, + super.key, +}); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/build.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/build.md new file mode 100644 index 00000000..03d55600 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/build.md @@ -0,0 +1,92 @@ + + + +# build method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) build +([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context) + +_override_ + + + +

Describes the part of the user interface represented by this widget.

+

The framework calls this method when this widget is inserted into the tree +in a given BuildContext and when the dependencies of this widget change +(e.g., an InheritedWidget referenced by this widget changes). This +method can potentially be called in every frame and should not have any side +effects beyond building a widget.

+

The framework replaces the subtree below this widget with the widget +returned by this method, either by updating the existing subtree or by +removing the subtree and inflating a new subtree, depending on whether the +widget returned by this method can update the root of the existing +subtree, as determined by calling Widget.canUpdate.

+

Typically implementations return a newly created constellation of widgets +that are configured with information from this widget's constructor and +from the given BuildContext.

+

The given BuildContext contains information about the location in the +tree at which this widget is being built. For example, the context +provides the set of inherited widgets for this location in the tree. A +given widget might be built with multiple different BuildContext +arguments over time if the widget is moved around the tree or if the +widget is inserted into the tree in multiple places at once.

+

The implementation of this method must only depend on:

+ +

If a widget's build method is to depend on anything else, use a +StatefulWidget instead.

+

See also:

+
    +
  • StatelessWidget, which contains the discussion on performance considerations.
  • +
+ + + +## Implementation + +```dart +@override +Widget build(BuildContext context) => + BlocListener, EditAccountState>( + listener: (context, state) { + if (customBuilder != null) { + return customBuilder!(context, state); + } + + if (onSuccess != null && + state.status == FormStatus.submissionSuccess) { + return onSuccess!(context); + } + if (onProgress != null && + state.status == FormStatus.submissionInProgress) { + return onProgress!(context); + } + if (onError != null && + (state.status == FormStatus.submissionCanceled || + state.status == FormStatus.submissionFailure)) { + return onError!(context, state.status, state.errorMessage); + } + }, + child: child, + ); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/child.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/child.md new file mode 100644 index 00000000..53bc3682 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/child.md @@ -0,0 +1,33 @@ + + + +# child property + + + + + *[](https://dart.dev/null-safety)* + + + +[Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) child + +_final_ + + + + + + +## Implementation + +```dart +final Widget child; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/customBuilder.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/customBuilder.md new file mode 100644 index 00000000..a8d52a8d --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/customBuilder.md @@ -0,0 +1,34 @@ + + + +# customBuilder property + + + + + *[](https://dart.dev/null-safety)* + + + +(void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, [EditAccountState](../../wyatt_authentication_bloc/EditAccountState-class.md) state)?) customBuilder + +_final_ + + + + + + +## Implementation + +```dart +final void Function(BuildContext context, EditAccountState state)? + customBuilder; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/onError.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/onError.md new file mode 100644 index 00000000..ed94a98f --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/onError.md @@ -0,0 +1,37 @@ + + + +# onError property + + + + + *[](https://dart.dev/null-safety)* + + + +(void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, FormStatus status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage)?) onError + +_final_ + + + + + + +## Implementation + +```dart +final void Function( + BuildContext context, + FormStatus status, + String? errorMessage, +)? onError; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/onProgress.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/onProgress.md new file mode 100644 index 00000000..4a30ed71 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/onProgress.md @@ -0,0 +1,33 @@ + + + +# onProgress property + + + + + *[](https://dart.dev/null-safety)* + + + +(void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?) onProgress + +_final_ + + + + + + +## Implementation + +```dart +final void Function(BuildContext context)? onProgress; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/onSuccess.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/onSuccess.md new file mode 100644 index 00000000..4d942f63 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/onSuccess.md @@ -0,0 +1,33 @@ + + + +# onSuccess property + + + + + *[](https://dart.dev/null-safety)* + + + +(void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?) onSuccess + +_final_ + + + + + + +## Implementation + +```dart +final void Function(BuildContext context)? onSuccess; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState-class.md new file mode 100644 index 00000000..9c7250d8 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState-class.md @@ -0,0 +1,179 @@ + + + +# EditAccountState class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Edit account cubit state to manage the form.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [Equatable](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable-class.html) +- EditAccountState + + + + + + + + +## Constructors + +[EditAccountState](../wyatt_authentication_bloc/EditAccountState/EditAccountState.md) ({required WyattForm form, FormStatus status = FormStatus.pure, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage}) + + _const_ + + +## Properties + +##### [email](../wyatt_authentication_bloc/EditAccountState/email.md) → FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError> + + + + +_read-only_ + + + +##### [errorMessage](../wyatt_authentication_bloc/EditAccountState/errorMessage.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? + + + +Optional error message. +_finalinherited_ + + + +##### [form](../wyatt_authentication_bloc/EditAccountState/form.md) → WyattForm + + + +FormData with all inputs, and associated metadata. +_finalinherited_ + + + +##### [hashCode](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [password](../wyatt_authentication_bloc/EditAccountState/password.md) → FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError> + + + + +_read-only_ + + + +##### [props](../wyatt_authentication_bloc/EditAccountState/props.md) → [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)> + + + +The list of properties that will be used to determine whether +two instances are equal. +_read-only_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + +##### [status](../wyatt_authentication_bloc/EditAccountState/status.md) → FormStatus + + + +Global status of a form. +_finalinherited_ + + + +##### [stringify](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/stringify.html) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)? + + + +If set to true, the toString method will be overridden to output +this instance's props. +_read-onlyinherited_ + + + + + +## Methods + +##### [copyWith](../wyatt_authentication_bloc/EditAccountState/copyWith.md)({WyattForm? form, FormStatus? status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage}) [EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md) + + + + + + + + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/EditAccountState/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_override_ + + + + + +## Operators + +##### [operator ==](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/EditAccountState.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/EditAccountState.md new file mode 100644 index 00000000..b8145411 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/EditAccountState.md @@ -0,0 +1,34 @@ + + + +# EditAccountState constructor + + + + + *[](https://dart.dev/null-safety)* + + +const +EditAccountState({required WyattForm form, FormStatus status = FormStatus.pure, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage}) + + + + + +## Implementation + +```dart +const EditAccountState({ + required super.form, + super.status = FormStatus.pure, + super.errorMessage, +}); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/copyWith.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/copyWith.md new file mode 100644 index 00000000..aed8958b --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/copyWith.md @@ -0,0 +1,44 @@ + + + +# copyWith method + + + + + *[](https://dart.dev/null-safety)* + + + + +[EditAccountState](../../wyatt_authentication_bloc/EditAccountState-class.md) copyWith +({WyattForm? form, FormStatus? status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage}) + + + + + + + + +## Implementation + +```dart +EditAccountState copyWith({ + WyattForm? form, + FormStatus? status, + String? errorMessage, +}) => + EditAccountState( + form: form ?? this.form, + status: status ?? this.status, + errorMessage: errorMessage ?? this.errorMessage, + ); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/email.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/email.md new file mode 100644 index 00000000..1ded8043 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/email.md @@ -0,0 +1,37 @@ + + + +# email property + + + + + *[](https://dart.dev/null-safety)* + + + + + +FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError> email + + + + + + + + +## Implementation + +```dart +FormInputValidator get email => + form.validatorOf(AuthFormField.email); +``` + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/errorMessage.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/errorMessage.md new file mode 100644 index 00000000..d0856deb --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/errorMessage.md @@ -0,0 +1,34 @@ + + + +# errorMessage property + + + + + *[](https://dart.dev/null-safety)* + + + +[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage + +_finalinherited_ + + + +

Optional error message.

+ + + +## Implementation + +```dart +final String? errorMessage; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/form.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/form.md new file mode 100644 index 00000000..d3f2da76 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/form.md @@ -0,0 +1,34 @@ + + + +# form property + + + + + *[](https://dart.dev/null-safety)* + + + +WyattForm form + +_finalinherited_ + + + +

FormData with all inputs, and associated metadata.

+ + + +## Implementation + +```dart +final WyattForm form; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/password.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/password.md new file mode 100644 index 00000000..77938106 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/password.md @@ -0,0 +1,37 @@ + + + +# password property + + + + + *[](https://dart.dev/null-safety)* + + + + + +FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError> password + + + + + + + + +## Implementation + +```dart +FormInputValidator get password => + form.validatorOf(AuthFormField.password); +``` + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/props.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/props.md new file mode 100644 index 00000000..eab8d26c --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/props.md @@ -0,0 +1,42 @@ + + + +# props property + + + + + *[](https://dart.dev/null-safety)* + + + + + +**Annotations** + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) +[List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)> props + + + + + +

The list of properties that will be used to determine whether +two instances are equal.

+ + + +## Implementation + +```dart +@override +List get props => [email, password, status]; +``` + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/status.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/status.md new file mode 100644 index 00000000..644a9f10 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/status.md @@ -0,0 +1,34 @@ + + + +# status property + + + + + *[](https://dart.dev/null-safety)* + + + +FormStatus status + +_finalinherited_ + + + +

Global status of a form.

+ + + +## Implementation + +```dart +final FormStatus status; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/toString.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/toString.md new file mode 100644 index 00000000..3a837f4e --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/toString.md @@ -0,0 +1,48 @@ + + + +# toString method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[String](https://api.flutter.dev/flutter/dart-core/String-class.html) toString +() + +_override_ + + + +

A string representation of this object.

+

Some classes have a default textual representation, +often paired with a static parse function (like int.parse). +These classes will provide the textual representation as +their string representation.

+

Other classes have no meaningful textual representation +that a program will care about. +Such classes will typically override toString to provide +useful information when inspecting the object, +mainly for debugging or logging.

+ + + +## Implementation + +```dart +@override +String toString() => 'EditAccountState(status: ${status.name} ' + '${(errorMessage != null) ? " [$errorMessage]" : ""}, $form)'; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder-class.md new file mode 100644 index 00000000..5692d1ab --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder-class.md @@ -0,0 +1,225 @@ + + + +# EmailVerificationBuilder<Extra> class + + + + + + + *[](https://dart.dev/null-safety)* + + + + + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [DiagnosticableTree](https://api.flutter.dev/flutter/foundation/DiagnosticableTree-class.html) +- [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) +- [StatelessWidget](https://api.flutter.dev/flutter/widgets/StatelessWidget-class.html) +- EmailVerificationBuilder + + + + + + + + +## Constructors + +[EmailVerificationBuilder](../wyatt_authentication_bloc/EmailVerificationBuilder/EmailVerificationBuilder.md) ({required [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) verified([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context), required [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) notVerified([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context), required [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) onError([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, FormStatus status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage), [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) customBuilder([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, [EmailVerificationState](../wyatt_authentication_bloc/EmailVerificationState-class.md))?, [Key](https://api.flutter.dev/flutter/foundation/Key-class.html)? key}) + + _const_ + + +## Properties + +##### [customBuilder](../wyatt_authentication_bloc/EmailVerificationBuilder/customBuilder.md) → ([Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, [EmailVerificationState](../wyatt_authentication_bloc/EmailVerificationState-class.md))?) + + + + +_final_ + + + +##### [hashCode](https://api.flutter.dev/flutter/widgets/Widget/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [key](https://api.flutter.dev/flutter/widgets/Widget/key.html) → [Key](https://api.flutter.dev/flutter/foundation/Key-class.html)? + + + +Controls how one widget replaces another widget in the tree. +_finalinherited_ + + + +##### [notVerified](../wyatt_authentication_bloc/EmailVerificationBuilder/notVerified.md) → [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context) + + + + +_final_ + + + +##### [onError](../wyatt_authentication_bloc/EmailVerificationBuilder/onError.md) → [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, FormStatus status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage) + + + + +_final_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + +##### [verified](../wyatt_authentication_bloc/EmailVerificationBuilder/verified.md) → [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context) + + + + +_final_ + + + + + +## Methods + +##### [build](../wyatt_authentication_bloc/EmailVerificationBuilder/build.md)([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context) [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) + + + +Describes the part of the user interface represented by this widget. +_override_ + + + +##### [createElement](https://api.flutter.dev/flutter/widgets/StatelessWidget/createElement.html)() [StatelessElement](https://api.flutter.dev/flutter/widgets/StatelessElement-class.html) + + + +Creates a StatelessElement to manage this widget's location in the tree. +_inherited_ + + + +##### [debugDescribeChildren](https://api.flutter.dev/flutter/foundation/DiagnosticableTree/debugDescribeChildren.html)() [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[DiagnosticsNode](https://api.flutter.dev/flutter/foundation/DiagnosticsNode-class.html)> + + + +Returns a list of DiagnosticsNode objects describing this node's +children. +_inherited_ + + + +##### [debugFillProperties](https://api.flutter.dev/flutter/widgets/Widget/debugFillProperties.html)([DiagnosticPropertiesBuilder](https://api.flutter.dev/flutter/foundation/DiagnosticPropertiesBuilder-class.html) properties) void + + + +Add additional properties associated with the node. +_inherited_ + + + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toDiagnosticsNode](https://api.flutter.dev/flutter/foundation/DiagnosticableTree/toDiagnosticsNode.html)({[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? name, [DiagnosticsTreeStyle](https://api.flutter.dev/flutter/foundation/DiagnosticsTreeStyle.html)? style}) [DiagnosticsNode](https://api.flutter.dev/flutter/foundation/DiagnosticsNode-class.html) + + + +Returns a debug representation of the object that is used by debugging +tools and by DiagnosticsNode.toStringDeep. +_inherited_ + + + +##### [toString](https://api.flutter.dev/flutter/foundation/Diagnosticable/toString.html)({[DiagnosticLevel](https://api.flutter.dev/flutter/foundation/DiagnosticLevel.html) minLevel = DiagnosticLevel.info}) [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + +##### [toStringDeep](https://api.flutter.dev/flutter/foundation/DiagnosticableTree/toStringDeep.html)({[String](https://api.flutter.dev/flutter/dart-core/String-class.html) prefixLineOne = '', [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? prefixOtherLines, [DiagnosticLevel](https://api.flutter.dev/flutter/foundation/DiagnosticLevel.html) minLevel = DiagnosticLevel.debug}) [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +Returns a string representation of this node and its descendants. +_inherited_ + + + +##### [toStringShallow](https://api.flutter.dev/flutter/foundation/DiagnosticableTree/toStringShallow.html)({[String](https://api.flutter.dev/flutter/dart-core/String-class.html) joiner = ', ', [DiagnosticLevel](https://api.flutter.dev/flutter/foundation/DiagnosticLevel.html) minLevel = DiagnosticLevel.debug}) [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +Returns a one-line detailed description of the object. +_inherited_ + + + +##### [toStringShort](https://api.flutter.dev/flutter/widgets/Widget/toStringShort.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A short, textual description of this widget. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/widgets/Widget/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder/EmailVerificationBuilder.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder/EmailVerificationBuilder.md new file mode 100644 index 00000000..02f74876 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder/EmailVerificationBuilder.md @@ -0,0 +1,36 @@ + + + +# EmailVerificationBuilder<Extra> constructor + + + + + *[](https://dart.dev/null-safety)* + + +const +EmailVerificationBuilder<Extra>({required [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) verified([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context), required [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) notVerified([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context), required [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) onError([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, FormStatus status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage), [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) customBuilder([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, [EmailVerificationState](../../wyatt_authentication_bloc/EmailVerificationState-class.md))?, [Key](https://api.flutter.dev/flutter/foundation/Key-class.html)? key}) + + + + + +## Implementation + +```dart +const EmailVerificationBuilder({ + required this.verified, + required this.notVerified, + required this.onError, + this.customBuilder, + super.key, +}); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder/build.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder/build.md new file mode 100644 index 00000000..6eaf5649 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder/build.md @@ -0,0 +1,91 @@ + + + +# build method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) build +([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context) + +_override_ + + + +

Describes the part of the user interface represented by this widget.

+

The framework calls this method when this widget is inserted into the tree +in a given BuildContext and when the dependencies of this widget change +(e.g., an InheritedWidget referenced by this widget changes). This +method can potentially be called in every frame and should not have any side +effects beyond building a widget.

+

The framework replaces the subtree below this widget with the widget +returned by this method, either by updating the existing subtree or by +removing the subtree and inflating a new subtree, depending on whether the +widget returned by this method can update the root of the existing +subtree, as determined by calling Widget.canUpdate.

+

Typically implementations return a newly created constellation of widgets +that are configured with information from this widget's constructor and +from the given BuildContext.

+

The given BuildContext contains information about the location in the +tree at which this widget is being built. For example, the context +provides the set of inherited widgets for this location in the tree. A +given widget might be built with multiple different BuildContext +arguments over time if the widget is moved around the tree or if the +widget is inserted into the tree in multiple places at once.

+

The implementation of this method must only depend on:

+ +

If a widget's build method is to depend on anything else, use a +StatefulWidget instead.

+

See also:

+
    +
  • StatelessWidget, which contains the discussion on performance considerations.
  • +
+ + + +## Implementation + +```dart +@override +Widget build(BuildContext context) => + BlocBuilder, EmailVerificationState>( + builder: (context, state) { + if (customBuilder != null) { + return customBuilder!(context, state); + } + + if (state.status.isSubmissionFailure || + state.status.isSubmissionCanceled) { + return onError( + context, + state.status, + state.errorMessage, + ); + } + + if (state.isVerified) { + return verified(context); + } + return notVerified(context); + }, + ); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder/customBuilder.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder/customBuilder.md new file mode 100644 index 00000000..1b238503 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder/customBuilder.md @@ -0,0 +1,34 @@ + + + +# customBuilder property + + + + + *[](https://dart.dev/null-safety)* + + + +([Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, [EmailVerificationState](../../wyatt_authentication_bloc/EmailVerificationState-class.md))?) customBuilder + +_final_ + + + + + + +## Implementation + +```dart +final Widget Function(BuildContext context, EmailVerificationState)? + customBuilder; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder/notVerified.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder/notVerified.md new file mode 100644 index 00000000..fb67f5a1 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder/notVerified.md @@ -0,0 +1,33 @@ + + + +# notVerified property + + + + + *[](https://dart.dev/null-safety)* + + + +[Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context) notVerified + +_final_ + + + + + + +## Implementation + +```dart +final Widget Function(BuildContext context) notVerified; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder/onError.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder/onError.md new file mode 100644 index 00000000..caa029d2 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder/onError.md @@ -0,0 +1,37 @@ + + + +# onError property + + + + + *[](https://dart.dev/null-safety)* + + + +[Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, FormStatus status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage) onError + +_final_ + + + + + + +## Implementation + +```dart +final Widget Function( + BuildContext context, + FormStatus status, + String? errorMessage, +) onError; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder/verified.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder/verified.md new file mode 100644 index 00000000..05f99c91 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder/verified.md @@ -0,0 +1,33 @@ + + + +# verified property + + + + + *[](https://dart.dev/null-safety)* + + + +[Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context) verified + +_final_ + + + + + + +## Implementation + +```dart +final Widget Function(BuildContext context) verified; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationCubit-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationCubit-class.md new file mode 100644 index 00000000..f582d49e --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationCubit-class.md @@ -0,0 +1,211 @@ + + + +# EmailVerificationCubit<Data> class + + + + + + + *[](https://dart.dev/null-safety)* + + + + + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [BlocBase](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase-class.html)<[EmailVerificationState](../wyatt_authentication_bloc/EmailVerificationState-class.md)> +- [Cubit](https://pub.dev/documentation/bloc/8.1.0/bloc/Cubit-class.html)<[EmailVerificationState](../wyatt_authentication_bloc/EmailVerificationState-class.md)> +- EmailVerificationCubit + + + + + + + + +## Constructors + +[EmailVerificationCubit](../wyatt_authentication_bloc/EmailVerificationCubit/EmailVerificationCubit.md) ({required [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> authenticationRepository}) + + + + +## Properties + +##### [authenticationRepository](../wyatt_authentication_bloc/EmailVerificationCubit/authenticationRepository.md) → [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> + + + + +_final_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [isClosed](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/isClosed.html) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +Whether the bloc is closed. +_read-onlyinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + +##### [state](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/state.html) → [EmailVerificationState](../wyatt_authentication_bloc/EmailVerificationState-class.md) + + + +The current state. +_read-onlyinherited_ + + + +##### [stream](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/stream.html) → [Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[EmailVerificationState](../wyatt_authentication_bloc/EmailVerificationState-class.md)> + + + +The current stream of states. +_read-onlyinherited_ + + + + + +## Methods + +##### [addError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/addError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [[StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html)? stackTrace]) void + + + +Reports an error which triggers onError with an optional StackTrace. +_inherited_ + + + +##### [checkEmailVerification](../wyatt_authentication_bloc/EmailVerificationCubit/checkEmailVerification.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + + + + + +##### [close](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/close.html)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> + + + +Closes the instance. +This method should be called when the instance is no longer needed. +Once close is called, the instance can no longer be used. +_inherited_ + + + +##### [emit](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/emit.html)([EmailVerificationState](../wyatt_authentication_bloc/EmailVerificationState-class.md) state) void + + + +Updates the state to the provided state. +emit does nothing if the state being emitted +is equal to the current state. +_inherited_ + + + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [onChange](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onChange.html)([Change](https://pub.dev/documentation/bloc/8.1.0/bloc/Change-class.html)<[EmailVerificationState](../wyatt_authentication_bloc/EmailVerificationState-class.md)> change) void + + + +Called whenever a change occurs with the given change. +A change occurs when a new state is emitted. +onChange is called before the state of the cubit is updated. +onChange is a great spot to add logging/analytics for a specific cubit. +_inherited_ + + + +##### [onError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html) stackTrace) void + + + +Called whenever an error occurs and notifies BlocObserver.onError. +_inherited_ + + + +##### [sendEmailVerification](../wyatt_authentication_bloc/EmailVerificationCubit/sendEmailVerification.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + + + + + +##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationCubit/EmailVerificationCubit.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationCubit/EmailVerificationCubit.md new file mode 100644 index 00000000..4dc46616 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationCubit/EmailVerificationCubit.md @@ -0,0 +1,32 @@ + + + +# EmailVerificationCubit<Data> constructor + + + + + *[](https://dart.dev/null-safety)* + + + +EmailVerificationCubit<Data>({required [AuthenticationRepository](../../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> authenticationRepository}) + + + + + +## Implementation + +```dart +EmailVerificationCubit({ + required this.authenticationRepository, +}) : super(const EmailVerificationState()); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationCubit/authenticationRepository.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationCubit/authenticationRepository.md new file mode 100644 index 00000000..32cdfa2a --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationCubit/authenticationRepository.md @@ -0,0 +1,33 @@ + + + +# authenticationRepository property + + + + + *[](https://dart.dev/null-safety)* + + + +[AuthenticationRepository](../../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> authenticationRepository + +_final_ + + + + + + +## Implementation + +```dart +final AuthenticationRepository authenticationRepository; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationCubit/checkEmailVerification.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationCubit/checkEmailVerification.md new file mode 100644 index 00000000..7b602aac --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationCubit/checkEmailVerification.md @@ -0,0 +1,65 @@ + + + +# checkEmailVerification method + + + + + *[](https://dart.dev/null-safety)* + + + + +[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> checkEmailVerification +() + + + + + + + + +## Implementation + +```dart +FutureOr checkEmailVerification() async { + emit(state.copyWith(status: FormStatus.submissionInProgress)); + + final refresh = await authenticationRepository.refresh(); + if (refresh.isErr) { + final refreshError = refresh.err!; + emit( + EmailVerificationState( + errorMessage: refreshError.message, + status: FormStatus.submissionFailure, + ), + ); + return; + } + + final wrapper = await authenticationRepository.sessionStream().last; + final currentAccount = wrapper.session?.account; + if (currentAccount != null) { + emit( + state.copyWith( + isVerified: currentAccount.emailVerified, + status: FormStatus.submissionSuccess, + ), + ); + } else { + const EmailVerificationState( + errorMessage: 'No current session', + status: FormStatus.submissionFailure, + ); + } +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationCubit/sendEmailVerification.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationCubit/sendEmailVerification.md new file mode 100644 index 00000000..5d9d58e5 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationCubit/sendEmailVerification.md @@ -0,0 +1,47 @@ + + + +# sendEmailVerification method + + + + + *[](https://dart.dev/null-safety)* + + + + +[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> sendEmailVerification +() + + + + + + + + +## Implementation + +```dart +FutureOr sendEmailVerification() async { + emit(state.copyWith(status: FormStatus.submissionInProgress)); + final response = await authenticationRepository.sendEmailVerification(); + emit( + response.fold( + (value) => state.copyWith(status: FormStatus.submissionSuccess), + (error) => state.copyWith( + errorMessage: error.message, + status: FormStatus.submissionFailure, + ), + ), + ); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState-class.md new file mode 100644 index 00000000..a1a99c58 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState-class.md @@ -0,0 +1,160 @@ + + + +# EmailVerificationState class + + + + + + + *[](https://dart.dev/null-safety)* + + + + + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [Equatable](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable-class.html) +- EmailVerificationState + + + + + + + + +## Constructors + +[EmailVerificationState](../wyatt_authentication_bloc/EmailVerificationState/EmailVerificationState.md) ({[bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) isVerified = false, FormStatus status = FormStatus.pure, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage}) + + _const_ + + +## Properties + +##### [errorMessage](../wyatt_authentication_bloc/EmailVerificationState/errorMessage.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? + + + + +_final_ + + + +##### [hashCode](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [isVerified](../wyatt_authentication_bloc/EmailVerificationState/isVerified.md) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + + +_final_ + + + +##### [props](../wyatt_authentication_bloc/EmailVerificationState/props.md) → [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> + + + +The list of properties that will be used to determine whether +two instances are equal. +_read-onlyoverride_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + +##### [status](../wyatt_authentication_bloc/EmailVerificationState/status.md) → FormStatus + + + + +_final_ + + + +##### [stringify](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/stringify.html) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)? + + + +If set to true, the toString method will be overridden to output +this instance's props. +_read-onlyinherited_ + + + + + +## Methods + +##### [copyWith](../wyatt_authentication_bloc/EmailVerificationState/copyWith.md)({FormStatus? status, [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)? isVerified, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage}) [EmailVerificationState](../wyatt_authentication_bloc/EmailVerificationState-class.md) + + + + + + + + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/EmailVerificationState/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_override_ + + + + + +## Operators + +##### [operator ==](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/EmailVerificationState.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/EmailVerificationState.md new file mode 100644 index 00000000..2b2eec71 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/EmailVerificationState.md @@ -0,0 +1,34 @@ + + + +# EmailVerificationState constructor + + + + + *[](https://dart.dev/null-safety)* + + +const +EmailVerificationState({[bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) isVerified = false, FormStatus status = FormStatus.pure, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage}) + + + + + +## Implementation + +```dart +const EmailVerificationState({ + this.isVerified = false, + this.status = FormStatus.pure, + this.errorMessage, +}); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/copyWith.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/copyWith.md new file mode 100644 index 00000000..3828f71a --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/copyWith.md @@ -0,0 +1,44 @@ + + + +# copyWith method + + + + + *[](https://dart.dev/null-safety)* + + + + +[EmailVerificationState](../../wyatt_authentication_bloc/EmailVerificationState-class.md) copyWith +({FormStatus? status, [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)? isVerified, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage}) + + + + + + + + +## Implementation + +```dart +EmailVerificationState copyWith({ + FormStatus? status, + bool? isVerified, + String? errorMessage, +}) => + EmailVerificationState( + status: status ?? this.status, + isVerified: isVerified ?? this.isVerified, + errorMessage: errorMessage ?? this.errorMessage, + ); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/errorMessage.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/errorMessage.md new file mode 100644 index 00000000..4f0a5b7f --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/errorMessage.md @@ -0,0 +1,33 @@ + + + +# errorMessage property + + + + + *[](https://dart.dev/null-safety)* + + + +[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage + +_final_ + + + + + + +## Implementation + +```dart +final String? errorMessage; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/isVerified.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/isVerified.md new file mode 100644 index 00000000..5fe39d63 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/isVerified.md @@ -0,0 +1,33 @@ + + + +# isVerified property + + + + + *[](https://dart.dev/null-safety)* + + + +[bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) isVerified + +_final_ + + + + + + +## Implementation + +```dart +final bool isVerified; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/props.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/props.md new file mode 100644 index 00000000..60e41027 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/props.md @@ -0,0 +1,42 @@ + + + +# props property + + + + + *[](https://dart.dev/null-safety)* + + + + + +**Annotations** + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) +[List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> props + +_override_ + + + +

The list of properties that will be used to determine whether +two instances are equal.

+ + + +## Implementation + +```dart +@override +List get props => [status, isVerified, errorMessage]; +``` + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/status.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/status.md new file mode 100644 index 00000000..5623cccf --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/status.md @@ -0,0 +1,33 @@ + + + +# status property + + + + + *[](https://dart.dev/null-safety)* + + + +FormStatus status + +_final_ + + + + + + +## Implementation + +```dart +final FormStatus status; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/toString.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/toString.md new file mode 100644 index 00000000..3fec7549 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/toString.md @@ -0,0 +1,49 @@ + + + +# toString method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[String](https://api.flutter.dev/flutter/dart-core/String-class.html) toString +() + +_override_ + + + +

A string representation of this object.

+

Some classes have a default textual representation, +often paired with a static parse function (like int.parse). +These classes will provide the textual representation as +their string representation.

+

Other classes have no meaningful textual representation +that a program will care about. +Such classes will typically override toString to provide +useful information when inspecting the object, +mainly for debugging or logging.

+ + + +## Implementation + +```dart +@override +String toString() => 'EmailVerificationState(status: ${status.name} ' + '${(errorMessage != null) ? " [$errorMessage]" : ""}, ' + 'isVerified: $isVerified)'; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureFirebase-class.md new file mode 100644 index 00000000..a97181ca --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureFirebase-class.md @@ -0,0 +1,137 @@ + + + +# FetchSignInMethodsForEmailFailureFirebase class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown during the fetch sign in methods if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- [FetchSignInMethodsForEmailFailureInterface](../wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureInterface-class.md) +- FetchSignInMethodsForEmailFailureFirebase + + + + + + + + +## Constructors + +[FetchSignInMethodsForEmailFailureFirebase](../wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureFirebase/FetchSignInMethodsForEmailFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + +[FetchSignInMethodsForEmailFailureFirebase.fromCode](../wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureFirebase/FetchSignInMethodsForEmailFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureFirebase/FetchSignInMethodsForEmailFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureFirebase/FetchSignInMethodsForEmailFailureFirebase.fromCode.md new file mode 100644 index 00000000..3cf4d6c5 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureFirebase/FetchSignInMethodsForEmailFailureFirebase.fromCode.md @@ -0,0 +1,40 @@ + + + +# FetchSignInMethodsForEmailFailureFirebase.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +FetchSignInMethodsForEmailFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + + +## Implementation + +```dart +FetchSignInMethodsForEmailFailureFirebase.fromCode(String code) + : super.fromCode(code) { + switch (code) { + case 'invalid-email': + msg = 'The email address is badly formatted.'; + break; + default: + this.code = 'unknown'; + msg = 'An unknown error occurred.'; + } +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureFirebase/FetchSignInMethodsForEmailFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureFirebase/FetchSignInMethodsForEmailFailureFirebase.md new file mode 100644 index 00000000..4a74506c --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureFirebase/FetchSignInMethodsForEmailFailureFirebase.md @@ -0,0 +1,31 @@ + + + +# FetchSignInMethodsForEmailFailureFirebase constructor + + + + + *[](https://dart.dev/null-safety)* + + + +FetchSignInMethodsForEmailFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + + + +## Implementation + +```dart +FetchSignInMethodsForEmailFailureFirebase([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureInterface-class.md new file mode 100644 index 00000000..5986c599 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureInterface-class.md @@ -0,0 +1,139 @@ + + + +# FetchSignInMethodsForEmailFailureInterface class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown during the fetch sign in methods if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- FetchSignInMethodsForEmailFailureInterface + + + +**Implementers** + +- [FetchSignInMethodsForEmailFailureFirebase](../wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureFirebase-class.md) + + + + + +## Constructors + +[FetchSignInMethodsForEmailFailureInterface](../wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureInterface/FetchSignInMethodsForEmailFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + +Thrown during the fetch sign in methods if a failure occurs. + +[FetchSignInMethodsForEmailFailureInterface.fromCode](../wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureInterface/FetchSignInMethodsForEmailFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + +Thrown during the fetch sign in methods if a failure occurs. + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureInterface/FetchSignInMethodsForEmailFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureInterface/FetchSignInMethodsForEmailFailureInterface.fromCode.md new file mode 100644 index 00000000..846ff49a --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureInterface/FetchSignInMethodsForEmailFailureInterface.fromCode.md @@ -0,0 +1,32 @@ + + + +# FetchSignInMethodsForEmailFailureInterface.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +FetchSignInMethodsForEmailFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + +

Thrown during the fetch sign in methods if a failure occurs.

+ + + +## Implementation + +```dart +FetchSignInMethodsForEmailFailureInterface.fromCode(super.code) + : super.fromCode(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureInterface/FetchSignInMethodsForEmailFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureInterface/FetchSignInMethodsForEmailFailureInterface.md new file mode 100644 index 00000000..b38af41e --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureInterface/FetchSignInMethodsForEmailFailureInterface.md @@ -0,0 +1,31 @@ + + + +# FetchSignInMethodsForEmailFailureInterface constructor + + + + + *[](https://dart.dev/null-safety)* + + + +FetchSignInMethodsForEmailFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + + +

Thrown during the fetch sign in methods if a failure occurs.

+ + + +## Implementation + +```dart +FetchSignInMethodsForEmailFailureInterface(super.code, super.msg); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ModelParsingFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ModelParsingFailureFirebase-class.md new file mode 100644 index 00000000..60876e96 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ModelParsingFailureFirebase-class.md @@ -0,0 +1,137 @@ + + + +# ModelParsingFailureFirebase class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown during the model parsing process if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- [ModelParsingFailureInterface](../wyatt_authentication_bloc/ModelParsingFailureInterface-class.md) +- ModelParsingFailureFirebase + + + + + + + + +## Constructors + +[ModelParsingFailureFirebase](../wyatt_authentication_bloc/ModelParsingFailureFirebase/ModelParsingFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + +[ModelParsingFailureFirebase.fromCode](../wyatt_authentication_bloc/ModelParsingFailureFirebase/ModelParsingFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ModelParsingFailureFirebase/ModelParsingFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ModelParsingFailureFirebase/ModelParsingFailureFirebase.fromCode.md new file mode 100644 index 00000000..0e9ae35c --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ModelParsingFailureFirebase/ModelParsingFailureFirebase.fromCode.md @@ -0,0 +1,30 @@ + + + +# ModelParsingFailureFirebase.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +ModelParsingFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + + +## Implementation + +```dart +ModelParsingFailureFirebase.fromCode(super.code) : super.fromCode(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ModelParsingFailureFirebase/ModelParsingFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ModelParsingFailureFirebase/ModelParsingFailureFirebase.md new file mode 100644 index 00000000..51b77521 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ModelParsingFailureFirebase/ModelParsingFailureFirebase.md @@ -0,0 +1,31 @@ + + + +# ModelParsingFailureFirebase constructor + + + + + *[](https://dart.dev/null-safety)* + + + +ModelParsingFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + + + +## Implementation + +```dart +ModelParsingFailureFirebase([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ModelParsingFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ModelParsingFailureInterface-class.md new file mode 100644 index 00000000..d8e2dead --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ModelParsingFailureInterface-class.md @@ -0,0 +1,139 @@ + + + +# ModelParsingFailureInterface class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown during the model parsing process if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- ModelParsingFailureInterface + + + +**Implementers** + +- [ModelParsingFailureFirebase](../wyatt_authentication_bloc/ModelParsingFailureFirebase-class.md) + + + + + +## Constructors + +[ModelParsingFailureInterface](../wyatt_authentication_bloc/ModelParsingFailureInterface/ModelParsingFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + + + +[ModelParsingFailureInterface.fromCode](../wyatt_authentication_bloc/ModelParsingFailureInterface/ModelParsingFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ModelParsingFailureInterface/ModelParsingFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ModelParsingFailureInterface/ModelParsingFailureInterface.fromCode.md new file mode 100644 index 00000000..055991cb --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ModelParsingFailureInterface/ModelParsingFailureInterface.fromCode.md @@ -0,0 +1,30 @@ + + + +# ModelParsingFailureInterface.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +ModelParsingFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + + +## Implementation + +```dart +ModelParsingFailureInterface.fromCode(super.code) : super.fromCode(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ModelParsingFailureInterface/ModelParsingFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ModelParsingFailureInterface/ModelParsingFailureInterface.md new file mode 100644 index 00000000..473c347a --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ModelParsingFailureInterface/ModelParsingFailureInterface.md @@ -0,0 +1,30 @@ + + + +# ModelParsingFailureInterface constructor + + + + + *[](https://dart.dev/null-safety)* + + + +ModelParsingFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + + + + + +## Implementation + +```dart +ModelParsingFailureInterface(super.code, super.msg); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit-class.md new file mode 100644 index 00000000..350b635e --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit-class.md @@ -0,0 +1,275 @@ + + + +# PasswordResetCubit<Extra> class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Cubit that allows user to reset his password

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [BlocBase](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase-class.html)<[PasswordResetState](../wyatt_authentication_bloc/PasswordResetState-class.md)> +- [Cubit](https://pub.dev/documentation/bloc/8.1.0/bloc/Cubit-class.html)<[PasswordResetState](../wyatt_authentication_bloc/PasswordResetState-class.md)> +- PasswordResetCubit + + + + + + + + +## Constructors + +[PasswordResetCubit](../wyatt_authentication_bloc/PasswordResetCubit/PasswordResetCubit.md) ({required [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Extra> authenticationRepository}) + + + + +## Properties + +##### [authenticationRepository](../wyatt_authentication_bloc/PasswordResetCubit/authenticationRepository.md) → [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Extra> + + + + +_final_ + + + +##### [formName](../wyatt_authentication_bloc/PasswordResetCubit/formName.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-only_ + + + +##### [formRepository](../wyatt_authentication_bloc/PasswordResetCubit/formRepository.md) → FormRepository + + + + +_read-only_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [isClosed](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/isClosed.html) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +Whether the bloc is closed. +_read-onlyinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + +##### [state](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/state.html) → [PasswordResetState](../wyatt_authentication_bloc/PasswordResetState-class.md) + + + +The current state. +_read-onlyinherited_ + + + +##### [stream](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/stream.html) → [Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[PasswordResetState](../wyatt_authentication_bloc/PasswordResetState-class.md)> + + + +The current stream of states. +_read-onlyinherited_ + + + + + +## Methods + +##### [addError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/addError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [[StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html)? stackTrace]) void + + + +Reports an error which triggers onError with an optional StackTrace. +_inherited_ + + + +##### [close](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/close.html)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> + + + +Closes the instance. +This method should be called when the instance is no longer needed. +Once close is called, the instance can no longer be used. +_inherited_ + + + +##### [dataChanged](../wyatt_authentication_bloc/PasswordResetCubit/dataChanged.md)<Value>([String](https://api.flutter.dev/flutter/dart-core/String-class.html) key, FormInputValidator<Value, ValidationError> dirtyValue) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + + + + + +##### [emailChanged](../wyatt_authentication_bloc/PasswordResetCubit/emailChanged.md)([String](https://api.flutter.dev/flutter/dart-core/String-class.html) value) void + + + + + + + + +##### [emailCustomChanged](../wyatt_authentication_bloc/PasswordResetCubit/emailCustomChanged.md)<Validator extends FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError>>(Validator validator) void + + + +Same as emailChanged but with a custom Validator. + + + + +##### [emit](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/emit.html)([PasswordResetState](../wyatt_authentication_bloc/PasswordResetState-class.md) state) void + + + +Updates the state to the provided state. +emit does nothing if the state being emitted +is equal to the current state. +_inherited_ + + + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [onChange](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onChange.html)([Change](https://pub.dev/documentation/bloc/8.1.0/bloc/Change-class.html)<[PasswordResetState](../wyatt_authentication_bloc/PasswordResetState-class.md)> change) void + + + +Called whenever a change occurs with the given change. +A change occurs when a new state is emitted. +onChange is called before the state of the cubit is updated. +onChange is a great spot to add logging/analytics for a specific cubit. +_inherited_ + + + +##### [onError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html) stackTrace) void + + + +Called whenever an error occurs and notifies BlocObserver.onError. +_inherited_ + + + +##### [reset](../wyatt_authentication_bloc/PasswordResetCubit/reset.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + + + + + +##### [submit](../wyatt_authentication_bloc/PasswordResetCubit/submit.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + +Sends a password reset email to the user + + + + +##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + +##### [update](../wyatt_authentication_bloc/PasswordResetCubit/update.md)(WyattForm form, {SetOperation operation = SetOperation.replace}) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + + + + + +##### [validate](../wyatt_authentication_bloc/PasswordResetCubit/validate.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + + + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/PasswordResetCubit.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/PasswordResetCubit.md new file mode 100644 index 00000000..71d64822 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/PasswordResetCubit.md @@ -0,0 +1,37 @@ + + + +# PasswordResetCubit<Extra> constructor + + + + + *[](https://dart.dev/null-safety)* + + + +PasswordResetCubit<Extra>({required [AuthenticationRepository](../../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Extra> authenticationRepository}) + + + + + +## Implementation + +```dart +PasswordResetCubit({ + required this.authenticationRepository, +}) : super( + PasswordResetState( + form: authenticationRepository.formRepository + .accessForm(AuthFormName.passwordResetForm), + ), + ); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/authenticationRepository.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/authenticationRepository.md new file mode 100644 index 00000000..1662ceda --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/authenticationRepository.md @@ -0,0 +1,33 @@ + + + +# authenticationRepository property + + + + + *[](https://dart.dev/null-safety)* + + + +[AuthenticationRepository](../../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Extra> authenticationRepository + +_final_ + + + + + + +## Implementation + +```dart +final AuthenticationRepository authenticationRepository; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/dataChanged.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/dataChanged.md new file mode 100644 index 00000000..c62e9718 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/dataChanged.md @@ -0,0 +1,53 @@ + + + +# dataChanged<Value> method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> dataChanged +<Value>([String](https://api.flutter.dev/flutter/dart-core/String-class.html) key, FormInputValidator<Value, ValidationError> dirtyValue) + + + + + + + + +## Implementation + +```dart +@override +FutureOr dataChanged( + String key, + FormInputValidator dirtyValue, +) { + final form = formRepository.accessForm(formName).clone(); + + try { + form.updateValidator(key, dirtyValue); + formRepository.updateForm(form); + } catch (e) { + rethrow; + } + + emit( + state.copyWith(form: form, status: form.validate()), + ); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/emailChanged.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/emailChanged.md new file mode 100644 index 00000000..85e7cc16 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/emailChanged.md @@ -0,0 +1,47 @@ + + + +# emailChanged method + + + + + *[](https://dart.dev/null-safety)* + + + + +void emailChanged +([String](https://api.flutter.dev/flutter/dart-core/String-class.html) value) + + + + + + + + +## Implementation + +```dart +void emailChanged(String value) { + final emailValidatorType = formRepository + .accessForm(formName) + .validatorOf(AuthFormField.email) + .runtimeType; + assert( + emailValidatorType == Email, + 'Use emailCustomChanged(...) with validator $emailValidatorType', + ); + + final Email email = Email.dirty(value); + dataChanged(AuthFormField.email, email); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/emailCustomChanged.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/emailCustomChanged.md new file mode 100644 index 00000000..fa9c4c14 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/emailCustomChanged.md @@ -0,0 +1,42 @@ + + + +# emailCustomChanged<Validator extends FormInputValidator<String?, ValidationError>> method + + + + + *[](https://dart.dev/null-safety)* + + + + +void emailCustomChanged +<Validator extends FormInputValidator<String?, ValidationError>>(Validator validator) + + + + + +

Same as emailChanged but with a custom Validator.

+

Sort of short hand for dataChanged.

+ + + +## Implementation + +```dart +void emailCustomChanged< + Validator extends FormInputValidator>( + Validator validator, +) { + dataChanged(AuthFormField.email, validator); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/formName.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/formName.md new file mode 100644 index 00000000..0e18d674 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/formName.md @@ -0,0 +1,40 @@ + + + +# formName property + + + + + *[](https://dart.dev/null-safety)* + + + + + +**Annotations** + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) +[String](https://api.flutter.dev/flutter/dart-core/String-class.html) formName + + + + + + + + +## Implementation + +```dart +@override +String get formName => AuthFormName.passwordResetForm; +``` + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/formRepository.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/formRepository.md new file mode 100644 index 00000000..db8665dd --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/formRepository.md @@ -0,0 +1,36 @@ + + + +# formRepository property + + + + + *[](https://dart.dev/null-safety)* + + + + + +FormRepository formRepository + + + + + + + + +## Implementation + +```dart +FormRepository get formRepository => authenticationRepository.formRepository; +``` + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/reset.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/reset.md new file mode 100644 index 00000000..199755fa --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/reset.md @@ -0,0 +1,43 @@ + + + +# reset method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> reset +() + + + + + + + + +## Implementation + +```dart +@override +FutureOr reset() { + final form = state.form.reset(); + formRepository.updateForm(form); + emit( + state.copyWith(form: form, status: form.validate()), + ); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/submit.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/submit.md new file mode 100644 index 00000000..31bfedc7 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/submit.md @@ -0,0 +1,70 @@ + + + +# submit method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> submit +() + + + + + +

Sends a password reset email to the user

+ + + +## Implementation + +```dart +@override +FutureOr submit() async { + if (!state.status.isValidated) { + return; + } + + emit(state.copyWith(status: FormStatus.submissionInProgress)); + + final form = formRepository.accessForm(formName); + final email = form.valueOf(AuthFormField.email); + + if (email.isNullOrEmpty) { + emit( + state.copyWith( + errorMessage: 'An error occured while retrieving data from the form.', + status: FormStatus.submissionFailure, + ), + ); + } + + final response = await authenticationRepository.sendPasswordResetEmail( + email: email!, + ); + + emit( + response.fold( + (value) => state.copyWith(status: FormStatus.submissionSuccess), + (error) => state.copyWith( + errorMessage: error.message, + status: FormStatus.submissionFailure, + ), + ), + ); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/update.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/update.md new file mode 100644 index 00000000..23388fad --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/update.md @@ -0,0 +1,51 @@ + + + +# update method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> update +(WyattForm form, {SetOperation operation = SetOperation.replace}) + + + + + + + + +## Implementation + +```dart +@override +FutureOr update( + WyattForm form, { + SetOperation operation = SetOperation.replace, +}) { + final WyattForm current = formRepository.accessForm(formName).clone(); + final WyattForm newForm = operation.operation.call(current, form); + formRepository.updateForm(newForm); + + emit( + state.copyWith( + form: newForm, + status: newForm.validate(), + ), + ); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/validate.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/validate.md new file mode 100644 index 00000000..5a8e5519 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/validate.md @@ -0,0 +1,43 @@ + + + +# validate method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> validate +() + + + + + + + + +## Implementation + +```dart +@override +FutureOr validate() { + emit( + state.copyWith( + status: formRepository.accessForm(formName).validate(), + ), + ); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState-class.md new file mode 100644 index 00000000..757a9170 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState-class.md @@ -0,0 +1,169 @@ + + + +# PasswordResetState class + + + + + + + *[](https://dart.dev/null-safety)* + + + + + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [Equatable](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable-class.html) +- PasswordResetState + + + + + + + + +## Constructors + +[PasswordResetState](../wyatt_authentication_bloc/PasswordResetState/PasswordResetState.md) ({required WyattForm form, FormStatus status = FormStatus.pure, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage}) + + _const_ + + +## Properties + +##### [email](../wyatt_authentication_bloc/PasswordResetState/email.md) → Email + + + + +_read-only_ + + + +##### [errorMessage](../wyatt_authentication_bloc/PasswordResetState/errorMessage.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? + + + +Optional error message. +_finalinherited_ + + + +##### [form](../wyatt_authentication_bloc/PasswordResetState/form.md) → WyattForm + + + +FormData with all inputs, and associated metadata. +_finalinherited_ + + + +##### [hashCode](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [props](../wyatt_authentication_bloc/PasswordResetState/props.md) → [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)> + + + +The list of properties that will be used to determine whether +two instances are equal. +_read-only_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + +##### [status](../wyatt_authentication_bloc/PasswordResetState/status.md) → FormStatus + + + +Global status of a form. +_finalinherited_ + + + +##### [stringify](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/stringify.html) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)? + + + +If set to true, the toString method will be overridden to output +this instance's props. +_read-onlyinherited_ + + + + + +## Methods + +##### [copyWith](../wyatt_authentication_bloc/PasswordResetState/copyWith.md)({WyattForm? form, FormStatus? status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage}) [PasswordResetState](../wyatt_authentication_bloc/PasswordResetState-class.md) + + + + + + + + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/PasswordResetState/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_override_ + + + + + +## Operators + +##### [operator ==](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/PasswordResetState.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/PasswordResetState.md new file mode 100644 index 00000000..c6d8f5cf --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/PasswordResetState.md @@ -0,0 +1,34 @@ + + + +# PasswordResetState constructor + + + + + *[](https://dart.dev/null-safety)* + + +const +PasswordResetState({required WyattForm form, FormStatus status = FormStatus.pure, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage}) + + + + + +## Implementation + +```dart +const PasswordResetState({ + required super.form, + super.status = FormStatus.pure, + super.errorMessage, +}); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/copyWith.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/copyWith.md new file mode 100644 index 00000000..60199cc6 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/copyWith.md @@ -0,0 +1,44 @@ + + + +# copyWith method + + + + + *[](https://dart.dev/null-safety)* + + + + +[PasswordResetState](../../wyatt_authentication_bloc/PasswordResetState-class.md) copyWith +({WyattForm? form, FormStatus? status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage}) + + + + + + + + +## Implementation + +```dart +PasswordResetState copyWith({ + WyattForm? form, + FormStatus? status, + String? errorMessage, +}) => + PasswordResetState( + form: form ?? this.form, + status: status ?? this.status, + errorMessage: errorMessage ?? this.errorMessage, + ); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/email.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/email.md new file mode 100644 index 00000000..0e3a2fc7 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/email.md @@ -0,0 +1,36 @@ + + + +# email property + + + + + *[](https://dart.dev/null-safety)* + + + + + +Email email + + + + + + + + +## Implementation + +```dart +Email get email => form.validatorOf(AuthFormField.email); +``` + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/errorMessage.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/errorMessage.md new file mode 100644 index 00000000..d0856deb --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/errorMessage.md @@ -0,0 +1,34 @@ + + + +# errorMessage property + + + + + *[](https://dart.dev/null-safety)* + + + +[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage + +_finalinherited_ + + + +

Optional error message.

+ + + +## Implementation + +```dart +final String? errorMessage; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/form.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/form.md new file mode 100644 index 00000000..d3f2da76 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/form.md @@ -0,0 +1,34 @@ + + + +# form property + + + + + *[](https://dart.dev/null-safety)* + + + +WyattForm form + +_finalinherited_ + + + +

FormData with all inputs, and associated metadata.

+ + + +## Implementation + +```dart +final WyattForm form; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/props.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/props.md new file mode 100644 index 00000000..4665a84e --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/props.md @@ -0,0 +1,42 @@ + + + +# props property + + + + + *[](https://dart.dev/null-safety)* + + + + + +**Annotations** + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) +[List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)> props + + + + + +

The list of properties that will be used to determine whether +two instances are equal.

+ + + +## Implementation + +```dart +@override +List get props => [email, status]; +``` + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/status.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/status.md new file mode 100644 index 00000000..644a9f10 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/status.md @@ -0,0 +1,34 @@ + + + +# status property + + + + + *[](https://dart.dev/null-safety)* + + + +FormStatus status + +_finalinherited_ + + + +

Global status of a form.

+ + + +## Implementation + +```dart +final FormStatus status; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/toString.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/toString.md new file mode 100644 index 00000000..d40bc441 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/toString.md @@ -0,0 +1,48 @@ + + + +# toString method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[String](https://api.flutter.dev/flutter/dart-core/String-class.html) toString +() + +_override_ + + + +

A string representation of this object.

+

Some classes have a default textual representation, +often paired with a static parse function (like int.parse). +These classes will provide the textual representation as +their string representation.

+

Other classes have no meaningful textual representation +that a program will care about. +Such classes will typically override toString to provide +useful information when inspecting the object, +mainly for debugging or logging.

+ + + +## Implementation + +```dart +@override +String toString() => 'PasswordResetState(status: ${status.name} ' + '${(errorMessage != null) ? " [$errorMessage]" : ""}, $form)'; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticateFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticateFailureFirebase-class.md new file mode 100644 index 00000000..527e46f4 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticateFailureFirebase-class.md @@ -0,0 +1,137 @@ + + + +# ReauthenticateFailureFirebase class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown during the reauthentication process if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- [ReauthenticateFailureInterface](../wyatt_authentication_bloc/ReauthenticateFailureInterface-class.md) +- ReauthenticateFailureFirebase + + + + + + + + +## Constructors + +[ReauthenticateFailureFirebase](../wyatt_authentication_bloc/ReauthenticateFailureFirebase/ReauthenticateFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + +[ReauthenticateFailureFirebase.fromCode](../wyatt_authentication_bloc/ReauthenticateFailureFirebase/ReauthenticateFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticateFailureFirebase/ReauthenticateFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticateFailureFirebase/ReauthenticateFailureFirebase.fromCode.md new file mode 100644 index 00000000..6ad6eccc --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticateFailureFirebase/ReauthenticateFailureFirebase.fromCode.md @@ -0,0 +1,57 @@ + + + +# ReauthenticateFailureFirebase.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +ReauthenticateFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + + +## Implementation + +```dart +ReauthenticateFailureFirebase.fromCode(String code) : super.fromCode(code) { + switch (code) { + case 'user-mismatch': + msg = 'Given credential does not correspond to the user.'; + break; + case 'user-not-found': + msg = 'User is not found, please create an account.'; + break; + case 'invalid-credential': + msg = 'The credential received is malformed or has expired.'; + break; + case 'invalid-email': + msg = 'Email is not valid or badly formatted.'; + break; + case 'wrong-password': + msg = 'Incorrect password, please try again.'; + break; + case 'invalid-verification-code': + msg = 'The credential verification code received is invalid.'; + break; + case 'invalid-verification-id': + msg = 'The credential verification ID received is invalid.'; + break; + default: + this.code = 'unknown'; + msg = 'An unknown error occurred.'; + } +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticateFailureFirebase/ReauthenticateFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticateFailureFirebase/ReauthenticateFailureFirebase.md new file mode 100644 index 00000000..e386d710 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticateFailureFirebase/ReauthenticateFailureFirebase.md @@ -0,0 +1,31 @@ + + + +# ReauthenticateFailureFirebase constructor + + + + + *[](https://dart.dev/null-safety)* + + + +ReauthenticateFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + + + +## Implementation + +```dart +ReauthenticateFailureFirebase([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticateFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticateFailureInterface-class.md new file mode 100644 index 00000000..7c36e2c0 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticateFailureInterface-class.md @@ -0,0 +1,139 @@ + + + +# ReauthenticateFailureInterface class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown during the reauthentication process if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- ReauthenticateFailureInterface + + + +**Implementers** + +- [ReauthenticateFailureFirebase](../wyatt_authentication_bloc/ReauthenticateFailureFirebase-class.md) + + + + + +## Constructors + +[ReauthenticateFailureInterface](../wyatt_authentication_bloc/ReauthenticateFailureInterface/ReauthenticateFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + + + +[ReauthenticateFailureInterface.fromCode](../wyatt_authentication_bloc/ReauthenticateFailureInterface/ReauthenticateFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticateFailureInterface/ReauthenticateFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticateFailureInterface/ReauthenticateFailureInterface.fromCode.md new file mode 100644 index 00000000..c8d73b99 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticateFailureInterface/ReauthenticateFailureInterface.fromCode.md @@ -0,0 +1,30 @@ + + + +# ReauthenticateFailureInterface.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +ReauthenticateFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + + +## Implementation + +```dart +ReauthenticateFailureInterface.fromCode(super.code) : super.fromCode(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticateFailureInterface/ReauthenticateFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticateFailureInterface/ReauthenticateFailureInterface.md new file mode 100644 index 00000000..511d8024 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticateFailureInterface/ReauthenticateFailureInterface.md @@ -0,0 +1,30 @@ + + + +# ReauthenticateFailureInterface constructor + + + + + *[](https://dart.dev/null-safety)* + + + +ReauthenticateFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + + + + + +## Implementation + +```dart +ReauthenticateFailureInterface(super.code, super.msg); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticatedEvent-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticatedEvent-class.md new file mode 100644 index 00000000..1184c6f3 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticatedEvent-class.md @@ -0,0 +1,137 @@ + + + +# ReauthenticatedEvent class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

When a user re-authenticates (from the logged in state to the +logged in state with a different and fresh access +token and a different login time)

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [Equatable](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable-class.html) +- [AuthenticationChangeEvent](../wyatt_authentication_bloc/AuthenticationChangeEvent-class.md) +- ReauthenticatedEvent + + + + + + + + +## Constructors + +[ReauthenticatedEvent](../wyatt_authentication_bloc/ReauthenticatedEvent/ReauthenticatedEvent.md) ({required [Account](../wyatt_authentication_bloc/Account-class.md) account}) + + _const_ + + +## Properties + +##### [account](../wyatt_authentication_bloc/ReauthenticatedEvent/account.md) → [Account](../wyatt_authentication_bloc/Account-class.md) + + + + +_final_ + + + +##### [hashCode](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [props](../wyatt_authentication_bloc/ReauthenticatedEvent/props.md) → [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> + + + +The list of properties that will be used to determine whether +two instances are equal. +_read-onlyoverride_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + +##### [stringify](../wyatt_authentication_bloc/AuthenticationChangeEvent/stringify.md) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +If set to true, the toString method will be overridden to output +this instance's props. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticatedEvent/ReauthenticatedEvent.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticatedEvent/ReauthenticatedEvent.md new file mode 100644 index 00000000..3b8ba4c3 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticatedEvent/ReauthenticatedEvent.md @@ -0,0 +1,30 @@ + + + +# ReauthenticatedEvent constructor + + + + + *[](https://dart.dev/null-safety)* + + +const +ReauthenticatedEvent({required [Account](../../wyatt_authentication_bloc/Account-class.md) account}) + + + + + +## Implementation + +```dart +const ReauthenticatedEvent({required this.account}); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticatedEvent/account.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticatedEvent/account.md new file mode 100644 index 00000000..671e197e --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticatedEvent/account.md @@ -0,0 +1,33 @@ + + + +# account property + + + + + *[](https://dart.dev/null-safety)* + + + +[Account](../../wyatt_authentication_bloc/Account-class.md) account + +_final_ + + + + + + +## Implementation + +```dart +final Account account; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticatedEvent/props.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticatedEvent/props.md new file mode 100644 index 00000000..fbde09d1 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticatedEvent/props.md @@ -0,0 +1,42 @@ + + + +# props property + + + + + *[](https://dart.dev/null-safety)* + + + + + +**Annotations** + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) +[List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> props + +_override_ + + + +

The list of properties that will be used to determine whether +two instances are equal.

+ + + +## Implementation + +```dart +@override +List get props => [account]; +``` + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshFailureFirebase-class.md new file mode 100644 index 00000000..32cdc623 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshFailureFirebase-class.md @@ -0,0 +1,137 @@ + + + +# RefreshFailureFirebase class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown during the refresh process if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- [RefreshFailureInterface](../wyatt_authentication_bloc/RefreshFailureInterface-class.md) +- RefreshFailureFirebase + + + + + + + + +## Constructors + +[RefreshFailureFirebase](../wyatt_authentication_bloc/RefreshFailureFirebase/RefreshFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + +[RefreshFailureFirebase.fromCode](../wyatt_authentication_bloc/RefreshFailureFirebase/RefreshFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshFailureFirebase/RefreshFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshFailureFirebase/RefreshFailureFirebase.fromCode.md new file mode 100644 index 00000000..4b2cce16 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshFailureFirebase/RefreshFailureFirebase.fromCode.md @@ -0,0 +1,30 @@ + + + +# RefreshFailureFirebase.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +RefreshFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + + +## Implementation + +```dart +RefreshFailureFirebase.fromCode(super.code) : super.fromCode(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshFailureFirebase/RefreshFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshFailureFirebase/RefreshFailureFirebase.md new file mode 100644 index 00000000..4ac4faee --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshFailureFirebase/RefreshFailureFirebase.md @@ -0,0 +1,31 @@ + + + +# RefreshFailureFirebase constructor + + + + + *[](https://dart.dev/null-safety)* + + + +RefreshFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + + + +## Implementation + +```dart +RefreshFailureFirebase([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshFailureInterface-class.md new file mode 100644 index 00000000..f485f140 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshFailureInterface-class.md @@ -0,0 +1,139 @@ + + + +# RefreshFailureInterface class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown during the refresh process if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- RefreshFailureInterface + + + +**Implementers** + +- [RefreshFailureFirebase](../wyatt_authentication_bloc/RefreshFailureFirebase-class.md) + + + + + +## Constructors + +[RefreshFailureInterface](../wyatt_authentication_bloc/RefreshFailureInterface/RefreshFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + +Thrown during the refresh process if a failure occurs. + +[RefreshFailureInterface.fromCode](../wyatt_authentication_bloc/RefreshFailureInterface/RefreshFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + +Thrown during the refresh process if a failure occurs. + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshFailureInterface/RefreshFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshFailureInterface/RefreshFailureInterface.fromCode.md new file mode 100644 index 00000000..33b4dace --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshFailureInterface/RefreshFailureInterface.fromCode.md @@ -0,0 +1,31 @@ + + + +# RefreshFailureInterface.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +RefreshFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + +

Thrown during the refresh process if a failure occurs.

+ + + +## Implementation + +```dart +RefreshFailureInterface.fromCode(super.code) : super.fromCode(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshFailureInterface/RefreshFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshFailureInterface/RefreshFailureInterface.md new file mode 100644 index 00000000..a958f830 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshFailureInterface/RefreshFailureInterface.md @@ -0,0 +1,31 @@ + + + +# RefreshFailureInterface constructor + + + + + *[](https://dart.dev/null-safety)* + + + +RefreshFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + + +

Thrown during the refresh process if a failure occurs.

+ + + +## Implementation + +```dart +RefreshFailureInterface(super.code, super.msg); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshedEvent-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshedEvent-class.md new file mode 100644 index 00000000..bdca95f0 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshedEvent-class.md @@ -0,0 +1,136 @@ + + + +# RefreshedEvent class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

When a user access token is refreshed (from the logged in state to the +logged in state with a different access token)

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [Equatable](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable-class.html) +- [AuthenticationChangeEvent](../wyatt_authentication_bloc/AuthenticationChangeEvent-class.md) +- RefreshedEvent + + + + + + + + +## Constructors + +[RefreshedEvent](../wyatt_authentication_bloc/RefreshedEvent/RefreshedEvent.md) ({required [Account](../wyatt_authentication_bloc/Account-class.md) account}) + + _const_ + + +## Properties + +##### [account](../wyatt_authentication_bloc/RefreshedEvent/account.md) → [Account](../wyatt_authentication_bloc/Account-class.md) + + + + +_final_ + + + +##### [hashCode](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [props](../wyatt_authentication_bloc/RefreshedEvent/props.md) → [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> + + + +The list of properties that will be used to determine whether +two instances are equal. +_read-onlyoverride_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + +##### [stringify](../wyatt_authentication_bloc/AuthenticationChangeEvent/stringify.md) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +If set to true, the toString method will be overridden to output +this instance's props. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshedEvent/RefreshedEvent.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshedEvent/RefreshedEvent.md new file mode 100644 index 00000000..7317339e --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshedEvent/RefreshedEvent.md @@ -0,0 +1,30 @@ + + + +# RefreshedEvent constructor + + + + + *[](https://dart.dev/null-safety)* + + +const +RefreshedEvent({required [Account](../../wyatt_authentication_bloc/Account-class.md) account}) + + + + + +## Implementation + +```dart +const RefreshedEvent({required this.account}); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshedEvent/account.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshedEvent/account.md new file mode 100644 index 00000000..671e197e --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshedEvent/account.md @@ -0,0 +1,33 @@ + + + +# account property + + + + + *[](https://dart.dev/null-safety)* + + + +[Account](../../wyatt_authentication_bloc/Account-class.md) account + +_final_ + + + + + + +## Implementation + +```dart +final Account account; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshedEvent/props.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshedEvent/props.md new file mode 100644 index 00000000..fbde09d1 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshedEvent/props.md @@ -0,0 +1,42 @@ + + + +# props property + + + + + *[](https://dart.dev/null-safety)* + + + + + +**Annotations** + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) +[List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> props + +_override_ + + + +

The list of properties that will be used to determine whether +two instances are equal.

+ + + +## Implementation + +```dart +@override +List get props => [account]; +``` + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendEmailVerificationFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendEmailVerificationFailureFirebase-class.md new file mode 100644 index 00000000..813d225c --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendEmailVerificationFailureFirebase-class.md @@ -0,0 +1,137 @@ + + + +# SendEmailVerificationFailureFirebase class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown during the email verification process if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- [SendEmailVerificationFailureInterface](../wyatt_authentication_bloc/SendEmailVerificationFailureInterface-class.md) +- SendEmailVerificationFailureFirebase + + + + + + + + +## Constructors + +[SendEmailVerificationFailureFirebase](../wyatt_authentication_bloc/SendEmailVerificationFailureFirebase/SendEmailVerificationFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + +[SendEmailVerificationFailureFirebase.fromCode](../wyatt_authentication_bloc/SendEmailVerificationFailureFirebase/SendEmailVerificationFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendEmailVerificationFailureFirebase/SendEmailVerificationFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendEmailVerificationFailureFirebase/SendEmailVerificationFailureFirebase.fromCode.md new file mode 100644 index 00000000..51531fd7 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendEmailVerificationFailureFirebase/SendEmailVerificationFailureFirebase.fromCode.md @@ -0,0 +1,30 @@ + + + +# SendEmailVerificationFailureFirebase.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SendEmailVerificationFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + + +## Implementation + +```dart +SendEmailVerificationFailureFirebase.fromCode(super.code) : super.fromCode(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendEmailVerificationFailureFirebase/SendEmailVerificationFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendEmailVerificationFailureFirebase/SendEmailVerificationFailureFirebase.md new file mode 100644 index 00000000..e1f740ba --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendEmailVerificationFailureFirebase/SendEmailVerificationFailureFirebase.md @@ -0,0 +1,31 @@ + + + +# SendEmailVerificationFailureFirebase constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SendEmailVerificationFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + + + +## Implementation + +```dart +SendEmailVerificationFailureFirebase([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendEmailVerificationFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendEmailVerificationFailureInterface-class.md new file mode 100644 index 00000000..42fff498 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendEmailVerificationFailureInterface-class.md @@ -0,0 +1,139 @@ + + + +# SendEmailVerificationFailureInterface class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown during the email verification process if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- SendEmailVerificationFailureInterface + + + +**Implementers** + +- [SendEmailVerificationFailureFirebase](../wyatt_authentication_bloc/SendEmailVerificationFailureFirebase-class.md) + + + + + +## Constructors + +[SendEmailVerificationFailureInterface](../wyatt_authentication_bloc/SendEmailVerificationFailureInterface/SendEmailVerificationFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + +Thrown during the email verification process if a failure occurs. + +[SendEmailVerificationFailureInterface.fromCode](../wyatt_authentication_bloc/SendEmailVerificationFailureInterface/SendEmailVerificationFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + +Thrown during the email verification process if a failure occurs. + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendEmailVerificationFailureInterface/SendEmailVerificationFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendEmailVerificationFailureInterface/SendEmailVerificationFailureInterface.fromCode.md new file mode 100644 index 00000000..26acc0c1 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendEmailVerificationFailureInterface/SendEmailVerificationFailureInterface.fromCode.md @@ -0,0 +1,31 @@ + + + +# SendEmailVerificationFailureInterface.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SendEmailVerificationFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + +

Thrown during the email verification process if a failure occurs.

+ + + +## Implementation + +```dart +SendEmailVerificationFailureInterface.fromCode(super.code) : super.fromCode(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendEmailVerificationFailureInterface/SendEmailVerificationFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendEmailVerificationFailureInterface/SendEmailVerificationFailureInterface.md new file mode 100644 index 00000000..aeda1679 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendEmailVerificationFailureInterface/SendEmailVerificationFailureInterface.md @@ -0,0 +1,31 @@ + + + +# SendEmailVerificationFailureInterface constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SendEmailVerificationFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + + +

Thrown during the email verification process if a failure occurs.

+ + + +## Implementation + +```dart +SendEmailVerificationFailureInterface(super.code, super.msg); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendPasswordResetEmailFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendPasswordResetEmailFailureFirebase-class.md new file mode 100644 index 00000000..55b4b215 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendPasswordResetEmailFailureFirebase-class.md @@ -0,0 +1,137 @@ + + + +# SendPasswordResetEmailFailureFirebase class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown during the password reset process if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- [SendPasswordResetEmailFailureInterface](../wyatt_authentication_bloc/SendPasswordResetEmailFailureInterface-class.md) +- SendPasswordResetEmailFailureFirebase + + + + + + + + +## Constructors + +[SendPasswordResetEmailFailureFirebase](../wyatt_authentication_bloc/SendPasswordResetEmailFailureFirebase/SendPasswordResetEmailFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + +[SendPasswordResetEmailFailureFirebase.fromCode](../wyatt_authentication_bloc/SendPasswordResetEmailFailureFirebase/SendPasswordResetEmailFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendPasswordResetEmailFailureFirebase/SendPasswordResetEmailFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendPasswordResetEmailFailureFirebase/SendPasswordResetEmailFailureFirebase.fromCode.md new file mode 100644 index 00000000..7b002359 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendPasswordResetEmailFailureFirebase/SendPasswordResetEmailFailureFirebase.fromCode.md @@ -0,0 +1,30 @@ + + + +# SendPasswordResetEmailFailureFirebase.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SendPasswordResetEmailFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + + +## Implementation + +```dart +SendPasswordResetEmailFailureFirebase.fromCode(super.code) : super.fromCode(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendPasswordResetEmailFailureFirebase/SendPasswordResetEmailFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendPasswordResetEmailFailureFirebase/SendPasswordResetEmailFailureFirebase.md new file mode 100644 index 00000000..e2fdbeab --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendPasswordResetEmailFailureFirebase/SendPasswordResetEmailFailureFirebase.md @@ -0,0 +1,31 @@ + + + +# SendPasswordResetEmailFailureFirebase constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SendPasswordResetEmailFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + + + +## Implementation + +```dart +SendPasswordResetEmailFailureFirebase([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendPasswordResetEmailFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendPasswordResetEmailFailureInterface-class.md new file mode 100644 index 00000000..6473ac89 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendPasswordResetEmailFailureInterface-class.md @@ -0,0 +1,139 @@ + + + +# SendPasswordResetEmailFailureInterface class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown during the password reset process if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- SendPasswordResetEmailFailureInterface + + + +**Implementers** + +- [SendPasswordResetEmailFailureFirebase](../wyatt_authentication_bloc/SendPasswordResetEmailFailureFirebase-class.md) + + + + + +## Constructors + +[SendPasswordResetEmailFailureInterface](../wyatt_authentication_bloc/SendPasswordResetEmailFailureInterface/SendPasswordResetEmailFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + +Thrown during the password reset process if a failure occurs. + +[SendPasswordResetEmailFailureInterface.fromCode](../wyatt_authentication_bloc/SendPasswordResetEmailFailureInterface/SendPasswordResetEmailFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + +Thrown during the password reset process if a failure occurs. + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendPasswordResetEmailFailureInterface/SendPasswordResetEmailFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendPasswordResetEmailFailureInterface/SendPasswordResetEmailFailureInterface.fromCode.md new file mode 100644 index 00000000..039bd78b --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendPasswordResetEmailFailureInterface/SendPasswordResetEmailFailureInterface.fromCode.md @@ -0,0 +1,32 @@ + + + +# SendPasswordResetEmailFailureInterface.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SendPasswordResetEmailFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + +

Thrown during the password reset process if a failure occurs.

+ + + +## Implementation + +```dart +SendPasswordResetEmailFailureInterface.fromCode(super.code) + : super.fromCode(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendPasswordResetEmailFailureInterface/SendPasswordResetEmailFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendPasswordResetEmailFailureInterface/SendPasswordResetEmailFailureInterface.md new file mode 100644 index 00000000..cec0a974 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendPasswordResetEmailFailureInterface/SendPasswordResetEmailFailureInterface.md @@ -0,0 +1,31 @@ + + + +# SendPasswordResetEmailFailureInterface constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SendPasswordResetEmailFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + + +

Thrown during the password reset process if a failure occurs.

+ + + +## Implementation + +```dart +SendPasswordResetEmailFailureInterface(super.code, super.msg); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendSignInLinkEmailFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendSignInLinkEmailFailureFirebase-class.md new file mode 100644 index 00000000..b487ad39 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendSignInLinkEmailFailureFirebase-class.md @@ -0,0 +1,137 @@ + + + +# SendSignInLinkEmailFailureFirebase class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown during the sign in link process if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- [SendSignInLinkEmailFailureInterface](../wyatt_authentication_bloc/SendSignInLinkEmailFailureInterface-class.md) +- SendSignInLinkEmailFailureFirebase + + + + + + + + +## Constructors + +[SendSignInLinkEmailFailureFirebase](../wyatt_authentication_bloc/SendSignInLinkEmailFailureFirebase/SendSignInLinkEmailFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + +[SendSignInLinkEmailFailureFirebase.fromCode](../wyatt_authentication_bloc/SendSignInLinkEmailFailureFirebase/SendSignInLinkEmailFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendSignInLinkEmailFailureFirebase/SendSignInLinkEmailFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendSignInLinkEmailFailureFirebase/SendSignInLinkEmailFailureFirebase.fromCode.md new file mode 100644 index 00000000..11ea5805 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendSignInLinkEmailFailureFirebase/SendSignInLinkEmailFailureFirebase.fromCode.md @@ -0,0 +1,30 @@ + + + +# SendSignInLinkEmailFailureFirebase.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SendSignInLinkEmailFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + + +## Implementation + +```dart +SendSignInLinkEmailFailureFirebase.fromCode(super.code) : super.fromCode(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendSignInLinkEmailFailureFirebase/SendSignInLinkEmailFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendSignInLinkEmailFailureFirebase/SendSignInLinkEmailFailureFirebase.md new file mode 100644 index 00000000..27c3a9b9 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendSignInLinkEmailFailureFirebase/SendSignInLinkEmailFailureFirebase.md @@ -0,0 +1,31 @@ + + + +# SendSignInLinkEmailFailureFirebase constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SendSignInLinkEmailFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + + + +## Implementation + +```dart +SendSignInLinkEmailFailureFirebase([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendSignInLinkEmailFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendSignInLinkEmailFailureInterface-class.md new file mode 100644 index 00000000..b1887411 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendSignInLinkEmailFailureInterface-class.md @@ -0,0 +1,139 @@ + + + +# SendSignInLinkEmailFailureInterface class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown during the sign in link process if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- SendSignInLinkEmailFailureInterface + + + +**Implementers** + +- [SendSignInLinkEmailFailureFirebase](../wyatt_authentication_bloc/SendSignInLinkEmailFailureFirebase-class.md) + + + + + +## Constructors + +[SendSignInLinkEmailFailureInterface](../wyatt_authentication_bloc/SendSignInLinkEmailFailureInterface/SendSignInLinkEmailFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + +Thrown during the sign in link process if a failure occurs. + +[SendSignInLinkEmailFailureInterface.fromCode](../wyatt_authentication_bloc/SendSignInLinkEmailFailureInterface/SendSignInLinkEmailFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + +Thrown during the sign in link process if a failure occurs. + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendSignInLinkEmailFailureInterface/SendSignInLinkEmailFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendSignInLinkEmailFailureInterface/SendSignInLinkEmailFailureInterface.fromCode.md new file mode 100644 index 00000000..6e8ab76a --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendSignInLinkEmailFailureInterface/SendSignInLinkEmailFailureInterface.fromCode.md @@ -0,0 +1,31 @@ + + + +# SendSignInLinkEmailFailureInterface.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SendSignInLinkEmailFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + +

Thrown during the sign in link process if a failure occurs.

+ + + +## Implementation + +```dart +SendSignInLinkEmailFailureInterface.fromCode(super.code) : super.fromCode(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendSignInLinkEmailFailureInterface/SendSignInLinkEmailFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendSignInLinkEmailFailureInterface/SendSignInLinkEmailFailureInterface.md new file mode 100644 index 00000000..eba02b41 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendSignInLinkEmailFailureInterface/SendSignInLinkEmailFailureInterface.md @@ -0,0 +1,31 @@ + + + +# SendSignInLinkEmailFailureInterface constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SendSignInLinkEmailFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + + +

Thrown during the sign in link process if a failure occurs.

+ + + +## Implementation + +```dart +SendSignInLinkEmailFailureInterface(super.code, super.msg); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Session-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Session-class.md new file mode 100644 index 00000000..29cc3040 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Session-class.md @@ -0,0 +1,144 @@ + + + +# Session<Data> class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

The Session object is used to transport and propagate +the connected user Account and personalized Data in the application.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [Equatable](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable-class.html) +- Session + + + + + + + + +## Constructors + +[Session](../wyatt_authentication_bloc/Session/Session.md) ({required [Account](../wyatt_authentication_bloc/Account-class.md) account, Data? data}) + + _const_ + + +## Properties + +##### [account](../wyatt_authentication_bloc/Session/account.md) → [Account](../wyatt_authentication_bloc/Account-class.md) + + + + +_final_ + + + +##### [data](../wyatt_authentication_bloc/Session/data.md) → Data? + + + + +_final_ + + + +##### [hashCode](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [props](../wyatt_authentication_bloc/Session/props.md) → [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> + + + +The list of properties that will be used to determine whether +two instances are equal. +_read-onlyoverride_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + +##### [stringify](../wyatt_authentication_bloc/Session/stringify.md) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)? + + + +If set to true, the toString method will be overridden to output +this instance's props. +_read-onlyoverride_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Session/Session.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Session/Session.md new file mode 100644 index 00000000..f8c9a635 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Session/Session.md @@ -0,0 +1,33 @@ + + + +# Session<Data> constructor + + + + + *[](https://dart.dev/null-safety)* + + +const +Session<Data>({required [Account](../../wyatt_authentication_bloc/Account-class.md) account, Data? data}) + + + + + +## Implementation + +```dart +const Session({ + required this.account, + this.data, +}); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Session/account.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Session/account.md new file mode 100644 index 00000000..671e197e --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Session/account.md @@ -0,0 +1,33 @@ + + + +# account property + + + + + *[](https://dart.dev/null-safety)* + + + +[Account](../../wyatt_authentication_bloc/Account-class.md) account + +_final_ + + + + + + +## Implementation + +```dart +final Account account; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Session/data.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Session/data.md new file mode 100644 index 00000000..b95c07e1 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Session/data.md @@ -0,0 +1,33 @@ + + + +# data property + + + + + *[](https://dart.dev/null-safety)* + + + +Data? data + +_final_ + + + + + + +## Implementation + +```dart +final Data? data; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Session/props.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Session/props.md new file mode 100644 index 00000000..5246eb8f --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Session/props.md @@ -0,0 +1,42 @@ + + + +# props property + + + + + *[](https://dart.dev/null-safety)* + + + + + +**Annotations** + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) +[List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> props + +_override_ + + + +

The list of properties that will be used to determine whether +two instances are equal.

+ + + +## Implementation + +```dart +@override +List get props => [account, data]; +``` + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Session/stringify.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Session/stringify.md new file mode 100644 index 00000000..c2fc4fca --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Session/stringify.md @@ -0,0 +1,47 @@ + + + +# stringify property + + + + + *[](https://dart.dev/null-safety)* + + + + + +**Annotations** + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) +[bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)? stringify + +_override_ + + + +

If set to true, the toString method will be overridden to output +this instance's props.

+

A global default value for stringify can be set using +EquatableConfig.stringify.

+

If this instance's stringify is set to null, the value of +EquatableConfig.stringify will be used instead. This defaults to +false.

+ + + +## Implementation + +```dart +@override +bool? get stringify => true; +``` + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SessionWrapper-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SessionWrapper-class.md new file mode 100644 index 00000000..dd0d4a9d --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SessionWrapper-class.md @@ -0,0 +1,144 @@ + + + +# SessionWrapper<Data> class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Contains the AuthenticationChangeEvent initiating the state +change and the current Session.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [Equatable](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable-class.html) +- SessionWrapper + + + + + + + + +## Constructors + +[SessionWrapper](../wyatt_authentication_bloc/SessionWrapper/SessionWrapper.md) ({required [AuthenticationChangeEvent](../wyatt_authentication_bloc/AuthenticationChangeEvent-class.md) event, [Session](../wyatt_authentication_bloc/Session-class.md)<Data>? session}) + + _const_ + + +## Properties + +##### [event](../wyatt_authentication_bloc/SessionWrapper/event.md) → [AuthenticationChangeEvent](../wyatt_authentication_bloc/AuthenticationChangeEvent-class.md) + + + + +_final_ + + + +##### [hashCode](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [props](../wyatt_authentication_bloc/SessionWrapper/props.md) → [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> + + + +The list of properties that will be used to determine whether +two instances are equal. +_read-onlyoverride_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + +##### [session](../wyatt_authentication_bloc/SessionWrapper/session.md) → [Session](../wyatt_authentication_bloc/Session-class.md)<Data>? + + + + +_final_ + + + +##### [stringify](../wyatt_authentication_bloc/SessionWrapper/stringify.md) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +If set to true, the toString method will be overridden to output +this instance's props. +_read-onlyoverride_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SessionWrapper/SessionWrapper.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SessionWrapper/SessionWrapper.md new file mode 100644 index 00000000..d26a9969 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SessionWrapper/SessionWrapper.md @@ -0,0 +1,33 @@ + + + +# SessionWrapper<Data> constructor + + + + + *[](https://dart.dev/null-safety)* + + +const +SessionWrapper<Data>({required [AuthenticationChangeEvent](../../wyatt_authentication_bloc/AuthenticationChangeEvent-class.md) event, [Session](../../wyatt_authentication_bloc/Session-class.md)<Data>? session}) + + + + + +## Implementation + +```dart +const SessionWrapper({ + required this.event, + this.session, +}); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SessionWrapper/event.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SessionWrapper/event.md new file mode 100644 index 00000000..a1e5da09 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SessionWrapper/event.md @@ -0,0 +1,33 @@ + + + +# event property + + + + + *[](https://dart.dev/null-safety)* + + + +[AuthenticationChangeEvent](../../wyatt_authentication_bloc/AuthenticationChangeEvent-class.md) event + +_final_ + + + + + + +## Implementation + +```dart +final AuthenticationChangeEvent event; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SessionWrapper/props.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SessionWrapper/props.md new file mode 100644 index 00000000..318648ca --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SessionWrapper/props.md @@ -0,0 +1,42 @@ + + + +# props property + + + + + *[](https://dart.dev/null-safety)* + + + + + +**Annotations** + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) +[List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> props + +_override_ + + + +

The list of properties that will be used to determine whether +two instances are equal.

+ + + +## Implementation + +```dart +@override +List get props => [event, session]; +``` + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SessionWrapper/session.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SessionWrapper/session.md new file mode 100644 index 00000000..a713c2af --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SessionWrapper/session.md @@ -0,0 +1,33 @@ + + + +# session property + + + + + *[](https://dart.dev/null-safety)* + + + +[Session](../../wyatt_authentication_bloc/Session-class.md)<Data>? session + +_final_ + + + + + + +## Implementation + +```dart +final Session? session; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SessionWrapper/stringify.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SessionWrapper/stringify.md new file mode 100644 index 00000000..4fe942de --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SessionWrapper/stringify.md @@ -0,0 +1,47 @@ + + + +# stringify property + + + + + *[](https://dart.dev/null-safety)* + + + + + +**Annotations** + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) +[bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) stringify + +_override_ + + + +

If set to true, the toString method will be overridden to output +this instance's props.

+

A global default value for stringify can be set using +EquatableConfig.stringify.

+

If this instance's stringify is set to null, the value of +EquatableConfig.stringify will be used instead. This defaults to +false.

+ + + +## Implementation + +```dart +@override +bool get stringify => true; +``` + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymously-mixin.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymously-mixin.md new file mode 100644 index 00000000..3dd086b7 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymously-mixin.md @@ -0,0 +1,269 @@ + + + +# SignInAnonymously<Data> mixin + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Sign in mixin.

+

Allows the user to sign in anonymously

+

Gives access to the signInAnonymously method and +onSignInAnonymously callback.

+ + +**Superclass Constraints** + +- [BaseSignInCubit](../wyatt_authentication_bloc/BaseSignInCubit-class.md)<Data> + + + + +**Mixin Applications** + +- [SignInCubit](../wyatt_authentication_bloc/SignInCubit-class.md) + + + +## Properties + +##### [authenticationRepository](../wyatt_authentication_bloc/BaseSignInCubit/authenticationRepository.md) → [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> + + + + +_finalinherited_ + + + +##### [formName](../wyatt_authentication_bloc/BaseSignInCubit/formName.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [formRepository](../wyatt_authentication_bloc/BaseSignInCubit/formRepository.md) → FormRepository + + + + +_read-onlyinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [isClosed](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/isClosed.html) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +Whether the bloc is closed. +_read-onlyinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + +##### [state](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/state.html) → [SignInState](../wyatt_authentication_bloc/SignInState-class.md) + + + +The current state. +_read-onlyinherited_ + + + +##### [stream](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/stream.html) → [Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[SignInState](../wyatt_authentication_bloc/SignInState-class.md)> + + + +The current stream of states. +_read-onlyinherited_ + + + + + +## Methods + +##### [addError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/addError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [[StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html)? stackTrace]) void + + + +Reports an error which triggers onError with an optional StackTrace. +_inherited_ + + + +##### [close](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/close.html)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> + + + +Closes the instance. +This method should be called when the instance is no longer needed. +Once close is called, the instance can no longer be used. +_inherited_ + + + +##### [dataChanged](../wyatt_authentication_bloc/BaseSignInCubit/dataChanged.md)<Value>([String](https://api.flutter.dev/flutter/dart-core/String-class.html) key, FormInputValidator<Value, ValidationError> dirtyValue) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + +##### [emit](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/emit.html)([SignInState](../wyatt_authentication_bloc/SignInState-class.md) state) void + + + +Updates the state to the provided state. +emit does nothing if the state being emitted +is equal to the current state. +_inherited_ + + + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [onChange](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onChange.html)([Change](https://pub.dev/documentation/bloc/8.1.0/bloc/Change-class.html)<[SignInState](../wyatt_authentication_bloc/SignInState-class.md)> change) void + + + +Called whenever a change occurs with the given change. +A change occurs when a new state is emitted. +onChange is called before the state of the cubit is updated. +onChange is a great spot to add logging/analytics for a specific cubit. +_inherited_ + + + +##### [onError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html) stackTrace) void + + + +Called whenever an error occurs and notifies BlocObserver.onError. +_inherited_ + + + +##### [onSignInAnonymously](../wyatt_authentication_bloc/SignInAnonymously/onSignInAnonymously.md)(Result<[Account](../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) FutureOrResult<Data?> + + + +This callback is triggered when a user signs in anonymously. + + + + +##### [reset](../wyatt_authentication_bloc/BaseSignInCubit/reset.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + +##### [signInAnonymously](../wyatt_authentication_bloc/SignInAnonymously/signInAnonymously.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + +Sign in anonymously. + + + + +##### [submit](../wyatt_authentication_bloc/BaseSignInCubit/submit.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + +##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + +##### [update](../wyatt_authentication_bloc/BaseSignInCubit/update.md)(WyattForm form, {SetOperation operation = SetOperation.replace}) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + +##### [validate](../wyatt_authentication_bloc/BaseSignInCubit/validate.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymously/onSignInAnonymously.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymously/onSignInAnonymously.md new file mode 100644 index 00000000..fa83d0b9 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymously/onSignInAnonymously.md @@ -0,0 +1,39 @@ + + + +# onSignInAnonymously method + + + + + *[](https://dart.dev/null-safety)* + + + + +FutureOrResult<Data?> onSignInAnonymously +(Result<[Account](../../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) + + + + + +

This callback is triggered when a user signs in anonymously.

+ + + +## Implementation + +```dart +FutureOrResult onSignInAnonymously( + Result result, + WyattForm form, +); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymously/signInAnonymously.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymously/signInAnonymously.md new file mode 100644 index 00000000..0c21eeb5 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymously/signInAnonymously.md @@ -0,0 +1,79 @@ + + + +# signInAnonymously method + + + + + *[](https://dart.dev/null-safety)* + + + + +[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> signInAnonymously +() + + + + + +

Sign in anonymously.

+

Throws a SignInAnonymouslyFailureInterface if an exception occurs.

+ + + +## Implementation + +```dart +FutureOr signInAnonymously() async { + if (state.status.isSubmissionInProgress) { + return; + } + + final form = formRepository.accessForm(formName); + emit(SignInState(form: form, status: FormStatus.submissionInProgress)); + + return CustomRoutine( + routine: authenticationRepository.signInAnonymously, + attachedLogic: (routineResult) => onSignInAnonymously( + routineResult, + form, + ), + onError: (error) { + emit( + SignInState( + form: form, + errorMessage: error.message, + status: FormStatus.submissionFailure, + ), + ); + addError(error); + }, + onSuccess: (account, data) { + authenticationRepository.addSession( + SessionWrapper( + event: SignedInEvent(account: account), + session: Session( + account: account, + data: data, + ), + ), + ); + emit( + SignInState( + form: form, + status: FormStatus.submissionSuccess, + ), + ); + }, + ).call(); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymouslyFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymouslyFailureFirebase-class.md new file mode 100644 index 00000000..23458a20 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymouslyFailureFirebase-class.md @@ -0,0 +1,137 @@ + + + +# SignInAnonymouslyFailureFirebase class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown during the sign in process if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- [SignInAnonymouslyFailureInterface](../wyatt_authentication_bloc/SignInAnonymouslyFailureInterface-class.md) +- SignInAnonymouslyFailureFirebase + + + + + + + + +## Constructors + +[SignInAnonymouslyFailureFirebase](../wyatt_authentication_bloc/SignInAnonymouslyFailureFirebase/SignInAnonymouslyFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + +[SignInAnonymouslyFailureFirebase.fromCode](../wyatt_authentication_bloc/SignInAnonymouslyFailureFirebase/SignInAnonymouslyFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymouslyFailureFirebase/SignInAnonymouslyFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymouslyFailureFirebase/SignInAnonymouslyFailureFirebase.fromCode.md new file mode 100644 index 00000000..7edb701d --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymouslyFailureFirebase/SignInAnonymouslyFailureFirebase.fromCode.md @@ -0,0 +1,40 @@ + + + +# SignInAnonymouslyFailureFirebase.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SignInAnonymouslyFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + + +## Implementation + +```dart +SignInAnonymouslyFailureFirebase.fromCode(String code) + : super.fromCode(code) { + switch (code) { + case 'operation-not-allowed': + msg = 'Operation is not allowed. Please contact support.'; + break; + default: + this.code = 'unknown'; + msg = 'An unknown error occurred.'; + } +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymouslyFailureFirebase/SignInAnonymouslyFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymouslyFailureFirebase/SignInAnonymouslyFailureFirebase.md new file mode 100644 index 00000000..3125f39a --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymouslyFailureFirebase/SignInAnonymouslyFailureFirebase.md @@ -0,0 +1,31 @@ + + + +# SignInAnonymouslyFailureFirebase constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SignInAnonymouslyFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + + + +## Implementation + +```dart +SignInAnonymouslyFailureFirebase([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymouslyFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymouslyFailureInterface-class.md new file mode 100644 index 00000000..df9dd187 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymouslyFailureInterface-class.md @@ -0,0 +1,139 @@ + + + +# SignInAnonymouslyFailureInterface class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown during the sign in process if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- SignInAnonymouslyFailureInterface + + + +**Implementers** + +- [SignInAnonymouslyFailureFirebase](../wyatt_authentication_bloc/SignInAnonymouslyFailureFirebase-class.md) + + + + + +## Constructors + +[SignInAnonymouslyFailureInterface](../wyatt_authentication_bloc/SignInAnonymouslyFailureInterface/SignInAnonymouslyFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + +Thrown during the sign in process if a failure occurs. + +[SignInAnonymouslyFailureInterface.fromCode](../wyatt_authentication_bloc/SignInAnonymouslyFailureInterface/SignInAnonymouslyFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + +Thrown during the sign in process if a failure occurs. + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymouslyFailureInterface/SignInAnonymouslyFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymouslyFailureInterface/SignInAnonymouslyFailureInterface.fromCode.md new file mode 100644 index 00000000..13e4bd31 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymouslyFailureInterface/SignInAnonymouslyFailureInterface.fromCode.md @@ -0,0 +1,31 @@ + + + +# SignInAnonymouslyFailureInterface.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SignInAnonymouslyFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + +

Thrown during the sign in process if a failure occurs.

+ + + +## Implementation + +```dart +SignInAnonymouslyFailureInterface.fromCode(super.code) : super.fromCode(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymouslyFailureInterface/SignInAnonymouslyFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymouslyFailureInterface/SignInAnonymouslyFailureInterface.md new file mode 100644 index 00000000..54eeaeb0 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymouslyFailureInterface/SignInAnonymouslyFailureInterface.md @@ -0,0 +1,31 @@ + + + +# SignInAnonymouslyFailureInterface constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SignInAnonymouslyFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + + +

Thrown during the sign in process if a failure occurs.

+ + + +## Implementation + +```dart +SignInAnonymouslyFailureInterface(super.code, super.msg); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInCubit-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInCubit-class.md new file mode 100644 index 00000000..638a83a7 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInCubit-class.md @@ -0,0 +1,354 @@ + + + +# SignInCubit<Data> class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Fully featured sign in cubit.

+

Sufficient in most cases. (Where fine granularity is not required.)

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [BlocBase](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase-class.html)<[SignInState](../wyatt_authentication_bloc/SignInState-class.md)> +- [Cubit](https://pub.dev/documentation/bloc/8.1.0/bloc/Cubit-class.html)<[SignInState](../wyatt_authentication_bloc/SignInState-class.md)> +- [BaseSignInCubit](../wyatt_authentication_bloc/BaseSignInCubit-class.md)<Data> +- SignInCubit + + +**Mixed in types** + +- [SignInAnonymously](../wyatt_authentication_bloc/SignInAnonymously-mixin.md)<Data> +- [SignInWithEmailPassword](../wyatt_authentication_bloc/SignInWithEmailPassword-mixin.md)<Data> +- [SignInWithGoogle](../wyatt_authentication_bloc/SignInWithGoogle-mixin.md)<Data> + + + + + + +## Constructors + +[SignInCubit](../wyatt_authentication_bloc/SignInCubit/SignInCubit.md) ({required [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> authenticationRepository}) + + + + +## Properties + +##### [authenticationRepository](../wyatt_authentication_bloc/BaseSignInCubit/authenticationRepository.md) → [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> + + + + +_finalinherited_ + + + +##### [formName](../wyatt_authentication_bloc/BaseSignInCubit/formName.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [formRepository](../wyatt_authentication_bloc/BaseSignInCubit/formRepository.md) → FormRepository + + + + +_read-onlyinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [isClosed](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/isClosed.html) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +Whether the bloc is closed. +_read-onlyinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + +##### [state](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/state.html) → [SignInState](../wyatt_authentication_bloc/SignInState-class.md) + + + +The current state. +_read-onlyinherited_ + + + +##### [stream](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/stream.html) → [Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[SignInState](../wyatt_authentication_bloc/SignInState-class.md)> + + + +The current stream of states. +_read-onlyinherited_ + + + + + +## Methods + +##### [addError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/addError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [[StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html)? stackTrace]) void + + + +Reports an error which triggers onError with an optional StackTrace. +_inherited_ + + + +##### [close](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/close.html)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> + + + +Closes the instance. +This method should be called when the instance is no longer needed. +Once close is called, the instance can no longer be used. +_inherited_ + + + +##### [dataChanged](../wyatt_authentication_bloc/BaseSignInCubit/dataChanged.md)<Value>([String](https://api.flutter.dev/flutter/dart-core/String-class.html) key, FormInputValidator<Value, ValidationError> dirtyValue) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + +##### [emailChanged](../wyatt_authentication_bloc/SignInWithEmailPassword/emailChanged.md)([String](https://api.flutter.dev/flutter/dart-core/String-class.html) value) void + + + + +_inherited_ + + + +##### [emailCustomChanged](../wyatt_authentication_bloc/SignInWithEmailPassword/emailCustomChanged.md)<Validator extends FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError>>(Validator validator) void + + + +Same as emailChanged but with a custom Validator. +_inherited_ + + + +##### [emit](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/emit.html)([SignInState](../wyatt_authentication_bloc/SignInState-class.md) state) void + + + +Updates the state to the provided state. +emit does nothing if the state being emitted +is equal to the current state. +_inherited_ + + + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [onChange](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onChange.html)([Change](https://pub.dev/documentation/bloc/8.1.0/bloc/Change-class.html)<[SignInState](../wyatt_authentication_bloc/SignInState-class.md)> change) void + + + +Called whenever a change occurs with the given change. +A change occurs when a new state is emitted. +onChange is called before the state of the cubit is updated. +onChange is a great spot to add logging/analytics for a specific cubit. +_inherited_ + + + +##### [onError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html) stackTrace) void + + + +Called whenever an error occurs and notifies BlocObserver.onError. +_inherited_ + + + +##### [onSignInAnonymously](../wyatt_authentication_bloc/SignInCubit/onSignInAnonymously.md)(Result<[Account](../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) FutureOrResult<Data?> + + + +This callback is triggered when a user signs in anonymously. +_override_ + + + +##### [onSignInWithEmailAndPassword](../wyatt_authentication_bloc/SignInCubit/onSignInWithEmailAndPassword.md)(Result<[Account](../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) FutureOrResult<Data?> + + + +This callback is triggered when a user signs in with email and password. +_override_ + + + +##### [onSignInWithGoogle](../wyatt_authentication_bloc/SignInCubit/onSignInWithGoogle.md)(Result<[Account](../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) FutureOrResult<Data?> + + + +This callback is triggered when a user signs in with google. +_override_ + + + +##### [passwordChanged](../wyatt_authentication_bloc/SignInWithEmailPassword/passwordChanged.md)([String](https://api.flutter.dev/flutter/dart-core/String-class.html) value) void + + + + +_inherited_ + + + +##### [passwordCustomChanged](../wyatt_authentication_bloc/SignInWithEmailPassword/passwordCustomChanged.md)<Validator extends FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError>>(Validator validator) void + + + +Same as passwordChanged but with a custom Validator. +_inherited_ + + + +##### [reset](../wyatt_authentication_bloc/BaseSignInCubit/reset.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + +##### [signInAnonymously](../wyatt_authentication_bloc/SignInAnonymously/signInAnonymously.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + +Sign in anonymously. +_inherited_ + + + +##### [signInWithEmailAndPassword](../wyatt_authentication_bloc/SignInWithEmailPassword/signInWithEmailAndPassword.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + +Signs in with the provided email and password. +_inherited_ + + + +##### [signInWithGoogle](../wyatt_authentication_bloc/SignInWithGoogle/signInWithGoogle.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + +Starts the Sign In with Google Flow. +_inherited_ + + + +##### [submit](../wyatt_authentication_bloc/BaseSignInCubit/submit.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + +##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + +##### [update](../wyatt_authentication_bloc/BaseSignInCubit/update.md)(WyattForm form, {SetOperation operation = SetOperation.replace}) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + +##### [validate](../wyatt_authentication_bloc/BaseSignInCubit/validate.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInCubit/SignInCubit.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInCubit/SignInCubit.md new file mode 100644 index 00000000..f2a52155 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInCubit/SignInCubit.md @@ -0,0 +1,30 @@ + + + +# SignInCubit<Data> constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SignInCubit<Data>({required [AuthenticationRepository](../../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> authenticationRepository}) + + + + + +## Implementation + +```dart +SignInCubit({required super.authenticationRepository}); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInCubit/onSignInAnonymously.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInCubit/onSignInAnonymously.md new file mode 100644 index 00000000..034b1e38 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInCubit/onSignInAnonymously.md @@ -0,0 +1,42 @@ + + + +# onSignInAnonymously method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +FutureOrResult<Data?> onSignInAnonymously +(Result<[Account](../../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) + +_override_ + + + +

This callback is triggered when a user signs in anonymously.

+ + + +## Implementation + +```dart +@override +FutureOrResult onSignInAnonymously( + Result result, + WyattForm form, +) => + const Ok(null); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInCubit/onSignInWithEmailAndPassword.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInCubit/onSignInWithEmailAndPassword.md new file mode 100644 index 00000000..53132dae --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInCubit/onSignInWithEmailAndPassword.md @@ -0,0 +1,42 @@ + + + +# onSignInWithEmailAndPassword method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +FutureOrResult<Data?> onSignInWithEmailAndPassword +(Result<[Account](../../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) + +_override_ + + + +

This callback is triggered when a user signs in with email and password.

+ + + +## Implementation + +```dart +@override +FutureOrResult onSignInWithEmailAndPassword( + Result result, + WyattForm form, +) => + const Ok(null); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInCubit/onSignInWithGoogle.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInCubit/onSignInWithGoogle.md new file mode 100644 index 00000000..19904a99 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInCubit/onSignInWithGoogle.md @@ -0,0 +1,42 @@ + + + +# onSignInWithGoogle method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +FutureOrResult<Data?> onSignInWithGoogle +(Result<[Account](../../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) + +_override_ + + + +

This callback is triggered when a user signs in with google.

+ + + +## Implementation + +```dart +@override +FutureOrResult onSignInWithGoogle( + Result result, + WyattForm form, +) => + const Ok(null); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener-class.md new file mode 100644 index 00000000..f048a063 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener-class.md @@ -0,0 +1,236 @@ + + + +# SignInListener<Data> class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Widget that listens and builds a child based on the state of +the sign in cubit

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [DiagnosticableTree](https://api.flutter.dev/flutter/foundation/DiagnosticableTree-class.html) +- [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) +- [StatelessWidget](https://api.flutter.dev/flutter/widgets/StatelessWidget-class.html) +- SignInListener + + + + + + + + +## Constructors + +[SignInListener](../wyatt_authentication_bloc/SignInListener/SignInListener.md) ({required [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) child, void onProgress([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?, void onSuccess([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?, void onError([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, FormStatus status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage)?, void customBuilder([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, [SignInState](../wyatt_authentication_bloc/SignInState-class.md) state)?, [Key](https://api.flutter.dev/flutter/foundation/Key-class.html)? key}) + + _const_ + + +## Properties + +##### [child](../wyatt_authentication_bloc/SignInListener/child.md) → [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) + + + + +_final_ + + + +##### [customBuilder](../wyatt_authentication_bloc/SignInListener/customBuilder.md) → (void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, [SignInState](../wyatt_authentication_bloc/SignInState-class.md) state)?) + + + + +_final_ + + + +##### [hashCode](https://api.flutter.dev/flutter/widgets/Widget/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [key](https://api.flutter.dev/flutter/widgets/Widget/key.html) → [Key](https://api.flutter.dev/flutter/foundation/Key-class.html)? + + + +Controls how one widget replaces another widget in the tree. +_finalinherited_ + + + +##### [onError](../wyatt_authentication_bloc/SignInListener/onError.md) → (void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, FormStatus status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage)?) + + + + +_final_ + + + +##### [onProgress](../wyatt_authentication_bloc/SignInListener/onProgress.md) → (void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?) + + + + +_final_ + + + +##### [onSuccess](../wyatt_authentication_bloc/SignInListener/onSuccess.md) → (void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?) + + + + +_final_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [build](../wyatt_authentication_bloc/SignInListener/build.md)([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context) [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) + + + +Describes the part of the user interface represented by this widget. +_override_ + + + +##### [createElement](https://api.flutter.dev/flutter/widgets/StatelessWidget/createElement.html)() [StatelessElement](https://api.flutter.dev/flutter/widgets/StatelessElement-class.html) + + + +Creates a StatelessElement to manage this widget's location in the tree. +_inherited_ + + + +##### [debugDescribeChildren](https://api.flutter.dev/flutter/foundation/DiagnosticableTree/debugDescribeChildren.html)() [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[DiagnosticsNode](https://api.flutter.dev/flutter/foundation/DiagnosticsNode-class.html)> + + + +Returns a list of DiagnosticsNode objects describing this node's +children. +_inherited_ + + + +##### [debugFillProperties](https://api.flutter.dev/flutter/widgets/Widget/debugFillProperties.html)([DiagnosticPropertiesBuilder](https://api.flutter.dev/flutter/foundation/DiagnosticPropertiesBuilder-class.html) properties) void + + + +Add additional properties associated with the node. +_inherited_ + + + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toDiagnosticsNode](https://api.flutter.dev/flutter/foundation/DiagnosticableTree/toDiagnosticsNode.html)({[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? name, [DiagnosticsTreeStyle](https://api.flutter.dev/flutter/foundation/DiagnosticsTreeStyle.html)? style}) [DiagnosticsNode](https://api.flutter.dev/flutter/foundation/DiagnosticsNode-class.html) + + + +Returns a debug representation of the object that is used by debugging +tools and by DiagnosticsNode.toStringDeep. +_inherited_ + + + +##### [toString](https://api.flutter.dev/flutter/foundation/Diagnosticable/toString.html)({[DiagnosticLevel](https://api.flutter.dev/flutter/foundation/DiagnosticLevel.html) minLevel = DiagnosticLevel.info}) [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + +##### [toStringDeep](https://api.flutter.dev/flutter/foundation/DiagnosticableTree/toStringDeep.html)({[String](https://api.flutter.dev/flutter/dart-core/String-class.html) prefixLineOne = '', [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? prefixOtherLines, [DiagnosticLevel](https://api.flutter.dev/flutter/foundation/DiagnosticLevel.html) minLevel = DiagnosticLevel.debug}) [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +Returns a string representation of this node and its descendants. +_inherited_ + + + +##### [toStringShallow](https://api.flutter.dev/flutter/foundation/DiagnosticableTree/toStringShallow.html)({[String](https://api.flutter.dev/flutter/dart-core/String-class.html) joiner = ', ', [DiagnosticLevel](https://api.flutter.dev/flutter/foundation/DiagnosticLevel.html) minLevel = DiagnosticLevel.debug}) [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +Returns a one-line detailed description of the object. +_inherited_ + + + +##### [toStringShort](https://api.flutter.dev/flutter/widgets/Widget/toStringShort.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A short, textual description of this widget. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/widgets/Widget/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/SignInListener.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/SignInListener.md new file mode 100644 index 00000000..a9cfeea1 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/SignInListener.md @@ -0,0 +1,37 @@ + + + +# SignInListener<Data> constructor + + + + + *[](https://dart.dev/null-safety)* + + +const +SignInListener<Data>({required [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) child, void onProgress([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?, void onSuccess([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?, void onError([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, FormStatus status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage)?, void customBuilder([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, [SignInState](../../wyatt_authentication_bloc/SignInState-class.md) state)?, [Key](https://api.flutter.dev/flutter/foundation/Key-class.html)? key}) + + + + + +## Implementation + +```dart +const SignInListener({ + required this.child, + this.onProgress, + this.onSuccess, + this.onError, + this.customBuilder, + super.key, +}); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/build.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/build.md new file mode 100644 index 00000000..d6783753 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/build.md @@ -0,0 +1,92 @@ + + + +# build method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) build +([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context) + +_override_ + + + +

Describes the part of the user interface represented by this widget.

+

The framework calls this method when this widget is inserted into the tree +in a given BuildContext and when the dependencies of this widget change +(e.g., an InheritedWidget referenced by this widget changes). This +method can potentially be called in every frame and should not have any side +effects beyond building a widget.

+

The framework replaces the subtree below this widget with the widget +returned by this method, either by updating the existing subtree or by +removing the subtree and inflating a new subtree, depending on whether the +widget returned by this method can update the root of the existing +subtree, as determined by calling Widget.canUpdate.

+

Typically implementations return a newly created constellation of widgets +that are configured with information from this widget's constructor and +from the given BuildContext.

+

The given BuildContext contains information about the location in the +tree at which this widget is being built. For example, the context +provides the set of inherited widgets for this location in the tree. A +given widget might be built with multiple different BuildContext +arguments over time if the widget is moved around the tree or if the +widget is inserted into the tree in multiple places at once.

+

The implementation of this method must only depend on:

+ +

If a widget's build method is to depend on anything else, use a +StatefulWidget instead.

+

See also:

+
    +
  • StatelessWidget, which contains the discussion on performance considerations.
  • +
+ + + +## Implementation + +```dart +@override +Widget build(BuildContext context) => + BlocListener, SignInState>( + listener: (context, state) { + if (customBuilder != null) { + return customBuilder!(context, state); + } + + if (onSuccess != null && + state.status == FormStatus.submissionSuccess) { + return onSuccess!(context); + } + if (onProgress != null && + state.status == FormStatus.submissionInProgress) { + return onProgress!(context); + } + if (onError != null && + (state.status == FormStatus.submissionCanceled || + state.status == FormStatus.submissionFailure)) { + return onError!(context, state.status, state.errorMessage); + } + }, + child: child, + ); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/child.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/child.md new file mode 100644 index 00000000..53bc3682 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/child.md @@ -0,0 +1,33 @@ + + + +# child property + + + + + *[](https://dart.dev/null-safety)* + + + +[Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) child + +_final_ + + + + + + +## Implementation + +```dart +final Widget child; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/customBuilder.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/customBuilder.md new file mode 100644 index 00000000..132cb4c3 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/customBuilder.md @@ -0,0 +1,33 @@ + + + +# customBuilder property + + + + + *[](https://dart.dev/null-safety)* + + + +(void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, [SignInState](../../wyatt_authentication_bloc/SignInState-class.md) state)?) customBuilder + +_final_ + + + + + + +## Implementation + +```dart +final void Function(BuildContext context, SignInState state)? customBuilder; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/onError.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/onError.md new file mode 100644 index 00000000..ed94a98f --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/onError.md @@ -0,0 +1,37 @@ + + + +# onError property + + + + + *[](https://dart.dev/null-safety)* + + + +(void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, FormStatus status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage)?) onError + +_final_ + + + + + + +## Implementation + +```dart +final void Function( + BuildContext context, + FormStatus status, + String? errorMessage, +)? onError; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/onProgress.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/onProgress.md new file mode 100644 index 00000000..4a30ed71 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/onProgress.md @@ -0,0 +1,33 @@ + + + +# onProgress property + + + + + *[](https://dart.dev/null-safety)* + + + +(void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?) onProgress + +_final_ + + + + + + +## Implementation + +```dart +final void Function(BuildContext context)? onProgress; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/onSuccess.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/onSuccess.md new file mode 100644 index 00000000..4d942f63 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/onSuccess.md @@ -0,0 +1,33 @@ + + + +# onSuccess property + + + + + *[](https://dart.dev/null-safety)* + + + +(void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?) onSuccess + +_final_ + + + + + + +## Implementation + +```dart +final void Function(BuildContext context)? onSuccess; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState-class.md new file mode 100644 index 00000000..efb514c4 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState-class.md @@ -0,0 +1,179 @@ + + + +# SignInState class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Sign in cubit state to manage the form.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [Equatable](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable-class.html) +- SignInState + + + + + + + + +## Constructors + +[SignInState](../wyatt_authentication_bloc/SignInState/SignInState.md) ({required WyattForm form, FormStatus status = FormStatus.pure, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage}) + + _const_ + + +## Properties + +##### [email](../wyatt_authentication_bloc/SignInState/email.md) → FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError> + + + + +_read-only_ + + + +##### [errorMessage](../wyatt_authentication_bloc/SignInState/errorMessage.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? + + + +Optional error message. +_finalinherited_ + + + +##### [form](../wyatt_authentication_bloc/SignInState/form.md) → WyattForm + + + +FormData with all inputs, and associated metadata. +_finalinherited_ + + + +##### [hashCode](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [password](../wyatt_authentication_bloc/SignInState/password.md) → FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError> + + + + +_read-only_ + + + +##### [props](../wyatt_authentication_bloc/SignInState/props.md) → [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)> + + + +The list of properties that will be used to determine whether +two instances are equal. +_read-only_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + +##### [status](../wyatt_authentication_bloc/SignInState/status.md) → FormStatus + + + +Global status of a form. +_finalinherited_ + + + +##### [stringify](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/stringify.html) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)? + + + +If set to true, the toString method will be overridden to output +this instance's props. +_read-onlyinherited_ + + + + + +## Methods + +##### [copyWith](../wyatt_authentication_bloc/SignInState/copyWith.md)({WyattForm? form, FormStatus? status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage}) [SignInState](../wyatt_authentication_bloc/SignInState-class.md) + + + + + + + + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/SignInState/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_override_ + + + + + +## Operators + +##### [operator ==](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/SignInState.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/SignInState.md new file mode 100644 index 00000000..648fe926 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/SignInState.md @@ -0,0 +1,34 @@ + + + +# SignInState constructor + + + + + *[](https://dart.dev/null-safety)* + + +const +SignInState({required WyattForm form, FormStatus status = FormStatus.pure, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage}) + + + + + +## Implementation + +```dart +const SignInState({ + required super.form, + super.status = FormStatus.pure, + super.errorMessage, +}); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/copyWith.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/copyWith.md new file mode 100644 index 00000000..e6b06fe5 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/copyWith.md @@ -0,0 +1,44 @@ + + + +# copyWith method + + + + + *[](https://dart.dev/null-safety)* + + + + +[SignInState](../../wyatt_authentication_bloc/SignInState-class.md) copyWith +({WyattForm? form, FormStatus? status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage}) + + + + + + + + +## Implementation + +```dart +SignInState copyWith({ + WyattForm? form, + FormStatus? status, + String? errorMessage, +}) => + SignInState( + form: form ?? this.form, + status: status ?? this.status, + errorMessage: errorMessage ?? this.errorMessage, + ); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/email.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/email.md new file mode 100644 index 00000000..1ded8043 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/email.md @@ -0,0 +1,37 @@ + + + +# email property + + + + + *[](https://dart.dev/null-safety)* + + + + + +FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError> email + + + + + + + + +## Implementation + +```dart +FormInputValidator get email => + form.validatorOf(AuthFormField.email); +``` + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/errorMessage.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/errorMessage.md new file mode 100644 index 00000000..d0856deb --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/errorMessage.md @@ -0,0 +1,34 @@ + + + +# errorMessage property + + + + + *[](https://dart.dev/null-safety)* + + + +[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage + +_finalinherited_ + + + +

Optional error message.

+ + + +## Implementation + +```dart +final String? errorMessage; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/form.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/form.md new file mode 100644 index 00000000..d3f2da76 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/form.md @@ -0,0 +1,34 @@ + + + +# form property + + + + + *[](https://dart.dev/null-safety)* + + + +WyattForm form + +_finalinherited_ + + + +

FormData with all inputs, and associated metadata.

+ + + +## Implementation + +```dart +final WyattForm form; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/password.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/password.md new file mode 100644 index 00000000..77938106 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/password.md @@ -0,0 +1,37 @@ + + + +# password property + + + + + *[](https://dart.dev/null-safety)* + + + + + +FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError> password + + + + + + + + +## Implementation + +```dart +FormInputValidator get password => + form.validatorOf(AuthFormField.password); +``` + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/props.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/props.md new file mode 100644 index 00000000..eab8d26c --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/props.md @@ -0,0 +1,42 @@ + + + +# props property + + + + + *[](https://dart.dev/null-safety)* + + + + + +**Annotations** + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) +[List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)> props + + + + + +

The list of properties that will be used to determine whether +two instances are equal.

+ + + +## Implementation + +```dart +@override +List get props => [email, password, status]; +``` + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/status.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/status.md new file mode 100644 index 00000000..644a9f10 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/status.md @@ -0,0 +1,34 @@ + + + +# status property + + + + + *[](https://dart.dev/null-safety)* + + + +FormStatus status + +_finalinherited_ + + + +

Global status of a form.

+ + + +## Implementation + +```dart +final FormStatus status; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/toString.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/toString.md new file mode 100644 index 00000000..01225d4e --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/toString.md @@ -0,0 +1,48 @@ + + + +# toString method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[String](https://api.flutter.dev/flutter/dart-core/String-class.html) toString +() + +_override_ + + + +

A string representation of this object.

+

Some classes have a default textual representation, +often paired with a static parse function (like int.parse). +These classes will provide the textual representation as +their string representation.

+

Other classes have no meaningful textual representation +that a program will care about. +Such classes will typically override toString to provide +useful information when inspecting the object, +mainly for debugging or logging.

+ + + +## Implementation + +```dart +@override +String toString() => 'SignInState(status: ${status.name} ' + '${(errorMessage != null) ? " [$errorMessage]" : ""}, $form)'; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithAppleFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithAppleFailureFirebase-class.md new file mode 100644 index 00000000..a188c284 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithAppleFailureFirebase-class.md @@ -0,0 +1,141 @@ + + + +# SignInWithAppleFailureFirebase class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown during the sign in process if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- [SignInWithCredentialFailureInterface](../wyatt_authentication_bloc/SignInWithCredentialFailureInterface-class.md) +- [SignInWithCredentialFailureFirebase](../wyatt_authentication_bloc/SignInWithCredentialFailureFirebase-class.md) +- SignInWithAppleFailureFirebase + +**Implemented types** + +- [SignInWithAppleFailureInterface](../wyatt_authentication_bloc/SignInWithAppleFailureInterface-class.md) + + + + + + + +## Constructors + +[SignInWithAppleFailureFirebase](../wyatt_authentication_bloc/SignInWithAppleFailureFirebase/SignInWithAppleFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + +[SignInWithAppleFailureFirebase.fromCode](../wyatt_authentication_bloc/SignInWithAppleFailureFirebase/SignInWithAppleFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithAppleFailureFirebase/SignInWithAppleFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithAppleFailureFirebase/SignInWithAppleFailureFirebase.fromCode.md new file mode 100644 index 00000000..c07fe58b --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithAppleFailureFirebase/SignInWithAppleFailureFirebase.fromCode.md @@ -0,0 +1,30 @@ + + + +# SignInWithAppleFailureFirebase.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SignInWithAppleFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + + +## Implementation + +```dart +SignInWithAppleFailureFirebase.fromCode(super.code) : super.fromCode(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithAppleFailureFirebase/SignInWithAppleFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithAppleFailureFirebase/SignInWithAppleFailureFirebase.md new file mode 100644 index 00000000..4aa51024 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithAppleFailureFirebase/SignInWithAppleFailureFirebase.md @@ -0,0 +1,30 @@ + + + +# SignInWithAppleFailureFirebase constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SignInWithAppleFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + + + +## Implementation + +```dart +SignInWithAppleFailureFirebase([super.code, super.msg]); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithAppleFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithAppleFailureInterface-class.md new file mode 100644 index 00000000..7b1837ba --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithAppleFailureInterface-class.md @@ -0,0 +1,140 @@ + + + +# SignInWithAppleFailureInterface class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown during the sign in process if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- SignInWithAppleFailureInterface + + + +**Implementers** + +- [SignInWithAppleFailureFirebase](../wyatt_authentication_bloc/SignInWithAppleFailureFirebase-class.md) +- [SignInWithTwitterFailureFirebase](../wyatt_authentication_bloc/SignInWithTwitterFailureFirebase-class.md) + + + + + +## Constructors + +[SignInWithAppleFailureInterface](../wyatt_authentication_bloc/SignInWithAppleFailureInterface/SignInWithAppleFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + +Thrown during the sign in process if a failure occurs. + +[SignInWithAppleFailureInterface.fromCode](../wyatt_authentication_bloc/SignInWithAppleFailureInterface/SignInWithAppleFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + +Thrown during the sign in process if a failure occurs. + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithAppleFailureInterface/SignInWithAppleFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithAppleFailureInterface/SignInWithAppleFailureInterface.fromCode.md new file mode 100644 index 00000000..6786f6d9 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithAppleFailureInterface/SignInWithAppleFailureInterface.fromCode.md @@ -0,0 +1,31 @@ + + + +# SignInWithAppleFailureInterface.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SignInWithAppleFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + +

Thrown during the sign in process if a failure occurs.

+ + + +## Implementation + +```dart +SignInWithAppleFailureInterface.fromCode(super.code) : super.fromCode(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithAppleFailureInterface/SignInWithAppleFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithAppleFailureInterface/SignInWithAppleFailureInterface.md new file mode 100644 index 00000000..6994d8b8 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithAppleFailureInterface/SignInWithAppleFailureInterface.md @@ -0,0 +1,31 @@ + + + +# SignInWithAppleFailureInterface constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SignInWithAppleFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + + +

Thrown during the sign in process if a failure occurs.

+ + + +## Implementation + +```dart +SignInWithAppleFailureInterface(super.code, super.msg); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithCredentialFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithCredentialFailureFirebase-class.md new file mode 100644 index 00000000..f9e120f8 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithCredentialFailureFirebase-class.md @@ -0,0 +1,143 @@ + + + +# SignInWithCredentialFailureFirebase class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown during the sign in process if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- [SignInWithCredentialFailureInterface](../wyatt_authentication_bloc/SignInWithCredentialFailureInterface-class.md) +- SignInWithCredentialFailureFirebase + + + +**Implementers** + +- [SignInWithAppleFailureFirebase](../wyatt_authentication_bloc/SignInWithAppleFailureFirebase-class.md) +- [SignInWithFacebookFailureFirebase](../wyatt_authentication_bloc/SignInWithFacebookFailureFirebase-class.md) +- [SignInWithGoogleFailureFirebase](../wyatt_authentication_bloc/SignInWithGoogleFailureFirebase-class.md) +- [SignInWithTwitterFailureFirebase](../wyatt_authentication_bloc/SignInWithTwitterFailureFirebase-class.md) + + + + + +## Constructors + +[SignInWithCredentialFailureFirebase](../wyatt_authentication_bloc/SignInWithCredentialFailureFirebase/SignInWithCredentialFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + +[SignInWithCredentialFailureFirebase.fromCode](../wyatt_authentication_bloc/SignInWithCredentialFailureFirebase/SignInWithCredentialFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithCredentialFailureFirebase/SignInWithCredentialFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithCredentialFailureFirebase/SignInWithCredentialFailureFirebase.fromCode.md new file mode 100644 index 00000000..d2b1deb1 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithCredentialFailureFirebase/SignInWithCredentialFailureFirebase.fromCode.md @@ -0,0 +1,61 @@ + + + +# SignInWithCredentialFailureFirebase.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SignInWithCredentialFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + + +## Implementation + +```dart +SignInWithCredentialFailureFirebase.fromCode(String code) + : super.fromCode(code) { + switch (code) { + case 'account-exists-with-different-credential': + msg = 'Account exists with different credentials.'; + break; + case 'invalid-credential': + msg = 'The credential received is malformed or has expired.'; + break; + case 'operation-not-allowed': + msg = 'Operation is not allowed. Please contact support.'; + break; + case 'user-disabled': + msg = 'This user has been disabled. Please contact support for help.'; + break; + case 'user-not-found': + msg = 'Email is not found, please create an account.'; + break; + case 'wrong-password': + msg = 'Incorrect password, please try again.'; + break; + case 'invalid-verification-code': + msg = 'The credential verification code received is invalid.'; + break; + case 'invalid-verification-id': + msg = 'The credential verification ID received is invalid.'; + break; + default: + this.code = 'unknown'; + msg = 'An unknown error occurred.'; + } +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithCredentialFailureFirebase/SignInWithCredentialFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithCredentialFailureFirebase/SignInWithCredentialFailureFirebase.md new file mode 100644 index 00000000..66f66bb9 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithCredentialFailureFirebase/SignInWithCredentialFailureFirebase.md @@ -0,0 +1,31 @@ + + + +# SignInWithCredentialFailureFirebase constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SignInWithCredentialFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + + + +## Implementation + +```dart +SignInWithCredentialFailureFirebase([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithCredentialFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithCredentialFailureInterface-class.md new file mode 100644 index 00000000..08473e12 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithCredentialFailureInterface-class.md @@ -0,0 +1,139 @@ + + + +# SignInWithCredentialFailureInterface class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown during the sign in process if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- SignInWithCredentialFailureInterface + + + +**Implementers** + +- [SignInWithCredentialFailureFirebase](../wyatt_authentication_bloc/SignInWithCredentialFailureFirebase-class.md) + + + + + +## Constructors + +[SignInWithCredentialFailureInterface](../wyatt_authentication_bloc/SignInWithCredentialFailureInterface/SignInWithCredentialFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + +Thrown during the sign in process if a failure occurs. + +[SignInWithCredentialFailureInterface.fromCode](../wyatt_authentication_bloc/SignInWithCredentialFailureInterface/SignInWithCredentialFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + +Thrown during the sign in process if a failure occurs. + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithCredentialFailureInterface/SignInWithCredentialFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithCredentialFailureInterface/SignInWithCredentialFailureInterface.fromCode.md new file mode 100644 index 00000000..14c794db --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithCredentialFailureInterface/SignInWithCredentialFailureInterface.fromCode.md @@ -0,0 +1,31 @@ + + + +# SignInWithCredentialFailureInterface.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SignInWithCredentialFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + +

Thrown during the sign in process if a failure occurs.

+ + + +## Implementation + +```dart +SignInWithCredentialFailureInterface.fromCode(super.code) : super.fromCode(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithCredentialFailureInterface/SignInWithCredentialFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithCredentialFailureInterface/SignInWithCredentialFailureInterface.md new file mode 100644 index 00000000..4030c6cd --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithCredentialFailureInterface/SignInWithCredentialFailureInterface.md @@ -0,0 +1,31 @@ + + + +# SignInWithCredentialFailureInterface constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SignInWithCredentialFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + + +

Thrown during the sign in process if a failure occurs.

+ + + +## Implementation + +```dart +SignInWithCredentialFailureInterface(super.code, super.msg); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureFirebase-class.md new file mode 100644 index 00000000..5a28b107 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureFirebase-class.md @@ -0,0 +1,137 @@ + + + +# SignInWithEmailAndPasswordFailureFirebase class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown during the sign in process if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- [SignInWithEmailAndPasswordFailureInterface](../wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureInterface-class.md) +- SignInWithEmailAndPasswordFailureFirebase + + + + + + + + +## Constructors + +[SignInWithEmailAndPasswordFailureFirebase](../wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureFirebase/SignInWithEmailAndPasswordFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + +[SignInWithEmailAndPasswordFailureFirebase.fromCode](../wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureFirebase/SignInWithEmailAndPasswordFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureFirebase/SignInWithEmailAndPasswordFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureFirebase/SignInWithEmailAndPasswordFailureFirebase.fromCode.md new file mode 100644 index 00000000..5b9663d4 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureFirebase/SignInWithEmailAndPasswordFailureFirebase.fromCode.md @@ -0,0 +1,49 @@ + + + +# SignInWithEmailAndPasswordFailureFirebase.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SignInWithEmailAndPasswordFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + + +## Implementation + +```dart +SignInWithEmailAndPasswordFailureFirebase.fromCode(String code) + : super.fromCode(code) { + switch (code) { + case 'invalid-email': + msg = 'Email is not valid or badly formatted.'; + break; + case 'user-disabled': + msg = 'This user has been disabled. Please contact support for help.'; + break; + case 'user-not-found': + msg = 'Email is not found, please create an account.'; + break; + case 'wrong-password': + msg = 'Incorrect password, please try again.'; + break; + default: + this.code = 'unknown'; + msg = 'An unknown error occurred.'; + } +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureFirebase/SignInWithEmailAndPasswordFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureFirebase/SignInWithEmailAndPasswordFailureFirebase.md new file mode 100644 index 00000000..42ec7079 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureFirebase/SignInWithEmailAndPasswordFailureFirebase.md @@ -0,0 +1,31 @@ + + + +# SignInWithEmailAndPasswordFailureFirebase constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SignInWithEmailAndPasswordFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + + + +## Implementation + +```dart +SignInWithEmailAndPasswordFailureFirebase([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureInterface-class.md new file mode 100644 index 00000000..acdf3cf0 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureInterface-class.md @@ -0,0 +1,139 @@ + + + +# SignInWithEmailAndPasswordFailureInterface class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown during the sign in process if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- SignInWithEmailAndPasswordFailureInterface + + + +**Implementers** + +- [SignInWithEmailAndPasswordFailureFirebase](../wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureFirebase-class.md) + + + + + +## Constructors + +[SignInWithEmailAndPasswordFailureInterface](../wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureInterface/SignInWithEmailAndPasswordFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + +Thrown during the sign in process if a failure occurs. + +[SignInWithEmailAndPasswordFailureInterface.fromCode](../wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureInterface/SignInWithEmailAndPasswordFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + +Thrown during the sign in process if a failure occurs. + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureInterface/SignInWithEmailAndPasswordFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureInterface/SignInWithEmailAndPasswordFailureInterface.fromCode.md new file mode 100644 index 00000000..735df785 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureInterface/SignInWithEmailAndPasswordFailureInterface.fromCode.md @@ -0,0 +1,32 @@ + + + +# SignInWithEmailAndPasswordFailureInterface.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SignInWithEmailAndPasswordFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + +

Thrown during the sign in process if a failure occurs.

+ + + +## Implementation + +```dart +SignInWithEmailAndPasswordFailureInterface.fromCode(super.code) + : super.fromCode(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureInterface/SignInWithEmailAndPasswordFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureInterface/SignInWithEmailAndPasswordFailureInterface.md new file mode 100644 index 00000000..fff1afd8 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureInterface/SignInWithEmailAndPasswordFailureInterface.md @@ -0,0 +1,31 @@ + + + +# SignInWithEmailAndPasswordFailureInterface constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SignInWithEmailAndPasswordFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + + +

Thrown during the sign in process if a failure occurs.

+ + + +## Implementation + +```dart +SignInWithEmailAndPasswordFailureInterface(super.code, super.msg); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailLinkFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailLinkFailureFirebase-class.md new file mode 100644 index 00000000..e2360fe9 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailLinkFailureFirebase-class.md @@ -0,0 +1,137 @@ + + + +# SignInWithEmailLinkFailureFirebase class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown during the sign in process if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- [SignInWithEmailLinkFailureInterface](../wyatt_authentication_bloc/SignInWithEmailLinkFailureInterface-class.md) +- SignInWithEmailLinkFailureFirebase + + + + + + + + +## Constructors + +[SignInWithEmailLinkFailureFirebase](../wyatt_authentication_bloc/SignInWithEmailLinkFailureFirebase/SignInWithEmailLinkFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + +[SignInWithEmailLinkFailureFirebase.fromCode](../wyatt_authentication_bloc/SignInWithEmailLinkFailureFirebase/SignInWithEmailLinkFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailLinkFailureFirebase/SignInWithEmailLinkFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailLinkFailureFirebase/SignInWithEmailLinkFailureFirebase.fromCode.md new file mode 100644 index 00000000..a8ccdec9 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailLinkFailureFirebase/SignInWithEmailLinkFailureFirebase.fromCode.md @@ -0,0 +1,46 @@ + + + +# SignInWithEmailLinkFailureFirebase.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SignInWithEmailLinkFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + + +## Implementation + +```dart +SignInWithEmailLinkFailureFirebase.fromCode(String code) + : super.fromCode(code) { + switch (code) { + case 'expired-action-code': + msg = 'Action code has expired.'; + break; + case 'invalid-email': + msg = 'Email is not valid or badly formatted.'; + break; + case 'user-disabled': + msg = 'This user has been disabled. Please contact support for help.'; + break; + default: + this.code = 'unknown'; + msg = 'An unknown error occurred.'; + } +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailLinkFailureFirebase/SignInWithEmailLinkFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailLinkFailureFirebase/SignInWithEmailLinkFailureFirebase.md new file mode 100644 index 00000000..456995ec --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailLinkFailureFirebase/SignInWithEmailLinkFailureFirebase.md @@ -0,0 +1,31 @@ + + + +# SignInWithEmailLinkFailureFirebase constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SignInWithEmailLinkFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + + + +## Implementation + +```dart +SignInWithEmailLinkFailureFirebase([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailLinkFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailLinkFailureInterface-class.md new file mode 100644 index 00000000..e087037b --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailLinkFailureInterface-class.md @@ -0,0 +1,139 @@ + + + +# SignInWithEmailLinkFailureInterface class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown during the sign in process if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- SignInWithEmailLinkFailureInterface + + + +**Implementers** + +- [SignInWithEmailLinkFailureFirebase](../wyatt_authentication_bloc/SignInWithEmailLinkFailureFirebase-class.md) + + + + + +## Constructors + +[SignInWithEmailLinkFailureInterface](../wyatt_authentication_bloc/SignInWithEmailLinkFailureInterface/SignInWithEmailLinkFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + +Thrown during the sign in process if a failure occurs. + +[SignInWithEmailLinkFailureInterface.fromCode](../wyatt_authentication_bloc/SignInWithEmailLinkFailureInterface/SignInWithEmailLinkFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + +Thrown during the sign in process if a failure occurs. + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailLinkFailureInterface/SignInWithEmailLinkFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailLinkFailureInterface/SignInWithEmailLinkFailureInterface.fromCode.md new file mode 100644 index 00000000..3d4531a9 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailLinkFailureInterface/SignInWithEmailLinkFailureInterface.fromCode.md @@ -0,0 +1,31 @@ + + + +# SignInWithEmailLinkFailureInterface.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SignInWithEmailLinkFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + +

Thrown during the sign in process if a failure occurs.

+ + + +## Implementation + +```dart +SignInWithEmailLinkFailureInterface.fromCode(super.code) : super.fromCode(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailLinkFailureInterface/SignInWithEmailLinkFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailLinkFailureInterface/SignInWithEmailLinkFailureInterface.md new file mode 100644 index 00000000..73f298cb --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailLinkFailureInterface/SignInWithEmailLinkFailureInterface.md @@ -0,0 +1,31 @@ + + + +# SignInWithEmailLinkFailureInterface constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SignInWithEmailLinkFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + + +

Thrown during the sign in process if a failure occurs.

+ + + +## Implementation + +```dart +SignInWithEmailLinkFailureInterface(super.code, super.msg); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword-mixin.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword-mixin.md new file mode 100644 index 00000000..78cf1a73 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword-mixin.md @@ -0,0 +1,305 @@ + + + +# SignInWithEmailPassword<Data> mixin + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Sign in mixin.

+

Allows the user to sign in with email and password

+

Gives access to the signInWithEmailAndPassword method and +onSignInWithEmailAndPassword callback.

+ + +**Superclass Constraints** + +- [BaseSignInCubit](../wyatt_authentication_bloc/BaseSignInCubit-class.md)<Data> + + + + +**Mixin Applications** + +- [SignInCubit](../wyatt_authentication_bloc/SignInCubit-class.md) + + + +## Properties + +##### [authenticationRepository](../wyatt_authentication_bloc/BaseSignInCubit/authenticationRepository.md) → [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> + + + + +_finalinherited_ + + + +##### [formName](../wyatt_authentication_bloc/BaseSignInCubit/formName.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [formRepository](../wyatt_authentication_bloc/BaseSignInCubit/formRepository.md) → FormRepository + + + + +_read-onlyinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [isClosed](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/isClosed.html) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +Whether the bloc is closed. +_read-onlyinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + +##### [state](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/state.html) → [SignInState](../wyatt_authentication_bloc/SignInState-class.md) + + + +The current state. +_read-onlyinherited_ + + + +##### [stream](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/stream.html) → [Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[SignInState](../wyatt_authentication_bloc/SignInState-class.md)> + + + +The current stream of states. +_read-onlyinherited_ + + + + + +## Methods + +##### [addError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/addError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [[StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html)? stackTrace]) void + + + +Reports an error which triggers onError with an optional StackTrace. +_inherited_ + + + +##### [close](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/close.html)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> + + + +Closes the instance. +This method should be called when the instance is no longer needed. +Once close is called, the instance can no longer be used. +_inherited_ + + + +##### [dataChanged](../wyatt_authentication_bloc/BaseSignInCubit/dataChanged.md)<Value>([String](https://api.flutter.dev/flutter/dart-core/String-class.html) key, FormInputValidator<Value, ValidationError> dirtyValue) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + +##### [emailChanged](../wyatt_authentication_bloc/SignInWithEmailPassword/emailChanged.md)([String](https://api.flutter.dev/flutter/dart-core/String-class.html) value) void + + + + + + + + +##### [emailCustomChanged](../wyatt_authentication_bloc/SignInWithEmailPassword/emailCustomChanged.md)<Validator extends FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError>>(Validator validator) void + + + +Same as emailChanged but with a custom Validator. + + + + +##### [emit](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/emit.html)([SignInState](../wyatt_authentication_bloc/SignInState-class.md) state) void + + + +Updates the state to the provided state. +emit does nothing if the state being emitted +is equal to the current state. +_inherited_ + + + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [onChange](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onChange.html)([Change](https://pub.dev/documentation/bloc/8.1.0/bloc/Change-class.html)<[SignInState](../wyatt_authentication_bloc/SignInState-class.md)> change) void + + + +Called whenever a change occurs with the given change. +A change occurs when a new state is emitted. +onChange is called before the state of the cubit is updated. +onChange is a great spot to add logging/analytics for a specific cubit. +_inherited_ + + + +##### [onError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html) stackTrace) void + + + +Called whenever an error occurs and notifies BlocObserver.onError. +_inherited_ + + + +##### [onSignInWithEmailAndPassword](../wyatt_authentication_bloc/SignInWithEmailPassword/onSignInWithEmailAndPassword.md)(Result<[Account](../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) FutureOrResult<Data?> + + + +This callback is triggered when a user signs in with email and password. + + + + +##### [passwordChanged](../wyatt_authentication_bloc/SignInWithEmailPassword/passwordChanged.md)([String](https://api.flutter.dev/flutter/dart-core/String-class.html) value) void + + + + + + + + +##### [passwordCustomChanged](../wyatt_authentication_bloc/SignInWithEmailPassword/passwordCustomChanged.md)<Validator extends FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError>>(Validator validator) void + + + +Same as passwordChanged but with a custom Validator. + + + + +##### [reset](../wyatt_authentication_bloc/BaseSignInCubit/reset.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + +##### [signInWithEmailAndPassword](../wyatt_authentication_bloc/SignInWithEmailPassword/signInWithEmailAndPassword.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + +Signs in with the provided email and password. + + + + +##### [submit](../wyatt_authentication_bloc/BaseSignInCubit/submit.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + +##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + +##### [update](../wyatt_authentication_bloc/BaseSignInCubit/update.md)(WyattForm form, {SetOperation operation = SetOperation.replace}) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + +##### [validate](../wyatt_authentication_bloc/BaseSignInCubit/validate.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword/emailChanged.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword/emailChanged.md new file mode 100644 index 00000000..85e7cc16 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword/emailChanged.md @@ -0,0 +1,47 @@ + + + +# emailChanged method + + + + + *[](https://dart.dev/null-safety)* + + + + +void emailChanged +([String](https://api.flutter.dev/flutter/dart-core/String-class.html) value) + + + + + + + + +## Implementation + +```dart +void emailChanged(String value) { + final emailValidatorType = formRepository + .accessForm(formName) + .validatorOf(AuthFormField.email) + .runtimeType; + assert( + emailValidatorType == Email, + 'Use emailCustomChanged(...) with validator $emailValidatorType', + ); + + final Email email = Email.dirty(value); + dataChanged(AuthFormField.email, email); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword/emailCustomChanged.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword/emailCustomChanged.md new file mode 100644 index 00000000..fcb48b24 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword/emailCustomChanged.md @@ -0,0 +1,42 @@ + + + +# emailCustomChanged<Validator extends FormInputValidator<String?, ValidationError>> method + + + + + *[](https://dart.dev/null-safety)* + + + + +void emailCustomChanged +<Validator extends FormInputValidator<String?, ValidationError>>(Validator validator) + + + + + +

Same as emailChanged but with a custom Validator.

+

Sort of short hand for dataChanged.

+ + + +## Implementation + +```dart +void emailCustomChanged< + Validator extends FormInputValidator>( + Validator validator, +) { + dataChanged(AuthFormField.email, validator); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword/onSignInWithEmailAndPassword.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword/onSignInWithEmailAndPassword.md new file mode 100644 index 00000000..0a35342a --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword/onSignInWithEmailAndPassword.md @@ -0,0 +1,39 @@ + + + +# onSignInWithEmailAndPassword method + + + + + *[](https://dart.dev/null-safety)* + + + + +FutureOrResult<Data?> onSignInWithEmailAndPassword +(Result<[Account](../../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) + + + + + +

This callback is triggered when a user signs in with email and password.

+ + + +## Implementation + +```dart +FutureOrResult onSignInWithEmailAndPassword( + Result result, + WyattForm form, +); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword/passwordChanged.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword/passwordChanged.md new file mode 100644 index 00000000..8db9fda0 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword/passwordChanged.md @@ -0,0 +1,46 @@ + + + +# passwordChanged method + + + + + *[](https://dart.dev/null-safety)* + + + + +void passwordChanged +([String](https://api.flutter.dev/flutter/dart-core/String-class.html) value) + + + + + + + + +## Implementation + +```dart +void passwordChanged(String value) { + final passwordValidatorType = formRepository + .accessForm(formName) + .validatorOf(AuthFormField.password) + .runtimeType; + assert( + passwordValidatorType == Password, + 'Use passwordCustomChanged(...) with validator $passwordValidatorType', + ); + final Password password = Password.dirty(value); + dataChanged(AuthFormField.password, password); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword/passwordCustomChanged.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword/passwordCustomChanged.md new file mode 100644 index 00000000..cca9b5ad --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword/passwordCustomChanged.md @@ -0,0 +1,42 @@ + + + +# passwordCustomChanged<Validator extends FormInputValidator<String?, ValidationError>> method + + + + + *[](https://dart.dev/null-safety)* + + + + +void passwordCustomChanged +<Validator extends FormInputValidator<String?, ValidationError>>(Validator validator) + + + + + +

Same as passwordChanged but with a custom Validator.

+

Sort of short hand for dataChanged.

+ + + +## Implementation + +```dart +void passwordCustomChanged< + Validator extends FormInputValidator>( + Validator validator, +) { + dataChanged(AuthFormField.password, validator); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword/signInWithEmailAndPassword.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword/signInWithEmailAndPassword.md new file mode 100644 index 00000000..808606f8 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword/signInWithEmailAndPassword.md @@ -0,0 +1,105 @@ + + + +# signInWithEmailAndPassword method + + + + + *[](https://dart.dev/null-safety)* + + + + +[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> signInWithEmailAndPassword +() + + + + + +

Signs in with the provided email and password.

+

Throws a SignInWithEmailAndPasswordFailureInterface if +an exception occurs.

+ + + +## Implementation + +```dart +FutureOr signInWithEmailAndPassword() async { + if (state.status.isSubmissionInProgress) { + return; + } + + if (!state.status.isValidated) { + return; + } + + final form = formRepository.accessForm(formName); + emit( + SignInState( + form: form, + status: FormStatus.submissionInProgress, + ), + ); + + final email = form.valueOf(AuthFormField.email); + final password = form.valueOf(AuthFormField.password); + + if (email.isNullOrEmpty || password.isNullOrEmpty) { + emit( + SignInState( + form: form, + errorMessage: 'An error occured while retrieving data from the form.', + status: FormStatus.submissionFailure, + ), + ); + } + + return CustomRoutine( + routine: () => authenticationRepository.signInWithEmailAndPassword( + email: email!, + password: password!, + ), + attachedLogic: (routineResult) => onSignInWithEmailAndPassword( + routineResult, + form, + ), + onError: (error) { + emit( + SignInState( + form: form, + errorMessage: error.message, + status: FormStatus.submissionFailure, + ), + ); + addError(error); + }, + onSuccess: (account, data) { + authenticationRepository.addSession( + SessionWrapper( + event: SignedInEvent(account: account), + session: Session( + account: account, + data: data, + ), + ), + ); + emit( + SignInState( + form: form, + status: FormStatus.submissionSuccess, + ), + ); + }, + ).call(); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithFacebookFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithFacebookFailureFirebase-class.md new file mode 100644 index 00000000..f1e15f55 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithFacebookFailureFirebase-class.md @@ -0,0 +1,141 @@ + + + +# SignInWithFacebookFailureFirebase class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown during the sign in process if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- [SignInWithCredentialFailureInterface](../wyatt_authentication_bloc/SignInWithCredentialFailureInterface-class.md) +- [SignInWithCredentialFailureFirebase](../wyatt_authentication_bloc/SignInWithCredentialFailureFirebase-class.md) +- SignInWithFacebookFailureFirebase + +**Implemented types** + +- [SignInWithFacebookFailureInterface](../wyatt_authentication_bloc/SignInWithFacebookFailureInterface-class.md) + + + + + + + +## Constructors + +[SignInWithFacebookFailureFirebase](../wyatt_authentication_bloc/SignInWithFacebookFailureFirebase/SignInWithFacebookFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + +[SignInWithFacebookFailureFirebase.fromCode](../wyatt_authentication_bloc/SignInWithFacebookFailureFirebase/SignInWithFacebookFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithFacebookFailureFirebase/SignInWithFacebookFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithFacebookFailureFirebase/SignInWithFacebookFailureFirebase.fromCode.md new file mode 100644 index 00000000..10c11c0b --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithFacebookFailureFirebase/SignInWithFacebookFailureFirebase.fromCode.md @@ -0,0 +1,30 @@ + + + +# SignInWithFacebookFailureFirebase.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SignInWithFacebookFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + + +## Implementation + +```dart +SignInWithFacebookFailureFirebase.fromCode(super.code) : super.fromCode(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithFacebookFailureFirebase/SignInWithFacebookFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithFacebookFailureFirebase/SignInWithFacebookFailureFirebase.md new file mode 100644 index 00000000..df7ed863 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithFacebookFailureFirebase/SignInWithFacebookFailureFirebase.md @@ -0,0 +1,30 @@ + + + +# SignInWithFacebookFailureFirebase constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SignInWithFacebookFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + + + +## Implementation + +```dart +SignInWithFacebookFailureFirebase([super.code, super.msg]); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithFacebookFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithFacebookFailureInterface-class.md new file mode 100644 index 00000000..c0ad332f --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithFacebookFailureInterface-class.md @@ -0,0 +1,139 @@ + + + +# SignInWithFacebookFailureInterface class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown during the sign in process if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- SignInWithFacebookFailureInterface + + + +**Implementers** + +- [SignInWithFacebookFailureFirebase](../wyatt_authentication_bloc/SignInWithFacebookFailureFirebase-class.md) + + + + + +## Constructors + +[SignInWithFacebookFailureInterface](../wyatt_authentication_bloc/SignInWithFacebookFailureInterface/SignInWithFacebookFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + +Thrown during the sign in process if a failure occurs. + +[SignInWithFacebookFailureInterface.fromCode](../wyatt_authentication_bloc/SignInWithFacebookFailureInterface/SignInWithFacebookFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + +Thrown during the sign in process if a failure occurs. + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithFacebookFailureInterface/SignInWithFacebookFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithFacebookFailureInterface/SignInWithFacebookFailureInterface.fromCode.md new file mode 100644 index 00000000..539c8a5a --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithFacebookFailureInterface/SignInWithFacebookFailureInterface.fromCode.md @@ -0,0 +1,31 @@ + + + +# SignInWithFacebookFailureInterface.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SignInWithFacebookFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + +

Thrown during the sign in process if a failure occurs.

+ + + +## Implementation + +```dart +SignInWithFacebookFailureInterface.fromCode(super.code) : super.fromCode(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithFacebookFailureInterface/SignInWithFacebookFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithFacebookFailureInterface/SignInWithFacebookFailureInterface.md new file mode 100644 index 00000000..abace647 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithFacebookFailureInterface/SignInWithFacebookFailureInterface.md @@ -0,0 +1,31 @@ + + + +# SignInWithFacebookFailureInterface constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SignInWithFacebookFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + + +

Thrown during the sign in process if a failure occurs.

+ + + +## Implementation + +```dart +SignInWithFacebookFailureInterface(super.code, super.msg); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogle-mixin.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogle-mixin.md new file mode 100644 index 00000000..ff62c2b5 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogle-mixin.md @@ -0,0 +1,269 @@ + + + +# SignInWithGoogle<Data> mixin + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Sign in mixin.

+

Allows the user to sign in with google

+

Gives access to the signInWithGoogle method and +onSignInWithGoogle callback.

+ + +**Superclass Constraints** + +- [BaseSignInCubit](../wyatt_authentication_bloc/BaseSignInCubit-class.md)<Data> + + + + +**Mixin Applications** + +- [SignInCubit](../wyatt_authentication_bloc/SignInCubit-class.md) + + + +## Properties + +##### [authenticationRepository](../wyatt_authentication_bloc/BaseSignInCubit/authenticationRepository.md) → [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> + + + + +_finalinherited_ + + + +##### [formName](../wyatt_authentication_bloc/BaseSignInCubit/formName.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [formRepository](../wyatt_authentication_bloc/BaseSignInCubit/formRepository.md) → FormRepository + + + + +_read-onlyinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [isClosed](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/isClosed.html) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +Whether the bloc is closed. +_read-onlyinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + +##### [state](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/state.html) → [SignInState](../wyatt_authentication_bloc/SignInState-class.md) + + + +The current state. +_read-onlyinherited_ + + + +##### [stream](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/stream.html) → [Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[SignInState](../wyatt_authentication_bloc/SignInState-class.md)> + + + +The current stream of states. +_read-onlyinherited_ + + + + + +## Methods + +##### [addError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/addError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [[StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html)? stackTrace]) void + + + +Reports an error which triggers onError with an optional StackTrace. +_inherited_ + + + +##### [close](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/close.html)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> + + + +Closes the instance. +This method should be called when the instance is no longer needed. +Once close is called, the instance can no longer be used. +_inherited_ + + + +##### [dataChanged](../wyatt_authentication_bloc/BaseSignInCubit/dataChanged.md)<Value>([String](https://api.flutter.dev/flutter/dart-core/String-class.html) key, FormInputValidator<Value, ValidationError> dirtyValue) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + +##### [emit](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/emit.html)([SignInState](../wyatt_authentication_bloc/SignInState-class.md) state) void + + + +Updates the state to the provided state. +emit does nothing if the state being emitted +is equal to the current state. +_inherited_ + + + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [onChange](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onChange.html)([Change](https://pub.dev/documentation/bloc/8.1.0/bloc/Change-class.html)<[SignInState](../wyatt_authentication_bloc/SignInState-class.md)> change) void + + + +Called whenever a change occurs with the given change. +A change occurs when a new state is emitted. +onChange is called before the state of the cubit is updated. +onChange is a great spot to add logging/analytics for a specific cubit. +_inherited_ + + + +##### [onError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html) stackTrace) void + + + +Called whenever an error occurs and notifies BlocObserver.onError. +_inherited_ + + + +##### [onSignInWithGoogle](../wyatt_authentication_bloc/SignInWithGoogle/onSignInWithGoogle.md)(Result<[Account](../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) FutureOrResult<Data?> + + + +This callback is triggered when a user signs in with google. + + + + +##### [reset](../wyatt_authentication_bloc/BaseSignInCubit/reset.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + +##### [signInWithGoogle](../wyatt_authentication_bloc/SignInWithGoogle/signInWithGoogle.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + +Starts the Sign In with Google Flow. + + + + +##### [submit](../wyatt_authentication_bloc/BaseSignInCubit/submit.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + +##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + +##### [update](../wyatt_authentication_bloc/BaseSignInCubit/update.md)(WyattForm form, {SetOperation operation = SetOperation.replace}) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + +##### [validate](../wyatt_authentication_bloc/BaseSignInCubit/validate.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogle/onSignInWithGoogle.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogle/onSignInWithGoogle.md new file mode 100644 index 00000000..2f91ea65 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogle/onSignInWithGoogle.md @@ -0,0 +1,39 @@ + + + +# onSignInWithGoogle method + + + + + *[](https://dart.dev/null-safety)* + + + + +FutureOrResult<Data?> onSignInWithGoogle +(Result<[Account](../../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) + + + + + +

This callback is triggered when a user signs in with google.

+ + + +## Implementation + +```dart +FutureOrResult onSignInWithGoogle( + Result result, + WyattForm form, +); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogle/signInWithGoogle.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogle/signInWithGoogle.md new file mode 100644 index 00000000..5f6d2741 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogle/signInWithGoogle.md @@ -0,0 +1,78 @@ + + + +# signInWithGoogle method + + + + + *[](https://dart.dev/null-safety)* + + + + +[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> signInWithGoogle +() + + + + + +

Starts the Sign In with Google Flow.

+

Throws a SignInWithGoogleFailureInterface if an exception occurs.

+ + + +## Implementation + +```dart +FutureOr signInWithGoogle() async { + if (state.status.isSubmissionInProgress) { + return; + } + final form = formRepository.accessForm(formName); + emit(SignInState(form: form, status: FormStatus.submissionInProgress)); + + return CustomRoutine( + routine: authenticationRepository.signInWithGoogle, + attachedLogic: (routineResult) => onSignInWithGoogle( + routineResult, + form, + ), + onError: (error) { + emit( + SignInState( + form: form, + errorMessage: error.message, + status: FormStatus.submissionFailure, + ), + ); + addError(error); + }, + onSuccess: (account, data) { + authenticationRepository.addSession( + SessionWrapper( + event: SignedInEvent(account: account), + session: Session( + account: account, + data: data, + ), + ), + ); + emit( + SignInState( + form: form, + status: FormStatus.submissionSuccess, + ), + ); + }, + ).call(); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogleFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogleFailureFirebase-class.md new file mode 100644 index 00000000..91cf6845 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogleFailureFirebase-class.md @@ -0,0 +1,141 @@ + + + +# SignInWithGoogleFailureFirebase class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown during the sign in process if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- [SignInWithCredentialFailureInterface](../wyatt_authentication_bloc/SignInWithCredentialFailureInterface-class.md) +- [SignInWithCredentialFailureFirebase](../wyatt_authentication_bloc/SignInWithCredentialFailureFirebase-class.md) +- SignInWithGoogleFailureFirebase + +**Implemented types** + +- [SignInWithGoogleFailureInterface](../wyatt_authentication_bloc/SignInWithGoogleFailureInterface-class.md) + + + + + + + +## Constructors + +[SignInWithGoogleFailureFirebase](../wyatt_authentication_bloc/SignInWithGoogleFailureFirebase/SignInWithGoogleFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + +[SignInWithGoogleFailureFirebase.fromCode](../wyatt_authentication_bloc/SignInWithGoogleFailureFirebase/SignInWithGoogleFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogleFailureFirebase/SignInWithGoogleFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogleFailureFirebase/SignInWithGoogleFailureFirebase.fromCode.md new file mode 100644 index 00000000..c189a40e --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogleFailureFirebase/SignInWithGoogleFailureFirebase.fromCode.md @@ -0,0 +1,30 @@ + + + +# SignInWithGoogleFailureFirebase.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SignInWithGoogleFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + + +## Implementation + +```dart +SignInWithGoogleFailureFirebase.fromCode(super.code) : super.fromCode(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogleFailureFirebase/SignInWithGoogleFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogleFailureFirebase/SignInWithGoogleFailureFirebase.md new file mode 100644 index 00000000..2a67c09d --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogleFailureFirebase/SignInWithGoogleFailureFirebase.md @@ -0,0 +1,30 @@ + + + +# SignInWithGoogleFailureFirebase constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SignInWithGoogleFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + + + +## Implementation + +```dart +SignInWithGoogleFailureFirebase([super.code, super.msg]); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogleFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogleFailureInterface-class.md new file mode 100644 index 00000000..0712ff53 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogleFailureInterface-class.md @@ -0,0 +1,139 @@ + + + +# SignInWithGoogleFailureInterface class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown during the sign in process if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- SignInWithGoogleFailureInterface + + + +**Implementers** + +- [SignInWithGoogleFailureFirebase](../wyatt_authentication_bloc/SignInWithGoogleFailureFirebase-class.md) + + + + + +## Constructors + +[SignInWithGoogleFailureInterface](../wyatt_authentication_bloc/SignInWithGoogleFailureInterface/SignInWithGoogleFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + +Thrown during the sign in process if a failure occurs. + +[SignInWithGoogleFailureInterface.fromCode](../wyatt_authentication_bloc/SignInWithGoogleFailureInterface/SignInWithGoogleFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + +Thrown during the sign in process if a failure occurs. + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogleFailureInterface/SignInWithGoogleFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogleFailureInterface/SignInWithGoogleFailureInterface.fromCode.md new file mode 100644 index 00000000..16441dda --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogleFailureInterface/SignInWithGoogleFailureInterface.fromCode.md @@ -0,0 +1,31 @@ + + + +# SignInWithGoogleFailureInterface.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SignInWithGoogleFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + +

Thrown during the sign in process if a failure occurs.

+ + + +## Implementation + +```dart +SignInWithGoogleFailureInterface.fromCode(super.code) : super.fromCode(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogleFailureInterface/SignInWithGoogleFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogleFailureInterface/SignInWithGoogleFailureInterface.md new file mode 100644 index 00000000..9337f2db --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogleFailureInterface/SignInWithGoogleFailureInterface.md @@ -0,0 +1,31 @@ + + + +# SignInWithGoogleFailureInterface constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SignInWithGoogleFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + + +

Thrown during the sign in process if a failure occurs.

+ + + +## Implementation + +```dart +SignInWithGoogleFailureInterface(super.code, super.msg); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithTwitterFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithTwitterFailureFirebase-class.md new file mode 100644 index 00000000..5aeb8957 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithTwitterFailureFirebase-class.md @@ -0,0 +1,141 @@ + + + +# SignInWithTwitterFailureFirebase class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown during the sign in process if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- [SignInWithCredentialFailureInterface](../wyatt_authentication_bloc/SignInWithCredentialFailureInterface-class.md) +- [SignInWithCredentialFailureFirebase](../wyatt_authentication_bloc/SignInWithCredentialFailureFirebase-class.md) +- SignInWithTwitterFailureFirebase + +**Implemented types** + +- [SignInWithAppleFailureInterface](../wyatt_authentication_bloc/SignInWithAppleFailureInterface-class.md) + + + + + + + +## Constructors + +[SignInWithTwitterFailureFirebase](../wyatt_authentication_bloc/SignInWithTwitterFailureFirebase/SignInWithTwitterFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + +[SignInWithTwitterFailureFirebase.fromCode](../wyatt_authentication_bloc/SignInWithTwitterFailureFirebase/SignInWithTwitterFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithTwitterFailureFirebase/SignInWithTwitterFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithTwitterFailureFirebase/SignInWithTwitterFailureFirebase.fromCode.md new file mode 100644 index 00000000..ce958339 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithTwitterFailureFirebase/SignInWithTwitterFailureFirebase.fromCode.md @@ -0,0 +1,30 @@ + + + +# SignInWithTwitterFailureFirebase.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SignInWithTwitterFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + + +## Implementation + +```dart +SignInWithTwitterFailureFirebase.fromCode(super.code) : super.fromCode(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithTwitterFailureFirebase/SignInWithTwitterFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithTwitterFailureFirebase/SignInWithTwitterFailureFirebase.md new file mode 100644 index 00000000..8d824501 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithTwitterFailureFirebase/SignInWithTwitterFailureFirebase.md @@ -0,0 +1,30 @@ + + + +# SignInWithTwitterFailureFirebase constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SignInWithTwitterFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + + + +## Implementation + +```dart +SignInWithTwitterFailureFirebase([super.code, super.msg]); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithTwitterFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithTwitterFailureInterface-class.md new file mode 100644 index 00000000..3fbd2788 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithTwitterFailureInterface-class.md @@ -0,0 +1,136 @@ + + + +# SignInWithTwitterFailureInterface class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown during the sign in process if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- SignInWithTwitterFailureInterface + + + + + + + + +## Constructors + +[SignInWithTwitterFailureInterface](../wyatt_authentication_bloc/SignInWithTwitterFailureInterface/SignInWithTwitterFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + +Thrown during the sign in process if a failure occurs. + +[SignInWithTwitterFailureInterface.fromCode](../wyatt_authentication_bloc/SignInWithTwitterFailureInterface/SignInWithTwitterFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + +Thrown during the sign in process if a failure occurs. + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithTwitterFailureInterface/SignInWithTwitterFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithTwitterFailureInterface/SignInWithTwitterFailureInterface.fromCode.md new file mode 100644 index 00000000..9d541237 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithTwitterFailureInterface/SignInWithTwitterFailureInterface.fromCode.md @@ -0,0 +1,31 @@ + + + +# SignInWithTwitterFailureInterface.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SignInWithTwitterFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + +

Thrown during the sign in process if a failure occurs.

+ + + +## Implementation + +```dart +SignInWithTwitterFailureInterface.fromCode(super.code) : super.fromCode(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithTwitterFailureInterface/SignInWithTwitterFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithTwitterFailureInterface/SignInWithTwitterFailureInterface.md new file mode 100644 index 00000000..14919bef --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithTwitterFailureInterface/SignInWithTwitterFailureInterface.md @@ -0,0 +1,31 @@ + + + +# SignInWithTwitterFailureInterface constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SignInWithTwitterFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + + +

Thrown during the sign in process if a failure occurs.

+ + + +## Implementation + +```dart +SignInWithTwitterFailureInterface(super.code, super.msg); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignOutFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignOutFailureFirebase-class.md new file mode 100644 index 00000000..3421331f --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignOutFailureFirebase-class.md @@ -0,0 +1,137 @@ + + + +# SignOutFailureFirebase class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown during the sign out process if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- [SignOutFailureInterface](../wyatt_authentication_bloc/SignOutFailureInterface-class.md) +- SignOutFailureFirebase + + + + + + + + +## Constructors + +[SignOutFailureFirebase](../wyatt_authentication_bloc/SignOutFailureFirebase/SignOutFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + +[SignOutFailureFirebase.fromCode](../wyatt_authentication_bloc/SignOutFailureFirebase/SignOutFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignOutFailureFirebase/SignOutFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignOutFailureFirebase/SignOutFailureFirebase.fromCode.md new file mode 100644 index 00000000..6cf59631 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignOutFailureFirebase/SignOutFailureFirebase.fromCode.md @@ -0,0 +1,30 @@ + + + +# SignOutFailureFirebase.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SignOutFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + + +## Implementation + +```dart +SignOutFailureFirebase.fromCode(super.code) : super.fromCode(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignOutFailureFirebase/SignOutFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignOutFailureFirebase/SignOutFailureFirebase.md new file mode 100644 index 00000000..c6fc7d7a --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignOutFailureFirebase/SignOutFailureFirebase.md @@ -0,0 +1,31 @@ + + + +# SignOutFailureFirebase constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SignOutFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + + + +## Implementation + +```dart +SignOutFailureFirebase([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignOutFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignOutFailureInterface-class.md new file mode 100644 index 00000000..cf527a70 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignOutFailureInterface-class.md @@ -0,0 +1,139 @@ + + + +# SignOutFailureInterface class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown during the sign out process if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- SignOutFailureInterface + + + +**Implementers** + +- [SignOutFailureFirebase](../wyatt_authentication_bloc/SignOutFailureFirebase-class.md) + + + + + +## Constructors + +[SignOutFailureInterface](../wyatt_authentication_bloc/SignOutFailureInterface/SignOutFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + +Thrown during the sign out process if a failure occurs. + +[SignOutFailureInterface.fromCode](../wyatt_authentication_bloc/SignOutFailureInterface/SignOutFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + +Thrown during the sign out process if a failure occurs. + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignOutFailureInterface/SignOutFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignOutFailureInterface/SignOutFailureInterface.fromCode.md new file mode 100644 index 00000000..bde9935f --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignOutFailureInterface/SignOutFailureInterface.fromCode.md @@ -0,0 +1,31 @@ + + + +# SignOutFailureInterface.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SignOutFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + +

Thrown during the sign out process if a failure occurs.

+ + + +## Implementation + +```dart +SignOutFailureInterface.fromCode(super.code) : super.fromCode(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignOutFailureInterface/SignOutFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignOutFailureInterface/SignOutFailureInterface.md new file mode 100644 index 00000000..a59596a0 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignOutFailureInterface/SignOutFailureInterface.md @@ -0,0 +1,31 @@ + + + +# SignOutFailureInterface constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SignOutFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + + +

Thrown during the sign out process if a failure occurs.

+ + + +## Implementation + +```dart +SignOutFailureInterface(super.code, super.msg); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpCubit-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpCubit-class.md new file mode 100644 index 00000000..b8229ff4 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpCubit-class.md @@ -0,0 +1,316 @@ + + + +# SignUpCubit<Data> class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Fully featured sign up cubit.

+

Sufficient in most cases. (Where fine granularity is not required.)

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [BlocBase](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase-class.html)<[SignUpState](../wyatt_authentication_bloc/SignUpState-class.md)> +- [Cubit](https://pub.dev/documentation/bloc/8.1.0/bloc/Cubit-class.html)<[SignUpState](../wyatt_authentication_bloc/SignUpState-class.md)> +- [BaseSignUpCubit](../wyatt_authentication_bloc/BaseSignUpCubit-class.md)<Data> +- SignUpCubit + + +**Mixed in types** + +- [SignUpWithEmailPassword](../wyatt_authentication_bloc/SignUpWithEmailPassword-mixin.md)<Data> + + + + + + +## Constructors + +[SignUpCubit](../wyatt_authentication_bloc/SignUpCubit/SignUpCubit.md) ({required [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> authenticationRepository}) + + + + +## Properties + +##### [authenticationRepository](../wyatt_authentication_bloc/BaseSignUpCubit/authenticationRepository.md) → [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> + + + + +_finalinherited_ + + + +##### [formName](../wyatt_authentication_bloc/BaseSignUpCubit/formName.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [formRepository](../wyatt_authentication_bloc/BaseSignUpCubit/formRepository.md) → FormRepository + + + + +_read-onlyinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [isClosed](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/isClosed.html) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +Whether the bloc is closed. +_read-onlyinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + +##### [state](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/state.html) → [SignUpState](../wyatt_authentication_bloc/SignUpState-class.md) + + + +The current state. +_read-onlyinherited_ + + + +##### [stream](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/stream.html) → [Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[SignUpState](../wyatt_authentication_bloc/SignUpState-class.md)> + + + +The current stream of states. +_read-onlyinherited_ + + + + + +## Methods + +##### [addError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/addError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [[StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html)? stackTrace]) void + + + +Reports an error which triggers onError with an optional StackTrace. +_inherited_ + + + +##### [close](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/close.html)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> + + + +Closes the instance. +This method should be called when the instance is no longer needed. +Once close is called, the instance can no longer be used. +_inherited_ + + + +##### [dataChanged](../wyatt_authentication_bloc/BaseSignUpCubit/dataChanged.md)<Value>([String](https://api.flutter.dev/flutter/dart-core/String-class.html) key, FormInputValidator<Value, ValidationError> dirtyValue) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + +##### [emailChanged](../wyatt_authentication_bloc/SignUpWithEmailPassword/emailChanged.md)([String](https://api.flutter.dev/flutter/dart-core/String-class.html) value) void + + + + +_inherited_ + + + +##### [emailCustomChanged](../wyatt_authentication_bloc/SignUpWithEmailPassword/emailCustomChanged.md)<Validator extends FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError>>(Validator validator) void + + + +Same as emailChanged but with a custom Validator. +_inherited_ + + + +##### [emit](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/emit.html)([SignUpState](../wyatt_authentication_bloc/SignUpState-class.md) state) void + + + +Updates the state to the provided state. +emit does nothing if the state being emitted +is equal to the current state. +_inherited_ + + + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [onChange](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onChange.html)([Change](https://pub.dev/documentation/bloc/8.1.0/bloc/Change-class.html)<[SignUpState](../wyatt_authentication_bloc/SignUpState-class.md)> change) void + + + +Called whenever a change occurs with the given change. +A change occurs when a new state is emitted. +onChange is called before the state of the cubit is updated. +onChange is a great spot to add logging/analytics for a specific cubit. +_inherited_ + + + +##### [onError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html) stackTrace) void + + + +Called whenever an error occurs and notifies BlocObserver.onError. +_inherited_ + + + +##### [onSignUpWithEmailAndPassword](../wyatt_authentication_bloc/SignUpCubit/onSignUpWithEmailAndPassword.md)(Result<[Account](../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) FutureOrResult<Data?> + + + +This callback is triggered when a user creates an account. +_override_ + + + +##### [passwordChanged](../wyatt_authentication_bloc/SignUpWithEmailPassword/passwordChanged.md)([String](https://api.flutter.dev/flutter/dart-core/String-class.html) value) void + + + + +_inherited_ + + + +##### [passwordCustomChanged](../wyatt_authentication_bloc/SignUpWithEmailPassword/passwordCustomChanged.md)<Validator extends FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError>>(Validator validator) void + + + +Same as passwordChanged but with a custom Validator. +_inherited_ + + + +##### [reset](../wyatt_authentication_bloc/BaseSignUpCubit/reset.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + +##### [signUpWithEmailPassword](../wyatt_authentication_bloc/SignUpWithEmailPassword/signUpWithEmailPassword.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + +Creates a new user with the provided email and password. +_inherited_ + + + +##### [submit](../wyatt_authentication_bloc/BaseSignUpCubit/submit.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + +##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + +##### [update](../wyatt_authentication_bloc/BaseSignUpCubit/update.md)(WyattForm form, {SetOperation operation = SetOperation.replace}) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + +##### [validate](../wyatt_authentication_bloc/BaseSignUpCubit/validate.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpCubit/SignUpCubit.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpCubit/SignUpCubit.md new file mode 100644 index 00000000..0306f024 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpCubit/SignUpCubit.md @@ -0,0 +1,30 @@ + + + +# SignUpCubit<Data> constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SignUpCubit<Data>({required [AuthenticationRepository](../../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> authenticationRepository}) + + + + + +## Implementation + +```dart +SignUpCubit({required super.authenticationRepository}); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpCubit/onSignUpWithEmailAndPassword.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpCubit/onSignUpWithEmailAndPassword.md new file mode 100644 index 00000000..e70dfa91 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpCubit/onSignUpWithEmailAndPassword.md @@ -0,0 +1,43 @@ + + + +# onSignUpWithEmailAndPassword method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +FutureOrResult<Data?> onSignUpWithEmailAndPassword +(Result<[Account](../../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) + +_override_ + + + +

This callback is triggered when a user creates an account.

+

For example: when a user sign up in firebase.

+ + + +## Implementation + +```dart +@override +FutureOrResult onSignUpWithEmailAndPassword( + Result result, + WyattForm form, +) => + const Ok(null); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener-class.md new file mode 100644 index 00000000..ea1477a1 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener-class.md @@ -0,0 +1,236 @@ + + + +# SignUpListener<Data> class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Widget that listens and builds a child based on the state of +the sign up cubit

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [DiagnosticableTree](https://api.flutter.dev/flutter/foundation/DiagnosticableTree-class.html) +- [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) +- [StatelessWidget](https://api.flutter.dev/flutter/widgets/StatelessWidget-class.html) +- SignUpListener + + + + + + + + +## Constructors + +[SignUpListener](../wyatt_authentication_bloc/SignUpListener/SignUpListener.md) ({required [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) child, void onProgress([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?, void onSuccess([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?, void onError([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, FormStatus status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage)?, void customBuilder([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, [SignUpState](../wyatt_authentication_bloc/SignUpState-class.md) state)?, [Key](https://api.flutter.dev/flutter/foundation/Key-class.html)? key}) + + _const_ + + +## Properties + +##### [child](../wyatt_authentication_bloc/SignUpListener/child.md) → [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) + + + + +_final_ + + + +##### [customBuilder](../wyatt_authentication_bloc/SignUpListener/customBuilder.md) → (void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, [SignUpState](../wyatt_authentication_bloc/SignUpState-class.md) state)?) + + + + +_final_ + + + +##### [hashCode](https://api.flutter.dev/flutter/widgets/Widget/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [key](https://api.flutter.dev/flutter/widgets/Widget/key.html) → [Key](https://api.flutter.dev/flutter/foundation/Key-class.html)? + + + +Controls how one widget replaces another widget in the tree. +_finalinherited_ + + + +##### [onError](../wyatt_authentication_bloc/SignUpListener/onError.md) → (void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, FormStatus status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage)?) + + + + +_final_ + + + +##### [onProgress](../wyatt_authentication_bloc/SignUpListener/onProgress.md) → (void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?) + + + + +_final_ + + + +##### [onSuccess](../wyatt_authentication_bloc/SignUpListener/onSuccess.md) → (void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?) + + + + +_final_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [build](../wyatt_authentication_bloc/SignUpListener/build.md)([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context) [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) + + + +Describes the part of the user interface represented by this widget. +_override_ + + + +##### [createElement](https://api.flutter.dev/flutter/widgets/StatelessWidget/createElement.html)() [StatelessElement](https://api.flutter.dev/flutter/widgets/StatelessElement-class.html) + + + +Creates a StatelessElement to manage this widget's location in the tree. +_inherited_ + + + +##### [debugDescribeChildren](https://api.flutter.dev/flutter/foundation/DiagnosticableTree/debugDescribeChildren.html)() [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[DiagnosticsNode](https://api.flutter.dev/flutter/foundation/DiagnosticsNode-class.html)> + + + +Returns a list of DiagnosticsNode objects describing this node's +children. +_inherited_ + + + +##### [debugFillProperties](https://api.flutter.dev/flutter/widgets/Widget/debugFillProperties.html)([DiagnosticPropertiesBuilder](https://api.flutter.dev/flutter/foundation/DiagnosticPropertiesBuilder-class.html) properties) void + + + +Add additional properties associated with the node. +_inherited_ + + + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toDiagnosticsNode](https://api.flutter.dev/flutter/foundation/DiagnosticableTree/toDiagnosticsNode.html)({[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? name, [DiagnosticsTreeStyle](https://api.flutter.dev/flutter/foundation/DiagnosticsTreeStyle.html)? style}) [DiagnosticsNode](https://api.flutter.dev/flutter/foundation/DiagnosticsNode-class.html) + + + +Returns a debug representation of the object that is used by debugging +tools and by DiagnosticsNode.toStringDeep. +_inherited_ + + + +##### [toString](https://api.flutter.dev/flutter/foundation/Diagnosticable/toString.html)({[DiagnosticLevel](https://api.flutter.dev/flutter/foundation/DiagnosticLevel.html) minLevel = DiagnosticLevel.info}) [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + +##### [toStringDeep](https://api.flutter.dev/flutter/foundation/DiagnosticableTree/toStringDeep.html)({[String](https://api.flutter.dev/flutter/dart-core/String-class.html) prefixLineOne = '', [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? prefixOtherLines, [DiagnosticLevel](https://api.flutter.dev/flutter/foundation/DiagnosticLevel.html) minLevel = DiagnosticLevel.debug}) [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +Returns a string representation of this node and its descendants. +_inherited_ + + + +##### [toStringShallow](https://api.flutter.dev/flutter/foundation/DiagnosticableTree/toStringShallow.html)({[String](https://api.flutter.dev/flutter/dart-core/String-class.html) joiner = ', ', [DiagnosticLevel](https://api.flutter.dev/flutter/foundation/DiagnosticLevel.html) minLevel = DiagnosticLevel.debug}) [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +Returns a one-line detailed description of the object. +_inherited_ + + + +##### [toStringShort](https://api.flutter.dev/flutter/widgets/Widget/toStringShort.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A short, textual description of this widget. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/widgets/Widget/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/SignUpListener.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/SignUpListener.md new file mode 100644 index 00000000..8eb3409d --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/SignUpListener.md @@ -0,0 +1,37 @@ + + + +# SignUpListener<Data> constructor + + + + + *[](https://dart.dev/null-safety)* + + +const +SignUpListener<Data>({required [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) child, void onProgress([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?, void onSuccess([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?, void onError([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, FormStatus status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage)?, void customBuilder([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, [SignUpState](../../wyatt_authentication_bloc/SignUpState-class.md) state)?, [Key](https://api.flutter.dev/flutter/foundation/Key-class.html)? key}) + + + + + +## Implementation + +```dart +const SignUpListener({ + required this.child, + this.onProgress, + this.onSuccess, + this.onError, + this.customBuilder, + super.key, +}); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/build.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/build.md new file mode 100644 index 00000000..8843765f --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/build.md @@ -0,0 +1,92 @@ + + + +# build method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) build +([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context) + +_override_ + + + +

Describes the part of the user interface represented by this widget.

+

The framework calls this method when this widget is inserted into the tree +in a given BuildContext and when the dependencies of this widget change +(e.g., an InheritedWidget referenced by this widget changes). This +method can potentially be called in every frame and should not have any side +effects beyond building a widget.

+

The framework replaces the subtree below this widget with the widget +returned by this method, either by updating the existing subtree or by +removing the subtree and inflating a new subtree, depending on whether the +widget returned by this method can update the root of the existing +subtree, as determined by calling Widget.canUpdate.

+

Typically implementations return a newly created constellation of widgets +that are configured with information from this widget's constructor and +from the given BuildContext.

+

The given BuildContext contains information about the location in the +tree at which this widget is being built. For example, the context +provides the set of inherited widgets for this location in the tree. A +given widget might be built with multiple different BuildContext +arguments over time if the widget is moved around the tree or if the +widget is inserted into the tree in multiple places at once.

+

The implementation of this method must only depend on:

+ +

If a widget's build method is to depend on anything else, use a +StatefulWidget instead.

+

See also:

+
    +
  • StatelessWidget, which contains the discussion on performance considerations.
  • +
+ + + +## Implementation + +```dart +@override +Widget build(BuildContext context) => + BlocListener, SignUpState>( + listener: (context, state) { + if (customBuilder != null) { + return customBuilder!(context, state); + } + + if (onSuccess != null && + state.status == FormStatus.submissionSuccess) { + return onSuccess!(context); + } + if (onProgress != null && + state.status == FormStatus.submissionInProgress) { + return onProgress!(context); + } + if (onError != null && + (state.status == FormStatus.submissionCanceled || + state.status == FormStatus.submissionFailure)) { + return onError!(context, state.status, state.errorMessage); + } + }, + child: child, + ); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/child.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/child.md new file mode 100644 index 00000000..53bc3682 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/child.md @@ -0,0 +1,33 @@ + + + +# child property + + + + + *[](https://dart.dev/null-safety)* + + + +[Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) child + +_final_ + + + + + + +## Implementation + +```dart +final Widget child; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/customBuilder.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/customBuilder.md new file mode 100644 index 00000000..e59261e0 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/customBuilder.md @@ -0,0 +1,33 @@ + + + +# customBuilder property + + + + + *[](https://dart.dev/null-safety)* + + + +(void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, [SignUpState](../../wyatt_authentication_bloc/SignUpState-class.md) state)?) customBuilder + +_final_ + + + + + + +## Implementation + +```dart +final void Function(BuildContext context, SignUpState state)? customBuilder; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/onError.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/onError.md new file mode 100644 index 00000000..ed94a98f --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/onError.md @@ -0,0 +1,37 @@ + + + +# onError property + + + + + *[](https://dart.dev/null-safety)* + + + +(void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, FormStatus status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage)?) onError + +_final_ + + + + + + +## Implementation + +```dart +final void Function( + BuildContext context, + FormStatus status, + String? errorMessage, +)? onError; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/onProgress.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/onProgress.md new file mode 100644 index 00000000..4a30ed71 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/onProgress.md @@ -0,0 +1,33 @@ + + + +# onProgress property + + + + + *[](https://dart.dev/null-safety)* + + + +(void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?) onProgress + +_final_ + + + + + + +## Implementation + +```dart +final void Function(BuildContext context)? onProgress; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/onSuccess.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/onSuccess.md new file mode 100644 index 00000000..4d942f63 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/onSuccess.md @@ -0,0 +1,33 @@ + + + +# onSuccess property + + + + + *[](https://dart.dev/null-safety)* + + + +(void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?) onSuccess + +_final_ + + + + + + +## Implementation + +```dart +final void Function(BuildContext context)? onSuccess; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState-class.md new file mode 100644 index 00000000..d1a945ac --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState-class.md @@ -0,0 +1,179 @@ + + + +# SignUpState class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Sign up cubit state to manage the form.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [Equatable](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable-class.html) +- SignUpState + + + + + + + + +## Constructors + +[SignUpState](../wyatt_authentication_bloc/SignUpState/SignUpState.md) ({required WyattForm form, FormStatus status = FormStatus.pure, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage}) + + _const_ + + +## Properties + +##### [email](../wyatt_authentication_bloc/SignUpState/email.md) → FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError> + + + + +_read-only_ + + + +##### [errorMessage](../wyatt_authentication_bloc/SignUpState/errorMessage.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? + + + +Optional error message. +_finalinherited_ + + + +##### [form](../wyatt_authentication_bloc/SignUpState/form.md) → WyattForm + + + +FormData with all inputs, and associated metadata. +_finalinherited_ + + + +##### [hashCode](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [password](../wyatt_authentication_bloc/SignUpState/password.md) → FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError> + + + + +_read-only_ + + + +##### [props](../wyatt_authentication_bloc/SignUpState/props.md) → [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> + + + +The list of properties that will be used to determine whether +two instances are equal. +_read-only_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + +##### [status](../wyatt_authentication_bloc/SignUpState/status.md) → FormStatus + + + +Global status of a form. +_finalinherited_ + + + +##### [stringify](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/stringify.html) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)? + + + +If set to true, the toString method will be overridden to output +this instance's props. +_read-onlyinherited_ + + + + + +## Methods + +##### [copyWith](../wyatt_authentication_bloc/SignUpState/copyWith.md)({WyattForm? form, FormStatus? status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage}) [SignUpState](../wyatt_authentication_bloc/SignUpState-class.md) + + + + + + + + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/SignUpState/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_override_ + + + + + +## Operators + +##### [operator ==](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/SignUpState.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/SignUpState.md new file mode 100644 index 00000000..2225e87b --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/SignUpState.md @@ -0,0 +1,34 @@ + + + +# SignUpState constructor + + + + + *[](https://dart.dev/null-safety)* + + +const +SignUpState({required WyattForm form, FormStatus status = FormStatus.pure, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage}) + + + + + +## Implementation + +```dart +const SignUpState({ + required super.form, + super.status = FormStatus.pure, + super.errorMessage, +}); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/copyWith.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/copyWith.md new file mode 100644 index 00000000..35561e0b --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/copyWith.md @@ -0,0 +1,44 @@ + + + +# copyWith method + + + + + *[](https://dart.dev/null-safety)* + + + + +[SignUpState](../../wyatt_authentication_bloc/SignUpState-class.md) copyWith +({WyattForm? form, FormStatus? status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage}) + + + + + + + + +## Implementation + +```dart +SignUpState copyWith({ + WyattForm? form, + FormStatus? status, + String? errorMessage, +}) => + SignUpState( + form: form ?? this.form, + status: status ?? this.status, + errorMessage: errorMessage ?? this.errorMessage, + ); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/email.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/email.md new file mode 100644 index 00000000..1ded8043 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/email.md @@ -0,0 +1,37 @@ + + + +# email property + + + + + *[](https://dart.dev/null-safety)* + + + + + +FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError> email + + + + + + + + +## Implementation + +```dart +FormInputValidator get email => + form.validatorOf(AuthFormField.email); +``` + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/errorMessage.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/errorMessage.md new file mode 100644 index 00000000..d0856deb --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/errorMessage.md @@ -0,0 +1,34 @@ + + + +# errorMessage property + + + + + *[](https://dart.dev/null-safety)* + + + +[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage + +_finalinherited_ + + + +

Optional error message.

+ + + +## Implementation + +```dart +final String? errorMessage; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/form.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/form.md new file mode 100644 index 00000000..d3f2da76 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/form.md @@ -0,0 +1,34 @@ + + + +# form property + + + + + *[](https://dart.dev/null-safety)* + + + +WyattForm form + +_finalinherited_ + + + +

FormData with all inputs, and associated metadata.

+ + + +## Implementation + +```dart +final WyattForm form; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/password.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/password.md new file mode 100644 index 00000000..77938106 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/password.md @@ -0,0 +1,37 @@ + + + +# password property + + + + + *[](https://dart.dev/null-safety)* + + + + + +FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError> password + + + + + + + + +## Implementation + +```dart +FormInputValidator get password => + form.validatorOf(AuthFormField.password); +``` + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/props.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/props.md new file mode 100644 index 00000000..2b5a46b8 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/props.md @@ -0,0 +1,42 @@ + + + +# props property + + + + + *[](https://dart.dev/null-safety)* + + + + + +**Annotations** + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) +[List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> props + + + + + +

The list of properties that will be used to determine whether +two instances are equal.

+ + + +## Implementation + +```dart +@override +List get props => [email, password, status, form]; +``` + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/status.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/status.md new file mode 100644 index 00000000..644a9f10 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/status.md @@ -0,0 +1,34 @@ + + + +# status property + + + + + *[](https://dart.dev/null-safety)* + + + +FormStatus status + +_finalinherited_ + + + +

Global status of a form.

+ + + +## Implementation + +```dart +final FormStatus status; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/toString.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/toString.md new file mode 100644 index 00000000..e53f76d6 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/toString.md @@ -0,0 +1,50 @@ + + + +# toString method + + + + + *[](https://dart.dev/null-safety)* + + + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) + +[String](https://api.flutter.dev/flutter/dart-core/String-class.html) toString +() + +_override_ + + + +

A string representation of this object.

+

Some classes have a default textual representation, +often paired with a static parse function (like int.parse). +These classes will provide the textual representation as +their string representation.

+

Other classes have no meaningful textual representation +that a program will care about. +Such classes will typically override toString to provide +useful information when inspecting the object, +mainly for debugging or logging.

+ + + +## Implementation + +```dart +@override +@override +String toString() => 'SignUpState(status: ${status.name} ' + '${(errorMessage != null) ? " [$errorMessage]" : ""}, $form)'; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureFirebase-class.md new file mode 100644 index 00000000..0b725844 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureFirebase-class.md @@ -0,0 +1,137 @@ + + + +# SignUpWithEmailAndPasswordFailureFirebase class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown if during the sign up process if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- [SignUpWithEmailAndPasswordFailureInterface](../wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureInterface-class.md) +- SignUpWithEmailAndPasswordFailureFirebase + + + + + + + + +## Constructors + +[SignUpWithEmailAndPasswordFailureFirebase](../wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureFirebase/SignUpWithEmailAndPasswordFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + +[SignUpWithEmailAndPasswordFailureFirebase.fromCode](../wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureFirebase/SignUpWithEmailAndPasswordFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureFirebase/SignUpWithEmailAndPasswordFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureFirebase/SignUpWithEmailAndPasswordFailureFirebase.fromCode.md new file mode 100644 index 00000000..a88070e0 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureFirebase/SignUpWithEmailAndPasswordFailureFirebase.fromCode.md @@ -0,0 +1,52 @@ + + + +# SignUpWithEmailAndPasswordFailureFirebase.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SignUpWithEmailAndPasswordFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + + +## Implementation + +```dart +SignUpWithEmailAndPasswordFailureFirebase.fromCode(String code) + : super.fromCode(code) { + switch (code) { + case 'invalid-email': + msg = 'The email address is badly formatted.'; + break; + case 'user-disabled': + msg = 'This user has been disabled. Please contact support for help.'; + break; + case 'email-already-in-use': + msg = 'An account already exists for that email.'; + break; + case 'operation-not-allowed': + msg = 'Operation is not allowed. Please contact support.'; + break; + case 'weak-password': + msg = 'Please enter a stronger password.'; + break; + default: + this.code = 'unknown'; + msg = 'An unknown error occurred.'; + } +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureFirebase/SignUpWithEmailAndPasswordFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureFirebase/SignUpWithEmailAndPasswordFailureFirebase.md new file mode 100644 index 00000000..3c589850 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureFirebase/SignUpWithEmailAndPasswordFailureFirebase.md @@ -0,0 +1,31 @@ + + + +# SignUpWithEmailAndPasswordFailureFirebase constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SignUpWithEmailAndPasswordFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + + + +## Implementation + +```dart +SignUpWithEmailAndPasswordFailureFirebase([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureInterface-class.md new file mode 100644 index 00000000..934c07dd --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureInterface-class.md @@ -0,0 +1,139 @@ + + + +# SignUpWithEmailAndPasswordFailureInterface class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown if during the sign up process if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- SignUpWithEmailAndPasswordFailureInterface + + + +**Implementers** + +- [SignUpWithEmailAndPasswordFailureFirebase](../wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureFirebase-class.md) + + + + + +## Constructors + +[SignUpWithEmailAndPasswordFailureInterface](../wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureInterface/SignUpWithEmailAndPasswordFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + +Thrown if during the sign up process if a failure occurs. + +[SignUpWithEmailAndPasswordFailureInterface.fromCode](../wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureInterface/SignUpWithEmailAndPasswordFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + +Thrown if during the sign up process if a failure occurs. + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureInterface/SignUpWithEmailAndPasswordFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureInterface/SignUpWithEmailAndPasswordFailureInterface.fromCode.md new file mode 100644 index 00000000..4eba5121 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureInterface/SignUpWithEmailAndPasswordFailureInterface.fromCode.md @@ -0,0 +1,32 @@ + + + +# SignUpWithEmailAndPasswordFailureInterface.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SignUpWithEmailAndPasswordFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + +

Thrown if during the sign up process if a failure occurs.

+ + + +## Implementation + +```dart +SignUpWithEmailAndPasswordFailureInterface.fromCode(super.code) + : super.fromCode(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureInterface/SignUpWithEmailAndPasswordFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureInterface/SignUpWithEmailAndPasswordFailureInterface.md new file mode 100644 index 00000000..105e574d --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureInterface/SignUpWithEmailAndPasswordFailureInterface.md @@ -0,0 +1,31 @@ + + + +# SignUpWithEmailAndPasswordFailureInterface constructor + + + + + *[](https://dart.dev/null-safety)* + + + +SignUpWithEmailAndPasswordFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + + +

Thrown if during the sign up process if a failure occurs.

+ + + +## Implementation + +```dart +SignUpWithEmailAndPasswordFailureInterface(super.code, super.msg); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword-mixin.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword-mixin.md new file mode 100644 index 00000000..220af3ad --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword-mixin.md @@ -0,0 +1,305 @@ + + + +# SignUpWithEmailPassword<Data> mixin + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Sign up mixin.

+

Allows the user to register with an email and a password.

+

Gives access to the signUpWithEmailPassword method and +onSignUpWithEmailAndPassword callback.

+ + +**Superclass Constraints** + +- [BaseSignUpCubit](../wyatt_authentication_bloc/BaseSignUpCubit-class.md)<Data> + + + + +**Mixin Applications** + +- [SignUpCubit](../wyatt_authentication_bloc/SignUpCubit-class.md) + + + +## Properties + +##### [authenticationRepository](../wyatt_authentication_bloc/BaseSignUpCubit/authenticationRepository.md) → [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> + + + + +_finalinherited_ + + + +##### [formName](../wyatt_authentication_bloc/BaseSignUpCubit/formName.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [formRepository](../wyatt_authentication_bloc/BaseSignUpCubit/formRepository.md) → FormRepository + + + + +_read-onlyinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [isClosed](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/isClosed.html) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +Whether the bloc is closed. +_read-onlyinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + +##### [state](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/state.html) → [SignUpState](../wyatt_authentication_bloc/SignUpState-class.md) + + + +The current state. +_read-onlyinherited_ + + + +##### [stream](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/stream.html) → [Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[SignUpState](../wyatt_authentication_bloc/SignUpState-class.md)> + + + +The current stream of states. +_read-onlyinherited_ + + + + + +## Methods + +##### [addError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/addError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [[StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html)? stackTrace]) void + + + +Reports an error which triggers onError with an optional StackTrace. +_inherited_ + + + +##### [close](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/close.html)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> + + + +Closes the instance. +This method should be called when the instance is no longer needed. +Once close is called, the instance can no longer be used. +_inherited_ + + + +##### [dataChanged](../wyatt_authentication_bloc/BaseSignUpCubit/dataChanged.md)<Value>([String](https://api.flutter.dev/flutter/dart-core/String-class.html) key, FormInputValidator<Value, ValidationError> dirtyValue) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + +##### [emailChanged](../wyatt_authentication_bloc/SignUpWithEmailPassword/emailChanged.md)([String](https://api.flutter.dev/flutter/dart-core/String-class.html) value) void + + + + + + + + +##### [emailCustomChanged](../wyatt_authentication_bloc/SignUpWithEmailPassword/emailCustomChanged.md)<Validator extends FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError>>(Validator validator) void + + + +Same as emailChanged but with a custom Validator. + + + + +##### [emit](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/emit.html)([SignUpState](../wyatt_authentication_bloc/SignUpState-class.md) state) void + + + +Updates the state to the provided state. +emit does nothing if the state being emitted +is equal to the current state. +_inherited_ + + + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [onChange](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onChange.html)([Change](https://pub.dev/documentation/bloc/8.1.0/bloc/Change-class.html)<[SignUpState](../wyatt_authentication_bloc/SignUpState-class.md)> change) void + + + +Called whenever a change occurs with the given change. +A change occurs when a new state is emitted. +onChange is called before the state of the cubit is updated. +onChange is a great spot to add logging/analytics for a specific cubit. +_inherited_ + + + +##### [onError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html) stackTrace) void + + + +Called whenever an error occurs and notifies BlocObserver.onError. +_inherited_ + + + +##### [onSignUpWithEmailAndPassword](../wyatt_authentication_bloc/SignUpWithEmailPassword/onSignUpWithEmailAndPassword.md)(Result<[Account](../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) FutureOrResult<Data?> + + + +This callback is triggered when a user creates an account. + + + + +##### [passwordChanged](../wyatt_authentication_bloc/SignUpWithEmailPassword/passwordChanged.md)([String](https://api.flutter.dev/flutter/dart-core/String-class.html) value) void + + + + + + + + +##### [passwordCustomChanged](../wyatt_authentication_bloc/SignUpWithEmailPassword/passwordCustomChanged.md)<Validator extends FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError>>(Validator validator) void + + + +Same as passwordChanged but with a custom Validator. + + + + +##### [reset](../wyatt_authentication_bloc/BaseSignUpCubit/reset.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + +##### [signUpWithEmailPassword](../wyatt_authentication_bloc/SignUpWithEmailPassword/signUpWithEmailPassword.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + +Creates a new user with the provided email and password. + + + + +##### [submit](../wyatt_authentication_bloc/BaseSignUpCubit/submit.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + +##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + +##### [update](../wyatt_authentication_bloc/BaseSignUpCubit/update.md)(WyattForm form, {SetOperation operation = SetOperation.replace}) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + +##### [validate](../wyatt_authentication_bloc/BaseSignUpCubit/validate.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword/emailChanged.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword/emailChanged.md new file mode 100644 index 00000000..85e7cc16 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword/emailChanged.md @@ -0,0 +1,47 @@ + + + +# emailChanged method + + + + + *[](https://dart.dev/null-safety)* + + + + +void emailChanged +([String](https://api.flutter.dev/flutter/dart-core/String-class.html) value) + + + + + + + + +## Implementation + +```dart +void emailChanged(String value) { + final emailValidatorType = formRepository + .accessForm(formName) + .validatorOf(AuthFormField.email) + .runtimeType; + assert( + emailValidatorType == Email, + 'Use emailCustomChanged(...) with validator $emailValidatorType', + ); + + final Email email = Email.dirty(value); + dataChanged(AuthFormField.email, email); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword/emailCustomChanged.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword/emailCustomChanged.md new file mode 100644 index 00000000..8915ba03 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword/emailCustomChanged.md @@ -0,0 +1,42 @@ + + + +# emailCustomChanged<Validator extends FormInputValidator<String?, ValidationError>> method + + + + + *[](https://dart.dev/null-safety)* + + + + +void emailCustomChanged +<Validator extends FormInputValidator<String?, ValidationError>>(Validator validator) + + + + + +

Same as emailChanged but with a custom Validator.

+

Sort of short hand for dataChanged.

+ + + +## Implementation + +```dart +void emailCustomChanged< + Validator extends FormInputValidator>( + Validator validator, +) { + dataChanged(AuthFormField.email, validator); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword/onSignUpWithEmailAndPassword.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword/onSignUpWithEmailAndPassword.md new file mode 100644 index 00000000..cd7c1a80 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword/onSignUpWithEmailAndPassword.md @@ -0,0 +1,40 @@ + + + +# onSignUpWithEmailAndPassword method + + + + + *[](https://dart.dev/null-safety)* + + + + +FutureOrResult<Data?> onSignUpWithEmailAndPassword +(Result<[Account](../../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) + + + + + +

This callback is triggered when a user creates an account.

+

For example: when a user sign up in firebase.

+ + + +## Implementation + +```dart +FutureOrResult onSignUpWithEmailAndPassword( + Result result, + WyattForm form, +); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword/passwordChanged.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword/passwordChanged.md new file mode 100644 index 00000000..8db9fda0 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword/passwordChanged.md @@ -0,0 +1,46 @@ + + + +# passwordChanged method + + + + + *[](https://dart.dev/null-safety)* + + + + +void passwordChanged +([String](https://api.flutter.dev/flutter/dart-core/String-class.html) value) + + + + + + + + +## Implementation + +```dart +void passwordChanged(String value) { + final passwordValidatorType = formRepository + .accessForm(formName) + .validatorOf(AuthFormField.password) + .runtimeType; + assert( + passwordValidatorType == Password, + 'Use passwordCustomChanged(...) with validator $passwordValidatorType', + ); + final Password password = Password.dirty(value); + dataChanged(AuthFormField.password, password); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword/passwordCustomChanged.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword/passwordCustomChanged.md new file mode 100644 index 00000000..5e3b39bd --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword/passwordCustomChanged.md @@ -0,0 +1,42 @@ + + + +# passwordCustomChanged<Validator extends FormInputValidator<String?, ValidationError>> method + + + + + *[](https://dart.dev/null-safety)* + + + + +void passwordCustomChanged +<Validator extends FormInputValidator<String?, ValidationError>>(Validator validator) + + + + + +

Same as passwordChanged but with a custom Validator.

+

Sort of short hand for dataChanged.

+ + + +## Implementation + +```dart +void passwordCustomChanged< + Validator extends FormInputValidator>( + Validator validator, +) { + dataChanged(AuthFormField.password, validator); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword/signUpWithEmailPassword.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword/signUpWithEmailPassword.md new file mode 100644 index 00000000..0fd593ac --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword/signUpWithEmailPassword.md @@ -0,0 +1,97 @@ + + + +# signUpWithEmailPassword method + + + + + *[](https://dart.dev/null-safety)* + + + + +[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> signUpWithEmailPassword +() + + + + + +

Creates a new user with the provided email and password.

+

Returns the newly created user's unique identifier.

+

Throws a SignUpWithEmailAndPasswordFailureInterface if +an exception occurs.

+ + + +## Implementation + +```dart +FutureOr signUpWithEmailPassword() async { + if (!state.status.isValidated) { + return; + } + + final form = formRepository.accessForm(formName); + emit(SignUpState(form: form, status: FormStatus.submissionInProgress)); + + final email = form.valueOf(AuthFormField.email); + final password = form.valueOf(AuthFormField.password); + + if (email.isNullOrEmpty || password.isNullOrEmpty) { + emit( + SignUpState( + form: form, + errorMessage: 'An error occured while retrieving data from the form.', + status: FormStatus.submissionFailure, + ), + ); + } + + return CustomRoutine( + routine: () => authenticationRepository.signUpWithEmailAndPassword( + email: email!, + password: password!, + ), + attachedLogic: (routineResult) => onSignUpWithEmailAndPassword( + routineResult, + form, + ), + onError: (error) { + emit( + SignUpState( + form: form, + errorMessage: error.message, + status: FormStatus.submissionFailure, + ), + ); + addError(error); + }, + onSuccess: (account, data) { + authenticationRepository.addSession( + SessionWrapper( + event: SignedUpEvent(account: account), + session: Session( + account: account, + data: data, + ), + ), + ); + emit( + SignUpState( + form: form, + status: FormStatus.submissionSuccess, + ), + ); + }, + ).call(); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInEvent-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInEvent-class.md new file mode 100644 index 00000000..c3b76749 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInEvent-class.md @@ -0,0 +1,135 @@ + + + +# SignedInEvent class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

When a user authenticates (from not logged in to logged in).

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [Equatable](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable-class.html) +- [AuthenticationChangeEvent](../wyatt_authentication_bloc/AuthenticationChangeEvent-class.md) +- SignedInEvent + + + + + + + + +## Constructors + +[SignedInEvent](../wyatt_authentication_bloc/SignedInEvent/SignedInEvent.md) ({required [Account](../wyatt_authentication_bloc/Account-class.md) account}) + + _const_ + + +## Properties + +##### [account](../wyatt_authentication_bloc/SignedInEvent/account.md) → [Account](../wyatt_authentication_bloc/Account-class.md) + + + + +_final_ + + + +##### [hashCode](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [props](../wyatt_authentication_bloc/SignedInEvent/props.md) → [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> + + + +The list of properties that will be used to determine whether +two instances are equal. +_read-onlyoverride_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + +##### [stringify](../wyatt_authentication_bloc/AuthenticationChangeEvent/stringify.md) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +If set to true, the toString method will be overridden to output +this instance's props. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInEvent/SignedInEvent.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInEvent/SignedInEvent.md new file mode 100644 index 00000000..cdc4ad73 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInEvent/SignedInEvent.md @@ -0,0 +1,30 @@ + + + +# SignedInEvent constructor + + + + + *[](https://dart.dev/null-safety)* + + +const +SignedInEvent({required [Account](../../wyatt_authentication_bloc/Account-class.md) account}) + + + + + +## Implementation + +```dart +const SignedInEvent({required this.account}); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInEvent/account.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInEvent/account.md new file mode 100644 index 00000000..671e197e --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInEvent/account.md @@ -0,0 +1,33 @@ + + + +# account property + + + + + *[](https://dart.dev/null-safety)* + + + +[Account](../../wyatt_authentication_bloc/Account-class.md) account + +_final_ + + + + + + +## Implementation + +```dart +final Account account; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInEvent/props.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInEvent/props.md new file mode 100644 index 00000000..fbde09d1 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInEvent/props.md @@ -0,0 +1,42 @@ + + + +# props property + + + + + *[](https://dart.dev/null-safety)* + + + + + +**Annotations** + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) +[List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> props + +_override_ + + + +

The list of properties that will be used to determine whether +two instances are equal.

+ + + +## Implementation + +```dart +@override +List get props => [account]; +``` + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInFromCacheEvent-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInFromCacheEvent-class.md new file mode 100644 index 00000000..fd2ab1bb --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInFromCacheEvent-class.md @@ -0,0 +1,135 @@ + + + +# SignedInFromCacheEvent class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

When a user authenticates automatically (from not logged in to logged in).

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [Equatable](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable-class.html) +- [AuthenticationChangeEvent](../wyatt_authentication_bloc/AuthenticationChangeEvent-class.md) +- SignedInFromCacheEvent + + + + + + + + +## Constructors + +[SignedInFromCacheEvent](../wyatt_authentication_bloc/SignedInFromCacheEvent/SignedInFromCacheEvent.md) ({required [Account](../wyatt_authentication_bloc/Account-class.md) account}) + + _const_ + + +## Properties + +##### [account](../wyatt_authentication_bloc/SignedInFromCacheEvent/account.md) → [Account](../wyatt_authentication_bloc/Account-class.md) + + + + +_final_ + + + +##### [hashCode](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [props](../wyatt_authentication_bloc/SignedInFromCacheEvent/props.md) → [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> + + + +The list of properties that will be used to determine whether +two instances are equal. +_read-onlyoverride_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + +##### [stringify](../wyatt_authentication_bloc/AuthenticationChangeEvent/stringify.md) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +If set to true, the toString method will be overridden to output +this instance's props. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInFromCacheEvent/SignedInFromCacheEvent.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInFromCacheEvent/SignedInFromCacheEvent.md new file mode 100644 index 00000000..99d1d86f --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInFromCacheEvent/SignedInFromCacheEvent.md @@ -0,0 +1,30 @@ + + + +# SignedInFromCacheEvent constructor + + + + + *[](https://dart.dev/null-safety)* + + +const +SignedInFromCacheEvent({required [Account](../../wyatt_authentication_bloc/Account-class.md) account}) + + + + + +## Implementation + +```dart +const SignedInFromCacheEvent({required this.account}); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInFromCacheEvent/account.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInFromCacheEvent/account.md new file mode 100644 index 00000000..671e197e --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInFromCacheEvent/account.md @@ -0,0 +1,33 @@ + + + +# account property + + + + + *[](https://dart.dev/null-safety)* + + + +[Account](../../wyatt_authentication_bloc/Account-class.md) account + +_final_ + + + + + + +## Implementation + +```dart +final Account account; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInFromCacheEvent/props.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInFromCacheEvent/props.md new file mode 100644 index 00000000..fbde09d1 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInFromCacheEvent/props.md @@ -0,0 +1,42 @@ + + + +# props property + + + + + *[](https://dart.dev/null-safety)* + + + + + +**Annotations** + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) +[List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> props + +_override_ + + + +

The list of properties that will be used to determine whether +two instances are equal.

+ + + +## Implementation + +```dart +@override +List get props => [account]; +``` + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedOutEvent-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedOutEvent-class.md new file mode 100644 index 00000000..0075e9eb --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedOutEvent-class.md @@ -0,0 +1,126 @@ + + + +# SignedOutEvent class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

When a user logs out.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [Equatable](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable-class.html) +- [AuthenticationChangeEvent](../wyatt_authentication_bloc/AuthenticationChangeEvent-class.md) +- SignedOutEvent + + + + + + + + +## Constructors + +[SignedOutEvent](../wyatt_authentication_bloc/SignedOutEvent/SignedOutEvent.md) () + + _const_ + + +## Properties + +##### [hashCode](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [props](../wyatt_authentication_bloc/AuthenticationChangeEvent/props.md) → [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> + + + +The list of properties that will be used to determine whether +two instances are equal. +_read-onlyinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + +##### [stringify](../wyatt_authentication_bloc/AuthenticationChangeEvent/stringify.md) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +If set to true, the toString method will be overridden to output +this instance's props. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedOutEvent/SignedOutEvent.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedOutEvent/SignedOutEvent.md new file mode 100644 index 00000000..734b4c5d --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedOutEvent/SignedOutEvent.md @@ -0,0 +1,30 @@ + + + +# SignedOutEvent constructor + + + + + *[](https://dart.dev/null-safety)* + + +const +SignedOutEvent() + + + + + +## Implementation + +```dart +const SignedOutEvent(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedUpEvent-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedUpEvent-class.md new file mode 100644 index 00000000..c53aeb32 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedUpEvent-class.md @@ -0,0 +1,135 @@ + + + +# SignedUpEvent class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

When a user creates an account.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [Equatable](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable-class.html) +- [AuthenticationChangeEvent](../wyatt_authentication_bloc/AuthenticationChangeEvent-class.md) +- SignedUpEvent + + + + + + + + +## Constructors + +[SignedUpEvent](../wyatt_authentication_bloc/SignedUpEvent/SignedUpEvent.md) ({required [Account](../wyatt_authentication_bloc/Account-class.md) account}) + + _const_ + + +## Properties + +##### [account](../wyatt_authentication_bloc/SignedUpEvent/account.md) → [Account](../wyatt_authentication_bloc/Account-class.md) + + + + +_final_ + + + +##### [hashCode](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [props](../wyatt_authentication_bloc/SignedUpEvent/props.md) → [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> + + + +The list of properties that will be used to determine whether +two instances are equal. +_read-onlyoverride_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + +##### [stringify](../wyatt_authentication_bloc/AuthenticationChangeEvent/stringify.md) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +If set to true, the toString method will be overridden to output +this instance's props. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedUpEvent/SignedUpEvent.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedUpEvent/SignedUpEvent.md new file mode 100644 index 00000000..4a68b5f5 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedUpEvent/SignedUpEvent.md @@ -0,0 +1,30 @@ + + + +# SignedUpEvent constructor + + + + + *[](https://dart.dev/null-safety)* + + +const +SignedUpEvent({required [Account](../../wyatt_authentication_bloc/Account-class.md) account}) + + + + + +## Implementation + +```dart +const SignedUpEvent({required this.account}); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedUpEvent/account.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedUpEvent/account.md new file mode 100644 index 00000000..671e197e --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedUpEvent/account.md @@ -0,0 +1,33 @@ + + + +# account property + + + + + *[](https://dart.dev/null-safety)* + + + +[Account](../../wyatt_authentication_bloc/Account-class.md) account + +_final_ + + + + + + +## Implementation + +```dart +final Account account; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedUpEvent/props.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedUpEvent/props.md new file mode 100644 index 00000000..fbde09d1 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedUpEvent/props.md @@ -0,0 +1,42 @@ + + + +# props property + + + + + *[](https://dart.dev/null-safety)* + + + + + +**Annotations** + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) +[List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> props + +_override_ + + + +

The list of properties that will be used to determine whether +two instances are equal.

+ + + +## Implementation + +```dart +@override +List get props => [account]; +``` + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UnknownAuthenticationEvent-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UnknownAuthenticationEvent-class.md new file mode 100644 index 00000000..1b5a7161 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UnknownAuthenticationEvent-class.md @@ -0,0 +1,126 @@ + + + +# UnknownAuthenticationEvent class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

When a user's login status is unknown.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [Equatable](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable-class.html) +- [AuthenticationChangeEvent](../wyatt_authentication_bloc/AuthenticationChangeEvent-class.md) +- UnknownAuthenticationEvent + + + + + + + + +## Constructors + +[UnknownAuthenticationEvent](../wyatt_authentication_bloc/UnknownAuthenticationEvent/UnknownAuthenticationEvent.md) () + + _const_ + + +## Properties + +##### [hashCode](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [props](../wyatt_authentication_bloc/AuthenticationChangeEvent/props.md) → [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> + + + +The list of properties that will be used to determine whether +two instances are equal. +_read-onlyinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + +##### [stringify](../wyatt_authentication_bloc/AuthenticationChangeEvent/stringify.md) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +If set to true, the toString method will be overridden to output +this instance's props. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UnknownAuthenticationEvent/UnknownAuthenticationEvent.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UnknownAuthenticationEvent/UnknownAuthenticationEvent.md new file mode 100644 index 00000000..6e9d242a --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UnknownAuthenticationEvent/UnknownAuthenticationEvent.md @@ -0,0 +1,30 @@ + + + +# UnknownAuthenticationEvent constructor + + + + + *[](https://dart.dev/null-safety)* + + +const +UnknownAuthenticationEvent() + + + + + +## Implementation + +```dart +const UnknownAuthenticationEvent(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmail-mixin.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmail-mixin.md new file mode 100644 index 00000000..0673d44e --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmail-mixin.md @@ -0,0 +1,287 @@ + + + +# UpdateEmail<Data> mixin + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Edit account mixin.

+

Allows the user to edit his email

+

Gives access to the updateEmail method and +onEmailUpdated callback.

+ + +**Superclass Constraints** + +- [BaseEditAccountCubit](../wyatt_authentication_bloc/BaseEditAccountCubit-class.md)<Data> + + + + +**Mixin Applications** + +- [EditAccountCubit](../wyatt_authentication_bloc/EditAccountCubit-class.md) + + + +## Properties + +##### [authenticationRepository](../wyatt_authentication_bloc/BaseEditAccountCubit/authenticationRepository.md) → [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> + + + + +_finalinherited_ + + + +##### [formName](../wyatt_authentication_bloc/BaseEditAccountCubit/formName.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [formRepository](../wyatt_authentication_bloc/BaseEditAccountCubit/formRepository.md) → FormRepository + + + + +_read-onlyinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [isClosed](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/isClosed.html) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +Whether the bloc is closed. +_read-onlyinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + +##### [state](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/state.html) → [EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md) + + + +The current state. +_read-onlyinherited_ + + + +##### [stream](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/stream.html) → [Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md)> + + + +The current stream of states. +_read-onlyinherited_ + + + + + +## Methods + +##### [addError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/addError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [[StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html)? stackTrace]) void + + + +Reports an error which triggers onError with an optional StackTrace. +_inherited_ + + + +##### [close](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/close.html)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> + + + +Closes the instance. +This method should be called when the instance is no longer needed. +Once close is called, the instance can no longer be used. +_inherited_ + + + +##### [dataChanged](../wyatt_authentication_bloc/BaseEditAccountCubit/dataChanged.md)<Value>([String](https://api.flutter.dev/flutter/dart-core/String-class.html) key, FormInputValidator<Value, ValidationError> dirtyValue) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + +##### [emailChanged](../wyatt_authentication_bloc/UpdateEmail/emailChanged.md)([String](https://api.flutter.dev/flutter/dart-core/String-class.html) value) void + + + + + + + + +##### [emailCustomChanged](../wyatt_authentication_bloc/UpdateEmail/emailCustomChanged.md)<Validator extends FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError>>(Validator validator) void + + + +Same as emailChanged but with a custom Validator. + + + + +##### [emit](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/emit.html)([EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md) state) void + + + +Updates the state to the provided state. +emit does nothing if the state being emitted +is equal to the current state. +_inherited_ + + + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [onChange](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onChange.html)([Change](https://pub.dev/documentation/bloc/8.1.0/bloc/Change-class.html)<[EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md)> change) void + + + +Called whenever a change occurs with the given change. +A change occurs when a new state is emitted. +onChange is called before the state of the cubit is updated. +onChange is a great spot to add logging/analytics for a specific cubit. +_inherited_ + + + +##### [onEmailUpdated](../wyatt_authentication_bloc/UpdateEmail/onEmailUpdated.md)(Result<[Account](../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) FutureOrResult<Data?> + + + +This callback is triggered when user updates his email + + + + +##### [onError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html) stackTrace) void + + + +Called whenever an error occurs and notifies BlocObserver.onError. +_inherited_ + + + +##### [reset](../wyatt_authentication_bloc/BaseEditAccountCubit/reset.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + +##### [submit](../wyatt_authentication_bloc/BaseEditAccountCubit/submit.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + +##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + +##### [update](../wyatt_authentication_bloc/BaseEditAccountCubit/update.md)(WyattForm form, {SetOperation operation = SetOperation.replace}) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + +##### [updateEmail](../wyatt_authentication_bloc/UpdateEmail/updateEmail.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + +Update or add email. + + + + +##### [validate](../wyatt_authentication_bloc/BaseEditAccountCubit/validate.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmail/emailChanged.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmail/emailChanged.md new file mode 100644 index 00000000..85e7cc16 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmail/emailChanged.md @@ -0,0 +1,47 @@ + + + +# emailChanged method + + + + + *[](https://dart.dev/null-safety)* + + + + +void emailChanged +([String](https://api.flutter.dev/flutter/dart-core/String-class.html) value) + + + + + + + + +## Implementation + +```dart +void emailChanged(String value) { + final emailValidatorType = formRepository + .accessForm(formName) + .validatorOf(AuthFormField.email) + .runtimeType; + assert( + emailValidatorType == Email, + 'Use emailCustomChanged(...) with validator $emailValidatorType', + ); + + final Email email = Email.dirty(value); + dataChanged(AuthFormField.email, email); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmail/emailCustomChanged.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmail/emailCustomChanged.md new file mode 100644 index 00000000..7ec149cb --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmail/emailCustomChanged.md @@ -0,0 +1,42 @@ + + + +# emailCustomChanged<Validator extends FormInputValidator<String?, ValidationError>> method + + + + + *[](https://dart.dev/null-safety)* + + + + +void emailCustomChanged +<Validator extends FormInputValidator<String?, ValidationError>>(Validator validator) + + + + + +

Same as emailChanged but with a custom Validator.

+

Sort of short hand for dataChanged.

+ + + +## Implementation + +```dart +void emailCustomChanged< + Validator extends FormInputValidator>( + Validator validator, +) { + dataChanged(AuthFormField.email, validator); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmail/onEmailUpdated.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmail/onEmailUpdated.md new file mode 100644 index 00000000..7e3757f2 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmail/onEmailUpdated.md @@ -0,0 +1,39 @@ + + + +# onEmailUpdated method + + + + + *[](https://dart.dev/null-safety)* + + + + +FutureOrResult<Data?> onEmailUpdated +(Result<[Account](../../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) + + + + + +

This callback is triggered when user updates his email

+ + + +## Implementation + +```dart +FutureOrResult onEmailUpdated( + Result result, + WyattForm form, +); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmail/updateEmail.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmail/updateEmail.md new file mode 100644 index 00000000..7c814f89 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmail/updateEmail.md @@ -0,0 +1,103 @@ + + + +# updateEmail method + + + + + *[](https://dart.dev/null-safety)* + + + + +[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> updateEmail +() + + + + + +

Update or add email.

+

Throws a UpdateEmailFailureInterface if +an exception occurs.

+ + + +## Implementation + +```dart +FutureOr updateEmail() async { + if (state.status.isSubmissionInProgress) { + return; + } + + if (!state.status.isValidated) { + return; + } + + final form = formRepository.accessForm(formName); + emit( + EditAccountState( + form: form, + status: FormStatus.submissionInProgress, + ), + ); + + final email = form.valueOf(AuthFormField.email); + + if (email.isNullOrEmpty) { + emit( + EditAccountState( + form: form, + errorMessage: 'An error occured while retrieving data from the form.', + status: FormStatus.submissionFailure, + ), + ); + } + + return CustomRoutine( + routine: () => authenticationRepository.updateEmail( + email: email!, + ), + attachedLogic: (routineResult) => onEmailUpdated( + routineResult, + form, + ), + onError: (error) { + emit( + EditAccountState( + form: form, + errorMessage: error.message, + status: FormStatus.submissionFailure, + ), + ); + addError(error); + }, + onSuccess: (account, data) { + authenticationRepository.addSession( + SessionWrapper( + event: UpdatedEvent(account: account), + session: Session( + account: account, + data: data, + ), + ), + ); + emit( + EditAccountState( + form: form, + status: FormStatus.submissionSuccess, + ), + ); + }, + ).call(); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmailFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmailFailureFirebase-class.md new file mode 100644 index 00000000..aa440929 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmailFailureFirebase-class.md @@ -0,0 +1,137 @@ + + + +# UpdateEmailFailureFirebase class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown during the email modification process if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- [UpdateEmailFailureInterface](../wyatt_authentication_bloc/UpdateEmailFailureInterface-class.md) +- UpdateEmailFailureFirebase + + + + + + + + +## Constructors + +[UpdateEmailFailureFirebase](../wyatt_authentication_bloc/UpdateEmailFailureFirebase/UpdateEmailFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + +[UpdateEmailFailureFirebase.fromCode](../wyatt_authentication_bloc/UpdateEmailFailureFirebase/UpdateEmailFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmailFailureFirebase/UpdateEmailFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmailFailureFirebase/UpdateEmailFailureFirebase.fromCode.md new file mode 100644 index 00000000..d9c01e20 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmailFailureFirebase/UpdateEmailFailureFirebase.fromCode.md @@ -0,0 +1,45 @@ + + + +# UpdateEmailFailureFirebase.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +UpdateEmailFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + + +## Implementation + +```dart +UpdateEmailFailureFirebase.fromCode(String code) : super.fromCode(code) { + switch (code) { + case 'invalid-email': + msg = 'Email is not valid or badly formatted.'; + break; + case 'email-already-in-use': + msg = 'An account already exists for that email.'; + break; + case 'requires-recent-login': + msg = "User's last sign-in time does not meet the security threshold."; + break; + default: + this.code = 'unknown'; + msg = 'An unknown error occurred.'; + } +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmailFailureFirebase/UpdateEmailFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmailFailureFirebase/UpdateEmailFailureFirebase.md new file mode 100644 index 00000000..7c7e5fe5 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmailFailureFirebase/UpdateEmailFailureFirebase.md @@ -0,0 +1,31 @@ + + + +# UpdateEmailFailureFirebase constructor + + + + + *[](https://dart.dev/null-safety)* + + + +UpdateEmailFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + + + +## Implementation + +```dart +UpdateEmailFailureFirebase([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmailFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmailFailureInterface-class.md new file mode 100644 index 00000000..29d54938 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmailFailureInterface-class.md @@ -0,0 +1,139 @@ + + + +# UpdateEmailFailureInterface class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown during the email modification process if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- UpdateEmailFailureInterface + + + +**Implementers** + +- [UpdateEmailFailureFirebase](../wyatt_authentication_bloc/UpdateEmailFailureFirebase-class.md) + + + + + +## Constructors + +[UpdateEmailFailureInterface](../wyatt_authentication_bloc/UpdateEmailFailureInterface/UpdateEmailFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + + + +[UpdateEmailFailureInterface.fromCode](../wyatt_authentication_bloc/UpdateEmailFailureInterface/UpdateEmailFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmailFailureInterface/UpdateEmailFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmailFailureInterface/UpdateEmailFailureInterface.fromCode.md new file mode 100644 index 00000000..656a17b9 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmailFailureInterface/UpdateEmailFailureInterface.fromCode.md @@ -0,0 +1,30 @@ + + + +# UpdateEmailFailureInterface.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +UpdateEmailFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + + +## Implementation + +```dart +UpdateEmailFailureInterface.fromCode(super.code) : super.fromCode(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmailFailureInterface/UpdateEmailFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmailFailureInterface/UpdateEmailFailureInterface.md new file mode 100644 index 00000000..ffa1fd03 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmailFailureInterface/UpdateEmailFailureInterface.md @@ -0,0 +1,30 @@ + + + +# UpdateEmailFailureInterface constructor + + + + + *[](https://dart.dev/null-safety)* + + + +UpdateEmailFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + + + + + +## Implementation + +```dart +UpdateEmailFailureInterface(super.code, super.msg); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePassword-mixin.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePassword-mixin.md new file mode 100644 index 00000000..cea1271f --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePassword-mixin.md @@ -0,0 +1,287 @@ + + + +# UpdatePassword<Data> mixin + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Edit account mixin.

+

Allows the user to edit his password

+

Gives access to the updatePassword method and +onPasswordUpdated callback.

+ + +**Superclass Constraints** + +- [BaseEditAccountCubit](../wyatt_authentication_bloc/BaseEditAccountCubit-class.md)<Data> + + + + +**Mixin Applications** + +- [EditAccountCubit](../wyatt_authentication_bloc/EditAccountCubit-class.md) + + + +## Properties + +##### [authenticationRepository](../wyatt_authentication_bloc/BaseEditAccountCubit/authenticationRepository.md) → [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> + + + + +_finalinherited_ + + + +##### [formName](../wyatt_authentication_bloc/BaseEditAccountCubit/formName.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [formRepository](../wyatt_authentication_bloc/BaseEditAccountCubit/formRepository.md) → FormRepository + + + + +_read-onlyinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [isClosed](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/isClosed.html) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +Whether the bloc is closed. +_read-onlyinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + +##### [state](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/state.html) → [EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md) + + + +The current state. +_read-onlyinherited_ + + + +##### [stream](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/stream.html) → [Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md)> + + + +The current stream of states. +_read-onlyinherited_ + + + + + +## Methods + +##### [addError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/addError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [[StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html)? stackTrace]) void + + + +Reports an error which triggers onError with an optional StackTrace. +_inherited_ + + + +##### [close](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/close.html)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> + + + +Closes the instance. +This method should be called when the instance is no longer needed. +Once close is called, the instance can no longer be used. +_inherited_ + + + +##### [dataChanged](../wyatt_authentication_bloc/BaseEditAccountCubit/dataChanged.md)<Value>([String](https://api.flutter.dev/flutter/dart-core/String-class.html) key, FormInputValidator<Value, ValidationError> dirtyValue) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + +##### [emit](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/emit.html)([EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md) state) void + + + +Updates the state to the provided state. +emit does nothing if the state being emitted +is equal to the current state. +_inherited_ + + + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [onChange](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onChange.html)([Change](https://pub.dev/documentation/bloc/8.1.0/bloc/Change-class.html)<[EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md)> change) void + + + +Called whenever a change occurs with the given change. +A change occurs when a new state is emitted. +onChange is called before the state of the cubit is updated. +onChange is a great spot to add logging/analytics for a specific cubit. +_inherited_ + + + +##### [onError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html) stackTrace) void + + + +Called whenever an error occurs and notifies BlocObserver.onError. +_inherited_ + + + +##### [onPasswordUpdated](../wyatt_authentication_bloc/UpdatePassword/onPasswordUpdated.md)(Result<[Account](../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) FutureOrResult<Data?> + + + +This callback is triggered when a user edits his password. + + + + +##### [passwordChanged](../wyatt_authentication_bloc/UpdatePassword/passwordChanged.md)([String](https://api.flutter.dev/flutter/dart-core/String-class.html) value) void + + + + + + + + +##### [passwordCustomChanged](../wyatt_authentication_bloc/UpdatePassword/passwordCustomChanged.md)<Validator extends FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError>>(Validator validator) void + + + +Same as passwordChanged but with a custom Validator. + + + + +##### [reset](../wyatt_authentication_bloc/BaseEditAccountCubit/reset.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + +##### [submit](../wyatt_authentication_bloc/BaseEditAccountCubit/submit.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + +##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + +##### [update](../wyatt_authentication_bloc/BaseEditAccountCubit/update.md)(WyattForm form, {SetOperation operation = SetOperation.replace}) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + +##### [updatePassword](../wyatt_authentication_bloc/UpdatePassword/updatePassword.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + +Update or add password. + + + + +##### [validate](../wyatt_authentication_bloc/BaseEditAccountCubit/validate.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> + + + + +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePassword/onPasswordUpdated.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePassword/onPasswordUpdated.md new file mode 100644 index 00000000..b0354384 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePassword/onPasswordUpdated.md @@ -0,0 +1,39 @@ + + + +# onPasswordUpdated method + + + + + *[](https://dart.dev/null-safety)* + + + + +FutureOrResult<Data?> onPasswordUpdated +(Result<[Account](../../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) + + + + + +

This callback is triggered when a user edits his password.

+ + + +## Implementation + +```dart +FutureOrResult onPasswordUpdated( + Result result, + WyattForm form, +); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePassword/passwordChanged.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePassword/passwordChanged.md new file mode 100644 index 00000000..8db9fda0 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePassword/passwordChanged.md @@ -0,0 +1,46 @@ + + + +# passwordChanged method + + + + + *[](https://dart.dev/null-safety)* + + + + +void passwordChanged +([String](https://api.flutter.dev/flutter/dart-core/String-class.html) value) + + + + + + + + +## Implementation + +```dart +void passwordChanged(String value) { + final passwordValidatorType = formRepository + .accessForm(formName) + .validatorOf(AuthFormField.password) + .runtimeType; + assert( + passwordValidatorType == Password, + 'Use passwordCustomChanged(...) with validator $passwordValidatorType', + ); + final Password password = Password.dirty(value); + dataChanged(AuthFormField.password, password); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePassword/passwordCustomChanged.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePassword/passwordCustomChanged.md new file mode 100644 index 00000000..2cb08454 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePassword/passwordCustomChanged.md @@ -0,0 +1,42 @@ + + + +# passwordCustomChanged<Validator extends FormInputValidator<String?, ValidationError>> method + + + + + *[](https://dart.dev/null-safety)* + + + + +void passwordCustomChanged +<Validator extends FormInputValidator<String?, ValidationError>>(Validator validator) + + + + + +

Same as passwordChanged but with a custom Validator.

+

Sort of short hand for dataChanged.

+ + + +## Implementation + +```dart +void passwordCustomChanged< + Validator extends FormInputValidator>( + Validator validator, +) { + dataChanged(AuthFormField.password, validator); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePassword/updatePassword.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePassword/updatePassword.md new file mode 100644 index 00000000..fae26194 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePassword/updatePassword.md @@ -0,0 +1,103 @@ + + + +# updatePassword method + + + + + *[](https://dart.dev/null-safety)* + + + + +[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> updatePassword +() + + + + + +

Update or add password.

+

Throws a UpdatePasswordFailureInterface if +an exception occurs.

+ + + +## Implementation + +```dart +FutureOr updatePassword() async { + if (state.status.isSubmissionInProgress) { + return; + } + + if (!state.status.isValidated) { + return; + } + + final form = formRepository.accessForm(formName); + emit( + EditAccountState( + form: form, + status: FormStatus.submissionInProgress, + ), + ); + + final password = form.valueOf(AuthFormField.password); + + if (password.isNullOrEmpty) { + emit( + EditAccountState( + form: form, + errorMessage: 'An error occured while retrieving data from the form.', + status: FormStatus.submissionFailure, + ), + ); + } + + return CustomRoutine( + routine: () => authenticationRepository.updatePassword( + password: password!, + ), + attachedLogic: (routineResult) => onPasswordUpdated( + routineResult, + form, + ), + onError: (error) { + emit( + EditAccountState( + form: form, + errorMessage: error.message, + status: FormStatus.submissionFailure, + ), + ); + addError(error); + }, + onSuccess: (account, data) { + authenticationRepository.addSession( + SessionWrapper( + event: SignedInEvent(account: account), + session: Session( + account: account, + data: data, + ), + ), + ); + emit( + EditAccountState( + form: form, + status: FormStatus.submissionSuccess, + ), + ); + }, + ).call(); +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePasswordFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePasswordFailureFirebase-class.md new file mode 100644 index 00000000..75e3bd3b --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePasswordFailureFirebase-class.md @@ -0,0 +1,137 @@ + + + +# UpdatePasswordFailureFirebase class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown during the password modification process if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- [UpdatePasswordFailureInterface](../wyatt_authentication_bloc/UpdatePasswordFailureInterface-class.md) +- UpdatePasswordFailureFirebase + + + + + + + + +## Constructors + +[UpdatePasswordFailureFirebase](../wyatt_authentication_bloc/UpdatePasswordFailureFirebase/UpdatePasswordFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + +[UpdatePasswordFailureFirebase.fromCode](../wyatt_authentication_bloc/UpdatePasswordFailureFirebase/UpdatePasswordFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePasswordFailureFirebase/UpdatePasswordFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePasswordFailureFirebase/UpdatePasswordFailureFirebase.fromCode.md new file mode 100644 index 00000000..1aa2ae7c --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePasswordFailureFirebase/UpdatePasswordFailureFirebase.fromCode.md @@ -0,0 +1,42 @@ + + + +# UpdatePasswordFailureFirebase.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +UpdatePasswordFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + + +## Implementation + +```dart +UpdatePasswordFailureFirebase.fromCode(String code) : super.fromCode(code) { + switch (code) { + case 'weak-password': + msg = 'Please enter a stronger password.'; + break; + case 'requires-recent-login': + msg = "User's last sign-in time does not meet the security threshold."; + break; + default: + this.code = 'unknown'; + msg = 'An unknown error occurred.'; + } +} +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePasswordFailureFirebase/UpdatePasswordFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePasswordFailureFirebase/UpdatePasswordFailureFirebase.md new file mode 100644 index 00000000..0f38d6b8 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePasswordFailureFirebase/UpdatePasswordFailureFirebase.md @@ -0,0 +1,31 @@ + + + +# UpdatePasswordFailureFirebase constructor + + + + + *[](https://dart.dev/null-safety)* + + + +UpdatePasswordFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + + + +## Implementation + +```dart +UpdatePasswordFailureFirebase([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePasswordFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePasswordFailureInterface-class.md new file mode 100644 index 00000000..d7a95cd8 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePasswordFailureInterface-class.md @@ -0,0 +1,139 @@ + + + +# UpdatePasswordFailureInterface class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown during the password modification process if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- UpdatePasswordFailureInterface + + + +**Implementers** + +- [UpdatePasswordFailureFirebase](../wyatt_authentication_bloc/UpdatePasswordFailureFirebase-class.md) + + + + + +## Constructors + +[UpdatePasswordFailureInterface](../wyatt_authentication_bloc/UpdatePasswordFailureInterface/UpdatePasswordFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + + + +[UpdatePasswordFailureInterface.fromCode](../wyatt_authentication_bloc/UpdatePasswordFailureInterface/UpdatePasswordFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePasswordFailureInterface/UpdatePasswordFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePasswordFailureInterface/UpdatePasswordFailureInterface.fromCode.md new file mode 100644 index 00000000..d459010f --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePasswordFailureInterface/UpdatePasswordFailureInterface.fromCode.md @@ -0,0 +1,30 @@ + + + +# UpdatePasswordFailureInterface.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +UpdatePasswordFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + + +## Implementation + +```dart +UpdatePasswordFailureInterface.fromCode(super.code) : super.fromCode(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePasswordFailureInterface/UpdatePasswordFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePasswordFailureInterface/UpdatePasswordFailureInterface.md new file mode 100644 index 00000000..bbba2c50 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePasswordFailureInterface/UpdatePasswordFailureInterface.md @@ -0,0 +1,30 @@ + + + +# UpdatePasswordFailureInterface constructor + + + + + *[](https://dart.dev/null-safety)* + + + +UpdatePasswordFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + + + + + +## Implementation + +```dart +UpdatePasswordFailureInterface(super.code, super.msg); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatedEvent-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatedEvent-class.md new file mode 100644 index 00000000..1097b97b --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatedEvent-class.md @@ -0,0 +1,135 @@ + + + +# UpdatedEvent class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

When the user's account has been updated.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [Equatable](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable-class.html) +- [AuthenticationChangeEvent](../wyatt_authentication_bloc/AuthenticationChangeEvent-class.md) +- UpdatedEvent + + + + + + + + +## Constructors + +[UpdatedEvent](../wyatt_authentication_bloc/UpdatedEvent/UpdatedEvent.md) ({required [Account](../wyatt_authentication_bloc/Account-class.md) account}) + + _const_ + + +## Properties + +##### [account](../wyatt_authentication_bloc/UpdatedEvent/account.md) → [Account](../wyatt_authentication_bloc/Account-class.md) + + + + +_final_ + + + +##### [hashCode](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [props](../wyatt_authentication_bloc/UpdatedEvent/props.md) → [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> + + + +The list of properties that will be used to determine whether +two instances are equal. +_read-onlyoverride_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + +##### [stringify](../wyatt_authentication_bloc/AuthenticationChangeEvent/stringify.md) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +If set to true, the toString method will be overridden to output +this instance's props. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatedEvent/UpdatedEvent.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatedEvent/UpdatedEvent.md new file mode 100644 index 00000000..cb29ebfe --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatedEvent/UpdatedEvent.md @@ -0,0 +1,30 @@ + + + +# UpdatedEvent constructor + + + + + *[](https://dart.dev/null-safety)* + + +const +UpdatedEvent({required [Account](../../wyatt_authentication_bloc/Account-class.md) account}) + + + + + +## Implementation + +```dart +const UpdatedEvent({required this.account}); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatedEvent/account.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatedEvent/account.md new file mode 100644 index 00000000..671e197e --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatedEvent/account.md @@ -0,0 +1,33 @@ + + + +# account property + + + + + *[](https://dart.dev/null-safety)* + + + +[Account](../../wyatt_authentication_bloc/Account-class.md) account + +_final_ + + + + + + +## Implementation + +```dart +final Account account; +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatedEvent/props.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatedEvent/props.md new file mode 100644 index 00000000..fbde09d1 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatedEvent/props.md @@ -0,0 +1,42 @@ + + + +# props property + + + + + *[](https://dart.dev/null-safety)* + + + + + +**Annotations** + +- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) +[List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> props + +_override_ + + + +

The list of properties that will be used to determine whether +two instances are equal.

+ + + +## Implementation + +```dart +@override +List get props => [account]; +``` + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/VerifyPasswordResetCodeFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/VerifyPasswordResetCodeFailureFirebase-class.md new file mode 100644 index 00000000..3a40b1bd --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/VerifyPasswordResetCodeFailureFirebase-class.md @@ -0,0 +1,137 @@ + + + +# VerifyPasswordResetCodeFailureFirebase class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown during the password reset process if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- [VerifyPasswordResetCodeFailureInterface](../wyatt_authentication_bloc/VerifyPasswordResetCodeFailureInterface-class.md) +- VerifyPasswordResetCodeFailureFirebase + + + + + + + + +## Constructors + +[VerifyPasswordResetCodeFailureFirebase](../wyatt_authentication_bloc/VerifyPasswordResetCodeFailureFirebase/VerifyPasswordResetCodeFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + +[VerifyPasswordResetCodeFailureFirebase.fromCode](../wyatt_authentication_bloc/VerifyPasswordResetCodeFailureFirebase/VerifyPasswordResetCodeFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/VerifyPasswordResetCodeFailureFirebase/VerifyPasswordResetCodeFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/VerifyPasswordResetCodeFailureFirebase/VerifyPasswordResetCodeFailureFirebase.fromCode.md new file mode 100644 index 00000000..7b721f98 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/VerifyPasswordResetCodeFailureFirebase/VerifyPasswordResetCodeFailureFirebase.fromCode.md @@ -0,0 +1,31 @@ + + + +# VerifyPasswordResetCodeFailureFirebase.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +VerifyPasswordResetCodeFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + + + + +## Implementation + +```dart +VerifyPasswordResetCodeFailureFirebase.fromCode(super.code) + : super.fromCode(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/VerifyPasswordResetCodeFailureFirebase/VerifyPasswordResetCodeFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/VerifyPasswordResetCodeFailureFirebase/VerifyPasswordResetCodeFailureFirebase.md new file mode 100644 index 00000000..22f49092 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/VerifyPasswordResetCodeFailureFirebase/VerifyPasswordResetCodeFailureFirebase.md @@ -0,0 +1,31 @@ + + + +# VerifyPasswordResetCodeFailureFirebase constructor + + + + + *[](https://dart.dev/null-safety)* + + + +VerifyPasswordResetCodeFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) + + + + + +## Implementation + +```dart +VerifyPasswordResetCodeFailureFirebase([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/VerifyPasswordResetCodeFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/VerifyPasswordResetCodeFailureInterface-class.md new file mode 100644 index 00000000..47e2e9b2 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/VerifyPasswordResetCodeFailureInterface-class.md @@ -0,0 +1,139 @@ + + + +# VerifyPasswordResetCodeFailureInterface class + + + + + + + *[](https://dart.dev/null-safety)* + + + +

Thrown during the password reset process if a failure occurs.

+ + + +**Inheritance** + +- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) +- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) +- VerifyPasswordResetCodeFailureInterface + + + +**Implementers** + +- [VerifyPasswordResetCodeFailureFirebase](../wyatt_authentication_bloc/VerifyPasswordResetCodeFailureFirebase-class.md) + + + + + +## Constructors + +[VerifyPasswordResetCodeFailureInterface](../wyatt_authentication_bloc/VerifyPasswordResetCodeFailureInterface/VerifyPasswordResetCodeFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + +Thrown during the password reset process if a failure occurs. + +[VerifyPasswordResetCodeFailureInterface.fromCode](../wyatt_authentication_bloc/VerifyPasswordResetCodeFailureInterface/VerifyPasswordResetCodeFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + +Thrown during the password reset process if a failure occurs. + + +## Properties + +##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) + + + +The hash code for this object. +_read-onlyinherited_ + + + +##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read-onlyinherited_ + + + +##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + + +_read / writeinherited_ + + + +##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) + + + +A representation of the runtime type of the object. +_read-onlyinherited_ + + + + + +## Methods + +##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic + + + +Invoked when a non-existent method or property is accessed. +_inherited_ + + + +##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) + + + +A string representation of this object. +_inherited_ + + + + + +## Operators + +##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) + + + +The equality operator. +_inherited_ + + + + + + + + + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/VerifyPasswordResetCodeFailureInterface/VerifyPasswordResetCodeFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/VerifyPasswordResetCodeFailureInterface/VerifyPasswordResetCodeFailureInterface.fromCode.md new file mode 100644 index 00000000..ed57be88 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/VerifyPasswordResetCodeFailureInterface/VerifyPasswordResetCodeFailureInterface.fromCode.md @@ -0,0 +1,32 @@ + + + +# VerifyPasswordResetCodeFailureInterface.fromCode constructor + + + + + *[](https://dart.dev/null-safety)* + + + +VerifyPasswordResetCodeFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) + + +

Thrown during the password reset process if a failure occurs.

+ + + +## Implementation + +```dart +VerifyPasswordResetCodeFailureInterface.fromCode(super.code) + : super.fromCode(); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/VerifyPasswordResetCodeFailureInterface/VerifyPasswordResetCodeFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/VerifyPasswordResetCodeFailureInterface/VerifyPasswordResetCodeFailureInterface.md new file mode 100644 index 00000000..e03ad3b7 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/VerifyPasswordResetCodeFailureInterface/VerifyPasswordResetCodeFailureInterface.md @@ -0,0 +1,31 @@ + + + +# VerifyPasswordResetCodeFailureInterface constructor + + + + + *[](https://dart.dev/null-safety)* + + + +VerifyPasswordResetCodeFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) + + +

Thrown during the password reset process if a failure occurs.

+ + + +## Implementation + +```dart +VerifyPasswordResetCodeFailureInterface(super.code, super.msg); +``` + + + + + + + diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/wyatt_authentication_bloc-library.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/wyatt_authentication_bloc-library.md new file mode 100644 index 00000000..46d7f563 --- /dev/null +++ b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/wyatt_authentication_bloc-library.md @@ -0,0 +1,727 @@ + + + + +# wyatt_authentication_bloc library + + + + + + + *[](https://dart.dev/null-safety)* + + + +

An authentication library for BLoC.

+ + +## Classes + +##### [Account](../wyatt_authentication_bloc/Account-class.md) + + + +Represents a user Account in the +various identity provisioning systems. + + +##### [AccountModel](../wyatt_authentication_bloc/AccountModel-class.md) + + + +Account Model to parse Firebase User data + + +##### [AuthenticationBuilder](../wyatt_authentication_bloc/AuthenticationBuilder-class.md)<Data> + + + + + + +##### [AuthenticationChangeEvent](../wyatt_authentication_bloc/AuthenticationChangeEvent-class.md) + + + +Represents an event initiated by a change in +the user's authentication status. + + +##### [AuthenticationCubit](../wyatt_authentication_bloc/AuthenticationCubit-class.md)<Data> + + + +Abstract authentication cubit class needs to be implemented in application. + + +##### [AuthenticationFirebaseDataSourceImpl](../wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl-class.md)<Data> + + + + + + +##### [AuthenticationRemoteDataSource](../wyatt_authentication_bloc/AuthenticationRemoteDataSource-class.md)<Data> + + + +Is responsible for abstracting the provenance of the data. + + +##### [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> + + + + + + +##### [AuthenticationRepositoryImpl](../wyatt_authentication_bloc/AuthenticationRepositoryImpl-class.md)<Data extends [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)> + + + + + + +##### [AuthenticationState](../wyatt_authentication_bloc/AuthenticationState-class.md)<Data> + + + + + + +##### [AuthFormField](../wyatt_authentication_bloc/AuthFormField-class.md) + + + +Default authentication form fields name + + +##### [AuthFormName](../wyatt_authentication_bloc/AuthFormName-class.md) + + + +Default authentication form name + + +##### [BaseEditAccountCubit](../wyatt_authentication_bloc/BaseEditAccountCubit-class.md)<Data> + + + +Abstract edit account cubit useful for implementing a cubit with fine +granularity by adding only the required mixins. + + +##### [BaseSignInCubit](../wyatt_authentication_bloc/BaseSignInCubit-class.md)<Data> + + + +Abstract sign in cubit useful for implementing a cubit with fine +granularity by adding only the required mixins. + + +##### [BaseSignUpCubit](../wyatt_authentication_bloc/BaseSignUpCubit-class.md)<Data> + + + +Abstract sign up cubit useful for implementing a cubit with fine +granularity by adding only the required mixins. + + +##### [CustomRoutine](../wyatt_authentication_bloc/CustomRoutine-class.md)<R, Data> + + + +Calls on each cubit action of this package. + + +##### [DeletedEvent](../wyatt_authentication_bloc/DeletedEvent-class.md) + + + +When a user deleted his account. + + +##### [EditAccountCubit](../wyatt_authentication_bloc/EditAccountCubit-class.md)<Data> + + + +Fully featured edit account cubit. + + +##### [EditAccountListener](../wyatt_authentication_bloc/EditAccountListener-class.md)<Data> + + + +Widget that listens and builds a child based on the state of +the edit account cubit + + +##### [EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md) + + + +Edit account cubit state to manage the form. + + +##### [EmailVerificationBuilder](../wyatt_authentication_bloc/EmailVerificationBuilder-class.md)<Extra> + + + + + + +##### [EmailVerificationCubit](../wyatt_authentication_bloc/EmailVerificationCubit-class.md)<Data> + + + + + + +##### [EmailVerificationState](../wyatt_authentication_bloc/EmailVerificationState-class.md) + + + + + + +##### [PasswordResetCubit](../wyatt_authentication_bloc/PasswordResetCubit-class.md)<Extra> + + + +Cubit that allows user to reset his password + + +##### [PasswordResetState](../wyatt_authentication_bloc/PasswordResetState-class.md) + + + + + + +##### [ReauthenticatedEvent](../wyatt_authentication_bloc/ReauthenticatedEvent-class.md) + + + +When a user re-authenticates (from the logged in state to the +logged in state with a different and fresh access +token and a different login time) + + +##### [RefreshedEvent](../wyatt_authentication_bloc/RefreshedEvent-class.md) + + + +When a user access token is refreshed (from the logged in state to the +logged in state with a different access token) + + +##### [Session](../wyatt_authentication_bloc/Session-class.md)<Data> + + + +The Session object is used to transport and propagate +the connected user Account and personalized Data in the application. + + +##### [SessionWrapper](../wyatt_authentication_bloc/SessionWrapper-class.md)<Data> + + + +Contains the AuthenticationChangeEvent initiating the state +change and the current Session. + + +##### [SignedInEvent](../wyatt_authentication_bloc/SignedInEvent-class.md) + + + +When a user authenticates (from not logged in to logged in). + + +##### [SignedInFromCacheEvent](../wyatt_authentication_bloc/SignedInFromCacheEvent-class.md) + + + +When a user authenticates automatically (from not logged in to logged in). + + +##### [SignedOutEvent](../wyatt_authentication_bloc/SignedOutEvent-class.md) + + + +When a user logs out. + + +##### [SignedUpEvent](../wyatt_authentication_bloc/SignedUpEvent-class.md) + + + +When a user creates an account. + + +##### [SignInCubit](../wyatt_authentication_bloc/SignInCubit-class.md)<Data> + + + +Fully featured sign in cubit. + + +##### [SignInListener](../wyatt_authentication_bloc/SignInListener-class.md)<Data> + + + +Widget that listens and builds a child based on the state of +the sign in cubit + + +##### [SignInState](../wyatt_authentication_bloc/SignInState-class.md) + + + +Sign in cubit state to manage the form. + + +##### [SignUpCubit](../wyatt_authentication_bloc/SignUpCubit-class.md)<Data> + + + +Fully featured sign up cubit. + + +##### [SignUpListener](../wyatt_authentication_bloc/SignUpListener-class.md)<Data> + + + +Widget that listens and builds a child based on the state of +the sign up cubit + + +##### [SignUpState](../wyatt_authentication_bloc/SignUpState-class.md) + + + +Sign up cubit state to manage the form. + + +##### [UnknownAuthenticationEvent](../wyatt_authentication_bloc/UnknownAuthenticationEvent-class.md) + + + +When a user's login status is unknown. + + +##### [UpdatedEvent](../wyatt_authentication_bloc/UpdatedEvent-class.md) + + + +When the user's account has been updated. + + + +## Mixins + +##### [SignInAnonymously](../wyatt_authentication_bloc/SignInAnonymously-mixin.md)<Data> + + + +Sign in mixin. + + +##### [SignInWithEmailPassword](../wyatt_authentication_bloc/SignInWithEmailPassword-mixin.md)<Data> + + + +Sign in mixin. + + +##### [SignInWithGoogle](../wyatt_authentication_bloc/SignInWithGoogle-mixin.md)<Data> + + + +Sign in mixin. + + +##### [SignUpWithEmailPassword](../wyatt_authentication_bloc/SignUpWithEmailPassword-mixin.md)<Data> + + + +Sign up mixin. + + +##### [UpdateEmail](../wyatt_authentication_bloc/UpdateEmail-mixin.md)<Data> + + + +Edit account mixin. + + +##### [UpdatePassword](../wyatt_authentication_bloc/UpdatePassword-mixin.md)<Data> + + + +Edit account mixin. + + + +## Extensions + +##### [BuildContextExtension](../wyatt_authentication_bloc/BuildContextExtension.md) + + + +Extension that helps to quickly access useful resources like wrapper, +session, account or data. + + + + + + +## Enums + +##### [AuthenticationStatus](../wyatt_authentication_bloc/AuthenticationStatus.md) + + + +Different authentication status + + + + +## Exceptions / Errors + +##### [ApplyActionCodeFailureFirebase](../wyatt_authentication_bloc/ApplyActionCodeFailureFirebase-class.md) + + + +Thrown if during the apply action code process if a failure occurs. + + +##### [ApplyActionCodeFailureInterface](../wyatt_authentication_bloc/ApplyActionCodeFailureInterface-class.md) + + + +Thrown if during the apply action code process if a failure occurs. + + +##### [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) + + + +Base exception used in Wyatt Authentication + + +##### [ConfirmPasswordResetFailureFirebase](../wyatt_authentication_bloc/ConfirmPasswordResetFailureFirebase-class.md) + + + +Thrown during the password reset process if a failure occurs. + + +##### [ConfirmPasswordResetFailureInterface](../wyatt_authentication_bloc/ConfirmPasswordResetFailureInterface-class.md) + + + +Thrown during the password reset process if a failure occurs. + + +##### [DeleteAccountFailureFirebase](../wyatt_authentication_bloc/DeleteAccountFailureFirebase-class.md) + + + +Thrown during the account deletion if a failure occurs. + + +##### [DeleteAccountFailureInterface](../wyatt_authentication_bloc/DeleteAccountFailureInterface-class.md) + + + +Thrown during the account deletion if a failure occurs. + + +##### [FetchSignInMethodsForEmailFailureFirebase](../wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureFirebase-class.md) + + + +Thrown during the fetch sign in methods if a failure occurs. + + +##### [FetchSignInMethodsForEmailFailureInterface](../wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureInterface-class.md) + + + +Thrown during the fetch sign in methods if a failure occurs. + + +##### [ModelParsingFailureFirebase](../wyatt_authentication_bloc/ModelParsingFailureFirebase-class.md) + + + +Thrown during the model parsing process if a failure occurs. + + +##### [ModelParsingFailureInterface](../wyatt_authentication_bloc/ModelParsingFailureInterface-class.md) + + + +Thrown during the model parsing process if a failure occurs. + + +##### [ReauthenticateFailureFirebase](../wyatt_authentication_bloc/ReauthenticateFailureFirebase-class.md) + + + +Thrown during the reauthentication process if a failure occurs. + + +##### [ReauthenticateFailureInterface](../wyatt_authentication_bloc/ReauthenticateFailureInterface-class.md) + + + +Thrown during the reauthentication process if a failure occurs. + + +##### [RefreshFailureFirebase](../wyatt_authentication_bloc/RefreshFailureFirebase-class.md) + + + +Thrown during the refresh process if a failure occurs. + + +##### [RefreshFailureInterface](../wyatt_authentication_bloc/RefreshFailureInterface-class.md) + + + +Thrown during the refresh process if a failure occurs. + + +##### [SendEmailVerificationFailureFirebase](../wyatt_authentication_bloc/SendEmailVerificationFailureFirebase-class.md) + + + +Thrown during the email verification process if a failure occurs. + + +##### [SendEmailVerificationFailureInterface](../wyatt_authentication_bloc/SendEmailVerificationFailureInterface-class.md) + + + +Thrown during the email verification process if a failure occurs. + + +##### [SendPasswordResetEmailFailureFirebase](../wyatt_authentication_bloc/SendPasswordResetEmailFailureFirebase-class.md) + + + +Thrown during the password reset process if a failure occurs. + + +##### [SendPasswordResetEmailFailureInterface](../wyatt_authentication_bloc/SendPasswordResetEmailFailureInterface-class.md) + + + +Thrown during the password reset process if a failure occurs. + + +##### [SendSignInLinkEmailFailureFirebase](../wyatt_authentication_bloc/SendSignInLinkEmailFailureFirebase-class.md) + + + +Thrown during the sign in link process if a failure occurs. + + +##### [SendSignInLinkEmailFailureInterface](../wyatt_authentication_bloc/SendSignInLinkEmailFailureInterface-class.md) + + + +Thrown during the sign in link process if a failure occurs. + + +##### [SignInAnonymouslyFailureFirebase](../wyatt_authentication_bloc/SignInAnonymouslyFailureFirebase-class.md) + + + +Thrown during the sign in process if a failure occurs. + + +##### [SignInAnonymouslyFailureInterface](../wyatt_authentication_bloc/SignInAnonymouslyFailureInterface-class.md) + + + +Thrown during the sign in process if a failure occurs. + + +##### [SignInWithAppleFailureFirebase](../wyatt_authentication_bloc/SignInWithAppleFailureFirebase-class.md) + + + +Thrown during the sign in process if a failure occurs. + + +##### [SignInWithAppleFailureInterface](../wyatt_authentication_bloc/SignInWithAppleFailureInterface-class.md) + + + +Thrown during the sign in process if a failure occurs. + + +##### [SignInWithCredentialFailureFirebase](../wyatt_authentication_bloc/SignInWithCredentialFailureFirebase-class.md) + + + +Thrown during the sign in process if a failure occurs. + + +##### [SignInWithCredentialFailureInterface](../wyatt_authentication_bloc/SignInWithCredentialFailureInterface-class.md) + + + +Thrown during the sign in process if a failure occurs. + + +##### [SignInWithEmailAndPasswordFailureFirebase](../wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureFirebase-class.md) + + + +Thrown during the sign in process if a failure occurs. + + +##### [SignInWithEmailAndPasswordFailureInterface](../wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureInterface-class.md) + + + +Thrown during the sign in process if a failure occurs. + + +##### [SignInWithEmailLinkFailureFirebase](../wyatt_authentication_bloc/SignInWithEmailLinkFailureFirebase-class.md) + + + +Thrown during the sign in process if a failure occurs. + + +##### [SignInWithEmailLinkFailureInterface](../wyatt_authentication_bloc/SignInWithEmailLinkFailureInterface-class.md) + + + +Thrown during the sign in process if a failure occurs. + + +##### [SignInWithFacebookFailureFirebase](../wyatt_authentication_bloc/SignInWithFacebookFailureFirebase-class.md) + + + +Thrown during the sign in process if a failure occurs. + + +##### [SignInWithFacebookFailureInterface](../wyatt_authentication_bloc/SignInWithFacebookFailureInterface-class.md) + + + +Thrown during the sign in process if a failure occurs. + + +##### [SignInWithGoogleFailureFirebase](../wyatt_authentication_bloc/SignInWithGoogleFailureFirebase-class.md) + + + +Thrown during the sign in process if a failure occurs. + + +##### [SignInWithGoogleFailureInterface](../wyatt_authentication_bloc/SignInWithGoogleFailureInterface-class.md) + + + +Thrown during the sign in process if a failure occurs. + + +##### [SignInWithTwitterFailureFirebase](../wyatt_authentication_bloc/SignInWithTwitterFailureFirebase-class.md) + + + +Thrown during the sign in process if a failure occurs. + + +##### [SignInWithTwitterFailureInterface](../wyatt_authentication_bloc/SignInWithTwitterFailureInterface-class.md) + + + +Thrown during the sign in process if a failure occurs. + + +##### [SignOutFailureFirebase](../wyatt_authentication_bloc/SignOutFailureFirebase-class.md) + + + +Thrown during the sign out process if a failure occurs. + + +##### [SignOutFailureInterface](../wyatt_authentication_bloc/SignOutFailureInterface-class.md) + + + +Thrown during the sign out process if a failure occurs. + + +##### [SignUpWithEmailAndPasswordFailureFirebase](../wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureFirebase-class.md) + + + +Thrown if during the sign up process if a failure occurs. + + +##### [SignUpWithEmailAndPasswordFailureInterface](../wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureInterface-class.md) + + + +Thrown if during the sign up process if a failure occurs. + + +##### [UpdateEmailFailureFirebase](../wyatt_authentication_bloc/UpdateEmailFailureFirebase-class.md) + + + +Thrown during the email modification process if a failure occurs. + + +##### [UpdateEmailFailureInterface](../wyatt_authentication_bloc/UpdateEmailFailureInterface-class.md) + + + +Thrown during the email modification process if a failure occurs. + + +##### [UpdatePasswordFailureFirebase](../wyatt_authentication_bloc/UpdatePasswordFailureFirebase-class.md) + + + +Thrown during the password modification process if a failure occurs. + + +##### [UpdatePasswordFailureInterface](../wyatt_authentication_bloc/UpdatePasswordFailureInterface-class.md) + + + +Thrown during the password modification process if a failure occurs. + + +##### [VerifyPasswordResetCodeFailureFirebase](../wyatt_authentication_bloc/VerifyPasswordResetCodeFailureFirebase-class.md) + + + +Thrown during the password reset process if a failure occurs. + + +##### [VerifyPasswordResetCodeFailureInterface](../wyatt_authentication_bloc/VerifyPasswordResetCodeFailureInterface-class.md) + + + +Thrown during the password reset process if a failure occurs. + + + + + + + diff --git a/packages/wyatt_authentication_bloc/example/.gitignore b/packages/wyatt_authentication_bloc/example/.gitignore index 891ead31..6df3a32a 100644 --- a/packages/wyatt_authentication_bloc/example/.gitignore +++ b/packages/wyatt_authentication_bloc/example/.gitignore @@ -22,7 +22,6 @@ migrate_working_dir/ #.vscode/ # Flutter/Dart/Pub related -**/doc/api/ **/ios/Flutter/.last_build_id .dart_tool/ .flutter-plugins -- 2.47.2 From b83275aaf634569b636da22f795ddfea4a39b345 Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Wed, 8 Feb 2023 13:37:52 +0100 Subject: [PATCH 19/47] feat(authentication): remove session wrapper for AuthenticationSession --- .../authentication/authentication_cubit.dart | 2 +- .../presentation/features/home/home_page.dart | 7 +- .../extensions/build_context_extension.dart | 84 +++++++++++++++---- ...hentication_firebase_data_source_impl.dart | 27 ++++-- .../authentication_repository_impl.dart | 22 +++-- .../authentication_remote_data_source.dart | 10 +-- .../lib/src/domain/entities/auth_session.dart | 60 +++++++++++++ .../authenticated_change_event.dart} | 22 ++--- .../authentication_change_event.dart | 11 +-- .../reauthenticated_event.dart | 13 +-- .../refreshed_event.dart | 11 +-- .../signed_in_event.dart | 9 +- .../signed_in_from_cache_event.dart | 9 +- .../signed_up_event.dart | 9 +- .../updated_event.dart | 9 +- .../lib/src/domain/entities/entities.dart | 3 +- .../src/domain/entities/session_wrapper.dart | 38 --------- .../authentication_repository.dart | 11 ++- .../builder/authentication_builder.dart | 8 +- .../cubit/authentication_cubit.dart | 74 ++++++++-------- .../cubit/authentication_state.dart | 10 +-- .../edit_account/cubit/mixin/edit_email.dart | 9 +- .../cubit/mixin/edit_password.dart | 9 +- .../cubit/email_verification_cubit.dart | 15 ++-- .../cubit/email_verification_state.dart | 9 +- .../cubit/mixin/sign_in_anonymously.dart | 9 +- .../mixin/sign_in_with_email_password.dart | 9 +- .../cubit/mixin/sign_in_with_google.dart | 9 +- .../mixin/sign_up_with_email_password.dart | 9 +- .../authentication_cubit_test.dart | 18 ++-- .../authentication_state_test.dart | 19 ++--- .../email_verification_cubit_test.dart | 17 +++- 32 files changed, 319 insertions(+), 262 deletions(-) create mode 100644 packages/wyatt_authentication_bloc/lib/src/domain/entities/auth_session.dart rename packages/wyatt_authentication_bloc/lib/src/domain/entities/{session.dart => authentication_change_event/authenticated_change_event.dart} (61%) delete mode 100644 packages/wyatt_authentication_bloc/lib/src/domain/entities/session_wrapper.dart diff --git a/packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/authentication_cubit.dart b/packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/authentication_cubit.dart index 5f03c2f7..ba34a213 100644 --- a/packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/authentication_cubit.dart +++ b/packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/authentication_cubit.dart @@ -37,7 +37,7 @@ class ExampleAuthenticationCubit extends AuthenticationCubit { } @override - FutureOrResult onSignInFromCache(SessionWrapper wrapper) { + FutureOrResult onSignInFromCache(AuthenticationSession session) { print('onSignInFromCache'); return const Ok(1); diff --git a/packages/wyatt_authentication_bloc/example/lib/presentation/features/home/home_page.dart b/packages/wyatt_authentication_bloc/example/lib/presentation/features/home/home_page.dart index dade25b8..463ea902 100644 --- a/packages/wyatt_authentication_bloc/example/lib/presentation/features/home/home_page.dart +++ b/packages/wyatt_authentication_bloc/example/lib/presentation/features/home/home_page.dart @@ -30,8 +30,7 @@ class HomePage extends StatelessWidget { Widget build(BuildContext context) { return Scaffold( appBar: AppBar( - title: Text( - 'Home | ${context.account, int>()?.email}'), + title: Text('Home | ${context.watchAccount()?.email}'), actions: [ IconButton( onPressed: () => @@ -44,8 +43,8 @@ class HomePage extends StatelessWidget { child: ListView( children: [ AuthenticationBuilder( - authenticated: (context, sessionWrapper) => Text( - 'Logged as ${sessionWrapper.session?.account.email} | GeneratedId is ${sessionWrapper.session?.data}'), + authenticated: (context, session) => Text( + 'Logged as ${session.account?.email} | GeneratedId is ${session.data}'), unauthenticated: (context) => const Text('Not logged (unauthenticated)'), unknown: (context) => const Text('Not logged (unknown)'), diff --git a/packages/wyatt_authentication_bloc/lib/src/core/extensions/build_context_extension.dart b/packages/wyatt_authentication_bloc/lib/src/core/extensions/build_context_extension.dart index c7753da4..83a4867c 100644 --- a/packages/wyatt_authentication_bloc/lib/src/core/extensions/build_context_extension.dart +++ b/packages/wyatt_authentication_bloc/lib/src/core/extensions/build_context_extension.dart @@ -17,26 +17,82 @@ import 'package:flutter/widgets.dart'; import 'package:flutter_bloc/flutter_bloc.dart'; import 'package:wyatt_authentication_bloc/src/domain/entities/account.dart'; -import 'package:wyatt_authentication_bloc/src/domain/entities/session.dart'; -import 'package:wyatt_authentication_bloc/src/domain/entities/session_wrapper.dart'; +import 'package:wyatt_authentication_bloc/src/domain/entities/auth_session.dart'; +import 'package:wyatt_authentication_bloc/src/domain/entities/authentication_change_event/authentication_change_event.dart'; import 'package:wyatt_authentication_bloc/src/features/authentication/cubit/authentication_cubit.dart'; /// Extension that helps to quickly access useful resources like wrapper, /// session, account or data. extension BuildContextExtension on BuildContext { - /// Returns session wrapper - SessionWrapper? wrapper, Data>() => - watch().currentSession(); + /// Read session in context from a specific AuthenticationCubit type [T] + AuthenticationSession? + readSessionFrom, Data>() => + read().currentSession(); - /// Returns session - Session? session, Data>() => - watch().currentSession()?.session; + /// Watch session in context from a specific AuthenticationCubit type [T] + AuthenticationSession? + watchSessionFrom, Data>() => + watch().currentSession(); - /// Returns account - Account? account, Data>() => - watch().currentSession()?.session?.account; + /// Read session in context from generic AuthenticationCubit type + AuthenticationSession? readSession() => + read>().currentSession(); - /// Returns associated data - Data? data, Data>() => - watch().currentSession()?.session?.data; + /// Watch session in context from generic AuthenticationCubit type + AuthenticationSession? watchSession() => + watch>().currentSession(); + + /// Read event in context from a specific AuthenticationCubit type [T] + AuthenticationChangeEvent? + readEventFrom, Data>() => + readSessionFrom()?.latestEvent; + + /// Watch event in context from a specific AuthenticationCubit type [T] + AuthenticationChangeEvent? + watchEventFrom, Data>() => + watchSessionFrom()?.latestEvent; + + /// Read event in context from generic AuthenticationCubit type + AuthenticationChangeEvent? readEvent() => + readSession()?.latestEvent; + + /// Watch event in context from generic AuthenticationCubit type + AuthenticationChangeEvent? watchEvent() => + watchSession()?.latestEvent; + + /// Read account in context from a specific AuthenticationCubit type [T] + Account? readAccountFrom, Data>() => + readSessionFrom()?.account; + + /// Watch account in context from a specific AuthenticationCubit type [T] + Account? watchAccountFrom, Data>() => + watchSessionFrom()?.account; + + /// Read account in context from generic AuthenticationCubit type + Account? readAccount() => readSession()?.account; + + /// Watch account in context from generic AuthenticationCubit type + Account? watchAccount() => watchSession()?.account; + + /// Read data in context from a specific AuthenticationCubit type [T] + Data? readDataFrom, Data>() => + readSessionFrom()?.data; + + /// Watch data in context from a specific AuthenticationCubit type [T] + Data? watchDataFrom, Data>() => + watchSessionFrom()?.data; + + /// Read data in context from generic AuthenticationCubit type + Data? readData() => readSession()?.data; + + /// Watch data in context from generic AuthenticationCubit type + Data? watchData() => watchSession()?.data; + + /// Check if user is authenticated from a + /// specific AuthenticationCubit type [T] + bool isAuthenticatedFrom, Data>() => + readEventFrom() is AuthenticatedChangeEvent; + + /// Check if user is authenticated from generic AuthenticationCubit type + bool isAuthenticated() => readEvent() is AuthenticatedChangeEvent; } diff --git a/packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/authentication_firebase_data_source_impl.dart b/packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/authentication_firebase_data_source_impl.dart index b2c9d4f2..f745e8cf 100644 --- a/packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/authentication_firebase_data_source_impl.dart +++ b/packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/authentication_firebase_data_source_impl.dart @@ -23,8 +23,8 @@ import 'package:wyatt_authentication_bloc/src/core/exceptions/exceptions.dart'; import 'package:wyatt_authentication_bloc/src/data/models/models.dart'; import 'package:wyatt_authentication_bloc/src/domain/data_sources/remote/authentication_remote_data_source.dart'; import 'package:wyatt_authentication_bloc/src/domain/entities/account.dart'; +import 'package:wyatt_authentication_bloc/src/domain/entities/auth_session.dart'; import 'package:wyatt_authentication_bloc/src/domain/entities/authentication_change_event/authentication_change_event.dart'; -import 'package:wyatt_authentication_bloc/src/domain/entities/session_wrapper.dart'; import 'package:wyatt_type_utils/wyatt_type_utils.dart'; class AuthenticationFirebaseDataSourceImpl @@ -41,7 +41,7 @@ class AuthenticationFirebaseDataSourceImpl _checkForCachedAccount(); } - late StreamController> _sessionStream; + late StreamController> _sessionStream; late StreamController _latestCredentials; final FirebaseAuth _firebaseAuth; @@ -51,8 +51,11 @@ class AuthenticationFirebaseDataSourceImpl final currentUser = _firebaseAuth.currentUser; if (currentUser == null) { - _sessionStream - .add(const SessionWrapper(event: UnknownAuthenticationEvent())); + _sessionStream.add( + const AuthenticationSession( + latestEvent: UnknownAuthenticationEvent(), + ), + ); return; } @@ -62,7 +65,9 @@ class AuthenticationFirebaseDataSourceImpl accessToken: jwt, ); _sessionStream.add( - SessionWrapper(event: SignedInFromCacheEvent(account: currentAccount)), + AuthenticationSession.fromEvent( + SignedInFromCacheEvent(account: currentAccount), + ), ); return; } @@ -78,19 +83,23 @@ class AuthenticationFirebaseDataSourceImpl return account; } - // Stream related methods =================================================== + // Session related methods =================================================== /// {@macro add_session} @override - void addSession(SessionWrapper wrapper) { - _sessionStream.add(wrapper); + void addSession(AuthenticationSession session) { + _sessionStream.add(session); } /// {@macro session_stream} @override - Stream> sessionStream() => + Stream> sessionStream() => _sessionStream.stream.asBroadcastStream(); + /// {@macro current_session} + @override + Future> currentSession() => sessionStream().last; + // SignUp/SignIn methods ==================================================== /// {@macro signup_pwd} diff --git a/packages/wyatt_authentication_bloc/lib/src/data/repositories/authentication_repository_impl.dart b/packages/wyatt_authentication_bloc/lib/src/data/repositories/authentication_repository_impl.dart index 4d3a3f4e..3b2c8481 100644 --- a/packages/wyatt_authentication_bloc/lib/src/data/repositories/authentication_repository_impl.dart +++ b/packages/wyatt_authentication_bloc/lib/src/data/repositories/authentication_repository_impl.dart @@ -18,7 +18,7 @@ import 'package:wyatt_architecture/wyatt_architecture.dart'; import 'package:wyatt_authentication_bloc/src/core/utils/forms.dart'; import 'package:wyatt_authentication_bloc/src/domain/data_sources/remote/authentication_remote_data_source.dart'; import 'package:wyatt_authentication_bloc/src/domain/entities/account.dart'; -import 'package:wyatt_authentication_bloc/src/domain/entities/session_wrapper.dart'; +import 'package:wyatt_authentication_bloc/src/domain/entities/auth_session.dart'; import 'package:wyatt_authentication_bloc/src/domain/repositories/authentication_repository.dart'; import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; import 'package:wyatt_type_utils/wyatt_type_utils.dart'; @@ -73,18 +73,30 @@ class AuthenticationRepositoryImpl @override FormRepository get formRepository => _formRepository; - // Stream related methods =================================================== + // Session related methods =================================================== /// {@macro add_session} @override - void addSession(SessionWrapper wrapper) => - authenticationRemoteDataSource.addSession(wrapper); + void addSession(AuthenticationSession session) => + authenticationRemoteDataSource.addSession(session); /// {@macro session_stream} @override - Stream> sessionStream() => + Stream> sessionStream() => authenticationRemoteDataSource.sessionStream(); + /// {@macro current_session} + @override + FutureOrResult> currentSession() => + Result.tryCatchAsync, AppException, + AppException>( + () async { + final session = await authenticationRemoteDataSource.currentSession(); + return session; + }, + (error) => error, + ); + // SignUp/SignIn methods ==================================================== /// {@macro signup_pwd} diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/data_sources/remote/authentication_remote_data_source.dart b/packages/wyatt_authentication_bloc/lib/src/domain/data_sources/remote/authentication_remote_data_source.dart index 6bec3426..91cb2550 100644 --- a/packages/wyatt_authentication_bloc/lib/src/domain/data_sources/remote/authentication_remote_data_source.dart +++ b/packages/wyatt_authentication_bloc/lib/src/domain/data_sources/remote/authentication_remote_data_source.dart @@ -16,16 +16,16 @@ import 'package:wyatt_architecture/wyatt_architecture.dart'; import 'package:wyatt_authentication_bloc/src/domain/entities/account.dart'; -import 'package:wyatt_authentication_bloc/src/domain/entities/session_wrapper.dart'; +import 'package:wyatt_authentication_bloc/src/domain/entities/auth_session.dart'; /// Is responsible for abstracting the provenance of the data. abstract class AuthenticationRemoteDataSource extends BaseRemoteDataSource { - // Stream related methods =================================================== + // Session related methods =================================================== - void addSession(SessionWrapper wrapper); - - Stream> sessionStream(); + void addSession(AuthenticationSession session); + Stream> sessionStream(); + Future> currentSession(); // SignUp/SignIn methods ==================================================== diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/entities/auth_session.dart b/packages/wyatt_authentication_bloc/lib/src/domain/entities/auth_session.dart new file mode 100644 index 00000000..a5a37cf2 --- /dev/null +++ b/packages/wyatt_authentication_bloc/lib/src/domain/entities/auth_session.dart @@ -0,0 +1,60 @@ +// Copyright (C) 2023 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +import 'package:equatable/equatable.dart'; +import 'package:wyatt_authentication_bloc/wyatt_authentication_bloc.dart'; + +/// The [AuthenticationSession] object is used to transport and propagate +/// the last event issued by an authentication state change, a user account +/// if connected, and the associated data. +class AuthenticationSession extends Equatable { + const AuthenticationSession({ + required this.latestEvent, + this.account, + this.data, + }); + + factory AuthenticationSession.fromEvent( + AuthenticationChangeEvent latestEvent, { + Data? data, + }) { + if (latestEvent is AuthenticatedChangeEvent) { + return AuthenticationSession( + latestEvent: latestEvent, + account: latestEvent.account, + data: data, + ); + } + return AuthenticationSession( + latestEvent: latestEvent, + data: data, + ); + } + + final AuthenticationChangeEvent latestEvent; + final Account? account; + final Data? data; + + @override + List get props => [ + latestEvent, + account, + data, + ]; + + @override + bool? get stringify => true; +} diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/entities/session.dart b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/authenticated_change_event.dart similarity index 61% rename from packages/wyatt_authentication_bloc/lib/src/domain/entities/session.dart rename to packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/authenticated_change_event.dart index 61162ee8..03bb2d50 100644 --- a/packages/wyatt_authentication_bloc/lib/src/domain/entities/session.dart +++ b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/authenticated_change_event.dart @@ -14,23 +14,15 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . -import 'package:equatable/equatable.dart'; -import 'package:wyatt_authentication_bloc/src/domain/entities/account.dart'; +part of 'authentication_change_event.dart'; + + +/// Represents every event where user is authenticated. +abstract class AuthenticatedChangeEvent extends AuthenticationChangeEvent { + const AuthenticatedChangeEvent({required this.account}); -/// The [Session] object is used to transport and propagate -/// the connected user [Account] and personalized [Data] in the application. -class Session extends Equatable { - const Session({ - required this.account, - this.data, - }); - final Account account; - final Data? data; - - @override - List get props => [account, data]; @override - bool? get stringify => true; + List get props => [account]; } diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/authentication_change_event.dart b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/authentication_change_event.dart index 51d6e511..08312b7c 100644 --- a/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/authentication_change_event.dart +++ b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/authentication_change_event.dart @@ -18,15 +18,16 @@ import 'package:equatable/equatable.dart'; import 'package:wyatt_architecture/wyatt_architecture.dart'; import 'package:wyatt_authentication_bloc/src/domain/entities/account.dart'; +part 'authenticated_change_event.dart'; +part 'deleted_event.dart'; +part 'reauthenticated_event.dart'; +part 'refreshed_event.dart'; part 'signed_in_event.dart'; +part 'signed_in_from_cache_event.dart'; part 'signed_out_event.dart'; part 'signed_up_event.dart'; -part 'refreshed_event.dart'; -part 'reauthenticated_event.dart'; -part 'updated_event.dart'; part 'unknown_authentication_event.dart'; -part 'signed_in_from_cache_event.dart'; -part 'deleted_event.dart'; +part 'updated_event.dart'; /// Represents an event initiated by a change in /// the user's authentication status. diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/reauthenticated_event.dart b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/reauthenticated_event.dart index 2ad9c96f..4cd8e13c 100644 --- a/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/reauthenticated_event.dart +++ b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/reauthenticated_event.dart @@ -16,14 +16,9 @@ part of 'authentication_change_event.dart'; -/// When a user re-authenticates (from the logged in state to the -/// logged in state with a different and fresh access +/// When a user re-authenticates (from the logged in state to the +/// logged in state with a different and fresh access /// token and a different login time) -class ReauthenticatedEvent extends AuthenticationChangeEvent { - const ReauthenticatedEvent({required this.account}); - - final Account account; - - @override - List get props => [account]; +class ReauthenticatedEvent extends AuthenticatedChangeEvent { + const ReauthenticatedEvent({required super.account}); } diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/refreshed_event.dart b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/refreshed_event.dart index ce8651d3..e2971cc4 100644 --- a/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/refreshed_event.dart +++ b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/refreshed_event.dart @@ -16,13 +16,8 @@ part of 'authentication_change_event.dart'; -/// When a user access token is refreshed (from the logged in state to the +/// When a user access token is refreshed (from the logged in state to the /// logged in state with a different access token) -class RefreshedEvent extends AuthenticationChangeEvent { - const RefreshedEvent({required this.account}); - - final Account account; - - @override - List get props => [account]; +class RefreshedEvent extends AuthenticatedChangeEvent { + const RefreshedEvent({required super.account}); } diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/signed_in_event.dart b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/signed_in_event.dart index 22cd6296..8d2fa0e3 100644 --- a/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/signed_in_event.dart +++ b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/signed_in_event.dart @@ -17,11 +17,6 @@ part of 'authentication_change_event.dart'; /// When a user authenticates (from not logged in to logged in). -class SignedInEvent extends AuthenticationChangeEvent { - const SignedInEvent({required this.account}); - - final Account account; - - @override - List get props => [account]; +class SignedInEvent extends AuthenticatedChangeEvent { + const SignedInEvent({required super.account}); } diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/signed_in_from_cache_event.dart b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/signed_in_from_cache_event.dart index b32f098a..a4e57dda 100644 --- a/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/signed_in_from_cache_event.dart +++ b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/signed_in_from_cache_event.dart @@ -17,11 +17,6 @@ part of 'authentication_change_event.dart'; /// When a user authenticates automatically (from not logged in to logged in). -class SignedInFromCacheEvent extends AuthenticationChangeEvent { - const SignedInFromCacheEvent({required this.account}); - - final Account account; - - @override - List get props => [account]; +class SignedInFromCacheEvent extends AuthenticatedChangeEvent { + const SignedInFromCacheEvent({required super.account}); } diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/signed_up_event.dart b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/signed_up_event.dart index 6683e0fa..903adbf1 100644 --- a/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/signed_up_event.dart +++ b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/signed_up_event.dart @@ -17,11 +17,6 @@ part of 'authentication_change_event.dart'; /// When a user creates an account. -class SignedUpEvent extends AuthenticationChangeEvent { - const SignedUpEvent({required this.account}); - - final Account account; - - @override - List get props => [account]; +class SignedUpEvent extends AuthenticatedChangeEvent { + const SignedUpEvent({required super.account}); } diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/updated_event.dart b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/updated_event.dart index f64e6c74..117cc725 100644 --- a/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/updated_event.dart +++ b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/updated_event.dart @@ -17,11 +17,6 @@ part of 'authentication_change_event.dart'; /// When the user's account has been updated. -class UpdatedEvent extends AuthenticationChangeEvent { - const UpdatedEvent({required this.account}); - - final Account account; - - @override - List get props => [account]; +class UpdatedEvent extends AuthenticatedChangeEvent { + const UpdatedEvent({required super.account}); } diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/entities/entities.dart b/packages/wyatt_authentication_bloc/lib/src/domain/entities/entities.dart index a466a036..a1afb54e 100644 --- a/packages/wyatt_authentication_bloc/lib/src/domain/entities/entities.dart +++ b/packages/wyatt_authentication_bloc/lib/src/domain/entities/entities.dart @@ -15,6 +15,5 @@ // along with this program. If not, see . export 'account.dart'; +export 'auth_session.dart'; export 'authentication_change_event/authentication_change_event.dart'; -export 'session.dart'; -export 'session_wrapper.dart'; diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/entities/session_wrapper.dart b/packages/wyatt_authentication_bloc/lib/src/domain/entities/session_wrapper.dart deleted file mode 100644 index 4fa2b924..00000000 --- a/packages/wyatt_authentication_bloc/lib/src/domain/entities/session_wrapper.dart +++ /dev/null @@ -1,38 +0,0 @@ -// Copyright (C) 2023 WYATT GROUP -// Please see the AUTHORS file for details. -// -// This program is free software: you can redistribute it and/or modify -// it under the terms of the GNU General Public License as published by -// the Free Software Foundation, either version 3 of the License, or -// any later version. -// -// This program is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with this program. If not, see . - -import 'package:equatable/equatable.dart'; -import 'package:wyatt_architecture/wyatt_architecture.dart'; -import 'package:wyatt_authentication_bloc/src/domain/entities/authentication_change_event/authentication_change_event.dart'; -import 'package:wyatt_authentication_bloc/src/domain/entities/session.dart'; - -/// Contains the [AuthenticationChangeEvent] initiating the state -/// change and the current [Session]. -class SessionWrapper extends Equatable implements Entity { - const SessionWrapper({ - required this.event, - this.session, - }); - - final AuthenticationChangeEvent event; - final Session? session; - - @override - List get props => [event, session]; - - @override - bool get stringify => true; -} diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/repositories/authentication_repository.dart b/packages/wyatt_authentication_bloc/lib/src/domain/repositories/authentication_repository.dart index 1eb6fc25..ab32e322 100644 --- a/packages/wyatt_authentication_bloc/lib/src/domain/repositories/authentication_repository.dart +++ b/packages/wyatt_authentication_bloc/lib/src/domain/repositories/authentication_repository.dart @@ -16,7 +16,7 @@ import 'package:wyatt_architecture/wyatt_architecture.dart'; import 'package:wyatt_authentication_bloc/src/domain/entities/account.dart'; -import 'package:wyatt_authentication_bloc/src/domain/entities/session_wrapper.dart'; +import 'package:wyatt_authentication_bloc/src/domain/entities/auth_session.dart'; import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; abstract class AuthenticationRepository extends BaseRepository { @@ -30,12 +30,17 @@ abstract class AuthenticationRepository extends BaseRepository { /// {@template add_session} /// Add a new authentication event. /// {@endtemplate} - void addSession(SessionWrapper wrapper); + void addSession(AuthenticationSession session); /// {@template session_stream} /// Authentication state change event stream. /// {@endtemplate} - Stream> sessionStream(); + Stream> sessionStream(); + + /// {@template current_session} + /// Latest session issued by the session stream. + /// {@endtemplate} + FutureOrResult> currentSession(); // SignUp/SignIn methods ==================================================== diff --git a/packages/wyatt_authentication_bloc/lib/src/features/authentication/builder/authentication_builder.dart b/packages/wyatt_authentication_bloc/lib/src/features/authentication/builder/authentication_builder.dart index 19e77c20..3c9f1999 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/authentication/builder/authentication_builder.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/authentication/builder/authentication_builder.dart @@ -17,7 +17,7 @@ import 'package:flutter/material.dart'; import 'package:flutter_bloc/flutter_bloc.dart'; import 'package:wyatt_authentication_bloc/src/core/enums/authentication_status.dart'; -import 'package:wyatt_authentication_bloc/src/domain/entities/session_wrapper.dart'; +import 'package:wyatt_authentication_bloc/src/domain/entities/auth_session.dart'; import 'package:wyatt_authentication_bloc/src/features/authentication/cubit/authentication_cubit.dart'; class AuthenticationBuilder extends StatelessWidget { @@ -30,7 +30,7 @@ class AuthenticationBuilder extends StatelessWidget { final Widget Function( BuildContext context, - SessionWrapper sessionWrapper, + AuthenticationSession session, ) authenticated; final Widget Function(BuildContext context) unauthenticated; final Widget Function(BuildContext context) unknown; @@ -40,8 +40,8 @@ class AuthenticationBuilder extends StatelessWidget { BlocBuilder, AuthenticationState>( builder: (context, state) { if (state.status == AuthenticationStatus.authenticated) { - if (state.wrapper != null) { - return authenticated(context, state.wrapper!); + if (state.session != null) { + return authenticated(context, state.session!); } else { return unauthenticated(context); } diff --git a/packages/wyatt_authentication_bloc/lib/src/features/authentication/cubit/authentication_cubit.dart b/packages/wyatt_authentication_bloc/lib/src/features/authentication/cubit/authentication_cubit.dart index c90ab44f..e6748680 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/authentication/cubit/authentication_cubit.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/authentication/cubit/authentication_cubit.dart @@ -42,35 +42,31 @@ abstract class AuthenticationCubit } final AuthenticationRepository authenticationRepository; - SessionWrapper? _latestSession; + AuthenticationSession? _latestSession; void _listenForAuthenticationChanges() { - authenticationRepository.sessionStream().asyncMap((wrapper) async { - final event = wrapper.event; + authenticationRepository.sessionStream().asyncMap((session) async { + final event = session.latestEvent; if (event is SignedInFromCacheEvent) { - final customRoutineResult = await onSignInFromCache(wrapper); + final customRoutineResult = await onSignInFromCache(session); if (customRoutineResult.isOk) { final account = event.account; final sessionData = customRoutineResult.ok; - final signedInSession = SessionWrapper( - event: SignedInFromCacheEvent(account: account), - session: Session( - account: account, - data: sessionData, - ), + final signedInSession = AuthenticationSession.fromEvent( + SignedInFromCacheEvent(account: account), + data: sessionData, ); return signedInSession; } } - return wrapper; - }).listen((wrapper) async { - _latestSession = wrapper; - final session = wrapper.session; - if (session != null) { - emit(AuthenticationState.authenticated(wrapper)); + return session; + }).listen((session) async { + _latestSession = session; + if (session.account != null) { + emit(AuthenticationState.authenticated(session)); return; } emit(AuthenticationState.unauthenticated()); @@ -80,19 +76,16 @@ abstract class AuthenticationCubit /// {@macro refresh} FutureOr refresh() async => CustomRoutine( - routine: authenticationRepository.refresh, - attachedLogic: onRefresh, - onError: addError, - onSuccess: (result, data) => authenticationRepository.addSession( - SessionWrapper( - event: RefreshedEvent(account: result), - session: Session( - account: result, + routine: authenticationRepository.refresh, + attachedLogic: onRefresh, + onError: addError, + onSuccess: (result, data) => authenticationRepository.addSession( + AuthenticationSession.fromEvent( + RefreshedEvent(account: result), data: data, ), ), - ), - ).call(); + ).call(); /// {@macro reauthenticate} FutureOr reauthenticate() async => CustomRoutine( @@ -100,12 +93,9 @@ abstract class AuthenticationCubit attachedLogic: onReauthenticate, onError: addError, onSuccess: (result, data) => authenticationRepository.addSession( - SessionWrapper( - event: ReauthenticatedEvent(account: result), - session: Session( - account: result, - data: data, - ), + AuthenticationSession.fromEvent( + ReauthenticatedEvent(account: result), + data: data, ), ), ).call(); @@ -115,8 +105,11 @@ abstract class AuthenticationCubit routine: authenticationRepository.signOut, attachedLogic: (routineResult) => onSignOut(), onError: addError, - onSuccess: (result, data) => authenticationRepository - .addSession(SessionWrapper(event: const SignedOutEvent())), + onSuccess: (result, data) => authenticationRepository.addSession( + const AuthenticationSession( + latestEvent: SignedOutEvent(), + ), + ), ).call(); /// {@macro delete} @@ -124,20 +117,23 @@ abstract class AuthenticationCubit routine: authenticationRepository.delete, attachedLogic: (routineResult) => onDelete(), onError: addError, - onSuccess: (result, data) => authenticationRepository - .addSession(SessionWrapper(event: const DeletedEvent())), + onSuccess: (result, data) => authenticationRepository.addSession( + const AuthenticationSession( + latestEvent: DeletedEvent(), + ), + ), ).call(); - /// Returns latest session wrapper. + /// Returns latest session. /// /// Contains latest event and latest session data (account + extra data) - SessionWrapper? currentSession() => _latestSession; + AuthenticationSession? currentSession() => _latestSession; /// This callback is triggered when the user is automaticcaly logged in from /// the cache. /// /// For example: when the user is sign in from the Firebase cache. - FutureOrResult onSignInFromCache(SessionWrapper wrapper); + FutureOrResult onSignInFromCache(AuthenticationSession session); /// This callback is triggered when the account is refreshed. /// diff --git a/packages/wyatt_authentication_bloc/lib/src/features/authentication/cubit/authentication_state.dart b/packages/wyatt_authentication_bloc/lib/src/features/authentication/cubit/authentication_state.dart index cf672a4c..1f3a1c72 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/authentication/cubit/authentication_state.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/authentication/cubit/authentication_state.dart @@ -17,25 +17,25 @@ part of 'authentication_cubit.dart'; class AuthenticationState extends Equatable { - const AuthenticationState._(this.status, this.wrapper); + const AuthenticationState._(this.status, this.session); const AuthenticationState.unauthenticated() : this._(AuthenticationStatus.unauthenticated, null); - const AuthenticationState.authenticated(SessionWrapper sessionWrapper) + const AuthenticationState.authenticated(AuthenticationSession session) : this._( AuthenticationStatus.authenticated, - sessionWrapper, + session, ); const AuthenticationState.unknown() : this._(AuthenticationStatus.unknown, null); final AuthenticationStatus status; - final SessionWrapper? wrapper; + final AuthenticationSession? session; @override - List get props => [status, wrapper]; + List get props => [status, session]; @override bool? get stringify => true; diff --git a/packages/wyatt_authentication_bloc/lib/src/features/edit_account/cubit/mixin/edit_email.dart b/packages/wyatt_authentication_bloc/lib/src/features/edit_account/cubit/mixin/edit_email.dart index 47aecb30..c755838f 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/edit_account/cubit/mixin/edit_email.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/edit_account/cubit/mixin/edit_email.dart @@ -111,12 +111,9 @@ mixin UpdateEmail on BaseEditAccountCubit { }, onSuccess: (account, data) { authenticationRepository.addSession( - SessionWrapper( - event: UpdatedEvent(account: account), - session: Session( - account: account, - data: data, - ), + AuthenticationSession.fromEvent( + UpdatedEvent(account: account), + data: data, ), ); emit( diff --git a/packages/wyatt_authentication_bloc/lib/src/features/edit_account/cubit/mixin/edit_password.dart b/packages/wyatt_authentication_bloc/lib/src/features/edit_account/cubit/mixin/edit_password.dart index 3b270800..31dcb20d 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/edit_account/cubit/mixin/edit_password.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/edit_account/cubit/mixin/edit_password.dart @@ -110,12 +110,9 @@ mixin UpdatePassword on BaseEditAccountCubit { }, onSuccess: (account, data) { authenticationRepository.addSession( - SessionWrapper( - event: SignedInEvent(account: account), - session: Session( - account: account, - data: data, - ), + AuthenticationSession.fromEvent( + UpdatedEvent(account: account), + data: data, ), ); emit( diff --git a/packages/wyatt_authentication_bloc/lib/src/features/email_verification/cubit/email_verification_cubit.dart b/packages/wyatt_authentication_bloc/lib/src/features/email_verification/cubit/email_verification_cubit.dart index 986b2bc9..56297baa 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/email_verification/cubit/email_verification_cubit.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/email_verification/cubit/email_verification_cubit.dart @@ -31,12 +31,13 @@ class EmailVerificationCubit extends Cubit { final AuthenticationRepository authenticationRepository; FutureOr sendEmailVerification() async { - emit(state.copyWith(status: FormStatus.submissionInProgress)); + emit(const EmailVerificationState(status: FormStatus.submissionInProgress)); final response = await authenticationRepository.sendEmailVerification(); emit( response.fold( - (value) => state.copyWith(status: FormStatus.submissionSuccess), - (error) => state.copyWith( + (value) => + const EmailVerificationState(status: FormStatus.submissionSuccess), + (error) => EmailVerificationState( errorMessage: error.message, status: FormStatus.submissionFailure, ), @@ -45,7 +46,7 @@ class EmailVerificationCubit extends Cubit { } FutureOr checkEmailVerification() async { - emit(state.copyWith(status: FormStatus.submissionInProgress)); + emit(const EmailVerificationState(status: FormStatus.submissionInProgress)); final refresh = await authenticationRepository.refresh(); if (refresh.isErr) { @@ -59,11 +60,11 @@ class EmailVerificationCubit extends Cubit { return; } - final wrapper = await authenticationRepository.sessionStream().last; - final currentAccount = wrapper.session?.account; + final session = await authenticationRepository.currentSession(); + final currentAccount = session.ok?.account; if (currentAccount != null) { emit( - state.copyWith( + EmailVerificationState( isVerified: currentAccount.emailVerified, status: FormStatus.submissionSuccess, ), diff --git a/packages/wyatt_authentication_bloc/lib/src/features/email_verification/cubit/email_verification_state.dart b/packages/wyatt_authentication_bloc/lib/src/features/email_verification/cubit/email_verification_state.dart index c78db5b7..aa12191d 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/email_verification/cubit/email_verification_state.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/email_verification/cubit/email_verification_state.dart @@ -1,4 +1,3 @@ -// ignore_for_file: public_member_api_docs, sort_constructors_first // Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // @@ -18,16 +17,16 @@ part of 'email_verification_cubit.dart'; class EmailVerificationState extends Equatable { - final FormStatus status; - final bool isVerified; - final String? errorMessage; - const EmailVerificationState({ this.isVerified = false, this.status = FormStatus.pure, this.errorMessage, }); + final FormStatus status; + final bool isVerified; + final String? errorMessage; + EmailVerificationState copyWith({ FormStatus? status, bool? isVerified, diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_anonymously.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_anonymously.dart index 2adf2f2f..fde28872 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_anonymously.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_anonymously.dart @@ -63,12 +63,9 @@ mixin SignInAnonymously on BaseSignInCubit { }, onSuccess: (account, data) { authenticationRepository.addSession( - SessionWrapper( - event: SignedInEvent(account: account), - session: Session( - account: account, - data: data, - ), + AuthenticationSession.fromEvent( + SignedInEvent(account: account), + data: data, ), ); emit( diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_with_email_password.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_with_email_password.dart index 36e7372b..616cde9b 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_with_email_password.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_with_email_password.dart @@ -136,12 +136,9 @@ mixin SignInWithEmailPassword on BaseSignInCubit { }, onSuccess: (account, data) { authenticationRepository.addSession( - SessionWrapper( - event: SignedInEvent(account: account), - session: Session( - account: account, - data: data, - ), + AuthenticationSession.fromEvent( + SignedInEvent(account: account), + data: data, ), ); emit( diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_with_google.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_with_google.dart index 458844fe..1d814d19 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_with_google.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/mixin/sign_in_with_google.dart @@ -62,12 +62,9 @@ mixin SignInWithGoogle on BaseSignInCubit { }, onSuccess: (account, data) { authenticationRepository.addSession( - SessionWrapper( - event: SignedInEvent(account: account), - session: Session( - account: account, - data: data, - ), + AuthenticationSession.fromEvent( + SignedInEvent(account: account), + data: data, ), ); emit( diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/mixin/sign_up_with_email_password.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/mixin/sign_up_with_email_password.dart index 7c2f39f0..80d56b7b 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/mixin/sign_up_with_email_password.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/mixin/sign_up_with_email_password.dart @@ -126,12 +126,9 @@ mixin SignUpWithEmailPassword on BaseSignUpCubit { }, onSuccess: (account, data) { authenticationRepository.addSession( - SessionWrapper( - event: SignedUpEvent(account: account), - session: Session( - account: account, - data: data, - ), + AuthenticationSession.fromEvent( + SignedUpEvent(account: account), + data: data, ), ); emit( diff --git a/packages/wyatt_authentication_bloc/test/authentication/authentication_cubit_test.dart b/packages/wyatt_authentication_bloc/test/authentication/authentication_cubit_test.dart index af1d17d7..f5c26033 100644 --- a/packages/wyatt_authentication_bloc/test/authentication/authentication_cubit_test.dart +++ b/packages/wyatt_authentication_bloc/test/authentication/authentication_cubit_test.dart @@ -43,7 +43,9 @@ class TestAuthenticationCubit extends AuthenticationCubit { const Ok(null); @override - FutureOrResult onSignInFromCache(SessionWrapper wrapper) async => + FutureOrResult onSignInFromCache( + AuthenticationSession session, + ) async => const Ok(null); @override @@ -53,9 +55,10 @@ class TestAuthenticationCubit extends AuthenticationCubit { void main() { group('AuthenticationCubit', () { final MockAccount account = MockAccount(); - final SessionWrapper wrapper = SessionWrapper( - event: const UnknownAuthenticationEvent(), - session: Session(account: account, data: 10), + final AuthenticationSession session = AuthenticationSession( + latestEvent: const UnknownAuthenticationEvent(), + account: account, + data: 10, ); late AuthenticationRepository authenticationRepository; @@ -80,14 +83,14 @@ void main() { 'emits authenticated when stream contains session', setUp: () { when(() => authenticationRepository.sessionStream()).thenAnswer( - (_) => Stream.fromIterable([wrapper]), + (_) => Stream.fromIterable([session]), ); }, build: () => TestAuthenticationCubit( authenticationRepository: authenticationRepository, ), seed: () => const AuthenticationState.unknown(), - expect: () => [AuthenticationState.authenticated(wrapper)], + expect: () => [AuthenticationState.authenticated(session)], ); blocTest, AuthenticationState>( @@ -95,7 +98,8 @@ void main() { setUp: () { when(() => authenticationRepository.sessionStream()).thenAnswer( (_) => Stream.fromIterable( - [const SessionWrapper(event: SignedOutEvent())],), + [const AuthenticationSession(latestEvent: SignedOutEvent())], + ), ); }, build: () => TestAuthenticationCubit( diff --git a/packages/wyatt_authentication_bloc/test/authentication/authentication_state_test.dart b/packages/wyatt_authentication_bloc/test/authentication/authentication_state_test.dart index 92bd5258..9566f2f3 100644 --- a/packages/wyatt_authentication_bloc/test/authentication/authentication_state_test.dart +++ b/packages/wyatt_authentication_bloc/test/authentication/authentication_state_test.dart @@ -27,7 +27,7 @@ void main() { const AuthenticationState state = AuthenticationState.unauthenticated(); expect(state.status, AuthenticationStatus.unauthenticated); - expect(state.wrapper, null); + expect(state.session, null); }); }); @@ -36,13 +36,12 @@ void main() { final MockAccount account = MockAccount(); final AuthenticationState state = AuthenticationState.authenticated( - SessionWrapper( - event: SignedInEvent(account: account), - session: Session(account: account), + AuthenticationSession.fromEvent( + SignedInEvent(account: account), ), ); expect(state.status, AuthenticationStatus.authenticated); - expect(state.wrapper?.session?.account, account); + expect(state.session?.account, account); }); }); @@ -52,14 +51,14 @@ void main() { const String extra = 'AwesomeExtraData'; final AuthenticationState state = AuthenticationState.authenticated( - SessionWrapper( - event: SignedInEvent(account: account), - session: Session(account: account, data: extra), + AuthenticationSession.fromEvent( + SignedInEvent(account: account), + data: extra, ), ); expect(state.status, AuthenticationStatus.authenticated); - expect(state.wrapper?.session?.account, account); - expect(state.wrapper?.session?.data, extra); + expect(state.session?.account, account); + expect(state.session?.data, extra); }); }); }); diff --git a/packages/wyatt_authentication_bloc/test/email_verification/email_verification_cubit_test.dart b/packages/wyatt_authentication_bloc/test/email_verification/email_verification_cubit_test.dart index e1000d56..c6b944c5 100644 --- a/packages/wyatt_authentication_bloc/test/email_verification/email_verification_cubit_test.dart +++ b/packages/wyatt_authentication_bloc/test/email_verification/email_verification_cubit_test.dart @@ -43,13 +43,24 @@ void main() { when(() => authenticationRepository.sessionStream()).thenAnswer( (_) => Stream.fromIterable([ - SessionWrapper( - event: SignedInFromCacheEvent(account: account), - session: Session(account: account, data: 10), + AuthenticationSession.fromEvent( + SignedInFromCacheEvent(account: account), + data: 10, ) ]), ); + when( + () => authenticationRepository.currentSession(), + ).thenAnswer( + (_) async => Ok( + AuthenticationSession.fromEvent( + SignedInFromCacheEvent(account: account), + data: 10, + ), + ), + ); + when( () => authenticationRepository.refresh(), ).thenAnswer((_) async => Ok(account)); -- 2.47.2 From eb4ae834c17321500433bd5e5337c34a8c7c6e1f Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Wed, 8 Feb 2023 16:09:26 +0100 Subject: [PATCH 20/47] fix(authentication): make sur access token is available on every steps --- .../sign_in/blocs/sign_in_cubit.dart | 2 +- ...hentication_firebase_data_source_impl.dart | 46 +++++++------------ .../lib/src/data/models/account_model.dart | 12 +++-- 3 files changed, 26 insertions(+), 34 deletions(-) diff --git a/packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/sign_in/blocs/sign_in_cubit.dart b/packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/sign_in/blocs/sign_in_cubit.dart index 947295c2..f8ad2ba2 100644 --- a/packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/sign_in/blocs/sign_in_cubit.dart +++ b/packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/sign_in/blocs/sign_in_cubit.dart @@ -27,7 +27,7 @@ class ExampleSignInCubit extends SignInCubit { @override FutureOrResult onSignInWithEmailAndPassword( Result result, WyattForm form) { - print('onSignInWithEmailAndPassword'); + print('onSignInWithEmailAndPassword: ${result.ok?.accessToken}'); return const Ok(1); } diff --git a/packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/authentication_firebase_data_source_impl.dart b/packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/authentication_firebase_data_source_impl.dart index f745e8cf..de644d5e 100644 --- a/packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/authentication_firebase_data_source_impl.dart +++ b/packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/authentication_firebase_data_source_impl.dart @@ -72,11 +72,15 @@ class AuthenticationFirebaseDataSourceImpl return; } - Account _addToStream( + Future _addToCredentialStream( UserCredential userCredential, - AuthenticationChangeEvent Function(Account account) eventBuilder, - ) { - final account = AccountModel.fromFirebaseUserCredential(userCredential); + ) async { + final currentUser = _firebaseAuth.currentUser; + final jwt = await currentUser?.getIdToken(true); + final account = AccountModel.fromFirebaseUserCredential( + userCredential, + accessToken: jwt, + ); _latestCredentials.add(userCredential); @@ -114,12 +118,7 @@ class AuthenticationFirebaseDataSourceImpl password: password, ); - return _addToStream( - userCredential, - (account) => SignedUpEvent( - account: account, - ), - ); + return _addToCredentialStream(userCredential); } on FirebaseAuthException catch (e) { throw SignUpWithEmailAndPasswordFailureFirebase.fromCode(e.code); } catch (_) { @@ -139,12 +138,7 @@ class AuthenticationFirebaseDataSourceImpl password: password, ); - return _addToStream( - userCredential, - (account) => SignedInEvent( - account: account, - ), - ); + return _addToCredentialStream(userCredential); } on FirebaseAuthException catch (e) { throw SignInWithEmailAndPasswordFailureFirebase.fromCode(e.code); } catch (_) { @@ -158,12 +152,7 @@ class AuthenticationFirebaseDataSourceImpl try { final userCredential = await _firebaseAuth.signInAnonymously(); - return _addToStream( - userCredential, - (account) => SignedInEvent( - account: account, - ), - ); + return _addToCredentialStream(userCredential); } on FirebaseAuthException catch (e) { throw SignInAnonymouslyFailureFirebase.fromCode(e.code); } catch (_) { @@ -191,12 +180,7 @@ class AuthenticationFirebaseDataSourceImpl final userCredential = await _firebaseAuth.signInWithCredential(credential); - return _addToStream( - userCredential, - (account) => SignedInEvent( - account: account, - ), - ); + return _addToCredentialStream(userCredential); } on FirebaseAuthException catch (e) { throw SignInWithGoogleFailureFirebase.fromCode(e.code); } catch (_) { @@ -248,7 +232,11 @@ class AuthenticationFirebaseDataSourceImpl throw Exception(); // Get caught just after. } - final account = AccountModel.fromFirebaseUser(_firebaseAuth.currentUser); + final jwt = await _firebaseAuth.currentUser?.getIdToken(true); + final account = AccountModel.fromFirebaseUser( + _firebaseAuth.currentUser, + accessToken: jwt, + ); return account; } on FirebaseAuthException catch (e) { diff --git a/packages/wyatt_authentication_bloc/lib/src/data/models/account_model.dart b/packages/wyatt_authentication_bloc/lib/src/data/models/account_model.dart index c79d54e8..cca70988 100644 --- a/packages/wyatt_authentication_bloc/lib/src/data/models/account_model.dart +++ b/packages/wyatt_authentication_bloc/lib/src/data/models/account_model.dart @@ -21,8 +21,9 @@ import 'package:wyatt_authentication_bloc/src/domain/entities/account.dart'; /// Account Model to parse Firebase User data class AccountModel extends Account { factory AccountModel.fromFirebaseUserCredential( - UserCredential? userCredential, - ) { + UserCredential? userCredential, { + required String? accessToken, + }) { final user = userCredential?.user; if (user != null) { final providerId = @@ -39,14 +40,17 @@ class AccountModel extends Account { email: user.email, phoneNumber: user.phoneNumber, photoURL: user.photoURL, - accessToken: userCredential?.credential?.accessToken, + accessToken: accessToken, ); } else { throw ModelParsingFailureFirebase('null-user', 'User cannot be null'); } } - factory AccountModel.fromFirebaseUser(User? user, {String? accessToken}) { + factory AccountModel.fromFirebaseUser( + User? user, { + required String? accessToken, + }) { if (user != null) { final providerId = (user.providerData.isEmpty) ? '' : user.providerData.first.providerId; -- 2.47.2 From 5a7930550d44a181e5d47b648cb7e5c7c78cc42c Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Wed, 8 Mar 2023 12:55:30 +0100 Subject: [PATCH 21/47] style(authentication): dart format + add some docs --- .../lib/src/core/constants/form_field.dart | 2 ++ .../lib/src/core/constants/form_name.dart | 3 +++ .../src/core/enums/authentication_status.dart | 2 ++ .../core/extensions/build_context_extension.dart | 4 ++-- .../lib/src/core/utils/custom_routine.dart | 16 +++++++++++++--- .../lib/src/core/utils/forms.dart | 5 +++++ .../lib/src/data/models/account_model.dart | 6 ++++++ .../lib/src/domain/entities/account.dart | 5 ++++- .../lib/src/domain/entities/auth_session.dart | 9 +++++++++ .../authenticated_change_event.dart | 5 ++++- .../authentication_change_event.dart | 3 +++ .../deleted_event.dart | 3 +++ .../reauthenticated_event.dart | 3 +++ .../refreshed_event.dart | 3 +++ .../signed_in_event.dart | 3 +++ .../signed_in_from_cache_event.dart | 3 +++ .../signed_out_event.dart | 3 +++ .../signed_up_event.dart | 3 +++ .../unknown_authentication_event.dart | 3 +++ .../updated_event.dart | 3 +++ .../builder/authentication_builder.dart | 9 +++++++++ .../cubit/authentication_state.dart | 10 ++++++++++ .../cubit/base_edit_account_cubit.dart | 5 +++++ .../edit_account/cubit/edit_account_cubit.dart | 3 +++ .../edit_account/cubit/edit_account_state.dart | 7 +++++++ .../listener/edit_account_listener.dart | 13 +++++++++++++ .../builder/email_verification_builder.dart | 11 +++++++++++ .../cubit/email_verification_cubit.dart | 5 +++++ .../cubit/email_verification_state.dart | 9 +++++++++ .../cubit/password_reset_cubit.dart | 5 +++++ .../cubit/password_reset_state.dart | 6 ++++++ .../sign_in/cubit/base_sign_in_cubit.dart | 7 ++++++- .../features/sign_in/cubit/sign_in_cubit.dart | 6 ++++-- .../features/sign_in/cubit/sign_in_state.dart | 7 +++++++ .../sign_in/listener/sign_in_listener.dart | 15 ++++++++++++++- .../sign_up/cubit/base_sign_up_cubit.dart | 7 ++++++- .../features/sign_up/cubit/sign_up_cubit.dart | 5 ++++- .../features/sign_up/cubit/sign_up_state.dart | 8 +++++++- .../sign_up/listener/sign_up_listener.dart | 15 ++++++++++++++- 39 files changed, 225 insertions(+), 15 deletions(-) diff --git a/packages/wyatt_authentication_bloc/lib/src/core/constants/form_field.dart b/packages/wyatt_authentication_bloc/lib/src/core/constants/form_field.dart index bbfc22e8..590e9ae6 100644 --- a/packages/wyatt_authentication_bloc/lib/src/core/constants/form_field.dart +++ b/packages/wyatt_authentication_bloc/lib/src/core/constants/form_field.dart @@ -18,8 +18,10 @@ abstract class AuthFormField { /// Email field: `wyattEmailField` static const email = 'wyattEmailField'; + /// Password field: `wyattPasswordField` static const password = 'wyattPasswordField'; + /// Confirm Password field: `wyattConfirmPasswordField` static const confirmPassword = 'wyattConfirmPasswordField'; } diff --git a/packages/wyatt_authentication_bloc/lib/src/core/constants/form_name.dart b/packages/wyatt_authentication_bloc/lib/src/core/constants/form_name.dart index 16f58cf0..17281b1e 100644 --- a/packages/wyatt_authentication_bloc/lib/src/core/constants/form_name.dart +++ b/packages/wyatt_authentication_bloc/lib/src/core/constants/form_name.dart @@ -18,10 +18,13 @@ abstract class AuthFormName { /// Sign Up form: `wyattSignUpForm` static const String signUpForm = 'wyattSignUpForm'; + /// Sign In form: `wyattSignInForm` static const String signInForm = 'wyattSignInForm'; + /// Password reset form: `wyattPasswordResetForm` static const String passwordResetForm = 'wyattPasswordResetForm'; + /// Edit account form: `wyattEditAccountForm` static const String editAccountForm = 'wyattEditAccountForm'; } diff --git a/packages/wyatt_authentication_bloc/lib/src/core/enums/authentication_status.dart b/packages/wyatt_authentication_bloc/lib/src/core/enums/authentication_status.dart index b88a7407..4a96cc46 100644 --- a/packages/wyatt_authentication_bloc/lib/src/core/enums/authentication_status.dart +++ b/packages/wyatt_authentication_bloc/lib/src/core/enums/authentication_status.dart @@ -18,8 +18,10 @@ enum AuthenticationStatus { /// At the application launch. unknown, + /// When the user is logged authenticated, + /// When the user is not logged unauthenticated, } diff --git a/packages/wyatt_authentication_bloc/lib/src/core/extensions/build_context_extension.dart b/packages/wyatt_authentication_bloc/lib/src/core/extensions/build_context_extension.dart index 83a4867c..d473dace 100644 --- a/packages/wyatt_authentication_bloc/lib/src/core/extensions/build_context_extension.dart +++ b/packages/wyatt_authentication_bloc/lib/src/core/extensions/build_context_extension.dart @@ -21,8 +21,8 @@ import 'package:wyatt_authentication_bloc/src/domain/entities/auth_session.dart' import 'package:wyatt_authentication_bloc/src/domain/entities/authentication_change_event/authentication_change_event.dart'; import 'package:wyatt_authentication_bloc/src/features/authentication/cubit/authentication_cubit.dart'; -/// Extension that helps to quickly access useful resources like wrapper, -/// session, account or data. +/// Extension that helps to quickly access useful resources +/// from the context. extension BuildContextExtension on BuildContext { /// Read session in context from a specific AuthenticationCubit type [T] AuthenticationSession? diff --git a/packages/wyatt_authentication_bloc/lib/src/core/utils/custom_routine.dart b/packages/wyatt_authentication_bloc/lib/src/core/utils/custom_routine.dart index bdd1eb7a..ff58f8df 100644 --- a/packages/wyatt_authentication_bloc/lib/src/core/utils/custom_routine.dart +++ b/packages/wyatt_authentication_bloc/lib/src/core/utils/custom_routine.dart @@ -20,10 +20,12 @@ import 'dart:async'; import 'package:wyatt_architecture/wyatt_architecture.dart'; import 'package:wyatt_type_utils/wyatt_type_utils.dart'; -/// Calls on each cubit action of this package. -/// -/// Useful to register custom logic on pre-implemented logic. +/// {@template custom_routine} +/// A custom routine that can be used to call a routine and +/// attach custom logic to it. +/// {@endtemplate} class CustomRoutine { + /// {@macro custom_routine} const CustomRoutine({ required this.routine, required this.attachedLogic, @@ -31,13 +33,21 @@ class CustomRoutine { required this.onSuccess, }); + /// The routine to be called final FutureOr> Function() routine; + + /// The custom logic to be attached to the routine final FutureOr> Function( Result routineResult, ) attachedLogic; + + /// The callback to be called when an error occurs final void Function(AppException exception) onError; + + /// The callback to be called when no error occurs final void Function(R result, Data? data) onSuccess; + /// Calls the routine and calls the custom attached logic FutureOr call() async { final result = await routine.call(); diff --git a/packages/wyatt_authentication_bloc/lib/src/core/utils/forms.dart b/packages/wyatt_authentication_bloc/lib/src/core/utils/forms.dart index f8f8bf17..ec95768b 100644 --- a/packages/wyatt_authentication_bloc/lib/src/core/utils/forms.dart +++ b/packages/wyatt_authentication_bloc/lib/src/core/utils/forms.dart @@ -17,7 +17,9 @@ import 'package:wyatt_authentication_bloc/wyatt_authentication_bloc.dart'; import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; +/// This class contains all the forms used in the authentication process. abstract class Forms { + /// Builds a sign in form. static WyattForm buildSignInForm( FormInputValidator? customEmailValidator, FormInputValidator? customPasswordValidator, @@ -36,6 +38,7 @@ abstract class Forms { name: AuthFormName.signInForm, ); + /// Builds a sign up form. static WyattForm buildSignUpForm( FormInputValidator? customEmailValidator, FormInputValidator? customPasswordValidator, @@ -57,6 +60,7 @@ abstract class Forms { name: AuthFormName.signUpForm, ); + /// Builds a password reset form. static WyattForm buildPasswordResetForm( FormInputValidator? customEmailValidator, ) => @@ -70,6 +74,7 @@ abstract class Forms { name: AuthFormName.passwordResetForm, ); + /// Builds an edit account form. static WyattForm buildEditAccountForm( FormInputValidator? customEmailValidator, FormInputValidator? customPasswordValidator, diff --git a/packages/wyatt_authentication_bloc/lib/src/data/models/account_model.dart b/packages/wyatt_authentication_bloc/lib/src/data/models/account_model.dart index cca70988..ebc29f93 100644 --- a/packages/wyatt_authentication_bloc/lib/src/data/models/account_model.dart +++ b/packages/wyatt_authentication_bloc/lib/src/data/models/account_model.dart @@ -18,8 +18,11 @@ import 'package:firebase_auth/firebase_auth.dart'; import 'package:wyatt_authentication_bloc/src/core/exceptions/exceptions.dart'; import 'package:wyatt_authentication_bloc/src/domain/entities/account.dart'; +/// {@template account_model} /// Account Model to parse Firebase User data +/// {@endtemplate} class AccountModel extends Account { + /// {@macro account_model} factory AccountModel.fromFirebaseUserCredential( UserCredential? userCredential, { required String? accessToken, @@ -47,6 +50,7 @@ class AccountModel extends Account { } } + /// {@macro account_model} factory AccountModel.fromFirebaseUser( User? user, { required String? accessToken, @@ -72,6 +76,7 @@ class AccountModel extends Account { throw ModelParsingFailureFirebase('null-user', 'User cannot be null'); } } + const AccountModel._({ required this.user, required super.id, @@ -87,6 +92,7 @@ class AccountModel extends Account { super.accessToken, }); + /// The Firebase User final User? user; @override diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/entities/account.dart b/packages/wyatt_authentication_bloc/lib/src/domain/entities/account.dart index ee6cd353..c0186496 100644 --- a/packages/wyatt_authentication_bloc/lib/src/domain/entities/account.dart +++ b/packages/wyatt_authentication_bloc/lib/src/domain/entities/account.dart @@ -17,9 +17,12 @@ import 'package:equatable/equatable.dart'; import 'package:wyatt_architecture/wyatt_architecture.dart'; -/// Represents a user [Account] in the +/// {@template account} +/// Represents a user [Account] in the /// various identity provisioning systems. +/// {@endtemplate} class Account extends Equatable implements Entity { + /// {@macro account} const Account({ required this.id, required this.isAnonymous, diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/entities/auth_session.dart b/packages/wyatt_authentication_bloc/lib/src/domain/entities/auth_session.dart index a5a37cf2..bdcbff74 100644 --- a/packages/wyatt_authentication_bloc/lib/src/domain/entities/auth_session.dart +++ b/packages/wyatt_authentication_bloc/lib/src/domain/entities/auth_session.dart @@ -17,16 +17,20 @@ import 'package:equatable/equatable.dart'; import 'package:wyatt_authentication_bloc/wyatt_authentication_bloc.dart'; +/// {@template authentication_session} /// The [AuthenticationSession] object is used to transport and propagate /// the last event issued by an authentication state change, a user account /// if connected, and the associated data. +/// {@endtemplate} class AuthenticationSession extends Equatable { + /// {@macro authentication_session} const AuthenticationSession({ required this.latestEvent, this.account, this.data, }); + /// Creates a new [AuthenticationSession] from an [AuthenticationChangeEvent]. factory AuthenticationSession.fromEvent( AuthenticationChangeEvent latestEvent, { Data? data, @@ -44,8 +48,13 @@ class AuthenticationSession extends Equatable { ); } + /// The last event issued by an authentication state change. final AuthenticationChangeEvent latestEvent; + + /// The user account if connected. final Account? account; + + /// The associated data. final Data? data; @override diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/authenticated_change_event.dart b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/authenticated_change_event.dart index 03bb2d50..fb9487dd 100644 --- a/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/authenticated_change_event.dart +++ b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/authenticated_change_event.dart @@ -16,11 +16,14 @@ part of 'authentication_change_event.dart'; - +/// {@template authenticated_change_event} /// Represents every event where user is authenticated. +/// {@endtemplate} abstract class AuthenticatedChangeEvent extends AuthenticationChangeEvent { + /// {@macro authenticated_change_event} const AuthenticatedChangeEvent({required this.account}); + /// The user's account. final Account account; @override diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/authentication_change_event.dart b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/authentication_change_event.dart index 08312b7c..b32b68b4 100644 --- a/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/authentication_change_event.dart +++ b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/authentication_change_event.dart @@ -29,9 +29,12 @@ part 'signed_up_event.dart'; part 'unknown_authentication_event.dart'; part 'updated_event.dart'; +/// {@template authentication_change_event} /// Represents an event initiated by a change in /// the user's authentication status. +/// {@endtemplate} abstract class AuthenticationChangeEvent extends Equatable implements Entity { + /// {@macro authentication_change_event} const AuthenticationChangeEvent(); @override diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/deleted_event.dart b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/deleted_event.dart index 2eff8187..0ab52ae9 100644 --- a/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/deleted_event.dart +++ b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/deleted_event.dart @@ -16,7 +16,10 @@ part of 'authentication_change_event.dart'; +/// {@template deleted_event} /// When a user deleted his account. +/// {@endtemplate} class DeletedEvent extends AuthenticationChangeEvent { + /// {@macro deleted_event} const DeletedEvent(); } diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/reauthenticated_event.dart b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/reauthenticated_event.dart index 4cd8e13c..fa7e066a 100644 --- a/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/reauthenticated_event.dart +++ b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/reauthenticated_event.dart @@ -16,9 +16,12 @@ part of 'authentication_change_event.dart'; +/// {@template reauthenticated_event} /// When a user re-authenticates (from the logged in state to the /// logged in state with a different and fresh access /// token and a different login time) +/// {@endtemplate} class ReauthenticatedEvent extends AuthenticatedChangeEvent { + /// {@macro reauthenticated_event} const ReauthenticatedEvent({required super.account}); } diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/refreshed_event.dart b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/refreshed_event.dart index e2971cc4..f765c3cc 100644 --- a/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/refreshed_event.dart +++ b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/refreshed_event.dart @@ -16,8 +16,11 @@ part of 'authentication_change_event.dart'; +/// {@template refreshed_event} /// When a user access token is refreshed (from the logged in state to the /// logged in state with a different access token) +/// {@endtemplate} class RefreshedEvent extends AuthenticatedChangeEvent { + /// {@macro refreshed_event} const RefreshedEvent({required super.account}); } diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/signed_in_event.dart b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/signed_in_event.dart index 8d2fa0e3..17b2ae3e 100644 --- a/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/signed_in_event.dart +++ b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/signed_in_event.dart @@ -16,7 +16,10 @@ part of 'authentication_change_event.dart'; +/// {@template signed_in_event} /// When a user authenticates (from not logged in to logged in). +/// {@endtemplate} class SignedInEvent extends AuthenticatedChangeEvent { + /// {@macro signed_in_event} const SignedInEvent({required super.account}); } diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/signed_in_from_cache_event.dart b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/signed_in_from_cache_event.dart index a4e57dda..01bf868d 100644 --- a/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/signed_in_from_cache_event.dart +++ b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/signed_in_from_cache_event.dart @@ -16,7 +16,10 @@ part of 'authentication_change_event.dart'; +/// {@template signed_in_from_cache_event} /// When a user authenticates automatically (from not logged in to logged in). +/// {@endtemplate} class SignedInFromCacheEvent extends AuthenticatedChangeEvent { + /// {@macro signed_in_from_cache_event} const SignedInFromCacheEvent({required super.account}); } diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/signed_out_event.dart b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/signed_out_event.dart index e7579097..dc4ea4cd 100644 --- a/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/signed_out_event.dart +++ b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/signed_out_event.dart @@ -16,7 +16,10 @@ part of 'authentication_change_event.dart'; +/// {@template signed_out_event} /// When a user logs out. +/// {@endtemplate} class SignedOutEvent extends AuthenticationChangeEvent { + /// {@macro signed_out_event} const SignedOutEvent(); } diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/signed_up_event.dart b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/signed_up_event.dart index 903adbf1..f95f7e5e 100644 --- a/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/signed_up_event.dart +++ b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/signed_up_event.dart @@ -16,7 +16,10 @@ part of 'authentication_change_event.dart'; +/// {@template signed_up_event} /// When a user creates an account. +/// {@endtemplate} class SignedUpEvent extends AuthenticatedChangeEvent { + /// {@macro signed_up_event} const SignedUpEvent({required super.account}); } diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/unknown_authentication_event.dart b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/unknown_authentication_event.dart index 93c56dec..287b53a0 100644 --- a/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/unknown_authentication_event.dart +++ b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/unknown_authentication_event.dart @@ -16,7 +16,10 @@ part of 'authentication_change_event.dart'; +/// {@template unknown_authentication_event} /// When a user's login status is unknown. +/// {@endtemplate} class UnknownAuthenticationEvent extends AuthenticationChangeEvent { + /// {@macro unknown_authentication_event} const UnknownAuthenticationEvent(); } diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/updated_event.dart b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/updated_event.dart index 117cc725..2178a56e 100644 --- a/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/updated_event.dart +++ b/packages/wyatt_authentication_bloc/lib/src/domain/entities/authentication_change_event/updated_event.dart @@ -16,7 +16,10 @@ part of 'authentication_change_event.dart'; +/// {@template updated_event} /// When the user's account has been updated. +/// {@endtemplate} class UpdatedEvent extends AuthenticatedChangeEvent { + /// {@macro updated_event} const UpdatedEvent({required super.account}); } diff --git a/packages/wyatt_authentication_bloc/lib/src/features/authentication/builder/authentication_builder.dart b/packages/wyatt_authentication_bloc/lib/src/features/authentication/builder/authentication_builder.dart index 3c9f1999..46eb0a57 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/authentication/builder/authentication_builder.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/authentication/builder/authentication_builder.dart @@ -20,7 +20,11 @@ import 'package:wyatt_authentication_bloc/src/core/enums/authentication_status.d import 'package:wyatt_authentication_bloc/src/domain/entities/auth_session.dart'; import 'package:wyatt_authentication_bloc/src/features/authentication/cubit/authentication_cubit.dart'; +/// {@template authentication_builder} +/// A widget that builds itself based on the current authentication state. +/// {@endtemplate} class AuthenticationBuilder extends StatelessWidget { + /// {@macro authentication_builder} const AuthenticationBuilder({ required this.authenticated, required this.unauthenticated, @@ -28,11 +32,16 @@ class AuthenticationBuilder extends StatelessWidget { super.key, }); + /// Widget to show when the user is authenticated. final Widget Function( BuildContext context, AuthenticationSession session, ) authenticated; + + /// Widget to show when the user is unauthenticated. final Widget Function(BuildContext context) unauthenticated; + + /// Widget to show when the authentication status is unknown. final Widget Function(BuildContext context) unknown; @override diff --git a/packages/wyatt_authentication_bloc/lib/src/features/authentication/cubit/authentication_state.dart b/packages/wyatt_authentication_bloc/lib/src/features/authentication/cubit/authentication_state.dart index 1f3a1c72..8a51d674 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/authentication/cubit/authentication_state.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/authentication/cubit/authentication_state.dart @@ -16,22 +16,32 @@ part of 'authentication_cubit.dart'; +/// {@template authentication_status} +/// The status of the authentication cubit. +/// {@endtemplate} class AuthenticationState extends Equatable { + /// {@macro authentication_status} const AuthenticationState._(this.status, this.session); + /// The user is not authenticated. const AuthenticationState.unauthenticated() : this._(AuthenticationStatus.unauthenticated, null); + /// The user is authenticated. const AuthenticationState.authenticated(AuthenticationSession session) : this._( AuthenticationStatus.authenticated, session, ); + /// The user's authentication status is unknown. const AuthenticationState.unknown() : this._(AuthenticationStatus.unknown, null); + /// The status of the authentication cubit. final AuthenticationStatus status; + + /// The session of the authentication cubit. final AuthenticationSession? session; @override diff --git a/packages/wyatt_authentication_bloc/lib/src/features/edit_account/cubit/base_edit_account_cubit.dart b/packages/wyatt_authentication_bloc/lib/src/features/edit_account/cubit/base_edit_account_cubit.dart index 3d6ba12d..119e16fd 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/edit_account/cubit/base_edit_account_cubit.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/edit_account/cubit/base_edit_account_cubit.dart @@ -16,10 +16,13 @@ part of 'edit_account_cubit.dart'; +/// {@template edit_account_cubit} /// Abstract edit account cubit useful for implementing a cubit with fine /// granularity by adding only the required mixins. +/// {@endtemplate} abstract class BaseEditAccountCubit extends FormDataCubit { + /// {@macro edit_account_cubit} BaseEditAccountCubit({ required this.authenticationRepository, }) : super( @@ -28,6 +31,8 @@ abstract class BaseEditAccountCubit .accessForm(AuthFormName.signInForm), ), ); + + /// The authentication repository. final AuthenticationRepository authenticationRepository; FormRepository get formRepository => authenticationRepository.formRepository; diff --git a/packages/wyatt_authentication_bloc/lib/src/features/edit_account/cubit/edit_account_cubit.dart b/packages/wyatt_authentication_bloc/lib/src/features/edit_account/cubit/edit_account_cubit.dart index b3fcc2b2..abc378cc 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/edit_account/cubit/edit_account_cubit.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/edit_account/cubit/edit_account_cubit.dart @@ -28,11 +28,14 @@ import 'package:wyatt_type_utils/wyatt_type_utils.dart'; part 'base_edit_account_cubit.dart'; part 'edit_account_state.dart'; +/// {@template edit_account_cubit} /// Fully featured edit account cubit. /// /// Sufficient in most cases. (Where fine granularity is not required.) +/// {@endtemplate} class EditAccountCubit extends BaseEditAccountCubit with UpdateEmail, UpdatePassword { + /// {@macro edit_account_cubit} EditAccountCubit({required super.authenticationRepository}); @override diff --git a/packages/wyatt_authentication_bloc/lib/src/features/edit_account/cubit/edit_account_state.dart b/packages/wyatt_authentication_bloc/lib/src/features/edit_account/cubit/edit_account_state.dart index 0c8fbfba..d7dd5032 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/edit_account/cubit/edit_account_state.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/edit_account/cubit/edit_account_state.dart @@ -16,15 +16,22 @@ part of 'edit_account_cubit.dart'; +/// {@template edit_account_state} /// Edit account cubit state to manage the form. +/// {@endtemplate} class EditAccountState extends FormDataState { + /// {@macro edit_account_state} const EditAccountState({ required super.form, super.status = FormStatus.pure, super.errorMessage, }); + + /// Email validator of the form FormInputValidator get email => form.validatorOf(AuthFormField.email); + + /// Password validator of the form FormInputValidator get password => form.validatorOf(AuthFormField.password); diff --git a/packages/wyatt_authentication_bloc/lib/src/features/edit_account/listener/edit_account_listener.dart b/packages/wyatt_authentication_bloc/lib/src/features/edit_account/listener/edit_account_listener.dart index 62134eb5..9adcb5ec 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/edit_account/listener/edit_account_listener.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/edit_account/listener/edit_account_listener.dart @@ -19,9 +19,12 @@ import 'package:flutter_bloc/flutter_bloc.dart'; import 'package:wyatt_authentication_bloc/src/features/edit_account/cubit/edit_account_cubit.dart'; import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; +/// {@template edit_account_listener} /// Widget that listens and builds a child based on the state of /// the edit account cubit +/// {@endtemplate} class EditAccountListener extends StatelessWidget { + /// {@macro edit_account_listener} const EditAccountListener({ required this.child, this.onProgress, @@ -31,15 +34,25 @@ class EditAccountListener extends StatelessWidget { super.key, }); + /// Callback to show when the edit account is in progress final void Function(BuildContext context)? onProgress; + + /// Callback to show when the edit account is successful final void Function(BuildContext context)? onSuccess; + + /// Callback to show when the edit account is unsuccessful final void Function( BuildContext context, FormStatus status, String? errorMessage, )? onError; + + /// Custom builder to show when the edit account is in progress, successful, + /// or unsuccessful final void Function(BuildContext context, EditAccountState state)? customBuilder; + + /// Child of the widget final Widget child; @override diff --git a/packages/wyatt_authentication_bloc/lib/src/features/email_verification/builder/email_verification_builder.dart b/packages/wyatt_authentication_bloc/lib/src/features/email_verification/builder/email_verification_builder.dart index 0de3bdf3..c030260d 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/email_verification/builder/email_verification_builder.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/email_verification/builder/email_verification_builder.dart @@ -19,7 +19,11 @@ import 'package:flutter_bloc/flutter_bloc.dart'; import 'package:wyatt_authentication_bloc/src/features/email_verification/cubit/email_verification_cubit.dart'; import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; +/// {@template email_verification_builder} +/// A widget that builds itself based on the latest [EmailVerificationState]. +/// {@endtemplate} class EmailVerificationBuilder extends StatelessWidget { + /// {@macro email_verification_builder} const EmailVerificationBuilder({ required this.verified, required this.notVerified, @@ -28,14 +32,21 @@ class EmailVerificationBuilder extends StatelessWidget { super.key, }); + /// Widget to show when the email is verified final Widget Function(BuildContext context) verified; + + /// Widget to show when the email is not verified final Widget Function(BuildContext context) notVerified; + + /// Widget to show when the email verification is unsuccessful final Widget Function( BuildContext context, FormStatus status, String? errorMessage, ) onError; + /// Custom builder to show when the email is verified, not verified, or + /// unsuccessful final Widget Function(BuildContext context, EmailVerificationState)? customBuilder; diff --git a/packages/wyatt_authentication_bloc/lib/src/features/email_verification/cubit/email_verification_cubit.dart b/packages/wyatt_authentication_bloc/lib/src/features/email_verification/cubit/email_verification_cubit.dart index 56297baa..92227e52 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/email_verification/cubit/email_verification_cubit.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/email_verification/cubit/email_verification_cubit.dart @@ -23,11 +23,16 @@ import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; part 'email_verification_state.dart'; +/// {@template email_verification_cubit} +/// Cubit for sending email verification. +/// {@endtemplate} class EmailVerificationCubit extends Cubit { + /// {@macro email_verification_cubit} EmailVerificationCubit({ required this.authenticationRepository, }) : super(const EmailVerificationState()); + /// The [AuthenticationRepository] used to send email verification. final AuthenticationRepository authenticationRepository; FutureOr sendEmailVerification() async { diff --git a/packages/wyatt_authentication_bloc/lib/src/features/email_verification/cubit/email_verification_state.dart b/packages/wyatt_authentication_bloc/lib/src/features/email_verification/cubit/email_verification_state.dart index aa12191d..22ac24c7 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/email_verification/cubit/email_verification_state.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/email_verification/cubit/email_verification_state.dart @@ -16,15 +16,24 @@ part of 'email_verification_cubit.dart'; +/// {@template email_verification_state} +/// The state of the [EmailVerificationCubit]. +/// {@endtemplate} class EmailVerificationState extends Equatable { + /// {@macro email_verification_state} const EmailVerificationState({ this.isVerified = false, this.status = FormStatus.pure, this.errorMessage, }); + /// The status of the form. final FormStatus status; + + /// Whether the email is verified. final bool isVerified; + + /// The error message if any. final String? errorMessage; EmailVerificationState copyWith({ diff --git a/packages/wyatt_authentication_bloc/lib/src/features/password_reset/cubit/password_reset_cubit.dart b/packages/wyatt_authentication_bloc/lib/src/features/password_reset/cubit/password_reset_cubit.dart index c8624fc6..969528e3 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/password_reset/cubit/password_reset_cubit.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/password_reset/cubit/password_reset_cubit.dart @@ -24,8 +24,11 @@ import 'package:wyatt_type_utils/wyatt_type_utils.dart'; part 'password_reset_state.dart'; +/// {@template password_reset_cubit} /// Cubit that allows user to reset his password +/// {@endtemplate} class PasswordResetCubit extends FormDataCubit { + /// {@macro password_reset_cubit} PasswordResetCubit({ required this.authenticationRepository, }) : super( @@ -34,6 +37,8 @@ class PasswordResetCubit extends FormDataCubit { .accessForm(AuthFormName.passwordResetForm), ), ); + + /// The repository that handles the authentication final AuthenticationRepository authenticationRepository; FormRepository get formRepository => authenticationRepository.formRepository; diff --git a/packages/wyatt_authentication_bloc/lib/src/features/password_reset/cubit/password_reset_state.dart b/packages/wyatt_authentication_bloc/lib/src/features/password_reset/cubit/password_reset_state.dart index cace663f..eafbf6b6 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/password_reset/cubit/password_reset_state.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/password_reset/cubit/password_reset_state.dart @@ -16,12 +16,18 @@ part of 'password_reset_cubit.dart'; +/// {@template password_reset_state} +/// The state of the [PasswordResetCubit]. +/// {@endtemplate} class PasswordResetState extends FormDataState { + /// {@macro password_reset_state} const PasswordResetState({ required super.form, super.status = FormStatus.pure, super.errorMessage, }); + + /// The email validator of the form. Email get email => form.validatorOf(AuthFormField.email); PasswordResetState copyWith({ diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/base_sign_in_cubit.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/base_sign_in_cubit.dart index bc55b6a8..3d59bee5 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/base_sign_in_cubit.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/base_sign_in_cubit.dart @@ -16,9 +16,12 @@ part of 'sign_in_cubit.dart'; -/// Abstract sign in cubit useful for implementing a cubit with fine +/// {@template sign_in_cubit} +/// Abstract sign in cubit useful for implementing a cubit with fine /// granularity by adding only the required mixins. +/// {@endtemplate} abstract class BaseSignInCubit extends FormDataCubit { + /// {@macro sign_in_cubit} BaseSignInCubit({ required this.authenticationRepository, }) : super( @@ -27,6 +30,8 @@ abstract class BaseSignInCubit extends FormDataCubit { .accessForm(AuthFormName.signInForm), ), ); + + /// The authentication repository. final AuthenticationRepository authenticationRepository; FormRepository get formRepository => authenticationRepository.formRepository; diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/sign_in_cubit.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/sign_in_cubit.dart index f1f3ccd5..fbde339c 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/sign_in_cubit.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/sign_in_cubit.dart @@ -14,7 +14,6 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . - import 'dart:async'; import 'package:wyatt_architecture/wyatt_architecture.dart'; @@ -31,14 +30,17 @@ import 'package:wyatt_type_utils/wyatt_type_utils.dart'; part 'base_sign_in_cubit.dart'; part 'sign_in_state.dart'; +/// {@template sign_in_cubit} /// Fully featured sign in cubit. -/// +/// /// Sufficient in most cases. (Where fine granularity is not required.) +/// {@endtemplate} class SignInCubit extends BaseSignInCubit with SignInAnonymously, SignInWithEmailPassword, SignInWithGoogle { + /// {@macro sign_in_cubit} SignInCubit({required super.authenticationRepository}); @override diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/sign_in_state.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/sign_in_state.dart index acb975b5..39ed623f 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/sign_in_state.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/cubit/sign_in_state.dart @@ -16,15 +16,22 @@ part of 'sign_in_cubit.dart'; +/// {@template sign_in_state} /// Sign in cubit state to manage the form. +/// {@endtemplate} class SignInState extends FormDataState { + /// {@macro sign_in_state} const SignInState({ required super.form, super.status = FormStatus.pure, super.errorMessage, }); + + /// Email validator of the form FormInputValidator get email => form.validatorOf(AuthFormField.email); + + /// Password validator of the form FormInputValidator get password => form.validatorOf(AuthFormField.password); diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/listener/sign_in_listener.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/listener/sign_in_listener.dart index cc66ac36..2d55fe16 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/sign_in/listener/sign_in_listener.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_in/listener/sign_in_listener.dart @@ -19,9 +19,12 @@ import 'package:flutter_bloc/flutter_bloc.dart'; import 'package:wyatt_authentication_bloc/src/features/sign_in/sign_in.dart'; import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; -/// Widget that listens and builds a child based on the state of +/// {@template sign_in_listener} +/// Widget that listens and builds a child based on the state of /// the sign in cubit +/// {@endtemplate} class SignInListener extends StatelessWidget { + /// {@macro sign_in_listener} const SignInListener({ required this.child, this.onProgress, @@ -31,14 +34,24 @@ class SignInListener extends StatelessWidget { super.key, }); + /// Callback to show when the sign in is in progress final void Function(BuildContext context)? onProgress; + + /// Callback to show when the sign in is successful final void Function(BuildContext context)? onSuccess; + + /// Callback to show when the sign in is unsuccessful final void Function( BuildContext context, FormStatus status, String? errorMessage, )? onError; + + /// Custom builder to show when the sign in is in progress, successful, or + /// unsuccessful final void Function(BuildContext context, SignInState state)? customBuilder; + + /// Child of the widget final Widget child; @override diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/base_sign_up_cubit.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/base_sign_up_cubit.dart index 42747ce3..3691f4c5 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/base_sign_up_cubit.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/base_sign_up_cubit.dart @@ -16,9 +16,12 @@ part of 'sign_up_cubit.dart'; -/// Abstract sign up cubit useful for implementing a cubit with fine +/// {@template base_sign_up_cubit} +/// Abstract sign up cubit useful for implementing a cubit with fine /// granularity by adding only the required mixins. +/// {@endtemplate} abstract class BaseSignUpCubit extends FormDataCubit { + /// {@macro base_sign_up_cubit} BaseSignUpCubit({ required this.authenticationRepository, }) : super( @@ -27,6 +30,8 @@ abstract class BaseSignUpCubit extends FormDataCubit { .accessForm(AuthFormName.signUpForm), ), ); + + /// The authentication repository. final AuthenticationRepository authenticationRepository; FormRepository get formRepository => authenticationRepository.formRepository; diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/sign_up_cubit.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/sign_up_cubit.dart index 75c285cf..09a76667 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/sign_up_cubit.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/sign_up_cubit.dart @@ -28,11 +28,14 @@ import 'package:wyatt_type_utils/wyatt_type_utils.dart'; part 'base_sign_up_cubit.dart'; part 'sign_up_state.dart'; +/// {@template sign_up_cubit} /// Fully featured sign up cubit. -/// +/// /// Sufficient in most cases. (Where fine granularity is not required.) +/// {@endtemplate} class SignUpCubit extends BaseSignUpCubit with SignUpWithEmailPassword { + /// {@macro sign_up_cubit} SignUpCubit({required super.authenticationRepository}); @override diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/sign_up_state.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/sign_up_state.dart index a66a3693..ac04efd5 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/sign_up_state.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_up/cubit/sign_up_state.dart @@ -16,15 +16,22 @@ part of 'sign_up_cubit.dart'; +/// {@template sign_up_state} /// Sign up cubit state to manage the form. +/// {@endtemplate} class SignUpState extends FormDataState { + /// {@macro sign_up_state} const SignUpState({ required super.form, super.status = FormStatus.pure, super.errorMessage, }); + + /// Email validator of the form FormInputValidator get email => form.validatorOf(AuthFormField.email); + + /// Password validator of the form FormInputValidator get password => form.validatorOf(AuthFormField.password); @@ -42,7 +49,6 @@ class SignUpState extends FormDataState { @override List get props => [email, password, status, form]; - @override @override String toString() => 'SignUpState(status: ${status.name} ' '${(errorMessage != null) ? " [$errorMessage]" : ""}, $form)'; diff --git a/packages/wyatt_authentication_bloc/lib/src/features/sign_up/listener/sign_up_listener.dart b/packages/wyatt_authentication_bloc/lib/src/features/sign_up/listener/sign_up_listener.dart index 1493df64..b4e5ad39 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/sign_up/listener/sign_up_listener.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/sign_up/listener/sign_up_listener.dart @@ -19,9 +19,12 @@ import 'package:flutter_bloc/flutter_bloc.dart'; import 'package:wyatt_authentication_bloc/src/features/sign_up/cubit/sign_up_cubit.dart'; import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; -/// Widget that listens and builds a child based on the state of +/// {@template sign_up_listener} +/// Widget that listens and builds a child based on the state of /// the sign up cubit +/// {@endtemplate} class SignUpListener extends StatelessWidget { + /// {@macro sign_up_listener} const SignUpListener({ required this.child, this.onProgress, @@ -31,14 +34,24 @@ class SignUpListener extends StatelessWidget { super.key, }); + /// Callback to show when the sign up is in progress final void Function(BuildContext context)? onProgress; + + /// Callback to show when the sign up is successful final void Function(BuildContext context)? onSuccess; + + /// Callback to show when the sign up is unsuccessful final void Function( BuildContext context, FormStatus status, String? errorMessage, )? onError; + + /// Custom builder to show when the sign up is in progress, successful, or + /// unsuccessful final void Function(BuildContext context, SignUpState state)? customBuilder; + + /// Child of the widget final Widget child; @override -- 2.47.2 From d53e7b80da619fb844e6213bc70ba71ba112ccab Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Wed, 8 Mar 2023 12:57:24 +0100 Subject: [PATCH 22/47] refactor(authentication)!: split data sources (cache, session, external) --- .../src/data/data_sources/data_sources.dart | 3 +- ...ation_firebase_cache_data_source_impl.dart | 56 +++++++++++++++++++ ...thentication_session_data_source_impl.dart | 45 +++++++++++++++ .../src/data/data_sources/local/local.dart | 18 ++++++ ...hentication_firebase_data_source_impl.dart | 53 ++---------------- .../src/data/data_sources/remote/remote.dart | 17 ++++++ .../authentication_repository_impl.dart | 54 +++++++++++++++--- .../src/domain/data_sources/data_sources.dart | 3 +- .../authentication_cache_data_source.dart | 40 +++++++++++++ .../authentication_session_data_source.dart | 36 ++++++++++++ .../src/domain/data_sources/local/local.dart | 18 ++++++ .../authentication_remote_data_source.dart | 40 ++++++++++--- .../domain/data_sources/remote/remote.dart | 17 ++++++ .../authentication_repository.dart | 14 ++++- .../cubit/authentication_cubit.dart | 26 ++++++++- 15 files changed, 371 insertions(+), 69 deletions(-) create mode 100644 packages/wyatt_authentication_bloc/lib/src/data/data_sources/local/authentication_firebase_cache_data_source_impl.dart create mode 100644 packages/wyatt_authentication_bloc/lib/src/data/data_sources/local/authentication_session_data_source_impl.dart create mode 100644 packages/wyatt_authentication_bloc/lib/src/data/data_sources/local/local.dart create mode 100644 packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/remote.dart create mode 100644 packages/wyatt_authentication_bloc/lib/src/domain/data_sources/local/authentication_cache_data_source.dart create mode 100644 packages/wyatt_authentication_bloc/lib/src/domain/data_sources/local/authentication_session_data_source.dart create mode 100644 packages/wyatt_authentication_bloc/lib/src/domain/data_sources/local/local.dart create mode 100644 packages/wyatt_authentication_bloc/lib/src/domain/data_sources/remote/remote.dart diff --git a/packages/wyatt_authentication_bloc/lib/src/data/data_sources/data_sources.dart b/packages/wyatt_authentication_bloc/lib/src/data/data_sources/data_sources.dart index 65cebddf..843f681b 100644 --- a/packages/wyatt_authentication_bloc/lib/src/data/data_sources/data_sources.dart +++ b/packages/wyatt_authentication_bloc/lib/src/data/data_sources/data_sources.dart @@ -14,4 +14,5 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . -export 'remote/authentication_firebase_data_source_impl.dart'; +export 'local/local.dart'; +export 'remote/remote.dart'; diff --git a/packages/wyatt_authentication_bloc/lib/src/data/data_sources/local/authentication_firebase_cache_data_source_impl.dart b/packages/wyatt_authentication_bloc/lib/src/data/data_sources/local/authentication_firebase_cache_data_source_impl.dart new file mode 100644 index 00000000..910887c2 --- /dev/null +++ b/packages/wyatt_authentication_bloc/lib/src/data/data_sources/local/authentication_firebase_cache_data_source_impl.dart @@ -0,0 +1,56 @@ +// Copyright (C) 2023 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +import 'package:wyatt_authentication_bloc/src/domain/data_sources/local/authentication_cache_data_source.dart'; +import 'package:wyatt_authentication_bloc/wyatt_authentication_bloc.dart'; + +/// {@template authentication_firebase_cache_data_source_impl} +/// A data source that manages the cache strategy. +/// This implementation uses Firebase. +/// {@endtemplate} +class AuthenticationFirebaseCacheDataSourceImpl + extends AuthenticationCacheDataSource { + /// {@macro authentication_firebase_cache_data_source_impl} + AuthenticationFirebaseCacheDataSourceImpl({ + FirebaseAuth? firebaseAuth, + }) : _firebaseAuth = firebaseAuth ?? FirebaseAuth.instance; + + final FirebaseAuth _firebaseAuth; + + // Already done by Firebase + @override + Future cacheAccount(Account account) => Future.value(); + + @override + Future getCachedAccount() async { + final currentUser = _firebaseAuth.currentUser; + if (currentUser == null) { + return null; + } + + final jwt = await currentUser.getIdToken(true); + final currentAccount = AccountModel.fromFirebaseUser( + currentUser, + accessToken: jwt, + ); + + return currentAccount; + } + + // Already done by Firebase + @override + Future removeCachedAccount() => Future.value(); +} diff --git a/packages/wyatt_authentication_bloc/lib/src/data/data_sources/local/authentication_session_data_source_impl.dart b/packages/wyatt_authentication_bloc/lib/src/data/data_sources/local/authentication_session_data_source_impl.dart new file mode 100644 index 00000000..1287d889 --- /dev/null +++ b/packages/wyatt_authentication_bloc/lib/src/data/data_sources/local/authentication_session_data_source_impl.dart @@ -0,0 +1,45 @@ +// Copyright (C) 2023 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +import 'dart:async'; + +import 'package:rxdart/subjects.dart'; +import 'package:wyatt_authentication_bloc/src/domain/data_sources/local/authentication_session_data_source.dart'; +import 'package:wyatt_authentication_bloc/src/domain/entities/auth_session.dart'; + +/// {@template authentication_session_data_source_impl} +/// A data source that manages the current session. +/// {@endtemplate} +class AuthenticationSessionDataSourceImpl + extends AuthenticationSessionDataSource { + /// {@macro authentication_session_data_source_impl} + AuthenticationSessionDataSourceImpl(); + + final StreamController> _sessionStream = + BehaviorSubject(); + + @override + void addSession(AuthenticationSession session) { + _sessionStream.add(session); + } + + @override + Future> currentSession() => sessionStream().last; + + @override + Stream> sessionStream() => + _sessionStream.stream.asBroadcastStream(); +} diff --git a/packages/wyatt_authentication_bloc/lib/src/data/data_sources/local/local.dart b/packages/wyatt_authentication_bloc/lib/src/data/data_sources/local/local.dart new file mode 100644 index 00000000..ba60b5e6 --- /dev/null +++ b/packages/wyatt_authentication_bloc/lib/src/data/data_sources/local/local.dart @@ -0,0 +1,18 @@ +// Copyright (C) 2023 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +export 'authentication_firebase_cache_data_source_impl.dart'; +export 'authentication_session_data_source_impl.dart'; diff --git a/packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/authentication_firebase_data_source_impl.dart b/packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/authentication_firebase_data_source_impl.dart index de644d5e..f2552b87 100644 --- a/packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/authentication_firebase_data_source_impl.dart +++ b/packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/authentication_firebase_data_source_impl.dart @@ -23,55 +23,27 @@ import 'package:wyatt_authentication_bloc/src/core/exceptions/exceptions.dart'; import 'package:wyatt_authentication_bloc/src/data/models/models.dart'; import 'package:wyatt_authentication_bloc/src/domain/data_sources/remote/authentication_remote_data_source.dart'; import 'package:wyatt_authentication_bloc/src/domain/entities/account.dart'; -import 'package:wyatt_authentication_bloc/src/domain/entities/auth_session.dart'; -import 'package:wyatt_authentication_bloc/src/domain/entities/authentication_change_event/authentication_change_event.dart'; import 'package:wyatt_type_utils/wyatt_type_utils.dart'; +/// {@template authentication_firebase_data_source_impl} +/// Implementation of [AuthenticationRemoteDataSource] using Firebase. +/// {@endtemplate} class AuthenticationFirebaseDataSourceImpl extends AuthenticationRemoteDataSource { + /// {@macro authentication_firebase_data_source_impl} AuthenticationFirebaseDataSourceImpl({ FirebaseAuth? firebaseAuth, GoogleSignIn? googleSignIn, }) : _firebaseAuth = firebaseAuth ?? FirebaseAuth.instance, _googleSignIn = googleSignIn ?? GoogleSignIn() { _latestCredentials = BehaviorSubject(); - _sessionStream = BehaviorSubject(); - - // Check for account in memory (persistence) - _checkForCachedAccount(); } - late StreamController> _sessionStream; late StreamController _latestCredentials; final FirebaseAuth _firebaseAuth; final GoogleSignIn _googleSignIn; - Future _checkForCachedAccount() async { - final currentUser = _firebaseAuth.currentUser; - - if (currentUser == null) { - _sessionStream.add( - const AuthenticationSession( - latestEvent: UnknownAuthenticationEvent(), - ), - ); - return; - } - - final jwt = await currentUser.getIdToken(true); - final currentAccount = AccountModel.fromFirebaseUser( - currentUser, - accessToken: jwt, - ); - _sessionStream.add( - AuthenticationSession.fromEvent( - SignedInFromCacheEvent(account: currentAccount), - ), - ); - return; - } - Future _addToCredentialStream( UserCredential userCredential, ) async { @@ -87,23 +59,6 @@ class AuthenticationFirebaseDataSourceImpl return account; } - // Session related methods =================================================== - - /// {@macro add_session} - @override - void addSession(AuthenticationSession session) { - _sessionStream.add(session); - } - - /// {@macro session_stream} - @override - Stream> sessionStream() => - _sessionStream.stream.asBroadcastStream(); - - /// {@macro current_session} - @override - Future> currentSession() => sessionStream().last; - // SignUp/SignIn methods ==================================================== /// {@macro signup_pwd} diff --git a/packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/remote.dart b/packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/remote.dart new file mode 100644 index 00000000..5a8c8679 --- /dev/null +++ b/packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/remote.dart @@ -0,0 +1,17 @@ +// Copyright (C) 2023 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +export 'authentication_firebase_data_source_impl.dart'; diff --git a/packages/wyatt_authentication_bloc/lib/src/data/repositories/authentication_repository_impl.dart b/packages/wyatt_authentication_bloc/lib/src/data/repositories/authentication_repository_impl.dart index 3b2c8481..652cca7a 100644 --- a/packages/wyatt_authentication_bloc/lib/src/data/repositories/authentication_repository_impl.dart +++ b/packages/wyatt_authentication_bloc/lib/src/data/repositories/authentication_repository_impl.dart @@ -16,17 +16,22 @@ import 'package:wyatt_architecture/wyatt_architecture.dart'; import 'package:wyatt_authentication_bloc/src/core/utils/forms.dart'; -import 'package:wyatt_authentication_bloc/src/domain/data_sources/remote/authentication_remote_data_source.dart'; -import 'package:wyatt_authentication_bloc/src/domain/entities/account.dart'; -import 'package:wyatt_authentication_bloc/src/domain/entities/auth_session.dart'; -import 'package:wyatt_authentication_bloc/src/domain/repositories/authentication_repository.dart'; +import 'package:wyatt_authentication_bloc/src/domain/data_sources/local/authentication_cache_data_source.dart'; +import 'package:wyatt_authentication_bloc/src/domain/data_sources/local/authentication_session_data_source.dart'; +import 'package:wyatt_authentication_bloc/src/domain/domain.dart'; import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; import 'package:wyatt_type_utils/wyatt_type_utils.dart'; +/// {@template authentication_repository_impl} +/// The default implementation of [AuthenticationRepository]. +/// {@endtemplate} class AuthenticationRepositoryImpl extends AuthenticationRepository { + /// {@macro authentication_repository_impl} AuthenticationRepositoryImpl({ required this.authenticationRemoteDataSource, + required this.authenticationCacheDataSource, + required this.authenticationSessionDataSource, FormRepository? formRepository, // ignore: strict_raw_type List? extraSignUpInputs, @@ -66,24 +71,57 @@ class AuthenticationRepositoryImpl ); } + /// The remote data source used to perform the authentication process. final AuthenticationRemoteDataSource authenticationRemoteDataSource; + + /// The cache data source used to cache the current account. + final AuthenticationCacheDataSource authenticationCacheDataSource; + + /// The session data source used to manage the current session. + final AuthenticationSessionDataSource authenticationSessionDataSource; + late FormRepository _formRepository; /// {@macro form_repo} @override FormRepository get formRepository => _formRepository; + // Cache related methods ==================================================== + + /// {@macro check_cache_account} + @override + Future checkForCachedAccount() async { + final cachedAccount = + await authenticationCacheDataSource.getCachedAccount(); + + if (cachedAccount == null) { + addSession( + const AuthenticationSession( + latestEvent: UnknownAuthenticationEvent(), + ), + ); + return; + } + + addSession( + AuthenticationSession.fromEvent( + SignedInFromCacheEvent(account: cachedAccount), + ), + ); + return; + } + // Session related methods =================================================== /// {@macro add_session} @override void addSession(AuthenticationSession session) => - authenticationRemoteDataSource.addSession(session); + authenticationSessionDataSource.addSession(session); /// {@macro session_stream} @override Stream> sessionStream() => - authenticationRemoteDataSource.sessionStream(); + authenticationSessionDataSource.sessionStream(); /// {@macro current_session} @override @@ -91,7 +129,9 @@ class AuthenticationRepositoryImpl Result.tryCatchAsync, AppException, AppException>( () async { - final session = await authenticationRemoteDataSource.currentSession(); + final session = + await authenticationSessionDataSource.currentSession(); + return session; }, (error) => error, diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/data_sources/data_sources.dart b/packages/wyatt_authentication_bloc/lib/src/domain/data_sources/data_sources.dart index 4a8f3011..843f681b 100644 --- a/packages/wyatt_authentication_bloc/lib/src/domain/data_sources/data_sources.dart +++ b/packages/wyatt_authentication_bloc/lib/src/domain/data_sources/data_sources.dart @@ -14,4 +14,5 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . -export 'remote/authentication_remote_data_source.dart'; +export 'local/local.dart'; +export 'remote/remote.dart'; diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/data_sources/local/authentication_cache_data_source.dart b/packages/wyatt_authentication_bloc/lib/src/domain/data_sources/local/authentication_cache_data_source.dart new file mode 100644 index 00000000..911ec217 --- /dev/null +++ b/packages/wyatt_authentication_bloc/lib/src/domain/data_sources/local/authentication_cache_data_source.dart @@ -0,0 +1,40 @@ +// Copyright (C) 2023 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +import 'package:wyatt_architecture/wyatt_architecture.dart'; +import 'package:wyatt_authentication_bloc/src/domain/entities/account.dart'; + +/// {@template authentication_cache_data_source} +/// A data source that manages the cache strategy. +/// {@endtemplate} +abstract class AuthenticationCacheDataSource extends BaseLocalDataSource { + /// {@macro authentication_cache_data_source} + const AuthenticationCacheDataSource(); + + /// Returns the cached account if it exists. + Future getCachedAccount(); + + /// Adds the current account to the cache. + /// + /// If an account is already cached, it will be replaced. + Future cacheAccount(Account account); + + /// Removes the current account from the cache. + /// + /// The cache will be empty after this operation. + /// If no account is cached, nothing will happen. + Future removeCachedAccount(); +} diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/data_sources/local/authentication_session_data_source.dart b/packages/wyatt_authentication_bloc/lib/src/domain/data_sources/local/authentication_session_data_source.dart new file mode 100644 index 00000000..c24d859a --- /dev/null +++ b/packages/wyatt_authentication_bloc/lib/src/domain/data_sources/local/authentication_session_data_source.dart @@ -0,0 +1,36 @@ +// Copyright (C) 2023 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +import 'package:wyatt_architecture/wyatt_architecture.dart'; +import 'package:wyatt_authentication_bloc/wyatt_authentication_bloc.dart'; + +/// {@template authentication_session_data_source} +/// A data source that manages the current session. +/// {@endtemplate} +abstract class AuthenticationSessionDataSource + extends BaseLocalDataSource { + /// {@macro authentication_session_data_source} + const AuthenticationSessionDataSource(); + + /// Adds a new session to the data source. + void addSession(AuthenticationSession session); + + /// Returns a stream of sessions. + Stream> sessionStream(); + + /// Returns the current session. + Future> currentSession(); +} diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/data_sources/local/local.dart b/packages/wyatt_authentication_bloc/lib/src/domain/data_sources/local/local.dart new file mode 100644 index 00000000..739d4717 --- /dev/null +++ b/packages/wyatt_authentication_bloc/lib/src/domain/data_sources/local/local.dart @@ -0,0 +1,18 @@ +// Copyright (C) 2023 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +export 'authentication_cache_data_source.dart'; +export 'authentication_session_data_source.dart'; diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/data_sources/remote/authentication_remote_data_source.dart b/packages/wyatt_authentication_bloc/lib/src/domain/data_sources/remote/authentication_remote_data_source.dart index 91cb2550..8d9afab5 100644 --- a/packages/wyatt_authentication_bloc/lib/src/domain/data_sources/remote/authentication_remote_data_source.dart +++ b/packages/wyatt_authentication_bloc/lib/src/domain/data_sources/remote/authentication_remote_data_source.dart @@ -16,49 +16,71 @@ import 'package:wyatt_architecture/wyatt_architecture.dart'; import 'package:wyatt_authentication_bloc/src/domain/entities/account.dart'; -import 'package:wyatt_authentication_bloc/src/domain/entities/auth_session.dart'; -/// Is responsible for abstracting the provenance of the data. +/// {@template authentication_remote_data_source} +/// A remote data source for authentication. +/// It is responsible for all the external communication with the authentication +/// providers. +/// {@endtemplate} abstract class AuthenticationRemoteDataSource extends BaseRemoteDataSource { - // Session related methods =================================================== - - void addSession(AuthenticationSession session); - Stream> sessionStream(); - Future> currentSession(); + /// {@macro authentication_remote_data_source} + const AuthenticationRemoteDataSource(); // SignUp/SignIn methods ==================================================== + /// Sign up with email and password. Future signUpWithEmailAndPassword({ required String email, required String password, }); + /// Sign in with email and password. Future signInWithEmailAndPassword({ required String email, required String password, }); + + /// Sign in anonymously. Future signInAnonymously(); + + /// Sign in with Google. Future signInWithGoogle(); + /// Sign out. Future signOut(); // Account management methods =============================================== - - // Future linkCurrentUserWith(AuthenticationProvider anotherProvider); + + /// Refresh the current account. Future refresh(); + + /// Reauthenticate the current account. Future reauthenticate(); + + /// Update the current account's email. Future updateEmail({required String email}); + + /// Update the current account's password. Future updatePassword({required String password}); + + /// Delete the current account. Future delete(); // Email related stuff ====================================================== + /// Send an email verification. Future sendEmailVerification(); + + /// Send a password reset email. Future sendPasswordResetEmail({required String email}); + + /// Confirm password reset. Future confirmPasswordReset({ required String code, required String newPassword, }); + + /// Verify password reset code. Future verifyPasswordResetCode({required String code}); } diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/data_sources/remote/remote.dart b/packages/wyatt_authentication_bloc/lib/src/domain/data_sources/remote/remote.dart new file mode 100644 index 00000000..7d684507 --- /dev/null +++ b/packages/wyatt_authentication_bloc/lib/src/domain/data_sources/remote/remote.dart @@ -0,0 +1,17 @@ +// Copyright (C) 2023 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +export 'authentication_remote_data_source.dart'; diff --git a/packages/wyatt_authentication_bloc/lib/src/domain/repositories/authentication_repository.dart b/packages/wyatt_authentication_bloc/lib/src/domain/repositories/authentication_repository.dart index ab32e322..a4f8769c 100644 --- a/packages/wyatt_authentication_bloc/lib/src/domain/repositories/authentication_repository.dart +++ b/packages/wyatt_authentication_bloc/lib/src/domain/repositories/authentication_repository.dart @@ -19,13 +19,25 @@ import 'package:wyatt_authentication_bloc/src/domain/entities/account.dart'; import 'package:wyatt_authentication_bloc/src/domain/entities/auth_session.dart'; import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; +/// {@template auth_repo} +/// Authentication repository interface. +/// {@endtemplate} abstract class AuthenticationRepository extends BaseRepository { /// {@template form_repo} /// Form repository used in different authentication cubits/blocs /// {@endtemplate} FormRepository get formRepository; - // Stream related methods =================================================== + // Cache related methods ==================================================== + + /// {@template check_cache_account} + /// Checks if there is a cached account. + /// And if there is, it will sign in the user automatically by + /// emitting an event. + /// {@endtemplate} + Future checkForCachedAccount(); + + // Session related methods =================================================== /// {@template add_session} /// Add a new authentication event. diff --git a/packages/wyatt_authentication_bloc/lib/src/features/authentication/cubit/authentication_cubit.dart b/packages/wyatt_authentication_bloc/lib/src/features/authentication/cubit/authentication_cubit.dart index e6748680..e5abf6ec 100644 --- a/packages/wyatt_authentication_bloc/lib/src/features/authentication/cubit/authentication_cubit.dart +++ b/packages/wyatt_authentication_bloc/lib/src/features/authentication/cubit/authentication_cubit.dart @@ -27,27 +27,45 @@ import 'package:wyatt_type_utils/wyatt_type_utils.dart'; part 'authentication_state.dart'; +/// {@template authentication_cubit} /// Abstract authentication cubit class needs to be implemented in application. /// /// This cubit is in charge of managing the global authentication state of /// the application. /// /// Its here you can override every callbacks and add your custom logic. +/// {@endtemplate} abstract class AuthenticationCubit extends Cubit> { + /// {@macro authentication_cubit} AuthenticationCubit({ required this.authenticationRepository, }) : super(const AuthenticationState.unknown()) { - _listenForAuthenticationChanges(); + _init(); } + + /// The authentication repository. final AuthenticationRepository authenticationRepository; + /// The latest session. AuthenticationSession? _latestSession; + /// Method that is called when the cubit is initialized. + Future _init() async { + /// Setup listeners. + _listenForAuthenticationChanges(); + + /// Check if there is a cached account. + await authenticationRepository.checkForCachedAccount(); + } + void _listenForAuthenticationChanges() { authenticationRepository.sessionStream().asyncMap((session) async { final event = session.latestEvent; + + /// If the session is signed in from cache. if (event is SignedInFromCacheEvent) { + /// Call the custom routine. final customRoutineResult = await onSignInFromCache(session); if (customRoutineResult.isOk) { @@ -64,12 +82,18 @@ abstract class AuthenticationCubit } return session; }).listen((session) async { + /// Save the latest session. _latestSession = session; + + /// If there is an account: emit authenticated state. if (session.account != null) { emit(AuthenticationState.authenticated(session)); return; } + + /// If there is no account: emit unauthenticated state. emit(AuthenticationState.unauthenticated()); + return; }); } -- 2.47.2 From 4d872edc4e83184189de23c0c3ca6c6bbee0b047 Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Wed, 8 Mar 2023 12:57:56 +0100 Subject: [PATCH 23/47] docs(authentication): update example with multiple data sources --- .../example/README.md | 18 +---- .../example/ios/Podfile.lock | 16 ++-- .../ios/Runner.xcodeproj/project.pbxproj | 4 + .../ios/Runner/GoogleService-Info.plist | 38 ++++++++++ .../example/lib/bootstrap.dart | 9 --- .../lib/core/dependency_injection/get_it.dart | 73 +++++++++++++++++-- .../example/lib/core/enums/dev_mode.dart | 44 +++++++++++ .../example/lib/core/flavors/flavor.dart | 72 ++++++++++++++++++ .../example/lib/firebase_options.dart | 6 +- .../example/lib/main.dart | 8 +- ...in_firebase.dart => main_development.dart} | 8 +- .../lib/presentation/features/app/app.dart | 3 + .../presentation/features/sub/sub_page.dart | 3 +- 13 files changed, 261 insertions(+), 41 deletions(-) create mode 100644 packages/wyatt_authentication_bloc/example/ios/Runner/GoogleService-Info.plist create mode 100644 packages/wyatt_authentication_bloc/example/lib/core/enums/dev_mode.dart create mode 100644 packages/wyatt_authentication_bloc/example/lib/core/flavors/flavor.dart rename packages/wyatt_authentication_bloc/example/lib/{main_firebase.dart => main_development.dart} (82%) diff --git a/packages/wyatt_authentication_bloc/example/README.md b/packages/wyatt_authentication_bloc/example/README.md index 139e82ee..df389404 100644 --- a/packages/wyatt_authentication_bloc/example/README.md +++ b/packages/wyatt_authentication_bloc/example/README.md @@ -1,16 +1,6 @@ # example_router -A new Flutter project. - -## Getting Started - -This project is a starting point for a Flutter application. - -A few resources to get you started if this is your first Flutter project: - -- [Lab: Write your first Flutter app](https://docs.flutter.dev/get-started/codelab) -- [Cookbook: Useful Flutter samples](https://docs.flutter.dev/cookbook) - -For help getting started with Flutter development, view the -[online documentation](https://docs.flutter.dev/), which offers tutorials, -samples, guidance on mobile development, and a full API reference. +```sh +firebase emulators:start --only auth +flutter run --target lib/main_development.dart --dart-define="dev_mode=emulator" +``` diff --git a/packages/wyatt_authentication_bloc/example/ios/Podfile.lock b/packages/wyatt_authentication_bloc/example/ios/Podfile.lock index bc6894a5..4e5cbe34 100644 --- a/packages/wyatt_authentication_bloc/example/ios/Podfile.lock +++ b/packages/wyatt_authentication_bloc/example/ios/Podfile.lock @@ -10,11 +10,11 @@ PODS: - FirebaseAuth (~> 10.3.0) - Firebase/CoreOnly (10.3.0): - FirebaseCore (= 10.3.0) - - firebase_auth (4.2.0): + - firebase_auth (4.2.9): - Firebase/Auth (= 10.3.0) - firebase_core - Flutter - - firebase_core (2.4.0): + - firebase_core (2.7.0): - Firebase/CoreOnly (= 10.3.0) - Flutter - FirebaseAuth (10.3.0): @@ -29,6 +29,8 @@ PODS: - FirebaseCoreInternal (10.3.0): - "GoogleUtilities/NSData+zlib (~> 7.8)" - Flutter (1.0.0) + - flutter_secure_storage (6.0.0): + - Flutter - google_sign_in_ios (0.0.1): - Flutter - GoogleSignIn (~> 6.2) @@ -61,6 +63,7 @@ DEPENDENCIES: - firebase_auth (from `.symlinks/plugins/firebase_auth/ios`) - firebase_core (from `.symlinks/plugins/firebase_core/ios`) - Flutter (from `Flutter`) + - flutter_secure_storage (from `.symlinks/plugins/flutter_secure_storage/ios`) - google_sign_in_ios (from `.symlinks/plugins/google_sign_in_ios/ios`) SPEC REPOS: @@ -83,19 +86,22 @@ EXTERNAL SOURCES: :path: ".symlinks/plugins/firebase_core/ios" Flutter: :path: Flutter + flutter_secure_storage: + :path: ".symlinks/plugins/flutter_secure_storage/ios" google_sign_in_ios: :path: ".symlinks/plugins/google_sign_in_ios/ios" SPEC CHECKSUMS: AppAuth: 8fca6b5563a5baef2c04bee27538025e4ceb2add Firebase: f92fc551ead69c94168d36c2b26188263860acd9 - firebase_auth: 579a0dc15451491cc83fccaa5102296635f24938 - firebase_core: 6f2f753e316765799d88568232ed59e300ff53db + firebase_auth: 4e8c693e848ed13b263de2d702d55fa82ed04a79 + firebase_core: 128d8c43c3a453a4a67463314fc3761bedff860b FirebaseAuth: 0e415d29d846c1dce2fb641e46f35e9888d9bec6 FirebaseCore: 988754646ab3bd4bdcb740f1bfe26b9f6c0d5f2a FirebaseCoreInternal: 29b76f784d607df8b2a1259d73c3f04f1210137b Flutter: f04841e97a9d0b0a8025694d0796dd46242b2854 - google_sign_in_ios: 4f85eb9f937450765c8573bb85fd8cd6a5af675c + flutter_secure_storage: 23fc622d89d073675f2eaa109381aefbcf5a49be + google_sign_in_ios: 1256ff9d941db546373826966720b0c24804bcdd GoogleSignIn: 5651ce3a61e56ca864160e79b484cd9ed3f49b7a GoogleUtilities: bad72cb363809015b1f7f19beb1f1cd23c589f95 GTMAppAuth: 0ff230db599948a9ad7470ca667337803b3fc4dd diff --git a/packages/wyatt_authentication_bloc/example/ios/Runner.xcodeproj/project.pbxproj b/packages/wyatt_authentication_bloc/example/ios/Runner.xcodeproj/project.pbxproj index 85497888..eda3ed8b 100644 --- a/packages/wyatt_authentication_bloc/example/ios/Runner.xcodeproj/project.pbxproj +++ b/packages/wyatt_authentication_bloc/example/ios/Runner.xcodeproj/project.pbxproj @@ -9,6 +9,7 @@ /* Begin PBXBuildFile section */ 1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */ = {isa = PBXBuildFile; fileRef = 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */; }; 3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */ = {isa = PBXBuildFile; fileRef = 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */; }; + 44F5B6790A35D9BA26574F6B /* GoogleService-Info.plist in Resources */ = {isa = PBXBuildFile; fileRef = F6E17622FCECE9BFC2543397 /* GoogleService-Info.plist */; }; 69F3BBCD5DEB05A456F6B74F /* Pods_Runner.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = B0A061B2E527F311149C3581 /* Pods_Runner.framework */; }; 74858FAF1ED2DC5600515810 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 74858FAE1ED2DC5600515810 /* AppDelegate.swift */; }; 97C146FC1CF9000F007C117D /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FA1CF9000F007C117D /* Main.storyboard */; }; @@ -46,6 +47,7 @@ 97C147021CF9000F007C117D /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; B0A061B2E527F311149C3581 /* Pods_Runner.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_Runner.framework; sourceTree = BUILT_PRODUCTS_DIR; }; F0D7945BAE0BEA457137ED73 /* Pods-Runner.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.debug.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig"; sourceTree = ""; }; + F6E17622FCECE9BFC2543397 /* GoogleService-Info.plist */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.plist.xml; name = "GoogleService-Info.plist"; path = "Runner/GoogleService-Info.plist"; sourceTree = ""; }; F9340E3A859C31E59380BD0F /* Pods-Runner.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.release.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig"; sourceTree = ""; }; /* End PBXFileReference section */ @@ -91,6 +93,7 @@ 97C146EF1CF9000F007C117D /* Products */, 66B357379C2757D2844F12BB /* Pods */, BC1E25CE0DADDF7B7201CCF8 /* Frameworks */, + F6E17622FCECE9BFC2543397 /* GoogleService-Info.plist */, ); sourceTree = ""; }; @@ -192,6 +195,7 @@ 3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */, 97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */, 97C146FC1CF9000F007C117D /* Main.storyboard in Resources */, + 44F5B6790A35D9BA26574F6B /* GoogleService-Info.plist in Resources */, ); runOnlyForDeploymentPostprocessing = 0; }; diff --git a/packages/wyatt_authentication_bloc/example/ios/Runner/GoogleService-Info.plist b/packages/wyatt_authentication_bloc/example/ios/Runner/GoogleService-Info.plist new file mode 100644 index 00000000..ac60a458 --- /dev/null +++ b/packages/wyatt_authentication_bloc/example/ios/Runner/GoogleService-Info.plist @@ -0,0 +1,38 @@ + + + + + CLIENT_ID + 136771801992-p629tpo9bk3hcm2955s5ahivdla57ln9.apps.googleusercontent.com + REVERSED_CLIENT_ID + com.googleusercontent.apps.136771801992-p629tpo9bk3hcm2955s5ahivdla57ln9 + ANDROID_CLIENT_ID + 136771801992-n2pq8oqutvrqj58e05hbavvc7n1jdfjb.apps.googleusercontent.com + API_KEY + AIzaSyCDbbhjbFrQwLXuIANdJzjkDk8uOETnn7w + GCM_SENDER_ID + 136771801992 + PLIST_VERSION + 1 + BUNDLE_ID + com.example.exampleRouter + PROJECT_ID + tchat-beta + STORAGE_BUCKET + tchat-beta.appspot.com + IS_ADS_ENABLED + + IS_ANALYTICS_ENABLED + + IS_APPINVITE_ENABLED + + IS_GCM_ENABLED + + IS_SIGNIN_ENABLED + + GOOGLE_APP_ID + 1:136771801992:ios:bcdca68d2b7d227097203d + DATABASE_URL + https://tchat-beta.firebaseio.com + + \ No newline at end of file diff --git a/packages/wyatt_authentication_bloc/example/lib/bootstrap.dart b/packages/wyatt_authentication_bloc/example/lib/bootstrap.dart index 05ee6358..948e01fd 100644 --- a/packages/wyatt_authentication_bloc/example/lib/bootstrap.dart +++ b/packages/wyatt_authentication_bloc/example/lib/bootstrap.dart @@ -18,11 +18,8 @@ import 'dart:async'; import 'package:example_router/core/dependency_injection/get_it.dart'; import 'package:example_router/core/utils/app_bloc_observer.dart'; -import 'package:example_router/firebase_options.dart'; -import 'package:firebase_core/firebase_core.dart'; import 'package:flutter/widgets.dart'; import 'package:flutter_bloc/flutter_bloc.dart'; -import 'package:wyatt_authentication_bloc/wyatt_authentication_bloc.dart'; class MockSettings { static MockSettings? _instance; @@ -70,12 +67,6 @@ Future bootstrap(FutureOr Function() builder) async { debugPrint(details.toString()); }; - if (MockSettings.isDisable()) { - await Firebase.initializeApp( - options: DefaultFirebaseOptions.currentPlatform, - ); - await FirebaseAuth.instance.useAuthEmulator('localhost', 9099); - } await GetItInitializer.init(); runApp(await builder()); diff --git a/packages/wyatt_authentication_bloc/example/lib/core/dependency_injection/get_it.dart b/packages/wyatt_authentication_bloc/example/lib/core/dependency_injection/get_it.dart index 1490523f..a4833f56 100644 --- a/packages/wyatt_authentication_bloc/example/lib/core/dependency_injection/get_it.dart +++ b/packages/wyatt_authentication_bloc/example/lib/core/dependency_injection/get_it.dart @@ -14,20 +14,81 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . +import 'dart:async'; + +import 'package:example_router/core/enums/dev_mode.dart'; +import 'package:example_router/core/flavors/flavor.dart'; import 'package:example_router/firebase_options.dart'; +import 'package:firebase_core/firebase_core.dart'; import 'package:get_it/get_it.dart'; import 'package:wyatt_authentication_bloc/wyatt_authentication_bloc.dart'; final getIt = GetIt.I; +/// Service and Data Source locator abstract class GetItInitializer { - static Future init() async { - getIt.registerLazySingleton>( - () => AuthenticationFirebaseDataSourceImpl( - firebaseAuth: FirebaseAuth.instance, - googleSignIn: - GoogleSignIn(clientId: DefaultFirebaseOptions.ios.iosClientId)), + static FutureOr _initCommon() async { + // Initialize common sources/services + getIt.registerLazySingleton>( + () => AuthenticationSessionDataSourceImpl(), ); + } + + static FutureOr _initEmulator() async { + // Initialize emulator sources/services + final firebaseAuth = FirebaseAuth.instance; + await firebaseAuth.useAuthEmulator('localhost', 9099); + getIt + ..registerLazySingleton>( + () => AuthenticationFirebaseDataSourceImpl( + firebaseAuth: firebaseAuth, + googleSignIn: + GoogleSignIn(clientId: DefaultFirebaseOptions.ios.iosClientId)), + ) + ..registerLazySingleton>( + () => AuthenticationFirebaseCacheDataSourceImpl( + firebaseAuth: firebaseAuth, + ), + ); + } + + static FutureOr _initFirebase() async { + // Initialize firebase sources/services. + getIt + ..registerLazySingleton>( + () => AuthenticationFirebaseDataSourceImpl( + firebaseAuth: FirebaseAuth.instance, + googleSignIn: + GoogleSignIn(clientId: DefaultFirebaseOptions.ios.iosClientId)), + ) + ..registerLazySingleton>( + () => AuthenticationFirebaseCacheDataSourceImpl( + firebaseAuth: FirebaseAuth.instance, + ), + ); + } + + static FutureOr _initRest() async { + // Initialize rest api sources/services + } + + static FutureOr init() async { + await _initCommon(); + final flavor = Flavor.get(); + + if (flavor.devMode == DevMode.rest) { + await _initRest(); + } else if (flavor.devMode == DevMode.emulator) { + await Firebase.initializeApp( + options: DefaultFirebaseOptions.currentPlatform, + ); + await _initEmulator(); + } else { + await Firebase.initializeApp( + options: DefaultFirebaseOptions.currentPlatform, + ); + await _initFirebase(); + } await getIt.allReady(); } diff --git a/packages/wyatt_authentication_bloc/example/lib/core/enums/dev_mode.dart b/packages/wyatt_authentication_bloc/example/lib/core/enums/dev_mode.dart new file mode 100644 index 00000000..5c99b7f8 --- /dev/null +++ b/packages/wyatt_authentication_bloc/example/lib/core/enums/dev_mode.dart @@ -0,0 +1,44 @@ +// Copyright (C) 2023 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +enum DevMode { + /// Mocked values + mock, + + /// Real values from REST API + rest, + + /// Emulated values with Firebase Emulator + emulator, + + /// Real values from Firebase + real; + + @override + String toString() => name; + + /// Tries to parse String and returns mode. Fallback is returned if there + /// is an error during parsing. + static DevMode fromString(String? mode, {DevMode fallback = DevMode.mock}) { + for (final m in values) { + if (m.name == mode) { + return m; + } + } + + return fallback; + } +} diff --git a/packages/wyatt_authentication_bloc/example/lib/core/flavors/flavor.dart b/packages/wyatt_authentication_bloc/example/lib/core/flavors/flavor.dart new file mode 100644 index 00000000..9fef201a --- /dev/null +++ b/packages/wyatt_authentication_bloc/example/lib/core/flavors/flavor.dart @@ -0,0 +1,72 @@ +// Copyright (C) 2023 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +import 'package:example_router/core/enums/dev_mode.dart'; +import 'package:flutter/material.dart'; + +abstract class Flavor { + Flavor._({ + this.banner, + this.bannerColor = Colors.red, + this.devMode, + }) { + _instance = this; + } + + static Flavor? _instance; + + final String? banner; + final Color bannerColor; + final DevMode? devMode; + + /// Returns [Flavor] instance. + static Flavor get() { + if (_instance == null) { + throw Exception('Flavor not initialized!'); + } + + return _instance!; + } + + @override + String toString() => runtimeType.toString().replaceAll('Flavor', ''); +} + +class DevelopmentFlavor extends Flavor { + factory DevelopmentFlavor() { + const modeString = String.fromEnvironment('dev_mode', defaultValue: 'mock'); + final mode = DevMode.fromString(modeString); + + return DevelopmentFlavor._(devMode: mode); + } + DevelopmentFlavor._({ + required super.devMode, + }) : super._( + banner: 'Dev', + ); +} + +class StagingFlavor extends Flavor { + StagingFlavor() + : super._( + banner: 'Staging', + bannerColor: Colors.green, + ); +} + +class ProductionFlavor extends Flavor { + ProductionFlavor() : super._(); +} diff --git a/packages/wyatt_authentication_bloc/example/lib/firebase_options.dart b/packages/wyatt_authentication_bloc/example/lib/firebase_options.dart index dcf7c17e..0725ddb4 100644 --- a/packages/wyatt_authentication_bloc/example/lib/firebase_options.dart +++ b/packages/wyatt_authentication_bloc/example/lib/firebase_options.dart @@ -65,8 +65,10 @@ class DefaultFirebaseOptions { projectId: 'tchat-beta', databaseURL: 'https://tchat-beta.firebaseio.com', storageBucket: 'tchat-beta.appspot.com', - androidClientId: '136771801992-n2pq8oqutvrqj58e05hbavvc7n1jdfjb.apps.googleusercontent.com', - iosClientId: '136771801992-p629tpo9bk3hcm2955s5ahivdla57ln9.apps.googleusercontent.com', + androidClientId: + '136771801992-n2pq8oqutvrqj58e05hbavvc7n1jdfjb.apps.googleusercontent.com', + iosClientId: + '136771801992-p629tpo9bk3hcm2955s5ahivdla57ln9.apps.googleusercontent.com', iosBundleId: 'com.example.exampleRouter', ); } diff --git a/packages/wyatt_authentication_bloc/example/lib/main.dart b/packages/wyatt_authentication_bloc/example/lib/main.dart index a7967932..a8d69968 100644 --- a/packages/wyatt_authentication_bloc/example/lib/main.dart +++ b/packages/wyatt_authentication_bloc/example/lib/main.dart @@ -15,9 +15,13 @@ // along with this program. If not, see . import 'package:example_router/bootstrap.dart'; +import 'package:example_router/core/flavors/flavor.dart'; import 'package:example_router/presentation/features/app/app.dart'; -void main() { - MockSettings.enable(); +void main(List args) { + // Define environment + ProductionFlavor(); + + // Initialize environment and variables bootstrap(App.new); } diff --git a/packages/wyatt_authentication_bloc/example/lib/main_firebase.dart b/packages/wyatt_authentication_bloc/example/lib/main_development.dart similarity index 82% rename from packages/wyatt_authentication_bloc/example/lib/main_firebase.dart rename to packages/wyatt_authentication_bloc/example/lib/main_development.dart index 62ee35ec..9025e30f 100644 --- a/packages/wyatt_authentication_bloc/example/lib/main_firebase.dart +++ b/packages/wyatt_authentication_bloc/example/lib/main_development.dart @@ -15,9 +15,13 @@ // along with this program. If not, see . import 'package:example_router/bootstrap.dart'; +import 'package:example_router/core/flavors/flavor.dart'; import 'package:example_router/presentation/features/app/app.dart'; -void main() { - MockSettings.disable(); +void main(List args) { + // Define environment + DevelopmentFlavor(); + + // Initialize environment and variables bootstrap(App.new); } diff --git a/packages/wyatt_authentication_bloc/example/lib/presentation/features/app/app.dart b/packages/wyatt_authentication_bloc/example/lib/presentation/features/app/app.dart index 5285f63d..51b038d9 100644 --- a/packages/wyatt_authentication_bloc/example/lib/presentation/features/app/app.dart +++ b/packages/wyatt_authentication_bloc/example/lib/presentation/features/app/app.dart @@ -34,6 +34,9 @@ class App extends StatelessWidget { AuthenticationRepositoryImpl( authenticationRemoteDataSource: getIt>(), + authenticationSessionDataSource: + getIt>(), + authenticationCacheDataSource: getIt>(), customPasswordValidator: const CustomPassword.pure(), extraSignUpInputs: [ FormInput( diff --git a/packages/wyatt_authentication_bloc/example/lib/presentation/features/sub/sub_page.dart b/packages/wyatt_authentication_bloc/example/lib/presentation/features/sub/sub_page.dart index 9c0f4ece..f56df50b 100644 --- a/packages/wyatt_authentication_bloc/example/lib/presentation/features/sub/sub_page.dart +++ b/packages/wyatt_authentication_bloc/example/lib/presentation/features/sub/sub_page.dart @@ -45,7 +45,8 @@ class SubPage extends StatelessWidget { children: [ const Text('Another page'), ElevatedButton( - onPressed: () => context.read>().delete(), + onPressed: () => + context.read>().delete(), child: const Text('Delete account'), ), ], -- 2.47.2 From 1d3e487d6b3472be57b4d6ecfbea0007d9b85fb9 Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Fri, 10 Mar 2023 15:07:49 +0100 Subject: [PATCH 24/47] feat(authentication): add mock + local storage --- .../lib/src/core/constants/storage.dart | 22 + .../lib/src/core/exceptions/exceptions.dart | 2 + .../src/core/exceptions/exceptions_base.dart | 382 +++++++++++++++++ .../src/core/exceptions/exceptions_mock.dart | 390 ++++++++++++++++++ ...secure_storage_cache_data_source_impl.dart | 75 ++++ .../src/data/data_sources/local/local.dart | 1 + .../authentication_base_data_source.dart | 106 +++++ .../authentication_mock_data_source_impl.dart | 201 +++++++++ .../src/data/data_sources/remote/remote.dart | 2 + .../lib/src/data/models/account_model.dart | 24 ++ .../authentication_repository_impl.dart | 24 +- .../wyatt_authentication_bloc/pubspec.yaml | 2 + 12 files changed, 1228 insertions(+), 3 deletions(-) create mode 100644 packages/wyatt_authentication_bloc/lib/src/core/constants/storage.dart create mode 100644 packages/wyatt_authentication_bloc/lib/src/core/exceptions/exceptions_base.dart create mode 100644 packages/wyatt_authentication_bloc/lib/src/core/exceptions/exceptions_mock.dart create mode 100644 packages/wyatt_authentication_bloc/lib/src/data/data_sources/local/authentication_secure_storage_cache_data_source_impl.dart create mode 100644 packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/authentication_base_data_source.dart create mode 100644 packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/authentication_mock_data_source_impl.dart diff --git a/packages/wyatt_authentication_bloc/lib/src/core/constants/storage.dart b/packages/wyatt_authentication_bloc/lib/src/core/constants/storage.dart new file mode 100644 index 00000000..e3875066 --- /dev/null +++ b/packages/wyatt_authentication_bloc/lib/src/core/constants/storage.dart @@ -0,0 +1,22 @@ +// Copyright (C) 2023 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +abstract class AuthStorage { + static const String refreshToken = 'wyattRefreshToken'; + static const String accessToken = 'wyattAccessToken'; + static const String email = 'wyattEmail'; + static const String id = 'wyattId'; +} diff --git a/packages/wyatt_authentication_bloc/lib/src/core/exceptions/exceptions.dart b/packages/wyatt_authentication_bloc/lib/src/core/exceptions/exceptions.dart index e10faebe..0fb036f7 100644 --- a/packages/wyatt_authentication_bloc/lib/src/core/exceptions/exceptions.dart +++ b/packages/wyatt_authentication_bloc/lib/src/core/exceptions/exceptions.dart @@ -16,7 +16,9 @@ import 'package:wyatt_architecture/wyatt_architecture.dart'; +part 'exceptions_base.dart'; part 'exceptions_firebase.dart'; +part 'exceptions_mock.dart'; /// Base exception used in Wyatt Authentication abstract class AuthenticationFailureInterface extends AppException diff --git a/packages/wyatt_authentication_bloc/lib/src/core/exceptions/exceptions_base.dart b/packages/wyatt_authentication_bloc/lib/src/core/exceptions/exceptions_base.dart new file mode 100644 index 00000000..cd994be5 --- /dev/null +++ b/packages/wyatt_authentication_bloc/lib/src/core/exceptions/exceptions_base.dart @@ -0,0 +1,382 @@ +// Copyright (C) 2023 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +part of 'exceptions.dart'; + +/// {@macro apply_action_code_failure} +class ApplyActionCodeFailureBase extends ApplyActionCodeFailureInterface { + ApplyActionCodeFailureBase([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); + ApplyActionCodeFailureBase.fromCode(String code) : super.fromCode(code) { + switch (code) { + case 'expired-action-code': + msg = 'Action code has expired.'; + break; + case 'invalid-action-code': + msg = 'Action code is invalid.'; + break; + case 'user-disabled': + msg = 'This user has been disabled. Please contact support for help.'; + break; + case 'user-not-found': + msg = 'Email is not found, please create an account.'; + break; + + default: + this.code = 'unknown'; + msg = 'An unknown error occurred.'; + } + } +} + +/// {@macro sign_up_with_email_and_password_failure} +class SignUpWithEmailAndPasswordFailureBase + extends SignUpWithEmailAndPasswordFailureInterface { + SignUpWithEmailAndPasswordFailureBase([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); + SignUpWithEmailAndPasswordFailureBase.fromCode(String code) + : super.fromCode(code) { + switch (code) { + case 'invalid-email': + msg = 'The email address is badly formatted.'; + break; + case 'user-disabled': + msg = 'This user has been disabled. Please contact support for help.'; + break; + case 'email-already-in-use': + msg = 'An account already exists for that email.'; + break; + case 'operation-not-allowed': + msg = 'Operation is not allowed. Please contact support.'; + break; + case 'weak-password': + msg = 'Please enter a stronger password.'; + break; + default: + this.code = 'unknown'; + msg = 'An unknown error occurred.'; + } + } +} + +/// {@macro fetch_sign_in_methods_failure} +class FetchSignInMethodsForEmailFailureBase + extends FetchSignInMethodsForEmailFailureInterface { + FetchSignInMethodsForEmailFailureBase([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); + FetchSignInMethodsForEmailFailureBase.fromCode(String code) + : super.fromCode(code) { + switch (code) { + case 'invalid-email': + msg = 'The email address is badly formatted.'; + break; + default: + this.code = 'unknown'; + msg = 'An unknown error occurred.'; + } + } +} + +/// {@macro sign_in_anonymously_failure} +class SignInAnonymouslyFailureBase extends SignInAnonymouslyFailureInterface { + SignInAnonymouslyFailureBase([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); + SignInAnonymouslyFailureBase.fromCode(String code) : super.fromCode(code) { + switch (code) { + case 'operation-not-allowed': + msg = 'Operation is not allowed. Please contact support.'; + break; + default: + this.code = 'unknown'; + msg = 'An unknown error occurred.'; + } + } +} + +/// {@macro sign_in_with_credential_failure} +class SignInWithCredentialFailureBase + extends SignInWithCredentialFailureInterface { + SignInWithCredentialFailureBase([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); + SignInWithCredentialFailureBase.fromCode(String code) : super.fromCode(code) { + switch (code) { + case 'account-exists-with-different-credential': + msg = 'Account exists with different credentials.'; + break; + case 'invalid-credential': + msg = 'The credential received is malformed or has expired.'; + break; + case 'operation-not-allowed': + msg = 'Operation is not allowed. Please contact support.'; + break; + case 'user-disabled': + msg = 'This user has been disabled. Please contact support for help.'; + break; + case 'user-not-found': + msg = 'Email is not found, please create an account.'; + break; + case 'wrong-password': + msg = 'Incorrect password, please try again.'; + break; + case 'invalid-verification-code': + msg = 'The credential verification code received is invalid.'; + break; + case 'invalid-verification-id': + msg = 'The credential verification ID received is invalid.'; + break; + default: + this.code = 'unknown'; + msg = 'An unknown error occurred.'; + } + } +} + +/// {@macro sign_in_with_google_failure} +class SignInWithGoogleFailureBase extends SignInWithCredentialFailureBase + implements SignInWithGoogleFailureInterface { + SignInWithGoogleFailureBase([super.code, super.msg]); + SignInWithGoogleFailureBase.fromCode(super.code) : super.fromCode(); +} + +/// {@macro sign_in_with_facebook_failure} +class SignInWithFacebookFailureBase extends SignInWithCredentialFailureBase + implements SignInWithFacebookFailureInterface { + SignInWithFacebookFailureBase([super.code, super.msg]); + SignInWithFacebookFailureBase.fromCode(super.code) : super.fromCode(); +} + +/// {@macro sign_in_with_apple_failure} +class SignInWithAppleFailureBase extends SignInWithCredentialFailureBase + implements SignInWithAppleFailureInterface { + SignInWithAppleFailureBase([super.code, super.msg]); + SignInWithAppleFailureBase.fromCode(super.code) : super.fromCode(); +} + +/// {@macro sign_in_with_twitter_failure} +class SignInWithTwitterFailureBase extends SignInWithCredentialFailureBase + implements SignInWithAppleFailureInterface { + SignInWithTwitterFailureBase([super.code, super.msg]); + SignInWithTwitterFailureBase.fromCode(super.code) : super.fromCode(); +} + +/// {@macro sign_in_with_email_link_failure} +class SignInWithEmailLinkFailureBase + extends SignInWithEmailLinkFailureInterface { + SignInWithEmailLinkFailureBase([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); + SignInWithEmailLinkFailureBase.fromCode(String code) : super.fromCode(code) { + switch (code) { + case 'expired-action-code': + msg = 'Action code has expired.'; + break; + case 'invalid-email': + msg = 'Email is not valid or badly formatted.'; + break; + case 'user-disabled': + msg = 'This user has been disabled. Please contact support for help.'; + break; + default: + this.code = 'unknown'; + msg = 'An unknown error occurred.'; + } + } +} + +/// {@macro sign_in_with_email_and_password_failure} +class SignInWithEmailAndPasswordFailureBase + extends SignInWithEmailAndPasswordFailureInterface { + SignInWithEmailAndPasswordFailureBase([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); + SignInWithEmailAndPasswordFailureBase.fromCode(String code) + : super.fromCode(code) { + switch (code) { + case 'invalid-email': + msg = 'Email is not valid or badly formatted.'; + break; + case 'user-disabled': + msg = 'This user has been disabled. Please contact support for help.'; + break; + case 'user-not-found': + msg = 'Email is not found, please create an account.'; + break; + case 'wrong-password': + msg = 'Incorrect password, please try again.'; + break; + default: + this.code = 'unknown'; + msg = 'An unknown error occurred.'; + } + } +} + +/// {@macro send_email_verification_failure} +class SendEmailVerificationFailureBase + extends SendEmailVerificationFailureInterface { + SendEmailVerificationFailureBase([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); + + SendEmailVerificationFailureBase.fromCode(super.code) : super.fromCode(); +} + +/// {@macro send_password_reset_email_failure} +class SendPasswordResetEmailFailureBase + extends SendPasswordResetEmailFailureInterface { + SendPasswordResetEmailFailureBase([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); + SendPasswordResetEmailFailureBase.fromCode(super.code) : super.fromCode(); +} + +/// {@macro send_sign_in_link_email_failure} +class SendSignInLinkEmailFailureBase + extends SendSignInLinkEmailFailureInterface { + SendSignInLinkEmailFailureBase([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); + + SendSignInLinkEmailFailureBase.fromCode(super.code) : super.fromCode(); +} + +/// {@macro confirm_password_reset_failure} +class ConfirmPasswordResetFailureBase + extends ConfirmPasswordResetFailureInterface { + ConfirmPasswordResetFailureBase([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); + + ConfirmPasswordResetFailureBase.fromCode(super.code) : super.fromCode(); +} + +/// {@macro verify_password_reset_code_failure} +class VerifyPasswordResetCodeFailureBase + extends VerifyPasswordResetCodeFailureInterface { + VerifyPasswordResetCodeFailureBase([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); + + VerifyPasswordResetCodeFailureBase.fromCode(super.code) : super.fromCode(); +} + +/// {@macro refresh_failure} +class RefreshFailureBase extends RefreshFailureInterface { + RefreshFailureBase([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); + RefreshFailureBase.fromCode(super.code) : super.fromCode(); +} + +/// {@macro sign_out_failure} +class SignOutFailureBase extends SignOutFailureInterface { + SignOutFailureBase([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); + + SignOutFailureBase.fromCode(super.code) : super.fromCode(); +} + +/// {@macro reauthenticate_failure} +class ReauthenticateFailureBase extends ReauthenticateFailureInterface { + ReauthenticateFailureBase([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); + ReauthenticateFailureBase.fromCode(String code) : super.fromCode(code) { + switch (code) { + case 'user-mismatch': + msg = 'Given credential does not correspond to the user.'; + break; + case 'user-not-found': + msg = 'User is not found, please create an account.'; + break; + case 'invalid-credential': + msg = 'The credential received is malformed or has expired.'; + break; + case 'invalid-email': + msg = 'Email is not valid or badly formatted.'; + break; + case 'wrong-password': + msg = 'Incorrect password, please try again.'; + break; + case 'invalid-verification-code': + msg = 'The credential verification code received is invalid.'; + break; + case 'invalid-verification-id': + msg = 'The credential verification ID received is invalid.'; + break; + default: + this.code = 'unknown'; + msg = 'An unknown error occurred.'; + } + } +} + +/// {@macro update_email_failure} +class UpdateEmailFailureBase extends UpdateEmailFailureInterface { + UpdateEmailFailureBase([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); + UpdateEmailFailureBase.fromCode(String code) : super.fromCode(code) { + switch (code) { + case 'invalid-email': + msg = 'Email is not valid or badly formatted.'; + break; + case 'email-already-in-use': + msg = 'An account already exists for that email.'; + break; + case 'requires-recent-login': + msg = "User's last sign-in time does not meet the security threshold."; + break; + default: + this.code = 'unknown'; + msg = 'An unknown error occurred.'; + } + } +} + +/// {@macro update_password_failure} +class UpdatePasswordFailureBase extends UpdatePasswordFailureInterface { + UpdatePasswordFailureBase([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); + UpdatePasswordFailureBase.fromCode(String code) : super.fromCode(code) { + switch (code) { + case 'weak-password': + msg = 'Please enter a stronger password.'; + break; + case 'requires-recent-login': + msg = "User's last sign-in time does not meet the security threshold."; + break; + default: + this.code = 'unknown'; + msg = 'An unknown error occurred.'; + } + } +} + +/// {@macro model_parsing_failure} +class ModelParsingFailureBase extends ModelParsingFailureInterface { + ModelParsingFailureBase([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); + + ModelParsingFailureBase.fromCode(super.code) : super.fromCode(); +} + +/// {@macro delete_account_failure} +class DeleteAccountFailureBase extends DeleteAccountFailureInterface { + DeleteAccountFailureBase([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); + + DeleteAccountFailureBase.fromCode(String code) : super.fromCode(code) { + switch (code) { + case 'requires-recent-login': + msg = "User's last sign-in time does not meet the security threshold."; + break; + default: + this.code = 'unknown'; + msg = 'An unknown error occurred.'; + } + } +} diff --git a/packages/wyatt_authentication_bloc/lib/src/core/exceptions/exceptions_mock.dart b/packages/wyatt_authentication_bloc/lib/src/core/exceptions/exceptions_mock.dart new file mode 100644 index 00000000..ad8b6826 --- /dev/null +++ b/packages/wyatt_authentication_bloc/lib/src/core/exceptions/exceptions_mock.dart @@ -0,0 +1,390 @@ +// Copyright (C) 2023 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +part of 'exceptions.dart'; + +/// {@macro apply_action_code_failure} +class ApplyActionCodeFailureMock extends ApplyActionCodeFailureInterface { + ApplyActionCodeFailureMock([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); + ApplyActionCodeFailureMock.fromCode(String code) : super.fromCode(code) { + switch (code) { + case 'expired-action-code': + msg = 'Action code has expired.'; + break; + case 'invalid-action-code': + msg = 'Action code is invalid.'; + break; + case 'user-disabled': + msg = 'This user has been disabled. Please contact support for help.'; + break; + case 'user-not-found': + msg = 'Email is not found, please create an account.'; + break; + + default: + this.code = 'unknown'; + msg = 'An unknown error occurred.'; + } + } +} + +/// {@macro sign_up_with_email_and_password_failure} +class SignUpWithEmailAndPasswordFailureMock + extends SignUpWithEmailAndPasswordFailureInterface { + SignUpWithEmailAndPasswordFailureMock([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); + SignUpWithEmailAndPasswordFailureMock.fromCode(String code) + : super.fromCode(code) { + switch (code) { + case 'invalid-email': + msg = 'The email address is badly formatted.'; + break; + case 'user-disabled': + msg = 'This user has been disabled. Please contact support for help.'; + break; + case 'email-already-in-use': + msg = 'An account already exists for that email.'; + break; + case 'operation-not-allowed': + msg = 'Operation is not allowed. Please contact support.'; + break; + case 'weak-password': + msg = 'Please enter a stronger password.'; + break; + default: + this.code = 'unknown'; + msg = 'An unknown error occurred.'; + } + } +} + +/// {@macro fetch_sign_in_methods_failure} +class FetchSignInMethodsForEmailFailureMock + extends FetchSignInMethodsForEmailFailureInterface { + FetchSignInMethodsForEmailFailureMock([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); + FetchSignInMethodsForEmailFailureMock.fromCode(String code) + : super.fromCode(code) { + switch (code) { + case 'invalid-email': + msg = 'The email address is badly formatted.'; + break; + default: + this.code = 'unknown'; + msg = 'An unknown error occurred.'; + } + } +} + +/// {@macro sign_in_anonymously_failure} +class SignInAnonymouslyFailureMock + extends SignInAnonymouslyFailureInterface { + SignInAnonymouslyFailureMock([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); + SignInAnonymouslyFailureMock.fromCode(String code) + : super.fromCode(code) { + switch (code) { + case 'operation-not-allowed': + msg = 'Operation is not allowed. Please contact support.'; + break; + default: + this.code = 'unknown'; + msg = 'An unknown error occurred.'; + } + } +} + +/// {@macro sign_in_with_credential_failure} +class SignInWithCredentialFailureMock + extends SignInWithCredentialFailureInterface { + SignInWithCredentialFailureMock([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); + SignInWithCredentialFailureMock.fromCode(String code) + : super.fromCode(code) { + switch (code) { + case 'account-exists-with-different-credential': + msg = 'Account exists with different credentials.'; + break; + case 'invalid-credential': + msg = 'The credential received is malformed or has expired.'; + break; + case 'operation-not-allowed': + msg = 'Operation is not allowed. Please contact support.'; + break; + case 'user-disabled': + msg = 'This user has been disabled. Please contact support for help.'; + break; + case 'user-not-found': + msg = 'Email is not found, please create an account.'; + break; + case 'wrong-password': + msg = 'Incorrect password, please try again.'; + break; + case 'invalid-verification-code': + msg = 'The credential verification code received is invalid.'; + break; + case 'invalid-verification-id': + msg = 'The credential verification ID received is invalid.'; + break; + default: + this.code = 'unknown'; + msg = 'An unknown error occurred.'; + } + } +} + +/// {@macro sign_in_with_google_failure} +class SignInWithGoogleFailureMock + extends SignInWithCredentialFailureMock + implements SignInWithGoogleFailureInterface { + SignInWithGoogleFailureMock([super.code, super.msg]); + SignInWithGoogleFailureMock.fromCode(super.code) : super.fromCode(); +} + +/// {@macro sign_in_with_facebook_failure} +class SignInWithFacebookFailureMock + extends SignInWithCredentialFailureMock + implements SignInWithFacebookFailureInterface { + SignInWithFacebookFailureMock([super.code, super.msg]); + SignInWithFacebookFailureMock.fromCode(super.code) : super.fromCode(); +} + +/// {@macro sign_in_with_apple_failure} +class SignInWithAppleFailureMock extends SignInWithCredentialFailureMock + implements SignInWithAppleFailureInterface { + SignInWithAppleFailureMock([super.code, super.msg]); + SignInWithAppleFailureMock.fromCode(super.code) : super.fromCode(); +} + +/// {@macro sign_in_with_twitter_failure} +class SignInWithTwitterFailureMock + extends SignInWithCredentialFailureMock + implements SignInWithAppleFailureInterface { + SignInWithTwitterFailureMock([super.code, super.msg]); + SignInWithTwitterFailureMock.fromCode(super.code) : super.fromCode(); +} + +/// {@macro sign_in_with_email_link_failure} +class SignInWithEmailLinkFailureMock + extends SignInWithEmailLinkFailureInterface { + SignInWithEmailLinkFailureMock([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); + SignInWithEmailLinkFailureMock.fromCode(String code) + : super.fromCode(code) { + switch (code) { + case 'expired-action-code': + msg = 'Action code has expired.'; + break; + case 'invalid-email': + msg = 'Email is not valid or badly formatted.'; + break; + case 'user-disabled': + msg = 'This user has been disabled. Please contact support for help.'; + break; + default: + this.code = 'unknown'; + msg = 'An unknown error occurred.'; + } + } +} + +/// {@macro sign_in_with_email_and_password_failure} +class SignInWithEmailAndPasswordFailureMock + extends SignInWithEmailAndPasswordFailureInterface { + SignInWithEmailAndPasswordFailureMock([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); + SignInWithEmailAndPasswordFailureMock.fromCode(String code) + : super.fromCode(code) { + switch (code) { + case 'invalid-email': + msg = 'Email is not valid or badly formatted.'; + break; + case 'user-disabled': + msg = 'This user has been disabled. Please contact support for help.'; + break; + case 'user-not-found': + msg = 'Email is not found, please create an account.'; + break; + case 'wrong-password': + msg = 'Incorrect password, please try again.'; + break; + default: + this.code = 'unknown'; + msg = 'An unknown error occurred.'; + } + } +} + +/// {@macro send_email_verification_failure} +class SendEmailVerificationFailureMock + extends SendEmailVerificationFailureInterface { + SendEmailVerificationFailureMock([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); + + SendEmailVerificationFailureMock.fromCode(super.code) : super.fromCode(); +} + +/// {@macro send_password_reset_email_failure} +class SendPasswordResetEmailFailureMock + extends SendPasswordResetEmailFailureInterface { + SendPasswordResetEmailFailureMock([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); + SendPasswordResetEmailFailureMock.fromCode(super.code) : super.fromCode(); +} + +/// {@macro send_sign_in_link_email_failure} +class SendSignInLinkEmailFailureMock + extends SendSignInLinkEmailFailureInterface { + SendSignInLinkEmailFailureMock([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); + + SendSignInLinkEmailFailureMock.fromCode(super.code) : super.fromCode(); +} + +/// {@macro confirm_password_reset_failure} +class ConfirmPasswordResetFailureMock + extends ConfirmPasswordResetFailureInterface { + ConfirmPasswordResetFailureMock([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); + + ConfirmPasswordResetFailureMock.fromCode(super.code) : super.fromCode(); +} + +/// {@macro verify_password_reset_code_failure} +class VerifyPasswordResetCodeFailureMock + extends VerifyPasswordResetCodeFailureInterface { + VerifyPasswordResetCodeFailureMock([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); + + VerifyPasswordResetCodeFailureMock.fromCode(super.code) + : super.fromCode(); +} + +/// {@macro refresh_failure} +class RefreshFailureMock extends RefreshFailureInterface { + RefreshFailureMock([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); + RefreshFailureMock.fromCode(super.code) : super.fromCode(); +} + +/// {@macro sign_out_failure} +class SignOutFailureMock extends SignOutFailureInterface { + SignOutFailureMock([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); + + SignOutFailureMock.fromCode(super.code) : super.fromCode(); +} + +/// {@macro reauthenticate_failure} +class ReauthenticateFailureMock extends ReauthenticateFailureInterface { + ReauthenticateFailureMock([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); + ReauthenticateFailureMock.fromCode(String code) : super.fromCode(code) { + switch (code) { + case 'user-mismatch': + msg = 'Given credential does not correspond to the user.'; + break; + case 'user-not-found': + msg = 'User is not found, please create an account.'; + break; + case 'invalid-credential': + msg = 'The credential received is malformed or has expired.'; + break; + case 'invalid-email': + msg = 'Email is not valid or badly formatted.'; + break; + case 'wrong-password': + msg = 'Incorrect password, please try again.'; + break; + case 'invalid-verification-code': + msg = 'The credential verification code received is invalid.'; + break; + case 'invalid-verification-id': + msg = 'The credential verification ID received is invalid.'; + break; + default: + this.code = 'unknown'; + msg = 'An unknown error occurred.'; + } + } +} + +/// {@macro update_email_failure} +class UpdateEmailFailureMock extends UpdateEmailFailureInterface { + UpdateEmailFailureMock([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); + UpdateEmailFailureMock.fromCode(String code) : super.fromCode(code) { + switch (code) { + case 'invalid-email': + msg = 'Email is not valid or badly formatted.'; + break; + case 'email-already-in-use': + msg = 'An account already exists for that email.'; + break; + case 'requires-recent-login': + msg = "User's last sign-in time does not meet the security threshold."; + break; + default: + this.code = 'unknown'; + msg = 'An unknown error occurred.'; + } + } +} + +/// {@macro update_password_failure} +class UpdatePasswordFailureMock extends UpdatePasswordFailureInterface { + UpdatePasswordFailureMock([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); + UpdatePasswordFailureMock.fromCode(String code) : super.fromCode(code) { + switch (code) { + case 'weak-password': + msg = 'Please enter a stronger password.'; + break; + case 'requires-recent-login': + msg = "User's last sign-in time does not meet the security threshold."; + break; + default: + this.code = 'unknown'; + msg = 'An unknown error occurred.'; + } + } +} + +/// {@macro model_parsing_failure} +class ModelParsingFailureMock extends ModelParsingFailureInterface { + ModelParsingFailureMock([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); + + ModelParsingFailureMock.fromCode(super.code) : super.fromCode(); +} + +/// {@macro delete_account_failure} +class DeleteAccountFailureMock extends DeleteAccountFailureInterface { + DeleteAccountFailureMock([String? code, String? msg]) + : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); + + DeleteAccountFailureMock.fromCode(String code) : super.fromCode(code) { + switch (code) { + case 'requires-recent-login': + msg = "User's last sign-in time does not meet the security threshold."; + break; + default: + this.code = 'unknown'; + msg = 'An unknown error occurred.'; + } + } +} diff --git a/packages/wyatt_authentication_bloc/lib/src/data/data_sources/local/authentication_secure_storage_cache_data_source_impl.dart b/packages/wyatt_authentication_bloc/lib/src/data/data_sources/local/authentication_secure_storage_cache_data_source_impl.dart new file mode 100644 index 00000000..a59f3383 --- /dev/null +++ b/packages/wyatt_authentication_bloc/lib/src/data/data_sources/local/authentication_secure_storage_cache_data_source_impl.dart @@ -0,0 +1,75 @@ +// Copyright (C) 2023 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +import 'package:flutter_secure_storage/flutter_secure_storage.dart'; +import 'package:wyatt_authentication_bloc/src/core/constants/storage.dart'; +import 'package:wyatt_authentication_bloc/wyatt_authentication_bloc.dart'; + +/// {@template authentication_secure_storage_cache_data_source_impl} +/// A data source that manages the cache strategy. +/// This implementation uses Secure Storage. +/// {@endtemplate} +class AuthenticationSecureStorageCacheDataSourceImpl + extends AuthenticationCacheDataSource { + /// {@macro authentication_secure_storage_cache_data_source_impl} + const AuthenticationSecureStorageCacheDataSourceImpl({ + FlutterSecureStorage? secureStorage, + }) : _secureStorage = secureStorage ?? const FlutterSecureStorage(); + + final FlutterSecureStorage _secureStorage; + + @override + Future cacheAccount(Account account) async { + await _secureStorage.write( + key: AuthStorage.id, + value: account.id, + ); + await _secureStorage.write( + key: AuthStorage.email, + value: account.email, + ); + await _secureStorage.write( + key: AuthStorage.accessToken, + value: account.accessToken, + ); + } + + @override + Future getCachedAccount() async { + final id = await _secureStorage.read(key: AuthStorage.id); + final email = await _secureStorage.read(key: AuthStorage.email); + final accessToken = await _secureStorage.read(key: AuthStorage.accessToken); + + if (id == null || email == null || accessToken == null) { + return null; + } + + final currentAccount = AccountModel.fromSecureStorage( + id: id, + email: email, + accessToken: accessToken, + ); + + return currentAccount; + } + + @override + Future removeCachedAccount() async { + await _secureStorage.delete(key: AuthStorage.id); + await _secureStorage.delete(key: AuthStorage.email); + await _secureStorage.delete(key: AuthStorage.accessToken); + } +} diff --git a/packages/wyatt_authentication_bloc/lib/src/data/data_sources/local/local.dart b/packages/wyatt_authentication_bloc/lib/src/data/data_sources/local/local.dart index ba60b5e6..b9bf04e1 100644 --- a/packages/wyatt_authentication_bloc/lib/src/data/data_sources/local/local.dart +++ b/packages/wyatt_authentication_bloc/lib/src/data/data_sources/local/local.dart @@ -15,4 +15,5 @@ // along with this program. If not, see . export 'authentication_firebase_cache_data_source_impl.dart'; +export 'authentication_secure_storage_cache_data_source_impl.dart'; export 'authentication_session_data_source_impl.dart'; diff --git a/packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/authentication_base_data_source.dart b/packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/authentication_base_data_source.dart new file mode 100644 index 00000000..bbdd8dd9 --- /dev/null +++ b/packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/authentication_base_data_source.dart @@ -0,0 +1,106 @@ +// Copyright (C) 2023 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +import 'package:wyatt_authentication_bloc/wyatt_authentication_bloc.dart'; + +/// {@template authentication_base_data_source} +/// Base class for custom [AuthenticationRemoteDataSource] implementations. +/// It implements all methods as throwing [UnimplementedError]s. +/// {@endtemplate} +class AuthenticationBaseDataSource + extends AuthenticationRemoteDataSource { + /// {@macro authentication_base_data_source} + const AuthenticationBaseDataSource(); + + @override + Future confirmPasswordReset({ + required String code, + required String newPassword, + }) { + throw UnimplementedError(); + } + + @override + Future delete() { + throw UnimplementedError(); + } + + @override + Future reauthenticate() { + throw UnimplementedError(); + } + + @override + Future refresh() { + throw UnimplementedError(); + } + + @override + Future sendEmailVerification() { + throw UnimplementedError(); + } + + @override + Future sendPasswordResetEmail({required String email}) { + throw UnimplementedError(); + } + + @override + Future signInAnonymously() { + throw UnimplementedError(); + } + + @override + Future signInWithEmailAndPassword({ + required String email, + required String password, + }) { + throw UnimplementedError(); + } + + @override + Future signInWithGoogle() { + throw UnimplementedError(); + } + + @override + Future signOut() { + throw UnimplementedError(); + } + + @override + Future signUpWithEmailAndPassword({ + required String email, + required String password, + }) { + throw UnimplementedError(); + } + + @override + Future updateEmail({required String email}) { + throw UnimplementedError(); + } + + @override + Future updatePassword({required String password}) { + throw UnimplementedError(); + } + + @override + Future verifyPasswordResetCode({required String code}) { + throw UnimplementedError(); + } +} diff --git a/packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/authentication_mock_data_source_impl.dart b/packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/authentication_mock_data_source_impl.dart new file mode 100644 index 00000000..ff876dd5 --- /dev/null +++ b/packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/authentication_mock_data_source_impl.dart @@ -0,0 +1,201 @@ +// Copyright (C) 2023 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +import 'dart:math'; + +import 'package:wyatt_authentication_bloc/wyatt_authentication_bloc.dart'; +import 'package:wyatt_type_utils/wyatt_type_utils.dart'; + +/// {@template authentication_mock_data_source_impl} +/// Implementation of [AuthenticationRemoteDataSource] using Mocks. +/// {@endtemplate} +class AuthenticationMockDataSourceImpl + extends AuthenticationRemoteDataSource { + /// {@macro authentication_mock_data_source_impl} + AuthenticationMockDataSourceImpl({ + this.mockData = const { + 'test@test.fr': Pair('test12', '1'), + 'alice@test.fr': Pair('alice12', '2'), + 'bob@test.fr': Pair('bob1234', '3'), + }, + this.accessToken = 'mock_access_token', + }); + + /// Mock data. + /// Format: > + final Map> mockData; + + /// Current user. + Account? _currentUser; + + /// Access token. + final String accessToken; + + /// A random delay to simulate network latency. + Future _randomDelay() async { + await Future.delayed( + Duration(milliseconds: Random().nextInt(400) + 200), + ); + return; + } + + // SignUp/SignIn methods ==================================================== + + /// {@macro signup_pwd} + @override + Future signUpWithEmailAndPassword({ + required String email, + required String password, + }) async { + await _randomDelay(); + mockData[email] = Pair(password, '4'); + + return _currentUser = Account( + id: '4', + isAnonymous: false, + emailVerified: false, + providerId: 'mock', + email: email, + accessToken: accessToken, + ); + } + + /// {@macro signin_pwd} + @override + Future signInWithEmailAndPassword({ + required String email, + required String password, + }) async { + await _randomDelay(); + final pair = mockData[email]; + + if (pair == null || pair.left != password) { + throw SignInWithEmailAndPasswordFailureMock(); + } + + return _currentUser = Account( + id: pair.right!, + isAnonymous: false, + emailVerified: true, + providerId: 'mock', + email: email, + accessToken: accessToken, + ); + } + + /// {@macro signin_anom} + @override + Future signInAnonymously() async { + await _randomDelay(); + return _currentUser = Account( + id: '5', + isAnonymous: true, + emailVerified: false, + providerId: 'mock', + accessToken: accessToken, + ); + } + + /// {@macro signin_google} + @override + Future signInWithGoogle() async { + await _randomDelay(); + return _currentUser = Account( + id: '6', + isAnonymous: false, + emailVerified: true, + providerId: 'google.com', + email: 'mock@gmail.com', + accessToken: accessToken, + ); + } + + /// {@macro signout} + @override + Future signOut() async { + await _randomDelay(); + _currentUser = null; + } + + // Account management methods =============================================== + + /// {@macro refresh} + @override + Future refresh() async { + await _randomDelay(); + if (_currentUser == null) { + throw RefreshFailureMock(); + } + return _currentUser!; + } + + /// {@macro reauthenticate} + @override + Future reauthenticate() async { + await _randomDelay(); + if (_currentUser == null) { + throw ReauthenticateFailureMock(); + } + return _currentUser!; + } + + /// {@macro update_email} + @override + Future updateEmail({required String email}) async { + throw UnimplementedError(); + } + + /// {@macro update_password} + @override + Future updatePassword({required String password}) async { + throw UnimplementedError(); + } + + /// {@macro delete} + @override + Future delete() async { + throw UnimplementedError(); + } + + // Email related stuff ====================================================== + + /// {@macro send_email_verification} + @override + Future sendEmailVerification() async { + throw UnimplementedError(); + } + + /// {@macro send_password_reset_email} + @override + Future sendPasswordResetEmail({required String email}) async { + throw UnimplementedError(); + } + + /// {@macro confirm_password_reset} + @override + Future confirmPasswordReset({ + required String code, + required String newPassword, + }) async { + throw UnimplementedError(); + } + + /// {@macro verify_password_reset_code} + @override + Future verifyPasswordResetCode({required String code}) async { + throw UnimplementedError(); + } +} diff --git a/packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/remote.dart b/packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/remote.dart index 5a8c8679..e76b675f 100644 --- a/packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/remote.dart +++ b/packages/wyatt_authentication_bloc/lib/src/data/data_sources/remote/remote.dart @@ -14,4 +14,6 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . +export 'authentication_base_data_source.dart'; export 'authentication_firebase_data_source_impl.dart'; +export 'authentication_mock_data_source_impl.dart'; diff --git a/packages/wyatt_authentication_bloc/lib/src/data/models/account_model.dart b/packages/wyatt_authentication_bloc/lib/src/data/models/account_model.dart index ebc29f93..683dd500 100644 --- a/packages/wyatt_authentication_bloc/lib/src/data/models/account_model.dart +++ b/packages/wyatt_authentication_bloc/lib/src/data/models/account_model.dart @@ -77,6 +77,30 @@ class AccountModel extends Account { } } + /// {@macro account_model} + factory AccountModel.fromSecureStorage({ + required String? id, + required String? email, + required String? accessToken, + }) { + if (id != null && email != null && accessToken != null) { + return AccountModel._( + user: null, + id: id, + emailVerified: false, + isAnonymous: false, + providerId: '', + email: email, + accessToken: accessToken, + ); + } else { + throw Exception( + 'null-id-email-access-token' + 'id, email, and accessToken cannot be null', + ); + } + } + const AccountModel._({ required this.user, required super.id, diff --git a/packages/wyatt_authentication_bloc/lib/src/data/repositories/authentication_repository_impl.dart b/packages/wyatt_authentication_bloc/lib/src/data/repositories/authentication_repository_impl.dart index 652cca7a..9b8bc99a 100644 --- a/packages/wyatt_authentication_bloc/lib/src/data/repositories/authentication_repository_impl.dart +++ b/packages/wyatt_authentication_bloc/lib/src/data/repositories/authentication_repository_impl.dart @@ -16,8 +16,6 @@ import 'package:wyatt_architecture/wyatt_architecture.dart'; import 'package:wyatt_authentication_bloc/src/core/utils/forms.dart'; -import 'package:wyatt_authentication_bloc/src/domain/data_sources/local/authentication_cache_data_source.dart'; -import 'package:wyatt_authentication_bloc/src/domain/data_sources/local/authentication_session_data_source.dart'; import 'package:wyatt_authentication_bloc/src/domain/domain.dart'; import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; import 'package:wyatt_type_utils/wyatt_type_utils.dart'; @@ -152,6 +150,8 @@ class AuthenticationRepositoryImpl email: email, password: password, ); + // Cache the account + await authenticationCacheDataSource.cacheAccount(account); return account; }, (error) => error, @@ -170,6 +170,8 @@ class AuthenticationRepositoryImpl email: email, password: password, ); + // Cache the account + await authenticationCacheDataSource.cacheAccount(account); return account; }, (error) => error, @@ -194,6 +196,8 @@ class AuthenticationRepositoryImpl () async { final account = await authenticationRemoteDataSource.signInWithGoogle(); + // Cache the account + await authenticationCacheDataSource.cacheAccount(account); return account; }, (error) => error, @@ -205,6 +209,8 @@ class AuthenticationRepositoryImpl Result.tryCatchAsync( () async { await authenticationRemoteDataSource.signOut(); + // Remove the cached account + await authenticationCacheDataSource.removeCachedAccount(); }, (error) => error, ); @@ -217,6 +223,8 @@ class AuthenticationRepositoryImpl Result.tryCatchAsync( () async { final account = await authenticationRemoteDataSource.refresh(); + // Cache the account + await authenticationCacheDataSource.cacheAccount(account); return account; }, (error) => error, @@ -228,6 +236,8 @@ class AuthenticationRepositoryImpl Result.tryCatchAsync( () async { final account = await authenticationRemoteDataSource.reauthenticate(); + // Cache the account + await authenticationCacheDataSource.cacheAccount(account); return account; }, (error) => error, @@ -240,6 +250,8 @@ class AuthenticationRepositoryImpl () async { final account = await authenticationRemoteDataSource.updateEmail(email: email); + // Cache the account + await authenticationCacheDataSource.cacheAccount(account); return account; }, (error) => error, @@ -253,6 +265,8 @@ class AuthenticationRepositoryImpl final account = await authenticationRemoteDataSource.updatePassword( password: password, ); + // Cache the account + await authenticationCacheDataSource.cacheAccount(account); return account; }, (error) => error, @@ -262,7 +276,11 @@ class AuthenticationRepositoryImpl @override FutureOrResult delete() => Result.tryCatchAsync( - () async => authenticationRemoteDataSource.delete(), + () async { + await authenticationRemoteDataSource.delete(); + // Remove the cached account + await authenticationCacheDataSource.removeCachedAccount(); + }, (error) => error, ); diff --git a/packages/wyatt_authentication_bloc/pubspec.yaml b/packages/wyatt_authentication_bloc/pubspec.yaml index a97dba05..429aa524 100644 --- a/packages/wyatt_authentication_bloc/pubspec.yaml +++ b/packages/wyatt_authentication_bloc/pubspec.yaml @@ -29,6 +29,8 @@ dependencies: wyatt_type_utils: hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub/ version: ^0.0.4 + flutter_secure_storage: ^8.0.0 + http: ^0.13.5 dev_dependencies: flutter_test: { sdk: flutter } -- 2.47.2 From a5cc20d05aa68758bea186b9b9de57cdad301a56 Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Thu, 13 Apr 2023 15:08:45 +0200 Subject: [PATCH 25/47] feat(i18n): change gitignore for symbolic link --- .gitignore | 468 ++++++++++++++++++++++++++++++--- packages/wyatt_i18n/.gitignore | 8 +- 2 files changed, 428 insertions(+), 48 deletions(-) mode change 100644 => 120000 packages/wyatt_i18n/.gitignore diff --git a/.gitignore b/.gitignore index a0057b37..f9b92095 100644 --- a/.gitignore +++ b/.gitignore @@ -1,7 +1,47 @@ # File created using '.gitignore Generator' for Visual Studio Code: https://bit.ly/vscode-gig +# Created by https://www.toptal.com/developers/gitignore/api/visualstudiocode,macos,android,androidstudio,dart,fastlane,firebase,flutter,java,jetbrains+all,kotlin,objective-c,swift,xcode +# Edit at https://www.toptal.com/developers/gitignore?templates=visualstudiocode,macos,android,androidstudio,dart,fastlane,firebase,flutter,java,jetbrains+all,kotlin,objective-c,swift,xcode -# Created by https://www.toptal.com/developers/gitignore/api/visualstudiocode,macos,dart,flutter,linux,windows -# Edit at https://www.toptal.com/developers/gitignore?templates=visualstudiocode,macos,dart,flutter,linux,windows +### Android ### +# Gradle files +.gradle/ +build/ + +# Local configuration file (sdk path, etc) +local.properties + +# Log/OS Files +*.log + +# Android Studio generated files and folders +captures/ +.externalNativeBuild/ +.cxx/ +*.apk +output.json + +# IntelliJ +*.iml +.idea/ +misc.xml +deploymentTargetDropDown.xml +render.experimental.xml + +# Keystore files +*.jks +*.keystore + +# Google Services (e.g. APIs or Firebase) +google-services.json + +# Android Profiling +*.hprof + +### Android Patch ### +gen-external-apklibs + +# Replacement of .externalNativeBuild directories introduced +# with Android Studio 3.5. ### Dart ### # See https://www.dartlang.org/guides/libraries/private-files @@ -9,7 +49,6 @@ # Files and directories created by pub .dart_tool/ .packages -build/ # If you're building an application, you may want to check-in your pubspec.lock pubspec.lock @@ -18,9 +57,9 @@ pubspec.lock # Avoid committing generated Javascript files: *.dart.js -*.info.json # Produced by the --dump-info flag. -*.js # When generated by dart2js. Don't specify *.js if your - # project includes source files written in JavaScript. +*.info.json # Produced by the --dump-info flag. +*.js # When generated by dart2js. Don't specify *.js if your +# project includes source files written in JavaScript. *.js_ *.js.deps *.js.map @@ -32,14 +71,47 @@ pubspec.lock # dotenv environment variables file .env +### fastlane ### +# fastlane - A streamlined workflow tool for Cocoa deployment +# +# It is recommended to not store the screenshots in the git repo. Instead, use fastlane to re-generate the +# screenshots whenever they are needed. +# For more information about the recommended setup visit: +# https://docs.fastlane.tools/best-practices/source-control/#source-control + +# fastlane specific +**/fastlane/report.xml + +# deliver temporary files +**/fastlane/Preview.html + +# snapshot generated screenshots +**/fastlane/screenshots + +# scan temporary files +**/fastlane/test_output + +# Fastlane.swift runner binary +**/fastlane/FastlaneRunner + +### Firebase ### +.idea +**/node_modules/* +**/.firebaserc + +### Firebase Patch ### +.runtimeconfig.json +.firebase/ + ### Flutter ### # Flutter/Dart/Pub related -.fvm/ +**/doc/api/ +.fvm/flutter_sdk .pub-cache/ .pub/ coverage/ lib/generated_plugin_registrant.dart -# For library packages, don’t commit the pubspec.lock file. +# For library packages, don't commit the pubspec.lock file. # Regenerating the pubspec.lock file lets you test your package against the latest compatible versions of its dependencies. # See https://dart.dev/guides/libraries/private-files#pubspeclock #pubspec.lock @@ -90,20 +162,131 @@ lib/generated_plugin_registrant.dart !**/ios/**/default.perspectivev3 !/packages/flutter_tools/test/data/dart_dependencies_test/**/.packages -### Linux ### -*~ +### Java ### +# Compiled class file +*.class -# temporary files which can be created if a process still has a handle open of a deleted file -.fuse_hidden* +# Log file -# KDE directory preferences -.directory +# BlueJ files +*.ctxt -# Linux trash folder which might appear on any partition or disk -.Trash-* +# Mobile Tools for Java (J2ME) +.mtj.tmp/ -# .nfs files are created when an open file is removed but is still being accessed -.nfs* +# Package Files # +*.jar +*.war +*.nar +*.ear +*.zip +*.tar.gz +*.rar + +# virtual machine crash logs, see http://www.java.com/en/download/help/error_hotspot.xml +hs_err_pid* +replay_pid* + +### JetBrains+all ### +# Covers JetBrains IDEs: IntelliJ, RubyMine, PhpStorm, AppCode, PyCharm, CLion, Android Studio, WebStorm and Rider +# Reference: https://intellij-support.jetbrains.com/hc/en-us/articles/206544839 + +# User-specific stuff +.idea/**/workspace.xml +.idea/**/tasks.xml +.idea/**/usage.statistics.xml +.idea/**/dictionaries +.idea/**/shelf + +# AWS User-specific +.idea/**/aws.xml + +# Generated files +.idea/**/contentModel.xml + +# Sensitive or high-churn files +.idea/**/dataSources/ +.idea/**/dataSources.ids +.idea/**/dataSources.local.xml +.idea/**/sqlDataSources.xml +.idea/**/dynamic.xml +.idea/**/uiDesigner.xml +.idea/**/dbnavigator.xml + +# Gradle +.idea/**/gradle.xml +.idea/**/libraries + +# Gradle and Maven with auto-import +# When using Gradle or Maven with auto-import, you should exclude module files, +# since they will be recreated, and may cause churn. Uncomment if using +# auto-import. +# .idea/artifacts +# .idea/compiler.xml +# .idea/jarRepositories.xml +# .idea/modules.xml +# .idea/*.iml +# .idea/modules +# *.iml +# *.ipr + +# CMake +cmake-build-*/ + +# Mongo Explorer plugin +.idea/**/mongoSettings.xml + +# File-based project format +*.iws + +# IntelliJ +out/ + +# mpeltonen/sbt-idea plugin +.idea_modules/ + +# JIRA plugin +atlassian-ide-plugin.xml + +# Cursive Clojure plugin +.idea/replstate.xml + +# SonarLint plugin +.idea/sonarlint/ + +# Crashlytics plugin (for Android Studio and IntelliJ) +com_crashlytics_export_strings.xml +crashlytics.properties +crashlytics-build.properties +fabric.properties + +# Editor-based Rest Client +.idea/httpRequests + +# Android studio 3.1+ serialized cache file +.idea/caches/build_file_checksums.ser + +### JetBrains+all Patch ### +# Ignore everything but code style settings and run configurations +# that are supposed to be shared within teams. + +.idea/* + +!.idea/codeStyles +!.idea/runConfigurations + +### Kotlin ### +# Compiled class file + +# Log file + +# BlueJ files + +# Mobile Tools for Java (J2ME) + +# Package Files # + +# virtual machine crash logs, see http://www.java.com/en/download/help/error_hotspot.xml ### macOS ### # General @@ -114,7 +297,6 @@ lib/generated_plugin_registrant.dart # Icon must end with two \r Icon - # Thumbnails ._* @@ -138,6 +320,116 @@ Temporary Items # iCloud generated files *.icloud +### Objective-C ### +# Xcode +# gitignore contributors: remember to update Global/Xcode.gitignore, Objective-C.gitignore & Swift.gitignore + +## User settings +xcuserdata/ + +## compatibility with Xcode 8 and earlier (ignoring not required starting Xcode 9) +*.xcscmblueprint +*.xccheckout + +## compatibility with Xcode 3 and earlier (ignoring not required starting Xcode 4) +DerivedData/ +*.moved-aside +*.pbxuser +!default.pbxuser +*.mode1v3 +!default.mode1v3 +*.mode2v3 +!default.mode2v3 +*.perspectivev3 +!default.perspectivev3 + +## Obj-C/Swift specific +*.hmap + +## App packaging +*.ipa +*.dSYM.zip +*.dSYM + +# CocoaPods +# We recommend against adding the Pods directory to your .gitignore. However +# you should judge for yourself, the pros and cons are mentioned at: +# https://guides.cocoapods.org/using/using-cocoapods.html#should-i-check-the-pods-directory-into-source-control +# Pods/ +# Add this line if you want to avoid checking in source code from the Xcode workspace +# *.xcworkspace + +# Carthage +# Add this line if you want to avoid checking in source code from Carthage dependencies. +# Carthage/Checkouts + +Carthage/Build/ + +# fastlane +# It is recommended to not store the screenshots in the git repo. +# Instead, use fastlane to re-generate the screenshots whenever they are needed. +# For more information about the recommended setup visit: +# https://docs.fastlane.tools/best-practices/source-control/#source-control + +fastlane/report.xml +fastlane/Preview.html +fastlane/screenshots/**/*.png +fastlane/test_output + +# Code Injection +# After new code Injection tools there's a generated folder /iOSInjectionProject +# https://github.com/johnno1962/injectionforxcode + +iOSInjectionProject/ + +### Objective-C Patch ### + +### Swift ### +# Xcode +# gitignore contributors: remember to update Global/Xcode.gitignore, Objective-C.gitignore & Swift.gitignore + +## Playgrounds +timeline.xctimeline +playground.xcworkspace + +# Swift Package Manager +# Add this line if you want to avoid checking in source code from Swift Package Manager dependencies. +# Packages/ +# Package.pins +# Package.resolved +# *.xcodeproj +# Xcode automatically generates this directory with a .xcworkspacedata file and xcuserdata +# hence it is not needed unless you have added a package configuration file to your project +# .swiftpm + +.build/ + +# CocoaPods +# We recommend against adding the Pods directory to your .gitignore. However +# you should judge for yourself, the pros and cons are mentioned at: +# https://guides.cocoapods.org/using/using-cocoapods.html#should-i-check-the-pods-directory-into-source-control +# Pods/ +# Add this line if you want to avoid checking in source code from the Xcode workspace +# *.xcworkspace + +# Carthage +# Add this line if you want to avoid checking in source code from Carthage dependencies. +# Carthage/Checkouts + +# Accio dependency management +Dependencies/ +.accio/ + +# fastlane +# It is recommended to not store the screenshots in the git repo. +# Instead, use fastlane to re-generate the screenshots whenever they are needed. +# For more information about the recommended setup visit: +# https://docs.fastlane.tools/best-practices/source-control/#source-control + +# Code Injection +# After new code Injection tools there's a generated folder /iOSInjectionProject +# https://github.com/johnno1962/injectionforxcode + ### VisualStudioCode ### .vscode/* !.vscode/settings.json @@ -157,35 +449,129 @@ Temporary Items .history .ionide -# Support for Project snippet scope +### Xcode ### -### Windows ### -# Windows thumbnail cache files -Thumbs.db -Thumbs.db:encryptable -ehthumbs.db -ehthumbs_vista.db +## Xcode 8 and earlier -# Dump file -*.stackdump +### Xcode Patch ### +*.xcodeproj/* +!*.xcodeproj/project.pbxproj +!*.xcodeproj/xcshareddata/ +!*.xcodeproj/project.xcworkspace/ +!*.xcworkspace/contents.xcworkspacedata +/*.gcno +**/xcshareddata/WorkspaceSettings.xcsettings -# Folder config file -[Dd]esktop.ini +### AndroidStudio ### +# Covers files to be ignored for android development using Android Studio. -# Recycle Bin used on file shares -$RECYCLE.BIN/ +# Built application files +*.ap_ +*.aab -# Windows Installer files -*.cab -*.msi -*.msix -*.msm -*.msp +# Files for the ART/Dalvik VM +*.dex -# Windows shortcuts -*.lnk +# Java class files -# End of https://www.toptal.com/developers/gitignore/api/visualstudiocode,macos,dart,flutter,linux,windows +# Generated files +bin/ +gen/ + +# Gradle files +.gradle + +# Signing files +.signing/ + +# Local configuration file (sdk path, etc) + +# Proguard folder generated by Eclipse +proguard/ + +# Log Files + +# Android Studio +/*/build/ +/*/local.properties +/*/out +/*/*/build +/*/*/production +.navigation/ +*.ipr +*~ +*.swp + +# Keystore files + +# Google Services (e.g. APIs or Firebase) +# google-services.json + +# Android Patch + +# External native build folder generated in Android Studio 2.2 and later +.externalNativeBuild + +# NDK +obj/ + +# IntelliJ IDEA +/out/ + +# User-specific configurations +.idea/caches/ +.idea/libraries/ +.idea/shelf/ +.idea/workspace.xml +.idea/tasks.xml +.idea/.name +.idea/compiler.xml +.idea/copyright/profiles_settings.xml +.idea/encodings.xml +.idea/misc.xml +.idea/modules.xml +.idea/scopes/scope_settings.xml +.idea/dictionaries +.idea/vcs.xml +.idea/jsLibraryMappings.xml +.idea/datasources.xml +.idea/dataSources.ids +.idea/sqlDataSources.xml +.idea/dynamic.xml +.idea/uiDesigner.xml +.idea/assetWizardSettings.xml +.idea/gradle.xml +.idea/jarRepositories.xml +.idea/navEditor.xml + +# Legacy Eclipse project files +.classpath +.project +.cproject +.settings/ + +# Mobile Tools for Java (J2ME) + +# Package Files # + +# virtual machine crash logs (Reference: http://www.java.com/en/download/help/error_hotspot.xml) + +## Plugin-specific files: + +# mpeltonen/sbt-idea plugin + +# JIRA plugin + +# Mongo Explorer plugin +.idea/mongoSettings.xml + +# Crashlytics plugin (for Android Studio and IntelliJ) + +### AndroidStudio Patch ### + +!/gradle/wrapper/gradle-wrapper.jar + +# End of https://www.toptal.com/developers/gitignore/api/visualstudiocode,macos,android,androidstudio,dart,fastlane,firebase,flutter,java,jetbrains+all,kotlin,objective-c,swift,xcode # Custom rules (everything added below won't be overriden by 'Generate .gitignore File' if you use 'Update' option) diff --git a/packages/wyatt_i18n/.gitignore b/packages/wyatt_i18n/.gitignore deleted file mode 100644 index 3cceda55..00000000 --- a/packages/wyatt_i18n/.gitignore +++ /dev/null @@ -1,7 +0,0 @@ -# https://dart.dev/guides/libraries/private-files -# Created by `dart pub` -.dart_tool/ - -# Avoid committing pubspec.lock for library packages; see -# https://dart.dev/guides/libraries/private-files#pubspeclock. -pubspec.lock diff --git a/packages/wyatt_i18n/.gitignore b/packages/wyatt_i18n/.gitignore new file mode 120000 index 00000000..6ef08f9d --- /dev/null +++ b/packages/wyatt_i18n/.gitignore @@ -0,0 +1 @@ +../../.gitignore \ No newline at end of file -- 2.47.2 From 6f585cf7ee3962f6d63ac89d62e0d18d819a82a2 Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Thu, 13 Apr 2023 15:36:03 +0200 Subject: [PATCH 26/47] chore: add scripts to clean license, authors --- AUTHORS | 4 +- packages/wyatt_analysis/.gitignore | 11 +- packages/wyatt_analysis/AUTHORS | 8 +- packages/wyatt_analysis/LICENSE | 675 +---------------- packages/wyatt_architecture/.gitignore | 134 +--- packages/wyatt_architecture/AUTHORS | 9 +- packages/wyatt_architecture/LICENSE | 675 +---------------- packages/wyatt_authentication_bloc/.gitignore | 31 +- packages/wyatt_authentication_bloc/AUTHORS | 8 +- packages/wyatt_authentication_bloc/LICENSE | 675 +---------------- packages/wyatt_bloc_helper/.gitignore | 11 +- packages/wyatt_bloc_helper/AUTHORS | 9 +- packages/wyatt_bloc_helper/LICENSE | 675 +---------------- packages/wyatt_bloc_layout/.gitignore | 134 +--- packages/wyatt_bloc_layout/AUTHORS | 9 +- packages/wyatt_bloc_layout/LICENSE | 675 +---------------- .../.gitignore | 8 +- .../AUTHORS | 1 + .../LICENSE | 1 + .../wyatt_component_copy_with_gen/.gitignore | 8 +- .../wyatt_component_copy_with_gen/AUTHORS | 1 + .../wyatt_component_copy_with_gen/LICENSE | 1 + packages/wyatt_crud_bloc/.gitignore | 134 +--- packages/wyatt_crud_bloc/AUTHORS | 1 + packages/wyatt_crud_bloc/LICENSE | 675 +---------------- .../.gitignore | 1 + .../wyatt_deferred_widget_annotation/AUTHORS | 1 + .../wyatt_deferred_widget_annotation/LICENSE | 1 + packages/wyatt_deferred_widget_gen/.gitignore | 1 + packages/wyatt_deferred_widget_gen/AUTHORS | 1 + packages/wyatt_deferred_widget_gen/LICENSE | 1 + packages/wyatt_form_bloc/.gitignore | 11 +- packages/wyatt_form_bloc/AUTHORS | 8 +- packages/wyatt_form_bloc/LICENSE | 693 +----------------- packages/wyatt_http_client/.gitignore | 11 +- packages/wyatt_http_client/AUTHORS | 8 +- packages/wyatt_http_client/LICENSE | 675 +---------------- packages/wyatt_i18n/AUTHORS | 8 +- packages/wyatt_i18n/LICENSE | 675 +---------------- packages/wyatt_notification_bloc/.gitignore | 11 +- packages/wyatt_notification_bloc/AUTHORS | 1 + packages/wyatt_notification_bloc/LICENSE | 1 + packages/wyatt_type_utils/.gitignore | 134 +--- packages/wyatt_type_utils/AUTHORS | 9 +- packages/wyatt_type_utils/LICENSE | 675 +---------------- packages/wyatt_ui_components/.gitignore | 134 +--- packages/wyatt_ui_components/AUTHORS | 9 +- packages/wyatt_ui_components/LICENSE | 675 +---------------- packages/wyatt_ui_kit/.gitignore | 8 +- packages/wyatt_ui_kit/AUTHORS | 1 + packages/wyatt_ui_kit/LICENSE | 1 + packages/wyatt_ui_layout/.gitignore | 134 +--- packages/wyatt_ui_layout/AUTHORS | 9 +- packages/wyatt_ui_layout/LICENSE | 675 +---------------- scripts/clean_gitignore.sh | 44 ++ scripts/symbolic_links.sh | 52 ++ 56 files changed, 151 insertions(+), 9090 deletions(-) mode change 100644 => 120000 packages/wyatt_analysis/.gitignore mode change 100644 => 120000 packages/wyatt_analysis/AUTHORS mode change 100644 => 120000 packages/wyatt_analysis/LICENSE mode change 100644 => 120000 packages/wyatt_architecture/.gitignore mode change 100644 => 120000 packages/wyatt_architecture/AUTHORS mode change 100644 => 120000 packages/wyatt_architecture/LICENSE mode change 100644 => 120000 packages/wyatt_authentication_bloc/.gitignore mode change 100644 => 120000 packages/wyatt_authentication_bloc/AUTHORS mode change 100644 => 120000 packages/wyatt_authentication_bloc/LICENSE mode change 100644 => 120000 packages/wyatt_bloc_helper/.gitignore mode change 100644 => 120000 packages/wyatt_bloc_helper/AUTHORS mode change 100644 => 120000 packages/wyatt_bloc_helper/LICENSE mode change 100644 => 120000 packages/wyatt_bloc_layout/.gitignore mode change 100644 => 120000 packages/wyatt_bloc_layout/AUTHORS mode change 100644 => 120000 packages/wyatt_bloc_layout/LICENSE mode change 100644 => 120000 packages/wyatt_component_copy_with_extension/.gitignore create mode 120000 packages/wyatt_component_copy_with_extension/AUTHORS create mode 120000 packages/wyatt_component_copy_with_extension/LICENSE mode change 100644 => 120000 packages/wyatt_component_copy_with_gen/.gitignore create mode 120000 packages/wyatt_component_copy_with_gen/AUTHORS create mode 120000 packages/wyatt_component_copy_with_gen/LICENSE mode change 100644 => 120000 packages/wyatt_crud_bloc/.gitignore create mode 120000 packages/wyatt_crud_bloc/AUTHORS mode change 100644 => 120000 packages/wyatt_crud_bloc/LICENSE create mode 120000 packages/wyatt_deferred_widget_annotation/.gitignore create mode 120000 packages/wyatt_deferred_widget_annotation/AUTHORS create mode 120000 packages/wyatt_deferred_widget_annotation/LICENSE create mode 120000 packages/wyatt_deferred_widget_gen/.gitignore create mode 120000 packages/wyatt_deferred_widget_gen/AUTHORS create mode 120000 packages/wyatt_deferred_widget_gen/LICENSE mode change 100644 => 120000 packages/wyatt_form_bloc/.gitignore mode change 100644 => 120000 packages/wyatt_form_bloc/AUTHORS mode change 100644 => 120000 packages/wyatt_form_bloc/LICENSE mode change 100644 => 120000 packages/wyatt_http_client/.gitignore mode change 100644 => 120000 packages/wyatt_http_client/AUTHORS mode change 100644 => 120000 packages/wyatt_http_client/LICENSE mode change 100644 => 120000 packages/wyatt_i18n/AUTHORS mode change 100644 => 120000 packages/wyatt_i18n/LICENSE mode change 100644 => 120000 packages/wyatt_notification_bloc/.gitignore create mode 120000 packages/wyatt_notification_bloc/AUTHORS create mode 120000 packages/wyatt_notification_bloc/LICENSE mode change 100644 => 120000 packages/wyatt_type_utils/.gitignore mode change 100644 => 120000 packages/wyatt_type_utils/AUTHORS mode change 100644 => 120000 packages/wyatt_type_utils/LICENSE mode change 100644 => 120000 packages/wyatt_ui_components/.gitignore mode change 100644 => 120000 packages/wyatt_ui_components/AUTHORS mode change 100644 => 120000 packages/wyatt_ui_components/LICENSE mode change 100644 => 120000 packages/wyatt_ui_kit/.gitignore create mode 120000 packages/wyatt_ui_kit/AUTHORS create mode 120000 packages/wyatt_ui_kit/LICENSE mode change 100644 => 120000 packages/wyatt_ui_layout/.gitignore mode change 100644 => 120000 packages/wyatt_ui_layout/AUTHORS mode change 100644 => 120000 packages/wyatt_ui_layout/LICENSE create mode 100755 scripts/clean_gitignore.sh create mode 100755 scripts/symbolic_links.sh diff --git a/AUTHORS b/AUTHORS index f9506138..a1c2a78d 100644 --- a/AUTHORS +++ b/AUTHORS @@ -4,5 +4,5 @@ # Name/Organization Wyatt Group S.A.S -Hugo Pointcheval -Malo Léon \ No newline at end of file +Hugo Pointcheval +Malo Léon diff --git a/packages/wyatt_analysis/.gitignore b/packages/wyatt_analysis/.gitignore deleted file mode 100644 index 65c34dc8..00000000 --- a/packages/wyatt_analysis/.gitignore +++ /dev/null @@ -1,10 +0,0 @@ -# Files and directories created by pub. -.dart_tool/ -.packages - -# Conventional directory for build outputs. -build/ - -# Omit committing pubspec.lock for library packages; see -# https://dart.dev/guides/libraries/private-files#pubspeclock. -pubspec.lock diff --git a/packages/wyatt_analysis/.gitignore b/packages/wyatt_analysis/.gitignore new file mode 120000 index 00000000..6ef08f9d --- /dev/null +++ b/packages/wyatt_analysis/.gitignore @@ -0,0 +1 @@ +../../.gitignore \ No newline at end of file diff --git a/packages/wyatt_analysis/AUTHORS b/packages/wyatt_analysis/AUTHORS deleted file mode 100644 index b6d7d765..00000000 --- a/packages/wyatt_analysis/AUTHORS +++ /dev/null @@ -1,7 +0,0 @@ -# Below is a list of people and organizations that have contributed -# to this project. Names should be added to the list like so: -# -# Name/Organization - -Wyatt Group S.A.S -Hugo Pointcheval \ No newline at end of file diff --git a/packages/wyatt_analysis/AUTHORS b/packages/wyatt_analysis/AUTHORS new file mode 120000 index 00000000..f04b7e8a --- /dev/null +++ b/packages/wyatt_analysis/AUTHORS @@ -0,0 +1 @@ +../../AUTHORS \ No newline at end of file diff --git a/packages/wyatt_analysis/LICENSE b/packages/wyatt_analysis/LICENSE deleted file mode 100644 index e72bfdda..00000000 --- a/packages/wyatt_analysis/LICENSE +++ /dev/null @@ -1,674 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. - - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. - - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. - - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Use with the GNU Affero General Public License. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: - - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. - - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. \ No newline at end of file diff --git a/packages/wyatt_analysis/LICENSE b/packages/wyatt_analysis/LICENSE new file mode 120000 index 00000000..30cff740 --- /dev/null +++ b/packages/wyatt_analysis/LICENSE @@ -0,0 +1 @@ +../../LICENSE \ No newline at end of file diff --git a/packages/wyatt_architecture/.gitignore b/packages/wyatt_architecture/.gitignore deleted file mode 100644 index e38f9b0c..00000000 --- a/packages/wyatt_architecture/.gitignore +++ /dev/null @@ -1,133 +0,0 @@ -# Miscellaneous -*.class -*.lock -*.log -*.pyc -*.swp -.DS_Store -.atom/ -.buildlog/ -.history -.svn/ - -# IntelliJ related -*.iml -*.ipr -*.iws -.idea/* - -# Visual Studio Code related -.classpath -.project -.settings/ -.vscode/* -!.vscode/settings.json -!.vscode/extensions.json - -# Flutter repo-specific -/bin/cache/ -/bin/mingit/ -/dev/benchmarks/mega_gallery/ -/dev/bots/.recipe_deps -/dev/bots/android_tools/ -/dev/docs/doc/ -/dev/docs/flutter.docs.zip -/dev/docs/lib/ -/dev/docs/pubspec.yaml -/dev/integration_tests/**/xcuserdata -/dev/integration_tests/**/Pods -/packages/flutter/coverage/ -version - -# packages file containing multi-root paths -.packages.generated - -# Flutter/Dart/Pub related -**/doc/api/ -**/ios/Flutter/.last_build_id -.dart_tool/ -.flutter-plugins -.flutter-plugins-dependencies -.packages -.pub-cache/ -.pub/ -build/ -flutter_*.png -linked_*.ds -unlinked.ds -unlinked_spec.ds -.fvm/ - -# Android related -**/android/**/gradle-wrapper.jar -**/android/.gradle -**/android/captures/ -**/android/gradlew -**/android/gradlew.bat -**/android/local.properties -**/android/**/GeneratedPluginRegistrant.java -**/android/key.properties -**/android/.idea/ -*.jks - -# iOS/XCode related -**/ios/**/*.mode1v3 -**/ios/**/*.mode2v3 -**/ios/**/*.moved-aside -**/ios/**/*.pbxuser -**/ios/**/*.perspectivev3 -**/ios/**/*sync/ -**/ios/**/.sconsign.dblite -**/ios/**/.tags* -**/ios/**/.vagrant/ -**/ios/**/DerivedData/ -**/ios/**/Icon? -**/ios/**/Pods/ -**/ios/**/.symlinks/ -**/ios/**/profile -**/ios/**/xcuserdata -**/ios/.generated/ -**/ios/Flutter/App.framework -**/ios/Flutter/Flutter.framework -**/ios/Flutter/Flutter.podspec -**/ios/Flutter/Generated.xcconfig -**/ios/Flutter/app.flx -**/ios/Flutter/app.zip -**/ios/Flutter/.last_build_id -**/ios/Flutter/flutter_assets/ -**/ios/Flutter/flutter_export_environment.sh -**/ios/ServiceDefinitions.json -**/ios/Runner/GeneratedPluginRegistrant.* - -# Coverage -coverage/ - -# Submodules -!pubspec.lock -packages/**/pubspec.lock - -# Web related -lib/generated_plugin_registrant.dart - -# Symbolication related -app.*.symbols - -# Obfuscation related -app.*.map.json - -# Exceptions to the above rules. -!**/ios/**/default.mode1v3 -!**/ios/**/default.mode2v3 -!**/ios/**/default.pbxuser -!**/ios/**/default.perspectivev3 -!/packages/flutter_tools/test/data/dart_dependencies_test/**/.packages -!/dev/ci/**/Gemfile.lock -!.vscode/extensions.json -!.vscode/launch.json -!.idea/codeStyles/ -!.idea/dictionaries/ -!.idea/runConfigurations/ - -# Omit committing pubspec.lock for library packages; see -# https://dart.dev/guides/libraries/private-files#pubspeclock. -pubspec.lock diff --git a/packages/wyatt_architecture/.gitignore b/packages/wyatt_architecture/.gitignore new file mode 120000 index 00000000..6ef08f9d --- /dev/null +++ b/packages/wyatt_architecture/.gitignore @@ -0,0 +1 @@ +../../.gitignore \ No newline at end of file diff --git a/packages/wyatt_architecture/AUTHORS b/packages/wyatt_architecture/AUTHORS deleted file mode 100644 index f9506138..00000000 --- a/packages/wyatt_architecture/AUTHORS +++ /dev/null @@ -1,8 +0,0 @@ -# Below is a list of people and organizations that have contributed -# to this project. Names should be added to the list like so: -# -# Name/Organization - -Wyatt Group S.A.S -Hugo Pointcheval -Malo Léon \ No newline at end of file diff --git a/packages/wyatt_architecture/AUTHORS b/packages/wyatt_architecture/AUTHORS new file mode 120000 index 00000000..f04b7e8a --- /dev/null +++ b/packages/wyatt_architecture/AUTHORS @@ -0,0 +1 @@ +../../AUTHORS \ No newline at end of file diff --git a/packages/wyatt_architecture/LICENSE b/packages/wyatt_architecture/LICENSE deleted file mode 100644 index e72bfdda..00000000 --- a/packages/wyatt_architecture/LICENSE +++ /dev/null @@ -1,674 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. - - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. - - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. - - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Use with the GNU Affero General Public License. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: - - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. - - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. \ No newline at end of file diff --git a/packages/wyatt_architecture/LICENSE b/packages/wyatt_architecture/LICENSE new file mode 120000 index 00000000..30cff740 --- /dev/null +++ b/packages/wyatt_architecture/LICENSE @@ -0,0 +1 @@ +../../LICENSE \ No newline at end of file diff --git a/packages/wyatt_authentication_bloc/.gitignore b/packages/wyatt_authentication_bloc/.gitignore deleted file mode 100644 index 0f643f51..00000000 --- a/packages/wyatt_authentication_bloc/.gitignore +++ /dev/null @@ -1,30 +0,0 @@ -# Miscellaneous -*.class -*.log -*.pyc -*.swp -.DS_Store -.atom/ -.buildlog/ -.history -.svn/ - -# IntelliJ related -*.iml -*.ipr -*.iws -.idea/ - -# The .vscode folder contains launch configuration and tasks you configure in -# VS Code which you may wish to be included in version control, so this line -# is commented out by default. -#.vscode/ - -# Flutter/Dart/Pub related -# Libraries should not include pubspec.lock, per https://dart.dev/guides/libraries/private-files#pubspeclock. -/pubspec.lock -.dart_tool/ -.packages -build/ -.flutter-plugins* -coverage/ \ No newline at end of file diff --git a/packages/wyatt_authentication_bloc/.gitignore b/packages/wyatt_authentication_bloc/.gitignore new file mode 120000 index 00000000..6ef08f9d --- /dev/null +++ b/packages/wyatt_authentication_bloc/.gitignore @@ -0,0 +1 @@ +../../.gitignore \ No newline at end of file diff --git a/packages/wyatt_authentication_bloc/AUTHORS b/packages/wyatt_authentication_bloc/AUTHORS deleted file mode 100644 index b6d7d765..00000000 --- a/packages/wyatt_authentication_bloc/AUTHORS +++ /dev/null @@ -1,7 +0,0 @@ -# Below is a list of people and organizations that have contributed -# to this project. Names should be added to the list like so: -# -# Name/Organization - -Wyatt Group S.A.S -Hugo Pointcheval \ No newline at end of file diff --git a/packages/wyatt_authentication_bloc/AUTHORS b/packages/wyatt_authentication_bloc/AUTHORS new file mode 120000 index 00000000..f04b7e8a --- /dev/null +++ b/packages/wyatt_authentication_bloc/AUTHORS @@ -0,0 +1 @@ +../../AUTHORS \ No newline at end of file diff --git a/packages/wyatt_authentication_bloc/LICENSE b/packages/wyatt_authentication_bloc/LICENSE deleted file mode 100644 index e72bfdda..00000000 --- a/packages/wyatt_authentication_bloc/LICENSE +++ /dev/null @@ -1,674 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. - - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. - - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. - - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Use with the GNU Affero General Public License. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: - - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. - - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. \ No newline at end of file diff --git a/packages/wyatt_authentication_bloc/LICENSE b/packages/wyatt_authentication_bloc/LICENSE new file mode 120000 index 00000000..30cff740 --- /dev/null +++ b/packages/wyatt_authentication_bloc/LICENSE @@ -0,0 +1 @@ +../../LICENSE \ No newline at end of file diff --git a/packages/wyatt_bloc_helper/.gitignore b/packages/wyatt_bloc_helper/.gitignore deleted file mode 100644 index 65c34dc8..00000000 --- a/packages/wyatt_bloc_helper/.gitignore +++ /dev/null @@ -1,10 +0,0 @@ -# Files and directories created by pub. -.dart_tool/ -.packages - -# Conventional directory for build outputs. -build/ - -# Omit committing pubspec.lock for library packages; see -# https://dart.dev/guides/libraries/private-files#pubspeclock. -pubspec.lock diff --git a/packages/wyatt_bloc_helper/.gitignore b/packages/wyatt_bloc_helper/.gitignore new file mode 120000 index 00000000..6ef08f9d --- /dev/null +++ b/packages/wyatt_bloc_helper/.gitignore @@ -0,0 +1 @@ +../../.gitignore \ No newline at end of file diff --git a/packages/wyatt_bloc_helper/AUTHORS b/packages/wyatt_bloc_helper/AUTHORS deleted file mode 100644 index 2a0b50f7..00000000 --- a/packages/wyatt_bloc_helper/AUTHORS +++ /dev/null @@ -1,8 +0,0 @@ -# Below is a list of people and organizations that have contributed -# to this project. Names should be added to the list like so: -# -# Name/Organization - -Wyatt Group S.A.S -Malo Léon -Hugo Pointcheval \ No newline at end of file diff --git a/packages/wyatt_bloc_helper/AUTHORS b/packages/wyatt_bloc_helper/AUTHORS new file mode 120000 index 00000000..f04b7e8a --- /dev/null +++ b/packages/wyatt_bloc_helper/AUTHORS @@ -0,0 +1 @@ +../../AUTHORS \ No newline at end of file diff --git a/packages/wyatt_bloc_helper/LICENSE b/packages/wyatt_bloc_helper/LICENSE deleted file mode 100644 index e72bfdda..00000000 --- a/packages/wyatt_bloc_helper/LICENSE +++ /dev/null @@ -1,674 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. - - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. - - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. - - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Use with the GNU Affero General Public License. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: - - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. - - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. \ No newline at end of file diff --git a/packages/wyatt_bloc_helper/LICENSE b/packages/wyatt_bloc_helper/LICENSE new file mode 120000 index 00000000..30cff740 --- /dev/null +++ b/packages/wyatt_bloc_helper/LICENSE @@ -0,0 +1 @@ +../../LICENSE \ No newline at end of file diff --git a/packages/wyatt_bloc_layout/.gitignore b/packages/wyatt_bloc_layout/.gitignore deleted file mode 100644 index e38f9b0c..00000000 --- a/packages/wyatt_bloc_layout/.gitignore +++ /dev/null @@ -1,133 +0,0 @@ -# Miscellaneous -*.class -*.lock -*.log -*.pyc -*.swp -.DS_Store -.atom/ -.buildlog/ -.history -.svn/ - -# IntelliJ related -*.iml -*.ipr -*.iws -.idea/* - -# Visual Studio Code related -.classpath -.project -.settings/ -.vscode/* -!.vscode/settings.json -!.vscode/extensions.json - -# Flutter repo-specific -/bin/cache/ -/bin/mingit/ -/dev/benchmarks/mega_gallery/ -/dev/bots/.recipe_deps -/dev/bots/android_tools/ -/dev/docs/doc/ -/dev/docs/flutter.docs.zip -/dev/docs/lib/ -/dev/docs/pubspec.yaml -/dev/integration_tests/**/xcuserdata -/dev/integration_tests/**/Pods -/packages/flutter/coverage/ -version - -# packages file containing multi-root paths -.packages.generated - -# Flutter/Dart/Pub related -**/doc/api/ -**/ios/Flutter/.last_build_id -.dart_tool/ -.flutter-plugins -.flutter-plugins-dependencies -.packages -.pub-cache/ -.pub/ -build/ -flutter_*.png -linked_*.ds -unlinked.ds -unlinked_spec.ds -.fvm/ - -# Android related -**/android/**/gradle-wrapper.jar -**/android/.gradle -**/android/captures/ -**/android/gradlew -**/android/gradlew.bat -**/android/local.properties -**/android/**/GeneratedPluginRegistrant.java -**/android/key.properties -**/android/.idea/ -*.jks - -# iOS/XCode related -**/ios/**/*.mode1v3 -**/ios/**/*.mode2v3 -**/ios/**/*.moved-aside -**/ios/**/*.pbxuser -**/ios/**/*.perspectivev3 -**/ios/**/*sync/ -**/ios/**/.sconsign.dblite -**/ios/**/.tags* -**/ios/**/.vagrant/ -**/ios/**/DerivedData/ -**/ios/**/Icon? -**/ios/**/Pods/ -**/ios/**/.symlinks/ -**/ios/**/profile -**/ios/**/xcuserdata -**/ios/.generated/ -**/ios/Flutter/App.framework -**/ios/Flutter/Flutter.framework -**/ios/Flutter/Flutter.podspec -**/ios/Flutter/Generated.xcconfig -**/ios/Flutter/app.flx -**/ios/Flutter/app.zip -**/ios/Flutter/.last_build_id -**/ios/Flutter/flutter_assets/ -**/ios/Flutter/flutter_export_environment.sh -**/ios/ServiceDefinitions.json -**/ios/Runner/GeneratedPluginRegistrant.* - -# Coverage -coverage/ - -# Submodules -!pubspec.lock -packages/**/pubspec.lock - -# Web related -lib/generated_plugin_registrant.dart - -# Symbolication related -app.*.symbols - -# Obfuscation related -app.*.map.json - -# Exceptions to the above rules. -!**/ios/**/default.mode1v3 -!**/ios/**/default.mode2v3 -!**/ios/**/default.pbxuser -!**/ios/**/default.perspectivev3 -!/packages/flutter_tools/test/data/dart_dependencies_test/**/.packages -!/dev/ci/**/Gemfile.lock -!.vscode/extensions.json -!.vscode/launch.json -!.idea/codeStyles/ -!.idea/dictionaries/ -!.idea/runConfigurations/ - -# Omit committing pubspec.lock for library packages; see -# https://dart.dev/guides/libraries/private-files#pubspeclock. -pubspec.lock diff --git a/packages/wyatt_bloc_layout/.gitignore b/packages/wyatt_bloc_layout/.gitignore new file mode 120000 index 00000000..6ef08f9d --- /dev/null +++ b/packages/wyatt_bloc_layout/.gitignore @@ -0,0 +1 @@ +../../.gitignore \ No newline at end of file diff --git a/packages/wyatt_bloc_layout/AUTHORS b/packages/wyatt_bloc_layout/AUTHORS deleted file mode 100644 index f9506138..00000000 --- a/packages/wyatt_bloc_layout/AUTHORS +++ /dev/null @@ -1,8 +0,0 @@ -# Below is a list of people and organizations that have contributed -# to this project. Names should be added to the list like so: -# -# Name/Organization - -Wyatt Group S.A.S -Hugo Pointcheval -Malo Léon \ No newline at end of file diff --git a/packages/wyatt_bloc_layout/AUTHORS b/packages/wyatt_bloc_layout/AUTHORS new file mode 120000 index 00000000..f04b7e8a --- /dev/null +++ b/packages/wyatt_bloc_layout/AUTHORS @@ -0,0 +1 @@ +../../AUTHORS \ No newline at end of file diff --git a/packages/wyatt_bloc_layout/LICENSE b/packages/wyatt_bloc_layout/LICENSE deleted file mode 100644 index e72bfdda..00000000 --- a/packages/wyatt_bloc_layout/LICENSE +++ /dev/null @@ -1,674 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. - - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. - - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. - - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Use with the GNU Affero General Public License. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: - - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. - - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. \ No newline at end of file diff --git a/packages/wyatt_bloc_layout/LICENSE b/packages/wyatt_bloc_layout/LICENSE new file mode 120000 index 00000000..30cff740 --- /dev/null +++ b/packages/wyatt_bloc_layout/LICENSE @@ -0,0 +1 @@ +../../LICENSE \ No newline at end of file diff --git a/packages/wyatt_component_copy_with_extension/.gitignore b/packages/wyatt_component_copy_with_extension/.gitignore deleted file mode 100644 index 3cceda55..00000000 --- a/packages/wyatt_component_copy_with_extension/.gitignore +++ /dev/null @@ -1,7 +0,0 @@ -# https://dart.dev/guides/libraries/private-files -# Created by `dart pub` -.dart_tool/ - -# Avoid committing pubspec.lock for library packages; see -# https://dart.dev/guides/libraries/private-files#pubspeclock. -pubspec.lock diff --git a/packages/wyatt_component_copy_with_extension/.gitignore b/packages/wyatt_component_copy_with_extension/.gitignore new file mode 120000 index 00000000..6ef08f9d --- /dev/null +++ b/packages/wyatt_component_copy_with_extension/.gitignore @@ -0,0 +1 @@ +../../.gitignore \ No newline at end of file diff --git a/packages/wyatt_component_copy_with_extension/AUTHORS b/packages/wyatt_component_copy_with_extension/AUTHORS new file mode 120000 index 00000000..f04b7e8a --- /dev/null +++ b/packages/wyatt_component_copy_with_extension/AUTHORS @@ -0,0 +1 @@ +../../AUTHORS \ No newline at end of file diff --git a/packages/wyatt_component_copy_with_extension/LICENSE b/packages/wyatt_component_copy_with_extension/LICENSE new file mode 120000 index 00000000..30cff740 --- /dev/null +++ b/packages/wyatt_component_copy_with_extension/LICENSE @@ -0,0 +1 @@ +../../LICENSE \ No newline at end of file diff --git a/packages/wyatt_component_copy_with_gen/.gitignore b/packages/wyatt_component_copy_with_gen/.gitignore deleted file mode 100644 index 3cceda55..00000000 --- a/packages/wyatt_component_copy_with_gen/.gitignore +++ /dev/null @@ -1,7 +0,0 @@ -# https://dart.dev/guides/libraries/private-files -# Created by `dart pub` -.dart_tool/ - -# Avoid committing pubspec.lock for library packages; see -# https://dart.dev/guides/libraries/private-files#pubspeclock. -pubspec.lock diff --git a/packages/wyatt_component_copy_with_gen/.gitignore b/packages/wyatt_component_copy_with_gen/.gitignore new file mode 120000 index 00000000..6ef08f9d --- /dev/null +++ b/packages/wyatt_component_copy_with_gen/.gitignore @@ -0,0 +1 @@ +../../.gitignore \ No newline at end of file diff --git a/packages/wyatt_component_copy_with_gen/AUTHORS b/packages/wyatt_component_copy_with_gen/AUTHORS new file mode 120000 index 00000000..f04b7e8a --- /dev/null +++ b/packages/wyatt_component_copy_with_gen/AUTHORS @@ -0,0 +1 @@ +../../AUTHORS \ No newline at end of file diff --git a/packages/wyatt_component_copy_with_gen/LICENSE b/packages/wyatt_component_copy_with_gen/LICENSE new file mode 120000 index 00000000..30cff740 --- /dev/null +++ b/packages/wyatt_component_copy_with_gen/LICENSE @@ -0,0 +1 @@ +../../LICENSE \ No newline at end of file diff --git a/packages/wyatt_crud_bloc/.gitignore b/packages/wyatt_crud_bloc/.gitignore deleted file mode 100644 index e38f9b0c..00000000 --- a/packages/wyatt_crud_bloc/.gitignore +++ /dev/null @@ -1,133 +0,0 @@ -# Miscellaneous -*.class -*.lock -*.log -*.pyc -*.swp -.DS_Store -.atom/ -.buildlog/ -.history -.svn/ - -# IntelliJ related -*.iml -*.ipr -*.iws -.idea/* - -# Visual Studio Code related -.classpath -.project -.settings/ -.vscode/* -!.vscode/settings.json -!.vscode/extensions.json - -# Flutter repo-specific -/bin/cache/ -/bin/mingit/ -/dev/benchmarks/mega_gallery/ -/dev/bots/.recipe_deps -/dev/bots/android_tools/ -/dev/docs/doc/ -/dev/docs/flutter.docs.zip -/dev/docs/lib/ -/dev/docs/pubspec.yaml -/dev/integration_tests/**/xcuserdata -/dev/integration_tests/**/Pods -/packages/flutter/coverage/ -version - -# packages file containing multi-root paths -.packages.generated - -# Flutter/Dart/Pub related -**/doc/api/ -**/ios/Flutter/.last_build_id -.dart_tool/ -.flutter-plugins -.flutter-plugins-dependencies -.packages -.pub-cache/ -.pub/ -build/ -flutter_*.png -linked_*.ds -unlinked.ds -unlinked_spec.ds -.fvm/ - -# Android related -**/android/**/gradle-wrapper.jar -**/android/.gradle -**/android/captures/ -**/android/gradlew -**/android/gradlew.bat -**/android/local.properties -**/android/**/GeneratedPluginRegistrant.java -**/android/key.properties -**/android/.idea/ -*.jks - -# iOS/XCode related -**/ios/**/*.mode1v3 -**/ios/**/*.mode2v3 -**/ios/**/*.moved-aside -**/ios/**/*.pbxuser -**/ios/**/*.perspectivev3 -**/ios/**/*sync/ -**/ios/**/.sconsign.dblite -**/ios/**/.tags* -**/ios/**/.vagrant/ -**/ios/**/DerivedData/ -**/ios/**/Icon? -**/ios/**/Pods/ -**/ios/**/.symlinks/ -**/ios/**/profile -**/ios/**/xcuserdata -**/ios/.generated/ -**/ios/Flutter/App.framework -**/ios/Flutter/Flutter.framework -**/ios/Flutter/Flutter.podspec -**/ios/Flutter/Generated.xcconfig -**/ios/Flutter/app.flx -**/ios/Flutter/app.zip -**/ios/Flutter/.last_build_id -**/ios/Flutter/flutter_assets/ -**/ios/Flutter/flutter_export_environment.sh -**/ios/ServiceDefinitions.json -**/ios/Runner/GeneratedPluginRegistrant.* - -# Coverage -coverage/ - -# Submodules -!pubspec.lock -packages/**/pubspec.lock - -# Web related -lib/generated_plugin_registrant.dart - -# Symbolication related -app.*.symbols - -# Obfuscation related -app.*.map.json - -# Exceptions to the above rules. -!**/ios/**/default.mode1v3 -!**/ios/**/default.mode2v3 -!**/ios/**/default.pbxuser -!**/ios/**/default.perspectivev3 -!/packages/flutter_tools/test/data/dart_dependencies_test/**/.packages -!/dev/ci/**/Gemfile.lock -!.vscode/extensions.json -!.vscode/launch.json -!.idea/codeStyles/ -!.idea/dictionaries/ -!.idea/runConfigurations/ - -# Omit committing pubspec.lock for library packages; see -# https://dart.dev/guides/libraries/private-files#pubspeclock. -pubspec.lock diff --git a/packages/wyatt_crud_bloc/.gitignore b/packages/wyatt_crud_bloc/.gitignore new file mode 120000 index 00000000..6ef08f9d --- /dev/null +++ b/packages/wyatt_crud_bloc/.gitignore @@ -0,0 +1 @@ +../../.gitignore \ No newline at end of file diff --git a/packages/wyatt_crud_bloc/AUTHORS b/packages/wyatt_crud_bloc/AUTHORS new file mode 120000 index 00000000..f04b7e8a --- /dev/null +++ b/packages/wyatt_crud_bloc/AUTHORS @@ -0,0 +1 @@ +../../AUTHORS \ No newline at end of file diff --git a/packages/wyatt_crud_bloc/LICENSE b/packages/wyatt_crud_bloc/LICENSE deleted file mode 100644 index e72bfdda..00000000 --- a/packages/wyatt_crud_bloc/LICENSE +++ /dev/null @@ -1,674 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. - - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. - - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. - - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Use with the GNU Affero General Public License. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: - - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. - - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. \ No newline at end of file diff --git a/packages/wyatt_crud_bloc/LICENSE b/packages/wyatt_crud_bloc/LICENSE new file mode 120000 index 00000000..30cff740 --- /dev/null +++ b/packages/wyatt_crud_bloc/LICENSE @@ -0,0 +1 @@ +../../LICENSE \ No newline at end of file diff --git a/packages/wyatt_deferred_widget_annotation/.gitignore b/packages/wyatt_deferred_widget_annotation/.gitignore new file mode 120000 index 00000000..6ef08f9d --- /dev/null +++ b/packages/wyatt_deferred_widget_annotation/.gitignore @@ -0,0 +1 @@ +../../.gitignore \ No newline at end of file diff --git a/packages/wyatt_deferred_widget_annotation/AUTHORS b/packages/wyatt_deferred_widget_annotation/AUTHORS new file mode 120000 index 00000000..f04b7e8a --- /dev/null +++ b/packages/wyatt_deferred_widget_annotation/AUTHORS @@ -0,0 +1 @@ +../../AUTHORS \ No newline at end of file diff --git a/packages/wyatt_deferred_widget_annotation/LICENSE b/packages/wyatt_deferred_widget_annotation/LICENSE new file mode 120000 index 00000000..30cff740 --- /dev/null +++ b/packages/wyatt_deferred_widget_annotation/LICENSE @@ -0,0 +1 @@ +../../LICENSE \ No newline at end of file diff --git a/packages/wyatt_deferred_widget_gen/.gitignore b/packages/wyatt_deferred_widget_gen/.gitignore new file mode 120000 index 00000000..6ef08f9d --- /dev/null +++ b/packages/wyatt_deferred_widget_gen/.gitignore @@ -0,0 +1 @@ +../../.gitignore \ No newline at end of file diff --git a/packages/wyatt_deferred_widget_gen/AUTHORS b/packages/wyatt_deferred_widget_gen/AUTHORS new file mode 120000 index 00000000..f04b7e8a --- /dev/null +++ b/packages/wyatt_deferred_widget_gen/AUTHORS @@ -0,0 +1 @@ +../../AUTHORS \ No newline at end of file diff --git a/packages/wyatt_deferred_widget_gen/LICENSE b/packages/wyatt_deferred_widget_gen/LICENSE new file mode 120000 index 00000000..30cff740 --- /dev/null +++ b/packages/wyatt_deferred_widget_gen/LICENSE @@ -0,0 +1 @@ +../../LICENSE \ No newline at end of file diff --git a/packages/wyatt_form_bloc/.gitignore b/packages/wyatt_form_bloc/.gitignore deleted file mode 100644 index 65c34dc8..00000000 --- a/packages/wyatt_form_bloc/.gitignore +++ /dev/null @@ -1,10 +0,0 @@ -# Files and directories created by pub. -.dart_tool/ -.packages - -# Conventional directory for build outputs. -build/ - -# Omit committing pubspec.lock for library packages; see -# https://dart.dev/guides/libraries/private-files#pubspeclock. -pubspec.lock diff --git a/packages/wyatt_form_bloc/.gitignore b/packages/wyatt_form_bloc/.gitignore new file mode 120000 index 00000000..6ef08f9d --- /dev/null +++ b/packages/wyatt_form_bloc/.gitignore @@ -0,0 +1 @@ +../../.gitignore \ No newline at end of file diff --git a/packages/wyatt_form_bloc/AUTHORS b/packages/wyatt_form_bloc/AUTHORS deleted file mode 100644 index b6d7d765..00000000 --- a/packages/wyatt_form_bloc/AUTHORS +++ /dev/null @@ -1,7 +0,0 @@ -# Below is a list of people and organizations that have contributed -# to this project. Names should be added to the list like so: -# -# Name/Organization - -Wyatt Group S.A.S -Hugo Pointcheval \ No newline at end of file diff --git a/packages/wyatt_form_bloc/AUTHORS b/packages/wyatt_form_bloc/AUTHORS new file mode 120000 index 00000000..f04b7e8a --- /dev/null +++ b/packages/wyatt_form_bloc/AUTHORS @@ -0,0 +1 @@ +../../AUTHORS \ No newline at end of file diff --git a/packages/wyatt_form_bloc/LICENSE b/packages/wyatt_form_bloc/LICENSE deleted file mode 100644 index 3b2646b3..00000000 --- a/packages/wyatt_form_bloc/LICENSE +++ /dev/null @@ -1,692 +0,0 @@ - - - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. - - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. - - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. - - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Use with the GNU Affero General Public License. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: - - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. - - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. \ No newline at end of file diff --git a/packages/wyatt_form_bloc/LICENSE b/packages/wyatt_form_bloc/LICENSE new file mode 120000 index 00000000..30cff740 --- /dev/null +++ b/packages/wyatt_form_bloc/LICENSE @@ -0,0 +1 @@ +../../LICENSE \ No newline at end of file diff --git a/packages/wyatt_http_client/.gitignore b/packages/wyatt_http_client/.gitignore deleted file mode 100644 index 65c34dc8..00000000 --- a/packages/wyatt_http_client/.gitignore +++ /dev/null @@ -1,10 +0,0 @@ -# Files and directories created by pub. -.dart_tool/ -.packages - -# Conventional directory for build outputs. -build/ - -# Omit committing pubspec.lock for library packages; see -# https://dart.dev/guides/libraries/private-files#pubspeclock. -pubspec.lock diff --git a/packages/wyatt_http_client/.gitignore b/packages/wyatt_http_client/.gitignore new file mode 120000 index 00000000..6ef08f9d --- /dev/null +++ b/packages/wyatt_http_client/.gitignore @@ -0,0 +1 @@ +../../.gitignore \ No newline at end of file diff --git a/packages/wyatt_http_client/AUTHORS b/packages/wyatt_http_client/AUTHORS deleted file mode 100644 index b6d7d765..00000000 --- a/packages/wyatt_http_client/AUTHORS +++ /dev/null @@ -1,7 +0,0 @@ -# Below is a list of people and organizations that have contributed -# to this project. Names should be added to the list like so: -# -# Name/Organization - -Wyatt Group S.A.S -Hugo Pointcheval \ No newline at end of file diff --git a/packages/wyatt_http_client/AUTHORS b/packages/wyatt_http_client/AUTHORS new file mode 120000 index 00000000..f04b7e8a --- /dev/null +++ b/packages/wyatt_http_client/AUTHORS @@ -0,0 +1 @@ +../../AUTHORS \ No newline at end of file diff --git a/packages/wyatt_http_client/LICENSE b/packages/wyatt_http_client/LICENSE deleted file mode 100644 index e72bfdda..00000000 --- a/packages/wyatt_http_client/LICENSE +++ /dev/null @@ -1,674 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. - - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. - - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. - - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Use with the GNU Affero General Public License. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: - - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. - - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. \ No newline at end of file diff --git a/packages/wyatt_http_client/LICENSE b/packages/wyatt_http_client/LICENSE new file mode 120000 index 00000000..30cff740 --- /dev/null +++ b/packages/wyatt_http_client/LICENSE @@ -0,0 +1 @@ +../../LICENSE \ No newline at end of file diff --git a/packages/wyatt_i18n/AUTHORS b/packages/wyatt_i18n/AUTHORS deleted file mode 100644 index 8a49779b..00000000 --- a/packages/wyatt_i18n/AUTHORS +++ /dev/null @@ -1,7 +0,0 @@ -# Below is a list of people and organizations that have contributed -# to this project. Names should be added to the list like so: -# -# Name/Organization - -Wyatt Group S.A.S -Hugo Pointcheval \ No newline at end of file diff --git a/packages/wyatt_i18n/AUTHORS b/packages/wyatt_i18n/AUTHORS new file mode 120000 index 00000000..f04b7e8a --- /dev/null +++ b/packages/wyatt_i18n/AUTHORS @@ -0,0 +1 @@ +../../AUTHORS \ No newline at end of file diff --git a/packages/wyatt_i18n/LICENSE b/packages/wyatt_i18n/LICENSE deleted file mode 100644 index e72bfdda..00000000 --- a/packages/wyatt_i18n/LICENSE +++ /dev/null @@ -1,674 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. - - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. - - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. - - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Use with the GNU Affero General Public License. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: - - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. - - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. \ No newline at end of file diff --git a/packages/wyatt_i18n/LICENSE b/packages/wyatt_i18n/LICENSE new file mode 120000 index 00000000..30cff740 --- /dev/null +++ b/packages/wyatt_i18n/LICENSE @@ -0,0 +1 @@ +../../LICENSE \ No newline at end of file diff --git a/packages/wyatt_notification_bloc/.gitignore b/packages/wyatt_notification_bloc/.gitignore deleted file mode 100644 index 65c34dc8..00000000 --- a/packages/wyatt_notification_bloc/.gitignore +++ /dev/null @@ -1,10 +0,0 @@ -# Files and directories created by pub. -.dart_tool/ -.packages - -# Conventional directory for build outputs. -build/ - -# Omit committing pubspec.lock for library packages; see -# https://dart.dev/guides/libraries/private-files#pubspeclock. -pubspec.lock diff --git a/packages/wyatt_notification_bloc/.gitignore b/packages/wyatt_notification_bloc/.gitignore new file mode 120000 index 00000000..6ef08f9d --- /dev/null +++ b/packages/wyatt_notification_bloc/.gitignore @@ -0,0 +1 @@ +../../.gitignore \ No newline at end of file diff --git a/packages/wyatt_notification_bloc/AUTHORS b/packages/wyatt_notification_bloc/AUTHORS new file mode 120000 index 00000000..f04b7e8a --- /dev/null +++ b/packages/wyatt_notification_bloc/AUTHORS @@ -0,0 +1 @@ +../../AUTHORS \ No newline at end of file diff --git a/packages/wyatt_notification_bloc/LICENSE b/packages/wyatt_notification_bloc/LICENSE new file mode 120000 index 00000000..30cff740 --- /dev/null +++ b/packages/wyatt_notification_bloc/LICENSE @@ -0,0 +1 @@ +../../LICENSE \ No newline at end of file diff --git a/packages/wyatt_type_utils/.gitignore b/packages/wyatt_type_utils/.gitignore deleted file mode 100644 index e38f9b0c..00000000 --- a/packages/wyatt_type_utils/.gitignore +++ /dev/null @@ -1,133 +0,0 @@ -# Miscellaneous -*.class -*.lock -*.log -*.pyc -*.swp -.DS_Store -.atom/ -.buildlog/ -.history -.svn/ - -# IntelliJ related -*.iml -*.ipr -*.iws -.idea/* - -# Visual Studio Code related -.classpath -.project -.settings/ -.vscode/* -!.vscode/settings.json -!.vscode/extensions.json - -# Flutter repo-specific -/bin/cache/ -/bin/mingit/ -/dev/benchmarks/mega_gallery/ -/dev/bots/.recipe_deps -/dev/bots/android_tools/ -/dev/docs/doc/ -/dev/docs/flutter.docs.zip -/dev/docs/lib/ -/dev/docs/pubspec.yaml -/dev/integration_tests/**/xcuserdata -/dev/integration_tests/**/Pods -/packages/flutter/coverage/ -version - -# packages file containing multi-root paths -.packages.generated - -# Flutter/Dart/Pub related -**/doc/api/ -**/ios/Flutter/.last_build_id -.dart_tool/ -.flutter-plugins -.flutter-plugins-dependencies -.packages -.pub-cache/ -.pub/ -build/ -flutter_*.png -linked_*.ds -unlinked.ds -unlinked_spec.ds -.fvm/ - -# Android related -**/android/**/gradle-wrapper.jar -**/android/.gradle -**/android/captures/ -**/android/gradlew -**/android/gradlew.bat -**/android/local.properties -**/android/**/GeneratedPluginRegistrant.java -**/android/key.properties -**/android/.idea/ -*.jks - -# iOS/XCode related -**/ios/**/*.mode1v3 -**/ios/**/*.mode2v3 -**/ios/**/*.moved-aside -**/ios/**/*.pbxuser -**/ios/**/*.perspectivev3 -**/ios/**/*sync/ -**/ios/**/.sconsign.dblite -**/ios/**/.tags* -**/ios/**/.vagrant/ -**/ios/**/DerivedData/ -**/ios/**/Icon? -**/ios/**/Pods/ -**/ios/**/.symlinks/ -**/ios/**/profile -**/ios/**/xcuserdata -**/ios/.generated/ -**/ios/Flutter/App.framework -**/ios/Flutter/Flutter.framework -**/ios/Flutter/Flutter.podspec -**/ios/Flutter/Generated.xcconfig -**/ios/Flutter/app.flx -**/ios/Flutter/app.zip -**/ios/Flutter/.last_build_id -**/ios/Flutter/flutter_assets/ -**/ios/Flutter/flutter_export_environment.sh -**/ios/ServiceDefinitions.json -**/ios/Runner/GeneratedPluginRegistrant.* - -# Coverage -coverage/ - -# Submodules -!pubspec.lock -packages/**/pubspec.lock - -# Web related -lib/generated_plugin_registrant.dart - -# Symbolication related -app.*.symbols - -# Obfuscation related -app.*.map.json - -# Exceptions to the above rules. -!**/ios/**/default.mode1v3 -!**/ios/**/default.mode2v3 -!**/ios/**/default.pbxuser -!**/ios/**/default.perspectivev3 -!/packages/flutter_tools/test/data/dart_dependencies_test/**/.packages -!/dev/ci/**/Gemfile.lock -!.vscode/extensions.json -!.vscode/launch.json -!.idea/codeStyles/ -!.idea/dictionaries/ -!.idea/runConfigurations/ - -# Omit committing pubspec.lock for library packages; see -# https://dart.dev/guides/libraries/private-files#pubspeclock. -pubspec.lock diff --git a/packages/wyatt_type_utils/.gitignore b/packages/wyatt_type_utils/.gitignore new file mode 120000 index 00000000..6ef08f9d --- /dev/null +++ b/packages/wyatt_type_utils/.gitignore @@ -0,0 +1 @@ +../../.gitignore \ No newline at end of file diff --git a/packages/wyatt_type_utils/AUTHORS b/packages/wyatt_type_utils/AUTHORS deleted file mode 100644 index f9506138..00000000 --- a/packages/wyatt_type_utils/AUTHORS +++ /dev/null @@ -1,8 +0,0 @@ -# Below is a list of people and organizations that have contributed -# to this project. Names should be added to the list like so: -# -# Name/Organization - -Wyatt Group S.A.S -Hugo Pointcheval -Malo Léon \ No newline at end of file diff --git a/packages/wyatt_type_utils/AUTHORS b/packages/wyatt_type_utils/AUTHORS new file mode 120000 index 00000000..f04b7e8a --- /dev/null +++ b/packages/wyatt_type_utils/AUTHORS @@ -0,0 +1 @@ +../../AUTHORS \ No newline at end of file diff --git a/packages/wyatt_type_utils/LICENSE b/packages/wyatt_type_utils/LICENSE deleted file mode 100644 index e72bfdda..00000000 --- a/packages/wyatt_type_utils/LICENSE +++ /dev/null @@ -1,674 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. - - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. - - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. - - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Use with the GNU Affero General Public License. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: - - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. - - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. \ No newline at end of file diff --git a/packages/wyatt_type_utils/LICENSE b/packages/wyatt_type_utils/LICENSE new file mode 120000 index 00000000..30cff740 --- /dev/null +++ b/packages/wyatt_type_utils/LICENSE @@ -0,0 +1 @@ +../../LICENSE \ No newline at end of file diff --git a/packages/wyatt_ui_components/.gitignore b/packages/wyatt_ui_components/.gitignore deleted file mode 100644 index e38f9b0c..00000000 --- a/packages/wyatt_ui_components/.gitignore +++ /dev/null @@ -1,133 +0,0 @@ -# Miscellaneous -*.class -*.lock -*.log -*.pyc -*.swp -.DS_Store -.atom/ -.buildlog/ -.history -.svn/ - -# IntelliJ related -*.iml -*.ipr -*.iws -.idea/* - -# Visual Studio Code related -.classpath -.project -.settings/ -.vscode/* -!.vscode/settings.json -!.vscode/extensions.json - -# Flutter repo-specific -/bin/cache/ -/bin/mingit/ -/dev/benchmarks/mega_gallery/ -/dev/bots/.recipe_deps -/dev/bots/android_tools/ -/dev/docs/doc/ -/dev/docs/flutter.docs.zip -/dev/docs/lib/ -/dev/docs/pubspec.yaml -/dev/integration_tests/**/xcuserdata -/dev/integration_tests/**/Pods -/packages/flutter/coverage/ -version - -# packages file containing multi-root paths -.packages.generated - -# Flutter/Dart/Pub related -**/doc/api/ -**/ios/Flutter/.last_build_id -.dart_tool/ -.flutter-plugins -.flutter-plugins-dependencies -.packages -.pub-cache/ -.pub/ -build/ -flutter_*.png -linked_*.ds -unlinked.ds -unlinked_spec.ds -.fvm/ - -# Android related -**/android/**/gradle-wrapper.jar -**/android/.gradle -**/android/captures/ -**/android/gradlew -**/android/gradlew.bat -**/android/local.properties -**/android/**/GeneratedPluginRegistrant.java -**/android/key.properties -**/android/.idea/ -*.jks - -# iOS/XCode related -**/ios/**/*.mode1v3 -**/ios/**/*.mode2v3 -**/ios/**/*.moved-aside -**/ios/**/*.pbxuser -**/ios/**/*.perspectivev3 -**/ios/**/*sync/ -**/ios/**/.sconsign.dblite -**/ios/**/.tags* -**/ios/**/.vagrant/ -**/ios/**/DerivedData/ -**/ios/**/Icon? -**/ios/**/Pods/ -**/ios/**/.symlinks/ -**/ios/**/profile -**/ios/**/xcuserdata -**/ios/.generated/ -**/ios/Flutter/App.framework -**/ios/Flutter/Flutter.framework -**/ios/Flutter/Flutter.podspec -**/ios/Flutter/Generated.xcconfig -**/ios/Flutter/app.flx -**/ios/Flutter/app.zip -**/ios/Flutter/.last_build_id -**/ios/Flutter/flutter_assets/ -**/ios/Flutter/flutter_export_environment.sh -**/ios/ServiceDefinitions.json -**/ios/Runner/GeneratedPluginRegistrant.* - -# Coverage -coverage/ - -# Submodules -!pubspec.lock -packages/**/pubspec.lock - -# Web related -lib/generated_plugin_registrant.dart - -# Symbolication related -app.*.symbols - -# Obfuscation related -app.*.map.json - -# Exceptions to the above rules. -!**/ios/**/default.mode1v3 -!**/ios/**/default.mode2v3 -!**/ios/**/default.pbxuser -!**/ios/**/default.perspectivev3 -!/packages/flutter_tools/test/data/dart_dependencies_test/**/.packages -!/dev/ci/**/Gemfile.lock -!.vscode/extensions.json -!.vscode/launch.json -!.idea/codeStyles/ -!.idea/dictionaries/ -!.idea/runConfigurations/ - -# Omit committing pubspec.lock for library packages; see -# https://dart.dev/guides/libraries/private-files#pubspeclock. -pubspec.lock diff --git a/packages/wyatt_ui_components/.gitignore b/packages/wyatt_ui_components/.gitignore new file mode 120000 index 00000000..6ef08f9d --- /dev/null +++ b/packages/wyatt_ui_components/.gitignore @@ -0,0 +1 @@ +../../.gitignore \ No newline at end of file diff --git a/packages/wyatt_ui_components/AUTHORS b/packages/wyatt_ui_components/AUTHORS deleted file mode 100644 index f9506138..00000000 --- a/packages/wyatt_ui_components/AUTHORS +++ /dev/null @@ -1,8 +0,0 @@ -# Below is a list of people and organizations that have contributed -# to this project. Names should be added to the list like so: -# -# Name/Organization - -Wyatt Group S.A.S -Hugo Pointcheval -Malo Léon \ No newline at end of file diff --git a/packages/wyatt_ui_components/AUTHORS b/packages/wyatt_ui_components/AUTHORS new file mode 120000 index 00000000..f04b7e8a --- /dev/null +++ b/packages/wyatt_ui_components/AUTHORS @@ -0,0 +1 @@ +../../AUTHORS \ No newline at end of file diff --git a/packages/wyatt_ui_components/LICENSE b/packages/wyatt_ui_components/LICENSE deleted file mode 100644 index e72bfdda..00000000 --- a/packages/wyatt_ui_components/LICENSE +++ /dev/null @@ -1,674 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. - - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. - - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. - - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Use with the GNU Affero General Public License. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: - - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. - - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. \ No newline at end of file diff --git a/packages/wyatt_ui_components/LICENSE b/packages/wyatt_ui_components/LICENSE new file mode 120000 index 00000000..30cff740 --- /dev/null +++ b/packages/wyatt_ui_components/LICENSE @@ -0,0 +1 @@ +../../LICENSE \ No newline at end of file diff --git a/packages/wyatt_ui_kit/.gitignore b/packages/wyatt_ui_kit/.gitignore deleted file mode 100644 index 3cceda55..00000000 --- a/packages/wyatt_ui_kit/.gitignore +++ /dev/null @@ -1,7 +0,0 @@ -# https://dart.dev/guides/libraries/private-files -# Created by `dart pub` -.dart_tool/ - -# Avoid committing pubspec.lock for library packages; see -# https://dart.dev/guides/libraries/private-files#pubspeclock. -pubspec.lock diff --git a/packages/wyatt_ui_kit/.gitignore b/packages/wyatt_ui_kit/.gitignore new file mode 120000 index 00000000..6ef08f9d --- /dev/null +++ b/packages/wyatt_ui_kit/.gitignore @@ -0,0 +1 @@ +../../.gitignore \ No newline at end of file diff --git a/packages/wyatt_ui_kit/AUTHORS b/packages/wyatt_ui_kit/AUTHORS new file mode 120000 index 00000000..f04b7e8a --- /dev/null +++ b/packages/wyatt_ui_kit/AUTHORS @@ -0,0 +1 @@ +../../AUTHORS \ No newline at end of file diff --git a/packages/wyatt_ui_kit/LICENSE b/packages/wyatt_ui_kit/LICENSE new file mode 120000 index 00000000..30cff740 --- /dev/null +++ b/packages/wyatt_ui_kit/LICENSE @@ -0,0 +1 @@ +../../LICENSE \ No newline at end of file diff --git a/packages/wyatt_ui_layout/.gitignore b/packages/wyatt_ui_layout/.gitignore deleted file mode 100644 index e38f9b0c..00000000 --- a/packages/wyatt_ui_layout/.gitignore +++ /dev/null @@ -1,133 +0,0 @@ -# Miscellaneous -*.class -*.lock -*.log -*.pyc -*.swp -.DS_Store -.atom/ -.buildlog/ -.history -.svn/ - -# IntelliJ related -*.iml -*.ipr -*.iws -.idea/* - -# Visual Studio Code related -.classpath -.project -.settings/ -.vscode/* -!.vscode/settings.json -!.vscode/extensions.json - -# Flutter repo-specific -/bin/cache/ -/bin/mingit/ -/dev/benchmarks/mega_gallery/ -/dev/bots/.recipe_deps -/dev/bots/android_tools/ -/dev/docs/doc/ -/dev/docs/flutter.docs.zip -/dev/docs/lib/ -/dev/docs/pubspec.yaml -/dev/integration_tests/**/xcuserdata -/dev/integration_tests/**/Pods -/packages/flutter/coverage/ -version - -# packages file containing multi-root paths -.packages.generated - -# Flutter/Dart/Pub related -**/doc/api/ -**/ios/Flutter/.last_build_id -.dart_tool/ -.flutter-plugins -.flutter-plugins-dependencies -.packages -.pub-cache/ -.pub/ -build/ -flutter_*.png -linked_*.ds -unlinked.ds -unlinked_spec.ds -.fvm/ - -# Android related -**/android/**/gradle-wrapper.jar -**/android/.gradle -**/android/captures/ -**/android/gradlew -**/android/gradlew.bat -**/android/local.properties -**/android/**/GeneratedPluginRegistrant.java -**/android/key.properties -**/android/.idea/ -*.jks - -# iOS/XCode related -**/ios/**/*.mode1v3 -**/ios/**/*.mode2v3 -**/ios/**/*.moved-aside -**/ios/**/*.pbxuser -**/ios/**/*.perspectivev3 -**/ios/**/*sync/ -**/ios/**/.sconsign.dblite -**/ios/**/.tags* -**/ios/**/.vagrant/ -**/ios/**/DerivedData/ -**/ios/**/Icon? -**/ios/**/Pods/ -**/ios/**/.symlinks/ -**/ios/**/profile -**/ios/**/xcuserdata -**/ios/.generated/ -**/ios/Flutter/App.framework -**/ios/Flutter/Flutter.framework -**/ios/Flutter/Flutter.podspec -**/ios/Flutter/Generated.xcconfig -**/ios/Flutter/app.flx -**/ios/Flutter/app.zip -**/ios/Flutter/.last_build_id -**/ios/Flutter/flutter_assets/ -**/ios/Flutter/flutter_export_environment.sh -**/ios/ServiceDefinitions.json -**/ios/Runner/GeneratedPluginRegistrant.* - -# Coverage -coverage/ - -# Submodules -!pubspec.lock -packages/**/pubspec.lock - -# Web related -lib/generated_plugin_registrant.dart - -# Symbolication related -app.*.symbols - -# Obfuscation related -app.*.map.json - -# Exceptions to the above rules. -!**/ios/**/default.mode1v3 -!**/ios/**/default.mode2v3 -!**/ios/**/default.pbxuser -!**/ios/**/default.perspectivev3 -!/packages/flutter_tools/test/data/dart_dependencies_test/**/.packages -!/dev/ci/**/Gemfile.lock -!.vscode/extensions.json -!.vscode/launch.json -!.idea/codeStyles/ -!.idea/dictionaries/ -!.idea/runConfigurations/ - -# Omit committing pubspec.lock for library packages; see -# https://dart.dev/guides/libraries/private-files#pubspeclock. -pubspec.lock diff --git a/packages/wyatt_ui_layout/.gitignore b/packages/wyatt_ui_layout/.gitignore new file mode 120000 index 00000000..6ef08f9d --- /dev/null +++ b/packages/wyatt_ui_layout/.gitignore @@ -0,0 +1 @@ +../../.gitignore \ No newline at end of file diff --git a/packages/wyatt_ui_layout/AUTHORS b/packages/wyatt_ui_layout/AUTHORS deleted file mode 100644 index f9506138..00000000 --- a/packages/wyatt_ui_layout/AUTHORS +++ /dev/null @@ -1,8 +0,0 @@ -# Below is a list of people and organizations that have contributed -# to this project. Names should be added to the list like so: -# -# Name/Organization - -Wyatt Group S.A.S -Hugo Pointcheval -Malo Léon \ No newline at end of file diff --git a/packages/wyatt_ui_layout/AUTHORS b/packages/wyatt_ui_layout/AUTHORS new file mode 120000 index 00000000..f04b7e8a --- /dev/null +++ b/packages/wyatt_ui_layout/AUTHORS @@ -0,0 +1 @@ +../../AUTHORS \ No newline at end of file diff --git a/packages/wyatt_ui_layout/LICENSE b/packages/wyatt_ui_layout/LICENSE deleted file mode 100644 index e72bfdda..00000000 --- a/packages/wyatt_ui_layout/LICENSE +++ /dev/null @@ -1,674 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. - - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. - - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. - - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Use with the GNU Affero General Public License. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: - - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. - - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. \ No newline at end of file diff --git a/packages/wyatt_ui_layout/LICENSE b/packages/wyatt_ui_layout/LICENSE new file mode 120000 index 00000000..30cff740 --- /dev/null +++ b/packages/wyatt_ui_layout/LICENSE @@ -0,0 +1 @@ +../../LICENSE \ No newline at end of file diff --git a/scripts/clean_gitignore.sh b/scripts/clean_gitignore.sh new file mode 100755 index 00000000..ad546849 --- /dev/null +++ b/scripts/clean_gitignore.sh @@ -0,0 +1,44 @@ +#!/usr/bin/env bash + +# Copyright (C) 2023 WYATT GROUP +# Please see the AUTHORS file for details. +# +# This program is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see . + +# Script that iterates through each package in the packages directory and +# removes .gitignore, AUTHORS, and LICENSE files if they exist. + +# Current directory +DIR=$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd) + +# Path to the packages directory +PACKAGES_DIR="$DIR/../packages" + +# Iterate through each package in the packages directory +for package in "$PACKAGES_DIR"/*; do + # Remove .gitignore file if it exists + if [ -f "$package/.gitignore" ]; then + rm "$package/.gitignore" + fi + + # Remove AUTHORS file if it exists + if [ -f "$package/AUTHORS" ]; then + rm "$package/AUTHORS" + fi + + # Remove LICENSE file if it exists + if [ -f "$package/LICENSE" ]; then + rm "$package/LICENSE" + fi +done diff --git a/scripts/symbolic_links.sh b/scripts/symbolic_links.sh new file mode 100755 index 00000000..f00ac7da --- /dev/null +++ b/scripts/symbolic_links.sh @@ -0,0 +1,52 @@ +#!/usr/bin/env bash + +# Copyright (C) 2023 WYATT GROUP +# Please see the AUTHORS file for details. +# +# This program is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see . + +# Script that iterates through each package in the packages directory and +# creates a symbolic link to the main .gitignore file, AUTHORS, and LICENSE +# files if they do not already exist. + +# Current directory +DIR=$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd) + +# Path to the packages directory +PACKAGES_DIR="$DIR/../packages" + +# Iterate through each package in the packages directory +for package in "$PACKAGES_DIR"/*; do + # Go to the package directory + cd "$package" + + # Create symbolic link to the main .gitignore file if it does not already + # exist + if [ ! -f .gitignore ]; then + ln -s ../../.gitignore .gitignore + fi + + # Create symbolic link to the main AUTHORS file if it does not already + # exist + + if [ ! -f AUTHORS ]; then + ln -s ../../AUTHORS AUTHORS + fi + + # Create symbolic link to the main LICENSE file if it does not already + # exist + if [ ! -f LICENSE ]; then + ln -s ../../LICENSE LICENSE + fi +done -- 2.47.2 From 973eefa7bca1b39aed1000513ea4567ed83f539d Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Thu, 13 Apr 2023 16:09:13 +0200 Subject: [PATCH 27/47] docs: update readme --- README.md | 176 +++++++++++++++++++++++++++++---------------- doc/work_flow.puml | 15 ---- doc/workflow.svg | 25 ------- 3 files changed, 114 insertions(+), 102 deletions(-) delete mode 100644 doc/work_flow.puml delete mode 100644 doc/workflow.svg diff --git a/README.md b/README.md index 410ef3c4..e8ed43f5 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,5 @@

- - - +

Wyatt Packages

- - Style: Wyatt Analysis - - - Maintained with Melos - + Style: Wyatt Analysis + Maintained with Melos

--- @@ -38,12 +32,40 @@ --- + + + + +- [About](#about) +- [Contribution](#contribution) + - [Prerequisite](#prerequisite) + - [Create a new package](#create-a-new-package) + - [Naming](#naming) + - [Create issues](#create-issues) + - [Branches](#branches) + - [Commits](#commits) + - [Before pushing](#before-pushing) + - [Merge your work](#merge-your-work) + - [Update version.](#update-version) + - [Publish your package](#publish-your-package) + - [Badging](#badging) +- [Usage](#usage) +- [Simple work flow diagramm](#simple-work-flow-diagramm) +- [Status](#status) +- [License](#license) + + + +--- + ## About Here is a set of [Flutter plugins](https://flutter.io/platform-plugins/) that enhance your applications. [Flutter](https://flutter.dev) is Google's UI toolkit for building beautiful, natively compiled applications for mobile, web, and desktop using a single codebase. It is used by developers and organizations worldwide and is free and open-source. +Those packages are developed by [Wyatt Studio](https://wyatt-studio.fr) and are available exclusively on this repository. + --- ## Contribution @@ -77,9 +99,9 @@ dart pub global activate mason_cli brew install lcov ``` -- genhtml. Used to convert coverage data into html pages. +* genhtml. Used to convert coverage data into html pages. -After installation of all these packages, the project can be bootstrapped using the command `melos bs`. +After installation of all these packages, the project can be bootstrapped using the command `melos bs` . ### Create a new package @@ -87,9 +109,11 @@ Create a new package in `packages/` folder. To create a new package in the packages/ folder, run the following command in the terminal: ```shell -mason make wyatt_package --package_name wyatt_ --description A new Wyatt package --flutter_only false +mason make wyatt_package_template --package_name --description A new Wyatt package --flutter false ``` +> Browse our [bricks](https://git.wyatt-studio.fr/Wyatt-FOSS/wyatt-bricks) for more information. + The variable in the above command is important and must be clear and understandable. After creating the package, bootstrap the project with the `melos bs` command. @@ -101,70 +125,63 @@ It have to be clear and intelligible. 1. You must use underscores in the name. 2. You must use the wyatt prefix for the package name. -3. You must name the example with a specific name. -For example, if the name is "CRUD BLOC," the following naming conventions should be used: +For example, if the name is `CRUD BLOC` the following naming conventions should be used: -1. name: crud_bloc -2. package name: wyatt_crud_bloc -3. example name: crud_bloc_example +1. package name: `wyatt_crud_bloc` +2. example name: `example` ### Create issues -Create an issue for each specific feature or task you want to work on and label it correctly using the following format: +Create an issue for each specific feature or task you want to work on and label it correctly using the following labels: https://git.wyatt-studio.fr/Wyatt-FOSS/wyatt-packages/labels. -``` -Type(scope): issue. -``` - -For example, on notification bloc package : - -- `Feature(notification_bloc): add firebase messaging data source.` -- `Test(notification_bloc): add test for pushwoosh datasource.` +For example, if you want to work on the `i18n` package, you should create an issue with the `i18n` label. ### Branches -The master branch is protected and cannot be pushed to directly. Please create a separate branch for each feature or task, with a name that corresponds to the related issue. The branch name should follow this format: +The `master` branch is protected and cannot be pushed to directly. Please create a separate branch for each feature or task, with a name that corresponds to the related issue. The branch name should follow this format: -`type(scope):issue` + `scope/type/short-name` -Example : -For the issue: - -- `Feature(notification_bloc): add firebase messaging data source.` - -The related branch should be named: - -- `notification_bloc/feat/add_firebase_messaging_data_source` +For example, if you are working on the `i18n` package and you want to add a new feature, you should create a branch named `i18n/feat/add-new-feature` . ### Commits See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. -tl;dr : `type(scope): description #issue`. +tldr : `type(scope): description #issue` . + Here allowed values: -- **feat** for a new feature for the user, not a new feature for build script. Such commit will trigger a release bumping a MINOR version. -- **fix** for a bug fix for the user, not a fix to a build script. Such commit will trigger a release bumping a PATCH version. -- **perf** for performance improvements. Such commit will trigger a release bumping a PATCH version. -- **docs** for changes to the documentation. -- **style** for formatting changes, missing semicolons, etc. -- **refactor** for refactoring production code, e.g. renaming a variable. -- **test** for adding missing tests, refactoring tests; no production code change. -- **build** for updating build configuration, development tools or other changes irrelevant to the user. +* **build** for updating build configuration, development tools or other changes irrelevant to the user. +* **ci** for changes to our CI configuration files and scripts. +* **docs** for changes to documentation. +* **feat** for a new feature for the user, not a new feature for build script. Such commit will trigger a release bumping a MINOR version. +* **fix** for a bug fix for the user, not a fix to a build script. Such commit will trigger a release bumping a PATCH version. +* **perf** for performance improvements. Such commit will trigger a release bumping a PATCH version. +* **refactor** for refactoring production code, e.g. renaming a variable. +* **style** for formatting changes, missing semicolons, etc. +* **test** for adding missing tests, refactoring tests; no production code change. +* **chore** for updating grunt tasks etc; no production code change. + +> Check `.pre-commit-config.yaml` and [pre-commit](https://pre-commit.com/) for more information about commit hooks. Some examples : -- `feat(auth): add AWS support. (#31)` = add a feature in authentication_bloc package, linked to the 31st issue. -- `docs: update readme.` = update **this** readme file. -- `fix(crud)!: fix bug in awesome() function. (#32)` = fix a bug, `!` is important and indicate `BREAKING CHANGES` linked with the 32nd issue. +* `feat(auth): add AWS support. (#31)` = add a feature in authentication_bloc package, linked to the 31st issue. +* `docs: update readme.` = update **this** readme file. +* `fix(crud)!: fix bug in awesome() function. (closes #32)` = fix a bug, `!` is important and indicate `BREAKING CHANGES` linked with the 32nd issue. -When you have completed your development work and are ready to resolve the related issue, you can close it via your commit message by including (close #issue_number). For example: +When you have completed your development work and are ready to resolve the related issue, you can close it via your commit message by including (closes #issue_number). For example: ```shell -feat(auth): add AWS support. (close #31) +feat(auth): add AWS support. (closes #31) ``` +> You can use `close` , `closes` , `closed` , `fix` , `fixes` , `fixed` , `resolve` , `resolves` or `resolved` . + +#### Before pushing + ```shell melos run test:all # this will run all tests in this project melos run gen-coverage # this will generate coverage report @@ -176,19 +193,19 @@ melos run publish # this will publish packages Please note that the issue will only be closed after it has been merged into the master branch. Before closing the issue, it is important to verify that all tests have been run and that coverage has been updated. -#### Merge your work +### Merge your work When you have completed your work and closed the related issue, it's possible that some changes may have been made to the master branch in the meantime. To maintain a clean Git history, it's recommended to rebase before creating a change request (pull request). Two situations : -- You haven't created a branch yet and have made local commits: +* You haven't created a branch yet and have made local commits: ```shell git pull --rebase ``` -- You are already working on a branch: +* You are already working on a branch: ```shell git rebase -i master @@ -198,7 +215,7 @@ It's recommended to use the `--fixup` option during the interactive rebase to ke Once you have rebased, you can create a pull request, receive the necessary approvals, and then merge your work. And with that, you're done! 🎉 -#### Update version. +### Update version. When your work has been merged into the master branch, it's time to update the package version. To update only your specific package, use the --scope option. For example, after merging changes into the `wyatt_notification_bloc` package, you can run the following command: @@ -214,22 +231,24 @@ You can then verify that all packages and their tests are working correctly by r melos run test:all ``` -#### Publish your package +### Publish your package -If package is ready for procution, publish it runnig : +If package is ready for production, publish it by running the following command : ```shell melos publish --scope"*package*" ``` -#### Badging +### Badging In the package `readme.md` file, please specify the supported SDK: ![SDK: Dart & Flutter](https://img.shields.io/badge/SDK-Dart%20%7C%20Flutter-blue?style=flat-square) ```markdown + ![SDK: Dart & Flutter](https://img.shields.io/badge/SDK-Dart%20%7C%20Flutter-blue?style=flat-square) + ``` or @@ -237,7 +256,9 @@ or ![SDK: Dart](https://img.shields.io/badge/SDK-Dart-blue?style=flat-square) ```markdown + ![SDK: Dart](https://img.shields.io/badge/SDK-Dart-blue?style=flat-square) + ``` --- @@ -251,11 +272,20 @@ dependencies: wyatt_analysis: git: url: https://git.wyatt-studio.fr/Wyatt-FOSS/wyatt-packages - ref: wyatt_analysis-v2.0.0 + ref: wyatt_analysis-v2.4.1 path: packages/wyatt_analysis ``` -Here you can change `package name` and `package version`. +or the hosted version : + +```yaml +dependencies: + wyatt_analysis: + hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub/ + version: 2.4.1 +``` + +Here you can change `package name` and `package version` . --- @@ -263,10 +293,32 @@ Here you can change `package name` and `package version`. To sum up, here a simple work flow diagramm. -![Dev Wokflow](doc/workflow.svg) +```plantuml +@startuml Simple Developpment Workflow +start +:Create an issue; +:Create branch related to the issue; +repeat :Commit related to the issue; +repeat while (feature is done) +:Update coverage; +:Close issue via last commit; +:Rebase from `master`; +:Create pull request; +:Merge branches; +:Update version; +:Publish package; +stop +@enduml +``` ## Status ![Status: Experimental](https://img.shields.io/badge/Status-WIP-red?style=flat-square) This repository is maintained by Wyatt Studio but work is in progress. + +## License + +[![License: GPL v3](https://img.shields.io/badge/License-GPL%20v3-blue.svg)](http://www.gnu.org/licenses/gpl-3.0) + +Thoses packages are licensed under the GNU General Public License v3.0. See the [LICENSE](LICENSE) file for details. diff --git a/doc/work_flow.puml b/doc/work_flow.puml deleted file mode 100644 index 5e6e983d..00000000 --- a/doc/work_flow.puml +++ /dev/null @@ -1,15 +0,0 @@ -@startuml Simple Developpment Workflow -start -:Create an issue; -:Create branch related to the issue; -repeat :Commit related to the issue; -repeat while (feature is done) -:Update coverage; -:Close issue via last commit; -:Rebase from `master`; -:Create pull request; -:Merge branches; -:Update version; -:Publish package; -stop -@enduml \ No newline at end of file diff --git a/doc/workflow.svg b/doc/workflow.svg deleted file mode 100644 index c8443191..00000000 --- a/doc/workflow.svg +++ /dev/null @@ -1,25 +0,0 @@ -Create an issueCreate branch related to the issueCommit related to the issuefeature is doneUpdate coverageClose issue via last commitRebase from `master`Create pull requestMerge branchesUpdate versionPublish package \ No newline at end of file -- 2.47.2 From 9f260b8d0bc56161fb0cac63effc1c07d2946b45 Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Thu, 13 Apr 2023 16:23:44 +0200 Subject: [PATCH 28/47] ci: add pubignore for each package --- .pubignore | 5 +++++ packages/wyatt_architecture/.pubignore | 1 + packages/wyatt_bloc_helper/.pubignore | 1 + packages/wyatt_bloc_layout/.pubignore | 1 + packages/wyatt_component_copy_with_extension/.pubignore | 1 + packages/wyatt_component_copy_with_gen/.pubignore | 1 + packages/wyatt_deferred_widget_annotation/.pubignore | 1 + packages/wyatt_deferred_widget_gen/.pubignore | 1 + packages/wyatt_http_client/.pubignore | 1 + packages/wyatt_i18n/.pubignore | 1 + packages/wyatt_notification_bloc/.pubignore | 1 + packages/wyatt_type_utils/.pubignore | 1 + packages/wyatt_ui_components/.pubignore | 1 + packages/wyatt_ui_kit/.pubignore | 1 + packages/wyatt_ui_layout/.pubignore | 1 + scripts/clean_gitignore.sh | 5 +++++ scripts/symbolic_links.sh | 6 ++++++ 17 files changed, 30 insertions(+) create mode 100644 .pubignore create mode 120000 packages/wyatt_architecture/.pubignore create mode 120000 packages/wyatt_bloc_helper/.pubignore create mode 120000 packages/wyatt_bloc_layout/.pubignore create mode 120000 packages/wyatt_component_copy_with_extension/.pubignore create mode 120000 packages/wyatt_component_copy_with_gen/.pubignore create mode 120000 packages/wyatt_deferred_widget_annotation/.pubignore create mode 120000 packages/wyatt_deferred_widget_gen/.pubignore create mode 120000 packages/wyatt_http_client/.pubignore create mode 120000 packages/wyatt_i18n/.pubignore create mode 120000 packages/wyatt_notification_bloc/.pubignore create mode 120000 packages/wyatt_type_utils/.pubignore create mode 120000 packages/wyatt_ui_components/.pubignore create mode 120000 packages/wyatt_ui_kit/.pubignore create mode 120000 packages/wyatt_ui_layout/.pubignore diff --git a/.pubignore b/.pubignore new file mode 100644 index 00000000..43c82d3c --- /dev/null +++ b/.pubignore @@ -0,0 +1,5 @@ +new_version.sh +.latest_version +.vscode/ +example/ +models/ diff --git a/packages/wyatt_architecture/.pubignore b/packages/wyatt_architecture/.pubignore new file mode 120000 index 00000000..52b2f28d --- /dev/null +++ b/packages/wyatt_architecture/.pubignore @@ -0,0 +1 @@ +../../.pubignore \ No newline at end of file diff --git a/packages/wyatt_bloc_helper/.pubignore b/packages/wyatt_bloc_helper/.pubignore new file mode 120000 index 00000000..52b2f28d --- /dev/null +++ b/packages/wyatt_bloc_helper/.pubignore @@ -0,0 +1 @@ +../../.pubignore \ No newline at end of file diff --git a/packages/wyatt_bloc_layout/.pubignore b/packages/wyatt_bloc_layout/.pubignore new file mode 120000 index 00000000..52b2f28d --- /dev/null +++ b/packages/wyatt_bloc_layout/.pubignore @@ -0,0 +1 @@ +../../.pubignore \ No newline at end of file diff --git a/packages/wyatt_component_copy_with_extension/.pubignore b/packages/wyatt_component_copy_with_extension/.pubignore new file mode 120000 index 00000000..52b2f28d --- /dev/null +++ b/packages/wyatt_component_copy_with_extension/.pubignore @@ -0,0 +1 @@ +../../.pubignore \ No newline at end of file diff --git a/packages/wyatt_component_copy_with_gen/.pubignore b/packages/wyatt_component_copy_with_gen/.pubignore new file mode 120000 index 00000000..52b2f28d --- /dev/null +++ b/packages/wyatt_component_copy_with_gen/.pubignore @@ -0,0 +1 @@ +../../.pubignore \ No newline at end of file diff --git a/packages/wyatt_deferred_widget_annotation/.pubignore b/packages/wyatt_deferred_widget_annotation/.pubignore new file mode 120000 index 00000000..52b2f28d --- /dev/null +++ b/packages/wyatt_deferred_widget_annotation/.pubignore @@ -0,0 +1 @@ +../../.pubignore \ No newline at end of file diff --git a/packages/wyatt_deferred_widget_gen/.pubignore b/packages/wyatt_deferred_widget_gen/.pubignore new file mode 120000 index 00000000..52b2f28d --- /dev/null +++ b/packages/wyatt_deferred_widget_gen/.pubignore @@ -0,0 +1 @@ +../../.pubignore \ No newline at end of file diff --git a/packages/wyatt_http_client/.pubignore b/packages/wyatt_http_client/.pubignore new file mode 120000 index 00000000..52b2f28d --- /dev/null +++ b/packages/wyatt_http_client/.pubignore @@ -0,0 +1 @@ +../../.pubignore \ No newline at end of file diff --git a/packages/wyatt_i18n/.pubignore b/packages/wyatt_i18n/.pubignore new file mode 120000 index 00000000..52b2f28d --- /dev/null +++ b/packages/wyatt_i18n/.pubignore @@ -0,0 +1 @@ +../../.pubignore \ No newline at end of file diff --git a/packages/wyatt_notification_bloc/.pubignore b/packages/wyatt_notification_bloc/.pubignore new file mode 120000 index 00000000..52b2f28d --- /dev/null +++ b/packages/wyatt_notification_bloc/.pubignore @@ -0,0 +1 @@ +../../.pubignore \ No newline at end of file diff --git a/packages/wyatt_type_utils/.pubignore b/packages/wyatt_type_utils/.pubignore new file mode 120000 index 00000000..52b2f28d --- /dev/null +++ b/packages/wyatt_type_utils/.pubignore @@ -0,0 +1 @@ +../../.pubignore \ No newline at end of file diff --git a/packages/wyatt_ui_components/.pubignore b/packages/wyatt_ui_components/.pubignore new file mode 120000 index 00000000..52b2f28d --- /dev/null +++ b/packages/wyatt_ui_components/.pubignore @@ -0,0 +1 @@ +../../.pubignore \ No newline at end of file diff --git a/packages/wyatt_ui_kit/.pubignore b/packages/wyatt_ui_kit/.pubignore new file mode 120000 index 00000000..52b2f28d --- /dev/null +++ b/packages/wyatt_ui_kit/.pubignore @@ -0,0 +1 @@ +../../.pubignore \ No newline at end of file diff --git a/packages/wyatt_ui_layout/.pubignore b/packages/wyatt_ui_layout/.pubignore new file mode 120000 index 00000000..52b2f28d --- /dev/null +++ b/packages/wyatt_ui_layout/.pubignore @@ -0,0 +1 @@ +../../.pubignore \ No newline at end of file diff --git a/scripts/clean_gitignore.sh b/scripts/clean_gitignore.sh index ad546849..74e5e289 100755 --- a/scripts/clean_gitignore.sh +++ b/scripts/clean_gitignore.sh @@ -32,6 +32,11 @@ for package in "$PACKAGES_DIR"/*; do rm "$package/.gitignore" fi + # Remove .pubignore file if it exists + if [ -f "$package/.pubignore" ]; then + rm "$package/.pubignore" + fi + # Remove AUTHORS file if it exists if [ -f "$package/AUTHORS" ]; then rm "$package/AUTHORS" diff --git a/scripts/symbolic_links.sh b/scripts/symbolic_links.sh index f00ac7da..1d2b6e59 100755 --- a/scripts/symbolic_links.sh +++ b/scripts/symbolic_links.sh @@ -37,6 +37,12 @@ for package in "$PACKAGES_DIR"/*; do ln -s ../../.gitignore .gitignore fi + # Create symbolic link to the main .pubignore file if it does not already + # exist + if [ ! -f .pubignore ]; then + ln -s ../../.pubignore .pubignore + fi + # Create symbolic link to the main AUTHORS file if it does not already # exist -- 2.47.2 From 84b17382c1dffd4fed5a4f3e79bd6abc13f84f82 Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Thu, 13 Apr 2023 16:24:11 +0200 Subject: [PATCH 29/47] docs(architecture): update readme --- packages/wyatt_architecture/README.md | 31 +++++++++++---------------- 1 file changed, 13 insertions(+), 18 deletions(-) diff --git a/packages/wyatt_architecture/README.md b/packages/wyatt_architecture/README.md index 871b2e08..a40b40c3 100644 --- a/packages/wyatt_architecture/README.md +++ b/packages/wyatt_architecture/README.md @@ -1,5 +1,5 @@ - - # Dart - Wyatt Type Utils

- - Style: Wyatt Analysis - + Style: Wyatt Analysis SDK: Dart & Flutter

-Type Utils for Dart & Flutter. +Either, Option and other useful types and extensions for Dart (and Flutter). ## Option\ @@ -62,8 +58,8 @@ print('`rand` contains 10 ? => ${rand.contains(10)}'); *E.g. null reference exception or index out of bounds are not related to domain - they rather indicate a defect.* Either is defined as a generic type with two branches -- success with **T** -- failure with **E** +* success with **T** +* failure with **E** It can appear in two forms, where it contains an object of **Ok**, or where it contains an object of **Err**. It cannot appear in both states at once, or in none of them. Therefore, if one possesses an **Result** instance, it either contains a successfully produced result, or contains an error object. @@ -95,20 +91,20 @@ print(myList); // prints '[42, 16]' This package also provides extensions for Dart types. -- Object - - isNull - - isNotNull - - log -- Iterable - - isNullOrEmpty - - isNotNullOrEmpty - - For bytes iterables +* Object + + isNull + + isNotNull + + log +* Iterable + + isNullOrEmpty + + isNotNullOrEmpty + + For bytes iterables - toTypedList - toStr -- String - - isNullOrEmpty - - isNotNullOrEmpty - - toBytes +* String + + isNullOrEmpty + + isNotNullOrEmpty + + toBytes String 🔁 Uint8List works with encoding: @@ -118,27 +114,27 @@ final Uint8List bytes = myString.toBytes(from : Encoding.utf16); print(bytes.toStr(to : Encoding.utf16)); // prints 'abc' ``` -- DateTime - - fromSecondsSinceEpoch - - secondsSinceEpoch - - timestamp - - tomorrow - - yesterday - - today - - add/sub/set - - nextDay - - previousDay - - nextMonth - - previousMonth - - nextYear - - previousYear - - nextWeek - - previousWeek - - isFuture - - isPast - - isLeapYear - - format - - operators +* DateTime + + fromSecondsSinceEpoch + + secondsSinceEpoch + + timestamp + + tomorrow + + yesterday + + today + + add/sub/set + + nextDay + + previousDay + + nextMonth + + previousMonth + + nextYear + + previousYear + + nextWeek + + previousWeek + + isFuture + + isPast + + isLeapYear + + format + + operators The date formatter works with `String` formatter: diff --git a/packages/wyatt_type_utils/lib/src/either/option.dart b/packages/wyatt_type_utils/lib/src/either/option.dart index d97ed2ac..3502984f 100644 --- a/packages/wyatt_type_utils/lib/src/either/option.dart +++ b/packages/wyatt_type_utils/lib/src/either/option.dart @@ -171,8 +171,11 @@ abstract class Option extends _EitherBase { } } +/// {@template value} +/// Contains the non-null value of the [Option]. +/// {@endtemplate} class Value extends Option with _Left { - /// {@macro ok} + /// {@macro value} const Value(this.value) : super._(); final T value; @@ -236,8 +239,11 @@ class Value extends Option with _Left { _EitherBase _or(_EitherBase res) => this as _EitherBase; } +/// {@template none} +/// Contains no value. +/// {@endtemplate} class None extends Option with _Right { - /// {@macro ok} + /// {@macro none} const None() : super._(); @override diff --git a/packages/wyatt_type_utils/lib/src/extensions/encoding.dart b/packages/wyatt_type_utils/lib/src/extensions/encoding.dart index 4a6fb8f7..5289d5f0 100644 --- a/packages/wyatt_type_utils/lib/src/extensions/encoding.dart +++ b/packages/wyatt_type_utils/lib/src/extensions/encoding.dart @@ -14,6 +14,7 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . +/// Defines different text encoding types. enum Encoding { utf8, utf16, diff --git a/packages/wyatt_type_utils/pubspec.yaml b/packages/wyatt_type_utils/pubspec.yaml index c74145af..94d5faf7 100644 --- a/packages/wyatt_type_utils/pubspec.yaml +++ b/packages/wyatt_type_utils/pubspec.yaml @@ -1,16 +1,16 @@ name: wyatt_type_utils -description: Either, Option and other useful types. +description: Either, Option and other useful types and extensions. repository: https://git.wyatt-studio.fr/Wyatt-FOSS/wyatt-packages/src/branch/master/packages/wyatt_type_utils version: 0.0.4 publish_to: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub environment: - sdk: '>=2.17.0 <3.0.0' + sdk: ">=2.17.0 <3.0.0" dev_dependencies: test: ^1.22.0 - + wyatt_analysis: hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub - version: ^2.4.1 \ No newline at end of file + version: ^2.4.1 -- 2.47.2 From e5e05500173d75cd4bcd97da558ee8139c16bd56 Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Thu, 13 Apr 2023 16:46:44 +0200 Subject: [PATCH 31/47] docs(arch): add documentation --- packages/wyatt_architecture/README.md | 2 +- .../repositories/photo_repository_impl.dart | 8 +++---- .../photos/add_photo_to_favorites.dart | 2 +- .../check_if_photo_is_in_favorites.dart | 2 +- .../domain/usecases/photos/display_photo.dart | 2 +- .../domain/usecases/photos/open_album.dart | 2 +- .../photos/remove_photo_from_favorites.dart | 2 +- .../usecases/photos/retrieve_all_albums.dart | 2 +- .../lib/src/core/exceptions/exceptions.dart | 21 +++++++++++++--- .../domain/data_sources/base_data_source.dart | 5 ++++ .../local/base_local_data_source.dart | 5 ++++ .../remote/base_remote_data_source.dart | 5 ++++ .../lib/src/domain/entities/entity.dart | 4 ++++ .../domain/repositories/base_repository.dart | 4 ++++ .../lib/src/domain/usecases/no_param.dart | 5 ++++ .../lib/src/domain/usecases/observers.dart | 7 +++--- .../lib/src/domain/usecases/usecase.dart | 24 +++++++++++++++++-- .../lib/wyatt_architecture.dart | 2 +- packages/wyatt_architecture/pubspec.yaml | 16 +++++-------- 19 files changed, 90 insertions(+), 30 deletions(-) diff --git a/packages/wyatt_architecture/README.md b/packages/wyatt_architecture/README.md index a40b40c3..263ab0e2 100644 --- a/packages/wyatt_architecture/README.md +++ b/packages/wyatt_architecture/README.md @@ -23,7 +23,7 @@ SDK: Flutter

-The Wyatt Architecture for Flutter. +The Wyatt Architecture for Flutter. Contains useful classes to help you to create a clean architecture following the Wyatt Architecture. (core, data, domain, presentation). ## Features diff --git a/packages/wyatt_architecture/example/lib/data/repositories/photo_repository_impl.dart b/packages/wyatt_architecture/example/lib/data/repositories/photo_repository_impl.dart index d7a5aaf3..274502f1 100644 --- a/packages/wyatt_architecture/example/lib/data/repositories/photo_repository_impl.dart +++ b/packages/wyatt_architecture/example/lib/data/repositories/photo_repository_impl.dart @@ -36,7 +36,7 @@ class PhotoRepositoryImpl extends PhotoRepository { @override FutureOrResult addPhotoToFavorites(Photo photo) => Result.tryCatchAsync( () => _favoriteLocalDataSource.addPhotoToFavorites(photo), - (error) => ClientException('Cannot add photo to favorites.'), + (error) => const ClientException('Cannot add photo to favorites.'), ); @override @@ -63,14 +63,14 @@ class PhotoRepositoryImpl extends PhotoRepository { FutureOrResult> getAllAlbums({int? start, int? limit}) => Result.tryCatchAsync( () => _albumRemoteDataSource.getAllAlbums(start: start, limit: limit), - (error) => ServerException('Cannot retrieve all albums.'), + (error) => const ServerException('Cannot retrieve all albums.'), ); @override FutureOrResult> getAllPhotos({int? start, int? limit}) async => Result.tryCatchAsync( () => _photoRemoteDataSource.getAllPhotos(start: start, limit: limit), - (error) => ServerException('Cannot retrieve all photos.'), + (error) => const ServerException('Cannot retrieve all photos.'), ); @override @@ -88,7 +88,7 @@ class PhotoRepositoryImpl extends PhotoRepository { } return Ok(response); } catch (_) { - return Err( + return const Err( ClientException('Cannot retrieve all photos from favorites.'), ); } diff --git a/packages/wyatt_architecture/example/lib/domain/usecases/photos/add_photo_to_favorites.dart b/packages/wyatt_architecture/example/lib/domain/usecases/photos/add_photo_to_favorites.dart index 769ae81d..ef8a0ec9 100644 --- a/packages/wyatt_architecture/example/lib/domain/usecases/photos/add_photo_to_favorites.dart +++ b/packages/wyatt_architecture/example/lib/domain/usecases/photos/add_photo_to_favorites.dart @@ -33,7 +33,7 @@ class AddPhotoToFavorites extends AsyncUseCase> { @override FutureOr onStart(Photo? params) { if (params == null) { - throw ClientException('Photo cannot be null'); + throw const ClientException('Photo cannot be null'); } } } diff --git a/packages/wyatt_architecture/example/lib/domain/usecases/photos/check_if_photo_is_in_favorites.dart b/packages/wyatt_architecture/example/lib/domain/usecases/photos/check_if_photo_is_in_favorites.dart index 7ff464ce..f0dcfa5c 100644 --- a/packages/wyatt_architecture/example/lib/domain/usecases/photos/check_if_photo_is_in_favorites.dart +++ b/packages/wyatt_architecture/example/lib/domain/usecases/photos/check_if_photo_is_in_favorites.dart @@ -30,7 +30,7 @@ class CheckIfPhotoIsInFavorites extends AsyncUseCase { @override FutureOr onStart(int? params) { if (params == null) { - throw ClientException('id cannot be null'); + throw const ClientException('id cannot be null'); } } } diff --git a/packages/wyatt_architecture/example/lib/domain/usecases/photos/display_photo.dart b/packages/wyatt_architecture/example/lib/domain/usecases/photos/display_photo.dart index 36076c70..79a06b8a 100644 --- a/packages/wyatt_architecture/example/lib/domain/usecases/photos/display_photo.dart +++ b/packages/wyatt_architecture/example/lib/domain/usecases/photos/display_photo.dart @@ -33,7 +33,7 @@ class DisplayPhoto extends AsyncUseCase { @override FutureOr onStart(int? params) { if (params == null) { - throw ClientException('id cannot be null'); + throw const ClientException('id cannot be null'); } } } diff --git a/packages/wyatt_architecture/example/lib/domain/usecases/photos/open_album.dart b/packages/wyatt_architecture/example/lib/domain/usecases/photos/open_album.dart index 8badf689..358e86a2 100644 --- a/packages/wyatt_architecture/example/lib/domain/usecases/photos/open_album.dart +++ b/packages/wyatt_architecture/example/lib/domain/usecases/photos/open_album.dart @@ -39,7 +39,7 @@ class OpenAlbum extends AsyncUseCase> { @override FutureOr onStart(QueryParameters? params) { if (params == null) { - throw ClientException('params cannot be null'); + throw const ClientException('params cannot be null'); } } } diff --git a/packages/wyatt_architecture/example/lib/domain/usecases/photos/remove_photo_from_favorites.dart b/packages/wyatt_architecture/example/lib/domain/usecases/photos/remove_photo_from_favorites.dart index 737c59a1..e73206b3 100644 --- a/packages/wyatt_architecture/example/lib/domain/usecases/photos/remove_photo_from_favorites.dart +++ b/packages/wyatt_architecture/example/lib/domain/usecases/photos/remove_photo_from_favorites.dart @@ -33,7 +33,7 @@ class RemovePhotoFromFavorites extends AsyncUseCase> { @override FutureOr onStart(int? params) { if (params == null) { - throw ClientException('id cannot be null'); + throw const ClientException('id cannot be null'); } } } diff --git a/packages/wyatt_architecture/example/lib/domain/usecases/photos/retrieve_all_albums.dart b/packages/wyatt_architecture/example/lib/domain/usecases/photos/retrieve_all_albums.dart index 0fc6a757..e88f8a12 100644 --- a/packages/wyatt_architecture/example/lib/domain/usecases/photos/retrieve_all_albums.dart +++ b/packages/wyatt_architecture/example/lib/domain/usecases/photos/retrieve_all_albums.dart @@ -37,7 +37,7 @@ class RetrieveAllAlbums extends AsyncUseCase> { @override FutureOr onStart(QueryParameters? params) { if (params == null) { - throw ClientException('params cannot be null'); + throw const ClientException('params cannot be null'); } } } diff --git a/packages/wyatt_architecture/lib/src/core/exceptions/exceptions.dart b/packages/wyatt_architecture/lib/src/core/exceptions/exceptions.dart index 3fb15944..e1fa8e9a 100644 --- a/packages/wyatt_architecture/lib/src/core/exceptions/exceptions.dart +++ b/packages/wyatt_architecture/lib/src/core/exceptions/exceptions.dart @@ -16,8 +16,13 @@ import 'package:wyatt_type_utils/wyatt_type_utils.dart'; +/// {@template app_exception} +/// [AppException] is a base class for all exceptions in the wyatt architecture. +/// {@endtemplate} abstract class AppException implements Exception { - AppException([this.message]); + /// {@macro app_exception} + const AppException([this.message]); + final String? message; @override @@ -30,10 +35,20 @@ abstract class AppException implements Exception { } } +/// {@template client_exception} +/// [ClientException] is a base class for all client exceptions in the wyatt +/// architecture. +/// {@endtemplate} class ClientException extends AppException { - ClientException([super.message]); + /// {@macro client_exception} + const ClientException([super.message]); } +/// {@template server_exception} +/// [ServerException] is a base class for all server exceptions in the wyatt +/// architecture. +/// {@endtemplate} class ServerException extends AppException { - ServerException([super.message]); + /// {@macro server_exception} + const ServerException([super.message]); } diff --git a/packages/wyatt_architecture/lib/src/domain/data_sources/base_data_source.dart b/packages/wyatt_architecture/lib/src/domain/data_sources/base_data_source.dart index 5dc243db..f5002603 100644 --- a/packages/wyatt_architecture/lib/src/domain/data_sources/base_data_source.dart +++ b/packages/wyatt_architecture/lib/src/domain/data_sources/base_data_source.dart @@ -14,6 +14,11 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . +/// {@template base_data_source} +/// [BaseDataSource] is a base class for all data sources in the wyatt +/// architecture. +/// {@endtemplate} abstract class BaseDataSource { + /// {@macro base_data_source} const BaseDataSource(); } diff --git a/packages/wyatt_architecture/lib/src/domain/data_sources/local/base_local_data_source.dart b/packages/wyatt_architecture/lib/src/domain/data_sources/local/base_local_data_source.dart index 1d7c134c..b091a13f 100644 --- a/packages/wyatt_architecture/lib/src/domain/data_sources/local/base_local_data_source.dart +++ b/packages/wyatt_architecture/lib/src/domain/data_sources/local/base_local_data_source.dart @@ -16,6 +16,11 @@ import 'package:wyatt_architecture/src/domain/data_sources/base_data_source.dart'; +/// {@template base_local_data_source} +/// [BaseLocalDataSource] is a base class for all local data sources in the +/// wyatt architecture. +/// {@endtemplate} abstract class BaseLocalDataSource extends BaseDataSource { + /// {@macro base_local_data_source} const BaseLocalDataSource(); } diff --git a/packages/wyatt_architecture/lib/src/domain/data_sources/remote/base_remote_data_source.dart b/packages/wyatt_architecture/lib/src/domain/data_sources/remote/base_remote_data_source.dart index a4a72999..8ed880c4 100644 --- a/packages/wyatt_architecture/lib/src/domain/data_sources/remote/base_remote_data_source.dart +++ b/packages/wyatt_architecture/lib/src/domain/data_sources/remote/base_remote_data_source.dart @@ -16,6 +16,11 @@ import 'package:wyatt_architecture/src/domain/data_sources/base_data_source.dart'; +/// {@template base_remote_data_source} +/// [BaseRemoteDataSource] is a base class for all remote data sources in the +/// wyatt architecture. +/// {@endtemplate} abstract class BaseRemoteDataSource extends BaseDataSource { + /// {@macro base_remote_data_source} const BaseRemoteDataSource(); } diff --git a/packages/wyatt_architecture/lib/src/domain/entities/entity.dart b/packages/wyatt_architecture/lib/src/domain/entities/entity.dart index fd988950..41a8ca17 100644 --- a/packages/wyatt_architecture/lib/src/domain/entities/entity.dart +++ b/packages/wyatt_architecture/lib/src/domain/entities/entity.dart @@ -14,6 +14,10 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . +/// {@template entity} +/// [Entity] is a base class for all entities in the domain layer. +/// {@endtemplate} abstract class Entity { + /// {@macro entity} const Entity(); } diff --git a/packages/wyatt_architecture/lib/src/domain/repositories/base_repository.dart b/packages/wyatt_architecture/lib/src/domain/repositories/base_repository.dart index 4a08a0db..a7e26b12 100644 --- a/packages/wyatt_architecture/lib/src/domain/repositories/base_repository.dart +++ b/packages/wyatt_architecture/lib/src/domain/repositories/base_repository.dart @@ -14,6 +14,10 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . +/// {@template base_repository} +/// [BaseRepository] is a base class for all repositories in the domain layer. +/// {@endtemplate} abstract class BaseRepository { + /// {@macro base_repository} const BaseRepository(); } diff --git a/packages/wyatt_architecture/lib/src/domain/usecases/no_param.dart b/packages/wyatt_architecture/lib/src/domain/usecases/no_param.dart index 7452af67..4509bd59 100644 --- a/packages/wyatt_architecture/lib/src/domain/usecases/no_param.dart +++ b/packages/wyatt_architecture/lib/src/domain/usecases/no_param.dart @@ -16,6 +16,11 @@ import 'package:wyatt_architecture/src/domain/entities/entity.dart'; +/// {@template no_param} +/// [NoParam] is a class that is used when a use case does not require any +/// parameters. +/// {@endtemplate} class NoParam extends Entity { + /// {@macro no_param} const NoParam(); } diff --git a/packages/wyatt_architecture/lib/src/domain/usecases/observers.dart b/packages/wyatt_architecture/lib/src/domain/usecases/observers.dart index 370546fe..a1925577 100644 --- a/packages/wyatt_architecture/lib/src/domain/usecases/observers.dart +++ b/packages/wyatt_architecture/lib/src/domain/usecases/observers.dart @@ -21,16 +21,17 @@ import 'package:wyatt_architecture/wyatt_architecture.dart'; /// Usecase observers mixin Observer { /// Called before usecase is runned. - /// Usefull to check the preconditions + /// Useful to check the preconditions FutureOr onStart(Parameters? params) {} /// Called when error occures during main scenario - /// Usefull to run alternative scenario + /// Useful to run alternative scenario FutureOr onError(AppException? error) {} } /// Specific observer for classic usecase mixin AsyncObserver { + /// Called when usecase is completed FutureOr onComplete(ReturnType? data) {} } @@ -39,6 +40,6 @@ mixin StreamObserver { /// Replaces the data event handler of this subscription. void onDone() {} - /// Replaces the done event handler of this subscription. + /// Replaces the done event handler of this subscription. void onData(ReturnType? data) {} } diff --git a/packages/wyatt_architecture/lib/src/domain/usecases/usecase.dart b/packages/wyatt_architecture/lib/src/domain/usecases/usecase.dart index c406535d..75c4c905 100644 --- a/packages/wyatt_architecture/lib/src/domain/usecases/usecase.dart +++ b/packages/wyatt_architecture/lib/src/domain/usecases/usecase.dart @@ -23,8 +23,13 @@ import 'package:wyatt_type_utils/wyatt_type_utils.dart'; typedef FutureOrResult = FutureOr>; typedef StreamResult = Stream>; -/// Abstract class of a use case +/// {@template base_usecase} +/// Abstract class of any use case. +/// {@endtemplate} abstract class BaseUseCase { + /// {@macro base_usecase} + const BaseUseCase(); + /// Run use case scenarios ReturnType call(Parameters parameters); @@ -33,11 +38,16 @@ abstract class BaseUseCase { ReturnType execute(Parameters params); } +/// {@template usecase} /// Abstract class of a use case that deals specifically /// with the response and its state. +/// {@endtemplate} abstract class UseCase extends BaseUseCase> with Observer { + /// {@macro usecase} + const UseCase(); + FutureOr _onSuccess(ReturnType data); /// Supports the result of the main scenario and integrates @@ -59,17 +69,27 @@ abstract class UseCase } } -/// Abtstract classic usecase. +/// {@template async_usecase} +/// Abtstract classic usecase bases on futures +/// {@endtemplate} abstract class AsyncUseCase extends UseCase with AsyncObserver { + /// {@macro async_usecase} + const AsyncUseCase(); + @override FutureOr _onSuccess(ReturnType data) => onComplete(data); } +/// {@template stream_usecase} /// Abstract specific usecase bases on streams +/// {@endtemplate} abstract class StreamUseCase extends UseCase> with StreamObserver { + /// {@macro stream_usecase} + const StreamUseCase(); + @override FutureOr _onSuccess(Stream data) { data.listen( diff --git a/packages/wyatt_architecture/lib/wyatt_architecture.dart b/packages/wyatt_architecture/lib/wyatt_architecture.dart index 54c20e0d..f07613aa 100644 --- a/packages/wyatt_architecture/lib/wyatt_architecture.dart +++ b/packages/wyatt_architecture/lib/wyatt_architecture.dart @@ -14,7 +14,7 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . -/// Architecture +/// Wyatt Architecture for Flutter library wyatt_architecture; export 'src/src.dart'; diff --git a/packages/wyatt_architecture/pubspec.yaml b/packages/wyatt_architecture/pubspec.yaml index cac59f5f..dafcc4eb 100644 --- a/packages/wyatt_architecture/pubspec.yaml +++ b/packages/wyatt_architecture/pubspec.yaml @@ -1,27 +1,23 @@ name: wyatt_architecture -description: A new Wyatt package +description: Wyatt Architecture contains useful classes to help you to create a clean architecture following the Wyatt Architecture principles. repository: https://git.wyatt-studio.fr/Wyatt-FOSS/wyatt-packages/src/branch/master/packages/wyatt_architecture version: 0.1.0+1 publish_to: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub environment: - sdk: '>=2.17.0 <3.0.0' + sdk: ">=2.17.0 <3.0.0" dependencies: - - flutter: - sdk: flutter + flutter: { sdk: flutter } wyatt_type_utils: hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub version: ^0.0.4 dev_dependencies: - - flutter_test: - sdk: flutter - + flutter_test: { sdk: flutter } + wyatt_analysis: hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub - version: ^2.4.1 \ No newline at end of file + version: ^2.4.1 -- 2.47.2 From 41add204f3fc04612e9ee0b5ac85fd683a596bc4 Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Thu, 13 Apr 2023 20:17:25 +0200 Subject: [PATCH 32/47] docs: change some documentation --- README.md | 6 ++++-- packages/wyatt_analysis/README.md | 2 +- packages/wyatt_architecture/README.md | 4 ++-- packages/wyatt_type_utils/README.md | 10 +++++++++- packages/wyatt_type_utils/lib/src/src.dart | 6 +----- 5 files changed, 17 insertions(+), 11 deletions(-) diff --git a/README.md b/README.md index e8ed43f5..8b78891e 100644 --- a/README.md +++ b/README.md @@ -253,14 +253,16 @@ In the package `readme.md` file, please specify the supported SDK: or -![SDK: Dart](https://img.shields.io/badge/SDK-Dart-blue?style=flat-square) +![SDK: Flutter](https://img.shields.io/badge/SDK-Flutter-blue?style=flat-square) ```markdown -![SDK: Dart](https://img.shields.io/badge/SDK-Dart-blue?style=flat-square) +![SDK: Flutter](https://img.shields.io/badge/SDK-Flutter-blue?style=flat-square) ``` +> Some packages requires Flutter, so please specify it. + --- ## Usage diff --git a/packages/wyatt_analysis/README.md b/packages/wyatt_analysis/README.md index 28b5244d..95d85e02 100644 --- a/packages/wyatt_analysis/README.md +++ b/packages/wyatt_analysis/README.md @@ -20,7 +20,7 @@ ![SDK: Dart & Flutter](https://img.shields.io/badge/SDK-Dart%20%7C%20Flutter-blue?style=flat-square) -This package provides lint rules for Dart and Flutter which are used at [Wyatt](https://wyattapp.io) and [Wyatt Studio](https://wyatt-studio.fr). For more information, see the complete list of options in **lib/analysis_options.2.4.1.yaml**. +This package provides lint rules for Dart and Flutter which are used at [Wyatt Studio](https://wyatt-studio.fr). For more information, see the complete list of options in **lib/analysis_options.2.4.1.yaml**. **Note**: This package was heavily inspired by [pedantic](https://github.com/dart-lang/pedantic), [Very Good Analysis](https://github.com/VeryGoodOpenSource/very_good_analysis) and the official [flutter_lints](https://pub.dev/packages/flutter_lints). diff --git a/packages/wyatt_architecture/README.md b/packages/wyatt_architecture/README.md index 263ab0e2..e077fbec 100644 --- a/packages/wyatt_architecture/README.md +++ b/packages/wyatt_architecture/README.md @@ -16,11 +16,11 @@ * along with this program. If not, see . --> -# Flutter - Wyatt Architecture +# Wyatt Architecture

Style: Wyatt Analysis - SDK: Flutter + SDK: Dart & Flutter

The Wyatt Architecture for Flutter. Contains useful classes to help you to create a clean architecture following the Wyatt Architecture. (core, data, domain, presentation). diff --git a/packages/wyatt_type_utils/README.md b/packages/wyatt_type_utils/README.md index 98034973..b36d5c1f 100644 --- a/packages/wyatt_type_utils/README.md +++ b/packages/wyatt_type_utils/README.md @@ -16,7 +16,7 @@ * along with this program. If not, see . --> -# Dart - Wyatt Type Utils +# Wyatt Type Utils

Style: Wyatt Analysis @@ -142,3 +142,11 @@ The date formatter works with `String` formatter: final DateTime date = DateTime(1999, 6, 30); print(date.format([dd, '/', mm, '/', yy])); // prints '30/06/99' ``` + +Allow comparison between nullable numbers: + +```dart +final int? a = 10; +final int? b = 20; +print(a < b); // prints 'true' +``` diff --git a/packages/wyatt_type_utils/lib/src/src.dart b/packages/wyatt_type_utils/lib/src/src.dart index 34d55694..c1d65c3c 100644 --- a/packages/wyatt_type_utils/lib/src/src.dart +++ b/packages/wyatt_type_utils/lib/src/src.dart @@ -15,9 +15,5 @@ // along with this program. If not, see . export 'either/either_base.dart'; -export 'extensions/date_time_extension.dart'; -export 'extensions/encoding.dart'; -export 'extensions/iterable_extension.dart'; -export 'extensions/object_extension.dart'; -export 'extensions/string_extension.dart'; +export 'extensions/extensions.dart'; export 'pair/pair.dart'; -- 2.47.2 From 72b27b27ee031b03b861b13dfd3d8c0591679b76 Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Thu, 13 Apr 2023 20:17:55 +0200 Subject: [PATCH 33/47] refactor(arch): move to dart package --- packages/wyatt_architecture/pubspec.yaml | 20 ++++++++++++++++---- 1 file changed, 16 insertions(+), 4 deletions(-) diff --git a/packages/wyatt_architecture/pubspec.yaml b/packages/wyatt_architecture/pubspec.yaml index dafcc4eb..e447fa29 100644 --- a/packages/wyatt_architecture/pubspec.yaml +++ b/packages/wyatt_architecture/pubspec.yaml @@ -1,3 +1,19 @@ +# Copyright (C) 2023 WYATT GROUP +# Please see the AUTHORS file for details. +# +# This program is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see . + name: wyatt_architecture description: Wyatt Architecture contains useful classes to help you to create a clean architecture following the Wyatt Architecture principles. repository: https://git.wyatt-studio.fr/Wyatt-FOSS/wyatt-packages/src/branch/master/packages/wyatt_architecture @@ -9,15 +25,11 @@ environment: sdk: ">=2.17.0 <3.0.0" dependencies: - flutter: { sdk: flutter } - wyatt_type_utils: hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub version: ^0.0.4 dev_dependencies: - flutter_test: { sdk: flutter } - wyatt_analysis: hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub version: ^2.4.1 -- 2.47.2 From 468aa72635638c40ffc8f8e40382ce5cbb6fe8b3 Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Thu, 13 Apr 2023 20:18:45 +0200 Subject: [PATCH 34/47] refactor(bloc_helper): docs + nullable multiprovider attributes --- packages/wyatt_bloc_helper/README.md | 14 ++++---- .../lib/src/utils/smart_provider.dart | 7 ++++ .../lib/src/widgets/multi_provider.dart | 36 ++++++++++++++----- packages/wyatt_bloc_helper/pubspec.yaml | 14 ++++---- 4 files changed, 47 insertions(+), 24 deletions(-) diff --git a/packages/wyatt_bloc_helper/README.md b/packages/wyatt_bloc_helper/README.md index 5b055eb4..ea4ffd4f 100644 --- a/packages/wyatt_bloc_helper/README.md +++ b/packages/wyatt_bloc_helper/README.md @@ -7,7 +7,7 @@ * the Free Software Foundation, either version 3 of the License, or * any later version. * - * This program is distributed in the hope that it will be useful, + * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. @@ -16,12 +16,10 @@ * along with this program. If not, see . --> -# Flutter - BloC Helper +# BloC Helper

- - Style: Wyatt Analysis - + Style: Wyatt Analysis SDK: Flutter

@@ -86,7 +84,7 @@ Widget buildChild(BuildContext context) { } ``` -> Note: here, you can use BlocBuilder, BlocListener,... and access Bloc and Repository instance with the mixin helper. +> Note: here, you can use BlocBuilder, BlocListener, ... and access Bloc and Repository instance with the mixin helper. ### Only BlocConsumer @@ -116,7 +114,7 @@ Widget onBuild(BuildContext context, CounterState state) { } ``` -If needed, you can wrap what depends on the state with the function `parent`. +If needed, you can wrap what depends on the state with the function `parent` . ```dart @override @@ -129,7 +127,7 @@ Widget parent(BuildContext context, Widget child) { ); ``` -> Note: you can override `onBuild`, but also `onListen`, `shouldBuildWhen` and `shouldListenWhen` methods. +> Note: you can override `onBuild` , but also `onListen` , `shouldBuildWhen` and `shouldListenWhen` methods. ### Both BlocProvider and BlocConsumer diff --git a/packages/wyatt_bloc_helper/lib/src/utils/smart_provider.dart b/packages/wyatt_bloc_helper/lib/src/utils/smart_provider.dart index 046da441..9ac68ddb 100644 --- a/packages/wyatt_bloc_helper/lib/src/utils/smart_provider.dart +++ b/packages/wyatt_bloc_helper/lib/src/utils/smart_provider.dart @@ -17,7 +17,12 @@ import 'package:flutter/widgets.dart'; import 'package:flutter_bloc/flutter_bloc.dart'; +/// A utility class that provides a way to create a [BlocProvider] or +/// [RepositoryProvider] with a [Bloc] or Repository that is already +/// available in the widget tree. abstract class SmartProvider { + /// Creates a [BlocProvider] with a [Bloc] that is possibly already + /// available in the widget tree. static BlocProvider bloc, State extends Object>( BuildContext context, { @@ -45,6 +50,8 @@ abstract class SmartProvider { ); } + /// Creates a [RepositoryProvider] with a Repository that is possibly + /// already available in the widget tree. static RepositoryProvider repo( BuildContext context, { required Repository Function(BuildContext) create, diff --git a/packages/wyatt_bloc_helper/lib/src/widgets/multi_provider.dart b/packages/wyatt_bloc_helper/lib/src/widgets/multi_provider.dart index 4cb3c2bf..4ddfbea0 100644 --- a/packages/wyatt_bloc_helper/lib/src/widgets/multi_provider.dart +++ b/packages/wyatt_bloc_helper/lib/src/widgets/multi_provider.dart @@ -77,9 +77,9 @@ import 'package:flutter_bloc/flutter_bloc.dart'; class MultiProvider extends StatelessWidget { /// {@macro multi_provider} const MultiProvider({ - required this.repositoryProviders, - required this.blocProviders, required this.child, + this.repositoryProviders = const >[], + this.blocProviders = const [], super.key, }); @@ -88,11 +88,31 @@ class MultiProvider extends StatelessWidget { final Widget child; @override - Widget build(BuildContext context) => MultiRepositoryProvider( - providers: repositoryProviders, - child: MultiBlocProvider( - providers: blocProviders, - child: child, - ), + Widget build(BuildContext context) { + if (repositoryProviders.isEmpty && blocProviders.isEmpty) { + return child; + } + + if (repositoryProviders.isEmpty) { + return MultiBlocProvider( + providers: blocProviders, + child: child, ); + } + + if (blocProviders.isEmpty) { + return MultiRepositoryProvider( + providers: repositoryProviders, + child: child, + ); + } + + return MultiRepositoryProvider( + providers: repositoryProviders, + child: MultiBlocProvider( + providers: blocProviders, + child: child, + ), + ); + } } diff --git a/packages/wyatt_bloc_helper/pubspec.yaml b/packages/wyatt_bloc_helper/pubspec.yaml index 00af1bf5..a133308c 100644 --- a/packages/wyatt_bloc_helper/pubspec.yaml +++ b/packages/wyatt_bloc_helper/pubspec.yaml @@ -6,20 +6,18 @@ version: 2.0.0 publish_to: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub environment: - sdk: '>=2.17.0 <3.0.0' + sdk: ">=2.17.0 <3.0.0" dependencies: - flutter: - sdk: flutter - + flutter: { sdk: flutter } + flutter_bloc: ^8.1.1 equatable: ^2.0.5 dev_dependencies: - flutter_test: - sdk: flutter + flutter_test: { sdk: flutter } bloc_test: ^9.1.0 - + wyatt_analysis: hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub - version: ^2.4.1 \ No newline at end of file + version: ^2.4.1 -- 2.47.2 From 4acab9a662c499c3825d5ff156db697f3f3ee324 Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Thu, 13 Apr 2023 20:19:35 +0200 Subject: [PATCH 35/47] feat(type_utils): add nullable num comparison --- .../lib/src/extensions/extensions.dart | 22 ++++++++ .../lib/src/extensions/num_extension.dart | 51 +++++++++++++++++++ 2 files changed, 73 insertions(+) create mode 100644 packages/wyatt_type_utils/lib/src/extensions/extensions.dart create mode 100644 packages/wyatt_type_utils/lib/src/extensions/num_extension.dart diff --git a/packages/wyatt_type_utils/lib/src/extensions/extensions.dart b/packages/wyatt_type_utils/lib/src/extensions/extensions.dart new file mode 100644 index 00000000..be624333 --- /dev/null +++ b/packages/wyatt_type_utils/lib/src/extensions/extensions.dart @@ -0,0 +1,22 @@ +// Copyright (C) 2023 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +export 'date_time_extension.dart'; +export 'encoding.dart'; +export 'iterable_extension.dart'; +export 'num_extension.dart'; +export 'object_extension.dart'; +export 'string_extension.dart'; diff --git a/packages/wyatt_type_utils/lib/src/extensions/num_extension.dart b/packages/wyatt_type_utils/lib/src/extensions/num_extension.dart new file mode 100644 index 00000000..66979260 --- /dev/null +++ b/packages/wyatt_type_utils/lib/src/extensions/num_extension.dart @@ -0,0 +1,51 @@ +// Copyright (C) 2023 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +extension NumExtension on num? { + bool operator <(num? other) { + if (this == null || other == null) { + return false; + } + return this < other; + } + + bool operator >(num? other) { + if (this == null || other == null) { + return false; + } + return this > other; + } + + bool operator <=(num? other) { + if (this == null && other == null) { + return true; + } + if (this == null || other == null) { + return false; + } + return this <= other; + } + + bool operator >=(num? other) { + if (this == null && other == null) { + return true; + } + if (this == null || other == null) { + return false; + } + return this >= other; + } +} -- 2.47.2 From 216a6c2aae736519c5287a5345984314b6a95fee Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Thu, 13 Apr 2023 20:21:30 +0200 Subject: [PATCH 36/47] feat(crud): change responsibility of blocs (closes #45, closes #44) --- packages/wyatt_crud_bloc/README.md | 178 +++++++-- packages/wyatt_crud_bloc/example/lib/app.dart | 26 +- .../wyatt_crud_bloc/example/lib/models.dart | 29 +- .../example/lib/user_cubit.dart | 25 +- .../wyatt_crud_bloc/lib/src/core/core.dart | 1 + .../lib/src/core/enums/where_query_type.dart | 1 + .../lib/src/core/mixins/operation.dart | 30 ++ .../crud_in_memory_data_source_impl.dart | 8 +- .../crud_firestore_data_source_impl.dart | 8 + .../repositories/crud_repository_impl.dart | 8 +- .../domain/data_sources/crud_data_source.dart | 15 + .../lib/src/domain/entities/object_model.dart | 7 + .../lib/src/domain/entities/query.dart | 48 ++- .../domain/repositories/crud_repository.dart | 23 ++ .../lib/src/domain/usecases/create.dart | 13 +- .../lib/src/domain/usecases/delete.dart | 13 +- .../lib/src/domain/usecases/delete_all.dart | 11 +- .../lib/src/domain/usecases/get.dart | 11 +- .../lib/src/domain/usecases/get_all.dart | 12 +- .../usecases/params/stream_parameters.dart | 16 +- .../usecases/params/update_parameters.dart | 20 +- .../lib/src/domain/usecases/query.dart | 13 +- .../lib/src/domain/usecases/stream_query.dart | 44 --- .../lib/src/domain/usecases/update.dart | 13 +- .../lib/src/domain/usecases/update_all.dart | 13 +- .../lib/src/domain/usecases/usecases.dart | 1 - .../crud/blocs/crud_advanced_cubit.dart | 305 +++++++++++++++ .../crud_base_cubit/crud_base_cubit.dart} | 41 +- .../crud_base_cubit}/crud_state.dart | 40 +- .../src/features/crud/blocs/crud_cubit.dart | 369 ++++++++++++++++++ .../features/crud/builder/crud_builder.dart | 26 +- .../lib/src/features/crud/crud.dart | 4 +- .../src/features/crud/cubit/crud_cubit.dart | 266 ------------- packages/wyatt_crud_bloc/pubspec.yaml | 6 +- 34 files changed, 1146 insertions(+), 498 deletions(-) create mode 100644 packages/wyatt_crud_bloc/lib/src/core/mixins/operation.dart delete mode 100644 packages/wyatt_crud_bloc/lib/src/domain/usecases/stream_query.dart create mode 100644 packages/wyatt_crud_bloc/lib/src/features/crud/blocs/crud_advanced_cubit.dart rename packages/wyatt_crud_bloc/lib/src/{core/extensions/num_extension.dart => features/crud/blocs/crud_base_cubit/crud_base_cubit.dart} (51%) rename packages/wyatt_crud_bloc/lib/src/features/crud/{cubit => blocs/crud_base_cubit}/crud_state.dart (58%) create mode 100644 packages/wyatt_crud_bloc/lib/src/features/crud/blocs/crud_cubit.dart delete mode 100644 packages/wyatt_crud_bloc/lib/src/features/crud/cubit/crud_cubit.dart diff --git a/packages/wyatt_crud_bloc/README.md b/packages/wyatt_crud_bloc/README.md index 8b55e735..4f483186 100644 --- a/packages/wyatt_crud_bloc/README.md +++ b/packages/wyatt_crud_bloc/README.md @@ -1,39 +1,167 @@ - -TODO: Put a short description of the package here that helps potential users -know whether this package might be useful for them. +# CRUD BloC -## Features +

+ Style: Wyatt Analysis + SDK: Flutter +

-TODO: List what your package can do. Maybe include images, gifs, or videos. +CRUD Bloc Pattern utilities for Flutter. -## Getting started +This package defines a set of classes that can be used to implement the CRUD Bloc Pattern. -TODO: List prerequisites and provide or point to information on how to -start using the package. +* Model +* Data Source + + In Memory + + Firestore +* Repository +* Use Case + + Create + + Get + + Get All + + Update + + Update All + + Delete + + Delete All + + Query +* Bloc + + Standard (C R U D), you have to choose the responsiblity of the bloc for each use case. For example, you can have a cubit that only handles the creation of an entity, and another cubit that only handles the deletion of an entity. Each cubit can only have one operation responsibility of each type, for example you can't have a cubit that handles get and get all. + + Advanced, you can set every use case to be handled by the bloc. This is useful if you want to have a single bloc that handles all the operations of an entity. ## Usage -TODO: Include short and useful examples for package users. Add longer examples -to `/example` folder. +Create a model class that extends the `ObjectModel` class. ```dart -const like = 'sample'; +class User extends ObjectModel { + @override + final String? id; + + final String? name; + + const User({ + required this.name, + this.id, + }); + + Map toMap() { + return { + 'name': name ?? '', + }; + } + + @override + String toString() => 'User(id: $id, name: $name)'; +} ``` -## Additional information +You have to implement a bloc. -TODO: Tell users more about the package: where to find more information, how to -contribute to the package, how to file issues, what response they can expect -from the package authors, and more. +```dart +/// A [CrudCubit] for [User]. +class UserCubit extends CrudCubit { + final CrudRepository _crudRepository; + + UserCubit(this._crudRepository); + + @override + CreateOperation? get createOperation => + Create(_crudRepository); + + @override + DeleteOperation? get deleteOperation => + Delete(_crudRepository); + + @override + ReadOperation? get readOperation => + GetAll(_crudRepository); + + @override + UpdateOperation? get updateOperation => + Update(_crudRepository); +} +``` + +> You can also use the `CrudAdvancedCubit` class to implement a bloc that handles all the use cases. + +Then you can use the bloc in your widget with a data source and a repository. + +```dart +class MyApp extends StatelessWidget { + const MyApp({Key? key}) : super(key: key); + + // This widget is the root of your application. + @override + Widget build(BuildContext context) { + final CrudDataSource userLocalDataSource = + CrudInMemoryDataSourceImpl(toMap: (user) => user.toMap()); + + final CrudRepository userRepository = + CrudRepositoryImpl(crudDataSource: userLocalDataSource); + + return RepositoryProvider>.value( + value: userRepository, + child: BlocProvider( + create: (context) => UserCubit(userRepository)..read(), + child: MaterialApp( + title: 'Flutter Demo', + theme: ThemeData( + primarySwatch: Colors.blue, + ), + home: const MyHomePage(), + ), + ), + ); + } +} +``` + +And anywhere in your widget tree you can use the BlocBuilder to build your widget. + +```dart +... +BlocBuilder( + builder: (context, state) { + return CrudBuilder.typed>( + state: state, + builder: ((context, state) { + return ListView.builder( + shrinkWrap: true, + itemCount: state.data.length, + itemBuilder: (context, index) { + final user = state.data.elementAt(index); + return ListTile( + title: Text(user?.name ?? 'Error'), + subtitle: Text(user?.id ?? 'Error'), + onTap: () { + context.read().delete(id: (user?.id)!); + }, + ); + }, + ); + }), + initialBuilder: (context, state) => const Text("Loading..."), + loadingBuilder: (context, state) => const Text("Loading..."), + errorBuilder: (context, state) => Text("Error: $state"), + ); + }, +), +... +``` diff --git a/packages/wyatt_crud_bloc/example/lib/app.dart b/packages/wyatt_crud_bloc/example/lib/app.dart index 47d7e59e..d5339343 100644 --- a/packages/wyatt_crud_bloc/example/lib/app.dart +++ b/packages/wyatt_crud_bloc/example/lib/app.dart @@ -36,8 +36,12 @@ class MyApp extends StatelessWidget { return RepositoryProvider>.value( value: userRepository, - child: BlocProvider( - create: (context) => UserCubit(userRepository)..getAll(), + child: MultiBlocProvider( + providers: [ + BlocProvider( + create: (context) => UserCubit(userRepository)..read(), + ), + ], child: MaterialApp( title: 'Flutter Demo', theme: ThemeData( @@ -78,9 +82,7 @@ class MyHomePage extends StatelessWidget { title: Text(user?.name ?? 'Error'), subtitle: Text(user?.id ?? 'Error'), onTap: () { - context.read().delete( - (user?.id)!, - ); + context.read().delete(id: (user?.id)!); }, ); }, @@ -108,22 +110,10 @@ class MyHomePage extends StatelessWidget { ), ElevatedButton( onPressed: () { - context.read().deleteAll(); - }, - child: const Text("DeleteAll"), - ), - ElevatedButton( - onPressed: () { - context.read().getAll(); + context.read().read(); }, child: const Text("GetAll"), ), - ElevatedButton( - onPressed: () { - context.read().query([LimitQuery(2)]); - }, - child: const Text("Query"), - ), const SizedBox(height: 20), ], ), diff --git a/packages/wyatt_crud_bloc/example/lib/models.dart b/packages/wyatt_crud_bloc/example/lib/models.dart index b4ccfebf..e9ed1c7f 100644 --- a/packages/wyatt_crud_bloc/example/lib/models.dart +++ b/packages/wyatt_crud_bloc/example/lib/models.dart @@ -18,37 +18,18 @@ import 'package:wyatt_crud_bloc/wyatt_crud_bloc.dart'; class User extends ObjectModel { @override - String? id; + final String? id; - String? name; - String? email; - String? phone; + final String? name; + final String? email; + final String? phone; - User({ + const User({ required this.name, required this.email, required this.phone, this.id, }); - // User._(); - - // factory User.parser() { - // return User._(); - // } - - // @override - // User? from(DocumentSnapshot? object) { - // if (object == null) return null; - // if (object.exists) { - // return User( - // id: object.id, - // name: (object.data() as Map?)!['name'] as String, - // email: (object.data() as Map?)!['email'] as String, - // phone: (object.data() as Map?)!['phone'] as String, - // ); - // } - // return null; - // } Map toMap() { return { diff --git a/packages/wyatt_crud_bloc/example/lib/user_cubit.dart b/packages/wyatt_crud_bloc/example/lib/user_cubit.dart index 703d6686..cc34df6c 100644 --- a/packages/wyatt_crud_bloc/example/lib/user_cubit.dart +++ b/packages/wyatt_crud_bloc/example/lib/user_cubit.dart @@ -17,32 +17,25 @@ import 'package:crud_bloc_example/models.dart'; import 'package:wyatt_crud_bloc/wyatt_crud_bloc.dart'; +/// A [CrudCubit] for [User]. class UserCubit extends CrudCubit { final CrudRepository _crudRepository; UserCubit(this._crudRepository); @override - Create? get crudCreate => Create(_crudRepository); + CreateOperation? get createOperation => + Create(_crudRepository); @override - Delete? get crudDelete => Delete(_crudRepository); + DeleteOperation? get deleteOperation => + Delete(_crudRepository); @override - DeleteAll? get crudDeleteAll => DeleteAll(_crudRepository); + ReadOperation? get readOperation => + GetAll(_crudRepository); @override - Get? get crudGet => Get(_crudRepository); - - @override - GetAll? get crudGetAll => GetAll(_crudRepository); - - @override - Query? get crudQuery => Query(_crudRepository); - - @override - Update? get crudUpdate => Update(_crudRepository); - - @override - UpdateAll? get crudUpdateAll => UpdateAll(_crudRepository); + UpdateOperation? get updateOperation => + Update(_crudRepository); } diff --git a/packages/wyatt_crud_bloc/lib/src/core/core.dart b/packages/wyatt_crud_bloc/lib/src/core/core.dart index 1d218692..12ebcadf 100644 --- a/packages/wyatt_crud_bloc/lib/src/core/core.dart +++ b/packages/wyatt_crud_bloc/lib/src/core/core.dart @@ -15,3 +15,4 @@ // along with this program. If not, see . export 'enums/where_query_type.dart'; +export 'mixins/operation.dart'; diff --git a/packages/wyatt_crud_bloc/lib/src/core/enums/where_query_type.dart b/packages/wyatt_crud_bloc/lib/src/core/enums/where_query_type.dart index f20879e7..6a7c9bfe 100644 --- a/packages/wyatt_crud_bloc/lib/src/core/enums/where_query_type.dart +++ b/packages/wyatt_crud_bloc/lib/src/core/enums/where_query_type.dart @@ -14,6 +14,7 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . +/// Defines different query types for WhereQuery. enum WhereQueryType { isEqualTo, isNotEqualTo, diff --git a/packages/wyatt_crud_bloc/lib/src/core/mixins/operation.dart b/packages/wyatt_crud_bloc/lib/src/core/mixins/operation.dart new file mode 100644 index 00000000..7a1b9b09 --- /dev/null +++ b/packages/wyatt_crud_bloc/lib/src/core/mixins/operation.dart @@ -0,0 +1,30 @@ +// Copyright (C) 2023 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +import 'package:wyatt_architecture/wyatt_architecture.dart'; +import 'package:wyatt_crud_bloc/src/domain/entities/object_model.dart'; + +/// Defines every write operation in CRUD. +mixin CreateOperation on AsyncUseCase {} + +/// Defines every read operation in CRUD. +mixin ReadOperation on AsyncUseCase {} + +/// Defines every update operation in CRUD. +mixin UpdateOperation on AsyncUseCase {} + +/// Defines every delete operation in CRUD. +mixin DeleteOperation on AsyncUseCase {} diff --git a/packages/wyatt_crud_bloc/lib/src/data/data_sources/local/crud_in_memory_data_source_impl.dart b/packages/wyatt_crud_bloc/lib/src/data/data_sources/local/crud_in_memory_data_source_impl.dart index bb892251..7c2f706b 100644 --- a/packages/wyatt_crud_bloc/lib/src/data/data_sources/local/crud_in_memory_data_source_impl.dart +++ b/packages/wyatt_crud_bloc/lib/src/data/data_sources/local/crud_in_memory_data_source_impl.dart @@ -17,13 +17,17 @@ import 'dart:async'; import 'package:wyatt_crud_bloc/src/core/enums/where_query_type.dart'; -import 'package:wyatt_crud_bloc/src/core/extensions/num_extension.dart'; -import 'package:wyatt_crud_bloc/src/domain/data_sources/crud_data_source.dart'; +import 'package:wyatt_crud_bloc/src/domain/data_sources/data_sources.dart'; import 'package:wyatt_crud_bloc/src/domain/entities/object_model.dart'; import 'package:wyatt_crud_bloc/src/domain/entities/query.dart'; +import 'package:wyatt_type_utils/wyatt_type_utils.dart'; +/// {@template crud_in_memory_data_source_impl} +/// A [CrudDataSource] that stores data in memory. +/// {@endtemplate} class CrudInMemoryDataSourceImpl extends CrudDataSource { + /// {@macro crud_in_memory_data_source_impl} CrudInMemoryDataSourceImpl({required this.toMap, Map? data}) : _data = data ?? {}; final Map _data; diff --git a/packages/wyatt_crud_bloc/lib/src/data/data_sources/remote/crud_firestore_data_source_impl.dart b/packages/wyatt_crud_bloc/lib/src/data/data_sources/remote/crud_firestore_data_source_impl.dart index e70ecc9c..2915f2e6 100644 --- a/packages/wyatt_crud_bloc/lib/src/data/data_sources/remote/crud_firestore_data_source_impl.dart +++ b/packages/wyatt_crud_bloc/lib/src/data/data_sources/remote/crud_firestore_data_source_impl.dart @@ -20,15 +20,23 @@ import 'package:wyatt_crud_bloc/src/domain/data_sources/crud_data_source.dart'; import 'package:wyatt_crud_bloc/src/domain/entities/object_model.dart'; import 'package:wyatt_crud_bloc/src/domain/entities/query.dart'; +/// {@template crud_firestore_data_source_impl} +/// A concrete implementation of [CrudDataSource] that uses +/// [FirebaseFirestore] as the data source. +/// {@endtemplate} class CrudFirestoreDataSourceImpl extends CrudDataSource { + /// {@macro crud_firestore_data_source_impl} CrudFirestoreDataSourceImpl( String collection, { + /// The function that converts a [DocumentSnapshot] to a [Model]. required Model Function( DocumentSnapshot>, SnapshotOptions?, ) fromFirestore, + + /// The function that converts a [Model] to a [Map]. required Map Function(Model, SetOptions?) toFirestore, FirebaseFirestore? firestore, }) : _firestore = firestore ?? FirebaseFirestore.instance, diff --git a/packages/wyatt_crud_bloc/lib/src/data/repositories/crud_repository_impl.dart b/packages/wyatt_crud_bloc/lib/src/data/repositories/crud_repository_impl.dart index f26fdc1d..7f068be2 100644 --- a/packages/wyatt_crud_bloc/lib/src/data/repositories/crud_repository_impl.dart +++ b/packages/wyatt_crud_bloc/lib/src/data/repositories/crud_repository_impl.dart @@ -21,9 +21,13 @@ import 'package:wyatt_crud_bloc/src/domain/entities/query.dart'; import 'package:wyatt_crud_bloc/src/domain/repositories/crud_repository.dart'; import 'package:wyatt_type_utils/wyatt_type_utils.dart'; +/// {@template crud_repository_impl} +/// A repository that implements the [CrudRepository] interface. +/// {@endtemplate} class CrudRepositoryImpl extends CrudRepository { - CrudRepositoryImpl({ + /// {@macro crud_repository_impl} + const CrudRepositoryImpl({ required CrudDataSource crudDataSource, }) : _crudDataSource = crudDataSource; final CrudDataSource _crudDataSource; @@ -99,6 +103,6 @@ class CrudRepositoryImpl if (lst.isNotNull) { return Ok, AppException>(lst); } - return Err, AppException>(ServerException()); + return Err, AppException>(const ServerException()); }); } diff --git a/packages/wyatt_crud_bloc/lib/src/domain/data_sources/crud_data_source.dart b/packages/wyatt_crud_bloc/lib/src/domain/data_sources/crud_data_source.dart index 95defb4c..b6d0ba30 100644 --- a/packages/wyatt_crud_bloc/lib/src/domain/data_sources/crud_data_source.dart +++ b/packages/wyatt_crud_bloc/lib/src/domain/data_sources/crud_data_source.dart @@ -17,27 +17,42 @@ import 'package:wyatt_architecture/wyatt_architecture.dart'; import 'package:wyatt_crud_bloc/src/domain/entities/query.dart'; +/// {@template crud_data_source} +/// A [BaseDataSource] that provides SCRUD operations. +/// {@endtemplate} abstract class CrudDataSource extends BaseDataSource { + /// {@macro crud_data_source} + const CrudDataSource(); + + /// Creates a new [Model] object. Future create(Model object, {String? id}); + /// Gets a [Model] object by its [id]. Future get(String id); + /// Gets all [Model] objects. Future> getAll(); + /// Updates a [Model] object by its [id]. Future update( String id, { Model? object, Map? raw, }); + /// Updates all [Model] objects. Future updateAll(Map? data); + /// Deletes a [Model] object by its [id]. Future delete(String id); + /// Deletes all [Model] objects. Future deleteAll(); + /// Queries [Model] objects by [conditions]. Future> query(List conditions); + /// Streams [Model] objects by [conditions]. Stream> stream({ String? id, List? conditions, diff --git a/packages/wyatt_crud_bloc/lib/src/domain/entities/object_model.dart b/packages/wyatt_crud_bloc/lib/src/domain/entities/object_model.dart index 2b419e41..10dc5a25 100644 --- a/packages/wyatt_crud_bloc/lib/src/domain/entities/object_model.dart +++ b/packages/wyatt_crud_bloc/lib/src/domain/entities/object_model.dart @@ -16,6 +16,13 @@ import 'package:wyatt_architecture/wyatt_architecture.dart'; +/// {@template object_model} +/// An abstract class that represents an object model. +/// {@endtemplate} abstract class ObjectModel extends Entity { + /// {@macro object_model} + const ObjectModel(); + + /// The id of the object model. String? get id; } diff --git a/packages/wyatt_crud_bloc/lib/src/domain/entities/query.dart b/packages/wyatt_crud_bloc/lib/src/domain/entities/query.dart index a414f3ff..5fe8908f 100644 --- a/packages/wyatt_crud_bloc/lib/src/domain/entities/query.dart +++ b/packages/wyatt_crud_bloc/lib/src/domain/entities/query.dart @@ -17,27 +17,59 @@ import 'package:wyatt_architecture/wyatt_architecture.dart'; import 'package:wyatt_crud_bloc/src/core/enums/where_query_type.dart'; -// ignore: one_member_abstracts -abstract class QueryParser { - Q parser(QueryInterface condition, Q query); +// // ignore: one_member_abstracts +// abstract class QueryParser { +// Q parser(QueryInterface condition, Q query); +// } + +typedef QueryParser = Q Function(QueryInterface condition, Q query); + +/// {@template query} +/// An abstract class that represents a query. +/// {@endtemplate} +abstract class QueryInterface extends Entity { + /// {@macro query} + const QueryInterface(); } -abstract class QueryInterface extends Entity {} - +/// {@template where_query} +/// Represents a where query. +/// {@endtemplate} class WhereQuery extends QueryInterface { - WhereQuery(this.type, this.field, this.value); + /// {@macro where_query} + const WhereQuery(this.type, this.field, this.value); + + /// The type of the where query. final WhereQueryType type; + + /// The field of the where query. final String field; + + /// The value of the where query. final Value value; } +/// {@template limit_query} +/// Represents a limit query. +/// {@endtemplate} class LimitQuery extends QueryInterface { - LimitQuery(this.limit); + /// {@macro limit_query} + const LimitQuery(this.limit); + + /// The limit of the limit query. final int limit; } +/// {@template offset_query} +/// Represents an offset query. +/// {@endtemplate} class OrderByQuery extends QueryInterface { - OrderByQuery(this.field, {this.ascending = true}); + /// {@macro offset_query} + const OrderByQuery(this.field, {this.ascending = true}); + + /// The field of the order by query. final String field; + + /// The ascending of the order by query. final bool ascending; } diff --git a/packages/wyatt_crud_bloc/lib/src/domain/repositories/crud_repository.dart b/packages/wyatt_crud_bloc/lib/src/domain/repositories/crud_repository.dart index f0313c44..95b52190 100644 --- a/packages/wyatt_crud_bloc/lib/src/domain/repositories/crud_repository.dart +++ b/packages/wyatt_crud_bloc/lib/src/domain/repositories/crud_repository.dart @@ -18,20 +18,43 @@ import 'package:wyatt_architecture/wyatt_architecture.dart'; import 'package:wyatt_crud_bloc/src/domain/entities/object_model.dart'; import 'package:wyatt_crud_bloc/src/domain/entities/query.dart'; +/// {@template crud_repository} +/// An abstract class that represents a SCRUD repository. +/// {@endtemplate} abstract class CrudRepository extends BaseRepository { + /// {@macro crud_repository} + const CrudRepository(); + + /// Creates a new object. FutureOrResult create(Model object, {String? id}); + + /// Gets an object by its [id]. FutureOrResult get(String id); + + /// Gets all objects. FutureOrResult> getAll(); + + /// Updates an object by its [id]. FutureOrResult update( String id, { Model? object, Map? raw, }); + + /// Updates all objects. FutureOrResult updateAll(Map raw); + + /// Deletes an object by its [id]. FutureOrResult delete(String id); + + /// Deletes all objects. FutureOrResult deleteAll(); + + /// Queries objects by [conditions]. FutureOrResult> query(List conditions); + + /// Streams objects by [conditions]. StreamResult> stream({ String? id, List? conditions, diff --git a/packages/wyatt_crud_bloc/lib/src/domain/usecases/create.dart b/packages/wyatt_crud_bloc/lib/src/domain/usecases/create.dart index 8a6940b5..ff88a046 100644 --- a/packages/wyatt_crud_bloc/lib/src/domain/usecases/create.dart +++ b/packages/wyatt_crud_bloc/lib/src/domain/usecases/create.dart @@ -1,4 +1,3 @@ -// ignore_for_file: public_member_api_docs, sort_constructors_first // Copyright (C) 2022 WYATT GROUP // Please see the AUTHORS file for details. // @@ -18,13 +17,19 @@ import 'dart:async'; import 'package:wyatt_architecture/wyatt_architecture.dart'; +import 'package:wyatt_crud_bloc/src/core/mixins/operation.dart'; import 'package:wyatt_crud_bloc/src/domain/entities/object_model.dart'; import 'package:wyatt_crud_bloc/src/domain/repositories/crud_repository.dart'; -class Create extends AsyncUseCase { - final CrudRepository _crudRepository; +/// {@template create} +/// A use case that creates an object model. +/// {@endtemplate} +class Create extends AsyncUseCase + with CreateOperation { + /// {@macro create} + const Create(this._crudRepository); - Create(this._crudRepository); + final CrudRepository _crudRepository; @override FutureOr onStart(Model? params) { diff --git a/packages/wyatt_crud_bloc/lib/src/domain/usecases/delete.dart b/packages/wyatt_crud_bloc/lib/src/domain/usecases/delete.dart index cdebd878..d8ffb17d 100644 --- a/packages/wyatt_crud_bloc/lib/src/domain/usecases/delete.dart +++ b/packages/wyatt_crud_bloc/lib/src/domain/usecases/delete.dart @@ -17,17 +17,24 @@ import 'dart:async'; import 'package:wyatt_architecture/wyatt_architecture.dart'; +import 'package:wyatt_crud_bloc/src/core/mixins/operation.dart'; import 'package:wyatt_crud_bloc/src/domain/entities/object_model.dart'; import 'package:wyatt_crud_bloc/src/domain/repositories/crud_repository.dart'; -class Delete extends AsyncUseCase { - Delete(this._crudRepository); +/// {@template delete} +/// A use case that deletes an object model. +/// {@endtemplate} +class Delete extends AsyncUseCase + with DeleteOperation { + /// {@macro delete} + const Delete(this._crudRepository); + final CrudRepository _crudRepository; @override FutureOr onStart(String? params) { if (params == null) { - throw ClientException('Id cannot be null.'); + throw const ClientException('Id cannot be null.'); } } diff --git a/packages/wyatt_crud_bloc/lib/src/domain/usecases/delete_all.dart b/packages/wyatt_crud_bloc/lib/src/domain/usecases/delete_all.dart index a1a36275..ae1935d7 100644 --- a/packages/wyatt_crud_bloc/lib/src/domain/usecases/delete_all.dart +++ b/packages/wyatt_crud_bloc/lib/src/domain/usecases/delete_all.dart @@ -15,11 +15,18 @@ // along with this program. If not, see . import 'package:wyatt_architecture/wyatt_architecture.dart'; +import 'package:wyatt_crud_bloc/src/core/mixins/operation.dart'; import 'package:wyatt_crud_bloc/src/domain/entities/object_model.dart'; import 'package:wyatt_crud_bloc/src/domain/repositories/crud_repository.dart'; -class DeleteAll extends AsyncUseCase { - DeleteAll(this._crudRepository); +/// {@template delete_all} +/// A use case that deletes all the object models. +/// {@endtemplate} +class DeleteAll extends AsyncUseCase + with DeleteOperation { + /// {@macro delete_all} + const DeleteAll(this._crudRepository); + final CrudRepository _crudRepository; @override diff --git a/packages/wyatt_crud_bloc/lib/src/domain/usecases/get.dart b/packages/wyatt_crud_bloc/lib/src/domain/usecases/get.dart index 40d6719c..08850936 100644 --- a/packages/wyatt_crud_bloc/lib/src/domain/usecases/get.dart +++ b/packages/wyatt_crud_bloc/lib/src/domain/usecases/get.dart @@ -17,17 +17,24 @@ import 'dart:async'; import 'package:wyatt_architecture/wyatt_architecture.dart'; +import 'package:wyatt_crud_bloc/src/core/mixins/operation.dart'; import 'package:wyatt_crud_bloc/src/domain/entities/object_model.dart'; import 'package:wyatt_crud_bloc/src/domain/repositories/crud_repository.dart'; -class Get extends AsyncUseCase { +/// {@template get} +/// A use case that gets an object model. +/// {@endtemplate} +class Get extends AsyncUseCase + with ReadOperation { + /// {@macro get} Get(this._crudRepository); + final CrudRepository _crudRepository; @override FutureOr onStart(String? params) { if (params == null) { - throw ClientException('Id cannot be null.'); + throw const ClientException('Id cannot be null.'); } } diff --git a/packages/wyatt_crud_bloc/lib/src/domain/usecases/get_all.dart b/packages/wyatt_crud_bloc/lib/src/domain/usecases/get_all.dart index 6fde76b7..63379212 100644 --- a/packages/wyatt_crud_bloc/lib/src/domain/usecases/get_all.dart +++ b/packages/wyatt_crud_bloc/lib/src/domain/usecases/get_all.dart @@ -15,12 +15,18 @@ // along with this program. If not, see . import 'package:wyatt_architecture/wyatt_architecture.dart'; +import 'package:wyatt_crud_bloc/src/core/mixins/operation.dart'; import 'package:wyatt_crud_bloc/src/domain/entities/object_model.dart'; import 'package:wyatt_crud_bloc/src/domain/repositories/crud_repository.dart'; -class GetAll - extends AsyncUseCase> { - GetAll(this._crudRepository); +/// {@template get_all} +/// A use case that gets all the object models. +/// {@endtemplate} +class GetAll extends AsyncUseCase> + with ReadOperation> { + /// {@macro get_all} + const GetAll(this._crudRepository); + final CrudRepository _crudRepository; @override diff --git a/packages/wyatt_crud_bloc/lib/src/domain/usecases/params/stream_parameters.dart b/packages/wyatt_crud_bloc/lib/src/domain/usecases/params/stream_parameters.dart index ed7768d4..0b2d178b 100644 --- a/packages/wyatt_crud_bloc/lib/src/domain/usecases/params/stream_parameters.dart +++ b/packages/wyatt_crud_bloc/lib/src/domain/usecases/params/stream_parameters.dart @@ -1,4 +1,3 @@ -// ignore_for_file: public_member_api_docs, sort_constructors_first // Copyright (C) 2022 WYATT GROUP // Please see the AUTHORS file for details. // @@ -17,12 +16,19 @@ import 'package:wyatt_crud_bloc/src/domain/entities/query.dart'; +/// {@template stream_parameters} +/// Represents the parameters for a query stream +/// {@endtemplate} class StreamParameters { - final String? id; - final List? conditions; - - StreamParameters({ + /// {@macro stream_parameters} + const StreamParameters({ this.id, this.conditions, }); + + /// The id of the object model. + final String? id; + + /// The conditions of the query. + final List? conditions; } diff --git a/packages/wyatt_crud_bloc/lib/src/domain/usecases/params/update_parameters.dart b/packages/wyatt_crud_bloc/lib/src/domain/usecases/params/update_parameters.dart index cbe4cd2b..c44ab784 100644 --- a/packages/wyatt_crud_bloc/lib/src/domain/usecases/params/update_parameters.dart +++ b/packages/wyatt_crud_bloc/lib/src/domain/usecases/params/update_parameters.dart @@ -1,4 +1,3 @@ -// ignore_for_file: public_member_api_docs, sort_constructors_first // Copyright (C) 2022 WYATT GROUP // Please see the AUTHORS file for details. // @@ -15,14 +14,23 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . +/// {@template update_parameters} +/// Represents the parameters for an update use case +/// {@endtemplate} class UpdateParameters { - final String id; - final Model? object; - final Map? raw; - - UpdateParameters({ + /// {@macro update_parameters} + const UpdateParameters({ required this.id, this.object, this.raw, }); + + /// The id of the object model. + final String id; + + /// The object model. + final Model? object; + + /// The raw data. + final Map? raw; } diff --git a/packages/wyatt_crud_bloc/lib/src/domain/usecases/query.dart b/packages/wyatt_crud_bloc/lib/src/domain/usecases/query.dart index 2070b015..4869fa0d 100644 --- a/packages/wyatt_crud_bloc/lib/src/domain/usecases/query.dart +++ b/packages/wyatt_crud_bloc/lib/src/domain/usecases/query.dart @@ -17,19 +17,26 @@ import 'dart:async'; import 'package:wyatt_architecture/wyatt_architecture.dart'; +import 'package:wyatt_crud_bloc/src/core/mixins/operation.dart'; import 'package:wyatt_crud_bloc/src/domain/entities/object_model.dart'; import 'package:wyatt_crud_bloc/src/domain/entities/query.dart'; import 'package:wyatt_crud_bloc/src/domain/repositories/crud_repository.dart'; +/// {@template query} +/// A use case that queries the object models. +/// {@endtemplate} class Query - extends AsyncUseCase, List> { - Query(this._crudRepository); + extends AsyncUseCase, List> + with ReadOperation, List> { + /// {@macro query} + const Query(this._crudRepository); + final CrudRepository _crudRepository; @override FutureOr onStart(List? params) { if (params == null) { - throw ClientException('List of conditions cannot be null.'); + throw const ClientException('List of conditions cannot be null.'); } } diff --git a/packages/wyatt_crud_bloc/lib/src/domain/usecases/stream_query.dart b/packages/wyatt_crud_bloc/lib/src/domain/usecases/stream_query.dart deleted file mode 100644 index 35e42b9e..00000000 --- a/packages/wyatt_crud_bloc/lib/src/domain/usecases/stream_query.dart +++ /dev/null @@ -1,44 +0,0 @@ -// Copyright (C) 2022 WYATT GROUP -// Please see the AUTHORS file for details. -// -// This program is free software: you can redistribute it and/or modify -// it under the terms of the GNU General Public License as published by -// the Free Software Foundation, either version 3 of the License, or -// any later version. -// -// This program is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with this program. If not, see . - -// class Stream extends UseCase> { -// final CrudRepository _crudRepository; - -// Stream(this._crudRepository); - -// @override -// StreamResult> call(StreamParameters params) => -// _crudRepository.stream(id: params.id, conditions: params.conditions); -// } - -// class StreamQuery -// extends StreamUseCase> { -// final CrudRepository _crudRepository; - -// StreamQuery(this._crudRepository); - -// @override -// FutureOr onStart(StreamParameters? params) { -// if(params == null){ -// throw ClientException('Stream parameters cannot be null.'); -// } -// } - -// @override -// FutureOrResult>> call(StreamParameters? params) => -// _crudRepository.stream(); -// } diff --git a/packages/wyatt_crud_bloc/lib/src/domain/usecases/update.dart b/packages/wyatt_crud_bloc/lib/src/domain/usecases/update.dart index 70c82b73..237e3e9d 100644 --- a/packages/wyatt_crud_bloc/lib/src/domain/usecases/update.dart +++ b/packages/wyatt_crud_bloc/lib/src/domain/usecases/update.dart @@ -17,19 +17,26 @@ import 'dart:async'; import 'package:wyatt_architecture/wyatt_architecture.dart'; +import 'package:wyatt_crud_bloc/src/core/mixins/operation.dart'; import 'package:wyatt_crud_bloc/src/domain/entities/object_model.dart'; import 'package:wyatt_crud_bloc/src/domain/repositories/crud_repository.dart'; import 'package:wyatt_crud_bloc/src/domain/usecases/params/update_parameters.dart'; +/// {@template update} +/// A use case that updates an object model. +/// {@endtemplate} class Update - extends AsyncUseCase, void> { - Update(this._crudRepository); + extends AsyncUseCase, void> + with UpdateOperation> { + /// {@macro update} + const Update(this._crudRepository); + final CrudRepository _crudRepository; @override FutureOr onStart(UpdateParameters? params) { if (params == null) { - throw ClientException('Update parameters cannot be null.'); + throw const ClientException('Update parameters cannot be null.'); } } diff --git a/packages/wyatt_crud_bloc/lib/src/domain/usecases/update_all.dart b/packages/wyatt_crud_bloc/lib/src/domain/usecases/update_all.dart index 60a81957..22c32181 100644 --- a/packages/wyatt_crud_bloc/lib/src/domain/usecases/update_all.dart +++ b/packages/wyatt_crud_bloc/lib/src/domain/usecases/update_all.dart @@ -17,18 +17,25 @@ import 'dart:async'; import 'package:wyatt_architecture/wyatt_architecture.dart'; +import 'package:wyatt_crud_bloc/src/core/mixins/operation.dart'; import 'package:wyatt_crud_bloc/src/domain/entities/object_model.dart'; import 'package:wyatt_crud_bloc/src/domain/repositories/crud_repository.dart'; +/// {@template update_all} +/// A use case that updates all the object models. +/// {@endtemplate} class UpdateAll - extends AsyncUseCase, void> { - UpdateAll(this._crudRepository); + extends AsyncUseCase, void> + with UpdateOperation> { + /// {@macro update_all} + const UpdateAll(this._crudRepository); + final CrudRepository _crudRepository; @override FutureOr onStart(Map? params) { if (params == null) { - throw ClientException('Data cannot be null.'); + throw const ClientException('Data cannot be null.'); } } diff --git a/packages/wyatt_crud_bloc/lib/src/domain/usecases/usecases.dart b/packages/wyatt_crud_bloc/lib/src/domain/usecases/usecases.dart index b53d1702..4a8d8467 100644 --- a/packages/wyatt_crud_bloc/lib/src/domain/usecases/usecases.dart +++ b/packages/wyatt_crud_bloc/lib/src/domain/usecases/usecases.dart @@ -21,6 +21,5 @@ export 'get.dart'; export 'get_all.dart'; export 'params/params.dart'; export 'query.dart'; -export 'stream_query.dart'; export 'update.dart'; export 'update_all.dart'; diff --git a/packages/wyatt_crud_bloc/lib/src/features/crud/blocs/crud_advanced_cubit.dart b/packages/wyatt_crud_bloc/lib/src/features/crud/blocs/crud_advanced_cubit.dart new file mode 100644 index 00000000..d41e35d9 --- /dev/null +++ b/packages/wyatt_crud_bloc/lib/src/features/crud/blocs/crud_advanced_cubit.dart @@ -0,0 +1,305 @@ +// Copyright (C) 2023 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +import 'dart:async'; + +import 'package:wyatt_crud_bloc/src/core/enums/where_query_type.dart'; +import 'package:wyatt_crud_bloc/src/domain/entities/object_model.dart'; +import 'package:wyatt_crud_bloc/src/domain/entities/query.dart'; +import 'package:wyatt_crud_bloc/src/domain/usecases/create.dart'; +import 'package:wyatt_crud_bloc/src/domain/usecases/delete.dart'; +import 'package:wyatt_crud_bloc/src/domain/usecases/delete_all.dart'; +import 'package:wyatt_crud_bloc/src/domain/usecases/get.dart'; +import 'package:wyatt_crud_bloc/src/domain/usecases/get_all.dart'; +import 'package:wyatt_crud_bloc/src/domain/usecases/params/update_parameters.dart'; +import 'package:wyatt_crud_bloc/src/domain/usecases/query.dart'; +import 'package:wyatt_crud_bloc/src/domain/usecases/update.dart'; +import 'package:wyatt_crud_bloc/src/domain/usecases/update_all.dart'; +import 'package:wyatt_crud_bloc/src/features/crud/blocs/crud_base_cubit/crud_base_cubit.dart'; + +/// {@template crud_cubit_advanced} +/// Cubit that handles CRUD operations with more granularity. +/// {@endtemplate} +abstract class CrudAdvancedCubit + extends CrudBaseCubit { + /// {@macro crud_cubit} + CrudAdvancedCubit() : super(); + + Create? get crudCreate; + DeleteAll? get crudDeleteAll; + Delete? get crudDelete; + GetAll? get crudGetAll; + Get? get crudGet; + Query? get crudQuery; + UpdateAll? get crudUpdateAll; + Update? get crudUpdate; + + FutureOr create(Model model) async { + final crud = crudCreate; + if (crud == null) { + return; + } + + final stateCopy = state; + emit(const CrudLoading()); + final result = await crud.call(model); + emit( + result.fold( + (_) { + if (stateCopy is CrudLoaded) { + if (stateCopy.data == null) { + return CrudLoaded(model); + } + if (stateCopy.data!.id == model.id) { + return CrudLoaded(model); + } + + return stateCopy; + } + if (stateCopy is CrudListLoaded) { + if (stateCopy.data.isEmpty) { + return CrudListLoaded([model]); + } + final List lst = stateCopy.data.toList()..add(model); + + return CrudListLoaded(lst); + } + + return const CrudOkReturn(); + }, + (error) => CrudError(error.toString()), + ), + ); + } + + FutureOr delete(String id) async { + final crud = crudDelete; + if (crud == null) { + return; + } + + final stateCopy = state; + emit(const CrudLoading()); + final result = await crud.call(id); + emit( + result.fold( + (_) { + if (stateCopy is CrudLoaded) { + if (stateCopy.data?.id == id) { + return CrudLoaded(null); + } + + return stateCopy; + } + if (stateCopy is CrudListLoaded) { + return CrudListLoaded( + stateCopy.data.where((element) => element?.id != id).toList(), + ); + } + + return const CrudOkReturn(); + }, + (error) => CrudError(error.toString()), + ), + ); + } + + FutureOr deleteAll() async { + final crud = crudDeleteAll; + if (crud == null) { + return; + } + final stateCopy = state; + emit(const CrudLoading()); + final result = await crud.call(null); + emit( + result.fold( + (_) { + if (stateCopy is CrudLoaded) { + return CrudLoaded(null); + } + if (stateCopy is CrudListLoaded) { + return CrudListLoaded(const []); + } + + return const CrudOkReturn(); + }, + (error) => CrudError(error.toString()), + ), + ); + } + + FutureOr get(String id) async { + final crud = crudGet; + if (crud == null) { + return; + } + emit(const CrudLoading()); + final result = await crud.call(id); + emit( + result.fold( + CrudLoaded.new, + (error) => CrudError(error.toString()), + ), + ); + } + + FutureOr getAll() async { + final crud = crudGetAll; + if (crud == null) { + return; + } + emit(const CrudLoading()); + final result = await crud.call(null); + emit( + result.fold( + CrudListLoaded.new, + (error) => CrudError(error.toString()), + ), + ); + } + + FutureOr query(List conditions) async { + final crud = crudQuery; + if (crud == null) { + return; + } + + emit(const CrudLoading()); + final result = await crud.call(conditions); + emit( + result.fold( + CrudListLoaded.new, + (error) => CrudError(error.toString()), + ), + ); + } + + FutureOr update(UpdateParameters param) async { + final crud = crudUpdate; + if (crud == null) { + return; + } + + final stateCopy = state; + emit(const CrudLoading()); + final result = await crud.call(param); + emit( + await result.foldAsync( + (_) async { + if (stateCopy is CrudLoaded) { + if (stateCopy.data?.id == param.id) { + // Same object, need to update actual stateCopy + final crudGet = this.crudGet; + if (crudGet == null) { + // No read operation, can't update stateCopy. + return stateCopy; + } + final newVersion = await crudGet.call(param.id); + if (newVersion.isOk) { + return CrudLoaded(newVersion.ok); + } + } + return stateCopy; + } + if (stateCopy is CrudListLoaded) { + final bool listContains = + stateCopy.data.any((element) => element?.id == param.id); + if (listContains) { + // Loaded objects contains the modified object. + + final crudGet = this.crudGet; + if (crudGet == null) { + // No read operation, can't update stateCopy. + return stateCopy; + } + final newVersion = await crudGet.call(param.id); + if (newVersion.isOk) { + final newList = stateCopy.data + .where( + (element) => element?.id != param.id, + ) + .toList(); + return CrudListLoaded(newList + [newVersion.ok]); + } + } + return stateCopy; + } + return const CrudOkReturn(); + }, + (error) async => CrudError(error.toString()), + ), + ); + } + + FutureOr updateAll(Map param) async { + final crud = crudUpdateAll; + if (crud == null) { + return; + } + + final stateCopy = state; + emit(const CrudLoading()); + final result = await crud.call(param); + emit( + await result.foldAsync( + (_) async { + if (stateCopy is CrudLoaded) { + // Same object, need to update actual stateCopy + final crudGet = this.crudGet; + if (crudGet == null) { + // No read operation, can't update stateCopy. + return stateCopy; + } + final actualId = stateCopy.data?.id; + final newVersion = await crudGet.call(actualId ?? ''); + if (newVersion.isOk) { + return CrudLoaded(newVersion.ok); + } + return stateCopy; + } + if (stateCopy is CrudListLoaded) { + final crudQuery = this.crudQuery; + if (crudQuery == null) { + // No read operation, can't update stateCopy. + return stateCopy; + } + // Load all id to retrieve exactly same object + // (not all because previous stateCopy can be a query result) + final List ids = stateCopy.data + .map( + (e) => e?.id, + ) + .toList(); + final result = await crudQuery.call([ + WhereQuery( + WhereQueryType.whereIn, + 'id', + ids, + ) + ]); + if (result.isOk) { + return CrudListLoaded(result.ok ?? []); + } + return stateCopy; + } + return const CrudOkReturn(); + }, + (error) async => CrudError(error.toString()), + ), + ); + } +} diff --git a/packages/wyatt_crud_bloc/lib/src/core/extensions/num_extension.dart b/packages/wyatt_crud_bloc/lib/src/features/crud/blocs/crud_base_cubit/crud_base_cubit.dart similarity index 51% rename from packages/wyatt_crud_bloc/lib/src/core/extensions/num_extension.dart rename to packages/wyatt_crud_bloc/lib/src/features/crud/blocs/crud_base_cubit/crud_base_cubit.dart index abe45b91..c694b880 100644 --- a/packages/wyatt_crud_bloc/lib/src/core/extensions/num_extension.dart +++ b/packages/wyatt_crud_bloc/lib/src/features/crud/blocs/crud_base_cubit/crud_base_cubit.dart @@ -14,38 +14,15 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . -extension NumExtension on num? { - bool operator <(num? other) { - if (this == null || other == null) { - return false; - } - return this < other; - } +import 'package:equatable/equatable.dart'; +import 'package:flutter_bloc/flutter_bloc.dart'; - bool operator >(num? other) { - if (this == null || other == null) { - return false; - } - return this > other; - } +part 'crud_state.dart'; - bool operator <=(num? other) { - if (this == null && other == null) { - return true; - } - if (this == null || other == null) { - return false; - } - return this <= other; - } - - bool operator >=(num? other) { - if (this == null && other == null) { - return true; - } - if (this == null || other == null) { - return false; - } - return this >= other; - } +/// {@template crud_base_cubit} +/// A base [Cubit] that handles SCRUD operations. +/// {@endtemplate} +abstract class CrudBaseCubit extends Cubit { + /// {@macro crud_base_cubit} + CrudBaseCubit() : super(const CrudInitial()); } diff --git a/packages/wyatt_crud_bloc/lib/src/features/crud/cubit/crud_state.dart b/packages/wyatt_crud_bloc/lib/src/features/crud/blocs/crud_base_cubit/crud_state.dart similarity index 58% rename from packages/wyatt_crud_bloc/lib/src/features/crud/cubit/crud_state.dart rename to packages/wyatt_crud_bloc/lib/src/features/crud/blocs/crud_base_cubit/crud_state.dart index f8ab26e2..64f2479a 100644 --- a/packages/wyatt_crud_bloc/lib/src/features/crud/cubit/crud_state.dart +++ b/packages/wyatt_crud_bloc/lib/src/features/crud/blocs/crud_base_cubit/crud_state.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify @@ -14,7 +14,7 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . -part of 'crud_cubit.dart'; +part of 'crud_base_cubit.dart'; abstract class CrudState extends Equatable { const CrudState(); @@ -23,18 +23,17 @@ abstract class CrudState extends Equatable { List get props => []; } -class CrudInitial extends CrudState {} - -class CrudLoading extends CrudState {} - -abstract class CrudSuccess extends CrudState { - const CrudSuccess(); +/// Initial state of the CrudBaseCubit. +class CrudInitial extends CrudState { + const CrudInitial(); } -class CrudOkReturn extends CrudState { - const CrudOkReturn(); +/// Loading state of the CrudBaseCubit. +class CrudLoading extends CrudState { + const CrudLoading(); } +/// Error state of the CrudBaseCubit. class CrudError extends CrudState { const CrudError(this.message); final String? message; @@ -43,6 +42,24 @@ class CrudError extends CrudState { List get props => [message]; } +/// Success state of the CrudBaseCubit. +/// This state is used to indicate that the operation was successful. +/// Can be one or list of objects. +abstract class CrudSuccess extends CrudState { + const CrudSuccess(); +} + +/// Success state of the CrudBaseCubit. +/// This state is used to indicate that the operation was successful. +/// Contains no objects. +/// Used for create, update, delete operations. +class CrudOkReturn extends CrudSuccess { + const CrudOkReturn(); +} + +/// Loaded state of the CrudBaseCubit. +/// This state is used to indicate that the operation was successful. +/// Contains one object. class CrudLoaded extends CrudSuccess { const CrudLoaded(this.data); final T? data; @@ -51,6 +68,9 @@ class CrudLoaded extends CrudSuccess { List get props => [data]; } +/// Loaded state of the CrudBaseCubit. +/// This state is used to indicate that the operation was successful. +/// Contains list of objects. class CrudListLoaded extends CrudSuccess { const CrudListLoaded(this.data); final List data; diff --git a/packages/wyatt_crud_bloc/lib/src/features/crud/blocs/crud_cubit.dart b/packages/wyatt_crud_bloc/lib/src/features/crud/blocs/crud_cubit.dart new file mode 100644 index 00000000..5d18975f --- /dev/null +++ b/packages/wyatt_crud_bloc/lib/src/features/crud/blocs/crud_cubit.dart @@ -0,0 +1,369 @@ +// Copyright (C) 2023 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +import 'dart:async'; + +import 'package:wyatt_crud_bloc/src/core/enums/where_query_type.dart'; +import 'package:wyatt_crud_bloc/src/core/mixins/operation.dart'; +import 'package:wyatt_crud_bloc/src/domain/entities/object_model.dart'; +import 'package:wyatt_crud_bloc/src/domain/entities/query.dart'; +import 'package:wyatt_crud_bloc/src/domain/usecases/create.dart'; +import 'package:wyatt_crud_bloc/src/domain/usecases/delete.dart'; +import 'package:wyatt_crud_bloc/src/domain/usecases/delete_all.dart'; +import 'package:wyatt_crud_bloc/src/domain/usecases/get.dart'; +import 'package:wyatt_crud_bloc/src/domain/usecases/get_all.dart'; +import 'package:wyatt_crud_bloc/src/domain/usecases/params/update_parameters.dart'; +import 'package:wyatt_crud_bloc/src/domain/usecases/query.dart'; +import 'package:wyatt_crud_bloc/src/domain/usecases/update.dart'; +import 'package:wyatt_crud_bloc/src/domain/usecases/update_all.dart'; +import 'package:wyatt_crud_bloc/src/features/crud/blocs/crud_base_cubit/crud_base_cubit.dart'; + +/// {@template crud_cubit} +/// Cubit that handles CRUD operations. +/// {@endtemplate} +abstract class CrudCubit extends CrudBaseCubit { + /// {@macro crud_cubit} + CrudCubit() : super(); + + /// Create operation. + /// Can be create. + CreateOperation? get createOperation; + + /// Read operation. + /// Can be get, getAll, query. + ReadOperation? get readOperation; + + /// Update operation. + /// Can be update, updateAll. + UpdateOperation? get updateOperation; + + /// Delete operation. + /// Can be delete or deleteAll. + DeleteOperation? get deleteOperation; + + Expected? _checkOperation(dynamic operation) { + if (operation == null) { + return null; + } + if (operation is! Expected) { + return null; + } + return operation; + } + + FutureOr create(Model model) async { + if (_checkOperation>(createOperation) != null) { + return _create(model); + } + } + + FutureOr read({String? id, List? conditions}) async { + if (_checkOperation>(readOperation) != null && id != null) { + return _get(id); + } + if (_checkOperation>(readOperation) != null) { + return _getAll(); + } + if (_checkOperation>(readOperation) != null && + conditions != null) { + return _query(conditions); + } + if (_checkOperation>(readOperation) != null && + conditions == null) { + return _getAll(); + } + } + + FutureOr update( + UpdateParameters? single, + Map? all, + ) async { + if (_checkOperation>(updateOperation) != null && + single != null) { + return _update(single); + } + + if (_checkOperation>(updateOperation) != null && + all != null) { + return _updateAll(all); + } + } + + FutureOr delete({String? id}) async { + if (_checkOperation>(deleteOperation) != null && id != null) { + return _delete(id); + } + if (_checkOperation>(deleteOperation) != null) { + return _deleteAll(); + } + } + + FutureOr _create(Model model) async { + final crud = _checkOperation>(createOperation); + if (crud == null) { + return; + } + + final stateCopy = state; + emit(const CrudLoading()); + final result = await crud.call(model); + emit( + result.fold( + (_) { + if (stateCopy is CrudLoaded) { + if (stateCopy.data == null) { + return CrudLoaded(model); + } + if (stateCopy.data!.id == model.id) { + return CrudLoaded(model); + } + + return stateCopy; + } + if (stateCopy is CrudListLoaded) { + if (stateCopy.data.isEmpty) { + return CrudListLoaded([model]); + } + final List lst = stateCopy.data.toList()..add(model); + + return CrudListLoaded(lst); + } + + return const CrudOkReturn(); + }, + (error) => CrudError(error.toString()), + ), + ); + } + + FutureOr _delete(String id) async { + final crud = _checkOperation>(deleteOperation); + if (crud == null) { + return; + } + + final stateCopy = state; + emit(const CrudLoading()); + final result = await crud.call(id); + emit( + result.fold( + (_) { + if (stateCopy is CrudLoaded) { + if (stateCopy.data?.id == id) { + return CrudLoaded(null); + } + + return stateCopy; + } + if (stateCopy is CrudListLoaded) { + return CrudListLoaded( + stateCopy.data.where((element) => element?.id != id).toList(), + ); + } + + return const CrudOkReturn(); + }, + (error) => CrudError(error.toString()), + ), + ); + } + + FutureOr _deleteAll() async { + final crud = _checkOperation>(deleteOperation); + if (crud == null) { + return; + } + final stateCopy = state; + emit(const CrudLoading()); + final result = await crud.call(null); + emit( + result.fold( + (_) { + if (stateCopy is CrudLoaded) { + return CrudLoaded(null); + } + if (stateCopy is CrudListLoaded) { + return CrudListLoaded(const []); + } + + return const CrudOkReturn(); + }, + (error) => CrudError(error.toString()), + ), + ); + } + + FutureOr _get(String id) async { + final crud = _checkOperation>(readOperation); + if (crud == null) { + return; + } + emit(const CrudLoading()); + final result = await crud.call(id); + emit( + result.fold( + CrudLoaded.new, + (error) => CrudError(error.toString()), + ), + ); + } + + FutureOr _getAll() async { + final crud = _checkOperation>(readOperation); + if (crud == null) { + return; + } + emit(const CrudLoading()); + final result = await crud.call(null); + emit( + result.fold( + CrudListLoaded.new, + (error) => CrudError(error.toString()), + ), + ); + } + + FutureOr _query(List conditions) async { + final crud = _checkOperation>(readOperation); + if (crud == null) { + return; + } + + emit(const CrudLoading()); + final result = await crud.call(conditions); + emit( + result.fold( + CrudListLoaded.new, + (error) => CrudError(error.toString()), + ), + ); + } + + FutureOr _update(UpdateParameters param) async { + final crud = _checkOperation>(updateOperation); + if (crud == null) { + return; + } + + final stateCopy = state; + emit(const CrudLoading()); + final result = await crud.call(param); + emit( + await result.foldAsync( + (_) async { + if (stateCopy is CrudLoaded) { + if (stateCopy.data?.id == param.id) { + // Same object, need to update actual stateCopy + final crudGet = _checkOperation>(readOperation); + if (crudGet == null) { + // No read operation, can't update stateCopy. + return stateCopy; + } + final newVersion = await crudGet.call(param.id); + if (newVersion.isOk) { + return CrudLoaded(newVersion.ok); + } + } + return stateCopy; + } + if (stateCopy is CrudListLoaded) { + final bool listContains = + stateCopy.data.any((element) => element?.id == param.id); + if (listContains) { + // Loaded objects contains the modified object. + + final crudGet = _checkOperation>(readOperation); + if (crudGet == null) { + // No read operation, can't update stateCopy. + return stateCopy; + } + final newVersion = await crudGet.call(param.id); + if (newVersion.isOk) { + final newList = stateCopy.data + .where( + (element) => element?.id != param.id, + ) + .toList(); + return CrudListLoaded(newList + [newVersion.ok]); + } + } + return stateCopy; + } + return const CrudOkReturn(); + }, + (error) async => CrudError(error.toString()), + ), + ); + } + + FutureOr _updateAll(Map param) async { + final crud = _checkOperation>(updateOperation); + if (crud == null) { + return; + } + + final stateCopy = state; + emit(const CrudLoading()); + final result = await crud.call(param); + emit( + await result.foldAsync( + (_) async { + if (stateCopy is CrudLoaded) { + // Same object, need to update actual stateCopy + final crudGet = _checkOperation>(readOperation); + if (crudGet == null) { + // No read operation, can't update stateCopy. + return stateCopy; + } + final actualId = stateCopy.data?.id; + final newVersion = await crudGet.call(actualId ?? ''); + if (newVersion.isOk) { + return CrudLoaded(newVersion.ok); + } + return stateCopy; + } + if (stateCopy is CrudListLoaded) { + final crudQuery = _checkOperation>(readOperation); + if (crudQuery == null) { + // No read operation, can't update stateCopy. + return stateCopy; + } + // Load all id to retrieve exactly same object + // (not all because previous stateCopy can be a query result) + final List ids = stateCopy.data + .map( + (e) => e?.id, + ) + .toList(); + final result = await crudQuery.call([ + WhereQuery( + WhereQueryType.whereIn, + 'id', + ids, + ) + ]); + if (result.isOk) { + return CrudListLoaded(result.ok ?? []); + } + return stateCopy; + } + return const CrudOkReturn(); + }, + (error) async => CrudError(error.toString()), + ), + ); + } +} diff --git a/packages/wyatt_crud_bloc/lib/src/features/crud/builder/crud_builder.dart b/packages/wyatt_crud_bloc/lib/src/features/crud/builder/crud_builder.dart index 62f1faaa..d864ce7a 100644 --- a/packages/wyatt_crud_bloc/lib/src/features/crud/builder/crud_builder.dart +++ b/packages/wyatt_crud_bloc/lib/src/features/crud/builder/crud_builder.dart @@ -15,15 +15,19 @@ // along with this program. If not, see . import 'package:flutter/material.dart'; -import 'package:wyatt_crud_bloc/src/features/crud/cubit/crud_cubit.dart'; +import 'package:wyatt_crud_bloc/src/features/crud/blocs/crud_base_cubit/crud_base_cubit.dart'; +/// {@template crud_builder} +/// A widget that builds itself based on the latest snapshot of interaction +/// with a [CrudBaseCubit]. +/// +/// * I = Initial State +/// * L = Loading State +/// * S = Success State +/// * E = Error State +/// {@endtemplate} class CrudBuilder extends StatelessWidget { - /// `` - /// - /// - I: the Initial State - /// - L: the Loading State - /// - S: the Success State - /// - E: the Error State + /// {@macro crud_builder} const CrudBuilder({ required this.state, required this.builder, @@ -34,11 +38,11 @@ class CrudBuilder extends StatelessWidget { super.key, }); - /// `` + /// {@macro crud_builder} /// - /// - S: the Success State - /// - /// For CrudStates only. + /// This factory constructor is used to create a [CrudBuilder] with + /// [CrudState]s. `S` is the Success State, and it must be a subtype of + /// [CrudSuccess]. It the only type that you have to specify. static CrudBuilder typed({ required CrudState state, diff --git a/packages/wyatt_crud_bloc/lib/src/features/crud/crud.dart b/packages/wyatt_crud_bloc/lib/src/features/crud/crud.dart index cb18407c..16113197 100644 --- a/packages/wyatt_crud_bloc/lib/src/features/crud/crud.dart +++ b/packages/wyatt_crud_bloc/lib/src/features/crud/crud.dart @@ -14,5 +14,7 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . +export 'blocs/crud_advanced_cubit.dart'; +export 'blocs/crud_base_cubit/crud_base_cubit.dart'; +export 'blocs/crud_cubit.dart'; export 'builder/builder.dart'; -export 'cubit/crud_cubit.dart'; diff --git a/packages/wyatt_crud_bloc/lib/src/features/crud/cubit/crud_cubit.dart b/packages/wyatt_crud_bloc/lib/src/features/crud/cubit/crud_cubit.dart deleted file mode 100644 index dcb466aa..00000000 --- a/packages/wyatt_crud_bloc/lib/src/features/crud/cubit/crud_cubit.dart +++ /dev/null @@ -1,266 +0,0 @@ -// Copyright (C) 2022 WYATT GROUP -// Please see the AUTHORS file for details. -// -// This program is free software: you can redistribute it and/or modify -// it under the terms of the GNU General Public License as published by -// the Free Software Foundation, either version 3 of the License, or -// any later version. -// -// This program is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with this program. If not, see . - -import 'dart:async'; - -import 'package:equatable/equatable.dart'; -import 'package:flutter_bloc/flutter_bloc.dart'; -import 'package:wyatt_architecture/wyatt_architecture.dart'; -import 'package:wyatt_crud_bloc/src/core/enums/where_query_type.dart'; -import 'package:wyatt_crud_bloc/src/domain/entities/object_model.dart'; -import 'package:wyatt_crud_bloc/src/domain/entities/query.dart'; -import 'package:wyatt_crud_bloc/src/domain/usecases/create.dart'; -import 'package:wyatt_crud_bloc/src/domain/usecases/delete.dart'; -import 'package:wyatt_crud_bloc/src/domain/usecases/delete_all.dart'; -import 'package:wyatt_crud_bloc/src/domain/usecases/get.dart'; -import 'package:wyatt_crud_bloc/src/domain/usecases/get_all.dart'; -import 'package:wyatt_crud_bloc/src/domain/usecases/params/update_parameters.dart'; -import 'package:wyatt_crud_bloc/src/domain/usecases/query.dart'; -import 'package:wyatt_crud_bloc/src/domain/usecases/update.dart'; -import 'package:wyatt_crud_bloc/src/domain/usecases/update_all.dart'; - -part 'crud_state.dart'; - -abstract class CrudCubit extends Cubit { - CrudCubit() : super(CrudInitial()); - Create? get crudCreate; - DeleteAll? get crudDeleteAll; - Delete? get crudDelete; - GetAll? get crudGetAll; - Get? get crudGet; - Query? get crudQuery; - UpdateAll? get crudUpdateAll; - Update? get crudUpdate; - - FutureOr create(Model model) async { - if (crudCreate != null) { - final stateCopy = state; - emit(CrudLoading()); - final result = await crudCreate!.call(model); - emit( - result.fold( - (_) { - if (stateCopy is CrudLoaded) { - return stateCopy; - } - if (stateCopy is CrudListLoaded) { - if (stateCopy.data.isEmpty) { - return CrudListLoaded([model]); - } - final List lst = stateCopy.data.toList()..add(model); - return CrudListLoaded(lst); - } - return const CrudOkReturn(); - }, - (error) => CrudError(error.toString()), - ), - ); - } - } - - FutureOr delete(String id) async { - if (crudDelete != null) { - final stateCopy = state; - emit(CrudLoading()); - final result = await crudDelete!.call(id); - emit( - result.fold( - (_) { - if (stateCopy is CrudLoaded) { - return stateCopy; - } - if (stateCopy is CrudListLoaded) { - return CrudListLoaded( - stateCopy.data.where((element) => element?.id != id).toList(), - ); - } - return const CrudOkReturn(); - }, - (error) => CrudError(error.toString()), - ), - ); - } - } - - FutureOr deleteAll() async { - if (crudDeleteAll != null) { - final stateCopy = state; - emit(CrudLoading()); - final result = await crudDeleteAll!.call(null); - emit( - result.fold( - (_) { - if (stateCopy is CrudLoaded) { - return CrudLoaded(null); - } - if (stateCopy is CrudListLoaded) { - return CrudListLoaded(const []); - } - return const CrudOkReturn(); - }, - (error) => CrudError(error.toString()), - ), - ); - } - } - - FutureOr get(String id) async { - if (crudGet != null) { - emit(CrudLoading()); - final result = await crudGet!.call(id); - emit( - result.fold( - CrudLoaded.new, - (error) => CrudError(error.toString()), - ), - ); - } - } - - FutureOr getAll() async { - if (crudGetAll != null) { - emit(CrudLoading()); - final result = await crudGetAll!.call(null); - emit( - result.fold( - CrudListLoaded.new, - (error) => CrudError(error.toString()), - ), - ); - } - } - - FutureOr query(List conditions) async { - if (crudQuery != null) { - emit(CrudLoading()); - final result = await crudQuery!.call(conditions); - emit( - result.fold( - CrudListLoaded.new, - (error) => CrudError(error.toString()), - ), - ); - } - } - - FutureOr update(UpdateParameters param) async { - if (crudUpdate != null) { - final stateCopy = state; - emit(CrudLoading()); - final result = await crudUpdate!.call(param); - emit( - await result.foldAsync( - (_) async { - if (stateCopy is CrudLoaded) { - if (stateCopy.data?.id == param.id) { - // Same object, need to update actual stateCopy - if (crudGet == null) { - throw ClientException( - 'Need to init Get usecase to use update.', - ); - } - final newVersion = await crudGet!.call(param.id); - if (newVersion.isOk) { - return CrudLoaded(newVersion.ok); - } - } - return stateCopy; - } - if (stateCopy is CrudListLoaded) { - final bool listContains = - stateCopy.data.any((element) => element?.id == param.id); - if (listContains) { - // Loaded objects contains the modified object. - if (crudGet == null) { - throw ClientException( - 'Need to init Get usecase to use update.', - ); - } - final newVersion = await crudGet!.call(param.id); - if (newVersion.isOk) { - final newList = stateCopy.data - .where( - (element) => element?.id != param.id, - ) - .toList(); - return CrudListLoaded(newList + [newVersion.ok]); - } - } - return stateCopy; - } - return const CrudOkReturn(); - }, - (error) async => CrudError(error.toString()), - ), - ); - } - } - - FutureOr updateAll(Map param) async { - if (crudUpdateAll != null) { - final stateCopy = state; - emit(CrudLoading()); - final result = await crudUpdateAll!.call(param); - emit( - await result.foldAsync( - (_) async { - if (stateCopy is CrudLoaded) { - // Same object, need to update actual stateCopy - if (crudGet == null) { - throw ClientException( - 'Need to init Get usecase to use updateAll.', - ); - } - final actualId = stateCopy.data?.id; - final newVersion = await crudGet!.call(actualId ?? ''); - if (newVersion.isOk) { - return CrudLoaded(newVersion.ok); - } - return stateCopy; - } - if (stateCopy is CrudListLoaded) { - if (crudQuery == null) { - throw ClientException( - 'Need to init Query usecase to use updateAll.', - ); - } - // Load all id to retrieve exactly same object - // (not all because previous stateCopy can be a query result) - final List ids = stateCopy.data - .map( - (e) => e?.id, - ) - .toList(); - final result = await crudQuery!.call([ - WhereQuery( - WhereQueryType.whereIn, - 'id', - ids, - ) - ]); - if (result.isOk) { - return CrudListLoaded(result.ok ?? []); - } - return stateCopy; - } - return const CrudOkReturn(); - }, - (error) async => CrudError(error.toString()), - ), - ); - } - } -} diff --git a/packages/wyatt_crud_bloc/pubspec.yaml b/packages/wyatt_crud_bloc/pubspec.yaml index 058de9d4..52960c0e 100644 --- a/packages/wyatt_crud_bloc/pubspec.yaml +++ b/packages/wyatt_crud_bloc/pubspec.yaml @@ -10,8 +10,7 @@ environment: flutter: ">=1.17.0" dependencies: - flutter: - sdk: flutter + flutter: { sdk: flutter } flutter_bloc: ^8.1.1 equatable: ^2.0.5 @@ -26,8 +25,7 @@ dependencies: version: ^0.0.4 dev_dependencies: - flutter_test: - sdk: flutter + flutter_test: { sdk: flutter } bloc_test: ^9.1.0 wyatt_analysis: hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub/ -- 2.47.2 From 07c2f4aeffc282e78b1645800a835e67c5e21b07 Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Thu, 13 Apr 2023 22:00:45 +0200 Subject: [PATCH 37/47] refactor(http)!: fix cascade dart good practices + docs --- .../lib/core/dependency_injection/get_it.dart | 14 +- packages/wyatt_http_client/README.md | 36 +- .../example/http_client_example.dart | 294 -------------- .../example/http_client_fastapi_example.dart | 371 ------------------ .../wyatt_http_client/example/pipeline.dart | 164 -------- .../wyatt_http_client/lib/src/middleware.dart | 12 +- .../lib/src/middleware_client.dart | 14 +- .../access_token_auth_middleware.dart | 15 - .../middlewares/basic_auth_middleware.dart | 21 +- .../middlewares/body_to_json_middleware.dart | 11 +- .../src/middlewares/default_middleware.dart | 6 + .../middlewares/digest_auth_middleware.dart | 12 +- .../lib/src/middlewares/middlewares.dart | 3 +- .../refresh_token_auth_middleware.dart | 16 +- .../middlewares/simple_logger_middleware.dart | 40 +- .../middlewares/unsafe_auth_middleware.dart | 15 +- .../middlewares/uri_prefix_middleware.dart | 15 +- .../lib/src/models/middleware_context.dart | 34 +- .../lib/src/models/middleware_request.dart | 49 ++- .../lib/src/models/middleware_response.dart | 26 +- .../lib/src/models/unfreezed_request.dart | 20 +- .../wyatt_http_client/lib/src/pipeline.dart | 27 +- .../lib/src/utils/authentication_methods.dart | 6 + .../lib/src/utils/convert.dart | 12 +- .../lib/src/utils/crypto.dart | 3 +- .../lib/src/utils/delay.dart | 2 + .../lib/src/utils/digest_auth.dart | 5 +- .../lib/src/utils/header_keys.dart | 6 + .../lib/src/utils/http_methods.dart | 4 + .../lib/src/utils/http_status.dart | 6 + .../lib/src/utils/protocols.dart | 4 + .../lib/src/utils/request_utils.dart | 6 + packages/wyatt_http_client/pubspec.yaml | 8 +- 33 files changed, 303 insertions(+), 974 deletions(-) delete mode 100644 packages/wyatt_http_client/example/http_client_example.dart delete mode 100644 packages/wyatt_http_client/example/http_client_fastapi_example.dart delete mode 100644 packages/wyatt_http_client/example/pipeline.dart delete mode 100644 packages/wyatt_http_client/lib/src/middlewares/access_token_auth_middleware.dart diff --git a/packages/wyatt_architecture/example/lib/core/dependency_injection/get_it.dart b/packages/wyatt_architecture/example/lib/core/dependency_injection/get_it.dart index e43a12a1..a3e2bc25 100644 --- a/packages/wyatt_architecture/example/lib/core/dependency_injection/get_it.dart +++ b/packages/wyatt_architecture/example/lib/core/dependency_injection/get_it.dart @@ -52,13 +52,13 @@ abstract class GetItInitializer { ) ..registerLazySingleton(() { final Pipeline pipeline = Pipeline() - .addMiddleware( - UriPrefixMiddleware( - protocol: Protocols.https, - authority: 'jsonplaceholder.typicode.com', - ), - ) - .addMiddleware(BodyToJsonMiddleware()); + ..addMiddleware( + const UriPrefixMiddleware( + protocol: Protocols.https, + authority: 'jsonplaceholder.typicode.com', + ), + ) + ..addMiddleware(const BodyToJsonMiddleware()); return MiddlewareClient(pipeline: pipeline); }) ..registerLazySingleton( diff --git a/packages/wyatt_http_client/README.md b/packages/wyatt_http_client/README.md index ee2b78d5..aee439ed 100644 --- a/packages/wyatt_http_client/README.md +++ b/packages/wyatt_http_client/README.md @@ -16,12 +16,10 @@ * along with this program. If not, see . --> -# Dart - HTTP Client +# HTTP Client

- - Style: Wyatt Analysis - + Style: Wyatt Analysis SDK: Dart & Flutter

@@ -52,13 +50,13 @@ For example, if you want to log every request, and simplify an url you can use p ```dart // Create the Pipeline final Pipeline pipeline = Pipeline() - .addMiddleware( - UriPrefixMiddleware( + ..addMiddleware( + const UriPrefixMiddleware( protocol: Protocols.http, authority: 'localhost:80', ), ) - .addMiddleware(SimpleLoggerMiddleware()); + ..addMiddleware(const SimpleLoggerMiddleware()); ``` Then if you print the pipeline, @@ -94,20 +92,20 @@ Let's start by creating the Pipeline: ```dart final Pipeline pipeline = Pipeline() - .addMiddleware( - UriPrefixMiddleware( + ..addMiddleware( + const UriPrefixMiddleware( protocol: Protocols.http, authority: 'localhost:80', ), ) - .addMiddleware(BodyToJsonMiddleware()) - .addMiddleware( - UnsafeAuthMiddleware( + ..addMiddleware(const BodyToJsonMiddleware()) + ..addMiddleware( + const UnsafeAuthMiddleware( username: 'wyatt', password: 'motdepasse', ), ) - .addMiddleware(SimpleLoggerMiddleware()); + ..addMiddleware(SimpleLoggerMiddleware()); ``` Then simply create a client and make a call. @@ -128,14 +126,14 @@ So now we want a real authentication. ```dart final Pipeline pipeline = Pipeline() - .addMiddleware( - UriPrefixMiddleware( + ..addMiddleware( + const UriPrefixMiddleware( protocol: Protocols.http, authority: 'localhost:80', ), ) - .addMiddleware(BodyToJsonMiddleware()) - .addMiddleware( + ..addMiddleware(const BodyToJsonMiddleware()) + ..addMiddleware( RefreshTokenAuthMiddleware( authorizationEndpoint: '/auth/sign-in', tokenEndpoint: '/auth/refresh', @@ -144,7 +142,7 @@ final Pipeline pipeline = Pipeline() unauthorized: HttpStatus.forbidden, ), ) - .addMiddleware(SimpleLoggerMiddleware()); + ..addMiddleware(const SimpleLoggerMiddleware()); ``` > Here we just change `UnsafeAuthMiddleware` by `RefreshTokenAuthMiddleware` and the whole app while adapt to a new authentication system. @@ -157,6 +155,8 @@ You can create your own middleware by implementing `Middleware` class, and use m class SimpleLoggerMiddleware with OnRequestMiddleware, OnResponseMiddleware implements Middleware { + + const SimpleLoggerMiddleware(); @override String getName() => 'SimpleLogger'; diff --git a/packages/wyatt_http_client/example/http_client_example.dart b/packages/wyatt_http_client/example/http_client_example.dart deleted file mode 100644 index 43009540..00000000 --- a/packages/wyatt_http_client/example/http_client_example.dart +++ /dev/null @@ -1,294 +0,0 @@ -// Copyright (C) 2022 WYATT GROUP -// Please see the AUTHORS file for details. -// -// This program is free software: you can redistribute it and/or modify -// it under the terms of the GNU General Public License as published by -// the Free Software Foundation, either version 3 of the License, or -// any later version. -// -// This program is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with this program. If not, see . - -import 'dart:async'; -import 'dart:io'; - -import 'package:wyatt_http_client/wyatt_http_client.dart'; - -String lastToken = ''; -int token = 0; - -void printAuth(HttpRequest req) { - print( - 'Authorization => ' - "${req.headers.value('Authorization') ?? 'no authorization header'}", - ); -} - -Future handleBasic(HttpRequest req) async { - printAuth(req); -} - -Future handleBasicNegotiate(HttpRequest req) async { - if (req.headers.value('Authorization') == null) { - req.response.statusCode = HttpStatus.unauthorized.statusCode; - req.response.headers.set(HeaderKeys.wwwAuthenticate, 'Basic realm="Wyatt"'); - print(req.response.headers.value('WWW-Authenticate')); - return req.response.close(); - } - printAuth(req); -} - -Future handleBearer(HttpRequest req) async { - printAuth(req); -} - -Future handleDigest(HttpRequest req) async { - if (req.headers.value('Authorization') == null) { - req.response.statusCode = HttpStatus.unauthorized.statusCode; - req.response.headers.set( - 'WWW-Authenticate', - 'Digest realm="Wyatt", ' - 'qop="auth,auth-int", ' - 'nonce="dcd98b7102dd2f0e8b11d0f600bfb0c093", ' - 'opaque="5ccc069c403ebaf9f0171e9517f40e41"', - ); - print(req.response.headers.value('WWW-Authenticate')); - return req.response.close(); - } - printAuth(req); -} - -Future handleUnsafe(HttpRequest req) async { - print( - 'Query parameters => ' - '${req.uri.queryParameters}', - ); -} - -Future handleOauth2RefreshToken(HttpRequest req) async { - final action = req.uri.queryParameters['action']; - if (action == null) { - printAuth(req); - } - - switch (action) { - case 'login': - if (req.method == 'POST') { - token++; - req.response.write( - '{"accessToken": "access-token-awesome$token", ' - '"refreshToken": "refresh-token-awesome$token"}', - ); - } - break; - case 'refresh': - printAuth(req); - if (req.method == 'GET') { - token++; - req.response.write('{"accessToken": "access-token-refreshed$token"}'); - } - break; - case 'access-denied': - final String receivedToken = req.headers.value('Authorization') ?? ''; - if (receivedToken != '' && - lastToken != '' && - receivedToken != lastToken) { - lastToken = receivedToken; - printAuth(req); - return req.response.close(); - } else { - lastToken = receivedToken; - req.response.statusCode = HttpStatus.unauthorized.statusCode; - return req.response.close(); - } - default: - break; - } -} - -Future server() async { - final server = await HttpServer.bind(InternetAddress.anyIPv6, 8080); - var error = 0; - var token = 0; - await server.forEach((request) { - print('[${request.method}] ${request.uri}'); - switch (request.uri.path) { - case '/test/basic-test': - handleBasic(request); - break; - case '/test/basic-test-with-negotiate': - handleBasicNegotiate(request); - break; - case '/test/digest-test': - handleDigest(request); - break; - case '/test/apikey-test': - handleBearer(request); - break; - case '/test/bearer-test': - handleBearer(request); - break; - case '/test/unsafe-test': - handleUnsafe(request); - break; - case '/test/oauth2-test': - handleOauth2RefreshToken(request); - break; - - case '/test/bearer-login': - if (request.method == 'POST') { - request.response.write('{"token": "access-token-test"}'); - } - break; - - case '/test/oauth2-test-error': - error++; - print('Error $error'); - if (error >= 3) { - print('Authorized'); - error = 0; - } else { - request.response.statusCode = HttpStatus.unauthorized.statusCode; - } - break; - case '/test/oauth2-test-timeout': - error++; - print('Error $error'); - request.response.statusCode = HttpStatus.unauthorized.statusCode; - break; - case '/test/oauth2-login': - if (request.method == 'POST') { - token++; - request.response.write( - '{"accessToken": "access-token-awesome$token", ' - '"refreshToken": "refresh-token-awesome$token"}', - ); - } - break; - case '/test/oauth2-refresh': - print( - 'Authorization => ' - "${request.headers.value('Authorization') ?? 'no refresh token'}", - ); - if (request.method == 'GET') { - token++; - request.response - .write('{"accessToken": "access-token-refreshed$token"}'); - } - break; - case '/test/oauth2-refresh-error': - request.response.statusCode = HttpStatus.unauthorized.statusCode; - break; - - default: - print(' => Unknown path or method'); - request.response.statusCode = HttpStatus.notFound.statusCode; - } - request.response.close(); - print('===================='); - }); -} - -Future main() async { - unawaited(server()); - const base = 'localhost:8080'; - final uriPrefix = UriPrefixMiddleware( - protocol: Protocols.http, - authority: base, - ); - final jsonEncoder = BodyToJsonMiddleware(); - final logger = SimpleLoggerMiddleware(); - - // Basic - final basicAuth = BasicAuthMiddleware( - username: 'username', - password: 'password', - ); - final basic = MiddlewareClient( - pipeline: Pipeline.fromIterable([ - uriPrefix, - basicAuth, - logger, - ]), - ); - await basic.get(Uri.parse('/test/basic-test')); - - // Digest - final digestAuth = DigestAuthMiddleware( - username: 'Mufasa', - password: 'Circle Of Life', - ); - final digest = MiddlewareClient( - pipeline: Pipeline.fromIterable([ - uriPrefix, - digestAuth, - logger, - ]), - ); - await digest.get(Uri.parse('/test/digest-test')); - - // // Bearer - // final bearer = BearerAuthenticationClient( - // token: 'access-token-test', - // inner: restClient, - // ); - // await bearer.get(Uri.parse('/test/bearer-test')); - - // // API Key - // final apiKey = BearerAuthenticationClient( - // token: 'awesome-api-key', - // authenticationMethod: 'ApiKey', - // inner: restClient, - // ); - // await apiKey.get(Uri.parse('/test/apikey-test')); - - // Unsafe URL - final unsafeAuth = UnsafeAuthMiddleware( - username: 'Mufasa', - password: 'Circle Of Life', - ); - final unsafe = MiddlewareClient( - pipeline: Pipeline.fromIterable([ - uriPrefix, - unsafeAuth, - logger, - ]), - ); - await unsafe.get(Uri.parse('/test/unsafe-test')); - - // OAuth2 - final refreshTokenAuth = RefreshTokenAuthMiddleware( - authorizationEndpoint: '/test/oauth2-test?action=login', - tokenEndpoint: '/test/oauth2-test?action=refresh', - accessTokenParser: (body) => body['accessToken']! as String, - refreshTokenParser: (body) => body['refreshToken']! as String, - ); - final refreshToken = MiddlewareClient( - pipeline: Pipeline.fromIterable([ - uriPrefix, - jsonEncoder, - refreshTokenAuth, - logger, - ]), - ); - await refreshToken.get(Uri.parse('/test/oauth2-test')); - // Login - await refreshToken.post( - Uri.parse('/test/oauth2-test'), - body: { - 'username': 'username', - 'password': 'password', - }, - ); - await refreshToken.get(Uri.parse('/test/oauth2-test')); - // await refreshToken.refresh(); - // await refreshToken.get(Uri.parse('/test/oauth2-test')); - // await refreshToken.get(Uri.parse('/test/oauth2-test?action=access-denied')); - - exit(0); -} diff --git a/packages/wyatt_http_client/example/http_client_fastapi_example.dart b/packages/wyatt_http_client/example/http_client_fastapi_example.dart deleted file mode 100644 index b9a900fd..00000000 --- a/packages/wyatt_http_client/example/http_client_fastapi_example.dart +++ /dev/null @@ -1,371 +0,0 @@ -// Copyright (C) 2022 WYATT GROUP -// Please see the AUTHORS file for details. -// -// This program is free software: you can redistribute it and/or modify -// it under the terms of the GNU General Public License as published by -// the Free Software Foundation, either version 3 of the License, or -// any later version. -// -// This program is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with this program. If not, see . - -// ignore_for_file: public_member_api_docs, sort_constructors_first -import 'dart:convert'; - -import 'package:wyatt_http_client/src/middleware_client.dart'; -import 'package:wyatt_http_client/src/middlewares/body_to_json_middleware.dart'; -import 'package:wyatt_http_client/src/middlewares/refresh_token_auth_middleware.dart'; -import 'package:wyatt_http_client/src/middlewares/simple_logger_middleware.dart'; -import 'package:wyatt_http_client/src/middlewares/uri_prefix_middleware.dart'; -import 'package:wyatt_http_client/src/pipeline.dart'; -import 'package:wyatt_http_client/src/utils/http_status.dart'; -import 'package:wyatt_http_client/src/utils/protocols.dart'; - -enum EmailVerificationAction { - signUp, - resetPassword, - changeEmail; - - String toSnakeCase() => name.splitMapJoin( - RegExp('[A-Z]'), - onMatch: (m) => '_${m[0]?.toLowerCase()}', - onNonMatch: (n) => n, - ); - - factory EmailVerificationAction.fromString(String str) => - EmailVerificationAction.values.firstWhere( - (element) => element.toSnakeCase() == str, - ); -} - -class VerifyCode { - final String email; - final String verificationCode; - final EmailVerificationAction action; - VerifyCode({ - required this.email, - required this.verificationCode, - required this.action, - }); - - VerifyCode copyWith({ - String? email, - String? verificationCode, - EmailVerificationAction? action, - }) => - VerifyCode( - email: email ?? this.email, - verificationCode: verificationCode ?? this.verificationCode, - action: action ?? this.action, - ); - - Map toMap() => { - 'email': email, - 'verification_code': verificationCode, - 'action': action.toSnakeCase(), - }; - - factory VerifyCode.fromMap(Map map) => VerifyCode( - email: map['email'] as String, - verificationCode: map['verification_code'] as String, - action: EmailVerificationAction.fromString(map['action'] as String), - ); - - String toJson() => json.encode(toMap()); - - factory VerifyCode.fromJson(String source) => - VerifyCode.fromMap(json.decode(source) as Map); - - @override - String toString() => 'VerifyCode(email: $email, verificationCode: ' - '$verificationCode, action: $action)'; -} - -class Account { - final String email; - final String? sessionId; - Account({ - required this.email, - this.sessionId, - }); - - Account copyWith({ - String? email, - String? sessionId, - }) => - Account( - email: email ?? this.email, - sessionId: sessionId ?? this.sessionId, - ); - - Map toMap() => { - 'email': email, - 'session_id': sessionId, - }; - - factory Account.fromMap(Map map) => Account( - email: map['email'] as String, - sessionId: - map['session_id'] != null ? map['session_id'] as String : null, - ); - - String toJson() => json.encode(toMap()); - - factory Account.fromJson(String source) => - Account.fromMap(json.decode(source) as Map); - - @override - String toString() => 'Account(email: $email, sessionId: $sessionId)'; -} - -class SignUp { - final String sessionId; - final String password; - SignUp({ - required this.sessionId, - required this.password, - }); - - SignUp copyWith({ - String? sessionId, - String? password, - }) => - SignUp( - sessionId: sessionId ?? this.sessionId, - password: password ?? this.password, - ); - - Map toMap() => { - 'session_id': sessionId, - 'password': password, - }; - - factory SignUp.fromMap(Map map) => SignUp( - sessionId: map['session_id'] as String, - password: map['password'] as String, - ); - - String toJson() => json.encode(toMap()); - - factory SignUp.fromJson(String source) => - SignUp.fromMap(json.decode(source) as Map); - - @override - String toString() => 'SignUp(sessionId: $sessionId, password: $password)'; -} - -class TokenSuccess { - final String accessToken; - final String refreshToken; - final Account account; - TokenSuccess({ - required this.accessToken, - required this.refreshToken, - required this.account, - }); - - TokenSuccess copyWith({ - String? accessToken, - String? refreshToken, - Account? account, - }) => - TokenSuccess( - accessToken: accessToken ?? this.accessToken, - refreshToken: refreshToken ?? this.refreshToken, - account: account ?? this.account, - ); - - Map toMap() => { - 'access_token': accessToken, - 'refresh_token': refreshToken, - 'account': account.toMap(), - }; - - factory TokenSuccess.fromMap(Map map) => TokenSuccess( - accessToken: map['access_token'] as String, - refreshToken: map['refresh_token'] as String, - account: Account.fromMap(map['account'] as Map), - ); - - String toJson() => json.encode(toMap()); - - factory TokenSuccess.fromJson(String source) => - TokenSuccess.fromMap(json.decode(source) as Map); - - @override - String toString() => 'TokenSuccess(accessToken: $accessToken, refreshToken: ' - '$refreshToken, account: $account)'; -} - -class Login { - final String email; - final String password; - Login({ - required this.email, - required this.password, - }); - - Login copyWith({ - String? email, - String? password, - }) => - Login( - email: email ?? this.email, - password: password ?? this.password, - ); - - Map toMap() => { - 'email': email, - 'password': password, - }; - - factory Login.fromMap(Map map) => Login( - email: map['email'] as String, - password: map['password'] as String, - ); - - String toJson() => json.encode(toMap()); - - factory Login.fromJson(String source) => - Login.fromMap(json.decode(source) as Map); - - @override - String toString() => 'Login(email: $email, password: $password)'; -} - -class FastAPI { - final String baseUrl; - final MiddlewareClient client; - final int apiVersion; - - FastAPI({ - this.baseUrl = 'localhost:80', - MiddlewareClient? client, - this.apiVersion = 1, - }) : client = client ?? MiddlewareClient(); - - String get apiPath => '/api/v$apiVersion'; - - Future sendSignUpCode(String email) async { - final r = await client.post( - Uri.parse('$apiPath/auth/send-sign-up-code'), - body: { - 'email': email, - }, - ); - if (r.statusCode != 201) { - throw Exception('Invalid reponse: ${r.statusCode}'); - } - } - - Future verifyCode(VerifyCode verifyCode) async { - final r = await client.post( - Uri.parse('$apiPath/auth/verify-code'), - body: verifyCode.toMap(), - ); - if (r.statusCode != 202) { - throw Exception('Invalid reponse: ${r.statusCode}'); - } else { - return Account.fromMap( - (jsonDecode(r.body) as Map)['account'] - as Map, - ); - } - } - - Future signUp(SignUp signUp) async { - final r = await client.post( - Uri.parse('$apiPath/auth/sign-up'), - body: signUp.toMap(), - ); - if (r.statusCode != 201) { - throw Exception('Invalid reponse: ${r.statusCode}'); - } else { - return Account.fromJson(r.body); - } - } - - Future signInWithPassword(Login login) async { - final r = await client.post( - Uri.parse('$apiPath/auth/sign-in-with-password'), - body: login.toMap(), - ); - if (r.statusCode != 200) { - throw Exception('Invalid reponse: ${r.statusCode}'); - } else { - return TokenSuccess.fromJson(r.body); - } - } - - // Future refresh() async { - // final r = await client.refresh(); - // return TokenSuccess.fromJson(r?.body ?? ''); - // } - - Future> getAccountList() async { - final r = await client.get( - Uri.parse('$apiPath/account'), - ); - if (r.statusCode != 200) { - throw Exception('Invalid reponse: ${r.statusCode}'); - } else { - final list = (jsonDecode(r.body) as Map)['founds'] - as List>; - final result = []; - for (final element in list) { - result.add(Account.fromMap(element)); - } - return result; - } - } -} - -void main(List args) async { - final Pipeline pipeline = Pipeline() - .addMiddleware( - UriPrefixMiddleware( - protocol: Protocols.http, - authority: 'localhost:80', - ), - ) - .addMiddleware(BodyToJsonMiddleware()) - .addMiddleware( - RefreshTokenAuthMiddleware( - authorizationEndpoint: '/api/v1/auth/sign-in-with-password', - tokenEndpoint: '/api/v1/auth/refresh', - accessTokenParser: (body) => body['access_token']! as String, - refreshTokenParser: (body) => body['refresh_token']! as String, - unauthorized: HttpStatus.forbidden, - ), - ) - .addMiddleware(SimpleLoggerMiddleware()); - - print(pipeline); - final client = MiddlewareClient(pipeline: pipeline); - - final api = FastAPI( - client: client, - ); - - await api.sendSignUpCode('git@pcl.ovh'); - // final verifiedAccount = await api.verifyCode( - // VerifyCode( - // email: 'git@pcl.ovh', - // verificationCode: '000000000', - // action: EmailVerificationAction.signUp, - // ), - // ); - // final registeredAccount = await api.signUp( - // SignUp(sessionId: verifiedAccount.sessionId ?? '', password: 'password'), - // ); - // final signedInAccount = await api.signInWithPassword( - // Login(email: 'git@pcl.ovh', password: 'password'), - // ); - final accountList = await api.getAccountList(); - print(accountList); -} diff --git a/packages/wyatt_http_client/example/pipeline.dart b/packages/wyatt_http_client/example/pipeline.dart deleted file mode 100644 index 7f261f39..00000000 --- a/packages/wyatt_http_client/example/pipeline.dart +++ /dev/null @@ -1,164 +0,0 @@ -// ignore_for_file: public_member_api_docs, sort_constructors_first -// Copyright (C) 2022 WYATT GROUP -// Please see the AUTHORS file for details. -// -// This program is free software: you can redistribute it and/or modify -// it under the terms of the GNU General Public License as published by -// the Free Software Foundation, either version 3 of the License, or -// any later version. -// -// This program is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with this program. If not, see . - -import 'package:wyatt_http_client/src/middleware_client.dart'; -import 'package:wyatt_http_client/src/middlewares/body_to_json_middleware.dart'; -import 'package:wyatt_http_client/src/middlewares/simple_logger_middleware.dart'; -import 'package:wyatt_http_client/src/middlewares/unsafe_auth_middleware.dart'; -import 'package:wyatt_http_client/src/middlewares/uri_prefix_middleware.dart'; -import 'package:wyatt_http_client/src/pipeline.dart'; -import 'package:wyatt_http_client/src/utils/protocols.dart'; - -// class RequestMutatorMiddleware implements Middleware { -// @override -// Middleware? parent; - -// @override -// Middleware? child; - -// RequestMutatorMiddleware({ -// this.parent, -// this.child, -// }); - -// @override -// BaseRequest onRequest(BaseRequest request) { -// print('RequestMutator::OnRequest: ${request.method} -> ${request.url}'); -// return child?.onRequest(request) ?? request; -// } - -// @override -// BaseResponse onResponse(BaseResponse response) { -// final res = child?.onResponse(response) ?? response; -// print( -// 'RequestMutator::OnResponse: ${res.statusCode} -> ${res.contentLength} -// bytes', -// ); -// return res; -// } -// } - -// typedef Middleware = Handler Function(Handler innerHandler); - -// Middleware createMiddleware({ -// FutureOr Function(Request)? requestHandler, -// FutureOr Function(Response)? responseHandler, -// FutureOr Function(Object error, StackTrace)? errorHandler, -// }) { -// requestHandler ??= (request) => null; -// responseHandler ??= (response) => response; - -// FutureOr Function(Object, StackTrace)? onError; -// if (errorHandler != null) { -// onError = (error, stackTrace) { -// if (error is Exception) throw error; -// return errorHandler(error, stackTrace); -// }; -// } - -// return (Handler innerHandler) { -// return (request) { -// return Future.sync(() => requestHandler!(request)).then((response) { -// if (response != null) return response; - -// return Future.sync(() => innerHandler(request)) -// .then((response) => responseHandler!(response), onError: -// onError); -// }); -// }; -// }; -// } - -// extension MiddlewareX on Middleware { -// Middleware addMiddleware(Middleware other) => -// (Handler handler) => this(other(handler)); -// Handler addHandler(Handler handler) => this(handler); -// } - -// typedef Handler = FutureOr Function(Request request); - -// final headerMutator = createMiddleware( -// responseHandler: (response) { -// print(response.headers); -// return response; -// },); - -// class Pipeline { -// const Pipeline(); - -// Pipeline addMiddleware(Middleware middleware) => -// _Pipeline(middleware, addHandler); - -// Handler addHandler(Handler handler) => handler; - -// Middleware get middleware => addHandler; -// } - -// class _Pipeline extends Pipeline { -// final Middleware _middleware; -// final Middleware _parent; - -// _Pipeline(this._middleware, this._parent); - -// @override -// Handler addHandler(Handler handler) => _parent(_middleware(handler)); -// } - -Future main(List args) async { - final UnsafeAuthMiddleware auth = UnsafeAuthMiddleware(); - final Pipeline pipeline = Pipeline() - .addMiddleware( - UriPrefixMiddleware( - protocol: Protocols.http, - authority: 'localhost:80', - ), - ) - .addMiddleware(BodyToJsonMiddleware()) - .addMiddleware( - UnsafeAuthMiddleware( - username: 'wyatt', - password: 'motdepasse', - ), - ) - .addMiddleware(SimpleLoggerMiddleware()); - // .addMiddleware( - // RefreshTokenMiddleware( - // authorizationEndpoint: '/api/v1/account/test?action=authorize', - // tokenEndpoint: '/api/v1/account/test?action=refresh', - // accessTokenParser: (body) => body['access_token']! as String, - // refreshTokenParser: (body) => body['refresh_token']! as String, - // ), - // ); - - print(pipeline); - final client = MiddlewareClient(pipeline: pipeline); - await client.post( - Uri.parse('/api/v1/account/test'), - body: { - 'email': 'test@test.fr', - }, - ); - auth - ..username = 'username' - ..password = 'password'; - await client.post( - Uri.parse('/api/v1/account/test'), - body: { - 'email': 'test@test.fr', - }, - ); -} diff --git a/packages/wyatt_http_client/lib/src/middleware.dart b/packages/wyatt_http_client/lib/src/middleware.dart index 07cf6323..9f0c9d67 100644 --- a/packages/wyatt_http_client/lib/src/middleware.dart +++ b/packages/wyatt_http_client/lib/src/middleware.dart @@ -18,12 +18,21 @@ import 'package:wyatt_http_client/src/models/middleware_context.dart'; import 'package:wyatt_http_client/src/models/middleware_request.dart'; import 'package:wyatt_http_client/src/models/middleware_response.dart'; +/// {@template middleware} +/// A middleware is a class that can intercept requests and responses +/// and modify them before they are sent to the server or before they +/// are returned to the client. +/// {@endtemplate} abstract class Middleware { - Middleware(); + /// {@macro middleware} + const Middleware(); + + /// The name of the middleware. String getName(); } mixin OnRequestMiddleware { + /// Performs an action before the request is sent to the server. Future onRequest( MiddlewareContext context, MiddlewareRequest request, @@ -31,6 +40,7 @@ mixin OnRequestMiddleware { } mixin OnResponseMiddleware { + /// Performs an action before the response is returned to the client. Future onResponse( MiddlewareContext context, MiddlewareResponse response, diff --git a/packages/wyatt_http_client/lib/src/middleware_client.dart b/packages/wyatt_http_client/lib/src/middleware_client.dart index 14cbd094..23c1f064 100644 --- a/packages/wyatt_http_client/lib/src/middleware_client.dart +++ b/packages/wyatt_http_client/lib/src/middleware_client.dart @@ -24,15 +24,23 @@ import 'package:wyatt_http_client/src/models/unfreezed_request.dart'; import 'package:wyatt_http_client/src/pipeline.dart'; import 'package:wyatt_http_client/src/utils/http_methods.dart'; +/// {@template middleware_client} +/// A custom [Client] implementation that allows you to intercept requests +/// and responses and modify them before they are sent to the server or +/// before they are returned to the client. +/// {@endtemplate} class MiddlewareClient extends BaseClient { + /// {@macro middleware_client} MiddlewareClient({ Pipeline? pipeline, Client? inner, }) : pipeline = pipeline ?? Pipeline(), - inner = inner ?? Client() { - print('Using Pipeline:\n$pipeline'); - } + inner = inner ?? Client(); + + /// The [Client] that will be used to send requests. final Client inner; + + /// The [Pipeline] that will be used to intercept requests and responses. final Pipeline pipeline; @override diff --git a/packages/wyatt_http_client/lib/src/middlewares/access_token_auth_middleware.dart b/packages/wyatt_http_client/lib/src/middlewares/access_token_auth_middleware.dart deleted file mode 100644 index 1bb8b149..00000000 --- a/packages/wyatt_http_client/lib/src/middlewares/access_token_auth_middleware.dart +++ /dev/null @@ -1,15 +0,0 @@ -// Copyright (C) 2022 WYATT GROUP -// Please see the AUTHORS file for details. -// -// This program is free software: you can redistribute it and/or modify -// it under the terms of the GNU General Public License as published by -// the Free Software Foundation, either version 3 of the License, or -// any later version. -// -// This program is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with this program. If not, see . diff --git a/packages/wyatt_http_client/lib/src/middlewares/basic_auth_middleware.dart b/packages/wyatt_http_client/lib/src/middlewares/basic_auth_middleware.dart index 529e3113..37bf033a 100644 --- a/packages/wyatt_http_client/lib/src/middlewares/basic_auth_middleware.dart +++ b/packages/wyatt_http_client/lib/src/middlewares/basic_auth_middleware.dart @@ -22,14 +22,24 @@ import 'package:wyatt_http_client/src/models/middleware_request.dart'; import 'package:wyatt_http_client/src/utils/authentication_methods.dart'; import 'package:wyatt_http_client/src/utils/header_keys.dart'; +/// {@template basic_auth_middleware} +/// A middleware that adds basic authentication to the request. +/// {@endtemplate} class BasicAuthMiddleware with OnRequestMiddleware implements Middleware { - BasicAuthMiddleware({ + /// {@macro basic_auth_middleware} + const BasicAuthMiddleware({ this.username, this.password, this.authenticationHeader = HeaderKeys.authorization, }); - String? username; - String? password; + + /// The username to use for authentication. + final String? username; + + /// The password to use for authentication. + final String? password; + + /// The header to use for authentication. final String authenticationHeader; @override @@ -43,10 +53,7 @@ class BasicAuthMiddleware with OnRequestMiddleware implements Middleware { if (username == null || password == null) { return request; } - print( - '${getName()}::OnRequest\n' - '>> Basic: ${base64Encode(utf8.encode('$username:$password'))}', - ); + final mutation = { authenticationHeader: '${AuthenticationMethods.basic} ' '${base64Encode(utf8.encode('$username:$password'))}', diff --git a/packages/wyatt_http_client/lib/src/middlewares/body_to_json_middleware.dart b/packages/wyatt_http_client/lib/src/middlewares/body_to_json_middleware.dart index a77048d8..e9aaaba7 100644 --- a/packages/wyatt_http_client/lib/src/middlewares/body_to_json_middleware.dart +++ b/packages/wyatt_http_client/lib/src/middlewares/body_to_json_middleware.dart @@ -20,7 +20,13 @@ import 'package:wyatt_http_client/src/middleware.dart'; import 'package:wyatt_http_client/src/models/middleware_context.dart'; import 'package:wyatt_http_client/src/models/middleware_request.dart'; +/// {@template body_to_json_middleware} +/// A middleware that transforms the body in json if it's a [Map]. +/// {@endtemplate} class BodyToJsonMiddleware with OnRequestMiddleware implements Middleware { + /// {@macro body_to_json_middleware} + const BodyToJsonMiddleware(); + @override String getName() => 'BodyToJson'; @@ -29,11 +35,6 @@ class BodyToJsonMiddleware with OnRequestMiddleware implements Middleware { MiddlewareContext context, MiddlewareRequest request, ) async { - print( - '${getName()}::OnRequest\n' - '>> Transforms body in json if Map then update ' - 'headers with right content-type', - ); final mutation = { 'content-type': 'application/json; charset=utf-8', }; diff --git a/packages/wyatt_http_client/lib/src/middlewares/default_middleware.dart b/packages/wyatt_http_client/lib/src/middlewares/default_middleware.dart index 65b766ca..456a07b5 100644 --- a/packages/wyatt_http_client/lib/src/middlewares/default_middleware.dart +++ b/packages/wyatt_http_client/lib/src/middlewares/default_middleware.dart @@ -16,7 +16,13 @@ import 'package:wyatt_http_client/src/middleware.dart'; +/// {@template default_middleware} +/// A default middleware that does nothing. +/// {@endtemplate} class DefaultMiddleware implements Middleware { + /// {@macro default_middleware} + const DefaultMiddleware(); + @override String getName() => 'DefaultMiddleware'; } diff --git a/packages/wyatt_http_client/lib/src/middlewares/digest_auth_middleware.dart b/packages/wyatt_http_client/lib/src/middlewares/digest_auth_middleware.dart index c09d0423..55c17030 100644 --- a/packages/wyatt_http_client/lib/src/middlewares/digest_auth_middleware.dart +++ b/packages/wyatt_http_client/lib/src/middlewares/digest_auth_middleware.dart @@ -22,9 +22,13 @@ import 'package:wyatt_http_client/src/utils/digest_auth.dart'; import 'package:wyatt_http_client/src/utils/header_keys.dart'; import 'package:wyatt_http_client/src/utils/http_status.dart'; +/// {@template digest_auth_middleware} +/// A middleware that handles digest authentication. +/// {@endtemplate} class DigestAuthMiddleware with OnRequestMiddleware, OnResponseMiddleware implements Middleware { + /// {@macro digest_auth_middleware} DigestAuthMiddleware({ required this.username, required this.password, @@ -47,10 +51,6 @@ class DigestAuthMiddleware MiddlewareContext context, MiddlewareRequest request, ) async { - print( - '${getName()}::OnRequest\n' - '>> Digest ready: ${_digestAuth.isReady()}', - ); if (_digestAuth.isReady()) { final mutation = { authenticationHeader: _digestAuth.getAuthString( @@ -82,10 +82,6 @@ class DigestAuthMiddleware return MiddlewareResponse(httpResponse: newResponse); } } - print( - '${getName()}::OnResponse\n' - '>> Digest ready: ${_digestAuth.isReady()}', - ); return response; } } diff --git a/packages/wyatt_http_client/lib/src/middlewares/middlewares.dart b/packages/wyatt_http_client/lib/src/middlewares/middlewares.dart index 9c2b70b0..29bbf147 100644 --- a/packages/wyatt_http_client/lib/src/middlewares/middlewares.dart +++ b/packages/wyatt_http_client/lib/src/middlewares/middlewares.dart @@ -14,7 +14,8 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . -export 'access_token_auth_middleware.dart'; +// All built-in middlewares + export 'basic_auth_middleware.dart'; export 'body_to_json_middleware.dart'; export 'default_middleware.dart'; diff --git a/packages/wyatt_http_client/lib/src/middlewares/refresh_token_auth_middleware.dart b/packages/wyatt_http_client/lib/src/middlewares/refresh_token_auth_middleware.dart index 19f3f137..50f5005d 100644 --- a/packages/wyatt_http_client/lib/src/middlewares/refresh_token_auth_middleware.dart +++ b/packages/wyatt_http_client/lib/src/middlewares/refresh_token_auth_middleware.dart @@ -28,9 +28,14 @@ import 'package:wyatt_http_client/src/utils/http_status.dart'; typedef TokenParser = String Function(Map); +/// {@template refresh_token_auth_middleware} +/// A middleware that refreshes the access token when it expires. +/// This middleware is useful for OAuth2. +/// {@endtemplate} class RefreshTokenAuthMiddleware with OnRequestMiddleware, OnResponseMiddleware implements Middleware { + /// {@macro refresh_token_auth_middleware} RefreshTokenAuthMiddleware({ required this.authorizationEndpoint, required this.tokenEndpoint, @@ -113,11 +118,6 @@ class RefreshTokenAuthMiddleware MiddlewareContext context, MiddlewareRequest request, ) async { - print( - '${getName()}::OnRequest\n' - '>> accessToken: $accessToken\n' - '>> refreshToken: $refreshToken', - ); // Check if it is authorization if (context.originalRequest?.url == Uri.parse(authorizationEndpoint)) { return request; @@ -168,12 +168,6 @@ class RefreshTokenAuthMiddleware } } - print( - '${getName()}::OnResponse\n' - '>> accessToken: $accessToken\n' - '>> refreshToken: $refreshToken', - ); - if (response.status == unauthorized) { // Refresh MiddlewareRequest? newRequest = await refresh(context); diff --git a/packages/wyatt_http_client/lib/src/middlewares/simple_logger_middleware.dart b/packages/wyatt_http_client/lib/src/middlewares/simple_logger_middleware.dart index 8e2d2637..31492b8f 100644 --- a/packages/wyatt_http_client/lib/src/middlewares/simple_logger_middleware.dart +++ b/packages/wyatt_http_client/lib/src/middlewares/simple_logger_middleware.dart @@ -19,9 +19,15 @@ import 'package:wyatt_http_client/src/models/middleware_context.dart'; import 'package:wyatt_http_client/src/models/middleware_request.dart'; import 'package:wyatt_http_client/src/models/middleware_response.dart'; +/// {@template simple_logger_middleware} +/// A simple logger middleware that logs the request and response. +/// {@endtemplate} class SimpleLoggerMiddleware with OnRequestMiddleware, OnResponseMiddleware implements Middleware { + /// {@macro simple_logger_middleware} + const SimpleLoggerMiddleware(); + @override String getName() => 'SimpleLogger'; @@ -30,11 +36,22 @@ class SimpleLoggerMiddleware MiddlewareContext context, MiddlewareRequest request, ) async { - print( - '${getName()}::OnRequest\n' - '>> ${request.method} ${request.url}\n' - '>> Headers: ${request.headers}\n>> Body: ${request.encodedBody}', - ); + final log = StringBuffer() + ..writeln('${getName()}::OnRequest') + ..writeln('>> ${request.method} ${request.url}'); + if (request.headers.isNotEmpty) { + log.writeln('>> Headers:'); + request.headers.forEach((key, value) { + log.writeln('>> $key: $value'); + }); + } + if (request.encodedBody.isNotEmpty) { + log + ..writeln('>> Body:') + ..writeln(request.encodedBody); + } + print(log); + return request; } @@ -43,12 +60,13 @@ class SimpleLoggerMiddleware MiddlewareContext context, MiddlewareResponse response, ) async { - print( - '${getName()}::OnResponse\n' - '>> Status: ${response.status.name.toUpperCase()}\n' - '>> Length: ${response.contentLength ?? '0'} bytes', - // '>> Body: ${response.body}', - ); + final log = StringBuffer() + ..writeln('${getName()}::OnResponse') + ..writeln('>> Status: ${response.status.name.toUpperCase()}') + ..writeln('>> Length: ${response.contentLength ?? '0'} bytes'); + + print(log); + return response; } } diff --git a/packages/wyatt_http_client/lib/src/middlewares/unsafe_auth_middleware.dart b/packages/wyatt_http_client/lib/src/middlewares/unsafe_auth_middleware.dart index 724d7211..f4481877 100644 --- a/packages/wyatt_http_client/lib/src/middlewares/unsafe_auth_middleware.dart +++ b/packages/wyatt_http_client/lib/src/middlewares/unsafe_auth_middleware.dart @@ -19,15 +19,20 @@ import 'package:wyatt_http_client/src/models/middleware_context.dart'; import 'package:wyatt_http_client/src/models/middleware_request.dart'; import 'package:wyatt_http_client/src/utils/convert.dart'; +/// {@template unsafe_auth_middleware} +/// A middleware that appends the username and password to the URL. +/// +/// This is not recommended to use in production. +/// {@endtemplate} class UnsafeAuthMiddleware with OnRequestMiddleware implements Middleware { - UnsafeAuthMiddleware({ + const UnsafeAuthMiddleware({ this.username, this.password, this.usernameField = 'username', this.passwordField = 'password', }); - String? username; - String? password; + final String? username; + final String? password; final String usernameField; final String passwordField; @@ -45,10 +50,6 @@ class UnsafeAuthMiddleware with OnRequestMiddleware implements Middleware { } final Uri uri = request.url + '?$usernameField=$username&$passwordField=$password'; - print( - '${getName()}::OnRequest\n' - '>> Append: ?$usernameField=$username&$passwordField=$password', - ); request.modifyRequest(request.unfreezedRequest.copyWith(url: uri)); return request; } diff --git a/packages/wyatt_http_client/lib/src/middlewares/uri_prefix_middleware.dart b/packages/wyatt_http_client/lib/src/middlewares/uri_prefix_middleware.dart index 04c3232f..f02cff99 100644 --- a/packages/wyatt_http_client/lib/src/middlewares/uri_prefix_middleware.dart +++ b/packages/wyatt_http_client/lib/src/middlewares/uri_prefix_middleware.dart @@ -19,12 +19,20 @@ import 'package:wyatt_http_client/src/models/middleware_context.dart'; import 'package:wyatt_http_client/src/models/middleware_request.dart'; import 'package:wyatt_http_client/src/utils/protocols.dart'; +/// {@template uri_prefix_middleware} +/// A middleware that adds a prefix to the request's URI. +/// {@endtemplate} class UriPrefixMiddleware with OnRequestMiddleware implements Middleware { - UriPrefixMiddleware({ + /// {@macro uri_prefix_middleware} + const UriPrefixMiddleware({ required this.protocol, required this.authority, }); + + /// The protocol of the prefix. final Protocols protocol; + + /// The authority of the prefix. final String? authority; @override @@ -36,11 +44,6 @@ class UriPrefixMiddleware with OnRequestMiddleware implements Middleware { MiddlewareRequest request, ) async { final Uri uri = Uri.parse('${protocol.scheme}$authority${request.url}'); - print( - '${getName()}::OnRequest\n' - '>> From: ${request.url}\n' - '>> To: $uri', - ); request.modifyRequest(request.unfreezedRequest.copyWith(url: uri)); return request; } diff --git a/packages/wyatt_http_client/lib/src/models/middleware_context.dart b/packages/wyatt_http_client/lib/src/models/middleware_context.dart index 503c2e3e..5071b39e 100644 --- a/packages/wyatt_http_client/lib/src/models/middleware_context.dart +++ b/packages/wyatt_http_client/lib/src/models/middleware_context.dart @@ -1,4 +1,3 @@ -// ignore_for_file: public_member_api_docs, sort_constructors_first // Copyright (C) 2022 WYATT GROUP // Please see the AUTHORS file for details. // @@ -20,15 +19,12 @@ import 'package:wyatt_http_client/src/models/middleware_request.dart'; import 'package:wyatt_http_client/src/models/middleware_response.dart'; import 'package:wyatt_http_client/src/pipeline.dart'; +/// {@template middleware_context} +/// A class that contains the context of the middleware. +/// {@endtemplate} class MiddlewareContext { - Pipeline pipeline; - MiddlewareClient client; - MiddlewareRequest? originalRequest; - MiddlewareRequest? lastRequest; - MiddlewareResponse? originalResponse; - MiddlewareResponse? lastResponse; - - MiddlewareContext({ + /// {@macro middleware_context} + const MiddlewareContext({ required this.pipeline, required this.client, this.originalRequest, @@ -37,6 +33,26 @@ class MiddlewareContext { this.lastResponse, }); + /// The pipeline that the middleware is in. + final Pipeline pipeline; + + /// The client that the middleware is in. + final MiddlewareClient client; + + /// The original request that the middleware is in. + final MiddlewareRequest? originalRequest; + + /// The last request that the middleware is in. + final MiddlewareRequest? lastRequest; + + /// The original response that the middleware is in. + final MiddlewareResponse? originalResponse; + + /// The last response that the middleware is in. + final MiddlewareResponse? lastResponse; + + /// Create a copy of this [MiddlewareContext] with the given fields replaced + /// with the new values. MiddlewareContext copyWith({ Pipeline? pipeline, MiddlewareClient? client, diff --git a/packages/wyatt_http_client/lib/src/models/middleware_request.dart b/packages/wyatt_http_client/lib/src/models/middleware_request.dart index 333d3177..e7c93703 100644 --- a/packages/wyatt_http_client/lib/src/models/middleware_request.dart +++ b/packages/wyatt_http_client/lib/src/models/middleware_request.dart @@ -1,4 +1,3 @@ -// ignore_for_file: public_member_api_docs, sort_constructors_first // Copyright (C) 2022 WYATT GROUP // Please see the AUTHORS file for details. // @@ -22,24 +21,43 @@ import 'package:wyatt_http_client/src/models/unfreezed_request.dart'; import 'package:wyatt_http_client/src/utils/convert.dart'; import 'package:wyatt_http_client/src/utils/request_utils.dart'; +/// {@template middleware_request} +/// A class that represents a middleware request. +/// {@endtemplate} class MiddlewareRequest { - UnfreezedRequest unfreezedRequest; - Request _httpRequest; - - Request get request => _httpRequest; - - // Proxy - String get method => _httpRequest.method; - Uri get url => _httpRequest.url; - Map get headers => _httpRequest.headers; - Encoding get encoding => _httpRequest.encoding; - String get encodedBody => _httpRequest.body; - Object? get body => unfreezedRequest.body; - + /// {@macro middleware_request} MiddlewareRequest({ required this.unfreezedRequest, }) : _httpRequest = Request(unfreezedRequest.method, unfreezedRequest.url); + /// The unfreezed request. + UnfreezedRequest unfreezedRequest; + + Request _httpRequest; + + /// The http request. (Read-only) + Request get request => _httpRequest; + + /// The request method (proxy, read-only). + String get method => _httpRequest.method; + + /// The request url (proxy, read-only). + Uri get url => _httpRequest.url; + + /// The request headers (proxy, read-only). + Map get headers => _httpRequest.headers; + + /// The request body (proxy, read-only). + Encoding get encoding => _httpRequest.encoding; + + /// The request body (proxy, read-only). + String get encodedBody => _httpRequest.body; + + /// The request body (proxy, read-only). + Object? get body => unfreezedRequest.body; + + /// Copies this request and returns a new request with the given + /// [unfreezedRequest]. MiddlewareRequest copyWith({ UnfreezedRequest? unfreezedRequest, }) => @@ -47,6 +65,7 @@ class MiddlewareRequest { unfreezedRequest: unfreezedRequest ?? this.unfreezedRequest, ); + /// Modifies the request with the given [unfreezedRequest]. void modifyRequest(UnfreezedRequest unfreezedRequest) { String? body; if (unfreezedRequest.body != null) { @@ -72,6 +91,8 @@ class MiddlewareRequest { this.unfreezedRequest = unfreezedRequest; } + /// Applies the changes made to the request by modifying it with the + /// [unfreezedRequest]. void apply() { modifyRequest(unfreezedRequest); } diff --git a/packages/wyatt_http_client/lib/src/models/middleware_response.dart b/packages/wyatt_http_client/lib/src/models/middleware_response.dart index 500c17c3..19781901 100644 --- a/packages/wyatt_http_client/lib/src/models/middleware_response.dart +++ b/packages/wyatt_http_client/lib/src/models/middleware_response.dart @@ -1,4 +1,3 @@ -// ignore_for_file: public_member_api_docs, sort_constructors_first // Copyright (C) 2022 WYATT GROUP // Please see the AUTHORS file for details. // @@ -18,12 +17,25 @@ import 'package:http/http.dart'; import 'package:wyatt_http_client/src/utils/http_status.dart'; +/// {@template middleware_response} +/// A class that represents a middleware response. +/// {@endtemplate} class MiddlewareResponse { - BaseResponse httpResponse; + /// {@macro middleware_response} + const MiddlewareResponse({ + required this.httpResponse, + }); - // Proxy + /// {@macro middleware_response} + final BaseResponse httpResponse; + + /// The status code of the response. (proxy) int get statusCode => httpResponse.statusCode; + + /// The status of the response. (proxy) HttpStatus get status => HttpStatus.from(statusCode); + + /// The body of the response. (proxy or empty string) String get body { if (httpResponse is Response) { return (httpResponse as Response).body; @@ -32,13 +44,13 @@ class MiddlewareResponse { } } + /// The content length of the response. (proxy) int? get contentLength => httpResponse.contentLength; + + /// The headers of the response. (proxy) Map get headers => httpResponse.headers; - MiddlewareResponse({ - required this.httpResponse, - }); - + /// Returns a copy of this response with the given [httpResponse]. MiddlewareResponse copyWith({ BaseResponse? httpResponse, }) => diff --git a/packages/wyatt_http_client/lib/src/models/unfreezed_request.dart b/packages/wyatt_http_client/lib/src/models/unfreezed_request.dart index d29c15d8..6779a5b6 100644 --- a/packages/wyatt_http_client/lib/src/models/unfreezed_request.dart +++ b/packages/wyatt_http_client/lib/src/models/unfreezed_request.dart @@ -16,20 +16,38 @@ import 'dart:convert'; +/// {@template unfreezed_request} +/// A class that represents an unfreezed request. +/// It is used to unfreeze a Request object, and allows you to +/// modify the request before sending it. +/// {@endtemplate} class UnfreezedRequest { - UnfreezedRequest({ + /// {@macro unfreezed_request} + const UnfreezedRequest({ required this.method, required this.url, this.headers, this.body, this.encoding, }); + + /// The request method. final String method; + + /// The request url. final Uri url; + + /// The request headers. final Map? headers; + + /// The request body. final Object? body; + + /// The request encoding. final Encoding? encoding; + /// Copies this request and returns a new request with the given [method], + /// [url], [headers], [body] and [encoding]. UnfreezedRequest copyWith({ String? method, Uri? url, diff --git a/packages/wyatt_http_client/lib/src/pipeline.dart b/packages/wyatt_http_client/lib/src/pipeline.dart index 3cebc400..7e1c2900 100644 --- a/packages/wyatt_http_client/lib/src/pipeline.dart +++ b/packages/wyatt_http_client/lib/src/pipeline.dart @@ -19,20 +19,27 @@ import 'package:wyatt_http_client/src/models/middleware_context.dart'; import 'package:wyatt_http_client/src/models/middleware_request.dart'; import 'package:wyatt_http_client/src/models/middleware_response.dart'; +/// {@template pipeline} +/// A [Pipeline] is a list of [Middleware]s that are executed in order. +/// {@endtemplate} class Pipeline { + /// {@macro pipeline} Pipeline() : _middlewares = []; + + /// {@macro pipeline} Pipeline.fromIterable(Iterable middlewares) : _middlewares = middlewares.toList(); + final List _middlewares; + /// The length of the [Pipeline]. + /// + /// This is the number of [Middleware]s in the [Pipeline]. int get length => _middlewares.length; /// Add a [Middleware] to this [Pipeline] - Pipeline addMiddleware(Middleware middleware) { + void addMiddleware(Middleware middleware) { _middlewares.add(middleware); - // TODO(hpcl): use Dart cascades instead of returning this - // ignore: avoid_returning_this - return this; } /// Create new [Pipeline] from the start or end to a specified [Middleware]. @@ -57,11 +64,15 @@ class Pipeline { return Pipeline.fromIterable(fromEnd ? nodes.reversed : nodes); } + /// Call the [onRequest] method of all [OnRequestMiddleware]s in the + /// [Pipeline]. + /// + /// The [MiddlewareRequest] returned by the last [OnRequestMiddleware] is + /// returned. Future onRequest( MiddlewareContext context, MiddlewareRequest request, ) async { - print('\n\nNEW REQUEST\n'); MiddlewareRequest req = request..apply(); MiddlewareContext ctx = context.copyWith(lastRequest: req); for (final middleware in _middlewares) { @@ -73,11 +84,15 @@ class Pipeline { return req; } + /// Call the [onResponse] method of all [OnResponseMiddleware]s in the + /// [Pipeline]. + /// + /// The [MiddlewareResponse] returned by the last [OnResponseMiddleware] is + /// returned. Future onResponse( MiddlewareContext context, MiddlewareResponse response, ) async { - print('\n\nNEW RESPONSE\n'); MiddlewareResponse res = response; MiddlewareContext ctx = context.copyWith(lastResponse: res); for (final middleware in _middlewares.reversed) { diff --git a/packages/wyatt_http_client/lib/src/utils/authentication_methods.dart b/packages/wyatt_http_client/lib/src/utils/authentication_methods.dart index ef73c15f..d8f028c2 100644 --- a/packages/wyatt_http_client/lib/src/utils/authentication_methods.dart +++ b/packages/wyatt_http_client/lib/src/utils/authentication_methods.dart @@ -14,8 +14,14 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . +/// Defines some authentication methods abstract class AuthenticationMethods { + /// The `Basic` authentication method. static const String basic = 'Basic'; + + /// The `Bearer` authentication method. static const String bearer = 'Bearer'; + + /// The `Digest` authentication method. static const String digest = 'Digest'; } diff --git a/packages/wyatt_http_client/lib/src/utils/convert.dart b/packages/wyatt_http_client/lib/src/utils/convert.dart index 1f287757..93c86d59 100644 --- a/packages/wyatt_http_client/lib/src/utils/convert.dart +++ b/packages/wyatt_http_client/lib/src/utils/convert.dart @@ -16,7 +16,11 @@ import 'dart:convert'; -class Convert { +/// Defines some convert functions. +abstract class Convert { + /// Converts a list of bytes to a hex string. + /// + /// If [upperCase] is `true`, the hex string will be in uppercase. static String toHex(List bytes, {bool upperCase = false}) { final buffer = StringBuffer(); for (final int part in bytes) { @@ -32,6 +36,11 @@ class Convert { } } + /// Converts a map to a query string. + /// + /// If [encoding] is `null`, the default encoding is `utf8`. + /// + /// For example, the map `{a: 1, b: 2}` will be converted to `a=1&b=2`. static String mapToQuery(Map map, {Encoding? encoding}) { final pairs = >[]; map.forEach( @@ -45,6 +54,7 @@ class Convert { } extension UriX on Uri { + /// Returns a new [Uri] by appending the given [path] to this [Uri]. Uri operator +(String path) { final thisPath = toString(); return Uri.parse(thisPath + path); diff --git a/packages/wyatt_http_client/lib/src/utils/crypto.dart b/packages/wyatt_http_client/lib/src/utils/crypto.dart index f27d08a7..bf7fa5a6 100644 --- a/packages/wyatt_http_client/lib/src/utils/crypto.dart +++ b/packages/wyatt_http_client/lib/src/utils/crypto.dart @@ -18,7 +18,8 @@ import 'dart:convert'; import 'package:crypto/crypto.dart'; -class Crypto { +/// Defines some crypto functions. +abstract class Crypto { /// Hash a string using MD5 static String md5Hash(String data) { final content = const Utf8Encoder().convert(data); diff --git a/packages/wyatt_http_client/lib/src/utils/delay.dart b/packages/wyatt_http_client/lib/src/utils/delay.dart index 3ca50947..cc9d4193 100644 --- a/packages/wyatt_http_client/lib/src/utils/delay.dart +++ b/packages/wyatt_http_client/lib/src/utils/delay.dart @@ -17,7 +17,9 @@ import 'dart:core'; import 'dart:math'; +/// Defines some delay functions. abstract class Delay { + /// Returns a delay based on the [attempt]. static Duration getRetryDelay(int attempt) { assert(attempt >= 0, 'attempt cannot be negative'); if (attempt <= 0) { diff --git a/packages/wyatt_http_client/lib/src/utils/digest_auth.dart b/packages/wyatt_http_client/lib/src/utils/digest_auth.dart index ba16c0aa..065eeef0 100644 --- a/packages/wyatt_http_client/lib/src/utils/digest_auth.dart +++ b/packages/wyatt_http_client/lib/src/utils/digest_auth.dart @@ -19,12 +19,13 @@ import 'dart:math'; import 'package:wyatt_http_client/src/utils/convert.dart'; import 'package:wyatt_http_client/src/utils/crypto.dart'; +/// A class for digest authentication. class DigestAuth { // request counter DigestAuth(this.username, this.password); - String username; - String password; + final String username; + final String password; // must get from first response String? _algorithm; diff --git a/packages/wyatt_http_client/lib/src/utils/header_keys.dart b/packages/wyatt_http_client/lib/src/utils/header_keys.dart index 9fe72ce8..c1c9e986 100644 --- a/packages/wyatt_http_client/lib/src/utils/header_keys.dart +++ b/packages/wyatt_http_client/lib/src/utils/header_keys.dart @@ -14,8 +14,14 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . +/// Defines some header keys. abstract class HeaderKeys { + /// The `Authorization` header key. static const String authorization = 'Authorization'; + + /// The `WWW-Authenticate` header key. static const String wwwAuthenticate = 'WWW-Authenticate'; + + /// The `Content-Type` header key. static const String contentType = 'Content-Type'; } diff --git a/packages/wyatt_http_client/lib/src/utils/http_methods.dart b/packages/wyatt_http_client/lib/src/utils/http_methods.dart index 7b0a4c7a..efef38c4 100644 --- a/packages/wyatt_http_client/lib/src/utils/http_methods.dart +++ b/packages/wyatt_http_client/lib/src/utils/http_methods.dart @@ -14,6 +14,7 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . +/// Defines http verb methods. enum HttpMethods { head('HEAD'), get('GET'), @@ -24,5 +25,8 @@ enum HttpMethods { const HttpMethods(this.method); + /// Returns the method of the http verb. + /// + /// For example, the method of [HttpMethods.get] is `GET`. final String method; } diff --git a/packages/wyatt_http_client/lib/src/utils/http_status.dart b/packages/wyatt_http_client/lib/src/utils/http_status.dart index e5360309..f5a5c488 100644 --- a/packages/wyatt_http_client/lib/src/utils/http_status.dart +++ b/packages/wyatt_http_client/lib/src/utils/http_status.dart @@ -83,6 +83,7 @@ enum HttpStatus { const HttpStatus(this.statusCode); + /// Returns the [HttpStatus] with the given [statusCode]. factory HttpStatus.from(int status) => HttpStatus.values.firstWhere((element) => element.statusCode == status); @@ -98,13 +99,18 @@ enum HttpStatus { return false; } + /// Checks if the status code is in the range of 100-199. bool isInfo() => statusCode >= 100 && statusCode < 200; + /// Checks if the status code is in the range of 200-299. bool isSuccess() => statusCode >= 200 && statusCode < 300; + /// Checks if the status code is in the range of 300-399. bool isRedirection() => statusCode >= 300 && statusCode < 400; + /// Checks if the status code is in the range of 400-499. bool isClientError() => statusCode >= 400 && statusCode < 500; + /// Checks if the status code is in the range of 500-599. bool isServerError() => statusCode >= 500 && statusCode < 600; } diff --git a/packages/wyatt_http_client/lib/src/utils/protocols.dart b/packages/wyatt_http_client/lib/src/utils/protocols.dart index 97b9d5f3..bf41a5d6 100644 --- a/packages/wyatt_http_client/lib/src/utils/protocols.dart +++ b/packages/wyatt_http_client/lib/src/utils/protocols.dart @@ -14,9 +14,13 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . +/// Defines few protocols enum Protocols { http, https; + /// Returns the scheme of the protocol. + /// + /// For example, the scheme of [Protocols.http] is `http://`. String get scheme => '$name://'; } diff --git a/packages/wyatt_http_client/lib/src/utils/request_utils.dart b/packages/wyatt_http_client/lib/src/utils/request_utils.dart index b50c0063..01794757 100644 --- a/packages/wyatt_http_client/lib/src/utils/request_utils.dart +++ b/packages/wyatt_http_client/lib/src/utils/request_utils.dart @@ -16,6 +16,7 @@ import 'package:http/http.dart'; +/// Defines some request utils. abstract class RequestUtils { static Request _copyNormalRequestWith( Request original, { @@ -38,6 +39,9 @@ abstract class RequestUtils { return request; } + /// Copies the given [original] request and returns a new request with the + /// given [method], [url], [headers], [maxRedirects], [followRedirects], + /// [persistentConnection] and [body]. static BaseRequest copyRequestWith( BaseRequest original, { String? method, @@ -77,6 +81,8 @@ abstract class RequestUtils { return request; } + /// Copies the given [original] request and returns a new request. + /// This method is useful when you want to modify the request static BaseRequest copyRequest(BaseRequest original) { if (original is Request) { return _copyNormalRequest(original); diff --git a/packages/wyatt_http_client/pubspec.yaml b/packages/wyatt_http_client/pubspec.yaml index 699732db..357e00a8 100644 --- a/packages/wyatt_http_client/pubspec.yaml +++ b/packages/wyatt_http_client/pubspec.yaml @@ -3,6 +3,8 @@ description: A Dart client for RESTful APIs with authentication. repository: https://git.wyatt-studio.fr/Wyatt-FOSS/wyatt-packages/src/branch/master/packages/wyatt_http_client version: 1.2.0 +publish_to: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub + environment: sdk: '>=2.17.0 <3.0.0' @@ -12,7 +14,5 @@ dependencies: dev_dependencies: wyatt_analysis: - git: - url: https://git.wyatt-studio.fr/Wyatt-FOSS/wyatt-packages - ref: wyatt_analysis-v2.4.1 - path: packages/wyatt_analysis + hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub + version: ^2.4.1 -- 2.47.2 From 95c492e977640bab67e15438201f5dc6717a4483 Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Thu, 13 Apr 2023 22:01:23 +0200 Subject: [PATCH 38/47] style: update some analysis files --- .../wyatt_architecture/analysis_options.yaml | 14 +++++-------- .../wyatt_bloc_helper/analysis_options.yaml | 3 --- .../wyatt_crud_bloc/analysis_options.yaml | 3 --- packages/wyatt_crud_bloc/pubspec.yaml | 4 ++-- packages/wyatt_i18n/README.md | 2 +- packages/wyatt_i18n/analysis_options.yaml | 1 + packages/wyatt_i18n/pubspec.yaml | 20 +++++++++---------- 7 files changed, 18 insertions(+), 29 deletions(-) diff --git a/packages/wyatt_architecture/analysis_options.yaml b/packages/wyatt_architecture/analysis_options.yaml index 9f5b6860..53aca98a 100644 --- a/packages/wyatt_architecture/analysis_options.yaml +++ b/packages/wyatt_architecture/analysis_options.yaml @@ -1,21 +1,17 @@ -# Copyright (C) 2022 WYATT GROUP +# Copyright (C) 2023 WYATT GROUP # Please see the AUTHORS file for details. -# +# # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # any later version. -# +# # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. -# +# # You should have received a copy of the GNU General Public License # along with this program. If not, see . - -include: package:wyatt_analysis/analysis_options.flutter.yaml - -analyzer: - exclude: "!example/**" +include: package:wyatt_analysis/analysis_options.yaml diff --git a/packages/wyatt_bloc_helper/analysis_options.yaml b/packages/wyatt_bloc_helper/analysis_options.yaml index b0c6aced..8c9daa4e 100644 --- a/packages/wyatt_bloc_helper/analysis_options.yaml +++ b/packages/wyatt_bloc_helper/analysis_options.yaml @@ -1,4 +1 @@ include: package:wyatt_analysis/analysis_options.flutter.yaml - -analyzer: - exclude: "!example/**" \ No newline at end of file diff --git a/packages/wyatt_crud_bloc/analysis_options.yaml b/packages/wyatt_crud_bloc/analysis_options.yaml index f09fbccc..8c9daa4e 100644 --- a/packages/wyatt_crud_bloc/analysis_options.yaml +++ b/packages/wyatt_crud_bloc/analysis_options.yaml @@ -1,4 +1 @@ include: package:wyatt_analysis/analysis_options.flutter.yaml - -analyzer: - exclude: "!example/**" diff --git a/packages/wyatt_crud_bloc/pubspec.yaml b/packages/wyatt_crud_bloc/pubspec.yaml index 52960c0e..09b9d2b2 100644 --- a/packages/wyatt_crud_bloc/pubspec.yaml +++ b/packages/wyatt_crud_bloc/pubspec.yaml @@ -28,5 +28,5 @@ dev_dependencies: flutter_test: { sdk: flutter } bloc_test: ^9.1.0 wyatt_analysis: - hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub/ - version: 2.4.1 + hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub + version: ^2.4.1 diff --git a/packages/wyatt_i18n/README.md b/packages/wyatt_i18n/README.md index 09cd8b61..b878a833 100644 --- a/packages/wyatt_i18n/README.md +++ b/packages/wyatt_i18n/README.md @@ -16,7 +16,7 @@ * along with this program. If not, see . --> -# Flutter - Wyatt I18n +# Wyatt I18n

Style: Wyatt Analysis diff --git a/packages/wyatt_i18n/analysis_options.yaml b/packages/wyatt_i18n/analysis_options.yaml index 265c79a8..3302c602 100644 --- a/packages/wyatt_i18n/analysis_options.yaml +++ b/packages/wyatt_i18n/analysis_options.yaml @@ -1,4 +1,5 @@ include: package:wyatt_analysis/analysis_options.flutter.yaml + analyzer: plugins: - dart_code_metrics diff --git a/packages/wyatt_i18n/pubspec.yaml b/packages/wyatt_i18n/pubspec.yaml index 23c658ea..a0336a93 100644 --- a/packages/wyatt_i18n/pubspec.yaml +++ b/packages/wyatt_i18n/pubspec.yaml @@ -1,17 +1,19 @@ name: wyatt_i18n -description: A package by wyatt studio. +description: Library to handle internationalization in Flutter apps. repository: https://git.wyatt-studio.fr/Wyatt-FOSS/wyatt-packages/src/branch/master/packages/wyatt_i18n version: 1.0.0 +publish_to: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub + environment: sdk: ">=2.19.0 <3.0.0" dependencies: collection: ^1.17.0 equatable: ^2.0.5 - flutter: {sdk: flutter} + flutter: { sdk: flutter } flutter_bloc: ^8.1.2 - flutter_localizations: {sdk: flutter} + flutter_localizations: { sdk: flutter } http: ^0.13.5 intl: ^0.17.0 path: ^1.8.0 @@ -20,26 +22,22 @@ dependencies: hosted: url: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub/ name: wyatt_architecture - version: 0.1.0+1 + version: ^0.1.0+1 wyatt_bloc_helper: hosted: url: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub/ name: wyatt_bloc_helper - version: 2.0.0 + version: ^2.0.0 wyatt_type_utils: hosted: url: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub/ name: wyatt_type_utils - version: 0.0.4 + version: ^0.0.4 yaml: ^3.1.1 dev_dependencies: - flutter_test: {sdk: flutter} + flutter_test: { sdk: flutter } dart_code_metrics: ^5.5.1 wyatt_analysis: hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub version: ^2.4.1 - -# The following section is specific to Flutter. -flutter: - uses-material-design: true -- 2.47.2 From 7606d26aac554d277a6f8af2e90b947c6df4ffae Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Thu, 13 Apr 2023 22:01:36 +0200 Subject: [PATCH 39/47] docs(http): add simple example --- .../wyatt_http_client/example/example.dart | 78 +++++++++++++++++++ 1 file changed, 78 insertions(+) create mode 100644 packages/wyatt_http_client/example/example.dart diff --git a/packages/wyatt_http_client/example/example.dart b/packages/wyatt_http_client/example/example.dart new file mode 100644 index 00000000..a5c529ea --- /dev/null +++ b/packages/wyatt_http_client/example/example.dart @@ -0,0 +1,78 @@ +// Copyright (C) 2023 WYATT GROUP +// Please see the AUTHORS file for details. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +import 'package:wyatt_http_client/wyatt_http_client.dart'; + +Future testSimpleGet() async { + print('testSimpleGet'); + final pipeline = Pipeline() + ..addMiddleware(const BodyToJsonMiddleware()) + ..addMiddleware(const SimpleLoggerMiddleware()); + + final client = MiddlewareClient(pipeline: pipeline); + + final response = await client + .get(Uri.parse('https://jsonplaceholder.typicode.com/todos/1')); + print(response.body); +} + +Future testUriPrefix() async { + print('testUriPrefix'); + final pipeline = Pipeline() + ..addMiddleware( + const UriPrefixMiddleware( + protocol: Protocols.https, + authority: 'jsonplaceholder.typicode.com', + ), + ) + ..addMiddleware(const BodyToJsonMiddleware()) + ..addMiddleware(const SimpleLoggerMiddleware()); + + final client = MiddlewareClient(pipeline: pipeline); + + final response = await client.get(Uri.parse('/todos/1')); + print(response.body); +} + +Future testBasicAuth() async { + print('testBasicAuth'); + final pipeline = Pipeline() + ..addMiddleware( + const BasicAuthMiddleware( + username: 'guest', + password: 'guest', + ), + ) + ..addMiddleware(const BodyToJsonMiddleware()) + ..addMiddleware(const SimpleLoggerMiddleware()); + + final client = MiddlewareClient(pipeline: pipeline); + + final response = + await client.get(Uri.parse('https://jigsaw.w3.org/HTTP/Basic/')); + + if (HttpStatus.from(response.statusCode).isSuccess()) { + print("🎉 You're in!"); + } else { + print("⭕️ Nope, you're not in."); + } +} + +void main(List args) { + testSimpleGet(); + testUriPrefix(); + testBasicAuth(); +} -- 2.47.2 From 5fe8d84cf67e245d91454888e68986cc6b627846 Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Thu, 13 Apr 2023 22:01:56 +0200 Subject: [PATCH 40/47] docs(component_copy_with): add some documentation --- .../README.md | 50 ++++++++++++------- .../analysis_options.yaml | 2 +- .../src/component_copy_with_extension.dart | 24 ++++++++- .../lib/src/component_proxy_extension.dart | 32 +++++++++--- .../lib/src/domain/component_annotation.dart | 4 ++ .../pubspec.yaml | 7 +-- .../wyatt_component_copy_with_gen/README.md | 24 +++++---- .../pubspec.yaml | 8 ++- 8 files changed, 104 insertions(+), 47 deletions(-) diff --git a/packages/wyatt_component_copy_with_extension/README.md b/packages/wyatt_component_copy_with_extension/README.md index 3ef1d24d..4dd5beaf 100644 --- a/packages/wyatt_component_copy_with_extension/README.md +++ b/packages/wyatt_component_copy_with_extension/README.md @@ -7,7 +7,7 @@ * the Free Software Foundation, either version 3 of the License, or * any later version. * - * This program is distributed in the hope that it will be useful, + * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. @@ -16,15 +16,32 @@ * along with this program. If not, see . --> -# Flutter - Component Copy With Extension +# Component Copy With Extension

Style: Wyatt Analysis - SDK: Flutter + SDK: Dart & Flutter

This package provides annotations for generating code and simplifying the use of an UI kit within a Flutter application. **The package contains only the annotation classes**. +> This package does not contain Flutter specific code, but there is no sense in using it without Flutter. + +## Summary + +* `ComponentProxyExtension` - Annotation class for generating a proxy of a component of an UI kit. +* `ComponentCopyWithExtension` - Annotation class for generating the copyWith method of a component implementation. + +For example, let's say we have a component of an UI kit that we want to use in our application. + +1) We create the component in the `wyatt_ui_components` , add the `ComponentProxyExtension` annotation and generate the code. This component does not have any specific implementation, and only have a set of properties. +2) Now we implement the component in our ui kit, `wyatt_ui_kit` , add the `ComponentCopyWithExtension` annotation and generate the code. This component has a specific implementation and can be used in the application. +3) But we can implement multiple ui kits, and each of them can have their own implementation of the same component. And at the top of the application tree we can use the `wyatt_ui_components` package, which contains only the proxy of the component. + +> In that way, the **application is UI kit agnostic**, and we can easily change the UI kit without changing the code of the application. + +We will use the `LoaderComponent` component as an example in this documentation. + ## Annotation Classes #### `ComponentProxyExtension` @@ -32,31 +49,30 @@ This package provides annotations for generating code and simplifying the use of This annotation class is used to annotate a new component of an UI kit in the `wyatt_ui_components` package. It generates the abstract proxy of the component and allows access to all its properties in different packages and throughout the application. ```dart -part 'text_field_component.g.dart'; +part 'loader_component.g.dart'; @ComponentProxyExtension() -abstract class TextFieldComponent extends Component { - with CopyWithMixin<$TextFieldComponentCWProxy> { - - const TextFieldComponent({ - ... +abstract class LoaderComponent extends Component + with CopyWithMixin<$LoaderComponentCWProxy> { + + const LoaderComponent({ + ... }); } ``` #### `ComponentCopyWithExtension` -This annotation class is used to annotate the implementation of components directly in the application. It generates the implementation of the proxy and the mixin to ensure that the component meets the specifications defined in the `wyatt_ui_components package`. +This annotation class is used to annotate the implementation of components directly in the application. It generates the implementation of the proxy and the mixin to ensure that the component meets the specifications defined in the `wyatt_ui_components package` . ```dart -part 'text_field_component.g.dart'; +part 'loader.g.dart'; -@ComponentProxyExtension() -abstract class TextFieldComponent extends Component { - with CopyWithMixin<$TextFieldComponentCWProxy> { - - const TextFieldComponent({ - ... +@ComponentCopyWithExtension() +class Loader extends LoaderComponent with $LoaderCWMixin { + + const Loader({ + ... }); } ``` diff --git a/packages/wyatt_component_copy_with_extension/analysis_options.yaml b/packages/wyatt_component_copy_with_extension/analysis_options.yaml index 0939257e..1c320a71 100644 --- a/packages/wyatt_component_copy_with_extension/analysis_options.yaml +++ b/packages/wyatt_component_copy_with_extension/analysis_options.yaml @@ -1,5 +1,5 @@ -include: package:wyatt_analysis/analysis_options.flutter.yaml +include: package:wyatt_analysis/analysis_options.yaml diff --git a/packages/wyatt_component_copy_with_extension/lib/src/component_copy_with_extension.dart b/packages/wyatt_component_copy_with_extension/lib/src/component_copy_with_extension.dart index 482b1748..a71e23bf 100644 --- a/packages/wyatt_component_copy_with_extension/lib/src/component_copy_with_extension.dart +++ b/packages/wyatt_component_copy_with_extension/lib/src/component_copy_with_extension.dart @@ -17,9 +17,29 @@ import 'package:meta/meta_meta.dart'; import 'package:wyatt_component_copy_with_extension/component_copy_with_extension.dart'; -/// Annotation used to indicate that the `copyWith` extension -/// should be generated for the compononent. +/// {@template component_copy_with_extension} +/// This annotation class is used to annotate the implementation of components +/// directly in the application. It generates the implementation of the proxy +/// and the mixin to ensure that the component meets the specifications +/// defined in the UI Kit. +/// +/// Basically it indicate that the `copyWith` extension +/// should be generated for the component. +/// +/// ```dart +/// part 'loader.g.dart'; +/// +/// @ComponentCopyWithExtension() +/// class Loader extends LoaderComponent with $LoaderCWMixin { +/// +/// const Loader({ +/// ... +/// }); +/// } +/// ``` +/// {@endtemplate} @Target({TargetKind.classType}) class ComponentCopyWithExtension extends ComponentAnnotation { + /// {@macro component_copy_with_extension} const ComponentCopyWithExtension({super.skipFields}); } diff --git a/packages/wyatt_component_copy_with_extension/lib/src/component_proxy_extension.dart b/packages/wyatt_component_copy_with_extension/lib/src/component_proxy_extension.dart index 3e75eef5..d34ac82c 100644 --- a/packages/wyatt_component_copy_with_extension/lib/src/component_proxy_extension.dart +++ b/packages/wyatt_component_copy_with_extension/lib/src/component_proxy_extension.dart @@ -14,12 +14,32 @@ // along with this program. If not, see . import 'package:meta/meta_meta.dart'; +import 'package:wyatt_component_copy_with_extension/src/domain/component_annotation.dart'; +/// {@template component_proxy_extension} +/// This annotation class is used to annotate a new component of an UI kit. +/// It generates the abstract proxy of the component and allows access to +/// all its properties in different packages and throughout the application. +/// +/// ```dart +/// part 'loader_component.g.dart'; +/// +/// @ComponentProxyExtension() +/// abstract class LoaderComponent extends Component +/// with CopyWithMixin<$LoaderComponentCWProxy> { +/// +/// const LoaderComponent({ +/// ... +/// }); +/// } +/// ``` +/// +/// The [skipFields] option allows you to directly and specifically change +/// a field. This makes it easier to use. +/// +/// {@endtemplate} @Target({TargetKind.classType}) -class ComponentProxyExtension { - const ComponentProxyExtension({ - this.skipFields = true, - }); - - final bool? skipFields; +class ComponentProxyExtension extends ComponentAnnotation { + /// {@macro component_proxy_extension} + const ComponentProxyExtension({super.skipFields}); } diff --git a/packages/wyatt_component_copy_with_extension/lib/src/domain/component_annotation.dart b/packages/wyatt_component_copy_with_extension/lib/src/domain/component_annotation.dart index 1faf6119..4408aa19 100644 --- a/packages/wyatt_component_copy_with_extension/lib/src/domain/component_annotation.dart +++ b/packages/wyatt_component_copy_with_extension/lib/src/domain/component_annotation.dart @@ -14,7 +14,11 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . +/// {@template component_annotation} +/// Abstract class that is used as a base for all annotations +/// {@endtemplate} abstract class ComponentAnnotation { + /// {@macro component_annotation} const ComponentAnnotation({this.skipFields = true}); /// Prevent the library from generating `copyWith` functions for individual diff --git a/packages/wyatt_component_copy_with_extension/pubspec.yaml b/packages/wyatt_component_copy_with_extension/pubspec.yaml index de13dc2d..4b0375c5 100644 --- a/packages/wyatt_component_copy_with_extension/pubspec.yaml +++ b/packages/wyatt_component_copy_with_extension/pubspec.yaml @@ -3,18 +3,15 @@ description: Extension for component copy with feature. repository: https://git.wyatt-studio.fr/Wyatt-FOSS/wyatt-packages/src/branch/master/packages/component_copy_with_extension version: 1.0.0 +publish_to: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub + environment: sdk: ">=2.19.0 <3.0.0" dependencies: meta: ^1.8.0 - path: ^1.8.0 dev_dependencies: wyatt_analysis: hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub version: ^2.4.1 - -# The following section is specific to Flutter. -flutter: - uses-material-design: true diff --git a/packages/wyatt_component_copy_with_gen/README.md b/packages/wyatt_component_copy_with_gen/README.md index 6b606cd8..64e5e799 100644 --- a/packages/wyatt_component_copy_with_gen/README.md +++ b/packages/wyatt_component_copy_with_gen/README.md @@ -7,7 +7,7 @@ * the Free Software Foundation, either version 3 of the License, or * any later version. * - * This program is distributed in the hope that it will be useful, + * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. @@ -16,30 +16,32 @@ * along with this program. If not, see . --> -# Dart - Component Copy With Gen +# Component Copy With Gen

Style: Wyatt Analysis SDK: Dart & Flutter

-A Dart package for generating code from annotations to ease the use of a UIKit in Flutter applications. The generated code is based on the annotation classes present in the 'wyatt_component_copy_with_extension' package. +A Dart package for generating code from annotations to ease the use of a UIKit in Flutter applications. The generated code is based on the annotation classes present in the [ `wyatt_component_copy_with_extension` package](https://git.wyatt-studio.fr/Wyatt-FOSS/wyatt-packages/src/branch/master/packages/wyatt_component_copy_with_extension) + +> This package does not contain Flutter specific code, but there is no sense in using it without Flutter. ## Features -- Supports the generation of abstract proxies in the `wyatt_ui_components` package. -- Supports direct use in Flutter applications. +* Supports the generation of abstract proxies in the `wyatt_ui_components` package. +* Supports direct use in Flutter applications. ## Usage ### In the 'wyatt_ui_components' package -- Add the appropriate annotation when addicdng a new component. -- Run the build runner command to generate the proxy. +* Add the appropriate annotation when adding a new component. +* Run the build runner command to generate the proxy. -### In Flutter applications +### In Flutter applications (or UI Kit implementations) -- Add the following dependencies to your pubspec.yaml: +* Add the following dependencies to your pubspec.yaml: ```yaml dependencies: @@ -51,7 +53,7 @@ dev_dependencies: build_runner: ^2.3.3 ``` -- In your UIKit, extend the desired component class and add the appropriate annotation. -- Run the code generation command via the build runner. +* In your UIKit, extend the desired component class and add the appropriate annotation. +* Run the code generation command via the build runner. For further details and additional features on class annotation, see the 'wyatt_component_copy_with_extension' package's README. diff --git a/packages/wyatt_component_copy_with_gen/pubspec.yaml b/packages/wyatt_component_copy_with_gen/pubspec.yaml index bae83cb0..301cb28c 100644 --- a/packages/wyatt_component_copy_with_gen/pubspec.yaml +++ b/packages/wyatt_component_copy_with_gen/pubspec.yaml @@ -3,21 +3,19 @@ description: Generator for copywith method for components. repository: https://git.wyatt-studio.fr/Wyatt-FOSS/wyatt-packages/src/branch/master/packages/component_copy_with_gen version: 1.0.0 -publish_to: "none" +publish_to: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub environment: sdk: ">=2.19.0 <3.0.0" dependencies: - path: ^1.8.0 build: ^2.3.1 source_gen: ^1.2.7 analyzer: ^5.4.0 wyatt_component_copy_with_extension: - git: - url: ssh://git@git.wyatt-studio.fr:993/Wyatt-FOSS/wyatt-packages.git - path: packages/wyatt_component_copy_with_extension + hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub + version: ^1.0.0 dev_dependencies: test: ^1.21.0 -- 2.47.2 From afbb911a0fc70552b13d67e61e43224d3b218101 Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Thu, 13 Apr 2023 22:53:51 +0200 Subject: [PATCH 41/47] docs(ui_components): add some documentation + readme --- packages/wyatt_ui_components/README.md | 63 ++++++++++--------- .../wyatt_ui_components/analysis_options.yaml | 16 ----- .../lib/src/core/enums/status_state.dart | 1 + .../extensions/build_context_extensions.dart | 8 +++ .../lib/src/core/mixins/copy_with_mixin.dart | 3 + .../lib/src/core/utils/multi_color.dart | 16 +++++ .../lib/src/core/utils/text_wrapper.dart | 4 ++ .../lib/src/core/utils/theme_helper.dart | 1 - .../lib/src/domain/entities/component.dart | 3 + .../lib/src/domain/entities/theme_style.dart | 4 ++ .../lib/src/features/component_theme.dart | 17 +++++ .../src/features/component_theme_data.dart | 3 + .../lib/wyatt_ui_components.dart | 2 +- packages/wyatt_ui_components/pubspec.yaml | 14 ++--- 14 files changed, 101 insertions(+), 54 deletions(-) diff --git a/packages/wyatt_ui_components/README.md b/packages/wyatt_ui_components/README.md index 4c2d773d..5fedb940 100644 --- a/packages/wyatt_ui_components/README.md +++ b/packages/wyatt_ui_components/README.md @@ -7,7 +7,7 @@ * the Free Software Foundation, either version 3 of the License, or * any later version. - * This program is distributed in the hope that it will be useful, + * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. @@ -16,48 +16,35 @@ * along with this program. If not, see . --> -# Flutter - Wyatt Ui Components +# Wyatt UI Components

- - Style: Wyatt Analysis - + Style: Wyatt Analysis SDK: Flutter

-Wyatt Ui Components for Flutter. +Wyatt UI Components for Flutter. This package defines all the components used in Wyatt Studio with their set of properties. But there is no implementation of the components. You have to create your own or check out [Wyatt UI Kit](https://git.wyatt-studio.fr/Wyatt-FOSS/wyatt-packages/src/branch/master/packages/wyatt_ui_kit) package. ## Usage ### Configuration -First create all your custom components in `core/design_system/components/`folder. For exemple : +First create all your custom components in `domain/entities` folder. For exemple : -├── design_system -│ ├── components +``` +├── domain +│ ├── entities │ │ ├── custom_app_bar.dart │ │ ├── custom_bottom_navigation_bar.dart │ │ └── ... │ └── ... └── ... - -You have to override `confgure` method. - -Then create AppComponentTheme class in `core/design_system/` folder and add all your components. For Example : - -```dart -class AppThemeComponent { - static ComponentThemeData get components => ComponentThemeData.raw( - appBar: const CustomAppBar(), - bottomNavigationBar: CustomBottomNavigationBar( - onTap: (context, index) { - print('$index'); - }, - ), - ); -} ``` +> Run `flutter pub run build_runner build` to generate your components. + +Then, add your components to `ComponentThemeData` class. + ### Provider In you main file, before calling router, call `ComponentTheme` widget and give your app as child. For example : @@ -72,7 +59,7 @@ class MyApp extends StatelessWidget { @override Widget build(BuildContext context) => ComponentTheme( - themDataWidget: AppThemeComponent.components, + componentThemeWidget: AppThemeComponent.components, child: MaterialApp( title: 'Wyatt Ui Layout Example', theme: ThemeData( @@ -102,12 +89,32 @@ For example : ) ``` -If you need specific settings, or pass parameters to your component, call `configure` method. It will use default paramters you've passed in your app comppnent theme file, and update the parameter you need to change. For example : +If you need specific settings, or pass parameters to your component, call `copyWith.call` method. ```dart @override Widget build(BuildContext context) => Scaffold( - appBar: context.components.appBar.configure({title:'New Title !}), + appBar: context.components.appBar.copyWith.call({title: 'New Title !'}), body: ... ) ``` + +## Development + +> Common to this, and Wyatt UI Kit packages. + +Add a new component : + +**Wyatt UI Components side** + + 1. Create a new file in `lib/src/domain/entities` folder. + 2. Add your component class. + 3. Add your component class to `ComponentThemeData` abstract class. + 4. Run `flutter pub run build_runner build` to generate your component proxy properties. + +**Wyatt UI Kit side** + 1. Create a new file in `lib/src/components` folder. + 2. Add your component class, styles, (and logic if needed) + 3. Run `flutter pub run build_runner build` to generate your component copy with method. + 4. Add a theme extension to your component class in `lib/src/domain/` + 5. Add your component class `wyattComponentThemeData` static property in `lib/src/features/wyatt_component_theme_data.dart` diff --git a/packages/wyatt_ui_components/analysis_options.yaml b/packages/wyatt_ui_components/analysis_options.yaml index 90d6bd51..8c9daa4e 100644 --- a/packages/wyatt_ui_components/analysis_options.yaml +++ b/packages/wyatt_ui_components/analysis_options.yaml @@ -1,17 +1 @@ -# Copyright (C) 2023 WYATT GROUP -# Please see the AUTHORS file for details. -# -# This program is free software: you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation, either version 3 of the License, or -# any later version. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program. If not, see . - include: package:wyatt_analysis/analysis_options.flutter.yaml diff --git a/packages/wyatt_ui_components/lib/src/core/enums/status_state.dart b/packages/wyatt_ui_components/lib/src/core/enums/status_state.dart index 878899f6..9add284a 100644 --- a/packages/wyatt_ui_components/lib/src/core/enums/status_state.dart +++ b/packages/wyatt_ui_components/lib/src/core/enums/status_state.dart @@ -14,6 +14,7 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . +/// Defines status states enum StatusState { initial, success, diff --git a/packages/wyatt_ui_components/lib/src/core/extensions/build_context_extensions.dart b/packages/wyatt_ui_components/lib/src/core/extensions/build_context_extensions.dart index be5e6045..b00fdb3f 100644 --- a/packages/wyatt_ui_components/lib/src/core/extensions/build_context_extensions.dart +++ b/packages/wyatt_ui_components/lib/src/core/extensions/build_context_extensions.dart @@ -18,5 +18,13 @@ import 'package:flutter/material.dart'; import 'package:wyatt_ui_components/src/features/features.dart'; extension ThemeComponentBuildContext on BuildContext { + /// Returns the [ComponentThemeData] of the current [BuildContext]. + /// + /// Throws an [AssertionError] if the current [BuildContext] does not contain + /// a [ComponentTheme]. ComponentThemeData get components => ComponentTheme.of(this); + + /// Returns the [ComponentThemeData] of the current [BuildContext] if it + /// exists. + ComponentThemeData? get maybeComponents => ComponentTheme.maybeOf(this); } diff --git a/packages/wyatt_ui_components/lib/src/core/mixins/copy_with_mixin.dart b/packages/wyatt_ui_components/lib/src/core/mixins/copy_with_mixin.dart index cd7bd5a9..728622c5 100644 --- a/packages/wyatt_ui_components/lib/src/core/mixins/copy_with_mixin.dart +++ b/packages/wyatt_ui_components/lib/src/core/mixins/copy_with_mixin.dart @@ -15,5 +15,8 @@ // along with this program. If not, see . mixin CopyWithMixin { + /// Returns a copy of the current object with the specified properties + /// overridden by the specified values. + /// You have to call the `.call()` method on the returned object. Proxy get copyWith; } diff --git a/packages/wyatt_ui_components/lib/src/core/utils/multi_color.dart b/packages/wyatt_ui_components/lib/src/core/utils/multi_color.dart index d64ac9a3..1a3aa44e 100644 --- a/packages/wyatt_ui_components/lib/src/core/utils/multi_color.dart +++ b/packages/wyatt_ui_components/lib/src/core/utils/multi_color.dart @@ -16,13 +16,20 @@ import 'package:flutter/widgets.dart'; +/// {@template multi_color} +/// A class that can hold a [Color] or a [List] of [Color]s. +/// {@endtemplate} class MultiColor { + /// {@macro multi_color} const MultiColor(this._colors) : _color = null; + + /// {@macro multi_color} const MultiColor.single(this._color) : _colors = null; final List? _colors; final Color? _color; + /// Returns a [Color] or the first [Color] in the [List] of [Color]s. Color get color => _color != null ? _color! : _colors?.isNotEmpty ?? false @@ -33,11 +40,20 @@ class MultiColor { message: '_color is not defined or _colors is empty.', ); + /// Returns the [List] of [Color]s. + /// If the [List] is empty or if it is a single [MultiColor], it will return + /// an empty [List]. List get colors => _colors ?? []; + /// Returns `true` if the [MultiColor] is a [List] of [Color]s that is not + /// empty with a length greater than 1. bool get isGradient => (_colors?.length ?? 0) > 1; + + /// Returns `true` if the [MultiColor] is a [Color] or a [List] of [Color]s + /// that is not empty with a length greater than 1. bool get isColor => _color != null || isGradient; + /// Lerps between two [MultiColor]s. static MultiColor? lerp(MultiColor? a, MultiColor? b, double t) { if (a == null && b == null) { return null; diff --git a/packages/wyatt_ui_components/lib/src/core/utils/text_wrapper.dart b/packages/wyatt_ui_components/lib/src/core/utils/text_wrapper.dart index ba23b89b..2c6e248e 100644 --- a/packages/wyatt_ui_components/lib/src/core/utils/text_wrapper.dart +++ b/packages/wyatt_ui_components/lib/src/core/utils/text_wrapper.dart @@ -17,9 +17,12 @@ import 'package:flutter/material.dart'; import 'package:wyatt_ui_components/wyatt_ui_components.dart'; +/// {@template text_wrapper} /// Wraps [String] and [TextStyle] into one object that can be /// a [Text] or a [RichText]. +/// {@endtemplate} class TextWrapper { + /// {@macro text_wrapper} const TextWrapper( this.data, { this.style, @@ -32,6 +35,7 @@ class TextWrapper { this.selectionColor, }); + /// Creates a [TextWrapper] from a [Text] widget. const TextWrapper.text(this.data) : style = null, gradientColors = null, diff --git a/packages/wyatt_ui_components/lib/src/core/utils/theme_helper.dart b/packages/wyatt_ui_components/lib/src/core/utils/theme_helper.dart index abefa83f..97fe94a0 100644 --- a/packages/wyatt_ui_components/lib/src/core/utils/theme_helper.dart +++ b/packages/wyatt_ui_components/lib/src/core/utils/theme_helper.dart @@ -28,7 +28,6 @@ abstract class ThemeHelper { /// determines if a style element is valid. /// [combine]: A function that combines two [P] type objects to create /// a new object. - static T? getThemeElement( List? styles, { required T? Function(P?)? transform, diff --git a/packages/wyatt_ui_components/lib/src/domain/entities/component.dart b/packages/wyatt_ui_components/lib/src/domain/entities/component.dart index e7f984f1..9cd334b5 100644 --- a/packages/wyatt_ui_components/lib/src/domain/entities/component.dart +++ b/packages/wyatt_ui_components/lib/src/domain/entities/component.dart @@ -17,6 +17,9 @@ import 'package:flutter/material.dart'; import 'package:wyatt_ui_components/src/core/utils/theme_resolver.dart'; +/// {@template component} +/// Base class for all components. +/// {@endtemplate} abstract class Component extends StatelessWidget { const Component({this.themeResolver, super.key}); diff --git a/packages/wyatt_ui_components/lib/src/domain/entities/theme_style.dart b/packages/wyatt_ui_components/lib/src/domain/entities/theme_style.dart index a0a69ffb..89db71e2 100644 --- a/packages/wyatt_ui_components/lib/src/domain/entities/theme_style.dart +++ b/packages/wyatt_ui_components/lib/src/domain/entities/theme_style.dart @@ -14,7 +14,11 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . +/// {@template theme_style} +/// Base class for all theme styles. +/// {@endtemplate} abstract class ThemeStyle { + /// {@macro theme_style} const ThemeStyle(); /// Merges non-null `other` attributes in `this` and returns a copy. diff --git a/packages/wyatt_ui_components/lib/src/features/component_theme.dart b/packages/wyatt_ui_components/lib/src/features/component_theme.dart index 0ed44487..c7dc79d3 100644 --- a/packages/wyatt_ui_components/lib/src/features/component_theme.dart +++ b/packages/wyatt_ui_components/lib/src/features/component_theme.dart @@ -17,7 +17,12 @@ import 'package:flutter/material.dart'; import 'package:wyatt_ui_components/src/features/features.dart'; +/// {@template component_theme} +/// A [ComponentTheme] widget that provides a [ComponentThemeData] to its +/// descendants. +/// {@endtemplate} class ComponentTheme extends StatelessWidget { + /// {@macro component_theme} const ComponentTheme({ required this.child, required this.componentThemeWidget, @@ -26,6 +31,9 @@ class ComponentTheme extends StatelessWidget { final Widget child; final ComponentThemeData componentThemeWidget; + /// Returns the [ComponentThemeData] of the closest ancestor [ComponentTheme] + /// widget. If there is no ancestor [ComponentTheme] widget, it throws an + /// assertion error. static ComponentThemeData of(BuildContext context) { final _InheritedComponentTheme? inheritedThemeComponent = context.dependOnInheritedWidgetOfExactType<_InheritedComponentTheme>(); @@ -37,6 +45,15 @@ class ComponentTheme extends StatelessWidget { return inheritedThemeComponent!.themeWidget.componentThemeWidget; } + /// Returns the [ComponentThemeData] of the closest ancestor [ComponentTheme] + /// widget. If there is no ancestor [ComponentTheme] widget, it returns null. + static ComponentThemeData? maybeOf(BuildContext context) { + final _InheritedComponentTheme? inheritedThemeComponent = + context.dependOnInheritedWidgetOfExactType<_InheritedComponentTheme>(); + + return inheritedThemeComponent?.themeWidget.componentThemeWidget; + } + @override Widget build(BuildContext context) => _InheritedComponentTheme( this, diff --git a/packages/wyatt_ui_components/lib/src/features/component_theme_data.dart b/packages/wyatt_ui_components/lib/src/features/component_theme_data.dart index aaff531d..c08e2502 100644 --- a/packages/wyatt_ui_components/lib/src/features/component_theme_data.dart +++ b/packages/wyatt_ui_components/lib/src/features/component_theme_data.dart @@ -18,6 +18,9 @@ import 'package:copy_with_extension/copy_with_extension.dart'; import 'package:wyatt_ui_components/src/domain/entities/entities.dart'; part 'component_theme_data.g.dart'; +/// {@template component_theme_data} +/// A class that holds all the components that are used in the app. +/// {@endtemplate} @CopyWith() class ComponentThemeData { factory ComponentThemeData({ diff --git a/packages/wyatt_ui_components/lib/wyatt_ui_components.dart b/packages/wyatt_ui_components/lib/wyatt_ui_components.dart index 3f16c3b1..e8cce321 100644 --- a/packages/wyatt_ui_components/lib/wyatt_ui_components.dart +++ b/packages/wyatt_ui_components/lib/wyatt_ui_components.dart @@ -14,7 +14,7 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . -/// Wyatt Ui Components +/// Wyatt UI Components library wyatt_ui_components; export 'src/src.dart'; diff --git a/packages/wyatt_ui_components/pubspec.yaml b/packages/wyatt_ui_components/pubspec.yaml index 81f439f9..eecf6f81 100644 --- a/packages/wyatt_ui_components/pubspec.yaml +++ b/packages/wyatt_ui_components/pubspec.yaml @@ -1,9 +1,9 @@ name: wyatt_ui_components -description: Primary ui components +description: Components that can be implemented in any application with copy constructor. repository: https://git.wyatt-studio.fr/Wyatt-FOSS/wyatt-packages/src/branch/master/packages/wyatt_ui_components version: 0.0.1 -publish_to: none +publish_to: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub environment: sdk: ">=2.17.0 <3.0.0" @@ -12,9 +12,8 @@ dependencies: flutter: { sdk: flutter } copy_with_extension: ^5.0.0 wyatt_component_copy_with_extension: - git: - url: ssh://git@git.wyatt-studio.fr:993/Wyatt-FOSS/wyatt-packages.git - path: packages/wyatt_component_copy_with_extension + hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub + version: ^1.0.0 dev_dependencies: flutter_test: { sdk: flutter } @@ -25,6 +24,5 @@ dev_dependencies: build_runner: ^2.3.3 copy_with_extension_gen: ^5.0.0 wyatt_component_copy_with_gen: - git: - url: ssh://git@git.wyatt-studio.fr:993/Wyatt-FOSS/wyatt-packages.git - path: packages/wyatt_component_copy_with_gen + hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub + version: ^1.0.0 -- 2.47.2 From 56de994e67417507f7706f6a760272842ad41d9d Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Thu, 13 Apr 2023 22:54:08 +0200 Subject: [PATCH 42/47] docs(ui_kit): add some documentation + readme --- packages/wyatt_ui_kit/README.md | 80 ++++++++++++++++-------------- packages/wyatt_ui_kit/pubspec.yaml | 21 +++----- 2 files changed, 50 insertions(+), 51 deletions(-) diff --git a/packages/wyatt_ui_kit/README.md b/packages/wyatt_ui_kit/README.md index 8ee9ac74..909c37ea 100644 --- a/packages/wyatt_ui_kit/README.md +++ b/packages/wyatt_ui_kit/README.md @@ -16,54 +16,60 @@ * along with this program. If not, see . --> -# Flutter - Wyatt Ui Kit +# Wyatt UI Kit

Style: Wyatt Analysis SDK: Flutter

-UIKit and Design System used in Wyatt Studio. - -## Theme negotiation - -When building a component, most of its attributes can be 'null'. -The `build()` method then starts to negotiate the theme in the tree to obtain the most consistent style possible. - -Explanation: - -When you build a component `Button({double? radius})`. -You have several possibilities: -1) Pass the "radius" into the constructor, `Button(radius: 12)`. -2) Set up a theme extension `ButtonThemeExtension(radius: 15)`. -3) Let `wyatt_ui_kit` "negotiate" and try to find a suitable style in the flutter theme. - -If this negotiation phase fails, then: -- If the value is mandatory: a hardcoded value in "wyatt_ui_kit" is chosen. -- If not, the style is simply not applied. - -If, for example, you don't use option 1, then the radius will be 15. If you use neither option 1 nor option 2 then the radius will be 4 as this is the [official Material Design value](https://m2.material.io/design/shape/about-shape.html#shape-customization-tool). - -## Features - -TODO: List what your package can do. Maybe include images, gifs, or videos. - -## Getting started - -TODO: List prerequisites and provide or point to information on how to -start using the package. +UIKit and Design System used in Wyatt Studio. This is a implementation of the components defined in [Wyatt UI Components](https://git.wyatt-studio.fr/Wyatt-FOSS/wyatt-packages/src/branch/master/packages/wyatt_ui_components) package. ## Usage -TODO: Include short and useful examples for package users. Add longer examples -to `/example` folder. +The UIKit provides `WyattComponentThemeData` class that contains all the components used in Wyatt Studio. You can use it in your app by calling `WyattComponentTheme` widget and give your app as child. For example : + +This component theme is to be used with Wyatt UI Components. It provides a default theme for all the components defined in Wyatt UI Components package. ```dart -const like = 'sample'; +void main() { + runApp(const MyApp()); +} + +class MyApp extends StatelessWidget { + const MyApp({super.key}); + + @override + Widget build(BuildContext context) => ComponentTheme( + // It is here that you can override the default theme ! + componentThemeWidget: WyattComponentThemeData(), + child: MaterialApp( + title: 'Wyatt Ui Layout Example', + theme: ThemeData( + primarySwatch: Colors.blue, + ), + home: const .., + ), + ); +} ``` -## Additional information +## Development -TODO: Tell users more about the package: where to find more information, how to -contribute to the package, how to file issues, what response they can expect -from the package authors, and more. +> Common to this, and Wyatt UI Components packages. + +Add a new component : + +**Wyatt UI Components side** + + 1. Create a new file in `lib/src/domain/entities` folder. + 2. Add your component class. + 3. Add your component class to `ComponentThemeData` abstract class. + 4. Run `flutter pub run build_runner build` to generate your component proxy properties. + +**Wyatt UI Kit side** + 1. Create a new file in `lib/src/components` folder. + 2. Add your component class, styles, (and logic if needed) + 3. Run `flutter pub run build_runner build` to generate your component copy with method. + 4. Add a theme extension to your component class in `lib/src/domain/` + 5. Add your component class `wyattComponentThemeData` static property in `lib/src/features/wyatt_component_theme_data.dart` diff --git a/packages/wyatt_ui_kit/pubspec.yaml b/packages/wyatt_ui_kit/pubspec.yaml index d34b1dbc..68082704 100644 --- a/packages/wyatt_ui_kit/pubspec.yaml +++ b/packages/wyatt_ui_kit/pubspec.yaml @@ -3,7 +3,7 @@ description: UIKit and Design System used in Wyatt Studio. repository: https://git.wyatt-studio.fr/Wyatt-FOSS/wyatt-packages/src/branch/master/packages/wyatt_ui_kit version: 1.0.0 -publish_to: none +publish_to: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub environment: sdk: ">=2.19.0 <3.0.0" @@ -22,13 +22,11 @@ dependencies: name: wyatt_bloc_helper version: 2.0.0 wyatt_component_copy_with_extension: - git: - url: ssh://git@git.wyatt-studio.fr:993/Wyatt-FOSS/wyatt-packages.git - path: packages/wyatt_component_copy_with_extension + hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub + version: ^1.0.0 wyatt_ui_components: - git: - url: ssh://git@git.wyatt-studio.fr:993/Wyatt-FOSS/wyatt-packages.git - path: packages/wyatt_ui_components + hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub + version: ^0.0.1 dev_dependencies: build_runner: ^2.3.3 @@ -37,10 +35,5 @@ dev_dependencies: hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub version: ^2.4.1 wyatt_component_copy_with_gen: - git: - url: ssh://git@git.wyatt-studio.fr:993/Wyatt-FOSS/wyatt-packages.git - path: packages/wyatt_component_copy_with_gen - -# The following section is specific to Flutter. -flutter: - uses-material-design: true + hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub + version: ^1.0.0 -- 2.47.2 From 79c5aa7c7682335f34711880c89b3f57e9a8cdf0 Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Thu, 13 Apr 2023 22:54:26 +0200 Subject: [PATCH 43/47] docs(ui_layout): add some documentation + readme --- packages/wyatt_ui_layout/README.md | 31 +++++-------------- .../wyatt_ui_layout/analysis_options.yaml | 17 ---------- .../layouts/content_layouts/grid_layout.dart | 10 ++++++ .../lib/src/presentation/layouts/layout.dart | 23 +++++++++----- .../bottom_navigation_bar_layout.dart | 25 ++++++--------- .../structural_layouts/frame_layout.dart | 18 ++++++----- .../top_app_bar_layout.dart | 21 ++++++------- .../wyatt_ui_layout/lib/wyatt_ui_layout.dart | 2 +- packages/wyatt_ui_layout/pubspec.yaml | 19 +++++------- 9 files changed, 69 insertions(+), 97 deletions(-) diff --git a/packages/wyatt_ui_layout/README.md b/packages/wyatt_ui_layout/README.md index e8d1656d..af77bf5f 100644 --- a/packages/wyatt_ui_layout/README.md +++ b/packages/wyatt_ui_layout/README.md @@ -7,7 +7,7 @@ * the Free Software Foundation, either version 3 of the License, or * any later version. - * This program is distributed in the hope that it will be useful, + * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. @@ -16,12 +16,10 @@ * along with this program. If not, see . --> -# Flutter - Wyatt Ui Layout +# Wyatt UI Layout

- - Style: Wyatt Analysis - + Style: Wyatt Analysis SDK: Flutter

@@ -31,19 +29,19 @@ Wyatt UI Layout is a Flutter package that provides pre-built layouts to make the Structural layouts are used to structure the GUI, and there are currently four layouts provided by this package: -- #### TopAppBarLayout +* #### TopAppBarLayout This layout is used to create a GUI with a classic app bar and a body. -- #### TopNavigationBarLayout +* #### TopNavigationBarLayout This layout is used to create a GUI with an app bar that includes navigation options and a body. -- #### BottomNavigationBarLayout +* #### BottomNavigationBarLayout This layout is used to create a GUI with a bottom bar that includes navigation options and a body. -- #### FrameLayout +* #### FrameLayout This layout is used to create a GUI that includes a classic app bar, a bottom navigation bar, and a body. @@ -51,19 +49,6 @@ This layout is used to create a GUI that includes a classic app bar, a bottom na Content layouts are used to display dynamic data and content within the GUI. Currently, there is only one content layout provided by this package: -- #### GridLayout +* #### GridLayout This layout is used to display data and content in a grid layout. - -### Installation - -To use Wyatt UI Layout in your Flutter project, add the following dependency to your pubspec.yaml file: - -```yaml -wyatt_ui_layout: - git: - url: https://git.wyatt-studio.fr/Wyatt-FOSS/wyatt-packages - path: packages/wyatt_ui_layout -``` - -That's it! You're now ready to use Wyatt UI Layout in your project. diff --git a/packages/wyatt_ui_layout/analysis_options.yaml b/packages/wyatt_ui_layout/analysis_options.yaml index f8bb612a..e66159fc 100644 --- a/packages/wyatt_ui_layout/analysis_options.yaml +++ b/packages/wyatt_ui_layout/analysis_options.yaml @@ -1,19 +1,2 @@ -# Copyright (C) 2022 WYATT GROUP -# Please see the AUTHORS file for details. -# -# This program is free software: you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation, either version 3 of the License, or -# any later version. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program. If not, see . - - include: package:wyatt_analysis/analysis_options.flutter.yaml diff --git a/packages/wyatt_ui_layout/lib/src/presentation/layouts/content_layouts/grid_layout.dart b/packages/wyatt_ui_layout/lib/src/presentation/layouts/content_layouts/grid_layout.dart index c06014c1..04c9a7a0 100644 --- a/packages/wyatt_ui_layout/lib/src/presentation/layouts/content_layouts/grid_layout.dart +++ b/packages/wyatt_ui_layout/lib/src/presentation/layouts/content_layouts/grid_layout.dart @@ -18,7 +18,12 @@ import 'package:flutter/material.dart'; import 'package:gap/gap.dart'; import 'package:wyatt_ui_layout/src/presentation/layouts/layout.dart'; +/// {@template grid_layout} +/// A concrete implementation of the [ContentLayout] abstract class for a layout +/// which defines a layout structure with a grid layout. +/// {@endtemplate} class GridLayout extends ContentLayout { + /// {@macro grid_layout} const GridLayout({ required this.children, this.verticalGap = 30, @@ -26,8 +31,13 @@ class GridLayout extends ContentLayout { super.key, }); + /// The children of the layout. final List children; + + /// The vertical gap between the children. final double verticalGap; + + /// The horizontal gap between the children. final double horizontalGap; @override diff --git a/packages/wyatt_ui_layout/lib/src/presentation/layouts/layout.dart b/packages/wyatt_ui_layout/lib/src/presentation/layouts/layout.dart index 41f839a8..28068913 100644 --- a/packages/wyatt_ui_layout/lib/src/presentation/layouts/layout.dart +++ b/packages/wyatt_ui_layout/lib/src/presentation/layouts/layout.dart @@ -1,4 +1,4 @@ -// Copyright (C) 2022 WYATT GROUP +// Copyright (C) 2023 WYATT GROUP // Please see the AUTHORS file for details. // // This program is free software: you can redistribute it and/or modify @@ -14,28 +14,35 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . -/// This file contains the [Layout] abstract class, which provides a base -/// for creating custom layout widgets in Flutter. -import 'package:flutter/material.dart'; +import 'package:flutter/widgets.dart'; +/// {@template layout} /// An abstract class that provides a base for creating custom layout widgets. /// /// This class can be used as a base for creating custom layout widgets in /// Flutter. It extends the [StatelessWidget] class and adds support for /// providing a custom key. Custom layout widgets that extend this class should /// override the [build] method to define the layout. +/// {@endtemplate} abstract class Layout extends StatelessWidget { - /// Creates a new [Layout] instance. - /// - /// [key] is an optional parameter that can be used to provide a custom key - /// for the widget. + /// {@macro layout} const Layout({super.key}); } +/// {@template structural_layout} +/// An abstract class that provides a base for creating custom structural layout +/// widgets. +/// {@endtemplate} abstract class StructuralLayout extends Layout { + /// {@macro structural_layout} const StructuralLayout({super.key}); } +/// {@template content_layout} +/// An abstract class that provides a base for creating custom content layout +/// widgets. +/// {@endtemplate} abstract class ContentLayout extends Layout { + /// {@macro content_layout} const ContentLayout({super.key}); } diff --git a/packages/wyatt_ui_layout/lib/src/presentation/layouts/structural_layouts/bottom_navigation_bar_layout.dart b/packages/wyatt_ui_layout/lib/src/presentation/layouts/structural_layouts/bottom_navigation_bar_layout.dart index 4ef676de..d8755e92 100644 --- a/packages/wyatt_ui_layout/lib/src/presentation/layouts/structural_layouts/bottom_navigation_bar_layout.dart +++ b/packages/wyatt_ui_layout/lib/src/presentation/layouts/structural_layouts/bottom_navigation_bar_layout.dart @@ -14,34 +14,27 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . -/// This file contains the concrete class [BottomNavigationBarLayout]. -/// -/// The [BottomNavigationBarLayout] class is a concrete implementation of the -/// [Layout] abstract class, which defines a layout structure with a bottom -/// navigation bar component. -/// -/// [BottomNavigationBarLayout] includes an optional -/// [BottomNavigationBarLayout.custom] -/// function for customizing the bottom navigation bar component. import 'package:flutter/material.dart'; import 'package:wyatt_ui_components/wyatt_ui_components.dart'; import 'package:wyatt_ui_layout/src/presentation/layouts/layout.dart'; -/// A concrete implementation of the [Layout] abstract class for a layout with -/// a bottom navigation bar component. +/// {@template bottom_navigation_bar_layout} +/// A concrete implementation of the [Layout] abstract class for a layout which +/// defines a layout structure with a bottom navigation bar component. +/// {@endtemplate} class BottomNavigationBarLayout extends StructuralLayout { - /// Creates a [BottomNavigationBarLayout] instance. - /// - /// [body] represents the main content of the layout. - /// [custom] is an optional function that can be used to customize - /// the bottom navigation bar component. + /// {@macro bottom_navigation_bar_layout} const BottomNavigationBarLayout({ required this.body, this.custom, super.key, }); + /// The main content of the layout. final Widget? body; + + /// An optional function that can be used to customize the bottom navigation + /// bar component. final BottomNavigationBarComponent? Function(BottomNavigationBarComponent?)? custom; diff --git a/packages/wyatt_ui_layout/lib/src/presentation/layouts/structural_layouts/frame_layout.dart b/packages/wyatt_ui_layout/lib/src/presentation/layouts/structural_layouts/frame_layout.dart index 79e28793..144ef867 100644 --- a/packages/wyatt_ui_layout/lib/src/presentation/layouts/structural_layouts/frame_layout.dart +++ b/packages/wyatt_ui_layout/lib/src/presentation/layouts/structural_layouts/frame_layout.dart @@ -18,6 +18,7 @@ import 'package:flutter/material.dart'; import 'package:wyatt_ui_components/wyatt_ui_components.dart'; import 'package:wyatt_ui_layout/src/presentation/layouts/layout.dart'; +/// {@template frame_layout} /// A layout that contains a top app bar, a body and a bottom navigation bar. /// /// This layout consists of a [TopAppBarComponent] at the top of the screen, @@ -25,15 +26,9 @@ import 'package:wyatt_ui_layout/src/presentation/layouts/layout.dart'; /// You can customize the app bar and the bottom navigation bar by passing /// a [customAppBar] and a [customBottomNavBar] functions that take /// the corresponding components and return the customized ones. +/// {@endtemplate} class FrameLayout extends StructuralLayout { - /// Creates a [FrameLayout] instance. - /// - /// [body] represents the main content of the layout. - /// [customAppBar] is an optional function that can be used to customize - /// the top app bar component. - /// [customBottomNavBar] is an optional function that can be used to customize - /// the bottom navigation bar component. - /// [height] represents the height of the top app bar. + /// {@macro frame_layout} const FrameLayout({ required this.body, this.customAppBar, @@ -42,10 +37,17 @@ class FrameLayout extends StructuralLayout { super.key, }); + /// An optional function that can be used to customize the top app bar final TopAppBarComponent? Function(TopAppBarComponent?)? customAppBar; + + /// An optional function that can be used to customize the bottom navigation final BottomNavigationBarComponent? Function(BottomNavigationBarComponent?)? customBottomNavBar; + + /// The main content of the layout. final Widget body; + + /// The height of the top app bar. final double height; @override diff --git a/packages/wyatt_ui_layout/lib/src/presentation/layouts/structural_layouts/top_app_bar_layout.dart b/packages/wyatt_ui_layout/lib/src/presentation/layouts/structural_layouts/top_app_bar_layout.dart index e69054bb..70f61b1e 100644 --- a/packages/wyatt_ui_layout/lib/src/presentation/layouts/structural_layouts/top_app_bar_layout.dart +++ b/packages/wyatt_ui_layout/lib/src/presentation/layouts/structural_layouts/top_app_bar_layout.dart @@ -14,16 +14,11 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . -/// This file contains the abstract class [TopBarLayout] and two concrete -/// classes [TopAppBarLayout] and [TopNavigationBarLayout]. -/// The [TopBarLayout] abstract class defines a layout structure with a top bar. -/// The [TopAppBarLayout] and [TopNavigationBarLayout] classes are concrete -/// implementations of the [TopBarLayout] class. - import 'package:flutter/material.dart'; import 'package:wyatt_ui_components/wyatt_ui_components.dart'; import 'package:wyatt_ui_layout/src/presentation/layouts/layout.dart'; +/// {@template top_bar_layout} /// An abstract class for creating layouts with a top bar component. /// /// This class provides a base for creating layouts that include a top bar @@ -34,14 +29,10 @@ import 'package:wyatt_ui_layout/src/presentation/layouts/layout.dart'; /// given [BuildContext]. /// /// [T] represents the type of the top bar component. +/// {@endtemplate} abstract class TopBarLayout extends StructuralLayout { - /// Creates a [TopBarLayout] instance. - /// - /// [body] represents the main content of the layout. - /// [custom] is an optional function that can be used to customize - /// the top bar component. - /// [height] represents the height of the top bar. + /// {@macro top_bar_layout} const TopBarLayout({ required this.body, this.custom, @@ -49,9 +40,15 @@ abstract class TopBarLayout super.key, }); + /// The main content of the layout. final Widget body; + /// An optional function that can be used to customize the top bar component. + /// The function takes the top bar component as an argument and returns + /// a customized top bar component. final T? Function(T?)? custom; + + /// The height of the top bar. final double height; /// Returns the top bar component for the given [BuildContext]. diff --git a/packages/wyatt_ui_layout/lib/wyatt_ui_layout.dart b/packages/wyatt_ui_layout/lib/wyatt_ui_layout.dart index 5ab915d4..ac5430dc 100644 --- a/packages/wyatt_ui_layout/lib/wyatt_ui_layout.dart +++ b/packages/wyatt_ui_layout/lib/wyatt_ui_layout.dart @@ -14,7 +14,7 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . -/// Wyatt Ui Layout +/// Wyatt UI Layout library wyatt_ui_layout; export 'src/src.dart'; diff --git a/packages/wyatt_ui_layout/pubspec.yaml b/packages/wyatt_ui_layout/pubspec.yaml index 7c8703ed..aaaf1130 100644 --- a/packages/wyatt_ui_layout/pubspec.yaml +++ b/packages/wyatt_ui_layout/pubspec.yaml @@ -3,27 +3,22 @@ description: Main layouts to help you build your application views. repository: https://git.wyatt-studio.fr/Wyatt-FOSS/wyatt-packages/src/branch/master/packages/wyatt_ui_layout version: 0.0.1 -publish_to: "none" +publish_to: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub environment: sdk: ">=2.17.0 <3.0.0" dependencies: - flutter: - sdk: flutter + flutter: { sdk: flutter } gap: ^2.0.1 wyatt_ui_components: - git: - url: https://git.wyatt-studio.fr/Wyatt-FOSS/wyatt-packages - path: packages/wyatt_ui_components + hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub + version: ^0.0.1 dev_dependencies: - flutter_test: - sdk: flutter + flutter_test: { sdk: flutter } wyatt_analysis: - git: - url: https://git.wyatt-studio.fr/Wyatt-FOSS/wyatt-packages - ref: wyatt_analysis-v2.4.1 - path: packages/wyatt_analysis + hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub + version: ^2.4.1 -- 2.47.2 From c3620e61c16f973c64dcc0f3f5d8d228e89acf76 Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Thu, 13 Apr 2023 23:13:11 +0200 Subject: [PATCH 44/47] refactor(bloc_layout): remove cross package export --- packages/wyatt_analysis/.pubignore | 3 +- packages/wyatt_authentication_bloc/.pubignore | 3 +- packages/wyatt_bloc_layout/README.md | 73 ++++++++----------- .../wyatt_bloc_layout/analysis_options.yaml | 16 ---- .../example/lib/bloc/example_cubit.dart | 13 ++-- .../lib/components/custom_app_bar.dart | 2 +- .../lib/components/custom_bottom_bar.dart | 2 +- .../lib/components/custom_error_widget.dart | 2 +- .../lib/components/custom_loading_widget.dart | 2 +- .../lib/components/theme_components.dart | 2 +- .../wyatt_bloc_layout/example/lib/main.dart | 3 + .../wyatt_bloc_layout/example/pubspec.yaml | 18 +++++ .../lib/src/core/mixins/gird_view_mixin.dart | 3 +- ...ar_grid_layout_cubit_screen_crud_list.dart | 1 + ...om_navigation_bar_layout_cubit_screen.dart | 2 + ...vigation_bar_layout_cubit_screen_crud.dart | 1 + ...ion_bar_layout_cubit_screen_crud_item.dart | 1 + ...ion_bar_layout_cubit_screen_crud_list.dart | 1 + .../src/presentation/cubit_screen_base.dart | 2 +- .../presentation/cubit_screen_crud_base.dart | 1 + .../cubit_screen_crud_item_base.dart | 1 + .../cubit_screen_crud_list_base.dart | 1 + ...me_grid_layout_cubit_screen_crud_list.dart | 1 + .../frame_layout_cubit_screen.dart | 2 + .../frame_layout_cubit_screen_crud.dart | 1 + .../frame_layout_cubit_screen_crud_item.dart | 1 + .../frame_layout_cubit_screen_crud_list.dart | 1 + .../grid_cubit_screen_crud_list_base.dart | 1 + ...ar_grid_layout_cubit_screen_crud_list.dart | 1 + .../top_app_bar_layout_cubit_screen.dart | 2 + .../top_app_bar_layout_cubit_screen_crud.dart | 1 + ...app_bar_layout_cubit_screen_crud_item.dart | 1 + ...app_bar_layout_cubit_screen_crud_list.dart | 1 + ...ar_grid_layout_cubit_screen_crud_list.dart | 1 + ...op_navigation_bar_layout_cubit_screen.dart | 2 + ...vigation_bar_layout_cubit_screen_crud.dart | 1 + ...ion_bar_layout_cubit_screen_crud_item.dart | 1 + ...ion_bar_layout_cubit_screen_crud_list.dart | 1 + packages/wyatt_bloc_layout/lib/src/src.dart | 6 -- packages/wyatt_bloc_layout/pubspec.yaml | 36 ++++----- packages/wyatt_crud_bloc/.pubignore | 3 +- packages/wyatt_form_bloc/.pubignore | 3 +- 42 files changed, 113 insertions(+), 107 deletions(-) mode change 100644 => 120000 packages/wyatt_analysis/.pubignore mode change 100644 => 120000 packages/wyatt_authentication_bloc/.pubignore mode change 100644 => 120000 packages/wyatt_crud_bloc/.pubignore mode change 100644 => 120000 packages/wyatt_form_bloc/.pubignore diff --git a/packages/wyatt_analysis/.pubignore b/packages/wyatt_analysis/.pubignore deleted file mode 100644 index e2355bec..00000000 --- a/packages/wyatt_analysis/.pubignore +++ /dev/null @@ -1,2 +0,0 @@ -new_version.sh -.latest_version \ No newline at end of file diff --git a/packages/wyatt_analysis/.pubignore b/packages/wyatt_analysis/.pubignore new file mode 120000 index 00000000..52b2f28d --- /dev/null +++ b/packages/wyatt_analysis/.pubignore @@ -0,0 +1 @@ +../../.pubignore \ No newline at end of file diff --git a/packages/wyatt_authentication_bloc/.pubignore b/packages/wyatt_authentication_bloc/.pubignore deleted file mode 100644 index 11610c5a..00000000 --- a/packages/wyatt_authentication_bloc/.pubignore +++ /dev/null @@ -1,2 +0,0 @@ -firebase_options.dart -.vscode \ No newline at end of file diff --git a/packages/wyatt_authentication_bloc/.pubignore b/packages/wyatt_authentication_bloc/.pubignore new file mode 120000 index 00000000..52b2f28d --- /dev/null +++ b/packages/wyatt_authentication_bloc/.pubignore @@ -0,0 +1 @@ +../../.pubignore \ No newline at end of file diff --git a/packages/wyatt_bloc_layout/README.md b/packages/wyatt_bloc_layout/README.md index b31892df..39b4c134 100644 --- a/packages/wyatt_bloc_layout/README.md +++ b/packages/wyatt_bloc_layout/README.md @@ -7,7 +7,7 @@ * the Free Software Foundation, either version 3 of the License, or * any later version. - * This program is distributed in the hope that it will be useful, + * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. @@ -16,57 +16,46 @@ * along with this program. If not, see . --> -# Flutter - Wyatt Bloc Layout +# Wyatt Bloc Layout

- - Style: Wyatt Analysis - + Style: Wyatt Analysis SDK: Flutter

Bloc Layout for Flutter. -Wyatt Bloc Layout is a Flutter package that builds on the Wyatt UI Layout package and the Wyatt Bloc Helper package. It provides a way to link multiple packages in order to create intelligent layouts that combine both layout and logic. The package allows developers to use the available layouts in the Wyatt UI Layout package along with the block state logic available in the Wyatt Bloc Helper package. It also uses the Wyatt Crud Bloc package to make it easier to implement CRUD logic. +Wyatt Bloc Layout is a Flutter package that is built on the Wyatt UI Layout package and the Wyatt Bloc Helper package. + +It provides a way to link multiple packages in order to create intelligent layouts that combine both layout and logic. The package allows developers to use the available layouts in the Wyatt UI Layout package along with the block state logic available in the Wyatt Bloc Helper package. + +It also uses the Wyatt Crud Bloc package to make it easier to implement CRUD logic. ### Features -- Allows developers to use available layouts from Wyatt UI Layout package. -- Links with the Wyatt Bloc Helper package to combine layout and block state logic. -- Uses the Wyatt Crud Bloc package to easily implement CRUD logic. +* Allows developers to use available layouts from Wyatt UI Layout package. +* Links with the Wyatt Bloc Helper package to combine layout and block state logic. +* Uses the Wyatt Crud Bloc package to easily implement CRUD logic. #### Available bloc layouts -- BottomNavigationBarGridLayoutCubitScreenCrudList -- BottomNavigationBarLayoutCubitScreen -- BottomNavigationBarLayoutCubitScreenCrud -- BottomNavigationBarLayoutCubitScreenCrudItem -- BottomNavigationBarLayoutCubitScreenCrudList -- FrameGridLayoutCubitScreenCrudList -- FrameLayoutCubitScreen -- FrameLayoutCubitScreenCrud -- FrameLayoutCubitScreenCrudItem -- FrameLayoutCubitScreenCrudList -- TopAppBarGridLayoutCubitScreenCrudList -- TopAppBarLayoutCubitScreen -- TopAppBarLayoutCubitScreenCrud -- TopAppBarLayoutCubitScreenCrudItem -- TopAppBarLayoutCubitScreenCrudList -- TopNavigationBarGridLayoutCubitScreenCrudList -- TopNavigationBarLayoutCubitScreen -- TopNavigationBarLayoutCubitScreenCrud -- TopNavigationBarLayoutCubitScreenCrudItem -- TopNavigationBarLayoutCubitScreenCrudList - -### Installation - -To use Wyatt Bloc Layout in your Flutter project, add the following dependency to your pubspec.yaml file: - -```yaml -wyatt_bloc_layout: - git: - url: https://git.wyatt-studio.fr/Wyatt-FOSS/wyatt-packages - path: packages/wyatt_bloc_layout -``` - -Then, run flutter pub get to download the package. +* BottomNavigationBarGridLayoutCubitScreenCrudList +* BottomNavigationBarLayoutCubitScreen +* BottomNavigationBarLayoutCubitScreenCrud +* BottomNavigationBarLayoutCubitScreenCrudItem +* BottomNavigationBarLayoutCubitScreenCrudList +* FrameGridLayoutCubitScreenCrudList +* FrameLayoutCubitScreen +* FrameLayoutCubitScreenCrud +* FrameLayoutCubitScreenCrudItem +* FrameLayoutCubitScreenCrudList +* TopAppBarGridLayoutCubitScreenCrudList +* TopAppBarLayoutCubitScreen +* TopAppBarLayoutCubitScreenCrud +* TopAppBarLayoutCubitScreenCrudItem +* TopAppBarLayoutCubitScreenCrudList +* TopNavigationBarGridLayoutCubitScreenCrudList +* TopNavigationBarLayoutCubitScreen +* TopNavigationBarLayoutCubitScreenCrud +* TopNavigationBarLayoutCubitScreenCrudItem +* TopNavigationBarLayoutCubitScreenCrudList diff --git a/packages/wyatt_bloc_layout/analysis_options.yaml b/packages/wyatt_bloc_layout/analysis_options.yaml index 90d6bd51..8c9daa4e 100644 --- a/packages/wyatt_bloc_layout/analysis_options.yaml +++ b/packages/wyatt_bloc_layout/analysis_options.yaml @@ -1,17 +1 @@ -# Copyright (C) 2023 WYATT GROUP -# Please see the AUTHORS file for details. -# -# This program is free software: you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation, either version 3 of the License, or -# any later version. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program. If not, see . - include: package:wyatt_analysis/analysis_options.flutter.yaml diff --git a/packages/wyatt_bloc_layout/example/lib/bloc/example_cubit.dart b/packages/wyatt_bloc_layout/example/lib/bloc/example_cubit.dart index 80c20d1a..dd2275d4 100644 --- a/packages/wyatt_bloc_layout/example/lib/bloc/example_cubit.dart +++ b/packages/wyatt_bloc_layout/example/lib/bloc/example_cubit.dart @@ -1,27 +1,28 @@ import 'dart:async'; -import 'package:wyatt_bloc_layout/wyatt_bloc_layout.dart'; +import 'package:flutter_bloc/flutter_bloc.dart'; +import 'package:wyatt_crud_bloc/wyatt_crud_bloc.dart'; class ExampleCubit extends Cubit { - ExampleCubit() : super(CrudInitial()); + ExampleCubit() : super(const CrudInitial()); FutureOr run() async { while (true) { await Future.delayed(const Duration(seconds: 1)); - emit(CrudLoading()); + emit(const CrudLoading()); await Future.delayed(const Duration(seconds: 1)); emit(const CrudError('Cubit Error')); await Future.delayed(const Duration(seconds: 1)); emit(const CrudLoaded('DATA LOADED')); await Future.delayed(const Duration(seconds: 1)); - emit(CrudInitial()); + emit(const CrudInitial()); } } FutureOr runList() async { while (true) { await Future.delayed(const Duration(seconds: 1)); - emit(CrudLoading()); + emit(const CrudLoading()); await Future.delayed(const Duration(seconds: 1)); emit(const CrudError('Cubit Error')); await Future.delayed(const Duration(seconds: 1)); @@ -34,7 +35,7 @@ class ExampleCubit extends Cubit { ]), ); await Future.delayed(const Duration(seconds: 1)); - emit(CrudInitial()); + emit(const CrudInitial()); } } } diff --git a/packages/wyatt_bloc_layout/example/lib/components/custom_app_bar.dart b/packages/wyatt_bloc_layout/example/lib/components/custom_app_bar.dart index aff474a8..1ca3cab4 100644 --- a/packages/wyatt_bloc_layout/example/lib/components/custom_app_bar.dart +++ b/packages/wyatt_bloc_layout/example/lib/components/custom_app_bar.dart @@ -1,7 +1,7 @@ import 'package:flutter/material.dart'; import 'package:flutter/services.dart'; -import 'package:wyatt_bloc_layout/wyatt_bloc_layout.dart'; import 'package:wyatt_component_copy_with_extension/component_copy_with_extension.dart'; +import 'package:wyatt_ui_components/wyatt_ui_components.dart'; part 'custom_app_bar.g.dart'; diff --git a/packages/wyatt_bloc_layout/example/lib/components/custom_bottom_bar.dart b/packages/wyatt_bloc_layout/example/lib/components/custom_bottom_bar.dart index 1b094adf..34417c03 100644 --- a/packages/wyatt_bloc_layout/example/lib/components/custom_bottom_bar.dart +++ b/packages/wyatt_bloc_layout/example/lib/components/custom_bottom_bar.dart @@ -1,6 +1,6 @@ import 'package:flutter/material.dart'; -import 'package:wyatt_bloc_layout/wyatt_bloc_layout.dart'; import 'package:wyatt_component_copy_with_extension/component_copy_with_extension.dart'; +import 'package:wyatt_ui_components/wyatt_ui_components.dart'; part 'custom_bottom_bar.g.dart'; diff --git a/packages/wyatt_bloc_layout/example/lib/components/custom_error_widget.dart b/packages/wyatt_bloc_layout/example/lib/components/custom_error_widget.dart index 77364998..5d9cfee7 100644 --- a/packages/wyatt_bloc_layout/example/lib/components/custom_error_widget.dart +++ b/packages/wyatt_bloc_layout/example/lib/components/custom_error_widget.dart @@ -1,6 +1,6 @@ import 'package:flutter/material.dart'; -import 'package:wyatt_bloc_layout/wyatt_bloc_layout.dart'; import 'package:wyatt_component_copy_with_extension/component_copy_with_extension.dart'; +import 'package:wyatt_ui_components/wyatt_ui_components.dart'; part 'custom_error_widget.g.dart'; diff --git a/packages/wyatt_bloc_layout/example/lib/components/custom_loading_widget.dart b/packages/wyatt_bloc_layout/example/lib/components/custom_loading_widget.dart index 94517557..fe53a631 100644 --- a/packages/wyatt_bloc_layout/example/lib/components/custom_loading_widget.dart +++ b/packages/wyatt_bloc_layout/example/lib/components/custom_loading_widget.dart @@ -1,6 +1,6 @@ import 'package:flutter/material.dart'; -import 'package:wyatt_bloc_layout/wyatt_bloc_layout.dart'; import 'package:wyatt_component_copy_with_extension/component_copy_with_extension.dart'; +import 'package:wyatt_ui_components/wyatt_ui_components.dart'; part 'custom_loading_widget.g.dart'; diff --git a/packages/wyatt_bloc_layout/example/lib/components/theme_components.dart b/packages/wyatt_bloc_layout/example/lib/components/theme_components.dart index b0b1f404..afc4203d 100644 --- a/packages/wyatt_bloc_layout/example/lib/components/theme_components.dart +++ b/packages/wyatt_bloc_layout/example/lib/components/theme_components.dart @@ -2,7 +2,7 @@ import 'package:bloc_layout_example/components/custom_app_bar.dart'; import 'package:bloc_layout_example/components/custom_bottom_bar.dart'; import 'package:bloc_layout_example/components/custom_error_widget.dart'; import 'package:bloc_layout_example/components/custom_loading_widget.dart'; -import 'package:wyatt_bloc_layout/wyatt_bloc_layout.dart'; +import 'package:wyatt_ui_components/wyatt_ui_components.dart'; class AppThemeComponent { static ComponentThemeData get components => ComponentThemeData.raw( diff --git a/packages/wyatt_bloc_layout/example/lib/main.dart b/packages/wyatt_bloc_layout/example/lib/main.dart index 4542215e..2856aec7 100644 --- a/packages/wyatt_bloc_layout/example/lib/main.dart +++ b/packages/wyatt_bloc_layout/example/lib/main.dart @@ -17,7 +17,10 @@ import 'package:bloc_layout_example/bloc/example_cubit.dart'; import 'package:bloc_layout_example/components/theme_components.dart'; import 'package:flutter/material.dart'; +import 'package:flutter_bloc/flutter_bloc.dart'; import 'package:wyatt_bloc_layout/wyatt_bloc_layout.dart'; +import 'package:wyatt_crud_bloc/wyatt_crud_bloc.dart'; +import 'package:wyatt_ui_components/wyatt_ui_components.dart'; void main() { runApp(const MyApp()); diff --git a/packages/wyatt_bloc_layout/example/pubspec.yaml b/packages/wyatt_bloc_layout/example/pubspec.yaml index 50944ac6..8d19be75 100644 --- a/packages/wyatt_bloc_layout/example/pubspec.yaml +++ b/packages/wyatt_bloc_layout/example/pubspec.yaml @@ -30,9 +30,27 @@ dependencies: flutter: sdk: flutter + flutter_bloc: ^8.1.2 + wyatt_bloc_layout: path: "../" + wyatt_bloc_helper: + hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub + version: ^2.0.0 + + wyatt_ui_layout: + hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub + version: ^0.0.1 + + wyatt_crud_bloc: + hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub + version: ^0.1.0+2 + + wyatt_ui_components: + hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub + version: ^0.0.1 + wyatt_component_copy_with_extension: git: url: ssh://git@git.wyatt-studio.fr:993/Wyatt-FOSS/wyatt-packages.git diff --git a/packages/wyatt_bloc_layout/lib/src/core/mixins/gird_view_mixin.dart b/packages/wyatt_bloc_layout/lib/src/core/mixins/gird_view_mixin.dart index 696ae8e9..636048e2 100644 --- a/packages/wyatt_bloc_layout/lib/src/core/mixins/gird_view_mixin.dart +++ b/packages/wyatt_bloc_layout/lib/src/core/mixins/gird_view_mixin.dart @@ -15,7 +15,8 @@ // along with this program. If not, see . import 'package:flutter/material.dart'; -import 'package:wyatt_bloc_layout/wyatt_bloc_layout.dart'; +import 'package:wyatt_crud_bloc/wyatt_crud_bloc.dart'; +import 'package:wyatt_ui_layout/wyatt_ui_layout.dart'; mixin GridLayoutMixin { Widget gridChild(BuildContext context, SuccessType? successType); diff --git a/packages/wyatt_bloc_layout/lib/src/presentation/bottom_navigation_bar_bloc_layout/bottom_navigation_bar_grid_layout_cubit_screen_crud_list.dart b/packages/wyatt_bloc_layout/lib/src/presentation/bottom_navigation_bar_bloc_layout/bottom_navigation_bar_grid_layout_cubit_screen_crud_list.dart index 099d6b79..952a2c81 100644 --- a/packages/wyatt_bloc_layout/lib/src/presentation/bottom_navigation_bar_bloc_layout/bottom_navigation_bar_grid_layout_cubit_screen_crud_list.dart +++ b/packages/wyatt_bloc_layout/lib/src/presentation/bottom_navigation_bar_bloc_layout/bottom_navigation_bar_grid_layout_cubit_screen_crud_list.dart @@ -16,6 +16,7 @@ import 'package:flutter_bloc/flutter_bloc.dart' as bloc_base; import 'package:wyatt_bloc_layout/wyatt_bloc_layout.dart'; +import 'package:wyatt_crud_bloc/wyatt_crud_bloc.dart'; abstract class BottomNavigationBarGridLayoutCubitScreenCrudList< Cubit extends bloc_base.Cubit, SuccessType extends Object?> diff --git a/packages/wyatt_bloc_layout/lib/src/presentation/bottom_navigation_bar_bloc_layout/bottom_navigation_bar_layout_cubit_screen.dart b/packages/wyatt_bloc_layout/lib/src/presentation/bottom_navigation_bar_bloc_layout/bottom_navigation_bar_layout_cubit_screen.dart index c729a0f6..0a02294f 100644 --- a/packages/wyatt_bloc_layout/lib/src/presentation/bottom_navigation_bar_bloc_layout/bottom_navigation_bar_layout_cubit_screen.dart +++ b/packages/wyatt_bloc_layout/lib/src/presentation/bottom_navigation_bar_bloc_layout/bottom_navigation_bar_layout_cubit_screen.dart @@ -18,6 +18,8 @@ import 'package:flutter/material.dart'; import 'package:flutter_bloc/flutter_bloc.dart' as bloc_base; import 'package:wyatt_bloc_layout/wyatt_bloc_layout.dart'; +import 'package:wyatt_ui_components/wyatt_ui_components.dart'; +import 'package:wyatt_ui_layout/wyatt_ui_layout.dart'; abstract class BottomNavigationBarLayoutCubitScreen< Cubit extends bloc_base.Cubit, diff --git a/packages/wyatt_bloc_layout/lib/src/presentation/bottom_navigation_bar_bloc_layout/bottom_navigation_bar_layout_cubit_screen_crud.dart b/packages/wyatt_bloc_layout/lib/src/presentation/bottom_navigation_bar_bloc_layout/bottom_navigation_bar_layout_cubit_screen_crud.dart index 16cc1abf..c1cc938d 100644 --- a/packages/wyatt_bloc_layout/lib/src/presentation/bottom_navigation_bar_bloc_layout/bottom_navigation_bar_layout_cubit_screen_crud.dart +++ b/packages/wyatt_bloc_layout/lib/src/presentation/bottom_navigation_bar_bloc_layout/bottom_navigation_bar_layout_cubit_screen_crud.dart @@ -17,6 +17,7 @@ import 'package:flutter/material.dart'; import 'package:flutter_bloc/flutter_bloc.dart' as bloc_base; import 'package:wyatt_bloc_layout/wyatt_bloc_layout.dart'; +import 'package:wyatt_crud_bloc/wyatt_crud_bloc.dart'; abstract class BottomNavigationBarLayoutCubitScreenCrud< Cubit extends bloc_base.Cubit, diff --git a/packages/wyatt_bloc_layout/lib/src/presentation/bottom_navigation_bar_bloc_layout/bottom_navigation_bar_layout_cubit_screen_crud_item.dart b/packages/wyatt_bloc_layout/lib/src/presentation/bottom_navigation_bar_bloc_layout/bottom_navigation_bar_layout_cubit_screen_crud_item.dart index f2bbdb07..69ff4371 100644 --- a/packages/wyatt_bloc_layout/lib/src/presentation/bottom_navigation_bar_bloc_layout/bottom_navigation_bar_layout_cubit_screen_crud_item.dart +++ b/packages/wyatt_bloc_layout/lib/src/presentation/bottom_navigation_bar_bloc_layout/bottom_navigation_bar_layout_cubit_screen_crud_item.dart @@ -16,6 +16,7 @@ import 'package:flutter_bloc/flutter_bloc.dart' as bloc_base; import 'package:wyatt_bloc_layout/wyatt_bloc_layout.dart'; +import 'package:wyatt_crud_bloc/wyatt_crud_bloc.dart'; abstract class BottomNavigationBarLayoutCubitScreenCrudItem< Cubit extends bloc_base.Cubit, SuccessType extends Object?> diff --git a/packages/wyatt_bloc_layout/lib/src/presentation/bottom_navigation_bar_bloc_layout/bottom_navigation_bar_layout_cubit_screen_crud_list.dart b/packages/wyatt_bloc_layout/lib/src/presentation/bottom_navigation_bar_bloc_layout/bottom_navigation_bar_layout_cubit_screen_crud_list.dart index cce7f2a4..7c6c5b21 100644 --- a/packages/wyatt_bloc_layout/lib/src/presentation/bottom_navigation_bar_bloc_layout/bottom_navigation_bar_layout_cubit_screen_crud_list.dart +++ b/packages/wyatt_bloc_layout/lib/src/presentation/bottom_navigation_bar_bloc_layout/bottom_navigation_bar_layout_cubit_screen_crud_list.dart @@ -16,6 +16,7 @@ import 'package:flutter_bloc/flutter_bloc.dart' as bloc_base; import 'package:wyatt_bloc_layout/wyatt_bloc_layout.dart'; +import 'package:wyatt_crud_bloc/wyatt_crud_bloc.dart'; abstract class BottomNavigationBarLayoutCubitScreenCrudList< Cubit extends bloc_base.Cubit, SuccessType extends Object?> diff --git a/packages/wyatt_bloc_layout/lib/src/presentation/cubit_screen_base.dart b/packages/wyatt_bloc_layout/lib/src/presentation/cubit_screen_base.dart index b4848316..4dc4107a 100644 --- a/packages/wyatt_bloc_layout/lib/src/presentation/cubit_screen_base.dart +++ b/packages/wyatt_bloc_layout/lib/src/presentation/cubit_screen_base.dart @@ -15,7 +15,7 @@ // along with this program. If not, see . import 'package:flutter_bloc/flutter_bloc.dart' as bloc_base; -import 'package:wyatt_bloc_layout/wyatt_bloc_layout.dart'; +import 'package:wyatt_bloc_helper/wyatt_bloc_helper.dart'; abstract class CubitScreenBase, State extends Object> extends CubitScreen { diff --git a/packages/wyatt_bloc_layout/lib/src/presentation/cubit_screen_crud_base.dart b/packages/wyatt_bloc_layout/lib/src/presentation/cubit_screen_crud_base.dart index a113c5ad..ad9142f8 100644 --- a/packages/wyatt_bloc_layout/lib/src/presentation/cubit_screen_crud_base.dart +++ b/packages/wyatt_bloc_layout/lib/src/presentation/cubit_screen_crud_base.dart @@ -17,6 +17,7 @@ import 'package:flutter/material.dart'; import 'package:flutter_bloc/flutter_bloc.dart' as bloc_base; import 'package:wyatt_bloc_layout/wyatt_bloc_layout.dart'; +import 'package:wyatt_crud_bloc/wyatt_crud_bloc.dart'; abstract class CubitScreenCrudBase, CrudSuccessState extends CrudSuccess> diff --git a/packages/wyatt_bloc_layout/lib/src/presentation/cubit_screen_crud_item_base.dart b/packages/wyatt_bloc_layout/lib/src/presentation/cubit_screen_crud_item_base.dart index 5e81a799..3fe2becb 100644 --- a/packages/wyatt_bloc_layout/lib/src/presentation/cubit_screen_crud_item_base.dart +++ b/packages/wyatt_bloc_layout/lib/src/presentation/cubit_screen_crud_item_base.dart @@ -16,6 +16,7 @@ import 'package:flutter_bloc/flutter_bloc.dart' as bloc_base; import 'package:wyatt_bloc_layout/wyatt_bloc_layout.dart'; +import 'package:wyatt_crud_bloc/wyatt_crud_bloc.dart'; abstract class CubitScreenCrudItemBase, T extends Object?> extends CubitScreenCrudBase> { diff --git a/packages/wyatt_bloc_layout/lib/src/presentation/cubit_screen_crud_list_base.dart b/packages/wyatt_bloc_layout/lib/src/presentation/cubit_screen_crud_list_base.dart index d641b6b5..f886138e 100644 --- a/packages/wyatt_bloc_layout/lib/src/presentation/cubit_screen_crud_list_base.dart +++ b/packages/wyatt_bloc_layout/lib/src/presentation/cubit_screen_crud_list_base.dart @@ -16,6 +16,7 @@ import 'package:flutter_bloc/flutter_bloc.dart' as bloc_base; import 'package:wyatt_bloc_layout/wyatt_bloc_layout.dart'; +import 'package:wyatt_crud_bloc/wyatt_crud_bloc.dart'; abstract class CubitScreenCrudListBase, T extends Object?> extends CubitScreenCrudBase> { diff --git a/packages/wyatt_bloc_layout/lib/src/presentation/frame_bloc_layout/frame_grid_layout_cubit_screen_crud_list.dart b/packages/wyatt_bloc_layout/lib/src/presentation/frame_bloc_layout/frame_grid_layout_cubit_screen_crud_list.dart index e62fea8c..e54e5c49 100644 --- a/packages/wyatt_bloc_layout/lib/src/presentation/frame_bloc_layout/frame_grid_layout_cubit_screen_crud_list.dart +++ b/packages/wyatt_bloc_layout/lib/src/presentation/frame_bloc_layout/frame_grid_layout_cubit_screen_crud_list.dart @@ -16,6 +16,7 @@ import 'package:flutter_bloc/flutter_bloc.dart' as bloc_base; import 'package:wyatt_bloc_layout/wyatt_bloc_layout.dart'; +import 'package:wyatt_crud_bloc/wyatt_crud_bloc.dart'; abstract class FrameLayoutGridCubitScreenCrudList< Cubit extends bloc_base.Cubit, SuccessType extends Object?> diff --git a/packages/wyatt_bloc_layout/lib/src/presentation/frame_bloc_layout/frame_layout_cubit_screen.dart b/packages/wyatt_bloc_layout/lib/src/presentation/frame_bloc_layout/frame_layout_cubit_screen.dart index d8631d8e..51985223 100644 --- a/packages/wyatt_bloc_layout/lib/src/presentation/frame_bloc_layout/frame_layout_cubit_screen.dart +++ b/packages/wyatt_bloc_layout/lib/src/presentation/frame_bloc_layout/frame_layout_cubit_screen.dart @@ -18,6 +18,8 @@ import 'package:flutter/material.dart'; import 'package:flutter_bloc/flutter_bloc.dart' as bloc_base; import 'package:wyatt_bloc_layout/wyatt_bloc_layout.dart'; +import 'package:wyatt_ui_components/wyatt_ui_components.dart'; +import 'package:wyatt_ui_layout/wyatt_ui_layout.dart'; abstract class FrameLayoutCubitScreen, State extends Object> extends CubitScreenBase { diff --git a/packages/wyatt_bloc_layout/lib/src/presentation/frame_bloc_layout/frame_layout_cubit_screen_crud.dart b/packages/wyatt_bloc_layout/lib/src/presentation/frame_bloc_layout/frame_layout_cubit_screen_crud.dart index a498490b..62e5fc91 100644 --- a/packages/wyatt_bloc_layout/lib/src/presentation/frame_bloc_layout/frame_layout_cubit_screen_crud.dart +++ b/packages/wyatt_bloc_layout/lib/src/presentation/frame_bloc_layout/frame_layout_cubit_screen_crud.dart @@ -17,6 +17,7 @@ import 'package:flutter/material.dart'; import 'package:flutter_bloc/flutter_bloc.dart' as bloc_base; import 'package:wyatt_bloc_layout/wyatt_bloc_layout.dart'; +import 'package:wyatt_crud_bloc/wyatt_crud_bloc.dart'; abstract class FrameLayoutCubitScreenCrud< Cubit extends bloc_base.Cubit, diff --git a/packages/wyatt_bloc_layout/lib/src/presentation/frame_bloc_layout/frame_layout_cubit_screen_crud_item.dart b/packages/wyatt_bloc_layout/lib/src/presentation/frame_bloc_layout/frame_layout_cubit_screen_crud_item.dart index 92db37fa..80381609 100644 --- a/packages/wyatt_bloc_layout/lib/src/presentation/frame_bloc_layout/frame_layout_cubit_screen_crud_item.dart +++ b/packages/wyatt_bloc_layout/lib/src/presentation/frame_bloc_layout/frame_layout_cubit_screen_crud_item.dart @@ -16,6 +16,7 @@ import 'package:flutter_bloc/flutter_bloc.dart' as bloc_base; import 'package:wyatt_bloc_layout/wyatt_bloc_layout.dart'; +import 'package:wyatt_crud_bloc/wyatt_crud_bloc.dart'; abstract class FrameLayoutCubitScreenCrudItem< Cubit extends bloc_base.Cubit, SuccessType extends Object?> diff --git a/packages/wyatt_bloc_layout/lib/src/presentation/frame_bloc_layout/frame_layout_cubit_screen_crud_list.dart b/packages/wyatt_bloc_layout/lib/src/presentation/frame_bloc_layout/frame_layout_cubit_screen_crud_list.dart index 8c38994a..6bbf7a6b 100644 --- a/packages/wyatt_bloc_layout/lib/src/presentation/frame_bloc_layout/frame_layout_cubit_screen_crud_list.dart +++ b/packages/wyatt_bloc_layout/lib/src/presentation/frame_bloc_layout/frame_layout_cubit_screen_crud_list.dart @@ -16,6 +16,7 @@ import 'package:flutter_bloc/flutter_bloc.dart' as bloc_base; import 'package:wyatt_bloc_layout/wyatt_bloc_layout.dart'; +import 'package:wyatt_crud_bloc/wyatt_crud_bloc.dart'; abstract class FrameLayoutCubitScreenCrudList< Cubit extends bloc_base.Cubit, SuccessType extends Object?> diff --git a/packages/wyatt_bloc_layout/lib/src/presentation/grid_cubit_screen_crud_list_base.dart b/packages/wyatt_bloc_layout/lib/src/presentation/grid_cubit_screen_crud_list_base.dart index 28931c40..c95cb338 100644 --- a/packages/wyatt_bloc_layout/lib/src/presentation/grid_cubit_screen_crud_list_base.dart +++ b/packages/wyatt_bloc_layout/lib/src/presentation/grid_cubit_screen_crud_list_base.dart @@ -16,6 +16,7 @@ import 'package:flutter_bloc/flutter_bloc.dart' as bloc_base; import 'package:wyatt_bloc_layout/wyatt_bloc_layout.dart'; +import 'package:wyatt_crud_bloc/wyatt_crud_bloc.dart'; abstract class GridCubitScreenCrudListBase< Cubit extends bloc_base.Cubit, T extends Object?> diff --git a/packages/wyatt_bloc_layout/lib/src/presentation/top_app_bar_bloc_layout/top_app_bar_grid_layout_cubit_screen_crud_list.dart b/packages/wyatt_bloc_layout/lib/src/presentation/top_app_bar_bloc_layout/top_app_bar_grid_layout_cubit_screen_crud_list.dart index efc7ecdc..e20a1842 100644 --- a/packages/wyatt_bloc_layout/lib/src/presentation/top_app_bar_bloc_layout/top_app_bar_grid_layout_cubit_screen_crud_list.dart +++ b/packages/wyatt_bloc_layout/lib/src/presentation/top_app_bar_bloc_layout/top_app_bar_grid_layout_cubit_screen_crud_list.dart @@ -16,6 +16,7 @@ import 'package:flutter_bloc/flutter_bloc.dart' as bloc_base; import 'package:wyatt_bloc_layout/wyatt_bloc_layout.dart'; +import 'package:wyatt_crud_bloc/wyatt_crud_bloc.dart'; abstract class TopAppBarGridLayoutCubitScreenCrudList< Cubit extends bloc_base.Cubit, SuccessType extends Object?> diff --git a/packages/wyatt_bloc_layout/lib/src/presentation/top_app_bar_bloc_layout/top_app_bar_layout_cubit_screen.dart b/packages/wyatt_bloc_layout/lib/src/presentation/top_app_bar_bloc_layout/top_app_bar_layout_cubit_screen.dart index 80479742..48fe0abe 100644 --- a/packages/wyatt_bloc_layout/lib/src/presentation/top_app_bar_bloc_layout/top_app_bar_layout_cubit_screen.dart +++ b/packages/wyatt_bloc_layout/lib/src/presentation/top_app_bar_bloc_layout/top_app_bar_layout_cubit_screen.dart @@ -18,6 +18,8 @@ import 'package:flutter/material.dart'; import 'package:flutter_bloc/flutter_bloc.dart' as bloc_base; import 'package:wyatt_bloc_layout/wyatt_bloc_layout.dart'; +import 'package:wyatt_ui_components/wyatt_ui_components.dart'; +import 'package:wyatt_ui_layout/wyatt_ui_layout.dart'; abstract class TopAppBarLayoutCubitScreen, State extends Object> extends CubitScreenBase { diff --git a/packages/wyatt_bloc_layout/lib/src/presentation/top_app_bar_bloc_layout/top_app_bar_layout_cubit_screen_crud.dart b/packages/wyatt_bloc_layout/lib/src/presentation/top_app_bar_bloc_layout/top_app_bar_layout_cubit_screen_crud.dart index 1de4081a..efa82d3e 100644 --- a/packages/wyatt_bloc_layout/lib/src/presentation/top_app_bar_bloc_layout/top_app_bar_layout_cubit_screen_crud.dart +++ b/packages/wyatt_bloc_layout/lib/src/presentation/top_app_bar_bloc_layout/top_app_bar_layout_cubit_screen_crud.dart @@ -17,6 +17,7 @@ import 'package:flutter/material.dart'; import 'package:flutter_bloc/flutter_bloc.dart' as bloc_base; import 'package:wyatt_bloc_layout/wyatt_bloc_layout.dart'; +import 'package:wyatt_crud_bloc/wyatt_crud_bloc.dart'; abstract class TopAppBarLayoutCubitScreenCrud< Cubit extends bloc_base.Cubit, diff --git a/packages/wyatt_bloc_layout/lib/src/presentation/top_app_bar_bloc_layout/top_app_bar_layout_cubit_screen_crud_item.dart b/packages/wyatt_bloc_layout/lib/src/presentation/top_app_bar_bloc_layout/top_app_bar_layout_cubit_screen_crud_item.dart index 9e90c286..dd7e2bb1 100644 --- a/packages/wyatt_bloc_layout/lib/src/presentation/top_app_bar_bloc_layout/top_app_bar_layout_cubit_screen_crud_item.dart +++ b/packages/wyatt_bloc_layout/lib/src/presentation/top_app_bar_bloc_layout/top_app_bar_layout_cubit_screen_crud_item.dart @@ -16,6 +16,7 @@ import 'package:flutter_bloc/flutter_bloc.dart' as bloc_base; import 'package:wyatt_bloc_layout/wyatt_bloc_layout.dart'; +import 'package:wyatt_crud_bloc/wyatt_crud_bloc.dart'; abstract class TopAppBarLayoutCubitScreenCrudItem< Cubit extends bloc_base.Cubit, SuccessType extends Object?> diff --git a/packages/wyatt_bloc_layout/lib/src/presentation/top_app_bar_bloc_layout/top_app_bar_layout_cubit_screen_crud_list.dart b/packages/wyatt_bloc_layout/lib/src/presentation/top_app_bar_bloc_layout/top_app_bar_layout_cubit_screen_crud_list.dart index 9bc6047d..902ce24c 100644 --- a/packages/wyatt_bloc_layout/lib/src/presentation/top_app_bar_bloc_layout/top_app_bar_layout_cubit_screen_crud_list.dart +++ b/packages/wyatt_bloc_layout/lib/src/presentation/top_app_bar_bloc_layout/top_app_bar_layout_cubit_screen_crud_list.dart @@ -16,6 +16,7 @@ import 'package:flutter_bloc/flutter_bloc.dart' as bloc_base; import 'package:wyatt_bloc_layout/wyatt_bloc_layout.dart'; +import 'package:wyatt_crud_bloc/wyatt_crud_bloc.dart'; abstract class TopAppBarLayoutCubitScreenCrudList< Cubit extends bloc_base.Cubit, SuccessType extends Object?> diff --git a/packages/wyatt_bloc_layout/lib/src/presentation/top_navigation_bar_bloc_layout/top_navigation_bar_grid_layout_cubit_screen_crud_list.dart b/packages/wyatt_bloc_layout/lib/src/presentation/top_navigation_bar_bloc_layout/top_navigation_bar_grid_layout_cubit_screen_crud_list.dart index 238079ba..b57d29cf 100644 --- a/packages/wyatt_bloc_layout/lib/src/presentation/top_navigation_bar_bloc_layout/top_navigation_bar_grid_layout_cubit_screen_crud_list.dart +++ b/packages/wyatt_bloc_layout/lib/src/presentation/top_navigation_bar_bloc_layout/top_navigation_bar_grid_layout_cubit_screen_crud_list.dart @@ -16,6 +16,7 @@ import 'package:flutter_bloc/flutter_bloc.dart' as bloc_base; import 'package:wyatt_bloc_layout/wyatt_bloc_layout.dart'; +import 'package:wyatt_crud_bloc/wyatt_crud_bloc.dart'; abstract class TopNavigationBarGridLayoutCubitScreenCrudList< Cubit extends bloc_base.Cubit, SuccessType extends Object?> diff --git a/packages/wyatt_bloc_layout/lib/src/presentation/top_navigation_bar_bloc_layout/top_navigation_bar_layout_cubit_screen.dart b/packages/wyatt_bloc_layout/lib/src/presentation/top_navigation_bar_bloc_layout/top_navigation_bar_layout_cubit_screen.dart index 7978b76f..b1903cdc 100644 --- a/packages/wyatt_bloc_layout/lib/src/presentation/top_navigation_bar_bloc_layout/top_navigation_bar_layout_cubit_screen.dart +++ b/packages/wyatt_bloc_layout/lib/src/presentation/top_navigation_bar_bloc_layout/top_navigation_bar_layout_cubit_screen.dart @@ -18,6 +18,8 @@ import 'package:flutter/material.dart'; import 'package:flutter_bloc/flutter_bloc.dart' as bloc_base; import 'package:wyatt_bloc_layout/wyatt_bloc_layout.dart'; +import 'package:wyatt_ui_components/wyatt_ui_components.dart'; +import 'package:wyatt_ui_layout/wyatt_ui_layout.dart'; abstract class TopNavigationBarLayoutCubitScreen< Cubit extends bloc_base.Cubit, diff --git a/packages/wyatt_bloc_layout/lib/src/presentation/top_navigation_bar_bloc_layout/top_navigation_bar_layout_cubit_screen_crud.dart b/packages/wyatt_bloc_layout/lib/src/presentation/top_navigation_bar_bloc_layout/top_navigation_bar_layout_cubit_screen_crud.dart index 65bd7bff..76bd6beb 100644 --- a/packages/wyatt_bloc_layout/lib/src/presentation/top_navigation_bar_bloc_layout/top_navigation_bar_layout_cubit_screen_crud.dart +++ b/packages/wyatt_bloc_layout/lib/src/presentation/top_navigation_bar_bloc_layout/top_navigation_bar_layout_cubit_screen_crud.dart @@ -17,6 +17,7 @@ import 'package:flutter/material.dart'; import 'package:flutter_bloc/flutter_bloc.dart' as bloc_base; import 'package:wyatt_bloc_layout/wyatt_bloc_layout.dart'; +import 'package:wyatt_crud_bloc/wyatt_crud_bloc.dart'; abstract class TopNavigationBarLayoutCubitScreenCrud< Cubit extends bloc_base.Cubit, diff --git a/packages/wyatt_bloc_layout/lib/src/presentation/top_navigation_bar_bloc_layout/top_navigation_bar_layout_cubit_screen_crud_item.dart b/packages/wyatt_bloc_layout/lib/src/presentation/top_navigation_bar_bloc_layout/top_navigation_bar_layout_cubit_screen_crud_item.dart index 6b4c022b..112b8844 100644 --- a/packages/wyatt_bloc_layout/lib/src/presentation/top_navigation_bar_bloc_layout/top_navigation_bar_layout_cubit_screen_crud_item.dart +++ b/packages/wyatt_bloc_layout/lib/src/presentation/top_navigation_bar_bloc_layout/top_navigation_bar_layout_cubit_screen_crud_item.dart @@ -16,6 +16,7 @@ import 'package:flutter_bloc/flutter_bloc.dart' as bloc_base; import 'package:wyatt_bloc_layout/wyatt_bloc_layout.dart'; +import 'package:wyatt_crud_bloc/wyatt_crud_bloc.dart'; abstract class TopNavigationBarLayoutCubitScreenCrudItem< Cubit extends bloc_base.Cubit, SuccessType extends Object?> diff --git a/packages/wyatt_bloc_layout/lib/src/presentation/top_navigation_bar_bloc_layout/top_navigation_bar_layout_cubit_screen_crud_list.dart b/packages/wyatt_bloc_layout/lib/src/presentation/top_navigation_bar_bloc_layout/top_navigation_bar_layout_cubit_screen_crud_list.dart index 0b04c6f2..0f17b282 100644 --- a/packages/wyatt_bloc_layout/lib/src/presentation/top_navigation_bar_bloc_layout/top_navigation_bar_layout_cubit_screen_crud_list.dart +++ b/packages/wyatt_bloc_layout/lib/src/presentation/top_navigation_bar_bloc_layout/top_navigation_bar_layout_cubit_screen_crud_list.dart @@ -16,6 +16,7 @@ import 'package:flutter_bloc/flutter_bloc.dart' as bloc_base; import 'package:wyatt_bloc_layout/wyatt_bloc_layout.dart'; +import 'package:wyatt_crud_bloc/wyatt_crud_bloc.dart'; abstract class TopNavigationBarLayoutCubitScreenCrudList< Cubit extends bloc_base.Cubit, SuccessType extends Object?> diff --git a/packages/wyatt_bloc_layout/lib/src/src.dart b/packages/wyatt_bloc_layout/lib/src/src.dart index 4da50dac..d35a3ae0 100644 --- a/packages/wyatt_bloc_layout/lib/src/src.dart +++ b/packages/wyatt_bloc_layout/lib/src/src.dart @@ -14,11 +14,5 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . -export 'package:flutter_bloc/flutter_bloc.dart'; -export 'package:wyatt_bloc_helper/wyatt_bloc_helper.dart'; -export 'package:wyatt_crud_bloc/wyatt_crud_bloc.dart'; -export 'package:wyatt_ui_components/wyatt_ui_components.dart'; -export 'package:wyatt_ui_layout/wyatt_ui_layout.dart'; - export 'core/core.dart'; export 'presentation/presentation.dart'; diff --git a/packages/wyatt_bloc_layout/pubspec.yaml b/packages/wyatt_bloc_layout/pubspec.yaml index 11e03807..538ebf97 100644 --- a/packages/wyatt_bloc_layout/pubspec.yaml +++ b/packages/wyatt_bloc_layout/pubspec.yaml @@ -3,43 +3,35 @@ description: Layouts based on bloc helper library repository: https://git.wyatt-studio.fr/Wyatt-FOSS/wyatt-packages/src/branch/master/packages/wyatt_bloc_layout version: 0.0.1 -publish_to: "none" +publish_to: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub environment: sdk: ">=2.17.0 <3.0.0" dependencies: - flutter: - sdk: flutter - + flutter: { sdk: flutter } + flutter_bloc: ^8.1.2 wyatt_bloc_helper: - git: - url: https://git.wyatt-studio.fr/Wyatt-FOSS/wyatt-packages - path: packages/wyatt_bloc_helper + hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub + version: ^2.0.0 wyatt_ui_layout: - git: - url: https://git.wyatt-studio.fr/Wyatt-FOSS/wyatt-packages - path: packages/wyatt_ui_layout + hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub + version: ^0.0.1 wyatt_crud_bloc: - git: - url: https://git.wyatt-studio.fr/Wyatt-FOSS/wyatt-packages - path: packages/wyatt_crud_bloc + hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub + version: ^0.1.0+2 wyatt_ui_components: - git: - url: https://git.wyatt-studio.fr/Wyatt-FOSS/wyatt-packages - path: packages/wyatt_ui_components + hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub + version: ^0.0.1 dev_dependencies: - flutter_test: - sdk: flutter + flutter_test: { sdk: flutter } wyatt_analysis: - git: - url: https://git.wyatt-studio.fr/Wyatt-FOSS/wyatt-packages - ref: wyatt_analysis-v2.4.1 - path: packages/wyatt_analysis + hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub + version: ^2.4.1 diff --git a/packages/wyatt_crud_bloc/.pubignore b/packages/wyatt_crud_bloc/.pubignore deleted file mode 100644 index 4ad4d99b..00000000 --- a/packages/wyatt_crud_bloc/.pubignore +++ /dev/null @@ -1,2 +0,0 @@ -google-services.json -.vscode \ No newline at end of file diff --git a/packages/wyatt_crud_bloc/.pubignore b/packages/wyatt_crud_bloc/.pubignore new file mode 120000 index 00000000..52b2f28d --- /dev/null +++ b/packages/wyatt_crud_bloc/.pubignore @@ -0,0 +1 @@ +../../.pubignore \ No newline at end of file diff --git a/packages/wyatt_form_bloc/.pubignore b/packages/wyatt_form_bloc/.pubignore deleted file mode 100644 index 11610c5a..00000000 --- a/packages/wyatt_form_bloc/.pubignore +++ /dev/null @@ -1,2 +0,0 @@ -firebase_options.dart -.vscode \ No newline at end of file diff --git a/packages/wyatt_form_bloc/.pubignore b/packages/wyatt_form_bloc/.pubignore new file mode 120000 index 00000000..52b2f28d --- /dev/null +++ b/packages/wyatt_form_bloc/.pubignore @@ -0,0 +1 @@ +../../.pubignore \ No newline at end of file -- 2.47.2 From 0a13c67058db39b10c03ce3d9b069b944780a45d Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Thu, 13 Apr 2023 23:43:57 +0200 Subject: [PATCH 45/47] refactor(authentication): remove cross package export --- packages/wyatt_authentication_bloc/README.md | 4 +- .../doc/api/__404error.md | 6 - .../doc/api/categories.json | 1 - .../doc/api/index.json | 1 - .../doc/api/index.md | 214 ------ .../doc/api/search.md | 6 - .../Account-class.md | 237 ------ .../Account/Account.md | 43 -- .../Account/accessToken.md | 34 - .../Account/creationTime.md | 35 - .../Account/email.md | 35 - .../Account/emailVerified.md | 35 - .../wyatt_authentication_bloc/Account/id.md | 34 - .../Account/isAnonymous.md | 34 - .../Account/isNewUser.md | 34 - .../Account/lastSignInTime.md | 34 - .../Account/phoneNumber.md | 36 - .../Account/photoURL.md | 36 - .../Account/props.md | 55 -- .../Account/providerId.md | 34 - .../Account/refreshToken.md | 34 - .../Account/stringify.md | 47 -- .../AccountModel-class.md | 247 ------ .../AccountModel.fromFirebaseUser.md | 51 -- ...AccountModel.fromFirebaseUserCredential.md | 54 -- .../AccountModel/refreshToken.md | 41 - .../AccountModel/user.md | 33 - .../ApplyActionCodeFailureFirebase-class.md | 137 ---- ...ApplyActionCodeFailureFirebase.fromCode.md | 49 -- .../ApplyActionCodeFailureFirebase.md | 31 - .../ApplyActionCodeFailureInterface-class.md | 139 ---- ...pplyActionCodeFailureInterface.fromCode.md | 31 - .../ApplyActionCodeFailureInterface.md | 31 - .../AuthFormField-class.md | 122 --- .../AuthFormField/AuthFormField.md | 25 - .../AuthFormField/confirmPassword-constant.md | 34 - .../AuthFormField/email-constant.md | 34 - .../AuthFormField/password-constant.md | 34 - .../AuthFormName-class.md | 131 ---- .../AuthFormName/AuthFormName.md | 25 - .../AuthFormName/editAccountForm-constant.md | 34 - .../passwordResetForm-constant.md | 34 - .../AuthFormName/signInForm-constant.md | 34 - .../AuthFormName/signUpForm-constant.md | 34 - .../AuthenticationBuilder-class.md | 216 ------ .../AuthenticationBuilder.md | 35 - .../AuthenticationBuilder/authenticated.md | 36 - .../AuthenticationBuilder/build.md | 85 -- .../AuthenticationBuilder/unauthenticated.md | 33 - .../AuthenticationBuilder/unknown.md | 33 - .../AuthenticationChangeEvent-class.md | 137 ---- .../AuthenticationChangeEvent.md | 30 - .../AuthenticationChangeEvent/props.md | 42 - .../AuthenticationChangeEvent/stringify.md | 47 -- .../AuthenticationCubit-class.md | 292 ------- .../AuthenticationCubit.md | 34 - .../authenticationRepository.md | 33 - .../AuthenticationCubit/currentSession.md | 37 - .../AuthenticationCubit/delete.md | 44 -- .../AuthenticationCubit/onDelete.md | 38 - .../AuthenticationCubit/onReauthenticate.md | 38 - .../AuthenticationCubit/onRefresh.md | 37 - .../AuthenticationCubit/onSignInFromCache.md | 38 - .../AuthenticationCubit/onSignOut.md | 37 - .../AuthenticationCubit/reauthenticate.md | 53 -- .../AuthenticationCubit/refresh.md | 49 -- .../AuthenticationCubit/signOut.md | 43 -- .../AuthenticationFailureInterface-class.md | 159 ---- ...AuthenticationFailureInterface.fromCode.md | 31 - .../AuthenticationFailureInterface.md | 30 - .../AuthenticationFailureInterface/code.md | 33 - .../AuthenticationFailureInterface/message.md | 40 - .../AuthenticationFailureInterface/msg.md | 33 - .../toString.md | 53 -- ...henticationFirebaseDataSourceImpl-class.md | 251 ------ .../AuthenticationFirebaseDataSourceImpl.md | 40 - .../addSession.md | 40 - .../confirmPasswordReset.md | 53 -- .../delete.md | 48 -- .../reauthenticate.md | 61 -- .../refresh.md | 52 -- .../sendEmailVerification.md | 47 -- .../sendPasswordResetEmail.md | 47 -- .../sessionStream.md | 39 - .../signInAnonymously.md | 54 -- .../signInWithEmailAndPassword.md | 61 -- .../signInWithGoogle.md | 68 -- .../signOut.md | 46 -- .../signUpWithEmailAndPassword.md | 62 -- .../updateEmail.md | 55 -- .../updatePassword.md | 55 -- .../verifyPasswordResetCode.md | 48 -- .../AuthenticationRemoteDataSource-class.md | 247 ------ .../AuthenticationRemoteDataSource.md | 25 - .../addSession.md | 35 - .../confirmPasswordReset.md | 38 - .../AuthenticationRemoteDataSource/delete.md | 35 - .../reauthenticate.md | 35 - .../AuthenticationRemoteDataSource/refresh.md | 35 - .../sendEmailVerification.md | 35 - .../sendPasswordResetEmail.md | 35 - .../sessionStream.md | 35 - .../signInAnonymously.md | 35 - .../signInWithEmailAndPassword.md | 38 - .../signInWithGoogle.md | 35 - .../AuthenticationRemoteDataSource/signOut.md | 35 - .../signUpWithEmailAndPassword.md | 38 - .../updateEmail.md | 35 - .../updatePassword.md | 35 - .../verifyPasswordResetCode.md | 35 - .../AuthenticationRepository-class.md | 258 ------- .../AuthenticationRepository.md | 25 - .../AuthenticationRepository/addSession.md | 36 - .../confirmPasswordReset.md | 40 - .../AuthenticationRepository/delete.md | 38 - .../formRepository.md | 37 - .../reauthenticate.md | 40 - .../AuthenticationRepository/refresh.md | 36 - .../sendEmailVerification.md | 37 - .../sendPasswordResetEmail.md | 37 - .../AuthenticationRepository/sessionStream.md | 36 - .../signInAnonymously.md | 37 - .../signInWithEmailAndPassword.md | 41 - .../signInWithGoogle.md | 37 - .../AuthenticationRepository/signOut.md | 37 - .../signUpWithEmailAndPassword.md | 42 - .../AuthenticationRepository/updateEmail.md | 40 - .../updatePassword.md | 40 - .../verifyPasswordResetCode.md | 37 - .../AuthenticationRepositoryImpl-class.md | 269 ------- .../AuthenticationRepositoryImpl.md | 69 -- .../addSession.md | 39 - .../authenticationRemoteDataSource.md | 33 - .../confirmPasswordReset.md | 51 -- .../AuthenticationRepositoryImpl/delete.md | 44 -- .../formRepository.md | 41 - .../reauthenticate.md | 49 -- .../AuthenticationRepositoryImpl/refresh.md | 45 -- .../sendEmailVerification.md | 45 -- .../sendPasswordResetEmail.md | 47 -- .../sessionStream.md | 39 - .../signInAnonymously.md | 47 -- .../signInWithEmailAndPassword.md | 54 -- .../signInWithGoogle.md | 47 -- .../AuthenticationRepositoryImpl/signOut.md | 45 -- .../signUpWithEmailAndPassword.md | 55 -- .../updateEmail.md | 48 -- .../updatePassword.md | 49 -- .../verifyPasswordResetCode.md | 47 -- .../AuthenticationState-class.md | 150 ---- .../AuthenticationState.authenticated.md | 34 - .../AuthenticationState.unauthenticated.md | 31 - .../AuthenticationState.unknown.md | 31 - .../AuthenticationState/props.md | 42 - .../AuthenticationState/status.md | 33 - .../AuthenticationState/stringify.md | 47 -- .../AuthenticationState/wrapper.md | 33 - .../AuthenticationStatus.md | 151 ---- .../AuthenticationStatus.md | 25 - .../AuthenticationStatus/values-constant.md | 29 - .../BaseEditAccountCubit-class.md | 261 ------- .../BaseEditAccountCubit.md | 37 - .../authenticationRepository.md | 33 - .../BaseEditAccountCubit/dataChanged.md | 53 -- .../BaseEditAccountCubit/formName.md | 40 - .../BaseEditAccountCubit/formRepository.md | 36 - .../BaseEditAccountCubit/reset.md | 43 -- .../BaseEditAccountCubit/submit.md | 48 -- .../BaseEditAccountCubit/update.md | 48 -- .../BaseEditAccountCubit/validate.md | 42 - .../BaseSignInCubit-class.md | 261 ------- .../BaseSignInCubit/BaseSignInCubit.md | 37 - .../authenticationRepository.md | 33 - .../BaseSignInCubit/dataChanged.md | 53 -- .../BaseSignInCubit/formName.md | 40 - .../BaseSignInCubit/formRepository.md | 36 - .../BaseSignInCubit/reset.md | 43 -- .../BaseSignInCubit/submit.md | 48 -- .../BaseSignInCubit/update.md | 48 -- .../BaseSignInCubit/validate.md | 42 - .../BaseSignUpCubit-class.md | 261 ------- .../BaseSignUpCubit/BaseSignUpCubit.md | 37 - .../authenticationRepository.md | 33 - .../BaseSignUpCubit/dataChanged.md | 53 -- .../BaseSignUpCubit/formName.md | 40 - .../BaseSignUpCubit/formRepository.md | 36 - .../BaseSignUpCubit/reset.md | 43 -- .../BaseSignUpCubit/submit.md | 49 -- .../BaseSignUpCubit/update.md | 51 -- .../BaseSignUpCubit/validate.md | 42 - .../BuildContextExtension.md | 76 -- .../BuildContextExtension/account.md | 37 - .../BuildContextExtension/data.md | 37 - .../BuildContextExtension/session.md | 37 - .../BuildContextExtension/wrapper.md | 37 - ...nfirmPasswordResetFailureFirebase-class.md | 137 ---- ...rmPasswordResetFailureFirebase.fromCode.md | 30 - .../ConfirmPasswordResetFailureFirebase.md | 31 - ...firmPasswordResetFailureInterface-class.md | 139 ---- ...mPasswordResetFailureInterface.fromCode.md | 31 - .../ConfirmPasswordResetFailureInterface.md | 31 - .../CustomRoutine-class.md | 139 ---- .../CustomRoutine/CustomRoutine.md | 35 - .../CustomRoutine/attachedLogic.md | 35 - .../CustomRoutine/call.md | 55 -- .../CustomRoutine/onError.md | 33 - .../CustomRoutine/onSuccess.md | 33 - .../CustomRoutine/routine.md | 33 - .../DeleteAccountFailureFirebase-class.md | 137 ---- .../DeleteAccountFailureFirebase.fromCode.md | 39 - .../DeleteAccountFailureFirebase.md | 31 - .../DeleteAccountFailureInterface-class.md | 139 ---- .../DeleteAccountFailureInterface.fromCode.md | 30 - .../DeleteAccountFailureInterface.md | 30 - .../DeletedEvent-class.md | 126 --- .../DeletedEvent/DeletedEvent.md | 30 - .../EditAccountCubit-class.md | 335 -------- .../EditAccountCubit/EditAccountCubit.md | 30 - .../EditAccountCubit/onEmailUpdated.md | 42 - .../EditAccountCubit/onPasswordUpdated.md | 42 - .../EditAccountListener-class.md | 236 ------ .../EditAccountListener.md | 37 - .../EditAccountListener/build.md | 92 --- .../EditAccountListener/child.md | 33 - .../EditAccountListener/customBuilder.md | 34 - .../EditAccountListener/onError.md | 37 - .../EditAccountListener/onProgress.md | 33 - .../EditAccountListener/onSuccess.md | 33 - .../EditAccountState-class.md | 179 ----- .../EditAccountState/EditAccountState.md | 34 - .../EditAccountState/copyWith.md | 44 -- .../EditAccountState/email.md | 37 - .../EditAccountState/errorMessage.md | 34 - .../EditAccountState/form.md | 34 - .../EditAccountState/password.md | 37 - .../EditAccountState/props.md | 42 - .../EditAccountState/status.md | 34 - .../EditAccountState/toString.md | 48 -- .../EmailVerificationBuilder-class.md | 225 ------ .../EmailVerificationBuilder.md | 36 - .../EmailVerificationBuilder/build.md | 91 --- .../EmailVerificationBuilder/customBuilder.md | 34 - .../EmailVerificationBuilder/notVerified.md | 33 - .../EmailVerificationBuilder/onError.md | 37 - .../EmailVerificationBuilder/verified.md | 33 - .../EmailVerificationCubit-class.md | 211 ----- .../EmailVerificationCubit.md | 32 - .../authenticationRepository.md | 33 - .../checkEmailVerification.md | 65 -- .../sendEmailVerification.md | 47 -- .../EmailVerificationState-class.md | 160 ---- .../EmailVerificationState.md | 34 - .../EmailVerificationState/copyWith.md | 44 -- .../EmailVerificationState/errorMessage.md | 33 - .../EmailVerificationState/isVerified.md | 33 - .../EmailVerificationState/props.md | 42 - .../EmailVerificationState/status.md | 33 - .../EmailVerificationState/toString.md | 49 -- ...nInMethodsForEmailFailureFirebase-class.md | 137 ---- ...MethodsForEmailFailureFirebase.fromCode.md | 40 - ...tchSignInMethodsForEmailFailureFirebase.md | 31 - ...InMethodsForEmailFailureInterface-class.md | 139 ---- ...ethodsForEmailFailureInterface.fromCode.md | 32 - ...chSignInMethodsForEmailFailureInterface.md | 31 - .../ModelParsingFailureFirebase-class.md | 137 ---- .../ModelParsingFailureFirebase.fromCode.md | 30 - .../ModelParsingFailureFirebase.md | 31 - .../ModelParsingFailureInterface-class.md | 139 ---- .../ModelParsingFailureInterface.fromCode.md | 30 - .../ModelParsingFailureInterface.md | 30 - .../PasswordResetCubit-class.md | 275 ------- .../PasswordResetCubit/PasswordResetCubit.md | 37 - .../authenticationRepository.md | 33 - .../PasswordResetCubit/dataChanged.md | 53 -- .../PasswordResetCubit/emailChanged.md | 47 -- .../PasswordResetCubit/emailCustomChanged.md | 42 - .../PasswordResetCubit/formName.md | 40 - .../PasswordResetCubit/formRepository.md | 36 - .../PasswordResetCubit/reset.md | 43 -- .../PasswordResetCubit/submit.md | 70 -- .../PasswordResetCubit/update.md | 51 -- .../PasswordResetCubit/validate.md | 43 -- .../PasswordResetState-class.md | 169 ---- .../PasswordResetState/PasswordResetState.md | 34 - .../PasswordResetState/copyWith.md | 44 -- .../PasswordResetState/email.md | 36 - .../PasswordResetState/errorMessage.md | 34 - .../PasswordResetState/form.md | 34 - .../PasswordResetState/props.md | 42 - .../PasswordResetState/status.md | 34 - .../PasswordResetState/toString.md | 48 -- .../ReauthenticateFailureFirebase-class.md | 137 ---- .../ReauthenticateFailureFirebase.fromCode.md | 57 -- .../ReauthenticateFailureFirebase.md | 31 - .../ReauthenticateFailureInterface-class.md | 139 ---- ...ReauthenticateFailureInterface.fromCode.md | 30 - .../ReauthenticateFailureInterface.md | 30 - .../ReauthenticatedEvent-class.md | 137 ---- .../ReauthenticatedEvent.md | 30 - .../ReauthenticatedEvent/account.md | 33 - .../ReauthenticatedEvent/props.md | 42 - .../RefreshFailureFirebase-class.md | 137 ---- .../RefreshFailureFirebase.fromCode.md | 30 - .../RefreshFailureFirebase.md | 31 - .../RefreshFailureInterface-class.md | 139 ---- .../RefreshFailureInterface.fromCode.md | 31 - .../RefreshFailureInterface.md | 31 - .../RefreshedEvent-class.md | 136 ---- .../RefreshedEvent/RefreshedEvent.md | 30 - .../RefreshedEvent/account.md | 33 - .../RefreshedEvent/props.md | 42 - ...dEmailVerificationFailureFirebase-class.md | 137 ---- ...ailVerificationFailureFirebase.fromCode.md | 30 - .../SendEmailVerificationFailureFirebase.md | 31 - ...EmailVerificationFailureInterface-class.md | 139 ---- ...ilVerificationFailureInterface.fromCode.md | 31 - .../SendEmailVerificationFailureInterface.md | 31 - ...PasswordResetEmailFailureFirebase-class.md | 137 ---- ...swordResetEmailFailureFirebase.fromCode.md | 30 - .../SendPasswordResetEmailFailureFirebase.md | 31 - ...asswordResetEmailFailureInterface-class.md | 139 ---- ...wordResetEmailFailureInterface.fromCode.md | 32 - .../SendPasswordResetEmailFailureInterface.md | 31 - ...endSignInLinkEmailFailureFirebase-class.md | 137 ---- ...SignInLinkEmailFailureFirebase.fromCode.md | 30 - .../SendSignInLinkEmailFailureFirebase.md | 31 - ...ndSignInLinkEmailFailureInterface-class.md | 139 ---- ...ignInLinkEmailFailureInterface.fromCode.md | 31 - .../SendSignInLinkEmailFailureInterface.md | 31 - .../Session-class.md | 144 ---- .../Session/Session.md | 33 - .../Session/account.md | 33 - .../wyatt_authentication_bloc/Session/data.md | 33 - .../Session/props.md | 42 - .../Session/stringify.md | 47 -- .../SessionWrapper-class.md | 144 ---- .../SessionWrapper/SessionWrapper.md | 33 - .../SessionWrapper/event.md | 33 - .../SessionWrapper/props.md | 42 - .../SessionWrapper/session.md | 33 - .../SessionWrapper/stringify.md | 47 -- .../SignInAnonymously-mixin.md | 269 ------- .../SignInAnonymously/onSignInAnonymously.md | 39 - .../SignInAnonymously/signInAnonymously.md | 79 -- .../SignInAnonymouslyFailureFirebase-class.md | 137 ---- ...gnInAnonymouslyFailureFirebase.fromCode.md | 40 - .../SignInAnonymouslyFailureFirebase.md | 31 - ...SignInAnonymouslyFailureInterface-class.md | 139 ---- ...nInAnonymouslyFailureInterface.fromCode.md | 31 - .../SignInAnonymouslyFailureInterface.md | 31 - .../SignInCubit-class.md | 354 --------- .../SignInCubit/SignInCubit.md | 30 - .../SignInCubit/onSignInAnonymously.md | 42 - .../onSignInWithEmailAndPassword.md | 42 - .../SignInCubit/onSignInWithGoogle.md | 42 - .../SignInListener-class.md | 236 ------ .../SignInListener/SignInListener.md | 37 - .../SignInListener/build.md | 92 --- .../SignInListener/child.md | 33 - .../SignInListener/customBuilder.md | 33 - .../SignInListener/onError.md | 37 - .../SignInListener/onProgress.md | 33 - .../SignInListener/onSuccess.md | 33 - .../SignInState-class.md | 179 ----- .../SignInState/SignInState.md | 34 - .../SignInState/copyWith.md | 44 -- .../SignInState/email.md | 37 - .../SignInState/errorMessage.md | 34 - .../SignInState/form.md | 34 - .../SignInState/password.md | 37 - .../SignInState/props.md | 42 - .../SignInState/status.md | 34 - .../SignInState/toString.md | 48 -- .../SignInWithAppleFailureFirebase-class.md | 141 ---- ...SignInWithAppleFailureFirebase.fromCode.md | 30 - .../SignInWithAppleFailureFirebase.md | 30 - .../SignInWithAppleFailureInterface-class.md | 140 ---- ...ignInWithAppleFailureInterface.fromCode.md | 31 - .../SignInWithAppleFailureInterface.md | 31 - ...gnInWithCredentialFailureFirebase-class.md | 143 ---- ...nWithCredentialFailureFirebase.fromCode.md | 61 -- .../SignInWithCredentialFailureFirebase.md | 31 - ...nInWithCredentialFailureInterface-class.md | 139 ---- ...WithCredentialFailureInterface.fromCode.md | 31 - .../SignInWithCredentialFailureInterface.md | 31 - ...thEmailAndPasswordFailureFirebase-class.md | 137 ---- ...mailAndPasswordFailureFirebase.fromCode.md | 49 -- ...gnInWithEmailAndPasswordFailureFirebase.md | 31 - ...hEmailAndPasswordFailureInterface-class.md | 139 ---- ...ailAndPasswordFailureInterface.fromCode.md | 32 - ...nInWithEmailAndPasswordFailureInterface.md | 31 - ...ignInWithEmailLinkFailureFirebase-class.md | 137 ---- ...InWithEmailLinkFailureFirebase.fromCode.md | 46 -- .../SignInWithEmailLinkFailureFirebase.md | 31 - ...gnInWithEmailLinkFailureInterface-class.md | 139 ---- ...nWithEmailLinkFailureInterface.fromCode.md | 31 - .../SignInWithEmailLinkFailureInterface.md | 31 - .../SignInWithEmailPassword-mixin.md | 305 -------- .../SignInWithEmailPassword/emailChanged.md | 47 -- .../emailCustomChanged.md | 42 - .../onSignInWithEmailAndPassword.md | 39 - .../passwordChanged.md | 46 -- .../passwordCustomChanged.md | 42 - .../signInWithEmailAndPassword.md | 105 --- ...SignInWithFacebookFailureFirebase-class.md | 141 ---- ...nInWithFacebookFailureFirebase.fromCode.md | 30 - .../SignInWithFacebookFailureFirebase.md | 30 - ...ignInWithFacebookFailureInterface-class.md | 139 ---- ...InWithFacebookFailureInterface.fromCode.md | 31 - .../SignInWithFacebookFailureInterface.md | 31 - .../SignInWithGoogle-mixin.md | 269 ------- .../SignInWithGoogle/onSignInWithGoogle.md | 39 - .../SignInWithGoogle/signInWithGoogle.md | 78 -- .../SignInWithGoogleFailureFirebase-class.md | 141 ---- ...ignInWithGoogleFailureFirebase.fromCode.md | 30 - .../SignInWithGoogleFailureFirebase.md | 30 - .../SignInWithGoogleFailureInterface-class.md | 139 ---- ...gnInWithGoogleFailureInterface.fromCode.md | 31 - .../SignInWithGoogleFailureInterface.md | 31 - .../SignInWithTwitterFailureFirebase-class.md | 141 ---- ...gnInWithTwitterFailureFirebase.fromCode.md | 30 - .../SignInWithTwitterFailureFirebase.md | 30 - ...SignInWithTwitterFailureInterface-class.md | 136 ---- ...nInWithTwitterFailureInterface.fromCode.md | 31 - .../SignInWithTwitterFailureInterface.md | 31 - .../SignOutFailureFirebase-class.md | 137 ---- .../SignOutFailureFirebase.fromCode.md | 30 - .../SignOutFailureFirebase.md | 31 - .../SignOutFailureInterface-class.md | 139 ---- .../SignOutFailureInterface.fromCode.md | 31 - .../SignOutFailureInterface.md | 31 - .../SignUpCubit-class.md | 316 -------- .../SignUpCubit/SignUpCubit.md | 30 - .../onSignUpWithEmailAndPassword.md | 43 -- .../SignUpListener-class.md | 236 ------ .../SignUpListener/SignUpListener.md | 37 - .../SignUpListener/build.md | 92 --- .../SignUpListener/child.md | 33 - .../SignUpListener/customBuilder.md | 33 - .../SignUpListener/onError.md | 37 - .../SignUpListener/onProgress.md | 33 - .../SignUpListener/onSuccess.md | 33 - .../SignUpState-class.md | 179 ----- .../SignUpState/SignUpState.md | 34 - .../SignUpState/copyWith.md | 44 -- .../SignUpState/email.md | 37 - .../SignUpState/errorMessage.md | 34 - .../SignUpState/form.md | 34 - .../SignUpState/password.md | 37 - .../SignUpState/props.md | 42 - .../SignUpState/status.md | 34 - .../SignUpState/toString.md | 50 -- ...thEmailAndPasswordFailureFirebase-class.md | 137 ---- ...mailAndPasswordFailureFirebase.fromCode.md | 52 -- ...gnUpWithEmailAndPasswordFailureFirebase.md | 31 - ...hEmailAndPasswordFailureInterface-class.md | 139 ---- ...ailAndPasswordFailureInterface.fromCode.md | 32 - ...nUpWithEmailAndPasswordFailureInterface.md | 31 - .../SignUpWithEmailPassword-mixin.md | 305 -------- .../SignUpWithEmailPassword/emailChanged.md | 47 -- .../emailCustomChanged.md | 42 - .../onSignUpWithEmailAndPassword.md | 40 - .../passwordChanged.md | 46 -- .../passwordCustomChanged.md | 42 - .../signUpWithEmailPassword.md | 97 --- .../SignedInEvent-class.md | 135 ---- .../SignedInEvent/SignedInEvent.md | 30 - .../SignedInEvent/account.md | 33 - .../SignedInEvent/props.md | 42 - .../SignedInFromCacheEvent-class.md | 135 ---- .../SignedInFromCacheEvent.md | 30 - .../SignedInFromCacheEvent/account.md | 33 - .../SignedInFromCacheEvent/props.md | 42 - .../SignedOutEvent-class.md | 126 --- .../SignedOutEvent/SignedOutEvent.md | 30 - .../SignedUpEvent-class.md | 135 ---- .../SignedUpEvent/SignedUpEvent.md | 30 - .../SignedUpEvent/account.md | 33 - .../SignedUpEvent/props.md | 42 - .../UnknownAuthenticationEvent-class.md | 126 --- .../UnknownAuthenticationEvent.md | 30 - .../UpdateEmail-mixin.md | 287 ------- .../UpdateEmail/emailChanged.md | 47 -- .../UpdateEmail/emailCustomChanged.md | 42 - .../UpdateEmail/onEmailUpdated.md | 39 - .../UpdateEmail/updateEmail.md | 103 --- .../UpdateEmailFailureFirebase-class.md | 137 ---- .../UpdateEmailFailureFirebase.fromCode.md | 45 -- .../UpdateEmailFailureFirebase.md | 31 - .../UpdateEmailFailureInterface-class.md | 139 ---- .../UpdateEmailFailureInterface.fromCode.md | 30 - .../UpdateEmailFailureInterface.md | 30 - .../UpdatePassword-mixin.md | 287 ------- .../UpdatePassword/onPasswordUpdated.md | 39 - .../UpdatePassword/passwordChanged.md | 46 -- .../UpdatePassword/passwordCustomChanged.md | 42 - .../UpdatePassword/updatePassword.md | 103 --- .../UpdatePasswordFailureFirebase-class.md | 137 ---- .../UpdatePasswordFailureFirebase.fromCode.md | 42 - .../UpdatePasswordFailureFirebase.md | 31 - .../UpdatePasswordFailureInterface-class.md | 139 ---- ...UpdatePasswordFailureInterface.fromCode.md | 30 - .../UpdatePasswordFailureInterface.md | 30 - .../UpdatedEvent-class.md | 135 ---- .../UpdatedEvent/UpdatedEvent.md | 30 - .../UpdatedEvent/account.md | 33 - .../UpdatedEvent/props.md | 42 - ...yPasswordResetCodeFailureFirebase-class.md | 137 ---- ...sswordResetCodeFailureFirebase.fromCode.md | 31 - .../VerifyPasswordResetCodeFailureFirebase.md | 31 - ...PasswordResetCodeFailureInterface-class.md | 139 ---- ...swordResetCodeFailureInterface.fromCode.md | 32 - ...VerifyPasswordResetCodeFailureInterface.md | 31 - .../wyatt_authentication_bloc-library.md | 727 ------------------ .../lib/core/dependency_injection/get_it.dart | 2 + .../example/pubspec.yaml | 2 + .../lib/src/core/constants/storage.dart | 8 + ...ation_firebase_cache_data_source_impl.dart | 2 +- .../lib/wyatt_authentication_bloc.dart | 3 - .../wyatt_authentication_bloc/pubspec.yaml | 2 +- 520 files changed, 16 insertions(+), 33833 deletions(-) delete mode 100644 packages/wyatt_authentication_bloc/doc/api/__404error.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/categories.json delete mode 100644 packages/wyatt_authentication_bloc/doc/api/index.json delete mode 100644 packages/wyatt_authentication_bloc/doc/api/index.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/search.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/Account.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/accessToken.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/creationTime.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/email.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/emailVerified.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/id.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/isAnonymous.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/isNewUser.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/lastSignInTime.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/phoneNumber.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/photoURL.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/props.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/providerId.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/refreshToken.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/stringify.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AccountModel-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AccountModel/AccountModel.fromFirebaseUser.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AccountModel/AccountModel.fromFirebaseUserCredential.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AccountModel/refreshToken.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AccountModel/user.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ApplyActionCodeFailureFirebase-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ApplyActionCodeFailureFirebase/ApplyActionCodeFailureFirebase.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ApplyActionCodeFailureFirebase/ApplyActionCodeFailureFirebase.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ApplyActionCodeFailureInterface-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ApplyActionCodeFailureInterface/ApplyActionCodeFailureInterface.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ApplyActionCodeFailureInterface/ApplyActionCodeFailureInterface.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormField-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormField/AuthFormField.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormField/confirmPassword-constant.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormField/email-constant.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormField/password-constant.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormName-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormName/AuthFormName.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormName/editAccountForm-constant.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormName/passwordResetForm-constant.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormName/signInForm-constant.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormName/signUpForm-constant.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationBuilder-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationBuilder/AuthenticationBuilder.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationBuilder/authenticated.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationBuilder/build.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationBuilder/unauthenticated.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationBuilder/unknown.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationChangeEvent-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationChangeEvent/AuthenticationChangeEvent.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationChangeEvent/props.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationChangeEvent/stringify.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/AuthenticationCubit.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/authenticationRepository.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/currentSession.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/delete.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/onDelete.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/onReauthenticate.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/onRefresh.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/onSignInFromCache.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/onSignOut.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/reauthenticate.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/refresh.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/signOut.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface/AuthenticationFailureInterface.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface/AuthenticationFailureInterface.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface/code.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface/message.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/AuthenticationFirebaseDataSourceImpl.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/addSession.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/confirmPasswordReset.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/delete.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/reauthenticate.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/refresh.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/sendEmailVerification.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/sendPasswordResetEmail.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/sessionStream.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signInAnonymously.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signInWithEmailAndPassword.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signInWithGoogle.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signOut.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signUpWithEmailAndPassword.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/updateEmail.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/updatePassword.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/verifyPasswordResetCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/AuthenticationRemoteDataSource.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/addSession.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/confirmPasswordReset.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/delete.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/reauthenticate.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/refresh.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/sendEmailVerification.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/sendPasswordResetEmail.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/sessionStream.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/signInAnonymously.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/signInWithEmailAndPassword.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/signInWithGoogle.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/signOut.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/signUpWithEmailAndPassword.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/updateEmail.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/updatePassword.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/verifyPasswordResetCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/AuthenticationRepository.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/addSession.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/confirmPasswordReset.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/delete.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/formRepository.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/reauthenticate.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/refresh.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/sendEmailVerification.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/sendPasswordResetEmail.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/sessionStream.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/signInAnonymously.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/signInWithEmailAndPassword.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/signInWithGoogle.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/signOut.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/signUpWithEmailAndPassword.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/updateEmail.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/updatePassword.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/verifyPasswordResetCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/AuthenticationRepositoryImpl.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/addSession.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/authenticationRemoteDataSource.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/confirmPasswordReset.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/delete.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/formRepository.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/reauthenticate.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/refresh.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/sendEmailVerification.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/sendPasswordResetEmail.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/sessionStream.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/signInAnonymously.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/signInWithEmailAndPassword.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/signInWithGoogle.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/signOut.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/signUpWithEmailAndPassword.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/updateEmail.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/updatePassword.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/verifyPasswordResetCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/AuthenticationState.authenticated.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/AuthenticationState.unauthenticated.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/AuthenticationState.unknown.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/props.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/status.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/stringify.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/wrapper.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationStatus.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationStatus/AuthenticationStatus.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationStatus/values-constant.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/BaseEditAccountCubit.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/authenticationRepository.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/dataChanged.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/formName.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/formRepository.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/reset.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/submit.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/update.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/validate.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/BaseSignInCubit.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/authenticationRepository.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/dataChanged.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/formName.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/formRepository.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/reset.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/submit.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/update.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/validate.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/BaseSignUpCubit.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/authenticationRepository.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/dataChanged.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/formName.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/formRepository.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/reset.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/submit.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/update.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/validate.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BuildContextExtension.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BuildContextExtension/account.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BuildContextExtension/data.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BuildContextExtension/session.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BuildContextExtension/wrapper.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ConfirmPasswordResetFailureFirebase-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ConfirmPasswordResetFailureFirebase/ConfirmPasswordResetFailureFirebase.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ConfirmPasswordResetFailureFirebase/ConfirmPasswordResetFailureFirebase.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ConfirmPasswordResetFailureInterface-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ConfirmPasswordResetFailureInterface/ConfirmPasswordResetFailureInterface.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ConfirmPasswordResetFailureInterface/ConfirmPasswordResetFailureInterface.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine/CustomRoutine.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine/attachedLogic.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine/call.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine/onError.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine/onSuccess.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine/routine.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeleteAccountFailureFirebase-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeleteAccountFailureFirebase/DeleteAccountFailureFirebase.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeleteAccountFailureFirebase/DeleteAccountFailureFirebase.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeleteAccountFailureInterface-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeleteAccountFailureInterface/DeleteAccountFailureInterface.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeleteAccountFailureInterface/DeleteAccountFailureInterface.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeletedEvent-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeletedEvent/DeletedEvent.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountCubit-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountCubit/EditAccountCubit.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountCubit/onEmailUpdated.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountCubit/onPasswordUpdated.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/EditAccountListener.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/build.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/child.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/customBuilder.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/onError.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/onProgress.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/onSuccess.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/EditAccountState.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/copyWith.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/email.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/errorMessage.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/form.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/password.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/props.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/status.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/toString.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder/EmailVerificationBuilder.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder/build.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder/customBuilder.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder/notVerified.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder/onError.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder/verified.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationCubit-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationCubit/EmailVerificationCubit.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationCubit/authenticationRepository.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationCubit/checkEmailVerification.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationCubit/sendEmailVerification.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/EmailVerificationState.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/copyWith.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/errorMessage.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/isVerified.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/props.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/status.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/toString.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureFirebase-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureFirebase/FetchSignInMethodsForEmailFailureFirebase.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureFirebase/FetchSignInMethodsForEmailFailureFirebase.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureInterface-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureInterface/FetchSignInMethodsForEmailFailureInterface.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureInterface/FetchSignInMethodsForEmailFailureInterface.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ModelParsingFailureFirebase-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ModelParsingFailureFirebase/ModelParsingFailureFirebase.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ModelParsingFailureFirebase/ModelParsingFailureFirebase.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ModelParsingFailureInterface-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ModelParsingFailureInterface/ModelParsingFailureInterface.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ModelParsingFailureInterface/ModelParsingFailureInterface.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/PasswordResetCubit.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/authenticationRepository.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/dataChanged.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/emailChanged.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/emailCustomChanged.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/formName.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/formRepository.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/reset.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/submit.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/update.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/validate.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/PasswordResetState.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/copyWith.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/email.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/errorMessage.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/form.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/props.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/status.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/toString.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticateFailureFirebase-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticateFailureFirebase/ReauthenticateFailureFirebase.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticateFailureFirebase/ReauthenticateFailureFirebase.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticateFailureInterface-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticateFailureInterface/ReauthenticateFailureInterface.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticateFailureInterface/ReauthenticateFailureInterface.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticatedEvent-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticatedEvent/ReauthenticatedEvent.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticatedEvent/account.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticatedEvent/props.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshFailureFirebase-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshFailureFirebase/RefreshFailureFirebase.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshFailureFirebase/RefreshFailureFirebase.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshFailureInterface-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshFailureInterface/RefreshFailureInterface.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshFailureInterface/RefreshFailureInterface.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshedEvent-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshedEvent/RefreshedEvent.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshedEvent/account.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshedEvent/props.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendEmailVerificationFailureFirebase-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendEmailVerificationFailureFirebase/SendEmailVerificationFailureFirebase.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendEmailVerificationFailureFirebase/SendEmailVerificationFailureFirebase.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendEmailVerificationFailureInterface-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendEmailVerificationFailureInterface/SendEmailVerificationFailureInterface.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendEmailVerificationFailureInterface/SendEmailVerificationFailureInterface.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendPasswordResetEmailFailureFirebase-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendPasswordResetEmailFailureFirebase/SendPasswordResetEmailFailureFirebase.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendPasswordResetEmailFailureFirebase/SendPasswordResetEmailFailureFirebase.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendPasswordResetEmailFailureInterface-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendPasswordResetEmailFailureInterface/SendPasswordResetEmailFailureInterface.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendPasswordResetEmailFailureInterface/SendPasswordResetEmailFailureInterface.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendSignInLinkEmailFailureFirebase-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendSignInLinkEmailFailureFirebase/SendSignInLinkEmailFailureFirebase.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendSignInLinkEmailFailureFirebase/SendSignInLinkEmailFailureFirebase.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendSignInLinkEmailFailureInterface-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendSignInLinkEmailFailureInterface/SendSignInLinkEmailFailureInterface.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendSignInLinkEmailFailureInterface/SendSignInLinkEmailFailureInterface.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Session-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Session/Session.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Session/account.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Session/data.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Session/props.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Session/stringify.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SessionWrapper-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SessionWrapper/SessionWrapper.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SessionWrapper/event.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SessionWrapper/props.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SessionWrapper/session.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SessionWrapper/stringify.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymously-mixin.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymously/onSignInAnonymously.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymously/signInAnonymously.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymouslyFailureFirebase-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymouslyFailureFirebase/SignInAnonymouslyFailureFirebase.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymouslyFailureFirebase/SignInAnonymouslyFailureFirebase.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymouslyFailureInterface-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymouslyFailureInterface/SignInAnonymouslyFailureInterface.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymouslyFailureInterface/SignInAnonymouslyFailureInterface.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInCubit-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInCubit/SignInCubit.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInCubit/onSignInAnonymously.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInCubit/onSignInWithEmailAndPassword.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInCubit/onSignInWithGoogle.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/SignInListener.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/build.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/child.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/customBuilder.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/onError.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/onProgress.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/onSuccess.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/SignInState.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/copyWith.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/email.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/errorMessage.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/form.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/password.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/props.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/status.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/toString.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithAppleFailureFirebase-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithAppleFailureFirebase/SignInWithAppleFailureFirebase.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithAppleFailureFirebase/SignInWithAppleFailureFirebase.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithAppleFailureInterface-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithAppleFailureInterface/SignInWithAppleFailureInterface.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithAppleFailureInterface/SignInWithAppleFailureInterface.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithCredentialFailureFirebase-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithCredentialFailureFirebase/SignInWithCredentialFailureFirebase.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithCredentialFailureFirebase/SignInWithCredentialFailureFirebase.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithCredentialFailureInterface-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithCredentialFailureInterface/SignInWithCredentialFailureInterface.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithCredentialFailureInterface/SignInWithCredentialFailureInterface.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureFirebase-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureFirebase/SignInWithEmailAndPasswordFailureFirebase.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureFirebase/SignInWithEmailAndPasswordFailureFirebase.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureInterface-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureInterface/SignInWithEmailAndPasswordFailureInterface.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureInterface/SignInWithEmailAndPasswordFailureInterface.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailLinkFailureFirebase-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailLinkFailureFirebase/SignInWithEmailLinkFailureFirebase.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailLinkFailureFirebase/SignInWithEmailLinkFailureFirebase.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailLinkFailureInterface-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailLinkFailureInterface/SignInWithEmailLinkFailureInterface.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailLinkFailureInterface/SignInWithEmailLinkFailureInterface.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword-mixin.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword/emailChanged.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword/emailCustomChanged.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword/onSignInWithEmailAndPassword.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword/passwordChanged.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword/passwordCustomChanged.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword/signInWithEmailAndPassword.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithFacebookFailureFirebase-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithFacebookFailureFirebase/SignInWithFacebookFailureFirebase.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithFacebookFailureFirebase/SignInWithFacebookFailureFirebase.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithFacebookFailureInterface-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithFacebookFailureInterface/SignInWithFacebookFailureInterface.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithFacebookFailureInterface/SignInWithFacebookFailureInterface.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogle-mixin.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogle/onSignInWithGoogle.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogle/signInWithGoogle.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogleFailureFirebase-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogleFailureFirebase/SignInWithGoogleFailureFirebase.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogleFailureFirebase/SignInWithGoogleFailureFirebase.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogleFailureInterface-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogleFailureInterface/SignInWithGoogleFailureInterface.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogleFailureInterface/SignInWithGoogleFailureInterface.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithTwitterFailureFirebase-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithTwitterFailureFirebase/SignInWithTwitterFailureFirebase.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithTwitterFailureFirebase/SignInWithTwitterFailureFirebase.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithTwitterFailureInterface-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithTwitterFailureInterface/SignInWithTwitterFailureInterface.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithTwitterFailureInterface/SignInWithTwitterFailureInterface.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignOutFailureFirebase-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignOutFailureFirebase/SignOutFailureFirebase.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignOutFailureFirebase/SignOutFailureFirebase.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignOutFailureInterface-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignOutFailureInterface/SignOutFailureInterface.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignOutFailureInterface/SignOutFailureInterface.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpCubit-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpCubit/SignUpCubit.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpCubit/onSignUpWithEmailAndPassword.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/SignUpListener.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/build.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/child.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/customBuilder.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/onError.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/onProgress.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/onSuccess.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/SignUpState.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/copyWith.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/email.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/errorMessage.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/form.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/password.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/props.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/status.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/toString.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureFirebase-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureFirebase/SignUpWithEmailAndPasswordFailureFirebase.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureFirebase/SignUpWithEmailAndPasswordFailureFirebase.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureInterface-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureInterface/SignUpWithEmailAndPasswordFailureInterface.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureInterface/SignUpWithEmailAndPasswordFailureInterface.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword-mixin.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword/emailChanged.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword/emailCustomChanged.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword/onSignUpWithEmailAndPassword.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword/passwordChanged.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword/passwordCustomChanged.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword/signUpWithEmailPassword.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInEvent-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInEvent/SignedInEvent.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInEvent/account.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInEvent/props.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInFromCacheEvent-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInFromCacheEvent/SignedInFromCacheEvent.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInFromCacheEvent/account.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInFromCacheEvent/props.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedOutEvent-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedOutEvent/SignedOutEvent.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedUpEvent-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedUpEvent/SignedUpEvent.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedUpEvent/account.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedUpEvent/props.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UnknownAuthenticationEvent-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UnknownAuthenticationEvent/UnknownAuthenticationEvent.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmail-mixin.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmail/emailChanged.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmail/emailCustomChanged.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmail/onEmailUpdated.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmail/updateEmail.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmailFailureFirebase-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmailFailureFirebase/UpdateEmailFailureFirebase.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmailFailureFirebase/UpdateEmailFailureFirebase.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmailFailureInterface-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmailFailureInterface/UpdateEmailFailureInterface.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmailFailureInterface/UpdateEmailFailureInterface.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePassword-mixin.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePassword/onPasswordUpdated.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePassword/passwordChanged.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePassword/passwordCustomChanged.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePassword/updatePassword.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePasswordFailureFirebase-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePasswordFailureFirebase/UpdatePasswordFailureFirebase.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePasswordFailureFirebase/UpdatePasswordFailureFirebase.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePasswordFailureInterface-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePasswordFailureInterface/UpdatePasswordFailureInterface.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePasswordFailureInterface/UpdatePasswordFailureInterface.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatedEvent-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatedEvent/UpdatedEvent.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatedEvent/account.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatedEvent/props.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/VerifyPasswordResetCodeFailureFirebase-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/VerifyPasswordResetCodeFailureFirebase/VerifyPasswordResetCodeFailureFirebase.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/VerifyPasswordResetCodeFailureFirebase/VerifyPasswordResetCodeFailureFirebase.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/VerifyPasswordResetCodeFailureInterface-class.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/VerifyPasswordResetCodeFailureInterface/VerifyPasswordResetCodeFailureInterface.fromCode.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/VerifyPasswordResetCodeFailureInterface/VerifyPasswordResetCodeFailureInterface.md delete mode 100644 packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/wyatt_authentication_bloc-library.md diff --git a/packages/wyatt_authentication_bloc/README.md b/packages/wyatt_authentication_bloc/README.md index 04f0f236..9d58adfb 100644 --- a/packages/wyatt_authentication_bloc/README.md +++ b/packages/wyatt_authentication_bloc/README.md @@ -16,7 +16,7 @@ * along with this program. If not, see . --> -# Flutter - Authentication BLoC +# Authentication BLoC

Style: Wyatt Analysis @@ -218,4 +218,4 @@ return SignInListener( ), child: ... ); -``` \ No newline at end of file +``` diff --git a/packages/wyatt_authentication_bloc/doc/api/__404error.md b/packages/wyatt_authentication_bloc/doc/api/__404error.md deleted file mode 100644 index 0fedbdcf..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/__404error.md +++ /dev/null @@ -1,6 +0,0 @@ -# 404 - -Oops, something's gone wrong :-( - -You've tried to visit a page that doesn't exist. Luckily this site has other -[pages](index.md). diff --git a/packages/wyatt_authentication_bloc/doc/api/categories.json b/packages/wyatt_authentication_bloc/doc/api/categories.json deleted file mode 100644 index fe51488c..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/categories.json +++ /dev/null @@ -1 +0,0 @@ -[] diff --git a/packages/wyatt_authentication_bloc/doc/api/index.json b/packages/wyatt_authentication_bloc/doc/api/index.json deleted file mode 100644 index 0745ab72..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/index.json +++ /dev/null @@ -1 +0,0 @@ -[{"name":"wyatt_authentication_bloc","qualifiedName":"wyatt_authentication_bloc","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md","type":"library","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"An authentication library for BLoC."},{"name":"Account","qualifiedName":"wyatt_authentication_bloc.Account","href":"wyatt_authentication_bloc/Account-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Represents a user Account in the \nvarious identity provisioning systems.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"Account","qualifiedName":"wyatt_authentication_bloc.Account.Account","href":"wyatt_authentication_bloc/Account/Account.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"Account","type":"class","href":"wyatt_authentication_bloc/Account-class.md"}},{"name":"accessToken","qualifiedName":"wyatt_authentication_bloc.Account.accessToken","href":"wyatt_authentication_bloc/Account/accessToken.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"The user access token","enclosedBy":{"name":"Account","type":"class","href":"wyatt_authentication_bloc/Account-class.md"}},{"name":"creationTime","qualifiedName":"wyatt_authentication_bloc.Account.creationTime","href":"wyatt_authentication_bloc/Account/creationTime.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Returns the users account creation time.","enclosedBy":{"name":"Account","type":"class","href":"wyatt_authentication_bloc/Account-class.md"}},{"name":"email","qualifiedName":"wyatt_authentication_bloc.Account.email","href":"wyatt_authentication_bloc/Account/email.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"The users email address.","enclosedBy":{"name":"Account","type":"class","href":"wyatt_authentication_bloc/Account-class.md"}},{"name":"emailVerified","qualifiedName":"wyatt_authentication_bloc.Account.emailVerified","href":"wyatt_authentication_bloc/Account/emailVerified.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Returns whether the users email address has been verified.","enclosedBy":{"name":"Account","type":"class","href":"wyatt_authentication_bloc/Account-class.md"}},{"name":"id","qualifiedName":"wyatt_authentication_bloc.Account.id","href":"wyatt_authentication_bloc/Account/id.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"The user's unique ID.","enclosedBy":{"name":"Account","type":"class","href":"wyatt_authentication_bloc/Account-class.md"}},{"name":"isAnonymous","qualifiedName":"wyatt_authentication_bloc.Account.isAnonymous","href":"wyatt_authentication_bloc/Account/isAnonymous.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Returns whether the user is a anonymous.","enclosedBy":{"name":"Account","type":"class","href":"wyatt_authentication_bloc/Account-class.md"}},{"name":"isNewUser","qualifiedName":"wyatt_authentication_bloc.Account.isNewUser","href":"wyatt_authentication_bloc/Account/isNewUser.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Whether the user account has been recently created.","enclosedBy":{"name":"Account","type":"class","href":"wyatt_authentication_bloc/Account-class.md"}},{"name":"lastSignInTime","qualifiedName":"wyatt_authentication_bloc.Account.lastSignInTime","href":"wyatt_authentication_bloc/Account/lastSignInTime.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"When the user last signed in as dictated by the server clock.","enclosedBy":{"name":"Account","type":"class","href":"wyatt_authentication_bloc/Account-class.md"}},{"name":"phoneNumber","qualifiedName":"wyatt_authentication_bloc.Account.phoneNumber","href":"wyatt_authentication_bloc/Account/phoneNumber.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Returns the users phone number.","enclosedBy":{"name":"Account","type":"class","href":"wyatt_authentication_bloc/Account-class.md"}},{"name":"photoURL","qualifiedName":"wyatt_authentication_bloc.Account.photoURL","href":"wyatt_authentication_bloc/Account/photoURL.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Returns a photo URL for the user.","enclosedBy":{"name":"Account","type":"class","href":"wyatt_authentication_bloc/Account-class.md"}},{"name":"props","qualifiedName":"wyatt_authentication_bloc.Account.props","href":"wyatt_authentication_bloc/Account/props.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"The list of properties that will be used to determine whether\ntwo instances are equal.","enclosedBy":{"name":"Account","type":"class","href":"wyatt_authentication_bloc/Account-class.md"}},{"name":"providerId","qualifiedName":"wyatt_authentication_bloc.Account.providerId","href":"wyatt_authentication_bloc/Account/providerId.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"The provider ID for the user.","enclosedBy":{"name":"Account","type":"class","href":"wyatt_authentication_bloc/Account-class.md"}},{"name":"refreshToken","qualifiedName":"wyatt_authentication_bloc.Account.refreshToken","href":"wyatt_authentication_bloc/Account/refreshToken.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"The user refresh token","enclosedBy":{"name":"Account","type":"class","href":"wyatt_authentication_bloc/Account-class.md"}},{"name":"stringify","qualifiedName":"wyatt_authentication_bloc.Account.stringify","href":"wyatt_authentication_bloc/Account/stringify.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"If set to true, the toString method will be overridden to output\nthis instance's props.","enclosedBy":{"name":"Account","type":"class","href":"wyatt_authentication_bloc/Account-class.md"}},{"name":"AccountModel","qualifiedName":"wyatt_authentication_bloc.AccountModel","href":"wyatt_authentication_bloc/AccountModel-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Account Model to parse Firebase User data","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"AccountModel.fromFirebaseUser","qualifiedName":"wyatt_authentication_bloc.AccountModel.fromFirebaseUser","href":"wyatt_authentication_bloc/AccountModel/AccountModel.fromFirebaseUser.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"AccountModel","type":"class","href":"wyatt_authentication_bloc/AccountModel-class.md"}},{"name":"AccountModel.fromFirebaseUserCredential","qualifiedName":"wyatt_authentication_bloc.AccountModel.fromFirebaseUserCredential","href":"wyatt_authentication_bloc/AccountModel/AccountModel.fromFirebaseUserCredential.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"AccountModel","type":"class","href":"wyatt_authentication_bloc/AccountModel-class.md"}},{"name":"refreshToken","qualifiedName":"wyatt_authentication_bloc.AccountModel.refreshToken","href":"wyatt_authentication_bloc/AccountModel/refreshToken.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"The user refresh token","enclosedBy":{"name":"AccountModel","type":"class","href":"wyatt_authentication_bloc/AccountModel-class.md"}},{"name":"user","qualifiedName":"wyatt_authentication_bloc.AccountModel.user","href":"wyatt_authentication_bloc/AccountModel/user.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"AccountModel","type":"class","href":"wyatt_authentication_bloc/AccountModel-class.md"}},{"name":"ApplyActionCodeFailureFirebase","qualifiedName":"wyatt_authentication_bloc.ApplyActionCodeFailureFirebase","href":"wyatt_authentication_bloc/ApplyActionCodeFailureFirebase-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown if during the apply action code process if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"ApplyActionCodeFailureFirebase","qualifiedName":"wyatt_authentication_bloc.ApplyActionCodeFailureFirebase.ApplyActionCodeFailureFirebase","href":"wyatt_authentication_bloc/ApplyActionCodeFailureFirebase/ApplyActionCodeFailureFirebase.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"ApplyActionCodeFailureFirebase","type":"class","href":"wyatt_authentication_bloc/ApplyActionCodeFailureFirebase-class.md"}},{"name":"ApplyActionCodeFailureFirebase.fromCode","qualifiedName":"wyatt_authentication_bloc.ApplyActionCodeFailureFirebase.fromCode","href":"wyatt_authentication_bloc/ApplyActionCodeFailureFirebase/ApplyActionCodeFailureFirebase.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"ApplyActionCodeFailureFirebase","type":"class","href":"wyatt_authentication_bloc/ApplyActionCodeFailureFirebase-class.md"}},{"name":"ApplyActionCodeFailureInterface","qualifiedName":"wyatt_authentication_bloc.ApplyActionCodeFailureInterface","href":"wyatt_authentication_bloc/ApplyActionCodeFailureInterface-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown if during the apply action code process if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"ApplyActionCodeFailureInterface","qualifiedName":"wyatt_authentication_bloc.ApplyActionCodeFailureInterface.ApplyActionCodeFailureInterface","href":"wyatt_authentication_bloc/ApplyActionCodeFailureInterface/ApplyActionCodeFailureInterface.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown if during the apply action code process if a failure occurs.","enclosedBy":{"name":"ApplyActionCodeFailureInterface","type":"class","href":"wyatt_authentication_bloc/ApplyActionCodeFailureInterface-class.md"}},{"name":"ApplyActionCodeFailureInterface.fromCode","qualifiedName":"wyatt_authentication_bloc.ApplyActionCodeFailureInterface.fromCode","href":"wyatt_authentication_bloc/ApplyActionCodeFailureInterface/ApplyActionCodeFailureInterface.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown if during the apply action code process if a failure occurs.","enclosedBy":{"name":"ApplyActionCodeFailureInterface","type":"class","href":"wyatt_authentication_bloc/ApplyActionCodeFailureInterface-class.md"}},{"name":"AuthFormField","qualifiedName":"wyatt_authentication_bloc.AuthFormField","href":"wyatt_authentication_bloc/AuthFormField-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Default authentication form fields name","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"AuthFormField","qualifiedName":"wyatt_authentication_bloc.AuthFormField.AuthFormField","href":"wyatt_authentication_bloc/AuthFormField/AuthFormField.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"AuthFormField","type":"class","href":"wyatt_authentication_bloc/AuthFormField-class.md"}},{"name":"confirmPassword","qualifiedName":"wyatt_authentication_bloc.AuthFormField.confirmPassword","href":"wyatt_authentication_bloc/AuthFormField/confirmPassword-constant.md","type":"constant","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Confirm Password field: wyattConfirmPasswordField","enclosedBy":{"name":"AuthFormField","type":"class","href":"wyatt_authentication_bloc/AuthFormField-class.md"}},{"name":"email","qualifiedName":"wyatt_authentication_bloc.AuthFormField.email","href":"wyatt_authentication_bloc/AuthFormField/email-constant.md","type":"constant","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Email field: wyattEmailField","enclosedBy":{"name":"AuthFormField","type":"class","href":"wyatt_authentication_bloc/AuthFormField-class.md"}},{"name":"password","qualifiedName":"wyatt_authentication_bloc.AuthFormField.password","href":"wyatt_authentication_bloc/AuthFormField/password-constant.md","type":"constant","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Password field: wyattPasswordField","enclosedBy":{"name":"AuthFormField","type":"class","href":"wyatt_authentication_bloc/AuthFormField-class.md"}},{"name":"AuthFormName","qualifiedName":"wyatt_authentication_bloc.AuthFormName","href":"wyatt_authentication_bloc/AuthFormName-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Default authentication form name","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"AuthFormName","qualifiedName":"wyatt_authentication_bloc.AuthFormName.AuthFormName","href":"wyatt_authentication_bloc/AuthFormName/AuthFormName.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"AuthFormName","type":"class","href":"wyatt_authentication_bloc/AuthFormName-class.md"}},{"name":"editAccountForm","qualifiedName":"wyatt_authentication_bloc.AuthFormName.editAccountForm","href":"wyatt_authentication_bloc/AuthFormName/editAccountForm-constant.md","type":"constant","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Edit account form: wyattEditAccountForm","enclosedBy":{"name":"AuthFormName","type":"class","href":"wyatt_authentication_bloc/AuthFormName-class.md"}},{"name":"passwordResetForm","qualifiedName":"wyatt_authentication_bloc.AuthFormName.passwordResetForm","href":"wyatt_authentication_bloc/AuthFormName/passwordResetForm-constant.md","type":"constant","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Password reset form: wyattPasswordResetForm","enclosedBy":{"name":"AuthFormName","type":"class","href":"wyatt_authentication_bloc/AuthFormName-class.md"}},{"name":"signInForm","qualifiedName":"wyatt_authentication_bloc.AuthFormName.signInForm","href":"wyatt_authentication_bloc/AuthFormName/signInForm-constant.md","type":"constant","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Sign In form: wyattSignInForm","enclosedBy":{"name":"AuthFormName","type":"class","href":"wyatt_authentication_bloc/AuthFormName-class.md"}},{"name":"signUpForm","qualifiedName":"wyatt_authentication_bloc.AuthFormName.signUpForm","href":"wyatt_authentication_bloc/AuthFormName/signUpForm-constant.md","type":"constant","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Sign Up form: wyattSignUpForm","enclosedBy":{"name":"AuthFormName","type":"class","href":"wyatt_authentication_bloc/AuthFormName-class.md"}},{"name":"AuthenticationBuilder","qualifiedName":"wyatt_authentication_bloc.AuthenticationBuilder","href":"wyatt_authentication_bloc/AuthenticationBuilder-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"AuthenticationBuilder","qualifiedName":"wyatt_authentication_bloc.AuthenticationBuilder.AuthenticationBuilder","href":"wyatt_authentication_bloc/AuthenticationBuilder/AuthenticationBuilder.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"AuthenticationBuilder","type":"class","href":"wyatt_authentication_bloc/AuthenticationBuilder-class.md"}},{"name":"authenticated","qualifiedName":"wyatt_authentication_bloc.AuthenticationBuilder.authenticated","href":"wyatt_authentication_bloc/AuthenticationBuilder/authenticated.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"AuthenticationBuilder","type":"class","href":"wyatt_authentication_bloc/AuthenticationBuilder-class.md"}},{"name":"build","qualifiedName":"wyatt_authentication_bloc.AuthenticationBuilder.build","href":"wyatt_authentication_bloc/AuthenticationBuilder/build.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"Describes the part of the user interface represented by this widget.","enclosedBy":{"name":"AuthenticationBuilder","type":"class","href":"wyatt_authentication_bloc/AuthenticationBuilder-class.md"}},{"name":"unauthenticated","qualifiedName":"wyatt_authentication_bloc.AuthenticationBuilder.unauthenticated","href":"wyatt_authentication_bloc/AuthenticationBuilder/unauthenticated.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"AuthenticationBuilder","type":"class","href":"wyatt_authentication_bloc/AuthenticationBuilder-class.md"}},{"name":"unknown","qualifiedName":"wyatt_authentication_bloc.AuthenticationBuilder.unknown","href":"wyatt_authentication_bloc/AuthenticationBuilder/unknown.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"AuthenticationBuilder","type":"class","href":"wyatt_authentication_bloc/AuthenticationBuilder-class.md"}},{"name":"AuthenticationChangeEvent","qualifiedName":"wyatt_authentication_bloc.AuthenticationChangeEvent","href":"wyatt_authentication_bloc/AuthenticationChangeEvent-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Represents an event initiated by a change in\nthe user's authentication status.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"AuthenticationChangeEvent","qualifiedName":"wyatt_authentication_bloc.AuthenticationChangeEvent.AuthenticationChangeEvent","href":"wyatt_authentication_bloc/AuthenticationChangeEvent/AuthenticationChangeEvent.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"AuthenticationChangeEvent","type":"class","href":"wyatt_authentication_bloc/AuthenticationChangeEvent-class.md"}},{"name":"props","qualifiedName":"wyatt_authentication_bloc.AuthenticationChangeEvent.props","href":"wyatt_authentication_bloc/AuthenticationChangeEvent/props.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"The list of properties that will be used to determine whether\ntwo instances are equal.","enclosedBy":{"name":"AuthenticationChangeEvent","type":"class","href":"wyatt_authentication_bloc/AuthenticationChangeEvent-class.md"}},{"name":"stringify","qualifiedName":"wyatt_authentication_bloc.AuthenticationChangeEvent.stringify","href":"wyatt_authentication_bloc/AuthenticationChangeEvent/stringify.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"If set to true, the toString method will be overridden to output\nthis instance's props.","enclosedBy":{"name":"AuthenticationChangeEvent","type":"class","href":"wyatt_authentication_bloc/AuthenticationChangeEvent-class.md"}},{"name":"AuthenticationCubit","qualifiedName":"wyatt_authentication_bloc.AuthenticationCubit","href":"wyatt_authentication_bloc/AuthenticationCubit-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Abstract authentication cubit class needs to be implemented in application.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"AuthenticationCubit","qualifiedName":"wyatt_authentication_bloc.AuthenticationCubit.AuthenticationCubit","href":"wyatt_authentication_bloc/AuthenticationCubit/AuthenticationCubit.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"AuthenticationCubit","type":"class","href":"wyatt_authentication_bloc/AuthenticationCubit-class.md"}},{"name":"authenticationRepository","qualifiedName":"wyatt_authentication_bloc.AuthenticationCubit.authenticationRepository","href":"wyatt_authentication_bloc/AuthenticationCubit/authenticationRepository.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"AuthenticationCubit","type":"class","href":"wyatt_authentication_bloc/AuthenticationCubit-class.md"}},{"name":"currentSession","qualifiedName":"wyatt_authentication_bloc.AuthenticationCubit.currentSession","href":"wyatt_authentication_bloc/AuthenticationCubit/currentSession.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Returns latest session wrapper.","enclosedBy":{"name":"AuthenticationCubit","type":"class","href":"wyatt_authentication_bloc/AuthenticationCubit-class.md"}},{"name":"delete","qualifiedName":"wyatt_authentication_bloc.AuthenticationCubit.delete","href":"wyatt_authentication_bloc/AuthenticationCubit/delete.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Delete account.","enclosedBy":{"name":"AuthenticationCubit","type":"class","href":"wyatt_authentication_bloc/AuthenticationCubit-class.md"}},{"name":"onDelete","qualifiedName":"wyatt_authentication_bloc.AuthenticationCubit.onDelete","href":"wyatt_authentication_bloc/AuthenticationCubit/onDelete.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"This callback is triggered when the current account is deleted from\nthe remote.","enclosedBy":{"name":"AuthenticationCubit","type":"class","href":"wyatt_authentication_bloc/AuthenticationCubit-class.md"}},{"name":"onReauthenticate","qualifiedName":"wyatt_authentication_bloc.AuthenticationCubit.onReauthenticate","href":"wyatt_authentication_bloc/AuthenticationCubit/onReauthenticate.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"This callback is triggered when the account is re-authenticated","enclosedBy":{"name":"AuthenticationCubit","type":"class","href":"wyatt_authentication_bloc/AuthenticationCubit-class.md"}},{"name":"onRefresh","qualifiedName":"wyatt_authentication_bloc.AuthenticationCubit.onRefresh","href":"wyatt_authentication_bloc/AuthenticationCubit/onRefresh.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"This callback is triggered when the account is refreshed.","enclosedBy":{"name":"AuthenticationCubit","type":"class","href":"wyatt_authentication_bloc/AuthenticationCubit-class.md"}},{"name":"onSignInFromCache","qualifiedName":"wyatt_authentication_bloc.AuthenticationCubit.onSignInFromCache","href":"wyatt_authentication_bloc/AuthenticationCubit/onSignInFromCache.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"This callback is triggered when the user is automaticcaly logged in from\nthe cache.","enclosedBy":{"name":"AuthenticationCubit","type":"class","href":"wyatt_authentication_bloc/AuthenticationCubit-class.md"}},{"name":"onSignOut","qualifiedName":"wyatt_authentication_bloc.AuthenticationCubit.onSignOut","href":"wyatt_authentication_bloc/AuthenticationCubit/onSignOut.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"This callback is triggered when the user is logged out.","enclosedBy":{"name":"AuthenticationCubit","type":"class","href":"wyatt_authentication_bloc/AuthenticationCubit-class.md"}},{"name":"reauthenticate","qualifiedName":"wyatt_authentication_bloc.AuthenticationCubit.reauthenticate","href":"wyatt_authentication_bloc/AuthenticationCubit/reauthenticate.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Some security-sensitive actions—such as deleting an account,\nsetting a primary email address, and changing a password—require that\nthe user has recently signed in.","enclosedBy":{"name":"AuthenticationCubit","type":"class","href":"wyatt_authentication_bloc/AuthenticationCubit-class.md"}},{"name":"refresh","qualifiedName":"wyatt_authentication_bloc.AuthenticationCubit.refresh","href":"wyatt_authentication_bloc/AuthenticationCubit/refresh.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Refreshes the current user, if signed in.","enclosedBy":{"name":"AuthenticationCubit","type":"class","href":"wyatt_authentication_bloc/AuthenticationCubit-class.md"}},{"name":"signOut","qualifiedName":"wyatt_authentication_bloc.AuthenticationCubit.signOut","href":"wyatt_authentication_bloc/AuthenticationCubit/signOut.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Signs out the current user.\nIt also clears the cache and the associated data.","enclosedBy":{"name":"AuthenticationCubit","type":"class","href":"wyatt_authentication_bloc/AuthenticationCubit-class.md"}},{"name":"AuthenticationFailureInterface","qualifiedName":"wyatt_authentication_bloc.AuthenticationFailureInterface","href":"wyatt_authentication_bloc/AuthenticationFailureInterface-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Base exception used in Wyatt Authentication","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"AuthenticationFailureInterface","qualifiedName":"wyatt_authentication_bloc.AuthenticationFailureInterface.AuthenticationFailureInterface","href":"wyatt_authentication_bloc/AuthenticationFailureInterface/AuthenticationFailureInterface.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"AuthenticationFailureInterface","type":"class","href":"wyatt_authentication_bloc/AuthenticationFailureInterface-class.md"}},{"name":"code","qualifiedName":"wyatt_authentication_bloc.AuthenticationFailureInterface.code","href":"wyatt_authentication_bloc/AuthenticationFailureInterface/code.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"AuthenticationFailureInterface","type":"class","href":"wyatt_authentication_bloc/AuthenticationFailureInterface-class.md"}},{"name":"AuthenticationFailureInterface.fromCode","qualifiedName":"wyatt_authentication_bloc.AuthenticationFailureInterface.fromCode","href":"wyatt_authentication_bloc/AuthenticationFailureInterface/AuthenticationFailureInterface.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"AuthenticationFailureInterface","type":"class","href":"wyatt_authentication_bloc/AuthenticationFailureInterface-class.md"}},{"name":"message","qualifiedName":"wyatt_authentication_bloc.AuthenticationFailureInterface.message","href":"wyatt_authentication_bloc/AuthenticationFailureInterface/message.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"AuthenticationFailureInterface","type":"class","href":"wyatt_authentication_bloc/AuthenticationFailureInterface-class.md"}},{"name":"msg","qualifiedName":"wyatt_authentication_bloc.AuthenticationFailureInterface.msg","href":"wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"AuthenticationFailureInterface","type":"class","href":"wyatt_authentication_bloc/AuthenticationFailureInterface-class.md"}},{"name":"toString","qualifiedName":"wyatt_authentication_bloc.AuthenticationFailureInterface.toString","href":"wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"A string representation of this object.","enclosedBy":{"name":"AuthenticationFailureInterface","type":"class","href":"wyatt_authentication_bloc/AuthenticationFailureInterface-class.md"}},{"name":"AuthenticationFirebaseDataSourceImpl","qualifiedName":"wyatt_authentication_bloc.AuthenticationFirebaseDataSourceImpl","href":"wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"AuthenticationFirebaseDataSourceImpl","qualifiedName":"wyatt_authentication_bloc.AuthenticationFirebaseDataSourceImpl.AuthenticationFirebaseDataSourceImpl","href":"wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/AuthenticationFirebaseDataSourceImpl.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"AuthenticationFirebaseDataSourceImpl","type":"class","href":"wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl-class.md"}},{"name":"addSession","qualifiedName":"wyatt_authentication_bloc.AuthenticationFirebaseDataSourceImpl.addSession","href":"wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/addSession.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"Add a new authentication event.","enclosedBy":{"name":"AuthenticationFirebaseDataSourceImpl","type":"class","href":"wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl-class.md"}},{"name":"confirmPasswordReset","qualifiedName":"wyatt_authentication_bloc.AuthenticationFirebaseDataSourceImpl.confirmPasswordReset","href":"wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/confirmPasswordReset.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"Confirms the password reset with the provided newPassword and code.","enclosedBy":{"name":"AuthenticationFirebaseDataSourceImpl","type":"class","href":"wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl-class.md"}},{"name":"delete","qualifiedName":"wyatt_authentication_bloc.AuthenticationFirebaseDataSourceImpl.delete","href":"wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/delete.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"Delete account.","enclosedBy":{"name":"AuthenticationFirebaseDataSourceImpl","type":"class","href":"wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl-class.md"}},{"name":"reauthenticate","qualifiedName":"wyatt_authentication_bloc.AuthenticationFirebaseDataSourceImpl.reauthenticate","href":"wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/reauthenticate.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"Some security-sensitive actions—such as deleting an account,\nsetting a primary email address, and changing a password—require that\nthe user has recently signed in.","enclosedBy":{"name":"AuthenticationFirebaseDataSourceImpl","type":"class","href":"wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl-class.md"}},{"name":"refresh","qualifiedName":"wyatt_authentication_bloc.AuthenticationFirebaseDataSourceImpl.refresh","href":"wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/refresh.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"Refreshes the current user, if signed in.","enclosedBy":{"name":"AuthenticationFirebaseDataSourceImpl","type":"class","href":"wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl-class.md"}},{"name":"sendEmailVerification","qualifiedName":"wyatt_authentication_bloc.AuthenticationFirebaseDataSourceImpl.sendEmailVerification","href":"wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/sendEmailVerification.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"Sends verification email to the account email.","enclosedBy":{"name":"AuthenticationFirebaseDataSourceImpl","type":"class","href":"wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl-class.md"}},{"name":"sendPasswordResetEmail","qualifiedName":"wyatt_authentication_bloc.AuthenticationFirebaseDataSourceImpl.sendPasswordResetEmail","href":"wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/sendPasswordResetEmail.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"Sends a password reset email to the provided email.","enclosedBy":{"name":"AuthenticationFirebaseDataSourceImpl","type":"class","href":"wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl-class.md"}},{"name":"sessionStream","qualifiedName":"wyatt_authentication_bloc.AuthenticationFirebaseDataSourceImpl.sessionStream","href":"wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/sessionStream.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"Authentication state change event stream.","enclosedBy":{"name":"AuthenticationFirebaseDataSourceImpl","type":"class","href":"wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl-class.md"}},{"name":"signInAnonymously","qualifiedName":"wyatt_authentication_bloc.AuthenticationFirebaseDataSourceImpl.signInAnonymously","href":"wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signInAnonymously.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"Sign in anonymously.","enclosedBy":{"name":"AuthenticationFirebaseDataSourceImpl","type":"class","href":"wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl-class.md"}},{"name":"signInWithEmailAndPassword","qualifiedName":"wyatt_authentication_bloc.AuthenticationFirebaseDataSourceImpl.signInWithEmailAndPassword","href":"wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signInWithEmailAndPassword.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"Signs in with the provided email and password.","enclosedBy":{"name":"AuthenticationFirebaseDataSourceImpl","type":"class","href":"wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl-class.md"}},{"name":"signInWithGoogle","qualifiedName":"wyatt_authentication_bloc.AuthenticationFirebaseDataSourceImpl.signInWithGoogle","href":"wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signInWithGoogle.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"Starts the Sign In with Google Flow.","enclosedBy":{"name":"AuthenticationFirebaseDataSourceImpl","type":"class","href":"wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl-class.md"}},{"name":"signOut","qualifiedName":"wyatt_authentication_bloc.AuthenticationFirebaseDataSourceImpl.signOut","href":"wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signOut.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"Signs out the current user.\nIt also clears the cache and the associated data.","enclosedBy":{"name":"AuthenticationFirebaseDataSourceImpl","type":"class","href":"wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl-class.md"}},{"name":"signUpWithEmailAndPassword","qualifiedName":"wyatt_authentication_bloc.AuthenticationFirebaseDataSourceImpl.signUpWithEmailAndPassword","href":"wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signUpWithEmailAndPassword.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"Creates a new user with the provided email and password.","enclosedBy":{"name":"AuthenticationFirebaseDataSourceImpl","type":"class","href":"wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl-class.md"}},{"name":"updateEmail","qualifiedName":"wyatt_authentication_bloc.AuthenticationFirebaseDataSourceImpl.updateEmail","href":"wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/updateEmail.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"Update or add email.","enclosedBy":{"name":"AuthenticationFirebaseDataSourceImpl","type":"class","href":"wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl-class.md"}},{"name":"updatePassword","qualifiedName":"wyatt_authentication_bloc.AuthenticationFirebaseDataSourceImpl.updatePassword","href":"wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/updatePassword.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"Update or add password.","enclosedBy":{"name":"AuthenticationFirebaseDataSourceImpl","type":"class","href":"wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl-class.md"}},{"name":"verifyPasswordResetCode","qualifiedName":"wyatt_authentication_bloc.AuthenticationFirebaseDataSourceImpl.verifyPasswordResetCode","href":"wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/verifyPasswordResetCode.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"Verify password reset code.","enclosedBy":{"name":"AuthenticationFirebaseDataSourceImpl","type":"class","href":"wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl-class.md"}},{"name":"AuthenticationRemoteDataSource","qualifiedName":"wyatt_authentication_bloc.AuthenticationRemoteDataSource","href":"wyatt_authentication_bloc/AuthenticationRemoteDataSource-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Is responsible for abstracting the provenance of the data.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"AuthenticationRemoteDataSource","qualifiedName":"wyatt_authentication_bloc.AuthenticationRemoteDataSource.AuthenticationRemoteDataSource","href":"wyatt_authentication_bloc/AuthenticationRemoteDataSource/AuthenticationRemoteDataSource.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"AuthenticationRemoteDataSource","type":"class","href":"wyatt_authentication_bloc/AuthenticationRemoteDataSource-class.md"}},{"name":"addSession","qualifiedName":"wyatt_authentication_bloc.AuthenticationRemoteDataSource.addSession","href":"wyatt_authentication_bloc/AuthenticationRemoteDataSource/addSession.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"AuthenticationRemoteDataSource","type":"class","href":"wyatt_authentication_bloc/AuthenticationRemoteDataSource-class.md"}},{"name":"confirmPasswordReset","qualifiedName":"wyatt_authentication_bloc.AuthenticationRemoteDataSource.confirmPasswordReset","href":"wyatt_authentication_bloc/AuthenticationRemoteDataSource/confirmPasswordReset.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"AuthenticationRemoteDataSource","type":"class","href":"wyatt_authentication_bloc/AuthenticationRemoteDataSource-class.md"}},{"name":"delete","qualifiedName":"wyatt_authentication_bloc.AuthenticationRemoteDataSource.delete","href":"wyatt_authentication_bloc/AuthenticationRemoteDataSource/delete.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"AuthenticationRemoteDataSource","type":"class","href":"wyatt_authentication_bloc/AuthenticationRemoteDataSource-class.md"}},{"name":"reauthenticate","qualifiedName":"wyatt_authentication_bloc.AuthenticationRemoteDataSource.reauthenticate","href":"wyatt_authentication_bloc/AuthenticationRemoteDataSource/reauthenticate.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"AuthenticationRemoteDataSource","type":"class","href":"wyatt_authentication_bloc/AuthenticationRemoteDataSource-class.md"}},{"name":"refresh","qualifiedName":"wyatt_authentication_bloc.AuthenticationRemoteDataSource.refresh","href":"wyatt_authentication_bloc/AuthenticationRemoteDataSource/refresh.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"AuthenticationRemoteDataSource","type":"class","href":"wyatt_authentication_bloc/AuthenticationRemoteDataSource-class.md"}},{"name":"sendEmailVerification","qualifiedName":"wyatt_authentication_bloc.AuthenticationRemoteDataSource.sendEmailVerification","href":"wyatt_authentication_bloc/AuthenticationRemoteDataSource/sendEmailVerification.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"AuthenticationRemoteDataSource","type":"class","href":"wyatt_authentication_bloc/AuthenticationRemoteDataSource-class.md"}},{"name":"sendPasswordResetEmail","qualifiedName":"wyatt_authentication_bloc.AuthenticationRemoteDataSource.sendPasswordResetEmail","href":"wyatt_authentication_bloc/AuthenticationRemoteDataSource/sendPasswordResetEmail.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"AuthenticationRemoteDataSource","type":"class","href":"wyatt_authentication_bloc/AuthenticationRemoteDataSource-class.md"}},{"name":"sessionStream","qualifiedName":"wyatt_authentication_bloc.AuthenticationRemoteDataSource.sessionStream","href":"wyatt_authentication_bloc/AuthenticationRemoteDataSource/sessionStream.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"AuthenticationRemoteDataSource","type":"class","href":"wyatt_authentication_bloc/AuthenticationRemoteDataSource-class.md"}},{"name":"signInAnonymously","qualifiedName":"wyatt_authentication_bloc.AuthenticationRemoteDataSource.signInAnonymously","href":"wyatt_authentication_bloc/AuthenticationRemoteDataSource/signInAnonymously.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"AuthenticationRemoteDataSource","type":"class","href":"wyatt_authentication_bloc/AuthenticationRemoteDataSource-class.md"}},{"name":"signInWithEmailAndPassword","qualifiedName":"wyatt_authentication_bloc.AuthenticationRemoteDataSource.signInWithEmailAndPassword","href":"wyatt_authentication_bloc/AuthenticationRemoteDataSource/signInWithEmailAndPassword.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"AuthenticationRemoteDataSource","type":"class","href":"wyatt_authentication_bloc/AuthenticationRemoteDataSource-class.md"}},{"name":"signInWithGoogle","qualifiedName":"wyatt_authentication_bloc.AuthenticationRemoteDataSource.signInWithGoogle","href":"wyatt_authentication_bloc/AuthenticationRemoteDataSource/signInWithGoogle.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"AuthenticationRemoteDataSource","type":"class","href":"wyatt_authentication_bloc/AuthenticationRemoteDataSource-class.md"}},{"name":"signOut","qualifiedName":"wyatt_authentication_bloc.AuthenticationRemoteDataSource.signOut","href":"wyatt_authentication_bloc/AuthenticationRemoteDataSource/signOut.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"AuthenticationRemoteDataSource","type":"class","href":"wyatt_authentication_bloc/AuthenticationRemoteDataSource-class.md"}},{"name":"signUpWithEmailAndPassword","qualifiedName":"wyatt_authentication_bloc.AuthenticationRemoteDataSource.signUpWithEmailAndPassword","href":"wyatt_authentication_bloc/AuthenticationRemoteDataSource/signUpWithEmailAndPassword.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"AuthenticationRemoteDataSource","type":"class","href":"wyatt_authentication_bloc/AuthenticationRemoteDataSource-class.md"}},{"name":"updateEmail","qualifiedName":"wyatt_authentication_bloc.AuthenticationRemoteDataSource.updateEmail","href":"wyatt_authentication_bloc/AuthenticationRemoteDataSource/updateEmail.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"AuthenticationRemoteDataSource","type":"class","href":"wyatt_authentication_bloc/AuthenticationRemoteDataSource-class.md"}},{"name":"updatePassword","qualifiedName":"wyatt_authentication_bloc.AuthenticationRemoteDataSource.updatePassword","href":"wyatt_authentication_bloc/AuthenticationRemoteDataSource/updatePassword.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"AuthenticationRemoteDataSource","type":"class","href":"wyatt_authentication_bloc/AuthenticationRemoteDataSource-class.md"}},{"name":"verifyPasswordResetCode","qualifiedName":"wyatt_authentication_bloc.AuthenticationRemoteDataSource.verifyPasswordResetCode","href":"wyatt_authentication_bloc/AuthenticationRemoteDataSource/verifyPasswordResetCode.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"AuthenticationRemoteDataSource","type":"class","href":"wyatt_authentication_bloc/AuthenticationRemoteDataSource-class.md"}},{"name":"AuthenticationRepository","qualifiedName":"wyatt_authentication_bloc.AuthenticationRepository","href":"wyatt_authentication_bloc/AuthenticationRepository-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"AuthenticationRepository","qualifiedName":"wyatt_authentication_bloc.AuthenticationRepository.AuthenticationRepository","href":"wyatt_authentication_bloc/AuthenticationRepository/AuthenticationRepository.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"AuthenticationRepository","type":"class","href":"wyatt_authentication_bloc/AuthenticationRepository-class.md"}},{"name":"addSession","qualifiedName":"wyatt_authentication_bloc.AuthenticationRepository.addSession","href":"wyatt_authentication_bloc/AuthenticationRepository/addSession.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Add a new authentication event.","enclosedBy":{"name":"AuthenticationRepository","type":"class","href":"wyatt_authentication_bloc/AuthenticationRepository-class.md"}},{"name":"confirmPasswordReset","qualifiedName":"wyatt_authentication_bloc.AuthenticationRepository.confirmPasswordReset","href":"wyatt_authentication_bloc/AuthenticationRepository/confirmPasswordReset.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Confirms the password reset with the provided newPassword and code.","enclosedBy":{"name":"AuthenticationRepository","type":"class","href":"wyatt_authentication_bloc/AuthenticationRepository-class.md"}},{"name":"delete","qualifiedName":"wyatt_authentication_bloc.AuthenticationRepository.delete","href":"wyatt_authentication_bloc/AuthenticationRepository/delete.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Delete account.","enclosedBy":{"name":"AuthenticationRepository","type":"class","href":"wyatt_authentication_bloc/AuthenticationRepository-class.md"}},{"name":"formRepository","qualifiedName":"wyatt_authentication_bloc.AuthenticationRepository.formRepository","href":"wyatt_authentication_bloc/AuthenticationRepository/formRepository.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Form repository used in different authentication cubits/blocs","enclosedBy":{"name":"AuthenticationRepository","type":"class","href":"wyatt_authentication_bloc/AuthenticationRepository-class.md"}},{"name":"reauthenticate","qualifiedName":"wyatt_authentication_bloc.AuthenticationRepository.reauthenticate","href":"wyatt_authentication_bloc/AuthenticationRepository/reauthenticate.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Some security-sensitive actions—such as deleting an account,\nsetting a primary email address, and changing a password—require that\nthe user has recently signed in.","enclosedBy":{"name":"AuthenticationRepository","type":"class","href":"wyatt_authentication_bloc/AuthenticationRepository-class.md"}},{"name":"refresh","qualifiedName":"wyatt_authentication_bloc.AuthenticationRepository.refresh","href":"wyatt_authentication_bloc/AuthenticationRepository/refresh.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Refreshes the current user, if signed in.","enclosedBy":{"name":"AuthenticationRepository","type":"class","href":"wyatt_authentication_bloc/AuthenticationRepository-class.md"}},{"name":"sendEmailVerification","qualifiedName":"wyatt_authentication_bloc.AuthenticationRepository.sendEmailVerification","href":"wyatt_authentication_bloc/AuthenticationRepository/sendEmailVerification.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Sends verification email to the account email.","enclosedBy":{"name":"AuthenticationRepository","type":"class","href":"wyatt_authentication_bloc/AuthenticationRepository-class.md"}},{"name":"sendPasswordResetEmail","qualifiedName":"wyatt_authentication_bloc.AuthenticationRepository.sendPasswordResetEmail","href":"wyatt_authentication_bloc/AuthenticationRepository/sendPasswordResetEmail.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Sends a password reset email to the provided email.","enclosedBy":{"name":"AuthenticationRepository","type":"class","href":"wyatt_authentication_bloc/AuthenticationRepository-class.md"}},{"name":"sessionStream","qualifiedName":"wyatt_authentication_bloc.AuthenticationRepository.sessionStream","href":"wyatt_authentication_bloc/AuthenticationRepository/sessionStream.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Authentication state change event stream.","enclosedBy":{"name":"AuthenticationRepository","type":"class","href":"wyatt_authentication_bloc/AuthenticationRepository-class.md"}},{"name":"signInAnonymously","qualifiedName":"wyatt_authentication_bloc.AuthenticationRepository.signInAnonymously","href":"wyatt_authentication_bloc/AuthenticationRepository/signInAnonymously.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Sign in anonymously.","enclosedBy":{"name":"AuthenticationRepository","type":"class","href":"wyatt_authentication_bloc/AuthenticationRepository-class.md"}},{"name":"signInWithEmailAndPassword","qualifiedName":"wyatt_authentication_bloc.AuthenticationRepository.signInWithEmailAndPassword","href":"wyatt_authentication_bloc/AuthenticationRepository/signInWithEmailAndPassword.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Signs in with the provided email and password.","enclosedBy":{"name":"AuthenticationRepository","type":"class","href":"wyatt_authentication_bloc/AuthenticationRepository-class.md"}},{"name":"signInWithGoogle","qualifiedName":"wyatt_authentication_bloc.AuthenticationRepository.signInWithGoogle","href":"wyatt_authentication_bloc/AuthenticationRepository/signInWithGoogle.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Starts the Sign In with Google Flow.","enclosedBy":{"name":"AuthenticationRepository","type":"class","href":"wyatt_authentication_bloc/AuthenticationRepository-class.md"}},{"name":"signOut","qualifiedName":"wyatt_authentication_bloc.AuthenticationRepository.signOut","href":"wyatt_authentication_bloc/AuthenticationRepository/signOut.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Signs out the current user.\nIt also clears the cache and the associated data.","enclosedBy":{"name":"AuthenticationRepository","type":"class","href":"wyatt_authentication_bloc/AuthenticationRepository-class.md"}},{"name":"signUpWithEmailAndPassword","qualifiedName":"wyatt_authentication_bloc.AuthenticationRepository.signUpWithEmailAndPassword","href":"wyatt_authentication_bloc/AuthenticationRepository/signUpWithEmailAndPassword.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Creates a new user with the provided email and password.","enclosedBy":{"name":"AuthenticationRepository","type":"class","href":"wyatt_authentication_bloc/AuthenticationRepository-class.md"}},{"name":"updateEmail","qualifiedName":"wyatt_authentication_bloc.AuthenticationRepository.updateEmail","href":"wyatt_authentication_bloc/AuthenticationRepository/updateEmail.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Update or add email.","enclosedBy":{"name":"AuthenticationRepository","type":"class","href":"wyatt_authentication_bloc/AuthenticationRepository-class.md"}},{"name":"updatePassword","qualifiedName":"wyatt_authentication_bloc.AuthenticationRepository.updatePassword","href":"wyatt_authentication_bloc/AuthenticationRepository/updatePassword.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Update or add password.","enclosedBy":{"name":"AuthenticationRepository","type":"class","href":"wyatt_authentication_bloc/AuthenticationRepository-class.md"}},{"name":"verifyPasswordResetCode","qualifiedName":"wyatt_authentication_bloc.AuthenticationRepository.verifyPasswordResetCode","href":"wyatt_authentication_bloc/AuthenticationRepository/verifyPasswordResetCode.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Verify password reset code.","enclosedBy":{"name":"AuthenticationRepository","type":"class","href":"wyatt_authentication_bloc/AuthenticationRepository-class.md"}},{"name":"AuthenticationRepositoryImpl","qualifiedName":"wyatt_authentication_bloc.AuthenticationRepositoryImpl","href":"wyatt_authentication_bloc/AuthenticationRepositoryImpl-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"AuthenticationRepositoryImpl","qualifiedName":"wyatt_authentication_bloc.AuthenticationRepositoryImpl.AuthenticationRepositoryImpl","href":"wyatt_authentication_bloc/AuthenticationRepositoryImpl/AuthenticationRepositoryImpl.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"AuthenticationRepositoryImpl","type":"class","href":"wyatt_authentication_bloc/AuthenticationRepositoryImpl-class.md"}},{"name":"addSession","qualifiedName":"wyatt_authentication_bloc.AuthenticationRepositoryImpl.addSession","href":"wyatt_authentication_bloc/AuthenticationRepositoryImpl/addSession.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"Add a new authentication event.","enclosedBy":{"name":"AuthenticationRepositoryImpl","type":"class","href":"wyatt_authentication_bloc/AuthenticationRepositoryImpl-class.md"}},{"name":"authenticationRemoteDataSource","qualifiedName":"wyatt_authentication_bloc.AuthenticationRepositoryImpl.authenticationRemoteDataSource","href":"wyatt_authentication_bloc/AuthenticationRepositoryImpl/authenticationRemoteDataSource.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"AuthenticationRepositoryImpl","type":"class","href":"wyatt_authentication_bloc/AuthenticationRepositoryImpl-class.md"}},{"name":"confirmPasswordReset","qualifiedName":"wyatt_authentication_bloc.AuthenticationRepositoryImpl.confirmPasswordReset","href":"wyatt_authentication_bloc/AuthenticationRepositoryImpl/confirmPasswordReset.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"Confirms the password reset with the provided newPassword and code.","enclosedBy":{"name":"AuthenticationRepositoryImpl","type":"class","href":"wyatt_authentication_bloc/AuthenticationRepositoryImpl-class.md"}},{"name":"delete","qualifiedName":"wyatt_authentication_bloc.AuthenticationRepositoryImpl.delete","href":"wyatt_authentication_bloc/AuthenticationRepositoryImpl/delete.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"Delete account.","enclosedBy":{"name":"AuthenticationRepositoryImpl","type":"class","href":"wyatt_authentication_bloc/AuthenticationRepositoryImpl-class.md"}},{"name":"formRepository","qualifiedName":"wyatt_authentication_bloc.AuthenticationRepositoryImpl.formRepository","href":"wyatt_authentication_bloc/AuthenticationRepositoryImpl/formRepository.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Form repository used in different authentication cubits/blocs","enclosedBy":{"name":"AuthenticationRepositoryImpl","type":"class","href":"wyatt_authentication_bloc/AuthenticationRepositoryImpl-class.md"}},{"name":"reauthenticate","qualifiedName":"wyatt_authentication_bloc.AuthenticationRepositoryImpl.reauthenticate","href":"wyatt_authentication_bloc/AuthenticationRepositoryImpl/reauthenticate.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"Some security-sensitive actions—such as deleting an account,\nsetting a primary email address, and changing a password—require that\nthe user has recently signed in.","enclosedBy":{"name":"AuthenticationRepositoryImpl","type":"class","href":"wyatt_authentication_bloc/AuthenticationRepositoryImpl-class.md"}},{"name":"refresh","qualifiedName":"wyatt_authentication_bloc.AuthenticationRepositoryImpl.refresh","href":"wyatt_authentication_bloc/AuthenticationRepositoryImpl/refresh.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"Refreshes the current user, if signed in.","enclosedBy":{"name":"AuthenticationRepositoryImpl","type":"class","href":"wyatt_authentication_bloc/AuthenticationRepositoryImpl-class.md"}},{"name":"sendEmailVerification","qualifiedName":"wyatt_authentication_bloc.AuthenticationRepositoryImpl.sendEmailVerification","href":"wyatt_authentication_bloc/AuthenticationRepositoryImpl/sendEmailVerification.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"Sends verification email to the account email.","enclosedBy":{"name":"AuthenticationRepositoryImpl","type":"class","href":"wyatt_authentication_bloc/AuthenticationRepositoryImpl-class.md"}},{"name":"sendPasswordResetEmail","qualifiedName":"wyatt_authentication_bloc.AuthenticationRepositoryImpl.sendPasswordResetEmail","href":"wyatt_authentication_bloc/AuthenticationRepositoryImpl/sendPasswordResetEmail.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"Sends a password reset email to the provided email.","enclosedBy":{"name":"AuthenticationRepositoryImpl","type":"class","href":"wyatt_authentication_bloc/AuthenticationRepositoryImpl-class.md"}},{"name":"sessionStream","qualifiedName":"wyatt_authentication_bloc.AuthenticationRepositoryImpl.sessionStream","href":"wyatt_authentication_bloc/AuthenticationRepositoryImpl/sessionStream.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"Authentication state change event stream.","enclosedBy":{"name":"AuthenticationRepositoryImpl","type":"class","href":"wyatt_authentication_bloc/AuthenticationRepositoryImpl-class.md"}},{"name":"signInAnonymously","qualifiedName":"wyatt_authentication_bloc.AuthenticationRepositoryImpl.signInAnonymously","href":"wyatt_authentication_bloc/AuthenticationRepositoryImpl/signInAnonymously.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"Sign in anonymously.","enclosedBy":{"name":"AuthenticationRepositoryImpl","type":"class","href":"wyatt_authentication_bloc/AuthenticationRepositoryImpl-class.md"}},{"name":"signInWithEmailAndPassword","qualifiedName":"wyatt_authentication_bloc.AuthenticationRepositoryImpl.signInWithEmailAndPassword","href":"wyatt_authentication_bloc/AuthenticationRepositoryImpl/signInWithEmailAndPassword.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"Signs in with the provided email and password.","enclosedBy":{"name":"AuthenticationRepositoryImpl","type":"class","href":"wyatt_authentication_bloc/AuthenticationRepositoryImpl-class.md"}},{"name":"signInWithGoogle","qualifiedName":"wyatt_authentication_bloc.AuthenticationRepositoryImpl.signInWithGoogle","href":"wyatt_authentication_bloc/AuthenticationRepositoryImpl/signInWithGoogle.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"Starts the Sign In with Google Flow.","enclosedBy":{"name":"AuthenticationRepositoryImpl","type":"class","href":"wyatt_authentication_bloc/AuthenticationRepositoryImpl-class.md"}},{"name":"signOut","qualifiedName":"wyatt_authentication_bloc.AuthenticationRepositoryImpl.signOut","href":"wyatt_authentication_bloc/AuthenticationRepositoryImpl/signOut.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"Signs out the current user.\nIt also clears the cache and the associated data.","enclosedBy":{"name":"AuthenticationRepositoryImpl","type":"class","href":"wyatt_authentication_bloc/AuthenticationRepositoryImpl-class.md"}},{"name":"signUpWithEmailAndPassword","qualifiedName":"wyatt_authentication_bloc.AuthenticationRepositoryImpl.signUpWithEmailAndPassword","href":"wyatt_authentication_bloc/AuthenticationRepositoryImpl/signUpWithEmailAndPassword.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"Creates a new user with the provided email and password.","enclosedBy":{"name":"AuthenticationRepositoryImpl","type":"class","href":"wyatt_authentication_bloc/AuthenticationRepositoryImpl-class.md"}},{"name":"updateEmail","qualifiedName":"wyatt_authentication_bloc.AuthenticationRepositoryImpl.updateEmail","href":"wyatt_authentication_bloc/AuthenticationRepositoryImpl/updateEmail.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"Update or add email.","enclosedBy":{"name":"AuthenticationRepositoryImpl","type":"class","href":"wyatt_authentication_bloc/AuthenticationRepositoryImpl-class.md"}},{"name":"updatePassword","qualifiedName":"wyatt_authentication_bloc.AuthenticationRepositoryImpl.updatePassword","href":"wyatt_authentication_bloc/AuthenticationRepositoryImpl/updatePassword.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"Update or add password.","enclosedBy":{"name":"AuthenticationRepositoryImpl","type":"class","href":"wyatt_authentication_bloc/AuthenticationRepositoryImpl-class.md"}},{"name":"verifyPasswordResetCode","qualifiedName":"wyatt_authentication_bloc.AuthenticationRepositoryImpl.verifyPasswordResetCode","href":"wyatt_authentication_bloc/AuthenticationRepositoryImpl/verifyPasswordResetCode.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"Verify password reset code.","enclosedBy":{"name":"AuthenticationRepositoryImpl","type":"class","href":"wyatt_authentication_bloc/AuthenticationRepositoryImpl-class.md"}},{"name":"AuthenticationState","qualifiedName":"wyatt_authentication_bloc.AuthenticationState","href":"wyatt_authentication_bloc/AuthenticationState-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"AuthenticationState.authenticated","qualifiedName":"wyatt_authentication_bloc.AuthenticationState.authenticated","href":"wyatt_authentication_bloc/AuthenticationState/AuthenticationState.authenticated.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"AuthenticationState","type":"class","href":"wyatt_authentication_bloc/AuthenticationState-class.md"}},{"name":"props","qualifiedName":"wyatt_authentication_bloc.AuthenticationState.props","href":"wyatt_authentication_bloc/AuthenticationState/props.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"The list of properties that will be used to determine whether\ntwo instances are equal.","enclosedBy":{"name":"AuthenticationState","type":"class","href":"wyatt_authentication_bloc/AuthenticationState-class.md"}},{"name":"status","qualifiedName":"wyatt_authentication_bloc.AuthenticationState.status","href":"wyatt_authentication_bloc/AuthenticationState/status.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"AuthenticationState","type":"class","href":"wyatt_authentication_bloc/AuthenticationState-class.md"}},{"name":"stringify","qualifiedName":"wyatt_authentication_bloc.AuthenticationState.stringify","href":"wyatt_authentication_bloc/AuthenticationState/stringify.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"If set to true, the toString method will be overridden to output\nthis instance's props.","enclosedBy":{"name":"AuthenticationState","type":"class","href":"wyatt_authentication_bloc/AuthenticationState-class.md"}},{"name":"AuthenticationState.unauthenticated","qualifiedName":"wyatt_authentication_bloc.AuthenticationState.unauthenticated","href":"wyatt_authentication_bloc/AuthenticationState/AuthenticationState.unauthenticated.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"AuthenticationState","type":"class","href":"wyatt_authentication_bloc/AuthenticationState-class.md"}},{"name":"AuthenticationState.unknown","qualifiedName":"wyatt_authentication_bloc.AuthenticationState.unknown","href":"wyatt_authentication_bloc/AuthenticationState/AuthenticationState.unknown.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"AuthenticationState","type":"class","href":"wyatt_authentication_bloc/AuthenticationState-class.md"}},{"name":"wrapper","qualifiedName":"wyatt_authentication_bloc.AuthenticationState.wrapper","href":"wyatt_authentication_bloc/AuthenticationState/wrapper.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"AuthenticationState","type":"class","href":"wyatt_authentication_bloc/AuthenticationState-class.md"}},{"name":"AuthenticationStatus","qualifiedName":"wyatt_authentication_bloc.AuthenticationStatus","href":"wyatt_authentication_bloc/AuthenticationStatus.md","type":"enum","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Different authentication status","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"AuthenticationStatus","qualifiedName":"wyatt_authentication_bloc.AuthenticationStatus.AuthenticationStatus","href":"wyatt_authentication_bloc/AuthenticationStatus/AuthenticationStatus.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"AuthenticationStatus","type":"enum","href":"wyatt_authentication_bloc/AuthenticationStatus.md"}},{"name":"values","qualifiedName":"wyatt_authentication_bloc.AuthenticationStatus.values","href":"wyatt_authentication_bloc/AuthenticationStatus/values-constant.md","type":"constant","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"A constant List of the values in this enum, in order of their declaration.","enclosedBy":{"name":"AuthenticationStatus","type":"enum","href":"wyatt_authentication_bloc/AuthenticationStatus.md"}},{"name":"BaseEditAccountCubit","qualifiedName":"wyatt_authentication_bloc.BaseEditAccountCubit","href":"wyatt_authentication_bloc/BaseEditAccountCubit-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Abstract edit account cubit useful for implementing a cubit with fine\ngranularity by adding only the required mixins.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"BaseEditAccountCubit","qualifiedName":"wyatt_authentication_bloc.BaseEditAccountCubit.BaseEditAccountCubit","href":"wyatt_authentication_bloc/BaseEditAccountCubit/BaseEditAccountCubit.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"BaseEditAccountCubit","type":"class","href":"wyatt_authentication_bloc/BaseEditAccountCubit-class.md"}},{"name":"authenticationRepository","qualifiedName":"wyatt_authentication_bloc.BaseEditAccountCubit.authenticationRepository","href":"wyatt_authentication_bloc/BaseEditAccountCubit/authenticationRepository.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"BaseEditAccountCubit","type":"class","href":"wyatt_authentication_bloc/BaseEditAccountCubit-class.md"}},{"name":"dataChanged","qualifiedName":"wyatt_authentication_bloc.BaseEditAccountCubit.dataChanged","href":"wyatt_authentication_bloc/BaseEditAccountCubit/dataChanged.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"BaseEditAccountCubit","type":"class","href":"wyatt_authentication_bloc/BaseEditAccountCubit-class.md"}},{"name":"formName","qualifiedName":"wyatt_authentication_bloc.BaseEditAccountCubit.formName","href":"wyatt_authentication_bloc/BaseEditAccountCubit/formName.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"BaseEditAccountCubit","type":"class","href":"wyatt_authentication_bloc/BaseEditAccountCubit-class.md"}},{"name":"formRepository","qualifiedName":"wyatt_authentication_bloc.BaseEditAccountCubit.formRepository","href":"wyatt_authentication_bloc/BaseEditAccountCubit/formRepository.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"BaseEditAccountCubit","type":"class","href":"wyatt_authentication_bloc/BaseEditAccountCubit-class.md"}},{"name":"reset","qualifiedName":"wyatt_authentication_bloc.BaseEditAccountCubit.reset","href":"wyatt_authentication_bloc/BaseEditAccountCubit/reset.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"BaseEditAccountCubit","type":"class","href":"wyatt_authentication_bloc/BaseEditAccountCubit-class.md"}},{"name":"submit","qualifiedName":"wyatt_authentication_bloc.BaseEditAccountCubit.submit","href":"wyatt_authentication_bloc/BaseEditAccountCubit/submit.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"BaseEditAccountCubit","type":"class","href":"wyatt_authentication_bloc/BaseEditAccountCubit-class.md"}},{"name":"update","qualifiedName":"wyatt_authentication_bloc.BaseEditAccountCubit.update","href":"wyatt_authentication_bloc/BaseEditAccountCubit/update.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"BaseEditAccountCubit","type":"class","href":"wyatt_authentication_bloc/BaseEditAccountCubit-class.md"}},{"name":"validate","qualifiedName":"wyatt_authentication_bloc.BaseEditAccountCubit.validate","href":"wyatt_authentication_bloc/BaseEditAccountCubit/validate.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"BaseEditAccountCubit","type":"class","href":"wyatt_authentication_bloc/BaseEditAccountCubit-class.md"}},{"name":"BaseSignInCubit","qualifiedName":"wyatt_authentication_bloc.BaseSignInCubit","href":"wyatt_authentication_bloc/BaseSignInCubit-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Abstract sign in cubit useful for implementing a cubit with fine \ngranularity by adding only the required mixins.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"BaseSignInCubit","qualifiedName":"wyatt_authentication_bloc.BaseSignInCubit.BaseSignInCubit","href":"wyatt_authentication_bloc/BaseSignInCubit/BaseSignInCubit.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"BaseSignInCubit","type":"class","href":"wyatt_authentication_bloc/BaseSignInCubit-class.md"}},{"name":"authenticationRepository","qualifiedName":"wyatt_authentication_bloc.BaseSignInCubit.authenticationRepository","href":"wyatt_authentication_bloc/BaseSignInCubit/authenticationRepository.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"BaseSignInCubit","type":"class","href":"wyatt_authentication_bloc/BaseSignInCubit-class.md"}},{"name":"dataChanged","qualifiedName":"wyatt_authentication_bloc.BaseSignInCubit.dataChanged","href":"wyatt_authentication_bloc/BaseSignInCubit/dataChanged.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"BaseSignInCubit","type":"class","href":"wyatt_authentication_bloc/BaseSignInCubit-class.md"}},{"name":"formName","qualifiedName":"wyatt_authentication_bloc.BaseSignInCubit.formName","href":"wyatt_authentication_bloc/BaseSignInCubit/formName.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"BaseSignInCubit","type":"class","href":"wyatt_authentication_bloc/BaseSignInCubit-class.md"}},{"name":"formRepository","qualifiedName":"wyatt_authentication_bloc.BaseSignInCubit.formRepository","href":"wyatt_authentication_bloc/BaseSignInCubit/formRepository.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"BaseSignInCubit","type":"class","href":"wyatt_authentication_bloc/BaseSignInCubit-class.md"}},{"name":"reset","qualifiedName":"wyatt_authentication_bloc.BaseSignInCubit.reset","href":"wyatt_authentication_bloc/BaseSignInCubit/reset.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"BaseSignInCubit","type":"class","href":"wyatt_authentication_bloc/BaseSignInCubit-class.md"}},{"name":"submit","qualifiedName":"wyatt_authentication_bloc.BaseSignInCubit.submit","href":"wyatt_authentication_bloc/BaseSignInCubit/submit.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"BaseSignInCubit","type":"class","href":"wyatt_authentication_bloc/BaseSignInCubit-class.md"}},{"name":"update","qualifiedName":"wyatt_authentication_bloc.BaseSignInCubit.update","href":"wyatt_authentication_bloc/BaseSignInCubit/update.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"BaseSignInCubit","type":"class","href":"wyatt_authentication_bloc/BaseSignInCubit-class.md"}},{"name":"validate","qualifiedName":"wyatt_authentication_bloc.BaseSignInCubit.validate","href":"wyatt_authentication_bloc/BaseSignInCubit/validate.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"BaseSignInCubit","type":"class","href":"wyatt_authentication_bloc/BaseSignInCubit-class.md"}},{"name":"BaseSignUpCubit","qualifiedName":"wyatt_authentication_bloc.BaseSignUpCubit","href":"wyatt_authentication_bloc/BaseSignUpCubit-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Abstract sign up cubit useful for implementing a cubit with fine \ngranularity by adding only the required mixins.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"BaseSignUpCubit","qualifiedName":"wyatt_authentication_bloc.BaseSignUpCubit.BaseSignUpCubit","href":"wyatt_authentication_bloc/BaseSignUpCubit/BaseSignUpCubit.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"BaseSignUpCubit","type":"class","href":"wyatt_authentication_bloc/BaseSignUpCubit-class.md"}},{"name":"authenticationRepository","qualifiedName":"wyatt_authentication_bloc.BaseSignUpCubit.authenticationRepository","href":"wyatt_authentication_bloc/BaseSignUpCubit/authenticationRepository.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"BaseSignUpCubit","type":"class","href":"wyatt_authentication_bloc/BaseSignUpCubit-class.md"}},{"name":"dataChanged","qualifiedName":"wyatt_authentication_bloc.BaseSignUpCubit.dataChanged","href":"wyatt_authentication_bloc/BaseSignUpCubit/dataChanged.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"BaseSignUpCubit","type":"class","href":"wyatt_authentication_bloc/BaseSignUpCubit-class.md"}},{"name":"formName","qualifiedName":"wyatt_authentication_bloc.BaseSignUpCubit.formName","href":"wyatt_authentication_bloc/BaseSignUpCubit/formName.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"BaseSignUpCubit","type":"class","href":"wyatt_authentication_bloc/BaseSignUpCubit-class.md"}},{"name":"formRepository","qualifiedName":"wyatt_authentication_bloc.BaseSignUpCubit.formRepository","href":"wyatt_authentication_bloc/BaseSignUpCubit/formRepository.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"BaseSignUpCubit","type":"class","href":"wyatt_authentication_bloc/BaseSignUpCubit-class.md"}},{"name":"reset","qualifiedName":"wyatt_authentication_bloc.BaseSignUpCubit.reset","href":"wyatt_authentication_bloc/BaseSignUpCubit/reset.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"BaseSignUpCubit","type":"class","href":"wyatt_authentication_bloc/BaseSignUpCubit-class.md"}},{"name":"submit","qualifiedName":"wyatt_authentication_bloc.BaseSignUpCubit.submit","href":"wyatt_authentication_bloc/BaseSignUpCubit/submit.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"BaseSignUpCubit","type":"class","href":"wyatt_authentication_bloc/BaseSignUpCubit-class.md"}},{"name":"update","qualifiedName":"wyatt_authentication_bloc.BaseSignUpCubit.update","href":"wyatt_authentication_bloc/BaseSignUpCubit/update.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"BaseSignUpCubit","type":"class","href":"wyatt_authentication_bloc/BaseSignUpCubit-class.md"}},{"name":"validate","qualifiedName":"wyatt_authentication_bloc.BaseSignUpCubit.validate","href":"wyatt_authentication_bloc/BaseSignUpCubit/validate.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"BaseSignUpCubit","type":"class","href":"wyatt_authentication_bloc/BaseSignUpCubit-class.md"}},{"name":"BuildContextExtension","qualifiedName":"wyatt_authentication_bloc.BuildContextExtension","href":"wyatt_authentication_bloc/BuildContextExtension.md","type":"extension","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Extension that helps to quickly access useful resources like wrapper,\nsession, account or data.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"account","qualifiedName":"wyatt_authentication_bloc.BuildContextExtension.account","href":"wyatt_authentication_bloc/BuildContextExtension/account.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Returns account","enclosedBy":{"name":"BuildContextExtension","type":"extension","href":"wyatt_authentication_bloc/BuildContextExtension.md"}},{"name":"data","qualifiedName":"wyatt_authentication_bloc.BuildContextExtension.data","href":"wyatt_authentication_bloc/BuildContextExtension/data.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Returns associated data","enclosedBy":{"name":"BuildContextExtension","type":"extension","href":"wyatt_authentication_bloc/BuildContextExtension.md"}},{"name":"session","qualifiedName":"wyatt_authentication_bloc.BuildContextExtension.session","href":"wyatt_authentication_bloc/BuildContextExtension/session.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Returns session","enclosedBy":{"name":"BuildContextExtension","type":"extension","href":"wyatt_authentication_bloc/BuildContextExtension.md"}},{"name":"wrapper","qualifiedName":"wyatt_authentication_bloc.BuildContextExtension.wrapper","href":"wyatt_authentication_bloc/BuildContextExtension/wrapper.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Returns session wrapper","enclosedBy":{"name":"BuildContextExtension","type":"extension","href":"wyatt_authentication_bloc/BuildContextExtension.md"}},{"name":"ConfirmPasswordResetFailureFirebase","qualifiedName":"wyatt_authentication_bloc.ConfirmPasswordResetFailureFirebase","href":"wyatt_authentication_bloc/ConfirmPasswordResetFailureFirebase-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the password reset process if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"ConfirmPasswordResetFailureFirebase","qualifiedName":"wyatt_authentication_bloc.ConfirmPasswordResetFailureFirebase.ConfirmPasswordResetFailureFirebase","href":"wyatt_authentication_bloc/ConfirmPasswordResetFailureFirebase/ConfirmPasswordResetFailureFirebase.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"ConfirmPasswordResetFailureFirebase","type":"class","href":"wyatt_authentication_bloc/ConfirmPasswordResetFailureFirebase-class.md"}},{"name":"ConfirmPasswordResetFailureFirebase.fromCode","qualifiedName":"wyatt_authentication_bloc.ConfirmPasswordResetFailureFirebase.fromCode","href":"wyatt_authentication_bloc/ConfirmPasswordResetFailureFirebase/ConfirmPasswordResetFailureFirebase.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"ConfirmPasswordResetFailureFirebase","type":"class","href":"wyatt_authentication_bloc/ConfirmPasswordResetFailureFirebase-class.md"}},{"name":"ConfirmPasswordResetFailureInterface","qualifiedName":"wyatt_authentication_bloc.ConfirmPasswordResetFailureInterface","href":"wyatt_authentication_bloc/ConfirmPasswordResetFailureInterface-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the password reset process if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"ConfirmPasswordResetFailureInterface","qualifiedName":"wyatt_authentication_bloc.ConfirmPasswordResetFailureInterface.ConfirmPasswordResetFailureInterface","href":"wyatt_authentication_bloc/ConfirmPasswordResetFailureInterface/ConfirmPasswordResetFailureInterface.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the password reset process if a failure occurs.","enclosedBy":{"name":"ConfirmPasswordResetFailureInterface","type":"class","href":"wyatt_authentication_bloc/ConfirmPasswordResetFailureInterface-class.md"}},{"name":"ConfirmPasswordResetFailureInterface.fromCode","qualifiedName":"wyatt_authentication_bloc.ConfirmPasswordResetFailureInterface.fromCode","href":"wyatt_authentication_bloc/ConfirmPasswordResetFailureInterface/ConfirmPasswordResetFailureInterface.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the password reset process if a failure occurs.","enclosedBy":{"name":"ConfirmPasswordResetFailureInterface","type":"class","href":"wyatt_authentication_bloc/ConfirmPasswordResetFailureInterface-class.md"}},{"name":"CustomRoutine","qualifiedName":"wyatt_authentication_bloc.CustomRoutine","href":"wyatt_authentication_bloc/CustomRoutine-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Calls on each cubit action of this package.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"CustomRoutine","qualifiedName":"wyatt_authentication_bloc.CustomRoutine.CustomRoutine","href":"wyatt_authentication_bloc/CustomRoutine/CustomRoutine.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"CustomRoutine","type":"class","href":"wyatt_authentication_bloc/CustomRoutine-class.md"}},{"name":"attachedLogic","qualifiedName":"wyatt_authentication_bloc.CustomRoutine.attachedLogic","href":"wyatt_authentication_bloc/CustomRoutine/attachedLogic.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"CustomRoutine","type":"class","href":"wyatt_authentication_bloc/CustomRoutine-class.md"}},{"name":"call","qualifiedName":"wyatt_authentication_bloc.CustomRoutine.call","href":"wyatt_authentication_bloc/CustomRoutine/call.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"CustomRoutine","type":"class","href":"wyatt_authentication_bloc/CustomRoutine-class.md"}},{"name":"onError","qualifiedName":"wyatt_authentication_bloc.CustomRoutine.onError","href":"wyatt_authentication_bloc/CustomRoutine/onError.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"CustomRoutine","type":"class","href":"wyatt_authentication_bloc/CustomRoutine-class.md"}},{"name":"onSuccess","qualifiedName":"wyatt_authentication_bloc.CustomRoutine.onSuccess","href":"wyatt_authentication_bloc/CustomRoutine/onSuccess.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"CustomRoutine","type":"class","href":"wyatt_authentication_bloc/CustomRoutine-class.md"}},{"name":"routine","qualifiedName":"wyatt_authentication_bloc.CustomRoutine.routine","href":"wyatt_authentication_bloc/CustomRoutine/routine.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"CustomRoutine","type":"class","href":"wyatt_authentication_bloc/CustomRoutine-class.md"}},{"name":"DeleteAccountFailureFirebase","qualifiedName":"wyatt_authentication_bloc.DeleteAccountFailureFirebase","href":"wyatt_authentication_bloc/DeleteAccountFailureFirebase-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the account deletion if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"DeleteAccountFailureFirebase","qualifiedName":"wyatt_authentication_bloc.DeleteAccountFailureFirebase.DeleteAccountFailureFirebase","href":"wyatt_authentication_bloc/DeleteAccountFailureFirebase/DeleteAccountFailureFirebase.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"DeleteAccountFailureFirebase","type":"class","href":"wyatt_authentication_bloc/DeleteAccountFailureFirebase-class.md"}},{"name":"DeleteAccountFailureFirebase.fromCode","qualifiedName":"wyatt_authentication_bloc.DeleteAccountFailureFirebase.fromCode","href":"wyatt_authentication_bloc/DeleteAccountFailureFirebase/DeleteAccountFailureFirebase.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"DeleteAccountFailureFirebase","type":"class","href":"wyatt_authentication_bloc/DeleteAccountFailureFirebase-class.md"}},{"name":"DeleteAccountFailureInterface","qualifiedName":"wyatt_authentication_bloc.DeleteAccountFailureInterface","href":"wyatt_authentication_bloc/DeleteAccountFailureInterface-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the account deletion if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"DeleteAccountFailureInterface","qualifiedName":"wyatt_authentication_bloc.DeleteAccountFailureInterface.DeleteAccountFailureInterface","href":"wyatt_authentication_bloc/DeleteAccountFailureInterface/DeleteAccountFailureInterface.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"DeleteAccountFailureInterface","type":"class","href":"wyatt_authentication_bloc/DeleteAccountFailureInterface-class.md"}},{"name":"DeleteAccountFailureInterface.fromCode","qualifiedName":"wyatt_authentication_bloc.DeleteAccountFailureInterface.fromCode","href":"wyatt_authentication_bloc/DeleteAccountFailureInterface/DeleteAccountFailureInterface.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"DeleteAccountFailureInterface","type":"class","href":"wyatt_authentication_bloc/DeleteAccountFailureInterface-class.md"}},{"name":"DeletedEvent","qualifiedName":"wyatt_authentication_bloc.DeletedEvent","href":"wyatt_authentication_bloc/DeletedEvent-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"When a user deleted his account.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"DeletedEvent","qualifiedName":"wyatt_authentication_bloc.DeletedEvent.DeletedEvent","href":"wyatt_authentication_bloc/DeletedEvent/DeletedEvent.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"DeletedEvent","type":"class","href":"wyatt_authentication_bloc/DeletedEvent-class.md"}},{"name":"EditAccountCubit","qualifiedName":"wyatt_authentication_bloc.EditAccountCubit","href":"wyatt_authentication_bloc/EditAccountCubit-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Fully featured edit account cubit.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"EditAccountCubit","qualifiedName":"wyatt_authentication_bloc.EditAccountCubit.EditAccountCubit","href":"wyatt_authentication_bloc/EditAccountCubit/EditAccountCubit.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"EditAccountCubit","type":"class","href":"wyatt_authentication_bloc/EditAccountCubit-class.md"}},{"name":"onEmailUpdated","qualifiedName":"wyatt_authentication_bloc.EditAccountCubit.onEmailUpdated","href":"wyatt_authentication_bloc/EditAccountCubit/onEmailUpdated.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"This callback is triggered when user updates his email","enclosedBy":{"name":"EditAccountCubit","type":"class","href":"wyatt_authentication_bloc/EditAccountCubit-class.md"}},{"name":"onPasswordUpdated","qualifiedName":"wyatt_authentication_bloc.EditAccountCubit.onPasswordUpdated","href":"wyatt_authentication_bloc/EditAccountCubit/onPasswordUpdated.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"This callback is triggered when a user edits his password.","enclosedBy":{"name":"EditAccountCubit","type":"class","href":"wyatt_authentication_bloc/EditAccountCubit-class.md"}},{"name":"EditAccountListener","qualifiedName":"wyatt_authentication_bloc.EditAccountListener","href":"wyatt_authentication_bloc/EditAccountListener-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Widget that listens and builds a child based on the state of\nthe edit account cubit","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"EditAccountListener","qualifiedName":"wyatt_authentication_bloc.EditAccountListener.EditAccountListener","href":"wyatt_authentication_bloc/EditAccountListener/EditAccountListener.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"EditAccountListener","type":"class","href":"wyatt_authentication_bloc/EditAccountListener-class.md"}},{"name":"build","qualifiedName":"wyatt_authentication_bloc.EditAccountListener.build","href":"wyatt_authentication_bloc/EditAccountListener/build.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"Describes the part of the user interface represented by this widget.","enclosedBy":{"name":"EditAccountListener","type":"class","href":"wyatt_authentication_bloc/EditAccountListener-class.md"}},{"name":"child","qualifiedName":"wyatt_authentication_bloc.EditAccountListener.child","href":"wyatt_authentication_bloc/EditAccountListener/child.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"EditAccountListener","type":"class","href":"wyatt_authentication_bloc/EditAccountListener-class.md"}},{"name":"customBuilder","qualifiedName":"wyatt_authentication_bloc.EditAccountListener.customBuilder","href":"wyatt_authentication_bloc/EditAccountListener/customBuilder.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"EditAccountListener","type":"class","href":"wyatt_authentication_bloc/EditAccountListener-class.md"}},{"name":"onError","qualifiedName":"wyatt_authentication_bloc.EditAccountListener.onError","href":"wyatt_authentication_bloc/EditAccountListener/onError.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"EditAccountListener","type":"class","href":"wyatt_authentication_bloc/EditAccountListener-class.md"}},{"name":"onProgress","qualifiedName":"wyatt_authentication_bloc.EditAccountListener.onProgress","href":"wyatt_authentication_bloc/EditAccountListener/onProgress.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"EditAccountListener","type":"class","href":"wyatt_authentication_bloc/EditAccountListener-class.md"}},{"name":"onSuccess","qualifiedName":"wyatt_authentication_bloc.EditAccountListener.onSuccess","href":"wyatt_authentication_bloc/EditAccountListener/onSuccess.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"EditAccountListener","type":"class","href":"wyatt_authentication_bloc/EditAccountListener-class.md"}},{"name":"EditAccountState","qualifiedName":"wyatt_authentication_bloc.EditAccountState","href":"wyatt_authentication_bloc/EditAccountState-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Edit account cubit state to manage the form.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"EditAccountState","qualifiedName":"wyatt_authentication_bloc.EditAccountState.EditAccountState","href":"wyatt_authentication_bloc/EditAccountState/EditAccountState.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"EditAccountState","type":"class","href":"wyatt_authentication_bloc/EditAccountState-class.md"}},{"name":"copyWith","qualifiedName":"wyatt_authentication_bloc.EditAccountState.copyWith","href":"wyatt_authentication_bloc/EditAccountState/copyWith.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"EditAccountState","type":"class","href":"wyatt_authentication_bloc/EditAccountState-class.md"}},{"name":"email","qualifiedName":"wyatt_authentication_bloc.EditAccountState.email","href":"wyatt_authentication_bloc/EditAccountState/email.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"EditAccountState","type":"class","href":"wyatt_authentication_bloc/EditAccountState-class.md"}},{"name":"errorMessage","qualifiedName":"wyatt_authentication_bloc.EditAccountState.errorMessage","href":"wyatt_authentication_bloc/EditAccountState/errorMessage.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Optional error message.","enclosedBy":{"name":"EditAccountState","type":"class","href":"wyatt_authentication_bloc/EditAccountState-class.md"}},{"name":"form","qualifiedName":"wyatt_authentication_bloc.EditAccountState.form","href":"wyatt_authentication_bloc/EditAccountState/form.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"FormData with all inputs, and associated metadata.","enclosedBy":{"name":"EditAccountState","type":"class","href":"wyatt_authentication_bloc/EditAccountState-class.md"}},{"name":"password","qualifiedName":"wyatt_authentication_bloc.EditAccountState.password","href":"wyatt_authentication_bloc/EditAccountState/password.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"EditAccountState","type":"class","href":"wyatt_authentication_bloc/EditAccountState-class.md"}},{"name":"props","qualifiedName":"wyatt_authentication_bloc.EditAccountState.props","href":"wyatt_authentication_bloc/EditAccountState/props.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"The list of properties that will be used to determine whether\ntwo instances are equal.","enclosedBy":{"name":"EditAccountState","type":"class","href":"wyatt_authentication_bloc/EditAccountState-class.md"}},{"name":"status","qualifiedName":"wyatt_authentication_bloc.EditAccountState.status","href":"wyatt_authentication_bloc/EditAccountState/status.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Global status of a form.","enclosedBy":{"name":"EditAccountState","type":"class","href":"wyatt_authentication_bloc/EditAccountState-class.md"}},{"name":"toString","qualifiedName":"wyatt_authentication_bloc.EditAccountState.toString","href":"wyatt_authentication_bloc/EditAccountState/toString.md","type":"method","overriddenDepth":2,"packageName":"wyatt_authentication_bloc","desc":"A string representation of this object.","enclosedBy":{"name":"EditAccountState","type":"class","href":"wyatt_authentication_bloc/EditAccountState-class.md"}},{"name":"EmailVerificationBuilder","qualifiedName":"wyatt_authentication_bloc.EmailVerificationBuilder","href":"wyatt_authentication_bloc/EmailVerificationBuilder-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"EmailVerificationBuilder","qualifiedName":"wyatt_authentication_bloc.EmailVerificationBuilder.EmailVerificationBuilder","href":"wyatt_authentication_bloc/EmailVerificationBuilder/EmailVerificationBuilder.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"EmailVerificationBuilder","type":"class","href":"wyatt_authentication_bloc/EmailVerificationBuilder-class.md"}},{"name":"build","qualifiedName":"wyatt_authentication_bloc.EmailVerificationBuilder.build","href":"wyatt_authentication_bloc/EmailVerificationBuilder/build.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"Describes the part of the user interface represented by this widget.","enclosedBy":{"name":"EmailVerificationBuilder","type":"class","href":"wyatt_authentication_bloc/EmailVerificationBuilder-class.md"}},{"name":"customBuilder","qualifiedName":"wyatt_authentication_bloc.EmailVerificationBuilder.customBuilder","href":"wyatt_authentication_bloc/EmailVerificationBuilder/customBuilder.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"EmailVerificationBuilder","type":"class","href":"wyatt_authentication_bloc/EmailVerificationBuilder-class.md"}},{"name":"notVerified","qualifiedName":"wyatt_authentication_bloc.EmailVerificationBuilder.notVerified","href":"wyatt_authentication_bloc/EmailVerificationBuilder/notVerified.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"EmailVerificationBuilder","type":"class","href":"wyatt_authentication_bloc/EmailVerificationBuilder-class.md"}},{"name":"onError","qualifiedName":"wyatt_authentication_bloc.EmailVerificationBuilder.onError","href":"wyatt_authentication_bloc/EmailVerificationBuilder/onError.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"EmailVerificationBuilder","type":"class","href":"wyatt_authentication_bloc/EmailVerificationBuilder-class.md"}},{"name":"verified","qualifiedName":"wyatt_authentication_bloc.EmailVerificationBuilder.verified","href":"wyatt_authentication_bloc/EmailVerificationBuilder/verified.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"EmailVerificationBuilder","type":"class","href":"wyatt_authentication_bloc/EmailVerificationBuilder-class.md"}},{"name":"EmailVerificationCubit","qualifiedName":"wyatt_authentication_bloc.EmailVerificationCubit","href":"wyatt_authentication_bloc/EmailVerificationCubit-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"EmailVerificationCubit","qualifiedName":"wyatt_authentication_bloc.EmailVerificationCubit.EmailVerificationCubit","href":"wyatt_authentication_bloc/EmailVerificationCubit/EmailVerificationCubit.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"EmailVerificationCubit","type":"class","href":"wyatt_authentication_bloc/EmailVerificationCubit-class.md"}},{"name":"authenticationRepository","qualifiedName":"wyatt_authentication_bloc.EmailVerificationCubit.authenticationRepository","href":"wyatt_authentication_bloc/EmailVerificationCubit/authenticationRepository.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"EmailVerificationCubit","type":"class","href":"wyatt_authentication_bloc/EmailVerificationCubit-class.md"}},{"name":"checkEmailVerification","qualifiedName":"wyatt_authentication_bloc.EmailVerificationCubit.checkEmailVerification","href":"wyatt_authentication_bloc/EmailVerificationCubit/checkEmailVerification.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"EmailVerificationCubit","type":"class","href":"wyatt_authentication_bloc/EmailVerificationCubit-class.md"}},{"name":"sendEmailVerification","qualifiedName":"wyatt_authentication_bloc.EmailVerificationCubit.sendEmailVerification","href":"wyatt_authentication_bloc/EmailVerificationCubit/sendEmailVerification.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"EmailVerificationCubit","type":"class","href":"wyatt_authentication_bloc/EmailVerificationCubit-class.md"}},{"name":"EmailVerificationState","qualifiedName":"wyatt_authentication_bloc.EmailVerificationState","href":"wyatt_authentication_bloc/EmailVerificationState-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"EmailVerificationState","qualifiedName":"wyatt_authentication_bloc.EmailVerificationState.EmailVerificationState","href":"wyatt_authentication_bloc/EmailVerificationState/EmailVerificationState.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"EmailVerificationState","type":"class","href":"wyatt_authentication_bloc/EmailVerificationState-class.md"}},{"name":"copyWith","qualifiedName":"wyatt_authentication_bloc.EmailVerificationState.copyWith","href":"wyatt_authentication_bloc/EmailVerificationState/copyWith.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"EmailVerificationState","type":"class","href":"wyatt_authentication_bloc/EmailVerificationState-class.md"}},{"name":"errorMessage","qualifiedName":"wyatt_authentication_bloc.EmailVerificationState.errorMessage","href":"wyatt_authentication_bloc/EmailVerificationState/errorMessage.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"EmailVerificationState","type":"class","href":"wyatt_authentication_bloc/EmailVerificationState-class.md"}},{"name":"isVerified","qualifiedName":"wyatt_authentication_bloc.EmailVerificationState.isVerified","href":"wyatt_authentication_bloc/EmailVerificationState/isVerified.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"EmailVerificationState","type":"class","href":"wyatt_authentication_bloc/EmailVerificationState-class.md"}},{"name":"props","qualifiedName":"wyatt_authentication_bloc.EmailVerificationState.props","href":"wyatt_authentication_bloc/EmailVerificationState/props.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"The list of properties that will be used to determine whether\ntwo instances are equal.","enclosedBy":{"name":"EmailVerificationState","type":"class","href":"wyatt_authentication_bloc/EmailVerificationState-class.md"}},{"name":"status","qualifiedName":"wyatt_authentication_bloc.EmailVerificationState.status","href":"wyatt_authentication_bloc/EmailVerificationState/status.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"EmailVerificationState","type":"class","href":"wyatt_authentication_bloc/EmailVerificationState-class.md"}},{"name":"toString","qualifiedName":"wyatt_authentication_bloc.EmailVerificationState.toString","href":"wyatt_authentication_bloc/EmailVerificationState/toString.md","type":"method","overriddenDepth":2,"packageName":"wyatt_authentication_bloc","desc":"A string representation of this object.","enclosedBy":{"name":"EmailVerificationState","type":"class","href":"wyatt_authentication_bloc/EmailVerificationState-class.md"}},{"name":"FetchSignInMethodsForEmailFailureFirebase","qualifiedName":"wyatt_authentication_bloc.FetchSignInMethodsForEmailFailureFirebase","href":"wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureFirebase-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the fetch sign in methods if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"FetchSignInMethodsForEmailFailureFirebase","qualifiedName":"wyatt_authentication_bloc.FetchSignInMethodsForEmailFailureFirebase.FetchSignInMethodsForEmailFailureFirebase","href":"wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureFirebase/FetchSignInMethodsForEmailFailureFirebase.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"FetchSignInMethodsForEmailFailureFirebase","type":"class","href":"wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureFirebase-class.md"}},{"name":"FetchSignInMethodsForEmailFailureFirebase.fromCode","qualifiedName":"wyatt_authentication_bloc.FetchSignInMethodsForEmailFailureFirebase.fromCode","href":"wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureFirebase/FetchSignInMethodsForEmailFailureFirebase.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"FetchSignInMethodsForEmailFailureFirebase","type":"class","href":"wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureFirebase-class.md"}},{"name":"FetchSignInMethodsForEmailFailureInterface","qualifiedName":"wyatt_authentication_bloc.FetchSignInMethodsForEmailFailureInterface","href":"wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureInterface-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the fetch sign in methods if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"FetchSignInMethodsForEmailFailureInterface","qualifiedName":"wyatt_authentication_bloc.FetchSignInMethodsForEmailFailureInterface.FetchSignInMethodsForEmailFailureInterface","href":"wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureInterface/FetchSignInMethodsForEmailFailureInterface.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the fetch sign in methods if a failure occurs.","enclosedBy":{"name":"FetchSignInMethodsForEmailFailureInterface","type":"class","href":"wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureInterface-class.md"}},{"name":"FetchSignInMethodsForEmailFailureInterface.fromCode","qualifiedName":"wyatt_authentication_bloc.FetchSignInMethodsForEmailFailureInterface.fromCode","href":"wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureInterface/FetchSignInMethodsForEmailFailureInterface.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the fetch sign in methods if a failure occurs.","enclosedBy":{"name":"FetchSignInMethodsForEmailFailureInterface","type":"class","href":"wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureInterface-class.md"}},{"name":"ModelParsingFailureFirebase","qualifiedName":"wyatt_authentication_bloc.ModelParsingFailureFirebase","href":"wyatt_authentication_bloc/ModelParsingFailureFirebase-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the model parsing process if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"ModelParsingFailureFirebase","qualifiedName":"wyatt_authentication_bloc.ModelParsingFailureFirebase.ModelParsingFailureFirebase","href":"wyatt_authentication_bloc/ModelParsingFailureFirebase/ModelParsingFailureFirebase.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"ModelParsingFailureFirebase","type":"class","href":"wyatt_authentication_bloc/ModelParsingFailureFirebase-class.md"}},{"name":"ModelParsingFailureFirebase.fromCode","qualifiedName":"wyatt_authentication_bloc.ModelParsingFailureFirebase.fromCode","href":"wyatt_authentication_bloc/ModelParsingFailureFirebase/ModelParsingFailureFirebase.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"ModelParsingFailureFirebase","type":"class","href":"wyatt_authentication_bloc/ModelParsingFailureFirebase-class.md"}},{"name":"ModelParsingFailureInterface","qualifiedName":"wyatt_authentication_bloc.ModelParsingFailureInterface","href":"wyatt_authentication_bloc/ModelParsingFailureInterface-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the model parsing process if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"ModelParsingFailureInterface","qualifiedName":"wyatt_authentication_bloc.ModelParsingFailureInterface.ModelParsingFailureInterface","href":"wyatt_authentication_bloc/ModelParsingFailureInterface/ModelParsingFailureInterface.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"ModelParsingFailureInterface","type":"class","href":"wyatt_authentication_bloc/ModelParsingFailureInterface-class.md"}},{"name":"ModelParsingFailureInterface.fromCode","qualifiedName":"wyatt_authentication_bloc.ModelParsingFailureInterface.fromCode","href":"wyatt_authentication_bloc/ModelParsingFailureInterface/ModelParsingFailureInterface.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"ModelParsingFailureInterface","type":"class","href":"wyatt_authentication_bloc/ModelParsingFailureInterface-class.md"}},{"name":"PasswordResetCubit","qualifiedName":"wyatt_authentication_bloc.PasswordResetCubit","href":"wyatt_authentication_bloc/PasswordResetCubit-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Cubit that allows user to reset his password","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"PasswordResetCubit","qualifiedName":"wyatt_authentication_bloc.PasswordResetCubit.PasswordResetCubit","href":"wyatt_authentication_bloc/PasswordResetCubit/PasswordResetCubit.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"PasswordResetCubit","type":"class","href":"wyatt_authentication_bloc/PasswordResetCubit-class.md"}},{"name":"authenticationRepository","qualifiedName":"wyatt_authentication_bloc.PasswordResetCubit.authenticationRepository","href":"wyatt_authentication_bloc/PasswordResetCubit/authenticationRepository.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"PasswordResetCubit","type":"class","href":"wyatt_authentication_bloc/PasswordResetCubit-class.md"}},{"name":"dataChanged","qualifiedName":"wyatt_authentication_bloc.PasswordResetCubit.dataChanged","href":"wyatt_authentication_bloc/PasswordResetCubit/dataChanged.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"PasswordResetCubit","type":"class","href":"wyatt_authentication_bloc/PasswordResetCubit-class.md"}},{"name":"emailChanged","qualifiedName":"wyatt_authentication_bloc.PasswordResetCubit.emailChanged","href":"wyatt_authentication_bloc/PasswordResetCubit/emailChanged.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"PasswordResetCubit","type":"class","href":"wyatt_authentication_bloc/PasswordResetCubit-class.md"}},{"name":"emailCustomChanged","qualifiedName":"wyatt_authentication_bloc.PasswordResetCubit.emailCustomChanged","href":"wyatt_authentication_bloc/PasswordResetCubit/emailCustomChanged.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Same as emailChanged but with a custom Validator.","enclosedBy":{"name":"PasswordResetCubit","type":"class","href":"wyatt_authentication_bloc/PasswordResetCubit-class.md"}},{"name":"formName","qualifiedName":"wyatt_authentication_bloc.PasswordResetCubit.formName","href":"wyatt_authentication_bloc/PasswordResetCubit/formName.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"PasswordResetCubit","type":"class","href":"wyatt_authentication_bloc/PasswordResetCubit-class.md"}},{"name":"formRepository","qualifiedName":"wyatt_authentication_bloc.PasswordResetCubit.formRepository","href":"wyatt_authentication_bloc/PasswordResetCubit/formRepository.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"PasswordResetCubit","type":"class","href":"wyatt_authentication_bloc/PasswordResetCubit-class.md"}},{"name":"reset","qualifiedName":"wyatt_authentication_bloc.PasswordResetCubit.reset","href":"wyatt_authentication_bloc/PasswordResetCubit/reset.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"PasswordResetCubit","type":"class","href":"wyatt_authentication_bloc/PasswordResetCubit-class.md"}},{"name":"submit","qualifiedName":"wyatt_authentication_bloc.PasswordResetCubit.submit","href":"wyatt_authentication_bloc/PasswordResetCubit/submit.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"Sends a password reset email to the user","enclosedBy":{"name":"PasswordResetCubit","type":"class","href":"wyatt_authentication_bloc/PasswordResetCubit-class.md"}},{"name":"update","qualifiedName":"wyatt_authentication_bloc.PasswordResetCubit.update","href":"wyatt_authentication_bloc/PasswordResetCubit/update.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"PasswordResetCubit","type":"class","href":"wyatt_authentication_bloc/PasswordResetCubit-class.md"}},{"name":"validate","qualifiedName":"wyatt_authentication_bloc.PasswordResetCubit.validate","href":"wyatt_authentication_bloc/PasswordResetCubit/validate.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"PasswordResetCubit","type":"class","href":"wyatt_authentication_bloc/PasswordResetCubit-class.md"}},{"name":"PasswordResetState","qualifiedName":"wyatt_authentication_bloc.PasswordResetState","href":"wyatt_authentication_bloc/PasswordResetState-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"PasswordResetState","qualifiedName":"wyatt_authentication_bloc.PasswordResetState.PasswordResetState","href":"wyatt_authentication_bloc/PasswordResetState/PasswordResetState.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"PasswordResetState","type":"class","href":"wyatt_authentication_bloc/PasswordResetState-class.md"}},{"name":"copyWith","qualifiedName":"wyatt_authentication_bloc.PasswordResetState.copyWith","href":"wyatt_authentication_bloc/PasswordResetState/copyWith.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"PasswordResetState","type":"class","href":"wyatt_authentication_bloc/PasswordResetState-class.md"}},{"name":"email","qualifiedName":"wyatt_authentication_bloc.PasswordResetState.email","href":"wyatt_authentication_bloc/PasswordResetState/email.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"PasswordResetState","type":"class","href":"wyatt_authentication_bloc/PasswordResetState-class.md"}},{"name":"errorMessage","qualifiedName":"wyatt_authentication_bloc.PasswordResetState.errorMessage","href":"wyatt_authentication_bloc/PasswordResetState/errorMessage.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Optional error message.","enclosedBy":{"name":"PasswordResetState","type":"class","href":"wyatt_authentication_bloc/PasswordResetState-class.md"}},{"name":"form","qualifiedName":"wyatt_authentication_bloc.PasswordResetState.form","href":"wyatt_authentication_bloc/PasswordResetState/form.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"FormData with all inputs, and associated metadata.","enclosedBy":{"name":"PasswordResetState","type":"class","href":"wyatt_authentication_bloc/PasswordResetState-class.md"}},{"name":"props","qualifiedName":"wyatt_authentication_bloc.PasswordResetState.props","href":"wyatt_authentication_bloc/PasswordResetState/props.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"The list of properties that will be used to determine whether\ntwo instances are equal.","enclosedBy":{"name":"PasswordResetState","type":"class","href":"wyatt_authentication_bloc/PasswordResetState-class.md"}},{"name":"status","qualifiedName":"wyatt_authentication_bloc.PasswordResetState.status","href":"wyatt_authentication_bloc/PasswordResetState/status.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Global status of a form.","enclosedBy":{"name":"PasswordResetState","type":"class","href":"wyatt_authentication_bloc/PasswordResetState-class.md"}},{"name":"toString","qualifiedName":"wyatt_authentication_bloc.PasswordResetState.toString","href":"wyatt_authentication_bloc/PasswordResetState/toString.md","type":"method","overriddenDepth":2,"packageName":"wyatt_authentication_bloc","desc":"A string representation of this object.","enclosedBy":{"name":"PasswordResetState","type":"class","href":"wyatt_authentication_bloc/PasswordResetState-class.md"}},{"name":"ReauthenticateFailureFirebase","qualifiedName":"wyatt_authentication_bloc.ReauthenticateFailureFirebase","href":"wyatt_authentication_bloc/ReauthenticateFailureFirebase-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the reauthentication process if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"ReauthenticateFailureFirebase","qualifiedName":"wyatt_authentication_bloc.ReauthenticateFailureFirebase.ReauthenticateFailureFirebase","href":"wyatt_authentication_bloc/ReauthenticateFailureFirebase/ReauthenticateFailureFirebase.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"ReauthenticateFailureFirebase","type":"class","href":"wyatt_authentication_bloc/ReauthenticateFailureFirebase-class.md"}},{"name":"ReauthenticateFailureFirebase.fromCode","qualifiedName":"wyatt_authentication_bloc.ReauthenticateFailureFirebase.fromCode","href":"wyatt_authentication_bloc/ReauthenticateFailureFirebase/ReauthenticateFailureFirebase.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"ReauthenticateFailureFirebase","type":"class","href":"wyatt_authentication_bloc/ReauthenticateFailureFirebase-class.md"}},{"name":"ReauthenticateFailureInterface","qualifiedName":"wyatt_authentication_bloc.ReauthenticateFailureInterface","href":"wyatt_authentication_bloc/ReauthenticateFailureInterface-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the reauthentication process if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"ReauthenticateFailureInterface","qualifiedName":"wyatt_authentication_bloc.ReauthenticateFailureInterface.ReauthenticateFailureInterface","href":"wyatt_authentication_bloc/ReauthenticateFailureInterface/ReauthenticateFailureInterface.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"ReauthenticateFailureInterface","type":"class","href":"wyatt_authentication_bloc/ReauthenticateFailureInterface-class.md"}},{"name":"ReauthenticateFailureInterface.fromCode","qualifiedName":"wyatt_authentication_bloc.ReauthenticateFailureInterface.fromCode","href":"wyatt_authentication_bloc/ReauthenticateFailureInterface/ReauthenticateFailureInterface.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"ReauthenticateFailureInterface","type":"class","href":"wyatt_authentication_bloc/ReauthenticateFailureInterface-class.md"}},{"name":"ReauthenticatedEvent","qualifiedName":"wyatt_authentication_bloc.ReauthenticatedEvent","href":"wyatt_authentication_bloc/ReauthenticatedEvent-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"When a user re-authenticates (from the logged in state to the \nlogged in state with a different and fresh access \ntoken and a different login time)","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"ReauthenticatedEvent","qualifiedName":"wyatt_authentication_bloc.ReauthenticatedEvent.ReauthenticatedEvent","href":"wyatt_authentication_bloc/ReauthenticatedEvent/ReauthenticatedEvent.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"ReauthenticatedEvent","type":"class","href":"wyatt_authentication_bloc/ReauthenticatedEvent-class.md"}},{"name":"account","qualifiedName":"wyatt_authentication_bloc.ReauthenticatedEvent.account","href":"wyatt_authentication_bloc/ReauthenticatedEvent/account.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"ReauthenticatedEvent","type":"class","href":"wyatt_authentication_bloc/ReauthenticatedEvent-class.md"}},{"name":"props","qualifiedName":"wyatt_authentication_bloc.ReauthenticatedEvent.props","href":"wyatt_authentication_bloc/ReauthenticatedEvent/props.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"The list of properties that will be used to determine whether\ntwo instances are equal.","enclosedBy":{"name":"ReauthenticatedEvent","type":"class","href":"wyatt_authentication_bloc/ReauthenticatedEvent-class.md"}},{"name":"RefreshFailureFirebase","qualifiedName":"wyatt_authentication_bloc.RefreshFailureFirebase","href":"wyatt_authentication_bloc/RefreshFailureFirebase-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the refresh process if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"RefreshFailureFirebase","qualifiedName":"wyatt_authentication_bloc.RefreshFailureFirebase.RefreshFailureFirebase","href":"wyatt_authentication_bloc/RefreshFailureFirebase/RefreshFailureFirebase.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"RefreshFailureFirebase","type":"class","href":"wyatt_authentication_bloc/RefreshFailureFirebase-class.md"}},{"name":"RefreshFailureFirebase.fromCode","qualifiedName":"wyatt_authentication_bloc.RefreshFailureFirebase.fromCode","href":"wyatt_authentication_bloc/RefreshFailureFirebase/RefreshFailureFirebase.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"RefreshFailureFirebase","type":"class","href":"wyatt_authentication_bloc/RefreshFailureFirebase-class.md"}},{"name":"RefreshFailureInterface","qualifiedName":"wyatt_authentication_bloc.RefreshFailureInterface","href":"wyatt_authentication_bloc/RefreshFailureInterface-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the refresh process if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"RefreshFailureInterface","qualifiedName":"wyatt_authentication_bloc.RefreshFailureInterface.RefreshFailureInterface","href":"wyatt_authentication_bloc/RefreshFailureInterface/RefreshFailureInterface.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the refresh process if a failure occurs.","enclosedBy":{"name":"RefreshFailureInterface","type":"class","href":"wyatt_authentication_bloc/RefreshFailureInterface-class.md"}},{"name":"RefreshFailureInterface.fromCode","qualifiedName":"wyatt_authentication_bloc.RefreshFailureInterface.fromCode","href":"wyatt_authentication_bloc/RefreshFailureInterface/RefreshFailureInterface.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the refresh process if a failure occurs.","enclosedBy":{"name":"RefreshFailureInterface","type":"class","href":"wyatt_authentication_bloc/RefreshFailureInterface-class.md"}},{"name":"RefreshedEvent","qualifiedName":"wyatt_authentication_bloc.RefreshedEvent","href":"wyatt_authentication_bloc/RefreshedEvent-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"When a user access token is refreshed (from the logged in state to the \nlogged in state with a different access token)","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"RefreshedEvent","qualifiedName":"wyatt_authentication_bloc.RefreshedEvent.RefreshedEvent","href":"wyatt_authentication_bloc/RefreshedEvent/RefreshedEvent.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"RefreshedEvent","type":"class","href":"wyatt_authentication_bloc/RefreshedEvent-class.md"}},{"name":"account","qualifiedName":"wyatt_authentication_bloc.RefreshedEvent.account","href":"wyatt_authentication_bloc/RefreshedEvent/account.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"RefreshedEvent","type":"class","href":"wyatt_authentication_bloc/RefreshedEvent-class.md"}},{"name":"props","qualifiedName":"wyatt_authentication_bloc.RefreshedEvent.props","href":"wyatt_authentication_bloc/RefreshedEvent/props.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"The list of properties that will be used to determine whether\ntwo instances are equal.","enclosedBy":{"name":"RefreshedEvent","type":"class","href":"wyatt_authentication_bloc/RefreshedEvent-class.md"}},{"name":"SendEmailVerificationFailureFirebase","qualifiedName":"wyatt_authentication_bloc.SendEmailVerificationFailureFirebase","href":"wyatt_authentication_bloc/SendEmailVerificationFailureFirebase-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the email verification process if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"SendEmailVerificationFailureFirebase","qualifiedName":"wyatt_authentication_bloc.SendEmailVerificationFailureFirebase.SendEmailVerificationFailureFirebase","href":"wyatt_authentication_bloc/SendEmailVerificationFailureFirebase/SendEmailVerificationFailureFirebase.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SendEmailVerificationFailureFirebase","type":"class","href":"wyatt_authentication_bloc/SendEmailVerificationFailureFirebase-class.md"}},{"name":"SendEmailVerificationFailureFirebase.fromCode","qualifiedName":"wyatt_authentication_bloc.SendEmailVerificationFailureFirebase.fromCode","href":"wyatt_authentication_bloc/SendEmailVerificationFailureFirebase/SendEmailVerificationFailureFirebase.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SendEmailVerificationFailureFirebase","type":"class","href":"wyatt_authentication_bloc/SendEmailVerificationFailureFirebase-class.md"}},{"name":"SendEmailVerificationFailureInterface","qualifiedName":"wyatt_authentication_bloc.SendEmailVerificationFailureInterface","href":"wyatt_authentication_bloc/SendEmailVerificationFailureInterface-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the email verification process if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"SendEmailVerificationFailureInterface","qualifiedName":"wyatt_authentication_bloc.SendEmailVerificationFailureInterface.SendEmailVerificationFailureInterface","href":"wyatt_authentication_bloc/SendEmailVerificationFailureInterface/SendEmailVerificationFailureInterface.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the email verification process if a failure occurs.","enclosedBy":{"name":"SendEmailVerificationFailureInterface","type":"class","href":"wyatt_authentication_bloc/SendEmailVerificationFailureInterface-class.md"}},{"name":"SendEmailVerificationFailureInterface.fromCode","qualifiedName":"wyatt_authentication_bloc.SendEmailVerificationFailureInterface.fromCode","href":"wyatt_authentication_bloc/SendEmailVerificationFailureInterface/SendEmailVerificationFailureInterface.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the email verification process if a failure occurs.","enclosedBy":{"name":"SendEmailVerificationFailureInterface","type":"class","href":"wyatt_authentication_bloc/SendEmailVerificationFailureInterface-class.md"}},{"name":"SendPasswordResetEmailFailureFirebase","qualifiedName":"wyatt_authentication_bloc.SendPasswordResetEmailFailureFirebase","href":"wyatt_authentication_bloc/SendPasswordResetEmailFailureFirebase-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the password reset process if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"SendPasswordResetEmailFailureFirebase","qualifiedName":"wyatt_authentication_bloc.SendPasswordResetEmailFailureFirebase.SendPasswordResetEmailFailureFirebase","href":"wyatt_authentication_bloc/SendPasswordResetEmailFailureFirebase/SendPasswordResetEmailFailureFirebase.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SendPasswordResetEmailFailureFirebase","type":"class","href":"wyatt_authentication_bloc/SendPasswordResetEmailFailureFirebase-class.md"}},{"name":"SendPasswordResetEmailFailureFirebase.fromCode","qualifiedName":"wyatt_authentication_bloc.SendPasswordResetEmailFailureFirebase.fromCode","href":"wyatt_authentication_bloc/SendPasswordResetEmailFailureFirebase/SendPasswordResetEmailFailureFirebase.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SendPasswordResetEmailFailureFirebase","type":"class","href":"wyatt_authentication_bloc/SendPasswordResetEmailFailureFirebase-class.md"}},{"name":"SendPasswordResetEmailFailureInterface","qualifiedName":"wyatt_authentication_bloc.SendPasswordResetEmailFailureInterface","href":"wyatt_authentication_bloc/SendPasswordResetEmailFailureInterface-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the password reset process if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"SendPasswordResetEmailFailureInterface","qualifiedName":"wyatt_authentication_bloc.SendPasswordResetEmailFailureInterface.SendPasswordResetEmailFailureInterface","href":"wyatt_authentication_bloc/SendPasswordResetEmailFailureInterface/SendPasswordResetEmailFailureInterface.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the password reset process if a failure occurs.","enclosedBy":{"name":"SendPasswordResetEmailFailureInterface","type":"class","href":"wyatt_authentication_bloc/SendPasswordResetEmailFailureInterface-class.md"}},{"name":"SendPasswordResetEmailFailureInterface.fromCode","qualifiedName":"wyatt_authentication_bloc.SendPasswordResetEmailFailureInterface.fromCode","href":"wyatt_authentication_bloc/SendPasswordResetEmailFailureInterface/SendPasswordResetEmailFailureInterface.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the password reset process if a failure occurs.","enclosedBy":{"name":"SendPasswordResetEmailFailureInterface","type":"class","href":"wyatt_authentication_bloc/SendPasswordResetEmailFailureInterface-class.md"}},{"name":"SendSignInLinkEmailFailureFirebase","qualifiedName":"wyatt_authentication_bloc.SendSignInLinkEmailFailureFirebase","href":"wyatt_authentication_bloc/SendSignInLinkEmailFailureFirebase-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the sign in link process if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"SendSignInLinkEmailFailureFirebase","qualifiedName":"wyatt_authentication_bloc.SendSignInLinkEmailFailureFirebase.SendSignInLinkEmailFailureFirebase","href":"wyatt_authentication_bloc/SendSignInLinkEmailFailureFirebase/SendSignInLinkEmailFailureFirebase.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SendSignInLinkEmailFailureFirebase","type":"class","href":"wyatt_authentication_bloc/SendSignInLinkEmailFailureFirebase-class.md"}},{"name":"SendSignInLinkEmailFailureFirebase.fromCode","qualifiedName":"wyatt_authentication_bloc.SendSignInLinkEmailFailureFirebase.fromCode","href":"wyatt_authentication_bloc/SendSignInLinkEmailFailureFirebase/SendSignInLinkEmailFailureFirebase.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SendSignInLinkEmailFailureFirebase","type":"class","href":"wyatt_authentication_bloc/SendSignInLinkEmailFailureFirebase-class.md"}},{"name":"SendSignInLinkEmailFailureInterface","qualifiedName":"wyatt_authentication_bloc.SendSignInLinkEmailFailureInterface","href":"wyatt_authentication_bloc/SendSignInLinkEmailFailureInterface-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the sign in link process if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"SendSignInLinkEmailFailureInterface","qualifiedName":"wyatt_authentication_bloc.SendSignInLinkEmailFailureInterface.SendSignInLinkEmailFailureInterface","href":"wyatt_authentication_bloc/SendSignInLinkEmailFailureInterface/SendSignInLinkEmailFailureInterface.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the sign in link process if a failure occurs.","enclosedBy":{"name":"SendSignInLinkEmailFailureInterface","type":"class","href":"wyatt_authentication_bloc/SendSignInLinkEmailFailureInterface-class.md"}},{"name":"SendSignInLinkEmailFailureInterface.fromCode","qualifiedName":"wyatt_authentication_bloc.SendSignInLinkEmailFailureInterface.fromCode","href":"wyatt_authentication_bloc/SendSignInLinkEmailFailureInterface/SendSignInLinkEmailFailureInterface.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the sign in link process if a failure occurs.","enclosedBy":{"name":"SendSignInLinkEmailFailureInterface","type":"class","href":"wyatt_authentication_bloc/SendSignInLinkEmailFailureInterface-class.md"}},{"name":"Session","qualifiedName":"wyatt_authentication_bloc.Session","href":"wyatt_authentication_bloc/Session-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"The Session object is used to transport and propagate\nthe connected user Account and personalized Data in the application.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"Session","qualifiedName":"wyatt_authentication_bloc.Session.Session","href":"wyatt_authentication_bloc/Session/Session.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"Session","type":"class","href":"wyatt_authentication_bloc/Session-class.md"}},{"name":"account","qualifiedName":"wyatt_authentication_bloc.Session.account","href":"wyatt_authentication_bloc/Session/account.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"Session","type":"class","href":"wyatt_authentication_bloc/Session-class.md"}},{"name":"data","qualifiedName":"wyatt_authentication_bloc.Session.data","href":"wyatt_authentication_bloc/Session/data.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"Session","type":"class","href":"wyatt_authentication_bloc/Session-class.md"}},{"name":"props","qualifiedName":"wyatt_authentication_bloc.Session.props","href":"wyatt_authentication_bloc/Session/props.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"The list of properties that will be used to determine whether\ntwo instances are equal.","enclosedBy":{"name":"Session","type":"class","href":"wyatt_authentication_bloc/Session-class.md"}},{"name":"stringify","qualifiedName":"wyatt_authentication_bloc.Session.stringify","href":"wyatt_authentication_bloc/Session/stringify.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"If set to true, the toString method will be overridden to output\nthis instance's props.","enclosedBy":{"name":"Session","type":"class","href":"wyatt_authentication_bloc/Session-class.md"}},{"name":"SessionWrapper","qualifiedName":"wyatt_authentication_bloc.SessionWrapper","href":"wyatt_authentication_bloc/SessionWrapper-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Contains the AuthenticationChangeEvent initiating the state \nchange and the current Session.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"SessionWrapper","qualifiedName":"wyatt_authentication_bloc.SessionWrapper.SessionWrapper","href":"wyatt_authentication_bloc/SessionWrapper/SessionWrapper.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SessionWrapper","type":"class","href":"wyatt_authentication_bloc/SessionWrapper-class.md"}},{"name":"event","qualifiedName":"wyatt_authentication_bloc.SessionWrapper.event","href":"wyatt_authentication_bloc/SessionWrapper/event.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SessionWrapper","type":"class","href":"wyatt_authentication_bloc/SessionWrapper-class.md"}},{"name":"props","qualifiedName":"wyatt_authentication_bloc.SessionWrapper.props","href":"wyatt_authentication_bloc/SessionWrapper/props.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"The list of properties that will be used to determine whether\ntwo instances are equal.","enclosedBy":{"name":"SessionWrapper","type":"class","href":"wyatt_authentication_bloc/SessionWrapper-class.md"}},{"name":"session","qualifiedName":"wyatt_authentication_bloc.SessionWrapper.session","href":"wyatt_authentication_bloc/SessionWrapper/session.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SessionWrapper","type":"class","href":"wyatt_authentication_bloc/SessionWrapper-class.md"}},{"name":"stringify","qualifiedName":"wyatt_authentication_bloc.SessionWrapper.stringify","href":"wyatt_authentication_bloc/SessionWrapper/stringify.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"If set to true, the toString method will be overridden to output\nthis instance's props.","enclosedBy":{"name":"SessionWrapper","type":"class","href":"wyatt_authentication_bloc/SessionWrapper-class.md"}},{"name":"SignInAnonymously","qualifiedName":"wyatt_authentication_bloc.SignInAnonymously","href":"wyatt_authentication_bloc/SignInAnonymously-mixin.md","type":"mixin","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Sign in mixin.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"onSignInAnonymously","qualifiedName":"wyatt_authentication_bloc.SignInAnonymously.onSignInAnonymously","href":"wyatt_authentication_bloc/SignInAnonymously/onSignInAnonymously.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"This callback is triggered when a user signs in anonymously.","enclosedBy":{"name":"SignInAnonymously","type":"mixin","href":"wyatt_authentication_bloc/SignInAnonymously-mixin.md"}},{"name":"signInAnonymously","qualifiedName":"wyatt_authentication_bloc.SignInAnonymously.signInAnonymously","href":"wyatt_authentication_bloc/SignInAnonymously/signInAnonymously.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Sign in anonymously.","enclosedBy":{"name":"SignInAnonymously","type":"mixin","href":"wyatt_authentication_bloc/SignInAnonymously-mixin.md"}},{"name":"SignInAnonymouslyFailureFirebase","qualifiedName":"wyatt_authentication_bloc.SignInAnonymouslyFailureFirebase","href":"wyatt_authentication_bloc/SignInAnonymouslyFailureFirebase-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the sign in process if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"SignInAnonymouslyFailureFirebase","qualifiedName":"wyatt_authentication_bloc.SignInAnonymouslyFailureFirebase.SignInAnonymouslyFailureFirebase","href":"wyatt_authentication_bloc/SignInAnonymouslyFailureFirebase/SignInAnonymouslyFailureFirebase.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignInAnonymouslyFailureFirebase","type":"class","href":"wyatt_authentication_bloc/SignInAnonymouslyFailureFirebase-class.md"}},{"name":"SignInAnonymouslyFailureFirebase.fromCode","qualifiedName":"wyatt_authentication_bloc.SignInAnonymouslyFailureFirebase.fromCode","href":"wyatt_authentication_bloc/SignInAnonymouslyFailureFirebase/SignInAnonymouslyFailureFirebase.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignInAnonymouslyFailureFirebase","type":"class","href":"wyatt_authentication_bloc/SignInAnonymouslyFailureFirebase-class.md"}},{"name":"SignInAnonymouslyFailureInterface","qualifiedName":"wyatt_authentication_bloc.SignInAnonymouslyFailureInterface","href":"wyatt_authentication_bloc/SignInAnonymouslyFailureInterface-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the sign in process if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"SignInAnonymouslyFailureInterface","qualifiedName":"wyatt_authentication_bloc.SignInAnonymouslyFailureInterface.SignInAnonymouslyFailureInterface","href":"wyatt_authentication_bloc/SignInAnonymouslyFailureInterface/SignInAnonymouslyFailureInterface.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the sign in process if a failure occurs.","enclosedBy":{"name":"SignInAnonymouslyFailureInterface","type":"class","href":"wyatt_authentication_bloc/SignInAnonymouslyFailureInterface-class.md"}},{"name":"SignInAnonymouslyFailureInterface.fromCode","qualifiedName":"wyatt_authentication_bloc.SignInAnonymouslyFailureInterface.fromCode","href":"wyatt_authentication_bloc/SignInAnonymouslyFailureInterface/SignInAnonymouslyFailureInterface.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the sign in process if a failure occurs.","enclosedBy":{"name":"SignInAnonymouslyFailureInterface","type":"class","href":"wyatt_authentication_bloc/SignInAnonymouslyFailureInterface-class.md"}},{"name":"SignInCubit","qualifiedName":"wyatt_authentication_bloc.SignInCubit","href":"wyatt_authentication_bloc/SignInCubit-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Fully featured sign in cubit.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"SignInCubit","qualifiedName":"wyatt_authentication_bloc.SignInCubit.SignInCubit","href":"wyatt_authentication_bloc/SignInCubit/SignInCubit.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignInCubit","type":"class","href":"wyatt_authentication_bloc/SignInCubit-class.md"}},{"name":"onSignInAnonymously","qualifiedName":"wyatt_authentication_bloc.SignInCubit.onSignInAnonymously","href":"wyatt_authentication_bloc/SignInCubit/onSignInAnonymously.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"This callback is triggered when a user signs in anonymously.","enclosedBy":{"name":"SignInCubit","type":"class","href":"wyatt_authentication_bloc/SignInCubit-class.md"}},{"name":"onSignInWithEmailAndPassword","qualifiedName":"wyatt_authentication_bloc.SignInCubit.onSignInWithEmailAndPassword","href":"wyatt_authentication_bloc/SignInCubit/onSignInWithEmailAndPassword.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"This callback is triggered when a user signs in with email and password.","enclosedBy":{"name":"SignInCubit","type":"class","href":"wyatt_authentication_bloc/SignInCubit-class.md"}},{"name":"onSignInWithGoogle","qualifiedName":"wyatt_authentication_bloc.SignInCubit.onSignInWithGoogle","href":"wyatt_authentication_bloc/SignInCubit/onSignInWithGoogle.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"This callback is triggered when a user signs in with google.","enclosedBy":{"name":"SignInCubit","type":"class","href":"wyatt_authentication_bloc/SignInCubit-class.md"}},{"name":"SignInListener","qualifiedName":"wyatt_authentication_bloc.SignInListener","href":"wyatt_authentication_bloc/SignInListener-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Widget that listens and builds a child based on the state of \nthe sign in cubit","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"SignInListener","qualifiedName":"wyatt_authentication_bloc.SignInListener.SignInListener","href":"wyatt_authentication_bloc/SignInListener/SignInListener.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignInListener","type":"class","href":"wyatt_authentication_bloc/SignInListener-class.md"}},{"name":"build","qualifiedName":"wyatt_authentication_bloc.SignInListener.build","href":"wyatt_authentication_bloc/SignInListener/build.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"Describes the part of the user interface represented by this widget.","enclosedBy":{"name":"SignInListener","type":"class","href":"wyatt_authentication_bloc/SignInListener-class.md"}},{"name":"child","qualifiedName":"wyatt_authentication_bloc.SignInListener.child","href":"wyatt_authentication_bloc/SignInListener/child.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignInListener","type":"class","href":"wyatt_authentication_bloc/SignInListener-class.md"}},{"name":"customBuilder","qualifiedName":"wyatt_authentication_bloc.SignInListener.customBuilder","href":"wyatt_authentication_bloc/SignInListener/customBuilder.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignInListener","type":"class","href":"wyatt_authentication_bloc/SignInListener-class.md"}},{"name":"onError","qualifiedName":"wyatt_authentication_bloc.SignInListener.onError","href":"wyatt_authentication_bloc/SignInListener/onError.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignInListener","type":"class","href":"wyatt_authentication_bloc/SignInListener-class.md"}},{"name":"onProgress","qualifiedName":"wyatt_authentication_bloc.SignInListener.onProgress","href":"wyatt_authentication_bloc/SignInListener/onProgress.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignInListener","type":"class","href":"wyatt_authentication_bloc/SignInListener-class.md"}},{"name":"onSuccess","qualifiedName":"wyatt_authentication_bloc.SignInListener.onSuccess","href":"wyatt_authentication_bloc/SignInListener/onSuccess.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignInListener","type":"class","href":"wyatt_authentication_bloc/SignInListener-class.md"}},{"name":"SignInState","qualifiedName":"wyatt_authentication_bloc.SignInState","href":"wyatt_authentication_bloc/SignInState-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Sign in cubit state to manage the form.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"SignInState","qualifiedName":"wyatt_authentication_bloc.SignInState.SignInState","href":"wyatt_authentication_bloc/SignInState/SignInState.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignInState","type":"class","href":"wyatt_authentication_bloc/SignInState-class.md"}},{"name":"copyWith","qualifiedName":"wyatt_authentication_bloc.SignInState.copyWith","href":"wyatt_authentication_bloc/SignInState/copyWith.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignInState","type":"class","href":"wyatt_authentication_bloc/SignInState-class.md"}},{"name":"email","qualifiedName":"wyatt_authentication_bloc.SignInState.email","href":"wyatt_authentication_bloc/SignInState/email.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignInState","type":"class","href":"wyatt_authentication_bloc/SignInState-class.md"}},{"name":"errorMessage","qualifiedName":"wyatt_authentication_bloc.SignInState.errorMessage","href":"wyatt_authentication_bloc/SignInState/errorMessage.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Optional error message.","enclosedBy":{"name":"SignInState","type":"class","href":"wyatt_authentication_bloc/SignInState-class.md"}},{"name":"form","qualifiedName":"wyatt_authentication_bloc.SignInState.form","href":"wyatt_authentication_bloc/SignInState/form.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"FormData with all inputs, and associated metadata.","enclosedBy":{"name":"SignInState","type":"class","href":"wyatt_authentication_bloc/SignInState-class.md"}},{"name":"password","qualifiedName":"wyatt_authentication_bloc.SignInState.password","href":"wyatt_authentication_bloc/SignInState/password.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignInState","type":"class","href":"wyatt_authentication_bloc/SignInState-class.md"}},{"name":"props","qualifiedName":"wyatt_authentication_bloc.SignInState.props","href":"wyatt_authentication_bloc/SignInState/props.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"The list of properties that will be used to determine whether\ntwo instances are equal.","enclosedBy":{"name":"SignInState","type":"class","href":"wyatt_authentication_bloc/SignInState-class.md"}},{"name":"status","qualifiedName":"wyatt_authentication_bloc.SignInState.status","href":"wyatt_authentication_bloc/SignInState/status.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Global status of a form.","enclosedBy":{"name":"SignInState","type":"class","href":"wyatt_authentication_bloc/SignInState-class.md"}},{"name":"toString","qualifiedName":"wyatt_authentication_bloc.SignInState.toString","href":"wyatt_authentication_bloc/SignInState/toString.md","type":"method","overriddenDepth":2,"packageName":"wyatt_authentication_bloc","desc":"A string representation of this object.","enclosedBy":{"name":"SignInState","type":"class","href":"wyatt_authentication_bloc/SignInState-class.md"}},{"name":"SignInWithAppleFailureFirebase","qualifiedName":"wyatt_authentication_bloc.SignInWithAppleFailureFirebase","href":"wyatt_authentication_bloc/SignInWithAppleFailureFirebase-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the sign in process if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"SignInWithAppleFailureFirebase","qualifiedName":"wyatt_authentication_bloc.SignInWithAppleFailureFirebase.SignInWithAppleFailureFirebase","href":"wyatt_authentication_bloc/SignInWithAppleFailureFirebase/SignInWithAppleFailureFirebase.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignInWithAppleFailureFirebase","type":"class","href":"wyatt_authentication_bloc/SignInWithAppleFailureFirebase-class.md"}},{"name":"SignInWithAppleFailureFirebase.fromCode","qualifiedName":"wyatt_authentication_bloc.SignInWithAppleFailureFirebase.fromCode","href":"wyatt_authentication_bloc/SignInWithAppleFailureFirebase/SignInWithAppleFailureFirebase.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignInWithAppleFailureFirebase","type":"class","href":"wyatt_authentication_bloc/SignInWithAppleFailureFirebase-class.md"}},{"name":"SignInWithAppleFailureInterface","qualifiedName":"wyatt_authentication_bloc.SignInWithAppleFailureInterface","href":"wyatt_authentication_bloc/SignInWithAppleFailureInterface-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the sign in process if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"SignInWithAppleFailureInterface","qualifiedName":"wyatt_authentication_bloc.SignInWithAppleFailureInterface.SignInWithAppleFailureInterface","href":"wyatt_authentication_bloc/SignInWithAppleFailureInterface/SignInWithAppleFailureInterface.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the sign in process if a failure occurs.","enclosedBy":{"name":"SignInWithAppleFailureInterface","type":"class","href":"wyatt_authentication_bloc/SignInWithAppleFailureInterface-class.md"}},{"name":"SignInWithAppleFailureInterface.fromCode","qualifiedName":"wyatt_authentication_bloc.SignInWithAppleFailureInterface.fromCode","href":"wyatt_authentication_bloc/SignInWithAppleFailureInterface/SignInWithAppleFailureInterface.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the sign in process if a failure occurs.","enclosedBy":{"name":"SignInWithAppleFailureInterface","type":"class","href":"wyatt_authentication_bloc/SignInWithAppleFailureInterface-class.md"}},{"name":"SignInWithCredentialFailureFirebase","qualifiedName":"wyatt_authentication_bloc.SignInWithCredentialFailureFirebase","href":"wyatt_authentication_bloc/SignInWithCredentialFailureFirebase-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the sign in process if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"SignInWithCredentialFailureFirebase","qualifiedName":"wyatt_authentication_bloc.SignInWithCredentialFailureFirebase.SignInWithCredentialFailureFirebase","href":"wyatt_authentication_bloc/SignInWithCredentialFailureFirebase/SignInWithCredentialFailureFirebase.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignInWithCredentialFailureFirebase","type":"class","href":"wyatt_authentication_bloc/SignInWithCredentialFailureFirebase-class.md"}},{"name":"SignInWithCredentialFailureFirebase.fromCode","qualifiedName":"wyatt_authentication_bloc.SignInWithCredentialFailureFirebase.fromCode","href":"wyatt_authentication_bloc/SignInWithCredentialFailureFirebase/SignInWithCredentialFailureFirebase.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignInWithCredentialFailureFirebase","type":"class","href":"wyatt_authentication_bloc/SignInWithCredentialFailureFirebase-class.md"}},{"name":"SignInWithCredentialFailureInterface","qualifiedName":"wyatt_authentication_bloc.SignInWithCredentialFailureInterface","href":"wyatt_authentication_bloc/SignInWithCredentialFailureInterface-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the sign in process if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"SignInWithCredentialFailureInterface","qualifiedName":"wyatt_authentication_bloc.SignInWithCredentialFailureInterface.SignInWithCredentialFailureInterface","href":"wyatt_authentication_bloc/SignInWithCredentialFailureInterface/SignInWithCredentialFailureInterface.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the sign in process if a failure occurs.","enclosedBy":{"name":"SignInWithCredentialFailureInterface","type":"class","href":"wyatt_authentication_bloc/SignInWithCredentialFailureInterface-class.md"}},{"name":"SignInWithCredentialFailureInterface.fromCode","qualifiedName":"wyatt_authentication_bloc.SignInWithCredentialFailureInterface.fromCode","href":"wyatt_authentication_bloc/SignInWithCredentialFailureInterface/SignInWithCredentialFailureInterface.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the sign in process if a failure occurs.","enclosedBy":{"name":"SignInWithCredentialFailureInterface","type":"class","href":"wyatt_authentication_bloc/SignInWithCredentialFailureInterface-class.md"}},{"name":"SignInWithEmailAndPasswordFailureFirebase","qualifiedName":"wyatt_authentication_bloc.SignInWithEmailAndPasswordFailureFirebase","href":"wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureFirebase-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the sign in process if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"SignInWithEmailAndPasswordFailureFirebase","qualifiedName":"wyatt_authentication_bloc.SignInWithEmailAndPasswordFailureFirebase.SignInWithEmailAndPasswordFailureFirebase","href":"wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureFirebase/SignInWithEmailAndPasswordFailureFirebase.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignInWithEmailAndPasswordFailureFirebase","type":"class","href":"wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureFirebase-class.md"}},{"name":"SignInWithEmailAndPasswordFailureFirebase.fromCode","qualifiedName":"wyatt_authentication_bloc.SignInWithEmailAndPasswordFailureFirebase.fromCode","href":"wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureFirebase/SignInWithEmailAndPasswordFailureFirebase.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignInWithEmailAndPasswordFailureFirebase","type":"class","href":"wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureFirebase-class.md"}},{"name":"SignInWithEmailAndPasswordFailureInterface","qualifiedName":"wyatt_authentication_bloc.SignInWithEmailAndPasswordFailureInterface","href":"wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureInterface-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the sign in process if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"SignInWithEmailAndPasswordFailureInterface","qualifiedName":"wyatt_authentication_bloc.SignInWithEmailAndPasswordFailureInterface.SignInWithEmailAndPasswordFailureInterface","href":"wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureInterface/SignInWithEmailAndPasswordFailureInterface.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the sign in process if a failure occurs.","enclosedBy":{"name":"SignInWithEmailAndPasswordFailureInterface","type":"class","href":"wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureInterface-class.md"}},{"name":"SignInWithEmailAndPasswordFailureInterface.fromCode","qualifiedName":"wyatt_authentication_bloc.SignInWithEmailAndPasswordFailureInterface.fromCode","href":"wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureInterface/SignInWithEmailAndPasswordFailureInterface.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the sign in process if a failure occurs.","enclosedBy":{"name":"SignInWithEmailAndPasswordFailureInterface","type":"class","href":"wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureInterface-class.md"}},{"name":"SignInWithEmailLinkFailureFirebase","qualifiedName":"wyatt_authentication_bloc.SignInWithEmailLinkFailureFirebase","href":"wyatt_authentication_bloc/SignInWithEmailLinkFailureFirebase-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the sign in process if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"SignInWithEmailLinkFailureFirebase","qualifiedName":"wyatt_authentication_bloc.SignInWithEmailLinkFailureFirebase.SignInWithEmailLinkFailureFirebase","href":"wyatt_authentication_bloc/SignInWithEmailLinkFailureFirebase/SignInWithEmailLinkFailureFirebase.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignInWithEmailLinkFailureFirebase","type":"class","href":"wyatt_authentication_bloc/SignInWithEmailLinkFailureFirebase-class.md"}},{"name":"SignInWithEmailLinkFailureFirebase.fromCode","qualifiedName":"wyatt_authentication_bloc.SignInWithEmailLinkFailureFirebase.fromCode","href":"wyatt_authentication_bloc/SignInWithEmailLinkFailureFirebase/SignInWithEmailLinkFailureFirebase.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignInWithEmailLinkFailureFirebase","type":"class","href":"wyatt_authentication_bloc/SignInWithEmailLinkFailureFirebase-class.md"}},{"name":"SignInWithEmailLinkFailureInterface","qualifiedName":"wyatt_authentication_bloc.SignInWithEmailLinkFailureInterface","href":"wyatt_authentication_bloc/SignInWithEmailLinkFailureInterface-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the sign in process if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"SignInWithEmailLinkFailureInterface","qualifiedName":"wyatt_authentication_bloc.SignInWithEmailLinkFailureInterface.SignInWithEmailLinkFailureInterface","href":"wyatt_authentication_bloc/SignInWithEmailLinkFailureInterface/SignInWithEmailLinkFailureInterface.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the sign in process if a failure occurs.","enclosedBy":{"name":"SignInWithEmailLinkFailureInterface","type":"class","href":"wyatt_authentication_bloc/SignInWithEmailLinkFailureInterface-class.md"}},{"name":"SignInWithEmailLinkFailureInterface.fromCode","qualifiedName":"wyatt_authentication_bloc.SignInWithEmailLinkFailureInterface.fromCode","href":"wyatt_authentication_bloc/SignInWithEmailLinkFailureInterface/SignInWithEmailLinkFailureInterface.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the sign in process if a failure occurs.","enclosedBy":{"name":"SignInWithEmailLinkFailureInterface","type":"class","href":"wyatt_authentication_bloc/SignInWithEmailLinkFailureInterface-class.md"}},{"name":"SignInWithEmailPassword","qualifiedName":"wyatt_authentication_bloc.SignInWithEmailPassword","href":"wyatt_authentication_bloc/SignInWithEmailPassword-mixin.md","type":"mixin","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Sign in mixin.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"emailChanged","qualifiedName":"wyatt_authentication_bloc.SignInWithEmailPassword.emailChanged","href":"wyatt_authentication_bloc/SignInWithEmailPassword/emailChanged.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignInWithEmailPassword","type":"mixin","href":"wyatt_authentication_bloc/SignInWithEmailPassword-mixin.md"}},{"name":"emailCustomChanged","qualifiedName":"wyatt_authentication_bloc.SignInWithEmailPassword.emailCustomChanged","href":"wyatt_authentication_bloc/SignInWithEmailPassword/emailCustomChanged.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Same as emailChanged but with a custom Validator.","enclosedBy":{"name":"SignInWithEmailPassword","type":"mixin","href":"wyatt_authentication_bloc/SignInWithEmailPassword-mixin.md"}},{"name":"onSignInWithEmailAndPassword","qualifiedName":"wyatt_authentication_bloc.SignInWithEmailPassword.onSignInWithEmailAndPassword","href":"wyatt_authentication_bloc/SignInWithEmailPassword/onSignInWithEmailAndPassword.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"This callback is triggered when a user signs in with email and password.","enclosedBy":{"name":"SignInWithEmailPassword","type":"mixin","href":"wyatt_authentication_bloc/SignInWithEmailPassword-mixin.md"}},{"name":"passwordChanged","qualifiedName":"wyatt_authentication_bloc.SignInWithEmailPassword.passwordChanged","href":"wyatt_authentication_bloc/SignInWithEmailPassword/passwordChanged.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignInWithEmailPassword","type":"mixin","href":"wyatt_authentication_bloc/SignInWithEmailPassword-mixin.md"}},{"name":"passwordCustomChanged","qualifiedName":"wyatt_authentication_bloc.SignInWithEmailPassword.passwordCustomChanged","href":"wyatt_authentication_bloc/SignInWithEmailPassword/passwordCustomChanged.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Same as passwordChanged but with a custom Validator.","enclosedBy":{"name":"SignInWithEmailPassword","type":"mixin","href":"wyatt_authentication_bloc/SignInWithEmailPassword-mixin.md"}},{"name":"signInWithEmailAndPassword","qualifiedName":"wyatt_authentication_bloc.SignInWithEmailPassword.signInWithEmailAndPassword","href":"wyatt_authentication_bloc/SignInWithEmailPassword/signInWithEmailAndPassword.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Signs in with the provided email and password.","enclosedBy":{"name":"SignInWithEmailPassword","type":"mixin","href":"wyatt_authentication_bloc/SignInWithEmailPassword-mixin.md"}},{"name":"SignInWithFacebookFailureFirebase","qualifiedName":"wyatt_authentication_bloc.SignInWithFacebookFailureFirebase","href":"wyatt_authentication_bloc/SignInWithFacebookFailureFirebase-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the sign in process if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"SignInWithFacebookFailureFirebase","qualifiedName":"wyatt_authentication_bloc.SignInWithFacebookFailureFirebase.SignInWithFacebookFailureFirebase","href":"wyatt_authentication_bloc/SignInWithFacebookFailureFirebase/SignInWithFacebookFailureFirebase.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignInWithFacebookFailureFirebase","type":"class","href":"wyatt_authentication_bloc/SignInWithFacebookFailureFirebase-class.md"}},{"name":"SignInWithFacebookFailureFirebase.fromCode","qualifiedName":"wyatt_authentication_bloc.SignInWithFacebookFailureFirebase.fromCode","href":"wyatt_authentication_bloc/SignInWithFacebookFailureFirebase/SignInWithFacebookFailureFirebase.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignInWithFacebookFailureFirebase","type":"class","href":"wyatt_authentication_bloc/SignInWithFacebookFailureFirebase-class.md"}},{"name":"SignInWithFacebookFailureInterface","qualifiedName":"wyatt_authentication_bloc.SignInWithFacebookFailureInterface","href":"wyatt_authentication_bloc/SignInWithFacebookFailureInterface-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the sign in process if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"SignInWithFacebookFailureInterface","qualifiedName":"wyatt_authentication_bloc.SignInWithFacebookFailureInterface.SignInWithFacebookFailureInterface","href":"wyatt_authentication_bloc/SignInWithFacebookFailureInterface/SignInWithFacebookFailureInterface.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the sign in process if a failure occurs.","enclosedBy":{"name":"SignInWithFacebookFailureInterface","type":"class","href":"wyatt_authentication_bloc/SignInWithFacebookFailureInterface-class.md"}},{"name":"SignInWithFacebookFailureInterface.fromCode","qualifiedName":"wyatt_authentication_bloc.SignInWithFacebookFailureInterface.fromCode","href":"wyatt_authentication_bloc/SignInWithFacebookFailureInterface/SignInWithFacebookFailureInterface.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the sign in process if a failure occurs.","enclosedBy":{"name":"SignInWithFacebookFailureInterface","type":"class","href":"wyatt_authentication_bloc/SignInWithFacebookFailureInterface-class.md"}},{"name":"SignInWithGoogle","qualifiedName":"wyatt_authentication_bloc.SignInWithGoogle","href":"wyatt_authentication_bloc/SignInWithGoogle-mixin.md","type":"mixin","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Sign in mixin.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"onSignInWithGoogle","qualifiedName":"wyatt_authentication_bloc.SignInWithGoogle.onSignInWithGoogle","href":"wyatt_authentication_bloc/SignInWithGoogle/onSignInWithGoogle.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"This callback is triggered when a user signs in with google.","enclosedBy":{"name":"SignInWithGoogle","type":"mixin","href":"wyatt_authentication_bloc/SignInWithGoogle-mixin.md"}},{"name":"signInWithGoogle","qualifiedName":"wyatt_authentication_bloc.SignInWithGoogle.signInWithGoogle","href":"wyatt_authentication_bloc/SignInWithGoogle/signInWithGoogle.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Starts the Sign In with Google Flow.","enclosedBy":{"name":"SignInWithGoogle","type":"mixin","href":"wyatt_authentication_bloc/SignInWithGoogle-mixin.md"}},{"name":"SignInWithGoogleFailureFirebase","qualifiedName":"wyatt_authentication_bloc.SignInWithGoogleFailureFirebase","href":"wyatt_authentication_bloc/SignInWithGoogleFailureFirebase-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the sign in process if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"SignInWithGoogleFailureFirebase","qualifiedName":"wyatt_authentication_bloc.SignInWithGoogleFailureFirebase.SignInWithGoogleFailureFirebase","href":"wyatt_authentication_bloc/SignInWithGoogleFailureFirebase/SignInWithGoogleFailureFirebase.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignInWithGoogleFailureFirebase","type":"class","href":"wyatt_authentication_bloc/SignInWithGoogleFailureFirebase-class.md"}},{"name":"SignInWithGoogleFailureFirebase.fromCode","qualifiedName":"wyatt_authentication_bloc.SignInWithGoogleFailureFirebase.fromCode","href":"wyatt_authentication_bloc/SignInWithGoogleFailureFirebase/SignInWithGoogleFailureFirebase.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignInWithGoogleFailureFirebase","type":"class","href":"wyatt_authentication_bloc/SignInWithGoogleFailureFirebase-class.md"}},{"name":"SignInWithGoogleFailureInterface","qualifiedName":"wyatt_authentication_bloc.SignInWithGoogleFailureInterface","href":"wyatt_authentication_bloc/SignInWithGoogleFailureInterface-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the sign in process if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"SignInWithGoogleFailureInterface","qualifiedName":"wyatt_authentication_bloc.SignInWithGoogleFailureInterface.SignInWithGoogleFailureInterface","href":"wyatt_authentication_bloc/SignInWithGoogleFailureInterface/SignInWithGoogleFailureInterface.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the sign in process if a failure occurs.","enclosedBy":{"name":"SignInWithGoogleFailureInterface","type":"class","href":"wyatt_authentication_bloc/SignInWithGoogleFailureInterface-class.md"}},{"name":"SignInWithGoogleFailureInterface.fromCode","qualifiedName":"wyatt_authentication_bloc.SignInWithGoogleFailureInterface.fromCode","href":"wyatt_authentication_bloc/SignInWithGoogleFailureInterface/SignInWithGoogleFailureInterface.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the sign in process if a failure occurs.","enclosedBy":{"name":"SignInWithGoogleFailureInterface","type":"class","href":"wyatt_authentication_bloc/SignInWithGoogleFailureInterface-class.md"}},{"name":"SignInWithTwitterFailureFirebase","qualifiedName":"wyatt_authentication_bloc.SignInWithTwitterFailureFirebase","href":"wyatt_authentication_bloc/SignInWithTwitterFailureFirebase-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the sign in process if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"SignInWithTwitterFailureFirebase","qualifiedName":"wyatt_authentication_bloc.SignInWithTwitterFailureFirebase.SignInWithTwitterFailureFirebase","href":"wyatt_authentication_bloc/SignInWithTwitterFailureFirebase/SignInWithTwitterFailureFirebase.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignInWithTwitterFailureFirebase","type":"class","href":"wyatt_authentication_bloc/SignInWithTwitterFailureFirebase-class.md"}},{"name":"SignInWithTwitterFailureFirebase.fromCode","qualifiedName":"wyatt_authentication_bloc.SignInWithTwitterFailureFirebase.fromCode","href":"wyatt_authentication_bloc/SignInWithTwitterFailureFirebase/SignInWithTwitterFailureFirebase.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignInWithTwitterFailureFirebase","type":"class","href":"wyatt_authentication_bloc/SignInWithTwitterFailureFirebase-class.md"}},{"name":"SignInWithTwitterFailureInterface","qualifiedName":"wyatt_authentication_bloc.SignInWithTwitterFailureInterface","href":"wyatt_authentication_bloc/SignInWithTwitterFailureInterface-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the sign in process if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"SignInWithTwitterFailureInterface","qualifiedName":"wyatt_authentication_bloc.SignInWithTwitterFailureInterface.SignInWithTwitterFailureInterface","href":"wyatt_authentication_bloc/SignInWithTwitterFailureInterface/SignInWithTwitterFailureInterface.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the sign in process if a failure occurs.","enclosedBy":{"name":"SignInWithTwitterFailureInterface","type":"class","href":"wyatt_authentication_bloc/SignInWithTwitterFailureInterface-class.md"}},{"name":"SignInWithTwitterFailureInterface.fromCode","qualifiedName":"wyatt_authentication_bloc.SignInWithTwitterFailureInterface.fromCode","href":"wyatt_authentication_bloc/SignInWithTwitterFailureInterface/SignInWithTwitterFailureInterface.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the sign in process if a failure occurs.","enclosedBy":{"name":"SignInWithTwitterFailureInterface","type":"class","href":"wyatt_authentication_bloc/SignInWithTwitterFailureInterface-class.md"}},{"name":"SignOutFailureFirebase","qualifiedName":"wyatt_authentication_bloc.SignOutFailureFirebase","href":"wyatt_authentication_bloc/SignOutFailureFirebase-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the sign out process if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"SignOutFailureFirebase","qualifiedName":"wyatt_authentication_bloc.SignOutFailureFirebase.SignOutFailureFirebase","href":"wyatt_authentication_bloc/SignOutFailureFirebase/SignOutFailureFirebase.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignOutFailureFirebase","type":"class","href":"wyatt_authentication_bloc/SignOutFailureFirebase-class.md"}},{"name":"SignOutFailureFirebase.fromCode","qualifiedName":"wyatt_authentication_bloc.SignOutFailureFirebase.fromCode","href":"wyatt_authentication_bloc/SignOutFailureFirebase/SignOutFailureFirebase.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignOutFailureFirebase","type":"class","href":"wyatt_authentication_bloc/SignOutFailureFirebase-class.md"}},{"name":"SignOutFailureInterface","qualifiedName":"wyatt_authentication_bloc.SignOutFailureInterface","href":"wyatt_authentication_bloc/SignOutFailureInterface-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the sign out process if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"SignOutFailureInterface","qualifiedName":"wyatt_authentication_bloc.SignOutFailureInterface.SignOutFailureInterface","href":"wyatt_authentication_bloc/SignOutFailureInterface/SignOutFailureInterface.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the sign out process if a failure occurs.","enclosedBy":{"name":"SignOutFailureInterface","type":"class","href":"wyatt_authentication_bloc/SignOutFailureInterface-class.md"}},{"name":"SignOutFailureInterface.fromCode","qualifiedName":"wyatt_authentication_bloc.SignOutFailureInterface.fromCode","href":"wyatt_authentication_bloc/SignOutFailureInterface/SignOutFailureInterface.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the sign out process if a failure occurs.","enclosedBy":{"name":"SignOutFailureInterface","type":"class","href":"wyatt_authentication_bloc/SignOutFailureInterface-class.md"}},{"name":"SignUpCubit","qualifiedName":"wyatt_authentication_bloc.SignUpCubit","href":"wyatt_authentication_bloc/SignUpCubit-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Fully featured sign up cubit.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"SignUpCubit","qualifiedName":"wyatt_authentication_bloc.SignUpCubit.SignUpCubit","href":"wyatt_authentication_bloc/SignUpCubit/SignUpCubit.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignUpCubit","type":"class","href":"wyatt_authentication_bloc/SignUpCubit-class.md"}},{"name":"onSignUpWithEmailAndPassword","qualifiedName":"wyatt_authentication_bloc.SignUpCubit.onSignUpWithEmailAndPassword","href":"wyatt_authentication_bloc/SignUpCubit/onSignUpWithEmailAndPassword.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"This callback is triggered when a user creates an account.","enclosedBy":{"name":"SignUpCubit","type":"class","href":"wyatt_authentication_bloc/SignUpCubit-class.md"}},{"name":"SignUpListener","qualifiedName":"wyatt_authentication_bloc.SignUpListener","href":"wyatt_authentication_bloc/SignUpListener-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Widget that listens and builds a child based on the state of \nthe sign up cubit","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"SignUpListener","qualifiedName":"wyatt_authentication_bloc.SignUpListener.SignUpListener","href":"wyatt_authentication_bloc/SignUpListener/SignUpListener.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignUpListener","type":"class","href":"wyatt_authentication_bloc/SignUpListener-class.md"}},{"name":"build","qualifiedName":"wyatt_authentication_bloc.SignUpListener.build","href":"wyatt_authentication_bloc/SignUpListener/build.md","type":"method","overriddenDepth":1,"packageName":"wyatt_authentication_bloc","desc":"Describes the part of the user interface represented by this widget.","enclosedBy":{"name":"SignUpListener","type":"class","href":"wyatt_authentication_bloc/SignUpListener-class.md"}},{"name":"child","qualifiedName":"wyatt_authentication_bloc.SignUpListener.child","href":"wyatt_authentication_bloc/SignUpListener/child.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignUpListener","type":"class","href":"wyatt_authentication_bloc/SignUpListener-class.md"}},{"name":"customBuilder","qualifiedName":"wyatt_authentication_bloc.SignUpListener.customBuilder","href":"wyatt_authentication_bloc/SignUpListener/customBuilder.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignUpListener","type":"class","href":"wyatt_authentication_bloc/SignUpListener-class.md"}},{"name":"onError","qualifiedName":"wyatt_authentication_bloc.SignUpListener.onError","href":"wyatt_authentication_bloc/SignUpListener/onError.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignUpListener","type":"class","href":"wyatt_authentication_bloc/SignUpListener-class.md"}},{"name":"onProgress","qualifiedName":"wyatt_authentication_bloc.SignUpListener.onProgress","href":"wyatt_authentication_bloc/SignUpListener/onProgress.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignUpListener","type":"class","href":"wyatt_authentication_bloc/SignUpListener-class.md"}},{"name":"onSuccess","qualifiedName":"wyatt_authentication_bloc.SignUpListener.onSuccess","href":"wyatt_authentication_bloc/SignUpListener/onSuccess.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignUpListener","type":"class","href":"wyatt_authentication_bloc/SignUpListener-class.md"}},{"name":"SignUpState","qualifiedName":"wyatt_authentication_bloc.SignUpState","href":"wyatt_authentication_bloc/SignUpState-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Sign up cubit state to manage the form.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"SignUpState","qualifiedName":"wyatt_authentication_bloc.SignUpState.SignUpState","href":"wyatt_authentication_bloc/SignUpState/SignUpState.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignUpState","type":"class","href":"wyatt_authentication_bloc/SignUpState-class.md"}},{"name":"copyWith","qualifiedName":"wyatt_authentication_bloc.SignUpState.copyWith","href":"wyatt_authentication_bloc/SignUpState/copyWith.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignUpState","type":"class","href":"wyatt_authentication_bloc/SignUpState-class.md"}},{"name":"email","qualifiedName":"wyatt_authentication_bloc.SignUpState.email","href":"wyatt_authentication_bloc/SignUpState/email.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignUpState","type":"class","href":"wyatt_authentication_bloc/SignUpState-class.md"}},{"name":"errorMessage","qualifiedName":"wyatt_authentication_bloc.SignUpState.errorMessage","href":"wyatt_authentication_bloc/SignUpState/errorMessage.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Optional error message.","enclosedBy":{"name":"SignUpState","type":"class","href":"wyatt_authentication_bloc/SignUpState-class.md"}},{"name":"form","qualifiedName":"wyatt_authentication_bloc.SignUpState.form","href":"wyatt_authentication_bloc/SignUpState/form.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"FormData with all inputs, and associated metadata.","enclosedBy":{"name":"SignUpState","type":"class","href":"wyatt_authentication_bloc/SignUpState-class.md"}},{"name":"password","qualifiedName":"wyatt_authentication_bloc.SignUpState.password","href":"wyatt_authentication_bloc/SignUpState/password.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignUpState","type":"class","href":"wyatt_authentication_bloc/SignUpState-class.md"}},{"name":"props","qualifiedName":"wyatt_authentication_bloc.SignUpState.props","href":"wyatt_authentication_bloc/SignUpState/props.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"The list of properties that will be used to determine whether\ntwo instances are equal.","enclosedBy":{"name":"SignUpState","type":"class","href":"wyatt_authentication_bloc/SignUpState-class.md"}},{"name":"status","qualifiedName":"wyatt_authentication_bloc.SignUpState.status","href":"wyatt_authentication_bloc/SignUpState/status.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Global status of a form.","enclosedBy":{"name":"SignUpState","type":"class","href":"wyatt_authentication_bloc/SignUpState-class.md"}},{"name":"toString","qualifiedName":"wyatt_authentication_bloc.SignUpState.toString","href":"wyatt_authentication_bloc/SignUpState/toString.md","type":"method","overriddenDepth":2,"packageName":"wyatt_authentication_bloc","desc":"A string representation of this object.","enclosedBy":{"name":"SignUpState","type":"class","href":"wyatt_authentication_bloc/SignUpState-class.md"}},{"name":"SignUpWithEmailAndPasswordFailureFirebase","qualifiedName":"wyatt_authentication_bloc.SignUpWithEmailAndPasswordFailureFirebase","href":"wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureFirebase-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown if during the sign up process if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"SignUpWithEmailAndPasswordFailureFirebase","qualifiedName":"wyatt_authentication_bloc.SignUpWithEmailAndPasswordFailureFirebase.SignUpWithEmailAndPasswordFailureFirebase","href":"wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureFirebase/SignUpWithEmailAndPasswordFailureFirebase.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignUpWithEmailAndPasswordFailureFirebase","type":"class","href":"wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureFirebase-class.md"}},{"name":"SignUpWithEmailAndPasswordFailureFirebase.fromCode","qualifiedName":"wyatt_authentication_bloc.SignUpWithEmailAndPasswordFailureFirebase.fromCode","href":"wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureFirebase/SignUpWithEmailAndPasswordFailureFirebase.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignUpWithEmailAndPasswordFailureFirebase","type":"class","href":"wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureFirebase-class.md"}},{"name":"SignUpWithEmailAndPasswordFailureInterface","qualifiedName":"wyatt_authentication_bloc.SignUpWithEmailAndPasswordFailureInterface","href":"wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureInterface-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown if during the sign up process if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"SignUpWithEmailAndPasswordFailureInterface","qualifiedName":"wyatt_authentication_bloc.SignUpWithEmailAndPasswordFailureInterface.SignUpWithEmailAndPasswordFailureInterface","href":"wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureInterface/SignUpWithEmailAndPasswordFailureInterface.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown if during the sign up process if a failure occurs.","enclosedBy":{"name":"SignUpWithEmailAndPasswordFailureInterface","type":"class","href":"wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureInterface-class.md"}},{"name":"SignUpWithEmailAndPasswordFailureInterface.fromCode","qualifiedName":"wyatt_authentication_bloc.SignUpWithEmailAndPasswordFailureInterface.fromCode","href":"wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureInterface/SignUpWithEmailAndPasswordFailureInterface.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown if during the sign up process if a failure occurs.","enclosedBy":{"name":"SignUpWithEmailAndPasswordFailureInterface","type":"class","href":"wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureInterface-class.md"}},{"name":"SignUpWithEmailPassword","qualifiedName":"wyatt_authentication_bloc.SignUpWithEmailPassword","href":"wyatt_authentication_bloc/SignUpWithEmailPassword-mixin.md","type":"mixin","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Sign up mixin.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"emailChanged","qualifiedName":"wyatt_authentication_bloc.SignUpWithEmailPassword.emailChanged","href":"wyatt_authentication_bloc/SignUpWithEmailPassword/emailChanged.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignUpWithEmailPassword","type":"mixin","href":"wyatt_authentication_bloc/SignUpWithEmailPassword-mixin.md"}},{"name":"emailCustomChanged","qualifiedName":"wyatt_authentication_bloc.SignUpWithEmailPassword.emailCustomChanged","href":"wyatt_authentication_bloc/SignUpWithEmailPassword/emailCustomChanged.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Same as emailChanged but with a custom Validator.","enclosedBy":{"name":"SignUpWithEmailPassword","type":"mixin","href":"wyatt_authentication_bloc/SignUpWithEmailPassword-mixin.md"}},{"name":"onSignUpWithEmailAndPassword","qualifiedName":"wyatt_authentication_bloc.SignUpWithEmailPassword.onSignUpWithEmailAndPassword","href":"wyatt_authentication_bloc/SignUpWithEmailPassword/onSignUpWithEmailAndPassword.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"This callback is triggered when a user creates an account.","enclosedBy":{"name":"SignUpWithEmailPassword","type":"mixin","href":"wyatt_authentication_bloc/SignUpWithEmailPassword-mixin.md"}},{"name":"passwordChanged","qualifiedName":"wyatt_authentication_bloc.SignUpWithEmailPassword.passwordChanged","href":"wyatt_authentication_bloc/SignUpWithEmailPassword/passwordChanged.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignUpWithEmailPassword","type":"mixin","href":"wyatt_authentication_bloc/SignUpWithEmailPassword-mixin.md"}},{"name":"passwordCustomChanged","qualifiedName":"wyatt_authentication_bloc.SignUpWithEmailPassword.passwordCustomChanged","href":"wyatt_authentication_bloc/SignUpWithEmailPassword/passwordCustomChanged.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Same as passwordChanged but with a custom Validator.","enclosedBy":{"name":"SignUpWithEmailPassword","type":"mixin","href":"wyatt_authentication_bloc/SignUpWithEmailPassword-mixin.md"}},{"name":"signUpWithEmailPassword","qualifiedName":"wyatt_authentication_bloc.SignUpWithEmailPassword.signUpWithEmailPassword","href":"wyatt_authentication_bloc/SignUpWithEmailPassword/signUpWithEmailPassword.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Creates a new user with the provided email and password.","enclosedBy":{"name":"SignUpWithEmailPassword","type":"mixin","href":"wyatt_authentication_bloc/SignUpWithEmailPassword-mixin.md"}},{"name":"SignedInEvent","qualifiedName":"wyatt_authentication_bloc.SignedInEvent","href":"wyatt_authentication_bloc/SignedInEvent-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"When a user authenticates (from not logged in to logged in).","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"SignedInEvent","qualifiedName":"wyatt_authentication_bloc.SignedInEvent.SignedInEvent","href":"wyatt_authentication_bloc/SignedInEvent/SignedInEvent.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignedInEvent","type":"class","href":"wyatt_authentication_bloc/SignedInEvent-class.md"}},{"name":"account","qualifiedName":"wyatt_authentication_bloc.SignedInEvent.account","href":"wyatt_authentication_bloc/SignedInEvent/account.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignedInEvent","type":"class","href":"wyatt_authentication_bloc/SignedInEvent-class.md"}},{"name":"props","qualifiedName":"wyatt_authentication_bloc.SignedInEvent.props","href":"wyatt_authentication_bloc/SignedInEvent/props.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"The list of properties that will be used to determine whether\ntwo instances are equal.","enclosedBy":{"name":"SignedInEvent","type":"class","href":"wyatt_authentication_bloc/SignedInEvent-class.md"}},{"name":"SignedInFromCacheEvent","qualifiedName":"wyatt_authentication_bloc.SignedInFromCacheEvent","href":"wyatt_authentication_bloc/SignedInFromCacheEvent-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"When a user authenticates automatically (from not logged in to logged in).","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"SignedInFromCacheEvent","qualifiedName":"wyatt_authentication_bloc.SignedInFromCacheEvent.SignedInFromCacheEvent","href":"wyatt_authentication_bloc/SignedInFromCacheEvent/SignedInFromCacheEvent.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignedInFromCacheEvent","type":"class","href":"wyatt_authentication_bloc/SignedInFromCacheEvent-class.md"}},{"name":"account","qualifiedName":"wyatt_authentication_bloc.SignedInFromCacheEvent.account","href":"wyatt_authentication_bloc/SignedInFromCacheEvent/account.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignedInFromCacheEvent","type":"class","href":"wyatt_authentication_bloc/SignedInFromCacheEvent-class.md"}},{"name":"props","qualifiedName":"wyatt_authentication_bloc.SignedInFromCacheEvent.props","href":"wyatt_authentication_bloc/SignedInFromCacheEvent/props.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"The list of properties that will be used to determine whether\ntwo instances are equal.","enclosedBy":{"name":"SignedInFromCacheEvent","type":"class","href":"wyatt_authentication_bloc/SignedInFromCacheEvent-class.md"}},{"name":"SignedOutEvent","qualifiedName":"wyatt_authentication_bloc.SignedOutEvent","href":"wyatt_authentication_bloc/SignedOutEvent-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"When a user logs out.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"SignedOutEvent","qualifiedName":"wyatt_authentication_bloc.SignedOutEvent.SignedOutEvent","href":"wyatt_authentication_bloc/SignedOutEvent/SignedOutEvent.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignedOutEvent","type":"class","href":"wyatt_authentication_bloc/SignedOutEvent-class.md"}},{"name":"SignedUpEvent","qualifiedName":"wyatt_authentication_bloc.SignedUpEvent","href":"wyatt_authentication_bloc/SignedUpEvent-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"When a user creates an account.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"SignedUpEvent","qualifiedName":"wyatt_authentication_bloc.SignedUpEvent.SignedUpEvent","href":"wyatt_authentication_bloc/SignedUpEvent/SignedUpEvent.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignedUpEvent","type":"class","href":"wyatt_authentication_bloc/SignedUpEvent-class.md"}},{"name":"account","qualifiedName":"wyatt_authentication_bloc.SignedUpEvent.account","href":"wyatt_authentication_bloc/SignedUpEvent/account.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"SignedUpEvent","type":"class","href":"wyatt_authentication_bloc/SignedUpEvent-class.md"}},{"name":"props","qualifiedName":"wyatt_authentication_bloc.SignedUpEvent.props","href":"wyatt_authentication_bloc/SignedUpEvent/props.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"The list of properties that will be used to determine whether\ntwo instances are equal.","enclosedBy":{"name":"SignedUpEvent","type":"class","href":"wyatt_authentication_bloc/SignedUpEvent-class.md"}},{"name":"UnknownAuthenticationEvent","qualifiedName":"wyatt_authentication_bloc.UnknownAuthenticationEvent","href":"wyatt_authentication_bloc/UnknownAuthenticationEvent-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"When a user's login status is unknown.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"UnknownAuthenticationEvent","qualifiedName":"wyatt_authentication_bloc.UnknownAuthenticationEvent.UnknownAuthenticationEvent","href":"wyatt_authentication_bloc/UnknownAuthenticationEvent/UnknownAuthenticationEvent.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"UnknownAuthenticationEvent","type":"class","href":"wyatt_authentication_bloc/UnknownAuthenticationEvent-class.md"}},{"name":"UpdateEmail","qualifiedName":"wyatt_authentication_bloc.UpdateEmail","href":"wyatt_authentication_bloc/UpdateEmail-mixin.md","type":"mixin","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Edit account mixin.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"emailChanged","qualifiedName":"wyatt_authentication_bloc.UpdateEmail.emailChanged","href":"wyatt_authentication_bloc/UpdateEmail/emailChanged.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"UpdateEmail","type":"mixin","href":"wyatt_authentication_bloc/UpdateEmail-mixin.md"}},{"name":"emailCustomChanged","qualifiedName":"wyatt_authentication_bloc.UpdateEmail.emailCustomChanged","href":"wyatt_authentication_bloc/UpdateEmail/emailCustomChanged.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Same as emailChanged but with a custom Validator.","enclosedBy":{"name":"UpdateEmail","type":"mixin","href":"wyatt_authentication_bloc/UpdateEmail-mixin.md"}},{"name":"onEmailUpdated","qualifiedName":"wyatt_authentication_bloc.UpdateEmail.onEmailUpdated","href":"wyatt_authentication_bloc/UpdateEmail/onEmailUpdated.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"This callback is triggered when user updates his email","enclosedBy":{"name":"UpdateEmail","type":"mixin","href":"wyatt_authentication_bloc/UpdateEmail-mixin.md"}},{"name":"updateEmail","qualifiedName":"wyatt_authentication_bloc.UpdateEmail.updateEmail","href":"wyatt_authentication_bloc/UpdateEmail/updateEmail.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Update or add email.","enclosedBy":{"name":"UpdateEmail","type":"mixin","href":"wyatt_authentication_bloc/UpdateEmail-mixin.md"}},{"name":"UpdateEmailFailureFirebase","qualifiedName":"wyatt_authentication_bloc.UpdateEmailFailureFirebase","href":"wyatt_authentication_bloc/UpdateEmailFailureFirebase-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the email modification process if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"UpdateEmailFailureFirebase","qualifiedName":"wyatt_authentication_bloc.UpdateEmailFailureFirebase.UpdateEmailFailureFirebase","href":"wyatt_authentication_bloc/UpdateEmailFailureFirebase/UpdateEmailFailureFirebase.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"UpdateEmailFailureFirebase","type":"class","href":"wyatt_authentication_bloc/UpdateEmailFailureFirebase-class.md"}},{"name":"UpdateEmailFailureFirebase.fromCode","qualifiedName":"wyatt_authentication_bloc.UpdateEmailFailureFirebase.fromCode","href":"wyatt_authentication_bloc/UpdateEmailFailureFirebase/UpdateEmailFailureFirebase.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"UpdateEmailFailureFirebase","type":"class","href":"wyatt_authentication_bloc/UpdateEmailFailureFirebase-class.md"}},{"name":"UpdateEmailFailureInterface","qualifiedName":"wyatt_authentication_bloc.UpdateEmailFailureInterface","href":"wyatt_authentication_bloc/UpdateEmailFailureInterface-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the email modification process if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"UpdateEmailFailureInterface","qualifiedName":"wyatt_authentication_bloc.UpdateEmailFailureInterface.UpdateEmailFailureInterface","href":"wyatt_authentication_bloc/UpdateEmailFailureInterface/UpdateEmailFailureInterface.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"UpdateEmailFailureInterface","type":"class","href":"wyatt_authentication_bloc/UpdateEmailFailureInterface-class.md"}},{"name":"UpdateEmailFailureInterface.fromCode","qualifiedName":"wyatt_authentication_bloc.UpdateEmailFailureInterface.fromCode","href":"wyatt_authentication_bloc/UpdateEmailFailureInterface/UpdateEmailFailureInterface.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"UpdateEmailFailureInterface","type":"class","href":"wyatt_authentication_bloc/UpdateEmailFailureInterface-class.md"}},{"name":"UpdatePassword","qualifiedName":"wyatt_authentication_bloc.UpdatePassword","href":"wyatt_authentication_bloc/UpdatePassword-mixin.md","type":"mixin","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Edit account mixin.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"onPasswordUpdated","qualifiedName":"wyatt_authentication_bloc.UpdatePassword.onPasswordUpdated","href":"wyatt_authentication_bloc/UpdatePassword/onPasswordUpdated.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"This callback is triggered when a user edits his password.","enclosedBy":{"name":"UpdatePassword","type":"mixin","href":"wyatt_authentication_bloc/UpdatePassword-mixin.md"}},{"name":"passwordChanged","qualifiedName":"wyatt_authentication_bloc.UpdatePassword.passwordChanged","href":"wyatt_authentication_bloc/UpdatePassword/passwordChanged.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"UpdatePassword","type":"mixin","href":"wyatt_authentication_bloc/UpdatePassword-mixin.md"}},{"name":"passwordCustomChanged","qualifiedName":"wyatt_authentication_bloc.UpdatePassword.passwordCustomChanged","href":"wyatt_authentication_bloc/UpdatePassword/passwordCustomChanged.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Same as passwordChanged but with a custom Validator.","enclosedBy":{"name":"UpdatePassword","type":"mixin","href":"wyatt_authentication_bloc/UpdatePassword-mixin.md"}},{"name":"updatePassword","qualifiedName":"wyatt_authentication_bloc.UpdatePassword.updatePassword","href":"wyatt_authentication_bloc/UpdatePassword/updatePassword.md","type":"method","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Update or add password.","enclosedBy":{"name":"UpdatePassword","type":"mixin","href":"wyatt_authentication_bloc/UpdatePassword-mixin.md"}},{"name":"UpdatePasswordFailureFirebase","qualifiedName":"wyatt_authentication_bloc.UpdatePasswordFailureFirebase","href":"wyatt_authentication_bloc/UpdatePasswordFailureFirebase-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the password modification process if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"UpdatePasswordFailureFirebase","qualifiedName":"wyatt_authentication_bloc.UpdatePasswordFailureFirebase.UpdatePasswordFailureFirebase","href":"wyatt_authentication_bloc/UpdatePasswordFailureFirebase/UpdatePasswordFailureFirebase.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"UpdatePasswordFailureFirebase","type":"class","href":"wyatt_authentication_bloc/UpdatePasswordFailureFirebase-class.md"}},{"name":"UpdatePasswordFailureFirebase.fromCode","qualifiedName":"wyatt_authentication_bloc.UpdatePasswordFailureFirebase.fromCode","href":"wyatt_authentication_bloc/UpdatePasswordFailureFirebase/UpdatePasswordFailureFirebase.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"UpdatePasswordFailureFirebase","type":"class","href":"wyatt_authentication_bloc/UpdatePasswordFailureFirebase-class.md"}},{"name":"UpdatePasswordFailureInterface","qualifiedName":"wyatt_authentication_bloc.UpdatePasswordFailureInterface","href":"wyatt_authentication_bloc/UpdatePasswordFailureInterface-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the password modification process if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"UpdatePasswordFailureInterface","qualifiedName":"wyatt_authentication_bloc.UpdatePasswordFailureInterface.UpdatePasswordFailureInterface","href":"wyatt_authentication_bloc/UpdatePasswordFailureInterface/UpdatePasswordFailureInterface.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"UpdatePasswordFailureInterface","type":"class","href":"wyatt_authentication_bloc/UpdatePasswordFailureInterface-class.md"}},{"name":"UpdatePasswordFailureInterface.fromCode","qualifiedName":"wyatt_authentication_bloc.UpdatePasswordFailureInterface.fromCode","href":"wyatt_authentication_bloc/UpdatePasswordFailureInterface/UpdatePasswordFailureInterface.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"UpdatePasswordFailureInterface","type":"class","href":"wyatt_authentication_bloc/UpdatePasswordFailureInterface-class.md"}},{"name":"UpdatedEvent","qualifiedName":"wyatt_authentication_bloc.UpdatedEvent","href":"wyatt_authentication_bloc/UpdatedEvent-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"When the user's account has been updated.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"UpdatedEvent","qualifiedName":"wyatt_authentication_bloc.UpdatedEvent.UpdatedEvent","href":"wyatt_authentication_bloc/UpdatedEvent/UpdatedEvent.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"UpdatedEvent","type":"class","href":"wyatt_authentication_bloc/UpdatedEvent-class.md"}},{"name":"account","qualifiedName":"wyatt_authentication_bloc.UpdatedEvent.account","href":"wyatt_authentication_bloc/UpdatedEvent/account.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"UpdatedEvent","type":"class","href":"wyatt_authentication_bloc/UpdatedEvent-class.md"}},{"name":"props","qualifiedName":"wyatt_authentication_bloc.UpdatedEvent.props","href":"wyatt_authentication_bloc/UpdatedEvent/props.md","type":"property","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"The list of properties that will be used to determine whether\ntwo instances are equal.","enclosedBy":{"name":"UpdatedEvent","type":"class","href":"wyatt_authentication_bloc/UpdatedEvent-class.md"}},{"name":"VerifyPasswordResetCodeFailureFirebase","qualifiedName":"wyatt_authentication_bloc.VerifyPasswordResetCodeFailureFirebase","href":"wyatt_authentication_bloc/VerifyPasswordResetCodeFailureFirebase-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the password reset process if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"VerifyPasswordResetCodeFailureFirebase","qualifiedName":"wyatt_authentication_bloc.VerifyPasswordResetCodeFailureFirebase.VerifyPasswordResetCodeFailureFirebase","href":"wyatt_authentication_bloc/VerifyPasswordResetCodeFailureFirebase/VerifyPasswordResetCodeFailureFirebase.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"VerifyPasswordResetCodeFailureFirebase","type":"class","href":"wyatt_authentication_bloc/VerifyPasswordResetCodeFailureFirebase-class.md"}},{"name":"VerifyPasswordResetCodeFailureFirebase.fromCode","qualifiedName":"wyatt_authentication_bloc.VerifyPasswordResetCodeFailureFirebase.fromCode","href":"wyatt_authentication_bloc/VerifyPasswordResetCodeFailureFirebase/VerifyPasswordResetCodeFailureFirebase.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"","enclosedBy":{"name":"VerifyPasswordResetCodeFailureFirebase","type":"class","href":"wyatt_authentication_bloc/VerifyPasswordResetCodeFailureFirebase-class.md"}},{"name":"VerifyPasswordResetCodeFailureInterface","qualifiedName":"wyatt_authentication_bloc.VerifyPasswordResetCodeFailureInterface","href":"wyatt_authentication_bloc/VerifyPasswordResetCodeFailureInterface-class.md","type":"class","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the password reset process if a failure occurs.","enclosedBy":{"name":"wyatt_authentication_bloc","type":"library","href":"wyatt_authentication_bloc/wyatt_authentication_bloc-library.md"}},{"name":"VerifyPasswordResetCodeFailureInterface","qualifiedName":"wyatt_authentication_bloc.VerifyPasswordResetCodeFailureInterface.VerifyPasswordResetCodeFailureInterface","href":"wyatt_authentication_bloc/VerifyPasswordResetCodeFailureInterface/VerifyPasswordResetCodeFailureInterface.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the password reset process if a failure occurs.","enclosedBy":{"name":"VerifyPasswordResetCodeFailureInterface","type":"class","href":"wyatt_authentication_bloc/VerifyPasswordResetCodeFailureInterface-class.md"}},{"name":"VerifyPasswordResetCodeFailureInterface.fromCode","qualifiedName":"wyatt_authentication_bloc.VerifyPasswordResetCodeFailureInterface.fromCode","href":"wyatt_authentication_bloc/VerifyPasswordResetCodeFailureInterface/VerifyPasswordResetCodeFailureInterface.fromCode.md","type":"constructor","overriddenDepth":0,"packageName":"wyatt_authentication_bloc","desc":"Thrown during the password reset process if a failure occurs.","enclosedBy":{"name":"VerifyPasswordResetCodeFailureInterface","type":"class","href":"wyatt_authentication_bloc/VerifyPasswordResetCodeFailureInterface-class.md"}}] diff --git a/packages/wyatt_authentication_bloc/doc/api/index.md b/packages/wyatt_authentication_bloc/doc/api/index.md deleted file mode 100644 index 7cf99eac..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/index.md +++ /dev/null @@ -1,214 +0,0 @@ - - - -# wyatt_authentication_bloc - Dart API docs - - - -

Flutter - Authentication BLoC

- Style: Wyatt Analysis - SDK: Flutter -

-

Authentication Bloc for Flutter.

-

Features

-
    -
  • 🧐 Wyatt Architecture
  • -
  • 🧱 Entities -
      -
    • Account -> Contains account information from provider.
    • -
    • Session -> Contains account and associated data retrieved from an external source.
    • -
    • AuthenticationChangeEvent -> Describes an event in authentication change (sign in, sign up, sign out, etc...)
    • -
    • SessionWrapper -> Contains latest authentication change event and session.
    • -
    -
  • -
  • 🔑 Powerful and secured authentication repository
  • -
  • 🔥 Multiple data sources -
      -
    • Mock
    • -
    • Firebase
    • -
    -
  • -
  • 🧊 Cubits, why make it complicated when you can make it simple? -
      -
    • Goes to the essential.
    • -
    -
  • -
  • 📐 Consistent -
      -
    • Every class have same naming convention
    • -
    -
  • -
  • 🧪 Tested
  • -
  • 📚 Documented: available here
  • -
-

Getting started

-

Simply add wyatt_authentication_bloc in pubspec.yaml , then

-
import 'package:wyatt_authentication_bloc/wyatt_authentication_bloc.dart';
-
-

Data source

-

The first step is to provide a data source.

-
getIt.registerLazySingleton<AuthenticationRemoteDataSource<int>>(
-    () => AuthenticationFirebaseDataSourceImpl<int>(
-        firebaseAuth: FirebaseAuth.instance,
-        googleSignIn:
-            GoogleSignIn(clientId: DefaultFirebaseOptions.ios.iosClientId)),
-);
-
-
-

Here we use GetIt (see example project)

-
-

Repository

-

Then you can configure your repository.

-
final AuthenticationRepository<int> authenticationRepository = AuthenticationRepositoryImpl(
-    authenticationRemoteDataSource:
-        getIt<AuthenticationRemoteDataSource<int>>(),
-    customPasswordValidator: const CustomPassword.pure(),
-    extraSignUpInputs: [
-        FormInput(
-        AuthFormField.confirmPassword,
-        const ConfirmedPassword.pure(),
-        metadata: const FormInputMetadata<void>(export: false),
-        ),
-    ],
-);
-
-
-

Here we pass some extra inputs for the sign up, and a custom password validator.

-
-

Cubits

-

It is necessary to implement each cubit. Don't panic, most of the work is already done 😊 you just have to customize the logic of these.

-

In each of these cubits it is necessary to overload the various callbacks.

-
-

Here the associated data Data is a int

-
-

Authentication

-

In the authentication are managed, the refresh, the deletion of account or the disconnection.

-
class ExampleAuthenticationCubit extends AuthenticationCubit<int> {
-  ExampleAuthenticationCubit({required super.authenticationRepository});
-
-  @override
-  FutureOrResult<int?> onReauthenticate(Result<Account, AppException> result) async {
-    // TODO
-  }
-
-  @override
-  FutureOrResult<int?> onRefresh(Result<Account, AppException> result) {
-    // TODO
-  }
-
-  @override
-  FutureOrResult<int?> onSignInFromCache(SessionWrapper<int> wrapper) {
-    // TODO
-  }
-
-  @override
-  FutureOrResult<void> onSignOut() {
-    // TODO
-  }
-
-  @override
-  FutureOrResult<void> onDelete() {
-    // TODO
-  }
-}
-
-

Sign Up

-
class ExampleSignUpCubit extends SignUpCubit<int> {
-  ExampleSignUpCubit({
-    required super.authenticationRepository,
-  });
-
-  @override
-  FutureOrResult<int?> onSignUpWithEmailAndPassword(Result<Account, AppException> result, WyattForm form) async {
-    // TODO
-  }
-}
-
-
-

Sign In

-
class ExampleSignInCubit extends SignInCubit<int> {
-  ExampleSignInCubit({
-    required super.authenticationRepository,
-  });
-
-  @override
-  FutureOrResult<int?> onSignInWithEmailAndPassword(Result<Account, AppException> result, WyattForm form) {
-    // TODO
-  }
-
-  @override
-  FutureOrResult<int?> onSignInAnonymously(Result<Account, AppException> result, WyattForm form) {
-    // TODO
-  }
-
-  @override
-  FutureOrResult<int?> onSignInWithGoogle(Result<Account, AppException> result, WyattForm form) {
-    // TODO
-  }
-}
-
-

After setting up all these cubits you can provide them in the application. And that's it!

-
BlocProvider<SignUpCubit<int>>(
-    create: (_) => ExampleSignUpCubit(
-        authenticationRepository: authenticationRepository,
-    ),
-),
-BlocProvider<SignInCubit<int>>(
-    create: (_) => ExampleSignInCubit(
-        authenticationRepository: authenticationRepository,
-    ),
-),
-
-

Widgets

-

Widgets are provided to make your life easier. Starting with the AuthenticationBuilder which allows you to build according to the authentication state.

-
AuthenticationBuilder<int>(
-    authenticated: (context, sessionWrapper) => Text(
-        'Logged as ${sessionWrapper.session?.account.email} | GeneratedId is ${sessionWrapper.session?.data}'),
-    unauthenticated: (context) =>
-        const Text('Not logged (unauthenticated)'),
-    unknown: (context) => const Text('Not logged (unknown)'),
-),
-
-

A BuildContext extension is also available to access certain attributes more quickly.

-
Text('Home | ${context.account<AuthenticationCubit<int>, int>()?.email}'),
-
-

Listeners are used to listen to the status of the sign in and sign up forms.

-
return SignInListener<int>(
-    onError: (context, status, errorMessage) => ScaffoldMessenger.of(context)
-    ..hideCurrentSnackBar()
-    ..showSnackBar(
-        SnackBar(content: Text(errorMessage ?? 'Sign In Failure')),
-    ),
-    child: ...
-);
-
- - -## Libraries - -##### [wyatt_authentication_bloc](wyatt_authentication_bloc/wyatt_authentication_bloc-library.md) -An authentication library for BLoC. - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/search.md b/packages/wyatt_authentication_bloc/doc/api/search.md deleted file mode 100644 index 0fedbdcf..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/search.md +++ /dev/null @@ -1,6 +0,0 @@ -# 404 - -Oops, something's gone wrong :-( - -You've tried to visit a page that doesn't exist. Luckily this site has other -[pages](index.md). diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account-class.md deleted file mode 100644 index f52d7482..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account-class.md +++ /dev/null @@ -1,237 +0,0 @@ - - - -# Account class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Represents a user Account in the -various identity provisioning systems.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [Equatable](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable-class.html) -- Account - - - -**Implementers** - -- [AccountModel](../wyatt_authentication_bloc/AccountModel-class.md) - - - - - -## Constructors - -[Account](../wyatt_authentication_bloc/Account/Account.md) ({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) id, required [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) isAnonymous, required [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) emailVerified, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) providerId, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? email, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? phoneNumber, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? photoURL, [DateTime](https://api.flutter.dev/flutter/dart-core/DateTime-class.html)? creationTime, [DateTime](https://api.flutter.dev/flutter/dart-core/DateTime-class.html)? lastSignInTime, [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)? isNewUser, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? accessToken, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? refreshToken}) - - _const_ - - -## Properties - -##### [accessToken](../wyatt_authentication_bloc/Account/accessToken.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? - - - -The user access token -_final_ - - - -##### [creationTime](../wyatt_authentication_bloc/Account/creationTime.md) → [DateTime](https://api.flutter.dev/flutter/dart-core/DateTime-class.html)? - - - -Returns the users account creation time. -_final_ - - - -##### [email](../wyatt_authentication_bloc/Account/email.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? - - - -The users email address. -_final_ - - - -##### [emailVerified](../wyatt_authentication_bloc/Account/emailVerified.md) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -Returns whether the users email address has been verified. -_final_ - - - -##### [hashCode](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [id](../wyatt_authentication_bloc/Account/id.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -The user's unique ID. -_final_ - - - -##### [isAnonymous](../wyatt_authentication_bloc/Account/isAnonymous.md) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -Returns whether the user is a anonymous. -_final_ - - - -##### [isNewUser](../wyatt_authentication_bloc/Account/isNewUser.md) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)? - - - -Whether the user account has been recently created. -_final_ - - - -##### [lastSignInTime](../wyatt_authentication_bloc/Account/lastSignInTime.md) → [DateTime](https://api.flutter.dev/flutter/dart-core/DateTime-class.html)? - - - -When the user last signed in as dictated by the server clock. -_final_ - - - -##### [phoneNumber](../wyatt_authentication_bloc/Account/phoneNumber.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? - - - -Returns the users phone number. -_final_ - - - -##### [photoURL](../wyatt_authentication_bloc/Account/photoURL.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? - - - -Returns a photo URL for the user. -_final_ - - - -##### [props](../wyatt_authentication_bloc/Account/props.md) → [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> - - - -The list of properties that will be used to determine whether -two instances are equal. -_read-onlyoverride_ - - - -##### [providerId](../wyatt_authentication_bloc/Account/providerId.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -The provider ID for the user. -_final_ - - - -##### [refreshToken](../wyatt_authentication_bloc/Account/refreshToken.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? - - - -The user refresh token -_final_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - -##### [stringify](../wyatt_authentication_bloc/Account/stringify.md) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -If set to true, the toString method will be overridden to output -this instance's props. -_read-onlyoverride_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/Account.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/Account.md deleted file mode 100644 index 22006c3c..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/Account.md +++ /dev/null @@ -1,43 +0,0 @@ - - - -# Account constructor - - - - - *[](https://dart.dev/null-safety)* - - -const -Account({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) id, required [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) isAnonymous, required [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) emailVerified, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) providerId, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? email, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? phoneNumber, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? photoURL, [DateTime](https://api.flutter.dev/flutter/dart-core/DateTime-class.html)? creationTime, [DateTime](https://api.flutter.dev/flutter/dart-core/DateTime-class.html)? lastSignInTime, [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)? isNewUser, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? accessToken, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? refreshToken}) - - - - - -## Implementation - -```dart -const Account({ - required this.id, - required this.isAnonymous, - required this.emailVerified, - required this.providerId, - this.email, - this.phoneNumber, - this.photoURL, - this.creationTime, - this.lastSignInTime, - this.isNewUser, - this.accessToken, - this.refreshToken, -}); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/accessToken.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/accessToken.md deleted file mode 100644 index 0ceb6c2e..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/accessToken.md +++ /dev/null @@ -1,34 +0,0 @@ - - - -# accessToken property - - - - - *[](https://dart.dev/null-safety)* - - - -[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? accessToken - -_final_ - - - -

The user access token

- - - -## Implementation - -```dart -final String? accessToken; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/creationTime.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/creationTime.md deleted file mode 100644 index cf5dfe5c..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/creationTime.md +++ /dev/null @@ -1,35 +0,0 @@ - - - -# creationTime property - - - - - *[](https://dart.dev/null-safety)* - - - -[DateTime](https://api.flutter.dev/flutter/dart-core/DateTime-class.html)? creationTime - -_final_ - - - -

Returns the users account creation time.

-

When this account was created as dictated by the server clock.

- - - -## Implementation - -```dart -final DateTime? creationTime; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/email.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/email.md deleted file mode 100644 index 2d007ce3..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/email.md +++ /dev/null @@ -1,35 +0,0 @@ - - - -# email property - - - - - *[](https://dart.dev/null-safety)* - - - -[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? email - -_final_ - - - -

The users email address.

-

Will be null if signing in anonymously.

- - - -## Implementation - -```dart -final String? email; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/emailVerified.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/emailVerified.md deleted file mode 100644 index e4e36b29..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/emailVerified.md +++ /dev/null @@ -1,35 +0,0 @@ - - - -# emailVerified property - - - - - *[](https://dart.dev/null-safety)* - - - -[bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) emailVerified - -_final_ - - - -

Returns whether the users email address has been verified.

-

To send a verification email, see SendEmailVerification.

- - - -## Implementation - -```dart -final bool emailVerified; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/id.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/id.md deleted file mode 100644 index 4796ed2f..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/id.md +++ /dev/null @@ -1,34 +0,0 @@ - - - -# id property - - - - - *[](https://dart.dev/null-safety)* - - - -[String](https://api.flutter.dev/flutter/dart-core/String-class.html) id - -_final_ - - - -

The user's unique ID.

- - - -## Implementation - -```dart -final String id; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/isAnonymous.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/isAnonymous.md deleted file mode 100644 index 324b4fda..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/isAnonymous.md +++ /dev/null @@ -1,34 +0,0 @@ - - - -# isAnonymous property - - - - - *[](https://dart.dev/null-safety)* - - - -[bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) isAnonymous - -_final_ - - - -

Returns whether the user is a anonymous.

- - - -## Implementation - -```dart -final bool isAnonymous; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/isNewUser.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/isNewUser.md deleted file mode 100644 index f96ab918..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/isNewUser.md +++ /dev/null @@ -1,34 +0,0 @@ - - - -# isNewUser property - - - - - *[](https://dart.dev/null-safety)* - - - -[bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)? isNewUser - -_final_ - - - -

Whether the user account has been recently created.

- - - -## Implementation - -```dart -final bool? isNewUser; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/lastSignInTime.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/lastSignInTime.md deleted file mode 100644 index 0f257f63..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/lastSignInTime.md +++ /dev/null @@ -1,34 +0,0 @@ - - - -# lastSignInTime property - - - - - *[](https://dart.dev/null-safety)* - - - -[DateTime](https://api.flutter.dev/flutter/dart-core/DateTime-class.html)? lastSignInTime - -_final_ - - - -

When the user last signed in as dictated by the server clock.

- - - -## Implementation - -```dart -final DateTime? lastSignInTime; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/phoneNumber.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/phoneNumber.md deleted file mode 100644 index 7b33f623..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/phoneNumber.md +++ /dev/null @@ -1,36 +0,0 @@ - - - -# phoneNumber property - - - - - *[](https://dart.dev/null-safety)* - - - -[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? phoneNumber - -_final_ - - - -

Returns the users phone number.

-

This property will be null if the user has not signed in or been has -their phone number linked.

- - - -## Implementation - -```dart -final String? phoneNumber; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/photoURL.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/photoURL.md deleted file mode 100644 index c76a2896..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/photoURL.md +++ /dev/null @@ -1,36 +0,0 @@ - - - -# photoURL property - - - - - *[](https://dart.dev/null-safety)* - - - -[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? photoURL - -_final_ - - - -

Returns a photo URL for the user.

-

This property will be populated if the user has signed in or been linked -with a 3rd party OAuth provider (such as Google).

- - - -## Implementation - -```dart -final String? photoURL; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/props.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/props.md deleted file mode 100644 index 619e2501..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/props.md +++ /dev/null @@ -1,55 +0,0 @@ - - - -# props property - - - - - *[](https://dart.dev/null-safety)* - - - - - -**Annotations** - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) -[List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> props - -_override_ - - - -

The list of properties that will be used to determine whether -two instances are equal.

- - - -## Implementation - -```dart -@override -List get props => [ - id, - isAnonymous, - email, - emailVerified, - phoneNumber, - photoURL, - creationTime, - lastSignInTime, - providerId, - isNewUser, - accessToken, - refreshToken, - ]; -``` - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/providerId.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/providerId.md deleted file mode 100644 index a539b552..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/providerId.md +++ /dev/null @@ -1,34 +0,0 @@ - - - -# providerId property - - - - - *[](https://dart.dev/null-safety)* - - - -[String](https://api.flutter.dev/flutter/dart-core/String-class.html) providerId - -_final_ - - - -

The provider ID for the user.

- - - -## Implementation - -```dart -final String providerId; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/refreshToken.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/refreshToken.md deleted file mode 100644 index 781948d8..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/refreshToken.md +++ /dev/null @@ -1,34 +0,0 @@ - - - -# refreshToken property - - - - - *[](https://dart.dev/null-safety)* - - - -[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? refreshToken - -_final_ - - - -

The user refresh token

- - - -## Implementation - -```dart -final String? refreshToken; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/stringify.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/stringify.md deleted file mode 100644 index 8df8a404..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Account/stringify.md +++ /dev/null @@ -1,47 +0,0 @@ - - - -# stringify property - - - - - *[](https://dart.dev/null-safety)* - - - - - -**Annotations** - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) -[bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) stringify - -_override_ - - - -

If set to true, the toString method will be overridden to output -this instance's props.

-

A global default value for stringify can be set using -EquatableConfig.stringify.

-

If this instance's stringify is set to null, the value of -EquatableConfig.stringify will be used instead. This defaults to -false.

- - - -## Implementation - -```dart -@override -bool get stringify => true; -``` - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AccountModel-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AccountModel-class.md deleted file mode 100644 index 68088ea5..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AccountModel-class.md +++ /dev/null @@ -1,247 +0,0 @@ - - - -# AccountModel class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Account Model to parse Firebase User data

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [Equatable](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable-class.html) -- [Account](../wyatt_authentication_bloc/Account-class.md) -- AccountModel - - - - - - - - -## Constructors - -[AccountModel.fromFirebaseUser](../wyatt_authentication_bloc/AccountModel/AccountModel.fromFirebaseUser.md) ([User](https://pub.dev/documentation/firebase_auth/4.2.0/firebase_auth/User-class.html)? user, {[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? accessToken}) - - _factory_ - -[AccountModel.fromFirebaseUserCredential](../wyatt_authentication_bloc/AccountModel/AccountModel.fromFirebaseUserCredential.md) ([UserCredential](https://pub.dev/documentation/firebase_auth/4.2.0/firebase_auth/UserCredential-class.html)? userCredential) - - _factory_ - - -## Properties - -##### [accessToken](../wyatt_authentication_bloc/Account/accessToken.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? - - - -The user access token -_finalinherited_ - - - -##### [creationTime](../wyatt_authentication_bloc/Account/creationTime.md) → [DateTime](https://api.flutter.dev/flutter/dart-core/DateTime-class.html)? - - - -Returns the users account creation time. -_finalinherited_ - - - -##### [email](../wyatt_authentication_bloc/Account/email.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? - - - -The users email address. -_finalinherited_ - - - -##### [emailVerified](../wyatt_authentication_bloc/Account/emailVerified.md) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -Returns whether the users email address has been verified. -_finalinherited_ - - - -##### [hashCode](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [id](../wyatt_authentication_bloc/Account/id.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -The user's unique ID. -_finalinherited_ - - - -##### [isAnonymous](../wyatt_authentication_bloc/Account/isAnonymous.md) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -Returns whether the user is a anonymous. -_finalinherited_ - - - -##### [isNewUser](../wyatt_authentication_bloc/Account/isNewUser.md) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)? - - - -Whether the user account has been recently created. -_finalinherited_ - - - -##### [lastSignInTime](../wyatt_authentication_bloc/Account/lastSignInTime.md) → [DateTime](https://api.flutter.dev/flutter/dart-core/DateTime-class.html)? - - - -When the user last signed in as dictated by the server clock. -_finalinherited_ - - - -##### [phoneNumber](../wyatt_authentication_bloc/Account/phoneNumber.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? - - - -Returns the users phone number. -_finalinherited_ - - - -##### [photoURL](../wyatt_authentication_bloc/Account/photoURL.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? - - - -Returns a photo URL for the user. -_finalinherited_ - - - -##### [props](../wyatt_authentication_bloc/Account/props.md) → [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> - - - -The list of properties that will be used to determine whether -two instances are equal. -_read-onlyinherited_ - - - -##### [providerId](../wyatt_authentication_bloc/Account/providerId.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -The provider ID for the user. -_finalinherited_ - - - -##### [refreshToken](../wyatt_authentication_bloc/AccountModel/refreshToken.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? - - - -The user refresh token -_read-onlyoverride_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - -##### [stringify](../wyatt_authentication_bloc/Account/stringify.md) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -If set to true, the toString method will be overridden to output -this instance's props. -_read-onlyinherited_ - - - -##### [user](../wyatt_authentication_bloc/AccountModel/user.md) → [User](https://pub.dev/documentation/firebase_auth/4.2.0/firebase_auth/User-class.html)? - - - - -_final_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AccountModel/AccountModel.fromFirebaseUser.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AccountModel/AccountModel.fromFirebaseUser.md deleted file mode 100644 index f040be39..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AccountModel/AccountModel.fromFirebaseUser.md +++ /dev/null @@ -1,51 +0,0 @@ - - - -# AccountModel.fromFirebaseUser constructor - - - - - *[](https://dart.dev/null-safety)* - - - -AccountModel.fromFirebaseUser([User](https://pub.dev/documentation/firebase_auth/4.2.0/firebase_auth/User-class.html)? user, {[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? accessToken}) - - - - - -## Implementation - -```dart -factory AccountModel.fromFirebaseUser(User? user, {String? accessToken}) { - if (user != null) { - final providerId = - (user.providerData.isEmpty) ? '' : user.providerData.first.providerId; - return AccountModel._( - user: user, - id: user.uid, - emailVerified: user.emailVerified, - isAnonymous: user.isAnonymous, - providerId: providerId, - creationTime: user.metadata.creationTime, - lastSignInTime: user.metadata.lastSignInTime, - isNewUser: false, - email: user.email, - phoneNumber: user.phoneNumber, - photoURL: user.photoURL, - accessToken: accessToken, - ); - } else { - throw ModelParsingFailureFirebase('null-user', 'User cannot be null'); - } -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AccountModel/AccountModel.fromFirebaseUserCredential.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AccountModel/AccountModel.fromFirebaseUserCredential.md deleted file mode 100644 index ac8c078e..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AccountModel/AccountModel.fromFirebaseUserCredential.md +++ /dev/null @@ -1,54 +0,0 @@ - - - -# AccountModel.fromFirebaseUserCredential constructor - - - - - *[](https://dart.dev/null-safety)* - - - -AccountModel.fromFirebaseUserCredential([UserCredential](https://pub.dev/documentation/firebase_auth/4.2.0/firebase_auth/UserCredential-class.html)? userCredential) - - - - - -## Implementation - -```dart -factory AccountModel.fromFirebaseUserCredential( - UserCredential? userCredential, -) { - final user = userCredential?.user; - if (user != null) { - final providerId = - (user.providerData.isEmpty) ? '' : user.providerData.first.providerId; - return AccountModel._( - user: user, - id: user.uid, - emailVerified: user.emailVerified, - isAnonymous: user.isAnonymous, - providerId: providerId, - creationTime: user.metadata.creationTime, - lastSignInTime: user.metadata.lastSignInTime, - isNewUser: userCredential?.additionalUserInfo?.isNewUser, - email: user.email, - phoneNumber: user.phoneNumber, - photoURL: user.photoURL, - accessToken: userCredential?.credential?.accessToken, - ); - } else { - throw ModelParsingFailureFirebase('null-user', 'User cannot be null'); - } -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AccountModel/refreshToken.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AccountModel/refreshToken.md deleted file mode 100644 index f8863731..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AccountModel/refreshToken.md +++ /dev/null @@ -1,41 +0,0 @@ - - - -# refreshToken property - - - - - *[](https://dart.dev/null-safety)* - - - - - -**Annotations** - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) -[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? refreshToken - -_override_ - - - -

The user refresh token

- - - -## Implementation - -```dart -@override -String? get refreshToken => user?.refreshToken; -``` - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AccountModel/user.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AccountModel/user.md deleted file mode 100644 index e0146cab..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AccountModel/user.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# user property - - - - - *[](https://dart.dev/null-safety)* - - - -[User](https://pub.dev/documentation/firebase_auth/4.2.0/firebase_auth/User-class.html)? user - -_final_ - - - - - - -## Implementation - -```dart -final User? user; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ApplyActionCodeFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ApplyActionCodeFailureFirebase-class.md deleted file mode 100644 index 451ed5dd..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ApplyActionCodeFailureFirebase-class.md +++ /dev/null @@ -1,137 +0,0 @@ - - - -# ApplyActionCodeFailureFirebase class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown if during the apply action code process if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- [ApplyActionCodeFailureInterface](../wyatt_authentication_bloc/ApplyActionCodeFailureInterface-class.md) -- ApplyActionCodeFailureFirebase - - - - - - - - -## Constructors - -[ApplyActionCodeFailureFirebase](../wyatt_authentication_bloc/ApplyActionCodeFailureFirebase/ApplyActionCodeFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - -[ApplyActionCodeFailureFirebase.fromCode](../wyatt_authentication_bloc/ApplyActionCodeFailureFirebase/ApplyActionCodeFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ApplyActionCodeFailureFirebase/ApplyActionCodeFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ApplyActionCodeFailureFirebase/ApplyActionCodeFailureFirebase.fromCode.md deleted file mode 100644 index 1c261bc6..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ApplyActionCodeFailureFirebase/ApplyActionCodeFailureFirebase.fromCode.md +++ /dev/null @@ -1,49 +0,0 @@ - - - -# ApplyActionCodeFailureFirebase.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -ApplyActionCodeFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - - -## Implementation - -```dart -ApplyActionCodeFailureFirebase.fromCode(String code) : super.fromCode(code) { - switch (code) { - case 'expired-action-code': - msg = 'Action code has expired.'; - break; - case 'invalid-action-code': - msg = 'Action code is invalid.'; - break; - case 'user-disabled': - msg = 'This user has been disabled. Please contact support for help.'; - break; - case 'user-not-found': - msg = 'Email is not found, please create an account.'; - break; - - default: - this.code = 'unknown'; - msg = 'An unknown error occurred.'; - } -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ApplyActionCodeFailureFirebase/ApplyActionCodeFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ApplyActionCodeFailureFirebase/ApplyActionCodeFailureFirebase.md deleted file mode 100644 index 2e03e5ae..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ApplyActionCodeFailureFirebase/ApplyActionCodeFailureFirebase.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# ApplyActionCodeFailureFirebase constructor - - - - - *[](https://dart.dev/null-safety)* - - - -ApplyActionCodeFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - - - -## Implementation - -```dart -ApplyActionCodeFailureFirebase([String? code, String? msg]) - : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ApplyActionCodeFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ApplyActionCodeFailureInterface-class.md deleted file mode 100644 index 487660fd..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ApplyActionCodeFailureInterface-class.md +++ /dev/null @@ -1,139 +0,0 @@ - - - -# ApplyActionCodeFailureInterface class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown if during the apply action code process if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- ApplyActionCodeFailureInterface - - - -**Implementers** - -- [ApplyActionCodeFailureFirebase](../wyatt_authentication_bloc/ApplyActionCodeFailureFirebase-class.md) - - - - - -## Constructors - -[ApplyActionCodeFailureInterface](../wyatt_authentication_bloc/ApplyActionCodeFailureInterface/ApplyActionCodeFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - -Thrown if during the apply action code process if a failure occurs. - -[ApplyActionCodeFailureInterface.fromCode](../wyatt_authentication_bloc/ApplyActionCodeFailureInterface/ApplyActionCodeFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - -Thrown if during the apply action code process if a failure occurs. - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ApplyActionCodeFailureInterface/ApplyActionCodeFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ApplyActionCodeFailureInterface/ApplyActionCodeFailureInterface.fromCode.md deleted file mode 100644 index 72b11f2d..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ApplyActionCodeFailureInterface/ApplyActionCodeFailureInterface.fromCode.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# ApplyActionCodeFailureInterface.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -ApplyActionCodeFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - -

Thrown if during the apply action code process if a failure occurs.

- - - -## Implementation - -```dart -ApplyActionCodeFailureInterface.fromCode(super.code) : super.fromCode(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ApplyActionCodeFailureInterface/ApplyActionCodeFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ApplyActionCodeFailureInterface/ApplyActionCodeFailureInterface.md deleted file mode 100644 index 0fb17fe9..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ApplyActionCodeFailureInterface/ApplyActionCodeFailureInterface.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# ApplyActionCodeFailureInterface constructor - - - - - *[](https://dart.dev/null-safety)* - - - -ApplyActionCodeFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - - -

Thrown if during the apply action code process if a failure occurs.

- - - -## Implementation - -```dart -ApplyActionCodeFailureInterface(super.code, super.msg); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormField-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormField-class.md deleted file mode 100644 index 9ccd48b3..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormField-class.md +++ /dev/null @@ -1,122 +0,0 @@ - - - -# AuthFormField class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Default authentication form fields name

- - - - -## Constructors - -[AuthFormField](../wyatt_authentication_bloc/AuthFormField/AuthFormField.md) () - - - - -## Properties - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - -## Constants - -##### [confirmPassword](../wyatt_authentication_bloc/AuthFormField/confirmPassword-constant.md) const [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -Confirm Password field: wyattConfirmPasswordField - - - - -##### [email](../wyatt_authentication_bloc/AuthFormField/email-constant.md) const [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -Email field: wyattEmailField - - - - -##### [password](../wyatt_authentication_bloc/AuthFormField/password-constant.md) const [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -Password field: wyattPasswordField - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormField/AuthFormField.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormField/AuthFormField.md deleted file mode 100644 index ab98b830..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormField/AuthFormField.md +++ /dev/null @@ -1,25 +0,0 @@ - - - -# AuthFormField constructor - - - - - *[](https://dart.dev/null-safety)* - - - -AuthFormField() - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormField/confirmPassword-constant.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormField/confirmPassword-constant.md deleted file mode 100644 index 7b7ac157..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormField/confirmPassword-constant.md +++ /dev/null @@ -1,34 +0,0 @@ - - - -# confirmPassword constant - - - - - *[](https://dart.dev/null-safety)* - - - -[String](https://api.flutter.dev/flutter/dart-core/String-class.html) const confirmPassword - - - - - -

Confirm Password field: wyattConfirmPasswordField

- - - -## Implementation - -```dart -static const confirmPassword = 'wyattConfirmPasswordField'; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormField/email-constant.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormField/email-constant.md deleted file mode 100644 index 9d842070..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormField/email-constant.md +++ /dev/null @@ -1,34 +0,0 @@ - - - -# email constant - - - - - *[](https://dart.dev/null-safety)* - - - -[String](https://api.flutter.dev/flutter/dart-core/String-class.html) const email - - - - - -

Email field: wyattEmailField

- - - -## Implementation - -```dart -static const email = 'wyattEmailField'; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormField/password-constant.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormField/password-constant.md deleted file mode 100644 index 00dbfc9d..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormField/password-constant.md +++ /dev/null @@ -1,34 +0,0 @@ - - - -# password constant - - - - - *[](https://dart.dev/null-safety)* - - - -[String](https://api.flutter.dev/flutter/dart-core/String-class.html) const password - - - - - -

Password field: wyattPasswordField

- - - -## Implementation - -```dart -static const password = 'wyattPasswordField'; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormName-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormName-class.md deleted file mode 100644 index f1c34250..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormName-class.md +++ /dev/null @@ -1,131 +0,0 @@ - - - -# AuthFormName class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Default authentication form name

- - - - -## Constructors - -[AuthFormName](../wyatt_authentication_bloc/AuthFormName/AuthFormName.md) () - - - - -## Properties - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - -## Constants - -##### [editAccountForm](../wyatt_authentication_bloc/AuthFormName/editAccountForm-constant.md) const [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -Edit account form: wyattEditAccountForm - - - - -##### [passwordResetForm](../wyatt_authentication_bloc/AuthFormName/passwordResetForm-constant.md) const [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -Password reset form: wyattPasswordResetForm - - - - -##### [signInForm](../wyatt_authentication_bloc/AuthFormName/signInForm-constant.md) const [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -Sign In form: wyattSignInForm - - - - -##### [signUpForm](../wyatt_authentication_bloc/AuthFormName/signUpForm-constant.md) const [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -Sign Up form: wyattSignUpForm - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormName/AuthFormName.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormName/AuthFormName.md deleted file mode 100644 index 060a09c7..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormName/AuthFormName.md +++ /dev/null @@ -1,25 +0,0 @@ - - - -# AuthFormName constructor - - - - - *[](https://dart.dev/null-safety)* - - - -AuthFormName() - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormName/editAccountForm-constant.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormName/editAccountForm-constant.md deleted file mode 100644 index 87add4b3..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormName/editAccountForm-constant.md +++ /dev/null @@ -1,34 +0,0 @@ - - - -# editAccountForm constant - - - - - *[](https://dart.dev/null-safety)* - - - -[String](https://api.flutter.dev/flutter/dart-core/String-class.html) const editAccountForm - - - - - -

Edit account form: wyattEditAccountForm

- - - -## Implementation - -```dart -static const String editAccountForm = 'wyattEditAccountForm'; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormName/passwordResetForm-constant.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormName/passwordResetForm-constant.md deleted file mode 100644 index 0732203c..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormName/passwordResetForm-constant.md +++ /dev/null @@ -1,34 +0,0 @@ - - - -# passwordResetForm constant - - - - - *[](https://dart.dev/null-safety)* - - - -[String](https://api.flutter.dev/flutter/dart-core/String-class.html) const passwordResetForm - - - - - -

Password reset form: wyattPasswordResetForm

- - - -## Implementation - -```dart -static const String passwordResetForm = 'wyattPasswordResetForm'; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormName/signInForm-constant.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormName/signInForm-constant.md deleted file mode 100644 index b5863475..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormName/signInForm-constant.md +++ /dev/null @@ -1,34 +0,0 @@ - - - -# signInForm constant - - - - - *[](https://dart.dev/null-safety)* - - - -[String](https://api.flutter.dev/flutter/dart-core/String-class.html) const signInForm - - - - - -

Sign In form: wyattSignInForm

- - - -## Implementation - -```dart -static const String signInForm = 'wyattSignInForm'; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormName/signUpForm-constant.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormName/signUpForm-constant.md deleted file mode 100644 index 83820763..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthFormName/signUpForm-constant.md +++ /dev/null @@ -1,34 +0,0 @@ - - - -# signUpForm constant - - - - - *[](https://dart.dev/null-safety)* - - - -[String](https://api.flutter.dev/flutter/dart-core/String-class.html) const signUpForm - - - - - -

Sign Up form: wyattSignUpForm

- - - -## Implementation - -```dart -static const String signUpForm = 'wyattSignUpForm'; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationBuilder-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationBuilder-class.md deleted file mode 100644 index ba5fe7a2..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationBuilder-class.md +++ /dev/null @@ -1,216 +0,0 @@ - - - -# AuthenticationBuilder<Data> class - - - - - - - *[](https://dart.dev/null-safety)* - - - - - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [DiagnosticableTree](https://api.flutter.dev/flutter/foundation/DiagnosticableTree-class.html) -- [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) -- [StatelessWidget](https://api.flutter.dev/flutter/widgets/StatelessWidget-class.html) -- AuthenticationBuilder - - - - - - - - -## Constructors - -[AuthenticationBuilder](../wyatt_authentication_bloc/AuthenticationBuilder/AuthenticationBuilder.md) ({required [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) authenticated([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, [SessionWrapper](../wyatt_authentication_bloc/SessionWrapper-class.md)<Data> sessionWrapper), required [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) unauthenticated([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context), required [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) unknown([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context), [Key](https://api.flutter.dev/flutter/foundation/Key-class.html)? key}) - - _const_ - - -## Properties - -##### [authenticated](../wyatt_authentication_bloc/AuthenticationBuilder/authenticated.md) → [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, [SessionWrapper](../wyatt_authentication_bloc/SessionWrapper-class.md)<Data> sessionWrapper) - - - - -_final_ - - - -##### [hashCode](https://api.flutter.dev/flutter/widgets/Widget/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [key](https://api.flutter.dev/flutter/widgets/Widget/key.html) → [Key](https://api.flutter.dev/flutter/foundation/Key-class.html)? - - - -Controls how one widget replaces another widget in the tree. -_finalinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - -##### [unauthenticated](../wyatt_authentication_bloc/AuthenticationBuilder/unauthenticated.md) → [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context) - - - - -_final_ - - - -##### [unknown](../wyatt_authentication_bloc/AuthenticationBuilder/unknown.md) → [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context) - - - - -_final_ - - - - - -## Methods - -##### [build](../wyatt_authentication_bloc/AuthenticationBuilder/build.md)([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context) [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) - - - -Describes the part of the user interface represented by this widget. -_override_ - - - -##### [createElement](https://api.flutter.dev/flutter/widgets/StatelessWidget/createElement.html)() [StatelessElement](https://api.flutter.dev/flutter/widgets/StatelessElement-class.html) - - - -Creates a StatelessElement to manage this widget's location in the tree. -_inherited_ - - - -##### [debugDescribeChildren](https://api.flutter.dev/flutter/foundation/DiagnosticableTree/debugDescribeChildren.html)() [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[DiagnosticsNode](https://api.flutter.dev/flutter/foundation/DiagnosticsNode-class.html)> - - - -Returns a list of DiagnosticsNode objects describing this node's -children. -_inherited_ - - - -##### [debugFillProperties](https://api.flutter.dev/flutter/widgets/Widget/debugFillProperties.html)([DiagnosticPropertiesBuilder](https://api.flutter.dev/flutter/foundation/DiagnosticPropertiesBuilder-class.html) properties) void - - - -Add additional properties associated with the node. -_inherited_ - - - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toDiagnosticsNode](https://api.flutter.dev/flutter/foundation/DiagnosticableTree/toDiagnosticsNode.html)({[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? name, [DiagnosticsTreeStyle](https://api.flutter.dev/flutter/foundation/DiagnosticsTreeStyle.html)? style}) [DiagnosticsNode](https://api.flutter.dev/flutter/foundation/DiagnosticsNode-class.html) - - - -Returns a debug representation of the object that is used by debugging -tools and by DiagnosticsNode.toStringDeep. -_inherited_ - - - -##### [toString](https://api.flutter.dev/flutter/foundation/Diagnosticable/toString.html)({[DiagnosticLevel](https://api.flutter.dev/flutter/foundation/DiagnosticLevel.html) minLevel = DiagnosticLevel.info}) [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - -##### [toStringDeep](https://api.flutter.dev/flutter/foundation/DiagnosticableTree/toStringDeep.html)({[String](https://api.flutter.dev/flutter/dart-core/String-class.html) prefixLineOne = '', [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? prefixOtherLines, [DiagnosticLevel](https://api.flutter.dev/flutter/foundation/DiagnosticLevel.html) minLevel = DiagnosticLevel.debug}) [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -Returns a string representation of this node and its descendants. -_inherited_ - - - -##### [toStringShallow](https://api.flutter.dev/flutter/foundation/DiagnosticableTree/toStringShallow.html)({[String](https://api.flutter.dev/flutter/dart-core/String-class.html) joiner = ', ', [DiagnosticLevel](https://api.flutter.dev/flutter/foundation/DiagnosticLevel.html) minLevel = DiagnosticLevel.debug}) [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -Returns a one-line detailed description of the object. -_inherited_ - - - -##### [toStringShort](https://api.flutter.dev/flutter/widgets/Widget/toStringShort.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A short, textual description of this widget. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/widgets/Widget/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationBuilder/AuthenticationBuilder.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationBuilder/AuthenticationBuilder.md deleted file mode 100644 index 6fa6aa7d..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationBuilder/AuthenticationBuilder.md +++ /dev/null @@ -1,35 +0,0 @@ - - - -# AuthenticationBuilder<Data> constructor - - - - - *[](https://dart.dev/null-safety)* - - -const -AuthenticationBuilder<Data>({required [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) authenticated([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, [SessionWrapper](../../wyatt_authentication_bloc/SessionWrapper-class.md)<Data> sessionWrapper), required [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) unauthenticated([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context), required [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) unknown([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context), [Key](https://api.flutter.dev/flutter/foundation/Key-class.html)? key}) - - - - - -## Implementation - -```dart -const AuthenticationBuilder({ - required this.authenticated, - required this.unauthenticated, - required this.unknown, - super.key, -}); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationBuilder/authenticated.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationBuilder/authenticated.md deleted file mode 100644 index 421ea1b9..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationBuilder/authenticated.md +++ /dev/null @@ -1,36 +0,0 @@ - - - -# authenticated property - - - - - *[](https://dart.dev/null-safety)* - - - -[Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, [SessionWrapper](../../wyatt_authentication_bloc/SessionWrapper-class.md)<Data> sessionWrapper) authenticated - -_final_ - - - - - - -## Implementation - -```dart -final Widget Function( - BuildContext context, - SessionWrapper sessionWrapper, -) authenticated; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationBuilder/build.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationBuilder/build.md deleted file mode 100644 index 5b5680da..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationBuilder/build.md +++ /dev/null @@ -1,85 +0,0 @@ - - - -# build method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) build -([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context) - -_override_ - - - -

Describes the part of the user interface represented by this widget.

-

The framework calls this method when this widget is inserted into the tree -in a given BuildContext and when the dependencies of this widget change -(e.g., an InheritedWidget referenced by this widget changes). This -method can potentially be called in every frame and should not have any side -effects beyond building a widget.

-

The framework replaces the subtree below this widget with the widget -returned by this method, either by updating the existing subtree or by -removing the subtree and inflating a new subtree, depending on whether the -widget returned by this method can update the root of the existing -subtree, as determined by calling Widget.canUpdate.

-

Typically implementations return a newly created constellation of widgets -that are configured with information from this widget's constructor and -from the given BuildContext.

-

The given BuildContext contains information about the location in the -tree at which this widget is being built. For example, the context -provides the set of inherited widgets for this location in the tree. A -given widget might be built with multiple different BuildContext -arguments over time if the widget is moved around the tree or if the -widget is inserted into the tree in multiple places at once.

-

The implementation of this method must only depend on:

- -

If a widget's build method is to depend on anything else, use a -StatefulWidget instead.

-

See also:

-
    -
  • StatelessWidget, which contains the discussion on performance considerations.
  • -
- - - -## Implementation - -```dart -@override -Widget build(BuildContext context) => - BlocBuilder, AuthenticationState>( - builder: (context, state) { - if (state.status == AuthenticationStatus.authenticated) { - if (state.wrapper != null) { - return authenticated(context, state.wrapper!); - } else { - return unauthenticated(context); - } - } else if (state.status == AuthenticationStatus.unauthenticated) { - return unauthenticated(context); - } else { - return unknown(context); - } - }, - ); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationBuilder/unauthenticated.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationBuilder/unauthenticated.md deleted file mode 100644 index 09ac9fe3..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationBuilder/unauthenticated.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# unauthenticated property - - - - - *[](https://dart.dev/null-safety)* - - - -[Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context) unauthenticated - -_final_ - - - - - - -## Implementation - -```dart -final Widget Function(BuildContext context) unauthenticated; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationBuilder/unknown.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationBuilder/unknown.md deleted file mode 100644 index 4573308e..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationBuilder/unknown.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# unknown property - - - - - *[](https://dart.dev/null-safety)* - - - -[Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context) unknown - -_final_ - - - - - - -## Implementation - -```dart -final Widget Function(BuildContext context) unknown; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationChangeEvent-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationChangeEvent-class.md deleted file mode 100644 index 4cb045d8..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationChangeEvent-class.md +++ /dev/null @@ -1,137 +0,0 @@ - - - -# AuthenticationChangeEvent class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Represents an event initiated by a change in -the user's authentication status.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [Equatable](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable-class.html) -- AuthenticationChangeEvent - - - -**Implementers** - -- [DeletedEvent](../wyatt_authentication_bloc/DeletedEvent-class.md) -- [ReauthenticatedEvent](../wyatt_authentication_bloc/ReauthenticatedEvent-class.md) -- [RefreshedEvent](../wyatt_authentication_bloc/RefreshedEvent-class.md) -- [SignedInEvent](../wyatt_authentication_bloc/SignedInEvent-class.md) -- [SignedInFromCacheEvent](../wyatt_authentication_bloc/SignedInFromCacheEvent-class.md) -- [SignedOutEvent](../wyatt_authentication_bloc/SignedOutEvent-class.md) -- [SignedUpEvent](../wyatt_authentication_bloc/SignedUpEvent-class.md) -- [UnknownAuthenticationEvent](../wyatt_authentication_bloc/UnknownAuthenticationEvent-class.md) -- [UpdatedEvent](../wyatt_authentication_bloc/UpdatedEvent-class.md) - - - - - -## Constructors - -[AuthenticationChangeEvent](../wyatt_authentication_bloc/AuthenticationChangeEvent/AuthenticationChangeEvent.md) () - - _const_ - - -## Properties - -##### [hashCode](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [props](../wyatt_authentication_bloc/AuthenticationChangeEvent/props.md) → [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> - - - -The list of properties that will be used to determine whether -two instances are equal. -_read-onlyoverride_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - -##### [stringify](../wyatt_authentication_bloc/AuthenticationChangeEvent/stringify.md) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -If set to true, the toString method will be overridden to output -this instance's props. -_read-onlyoverride_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationChangeEvent/AuthenticationChangeEvent.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationChangeEvent/AuthenticationChangeEvent.md deleted file mode 100644 index 82567010..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationChangeEvent/AuthenticationChangeEvent.md +++ /dev/null @@ -1,30 +0,0 @@ - - - -# AuthenticationChangeEvent constructor - - - - - *[](https://dart.dev/null-safety)* - - -const -AuthenticationChangeEvent() - - - - - -## Implementation - -```dart -const AuthenticationChangeEvent(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationChangeEvent/props.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationChangeEvent/props.md deleted file mode 100644 index 35d92209..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationChangeEvent/props.md +++ /dev/null @@ -1,42 +0,0 @@ - - - -# props property - - - - - *[](https://dart.dev/null-safety)* - - - - - -**Annotations** - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) -[List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> props - -_override_ - - - -

The list of properties that will be used to determine whether -two instances are equal.

- - - -## Implementation - -```dart -@override -List get props => []; -``` - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationChangeEvent/stringify.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationChangeEvent/stringify.md deleted file mode 100644 index a2e1620f..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationChangeEvent/stringify.md +++ /dev/null @@ -1,47 +0,0 @@ - - - -# stringify property - - - - - *[](https://dart.dev/null-safety)* - - - - - -**Annotations** - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) -[bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) stringify - -_override_ - - - -

If set to true, the toString method will be overridden to output -this instance's props.

-

A global default value for stringify can be set using -EquatableConfig.stringify.

-

If this instance's stringify is set to null, the value of -EquatableConfig.stringify will be used instead. This defaults to -false.

- - - -## Implementation - -```dart -@override -bool get stringify => true; -``` - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit-class.md deleted file mode 100644 index 3758c56f..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit-class.md +++ /dev/null @@ -1,292 +0,0 @@ - - - -# AuthenticationCubit<Data> class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Abstract authentication cubit class needs to be implemented in application.

-

This cubit is in charge of managing the global authentication state of -the application.

-

Its here you can override every callbacks and add your custom logic.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [BlocBase](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase-class.html)<[AuthenticationState](../wyatt_authentication_bloc/AuthenticationState-class.md)<Data>> -- [Cubit](https://pub.dev/documentation/bloc/8.1.0/bloc/Cubit-class.html)<[AuthenticationState](../wyatt_authentication_bloc/AuthenticationState-class.md)<Data>> -- AuthenticationCubit - - - - - - - - -## Constructors - -[AuthenticationCubit](../wyatt_authentication_bloc/AuthenticationCubit/AuthenticationCubit.md) ({required [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> authenticationRepository}) - - - - -## Properties - -##### [authenticationRepository](../wyatt_authentication_bloc/AuthenticationCubit/authenticationRepository.md) → [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> - - - - -_final_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [isClosed](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/isClosed.html) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -Whether the bloc is closed. -_read-onlyinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - -##### [state](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/state.html) → [AuthenticationState](../wyatt_authentication_bloc/AuthenticationState-class.md)<Data> - - - -The current state. -_read-onlyinherited_ - - - -##### [stream](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/stream.html) → [Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[AuthenticationState](../wyatt_authentication_bloc/AuthenticationState-class.md)<Data>> - - - -The current stream of states. -_read-onlyinherited_ - - - - - -## Methods - -##### [addError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/addError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [[StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html)? stackTrace]) void - - - -Reports an error which triggers onError with an optional StackTrace. -_inherited_ - - - -##### [close](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/close.html)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> - - - -Closes the instance. -This method should be called when the instance is no longer needed. -Once close is called, the instance can no longer be used. -_inherited_ - - - -##### [currentSession](../wyatt_authentication_bloc/AuthenticationCubit/currentSession.md)() [SessionWrapper](../wyatt_authentication_bloc/SessionWrapper-class.md)<Data>? - - - -Returns latest session wrapper. - - - - -##### [delete](../wyatt_authentication_bloc/AuthenticationCubit/delete.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - -Delete account. - - - - -##### [emit](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/emit.html)([AuthenticationState](../wyatt_authentication_bloc/AuthenticationState-class.md)<Data> state) void - - - -Updates the state to the provided state. -emit does nothing if the state being emitted -is equal to the current state. -_inherited_ - - - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [onChange](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onChange.html)([Change](https://pub.dev/documentation/bloc/8.1.0/bloc/Change-class.html)<[AuthenticationState](../wyatt_authentication_bloc/AuthenticationState-class.md)<Data>> change) void - - - -Called whenever a change occurs with the given change. -A change occurs when a new state is emitted. -onChange is called before the state of the cubit is updated. -onChange is a great spot to add logging/analytics for a specific cubit. -_inherited_ - - - -##### [onDelete](../wyatt_authentication_bloc/AuthenticationCubit/onDelete.md)() FutureOrResult<void> - - - -This callback is triggered when the current account is deleted from -the remote. - - - - -##### [onError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html) stackTrace) void - - - -Called whenever an error occurs and notifies BlocObserver.onError. -_inherited_ - - - -##### [onReauthenticate](../wyatt_authentication_bloc/AuthenticationCubit/onReauthenticate.md)(Result<[Account](../wyatt_authentication_bloc/Account-class.md), AppException> result) FutureOrResult<Data?> - - - -This callback is triggered when the account is re-authenticated - - - - -##### [onRefresh](../wyatt_authentication_bloc/AuthenticationCubit/onRefresh.md)(Result<[Account](../wyatt_authentication_bloc/Account-class.md), AppException> result) FutureOrResult<Data?> - - - -This callback is triggered when the account is refreshed. - - - - -##### [onSignInFromCache](../wyatt_authentication_bloc/AuthenticationCubit/onSignInFromCache.md)([SessionWrapper](../wyatt_authentication_bloc/SessionWrapper-class.md)<Data> wrapper) FutureOrResult<Data?> - - - -This callback is triggered when the user is automaticcaly logged in from -the cache. - - - - -##### [onSignOut](../wyatt_authentication_bloc/AuthenticationCubit/onSignOut.md)() FutureOrResult<void> - - - -This callback is triggered when the user is logged out. - - - - -##### [reauthenticate](../wyatt_authentication_bloc/AuthenticationCubit/reauthenticate.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - -Some security-sensitive actions—such as deleting an account, -setting a primary email address, and changing a password—require that -the user has recently signed in. - - - - -##### [refresh](../wyatt_authentication_bloc/AuthenticationCubit/refresh.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - -Refreshes the current user, if signed in. - - - - -##### [signOut](../wyatt_authentication_bloc/AuthenticationCubit/signOut.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - -Signs out the current user. -It also clears the cache and the associated data. - - - - -##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/AuthenticationCubit.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/AuthenticationCubit.md deleted file mode 100644 index 8a689e53..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/AuthenticationCubit.md +++ /dev/null @@ -1,34 +0,0 @@ - - - -# AuthenticationCubit<Data> constructor - - - - - *[](https://dart.dev/null-safety)* - - - -AuthenticationCubit<Data>({required [AuthenticationRepository](../../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> authenticationRepository}) - - - - - -## Implementation - -```dart -AuthenticationCubit({ - required this.authenticationRepository, -}) : super(const AuthenticationState.unknown()) { - _listenForAuthenticationChanges(); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/authenticationRepository.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/authenticationRepository.md deleted file mode 100644 index 32cdfa2a..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/authenticationRepository.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# authenticationRepository property - - - - - *[](https://dart.dev/null-safety)* - - - -[AuthenticationRepository](../../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> authenticationRepository - -_final_ - - - - - - -## Implementation - -```dart -final AuthenticationRepository authenticationRepository; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/currentSession.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/currentSession.md deleted file mode 100644 index 855d8d0e..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/currentSession.md +++ /dev/null @@ -1,37 +0,0 @@ - - - -# currentSession method - - - - - *[](https://dart.dev/null-safety)* - - - - -[SessionWrapper](../../wyatt_authentication_bloc/SessionWrapper-class.md)<Data>? currentSession -() - - - - - -

Returns latest session wrapper.

-

Contains latest event and latest session data (account + extra data)

- - - -## Implementation - -```dart -SessionWrapper? currentSession() => _latestSession; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/delete.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/delete.md deleted file mode 100644 index 849e1aca..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/delete.md +++ /dev/null @@ -1,44 +0,0 @@ - - - -# delete method - - - - - *[](https://dart.dev/null-safety)* - - - - -[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> delete -() - - - - - -

Delete account.

-

Throws a DeleteAccountFailureInterface if -an exception occurs.

- - - -## Implementation - -```dart -FutureOr delete() async => CustomRoutine( - routine: authenticationRepository.delete, - attachedLogic: (routineResult) => onDelete(), - onError: addError, - onSuccess: (result, data) => authenticationRepository - .addSession(SessionWrapper(event: const DeletedEvent())), - ).call(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/onDelete.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/onDelete.md deleted file mode 100644 index b5fd50a4..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/onDelete.md +++ /dev/null @@ -1,38 +0,0 @@ - - - -# onDelete method - - - - - *[](https://dart.dev/null-safety)* - - - - -FutureOrResult<void> onDelete -() - - - - - -

This callback is triggered when the current account is deleted from -the remote.

-

For example: when the user wants to delete his account from Firebase

- - - -## Implementation - -```dart -FutureOrResult onDelete(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/onReauthenticate.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/onReauthenticate.md deleted file mode 100644 index 434c5de1..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/onReauthenticate.md +++ /dev/null @@ -1,38 +0,0 @@ - - - -# onReauthenticate method - - - - - *[](https://dart.dev/null-safety)* - - - - -FutureOrResult<Data?> onReauthenticate -(Result<[Account](../../wyatt_authentication_bloc/Account-class.md), AppException> result) - - - - - -

This callback is triggered when the account is re-authenticated

-

For example: when the user is logged in and sign in -from an another provider

- - - -## Implementation - -```dart -FutureOrResult onReauthenticate(Result result); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/onRefresh.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/onRefresh.md deleted file mode 100644 index b3812fa8..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/onRefresh.md +++ /dev/null @@ -1,37 +0,0 @@ - - - -# onRefresh method - - - - - *[](https://dart.dev/null-safety)* - - - - -FutureOrResult<Data?> onRefresh -(Result<[Account](../../wyatt_authentication_bloc/Account-class.md), AppException> result) - - - - - -

This callback is triggered when the account is refreshed.

-

For example: when the access token is refreshed.

- - - -## Implementation - -```dart -FutureOrResult onRefresh(Result result); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/onSignInFromCache.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/onSignInFromCache.md deleted file mode 100644 index 3f0ccf94..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/onSignInFromCache.md +++ /dev/null @@ -1,38 +0,0 @@ - - - -# onSignInFromCache method - - - - - *[](https://dart.dev/null-safety)* - - - - -FutureOrResult<Data?> onSignInFromCache -([SessionWrapper](../../wyatt_authentication_bloc/SessionWrapper-class.md)<Data> wrapper) - - - - - -

This callback is triggered when the user is automaticcaly logged in from -the cache.

-

For example: when the user is sign in from the Firebase cache.

- - - -## Implementation - -```dart -FutureOrResult onSignInFromCache(SessionWrapper wrapper); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/onSignOut.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/onSignOut.md deleted file mode 100644 index 930d66b7..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/onSignOut.md +++ /dev/null @@ -1,37 +0,0 @@ - - - -# onSignOut method - - - - - *[](https://dart.dev/null-safety)* - - - - -FutureOrResult<void> onSignOut -() - - - - - -

This callback is triggered when the user is logged out.

-

For example: when the user clicks on the logout button.

- - - -## Implementation - -```dart -FutureOrResult onSignOut(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/reauthenticate.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/reauthenticate.md deleted file mode 100644 index b2eeb9c5..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/reauthenticate.md +++ /dev/null @@ -1,53 +0,0 @@ - - - -# reauthenticate method - - - - - *[](https://dart.dev/null-safety)* - - - - -[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> reauthenticate -() - - - - - -

Some security-sensitive actions—such as deleting an account, -setting a primary email address, and changing a password—require that -the user has recently signed in.

-

Throws a ReauthenticateFailureInterface if -an exception occurs.

- - - -## Implementation - -```dart -FutureOr reauthenticate() async => CustomRoutine( - routine: authenticationRepository.reauthenticate, - attachedLogic: onReauthenticate, - onError: addError, - onSuccess: (result, data) => authenticationRepository.addSession( - SessionWrapper( - event: ReauthenticatedEvent(account: result), - session: Session( - account: result, - data: data, - ), - ), - ), - ).call(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/refresh.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/refresh.md deleted file mode 100644 index be643224..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/refresh.md +++ /dev/null @@ -1,49 +0,0 @@ - - - -# refresh method - - - - - *[](https://dart.dev/null-safety)* - - - - -[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> refresh -() - - - - - -

Refreshes the current user, if signed in.

- - - -## Implementation - -```dart -FutureOr refresh() async => CustomRoutine( - routine: authenticationRepository.refresh, - attachedLogic: onRefresh, - onError: addError, - onSuccess: (result, data) => authenticationRepository.addSession( - SessionWrapper( - event: RefreshedEvent(account: result), - session: Session( - account: result, - data: data, - ), - ), - ), - ).call(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/signOut.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/signOut.md deleted file mode 100644 index f2634117..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationCubit/signOut.md +++ /dev/null @@ -1,43 +0,0 @@ - - - -# signOut method - - - - - *[](https://dart.dev/null-safety)* - - - - -[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> signOut -() - - - - - -

Signs out the current user. -It also clears the cache and the associated data.

- - - -## Implementation - -```dart -FutureOr signOut() async => CustomRoutine( - routine: authenticationRepository.signOut, - attachedLogic: (routineResult) => onSignOut(), - onError: addError, - onSuccess: (result, data) => authenticationRepository - .addSession(SessionWrapper(event: const SignedOutEvent())), - ).call(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface-class.md deleted file mode 100644 index 36c265c0..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface-class.md +++ /dev/null @@ -1,159 +0,0 @@ - - - -# AuthenticationFailureInterface class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Base exception used in Wyatt Authentication

- - - - -**Implemented types** - -- [Exception](https://api.flutter.dev/flutter/dart-core/Exception-class.html) - - -**Implementers** - -- [ApplyActionCodeFailureInterface](../wyatt_authentication_bloc/ApplyActionCodeFailureInterface-class.md) -- [ConfirmPasswordResetFailureInterface](../wyatt_authentication_bloc/ConfirmPasswordResetFailureInterface-class.md) -- [DeleteAccountFailureInterface](../wyatt_authentication_bloc/DeleteAccountFailureInterface-class.md) -- [FetchSignInMethodsForEmailFailureInterface](../wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureInterface-class.md) -- [ModelParsingFailureInterface](../wyatt_authentication_bloc/ModelParsingFailureInterface-class.md) -- [ReauthenticateFailureInterface](../wyatt_authentication_bloc/ReauthenticateFailureInterface-class.md) -- [RefreshFailureInterface](../wyatt_authentication_bloc/RefreshFailureInterface-class.md) -- [SendEmailVerificationFailureInterface](../wyatt_authentication_bloc/SendEmailVerificationFailureInterface-class.md) -- [SendPasswordResetEmailFailureInterface](../wyatt_authentication_bloc/SendPasswordResetEmailFailureInterface-class.md) -- [SendSignInLinkEmailFailureInterface](../wyatt_authentication_bloc/SendSignInLinkEmailFailureInterface-class.md) -- [SignInAnonymouslyFailureInterface](../wyatt_authentication_bloc/SignInAnonymouslyFailureInterface-class.md) -- [SignInWithAppleFailureInterface](../wyatt_authentication_bloc/SignInWithAppleFailureInterface-class.md) -- [SignInWithCredentialFailureInterface](../wyatt_authentication_bloc/SignInWithCredentialFailureInterface-class.md) -- [SignInWithEmailAndPasswordFailureInterface](../wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureInterface-class.md) -- [SignInWithEmailLinkFailureInterface](../wyatt_authentication_bloc/SignInWithEmailLinkFailureInterface-class.md) -- [SignInWithFacebookFailureInterface](../wyatt_authentication_bloc/SignInWithFacebookFailureInterface-class.md) -- [SignInWithGoogleFailureInterface](../wyatt_authentication_bloc/SignInWithGoogleFailureInterface-class.md) -- [SignInWithTwitterFailureInterface](../wyatt_authentication_bloc/SignInWithTwitterFailureInterface-class.md) -- [SignOutFailureInterface](../wyatt_authentication_bloc/SignOutFailureInterface-class.md) -- [SignUpWithEmailAndPasswordFailureInterface](../wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureInterface-class.md) -- [UpdateEmailFailureInterface](../wyatt_authentication_bloc/UpdateEmailFailureInterface-class.md) -- [UpdatePasswordFailureInterface](../wyatt_authentication_bloc/UpdatePasswordFailureInterface-class.md) -- [VerifyPasswordResetCodeFailureInterface](../wyatt_authentication_bloc/VerifyPasswordResetCodeFailureInterface-class.md) - - - - - -## Constructors - -[AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface/AuthenticationFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - - - -[AuthenticationFailureInterface.fromCode](../wyatt_authentication_bloc/AuthenticationFailureInterface/AuthenticationFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / write_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-only_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / write_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface/AuthenticationFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface/AuthenticationFailureInterface.fromCode.md deleted file mode 100644 index 96605d88..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface/AuthenticationFailureInterface.fromCode.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# AuthenticationFailureInterface.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -AuthenticationFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - - -## Implementation - -```dart -AuthenticationFailureInterface.fromCode(this.code) - : msg = 'An unknown error occurred.'; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface/AuthenticationFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface/AuthenticationFailureInterface.md deleted file mode 100644 index b64683e8..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface/AuthenticationFailureInterface.md +++ /dev/null @@ -1,30 +0,0 @@ - - - -# AuthenticationFailureInterface constructor - - - - - *[](https://dart.dev/null-safety)* - - - -AuthenticationFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - - - - - -## Implementation - -```dart -AuthenticationFailureInterface(this.code, this.msg); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface/code.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface/code.md deleted file mode 100644 index 7d6e8996..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface/code.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# code property - - - - - *[](https://dart.dev/null-safety)* - - - -[String](https://api.flutter.dev/flutter/dart-core/String-class.html) code - -_read / write_ - - - - - - -## Implementation - -```dart -String code; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface/message.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface/message.md deleted file mode 100644 index fed51258..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface/message.md +++ /dev/null @@ -1,40 +0,0 @@ - - - -# message property - - - - - *[](https://dart.dev/null-safety)* - - - - - -**Annotations** - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) -[String](https://api.flutter.dev/flutter/dart-core/String-class.html) message - - - - - - - - -## Implementation - -```dart -@override -String get message => msg; -``` - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md deleted file mode 100644 index 820911a4..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# msg property - - - - - *[](https://dart.dev/null-safety)* - - - -[String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg - -_read / write_ - - - - - - -## Implementation - -```dart -String msg; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md deleted file mode 100644 index adf014b9..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md +++ /dev/null @@ -1,53 +0,0 @@ - - - -# toString method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[String](https://api.flutter.dev/flutter/dart-core/String-class.html) toString -() - -_inherited_ - - - -

A string representation of this object.

-

Some classes have a default textual representation, -often paired with a static parse function (like int.parse). -These classes will provide the textual representation as -their string representation.

-

Other classes have no meaningful textual representation -that a program will care about. -Such classes will typically override toString to provide -useful information when inspecting the object, -mainly for debugging or logging.

- - - -## Implementation - -```dart -@override -String toString() { - if (message.isNotNullOrEmpty) { - return '$runtimeType: $message'; - } else { - return '$runtimeType: An exception occured'; - } -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl-class.md deleted file mode 100644 index 39635ba2..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl-class.md +++ /dev/null @@ -1,251 +0,0 @@ - - - -# AuthenticationFirebaseDataSourceImpl<Data> class - - - - - - - *[](https://dart.dev/null-safety)* - - - - - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationRemoteDataSource](../wyatt_authentication_bloc/AuthenticationRemoteDataSource-class.md)<Data> -- AuthenticationFirebaseDataSourceImpl - - - - - - - - -## Constructors - -[AuthenticationFirebaseDataSourceImpl](../wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/AuthenticationFirebaseDataSourceImpl.md) ({[FirebaseAuth](https://pub.dev/documentation/firebase_auth/4.2.0/firebase_auth/FirebaseAuth-class.html)? firebaseAuth, [GoogleSignIn](https://pub.dev/documentation/google_sign_in/5.4.2/google_sign_in/GoogleSignIn-class.html)? googleSignIn}) - - - - -## Properties - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [addSession](../wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/addSession.md)([SessionWrapper](../wyatt_authentication_bloc/SessionWrapper-class.md)<Data> wrapper) void - - - -Add a new authentication event. -_override_ - - - -##### [confirmPasswordReset](../wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/confirmPasswordReset.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) newPassword}) [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> - - - -Confirms the password reset with the provided newPassword and code. -_override_ - - - -##### [delete](../wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/delete.md)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> - - - -Delete account. -_override_ - - - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [reauthenticate](../wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/reauthenticate.md)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../wyatt_authentication_bloc/Account-class.md)> - - - -Some security-sensitive actions—such as deleting an account, -setting a primary email address, and changing a password—require that -the user has recently signed in. -_override_ - - - -##### [refresh](../wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/refresh.md)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../wyatt_authentication_bloc/Account-class.md)> - - - -Refreshes the current user, if signed in. -_override_ - - - -##### [sendEmailVerification](../wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/sendEmailVerification.md)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> - - - -Sends verification email to the account email. -_override_ - - - -##### [sendPasswordResetEmail](../wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/sendPasswordResetEmail.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email}) [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> - - - -Sends a password reset email to the provided email. -_override_ - - - -##### [sessionStream](../wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/sessionStream.md)() [Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[SessionWrapper](../wyatt_authentication_bloc/SessionWrapper-class.md)<Data>> - - - -Authentication state change event stream. -_override_ - - - -##### [signInAnonymously](../wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signInAnonymously.md)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../wyatt_authentication_bloc/Account-class.md)> - - - -Sign in anonymously. -_override_ - - - -##### [signInWithEmailAndPassword](../wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signInWithEmailAndPassword.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../wyatt_authentication_bloc/Account-class.md)> - - - -Signs in with the provided email and password. -_override_ - - - -##### [signInWithGoogle](../wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signInWithGoogle.md)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../wyatt_authentication_bloc/Account-class.md)> - - - -Starts the Sign In with Google Flow. -_override_ - - - -##### [signOut](../wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signOut.md)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> - - - -Signs out the current user. -It also clears the cache and the associated data. -_override_ - - - -##### [signUpWithEmailAndPassword](../wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signUpWithEmailAndPassword.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../wyatt_authentication_bloc/Account-class.md)> - - - -Creates a new user with the provided email and password. -_override_ - - - -##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - -##### [updateEmail](../wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/updateEmail.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email}) [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../wyatt_authentication_bloc/Account-class.md)> - - - -Update or add email. -_override_ - - - -##### [updatePassword](../wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/updatePassword.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../wyatt_authentication_bloc/Account-class.md)> - - - -Update or add password. -_override_ - - - -##### [verifyPasswordResetCode](../wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/verifyPasswordResetCode.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) code}) [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)> - - - -Verify password reset code. -_override_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/AuthenticationFirebaseDataSourceImpl.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/AuthenticationFirebaseDataSourceImpl.md deleted file mode 100644 index d6364dcf..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/AuthenticationFirebaseDataSourceImpl.md +++ /dev/null @@ -1,40 +0,0 @@ - - - -# AuthenticationFirebaseDataSourceImpl<Data> constructor - - - - - *[](https://dart.dev/null-safety)* - - - -AuthenticationFirebaseDataSourceImpl<Data>({[FirebaseAuth](https://pub.dev/documentation/firebase_auth/4.2.0/firebase_auth/FirebaseAuth-class.html)? firebaseAuth, [GoogleSignIn](https://pub.dev/documentation/google_sign_in/5.4.2/google_sign_in/GoogleSignIn-class.html)? googleSignIn}) - - - - - -## Implementation - -```dart -AuthenticationFirebaseDataSourceImpl({ - FirebaseAuth? firebaseAuth, - GoogleSignIn? googleSignIn, -}) : _firebaseAuth = firebaseAuth ?? FirebaseAuth.instance, - _googleSignIn = googleSignIn ?? GoogleSignIn() { - _latestCredentials = BehaviorSubject(); - _sessionStream = BehaviorSubject(); - - // Check for account in memory (persistence) - _checkForCachedAccount(); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/addSession.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/addSession.md deleted file mode 100644 index adb9c34d..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/addSession.md +++ /dev/null @@ -1,40 +0,0 @@ - - - -# addSession method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -void addSession -([SessionWrapper](../../wyatt_authentication_bloc/SessionWrapper-class.md)<Data> wrapper) - -_override_ - - - -

Add a new authentication event.

- - - -## Implementation - -```dart -@override -void addSession(SessionWrapper wrapper) { - _sessionStream.add(wrapper); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/confirmPasswordReset.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/confirmPasswordReset.md deleted file mode 100644 index 5be2ed73..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/confirmPasswordReset.md +++ /dev/null @@ -1,53 +0,0 @@ - - - -# confirmPasswordReset method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> confirmPasswordReset -({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) newPassword}) - -_override_ - - - -

Confirms the password reset with the provided newPassword and code.

-

Throws a ConfirmPasswordResetFailureInterface if an exception occurs.

- - - -## Implementation - -```dart -@override -Future confirmPasswordReset({ - required String code, - required String newPassword, -}) async { - try { - await _firebaseAuth.confirmPasswordReset( - code: code, - newPassword: newPassword, - ); - } on FirebaseAuthException catch (e) { - throw ConfirmPasswordResetFailureFirebase.fromCode(e.code); - } catch (_) { - throw ConfirmPasswordResetFailureFirebase(); - } -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/delete.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/delete.md deleted file mode 100644 index 64729914..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/delete.md +++ /dev/null @@ -1,48 +0,0 @@ - - - -# delete method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> delete -() - -_override_ - - - -

Delete account.

-

Throws a DeleteAccountFailureInterface if -an exception occurs.

- - - -## Implementation - -```dart -@override -Future delete() async { - try { - await _firebaseAuth.currentUser!.delete(); - } on FirebaseAuthException catch (e) { - throw DeleteAccountFailureFirebase.fromCode(e.code); - } catch (_) { - throw DeleteAccountFailureFirebase(); - } -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/reauthenticate.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/reauthenticate.md deleted file mode 100644 index 244efea5..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/reauthenticate.md +++ /dev/null @@ -1,61 +0,0 @@ - - - -# reauthenticate method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../../wyatt_authentication_bloc/Account-class.md)> reauthenticate -() - -_override_ - - - -

Some security-sensitive actions—such as deleting an account, -setting a primary email address, and changing a password—require that -the user has recently signed in.

-

Throws a ReauthenticateFailureInterface if -an exception occurs.

- - - -## Implementation - -```dart -@override -Future reauthenticate() async { - final latestCreds = - await _latestCredentials.stream.asBroadcastStream().last; - try { - if (latestCreds?.credential != null) { - await _firebaseAuth.currentUser - ?.reauthenticateWithCredential(latestCreds!.credential!); - } else { - throw Exception(); // Get caught just after. - } - - final account = AccountModel.fromFirebaseUser(_firebaseAuth.currentUser); - - return account; - } on FirebaseAuthException catch (e) { - throw ReauthenticateFailureFirebase.fromCode(e.code); - } catch (_) { - throw ReauthenticateFailureFirebase(); - } -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/refresh.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/refresh.md deleted file mode 100644 index 323f75a1..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/refresh.md +++ /dev/null @@ -1,52 +0,0 @@ - - - -# refresh method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../../wyatt_authentication_bloc/Account-class.md)> refresh -() - -_override_ - - - -

Refreshes the current user, if signed in.

- - - -## Implementation - -```dart -@override -Future refresh() async { - try { - final jwt = await _firebaseAuth.currentUser?.getIdToken(true); - final account = AccountModel.fromFirebaseUser( - _firebaseAuth.currentUser, - accessToken: jwt, - ); - - return account; - } on FirebaseAuthException catch (e) { - throw RefreshFailureFirebase.fromCode(e.code); - } catch (_) { - throw RefreshFailureFirebase(); - } -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/sendEmailVerification.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/sendEmailVerification.md deleted file mode 100644 index 36e3bde4..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/sendEmailVerification.md +++ /dev/null @@ -1,47 +0,0 @@ - - - -# sendEmailVerification method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> sendEmailVerification -() - -_override_ - - - -

Sends verification email to the account email.

-

Throws a SendEmailVerificationFailureInterface if an exception occurs.

- - - -## Implementation - -```dart -@override -Future sendEmailVerification() async { - try { - await _firebaseAuth.currentUser!.sendEmailVerification(); - } on FirebaseAuthException catch (e) { - throw SendEmailVerificationFailureFirebase.fromCode(e.code); - } catch (_) { - throw SendEmailVerificationFailureFirebase(); - } -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/sendPasswordResetEmail.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/sendPasswordResetEmail.md deleted file mode 100644 index 44ab9cd1..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/sendPasswordResetEmail.md +++ /dev/null @@ -1,47 +0,0 @@ - - - -# sendPasswordResetEmail method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> sendPasswordResetEmail -({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email}) - -_override_ - - - -

Sends a password reset email to the provided email.

-

Throws a SendPasswordResetEmailFailureInterface if an exception occurs.

- - - -## Implementation - -```dart -@override -Future sendPasswordResetEmail({required String email}) async { - try { - await _firebaseAuth.sendPasswordResetEmail(email: email); - } on FirebaseAuthException catch (e) { - throw SendPasswordResetEmailFailureFirebase.fromCode(e.code); - } catch (_) { - throw SendPasswordResetEmailFailureFirebase(); - } -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/sessionStream.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/sessionStream.md deleted file mode 100644 index d2bd33ab..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/sessionStream.md +++ /dev/null @@ -1,39 +0,0 @@ - - - -# sessionStream method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[SessionWrapper](../../wyatt_authentication_bloc/SessionWrapper-class.md)<Data>> sessionStream -() - -_override_ - - - -

Authentication state change event stream.

- - - -## Implementation - -```dart -@override -Stream> sessionStream() => - _sessionStream.stream.asBroadcastStream(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signInAnonymously.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signInAnonymously.md deleted file mode 100644 index 80bef88a..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signInAnonymously.md +++ /dev/null @@ -1,54 +0,0 @@ - - - -# signInAnonymously method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../../wyatt_authentication_bloc/Account-class.md)> signInAnonymously -() - -_override_ - - - -

Sign in anonymously.

-

Throws a SignInAnonymouslyFailureInterface if an exception occurs.

- - - -## Implementation - -```dart -@override -Future signInAnonymously() async { - try { - final userCredential = await _firebaseAuth.signInAnonymously(); - - return _addToStream( - userCredential, - (account) => SignedInEvent( - account: account, - ), - ); - } on FirebaseAuthException catch (e) { - throw SignInAnonymouslyFailureFirebase.fromCode(e.code); - } catch (_) { - throw SignInAnonymouslyFailureFirebase(); - } -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signInWithEmailAndPassword.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signInWithEmailAndPassword.md deleted file mode 100644 index 0303cc78..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signInWithEmailAndPassword.md +++ /dev/null @@ -1,61 +0,0 @@ - - - -# signInWithEmailAndPassword method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../../wyatt_authentication_bloc/Account-class.md)> signInWithEmailAndPassword -({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) - -_override_ - - - -

Signs in with the provided email and password.

-

Throws a SignInWithEmailAndPasswordFailureInterface if -an exception occurs.

- - - -## Implementation - -```dart -@override -Future signInWithEmailAndPassword({ - required String email, - required String password, -}) async { - try { - final userCredential = await _firebaseAuth.signInWithEmailAndPassword( - email: email, - password: password, - ); - - return _addToStream( - userCredential, - (account) => SignedInEvent( - account: account, - ), - ); - } on FirebaseAuthException catch (e) { - throw SignInWithEmailAndPasswordFailureFirebase.fromCode(e.code); - } catch (_) { - throw SignInWithEmailAndPasswordFailureFirebase(); - } -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signInWithGoogle.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signInWithGoogle.md deleted file mode 100644 index a8e00d8f..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signInWithGoogle.md +++ /dev/null @@ -1,68 +0,0 @@ - - - -# signInWithGoogle method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../../wyatt_authentication_bloc/Account-class.md)> signInWithGoogle -() - -_override_ - - - -

Starts the Sign In with Google Flow.

-

Throws a SignInWithGoogleFailureInterface if an exception occurs.

- - - -## Implementation - -```dart -@override -Future signInWithGoogle() async { - try { - // Trigger the authentication flow - final GoogleSignInAccount? googleUser = await _googleSignIn.signIn(); - - // Obtain the auth details from the request - final GoogleSignInAuthentication? googleAuth = - await googleUser?.authentication; - - // Create a new credential - final credential = GoogleAuthProvider.credential( - accessToken: googleAuth?.accessToken, - idToken: googleAuth?.idToken, - ); - - final userCredential = - await _firebaseAuth.signInWithCredential(credential); - - return _addToStream( - userCredential, - (account) => SignedInEvent( - account: account, - ), - ); - } on FirebaseAuthException catch (e) { - throw SignInWithGoogleFailureFirebase.fromCode(e.code); - } catch (_) { - throw SignInWithGoogleFailureFirebase(); - } -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signOut.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signOut.md deleted file mode 100644 index 8e648e71..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signOut.md +++ /dev/null @@ -1,46 +0,0 @@ - - - -# signOut method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> signOut -() - -_override_ - - - -

Signs out the current user. -It also clears the cache and the associated data.

- - - -## Implementation - -```dart -@override -Future signOut() async { - try { - _latestCredentials.add(null); - await _firebaseAuth.signOut(); - } catch (_) { - throw SignOutFailureFirebase(); - } -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signUpWithEmailAndPassword.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signUpWithEmailAndPassword.md deleted file mode 100644 index 4c81f5e2..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/signUpWithEmailAndPassword.md +++ /dev/null @@ -1,62 +0,0 @@ - - - -# signUpWithEmailAndPassword method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../../wyatt_authentication_bloc/Account-class.md)> signUpWithEmailAndPassword -({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) - -_override_ - - - -

Creates a new user with the provided email and password.

-

Returns the newly created user's unique identifier.

-

Throws a SignUpWithEmailAndPasswordFailureInterface if -an exception occurs.

- - - -## Implementation - -```dart -@override -Future signUpWithEmailAndPassword({ - required String email, - required String password, -}) async { - try { - final userCredential = await _firebaseAuth.createUserWithEmailAndPassword( - email: email, - password: password, - ); - - return _addToStream( - userCredential, - (account) => SignedUpEvent( - account: account, - ), - ); - } on FirebaseAuthException catch (e) { - throw SignUpWithEmailAndPasswordFailureFirebase.fromCode(e.code); - } catch (_) { - throw SignUpWithEmailAndPasswordFailureFirebase(); - } -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/updateEmail.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/updateEmail.md deleted file mode 100644 index 11399787..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/updateEmail.md +++ /dev/null @@ -1,55 +0,0 @@ - - - -# updateEmail method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../../wyatt_authentication_bloc/Account-class.md)> updateEmail -({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email}) - -_override_ - - - -

Update or add email.

-

Throws a UpdateEmailFailureInterface if -an exception occurs.

- - - -## Implementation - -```dart -@override -Future updateEmail({required String email}) async { - try { - await _firebaseAuth.currentUser!.updateEmail(email); - final jwt = await _firebaseAuth.currentUser!.getIdToken(true); - final account = AccountModel.fromFirebaseUser( - _firebaseAuth.currentUser, - accessToken: jwt, - ); - - return account; - } on FirebaseAuthException catch (e) { - throw UpdateEmailFailureFirebase.fromCode(e.code); - } catch (_) { - throw UpdateEmailFailureFirebase(); - } -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/updatePassword.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/updatePassword.md deleted file mode 100644 index be85ed32..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/updatePassword.md +++ /dev/null @@ -1,55 +0,0 @@ - - - -# updatePassword method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../../wyatt_authentication_bloc/Account-class.md)> updatePassword -({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) - -_override_ - - - -

Update or add password.

-

Throws a UpdatePasswordFailureInterface if -an exception occurs.

- - - -## Implementation - -```dart -@override -Future updatePassword({required String password}) async { - try { - await _firebaseAuth.currentUser!.updatePassword(password); - final jwt = await _firebaseAuth.currentUser!.getIdToken(true); - final account = AccountModel.fromFirebaseUser( - _firebaseAuth.currentUser, - accessToken: jwt, - ); - - return account; - } on FirebaseAuthException catch (e) { - throw UpdatePasswordFailureFirebase.fromCode(e.code); - } catch (_) { - throw UpdatePasswordFailureFirebase(); - } -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/verifyPasswordResetCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/verifyPasswordResetCode.md deleted file mode 100644 index 887564d5..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl/verifyPasswordResetCode.md +++ /dev/null @@ -1,48 +0,0 @@ - - - -# verifyPasswordResetCode method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)> verifyPasswordResetCode -({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) code}) - -_override_ - - - -

Verify password reset code.

-

Throws a VerifyPasswordResetCodeFailureInterface if an exception occurs.

- - - -## Implementation - -```dart -@override -Future verifyPasswordResetCode({required String code}) async { - try { - final email = await _firebaseAuth.verifyPasswordResetCode(code); - return email.isNotNullOrEmpty; - } on FirebaseAuthException catch (e) { - throw VerifyPasswordResetCodeFailureFirebase.fromCode(e.code); - } catch (_) { - throw VerifyPasswordResetCodeFailureFirebase(); - } -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource-class.md deleted file mode 100644 index 29bfc2f7..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource-class.md +++ /dev/null @@ -1,247 +0,0 @@ - - - -# AuthenticationRemoteDataSource<Data> class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Is responsible for abstracting the provenance of the data.

- - - - - - -**Implementers** - -- [AuthenticationFirebaseDataSourceImpl](../wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl-class.md) - - - - - -## Constructors - -[AuthenticationRemoteDataSource](../wyatt_authentication_bloc/AuthenticationRemoteDataSource/AuthenticationRemoteDataSource.md) () - - - - -## Properties - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [addSession](../wyatt_authentication_bloc/AuthenticationRemoteDataSource/addSession.md)([SessionWrapper](../wyatt_authentication_bloc/SessionWrapper-class.md)<Data> wrapper) void - - - - - - - - -##### [confirmPasswordReset](../wyatt_authentication_bloc/AuthenticationRemoteDataSource/confirmPasswordReset.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) newPassword}) [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> - - - - - - - - -##### [delete](../wyatt_authentication_bloc/AuthenticationRemoteDataSource/delete.md)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> - - - - - - - - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [reauthenticate](../wyatt_authentication_bloc/AuthenticationRemoteDataSource/reauthenticate.md)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../wyatt_authentication_bloc/Account-class.md)> - - - - - - - - -##### [refresh](../wyatt_authentication_bloc/AuthenticationRemoteDataSource/refresh.md)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../wyatt_authentication_bloc/Account-class.md)> - - - - - - - - -##### [sendEmailVerification](../wyatt_authentication_bloc/AuthenticationRemoteDataSource/sendEmailVerification.md)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> - - - - - - - - -##### [sendPasswordResetEmail](../wyatt_authentication_bloc/AuthenticationRemoteDataSource/sendPasswordResetEmail.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email}) [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> - - - - - - - - -##### [sessionStream](../wyatt_authentication_bloc/AuthenticationRemoteDataSource/sessionStream.md)() [Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[SessionWrapper](../wyatt_authentication_bloc/SessionWrapper-class.md)<Data>> - - - - - - - - -##### [signInAnonymously](../wyatt_authentication_bloc/AuthenticationRemoteDataSource/signInAnonymously.md)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../wyatt_authentication_bloc/Account-class.md)> - - - - - - - - -##### [signInWithEmailAndPassword](../wyatt_authentication_bloc/AuthenticationRemoteDataSource/signInWithEmailAndPassword.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../wyatt_authentication_bloc/Account-class.md)> - - - - - - - - -##### [signInWithGoogle](../wyatt_authentication_bloc/AuthenticationRemoteDataSource/signInWithGoogle.md)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../wyatt_authentication_bloc/Account-class.md)> - - - - - - - - -##### [signOut](../wyatt_authentication_bloc/AuthenticationRemoteDataSource/signOut.md)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> - - - - - - - - -##### [signUpWithEmailAndPassword](../wyatt_authentication_bloc/AuthenticationRemoteDataSource/signUpWithEmailAndPassword.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../wyatt_authentication_bloc/Account-class.md)> - - - - - - - - -##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - -##### [updateEmail](../wyatt_authentication_bloc/AuthenticationRemoteDataSource/updateEmail.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email}) [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../wyatt_authentication_bloc/Account-class.md)> - - - - - - - - -##### [updatePassword](../wyatt_authentication_bloc/AuthenticationRemoteDataSource/updatePassword.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../wyatt_authentication_bloc/Account-class.md)> - - - - - - - - -##### [verifyPasswordResetCode](../wyatt_authentication_bloc/AuthenticationRemoteDataSource/verifyPasswordResetCode.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) code}) [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)> - - - - - - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/AuthenticationRemoteDataSource.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/AuthenticationRemoteDataSource.md deleted file mode 100644 index 9552fade..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/AuthenticationRemoteDataSource.md +++ /dev/null @@ -1,25 +0,0 @@ - - - -# AuthenticationRemoteDataSource<Data> constructor - - - - - *[](https://dart.dev/null-safety)* - - - -AuthenticationRemoteDataSource<Data>() - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/addSession.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/addSession.md deleted file mode 100644 index f1567da2..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/addSession.md +++ /dev/null @@ -1,35 +0,0 @@ - - - -# addSession method - - - - - *[](https://dart.dev/null-safety)* - - - - -void addSession -([SessionWrapper](../../wyatt_authentication_bloc/SessionWrapper-class.md)<Data> wrapper) - - - - - - - - -## Implementation - -```dart -void addSession(SessionWrapper wrapper); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/confirmPasswordReset.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/confirmPasswordReset.md deleted file mode 100644 index 785714a8..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/confirmPasswordReset.md +++ /dev/null @@ -1,38 +0,0 @@ - - - -# confirmPasswordReset method - - - - - *[](https://dart.dev/null-safety)* - - - - -[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> confirmPasswordReset -({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) newPassword}) - - - - - - - - -## Implementation - -```dart -Future confirmPasswordReset({ - required String code, - required String newPassword, -}); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/delete.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/delete.md deleted file mode 100644 index aad9ff7b..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/delete.md +++ /dev/null @@ -1,35 +0,0 @@ - - - -# delete method - - - - - *[](https://dart.dev/null-safety)* - - - - -[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> delete -() - - - - - - - - -## Implementation - -```dart -Future delete(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/reauthenticate.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/reauthenticate.md deleted file mode 100644 index 7f369a4c..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/reauthenticate.md +++ /dev/null @@ -1,35 +0,0 @@ - - - -# reauthenticate method - - - - - *[](https://dart.dev/null-safety)* - - - - -[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../../wyatt_authentication_bloc/Account-class.md)> reauthenticate -() - - - - - - - - -## Implementation - -```dart -Future reauthenticate(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/refresh.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/refresh.md deleted file mode 100644 index 104a6bc0..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/refresh.md +++ /dev/null @@ -1,35 +0,0 @@ - - - -# refresh method - - - - - *[](https://dart.dev/null-safety)* - - - - -[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../../wyatt_authentication_bloc/Account-class.md)> refresh -() - - - - - - - - -## Implementation - -```dart -Future refresh(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/sendEmailVerification.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/sendEmailVerification.md deleted file mode 100644 index 8ee8fe82..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/sendEmailVerification.md +++ /dev/null @@ -1,35 +0,0 @@ - - - -# sendEmailVerification method - - - - - *[](https://dart.dev/null-safety)* - - - - -[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> sendEmailVerification -() - - - - - - - - -## Implementation - -```dart -Future sendEmailVerification(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/sendPasswordResetEmail.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/sendPasswordResetEmail.md deleted file mode 100644 index 86a6aae2..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/sendPasswordResetEmail.md +++ /dev/null @@ -1,35 +0,0 @@ - - - -# sendPasswordResetEmail method - - - - - *[](https://dart.dev/null-safety)* - - - - -[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> sendPasswordResetEmail -({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email}) - - - - - - - - -## Implementation - -```dart -Future sendPasswordResetEmail({required String email}); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/sessionStream.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/sessionStream.md deleted file mode 100644 index 9d8739aa..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/sessionStream.md +++ /dev/null @@ -1,35 +0,0 @@ - - - -# sessionStream method - - - - - *[](https://dart.dev/null-safety)* - - - - -[Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[SessionWrapper](../../wyatt_authentication_bloc/SessionWrapper-class.md)<Data>> sessionStream -() - - - - - - - - -## Implementation - -```dart -Stream> sessionStream(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/signInAnonymously.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/signInAnonymously.md deleted file mode 100644 index ac7985b1..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/signInAnonymously.md +++ /dev/null @@ -1,35 +0,0 @@ - - - -# signInAnonymously method - - - - - *[](https://dart.dev/null-safety)* - - - - -[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../../wyatt_authentication_bloc/Account-class.md)> signInAnonymously -() - - - - - - - - -## Implementation - -```dart -Future signInAnonymously(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/signInWithEmailAndPassword.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/signInWithEmailAndPassword.md deleted file mode 100644 index 394754c5..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/signInWithEmailAndPassword.md +++ /dev/null @@ -1,38 +0,0 @@ - - - -# signInWithEmailAndPassword method - - - - - *[](https://dart.dev/null-safety)* - - - - -[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../../wyatt_authentication_bloc/Account-class.md)> signInWithEmailAndPassword -({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) - - - - - - - - -## Implementation - -```dart -Future signInWithEmailAndPassword({ - required String email, - required String password, -}); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/signInWithGoogle.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/signInWithGoogle.md deleted file mode 100644 index 4713504f..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/signInWithGoogle.md +++ /dev/null @@ -1,35 +0,0 @@ - - - -# signInWithGoogle method - - - - - *[](https://dart.dev/null-safety)* - - - - -[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../../wyatt_authentication_bloc/Account-class.md)> signInWithGoogle -() - - - - - - - - -## Implementation - -```dart -Future signInWithGoogle(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/signOut.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/signOut.md deleted file mode 100644 index f650758c..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/signOut.md +++ /dev/null @@ -1,35 +0,0 @@ - - - -# signOut method - - - - - *[](https://dart.dev/null-safety)* - - - - -[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> signOut -() - - - - - - - - -## Implementation - -```dart -Future signOut(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/signUpWithEmailAndPassword.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/signUpWithEmailAndPassword.md deleted file mode 100644 index 6d55af4c..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/signUpWithEmailAndPassword.md +++ /dev/null @@ -1,38 +0,0 @@ - - - -# signUpWithEmailAndPassword method - - - - - *[](https://dart.dev/null-safety)* - - - - -[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../../wyatt_authentication_bloc/Account-class.md)> signUpWithEmailAndPassword -({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) - - - - - - - - -## Implementation - -```dart -Future signUpWithEmailAndPassword({ - required String email, - required String password, -}); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/updateEmail.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/updateEmail.md deleted file mode 100644 index 07110bcb..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/updateEmail.md +++ /dev/null @@ -1,35 +0,0 @@ - - - -# updateEmail method - - - - - *[](https://dart.dev/null-safety)* - - - - -[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../../wyatt_authentication_bloc/Account-class.md)> updateEmail -({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email}) - - - - - - - - -## Implementation - -```dart -Future updateEmail({required String email}); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/updatePassword.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/updatePassword.md deleted file mode 100644 index 043a101f..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/updatePassword.md +++ /dev/null @@ -1,35 +0,0 @@ - - - -# updatePassword method - - - - - *[](https://dart.dev/null-safety)* - - - - -[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[Account](../../wyatt_authentication_bloc/Account-class.md)> updatePassword -({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) - - - - - - - - -## Implementation - -```dart -Future updatePassword({required String password}); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/verifyPasswordResetCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/verifyPasswordResetCode.md deleted file mode 100644 index bee09e13..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRemoteDataSource/verifyPasswordResetCode.md +++ /dev/null @@ -1,35 +0,0 @@ - - - -# verifyPasswordResetCode method - - - - - *[](https://dart.dev/null-safety)* - - - - -[Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<[bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)> verifyPasswordResetCode -({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) code}) - - - - - - - - -## Implementation - -```dart -Future verifyPasswordResetCode({required String code}); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository-class.md deleted file mode 100644 index 80cf4ff5..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository-class.md +++ /dev/null @@ -1,258 +0,0 @@ - - - -# AuthenticationRepository<Data> class - - - - - - - *[](https://dart.dev/null-safety)* - - - - - - - - - -**Implementers** - -- [AuthenticationRepositoryImpl](../wyatt_authentication_bloc/AuthenticationRepositoryImpl-class.md) - - - - - -## Constructors - -[AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository/AuthenticationRepository.md) () - - - - -## Properties - -##### [formRepository](../wyatt_authentication_bloc/AuthenticationRepository/formRepository.md) → FormRepository - - - -Form repository used in different authentication cubits/blocs -_read-only_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [addSession](../wyatt_authentication_bloc/AuthenticationRepository/addSession.md)([SessionWrapper](../wyatt_authentication_bloc/SessionWrapper-class.md)<Data> wrapper) void - - - -Add a new authentication event. - - - - -##### [confirmPasswordReset](../wyatt_authentication_bloc/AuthenticationRepository/confirmPasswordReset.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) newPassword}) FutureOrResult<void> - - - -Confirms the password reset with the provided newPassword and code. - - - - -##### [delete](../wyatt_authentication_bloc/AuthenticationRepository/delete.md)() FutureOrResult<void> - - - -Delete account. - - - - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [reauthenticate](../wyatt_authentication_bloc/AuthenticationRepository/reauthenticate.md)() FutureOrResult<[Account](../wyatt_authentication_bloc/Account-class.md)> - - - -Some security-sensitive actions—such as deleting an account, -setting a primary email address, and changing a password—require that -the user has recently signed in. - - - - -##### [refresh](../wyatt_authentication_bloc/AuthenticationRepository/refresh.md)() FutureOrResult<[Account](../wyatt_authentication_bloc/Account-class.md)> - - - -Refreshes the current user, if signed in. - - - - -##### [sendEmailVerification](../wyatt_authentication_bloc/AuthenticationRepository/sendEmailVerification.md)() FutureOrResult<void> - - - -Sends verification email to the account email. - - - - -##### [sendPasswordResetEmail](../wyatt_authentication_bloc/AuthenticationRepository/sendPasswordResetEmail.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email}) FutureOrResult<void> - - - -Sends a password reset email to the provided email. - - - - -##### [sessionStream](../wyatt_authentication_bloc/AuthenticationRepository/sessionStream.md)() [Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[SessionWrapper](../wyatt_authentication_bloc/SessionWrapper-class.md)<Data>> - - - -Authentication state change event stream. - - - - -##### [signInAnonymously](../wyatt_authentication_bloc/AuthenticationRepository/signInAnonymously.md)() FutureOrResult<[Account](../wyatt_authentication_bloc/Account-class.md)> - - - -Sign in anonymously. - - - - -##### [signInWithEmailAndPassword](../wyatt_authentication_bloc/AuthenticationRepository/signInWithEmailAndPassword.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) FutureOrResult<[Account](../wyatt_authentication_bloc/Account-class.md)> - - - -Signs in with the provided email and password. - - - - -##### [signInWithGoogle](../wyatt_authentication_bloc/AuthenticationRepository/signInWithGoogle.md)() FutureOrResult<[Account](../wyatt_authentication_bloc/Account-class.md)> - - - -Starts the Sign In with Google Flow. - - - - -##### [signOut](../wyatt_authentication_bloc/AuthenticationRepository/signOut.md)() FutureOrResult<void> - - - -Signs out the current user. -It also clears the cache and the associated data. - - - - -##### [signUpWithEmailAndPassword](../wyatt_authentication_bloc/AuthenticationRepository/signUpWithEmailAndPassword.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) FutureOrResult<[Account](../wyatt_authentication_bloc/Account-class.md)> - - - -Creates a new user with the provided email and password. - - - - -##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - -##### [updateEmail](../wyatt_authentication_bloc/AuthenticationRepository/updateEmail.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email}) FutureOrResult<[Account](../wyatt_authentication_bloc/Account-class.md)> - - - -Update or add email. - - - - -##### [updatePassword](../wyatt_authentication_bloc/AuthenticationRepository/updatePassword.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) FutureOrResult<[Account](../wyatt_authentication_bloc/Account-class.md)> - - - -Update or add password. - - - - -##### [verifyPasswordResetCode](../wyatt_authentication_bloc/AuthenticationRepository/verifyPasswordResetCode.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) code}) FutureOrResult<[bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)> - - - -Verify password reset code. - - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/AuthenticationRepository.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/AuthenticationRepository.md deleted file mode 100644 index da6e6d1d..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/AuthenticationRepository.md +++ /dev/null @@ -1,25 +0,0 @@ - - - -# AuthenticationRepository<Data> constructor - - - - - *[](https://dart.dev/null-safety)* - - - -AuthenticationRepository<Data>() - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/addSession.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/addSession.md deleted file mode 100644 index dd5755bd..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/addSession.md +++ /dev/null @@ -1,36 +0,0 @@ - - - -# addSession method - - - - - *[](https://dart.dev/null-safety)* - - - - -void addSession -([SessionWrapper](../../wyatt_authentication_bloc/SessionWrapper-class.md)<Data> wrapper) - - - - - -

Add a new authentication event.

- - - -## Implementation - -```dart -void addSession(SessionWrapper wrapper); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/confirmPasswordReset.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/confirmPasswordReset.md deleted file mode 100644 index 43531c88..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/confirmPasswordReset.md +++ /dev/null @@ -1,40 +0,0 @@ - - - -# confirmPasswordReset method - - - - - *[](https://dart.dev/null-safety)* - - - - -FutureOrResult<void> confirmPasswordReset -({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) newPassword}) - - - - - -

Confirms the password reset with the provided newPassword and code.

-

Throws a ConfirmPasswordResetFailureInterface if an exception occurs.

- - - -## Implementation - -```dart -FutureOrResult confirmPasswordReset({ - required String code, - required String newPassword, -}); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/delete.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/delete.md deleted file mode 100644 index 05b49493..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/delete.md +++ /dev/null @@ -1,38 +0,0 @@ - - - -# delete method - - - - - *[](https://dart.dev/null-safety)* - - - - -FutureOrResult<void> delete -() - - - - - -

Delete account.

-

Throws a DeleteAccountFailureInterface if -an exception occurs.

- - - -## Implementation - -```dart -FutureOrResult delete(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/formRepository.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/formRepository.md deleted file mode 100644 index 0bded545..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/formRepository.md +++ /dev/null @@ -1,37 +0,0 @@ - - - -# formRepository property - - - - - *[](https://dart.dev/null-safety)* - - - - - -FormRepository formRepository - - - - - -

Form repository used in different authentication cubits/blocs

- - - -## Implementation - -```dart -FormRepository get formRepository; -``` - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/reauthenticate.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/reauthenticate.md deleted file mode 100644 index 809974fe..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/reauthenticate.md +++ /dev/null @@ -1,40 +0,0 @@ - - - -# reauthenticate method - - - - - *[](https://dart.dev/null-safety)* - - - - -FutureOrResult<[Account](../../wyatt_authentication_bloc/Account-class.md)> reauthenticate -() - - - - - -

Some security-sensitive actions—such as deleting an account, -setting a primary email address, and changing a password—require that -the user has recently signed in.

-

Throws a ReauthenticateFailureInterface if -an exception occurs.

- - - -## Implementation - -```dart -FutureOrResult reauthenticate(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/refresh.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/refresh.md deleted file mode 100644 index 5f3413e3..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/refresh.md +++ /dev/null @@ -1,36 +0,0 @@ - - - -# refresh method - - - - - *[](https://dart.dev/null-safety)* - - - - -FutureOrResult<[Account](../../wyatt_authentication_bloc/Account-class.md)> refresh -() - - - - - -

Refreshes the current user, if signed in.

- - - -## Implementation - -```dart -FutureOrResult refresh(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/sendEmailVerification.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/sendEmailVerification.md deleted file mode 100644 index 184e510c..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/sendEmailVerification.md +++ /dev/null @@ -1,37 +0,0 @@ - - - -# sendEmailVerification method - - - - - *[](https://dart.dev/null-safety)* - - - - -FutureOrResult<void> sendEmailVerification -() - - - - - -

Sends verification email to the account email.

-

Throws a SendEmailVerificationFailureInterface if an exception occurs.

- - - -## Implementation - -```dart -FutureOrResult sendEmailVerification(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/sendPasswordResetEmail.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/sendPasswordResetEmail.md deleted file mode 100644 index 5778307e..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/sendPasswordResetEmail.md +++ /dev/null @@ -1,37 +0,0 @@ - - - -# sendPasswordResetEmail method - - - - - *[](https://dart.dev/null-safety)* - - - - -FutureOrResult<void> sendPasswordResetEmail -({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email}) - - - - - -

Sends a password reset email to the provided email.

-

Throws a SendPasswordResetEmailFailureInterface if an exception occurs.

- - - -## Implementation - -```dart -FutureOrResult sendPasswordResetEmail({required String email}); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/sessionStream.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/sessionStream.md deleted file mode 100644 index d911cb8d..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/sessionStream.md +++ /dev/null @@ -1,36 +0,0 @@ - - - -# sessionStream method - - - - - *[](https://dart.dev/null-safety)* - - - - -[Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[SessionWrapper](../../wyatt_authentication_bloc/SessionWrapper-class.md)<Data>> sessionStream -() - - - - - -

Authentication state change event stream.

- - - -## Implementation - -```dart -Stream> sessionStream(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/signInAnonymously.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/signInAnonymously.md deleted file mode 100644 index 03d3f774..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/signInAnonymously.md +++ /dev/null @@ -1,37 +0,0 @@ - - - -# signInAnonymously method - - - - - *[](https://dart.dev/null-safety)* - - - - -FutureOrResult<[Account](../../wyatt_authentication_bloc/Account-class.md)> signInAnonymously -() - - - - - -

Sign in anonymously.

-

Throws a SignInAnonymouslyFailureInterface if an exception occurs.

- - - -## Implementation - -```dart -FutureOrResult signInAnonymously(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/signInWithEmailAndPassword.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/signInWithEmailAndPassword.md deleted file mode 100644 index 5ae7989f..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/signInWithEmailAndPassword.md +++ /dev/null @@ -1,41 +0,0 @@ - - - -# signInWithEmailAndPassword method - - - - - *[](https://dart.dev/null-safety)* - - - - -FutureOrResult<[Account](../../wyatt_authentication_bloc/Account-class.md)> signInWithEmailAndPassword -({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) - - - - - -

Signs in with the provided email and password.

-

Throws a SignInWithEmailAndPasswordFailureInterface if -an exception occurs.

- - - -## Implementation - -```dart -FutureOrResult signInWithEmailAndPassword({ - required String email, - required String password, -}); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/signInWithGoogle.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/signInWithGoogle.md deleted file mode 100644 index 18a8989b..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/signInWithGoogle.md +++ /dev/null @@ -1,37 +0,0 @@ - - - -# signInWithGoogle method - - - - - *[](https://dart.dev/null-safety)* - - - - -FutureOrResult<[Account](../../wyatt_authentication_bloc/Account-class.md)> signInWithGoogle -() - - - - - -

Starts the Sign In with Google Flow.

-

Throws a SignInWithGoogleFailureInterface if an exception occurs.

- - - -## Implementation - -```dart -FutureOrResult signInWithGoogle(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/signOut.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/signOut.md deleted file mode 100644 index 7dad6c4b..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/signOut.md +++ /dev/null @@ -1,37 +0,0 @@ - - - -# signOut method - - - - - *[](https://dart.dev/null-safety)* - - - - -FutureOrResult<void> signOut -() - - - - - -

Signs out the current user. -It also clears the cache and the associated data.

- - - -## Implementation - -```dart -FutureOrResult signOut(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/signUpWithEmailAndPassword.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/signUpWithEmailAndPassword.md deleted file mode 100644 index 7a99a749..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/signUpWithEmailAndPassword.md +++ /dev/null @@ -1,42 +0,0 @@ - - - -# signUpWithEmailAndPassword method - - - - - *[](https://dart.dev/null-safety)* - - - - -FutureOrResult<[Account](../../wyatt_authentication_bloc/Account-class.md)> signUpWithEmailAndPassword -({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) - - - - - -

Creates a new user with the provided email and password.

-

Returns the newly created user's unique identifier.

-

Throws a SignUpWithEmailAndPasswordFailureInterface if -an exception occurs.

- - - -## Implementation - -```dart -FutureOrResult signUpWithEmailAndPassword({ - required String email, - required String password, -}); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/updateEmail.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/updateEmail.md deleted file mode 100644 index e324d7ad..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/updateEmail.md +++ /dev/null @@ -1,40 +0,0 @@ - - - -# updateEmail method - - - - - *[](https://dart.dev/null-safety)* - - - - -FutureOrResult<[Account](../../wyatt_authentication_bloc/Account-class.md)> updateEmail -({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email}) - - - - - -

Update or add email.

-

Throws a UpdateEmailFailureInterface if -an exception occurs.

- - - -## Implementation - -```dart -FutureOrResult updateEmail({ - required String email, -}); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/updatePassword.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/updatePassword.md deleted file mode 100644 index ac90a4a9..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/updatePassword.md +++ /dev/null @@ -1,40 +0,0 @@ - - - -# updatePassword method - - - - - *[](https://dart.dev/null-safety)* - - - - -FutureOrResult<[Account](../../wyatt_authentication_bloc/Account-class.md)> updatePassword -({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) - - - - - -

Update or add password.

-

Throws a UpdatePasswordFailureInterface if -an exception occurs.

- - - -## Implementation - -```dart -FutureOrResult updatePassword({ - required String password, -}); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/verifyPasswordResetCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/verifyPasswordResetCode.md deleted file mode 100644 index 73463137..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepository/verifyPasswordResetCode.md +++ /dev/null @@ -1,37 +0,0 @@ - - - -# verifyPasswordResetCode method - - - - - *[](https://dart.dev/null-safety)* - - - - -FutureOrResult<[bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)> verifyPasswordResetCode -({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) code}) - - - - - -

Verify password reset code.

-

Throws a VerifyPasswordResetCodeFailureInterface if an exception occurs.

- - - -## Implementation - -```dart -FutureOrResult verifyPasswordResetCode({required String code}); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl-class.md deleted file mode 100644 index 5ec57c81..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl-class.md +++ /dev/null @@ -1,269 +0,0 @@ - - - -# AuthenticationRepositoryImpl<Data extends Object> class - - - - - - - *[](https://dart.dev/null-safety)* - - - - - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> -- AuthenticationRepositoryImpl - - - - - - - - -## Constructors - -[AuthenticationRepositoryImpl](../wyatt_authentication_bloc/AuthenticationRepositoryImpl/AuthenticationRepositoryImpl.md) ({required [AuthenticationRemoteDataSource](../wyatt_authentication_bloc/AuthenticationRemoteDataSource-class.md)<Data> authenticationRemoteDataSource, FormRepository? formRepository, [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<FormInput<dynamic, FormInputValidator<dynamic, ValidationError>, dynamic>>? extraSignUpInputs, [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<FormInput<dynamic, FormInputValidator<dynamic, ValidationError>, dynamic>>? extraEditAccountInputs, FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError>? customEmailValidator, FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError>? customPasswordValidator}) - - - - -## Properties - -##### [authenticationRemoteDataSource](../wyatt_authentication_bloc/AuthenticationRepositoryImpl/authenticationRemoteDataSource.md) → [AuthenticationRemoteDataSource](../wyatt_authentication_bloc/AuthenticationRemoteDataSource-class.md)<Data> - - - - -_final_ - - - -##### [formRepository](../wyatt_authentication_bloc/AuthenticationRepositoryImpl/formRepository.md) → FormRepository - - - -Form repository used in different authentication cubits/blocs -_read-onlyoverride_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [addSession](../wyatt_authentication_bloc/AuthenticationRepositoryImpl/addSession.md)([SessionWrapper](../wyatt_authentication_bloc/SessionWrapper-class.md)<Data> wrapper) void - - - -Add a new authentication event. -_override_ - - - -##### [confirmPasswordReset](../wyatt_authentication_bloc/AuthenticationRepositoryImpl/confirmPasswordReset.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) newPassword}) FutureOrResult<void> - - - -Confirms the password reset with the provided newPassword and code. -_override_ - - - -##### [delete](../wyatt_authentication_bloc/AuthenticationRepositoryImpl/delete.md)() FutureOrResult<void> - - - -Delete account. -_override_ - - - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [reauthenticate](../wyatt_authentication_bloc/AuthenticationRepositoryImpl/reauthenticate.md)() FutureOrResult<[Account](../wyatt_authentication_bloc/Account-class.md)> - - - -Some security-sensitive actions—such as deleting an account, -setting a primary email address, and changing a password—require that -the user has recently signed in. -_override_ - - - -##### [refresh](../wyatt_authentication_bloc/AuthenticationRepositoryImpl/refresh.md)() FutureOrResult<[Account](../wyatt_authentication_bloc/Account-class.md)> - - - -Refreshes the current user, if signed in. -_override_ - - - -##### [sendEmailVerification](../wyatt_authentication_bloc/AuthenticationRepositoryImpl/sendEmailVerification.md)() FutureOrResult<void> - - - -Sends verification email to the account email. -_override_ - - - -##### [sendPasswordResetEmail](../wyatt_authentication_bloc/AuthenticationRepositoryImpl/sendPasswordResetEmail.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email}) FutureOrResult<void> - - - -Sends a password reset email to the provided email. -_override_ - - - -##### [sessionStream](../wyatt_authentication_bloc/AuthenticationRepositoryImpl/sessionStream.md)() [Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[SessionWrapper](../wyatt_authentication_bloc/SessionWrapper-class.md)<Data>> - - - -Authentication state change event stream. -_override_ - - - -##### [signInAnonymously](../wyatt_authentication_bloc/AuthenticationRepositoryImpl/signInAnonymously.md)() FutureOrResult<[Account](../wyatt_authentication_bloc/Account-class.md)> - - - -Sign in anonymously. -_override_ - - - -##### [signInWithEmailAndPassword](../wyatt_authentication_bloc/AuthenticationRepositoryImpl/signInWithEmailAndPassword.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) FutureOrResult<[Account](../wyatt_authentication_bloc/Account-class.md)> - - - -Signs in with the provided email and password. -_override_ - - - -##### [signInWithGoogle](../wyatt_authentication_bloc/AuthenticationRepositoryImpl/signInWithGoogle.md)() FutureOrResult<[Account](../wyatt_authentication_bloc/Account-class.md)> - - - -Starts the Sign In with Google Flow. -_override_ - - - -##### [signOut](../wyatt_authentication_bloc/AuthenticationRepositoryImpl/signOut.md)() FutureOrResult<void> - - - -Signs out the current user. -It also clears the cache and the associated data. -_override_ - - - -##### [signUpWithEmailAndPassword](../wyatt_authentication_bloc/AuthenticationRepositoryImpl/signUpWithEmailAndPassword.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) FutureOrResult<[Account](../wyatt_authentication_bloc/Account-class.md)> - - - -Creates a new user with the provided email and password. -_override_ - - - -##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - -##### [updateEmail](../wyatt_authentication_bloc/AuthenticationRepositoryImpl/updateEmail.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email}) FutureOrResult<[Account](../wyatt_authentication_bloc/Account-class.md)> - - - -Update or add email. -_override_ - - - -##### [updatePassword](../wyatt_authentication_bloc/AuthenticationRepositoryImpl/updatePassword.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) FutureOrResult<[Account](../wyatt_authentication_bloc/Account-class.md)> - - - -Update or add password. -_override_ - - - -##### [verifyPasswordResetCode](../wyatt_authentication_bloc/AuthenticationRepositoryImpl/verifyPasswordResetCode.md)({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) code}) FutureOrResult<[bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)> - - - -Verify password reset code. -_override_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/AuthenticationRepositoryImpl.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/AuthenticationRepositoryImpl.md deleted file mode 100644 index 5fd00e8a..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/AuthenticationRepositoryImpl.md +++ /dev/null @@ -1,69 +0,0 @@ - - - -# AuthenticationRepositoryImpl<Data extends Object> constructor - - - - - *[](https://dart.dev/null-safety)* - - - -AuthenticationRepositoryImpl<Data extends Object>({required [AuthenticationRemoteDataSource](../../wyatt_authentication_bloc/AuthenticationRemoteDataSource-class.md)<Data> authenticationRemoteDataSource, FormRepository? formRepository, [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<FormInput<dynamic, FormInputValidator<dynamic, ValidationError>, dynamic>>? extraSignUpInputs, [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<FormInput<dynamic, FormInputValidator<dynamic, ValidationError>, dynamic>>? extraEditAccountInputs, FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError>? customEmailValidator, FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError>? customPasswordValidator}) - - - - - -## Implementation - -```dart -AuthenticationRepositoryImpl({ - required this.authenticationRemoteDataSource, - FormRepository? formRepository, - // ignore: strict_raw_type - List? extraSignUpInputs, - // ignore: strict_raw_type - List? extraEditAccountInputs, - FormInputValidator? customEmailValidator, - FormInputValidator? customPasswordValidator, -}) { - _formRepository = formRepository ?? FormRepositoryImpl(); - - if (formRepository != null) { - return; - } - _formRepository - ..registerForm( - Forms.buildSignUpForm( - customEmailValidator, - customPasswordValidator, - extraSignUpInputs, - ), - ) - ..registerForm( - Forms.buildSignInForm( - customEmailValidator, - customPasswordValidator, - ), - ) - ..registerForm( - Forms.buildPasswordResetForm(customEmailValidator), - ) - ..registerForm( - Forms.buildEditAccountForm( - customEmailValidator, - customPasswordValidator, - extraEditAccountInputs, - ), - ); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/addSession.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/addSession.md deleted file mode 100644 index 24fac35a..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/addSession.md +++ /dev/null @@ -1,39 +0,0 @@ - - - -# addSession method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -void addSession -([SessionWrapper](../../wyatt_authentication_bloc/SessionWrapper-class.md)<Data> wrapper) - -_override_ - - - -

Add a new authentication event.

- - - -## Implementation - -```dart -@override -void addSession(SessionWrapper wrapper) => - authenticationRemoteDataSource.addSession(wrapper); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/authenticationRemoteDataSource.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/authenticationRemoteDataSource.md deleted file mode 100644 index c5a64a53..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/authenticationRemoteDataSource.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# authenticationRemoteDataSource property - - - - - *[](https://dart.dev/null-safety)* - - - -[AuthenticationRemoteDataSource](../../wyatt_authentication_bloc/AuthenticationRemoteDataSource-class.md)<Data> authenticationRemoteDataSource - -_final_ - - - - - - -## Implementation - -```dart -final AuthenticationRemoteDataSource authenticationRemoteDataSource; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/confirmPasswordReset.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/confirmPasswordReset.md deleted file mode 100644 index 1d7641ae..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/confirmPasswordReset.md +++ /dev/null @@ -1,51 +0,0 @@ - - - -# confirmPasswordReset method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -FutureOrResult<void> confirmPasswordReset -({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) newPassword}) - -_override_ - - - -

Confirms the password reset with the provided newPassword and code.

-

Throws a ConfirmPasswordResetFailureInterface if an exception occurs.

- - - -## Implementation - -```dart -@override -FutureOrResult confirmPasswordReset({ - required String code, - required String newPassword, -}) => - Result.tryCatchAsync( - () async { - await authenticationRemoteDataSource.confirmPasswordReset( - code: code, - newPassword: newPassword, - ); - }, - (error) => error, - ); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/delete.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/delete.md deleted file mode 100644 index 2275ccde..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/delete.md +++ /dev/null @@ -1,44 +0,0 @@ - - - -# delete method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -FutureOrResult<void> delete -() - -_override_ - - - -

Delete account.

-

Throws a DeleteAccountFailureInterface if -an exception occurs.

- - - -## Implementation - -```dart -@override -FutureOrResult delete() => - Result.tryCatchAsync( - () async => authenticationRemoteDataSource.delete(), - (error) => error, - ); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/formRepository.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/formRepository.md deleted file mode 100644 index d38908fe..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/formRepository.md +++ /dev/null @@ -1,41 +0,0 @@ - - - -# formRepository property - - - - - *[](https://dart.dev/null-safety)* - - - - - -**Annotations** - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) -FormRepository formRepository - -_override_ - - - -

Form repository used in different authentication cubits/blocs

- - - -## Implementation - -```dart -@override -FormRepository get formRepository => _formRepository; -``` - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/reauthenticate.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/reauthenticate.md deleted file mode 100644 index 251168fb..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/reauthenticate.md +++ /dev/null @@ -1,49 +0,0 @@ - - - -# reauthenticate method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -FutureOrResult<[Account](../../wyatt_authentication_bloc/Account-class.md)> reauthenticate -() - -_override_ - - - -

Some security-sensitive actions—such as deleting an account, -setting a primary email address, and changing a password—require that -the user has recently signed in.

-

Throws a ReauthenticateFailureInterface if -an exception occurs.

- - - -## Implementation - -```dart -@override -FutureOrResult reauthenticate() => - Result.tryCatchAsync( - () async { - final account = await authenticationRemoteDataSource.reauthenticate(); - return account; - }, - (error) => error, - ); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/refresh.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/refresh.md deleted file mode 100644 index 744850b4..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/refresh.md +++ /dev/null @@ -1,45 +0,0 @@ - - - -# refresh method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -FutureOrResult<[Account](../../wyatt_authentication_bloc/Account-class.md)> refresh -() - -_override_ - - - -

Refreshes the current user, if signed in.

- - - -## Implementation - -```dart -@override -FutureOrResult refresh() => - Result.tryCatchAsync( - () async { - final account = await authenticationRemoteDataSource.refresh(); - return account; - }, - (error) => error, - ); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/sendEmailVerification.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/sendEmailVerification.md deleted file mode 100644 index 3b70fe5d..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/sendEmailVerification.md +++ /dev/null @@ -1,45 +0,0 @@ - - - -# sendEmailVerification method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -FutureOrResult<void> sendEmailVerification -() - -_override_ - - - -

Sends verification email to the account email.

-

Throws a SendEmailVerificationFailureInterface if an exception occurs.

- - - -## Implementation - -```dart -@override -FutureOrResult sendEmailVerification() => - Result.tryCatchAsync( - () async { - await authenticationRemoteDataSource.sendEmailVerification(); - }, - (error) => error, - ); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/sendPasswordResetEmail.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/sendPasswordResetEmail.md deleted file mode 100644 index df9cbe89..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/sendPasswordResetEmail.md +++ /dev/null @@ -1,47 +0,0 @@ - - - -# sendPasswordResetEmail method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -FutureOrResult<void> sendPasswordResetEmail -({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email}) - -_override_ - - - -

Sends a password reset email to the provided email.

-

Throws a SendPasswordResetEmailFailureInterface if an exception occurs.

- - - -## Implementation - -```dart -@override -FutureOrResult sendPasswordResetEmail({required String email}) => - Result.tryCatchAsync( - () async { - await authenticationRemoteDataSource.sendPasswordResetEmail( - email: email, - ); - }, - (error) => error, - ); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/sessionStream.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/sessionStream.md deleted file mode 100644 index 33cab460..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/sessionStream.md +++ /dev/null @@ -1,39 +0,0 @@ - - - -# sessionStream method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[SessionWrapper](../../wyatt_authentication_bloc/SessionWrapper-class.md)<Data>> sessionStream -() - -_override_ - - - -

Authentication state change event stream.

- - - -## Implementation - -```dart -@override -Stream> sessionStream() => - authenticationRemoteDataSource.sessionStream(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/signInAnonymously.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/signInAnonymously.md deleted file mode 100644 index 8dfc8cea..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/signInAnonymously.md +++ /dev/null @@ -1,47 +0,0 @@ - - - -# signInAnonymously method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -FutureOrResult<[Account](../../wyatt_authentication_bloc/Account-class.md)> signInAnonymously -() - -_override_ - - - -

Sign in anonymously.

-

Throws a SignInAnonymouslyFailureInterface if an exception occurs.

- - - -## Implementation - -```dart -@override -FutureOrResult signInAnonymously() => - Result.tryCatchAsync( - () async { - final account = - await authenticationRemoteDataSource.signInAnonymously(); - return account; - }, - (error) => error, - ); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/signInWithEmailAndPassword.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/signInWithEmailAndPassword.md deleted file mode 100644 index a42a7bab..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/signInWithEmailAndPassword.md +++ /dev/null @@ -1,54 +0,0 @@ - - - -# signInWithEmailAndPassword method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -FutureOrResult<[Account](../../wyatt_authentication_bloc/Account-class.md)> signInWithEmailAndPassword -({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) - -_override_ - - - -

Signs in with the provided email and password.

-

Throws a SignInWithEmailAndPasswordFailureInterface if -an exception occurs.

- - - -## Implementation - -```dart -@override -FutureOrResult signInWithEmailAndPassword({ - required String email, - required String password, -}) => - Result.tryCatchAsync( - () async { - final account = - await authenticationRemoteDataSource.signInWithEmailAndPassword( - email: email, - password: password, - ); - return account; - }, - (error) => error, - ); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/signInWithGoogle.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/signInWithGoogle.md deleted file mode 100644 index e6e5095d..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/signInWithGoogle.md +++ /dev/null @@ -1,47 +0,0 @@ - - - -# signInWithGoogle method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -FutureOrResult<[Account](../../wyatt_authentication_bloc/Account-class.md)> signInWithGoogle -() - -_override_ - - - -

Starts the Sign In with Google Flow.

-

Throws a SignInWithGoogleFailureInterface if an exception occurs.

- - - -## Implementation - -```dart -@override -FutureOrResult signInWithGoogle() => - Result.tryCatchAsync( - () async { - final account = - await authenticationRemoteDataSource.signInWithGoogle(); - return account; - }, - (error) => error, - ); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/signOut.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/signOut.md deleted file mode 100644 index 5b83c76a..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/signOut.md +++ /dev/null @@ -1,45 +0,0 @@ - - - -# signOut method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -FutureOrResult<void> signOut -() - -_override_ - - - -

Signs out the current user. -It also clears the cache and the associated data.

- - - -## Implementation - -```dart -@override -FutureOrResult signOut() => - Result.tryCatchAsync( - () async { - await authenticationRemoteDataSource.signOut(); - }, - (error) => error, - ); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/signUpWithEmailAndPassword.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/signUpWithEmailAndPassword.md deleted file mode 100644 index 5a0ce347..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/signUpWithEmailAndPassword.md +++ /dev/null @@ -1,55 +0,0 @@ - - - -# signUpWithEmailAndPassword method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -FutureOrResult<[Account](../../wyatt_authentication_bloc/Account-class.md)> signUpWithEmailAndPassword -({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email, required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) - -_override_ - - - -

Creates a new user with the provided email and password.

-

Returns the newly created user's unique identifier.

-

Throws a SignUpWithEmailAndPasswordFailureInterface if -an exception occurs.

- - - -## Implementation - -```dart -@override -FutureOrResult signUpWithEmailAndPassword({ - required String email, - required String password, -}) => - Result.tryCatchAsync( - () async { - final account = - await authenticationRemoteDataSource.signUpWithEmailAndPassword( - email: email, - password: password, - ); - return account; - }, - (error) => error, - ); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/updateEmail.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/updateEmail.md deleted file mode 100644 index 89647f63..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/updateEmail.md +++ /dev/null @@ -1,48 +0,0 @@ - - - -# updateEmail method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -FutureOrResult<[Account](../../wyatt_authentication_bloc/Account-class.md)> updateEmail -({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) email}) - -_override_ - - - -

Update or add email.

-

Throws a UpdateEmailFailureInterface if -an exception occurs.

- - - -## Implementation - -```dart -@override -FutureOrResult updateEmail({required String email}) => - Result.tryCatchAsync( - () async { - final account = - await authenticationRemoteDataSource.updateEmail(email: email); - return account; - }, - (error) => error, - ); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/updatePassword.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/updatePassword.md deleted file mode 100644 index 3e839532..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/updatePassword.md +++ /dev/null @@ -1,49 +0,0 @@ - - - -# updatePassword method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -FutureOrResult<[Account](../../wyatt_authentication_bloc/Account-class.md)> updatePassword -({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) password}) - -_override_ - - - -

Update or add password.

-

Throws a UpdatePasswordFailureInterface if -an exception occurs.

- - - -## Implementation - -```dart -@override -FutureOrResult updatePassword({required String password}) => - Result.tryCatchAsync( - () async { - final account = await authenticationRemoteDataSource.updatePassword( - password: password, - ); - return account; - }, - (error) => error, - ); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/verifyPasswordResetCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/verifyPasswordResetCode.md deleted file mode 100644 index 6a2eae13..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationRepositoryImpl/verifyPasswordResetCode.md +++ /dev/null @@ -1,47 +0,0 @@ - - - -# verifyPasswordResetCode method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -FutureOrResult<[bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)> verifyPasswordResetCode -({required [String](https://api.flutter.dev/flutter/dart-core/String-class.html) code}) - -_override_ - - - -

Verify password reset code.

-

Throws a VerifyPasswordResetCodeFailureInterface if an exception occurs.

- - - -## Implementation - -```dart -@override -FutureOrResult verifyPasswordResetCode({required String code}) => - Result.tryCatchAsync( - () async { - final response = await authenticationRemoteDataSource - .verifyPasswordResetCode(code: code); - return response; - }, - (error) => error, - ); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState-class.md deleted file mode 100644 index 8b0c36ea..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState-class.md +++ /dev/null @@ -1,150 +0,0 @@ - - - -# AuthenticationState<Data> class - - - - - - - *[](https://dart.dev/null-safety)* - - - - - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [Equatable](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable-class.html) -- AuthenticationState - - - - - - - - -## Constructors - -[AuthenticationState.authenticated](../wyatt_authentication_bloc/AuthenticationState/AuthenticationState.authenticated.md) ([SessionWrapper](../wyatt_authentication_bloc/SessionWrapper-class.md)<Data> sessionWrapper) - - _const_ - -[AuthenticationState.unauthenticated](../wyatt_authentication_bloc/AuthenticationState/AuthenticationState.unauthenticated.md) () - - _const_ - -[AuthenticationState.unknown](../wyatt_authentication_bloc/AuthenticationState/AuthenticationState.unknown.md) () - - _const_ - - -## Properties - -##### [hashCode](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [props](../wyatt_authentication_bloc/AuthenticationState/props.md) → [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> - - - -The list of properties that will be used to determine whether -two instances are equal. -_read-onlyoverride_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - -##### [status](../wyatt_authentication_bloc/AuthenticationState/status.md) → [AuthenticationStatus](../wyatt_authentication_bloc/AuthenticationStatus.md) - - - - -_final_ - - - -##### [stringify](../wyatt_authentication_bloc/AuthenticationState/stringify.md) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)? - - - -If set to true, the toString method will be overridden to output -this instance's props. -_read-onlyoverride_ - - - -##### [wrapper](../wyatt_authentication_bloc/AuthenticationState/wrapper.md) → [SessionWrapper](../wyatt_authentication_bloc/SessionWrapper-class.md)<Data>? - - - - -_final_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/AuthenticationState.authenticated.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/AuthenticationState.authenticated.md deleted file mode 100644 index d9f91abf..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/AuthenticationState.authenticated.md +++ /dev/null @@ -1,34 +0,0 @@ - - - -# AuthenticationState<Data>.authenticated constructor - - - - - *[](https://dart.dev/null-safety)* - - -const -AuthenticationState<Data>.authenticated([SessionWrapper](../../wyatt_authentication_bloc/SessionWrapper-class.md)<Data> sessionWrapper) - - - - - -## Implementation - -```dart -const AuthenticationState.authenticated(SessionWrapper sessionWrapper) - : this._( - AuthenticationStatus.authenticated, - sessionWrapper, - ); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/AuthenticationState.unauthenticated.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/AuthenticationState.unauthenticated.md deleted file mode 100644 index e2bddab6..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/AuthenticationState.unauthenticated.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# AuthenticationState<Data>.unauthenticated constructor - - - - - *[](https://dart.dev/null-safety)* - - -const -AuthenticationState<Data>.unauthenticated() - - - - - -## Implementation - -```dart -const AuthenticationState.unauthenticated() - : this._(AuthenticationStatus.unauthenticated, null); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/AuthenticationState.unknown.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/AuthenticationState.unknown.md deleted file mode 100644 index 09ff10d9..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/AuthenticationState.unknown.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# AuthenticationState<Data>.unknown constructor - - - - - *[](https://dart.dev/null-safety)* - - -const -AuthenticationState<Data>.unknown() - - - - - -## Implementation - -```dart -const AuthenticationState.unknown() - : this._(AuthenticationStatus.unknown, null); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/props.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/props.md deleted file mode 100644 index 908ab81c..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/props.md +++ /dev/null @@ -1,42 +0,0 @@ - - - -# props property - - - - - *[](https://dart.dev/null-safety)* - - - - - -**Annotations** - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) -[List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> props - -_override_ - - - -

The list of properties that will be used to determine whether -two instances are equal.

- - - -## Implementation - -```dart -@override -List get props => [status, wrapper]; -``` - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/status.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/status.md deleted file mode 100644 index 40efc5ec..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/status.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# status property - - - - - *[](https://dart.dev/null-safety)* - - - -[AuthenticationStatus](../../wyatt_authentication_bloc/AuthenticationStatus.md) status - -_final_ - - - - - - -## Implementation - -```dart -final AuthenticationStatus status; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/stringify.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/stringify.md deleted file mode 100644 index d226dc33..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/stringify.md +++ /dev/null @@ -1,47 +0,0 @@ - - - -# stringify property - - - - - *[](https://dart.dev/null-safety)* - - - - - -**Annotations** - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) -[bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)? stringify - -_override_ - - - -

If set to true, the toString method will be overridden to output -this instance's props.

-

A global default value for stringify can be set using -EquatableConfig.stringify.

-

If this instance's stringify is set to null, the value of -EquatableConfig.stringify will be used instead. This defaults to -false.

- - - -## Implementation - -```dart -@override -bool? get stringify => true; -``` - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/wrapper.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/wrapper.md deleted file mode 100644 index cab7f3c8..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationState/wrapper.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# wrapper property - - - - - *[](https://dart.dev/null-safety)* - - - -[SessionWrapper](../../wyatt_authentication_bloc/SessionWrapper-class.md)<Data>? wrapper - -_final_ - - - - - - -## Implementation - -```dart -final SessionWrapper? wrapper; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationStatus.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationStatus.md deleted file mode 100644 index 2e76c5aa..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationStatus.md +++ /dev/null @@ -1,151 +0,0 @@ - - - -# AuthenticationStatus enum - - - - - *[](https://dart.dev/null-safety)* - - - -

Different authentication status

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [Enum](https://api.flutter.dev/flutter/dart-core/Enum-class.html) -- AuthenticationStatus - - - - - - -## Constructors - -[AuthenticationStatus](../wyatt_authentication_bloc/AuthenticationStatus/AuthenticationStatus.md) () - - _const_ - - -## Values - -##### [unknown](../wyatt_authentication_bloc/AuthenticationStatus.md) const [AuthenticationStatus](../wyatt_authentication_bloc/AuthenticationStatus.md) - - - -

At the application launch.

- - - - -##### [authenticated](../wyatt_authentication_bloc/AuthenticationStatus.md) const [AuthenticationStatus](../wyatt_authentication_bloc/AuthenticationStatus.md) - - - -

When the user is logged

- - - - -##### [unauthenticated](../wyatt_authentication_bloc/AuthenticationStatus.md) const [AuthenticationStatus](../wyatt_authentication_bloc/AuthenticationStatus.md) - - - -

When the user is not logged

- - - - - -## Properties - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [index](https://api.flutter.dev/flutter/dart-core/Enum/index.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -A numeric identifier for the enumerated value. -_read-onlyinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - -## Constants - -##### [values](../wyatt_authentication_bloc/AuthenticationStatus/values-constant.md) const [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[AuthenticationStatus](../wyatt_authentication_bloc/AuthenticationStatus.md)> - - - -A constant List of the values in this enum, in order of their declaration. - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationStatus/AuthenticationStatus.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationStatus/AuthenticationStatus.md deleted file mode 100644 index be2e4631..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationStatus/AuthenticationStatus.md +++ /dev/null @@ -1,25 +0,0 @@ - - - -# AuthenticationStatus constructor - - - - - *[](https://dart.dev/null-safety)* - - -const -AuthenticationStatus() - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationStatus/values-constant.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationStatus/values-constant.md deleted file mode 100644 index 9639a71a..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/AuthenticationStatus/values-constant.md +++ /dev/null @@ -1,29 +0,0 @@ - - - -# values constant - - - - - *[](https://dart.dev/null-safety)* - - - -[List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[AuthenticationStatus](../../wyatt_authentication_bloc/AuthenticationStatus.md)> const values - - - - - -

A constant List of the values in this enum, in order of their declaration.

- - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit-class.md deleted file mode 100644 index a1d6b8f8..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit-class.md +++ /dev/null @@ -1,261 +0,0 @@ - - - -# BaseEditAccountCubit<Data> class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Abstract edit account cubit useful for implementing a cubit with fine -granularity by adding only the required mixins.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [BlocBase](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase-class.html)<[EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md)> -- [Cubit](https://pub.dev/documentation/bloc/8.1.0/bloc/Cubit-class.html)<[EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md)> -- BaseEditAccountCubit - - - -**Implementers** - -- [EditAccountCubit](../wyatt_authentication_bloc/EditAccountCubit-class.md) - - - - - -## Constructors - -[BaseEditAccountCubit](../wyatt_authentication_bloc/BaseEditAccountCubit/BaseEditAccountCubit.md) ({required [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> authenticationRepository}) - - - - -## Properties - -##### [authenticationRepository](../wyatt_authentication_bloc/BaseEditAccountCubit/authenticationRepository.md) → [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> - - - - -_final_ - - - -##### [formName](../wyatt_authentication_bloc/BaseEditAccountCubit/formName.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-only_ - - - -##### [formRepository](../wyatt_authentication_bloc/BaseEditAccountCubit/formRepository.md) → FormRepository - - - - -_read-only_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [isClosed](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/isClosed.html) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -Whether the bloc is closed. -_read-onlyinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - -##### [state](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/state.html) → [EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md) - - - -The current state. -_read-onlyinherited_ - - - -##### [stream](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/stream.html) → [Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md)> - - - -The current stream of states. -_read-onlyinherited_ - - - - - -## Methods - -##### [addError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/addError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [[StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html)? stackTrace]) void - - - -Reports an error which triggers onError with an optional StackTrace. -_inherited_ - - - -##### [close](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/close.html)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> - - - -Closes the instance. -This method should be called when the instance is no longer needed. -Once close is called, the instance can no longer be used. -_inherited_ - - - -##### [dataChanged](../wyatt_authentication_bloc/BaseEditAccountCubit/dataChanged.md)<Value>([String](https://api.flutter.dev/flutter/dart-core/String-class.html) key, FormInputValidator<Value, ValidationError> dirtyValue) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - - - - - -##### [emit](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/emit.html)([EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md) state) void - - - -Updates the state to the provided state. -emit does nothing if the state being emitted -is equal to the current state. -_inherited_ - - - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [onChange](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onChange.html)([Change](https://pub.dev/documentation/bloc/8.1.0/bloc/Change-class.html)<[EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md)> change) void - - - -Called whenever a change occurs with the given change. -A change occurs when a new state is emitted. -onChange is called before the state of the cubit is updated. -onChange is a great spot to add logging/analytics for a specific cubit. -_inherited_ - - - -##### [onError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html) stackTrace) void - - - -Called whenever an error occurs and notifies BlocObserver.onError. -_inherited_ - - - -##### [reset](../wyatt_authentication_bloc/BaseEditAccountCubit/reset.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - - - - - -##### [submit](../wyatt_authentication_bloc/BaseEditAccountCubit/submit.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - - - - - -##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - -##### [update](../wyatt_authentication_bloc/BaseEditAccountCubit/update.md)(WyattForm form, {SetOperation operation = SetOperation.replace}) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - - - - - -##### [validate](../wyatt_authentication_bloc/BaseEditAccountCubit/validate.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - - - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/BaseEditAccountCubit.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/BaseEditAccountCubit.md deleted file mode 100644 index 8f85be67..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/BaseEditAccountCubit.md +++ /dev/null @@ -1,37 +0,0 @@ - - - -# BaseEditAccountCubit<Data> constructor - - - - - *[](https://dart.dev/null-safety)* - - - -BaseEditAccountCubit<Data>({required [AuthenticationRepository](../../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> authenticationRepository}) - - - - - -## Implementation - -```dart -BaseEditAccountCubit({ - required this.authenticationRepository, -}) : super( - EditAccountState( - form: authenticationRepository.formRepository - .accessForm(AuthFormName.signInForm), - ), - ); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/authenticationRepository.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/authenticationRepository.md deleted file mode 100644 index 32cdfa2a..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/authenticationRepository.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# authenticationRepository property - - - - - *[](https://dart.dev/null-safety)* - - - -[AuthenticationRepository](../../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> authenticationRepository - -_final_ - - - - - - -## Implementation - -```dart -final AuthenticationRepository authenticationRepository; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/dataChanged.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/dataChanged.md deleted file mode 100644 index 1748061e..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/dataChanged.md +++ /dev/null @@ -1,53 +0,0 @@ - - - -# dataChanged<Value> method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> dataChanged -<Value>([String](https://api.flutter.dev/flutter/dart-core/String-class.html) key, FormInputValidator<Value, ValidationError> dirtyValue) - - - - - - - - -## Implementation - -```dart -@override -FutureOr dataChanged( - String key, - FormInputValidator dirtyValue, -) { - final form = formRepository.accessForm(formName).clone(); - - try { - form.updateValidator(key, dirtyValue); - formRepository.updateForm(form); - } catch (e) { - rethrow; - } - - emit( - EditAccountState(form: form, status: form.validate()), - ); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/formName.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/formName.md deleted file mode 100644 index 3196e650..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/formName.md +++ /dev/null @@ -1,40 +0,0 @@ - - - -# formName property - - - - - *[](https://dart.dev/null-safety)* - - - - - -**Annotations** - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) -[String](https://api.flutter.dev/flutter/dart-core/String-class.html) formName - - - - - - - - -## Implementation - -```dart -@override -String get formName => AuthFormName.signInForm; -``` - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/formRepository.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/formRepository.md deleted file mode 100644 index db8665dd..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/formRepository.md +++ /dev/null @@ -1,36 +0,0 @@ - - - -# formRepository property - - - - - *[](https://dart.dev/null-safety)* - - - - - -FormRepository formRepository - - - - - - - - -## Implementation - -```dart -FormRepository get formRepository => authenticationRepository.formRepository; -``` - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/reset.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/reset.md deleted file mode 100644 index 5344b5c4..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/reset.md +++ /dev/null @@ -1,43 +0,0 @@ - - - -# reset method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> reset -() - - - - - - - - -## Implementation - -```dart -@override -FutureOr reset() { - final form = state.form.reset(); - formRepository.updateForm(form); - emit( - EditAccountState(form: form, status: form.validate()), - ); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/submit.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/submit.md deleted file mode 100644 index 4ae4a062..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/submit.md +++ /dev/null @@ -1,48 +0,0 @@ - - - -# submit method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> submit -() - - - - - - - - -## Implementation - -```dart -@override -FutureOr submit() async { - final WyattForm form = formRepository.accessForm(formName); - const error = '`submit()` is not implemented for BaseEditAccountCubit, ' - 'please use `updateEmail()` or `updatePassword()`.'; - emit( - EditAccountState( - form: form, - errorMessage: error, - status: FormStatus.submissionFailure, - ), - ); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/update.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/update.md deleted file mode 100644 index f0bb65a1..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/update.md +++ /dev/null @@ -1,48 +0,0 @@ - - - -# update method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> update -(WyattForm form, {SetOperation operation = SetOperation.replace}) - - - - - - - - -## Implementation - -```dart -@override -FutureOr update( - WyattForm form, { - SetOperation operation = SetOperation.replace, -}) { - final WyattForm current = formRepository.accessForm(formName).clone(); - final WyattForm newForm = operation.operation.call(current, form); - formRepository.updateForm(newForm); - - emit( - EditAccountState(form: newForm, status: newForm.validate()), - ); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/validate.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/validate.md deleted file mode 100644 index 73e17324..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseEditAccountCubit/validate.md +++ /dev/null @@ -1,42 +0,0 @@ - - - -# validate method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> validate -() - - - - - - - - -## Implementation - -```dart -@override -FutureOr validate() { - final WyattForm form = formRepository.accessForm(formName); - emit( - EditAccountState(form: form, status: form.validate()), - ); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit-class.md deleted file mode 100644 index d56382ff..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit-class.md +++ /dev/null @@ -1,261 +0,0 @@ - - - -# BaseSignInCubit<Data> class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Abstract sign in cubit useful for implementing a cubit with fine -granularity by adding only the required mixins.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [BlocBase](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase-class.html)<[SignInState](../wyatt_authentication_bloc/SignInState-class.md)> -- [Cubit](https://pub.dev/documentation/bloc/8.1.0/bloc/Cubit-class.html)<[SignInState](../wyatt_authentication_bloc/SignInState-class.md)> -- BaseSignInCubit - - - -**Implementers** - -- [SignInCubit](../wyatt_authentication_bloc/SignInCubit-class.md) - - - - - -## Constructors - -[BaseSignInCubit](../wyatt_authentication_bloc/BaseSignInCubit/BaseSignInCubit.md) ({required [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> authenticationRepository}) - - - - -## Properties - -##### [authenticationRepository](../wyatt_authentication_bloc/BaseSignInCubit/authenticationRepository.md) → [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> - - - - -_final_ - - - -##### [formName](../wyatt_authentication_bloc/BaseSignInCubit/formName.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-only_ - - - -##### [formRepository](../wyatt_authentication_bloc/BaseSignInCubit/formRepository.md) → FormRepository - - - - -_read-only_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [isClosed](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/isClosed.html) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -Whether the bloc is closed. -_read-onlyinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - -##### [state](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/state.html) → [SignInState](../wyatt_authentication_bloc/SignInState-class.md) - - - -The current state. -_read-onlyinherited_ - - - -##### [stream](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/stream.html) → [Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[SignInState](../wyatt_authentication_bloc/SignInState-class.md)> - - - -The current stream of states. -_read-onlyinherited_ - - - - - -## Methods - -##### [addError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/addError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [[StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html)? stackTrace]) void - - - -Reports an error which triggers onError with an optional StackTrace. -_inherited_ - - - -##### [close](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/close.html)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> - - - -Closes the instance. -This method should be called when the instance is no longer needed. -Once close is called, the instance can no longer be used. -_inherited_ - - - -##### [dataChanged](../wyatt_authentication_bloc/BaseSignInCubit/dataChanged.md)<Value>([String](https://api.flutter.dev/flutter/dart-core/String-class.html) key, FormInputValidator<Value, ValidationError> dirtyValue) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - - - - - -##### [emit](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/emit.html)([SignInState](../wyatt_authentication_bloc/SignInState-class.md) state) void - - - -Updates the state to the provided state. -emit does nothing if the state being emitted -is equal to the current state. -_inherited_ - - - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [onChange](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onChange.html)([Change](https://pub.dev/documentation/bloc/8.1.0/bloc/Change-class.html)<[SignInState](../wyatt_authentication_bloc/SignInState-class.md)> change) void - - - -Called whenever a change occurs with the given change. -A change occurs when a new state is emitted. -onChange is called before the state of the cubit is updated. -onChange is a great spot to add logging/analytics for a specific cubit. -_inherited_ - - - -##### [onError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html) stackTrace) void - - - -Called whenever an error occurs and notifies BlocObserver.onError. -_inherited_ - - - -##### [reset](../wyatt_authentication_bloc/BaseSignInCubit/reset.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - - - - - -##### [submit](../wyatt_authentication_bloc/BaseSignInCubit/submit.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - - - - - -##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - -##### [update](../wyatt_authentication_bloc/BaseSignInCubit/update.md)(WyattForm form, {SetOperation operation = SetOperation.replace}) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - - - - - -##### [validate](../wyatt_authentication_bloc/BaseSignInCubit/validate.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - - - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/BaseSignInCubit.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/BaseSignInCubit.md deleted file mode 100644 index 11cb730f..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/BaseSignInCubit.md +++ /dev/null @@ -1,37 +0,0 @@ - - - -# BaseSignInCubit<Data> constructor - - - - - *[](https://dart.dev/null-safety)* - - - -BaseSignInCubit<Data>({required [AuthenticationRepository](../../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> authenticationRepository}) - - - - - -## Implementation - -```dart -BaseSignInCubit({ - required this.authenticationRepository, -}) : super( - SignInState( - form: authenticationRepository.formRepository - .accessForm(AuthFormName.signInForm), - ), - ); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/authenticationRepository.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/authenticationRepository.md deleted file mode 100644 index 32cdfa2a..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/authenticationRepository.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# authenticationRepository property - - - - - *[](https://dart.dev/null-safety)* - - - -[AuthenticationRepository](../../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> authenticationRepository - -_final_ - - - - - - -## Implementation - -```dart -final AuthenticationRepository authenticationRepository; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/dataChanged.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/dataChanged.md deleted file mode 100644 index 2c85a80b..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/dataChanged.md +++ /dev/null @@ -1,53 +0,0 @@ - - - -# dataChanged<Value> method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> dataChanged -<Value>([String](https://api.flutter.dev/flutter/dart-core/String-class.html) key, FormInputValidator<Value, ValidationError> dirtyValue) - - - - - - - - -## Implementation - -```dart -@override -FutureOr dataChanged( - String key, - FormInputValidator dirtyValue, -) { - final form = formRepository.accessForm(formName).clone(); - - try { - form.updateValidator(key, dirtyValue); - formRepository.updateForm(form); - } catch (e) { - rethrow; - } - - emit( - SignInState(form: form, status: form.validate()), - ); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/formName.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/formName.md deleted file mode 100644 index 3196e650..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/formName.md +++ /dev/null @@ -1,40 +0,0 @@ - - - -# formName property - - - - - *[](https://dart.dev/null-safety)* - - - - - -**Annotations** - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) -[String](https://api.flutter.dev/flutter/dart-core/String-class.html) formName - - - - - - - - -## Implementation - -```dart -@override -String get formName => AuthFormName.signInForm; -``` - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/formRepository.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/formRepository.md deleted file mode 100644 index db8665dd..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/formRepository.md +++ /dev/null @@ -1,36 +0,0 @@ - - - -# formRepository property - - - - - *[](https://dart.dev/null-safety)* - - - - - -FormRepository formRepository - - - - - - - - -## Implementation - -```dart -FormRepository get formRepository => authenticationRepository.formRepository; -``` - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/reset.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/reset.md deleted file mode 100644 index 5d78a829..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/reset.md +++ /dev/null @@ -1,43 +0,0 @@ - - - -# reset method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> reset -() - - - - - - - - -## Implementation - -```dart -@override -FutureOr reset() { - final form = state.form.reset(); - formRepository.updateForm(form); - emit( - SignInState(form: form, status: form.validate()), - ); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/submit.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/submit.md deleted file mode 100644 index 69de04c2..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/submit.md +++ /dev/null @@ -1,48 +0,0 @@ - - - -# submit method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> submit -() - - - - - - - - -## Implementation - -```dart -@override -FutureOr submit() async { - final WyattForm form = formRepository.accessForm(formName); - const error = '`submit()` is not implemented for BaseSignInCubit, ' - 'please use `signUpWithEmailAndPassword()`.'; - emit( - SignInState( - form: form, - errorMessage: error, - status: FormStatus.submissionFailure, - ), - ); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/update.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/update.md deleted file mode 100644 index d37c336c..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/update.md +++ /dev/null @@ -1,48 +0,0 @@ - - - -# update method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> update -(WyattForm form, {SetOperation operation = SetOperation.replace}) - - - - - - - - -## Implementation - -```dart -@override -FutureOr update( - WyattForm form, { - SetOperation operation = SetOperation.replace, -}) { - final WyattForm current = formRepository.accessForm(formName).clone(); - final WyattForm newForm = operation.operation.call(current, form); - formRepository.updateForm(newForm); - - emit( - SignInState(form: newForm, status: newForm.validate()), - ); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/validate.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/validate.md deleted file mode 100644 index 8dbc20d1..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignInCubit/validate.md +++ /dev/null @@ -1,42 +0,0 @@ - - - -# validate method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> validate -() - - - - - - - - -## Implementation - -```dart -@override -FutureOr validate() { - final WyattForm form = formRepository.accessForm(formName); - emit( - SignInState(form: form, status: form.validate()), - ); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit-class.md deleted file mode 100644 index 4bf08947..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit-class.md +++ /dev/null @@ -1,261 +0,0 @@ - - - -# BaseSignUpCubit<Data> class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Abstract sign up cubit useful for implementing a cubit with fine -granularity by adding only the required mixins.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [BlocBase](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase-class.html)<[SignUpState](../wyatt_authentication_bloc/SignUpState-class.md)> -- [Cubit](https://pub.dev/documentation/bloc/8.1.0/bloc/Cubit-class.html)<[SignUpState](../wyatt_authentication_bloc/SignUpState-class.md)> -- BaseSignUpCubit - - - -**Implementers** - -- [SignUpCubit](../wyatt_authentication_bloc/SignUpCubit-class.md) - - - - - -## Constructors - -[BaseSignUpCubit](../wyatt_authentication_bloc/BaseSignUpCubit/BaseSignUpCubit.md) ({required [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> authenticationRepository}) - - - - -## Properties - -##### [authenticationRepository](../wyatt_authentication_bloc/BaseSignUpCubit/authenticationRepository.md) → [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> - - - - -_final_ - - - -##### [formName](../wyatt_authentication_bloc/BaseSignUpCubit/formName.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-only_ - - - -##### [formRepository](../wyatt_authentication_bloc/BaseSignUpCubit/formRepository.md) → FormRepository - - - - -_read-only_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [isClosed](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/isClosed.html) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -Whether the bloc is closed. -_read-onlyinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - -##### [state](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/state.html) → [SignUpState](../wyatt_authentication_bloc/SignUpState-class.md) - - - -The current state. -_read-onlyinherited_ - - - -##### [stream](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/stream.html) → [Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[SignUpState](../wyatt_authentication_bloc/SignUpState-class.md)> - - - -The current stream of states. -_read-onlyinherited_ - - - - - -## Methods - -##### [addError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/addError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [[StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html)? stackTrace]) void - - - -Reports an error which triggers onError with an optional StackTrace. -_inherited_ - - - -##### [close](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/close.html)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> - - - -Closes the instance. -This method should be called when the instance is no longer needed. -Once close is called, the instance can no longer be used. -_inherited_ - - - -##### [dataChanged](../wyatt_authentication_bloc/BaseSignUpCubit/dataChanged.md)<Value>([String](https://api.flutter.dev/flutter/dart-core/String-class.html) key, FormInputValidator<Value, ValidationError> dirtyValue) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - - - - - -##### [emit](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/emit.html)([SignUpState](../wyatt_authentication_bloc/SignUpState-class.md) state) void - - - -Updates the state to the provided state. -emit does nothing if the state being emitted -is equal to the current state. -_inherited_ - - - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [onChange](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onChange.html)([Change](https://pub.dev/documentation/bloc/8.1.0/bloc/Change-class.html)<[SignUpState](../wyatt_authentication_bloc/SignUpState-class.md)> change) void - - - -Called whenever a change occurs with the given change. -A change occurs when a new state is emitted. -onChange is called before the state of the cubit is updated. -onChange is a great spot to add logging/analytics for a specific cubit. -_inherited_ - - - -##### [onError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html) stackTrace) void - - - -Called whenever an error occurs and notifies BlocObserver.onError. -_inherited_ - - - -##### [reset](../wyatt_authentication_bloc/BaseSignUpCubit/reset.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - - - - - -##### [submit](../wyatt_authentication_bloc/BaseSignUpCubit/submit.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - - - - - -##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - -##### [update](../wyatt_authentication_bloc/BaseSignUpCubit/update.md)(WyattForm form, {SetOperation operation = SetOperation.replace}) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - - - - - -##### [validate](../wyatt_authentication_bloc/BaseSignUpCubit/validate.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - - - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/BaseSignUpCubit.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/BaseSignUpCubit.md deleted file mode 100644 index 00958987..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/BaseSignUpCubit.md +++ /dev/null @@ -1,37 +0,0 @@ - - - -# BaseSignUpCubit<Data> constructor - - - - - *[](https://dart.dev/null-safety)* - - - -BaseSignUpCubit<Data>({required [AuthenticationRepository](../../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> authenticationRepository}) - - - - - -## Implementation - -```dart -BaseSignUpCubit({ - required this.authenticationRepository, -}) : super( - SignUpState( - form: authenticationRepository.formRepository - .accessForm(AuthFormName.signUpForm), - ), - ); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/authenticationRepository.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/authenticationRepository.md deleted file mode 100644 index 32cdfa2a..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/authenticationRepository.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# authenticationRepository property - - - - - *[](https://dart.dev/null-safety)* - - - -[AuthenticationRepository](../../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> authenticationRepository - -_final_ - - - - - - -## Implementation - -```dart -final AuthenticationRepository authenticationRepository; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/dataChanged.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/dataChanged.md deleted file mode 100644 index 8583e9da..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/dataChanged.md +++ /dev/null @@ -1,53 +0,0 @@ - - - -# dataChanged<Value> method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> dataChanged -<Value>([String](https://api.flutter.dev/flutter/dart-core/String-class.html) key, FormInputValidator<Value, ValidationError> dirtyValue) - - - - - - - - -## Implementation - -```dart -@override -FutureOr dataChanged( - String key, - FormInputValidator dirtyValue, -) { - final form = formRepository.accessForm(formName).clone(); - - try { - form.updateValidator(key, dirtyValue); - formRepository.updateForm(form); - } catch (e) { - rethrow; - } - - emit( - SignUpState(form: form, status: form.validate()), - ); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/formName.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/formName.md deleted file mode 100644 index f79689dd..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/formName.md +++ /dev/null @@ -1,40 +0,0 @@ - - - -# formName property - - - - - *[](https://dart.dev/null-safety)* - - - - - -**Annotations** - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) -[String](https://api.flutter.dev/flutter/dart-core/String-class.html) formName - - - - - - - - -## Implementation - -```dart -@override -String get formName => AuthFormName.signUpForm; -``` - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/formRepository.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/formRepository.md deleted file mode 100644 index db8665dd..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/formRepository.md +++ /dev/null @@ -1,36 +0,0 @@ - - - -# formRepository property - - - - - *[](https://dart.dev/null-safety)* - - - - - -FormRepository formRepository - - - - - - - - -## Implementation - -```dart -FormRepository get formRepository => authenticationRepository.formRepository; -``` - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/reset.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/reset.md deleted file mode 100644 index 621867ee..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/reset.md +++ /dev/null @@ -1,43 +0,0 @@ - - - -# reset method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> reset -() - - - - - - - - -## Implementation - -```dart -@override -FutureOr reset() { - final form = state.form.reset(); - formRepository.updateForm(form); - emit( - SignUpState(form: form, status: form.validate()), - ); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/submit.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/submit.md deleted file mode 100644 index b9699be7..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/submit.md +++ /dev/null @@ -1,49 +0,0 @@ - - - -# submit method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> submit -() - - - - - - - - -## Implementation - -```dart -@override -FutureOr submit() async { - final WyattForm form = formRepository.accessForm(formName); - const error = '`submit()` is not implemented for BaseSignUpCubit, ' - 'please use `signUpWithEmailAndPassword()`.'; - emit( - SignUpState( - form: form, - errorMessage: error, - status: FormStatus.submissionFailure, - ), - ); - throw UnimplementedError(error); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/update.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/update.md deleted file mode 100644 index 9cd644a4..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/update.md +++ /dev/null @@ -1,51 +0,0 @@ - - - -# update method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> update -(WyattForm form, {SetOperation operation = SetOperation.replace}) - - - - - - - - -## Implementation - -```dart -@override -FutureOr update( - WyattForm form, { - SetOperation operation = SetOperation.replace, -}) { - final WyattForm current = formRepository.accessForm(formName).clone(); - final WyattForm newForm = operation.operation.call(current, form); - formRepository.updateForm(newForm); - - emit( - SignUpState( - form: newForm, - status: newForm.validate(), - ), - ); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/validate.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/validate.md deleted file mode 100644 index 1eeceb04..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BaseSignUpCubit/validate.md +++ /dev/null @@ -1,42 +0,0 @@ - - - -# validate method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> validate -() - - - - - - - - -## Implementation - -```dart -@override -FutureOr validate() { - final WyattForm form = formRepository.accessForm(formName); - emit( - SignUpState(form: form, status: form.validate()), - ); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BuildContextExtension.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BuildContextExtension.md deleted file mode 100644 index 6ee49aa0..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BuildContextExtension.md +++ /dev/null @@ -1,76 +0,0 @@ - - - -# BuildContextExtension extension -on [BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) - - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Extension that helps to quickly access useful resources like wrapper, -session, account or data.

- - - - - - -## Methods - -##### [account](../wyatt_authentication_bloc/BuildContextExtension/account.md)<T extends [AuthenticationCubit](../wyatt_authentication_bloc/AuthenticationCubit-class.md)<Data>, Data>() [Account](../wyatt_authentication_bloc/Account-class.md)? - - - -Returns account - - - - -##### [data](../wyatt_authentication_bloc/BuildContextExtension/data.md)<T extends [AuthenticationCubit](../wyatt_authentication_bloc/AuthenticationCubit-class.md)<Data>, Data>() Data? - - - -Returns associated data - - - - -##### [session](../wyatt_authentication_bloc/BuildContextExtension/session.md)<T extends [AuthenticationCubit](../wyatt_authentication_bloc/AuthenticationCubit-class.md)<Data>, Data>() [Session](../wyatt_authentication_bloc/Session-class.md)<Data>? - - - -Returns session - - - - -##### [wrapper](../wyatt_authentication_bloc/BuildContextExtension/wrapper.md)<T extends [AuthenticationCubit](../wyatt_authentication_bloc/AuthenticationCubit-class.md)<Data>, Data>() [SessionWrapper](../wyatt_authentication_bloc/SessionWrapper-class.md)<Data>? - - - -Returns session wrapper - - - - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BuildContextExtension/account.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BuildContextExtension/account.md deleted file mode 100644 index d0f51a1f..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BuildContextExtension/account.md +++ /dev/null @@ -1,37 +0,0 @@ - - - -# account<T extends AuthenticationCubit<Data>, Data> method - - - - - *[](https://dart.dev/null-safety)* - - - - -[Account](../../wyatt_authentication_bloc/Account-class.md)? account -<T extends AuthenticationCubit<Data>, Data>() - - - - - -

Returns account

- - - -## Implementation - -```dart -Account? account, Data>() => - watch().currentSession()?.session?.account; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BuildContextExtension/data.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BuildContextExtension/data.md deleted file mode 100644 index 1958e209..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BuildContextExtension/data.md +++ /dev/null @@ -1,37 +0,0 @@ - - - -# data<T extends AuthenticationCubit<Data>, Data> method - - - - - *[](https://dart.dev/null-safety)* - - - - -Data? data -<T extends AuthenticationCubit<Data>, Data>() - - - - - -

Returns associated data

- - - -## Implementation - -```dart -Data? data, Data>() => - watch().currentSession()?.session?.data; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BuildContextExtension/session.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BuildContextExtension/session.md deleted file mode 100644 index 2d5d16b1..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BuildContextExtension/session.md +++ /dev/null @@ -1,37 +0,0 @@ - - - -# session<T extends AuthenticationCubit<Data>, Data> method - - - - - *[](https://dart.dev/null-safety)* - - - - -[Session](../../wyatt_authentication_bloc/Session-class.md)<Data>? session -<T extends AuthenticationCubit<Data>, Data>() - - - - - -

Returns session

- - - -## Implementation - -```dart -Session? session, Data>() => - watch().currentSession()?.session; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BuildContextExtension/wrapper.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BuildContextExtension/wrapper.md deleted file mode 100644 index edeb2c9e..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/BuildContextExtension/wrapper.md +++ /dev/null @@ -1,37 +0,0 @@ - - - -# wrapper<T extends AuthenticationCubit<Data>, Data> method - - - - - *[](https://dart.dev/null-safety)* - - - - -[SessionWrapper](../../wyatt_authentication_bloc/SessionWrapper-class.md)<Data>? wrapper -<T extends AuthenticationCubit<Data>, Data>() - - - - - -

Returns session wrapper

- - - -## Implementation - -```dart -SessionWrapper? wrapper, Data>() => - watch().currentSession(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ConfirmPasswordResetFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ConfirmPasswordResetFailureFirebase-class.md deleted file mode 100644 index a9608f3c..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ConfirmPasswordResetFailureFirebase-class.md +++ /dev/null @@ -1,137 +0,0 @@ - - - -# ConfirmPasswordResetFailureFirebase class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown during the password reset process if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- [ConfirmPasswordResetFailureInterface](../wyatt_authentication_bloc/ConfirmPasswordResetFailureInterface-class.md) -- ConfirmPasswordResetFailureFirebase - - - - - - - - -## Constructors - -[ConfirmPasswordResetFailureFirebase](../wyatt_authentication_bloc/ConfirmPasswordResetFailureFirebase/ConfirmPasswordResetFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - -[ConfirmPasswordResetFailureFirebase.fromCode](../wyatt_authentication_bloc/ConfirmPasswordResetFailureFirebase/ConfirmPasswordResetFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ConfirmPasswordResetFailureFirebase/ConfirmPasswordResetFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ConfirmPasswordResetFailureFirebase/ConfirmPasswordResetFailureFirebase.fromCode.md deleted file mode 100644 index 4d51aa2d..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ConfirmPasswordResetFailureFirebase/ConfirmPasswordResetFailureFirebase.fromCode.md +++ /dev/null @@ -1,30 +0,0 @@ - - - -# ConfirmPasswordResetFailureFirebase.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -ConfirmPasswordResetFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - - -## Implementation - -```dart -ConfirmPasswordResetFailureFirebase.fromCode(super.code) : super.fromCode(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ConfirmPasswordResetFailureFirebase/ConfirmPasswordResetFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ConfirmPasswordResetFailureFirebase/ConfirmPasswordResetFailureFirebase.md deleted file mode 100644 index 97e8c31a..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ConfirmPasswordResetFailureFirebase/ConfirmPasswordResetFailureFirebase.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# ConfirmPasswordResetFailureFirebase constructor - - - - - *[](https://dart.dev/null-safety)* - - - -ConfirmPasswordResetFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - - - -## Implementation - -```dart -ConfirmPasswordResetFailureFirebase([String? code, String? msg]) - : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ConfirmPasswordResetFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ConfirmPasswordResetFailureInterface-class.md deleted file mode 100644 index 29578d9c..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ConfirmPasswordResetFailureInterface-class.md +++ /dev/null @@ -1,139 +0,0 @@ - - - -# ConfirmPasswordResetFailureInterface class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown during the password reset process if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- ConfirmPasswordResetFailureInterface - - - -**Implementers** - -- [ConfirmPasswordResetFailureFirebase](../wyatt_authentication_bloc/ConfirmPasswordResetFailureFirebase-class.md) - - - - - -## Constructors - -[ConfirmPasswordResetFailureInterface](../wyatt_authentication_bloc/ConfirmPasswordResetFailureInterface/ConfirmPasswordResetFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - -Thrown during the password reset process if a failure occurs. - -[ConfirmPasswordResetFailureInterface.fromCode](../wyatt_authentication_bloc/ConfirmPasswordResetFailureInterface/ConfirmPasswordResetFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - -Thrown during the password reset process if a failure occurs. - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ConfirmPasswordResetFailureInterface/ConfirmPasswordResetFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ConfirmPasswordResetFailureInterface/ConfirmPasswordResetFailureInterface.fromCode.md deleted file mode 100644 index c0177f60..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ConfirmPasswordResetFailureInterface/ConfirmPasswordResetFailureInterface.fromCode.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# ConfirmPasswordResetFailureInterface.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -ConfirmPasswordResetFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - -

Thrown during the password reset process if a failure occurs.

- - - -## Implementation - -```dart -ConfirmPasswordResetFailureInterface.fromCode(super.code) : super.fromCode(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ConfirmPasswordResetFailureInterface/ConfirmPasswordResetFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ConfirmPasswordResetFailureInterface/ConfirmPasswordResetFailureInterface.md deleted file mode 100644 index 585e23fc..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ConfirmPasswordResetFailureInterface/ConfirmPasswordResetFailureInterface.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# ConfirmPasswordResetFailureInterface constructor - - - - - *[](https://dart.dev/null-safety)* - - - -ConfirmPasswordResetFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - - -

Thrown during the password reset process if a failure occurs.

- - - -## Implementation - -```dart -ConfirmPasswordResetFailureInterface(super.code, super.msg); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine-class.md deleted file mode 100644 index 8d140161..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine-class.md +++ /dev/null @@ -1,139 +0,0 @@ - - - -# CustomRoutine<R, Data> class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Calls on each cubit action of this package.

-

Useful to register custom logic on pre-implemented logic.

- - - - -## Constructors - -[CustomRoutine](../wyatt_authentication_bloc/CustomRoutine/CustomRoutine.md) ({required [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<Result<R, AppException>> routine(), required [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<Result<Data?, AppException>> attachedLogic(Result<R, AppException> routineResult), required void onError(AppException exception), required void onSuccess(R result, Data? data)}) - - _const_ - - -## Properties - -##### [attachedLogic](../wyatt_authentication_bloc/CustomRoutine/attachedLogic.md) → [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<Result<Data?, AppException>> Function(Result<R, AppException> routineResult) - - - - -_final_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [onError](../wyatt_authentication_bloc/CustomRoutine/onError.md) → void Function(AppException exception) - - - - -_final_ - - - -##### [onSuccess](../wyatt_authentication_bloc/CustomRoutine/onSuccess.md) → void Function(R result, Data? data) - - - - -_final_ - - - -##### [routine](../wyatt_authentication_bloc/CustomRoutine/routine.md) → [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<Result<R, AppException>> Function() - - - - -_final_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [call](../wyatt_authentication_bloc/CustomRoutine/call.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - - - - - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine/CustomRoutine.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine/CustomRoutine.md deleted file mode 100644 index 4e771554..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine/CustomRoutine.md +++ /dev/null @@ -1,35 +0,0 @@ - - - -# CustomRoutine<R, Data> constructor - - - - - *[](https://dart.dev/null-safety)* - - -const -CustomRoutine<R, Data>({required [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<Result<R, AppException>> routine(), required [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<Result<Data?, AppException>> attachedLogic(Result<R, AppException> routineResult), required void onError(AppException exception), required void onSuccess(R result, Data? data)}) - - - - - -## Implementation - -```dart -const CustomRoutine({ - required this.routine, - required this.attachedLogic, - required this.onError, - required this.onSuccess, -}); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine/attachedLogic.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine/attachedLogic.md deleted file mode 100644 index 0486eb86..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine/attachedLogic.md +++ /dev/null @@ -1,35 +0,0 @@ - - - -# attachedLogic property - - - - - *[](https://dart.dev/null-safety)* - - - -[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<Result<Data?, AppException>> Function(Result<R, AppException> routineResult) attachedLogic - -_final_ - - - - - - -## Implementation - -```dart -final FutureOr> Function( - Result routineResult, -) attachedLogic; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine/call.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine/call.md deleted file mode 100644 index a03b3b8b..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine/call.md +++ /dev/null @@ -1,55 +0,0 @@ - - - -# call method - - - - - *[](https://dart.dev/null-safety)* - - - - -[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> call -() - - - - - - - - -## Implementation - -```dart -FutureOr call() async { - final result = await routine.call(); - - // Call custom logic - final customRoutineResult = await attachedLogic.call(result); - - // Check for errors - if (result.isErr) { - onError.call(result.err!); - - return; - } - if (customRoutineResult.isErr) { - onError.call(customRoutineResult.err!); - - return; - } - - // If no error - return onSuccess.call(result.ok as R, customRoutineResult.ok); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine/onError.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine/onError.md deleted file mode 100644 index 540b3834..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine/onError.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# onError property - - - - - *[](https://dart.dev/null-safety)* - - - -void Function(AppException exception) onError - -_final_ - - - - - - -## Implementation - -```dart -final void Function(AppException exception) onError; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine/onSuccess.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine/onSuccess.md deleted file mode 100644 index 0232c8c7..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine/onSuccess.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# onSuccess property - - - - - *[](https://dart.dev/null-safety)* - - - -void Function(R result, Data? data) onSuccess - -_final_ - - - - - - -## Implementation - -```dart -final void Function(R result, Data? data) onSuccess; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine/routine.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine/routine.md deleted file mode 100644 index 9359edea..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/CustomRoutine/routine.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# routine property - - - - - *[](https://dart.dev/null-safety)* - - - -[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<Result<R, AppException>> Function() routine - -_final_ - - - - - - -## Implementation - -```dart -final FutureOr> Function() routine; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeleteAccountFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeleteAccountFailureFirebase-class.md deleted file mode 100644 index b7283c93..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeleteAccountFailureFirebase-class.md +++ /dev/null @@ -1,137 +0,0 @@ - - - -# DeleteAccountFailureFirebase class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown during the account deletion if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- [DeleteAccountFailureInterface](../wyatt_authentication_bloc/DeleteAccountFailureInterface-class.md) -- DeleteAccountFailureFirebase - - - - - - - - -## Constructors - -[DeleteAccountFailureFirebase](../wyatt_authentication_bloc/DeleteAccountFailureFirebase/DeleteAccountFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - -[DeleteAccountFailureFirebase.fromCode](../wyatt_authentication_bloc/DeleteAccountFailureFirebase/DeleteAccountFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeleteAccountFailureFirebase/DeleteAccountFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeleteAccountFailureFirebase/DeleteAccountFailureFirebase.fromCode.md deleted file mode 100644 index 8c43e144..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeleteAccountFailureFirebase/DeleteAccountFailureFirebase.fromCode.md +++ /dev/null @@ -1,39 +0,0 @@ - - - -# DeleteAccountFailureFirebase.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -DeleteAccountFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - - -## Implementation - -```dart -DeleteAccountFailureFirebase.fromCode(String code) : super.fromCode(code) { - switch (code) { - case 'requires-recent-login': - msg = "User's last sign-in time does not meet the security threshold."; - break; - default: - this.code = 'unknown'; - msg = 'An unknown error occurred.'; - } -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeleteAccountFailureFirebase/DeleteAccountFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeleteAccountFailureFirebase/DeleteAccountFailureFirebase.md deleted file mode 100644 index e9be7130..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeleteAccountFailureFirebase/DeleteAccountFailureFirebase.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# DeleteAccountFailureFirebase constructor - - - - - *[](https://dart.dev/null-safety)* - - - -DeleteAccountFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - - - -## Implementation - -```dart -DeleteAccountFailureFirebase([String? code, String? msg]) - : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeleteAccountFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeleteAccountFailureInterface-class.md deleted file mode 100644 index 78a6a6f7..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeleteAccountFailureInterface-class.md +++ /dev/null @@ -1,139 +0,0 @@ - - - -# DeleteAccountFailureInterface class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown during the account deletion if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- DeleteAccountFailureInterface - - - -**Implementers** - -- [DeleteAccountFailureFirebase](../wyatt_authentication_bloc/DeleteAccountFailureFirebase-class.md) - - - - - -## Constructors - -[DeleteAccountFailureInterface](../wyatt_authentication_bloc/DeleteAccountFailureInterface/DeleteAccountFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - - - -[DeleteAccountFailureInterface.fromCode](../wyatt_authentication_bloc/DeleteAccountFailureInterface/DeleteAccountFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeleteAccountFailureInterface/DeleteAccountFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeleteAccountFailureInterface/DeleteAccountFailureInterface.fromCode.md deleted file mode 100644 index 7e18dc37..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeleteAccountFailureInterface/DeleteAccountFailureInterface.fromCode.md +++ /dev/null @@ -1,30 +0,0 @@ - - - -# DeleteAccountFailureInterface.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -DeleteAccountFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - - -## Implementation - -```dart -DeleteAccountFailureInterface.fromCode(super.code) : super.fromCode(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeleteAccountFailureInterface/DeleteAccountFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeleteAccountFailureInterface/DeleteAccountFailureInterface.md deleted file mode 100644 index 09759d9d..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeleteAccountFailureInterface/DeleteAccountFailureInterface.md +++ /dev/null @@ -1,30 +0,0 @@ - - - -# DeleteAccountFailureInterface constructor - - - - - *[](https://dart.dev/null-safety)* - - - -DeleteAccountFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - - - - - -## Implementation - -```dart -DeleteAccountFailureInterface(super.code, super.msg); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeletedEvent-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeletedEvent-class.md deleted file mode 100644 index 9ada8b22..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeletedEvent-class.md +++ /dev/null @@ -1,126 +0,0 @@ - - - -# DeletedEvent class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

When a user deleted his account.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [Equatable](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable-class.html) -- [AuthenticationChangeEvent](../wyatt_authentication_bloc/AuthenticationChangeEvent-class.md) -- DeletedEvent - - - - - - - - -## Constructors - -[DeletedEvent](../wyatt_authentication_bloc/DeletedEvent/DeletedEvent.md) () - - _const_ - - -## Properties - -##### [hashCode](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [props](../wyatt_authentication_bloc/AuthenticationChangeEvent/props.md) → [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> - - - -The list of properties that will be used to determine whether -two instances are equal. -_read-onlyinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - -##### [stringify](../wyatt_authentication_bloc/AuthenticationChangeEvent/stringify.md) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -If set to true, the toString method will be overridden to output -this instance's props. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeletedEvent/DeletedEvent.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeletedEvent/DeletedEvent.md deleted file mode 100644 index 3d031272..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/DeletedEvent/DeletedEvent.md +++ /dev/null @@ -1,30 +0,0 @@ - - - -# DeletedEvent constructor - - - - - *[](https://dart.dev/null-safety)* - - -const -DeletedEvent() - - - - - -## Implementation - -```dart -const DeletedEvent(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountCubit-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountCubit-class.md deleted file mode 100644 index 34e20299..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountCubit-class.md +++ /dev/null @@ -1,335 +0,0 @@ - - - -# EditAccountCubit<Data> class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Fully featured edit account cubit.

-

Sufficient in most cases. (Where fine granularity is not required.)

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [BlocBase](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase-class.html)<[EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md)> -- [Cubit](https://pub.dev/documentation/bloc/8.1.0/bloc/Cubit-class.html)<[EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md)> -- [BaseEditAccountCubit](../wyatt_authentication_bloc/BaseEditAccountCubit-class.md)<Data> -- EditAccountCubit - - -**Mixed in types** - -- [UpdateEmail](../wyatt_authentication_bloc/UpdateEmail-mixin.md)<Data> -- [UpdatePassword](../wyatt_authentication_bloc/UpdatePassword-mixin.md)<Data> - - - - - - -## Constructors - -[EditAccountCubit](../wyatt_authentication_bloc/EditAccountCubit/EditAccountCubit.md) ({required [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> authenticationRepository}) - - - - -## Properties - -##### [authenticationRepository](../wyatt_authentication_bloc/BaseEditAccountCubit/authenticationRepository.md) → [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> - - - - -_finalinherited_ - - - -##### [formName](../wyatt_authentication_bloc/BaseEditAccountCubit/formName.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [formRepository](../wyatt_authentication_bloc/BaseEditAccountCubit/formRepository.md) → FormRepository - - - - -_read-onlyinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [isClosed](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/isClosed.html) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -Whether the bloc is closed. -_read-onlyinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - -##### [state](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/state.html) → [EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md) - - - -The current state. -_read-onlyinherited_ - - - -##### [stream](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/stream.html) → [Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md)> - - - -The current stream of states. -_read-onlyinherited_ - - - - - -## Methods - -##### [addError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/addError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [[StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html)? stackTrace]) void - - - -Reports an error which triggers onError with an optional StackTrace. -_inherited_ - - - -##### [close](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/close.html)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> - - - -Closes the instance. -This method should be called when the instance is no longer needed. -Once close is called, the instance can no longer be used. -_inherited_ - - - -##### [dataChanged](../wyatt_authentication_bloc/BaseEditAccountCubit/dataChanged.md)<Value>([String](https://api.flutter.dev/flutter/dart-core/String-class.html) key, FormInputValidator<Value, ValidationError> dirtyValue) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - -##### [emailChanged](../wyatt_authentication_bloc/UpdateEmail/emailChanged.md)([String](https://api.flutter.dev/flutter/dart-core/String-class.html) value) void - - - - -_inherited_ - - - -##### [emailCustomChanged](../wyatt_authentication_bloc/UpdateEmail/emailCustomChanged.md)<Validator extends FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError>>(Validator validator) void - - - -Same as emailChanged but with a custom Validator. -_inherited_ - - - -##### [emit](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/emit.html)([EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md) state) void - - - -Updates the state to the provided state. -emit does nothing if the state being emitted -is equal to the current state. -_inherited_ - - - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [onChange](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onChange.html)([Change](https://pub.dev/documentation/bloc/8.1.0/bloc/Change-class.html)<[EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md)> change) void - - - -Called whenever a change occurs with the given change. -A change occurs when a new state is emitted. -onChange is called before the state of the cubit is updated. -onChange is a great spot to add logging/analytics for a specific cubit. -_inherited_ - - - -##### [onEmailUpdated](../wyatt_authentication_bloc/EditAccountCubit/onEmailUpdated.md)(Result<[Account](../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) FutureOrResult<Data?> - - - -This callback is triggered when user updates his email -_override_ - - - -##### [onError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html) stackTrace) void - - - -Called whenever an error occurs and notifies BlocObserver.onError. -_inherited_ - - - -##### [onPasswordUpdated](../wyatt_authentication_bloc/EditAccountCubit/onPasswordUpdated.md)(Result<[Account](../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) FutureOrResult<Data?> - - - -This callback is triggered when a user edits his password. -_override_ - - - -##### [passwordChanged](../wyatt_authentication_bloc/UpdatePassword/passwordChanged.md)([String](https://api.flutter.dev/flutter/dart-core/String-class.html) value) void - - - - -_inherited_ - - - -##### [passwordCustomChanged](../wyatt_authentication_bloc/UpdatePassword/passwordCustomChanged.md)<Validator extends FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError>>(Validator validator) void - - - -Same as passwordChanged but with a custom Validator. -_inherited_ - - - -##### [reset](../wyatt_authentication_bloc/BaseEditAccountCubit/reset.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - -##### [submit](../wyatt_authentication_bloc/BaseEditAccountCubit/submit.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - -##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - -##### [update](../wyatt_authentication_bloc/BaseEditAccountCubit/update.md)(WyattForm form, {SetOperation operation = SetOperation.replace}) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - -##### [updateEmail](../wyatt_authentication_bloc/UpdateEmail/updateEmail.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - -Update or add email. -_inherited_ - - - -##### [updatePassword](../wyatt_authentication_bloc/UpdatePassword/updatePassword.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - -Update or add password. -_inherited_ - - - -##### [validate](../wyatt_authentication_bloc/BaseEditAccountCubit/validate.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountCubit/EditAccountCubit.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountCubit/EditAccountCubit.md deleted file mode 100644 index 801c095c..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountCubit/EditAccountCubit.md +++ /dev/null @@ -1,30 +0,0 @@ - - - -# EditAccountCubit<Data> constructor - - - - - *[](https://dart.dev/null-safety)* - - - -EditAccountCubit<Data>({required [AuthenticationRepository](../../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> authenticationRepository}) - - - - - -## Implementation - -```dart -EditAccountCubit({required super.authenticationRepository}); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountCubit/onEmailUpdated.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountCubit/onEmailUpdated.md deleted file mode 100644 index bc18c4b1..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountCubit/onEmailUpdated.md +++ /dev/null @@ -1,42 +0,0 @@ - - - -# onEmailUpdated method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -FutureOrResult<Data?> onEmailUpdated -(Result<[Account](../../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) - -_override_ - - - -

This callback is triggered when user updates his email

- - - -## Implementation - -```dart -@override -FutureOrResult onEmailUpdated( - Result result, - WyattForm form, -) => - const Ok(null); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountCubit/onPasswordUpdated.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountCubit/onPasswordUpdated.md deleted file mode 100644 index c506f486..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountCubit/onPasswordUpdated.md +++ /dev/null @@ -1,42 +0,0 @@ - - - -# onPasswordUpdated method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -FutureOrResult<Data?> onPasswordUpdated -(Result<[Account](../../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) - -_override_ - - - -

This callback is triggered when a user edits his password.

- - - -## Implementation - -```dart -@override -FutureOrResult onPasswordUpdated( - Result result, - WyattForm form, -) => - const Ok(null); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener-class.md deleted file mode 100644 index a6da474c..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener-class.md +++ /dev/null @@ -1,236 +0,0 @@ - - - -# EditAccountListener<Data> class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Widget that listens and builds a child based on the state of -the edit account cubit

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [DiagnosticableTree](https://api.flutter.dev/flutter/foundation/DiagnosticableTree-class.html) -- [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) -- [StatelessWidget](https://api.flutter.dev/flutter/widgets/StatelessWidget-class.html) -- EditAccountListener - - - - - - - - -## Constructors - -[EditAccountListener](../wyatt_authentication_bloc/EditAccountListener/EditAccountListener.md) ({required [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) child, void onProgress([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?, void onSuccess([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?, void onError([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, FormStatus status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage)?, void customBuilder([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, [EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md) state)?, [Key](https://api.flutter.dev/flutter/foundation/Key-class.html)? key}) - - _const_ - - -## Properties - -##### [child](../wyatt_authentication_bloc/EditAccountListener/child.md) → [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) - - - - -_final_ - - - -##### [customBuilder](../wyatt_authentication_bloc/EditAccountListener/customBuilder.md) → (void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, [EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md) state)?) - - - - -_final_ - - - -##### [hashCode](https://api.flutter.dev/flutter/widgets/Widget/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [key](https://api.flutter.dev/flutter/widgets/Widget/key.html) → [Key](https://api.flutter.dev/flutter/foundation/Key-class.html)? - - - -Controls how one widget replaces another widget in the tree. -_finalinherited_ - - - -##### [onError](../wyatt_authentication_bloc/EditAccountListener/onError.md) → (void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, FormStatus status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage)?) - - - - -_final_ - - - -##### [onProgress](../wyatt_authentication_bloc/EditAccountListener/onProgress.md) → (void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?) - - - - -_final_ - - - -##### [onSuccess](../wyatt_authentication_bloc/EditAccountListener/onSuccess.md) → (void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?) - - - - -_final_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [build](../wyatt_authentication_bloc/EditAccountListener/build.md)([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context) [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) - - - -Describes the part of the user interface represented by this widget. -_override_ - - - -##### [createElement](https://api.flutter.dev/flutter/widgets/StatelessWidget/createElement.html)() [StatelessElement](https://api.flutter.dev/flutter/widgets/StatelessElement-class.html) - - - -Creates a StatelessElement to manage this widget's location in the tree. -_inherited_ - - - -##### [debugDescribeChildren](https://api.flutter.dev/flutter/foundation/DiagnosticableTree/debugDescribeChildren.html)() [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[DiagnosticsNode](https://api.flutter.dev/flutter/foundation/DiagnosticsNode-class.html)> - - - -Returns a list of DiagnosticsNode objects describing this node's -children. -_inherited_ - - - -##### [debugFillProperties](https://api.flutter.dev/flutter/widgets/Widget/debugFillProperties.html)([DiagnosticPropertiesBuilder](https://api.flutter.dev/flutter/foundation/DiagnosticPropertiesBuilder-class.html) properties) void - - - -Add additional properties associated with the node. -_inherited_ - - - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toDiagnosticsNode](https://api.flutter.dev/flutter/foundation/DiagnosticableTree/toDiagnosticsNode.html)({[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? name, [DiagnosticsTreeStyle](https://api.flutter.dev/flutter/foundation/DiagnosticsTreeStyle.html)? style}) [DiagnosticsNode](https://api.flutter.dev/flutter/foundation/DiagnosticsNode-class.html) - - - -Returns a debug representation of the object that is used by debugging -tools and by DiagnosticsNode.toStringDeep. -_inherited_ - - - -##### [toString](https://api.flutter.dev/flutter/foundation/Diagnosticable/toString.html)({[DiagnosticLevel](https://api.flutter.dev/flutter/foundation/DiagnosticLevel.html) minLevel = DiagnosticLevel.info}) [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - -##### [toStringDeep](https://api.flutter.dev/flutter/foundation/DiagnosticableTree/toStringDeep.html)({[String](https://api.flutter.dev/flutter/dart-core/String-class.html) prefixLineOne = '', [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? prefixOtherLines, [DiagnosticLevel](https://api.flutter.dev/flutter/foundation/DiagnosticLevel.html) minLevel = DiagnosticLevel.debug}) [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -Returns a string representation of this node and its descendants. -_inherited_ - - - -##### [toStringShallow](https://api.flutter.dev/flutter/foundation/DiagnosticableTree/toStringShallow.html)({[String](https://api.flutter.dev/flutter/dart-core/String-class.html) joiner = ', ', [DiagnosticLevel](https://api.flutter.dev/flutter/foundation/DiagnosticLevel.html) minLevel = DiagnosticLevel.debug}) [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -Returns a one-line detailed description of the object. -_inherited_ - - - -##### [toStringShort](https://api.flutter.dev/flutter/widgets/Widget/toStringShort.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A short, textual description of this widget. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/widgets/Widget/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/EditAccountListener.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/EditAccountListener.md deleted file mode 100644 index ec51cd1d..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/EditAccountListener.md +++ /dev/null @@ -1,37 +0,0 @@ - - - -# EditAccountListener<Data> constructor - - - - - *[](https://dart.dev/null-safety)* - - -const -EditAccountListener<Data>({required [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) child, void onProgress([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?, void onSuccess([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?, void onError([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, FormStatus status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage)?, void customBuilder([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, [EditAccountState](../../wyatt_authentication_bloc/EditAccountState-class.md) state)?, [Key](https://api.flutter.dev/flutter/foundation/Key-class.html)? key}) - - - - - -## Implementation - -```dart -const EditAccountListener({ - required this.child, - this.onProgress, - this.onSuccess, - this.onError, - this.customBuilder, - super.key, -}); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/build.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/build.md deleted file mode 100644 index 03d55600..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/build.md +++ /dev/null @@ -1,92 +0,0 @@ - - - -# build method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) build -([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context) - -_override_ - - - -

Describes the part of the user interface represented by this widget.

-

The framework calls this method when this widget is inserted into the tree -in a given BuildContext and when the dependencies of this widget change -(e.g., an InheritedWidget referenced by this widget changes). This -method can potentially be called in every frame and should not have any side -effects beyond building a widget.

-

The framework replaces the subtree below this widget with the widget -returned by this method, either by updating the existing subtree or by -removing the subtree and inflating a new subtree, depending on whether the -widget returned by this method can update the root of the existing -subtree, as determined by calling Widget.canUpdate.

-

Typically implementations return a newly created constellation of widgets -that are configured with information from this widget's constructor and -from the given BuildContext.

-

The given BuildContext contains information about the location in the -tree at which this widget is being built. For example, the context -provides the set of inherited widgets for this location in the tree. A -given widget might be built with multiple different BuildContext -arguments over time if the widget is moved around the tree or if the -widget is inserted into the tree in multiple places at once.

-

The implementation of this method must only depend on:

- -

If a widget's build method is to depend on anything else, use a -StatefulWidget instead.

-

See also:

-
    -
  • StatelessWidget, which contains the discussion on performance considerations.
  • -
- - - -## Implementation - -```dart -@override -Widget build(BuildContext context) => - BlocListener, EditAccountState>( - listener: (context, state) { - if (customBuilder != null) { - return customBuilder!(context, state); - } - - if (onSuccess != null && - state.status == FormStatus.submissionSuccess) { - return onSuccess!(context); - } - if (onProgress != null && - state.status == FormStatus.submissionInProgress) { - return onProgress!(context); - } - if (onError != null && - (state.status == FormStatus.submissionCanceled || - state.status == FormStatus.submissionFailure)) { - return onError!(context, state.status, state.errorMessage); - } - }, - child: child, - ); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/child.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/child.md deleted file mode 100644 index 53bc3682..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/child.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# child property - - - - - *[](https://dart.dev/null-safety)* - - - -[Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) child - -_final_ - - - - - - -## Implementation - -```dart -final Widget child; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/customBuilder.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/customBuilder.md deleted file mode 100644 index a8d52a8d..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/customBuilder.md +++ /dev/null @@ -1,34 +0,0 @@ - - - -# customBuilder property - - - - - *[](https://dart.dev/null-safety)* - - - -(void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, [EditAccountState](../../wyatt_authentication_bloc/EditAccountState-class.md) state)?) customBuilder - -_final_ - - - - - - -## Implementation - -```dart -final void Function(BuildContext context, EditAccountState state)? - customBuilder; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/onError.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/onError.md deleted file mode 100644 index ed94a98f..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/onError.md +++ /dev/null @@ -1,37 +0,0 @@ - - - -# onError property - - - - - *[](https://dart.dev/null-safety)* - - - -(void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, FormStatus status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage)?) onError - -_final_ - - - - - - -## Implementation - -```dart -final void Function( - BuildContext context, - FormStatus status, - String? errorMessage, -)? onError; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/onProgress.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/onProgress.md deleted file mode 100644 index 4a30ed71..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/onProgress.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# onProgress property - - - - - *[](https://dart.dev/null-safety)* - - - -(void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?) onProgress - -_final_ - - - - - - -## Implementation - -```dart -final void Function(BuildContext context)? onProgress; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/onSuccess.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/onSuccess.md deleted file mode 100644 index 4d942f63..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountListener/onSuccess.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# onSuccess property - - - - - *[](https://dart.dev/null-safety)* - - - -(void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?) onSuccess - -_final_ - - - - - - -## Implementation - -```dart -final void Function(BuildContext context)? onSuccess; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState-class.md deleted file mode 100644 index 9c7250d8..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState-class.md +++ /dev/null @@ -1,179 +0,0 @@ - - - -# EditAccountState class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Edit account cubit state to manage the form.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [Equatable](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable-class.html) -- EditAccountState - - - - - - - - -## Constructors - -[EditAccountState](../wyatt_authentication_bloc/EditAccountState/EditAccountState.md) ({required WyattForm form, FormStatus status = FormStatus.pure, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage}) - - _const_ - - -## Properties - -##### [email](../wyatt_authentication_bloc/EditAccountState/email.md) → FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError> - - - - -_read-only_ - - - -##### [errorMessage](../wyatt_authentication_bloc/EditAccountState/errorMessage.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? - - - -Optional error message. -_finalinherited_ - - - -##### [form](../wyatt_authentication_bloc/EditAccountState/form.md) → WyattForm - - - -FormData with all inputs, and associated metadata. -_finalinherited_ - - - -##### [hashCode](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [password](../wyatt_authentication_bloc/EditAccountState/password.md) → FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError> - - - - -_read-only_ - - - -##### [props](../wyatt_authentication_bloc/EditAccountState/props.md) → [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)> - - - -The list of properties that will be used to determine whether -two instances are equal. -_read-only_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - -##### [status](../wyatt_authentication_bloc/EditAccountState/status.md) → FormStatus - - - -Global status of a form. -_finalinherited_ - - - -##### [stringify](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/stringify.html) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)? - - - -If set to true, the toString method will be overridden to output -this instance's props. -_read-onlyinherited_ - - - - - -## Methods - -##### [copyWith](../wyatt_authentication_bloc/EditAccountState/copyWith.md)({WyattForm? form, FormStatus? status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage}) [EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md) - - - - - - - - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/EditAccountState/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_override_ - - - - - -## Operators - -##### [operator ==](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/EditAccountState.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/EditAccountState.md deleted file mode 100644 index b8145411..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/EditAccountState.md +++ /dev/null @@ -1,34 +0,0 @@ - - - -# EditAccountState constructor - - - - - *[](https://dart.dev/null-safety)* - - -const -EditAccountState({required WyattForm form, FormStatus status = FormStatus.pure, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage}) - - - - - -## Implementation - -```dart -const EditAccountState({ - required super.form, - super.status = FormStatus.pure, - super.errorMessage, -}); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/copyWith.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/copyWith.md deleted file mode 100644 index aed8958b..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/copyWith.md +++ /dev/null @@ -1,44 +0,0 @@ - - - -# copyWith method - - - - - *[](https://dart.dev/null-safety)* - - - - -[EditAccountState](../../wyatt_authentication_bloc/EditAccountState-class.md) copyWith -({WyattForm? form, FormStatus? status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage}) - - - - - - - - -## Implementation - -```dart -EditAccountState copyWith({ - WyattForm? form, - FormStatus? status, - String? errorMessage, -}) => - EditAccountState( - form: form ?? this.form, - status: status ?? this.status, - errorMessage: errorMessage ?? this.errorMessage, - ); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/email.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/email.md deleted file mode 100644 index 1ded8043..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/email.md +++ /dev/null @@ -1,37 +0,0 @@ - - - -# email property - - - - - *[](https://dart.dev/null-safety)* - - - - - -FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError> email - - - - - - - - -## Implementation - -```dart -FormInputValidator get email => - form.validatorOf(AuthFormField.email); -``` - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/errorMessage.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/errorMessage.md deleted file mode 100644 index d0856deb..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/errorMessage.md +++ /dev/null @@ -1,34 +0,0 @@ - - - -# errorMessage property - - - - - *[](https://dart.dev/null-safety)* - - - -[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage - -_finalinherited_ - - - -

Optional error message.

- - - -## Implementation - -```dart -final String? errorMessage; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/form.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/form.md deleted file mode 100644 index d3f2da76..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/form.md +++ /dev/null @@ -1,34 +0,0 @@ - - - -# form property - - - - - *[](https://dart.dev/null-safety)* - - - -WyattForm form - -_finalinherited_ - - - -

FormData with all inputs, and associated metadata.

- - - -## Implementation - -```dart -final WyattForm form; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/password.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/password.md deleted file mode 100644 index 77938106..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/password.md +++ /dev/null @@ -1,37 +0,0 @@ - - - -# password property - - - - - *[](https://dart.dev/null-safety)* - - - - - -FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError> password - - - - - - - - -## Implementation - -```dart -FormInputValidator get password => - form.validatorOf(AuthFormField.password); -``` - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/props.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/props.md deleted file mode 100644 index eab8d26c..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/props.md +++ /dev/null @@ -1,42 +0,0 @@ - - - -# props property - - - - - *[](https://dart.dev/null-safety)* - - - - - -**Annotations** - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) -[List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)> props - - - - - -

The list of properties that will be used to determine whether -two instances are equal.

- - - -## Implementation - -```dart -@override -List get props => [email, password, status]; -``` - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/status.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/status.md deleted file mode 100644 index 644a9f10..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/status.md +++ /dev/null @@ -1,34 +0,0 @@ - - - -# status property - - - - - *[](https://dart.dev/null-safety)* - - - -FormStatus status - -_finalinherited_ - - - -

Global status of a form.

- - - -## Implementation - -```dart -final FormStatus status; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/toString.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/toString.md deleted file mode 100644 index 3a837f4e..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EditAccountState/toString.md +++ /dev/null @@ -1,48 +0,0 @@ - - - -# toString method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[String](https://api.flutter.dev/flutter/dart-core/String-class.html) toString -() - -_override_ - - - -

A string representation of this object.

-

Some classes have a default textual representation, -often paired with a static parse function (like int.parse). -These classes will provide the textual representation as -their string representation.

-

Other classes have no meaningful textual representation -that a program will care about. -Such classes will typically override toString to provide -useful information when inspecting the object, -mainly for debugging or logging.

- - - -## Implementation - -```dart -@override -String toString() => 'EditAccountState(status: ${status.name} ' - '${(errorMessage != null) ? " [$errorMessage]" : ""}, $form)'; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder-class.md deleted file mode 100644 index 5692d1ab..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder-class.md +++ /dev/null @@ -1,225 +0,0 @@ - - - -# EmailVerificationBuilder<Extra> class - - - - - - - *[](https://dart.dev/null-safety)* - - - - - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [DiagnosticableTree](https://api.flutter.dev/flutter/foundation/DiagnosticableTree-class.html) -- [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) -- [StatelessWidget](https://api.flutter.dev/flutter/widgets/StatelessWidget-class.html) -- EmailVerificationBuilder - - - - - - - - -## Constructors - -[EmailVerificationBuilder](../wyatt_authentication_bloc/EmailVerificationBuilder/EmailVerificationBuilder.md) ({required [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) verified([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context), required [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) notVerified([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context), required [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) onError([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, FormStatus status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage), [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) customBuilder([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, [EmailVerificationState](../wyatt_authentication_bloc/EmailVerificationState-class.md))?, [Key](https://api.flutter.dev/flutter/foundation/Key-class.html)? key}) - - _const_ - - -## Properties - -##### [customBuilder](../wyatt_authentication_bloc/EmailVerificationBuilder/customBuilder.md) → ([Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, [EmailVerificationState](../wyatt_authentication_bloc/EmailVerificationState-class.md))?) - - - - -_final_ - - - -##### [hashCode](https://api.flutter.dev/flutter/widgets/Widget/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [key](https://api.flutter.dev/flutter/widgets/Widget/key.html) → [Key](https://api.flutter.dev/flutter/foundation/Key-class.html)? - - - -Controls how one widget replaces another widget in the tree. -_finalinherited_ - - - -##### [notVerified](../wyatt_authentication_bloc/EmailVerificationBuilder/notVerified.md) → [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context) - - - - -_final_ - - - -##### [onError](../wyatt_authentication_bloc/EmailVerificationBuilder/onError.md) → [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, FormStatus status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage) - - - - -_final_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - -##### [verified](../wyatt_authentication_bloc/EmailVerificationBuilder/verified.md) → [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context) - - - - -_final_ - - - - - -## Methods - -##### [build](../wyatt_authentication_bloc/EmailVerificationBuilder/build.md)([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context) [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) - - - -Describes the part of the user interface represented by this widget. -_override_ - - - -##### [createElement](https://api.flutter.dev/flutter/widgets/StatelessWidget/createElement.html)() [StatelessElement](https://api.flutter.dev/flutter/widgets/StatelessElement-class.html) - - - -Creates a StatelessElement to manage this widget's location in the tree. -_inherited_ - - - -##### [debugDescribeChildren](https://api.flutter.dev/flutter/foundation/DiagnosticableTree/debugDescribeChildren.html)() [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[DiagnosticsNode](https://api.flutter.dev/flutter/foundation/DiagnosticsNode-class.html)> - - - -Returns a list of DiagnosticsNode objects describing this node's -children. -_inherited_ - - - -##### [debugFillProperties](https://api.flutter.dev/flutter/widgets/Widget/debugFillProperties.html)([DiagnosticPropertiesBuilder](https://api.flutter.dev/flutter/foundation/DiagnosticPropertiesBuilder-class.html) properties) void - - - -Add additional properties associated with the node. -_inherited_ - - - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toDiagnosticsNode](https://api.flutter.dev/flutter/foundation/DiagnosticableTree/toDiagnosticsNode.html)({[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? name, [DiagnosticsTreeStyle](https://api.flutter.dev/flutter/foundation/DiagnosticsTreeStyle.html)? style}) [DiagnosticsNode](https://api.flutter.dev/flutter/foundation/DiagnosticsNode-class.html) - - - -Returns a debug representation of the object that is used by debugging -tools and by DiagnosticsNode.toStringDeep. -_inherited_ - - - -##### [toString](https://api.flutter.dev/flutter/foundation/Diagnosticable/toString.html)({[DiagnosticLevel](https://api.flutter.dev/flutter/foundation/DiagnosticLevel.html) minLevel = DiagnosticLevel.info}) [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - -##### [toStringDeep](https://api.flutter.dev/flutter/foundation/DiagnosticableTree/toStringDeep.html)({[String](https://api.flutter.dev/flutter/dart-core/String-class.html) prefixLineOne = '', [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? prefixOtherLines, [DiagnosticLevel](https://api.flutter.dev/flutter/foundation/DiagnosticLevel.html) minLevel = DiagnosticLevel.debug}) [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -Returns a string representation of this node and its descendants. -_inherited_ - - - -##### [toStringShallow](https://api.flutter.dev/flutter/foundation/DiagnosticableTree/toStringShallow.html)({[String](https://api.flutter.dev/flutter/dart-core/String-class.html) joiner = ', ', [DiagnosticLevel](https://api.flutter.dev/flutter/foundation/DiagnosticLevel.html) minLevel = DiagnosticLevel.debug}) [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -Returns a one-line detailed description of the object. -_inherited_ - - - -##### [toStringShort](https://api.flutter.dev/flutter/widgets/Widget/toStringShort.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A short, textual description of this widget. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/widgets/Widget/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder/EmailVerificationBuilder.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder/EmailVerificationBuilder.md deleted file mode 100644 index 02f74876..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder/EmailVerificationBuilder.md +++ /dev/null @@ -1,36 +0,0 @@ - - - -# EmailVerificationBuilder<Extra> constructor - - - - - *[](https://dart.dev/null-safety)* - - -const -EmailVerificationBuilder<Extra>({required [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) verified([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context), required [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) notVerified([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context), required [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) onError([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, FormStatus status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage), [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) customBuilder([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, [EmailVerificationState](../../wyatt_authentication_bloc/EmailVerificationState-class.md))?, [Key](https://api.flutter.dev/flutter/foundation/Key-class.html)? key}) - - - - - -## Implementation - -```dart -const EmailVerificationBuilder({ - required this.verified, - required this.notVerified, - required this.onError, - this.customBuilder, - super.key, -}); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder/build.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder/build.md deleted file mode 100644 index 6eaf5649..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder/build.md +++ /dev/null @@ -1,91 +0,0 @@ - - - -# build method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) build -([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context) - -_override_ - - - -

Describes the part of the user interface represented by this widget.

-

The framework calls this method when this widget is inserted into the tree -in a given BuildContext and when the dependencies of this widget change -(e.g., an InheritedWidget referenced by this widget changes). This -method can potentially be called in every frame and should not have any side -effects beyond building a widget.

-

The framework replaces the subtree below this widget with the widget -returned by this method, either by updating the existing subtree or by -removing the subtree and inflating a new subtree, depending on whether the -widget returned by this method can update the root of the existing -subtree, as determined by calling Widget.canUpdate.

-

Typically implementations return a newly created constellation of widgets -that are configured with information from this widget's constructor and -from the given BuildContext.

-

The given BuildContext contains information about the location in the -tree at which this widget is being built. For example, the context -provides the set of inherited widgets for this location in the tree. A -given widget might be built with multiple different BuildContext -arguments over time if the widget is moved around the tree or if the -widget is inserted into the tree in multiple places at once.

-

The implementation of this method must only depend on:

- -

If a widget's build method is to depend on anything else, use a -StatefulWidget instead.

-

See also:

-
    -
  • StatelessWidget, which contains the discussion on performance considerations.
  • -
- - - -## Implementation - -```dart -@override -Widget build(BuildContext context) => - BlocBuilder, EmailVerificationState>( - builder: (context, state) { - if (customBuilder != null) { - return customBuilder!(context, state); - } - - if (state.status.isSubmissionFailure || - state.status.isSubmissionCanceled) { - return onError( - context, - state.status, - state.errorMessage, - ); - } - - if (state.isVerified) { - return verified(context); - } - return notVerified(context); - }, - ); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder/customBuilder.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder/customBuilder.md deleted file mode 100644 index 1b238503..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder/customBuilder.md +++ /dev/null @@ -1,34 +0,0 @@ - - - -# customBuilder property - - - - - *[](https://dart.dev/null-safety)* - - - -([Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, [EmailVerificationState](../../wyatt_authentication_bloc/EmailVerificationState-class.md))?) customBuilder - -_final_ - - - - - - -## Implementation - -```dart -final Widget Function(BuildContext context, EmailVerificationState)? - customBuilder; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder/notVerified.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder/notVerified.md deleted file mode 100644 index fb67f5a1..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder/notVerified.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# notVerified property - - - - - *[](https://dart.dev/null-safety)* - - - -[Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context) notVerified - -_final_ - - - - - - -## Implementation - -```dart -final Widget Function(BuildContext context) notVerified; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder/onError.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder/onError.md deleted file mode 100644 index caa029d2..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder/onError.md +++ /dev/null @@ -1,37 +0,0 @@ - - - -# onError property - - - - - *[](https://dart.dev/null-safety)* - - - -[Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, FormStatus status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage) onError - -_final_ - - - - - - -## Implementation - -```dart -final Widget Function( - BuildContext context, - FormStatus status, - String? errorMessage, -) onError; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder/verified.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder/verified.md deleted file mode 100644 index 05f99c91..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationBuilder/verified.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# verified property - - - - - *[](https://dart.dev/null-safety)* - - - -[Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context) verified - -_final_ - - - - - - -## Implementation - -```dart -final Widget Function(BuildContext context) verified; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationCubit-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationCubit-class.md deleted file mode 100644 index f582d49e..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationCubit-class.md +++ /dev/null @@ -1,211 +0,0 @@ - - - -# EmailVerificationCubit<Data> class - - - - - - - *[](https://dart.dev/null-safety)* - - - - - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [BlocBase](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase-class.html)<[EmailVerificationState](../wyatt_authentication_bloc/EmailVerificationState-class.md)> -- [Cubit](https://pub.dev/documentation/bloc/8.1.0/bloc/Cubit-class.html)<[EmailVerificationState](../wyatt_authentication_bloc/EmailVerificationState-class.md)> -- EmailVerificationCubit - - - - - - - - -## Constructors - -[EmailVerificationCubit](../wyatt_authentication_bloc/EmailVerificationCubit/EmailVerificationCubit.md) ({required [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> authenticationRepository}) - - - - -## Properties - -##### [authenticationRepository](../wyatt_authentication_bloc/EmailVerificationCubit/authenticationRepository.md) → [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> - - - - -_final_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [isClosed](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/isClosed.html) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -Whether the bloc is closed. -_read-onlyinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - -##### [state](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/state.html) → [EmailVerificationState](../wyatt_authentication_bloc/EmailVerificationState-class.md) - - - -The current state. -_read-onlyinherited_ - - - -##### [stream](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/stream.html) → [Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[EmailVerificationState](../wyatt_authentication_bloc/EmailVerificationState-class.md)> - - - -The current stream of states. -_read-onlyinherited_ - - - - - -## Methods - -##### [addError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/addError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [[StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html)? stackTrace]) void - - - -Reports an error which triggers onError with an optional StackTrace. -_inherited_ - - - -##### [checkEmailVerification](../wyatt_authentication_bloc/EmailVerificationCubit/checkEmailVerification.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - - - - - -##### [close](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/close.html)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> - - - -Closes the instance. -This method should be called when the instance is no longer needed. -Once close is called, the instance can no longer be used. -_inherited_ - - - -##### [emit](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/emit.html)([EmailVerificationState](../wyatt_authentication_bloc/EmailVerificationState-class.md) state) void - - - -Updates the state to the provided state. -emit does nothing if the state being emitted -is equal to the current state. -_inherited_ - - - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [onChange](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onChange.html)([Change](https://pub.dev/documentation/bloc/8.1.0/bloc/Change-class.html)<[EmailVerificationState](../wyatt_authentication_bloc/EmailVerificationState-class.md)> change) void - - - -Called whenever a change occurs with the given change. -A change occurs when a new state is emitted. -onChange is called before the state of the cubit is updated. -onChange is a great spot to add logging/analytics for a specific cubit. -_inherited_ - - - -##### [onError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html) stackTrace) void - - - -Called whenever an error occurs and notifies BlocObserver.onError. -_inherited_ - - - -##### [sendEmailVerification](../wyatt_authentication_bloc/EmailVerificationCubit/sendEmailVerification.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - - - - - -##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationCubit/EmailVerificationCubit.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationCubit/EmailVerificationCubit.md deleted file mode 100644 index 4dc46616..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationCubit/EmailVerificationCubit.md +++ /dev/null @@ -1,32 +0,0 @@ - - - -# EmailVerificationCubit<Data> constructor - - - - - *[](https://dart.dev/null-safety)* - - - -EmailVerificationCubit<Data>({required [AuthenticationRepository](../../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> authenticationRepository}) - - - - - -## Implementation - -```dart -EmailVerificationCubit({ - required this.authenticationRepository, -}) : super(const EmailVerificationState()); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationCubit/authenticationRepository.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationCubit/authenticationRepository.md deleted file mode 100644 index 32cdfa2a..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationCubit/authenticationRepository.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# authenticationRepository property - - - - - *[](https://dart.dev/null-safety)* - - - -[AuthenticationRepository](../../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> authenticationRepository - -_final_ - - - - - - -## Implementation - -```dart -final AuthenticationRepository authenticationRepository; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationCubit/checkEmailVerification.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationCubit/checkEmailVerification.md deleted file mode 100644 index 7b602aac..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationCubit/checkEmailVerification.md +++ /dev/null @@ -1,65 +0,0 @@ - - - -# checkEmailVerification method - - - - - *[](https://dart.dev/null-safety)* - - - - -[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> checkEmailVerification -() - - - - - - - - -## Implementation - -```dart -FutureOr checkEmailVerification() async { - emit(state.copyWith(status: FormStatus.submissionInProgress)); - - final refresh = await authenticationRepository.refresh(); - if (refresh.isErr) { - final refreshError = refresh.err!; - emit( - EmailVerificationState( - errorMessage: refreshError.message, - status: FormStatus.submissionFailure, - ), - ); - return; - } - - final wrapper = await authenticationRepository.sessionStream().last; - final currentAccount = wrapper.session?.account; - if (currentAccount != null) { - emit( - state.copyWith( - isVerified: currentAccount.emailVerified, - status: FormStatus.submissionSuccess, - ), - ); - } else { - const EmailVerificationState( - errorMessage: 'No current session', - status: FormStatus.submissionFailure, - ); - } -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationCubit/sendEmailVerification.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationCubit/sendEmailVerification.md deleted file mode 100644 index 5d9d58e5..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationCubit/sendEmailVerification.md +++ /dev/null @@ -1,47 +0,0 @@ - - - -# sendEmailVerification method - - - - - *[](https://dart.dev/null-safety)* - - - - -[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> sendEmailVerification -() - - - - - - - - -## Implementation - -```dart -FutureOr sendEmailVerification() async { - emit(state.copyWith(status: FormStatus.submissionInProgress)); - final response = await authenticationRepository.sendEmailVerification(); - emit( - response.fold( - (value) => state.copyWith(status: FormStatus.submissionSuccess), - (error) => state.copyWith( - errorMessage: error.message, - status: FormStatus.submissionFailure, - ), - ), - ); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState-class.md deleted file mode 100644 index a1a99c58..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState-class.md +++ /dev/null @@ -1,160 +0,0 @@ - - - -# EmailVerificationState class - - - - - - - *[](https://dart.dev/null-safety)* - - - - - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [Equatable](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable-class.html) -- EmailVerificationState - - - - - - - - -## Constructors - -[EmailVerificationState](../wyatt_authentication_bloc/EmailVerificationState/EmailVerificationState.md) ({[bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) isVerified = false, FormStatus status = FormStatus.pure, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage}) - - _const_ - - -## Properties - -##### [errorMessage](../wyatt_authentication_bloc/EmailVerificationState/errorMessage.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? - - - - -_final_ - - - -##### [hashCode](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [isVerified](../wyatt_authentication_bloc/EmailVerificationState/isVerified.md) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - - -_final_ - - - -##### [props](../wyatt_authentication_bloc/EmailVerificationState/props.md) → [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> - - - -The list of properties that will be used to determine whether -two instances are equal. -_read-onlyoverride_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - -##### [status](../wyatt_authentication_bloc/EmailVerificationState/status.md) → FormStatus - - - - -_final_ - - - -##### [stringify](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/stringify.html) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)? - - - -If set to true, the toString method will be overridden to output -this instance's props. -_read-onlyinherited_ - - - - - -## Methods - -##### [copyWith](../wyatt_authentication_bloc/EmailVerificationState/copyWith.md)({FormStatus? status, [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)? isVerified, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage}) [EmailVerificationState](../wyatt_authentication_bloc/EmailVerificationState-class.md) - - - - - - - - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/EmailVerificationState/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_override_ - - - - - -## Operators - -##### [operator ==](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/EmailVerificationState.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/EmailVerificationState.md deleted file mode 100644 index 2b2eec71..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/EmailVerificationState.md +++ /dev/null @@ -1,34 +0,0 @@ - - - -# EmailVerificationState constructor - - - - - *[](https://dart.dev/null-safety)* - - -const -EmailVerificationState({[bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) isVerified = false, FormStatus status = FormStatus.pure, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage}) - - - - - -## Implementation - -```dart -const EmailVerificationState({ - this.isVerified = false, - this.status = FormStatus.pure, - this.errorMessage, -}); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/copyWith.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/copyWith.md deleted file mode 100644 index 3828f71a..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/copyWith.md +++ /dev/null @@ -1,44 +0,0 @@ - - - -# copyWith method - - - - - *[](https://dart.dev/null-safety)* - - - - -[EmailVerificationState](../../wyatt_authentication_bloc/EmailVerificationState-class.md) copyWith -({FormStatus? status, [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)? isVerified, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage}) - - - - - - - - -## Implementation - -```dart -EmailVerificationState copyWith({ - FormStatus? status, - bool? isVerified, - String? errorMessage, -}) => - EmailVerificationState( - status: status ?? this.status, - isVerified: isVerified ?? this.isVerified, - errorMessage: errorMessage ?? this.errorMessage, - ); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/errorMessage.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/errorMessage.md deleted file mode 100644 index 4f0a5b7f..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/errorMessage.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# errorMessage property - - - - - *[](https://dart.dev/null-safety)* - - - -[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage - -_final_ - - - - - - -## Implementation - -```dart -final String? errorMessage; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/isVerified.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/isVerified.md deleted file mode 100644 index 5fe39d63..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/isVerified.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# isVerified property - - - - - *[](https://dart.dev/null-safety)* - - - -[bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) isVerified - -_final_ - - - - - - -## Implementation - -```dart -final bool isVerified; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/props.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/props.md deleted file mode 100644 index 60e41027..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/props.md +++ /dev/null @@ -1,42 +0,0 @@ - - - -# props property - - - - - *[](https://dart.dev/null-safety)* - - - - - -**Annotations** - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) -[List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> props - -_override_ - - - -

The list of properties that will be used to determine whether -two instances are equal.

- - - -## Implementation - -```dart -@override -List get props => [status, isVerified, errorMessage]; -``` - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/status.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/status.md deleted file mode 100644 index 5623cccf..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/status.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# status property - - - - - *[](https://dart.dev/null-safety)* - - - -FormStatus status - -_final_ - - - - - - -## Implementation - -```dart -final FormStatus status; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/toString.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/toString.md deleted file mode 100644 index 3fec7549..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/EmailVerificationState/toString.md +++ /dev/null @@ -1,49 +0,0 @@ - - - -# toString method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[String](https://api.flutter.dev/flutter/dart-core/String-class.html) toString -() - -_override_ - - - -

A string representation of this object.

-

Some classes have a default textual representation, -often paired with a static parse function (like int.parse). -These classes will provide the textual representation as -their string representation.

-

Other classes have no meaningful textual representation -that a program will care about. -Such classes will typically override toString to provide -useful information when inspecting the object, -mainly for debugging or logging.

- - - -## Implementation - -```dart -@override -String toString() => 'EmailVerificationState(status: ${status.name} ' - '${(errorMessage != null) ? " [$errorMessage]" : ""}, ' - 'isVerified: $isVerified)'; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureFirebase-class.md deleted file mode 100644 index a97181ca..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureFirebase-class.md +++ /dev/null @@ -1,137 +0,0 @@ - - - -# FetchSignInMethodsForEmailFailureFirebase class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown during the fetch sign in methods if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- [FetchSignInMethodsForEmailFailureInterface](../wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureInterface-class.md) -- FetchSignInMethodsForEmailFailureFirebase - - - - - - - - -## Constructors - -[FetchSignInMethodsForEmailFailureFirebase](../wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureFirebase/FetchSignInMethodsForEmailFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - -[FetchSignInMethodsForEmailFailureFirebase.fromCode](../wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureFirebase/FetchSignInMethodsForEmailFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureFirebase/FetchSignInMethodsForEmailFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureFirebase/FetchSignInMethodsForEmailFailureFirebase.fromCode.md deleted file mode 100644 index 3cf4d6c5..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureFirebase/FetchSignInMethodsForEmailFailureFirebase.fromCode.md +++ /dev/null @@ -1,40 +0,0 @@ - - - -# FetchSignInMethodsForEmailFailureFirebase.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -FetchSignInMethodsForEmailFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - - -## Implementation - -```dart -FetchSignInMethodsForEmailFailureFirebase.fromCode(String code) - : super.fromCode(code) { - switch (code) { - case 'invalid-email': - msg = 'The email address is badly formatted.'; - break; - default: - this.code = 'unknown'; - msg = 'An unknown error occurred.'; - } -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureFirebase/FetchSignInMethodsForEmailFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureFirebase/FetchSignInMethodsForEmailFailureFirebase.md deleted file mode 100644 index 4a74506c..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureFirebase/FetchSignInMethodsForEmailFailureFirebase.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# FetchSignInMethodsForEmailFailureFirebase constructor - - - - - *[](https://dart.dev/null-safety)* - - - -FetchSignInMethodsForEmailFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - - - -## Implementation - -```dart -FetchSignInMethodsForEmailFailureFirebase([String? code, String? msg]) - : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureInterface-class.md deleted file mode 100644 index 5986c599..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureInterface-class.md +++ /dev/null @@ -1,139 +0,0 @@ - - - -# FetchSignInMethodsForEmailFailureInterface class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown during the fetch sign in methods if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- FetchSignInMethodsForEmailFailureInterface - - - -**Implementers** - -- [FetchSignInMethodsForEmailFailureFirebase](../wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureFirebase-class.md) - - - - - -## Constructors - -[FetchSignInMethodsForEmailFailureInterface](../wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureInterface/FetchSignInMethodsForEmailFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - -Thrown during the fetch sign in methods if a failure occurs. - -[FetchSignInMethodsForEmailFailureInterface.fromCode](../wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureInterface/FetchSignInMethodsForEmailFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - -Thrown during the fetch sign in methods if a failure occurs. - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureInterface/FetchSignInMethodsForEmailFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureInterface/FetchSignInMethodsForEmailFailureInterface.fromCode.md deleted file mode 100644 index 846ff49a..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureInterface/FetchSignInMethodsForEmailFailureInterface.fromCode.md +++ /dev/null @@ -1,32 +0,0 @@ - - - -# FetchSignInMethodsForEmailFailureInterface.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -FetchSignInMethodsForEmailFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - -

Thrown during the fetch sign in methods if a failure occurs.

- - - -## Implementation - -```dart -FetchSignInMethodsForEmailFailureInterface.fromCode(super.code) - : super.fromCode(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureInterface/FetchSignInMethodsForEmailFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureInterface/FetchSignInMethodsForEmailFailureInterface.md deleted file mode 100644 index b38af41e..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureInterface/FetchSignInMethodsForEmailFailureInterface.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# FetchSignInMethodsForEmailFailureInterface constructor - - - - - *[](https://dart.dev/null-safety)* - - - -FetchSignInMethodsForEmailFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - - -

Thrown during the fetch sign in methods if a failure occurs.

- - - -## Implementation - -```dart -FetchSignInMethodsForEmailFailureInterface(super.code, super.msg); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ModelParsingFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ModelParsingFailureFirebase-class.md deleted file mode 100644 index 60876e96..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ModelParsingFailureFirebase-class.md +++ /dev/null @@ -1,137 +0,0 @@ - - - -# ModelParsingFailureFirebase class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown during the model parsing process if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- [ModelParsingFailureInterface](../wyatt_authentication_bloc/ModelParsingFailureInterface-class.md) -- ModelParsingFailureFirebase - - - - - - - - -## Constructors - -[ModelParsingFailureFirebase](../wyatt_authentication_bloc/ModelParsingFailureFirebase/ModelParsingFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - -[ModelParsingFailureFirebase.fromCode](../wyatt_authentication_bloc/ModelParsingFailureFirebase/ModelParsingFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ModelParsingFailureFirebase/ModelParsingFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ModelParsingFailureFirebase/ModelParsingFailureFirebase.fromCode.md deleted file mode 100644 index 0e9ae35c..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ModelParsingFailureFirebase/ModelParsingFailureFirebase.fromCode.md +++ /dev/null @@ -1,30 +0,0 @@ - - - -# ModelParsingFailureFirebase.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -ModelParsingFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - - -## Implementation - -```dart -ModelParsingFailureFirebase.fromCode(super.code) : super.fromCode(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ModelParsingFailureFirebase/ModelParsingFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ModelParsingFailureFirebase/ModelParsingFailureFirebase.md deleted file mode 100644 index 51b77521..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ModelParsingFailureFirebase/ModelParsingFailureFirebase.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# ModelParsingFailureFirebase constructor - - - - - *[](https://dart.dev/null-safety)* - - - -ModelParsingFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - - - -## Implementation - -```dart -ModelParsingFailureFirebase([String? code, String? msg]) - : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ModelParsingFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ModelParsingFailureInterface-class.md deleted file mode 100644 index d8e2dead..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ModelParsingFailureInterface-class.md +++ /dev/null @@ -1,139 +0,0 @@ - - - -# ModelParsingFailureInterface class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown during the model parsing process if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- ModelParsingFailureInterface - - - -**Implementers** - -- [ModelParsingFailureFirebase](../wyatt_authentication_bloc/ModelParsingFailureFirebase-class.md) - - - - - -## Constructors - -[ModelParsingFailureInterface](../wyatt_authentication_bloc/ModelParsingFailureInterface/ModelParsingFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - - - -[ModelParsingFailureInterface.fromCode](../wyatt_authentication_bloc/ModelParsingFailureInterface/ModelParsingFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ModelParsingFailureInterface/ModelParsingFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ModelParsingFailureInterface/ModelParsingFailureInterface.fromCode.md deleted file mode 100644 index 055991cb..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ModelParsingFailureInterface/ModelParsingFailureInterface.fromCode.md +++ /dev/null @@ -1,30 +0,0 @@ - - - -# ModelParsingFailureInterface.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -ModelParsingFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - - -## Implementation - -```dart -ModelParsingFailureInterface.fromCode(super.code) : super.fromCode(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ModelParsingFailureInterface/ModelParsingFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ModelParsingFailureInterface/ModelParsingFailureInterface.md deleted file mode 100644 index 473c347a..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ModelParsingFailureInterface/ModelParsingFailureInterface.md +++ /dev/null @@ -1,30 +0,0 @@ - - - -# ModelParsingFailureInterface constructor - - - - - *[](https://dart.dev/null-safety)* - - - -ModelParsingFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - - - - - -## Implementation - -```dart -ModelParsingFailureInterface(super.code, super.msg); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit-class.md deleted file mode 100644 index 350b635e..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit-class.md +++ /dev/null @@ -1,275 +0,0 @@ - - - -# PasswordResetCubit<Extra> class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Cubit that allows user to reset his password

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [BlocBase](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase-class.html)<[PasswordResetState](../wyatt_authentication_bloc/PasswordResetState-class.md)> -- [Cubit](https://pub.dev/documentation/bloc/8.1.0/bloc/Cubit-class.html)<[PasswordResetState](../wyatt_authentication_bloc/PasswordResetState-class.md)> -- PasswordResetCubit - - - - - - - - -## Constructors - -[PasswordResetCubit](../wyatt_authentication_bloc/PasswordResetCubit/PasswordResetCubit.md) ({required [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Extra> authenticationRepository}) - - - - -## Properties - -##### [authenticationRepository](../wyatt_authentication_bloc/PasswordResetCubit/authenticationRepository.md) → [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Extra> - - - - -_final_ - - - -##### [formName](../wyatt_authentication_bloc/PasswordResetCubit/formName.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-only_ - - - -##### [formRepository](../wyatt_authentication_bloc/PasswordResetCubit/formRepository.md) → FormRepository - - - - -_read-only_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [isClosed](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/isClosed.html) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -Whether the bloc is closed. -_read-onlyinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - -##### [state](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/state.html) → [PasswordResetState](../wyatt_authentication_bloc/PasswordResetState-class.md) - - - -The current state. -_read-onlyinherited_ - - - -##### [stream](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/stream.html) → [Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[PasswordResetState](../wyatt_authentication_bloc/PasswordResetState-class.md)> - - - -The current stream of states. -_read-onlyinherited_ - - - - - -## Methods - -##### [addError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/addError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [[StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html)? stackTrace]) void - - - -Reports an error which triggers onError with an optional StackTrace. -_inherited_ - - - -##### [close](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/close.html)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> - - - -Closes the instance. -This method should be called when the instance is no longer needed. -Once close is called, the instance can no longer be used. -_inherited_ - - - -##### [dataChanged](../wyatt_authentication_bloc/PasswordResetCubit/dataChanged.md)<Value>([String](https://api.flutter.dev/flutter/dart-core/String-class.html) key, FormInputValidator<Value, ValidationError> dirtyValue) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - - - - - -##### [emailChanged](../wyatt_authentication_bloc/PasswordResetCubit/emailChanged.md)([String](https://api.flutter.dev/flutter/dart-core/String-class.html) value) void - - - - - - - - -##### [emailCustomChanged](../wyatt_authentication_bloc/PasswordResetCubit/emailCustomChanged.md)<Validator extends FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError>>(Validator validator) void - - - -Same as emailChanged but with a custom Validator. - - - - -##### [emit](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/emit.html)([PasswordResetState](../wyatt_authentication_bloc/PasswordResetState-class.md) state) void - - - -Updates the state to the provided state. -emit does nothing if the state being emitted -is equal to the current state. -_inherited_ - - - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [onChange](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onChange.html)([Change](https://pub.dev/documentation/bloc/8.1.0/bloc/Change-class.html)<[PasswordResetState](../wyatt_authentication_bloc/PasswordResetState-class.md)> change) void - - - -Called whenever a change occurs with the given change. -A change occurs when a new state is emitted. -onChange is called before the state of the cubit is updated. -onChange is a great spot to add logging/analytics for a specific cubit. -_inherited_ - - - -##### [onError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html) stackTrace) void - - - -Called whenever an error occurs and notifies BlocObserver.onError. -_inherited_ - - - -##### [reset](../wyatt_authentication_bloc/PasswordResetCubit/reset.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - - - - - -##### [submit](../wyatt_authentication_bloc/PasswordResetCubit/submit.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - -Sends a password reset email to the user - - - - -##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - -##### [update](../wyatt_authentication_bloc/PasswordResetCubit/update.md)(WyattForm form, {SetOperation operation = SetOperation.replace}) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - - - - - -##### [validate](../wyatt_authentication_bloc/PasswordResetCubit/validate.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - - - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/PasswordResetCubit.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/PasswordResetCubit.md deleted file mode 100644 index 71d64822..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/PasswordResetCubit.md +++ /dev/null @@ -1,37 +0,0 @@ - - - -# PasswordResetCubit<Extra> constructor - - - - - *[](https://dart.dev/null-safety)* - - - -PasswordResetCubit<Extra>({required [AuthenticationRepository](../../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Extra> authenticationRepository}) - - - - - -## Implementation - -```dart -PasswordResetCubit({ - required this.authenticationRepository, -}) : super( - PasswordResetState( - form: authenticationRepository.formRepository - .accessForm(AuthFormName.passwordResetForm), - ), - ); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/authenticationRepository.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/authenticationRepository.md deleted file mode 100644 index 1662ceda..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/authenticationRepository.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# authenticationRepository property - - - - - *[](https://dart.dev/null-safety)* - - - -[AuthenticationRepository](../../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Extra> authenticationRepository - -_final_ - - - - - - -## Implementation - -```dart -final AuthenticationRepository authenticationRepository; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/dataChanged.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/dataChanged.md deleted file mode 100644 index c62e9718..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/dataChanged.md +++ /dev/null @@ -1,53 +0,0 @@ - - - -# dataChanged<Value> method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> dataChanged -<Value>([String](https://api.flutter.dev/flutter/dart-core/String-class.html) key, FormInputValidator<Value, ValidationError> dirtyValue) - - - - - - - - -## Implementation - -```dart -@override -FutureOr dataChanged( - String key, - FormInputValidator dirtyValue, -) { - final form = formRepository.accessForm(formName).clone(); - - try { - form.updateValidator(key, dirtyValue); - formRepository.updateForm(form); - } catch (e) { - rethrow; - } - - emit( - state.copyWith(form: form, status: form.validate()), - ); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/emailChanged.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/emailChanged.md deleted file mode 100644 index 85e7cc16..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/emailChanged.md +++ /dev/null @@ -1,47 +0,0 @@ - - - -# emailChanged method - - - - - *[](https://dart.dev/null-safety)* - - - - -void emailChanged -([String](https://api.flutter.dev/flutter/dart-core/String-class.html) value) - - - - - - - - -## Implementation - -```dart -void emailChanged(String value) { - final emailValidatorType = formRepository - .accessForm(formName) - .validatorOf(AuthFormField.email) - .runtimeType; - assert( - emailValidatorType == Email, - 'Use emailCustomChanged(...) with validator $emailValidatorType', - ); - - final Email email = Email.dirty(value); - dataChanged(AuthFormField.email, email); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/emailCustomChanged.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/emailCustomChanged.md deleted file mode 100644 index fa9c4c14..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/emailCustomChanged.md +++ /dev/null @@ -1,42 +0,0 @@ - - - -# emailCustomChanged<Validator extends FormInputValidator<String?, ValidationError>> method - - - - - *[](https://dart.dev/null-safety)* - - - - -void emailCustomChanged -<Validator extends FormInputValidator<String?, ValidationError>>(Validator validator) - - - - - -

Same as emailChanged but with a custom Validator.

-

Sort of short hand for dataChanged.

- - - -## Implementation - -```dart -void emailCustomChanged< - Validator extends FormInputValidator>( - Validator validator, -) { - dataChanged(AuthFormField.email, validator); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/formName.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/formName.md deleted file mode 100644 index 0e18d674..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/formName.md +++ /dev/null @@ -1,40 +0,0 @@ - - - -# formName property - - - - - *[](https://dart.dev/null-safety)* - - - - - -**Annotations** - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) -[String](https://api.flutter.dev/flutter/dart-core/String-class.html) formName - - - - - - - - -## Implementation - -```dart -@override -String get formName => AuthFormName.passwordResetForm; -``` - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/formRepository.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/formRepository.md deleted file mode 100644 index db8665dd..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/formRepository.md +++ /dev/null @@ -1,36 +0,0 @@ - - - -# formRepository property - - - - - *[](https://dart.dev/null-safety)* - - - - - -FormRepository formRepository - - - - - - - - -## Implementation - -```dart -FormRepository get formRepository => authenticationRepository.formRepository; -``` - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/reset.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/reset.md deleted file mode 100644 index 199755fa..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/reset.md +++ /dev/null @@ -1,43 +0,0 @@ - - - -# reset method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> reset -() - - - - - - - - -## Implementation - -```dart -@override -FutureOr reset() { - final form = state.form.reset(); - formRepository.updateForm(form); - emit( - state.copyWith(form: form, status: form.validate()), - ); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/submit.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/submit.md deleted file mode 100644 index 31bfedc7..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/submit.md +++ /dev/null @@ -1,70 +0,0 @@ - - - -# submit method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> submit -() - - - - - -

Sends a password reset email to the user

- - - -## Implementation - -```dart -@override -FutureOr submit() async { - if (!state.status.isValidated) { - return; - } - - emit(state.copyWith(status: FormStatus.submissionInProgress)); - - final form = formRepository.accessForm(formName); - final email = form.valueOf(AuthFormField.email); - - if (email.isNullOrEmpty) { - emit( - state.copyWith( - errorMessage: 'An error occured while retrieving data from the form.', - status: FormStatus.submissionFailure, - ), - ); - } - - final response = await authenticationRepository.sendPasswordResetEmail( - email: email!, - ); - - emit( - response.fold( - (value) => state.copyWith(status: FormStatus.submissionSuccess), - (error) => state.copyWith( - errorMessage: error.message, - status: FormStatus.submissionFailure, - ), - ), - ); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/update.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/update.md deleted file mode 100644 index 23388fad..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/update.md +++ /dev/null @@ -1,51 +0,0 @@ - - - -# update method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> update -(WyattForm form, {SetOperation operation = SetOperation.replace}) - - - - - - - - -## Implementation - -```dart -@override -FutureOr update( - WyattForm form, { - SetOperation operation = SetOperation.replace, -}) { - final WyattForm current = formRepository.accessForm(formName).clone(); - final WyattForm newForm = operation.operation.call(current, form); - formRepository.updateForm(newForm); - - emit( - state.copyWith( - form: newForm, - status: newForm.validate(), - ), - ); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/validate.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/validate.md deleted file mode 100644 index 5a8e5519..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetCubit/validate.md +++ /dev/null @@ -1,43 +0,0 @@ - - - -# validate method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> validate -() - - - - - - - - -## Implementation - -```dart -@override -FutureOr validate() { - emit( - state.copyWith( - status: formRepository.accessForm(formName).validate(), - ), - ); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState-class.md deleted file mode 100644 index 757a9170..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState-class.md +++ /dev/null @@ -1,169 +0,0 @@ - - - -# PasswordResetState class - - - - - - - *[](https://dart.dev/null-safety)* - - - - - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [Equatable](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable-class.html) -- PasswordResetState - - - - - - - - -## Constructors - -[PasswordResetState](../wyatt_authentication_bloc/PasswordResetState/PasswordResetState.md) ({required WyattForm form, FormStatus status = FormStatus.pure, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage}) - - _const_ - - -## Properties - -##### [email](../wyatt_authentication_bloc/PasswordResetState/email.md) → Email - - - - -_read-only_ - - - -##### [errorMessage](../wyatt_authentication_bloc/PasswordResetState/errorMessage.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? - - - -Optional error message. -_finalinherited_ - - - -##### [form](../wyatt_authentication_bloc/PasswordResetState/form.md) → WyattForm - - - -FormData with all inputs, and associated metadata. -_finalinherited_ - - - -##### [hashCode](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [props](../wyatt_authentication_bloc/PasswordResetState/props.md) → [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)> - - - -The list of properties that will be used to determine whether -two instances are equal. -_read-only_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - -##### [status](../wyatt_authentication_bloc/PasswordResetState/status.md) → FormStatus - - - -Global status of a form. -_finalinherited_ - - - -##### [stringify](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/stringify.html) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)? - - - -If set to true, the toString method will be overridden to output -this instance's props. -_read-onlyinherited_ - - - - - -## Methods - -##### [copyWith](../wyatt_authentication_bloc/PasswordResetState/copyWith.md)({WyattForm? form, FormStatus? status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage}) [PasswordResetState](../wyatt_authentication_bloc/PasswordResetState-class.md) - - - - - - - - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/PasswordResetState/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_override_ - - - - - -## Operators - -##### [operator ==](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/PasswordResetState.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/PasswordResetState.md deleted file mode 100644 index c6d8f5cf..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/PasswordResetState.md +++ /dev/null @@ -1,34 +0,0 @@ - - - -# PasswordResetState constructor - - - - - *[](https://dart.dev/null-safety)* - - -const -PasswordResetState({required WyattForm form, FormStatus status = FormStatus.pure, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage}) - - - - - -## Implementation - -```dart -const PasswordResetState({ - required super.form, - super.status = FormStatus.pure, - super.errorMessage, -}); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/copyWith.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/copyWith.md deleted file mode 100644 index 60199cc6..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/copyWith.md +++ /dev/null @@ -1,44 +0,0 @@ - - - -# copyWith method - - - - - *[](https://dart.dev/null-safety)* - - - - -[PasswordResetState](../../wyatt_authentication_bloc/PasswordResetState-class.md) copyWith -({WyattForm? form, FormStatus? status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage}) - - - - - - - - -## Implementation - -```dart -PasswordResetState copyWith({ - WyattForm? form, - FormStatus? status, - String? errorMessage, -}) => - PasswordResetState( - form: form ?? this.form, - status: status ?? this.status, - errorMessage: errorMessage ?? this.errorMessage, - ); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/email.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/email.md deleted file mode 100644 index 0e3a2fc7..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/email.md +++ /dev/null @@ -1,36 +0,0 @@ - - - -# email property - - - - - *[](https://dart.dev/null-safety)* - - - - - -Email email - - - - - - - - -## Implementation - -```dart -Email get email => form.validatorOf(AuthFormField.email); -``` - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/errorMessage.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/errorMessage.md deleted file mode 100644 index d0856deb..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/errorMessage.md +++ /dev/null @@ -1,34 +0,0 @@ - - - -# errorMessage property - - - - - *[](https://dart.dev/null-safety)* - - - -[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage - -_finalinherited_ - - - -

Optional error message.

- - - -## Implementation - -```dart -final String? errorMessage; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/form.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/form.md deleted file mode 100644 index d3f2da76..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/form.md +++ /dev/null @@ -1,34 +0,0 @@ - - - -# form property - - - - - *[](https://dart.dev/null-safety)* - - - -WyattForm form - -_finalinherited_ - - - -

FormData with all inputs, and associated metadata.

- - - -## Implementation - -```dart -final WyattForm form; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/props.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/props.md deleted file mode 100644 index 4665a84e..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/props.md +++ /dev/null @@ -1,42 +0,0 @@ - - - -# props property - - - - - *[](https://dart.dev/null-safety)* - - - - - -**Annotations** - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) -[List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)> props - - - - - -

The list of properties that will be used to determine whether -two instances are equal.

- - - -## Implementation - -```dart -@override -List get props => [email, status]; -``` - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/status.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/status.md deleted file mode 100644 index 644a9f10..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/status.md +++ /dev/null @@ -1,34 +0,0 @@ - - - -# status property - - - - - *[](https://dart.dev/null-safety)* - - - -FormStatus status - -_finalinherited_ - - - -

Global status of a form.

- - - -## Implementation - -```dart -final FormStatus status; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/toString.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/toString.md deleted file mode 100644 index d40bc441..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/PasswordResetState/toString.md +++ /dev/null @@ -1,48 +0,0 @@ - - - -# toString method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[String](https://api.flutter.dev/flutter/dart-core/String-class.html) toString -() - -_override_ - - - -

A string representation of this object.

-

Some classes have a default textual representation, -often paired with a static parse function (like int.parse). -These classes will provide the textual representation as -their string representation.

-

Other classes have no meaningful textual representation -that a program will care about. -Such classes will typically override toString to provide -useful information when inspecting the object, -mainly for debugging or logging.

- - - -## Implementation - -```dart -@override -String toString() => 'PasswordResetState(status: ${status.name} ' - '${(errorMessage != null) ? " [$errorMessage]" : ""}, $form)'; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticateFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticateFailureFirebase-class.md deleted file mode 100644 index 527e46f4..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticateFailureFirebase-class.md +++ /dev/null @@ -1,137 +0,0 @@ - - - -# ReauthenticateFailureFirebase class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown during the reauthentication process if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- [ReauthenticateFailureInterface](../wyatt_authentication_bloc/ReauthenticateFailureInterface-class.md) -- ReauthenticateFailureFirebase - - - - - - - - -## Constructors - -[ReauthenticateFailureFirebase](../wyatt_authentication_bloc/ReauthenticateFailureFirebase/ReauthenticateFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - -[ReauthenticateFailureFirebase.fromCode](../wyatt_authentication_bloc/ReauthenticateFailureFirebase/ReauthenticateFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticateFailureFirebase/ReauthenticateFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticateFailureFirebase/ReauthenticateFailureFirebase.fromCode.md deleted file mode 100644 index 6ad6eccc..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticateFailureFirebase/ReauthenticateFailureFirebase.fromCode.md +++ /dev/null @@ -1,57 +0,0 @@ - - - -# ReauthenticateFailureFirebase.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -ReauthenticateFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - - -## Implementation - -```dart -ReauthenticateFailureFirebase.fromCode(String code) : super.fromCode(code) { - switch (code) { - case 'user-mismatch': - msg = 'Given credential does not correspond to the user.'; - break; - case 'user-not-found': - msg = 'User is not found, please create an account.'; - break; - case 'invalid-credential': - msg = 'The credential received is malformed or has expired.'; - break; - case 'invalid-email': - msg = 'Email is not valid or badly formatted.'; - break; - case 'wrong-password': - msg = 'Incorrect password, please try again.'; - break; - case 'invalid-verification-code': - msg = 'The credential verification code received is invalid.'; - break; - case 'invalid-verification-id': - msg = 'The credential verification ID received is invalid.'; - break; - default: - this.code = 'unknown'; - msg = 'An unknown error occurred.'; - } -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticateFailureFirebase/ReauthenticateFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticateFailureFirebase/ReauthenticateFailureFirebase.md deleted file mode 100644 index e386d710..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticateFailureFirebase/ReauthenticateFailureFirebase.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# ReauthenticateFailureFirebase constructor - - - - - *[](https://dart.dev/null-safety)* - - - -ReauthenticateFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - - - -## Implementation - -```dart -ReauthenticateFailureFirebase([String? code, String? msg]) - : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticateFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticateFailureInterface-class.md deleted file mode 100644 index 7c36e2c0..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticateFailureInterface-class.md +++ /dev/null @@ -1,139 +0,0 @@ - - - -# ReauthenticateFailureInterface class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown during the reauthentication process if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- ReauthenticateFailureInterface - - - -**Implementers** - -- [ReauthenticateFailureFirebase](../wyatt_authentication_bloc/ReauthenticateFailureFirebase-class.md) - - - - - -## Constructors - -[ReauthenticateFailureInterface](../wyatt_authentication_bloc/ReauthenticateFailureInterface/ReauthenticateFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - - - -[ReauthenticateFailureInterface.fromCode](../wyatt_authentication_bloc/ReauthenticateFailureInterface/ReauthenticateFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticateFailureInterface/ReauthenticateFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticateFailureInterface/ReauthenticateFailureInterface.fromCode.md deleted file mode 100644 index c8d73b99..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticateFailureInterface/ReauthenticateFailureInterface.fromCode.md +++ /dev/null @@ -1,30 +0,0 @@ - - - -# ReauthenticateFailureInterface.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -ReauthenticateFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - - -## Implementation - -```dart -ReauthenticateFailureInterface.fromCode(super.code) : super.fromCode(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticateFailureInterface/ReauthenticateFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticateFailureInterface/ReauthenticateFailureInterface.md deleted file mode 100644 index 511d8024..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticateFailureInterface/ReauthenticateFailureInterface.md +++ /dev/null @@ -1,30 +0,0 @@ - - - -# ReauthenticateFailureInterface constructor - - - - - *[](https://dart.dev/null-safety)* - - - -ReauthenticateFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - - - - - -## Implementation - -```dart -ReauthenticateFailureInterface(super.code, super.msg); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticatedEvent-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticatedEvent-class.md deleted file mode 100644 index 1184c6f3..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticatedEvent-class.md +++ /dev/null @@ -1,137 +0,0 @@ - - - -# ReauthenticatedEvent class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

When a user re-authenticates (from the logged in state to the -logged in state with a different and fresh access -token and a different login time)

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [Equatable](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable-class.html) -- [AuthenticationChangeEvent](../wyatt_authentication_bloc/AuthenticationChangeEvent-class.md) -- ReauthenticatedEvent - - - - - - - - -## Constructors - -[ReauthenticatedEvent](../wyatt_authentication_bloc/ReauthenticatedEvent/ReauthenticatedEvent.md) ({required [Account](../wyatt_authentication_bloc/Account-class.md) account}) - - _const_ - - -## Properties - -##### [account](../wyatt_authentication_bloc/ReauthenticatedEvent/account.md) → [Account](../wyatt_authentication_bloc/Account-class.md) - - - - -_final_ - - - -##### [hashCode](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [props](../wyatt_authentication_bloc/ReauthenticatedEvent/props.md) → [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> - - - -The list of properties that will be used to determine whether -two instances are equal. -_read-onlyoverride_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - -##### [stringify](../wyatt_authentication_bloc/AuthenticationChangeEvent/stringify.md) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -If set to true, the toString method will be overridden to output -this instance's props. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticatedEvent/ReauthenticatedEvent.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticatedEvent/ReauthenticatedEvent.md deleted file mode 100644 index 3b8ba4c3..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticatedEvent/ReauthenticatedEvent.md +++ /dev/null @@ -1,30 +0,0 @@ - - - -# ReauthenticatedEvent constructor - - - - - *[](https://dart.dev/null-safety)* - - -const -ReauthenticatedEvent({required [Account](../../wyatt_authentication_bloc/Account-class.md) account}) - - - - - -## Implementation - -```dart -const ReauthenticatedEvent({required this.account}); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticatedEvent/account.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticatedEvent/account.md deleted file mode 100644 index 671e197e..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticatedEvent/account.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# account property - - - - - *[](https://dart.dev/null-safety)* - - - -[Account](../../wyatt_authentication_bloc/Account-class.md) account - -_final_ - - - - - - -## Implementation - -```dart -final Account account; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticatedEvent/props.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticatedEvent/props.md deleted file mode 100644 index fbde09d1..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/ReauthenticatedEvent/props.md +++ /dev/null @@ -1,42 +0,0 @@ - - - -# props property - - - - - *[](https://dart.dev/null-safety)* - - - - - -**Annotations** - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) -[List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> props - -_override_ - - - -

The list of properties that will be used to determine whether -two instances are equal.

- - - -## Implementation - -```dart -@override -List get props => [account]; -``` - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshFailureFirebase-class.md deleted file mode 100644 index 32cdc623..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshFailureFirebase-class.md +++ /dev/null @@ -1,137 +0,0 @@ - - - -# RefreshFailureFirebase class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown during the refresh process if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- [RefreshFailureInterface](../wyatt_authentication_bloc/RefreshFailureInterface-class.md) -- RefreshFailureFirebase - - - - - - - - -## Constructors - -[RefreshFailureFirebase](../wyatt_authentication_bloc/RefreshFailureFirebase/RefreshFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - -[RefreshFailureFirebase.fromCode](../wyatt_authentication_bloc/RefreshFailureFirebase/RefreshFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshFailureFirebase/RefreshFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshFailureFirebase/RefreshFailureFirebase.fromCode.md deleted file mode 100644 index 4b2cce16..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshFailureFirebase/RefreshFailureFirebase.fromCode.md +++ /dev/null @@ -1,30 +0,0 @@ - - - -# RefreshFailureFirebase.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -RefreshFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - - -## Implementation - -```dart -RefreshFailureFirebase.fromCode(super.code) : super.fromCode(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshFailureFirebase/RefreshFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshFailureFirebase/RefreshFailureFirebase.md deleted file mode 100644 index 4ac4faee..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshFailureFirebase/RefreshFailureFirebase.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# RefreshFailureFirebase constructor - - - - - *[](https://dart.dev/null-safety)* - - - -RefreshFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - - - -## Implementation - -```dart -RefreshFailureFirebase([String? code, String? msg]) - : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshFailureInterface-class.md deleted file mode 100644 index f485f140..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshFailureInterface-class.md +++ /dev/null @@ -1,139 +0,0 @@ - - - -# RefreshFailureInterface class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown during the refresh process if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- RefreshFailureInterface - - - -**Implementers** - -- [RefreshFailureFirebase](../wyatt_authentication_bloc/RefreshFailureFirebase-class.md) - - - - - -## Constructors - -[RefreshFailureInterface](../wyatt_authentication_bloc/RefreshFailureInterface/RefreshFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - -Thrown during the refresh process if a failure occurs. - -[RefreshFailureInterface.fromCode](../wyatt_authentication_bloc/RefreshFailureInterface/RefreshFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - -Thrown during the refresh process if a failure occurs. - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshFailureInterface/RefreshFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshFailureInterface/RefreshFailureInterface.fromCode.md deleted file mode 100644 index 33b4dace..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshFailureInterface/RefreshFailureInterface.fromCode.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# RefreshFailureInterface.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -RefreshFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - -

Thrown during the refresh process if a failure occurs.

- - - -## Implementation - -```dart -RefreshFailureInterface.fromCode(super.code) : super.fromCode(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshFailureInterface/RefreshFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshFailureInterface/RefreshFailureInterface.md deleted file mode 100644 index a958f830..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshFailureInterface/RefreshFailureInterface.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# RefreshFailureInterface constructor - - - - - *[](https://dart.dev/null-safety)* - - - -RefreshFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - - -

Thrown during the refresh process if a failure occurs.

- - - -## Implementation - -```dart -RefreshFailureInterface(super.code, super.msg); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshedEvent-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshedEvent-class.md deleted file mode 100644 index bdca95f0..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshedEvent-class.md +++ /dev/null @@ -1,136 +0,0 @@ - - - -# RefreshedEvent class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

When a user access token is refreshed (from the logged in state to the -logged in state with a different access token)

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [Equatable](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable-class.html) -- [AuthenticationChangeEvent](../wyatt_authentication_bloc/AuthenticationChangeEvent-class.md) -- RefreshedEvent - - - - - - - - -## Constructors - -[RefreshedEvent](../wyatt_authentication_bloc/RefreshedEvent/RefreshedEvent.md) ({required [Account](../wyatt_authentication_bloc/Account-class.md) account}) - - _const_ - - -## Properties - -##### [account](../wyatt_authentication_bloc/RefreshedEvent/account.md) → [Account](../wyatt_authentication_bloc/Account-class.md) - - - - -_final_ - - - -##### [hashCode](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [props](../wyatt_authentication_bloc/RefreshedEvent/props.md) → [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> - - - -The list of properties that will be used to determine whether -two instances are equal. -_read-onlyoverride_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - -##### [stringify](../wyatt_authentication_bloc/AuthenticationChangeEvent/stringify.md) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -If set to true, the toString method will be overridden to output -this instance's props. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshedEvent/RefreshedEvent.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshedEvent/RefreshedEvent.md deleted file mode 100644 index 7317339e..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshedEvent/RefreshedEvent.md +++ /dev/null @@ -1,30 +0,0 @@ - - - -# RefreshedEvent constructor - - - - - *[](https://dart.dev/null-safety)* - - -const -RefreshedEvent({required [Account](../../wyatt_authentication_bloc/Account-class.md) account}) - - - - - -## Implementation - -```dart -const RefreshedEvent({required this.account}); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshedEvent/account.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshedEvent/account.md deleted file mode 100644 index 671e197e..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshedEvent/account.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# account property - - - - - *[](https://dart.dev/null-safety)* - - - -[Account](../../wyatt_authentication_bloc/Account-class.md) account - -_final_ - - - - - - -## Implementation - -```dart -final Account account; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshedEvent/props.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshedEvent/props.md deleted file mode 100644 index fbde09d1..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/RefreshedEvent/props.md +++ /dev/null @@ -1,42 +0,0 @@ - - - -# props property - - - - - *[](https://dart.dev/null-safety)* - - - - - -**Annotations** - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) -[List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> props - -_override_ - - - -

The list of properties that will be used to determine whether -two instances are equal.

- - - -## Implementation - -```dart -@override -List get props => [account]; -``` - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendEmailVerificationFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendEmailVerificationFailureFirebase-class.md deleted file mode 100644 index 813d225c..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendEmailVerificationFailureFirebase-class.md +++ /dev/null @@ -1,137 +0,0 @@ - - - -# SendEmailVerificationFailureFirebase class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown during the email verification process if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- [SendEmailVerificationFailureInterface](../wyatt_authentication_bloc/SendEmailVerificationFailureInterface-class.md) -- SendEmailVerificationFailureFirebase - - - - - - - - -## Constructors - -[SendEmailVerificationFailureFirebase](../wyatt_authentication_bloc/SendEmailVerificationFailureFirebase/SendEmailVerificationFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - -[SendEmailVerificationFailureFirebase.fromCode](../wyatt_authentication_bloc/SendEmailVerificationFailureFirebase/SendEmailVerificationFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendEmailVerificationFailureFirebase/SendEmailVerificationFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendEmailVerificationFailureFirebase/SendEmailVerificationFailureFirebase.fromCode.md deleted file mode 100644 index 51531fd7..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendEmailVerificationFailureFirebase/SendEmailVerificationFailureFirebase.fromCode.md +++ /dev/null @@ -1,30 +0,0 @@ - - - -# SendEmailVerificationFailureFirebase.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SendEmailVerificationFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - - -## Implementation - -```dart -SendEmailVerificationFailureFirebase.fromCode(super.code) : super.fromCode(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendEmailVerificationFailureFirebase/SendEmailVerificationFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendEmailVerificationFailureFirebase/SendEmailVerificationFailureFirebase.md deleted file mode 100644 index e1f740ba..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendEmailVerificationFailureFirebase/SendEmailVerificationFailureFirebase.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# SendEmailVerificationFailureFirebase constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SendEmailVerificationFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - - - -## Implementation - -```dart -SendEmailVerificationFailureFirebase([String? code, String? msg]) - : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendEmailVerificationFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendEmailVerificationFailureInterface-class.md deleted file mode 100644 index 42fff498..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendEmailVerificationFailureInterface-class.md +++ /dev/null @@ -1,139 +0,0 @@ - - - -# SendEmailVerificationFailureInterface class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown during the email verification process if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- SendEmailVerificationFailureInterface - - - -**Implementers** - -- [SendEmailVerificationFailureFirebase](../wyatt_authentication_bloc/SendEmailVerificationFailureFirebase-class.md) - - - - - -## Constructors - -[SendEmailVerificationFailureInterface](../wyatt_authentication_bloc/SendEmailVerificationFailureInterface/SendEmailVerificationFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - -Thrown during the email verification process if a failure occurs. - -[SendEmailVerificationFailureInterface.fromCode](../wyatt_authentication_bloc/SendEmailVerificationFailureInterface/SendEmailVerificationFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - -Thrown during the email verification process if a failure occurs. - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendEmailVerificationFailureInterface/SendEmailVerificationFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendEmailVerificationFailureInterface/SendEmailVerificationFailureInterface.fromCode.md deleted file mode 100644 index 26acc0c1..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendEmailVerificationFailureInterface/SendEmailVerificationFailureInterface.fromCode.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# SendEmailVerificationFailureInterface.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SendEmailVerificationFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - -

Thrown during the email verification process if a failure occurs.

- - - -## Implementation - -```dart -SendEmailVerificationFailureInterface.fromCode(super.code) : super.fromCode(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendEmailVerificationFailureInterface/SendEmailVerificationFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendEmailVerificationFailureInterface/SendEmailVerificationFailureInterface.md deleted file mode 100644 index aeda1679..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendEmailVerificationFailureInterface/SendEmailVerificationFailureInterface.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# SendEmailVerificationFailureInterface constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SendEmailVerificationFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - - -

Thrown during the email verification process if a failure occurs.

- - - -## Implementation - -```dart -SendEmailVerificationFailureInterface(super.code, super.msg); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendPasswordResetEmailFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendPasswordResetEmailFailureFirebase-class.md deleted file mode 100644 index 55b4b215..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendPasswordResetEmailFailureFirebase-class.md +++ /dev/null @@ -1,137 +0,0 @@ - - - -# SendPasswordResetEmailFailureFirebase class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown during the password reset process if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- [SendPasswordResetEmailFailureInterface](../wyatt_authentication_bloc/SendPasswordResetEmailFailureInterface-class.md) -- SendPasswordResetEmailFailureFirebase - - - - - - - - -## Constructors - -[SendPasswordResetEmailFailureFirebase](../wyatt_authentication_bloc/SendPasswordResetEmailFailureFirebase/SendPasswordResetEmailFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - -[SendPasswordResetEmailFailureFirebase.fromCode](../wyatt_authentication_bloc/SendPasswordResetEmailFailureFirebase/SendPasswordResetEmailFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendPasswordResetEmailFailureFirebase/SendPasswordResetEmailFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendPasswordResetEmailFailureFirebase/SendPasswordResetEmailFailureFirebase.fromCode.md deleted file mode 100644 index 7b002359..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendPasswordResetEmailFailureFirebase/SendPasswordResetEmailFailureFirebase.fromCode.md +++ /dev/null @@ -1,30 +0,0 @@ - - - -# SendPasswordResetEmailFailureFirebase.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SendPasswordResetEmailFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - - -## Implementation - -```dart -SendPasswordResetEmailFailureFirebase.fromCode(super.code) : super.fromCode(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendPasswordResetEmailFailureFirebase/SendPasswordResetEmailFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendPasswordResetEmailFailureFirebase/SendPasswordResetEmailFailureFirebase.md deleted file mode 100644 index e2fdbeab..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendPasswordResetEmailFailureFirebase/SendPasswordResetEmailFailureFirebase.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# SendPasswordResetEmailFailureFirebase constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SendPasswordResetEmailFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - - - -## Implementation - -```dart -SendPasswordResetEmailFailureFirebase([String? code, String? msg]) - : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendPasswordResetEmailFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendPasswordResetEmailFailureInterface-class.md deleted file mode 100644 index 6473ac89..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendPasswordResetEmailFailureInterface-class.md +++ /dev/null @@ -1,139 +0,0 @@ - - - -# SendPasswordResetEmailFailureInterface class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown during the password reset process if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- SendPasswordResetEmailFailureInterface - - - -**Implementers** - -- [SendPasswordResetEmailFailureFirebase](../wyatt_authentication_bloc/SendPasswordResetEmailFailureFirebase-class.md) - - - - - -## Constructors - -[SendPasswordResetEmailFailureInterface](../wyatt_authentication_bloc/SendPasswordResetEmailFailureInterface/SendPasswordResetEmailFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - -Thrown during the password reset process if a failure occurs. - -[SendPasswordResetEmailFailureInterface.fromCode](../wyatt_authentication_bloc/SendPasswordResetEmailFailureInterface/SendPasswordResetEmailFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - -Thrown during the password reset process if a failure occurs. - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendPasswordResetEmailFailureInterface/SendPasswordResetEmailFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendPasswordResetEmailFailureInterface/SendPasswordResetEmailFailureInterface.fromCode.md deleted file mode 100644 index 039bd78b..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendPasswordResetEmailFailureInterface/SendPasswordResetEmailFailureInterface.fromCode.md +++ /dev/null @@ -1,32 +0,0 @@ - - - -# SendPasswordResetEmailFailureInterface.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SendPasswordResetEmailFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - -

Thrown during the password reset process if a failure occurs.

- - - -## Implementation - -```dart -SendPasswordResetEmailFailureInterface.fromCode(super.code) - : super.fromCode(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendPasswordResetEmailFailureInterface/SendPasswordResetEmailFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendPasswordResetEmailFailureInterface/SendPasswordResetEmailFailureInterface.md deleted file mode 100644 index cec0a974..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendPasswordResetEmailFailureInterface/SendPasswordResetEmailFailureInterface.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# SendPasswordResetEmailFailureInterface constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SendPasswordResetEmailFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - - -

Thrown during the password reset process if a failure occurs.

- - - -## Implementation - -```dart -SendPasswordResetEmailFailureInterface(super.code, super.msg); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendSignInLinkEmailFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendSignInLinkEmailFailureFirebase-class.md deleted file mode 100644 index b487ad39..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendSignInLinkEmailFailureFirebase-class.md +++ /dev/null @@ -1,137 +0,0 @@ - - - -# SendSignInLinkEmailFailureFirebase class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown during the sign in link process if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- [SendSignInLinkEmailFailureInterface](../wyatt_authentication_bloc/SendSignInLinkEmailFailureInterface-class.md) -- SendSignInLinkEmailFailureFirebase - - - - - - - - -## Constructors - -[SendSignInLinkEmailFailureFirebase](../wyatt_authentication_bloc/SendSignInLinkEmailFailureFirebase/SendSignInLinkEmailFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - -[SendSignInLinkEmailFailureFirebase.fromCode](../wyatt_authentication_bloc/SendSignInLinkEmailFailureFirebase/SendSignInLinkEmailFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendSignInLinkEmailFailureFirebase/SendSignInLinkEmailFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendSignInLinkEmailFailureFirebase/SendSignInLinkEmailFailureFirebase.fromCode.md deleted file mode 100644 index 11ea5805..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendSignInLinkEmailFailureFirebase/SendSignInLinkEmailFailureFirebase.fromCode.md +++ /dev/null @@ -1,30 +0,0 @@ - - - -# SendSignInLinkEmailFailureFirebase.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SendSignInLinkEmailFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - - -## Implementation - -```dart -SendSignInLinkEmailFailureFirebase.fromCode(super.code) : super.fromCode(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendSignInLinkEmailFailureFirebase/SendSignInLinkEmailFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendSignInLinkEmailFailureFirebase/SendSignInLinkEmailFailureFirebase.md deleted file mode 100644 index 27c3a9b9..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendSignInLinkEmailFailureFirebase/SendSignInLinkEmailFailureFirebase.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# SendSignInLinkEmailFailureFirebase constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SendSignInLinkEmailFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - - - -## Implementation - -```dart -SendSignInLinkEmailFailureFirebase([String? code, String? msg]) - : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendSignInLinkEmailFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendSignInLinkEmailFailureInterface-class.md deleted file mode 100644 index b1887411..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendSignInLinkEmailFailureInterface-class.md +++ /dev/null @@ -1,139 +0,0 @@ - - - -# SendSignInLinkEmailFailureInterface class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown during the sign in link process if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- SendSignInLinkEmailFailureInterface - - - -**Implementers** - -- [SendSignInLinkEmailFailureFirebase](../wyatt_authentication_bloc/SendSignInLinkEmailFailureFirebase-class.md) - - - - - -## Constructors - -[SendSignInLinkEmailFailureInterface](../wyatt_authentication_bloc/SendSignInLinkEmailFailureInterface/SendSignInLinkEmailFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - -Thrown during the sign in link process if a failure occurs. - -[SendSignInLinkEmailFailureInterface.fromCode](../wyatt_authentication_bloc/SendSignInLinkEmailFailureInterface/SendSignInLinkEmailFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - -Thrown during the sign in link process if a failure occurs. - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendSignInLinkEmailFailureInterface/SendSignInLinkEmailFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendSignInLinkEmailFailureInterface/SendSignInLinkEmailFailureInterface.fromCode.md deleted file mode 100644 index 6e8ab76a..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendSignInLinkEmailFailureInterface/SendSignInLinkEmailFailureInterface.fromCode.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# SendSignInLinkEmailFailureInterface.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SendSignInLinkEmailFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - -

Thrown during the sign in link process if a failure occurs.

- - - -## Implementation - -```dart -SendSignInLinkEmailFailureInterface.fromCode(super.code) : super.fromCode(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendSignInLinkEmailFailureInterface/SendSignInLinkEmailFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendSignInLinkEmailFailureInterface/SendSignInLinkEmailFailureInterface.md deleted file mode 100644 index eba02b41..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SendSignInLinkEmailFailureInterface/SendSignInLinkEmailFailureInterface.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# SendSignInLinkEmailFailureInterface constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SendSignInLinkEmailFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - - -

Thrown during the sign in link process if a failure occurs.

- - - -## Implementation - -```dart -SendSignInLinkEmailFailureInterface(super.code, super.msg); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Session-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Session-class.md deleted file mode 100644 index 29cc3040..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Session-class.md +++ /dev/null @@ -1,144 +0,0 @@ - - - -# Session<Data> class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

The Session object is used to transport and propagate -the connected user Account and personalized Data in the application.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [Equatable](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable-class.html) -- Session - - - - - - - - -## Constructors - -[Session](../wyatt_authentication_bloc/Session/Session.md) ({required [Account](../wyatt_authentication_bloc/Account-class.md) account, Data? data}) - - _const_ - - -## Properties - -##### [account](../wyatt_authentication_bloc/Session/account.md) → [Account](../wyatt_authentication_bloc/Account-class.md) - - - - -_final_ - - - -##### [data](../wyatt_authentication_bloc/Session/data.md) → Data? - - - - -_final_ - - - -##### [hashCode](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [props](../wyatt_authentication_bloc/Session/props.md) → [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> - - - -The list of properties that will be used to determine whether -two instances are equal. -_read-onlyoverride_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - -##### [stringify](../wyatt_authentication_bloc/Session/stringify.md) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)? - - - -If set to true, the toString method will be overridden to output -this instance's props. -_read-onlyoverride_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Session/Session.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Session/Session.md deleted file mode 100644 index f8c9a635..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Session/Session.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# Session<Data> constructor - - - - - *[](https://dart.dev/null-safety)* - - -const -Session<Data>({required [Account](../../wyatt_authentication_bloc/Account-class.md) account, Data? data}) - - - - - -## Implementation - -```dart -const Session({ - required this.account, - this.data, -}); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Session/account.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Session/account.md deleted file mode 100644 index 671e197e..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Session/account.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# account property - - - - - *[](https://dart.dev/null-safety)* - - - -[Account](../../wyatt_authentication_bloc/Account-class.md) account - -_final_ - - - - - - -## Implementation - -```dart -final Account account; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Session/data.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Session/data.md deleted file mode 100644 index b95c07e1..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Session/data.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# data property - - - - - *[](https://dart.dev/null-safety)* - - - -Data? data - -_final_ - - - - - - -## Implementation - -```dart -final Data? data; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Session/props.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Session/props.md deleted file mode 100644 index 5246eb8f..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Session/props.md +++ /dev/null @@ -1,42 +0,0 @@ - - - -# props property - - - - - *[](https://dart.dev/null-safety)* - - - - - -**Annotations** - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) -[List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> props - -_override_ - - - -

The list of properties that will be used to determine whether -two instances are equal.

- - - -## Implementation - -```dart -@override -List get props => [account, data]; -``` - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Session/stringify.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Session/stringify.md deleted file mode 100644 index c2fc4fca..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/Session/stringify.md +++ /dev/null @@ -1,47 +0,0 @@ - - - -# stringify property - - - - - *[](https://dart.dev/null-safety)* - - - - - -**Annotations** - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) -[bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)? stringify - -_override_ - - - -

If set to true, the toString method will be overridden to output -this instance's props.

-

A global default value for stringify can be set using -EquatableConfig.stringify.

-

If this instance's stringify is set to null, the value of -EquatableConfig.stringify will be used instead. This defaults to -false.

- - - -## Implementation - -```dart -@override -bool? get stringify => true; -``` - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SessionWrapper-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SessionWrapper-class.md deleted file mode 100644 index dd0d4a9d..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SessionWrapper-class.md +++ /dev/null @@ -1,144 +0,0 @@ - - - -# SessionWrapper<Data> class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Contains the AuthenticationChangeEvent initiating the state -change and the current Session.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [Equatable](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable-class.html) -- SessionWrapper - - - - - - - - -## Constructors - -[SessionWrapper](../wyatt_authentication_bloc/SessionWrapper/SessionWrapper.md) ({required [AuthenticationChangeEvent](../wyatt_authentication_bloc/AuthenticationChangeEvent-class.md) event, [Session](../wyatt_authentication_bloc/Session-class.md)<Data>? session}) - - _const_ - - -## Properties - -##### [event](../wyatt_authentication_bloc/SessionWrapper/event.md) → [AuthenticationChangeEvent](../wyatt_authentication_bloc/AuthenticationChangeEvent-class.md) - - - - -_final_ - - - -##### [hashCode](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [props](../wyatt_authentication_bloc/SessionWrapper/props.md) → [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> - - - -The list of properties that will be used to determine whether -two instances are equal. -_read-onlyoverride_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - -##### [session](../wyatt_authentication_bloc/SessionWrapper/session.md) → [Session](../wyatt_authentication_bloc/Session-class.md)<Data>? - - - - -_final_ - - - -##### [stringify](../wyatt_authentication_bloc/SessionWrapper/stringify.md) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -If set to true, the toString method will be overridden to output -this instance's props. -_read-onlyoverride_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SessionWrapper/SessionWrapper.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SessionWrapper/SessionWrapper.md deleted file mode 100644 index d26a9969..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SessionWrapper/SessionWrapper.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# SessionWrapper<Data> constructor - - - - - *[](https://dart.dev/null-safety)* - - -const -SessionWrapper<Data>({required [AuthenticationChangeEvent](../../wyatt_authentication_bloc/AuthenticationChangeEvent-class.md) event, [Session](../../wyatt_authentication_bloc/Session-class.md)<Data>? session}) - - - - - -## Implementation - -```dart -const SessionWrapper({ - required this.event, - this.session, -}); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SessionWrapper/event.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SessionWrapper/event.md deleted file mode 100644 index a1e5da09..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SessionWrapper/event.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# event property - - - - - *[](https://dart.dev/null-safety)* - - - -[AuthenticationChangeEvent](../../wyatt_authentication_bloc/AuthenticationChangeEvent-class.md) event - -_final_ - - - - - - -## Implementation - -```dart -final AuthenticationChangeEvent event; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SessionWrapper/props.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SessionWrapper/props.md deleted file mode 100644 index 318648ca..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SessionWrapper/props.md +++ /dev/null @@ -1,42 +0,0 @@ - - - -# props property - - - - - *[](https://dart.dev/null-safety)* - - - - - -**Annotations** - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) -[List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> props - -_override_ - - - -

The list of properties that will be used to determine whether -two instances are equal.

- - - -## Implementation - -```dart -@override -List get props => [event, session]; -``` - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SessionWrapper/session.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SessionWrapper/session.md deleted file mode 100644 index a713c2af..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SessionWrapper/session.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# session property - - - - - *[](https://dart.dev/null-safety)* - - - -[Session](../../wyatt_authentication_bloc/Session-class.md)<Data>? session - -_final_ - - - - - - -## Implementation - -```dart -final Session? session; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SessionWrapper/stringify.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SessionWrapper/stringify.md deleted file mode 100644 index 4fe942de..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SessionWrapper/stringify.md +++ /dev/null @@ -1,47 +0,0 @@ - - - -# stringify property - - - - - *[](https://dart.dev/null-safety)* - - - - - -**Annotations** - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) -[bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) stringify - -_override_ - - - -

If set to true, the toString method will be overridden to output -this instance's props.

-

A global default value for stringify can be set using -EquatableConfig.stringify.

-

If this instance's stringify is set to null, the value of -EquatableConfig.stringify will be used instead. This defaults to -false.

- - - -## Implementation - -```dart -@override -bool get stringify => true; -``` - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymously-mixin.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymously-mixin.md deleted file mode 100644 index 3dd086b7..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymously-mixin.md +++ /dev/null @@ -1,269 +0,0 @@ - - - -# SignInAnonymously<Data> mixin - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Sign in mixin.

-

Allows the user to sign in anonymously

-

Gives access to the signInAnonymously method and -onSignInAnonymously callback.

- - -**Superclass Constraints** - -- [BaseSignInCubit](../wyatt_authentication_bloc/BaseSignInCubit-class.md)<Data> - - - - -**Mixin Applications** - -- [SignInCubit](../wyatt_authentication_bloc/SignInCubit-class.md) - - - -## Properties - -##### [authenticationRepository](../wyatt_authentication_bloc/BaseSignInCubit/authenticationRepository.md) → [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> - - - - -_finalinherited_ - - - -##### [formName](../wyatt_authentication_bloc/BaseSignInCubit/formName.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [formRepository](../wyatt_authentication_bloc/BaseSignInCubit/formRepository.md) → FormRepository - - - - -_read-onlyinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [isClosed](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/isClosed.html) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -Whether the bloc is closed. -_read-onlyinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - -##### [state](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/state.html) → [SignInState](../wyatt_authentication_bloc/SignInState-class.md) - - - -The current state. -_read-onlyinherited_ - - - -##### [stream](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/stream.html) → [Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[SignInState](../wyatt_authentication_bloc/SignInState-class.md)> - - - -The current stream of states. -_read-onlyinherited_ - - - - - -## Methods - -##### [addError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/addError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [[StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html)? stackTrace]) void - - - -Reports an error which triggers onError with an optional StackTrace. -_inherited_ - - - -##### [close](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/close.html)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> - - - -Closes the instance. -This method should be called when the instance is no longer needed. -Once close is called, the instance can no longer be used. -_inherited_ - - - -##### [dataChanged](../wyatt_authentication_bloc/BaseSignInCubit/dataChanged.md)<Value>([String](https://api.flutter.dev/flutter/dart-core/String-class.html) key, FormInputValidator<Value, ValidationError> dirtyValue) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - -##### [emit](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/emit.html)([SignInState](../wyatt_authentication_bloc/SignInState-class.md) state) void - - - -Updates the state to the provided state. -emit does nothing if the state being emitted -is equal to the current state. -_inherited_ - - - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [onChange](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onChange.html)([Change](https://pub.dev/documentation/bloc/8.1.0/bloc/Change-class.html)<[SignInState](../wyatt_authentication_bloc/SignInState-class.md)> change) void - - - -Called whenever a change occurs with the given change. -A change occurs when a new state is emitted. -onChange is called before the state of the cubit is updated. -onChange is a great spot to add logging/analytics for a specific cubit. -_inherited_ - - - -##### [onError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html) stackTrace) void - - - -Called whenever an error occurs and notifies BlocObserver.onError. -_inherited_ - - - -##### [onSignInAnonymously](../wyatt_authentication_bloc/SignInAnonymously/onSignInAnonymously.md)(Result<[Account](../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) FutureOrResult<Data?> - - - -This callback is triggered when a user signs in anonymously. - - - - -##### [reset](../wyatt_authentication_bloc/BaseSignInCubit/reset.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - -##### [signInAnonymously](../wyatt_authentication_bloc/SignInAnonymously/signInAnonymously.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - -Sign in anonymously. - - - - -##### [submit](../wyatt_authentication_bloc/BaseSignInCubit/submit.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - -##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - -##### [update](../wyatt_authentication_bloc/BaseSignInCubit/update.md)(WyattForm form, {SetOperation operation = SetOperation.replace}) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - -##### [validate](../wyatt_authentication_bloc/BaseSignInCubit/validate.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymously/onSignInAnonymously.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymously/onSignInAnonymously.md deleted file mode 100644 index fa83d0b9..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymously/onSignInAnonymously.md +++ /dev/null @@ -1,39 +0,0 @@ - - - -# onSignInAnonymously method - - - - - *[](https://dart.dev/null-safety)* - - - - -FutureOrResult<Data?> onSignInAnonymously -(Result<[Account](../../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) - - - - - -

This callback is triggered when a user signs in anonymously.

- - - -## Implementation - -```dart -FutureOrResult onSignInAnonymously( - Result result, - WyattForm form, -); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymously/signInAnonymously.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymously/signInAnonymously.md deleted file mode 100644 index 0c21eeb5..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymously/signInAnonymously.md +++ /dev/null @@ -1,79 +0,0 @@ - - - -# signInAnonymously method - - - - - *[](https://dart.dev/null-safety)* - - - - -[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> signInAnonymously -() - - - - - -

Sign in anonymously.

-

Throws a SignInAnonymouslyFailureInterface if an exception occurs.

- - - -## Implementation - -```dart -FutureOr signInAnonymously() async { - if (state.status.isSubmissionInProgress) { - return; - } - - final form = formRepository.accessForm(formName); - emit(SignInState(form: form, status: FormStatus.submissionInProgress)); - - return CustomRoutine( - routine: authenticationRepository.signInAnonymously, - attachedLogic: (routineResult) => onSignInAnonymously( - routineResult, - form, - ), - onError: (error) { - emit( - SignInState( - form: form, - errorMessage: error.message, - status: FormStatus.submissionFailure, - ), - ); - addError(error); - }, - onSuccess: (account, data) { - authenticationRepository.addSession( - SessionWrapper( - event: SignedInEvent(account: account), - session: Session( - account: account, - data: data, - ), - ), - ); - emit( - SignInState( - form: form, - status: FormStatus.submissionSuccess, - ), - ); - }, - ).call(); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymouslyFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymouslyFailureFirebase-class.md deleted file mode 100644 index 23458a20..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymouslyFailureFirebase-class.md +++ /dev/null @@ -1,137 +0,0 @@ - - - -# SignInAnonymouslyFailureFirebase class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown during the sign in process if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- [SignInAnonymouslyFailureInterface](../wyatt_authentication_bloc/SignInAnonymouslyFailureInterface-class.md) -- SignInAnonymouslyFailureFirebase - - - - - - - - -## Constructors - -[SignInAnonymouslyFailureFirebase](../wyatt_authentication_bloc/SignInAnonymouslyFailureFirebase/SignInAnonymouslyFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - -[SignInAnonymouslyFailureFirebase.fromCode](../wyatt_authentication_bloc/SignInAnonymouslyFailureFirebase/SignInAnonymouslyFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymouslyFailureFirebase/SignInAnonymouslyFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymouslyFailureFirebase/SignInAnonymouslyFailureFirebase.fromCode.md deleted file mode 100644 index 7edb701d..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymouslyFailureFirebase/SignInAnonymouslyFailureFirebase.fromCode.md +++ /dev/null @@ -1,40 +0,0 @@ - - - -# SignInAnonymouslyFailureFirebase.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SignInAnonymouslyFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - - -## Implementation - -```dart -SignInAnonymouslyFailureFirebase.fromCode(String code) - : super.fromCode(code) { - switch (code) { - case 'operation-not-allowed': - msg = 'Operation is not allowed. Please contact support.'; - break; - default: - this.code = 'unknown'; - msg = 'An unknown error occurred.'; - } -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymouslyFailureFirebase/SignInAnonymouslyFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymouslyFailureFirebase/SignInAnonymouslyFailureFirebase.md deleted file mode 100644 index 3125f39a..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymouslyFailureFirebase/SignInAnonymouslyFailureFirebase.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# SignInAnonymouslyFailureFirebase constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SignInAnonymouslyFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - - - -## Implementation - -```dart -SignInAnonymouslyFailureFirebase([String? code, String? msg]) - : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymouslyFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymouslyFailureInterface-class.md deleted file mode 100644 index df9dd187..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymouslyFailureInterface-class.md +++ /dev/null @@ -1,139 +0,0 @@ - - - -# SignInAnonymouslyFailureInterface class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown during the sign in process if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- SignInAnonymouslyFailureInterface - - - -**Implementers** - -- [SignInAnonymouslyFailureFirebase](../wyatt_authentication_bloc/SignInAnonymouslyFailureFirebase-class.md) - - - - - -## Constructors - -[SignInAnonymouslyFailureInterface](../wyatt_authentication_bloc/SignInAnonymouslyFailureInterface/SignInAnonymouslyFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - -Thrown during the sign in process if a failure occurs. - -[SignInAnonymouslyFailureInterface.fromCode](../wyatt_authentication_bloc/SignInAnonymouslyFailureInterface/SignInAnonymouslyFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - -Thrown during the sign in process if a failure occurs. - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymouslyFailureInterface/SignInAnonymouslyFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymouslyFailureInterface/SignInAnonymouslyFailureInterface.fromCode.md deleted file mode 100644 index 13e4bd31..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymouslyFailureInterface/SignInAnonymouslyFailureInterface.fromCode.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# SignInAnonymouslyFailureInterface.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SignInAnonymouslyFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - -

Thrown during the sign in process if a failure occurs.

- - - -## Implementation - -```dart -SignInAnonymouslyFailureInterface.fromCode(super.code) : super.fromCode(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymouslyFailureInterface/SignInAnonymouslyFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymouslyFailureInterface/SignInAnonymouslyFailureInterface.md deleted file mode 100644 index 54eeaeb0..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInAnonymouslyFailureInterface/SignInAnonymouslyFailureInterface.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# SignInAnonymouslyFailureInterface constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SignInAnonymouslyFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - - -

Thrown during the sign in process if a failure occurs.

- - - -## Implementation - -```dart -SignInAnonymouslyFailureInterface(super.code, super.msg); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInCubit-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInCubit-class.md deleted file mode 100644 index 638a83a7..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInCubit-class.md +++ /dev/null @@ -1,354 +0,0 @@ - - - -# SignInCubit<Data> class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Fully featured sign in cubit.

-

Sufficient in most cases. (Where fine granularity is not required.)

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [BlocBase](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase-class.html)<[SignInState](../wyatt_authentication_bloc/SignInState-class.md)> -- [Cubit](https://pub.dev/documentation/bloc/8.1.0/bloc/Cubit-class.html)<[SignInState](../wyatt_authentication_bloc/SignInState-class.md)> -- [BaseSignInCubit](../wyatt_authentication_bloc/BaseSignInCubit-class.md)<Data> -- SignInCubit - - -**Mixed in types** - -- [SignInAnonymously](../wyatt_authentication_bloc/SignInAnonymously-mixin.md)<Data> -- [SignInWithEmailPassword](../wyatt_authentication_bloc/SignInWithEmailPassword-mixin.md)<Data> -- [SignInWithGoogle](../wyatt_authentication_bloc/SignInWithGoogle-mixin.md)<Data> - - - - - - -## Constructors - -[SignInCubit](../wyatt_authentication_bloc/SignInCubit/SignInCubit.md) ({required [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> authenticationRepository}) - - - - -## Properties - -##### [authenticationRepository](../wyatt_authentication_bloc/BaseSignInCubit/authenticationRepository.md) → [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> - - - - -_finalinherited_ - - - -##### [formName](../wyatt_authentication_bloc/BaseSignInCubit/formName.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [formRepository](../wyatt_authentication_bloc/BaseSignInCubit/formRepository.md) → FormRepository - - - - -_read-onlyinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [isClosed](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/isClosed.html) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -Whether the bloc is closed. -_read-onlyinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - -##### [state](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/state.html) → [SignInState](../wyatt_authentication_bloc/SignInState-class.md) - - - -The current state. -_read-onlyinherited_ - - - -##### [stream](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/stream.html) → [Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[SignInState](../wyatt_authentication_bloc/SignInState-class.md)> - - - -The current stream of states. -_read-onlyinherited_ - - - - - -## Methods - -##### [addError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/addError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [[StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html)? stackTrace]) void - - - -Reports an error which triggers onError with an optional StackTrace. -_inherited_ - - - -##### [close](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/close.html)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> - - - -Closes the instance. -This method should be called when the instance is no longer needed. -Once close is called, the instance can no longer be used. -_inherited_ - - - -##### [dataChanged](../wyatt_authentication_bloc/BaseSignInCubit/dataChanged.md)<Value>([String](https://api.flutter.dev/flutter/dart-core/String-class.html) key, FormInputValidator<Value, ValidationError> dirtyValue) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - -##### [emailChanged](../wyatt_authentication_bloc/SignInWithEmailPassword/emailChanged.md)([String](https://api.flutter.dev/flutter/dart-core/String-class.html) value) void - - - - -_inherited_ - - - -##### [emailCustomChanged](../wyatt_authentication_bloc/SignInWithEmailPassword/emailCustomChanged.md)<Validator extends FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError>>(Validator validator) void - - - -Same as emailChanged but with a custom Validator. -_inherited_ - - - -##### [emit](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/emit.html)([SignInState](../wyatt_authentication_bloc/SignInState-class.md) state) void - - - -Updates the state to the provided state. -emit does nothing if the state being emitted -is equal to the current state. -_inherited_ - - - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [onChange](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onChange.html)([Change](https://pub.dev/documentation/bloc/8.1.0/bloc/Change-class.html)<[SignInState](../wyatt_authentication_bloc/SignInState-class.md)> change) void - - - -Called whenever a change occurs with the given change. -A change occurs when a new state is emitted. -onChange is called before the state of the cubit is updated. -onChange is a great spot to add logging/analytics for a specific cubit. -_inherited_ - - - -##### [onError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html) stackTrace) void - - - -Called whenever an error occurs and notifies BlocObserver.onError. -_inherited_ - - - -##### [onSignInAnonymously](../wyatt_authentication_bloc/SignInCubit/onSignInAnonymously.md)(Result<[Account](../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) FutureOrResult<Data?> - - - -This callback is triggered when a user signs in anonymously. -_override_ - - - -##### [onSignInWithEmailAndPassword](../wyatt_authentication_bloc/SignInCubit/onSignInWithEmailAndPassword.md)(Result<[Account](../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) FutureOrResult<Data?> - - - -This callback is triggered when a user signs in with email and password. -_override_ - - - -##### [onSignInWithGoogle](../wyatt_authentication_bloc/SignInCubit/onSignInWithGoogle.md)(Result<[Account](../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) FutureOrResult<Data?> - - - -This callback is triggered when a user signs in with google. -_override_ - - - -##### [passwordChanged](../wyatt_authentication_bloc/SignInWithEmailPassword/passwordChanged.md)([String](https://api.flutter.dev/flutter/dart-core/String-class.html) value) void - - - - -_inherited_ - - - -##### [passwordCustomChanged](../wyatt_authentication_bloc/SignInWithEmailPassword/passwordCustomChanged.md)<Validator extends FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError>>(Validator validator) void - - - -Same as passwordChanged but with a custom Validator. -_inherited_ - - - -##### [reset](../wyatt_authentication_bloc/BaseSignInCubit/reset.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - -##### [signInAnonymously](../wyatt_authentication_bloc/SignInAnonymously/signInAnonymously.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - -Sign in anonymously. -_inherited_ - - - -##### [signInWithEmailAndPassword](../wyatt_authentication_bloc/SignInWithEmailPassword/signInWithEmailAndPassword.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - -Signs in with the provided email and password. -_inherited_ - - - -##### [signInWithGoogle](../wyatt_authentication_bloc/SignInWithGoogle/signInWithGoogle.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - -Starts the Sign In with Google Flow. -_inherited_ - - - -##### [submit](../wyatt_authentication_bloc/BaseSignInCubit/submit.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - -##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - -##### [update](../wyatt_authentication_bloc/BaseSignInCubit/update.md)(WyattForm form, {SetOperation operation = SetOperation.replace}) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - -##### [validate](../wyatt_authentication_bloc/BaseSignInCubit/validate.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInCubit/SignInCubit.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInCubit/SignInCubit.md deleted file mode 100644 index f2a52155..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInCubit/SignInCubit.md +++ /dev/null @@ -1,30 +0,0 @@ - - - -# SignInCubit<Data> constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SignInCubit<Data>({required [AuthenticationRepository](../../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> authenticationRepository}) - - - - - -## Implementation - -```dart -SignInCubit({required super.authenticationRepository}); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInCubit/onSignInAnonymously.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInCubit/onSignInAnonymously.md deleted file mode 100644 index 034b1e38..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInCubit/onSignInAnonymously.md +++ /dev/null @@ -1,42 +0,0 @@ - - - -# onSignInAnonymously method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -FutureOrResult<Data?> onSignInAnonymously -(Result<[Account](../../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) - -_override_ - - - -

This callback is triggered when a user signs in anonymously.

- - - -## Implementation - -```dart -@override -FutureOrResult onSignInAnonymously( - Result result, - WyattForm form, -) => - const Ok(null); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInCubit/onSignInWithEmailAndPassword.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInCubit/onSignInWithEmailAndPassword.md deleted file mode 100644 index 53132dae..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInCubit/onSignInWithEmailAndPassword.md +++ /dev/null @@ -1,42 +0,0 @@ - - - -# onSignInWithEmailAndPassword method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -FutureOrResult<Data?> onSignInWithEmailAndPassword -(Result<[Account](../../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) - -_override_ - - - -

This callback is triggered when a user signs in with email and password.

- - - -## Implementation - -```dart -@override -FutureOrResult onSignInWithEmailAndPassword( - Result result, - WyattForm form, -) => - const Ok(null); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInCubit/onSignInWithGoogle.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInCubit/onSignInWithGoogle.md deleted file mode 100644 index 19904a99..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInCubit/onSignInWithGoogle.md +++ /dev/null @@ -1,42 +0,0 @@ - - - -# onSignInWithGoogle method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -FutureOrResult<Data?> onSignInWithGoogle -(Result<[Account](../../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) - -_override_ - - - -

This callback is triggered when a user signs in with google.

- - - -## Implementation - -```dart -@override -FutureOrResult onSignInWithGoogle( - Result result, - WyattForm form, -) => - const Ok(null); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener-class.md deleted file mode 100644 index f048a063..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener-class.md +++ /dev/null @@ -1,236 +0,0 @@ - - - -# SignInListener<Data> class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Widget that listens and builds a child based on the state of -the sign in cubit

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [DiagnosticableTree](https://api.flutter.dev/flutter/foundation/DiagnosticableTree-class.html) -- [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) -- [StatelessWidget](https://api.flutter.dev/flutter/widgets/StatelessWidget-class.html) -- SignInListener - - - - - - - - -## Constructors - -[SignInListener](../wyatt_authentication_bloc/SignInListener/SignInListener.md) ({required [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) child, void onProgress([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?, void onSuccess([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?, void onError([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, FormStatus status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage)?, void customBuilder([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, [SignInState](../wyatt_authentication_bloc/SignInState-class.md) state)?, [Key](https://api.flutter.dev/flutter/foundation/Key-class.html)? key}) - - _const_ - - -## Properties - -##### [child](../wyatt_authentication_bloc/SignInListener/child.md) → [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) - - - - -_final_ - - - -##### [customBuilder](../wyatt_authentication_bloc/SignInListener/customBuilder.md) → (void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, [SignInState](../wyatt_authentication_bloc/SignInState-class.md) state)?) - - - - -_final_ - - - -##### [hashCode](https://api.flutter.dev/flutter/widgets/Widget/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [key](https://api.flutter.dev/flutter/widgets/Widget/key.html) → [Key](https://api.flutter.dev/flutter/foundation/Key-class.html)? - - - -Controls how one widget replaces another widget in the tree. -_finalinherited_ - - - -##### [onError](../wyatt_authentication_bloc/SignInListener/onError.md) → (void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, FormStatus status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage)?) - - - - -_final_ - - - -##### [onProgress](../wyatt_authentication_bloc/SignInListener/onProgress.md) → (void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?) - - - - -_final_ - - - -##### [onSuccess](../wyatt_authentication_bloc/SignInListener/onSuccess.md) → (void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?) - - - - -_final_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [build](../wyatt_authentication_bloc/SignInListener/build.md)([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context) [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) - - - -Describes the part of the user interface represented by this widget. -_override_ - - - -##### [createElement](https://api.flutter.dev/flutter/widgets/StatelessWidget/createElement.html)() [StatelessElement](https://api.flutter.dev/flutter/widgets/StatelessElement-class.html) - - - -Creates a StatelessElement to manage this widget's location in the tree. -_inherited_ - - - -##### [debugDescribeChildren](https://api.flutter.dev/flutter/foundation/DiagnosticableTree/debugDescribeChildren.html)() [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[DiagnosticsNode](https://api.flutter.dev/flutter/foundation/DiagnosticsNode-class.html)> - - - -Returns a list of DiagnosticsNode objects describing this node's -children. -_inherited_ - - - -##### [debugFillProperties](https://api.flutter.dev/flutter/widgets/Widget/debugFillProperties.html)([DiagnosticPropertiesBuilder](https://api.flutter.dev/flutter/foundation/DiagnosticPropertiesBuilder-class.html) properties) void - - - -Add additional properties associated with the node. -_inherited_ - - - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toDiagnosticsNode](https://api.flutter.dev/flutter/foundation/DiagnosticableTree/toDiagnosticsNode.html)({[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? name, [DiagnosticsTreeStyle](https://api.flutter.dev/flutter/foundation/DiagnosticsTreeStyle.html)? style}) [DiagnosticsNode](https://api.flutter.dev/flutter/foundation/DiagnosticsNode-class.html) - - - -Returns a debug representation of the object that is used by debugging -tools and by DiagnosticsNode.toStringDeep. -_inherited_ - - - -##### [toString](https://api.flutter.dev/flutter/foundation/Diagnosticable/toString.html)({[DiagnosticLevel](https://api.flutter.dev/flutter/foundation/DiagnosticLevel.html) minLevel = DiagnosticLevel.info}) [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - -##### [toStringDeep](https://api.flutter.dev/flutter/foundation/DiagnosticableTree/toStringDeep.html)({[String](https://api.flutter.dev/flutter/dart-core/String-class.html) prefixLineOne = '', [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? prefixOtherLines, [DiagnosticLevel](https://api.flutter.dev/flutter/foundation/DiagnosticLevel.html) minLevel = DiagnosticLevel.debug}) [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -Returns a string representation of this node and its descendants. -_inherited_ - - - -##### [toStringShallow](https://api.flutter.dev/flutter/foundation/DiagnosticableTree/toStringShallow.html)({[String](https://api.flutter.dev/flutter/dart-core/String-class.html) joiner = ', ', [DiagnosticLevel](https://api.flutter.dev/flutter/foundation/DiagnosticLevel.html) minLevel = DiagnosticLevel.debug}) [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -Returns a one-line detailed description of the object. -_inherited_ - - - -##### [toStringShort](https://api.flutter.dev/flutter/widgets/Widget/toStringShort.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A short, textual description of this widget. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/widgets/Widget/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/SignInListener.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/SignInListener.md deleted file mode 100644 index a9cfeea1..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/SignInListener.md +++ /dev/null @@ -1,37 +0,0 @@ - - - -# SignInListener<Data> constructor - - - - - *[](https://dart.dev/null-safety)* - - -const -SignInListener<Data>({required [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) child, void onProgress([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?, void onSuccess([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?, void onError([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, FormStatus status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage)?, void customBuilder([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, [SignInState](../../wyatt_authentication_bloc/SignInState-class.md) state)?, [Key](https://api.flutter.dev/flutter/foundation/Key-class.html)? key}) - - - - - -## Implementation - -```dart -const SignInListener({ - required this.child, - this.onProgress, - this.onSuccess, - this.onError, - this.customBuilder, - super.key, -}); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/build.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/build.md deleted file mode 100644 index d6783753..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/build.md +++ /dev/null @@ -1,92 +0,0 @@ - - - -# build method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) build -([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context) - -_override_ - - - -

Describes the part of the user interface represented by this widget.

-

The framework calls this method when this widget is inserted into the tree -in a given BuildContext and when the dependencies of this widget change -(e.g., an InheritedWidget referenced by this widget changes). This -method can potentially be called in every frame and should not have any side -effects beyond building a widget.

-

The framework replaces the subtree below this widget with the widget -returned by this method, either by updating the existing subtree or by -removing the subtree and inflating a new subtree, depending on whether the -widget returned by this method can update the root of the existing -subtree, as determined by calling Widget.canUpdate.

-

Typically implementations return a newly created constellation of widgets -that are configured with information from this widget's constructor and -from the given BuildContext.

-

The given BuildContext contains information about the location in the -tree at which this widget is being built. For example, the context -provides the set of inherited widgets for this location in the tree. A -given widget might be built with multiple different BuildContext -arguments over time if the widget is moved around the tree or if the -widget is inserted into the tree in multiple places at once.

-

The implementation of this method must only depend on:

- -

If a widget's build method is to depend on anything else, use a -StatefulWidget instead.

-

See also:

-
    -
  • StatelessWidget, which contains the discussion on performance considerations.
  • -
- - - -## Implementation - -```dart -@override -Widget build(BuildContext context) => - BlocListener, SignInState>( - listener: (context, state) { - if (customBuilder != null) { - return customBuilder!(context, state); - } - - if (onSuccess != null && - state.status == FormStatus.submissionSuccess) { - return onSuccess!(context); - } - if (onProgress != null && - state.status == FormStatus.submissionInProgress) { - return onProgress!(context); - } - if (onError != null && - (state.status == FormStatus.submissionCanceled || - state.status == FormStatus.submissionFailure)) { - return onError!(context, state.status, state.errorMessage); - } - }, - child: child, - ); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/child.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/child.md deleted file mode 100644 index 53bc3682..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/child.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# child property - - - - - *[](https://dart.dev/null-safety)* - - - -[Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) child - -_final_ - - - - - - -## Implementation - -```dart -final Widget child; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/customBuilder.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/customBuilder.md deleted file mode 100644 index 132cb4c3..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/customBuilder.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# customBuilder property - - - - - *[](https://dart.dev/null-safety)* - - - -(void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, [SignInState](../../wyatt_authentication_bloc/SignInState-class.md) state)?) customBuilder - -_final_ - - - - - - -## Implementation - -```dart -final void Function(BuildContext context, SignInState state)? customBuilder; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/onError.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/onError.md deleted file mode 100644 index ed94a98f..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/onError.md +++ /dev/null @@ -1,37 +0,0 @@ - - - -# onError property - - - - - *[](https://dart.dev/null-safety)* - - - -(void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, FormStatus status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage)?) onError - -_final_ - - - - - - -## Implementation - -```dart -final void Function( - BuildContext context, - FormStatus status, - String? errorMessage, -)? onError; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/onProgress.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/onProgress.md deleted file mode 100644 index 4a30ed71..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/onProgress.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# onProgress property - - - - - *[](https://dart.dev/null-safety)* - - - -(void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?) onProgress - -_final_ - - - - - - -## Implementation - -```dart -final void Function(BuildContext context)? onProgress; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/onSuccess.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/onSuccess.md deleted file mode 100644 index 4d942f63..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInListener/onSuccess.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# onSuccess property - - - - - *[](https://dart.dev/null-safety)* - - - -(void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?) onSuccess - -_final_ - - - - - - -## Implementation - -```dart -final void Function(BuildContext context)? onSuccess; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState-class.md deleted file mode 100644 index efb514c4..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState-class.md +++ /dev/null @@ -1,179 +0,0 @@ - - - -# SignInState class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Sign in cubit state to manage the form.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [Equatable](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable-class.html) -- SignInState - - - - - - - - -## Constructors - -[SignInState](../wyatt_authentication_bloc/SignInState/SignInState.md) ({required WyattForm form, FormStatus status = FormStatus.pure, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage}) - - _const_ - - -## Properties - -##### [email](../wyatt_authentication_bloc/SignInState/email.md) → FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError> - - - - -_read-only_ - - - -##### [errorMessage](../wyatt_authentication_bloc/SignInState/errorMessage.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? - - - -Optional error message. -_finalinherited_ - - - -##### [form](../wyatt_authentication_bloc/SignInState/form.md) → WyattForm - - - -FormData with all inputs, and associated metadata. -_finalinherited_ - - - -##### [hashCode](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [password](../wyatt_authentication_bloc/SignInState/password.md) → FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError> - - - - -_read-only_ - - - -##### [props](../wyatt_authentication_bloc/SignInState/props.md) → [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)> - - - -The list of properties that will be used to determine whether -two instances are equal. -_read-only_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - -##### [status](../wyatt_authentication_bloc/SignInState/status.md) → FormStatus - - - -Global status of a form. -_finalinherited_ - - - -##### [stringify](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/stringify.html) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)? - - - -If set to true, the toString method will be overridden to output -this instance's props. -_read-onlyinherited_ - - - - - -## Methods - -##### [copyWith](../wyatt_authentication_bloc/SignInState/copyWith.md)({WyattForm? form, FormStatus? status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage}) [SignInState](../wyatt_authentication_bloc/SignInState-class.md) - - - - - - - - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/SignInState/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_override_ - - - - - -## Operators - -##### [operator ==](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/SignInState.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/SignInState.md deleted file mode 100644 index 648fe926..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/SignInState.md +++ /dev/null @@ -1,34 +0,0 @@ - - - -# SignInState constructor - - - - - *[](https://dart.dev/null-safety)* - - -const -SignInState({required WyattForm form, FormStatus status = FormStatus.pure, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage}) - - - - - -## Implementation - -```dart -const SignInState({ - required super.form, - super.status = FormStatus.pure, - super.errorMessage, -}); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/copyWith.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/copyWith.md deleted file mode 100644 index e6b06fe5..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/copyWith.md +++ /dev/null @@ -1,44 +0,0 @@ - - - -# copyWith method - - - - - *[](https://dart.dev/null-safety)* - - - - -[SignInState](../../wyatt_authentication_bloc/SignInState-class.md) copyWith -({WyattForm? form, FormStatus? status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage}) - - - - - - - - -## Implementation - -```dart -SignInState copyWith({ - WyattForm? form, - FormStatus? status, - String? errorMessage, -}) => - SignInState( - form: form ?? this.form, - status: status ?? this.status, - errorMessage: errorMessage ?? this.errorMessage, - ); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/email.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/email.md deleted file mode 100644 index 1ded8043..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/email.md +++ /dev/null @@ -1,37 +0,0 @@ - - - -# email property - - - - - *[](https://dart.dev/null-safety)* - - - - - -FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError> email - - - - - - - - -## Implementation - -```dart -FormInputValidator get email => - form.validatorOf(AuthFormField.email); -``` - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/errorMessage.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/errorMessage.md deleted file mode 100644 index d0856deb..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/errorMessage.md +++ /dev/null @@ -1,34 +0,0 @@ - - - -# errorMessage property - - - - - *[](https://dart.dev/null-safety)* - - - -[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage - -_finalinherited_ - - - -

Optional error message.

- - - -## Implementation - -```dart -final String? errorMessage; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/form.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/form.md deleted file mode 100644 index d3f2da76..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/form.md +++ /dev/null @@ -1,34 +0,0 @@ - - - -# form property - - - - - *[](https://dart.dev/null-safety)* - - - -WyattForm form - -_finalinherited_ - - - -

FormData with all inputs, and associated metadata.

- - - -## Implementation - -```dart -final WyattForm form; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/password.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/password.md deleted file mode 100644 index 77938106..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/password.md +++ /dev/null @@ -1,37 +0,0 @@ - - - -# password property - - - - - *[](https://dart.dev/null-safety)* - - - - - -FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError> password - - - - - - - - -## Implementation - -```dart -FormInputValidator get password => - form.validatorOf(AuthFormField.password); -``` - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/props.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/props.md deleted file mode 100644 index eab8d26c..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/props.md +++ /dev/null @@ -1,42 +0,0 @@ - - - -# props property - - - - - *[](https://dart.dev/null-safety)* - - - - - -**Annotations** - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) -[List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)> props - - - - - -

The list of properties that will be used to determine whether -two instances are equal.

- - - -## Implementation - -```dart -@override -List get props => [email, password, status]; -``` - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/status.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/status.md deleted file mode 100644 index 644a9f10..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/status.md +++ /dev/null @@ -1,34 +0,0 @@ - - - -# status property - - - - - *[](https://dart.dev/null-safety)* - - - -FormStatus status - -_finalinherited_ - - - -

Global status of a form.

- - - -## Implementation - -```dart -final FormStatus status; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/toString.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/toString.md deleted file mode 100644 index 01225d4e..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInState/toString.md +++ /dev/null @@ -1,48 +0,0 @@ - - - -# toString method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[String](https://api.flutter.dev/flutter/dart-core/String-class.html) toString -() - -_override_ - - - -

A string representation of this object.

-

Some classes have a default textual representation, -often paired with a static parse function (like int.parse). -These classes will provide the textual representation as -their string representation.

-

Other classes have no meaningful textual representation -that a program will care about. -Such classes will typically override toString to provide -useful information when inspecting the object, -mainly for debugging or logging.

- - - -## Implementation - -```dart -@override -String toString() => 'SignInState(status: ${status.name} ' - '${(errorMessage != null) ? " [$errorMessage]" : ""}, $form)'; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithAppleFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithAppleFailureFirebase-class.md deleted file mode 100644 index a188c284..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithAppleFailureFirebase-class.md +++ /dev/null @@ -1,141 +0,0 @@ - - - -# SignInWithAppleFailureFirebase class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown during the sign in process if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- [SignInWithCredentialFailureInterface](../wyatt_authentication_bloc/SignInWithCredentialFailureInterface-class.md) -- [SignInWithCredentialFailureFirebase](../wyatt_authentication_bloc/SignInWithCredentialFailureFirebase-class.md) -- SignInWithAppleFailureFirebase - -**Implemented types** - -- [SignInWithAppleFailureInterface](../wyatt_authentication_bloc/SignInWithAppleFailureInterface-class.md) - - - - - - - -## Constructors - -[SignInWithAppleFailureFirebase](../wyatt_authentication_bloc/SignInWithAppleFailureFirebase/SignInWithAppleFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - -[SignInWithAppleFailureFirebase.fromCode](../wyatt_authentication_bloc/SignInWithAppleFailureFirebase/SignInWithAppleFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithAppleFailureFirebase/SignInWithAppleFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithAppleFailureFirebase/SignInWithAppleFailureFirebase.fromCode.md deleted file mode 100644 index c07fe58b..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithAppleFailureFirebase/SignInWithAppleFailureFirebase.fromCode.md +++ /dev/null @@ -1,30 +0,0 @@ - - - -# SignInWithAppleFailureFirebase.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SignInWithAppleFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - - -## Implementation - -```dart -SignInWithAppleFailureFirebase.fromCode(super.code) : super.fromCode(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithAppleFailureFirebase/SignInWithAppleFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithAppleFailureFirebase/SignInWithAppleFailureFirebase.md deleted file mode 100644 index 4aa51024..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithAppleFailureFirebase/SignInWithAppleFailureFirebase.md +++ /dev/null @@ -1,30 +0,0 @@ - - - -# SignInWithAppleFailureFirebase constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SignInWithAppleFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - - - -## Implementation - -```dart -SignInWithAppleFailureFirebase([super.code, super.msg]); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithAppleFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithAppleFailureInterface-class.md deleted file mode 100644 index 7b1837ba..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithAppleFailureInterface-class.md +++ /dev/null @@ -1,140 +0,0 @@ - - - -# SignInWithAppleFailureInterface class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown during the sign in process if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- SignInWithAppleFailureInterface - - - -**Implementers** - -- [SignInWithAppleFailureFirebase](../wyatt_authentication_bloc/SignInWithAppleFailureFirebase-class.md) -- [SignInWithTwitterFailureFirebase](../wyatt_authentication_bloc/SignInWithTwitterFailureFirebase-class.md) - - - - - -## Constructors - -[SignInWithAppleFailureInterface](../wyatt_authentication_bloc/SignInWithAppleFailureInterface/SignInWithAppleFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - -Thrown during the sign in process if a failure occurs. - -[SignInWithAppleFailureInterface.fromCode](../wyatt_authentication_bloc/SignInWithAppleFailureInterface/SignInWithAppleFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - -Thrown during the sign in process if a failure occurs. - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithAppleFailureInterface/SignInWithAppleFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithAppleFailureInterface/SignInWithAppleFailureInterface.fromCode.md deleted file mode 100644 index 6786f6d9..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithAppleFailureInterface/SignInWithAppleFailureInterface.fromCode.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# SignInWithAppleFailureInterface.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SignInWithAppleFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - -

Thrown during the sign in process if a failure occurs.

- - - -## Implementation - -```dart -SignInWithAppleFailureInterface.fromCode(super.code) : super.fromCode(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithAppleFailureInterface/SignInWithAppleFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithAppleFailureInterface/SignInWithAppleFailureInterface.md deleted file mode 100644 index 6994d8b8..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithAppleFailureInterface/SignInWithAppleFailureInterface.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# SignInWithAppleFailureInterface constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SignInWithAppleFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - - -

Thrown during the sign in process if a failure occurs.

- - - -## Implementation - -```dart -SignInWithAppleFailureInterface(super.code, super.msg); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithCredentialFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithCredentialFailureFirebase-class.md deleted file mode 100644 index f9e120f8..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithCredentialFailureFirebase-class.md +++ /dev/null @@ -1,143 +0,0 @@ - - - -# SignInWithCredentialFailureFirebase class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown during the sign in process if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- [SignInWithCredentialFailureInterface](../wyatt_authentication_bloc/SignInWithCredentialFailureInterface-class.md) -- SignInWithCredentialFailureFirebase - - - -**Implementers** - -- [SignInWithAppleFailureFirebase](../wyatt_authentication_bloc/SignInWithAppleFailureFirebase-class.md) -- [SignInWithFacebookFailureFirebase](../wyatt_authentication_bloc/SignInWithFacebookFailureFirebase-class.md) -- [SignInWithGoogleFailureFirebase](../wyatt_authentication_bloc/SignInWithGoogleFailureFirebase-class.md) -- [SignInWithTwitterFailureFirebase](../wyatt_authentication_bloc/SignInWithTwitterFailureFirebase-class.md) - - - - - -## Constructors - -[SignInWithCredentialFailureFirebase](../wyatt_authentication_bloc/SignInWithCredentialFailureFirebase/SignInWithCredentialFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - -[SignInWithCredentialFailureFirebase.fromCode](../wyatt_authentication_bloc/SignInWithCredentialFailureFirebase/SignInWithCredentialFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithCredentialFailureFirebase/SignInWithCredentialFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithCredentialFailureFirebase/SignInWithCredentialFailureFirebase.fromCode.md deleted file mode 100644 index d2b1deb1..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithCredentialFailureFirebase/SignInWithCredentialFailureFirebase.fromCode.md +++ /dev/null @@ -1,61 +0,0 @@ - - - -# SignInWithCredentialFailureFirebase.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SignInWithCredentialFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - - -## Implementation - -```dart -SignInWithCredentialFailureFirebase.fromCode(String code) - : super.fromCode(code) { - switch (code) { - case 'account-exists-with-different-credential': - msg = 'Account exists with different credentials.'; - break; - case 'invalid-credential': - msg = 'The credential received is malformed or has expired.'; - break; - case 'operation-not-allowed': - msg = 'Operation is not allowed. Please contact support.'; - break; - case 'user-disabled': - msg = 'This user has been disabled. Please contact support for help.'; - break; - case 'user-not-found': - msg = 'Email is not found, please create an account.'; - break; - case 'wrong-password': - msg = 'Incorrect password, please try again.'; - break; - case 'invalid-verification-code': - msg = 'The credential verification code received is invalid.'; - break; - case 'invalid-verification-id': - msg = 'The credential verification ID received is invalid.'; - break; - default: - this.code = 'unknown'; - msg = 'An unknown error occurred.'; - } -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithCredentialFailureFirebase/SignInWithCredentialFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithCredentialFailureFirebase/SignInWithCredentialFailureFirebase.md deleted file mode 100644 index 66f66bb9..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithCredentialFailureFirebase/SignInWithCredentialFailureFirebase.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# SignInWithCredentialFailureFirebase constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SignInWithCredentialFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - - - -## Implementation - -```dart -SignInWithCredentialFailureFirebase([String? code, String? msg]) - : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithCredentialFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithCredentialFailureInterface-class.md deleted file mode 100644 index 08473e12..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithCredentialFailureInterface-class.md +++ /dev/null @@ -1,139 +0,0 @@ - - - -# SignInWithCredentialFailureInterface class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown during the sign in process if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- SignInWithCredentialFailureInterface - - - -**Implementers** - -- [SignInWithCredentialFailureFirebase](../wyatt_authentication_bloc/SignInWithCredentialFailureFirebase-class.md) - - - - - -## Constructors - -[SignInWithCredentialFailureInterface](../wyatt_authentication_bloc/SignInWithCredentialFailureInterface/SignInWithCredentialFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - -Thrown during the sign in process if a failure occurs. - -[SignInWithCredentialFailureInterface.fromCode](../wyatt_authentication_bloc/SignInWithCredentialFailureInterface/SignInWithCredentialFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - -Thrown during the sign in process if a failure occurs. - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithCredentialFailureInterface/SignInWithCredentialFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithCredentialFailureInterface/SignInWithCredentialFailureInterface.fromCode.md deleted file mode 100644 index 14c794db..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithCredentialFailureInterface/SignInWithCredentialFailureInterface.fromCode.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# SignInWithCredentialFailureInterface.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SignInWithCredentialFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - -

Thrown during the sign in process if a failure occurs.

- - - -## Implementation - -```dart -SignInWithCredentialFailureInterface.fromCode(super.code) : super.fromCode(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithCredentialFailureInterface/SignInWithCredentialFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithCredentialFailureInterface/SignInWithCredentialFailureInterface.md deleted file mode 100644 index 4030c6cd..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithCredentialFailureInterface/SignInWithCredentialFailureInterface.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# SignInWithCredentialFailureInterface constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SignInWithCredentialFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - - -

Thrown during the sign in process if a failure occurs.

- - - -## Implementation - -```dart -SignInWithCredentialFailureInterface(super.code, super.msg); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureFirebase-class.md deleted file mode 100644 index 5a28b107..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureFirebase-class.md +++ /dev/null @@ -1,137 +0,0 @@ - - - -# SignInWithEmailAndPasswordFailureFirebase class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown during the sign in process if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- [SignInWithEmailAndPasswordFailureInterface](../wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureInterface-class.md) -- SignInWithEmailAndPasswordFailureFirebase - - - - - - - - -## Constructors - -[SignInWithEmailAndPasswordFailureFirebase](../wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureFirebase/SignInWithEmailAndPasswordFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - -[SignInWithEmailAndPasswordFailureFirebase.fromCode](../wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureFirebase/SignInWithEmailAndPasswordFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureFirebase/SignInWithEmailAndPasswordFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureFirebase/SignInWithEmailAndPasswordFailureFirebase.fromCode.md deleted file mode 100644 index 5b9663d4..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureFirebase/SignInWithEmailAndPasswordFailureFirebase.fromCode.md +++ /dev/null @@ -1,49 +0,0 @@ - - - -# SignInWithEmailAndPasswordFailureFirebase.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SignInWithEmailAndPasswordFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - - -## Implementation - -```dart -SignInWithEmailAndPasswordFailureFirebase.fromCode(String code) - : super.fromCode(code) { - switch (code) { - case 'invalid-email': - msg = 'Email is not valid or badly formatted.'; - break; - case 'user-disabled': - msg = 'This user has been disabled. Please contact support for help.'; - break; - case 'user-not-found': - msg = 'Email is not found, please create an account.'; - break; - case 'wrong-password': - msg = 'Incorrect password, please try again.'; - break; - default: - this.code = 'unknown'; - msg = 'An unknown error occurred.'; - } -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureFirebase/SignInWithEmailAndPasswordFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureFirebase/SignInWithEmailAndPasswordFailureFirebase.md deleted file mode 100644 index 42ec7079..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureFirebase/SignInWithEmailAndPasswordFailureFirebase.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# SignInWithEmailAndPasswordFailureFirebase constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SignInWithEmailAndPasswordFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - - - -## Implementation - -```dart -SignInWithEmailAndPasswordFailureFirebase([String? code, String? msg]) - : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureInterface-class.md deleted file mode 100644 index acdf3cf0..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureInterface-class.md +++ /dev/null @@ -1,139 +0,0 @@ - - - -# SignInWithEmailAndPasswordFailureInterface class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown during the sign in process if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- SignInWithEmailAndPasswordFailureInterface - - - -**Implementers** - -- [SignInWithEmailAndPasswordFailureFirebase](../wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureFirebase-class.md) - - - - - -## Constructors - -[SignInWithEmailAndPasswordFailureInterface](../wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureInterface/SignInWithEmailAndPasswordFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - -Thrown during the sign in process if a failure occurs. - -[SignInWithEmailAndPasswordFailureInterface.fromCode](../wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureInterface/SignInWithEmailAndPasswordFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - -Thrown during the sign in process if a failure occurs. - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureInterface/SignInWithEmailAndPasswordFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureInterface/SignInWithEmailAndPasswordFailureInterface.fromCode.md deleted file mode 100644 index 735df785..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureInterface/SignInWithEmailAndPasswordFailureInterface.fromCode.md +++ /dev/null @@ -1,32 +0,0 @@ - - - -# SignInWithEmailAndPasswordFailureInterface.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SignInWithEmailAndPasswordFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - -

Thrown during the sign in process if a failure occurs.

- - - -## Implementation - -```dart -SignInWithEmailAndPasswordFailureInterface.fromCode(super.code) - : super.fromCode(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureInterface/SignInWithEmailAndPasswordFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureInterface/SignInWithEmailAndPasswordFailureInterface.md deleted file mode 100644 index fff1afd8..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureInterface/SignInWithEmailAndPasswordFailureInterface.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# SignInWithEmailAndPasswordFailureInterface constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SignInWithEmailAndPasswordFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - - -

Thrown during the sign in process if a failure occurs.

- - - -## Implementation - -```dart -SignInWithEmailAndPasswordFailureInterface(super.code, super.msg); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailLinkFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailLinkFailureFirebase-class.md deleted file mode 100644 index e2360fe9..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailLinkFailureFirebase-class.md +++ /dev/null @@ -1,137 +0,0 @@ - - - -# SignInWithEmailLinkFailureFirebase class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown during the sign in process if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- [SignInWithEmailLinkFailureInterface](../wyatt_authentication_bloc/SignInWithEmailLinkFailureInterface-class.md) -- SignInWithEmailLinkFailureFirebase - - - - - - - - -## Constructors - -[SignInWithEmailLinkFailureFirebase](../wyatt_authentication_bloc/SignInWithEmailLinkFailureFirebase/SignInWithEmailLinkFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - -[SignInWithEmailLinkFailureFirebase.fromCode](../wyatt_authentication_bloc/SignInWithEmailLinkFailureFirebase/SignInWithEmailLinkFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailLinkFailureFirebase/SignInWithEmailLinkFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailLinkFailureFirebase/SignInWithEmailLinkFailureFirebase.fromCode.md deleted file mode 100644 index a8ccdec9..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailLinkFailureFirebase/SignInWithEmailLinkFailureFirebase.fromCode.md +++ /dev/null @@ -1,46 +0,0 @@ - - - -# SignInWithEmailLinkFailureFirebase.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SignInWithEmailLinkFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - - -## Implementation - -```dart -SignInWithEmailLinkFailureFirebase.fromCode(String code) - : super.fromCode(code) { - switch (code) { - case 'expired-action-code': - msg = 'Action code has expired.'; - break; - case 'invalid-email': - msg = 'Email is not valid or badly formatted.'; - break; - case 'user-disabled': - msg = 'This user has been disabled. Please contact support for help.'; - break; - default: - this.code = 'unknown'; - msg = 'An unknown error occurred.'; - } -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailLinkFailureFirebase/SignInWithEmailLinkFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailLinkFailureFirebase/SignInWithEmailLinkFailureFirebase.md deleted file mode 100644 index 456995ec..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailLinkFailureFirebase/SignInWithEmailLinkFailureFirebase.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# SignInWithEmailLinkFailureFirebase constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SignInWithEmailLinkFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - - - -## Implementation - -```dart -SignInWithEmailLinkFailureFirebase([String? code, String? msg]) - : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailLinkFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailLinkFailureInterface-class.md deleted file mode 100644 index e087037b..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailLinkFailureInterface-class.md +++ /dev/null @@ -1,139 +0,0 @@ - - - -# SignInWithEmailLinkFailureInterface class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown during the sign in process if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- SignInWithEmailLinkFailureInterface - - - -**Implementers** - -- [SignInWithEmailLinkFailureFirebase](../wyatt_authentication_bloc/SignInWithEmailLinkFailureFirebase-class.md) - - - - - -## Constructors - -[SignInWithEmailLinkFailureInterface](../wyatt_authentication_bloc/SignInWithEmailLinkFailureInterface/SignInWithEmailLinkFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - -Thrown during the sign in process if a failure occurs. - -[SignInWithEmailLinkFailureInterface.fromCode](../wyatt_authentication_bloc/SignInWithEmailLinkFailureInterface/SignInWithEmailLinkFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - -Thrown during the sign in process if a failure occurs. - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailLinkFailureInterface/SignInWithEmailLinkFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailLinkFailureInterface/SignInWithEmailLinkFailureInterface.fromCode.md deleted file mode 100644 index 3d4531a9..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailLinkFailureInterface/SignInWithEmailLinkFailureInterface.fromCode.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# SignInWithEmailLinkFailureInterface.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SignInWithEmailLinkFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - -

Thrown during the sign in process if a failure occurs.

- - - -## Implementation - -```dart -SignInWithEmailLinkFailureInterface.fromCode(super.code) : super.fromCode(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailLinkFailureInterface/SignInWithEmailLinkFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailLinkFailureInterface/SignInWithEmailLinkFailureInterface.md deleted file mode 100644 index 73f298cb..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailLinkFailureInterface/SignInWithEmailLinkFailureInterface.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# SignInWithEmailLinkFailureInterface constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SignInWithEmailLinkFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - - -

Thrown during the sign in process if a failure occurs.

- - - -## Implementation - -```dart -SignInWithEmailLinkFailureInterface(super.code, super.msg); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword-mixin.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword-mixin.md deleted file mode 100644 index 78cf1a73..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword-mixin.md +++ /dev/null @@ -1,305 +0,0 @@ - - - -# SignInWithEmailPassword<Data> mixin - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Sign in mixin.

-

Allows the user to sign in with email and password

-

Gives access to the signInWithEmailAndPassword method and -onSignInWithEmailAndPassword callback.

- - -**Superclass Constraints** - -- [BaseSignInCubit](../wyatt_authentication_bloc/BaseSignInCubit-class.md)<Data> - - - - -**Mixin Applications** - -- [SignInCubit](../wyatt_authentication_bloc/SignInCubit-class.md) - - - -## Properties - -##### [authenticationRepository](../wyatt_authentication_bloc/BaseSignInCubit/authenticationRepository.md) → [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> - - - - -_finalinherited_ - - - -##### [formName](../wyatt_authentication_bloc/BaseSignInCubit/formName.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [formRepository](../wyatt_authentication_bloc/BaseSignInCubit/formRepository.md) → FormRepository - - - - -_read-onlyinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [isClosed](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/isClosed.html) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -Whether the bloc is closed. -_read-onlyinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - -##### [state](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/state.html) → [SignInState](../wyatt_authentication_bloc/SignInState-class.md) - - - -The current state. -_read-onlyinherited_ - - - -##### [stream](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/stream.html) → [Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[SignInState](../wyatt_authentication_bloc/SignInState-class.md)> - - - -The current stream of states. -_read-onlyinherited_ - - - - - -## Methods - -##### [addError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/addError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [[StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html)? stackTrace]) void - - - -Reports an error which triggers onError with an optional StackTrace. -_inherited_ - - - -##### [close](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/close.html)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> - - - -Closes the instance. -This method should be called when the instance is no longer needed. -Once close is called, the instance can no longer be used. -_inherited_ - - - -##### [dataChanged](../wyatt_authentication_bloc/BaseSignInCubit/dataChanged.md)<Value>([String](https://api.flutter.dev/flutter/dart-core/String-class.html) key, FormInputValidator<Value, ValidationError> dirtyValue) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - -##### [emailChanged](../wyatt_authentication_bloc/SignInWithEmailPassword/emailChanged.md)([String](https://api.flutter.dev/flutter/dart-core/String-class.html) value) void - - - - - - - - -##### [emailCustomChanged](../wyatt_authentication_bloc/SignInWithEmailPassword/emailCustomChanged.md)<Validator extends FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError>>(Validator validator) void - - - -Same as emailChanged but with a custom Validator. - - - - -##### [emit](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/emit.html)([SignInState](../wyatt_authentication_bloc/SignInState-class.md) state) void - - - -Updates the state to the provided state. -emit does nothing if the state being emitted -is equal to the current state. -_inherited_ - - - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [onChange](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onChange.html)([Change](https://pub.dev/documentation/bloc/8.1.0/bloc/Change-class.html)<[SignInState](../wyatt_authentication_bloc/SignInState-class.md)> change) void - - - -Called whenever a change occurs with the given change. -A change occurs when a new state is emitted. -onChange is called before the state of the cubit is updated. -onChange is a great spot to add logging/analytics for a specific cubit. -_inherited_ - - - -##### [onError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html) stackTrace) void - - - -Called whenever an error occurs and notifies BlocObserver.onError. -_inherited_ - - - -##### [onSignInWithEmailAndPassword](../wyatt_authentication_bloc/SignInWithEmailPassword/onSignInWithEmailAndPassword.md)(Result<[Account](../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) FutureOrResult<Data?> - - - -This callback is triggered when a user signs in with email and password. - - - - -##### [passwordChanged](../wyatt_authentication_bloc/SignInWithEmailPassword/passwordChanged.md)([String](https://api.flutter.dev/flutter/dart-core/String-class.html) value) void - - - - - - - - -##### [passwordCustomChanged](../wyatt_authentication_bloc/SignInWithEmailPassword/passwordCustomChanged.md)<Validator extends FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError>>(Validator validator) void - - - -Same as passwordChanged but with a custom Validator. - - - - -##### [reset](../wyatt_authentication_bloc/BaseSignInCubit/reset.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - -##### [signInWithEmailAndPassword](../wyatt_authentication_bloc/SignInWithEmailPassword/signInWithEmailAndPassword.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - -Signs in with the provided email and password. - - - - -##### [submit](../wyatt_authentication_bloc/BaseSignInCubit/submit.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - -##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - -##### [update](../wyatt_authentication_bloc/BaseSignInCubit/update.md)(WyattForm form, {SetOperation operation = SetOperation.replace}) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - -##### [validate](../wyatt_authentication_bloc/BaseSignInCubit/validate.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword/emailChanged.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword/emailChanged.md deleted file mode 100644 index 85e7cc16..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword/emailChanged.md +++ /dev/null @@ -1,47 +0,0 @@ - - - -# emailChanged method - - - - - *[](https://dart.dev/null-safety)* - - - - -void emailChanged -([String](https://api.flutter.dev/flutter/dart-core/String-class.html) value) - - - - - - - - -## Implementation - -```dart -void emailChanged(String value) { - final emailValidatorType = formRepository - .accessForm(formName) - .validatorOf(AuthFormField.email) - .runtimeType; - assert( - emailValidatorType == Email, - 'Use emailCustomChanged(...) with validator $emailValidatorType', - ); - - final Email email = Email.dirty(value); - dataChanged(AuthFormField.email, email); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword/emailCustomChanged.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword/emailCustomChanged.md deleted file mode 100644 index fcb48b24..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword/emailCustomChanged.md +++ /dev/null @@ -1,42 +0,0 @@ - - - -# emailCustomChanged<Validator extends FormInputValidator<String?, ValidationError>> method - - - - - *[](https://dart.dev/null-safety)* - - - - -void emailCustomChanged -<Validator extends FormInputValidator<String?, ValidationError>>(Validator validator) - - - - - -

Same as emailChanged but with a custom Validator.

-

Sort of short hand for dataChanged.

- - - -## Implementation - -```dart -void emailCustomChanged< - Validator extends FormInputValidator>( - Validator validator, -) { - dataChanged(AuthFormField.email, validator); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword/onSignInWithEmailAndPassword.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword/onSignInWithEmailAndPassword.md deleted file mode 100644 index 0a35342a..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword/onSignInWithEmailAndPassword.md +++ /dev/null @@ -1,39 +0,0 @@ - - - -# onSignInWithEmailAndPassword method - - - - - *[](https://dart.dev/null-safety)* - - - - -FutureOrResult<Data?> onSignInWithEmailAndPassword -(Result<[Account](../../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) - - - - - -

This callback is triggered when a user signs in with email and password.

- - - -## Implementation - -```dart -FutureOrResult onSignInWithEmailAndPassword( - Result result, - WyattForm form, -); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword/passwordChanged.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword/passwordChanged.md deleted file mode 100644 index 8db9fda0..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword/passwordChanged.md +++ /dev/null @@ -1,46 +0,0 @@ - - - -# passwordChanged method - - - - - *[](https://dart.dev/null-safety)* - - - - -void passwordChanged -([String](https://api.flutter.dev/flutter/dart-core/String-class.html) value) - - - - - - - - -## Implementation - -```dart -void passwordChanged(String value) { - final passwordValidatorType = formRepository - .accessForm(formName) - .validatorOf(AuthFormField.password) - .runtimeType; - assert( - passwordValidatorType == Password, - 'Use passwordCustomChanged(...) with validator $passwordValidatorType', - ); - final Password password = Password.dirty(value); - dataChanged(AuthFormField.password, password); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword/passwordCustomChanged.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword/passwordCustomChanged.md deleted file mode 100644 index cca9b5ad..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword/passwordCustomChanged.md +++ /dev/null @@ -1,42 +0,0 @@ - - - -# passwordCustomChanged<Validator extends FormInputValidator<String?, ValidationError>> method - - - - - *[](https://dart.dev/null-safety)* - - - - -void passwordCustomChanged -<Validator extends FormInputValidator<String?, ValidationError>>(Validator validator) - - - - - -

Same as passwordChanged but with a custom Validator.

-

Sort of short hand for dataChanged.

- - - -## Implementation - -```dart -void passwordCustomChanged< - Validator extends FormInputValidator>( - Validator validator, -) { - dataChanged(AuthFormField.password, validator); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword/signInWithEmailAndPassword.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword/signInWithEmailAndPassword.md deleted file mode 100644 index 808606f8..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithEmailPassword/signInWithEmailAndPassword.md +++ /dev/null @@ -1,105 +0,0 @@ - - - -# signInWithEmailAndPassword method - - - - - *[](https://dart.dev/null-safety)* - - - - -[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> signInWithEmailAndPassword -() - - - - - -

Signs in with the provided email and password.

-

Throws a SignInWithEmailAndPasswordFailureInterface if -an exception occurs.

- - - -## Implementation - -```dart -FutureOr signInWithEmailAndPassword() async { - if (state.status.isSubmissionInProgress) { - return; - } - - if (!state.status.isValidated) { - return; - } - - final form = formRepository.accessForm(formName); - emit( - SignInState( - form: form, - status: FormStatus.submissionInProgress, - ), - ); - - final email = form.valueOf(AuthFormField.email); - final password = form.valueOf(AuthFormField.password); - - if (email.isNullOrEmpty || password.isNullOrEmpty) { - emit( - SignInState( - form: form, - errorMessage: 'An error occured while retrieving data from the form.', - status: FormStatus.submissionFailure, - ), - ); - } - - return CustomRoutine( - routine: () => authenticationRepository.signInWithEmailAndPassword( - email: email!, - password: password!, - ), - attachedLogic: (routineResult) => onSignInWithEmailAndPassword( - routineResult, - form, - ), - onError: (error) { - emit( - SignInState( - form: form, - errorMessage: error.message, - status: FormStatus.submissionFailure, - ), - ); - addError(error); - }, - onSuccess: (account, data) { - authenticationRepository.addSession( - SessionWrapper( - event: SignedInEvent(account: account), - session: Session( - account: account, - data: data, - ), - ), - ); - emit( - SignInState( - form: form, - status: FormStatus.submissionSuccess, - ), - ); - }, - ).call(); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithFacebookFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithFacebookFailureFirebase-class.md deleted file mode 100644 index f1e15f55..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithFacebookFailureFirebase-class.md +++ /dev/null @@ -1,141 +0,0 @@ - - - -# SignInWithFacebookFailureFirebase class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown during the sign in process if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- [SignInWithCredentialFailureInterface](../wyatt_authentication_bloc/SignInWithCredentialFailureInterface-class.md) -- [SignInWithCredentialFailureFirebase](../wyatt_authentication_bloc/SignInWithCredentialFailureFirebase-class.md) -- SignInWithFacebookFailureFirebase - -**Implemented types** - -- [SignInWithFacebookFailureInterface](../wyatt_authentication_bloc/SignInWithFacebookFailureInterface-class.md) - - - - - - - -## Constructors - -[SignInWithFacebookFailureFirebase](../wyatt_authentication_bloc/SignInWithFacebookFailureFirebase/SignInWithFacebookFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - -[SignInWithFacebookFailureFirebase.fromCode](../wyatt_authentication_bloc/SignInWithFacebookFailureFirebase/SignInWithFacebookFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithFacebookFailureFirebase/SignInWithFacebookFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithFacebookFailureFirebase/SignInWithFacebookFailureFirebase.fromCode.md deleted file mode 100644 index 10c11c0b..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithFacebookFailureFirebase/SignInWithFacebookFailureFirebase.fromCode.md +++ /dev/null @@ -1,30 +0,0 @@ - - - -# SignInWithFacebookFailureFirebase.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SignInWithFacebookFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - - -## Implementation - -```dart -SignInWithFacebookFailureFirebase.fromCode(super.code) : super.fromCode(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithFacebookFailureFirebase/SignInWithFacebookFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithFacebookFailureFirebase/SignInWithFacebookFailureFirebase.md deleted file mode 100644 index df7ed863..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithFacebookFailureFirebase/SignInWithFacebookFailureFirebase.md +++ /dev/null @@ -1,30 +0,0 @@ - - - -# SignInWithFacebookFailureFirebase constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SignInWithFacebookFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - - - -## Implementation - -```dart -SignInWithFacebookFailureFirebase([super.code, super.msg]); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithFacebookFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithFacebookFailureInterface-class.md deleted file mode 100644 index c0ad332f..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithFacebookFailureInterface-class.md +++ /dev/null @@ -1,139 +0,0 @@ - - - -# SignInWithFacebookFailureInterface class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown during the sign in process if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- SignInWithFacebookFailureInterface - - - -**Implementers** - -- [SignInWithFacebookFailureFirebase](../wyatt_authentication_bloc/SignInWithFacebookFailureFirebase-class.md) - - - - - -## Constructors - -[SignInWithFacebookFailureInterface](../wyatt_authentication_bloc/SignInWithFacebookFailureInterface/SignInWithFacebookFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - -Thrown during the sign in process if a failure occurs. - -[SignInWithFacebookFailureInterface.fromCode](../wyatt_authentication_bloc/SignInWithFacebookFailureInterface/SignInWithFacebookFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - -Thrown during the sign in process if a failure occurs. - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithFacebookFailureInterface/SignInWithFacebookFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithFacebookFailureInterface/SignInWithFacebookFailureInterface.fromCode.md deleted file mode 100644 index 539c8a5a..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithFacebookFailureInterface/SignInWithFacebookFailureInterface.fromCode.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# SignInWithFacebookFailureInterface.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SignInWithFacebookFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - -

Thrown during the sign in process if a failure occurs.

- - - -## Implementation - -```dart -SignInWithFacebookFailureInterface.fromCode(super.code) : super.fromCode(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithFacebookFailureInterface/SignInWithFacebookFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithFacebookFailureInterface/SignInWithFacebookFailureInterface.md deleted file mode 100644 index abace647..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithFacebookFailureInterface/SignInWithFacebookFailureInterface.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# SignInWithFacebookFailureInterface constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SignInWithFacebookFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - - -

Thrown during the sign in process if a failure occurs.

- - - -## Implementation - -```dart -SignInWithFacebookFailureInterface(super.code, super.msg); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogle-mixin.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogle-mixin.md deleted file mode 100644 index ff62c2b5..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogle-mixin.md +++ /dev/null @@ -1,269 +0,0 @@ - - - -# SignInWithGoogle<Data> mixin - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Sign in mixin.

-

Allows the user to sign in with google

-

Gives access to the signInWithGoogle method and -onSignInWithGoogle callback.

- - -**Superclass Constraints** - -- [BaseSignInCubit](../wyatt_authentication_bloc/BaseSignInCubit-class.md)<Data> - - - - -**Mixin Applications** - -- [SignInCubit](../wyatt_authentication_bloc/SignInCubit-class.md) - - - -## Properties - -##### [authenticationRepository](../wyatt_authentication_bloc/BaseSignInCubit/authenticationRepository.md) → [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> - - - - -_finalinherited_ - - - -##### [formName](../wyatt_authentication_bloc/BaseSignInCubit/formName.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [formRepository](../wyatt_authentication_bloc/BaseSignInCubit/formRepository.md) → FormRepository - - - - -_read-onlyinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [isClosed](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/isClosed.html) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -Whether the bloc is closed. -_read-onlyinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - -##### [state](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/state.html) → [SignInState](../wyatt_authentication_bloc/SignInState-class.md) - - - -The current state. -_read-onlyinherited_ - - - -##### [stream](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/stream.html) → [Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[SignInState](../wyatt_authentication_bloc/SignInState-class.md)> - - - -The current stream of states. -_read-onlyinherited_ - - - - - -## Methods - -##### [addError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/addError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [[StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html)? stackTrace]) void - - - -Reports an error which triggers onError with an optional StackTrace. -_inherited_ - - - -##### [close](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/close.html)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> - - - -Closes the instance. -This method should be called when the instance is no longer needed. -Once close is called, the instance can no longer be used. -_inherited_ - - - -##### [dataChanged](../wyatt_authentication_bloc/BaseSignInCubit/dataChanged.md)<Value>([String](https://api.flutter.dev/flutter/dart-core/String-class.html) key, FormInputValidator<Value, ValidationError> dirtyValue) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - -##### [emit](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/emit.html)([SignInState](../wyatt_authentication_bloc/SignInState-class.md) state) void - - - -Updates the state to the provided state. -emit does nothing if the state being emitted -is equal to the current state. -_inherited_ - - - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [onChange](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onChange.html)([Change](https://pub.dev/documentation/bloc/8.1.0/bloc/Change-class.html)<[SignInState](../wyatt_authentication_bloc/SignInState-class.md)> change) void - - - -Called whenever a change occurs with the given change. -A change occurs when a new state is emitted. -onChange is called before the state of the cubit is updated. -onChange is a great spot to add logging/analytics for a specific cubit. -_inherited_ - - - -##### [onError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html) stackTrace) void - - - -Called whenever an error occurs and notifies BlocObserver.onError. -_inherited_ - - - -##### [onSignInWithGoogle](../wyatt_authentication_bloc/SignInWithGoogle/onSignInWithGoogle.md)(Result<[Account](../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) FutureOrResult<Data?> - - - -This callback is triggered when a user signs in with google. - - - - -##### [reset](../wyatt_authentication_bloc/BaseSignInCubit/reset.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - -##### [signInWithGoogle](../wyatt_authentication_bloc/SignInWithGoogle/signInWithGoogle.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - -Starts the Sign In with Google Flow. - - - - -##### [submit](../wyatt_authentication_bloc/BaseSignInCubit/submit.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - -##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - -##### [update](../wyatt_authentication_bloc/BaseSignInCubit/update.md)(WyattForm form, {SetOperation operation = SetOperation.replace}) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - -##### [validate](../wyatt_authentication_bloc/BaseSignInCubit/validate.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogle/onSignInWithGoogle.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogle/onSignInWithGoogle.md deleted file mode 100644 index 2f91ea65..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogle/onSignInWithGoogle.md +++ /dev/null @@ -1,39 +0,0 @@ - - - -# onSignInWithGoogle method - - - - - *[](https://dart.dev/null-safety)* - - - - -FutureOrResult<Data?> onSignInWithGoogle -(Result<[Account](../../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) - - - - - -

This callback is triggered when a user signs in with google.

- - - -## Implementation - -```dart -FutureOrResult onSignInWithGoogle( - Result result, - WyattForm form, -); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogle/signInWithGoogle.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogle/signInWithGoogle.md deleted file mode 100644 index 5f6d2741..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogle/signInWithGoogle.md +++ /dev/null @@ -1,78 +0,0 @@ - - - -# signInWithGoogle method - - - - - *[](https://dart.dev/null-safety)* - - - - -[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> signInWithGoogle -() - - - - - -

Starts the Sign In with Google Flow.

-

Throws a SignInWithGoogleFailureInterface if an exception occurs.

- - - -## Implementation - -```dart -FutureOr signInWithGoogle() async { - if (state.status.isSubmissionInProgress) { - return; - } - final form = formRepository.accessForm(formName); - emit(SignInState(form: form, status: FormStatus.submissionInProgress)); - - return CustomRoutine( - routine: authenticationRepository.signInWithGoogle, - attachedLogic: (routineResult) => onSignInWithGoogle( - routineResult, - form, - ), - onError: (error) { - emit( - SignInState( - form: form, - errorMessage: error.message, - status: FormStatus.submissionFailure, - ), - ); - addError(error); - }, - onSuccess: (account, data) { - authenticationRepository.addSession( - SessionWrapper( - event: SignedInEvent(account: account), - session: Session( - account: account, - data: data, - ), - ), - ); - emit( - SignInState( - form: form, - status: FormStatus.submissionSuccess, - ), - ); - }, - ).call(); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogleFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogleFailureFirebase-class.md deleted file mode 100644 index 91cf6845..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogleFailureFirebase-class.md +++ /dev/null @@ -1,141 +0,0 @@ - - - -# SignInWithGoogleFailureFirebase class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown during the sign in process if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- [SignInWithCredentialFailureInterface](../wyatt_authentication_bloc/SignInWithCredentialFailureInterface-class.md) -- [SignInWithCredentialFailureFirebase](../wyatt_authentication_bloc/SignInWithCredentialFailureFirebase-class.md) -- SignInWithGoogleFailureFirebase - -**Implemented types** - -- [SignInWithGoogleFailureInterface](../wyatt_authentication_bloc/SignInWithGoogleFailureInterface-class.md) - - - - - - - -## Constructors - -[SignInWithGoogleFailureFirebase](../wyatt_authentication_bloc/SignInWithGoogleFailureFirebase/SignInWithGoogleFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - -[SignInWithGoogleFailureFirebase.fromCode](../wyatt_authentication_bloc/SignInWithGoogleFailureFirebase/SignInWithGoogleFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogleFailureFirebase/SignInWithGoogleFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogleFailureFirebase/SignInWithGoogleFailureFirebase.fromCode.md deleted file mode 100644 index c189a40e..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogleFailureFirebase/SignInWithGoogleFailureFirebase.fromCode.md +++ /dev/null @@ -1,30 +0,0 @@ - - - -# SignInWithGoogleFailureFirebase.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SignInWithGoogleFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - - -## Implementation - -```dart -SignInWithGoogleFailureFirebase.fromCode(super.code) : super.fromCode(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogleFailureFirebase/SignInWithGoogleFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogleFailureFirebase/SignInWithGoogleFailureFirebase.md deleted file mode 100644 index 2a67c09d..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogleFailureFirebase/SignInWithGoogleFailureFirebase.md +++ /dev/null @@ -1,30 +0,0 @@ - - - -# SignInWithGoogleFailureFirebase constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SignInWithGoogleFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - - - -## Implementation - -```dart -SignInWithGoogleFailureFirebase([super.code, super.msg]); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogleFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogleFailureInterface-class.md deleted file mode 100644 index 0712ff53..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogleFailureInterface-class.md +++ /dev/null @@ -1,139 +0,0 @@ - - - -# SignInWithGoogleFailureInterface class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown during the sign in process if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- SignInWithGoogleFailureInterface - - - -**Implementers** - -- [SignInWithGoogleFailureFirebase](../wyatt_authentication_bloc/SignInWithGoogleFailureFirebase-class.md) - - - - - -## Constructors - -[SignInWithGoogleFailureInterface](../wyatt_authentication_bloc/SignInWithGoogleFailureInterface/SignInWithGoogleFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - -Thrown during the sign in process if a failure occurs. - -[SignInWithGoogleFailureInterface.fromCode](../wyatt_authentication_bloc/SignInWithGoogleFailureInterface/SignInWithGoogleFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - -Thrown during the sign in process if a failure occurs. - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogleFailureInterface/SignInWithGoogleFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogleFailureInterface/SignInWithGoogleFailureInterface.fromCode.md deleted file mode 100644 index 16441dda..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogleFailureInterface/SignInWithGoogleFailureInterface.fromCode.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# SignInWithGoogleFailureInterface.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SignInWithGoogleFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - -

Thrown during the sign in process if a failure occurs.

- - - -## Implementation - -```dart -SignInWithGoogleFailureInterface.fromCode(super.code) : super.fromCode(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogleFailureInterface/SignInWithGoogleFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogleFailureInterface/SignInWithGoogleFailureInterface.md deleted file mode 100644 index 9337f2db..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithGoogleFailureInterface/SignInWithGoogleFailureInterface.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# SignInWithGoogleFailureInterface constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SignInWithGoogleFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - - -

Thrown during the sign in process if a failure occurs.

- - - -## Implementation - -```dart -SignInWithGoogleFailureInterface(super.code, super.msg); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithTwitterFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithTwitterFailureFirebase-class.md deleted file mode 100644 index 5aeb8957..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithTwitterFailureFirebase-class.md +++ /dev/null @@ -1,141 +0,0 @@ - - - -# SignInWithTwitterFailureFirebase class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown during the sign in process if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- [SignInWithCredentialFailureInterface](../wyatt_authentication_bloc/SignInWithCredentialFailureInterface-class.md) -- [SignInWithCredentialFailureFirebase](../wyatt_authentication_bloc/SignInWithCredentialFailureFirebase-class.md) -- SignInWithTwitterFailureFirebase - -**Implemented types** - -- [SignInWithAppleFailureInterface](../wyatt_authentication_bloc/SignInWithAppleFailureInterface-class.md) - - - - - - - -## Constructors - -[SignInWithTwitterFailureFirebase](../wyatt_authentication_bloc/SignInWithTwitterFailureFirebase/SignInWithTwitterFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - -[SignInWithTwitterFailureFirebase.fromCode](../wyatt_authentication_bloc/SignInWithTwitterFailureFirebase/SignInWithTwitterFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithTwitterFailureFirebase/SignInWithTwitterFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithTwitterFailureFirebase/SignInWithTwitterFailureFirebase.fromCode.md deleted file mode 100644 index ce958339..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithTwitterFailureFirebase/SignInWithTwitterFailureFirebase.fromCode.md +++ /dev/null @@ -1,30 +0,0 @@ - - - -# SignInWithTwitterFailureFirebase.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SignInWithTwitterFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - - -## Implementation - -```dart -SignInWithTwitterFailureFirebase.fromCode(super.code) : super.fromCode(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithTwitterFailureFirebase/SignInWithTwitterFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithTwitterFailureFirebase/SignInWithTwitterFailureFirebase.md deleted file mode 100644 index 8d824501..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithTwitterFailureFirebase/SignInWithTwitterFailureFirebase.md +++ /dev/null @@ -1,30 +0,0 @@ - - - -# SignInWithTwitterFailureFirebase constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SignInWithTwitterFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - - - -## Implementation - -```dart -SignInWithTwitterFailureFirebase([super.code, super.msg]); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithTwitterFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithTwitterFailureInterface-class.md deleted file mode 100644 index 3fbd2788..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithTwitterFailureInterface-class.md +++ /dev/null @@ -1,136 +0,0 @@ - - - -# SignInWithTwitterFailureInterface class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown during the sign in process if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- SignInWithTwitterFailureInterface - - - - - - - - -## Constructors - -[SignInWithTwitterFailureInterface](../wyatt_authentication_bloc/SignInWithTwitterFailureInterface/SignInWithTwitterFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - -Thrown during the sign in process if a failure occurs. - -[SignInWithTwitterFailureInterface.fromCode](../wyatt_authentication_bloc/SignInWithTwitterFailureInterface/SignInWithTwitterFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - -Thrown during the sign in process if a failure occurs. - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithTwitterFailureInterface/SignInWithTwitterFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithTwitterFailureInterface/SignInWithTwitterFailureInterface.fromCode.md deleted file mode 100644 index 9d541237..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithTwitterFailureInterface/SignInWithTwitterFailureInterface.fromCode.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# SignInWithTwitterFailureInterface.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SignInWithTwitterFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - -

Thrown during the sign in process if a failure occurs.

- - - -## Implementation - -```dart -SignInWithTwitterFailureInterface.fromCode(super.code) : super.fromCode(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithTwitterFailureInterface/SignInWithTwitterFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithTwitterFailureInterface/SignInWithTwitterFailureInterface.md deleted file mode 100644 index 14919bef..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignInWithTwitterFailureInterface/SignInWithTwitterFailureInterface.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# SignInWithTwitterFailureInterface constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SignInWithTwitterFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - - -

Thrown during the sign in process if a failure occurs.

- - - -## Implementation - -```dart -SignInWithTwitterFailureInterface(super.code, super.msg); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignOutFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignOutFailureFirebase-class.md deleted file mode 100644 index 3421331f..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignOutFailureFirebase-class.md +++ /dev/null @@ -1,137 +0,0 @@ - - - -# SignOutFailureFirebase class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown during the sign out process if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- [SignOutFailureInterface](../wyatt_authentication_bloc/SignOutFailureInterface-class.md) -- SignOutFailureFirebase - - - - - - - - -## Constructors - -[SignOutFailureFirebase](../wyatt_authentication_bloc/SignOutFailureFirebase/SignOutFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - -[SignOutFailureFirebase.fromCode](../wyatt_authentication_bloc/SignOutFailureFirebase/SignOutFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignOutFailureFirebase/SignOutFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignOutFailureFirebase/SignOutFailureFirebase.fromCode.md deleted file mode 100644 index 6cf59631..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignOutFailureFirebase/SignOutFailureFirebase.fromCode.md +++ /dev/null @@ -1,30 +0,0 @@ - - - -# SignOutFailureFirebase.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SignOutFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - - -## Implementation - -```dart -SignOutFailureFirebase.fromCode(super.code) : super.fromCode(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignOutFailureFirebase/SignOutFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignOutFailureFirebase/SignOutFailureFirebase.md deleted file mode 100644 index c6fc7d7a..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignOutFailureFirebase/SignOutFailureFirebase.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# SignOutFailureFirebase constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SignOutFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - - - -## Implementation - -```dart -SignOutFailureFirebase([String? code, String? msg]) - : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignOutFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignOutFailureInterface-class.md deleted file mode 100644 index cf527a70..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignOutFailureInterface-class.md +++ /dev/null @@ -1,139 +0,0 @@ - - - -# SignOutFailureInterface class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown during the sign out process if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- SignOutFailureInterface - - - -**Implementers** - -- [SignOutFailureFirebase](../wyatt_authentication_bloc/SignOutFailureFirebase-class.md) - - - - - -## Constructors - -[SignOutFailureInterface](../wyatt_authentication_bloc/SignOutFailureInterface/SignOutFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - -Thrown during the sign out process if a failure occurs. - -[SignOutFailureInterface.fromCode](../wyatt_authentication_bloc/SignOutFailureInterface/SignOutFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - -Thrown during the sign out process if a failure occurs. - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignOutFailureInterface/SignOutFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignOutFailureInterface/SignOutFailureInterface.fromCode.md deleted file mode 100644 index bde9935f..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignOutFailureInterface/SignOutFailureInterface.fromCode.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# SignOutFailureInterface.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SignOutFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - -

Thrown during the sign out process if a failure occurs.

- - - -## Implementation - -```dart -SignOutFailureInterface.fromCode(super.code) : super.fromCode(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignOutFailureInterface/SignOutFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignOutFailureInterface/SignOutFailureInterface.md deleted file mode 100644 index a59596a0..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignOutFailureInterface/SignOutFailureInterface.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# SignOutFailureInterface constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SignOutFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - - -

Thrown during the sign out process if a failure occurs.

- - - -## Implementation - -```dart -SignOutFailureInterface(super.code, super.msg); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpCubit-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpCubit-class.md deleted file mode 100644 index b8229ff4..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpCubit-class.md +++ /dev/null @@ -1,316 +0,0 @@ - - - -# SignUpCubit<Data> class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Fully featured sign up cubit.

-

Sufficient in most cases. (Where fine granularity is not required.)

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [BlocBase](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase-class.html)<[SignUpState](../wyatt_authentication_bloc/SignUpState-class.md)> -- [Cubit](https://pub.dev/documentation/bloc/8.1.0/bloc/Cubit-class.html)<[SignUpState](../wyatt_authentication_bloc/SignUpState-class.md)> -- [BaseSignUpCubit](../wyatt_authentication_bloc/BaseSignUpCubit-class.md)<Data> -- SignUpCubit - - -**Mixed in types** - -- [SignUpWithEmailPassword](../wyatt_authentication_bloc/SignUpWithEmailPassword-mixin.md)<Data> - - - - - - -## Constructors - -[SignUpCubit](../wyatt_authentication_bloc/SignUpCubit/SignUpCubit.md) ({required [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> authenticationRepository}) - - - - -## Properties - -##### [authenticationRepository](../wyatt_authentication_bloc/BaseSignUpCubit/authenticationRepository.md) → [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> - - - - -_finalinherited_ - - - -##### [formName](../wyatt_authentication_bloc/BaseSignUpCubit/formName.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [formRepository](../wyatt_authentication_bloc/BaseSignUpCubit/formRepository.md) → FormRepository - - - - -_read-onlyinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [isClosed](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/isClosed.html) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -Whether the bloc is closed. -_read-onlyinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - -##### [state](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/state.html) → [SignUpState](../wyatt_authentication_bloc/SignUpState-class.md) - - - -The current state. -_read-onlyinherited_ - - - -##### [stream](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/stream.html) → [Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[SignUpState](../wyatt_authentication_bloc/SignUpState-class.md)> - - - -The current stream of states. -_read-onlyinherited_ - - - - - -## Methods - -##### [addError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/addError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [[StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html)? stackTrace]) void - - - -Reports an error which triggers onError with an optional StackTrace. -_inherited_ - - - -##### [close](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/close.html)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> - - - -Closes the instance. -This method should be called when the instance is no longer needed. -Once close is called, the instance can no longer be used. -_inherited_ - - - -##### [dataChanged](../wyatt_authentication_bloc/BaseSignUpCubit/dataChanged.md)<Value>([String](https://api.flutter.dev/flutter/dart-core/String-class.html) key, FormInputValidator<Value, ValidationError> dirtyValue) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - -##### [emailChanged](../wyatt_authentication_bloc/SignUpWithEmailPassword/emailChanged.md)([String](https://api.flutter.dev/flutter/dart-core/String-class.html) value) void - - - - -_inherited_ - - - -##### [emailCustomChanged](../wyatt_authentication_bloc/SignUpWithEmailPassword/emailCustomChanged.md)<Validator extends FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError>>(Validator validator) void - - - -Same as emailChanged but with a custom Validator. -_inherited_ - - - -##### [emit](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/emit.html)([SignUpState](../wyatt_authentication_bloc/SignUpState-class.md) state) void - - - -Updates the state to the provided state. -emit does nothing if the state being emitted -is equal to the current state. -_inherited_ - - - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [onChange](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onChange.html)([Change](https://pub.dev/documentation/bloc/8.1.0/bloc/Change-class.html)<[SignUpState](../wyatt_authentication_bloc/SignUpState-class.md)> change) void - - - -Called whenever a change occurs with the given change. -A change occurs when a new state is emitted. -onChange is called before the state of the cubit is updated. -onChange is a great spot to add logging/analytics for a specific cubit. -_inherited_ - - - -##### [onError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html) stackTrace) void - - - -Called whenever an error occurs and notifies BlocObserver.onError. -_inherited_ - - - -##### [onSignUpWithEmailAndPassword](../wyatt_authentication_bloc/SignUpCubit/onSignUpWithEmailAndPassword.md)(Result<[Account](../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) FutureOrResult<Data?> - - - -This callback is triggered when a user creates an account. -_override_ - - - -##### [passwordChanged](../wyatt_authentication_bloc/SignUpWithEmailPassword/passwordChanged.md)([String](https://api.flutter.dev/flutter/dart-core/String-class.html) value) void - - - - -_inherited_ - - - -##### [passwordCustomChanged](../wyatt_authentication_bloc/SignUpWithEmailPassword/passwordCustomChanged.md)<Validator extends FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError>>(Validator validator) void - - - -Same as passwordChanged but with a custom Validator. -_inherited_ - - - -##### [reset](../wyatt_authentication_bloc/BaseSignUpCubit/reset.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - -##### [signUpWithEmailPassword](../wyatt_authentication_bloc/SignUpWithEmailPassword/signUpWithEmailPassword.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - -Creates a new user with the provided email and password. -_inherited_ - - - -##### [submit](../wyatt_authentication_bloc/BaseSignUpCubit/submit.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - -##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - -##### [update](../wyatt_authentication_bloc/BaseSignUpCubit/update.md)(WyattForm form, {SetOperation operation = SetOperation.replace}) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - -##### [validate](../wyatt_authentication_bloc/BaseSignUpCubit/validate.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpCubit/SignUpCubit.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpCubit/SignUpCubit.md deleted file mode 100644 index 0306f024..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpCubit/SignUpCubit.md +++ /dev/null @@ -1,30 +0,0 @@ - - - -# SignUpCubit<Data> constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SignUpCubit<Data>({required [AuthenticationRepository](../../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> authenticationRepository}) - - - - - -## Implementation - -```dart -SignUpCubit({required super.authenticationRepository}); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpCubit/onSignUpWithEmailAndPassword.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpCubit/onSignUpWithEmailAndPassword.md deleted file mode 100644 index e70dfa91..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpCubit/onSignUpWithEmailAndPassword.md +++ /dev/null @@ -1,43 +0,0 @@ - - - -# onSignUpWithEmailAndPassword method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -FutureOrResult<Data?> onSignUpWithEmailAndPassword -(Result<[Account](../../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) - -_override_ - - - -

This callback is triggered when a user creates an account.

-

For example: when a user sign up in firebase.

- - - -## Implementation - -```dart -@override -FutureOrResult onSignUpWithEmailAndPassword( - Result result, - WyattForm form, -) => - const Ok(null); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener-class.md deleted file mode 100644 index ea1477a1..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener-class.md +++ /dev/null @@ -1,236 +0,0 @@ - - - -# SignUpListener<Data> class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Widget that listens and builds a child based on the state of -the sign up cubit

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [DiagnosticableTree](https://api.flutter.dev/flutter/foundation/DiagnosticableTree-class.html) -- [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) -- [StatelessWidget](https://api.flutter.dev/flutter/widgets/StatelessWidget-class.html) -- SignUpListener - - - - - - - - -## Constructors - -[SignUpListener](../wyatt_authentication_bloc/SignUpListener/SignUpListener.md) ({required [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) child, void onProgress([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?, void onSuccess([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?, void onError([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, FormStatus status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage)?, void customBuilder([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, [SignUpState](../wyatt_authentication_bloc/SignUpState-class.md) state)?, [Key](https://api.flutter.dev/flutter/foundation/Key-class.html)? key}) - - _const_ - - -## Properties - -##### [child](../wyatt_authentication_bloc/SignUpListener/child.md) → [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) - - - - -_final_ - - - -##### [customBuilder](../wyatt_authentication_bloc/SignUpListener/customBuilder.md) → (void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, [SignUpState](../wyatt_authentication_bloc/SignUpState-class.md) state)?) - - - - -_final_ - - - -##### [hashCode](https://api.flutter.dev/flutter/widgets/Widget/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [key](https://api.flutter.dev/flutter/widgets/Widget/key.html) → [Key](https://api.flutter.dev/flutter/foundation/Key-class.html)? - - - -Controls how one widget replaces another widget in the tree. -_finalinherited_ - - - -##### [onError](../wyatt_authentication_bloc/SignUpListener/onError.md) → (void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, FormStatus status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage)?) - - - - -_final_ - - - -##### [onProgress](../wyatt_authentication_bloc/SignUpListener/onProgress.md) → (void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?) - - - - -_final_ - - - -##### [onSuccess](../wyatt_authentication_bloc/SignUpListener/onSuccess.md) → (void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?) - - - - -_final_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [build](../wyatt_authentication_bloc/SignUpListener/build.md)([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context) [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) - - - -Describes the part of the user interface represented by this widget. -_override_ - - - -##### [createElement](https://api.flutter.dev/flutter/widgets/StatelessWidget/createElement.html)() [StatelessElement](https://api.flutter.dev/flutter/widgets/StatelessElement-class.html) - - - -Creates a StatelessElement to manage this widget's location in the tree. -_inherited_ - - - -##### [debugDescribeChildren](https://api.flutter.dev/flutter/foundation/DiagnosticableTree/debugDescribeChildren.html)() [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[DiagnosticsNode](https://api.flutter.dev/flutter/foundation/DiagnosticsNode-class.html)> - - - -Returns a list of DiagnosticsNode objects describing this node's -children. -_inherited_ - - - -##### [debugFillProperties](https://api.flutter.dev/flutter/widgets/Widget/debugFillProperties.html)([DiagnosticPropertiesBuilder](https://api.flutter.dev/flutter/foundation/DiagnosticPropertiesBuilder-class.html) properties) void - - - -Add additional properties associated with the node. -_inherited_ - - - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toDiagnosticsNode](https://api.flutter.dev/flutter/foundation/DiagnosticableTree/toDiagnosticsNode.html)({[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? name, [DiagnosticsTreeStyle](https://api.flutter.dev/flutter/foundation/DiagnosticsTreeStyle.html)? style}) [DiagnosticsNode](https://api.flutter.dev/flutter/foundation/DiagnosticsNode-class.html) - - - -Returns a debug representation of the object that is used by debugging -tools and by DiagnosticsNode.toStringDeep. -_inherited_ - - - -##### [toString](https://api.flutter.dev/flutter/foundation/Diagnosticable/toString.html)({[DiagnosticLevel](https://api.flutter.dev/flutter/foundation/DiagnosticLevel.html) minLevel = DiagnosticLevel.info}) [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - -##### [toStringDeep](https://api.flutter.dev/flutter/foundation/DiagnosticableTree/toStringDeep.html)({[String](https://api.flutter.dev/flutter/dart-core/String-class.html) prefixLineOne = '', [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? prefixOtherLines, [DiagnosticLevel](https://api.flutter.dev/flutter/foundation/DiagnosticLevel.html) minLevel = DiagnosticLevel.debug}) [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -Returns a string representation of this node and its descendants. -_inherited_ - - - -##### [toStringShallow](https://api.flutter.dev/flutter/foundation/DiagnosticableTree/toStringShallow.html)({[String](https://api.flutter.dev/flutter/dart-core/String-class.html) joiner = ', ', [DiagnosticLevel](https://api.flutter.dev/flutter/foundation/DiagnosticLevel.html) minLevel = DiagnosticLevel.debug}) [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -Returns a one-line detailed description of the object. -_inherited_ - - - -##### [toStringShort](https://api.flutter.dev/flutter/widgets/Widget/toStringShort.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A short, textual description of this widget. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/widgets/Widget/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/SignUpListener.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/SignUpListener.md deleted file mode 100644 index 8eb3409d..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/SignUpListener.md +++ /dev/null @@ -1,37 +0,0 @@ - - - -# SignUpListener<Data> constructor - - - - - *[](https://dart.dev/null-safety)* - - -const -SignUpListener<Data>({required [Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) child, void onProgress([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?, void onSuccess([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?, void onError([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, FormStatus status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage)?, void customBuilder([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, [SignUpState](../../wyatt_authentication_bloc/SignUpState-class.md) state)?, [Key](https://api.flutter.dev/flutter/foundation/Key-class.html)? key}) - - - - - -## Implementation - -```dart -const SignUpListener({ - required this.child, - this.onProgress, - this.onSuccess, - this.onError, - this.customBuilder, - super.key, -}); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/build.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/build.md deleted file mode 100644 index 8843765f..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/build.md +++ /dev/null @@ -1,92 +0,0 @@ - - - -# build method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) build -([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context) - -_override_ - - - -

Describes the part of the user interface represented by this widget.

-

The framework calls this method when this widget is inserted into the tree -in a given BuildContext and when the dependencies of this widget change -(e.g., an InheritedWidget referenced by this widget changes). This -method can potentially be called in every frame and should not have any side -effects beyond building a widget.

-

The framework replaces the subtree below this widget with the widget -returned by this method, either by updating the existing subtree or by -removing the subtree and inflating a new subtree, depending on whether the -widget returned by this method can update the root of the existing -subtree, as determined by calling Widget.canUpdate.

-

Typically implementations return a newly created constellation of widgets -that are configured with information from this widget's constructor and -from the given BuildContext.

-

The given BuildContext contains information about the location in the -tree at which this widget is being built. For example, the context -provides the set of inherited widgets for this location in the tree. A -given widget might be built with multiple different BuildContext -arguments over time if the widget is moved around the tree or if the -widget is inserted into the tree in multiple places at once.

-

The implementation of this method must only depend on:

- -

If a widget's build method is to depend on anything else, use a -StatefulWidget instead.

-

See also:

-
    -
  • StatelessWidget, which contains the discussion on performance considerations.
  • -
- - - -## Implementation - -```dart -@override -Widget build(BuildContext context) => - BlocListener, SignUpState>( - listener: (context, state) { - if (customBuilder != null) { - return customBuilder!(context, state); - } - - if (onSuccess != null && - state.status == FormStatus.submissionSuccess) { - return onSuccess!(context); - } - if (onProgress != null && - state.status == FormStatus.submissionInProgress) { - return onProgress!(context); - } - if (onError != null && - (state.status == FormStatus.submissionCanceled || - state.status == FormStatus.submissionFailure)) { - return onError!(context, state.status, state.errorMessage); - } - }, - child: child, - ); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/child.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/child.md deleted file mode 100644 index 53bc3682..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/child.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# child property - - - - - *[](https://dart.dev/null-safety)* - - - -[Widget](https://api.flutter.dev/flutter/widgets/Widget-class.html) child - -_final_ - - - - - - -## Implementation - -```dart -final Widget child; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/customBuilder.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/customBuilder.md deleted file mode 100644 index e59261e0..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/customBuilder.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# customBuilder property - - - - - *[](https://dart.dev/null-safety)* - - - -(void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, [SignUpState](../../wyatt_authentication_bloc/SignUpState-class.md) state)?) customBuilder - -_final_ - - - - - - -## Implementation - -```dart -final void Function(BuildContext context, SignUpState state)? customBuilder; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/onError.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/onError.md deleted file mode 100644 index ed94a98f..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/onError.md +++ /dev/null @@ -1,37 +0,0 @@ - - - -# onError property - - - - - *[](https://dart.dev/null-safety)* - - - -(void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context, FormStatus status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage)?) onError - -_final_ - - - - - - -## Implementation - -```dart -final void Function( - BuildContext context, - FormStatus status, - String? errorMessage, -)? onError; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/onProgress.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/onProgress.md deleted file mode 100644 index 4a30ed71..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/onProgress.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# onProgress property - - - - - *[](https://dart.dev/null-safety)* - - - -(void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?) onProgress - -_final_ - - - - - - -## Implementation - -```dart -final void Function(BuildContext context)? onProgress; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/onSuccess.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/onSuccess.md deleted file mode 100644 index 4d942f63..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpListener/onSuccess.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# onSuccess property - - - - - *[](https://dart.dev/null-safety)* - - - -(void Function([BuildContext](https://api.flutter.dev/flutter/widgets/BuildContext-class.html) context)?) onSuccess - -_final_ - - - - - - -## Implementation - -```dart -final void Function(BuildContext context)? onSuccess; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState-class.md deleted file mode 100644 index d1a945ac..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState-class.md +++ /dev/null @@ -1,179 +0,0 @@ - - - -# SignUpState class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Sign up cubit state to manage the form.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [Equatable](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable-class.html) -- SignUpState - - - - - - - - -## Constructors - -[SignUpState](../wyatt_authentication_bloc/SignUpState/SignUpState.md) ({required WyattForm form, FormStatus status = FormStatus.pure, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage}) - - _const_ - - -## Properties - -##### [email](../wyatt_authentication_bloc/SignUpState/email.md) → FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError> - - - - -_read-only_ - - - -##### [errorMessage](../wyatt_authentication_bloc/SignUpState/errorMessage.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? - - - -Optional error message. -_finalinherited_ - - - -##### [form](../wyatt_authentication_bloc/SignUpState/form.md) → WyattForm - - - -FormData with all inputs, and associated metadata. -_finalinherited_ - - - -##### [hashCode](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [password](../wyatt_authentication_bloc/SignUpState/password.md) → FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError> - - - - -_read-only_ - - - -##### [props](../wyatt_authentication_bloc/SignUpState/props.md) → [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> - - - -The list of properties that will be used to determine whether -two instances are equal. -_read-only_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - -##### [status](../wyatt_authentication_bloc/SignUpState/status.md) → FormStatus - - - -Global status of a form. -_finalinherited_ - - - -##### [stringify](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/stringify.html) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html)? - - - -If set to true, the toString method will be overridden to output -this instance's props. -_read-onlyinherited_ - - - - - -## Methods - -##### [copyWith](../wyatt_authentication_bloc/SignUpState/copyWith.md)({WyattForm? form, FormStatus? status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage}) [SignUpState](../wyatt_authentication_bloc/SignUpState-class.md) - - - - - - - - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/SignUpState/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_override_ - - - - - -## Operators - -##### [operator ==](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/SignUpState.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/SignUpState.md deleted file mode 100644 index 2225e87b..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/SignUpState.md +++ /dev/null @@ -1,34 +0,0 @@ - - - -# SignUpState constructor - - - - - *[](https://dart.dev/null-safety)* - - -const -SignUpState({required WyattForm form, FormStatus status = FormStatus.pure, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage}) - - - - - -## Implementation - -```dart -const SignUpState({ - required super.form, - super.status = FormStatus.pure, - super.errorMessage, -}); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/copyWith.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/copyWith.md deleted file mode 100644 index 35561e0b..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/copyWith.md +++ /dev/null @@ -1,44 +0,0 @@ - - - -# copyWith method - - - - - *[](https://dart.dev/null-safety)* - - - - -[SignUpState](../../wyatt_authentication_bloc/SignUpState-class.md) copyWith -({WyattForm? form, FormStatus? status, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage}) - - - - - - - - -## Implementation - -```dart -SignUpState copyWith({ - WyattForm? form, - FormStatus? status, - String? errorMessage, -}) => - SignUpState( - form: form ?? this.form, - status: status ?? this.status, - errorMessage: errorMessage ?? this.errorMessage, - ); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/email.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/email.md deleted file mode 100644 index 1ded8043..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/email.md +++ /dev/null @@ -1,37 +0,0 @@ - - - -# email property - - - - - *[](https://dart.dev/null-safety)* - - - - - -FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError> email - - - - - - - - -## Implementation - -```dart -FormInputValidator get email => - form.validatorOf(AuthFormField.email); -``` - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/errorMessage.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/errorMessage.md deleted file mode 100644 index d0856deb..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/errorMessage.md +++ /dev/null @@ -1,34 +0,0 @@ - - - -# errorMessage property - - - - - *[](https://dart.dev/null-safety)* - - - -[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? errorMessage - -_finalinherited_ - - - -

Optional error message.

- - - -## Implementation - -```dart -final String? errorMessage; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/form.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/form.md deleted file mode 100644 index d3f2da76..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/form.md +++ /dev/null @@ -1,34 +0,0 @@ - - - -# form property - - - - - *[](https://dart.dev/null-safety)* - - - -WyattForm form - -_finalinherited_ - - - -

FormData with all inputs, and associated metadata.

- - - -## Implementation - -```dart -final WyattForm form; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/password.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/password.md deleted file mode 100644 index 77938106..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/password.md +++ /dev/null @@ -1,37 +0,0 @@ - - - -# password property - - - - - *[](https://dart.dev/null-safety)* - - - - - -FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError> password - - - - - - - - -## Implementation - -```dart -FormInputValidator get password => - form.validatorOf(AuthFormField.password); -``` - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/props.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/props.md deleted file mode 100644 index 2b5a46b8..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/props.md +++ /dev/null @@ -1,42 +0,0 @@ - - - -# props property - - - - - *[](https://dart.dev/null-safety)* - - - - - -**Annotations** - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) -[List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> props - - - - - -

The list of properties that will be used to determine whether -two instances are equal.

- - - -## Implementation - -```dart -@override -List get props => [email, password, status, form]; -``` - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/status.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/status.md deleted file mode 100644 index 644a9f10..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/status.md +++ /dev/null @@ -1,34 +0,0 @@ - - - -# status property - - - - - *[](https://dart.dev/null-safety)* - - - -FormStatus status - -_finalinherited_ - - - -

Global status of a form.

- - - -## Implementation - -```dart -final FormStatus status; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/toString.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/toString.md deleted file mode 100644 index e53f76d6..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpState/toString.md +++ /dev/null @@ -1,50 +0,0 @@ - - - -# toString method - - - - - *[](https://dart.dev/null-safety)* - - - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) - -[String](https://api.flutter.dev/flutter/dart-core/String-class.html) toString -() - -_override_ - - - -

A string representation of this object.

-

Some classes have a default textual representation, -often paired with a static parse function (like int.parse). -These classes will provide the textual representation as -their string representation.

-

Other classes have no meaningful textual representation -that a program will care about. -Such classes will typically override toString to provide -useful information when inspecting the object, -mainly for debugging or logging.

- - - -## Implementation - -```dart -@override -@override -String toString() => 'SignUpState(status: ${status.name} ' - '${(errorMessage != null) ? " [$errorMessage]" : ""}, $form)'; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureFirebase-class.md deleted file mode 100644 index 0b725844..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureFirebase-class.md +++ /dev/null @@ -1,137 +0,0 @@ - - - -# SignUpWithEmailAndPasswordFailureFirebase class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown if during the sign up process if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- [SignUpWithEmailAndPasswordFailureInterface](../wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureInterface-class.md) -- SignUpWithEmailAndPasswordFailureFirebase - - - - - - - - -## Constructors - -[SignUpWithEmailAndPasswordFailureFirebase](../wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureFirebase/SignUpWithEmailAndPasswordFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - -[SignUpWithEmailAndPasswordFailureFirebase.fromCode](../wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureFirebase/SignUpWithEmailAndPasswordFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureFirebase/SignUpWithEmailAndPasswordFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureFirebase/SignUpWithEmailAndPasswordFailureFirebase.fromCode.md deleted file mode 100644 index a88070e0..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureFirebase/SignUpWithEmailAndPasswordFailureFirebase.fromCode.md +++ /dev/null @@ -1,52 +0,0 @@ - - - -# SignUpWithEmailAndPasswordFailureFirebase.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SignUpWithEmailAndPasswordFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - - -## Implementation - -```dart -SignUpWithEmailAndPasswordFailureFirebase.fromCode(String code) - : super.fromCode(code) { - switch (code) { - case 'invalid-email': - msg = 'The email address is badly formatted.'; - break; - case 'user-disabled': - msg = 'This user has been disabled. Please contact support for help.'; - break; - case 'email-already-in-use': - msg = 'An account already exists for that email.'; - break; - case 'operation-not-allowed': - msg = 'Operation is not allowed. Please contact support.'; - break; - case 'weak-password': - msg = 'Please enter a stronger password.'; - break; - default: - this.code = 'unknown'; - msg = 'An unknown error occurred.'; - } -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureFirebase/SignUpWithEmailAndPasswordFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureFirebase/SignUpWithEmailAndPasswordFailureFirebase.md deleted file mode 100644 index 3c589850..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureFirebase/SignUpWithEmailAndPasswordFailureFirebase.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# SignUpWithEmailAndPasswordFailureFirebase constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SignUpWithEmailAndPasswordFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - - - -## Implementation - -```dart -SignUpWithEmailAndPasswordFailureFirebase([String? code, String? msg]) - : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureInterface-class.md deleted file mode 100644 index 934c07dd..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureInterface-class.md +++ /dev/null @@ -1,139 +0,0 @@ - - - -# SignUpWithEmailAndPasswordFailureInterface class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown if during the sign up process if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- SignUpWithEmailAndPasswordFailureInterface - - - -**Implementers** - -- [SignUpWithEmailAndPasswordFailureFirebase](../wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureFirebase-class.md) - - - - - -## Constructors - -[SignUpWithEmailAndPasswordFailureInterface](../wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureInterface/SignUpWithEmailAndPasswordFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - -Thrown if during the sign up process if a failure occurs. - -[SignUpWithEmailAndPasswordFailureInterface.fromCode](../wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureInterface/SignUpWithEmailAndPasswordFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - -Thrown if during the sign up process if a failure occurs. - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureInterface/SignUpWithEmailAndPasswordFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureInterface/SignUpWithEmailAndPasswordFailureInterface.fromCode.md deleted file mode 100644 index 4eba5121..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureInterface/SignUpWithEmailAndPasswordFailureInterface.fromCode.md +++ /dev/null @@ -1,32 +0,0 @@ - - - -# SignUpWithEmailAndPasswordFailureInterface.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SignUpWithEmailAndPasswordFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - -

Thrown if during the sign up process if a failure occurs.

- - - -## Implementation - -```dart -SignUpWithEmailAndPasswordFailureInterface.fromCode(super.code) - : super.fromCode(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureInterface/SignUpWithEmailAndPasswordFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureInterface/SignUpWithEmailAndPasswordFailureInterface.md deleted file mode 100644 index 105e574d..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureInterface/SignUpWithEmailAndPasswordFailureInterface.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# SignUpWithEmailAndPasswordFailureInterface constructor - - - - - *[](https://dart.dev/null-safety)* - - - -SignUpWithEmailAndPasswordFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - - -

Thrown if during the sign up process if a failure occurs.

- - - -## Implementation - -```dart -SignUpWithEmailAndPasswordFailureInterface(super.code, super.msg); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword-mixin.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword-mixin.md deleted file mode 100644 index 220af3ad..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword-mixin.md +++ /dev/null @@ -1,305 +0,0 @@ - - - -# SignUpWithEmailPassword<Data> mixin - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Sign up mixin.

-

Allows the user to register with an email and a password.

-

Gives access to the signUpWithEmailPassword method and -onSignUpWithEmailAndPassword callback.

- - -**Superclass Constraints** - -- [BaseSignUpCubit](../wyatt_authentication_bloc/BaseSignUpCubit-class.md)<Data> - - - - -**Mixin Applications** - -- [SignUpCubit](../wyatt_authentication_bloc/SignUpCubit-class.md) - - - -## Properties - -##### [authenticationRepository](../wyatt_authentication_bloc/BaseSignUpCubit/authenticationRepository.md) → [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> - - - - -_finalinherited_ - - - -##### [formName](../wyatt_authentication_bloc/BaseSignUpCubit/formName.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [formRepository](../wyatt_authentication_bloc/BaseSignUpCubit/formRepository.md) → FormRepository - - - - -_read-onlyinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [isClosed](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/isClosed.html) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -Whether the bloc is closed. -_read-onlyinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - -##### [state](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/state.html) → [SignUpState](../wyatt_authentication_bloc/SignUpState-class.md) - - - -The current state. -_read-onlyinherited_ - - - -##### [stream](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/stream.html) → [Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[SignUpState](../wyatt_authentication_bloc/SignUpState-class.md)> - - - -The current stream of states. -_read-onlyinherited_ - - - - - -## Methods - -##### [addError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/addError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [[StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html)? stackTrace]) void - - - -Reports an error which triggers onError with an optional StackTrace. -_inherited_ - - - -##### [close](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/close.html)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> - - - -Closes the instance. -This method should be called when the instance is no longer needed. -Once close is called, the instance can no longer be used. -_inherited_ - - - -##### [dataChanged](../wyatt_authentication_bloc/BaseSignUpCubit/dataChanged.md)<Value>([String](https://api.flutter.dev/flutter/dart-core/String-class.html) key, FormInputValidator<Value, ValidationError> dirtyValue) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - -##### [emailChanged](../wyatt_authentication_bloc/SignUpWithEmailPassword/emailChanged.md)([String](https://api.flutter.dev/flutter/dart-core/String-class.html) value) void - - - - - - - - -##### [emailCustomChanged](../wyatt_authentication_bloc/SignUpWithEmailPassword/emailCustomChanged.md)<Validator extends FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError>>(Validator validator) void - - - -Same as emailChanged but with a custom Validator. - - - - -##### [emit](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/emit.html)([SignUpState](../wyatt_authentication_bloc/SignUpState-class.md) state) void - - - -Updates the state to the provided state. -emit does nothing if the state being emitted -is equal to the current state. -_inherited_ - - - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [onChange](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onChange.html)([Change](https://pub.dev/documentation/bloc/8.1.0/bloc/Change-class.html)<[SignUpState](../wyatt_authentication_bloc/SignUpState-class.md)> change) void - - - -Called whenever a change occurs with the given change. -A change occurs when a new state is emitted. -onChange is called before the state of the cubit is updated. -onChange is a great spot to add logging/analytics for a specific cubit. -_inherited_ - - - -##### [onError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html) stackTrace) void - - - -Called whenever an error occurs and notifies BlocObserver.onError. -_inherited_ - - - -##### [onSignUpWithEmailAndPassword](../wyatt_authentication_bloc/SignUpWithEmailPassword/onSignUpWithEmailAndPassword.md)(Result<[Account](../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) FutureOrResult<Data?> - - - -This callback is triggered when a user creates an account. - - - - -##### [passwordChanged](../wyatt_authentication_bloc/SignUpWithEmailPassword/passwordChanged.md)([String](https://api.flutter.dev/flutter/dart-core/String-class.html) value) void - - - - - - - - -##### [passwordCustomChanged](../wyatt_authentication_bloc/SignUpWithEmailPassword/passwordCustomChanged.md)<Validator extends FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError>>(Validator validator) void - - - -Same as passwordChanged but with a custom Validator. - - - - -##### [reset](../wyatt_authentication_bloc/BaseSignUpCubit/reset.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - -##### [signUpWithEmailPassword](../wyatt_authentication_bloc/SignUpWithEmailPassword/signUpWithEmailPassword.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - -Creates a new user with the provided email and password. - - - - -##### [submit](../wyatt_authentication_bloc/BaseSignUpCubit/submit.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - -##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - -##### [update](../wyatt_authentication_bloc/BaseSignUpCubit/update.md)(WyattForm form, {SetOperation operation = SetOperation.replace}) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - -##### [validate](../wyatt_authentication_bloc/BaseSignUpCubit/validate.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword/emailChanged.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword/emailChanged.md deleted file mode 100644 index 85e7cc16..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword/emailChanged.md +++ /dev/null @@ -1,47 +0,0 @@ - - - -# emailChanged method - - - - - *[](https://dart.dev/null-safety)* - - - - -void emailChanged -([String](https://api.flutter.dev/flutter/dart-core/String-class.html) value) - - - - - - - - -## Implementation - -```dart -void emailChanged(String value) { - final emailValidatorType = formRepository - .accessForm(formName) - .validatorOf(AuthFormField.email) - .runtimeType; - assert( - emailValidatorType == Email, - 'Use emailCustomChanged(...) with validator $emailValidatorType', - ); - - final Email email = Email.dirty(value); - dataChanged(AuthFormField.email, email); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword/emailCustomChanged.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword/emailCustomChanged.md deleted file mode 100644 index 8915ba03..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword/emailCustomChanged.md +++ /dev/null @@ -1,42 +0,0 @@ - - - -# emailCustomChanged<Validator extends FormInputValidator<String?, ValidationError>> method - - - - - *[](https://dart.dev/null-safety)* - - - - -void emailCustomChanged -<Validator extends FormInputValidator<String?, ValidationError>>(Validator validator) - - - - - -

Same as emailChanged but with a custom Validator.

-

Sort of short hand for dataChanged.

- - - -## Implementation - -```dart -void emailCustomChanged< - Validator extends FormInputValidator>( - Validator validator, -) { - dataChanged(AuthFormField.email, validator); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword/onSignUpWithEmailAndPassword.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword/onSignUpWithEmailAndPassword.md deleted file mode 100644 index cd7c1a80..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword/onSignUpWithEmailAndPassword.md +++ /dev/null @@ -1,40 +0,0 @@ - - - -# onSignUpWithEmailAndPassword method - - - - - *[](https://dart.dev/null-safety)* - - - - -FutureOrResult<Data?> onSignUpWithEmailAndPassword -(Result<[Account](../../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) - - - - - -

This callback is triggered when a user creates an account.

-

For example: when a user sign up in firebase.

- - - -## Implementation - -```dart -FutureOrResult onSignUpWithEmailAndPassword( - Result result, - WyattForm form, -); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword/passwordChanged.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword/passwordChanged.md deleted file mode 100644 index 8db9fda0..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword/passwordChanged.md +++ /dev/null @@ -1,46 +0,0 @@ - - - -# passwordChanged method - - - - - *[](https://dart.dev/null-safety)* - - - - -void passwordChanged -([String](https://api.flutter.dev/flutter/dart-core/String-class.html) value) - - - - - - - - -## Implementation - -```dart -void passwordChanged(String value) { - final passwordValidatorType = formRepository - .accessForm(formName) - .validatorOf(AuthFormField.password) - .runtimeType; - assert( - passwordValidatorType == Password, - 'Use passwordCustomChanged(...) with validator $passwordValidatorType', - ); - final Password password = Password.dirty(value); - dataChanged(AuthFormField.password, password); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword/passwordCustomChanged.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword/passwordCustomChanged.md deleted file mode 100644 index 5e3b39bd..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword/passwordCustomChanged.md +++ /dev/null @@ -1,42 +0,0 @@ - - - -# passwordCustomChanged<Validator extends FormInputValidator<String?, ValidationError>> method - - - - - *[](https://dart.dev/null-safety)* - - - - -void passwordCustomChanged -<Validator extends FormInputValidator<String?, ValidationError>>(Validator validator) - - - - - -

Same as passwordChanged but with a custom Validator.

-

Sort of short hand for dataChanged.

- - - -## Implementation - -```dart -void passwordCustomChanged< - Validator extends FormInputValidator>( - Validator validator, -) { - dataChanged(AuthFormField.password, validator); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword/signUpWithEmailPassword.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword/signUpWithEmailPassword.md deleted file mode 100644 index 0fd593ac..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignUpWithEmailPassword/signUpWithEmailPassword.md +++ /dev/null @@ -1,97 +0,0 @@ - - - -# signUpWithEmailPassword method - - - - - *[](https://dart.dev/null-safety)* - - - - -[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> signUpWithEmailPassword -() - - - - - -

Creates a new user with the provided email and password.

-

Returns the newly created user's unique identifier.

-

Throws a SignUpWithEmailAndPasswordFailureInterface if -an exception occurs.

- - - -## Implementation - -```dart -FutureOr signUpWithEmailPassword() async { - if (!state.status.isValidated) { - return; - } - - final form = formRepository.accessForm(formName); - emit(SignUpState(form: form, status: FormStatus.submissionInProgress)); - - final email = form.valueOf(AuthFormField.email); - final password = form.valueOf(AuthFormField.password); - - if (email.isNullOrEmpty || password.isNullOrEmpty) { - emit( - SignUpState( - form: form, - errorMessage: 'An error occured while retrieving data from the form.', - status: FormStatus.submissionFailure, - ), - ); - } - - return CustomRoutine( - routine: () => authenticationRepository.signUpWithEmailAndPassword( - email: email!, - password: password!, - ), - attachedLogic: (routineResult) => onSignUpWithEmailAndPassword( - routineResult, - form, - ), - onError: (error) { - emit( - SignUpState( - form: form, - errorMessage: error.message, - status: FormStatus.submissionFailure, - ), - ); - addError(error); - }, - onSuccess: (account, data) { - authenticationRepository.addSession( - SessionWrapper( - event: SignedUpEvent(account: account), - session: Session( - account: account, - data: data, - ), - ), - ); - emit( - SignUpState( - form: form, - status: FormStatus.submissionSuccess, - ), - ); - }, - ).call(); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInEvent-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInEvent-class.md deleted file mode 100644 index c3b76749..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInEvent-class.md +++ /dev/null @@ -1,135 +0,0 @@ - - - -# SignedInEvent class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

When a user authenticates (from not logged in to logged in).

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [Equatable](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable-class.html) -- [AuthenticationChangeEvent](../wyatt_authentication_bloc/AuthenticationChangeEvent-class.md) -- SignedInEvent - - - - - - - - -## Constructors - -[SignedInEvent](../wyatt_authentication_bloc/SignedInEvent/SignedInEvent.md) ({required [Account](../wyatt_authentication_bloc/Account-class.md) account}) - - _const_ - - -## Properties - -##### [account](../wyatt_authentication_bloc/SignedInEvent/account.md) → [Account](../wyatt_authentication_bloc/Account-class.md) - - - - -_final_ - - - -##### [hashCode](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [props](../wyatt_authentication_bloc/SignedInEvent/props.md) → [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> - - - -The list of properties that will be used to determine whether -two instances are equal. -_read-onlyoverride_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - -##### [stringify](../wyatt_authentication_bloc/AuthenticationChangeEvent/stringify.md) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -If set to true, the toString method will be overridden to output -this instance's props. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInEvent/SignedInEvent.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInEvent/SignedInEvent.md deleted file mode 100644 index cdc4ad73..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInEvent/SignedInEvent.md +++ /dev/null @@ -1,30 +0,0 @@ - - - -# SignedInEvent constructor - - - - - *[](https://dart.dev/null-safety)* - - -const -SignedInEvent({required [Account](../../wyatt_authentication_bloc/Account-class.md) account}) - - - - - -## Implementation - -```dart -const SignedInEvent({required this.account}); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInEvent/account.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInEvent/account.md deleted file mode 100644 index 671e197e..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInEvent/account.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# account property - - - - - *[](https://dart.dev/null-safety)* - - - -[Account](../../wyatt_authentication_bloc/Account-class.md) account - -_final_ - - - - - - -## Implementation - -```dart -final Account account; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInEvent/props.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInEvent/props.md deleted file mode 100644 index fbde09d1..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInEvent/props.md +++ /dev/null @@ -1,42 +0,0 @@ - - - -# props property - - - - - *[](https://dart.dev/null-safety)* - - - - - -**Annotations** - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) -[List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> props - -_override_ - - - -

The list of properties that will be used to determine whether -two instances are equal.

- - - -## Implementation - -```dart -@override -List get props => [account]; -``` - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInFromCacheEvent-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInFromCacheEvent-class.md deleted file mode 100644 index fd2ab1bb..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInFromCacheEvent-class.md +++ /dev/null @@ -1,135 +0,0 @@ - - - -# SignedInFromCacheEvent class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

When a user authenticates automatically (from not logged in to logged in).

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [Equatable](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable-class.html) -- [AuthenticationChangeEvent](../wyatt_authentication_bloc/AuthenticationChangeEvent-class.md) -- SignedInFromCacheEvent - - - - - - - - -## Constructors - -[SignedInFromCacheEvent](../wyatt_authentication_bloc/SignedInFromCacheEvent/SignedInFromCacheEvent.md) ({required [Account](../wyatt_authentication_bloc/Account-class.md) account}) - - _const_ - - -## Properties - -##### [account](../wyatt_authentication_bloc/SignedInFromCacheEvent/account.md) → [Account](../wyatt_authentication_bloc/Account-class.md) - - - - -_final_ - - - -##### [hashCode](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [props](../wyatt_authentication_bloc/SignedInFromCacheEvent/props.md) → [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> - - - -The list of properties that will be used to determine whether -two instances are equal. -_read-onlyoverride_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - -##### [stringify](../wyatt_authentication_bloc/AuthenticationChangeEvent/stringify.md) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -If set to true, the toString method will be overridden to output -this instance's props. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInFromCacheEvent/SignedInFromCacheEvent.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInFromCacheEvent/SignedInFromCacheEvent.md deleted file mode 100644 index 99d1d86f..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInFromCacheEvent/SignedInFromCacheEvent.md +++ /dev/null @@ -1,30 +0,0 @@ - - - -# SignedInFromCacheEvent constructor - - - - - *[](https://dart.dev/null-safety)* - - -const -SignedInFromCacheEvent({required [Account](../../wyatt_authentication_bloc/Account-class.md) account}) - - - - - -## Implementation - -```dart -const SignedInFromCacheEvent({required this.account}); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInFromCacheEvent/account.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInFromCacheEvent/account.md deleted file mode 100644 index 671e197e..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInFromCacheEvent/account.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# account property - - - - - *[](https://dart.dev/null-safety)* - - - -[Account](../../wyatt_authentication_bloc/Account-class.md) account - -_final_ - - - - - - -## Implementation - -```dart -final Account account; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInFromCacheEvent/props.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInFromCacheEvent/props.md deleted file mode 100644 index fbde09d1..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedInFromCacheEvent/props.md +++ /dev/null @@ -1,42 +0,0 @@ - - - -# props property - - - - - *[](https://dart.dev/null-safety)* - - - - - -**Annotations** - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) -[List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> props - -_override_ - - - -

The list of properties that will be used to determine whether -two instances are equal.

- - - -## Implementation - -```dart -@override -List get props => [account]; -``` - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedOutEvent-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedOutEvent-class.md deleted file mode 100644 index 0075e9eb..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedOutEvent-class.md +++ /dev/null @@ -1,126 +0,0 @@ - - - -# SignedOutEvent class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

When a user logs out.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [Equatable](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable-class.html) -- [AuthenticationChangeEvent](../wyatt_authentication_bloc/AuthenticationChangeEvent-class.md) -- SignedOutEvent - - - - - - - - -## Constructors - -[SignedOutEvent](../wyatt_authentication_bloc/SignedOutEvent/SignedOutEvent.md) () - - _const_ - - -## Properties - -##### [hashCode](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [props](../wyatt_authentication_bloc/AuthenticationChangeEvent/props.md) → [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> - - - -The list of properties that will be used to determine whether -two instances are equal. -_read-onlyinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - -##### [stringify](../wyatt_authentication_bloc/AuthenticationChangeEvent/stringify.md) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -If set to true, the toString method will be overridden to output -this instance's props. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedOutEvent/SignedOutEvent.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedOutEvent/SignedOutEvent.md deleted file mode 100644 index 734b4c5d..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedOutEvent/SignedOutEvent.md +++ /dev/null @@ -1,30 +0,0 @@ - - - -# SignedOutEvent constructor - - - - - *[](https://dart.dev/null-safety)* - - -const -SignedOutEvent() - - - - - -## Implementation - -```dart -const SignedOutEvent(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedUpEvent-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedUpEvent-class.md deleted file mode 100644 index c53aeb32..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedUpEvent-class.md +++ /dev/null @@ -1,135 +0,0 @@ - - - -# SignedUpEvent class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

When a user creates an account.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [Equatable](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable-class.html) -- [AuthenticationChangeEvent](../wyatt_authentication_bloc/AuthenticationChangeEvent-class.md) -- SignedUpEvent - - - - - - - - -## Constructors - -[SignedUpEvent](../wyatt_authentication_bloc/SignedUpEvent/SignedUpEvent.md) ({required [Account](../wyatt_authentication_bloc/Account-class.md) account}) - - _const_ - - -## Properties - -##### [account](../wyatt_authentication_bloc/SignedUpEvent/account.md) → [Account](../wyatt_authentication_bloc/Account-class.md) - - - - -_final_ - - - -##### [hashCode](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [props](../wyatt_authentication_bloc/SignedUpEvent/props.md) → [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> - - - -The list of properties that will be used to determine whether -two instances are equal. -_read-onlyoverride_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - -##### [stringify](../wyatt_authentication_bloc/AuthenticationChangeEvent/stringify.md) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -If set to true, the toString method will be overridden to output -this instance's props. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedUpEvent/SignedUpEvent.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedUpEvent/SignedUpEvent.md deleted file mode 100644 index 4a68b5f5..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedUpEvent/SignedUpEvent.md +++ /dev/null @@ -1,30 +0,0 @@ - - - -# SignedUpEvent constructor - - - - - *[](https://dart.dev/null-safety)* - - -const -SignedUpEvent({required [Account](../../wyatt_authentication_bloc/Account-class.md) account}) - - - - - -## Implementation - -```dart -const SignedUpEvent({required this.account}); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedUpEvent/account.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedUpEvent/account.md deleted file mode 100644 index 671e197e..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedUpEvent/account.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# account property - - - - - *[](https://dart.dev/null-safety)* - - - -[Account](../../wyatt_authentication_bloc/Account-class.md) account - -_final_ - - - - - - -## Implementation - -```dart -final Account account; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedUpEvent/props.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedUpEvent/props.md deleted file mode 100644 index fbde09d1..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/SignedUpEvent/props.md +++ /dev/null @@ -1,42 +0,0 @@ - - - -# props property - - - - - *[](https://dart.dev/null-safety)* - - - - - -**Annotations** - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) -[List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> props - -_override_ - - - -

The list of properties that will be used to determine whether -two instances are equal.

- - - -## Implementation - -```dart -@override -List get props => [account]; -``` - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UnknownAuthenticationEvent-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UnknownAuthenticationEvent-class.md deleted file mode 100644 index 1b5a7161..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UnknownAuthenticationEvent-class.md +++ /dev/null @@ -1,126 +0,0 @@ - - - -# UnknownAuthenticationEvent class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

When a user's login status is unknown.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [Equatable](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable-class.html) -- [AuthenticationChangeEvent](../wyatt_authentication_bloc/AuthenticationChangeEvent-class.md) -- UnknownAuthenticationEvent - - - - - - - - -## Constructors - -[UnknownAuthenticationEvent](../wyatt_authentication_bloc/UnknownAuthenticationEvent/UnknownAuthenticationEvent.md) () - - _const_ - - -## Properties - -##### [hashCode](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [props](../wyatt_authentication_bloc/AuthenticationChangeEvent/props.md) → [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> - - - -The list of properties that will be used to determine whether -two instances are equal. -_read-onlyinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - -##### [stringify](../wyatt_authentication_bloc/AuthenticationChangeEvent/stringify.md) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -If set to true, the toString method will be overridden to output -this instance's props. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UnknownAuthenticationEvent/UnknownAuthenticationEvent.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UnknownAuthenticationEvent/UnknownAuthenticationEvent.md deleted file mode 100644 index 6e9d242a..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UnknownAuthenticationEvent/UnknownAuthenticationEvent.md +++ /dev/null @@ -1,30 +0,0 @@ - - - -# UnknownAuthenticationEvent constructor - - - - - *[](https://dart.dev/null-safety)* - - -const -UnknownAuthenticationEvent() - - - - - -## Implementation - -```dart -const UnknownAuthenticationEvent(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmail-mixin.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmail-mixin.md deleted file mode 100644 index 0673d44e..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmail-mixin.md +++ /dev/null @@ -1,287 +0,0 @@ - - - -# UpdateEmail<Data> mixin - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Edit account mixin.

-

Allows the user to edit his email

-

Gives access to the updateEmail method and -onEmailUpdated callback.

- - -**Superclass Constraints** - -- [BaseEditAccountCubit](../wyatt_authentication_bloc/BaseEditAccountCubit-class.md)<Data> - - - - -**Mixin Applications** - -- [EditAccountCubit](../wyatt_authentication_bloc/EditAccountCubit-class.md) - - - -## Properties - -##### [authenticationRepository](../wyatt_authentication_bloc/BaseEditAccountCubit/authenticationRepository.md) → [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> - - - - -_finalinherited_ - - - -##### [formName](../wyatt_authentication_bloc/BaseEditAccountCubit/formName.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [formRepository](../wyatt_authentication_bloc/BaseEditAccountCubit/formRepository.md) → FormRepository - - - - -_read-onlyinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [isClosed](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/isClosed.html) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -Whether the bloc is closed. -_read-onlyinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - -##### [state](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/state.html) → [EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md) - - - -The current state. -_read-onlyinherited_ - - - -##### [stream](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/stream.html) → [Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md)> - - - -The current stream of states. -_read-onlyinherited_ - - - - - -## Methods - -##### [addError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/addError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [[StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html)? stackTrace]) void - - - -Reports an error which triggers onError with an optional StackTrace. -_inherited_ - - - -##### [close](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/close.html)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> - - - -Closes the instance. -This method should be called when the instance is no longer needed. -Once close is called, the instance can no longer be used. -_inherited_ - - - -##### [dataChanged](../wyatt_authentication_bloc/BaseEditAccountCubit/dataChanged.md)<Value>([String](https://api.flutter.dev/flutter/dart-core/String-class.html) key, FormInputValidator<Value, ValidationError> dirtyValue) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - -##### [emailChanged](../wyatt_authentication_bloc/UpdateEmail/emailChanged.md)([String](https://api.flutter.dev/flutter/dart-core/String-class.html) value) void - - - - - - - - -##### [emailCustomChanged](../wyatt_authentication_bloc/UpdateEmail/emailCustomChanged.md)<Validator extends FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError>>(Validator validator) void - - - -Same as emailChanged but with a custom Validator. - - - - -##### [emit](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/emit.html)([EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md) state) void - - - -Updates the state to the provided state. -emit does nothing if the state being emitted -is equal to the current state. -_inherited_ - - - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [onChange](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onChange.html)([Change](https://pub.dev/documentation/bloc/8.1.0/bloc/Change-class.html)<[EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md)> change) void - - - -Called whenever a change occurs with the given change. -A change occurs when a new state is emitted. -onChange is called before the state of the cubit is updated. -onChange is a great spot to add logging/analytics for a specific cubit. -_inherited_ - - - -##### [onEmailUpdated](../wyatt_authentication_bloc/UpdateEmail/onEmailUpdated.md)(Result<[Account](../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) FutureOrResult<Data?> - - - -This callback is triggered when user updates his email - - - - -##### [onError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html) stackTrace) void - - - -Called whenever an error occurs and notifies BlocObserver.onError. -_inherited_ - - - -##### [reset](../wyatt_authentication_bloc/BaseEditAccountCubit/reset.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - -##### [submit](../wyatt_authentication_bloc/BaseEditAccountCubit/submit.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - -##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - -##### [update](../wyatt_authentication_bloc/BaseEditAccountCubit/update.md)(WyattForm form, {SetOperation operation = SetOperation.replace}) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - -##### [updateEmail](../wyatt_authentication_bloc/UpdateEmail/updateEmail.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - -Update or add email. - - - - -##### [validate](../wyatt_authentication_bloc/BaseEditAccountCubit/validate.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmail/emailChanged.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmail/emailChanged.md deleted file mode 100644 index 85e7cc16..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmail/emailChanged.md +++ /dev/null @@ -1,47 +0,0 @@ - - - -# emailChanged method - - - - - *[](https://dart.dev/null-safety)* - - - - -void emailChanged -([String](https://api.flutter.dev/flutter/dart-core/String-class.html) value) - - - - - - - - -## Implementation - -```dart -void emailChanged(String value) { - final emailValidatorType = formRepository - .accessForm(formName) - .validatorOf(AuthFormField.email) - .runtimeType; - assert( - emailValidatorType == Email, - 'Use emailCustomChanged(...) with validator $emailValidatorType', - ); - - final Email email = Email.dirty(value); - dataChanged(AuthFormField.email, email); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmail/emailCustomChanged.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmail/emailCustomChanged.md deleted file mode 100644 index 7ec149cb..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmail/emailCustomChanged.md +++ /dev/null @@ -1,42 +0,0 @@ - - - -# emailCustomChanged<Validator extends FormInputValidator<String?, ValidationError>> method - - - - - *[](https://dart.dev/null-safety)* - - - - -void emailCustomChanged -<Validator extends FormInputValidator<String?, ValidationError>>(Validator validator) - - - - - -

Same as emailChanged but with a custom Validator.

-

Sort of short hand for dataChanged.

- - - -## Implementation - -```dart -void emailCustomChanged< - Validator extends FormInputValidator>( - Validator validator, -) { - dataChanged(AuthFormField.email, validator); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmail/onEmailUpdated.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmail/onEmailUpdated.md deleted file mode 100644 index 7e3757f2..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmail/onEmailUpdated.md +++ /dev/null @@ -1,39 +0,0 @@ - - - -# onEmailUpdated method - - - - - *[](https://dart.dev/null-safety)* - - - - -FutureOrResult<Data?> onEmailUpdated -(Result<[Account](../../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) - - - - - -

This callback is triggered when user updates his email

- - - -## Implementation - -```dart -FutureOrResult onEmailUpdated( - Result result, - WyattForm form, -); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmail/updateEmail.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmail/updateEmail.md deleted file mode 100644 index 7c814f89..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmail/updateEmail.md +++ /dev/null @@ -1,103 +0,0 @@ - - - -# updateEmail method - - - - - *[](https://dart.dev/null-safety)* - - - - -[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> updateEmail -() - - - - - -

Update or add email.

-

Throws a UpdateEmailFailureInterface if -an exception occurs.

- - - -## Implementation - -```dart -FutureOr updateEmail() async { - if (state.status.isSubmissionInProgress) { - return; - } - - if (!state.status.isValidated) { - return; - } - - final form = formRepository.accessForm(formName); - emit( - EditAccountState( - form: form, - status: FormStatus.submissionInProgress, - ), - ); - - final email = form.valueOf(AuthFormField.email); - - if (email.isNullOrEmpty) { - emit( - EditAccountState( - form: form, - errorMessage: 'An error occured while retrieving data from the form.', - status: FormStatus.submissionFailure, - ), - ); - } - - return CustomRoutine( - routine: () => authenticationRepository.updateEmail( - email: email!, - ), - attachedLogic: (routineResult) => onEmailUpdated( - routineResult, - form, - ), - onError: (error) { - emit( - EditAccountState( - form: form, - errorMessage: error.message, - status: FormStatus.submissionFailure, - ), - ); - addError(error); - }, - onSuccess: (account, data) { - authenticationRepository.addSession( - SessionWrapper( - event: UpdatedEvent(account: account), - session: Session( - account: account, - data: data, - ), - ), - ); - emit( - EditAccountState( - form: form, - status: FormStatus.submissionSuccess, - ), - ); - }, - ).call(); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmailFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmailFailureFirebase-class.md deleted file mode 100644 index aa440929..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmailFailureFirebase-class.md +++ /dev/null @@ -1,137 +0,0 @@ - - - -# UpdateEmailFailureFirebase class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown during the email modification process if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- [UpdateEmailFailureInterface](../wyatt_authentication_bloc/UpdateEmailFailureInterface-class.md) -- UpdateEmailFailureFirebase - - - - - - - - -## Constructors - -[UpdateEmailFailureFirebase](../wyatt_authentication_bloc/UpdateEmailFailureFirebase/UpdateEmailFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - -[UpdateEmailFailureFirebase.fromCode](../wyatt_authentication_bloc/UpdateEmailFailureFirebase/UpdateEmailFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmailFailureFirebase/UpdateEmailFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmailFailureFirebase/UpdateEmailFailureFirebase.fromCode.md deleted file mode 100644 index d9c01e20..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmailFailureFirebase/UpdateEmailFailureFirebase.fromCode.md +++ /dev/null @@ -1,45 +0,0 @@ - - - -# UpdateEmailFailureFirebase.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -UpdateEmailFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - - -## Implementation - -```dart -UpdateEmailFailureFirebase.fromCode(String code) : super.fromCode(code) { - switch (code) { - case 'invalid-email': - msg = 'Email is not valid or badly formatted.'; - break; - case 'email-already-in-use': - msg = 'An account already exists for that email.'; - break; - case 'requires-recent-login': - msg = "User's last sign-in time does not meet the security threshold."; - break; - default: - this.code = 'unknown'; - msg = 'An unknown error occurred.'; - } -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmailFailureFirebase/UpdateEmailFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmailFailureFirebase/UpdateEmailFailureFirebase.md deleted file mode 100644 index 7c7e5fe5..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmailFailureFirebase/UpdateEmailFailureFirebase.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# UpdateEmailFailureFirebase constructor - - - - - *[](https://dart.dev/null-safety)* - - - -UpdateEmailFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - - - -## Implementation - -```dart -UpdateEmailFailureFirebase([String? code, String? msg]) - : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmailFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmailFailureInterface-class.md deleted file mode 100644 index 29d54938..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmailFailureInterface-class.md +++ /dev/null @@ -1,139 +0,0 @@ - - - -# UpdateEmailFailureInterface class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown during the email modification process if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- UpdateEmailFailureInterface - - - -**Implementers** - -- [UpdateEmailFailureFirebase](../wyatt_authentication_bloc/UpdateEmailFailureFirebase-class.md) - - - - - -## Constructors - -[UpdateEmailFailureInterface](../wyatt_authentication_bloc/UpdateEmailFailureInterface/UpdateEmailFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - - - -[UpdateEmailFailureInterface.fromCode](../wyatt_authentication_bloc/UpdateEmailFailureInterface/UpdateEmailFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmailFailureInterface/UpdateEmailFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmailFailureInterface/UpdateEmailFailureInterface.fromCode.md deleted file mode 100644 index 656a17b9..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmailFailureInterface/UpdateEmailFailureInterface.fromCode.md +++ /dev/null @@ -1,30 +0,0 @@ - - - -# UpdateEmailFailureInterface.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -UpdateEmailFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - - -## Implementation - -```dart -UpdateEmailFailureInterface.fromCode(super.code) : super.fromCode(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmailFailureInterface/UpdateEmailFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmailFailureInterface/UpdateEmailFailureInterface.md deleted file mode 100644 index ffa1fd03..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdateEmailFailureInterface/UpdateEmailFailureInterface.md +++ /dev/null @@ -1,30 +0,0 @@ - - - -# UpdateEmailFailureInterface constructor - - - - - *[](https://dart.dev/null-safety)* - - - -UpdateEmailFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - - - - - -## Implementation - -```dart -UpdateEmailFailureInterface(super.code, super.msg); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePassword-mixin.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePassword-mixin.md deleted file mode 100644 index cea1271f..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePassword-mixin.md +++ /dev/null @@ -1,287 +0,0 @@ - - - -# UpdatePassword<Data> mixin - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Edit account mixin.

-

Allows the user to edit his password

-

Gives access to the updatePassword method and -onPasswordUpdated callback.

- - -**Superclass Constraints** - -- [BaseEditAccountCubit](../wyatt_authentication_bloc/BaseEditAccountCubit-class.md)<Data> - - - - -**Mixin Applications** - -- [EditAccountCubit](../wyatt_authentication_bloc/EditAccountCubit-class.md) - - - -## Properties - -##### [authenticationRepository](../wyatt_authentication_bloc/BaseEditAccountCubit/authenticationRepository.md) → [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> - - - - -_finalinherited_ - - - -##### [formName](../wyatt_authentication_bloc/BaseEditAccountCubit/formName.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [formRepository](../wyatt_authentication_bloc/BaseEditAccountCubit/formRepository.md) → FormRepository - - - - -_read-onlyinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [isClosed](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/isClosed.html) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -Whether the bloc is closed. -_read-onlyinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - -##### [state](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/state.html) → [EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md) - - - -The current state. -_read-onlyinherited_ - - - -##### [stream](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/stream.html) → [Stream](https://api.flutter.dev/flutter/dart-async/Stream-class.html)<[EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md)> - - - -The current stream of states. -_read-onlyinherited_ - - - - - -## Methods - -##### [addError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/addError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [[StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html)? stackTrace]) void - - - -Reports an error which triggers onError with an optional StackTrace. -_inherited_ - - - -##### [close](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/close.html)() [Future](https://api.flutter.dev/flutter/dart-async/Future-class.html)<void> - - - -Closes the instance. -This method should be called when the instance is no longer needed. -Once close is called, the instance can no longer be used. -_inherited_ - - - -##### [dataChanged](../wyatt_authentication_bloc/BaseEditAccountCubit/dataChanged.md)<Value>([String](https://api.flutter.dev/flutter/dart-core/String-class.html) key, FormInputValidator<Value, ValidationError> dirtyValue) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - -##### [emit](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/emit.html)([EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md) state) void - - - -Updates the state to the provided state. -emit does nothing if the state being emitted -is equal to the current state. -_inherited_ - - - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [onChange](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onChange.html)([Change](https://pub.dev/documentation/bloc/8.1.0/bloc/Change-class.html)<[EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md)> change) void - - - -Called whenever a change occurs with the given change. -A change occurs when a new state is emitted. -onChange is called before the state of the cubit is updated. -onChange is a great spot to add logging/analytics for a specific cubit. -_inherited_ - - - -##### [onError](https://pub.dev/documentation/bloc/8.1.0/bloc/BlocBase/onError.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) error, [StackTrace](https://api.flutter.dev/flutter/dart-core/StackTrace-class.html) stackTrace) void - - - -Called whenever an error occurs and notifies BlocObserver.onError. -_inherited_ - - - -##### [onPasswordUpdated](../wyatt_authentication_bloc/UpdatePassword/onPasswordUpdated.md)(Result<[Account](../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) FutureOrResult<Data?> - - - -This callback is triggered when a user edits his password. - - - - -##### [passwordChanged](../wyatt_authentication_bloc/UpdatePassword/passwordChanged.md)([String](https://api.flutter.dev/flutter/dart-core/String-class.html) value) void - - - - - - - - -##### [passwordCustomChanged](../wyatt_authentication_bloc/UpdatePassword/passwordCustomChanged.md)<Validator extends FormInputValidator<[String](https://api.flutter.dev/flutter/dart-core/String-class.html)?, ValidationError>>(Validator validator) void - - - -Same as passwordChanged but with a custom Validator. - - - - -##### [reset](../wyatt_authentication_bloc/BaseEditAccountCubit/reset.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - -##### [submit](../wyatt_authentication_bloc/BaseEditAccountCubit/submit.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - -##### [toString](https://api.flutter.dev/flutter/dart-core/Object/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - -##### [update](../wyatt_authentication_bloc/BaseEditAccountCubit/update.md)(WyattForm form, {SetOperation operation = SetOperation.replace}) [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - -##### [updatePassword](../wyatt_authentication_bloc/UpdatePassword/updatePassword.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - -Update or add password. - - - - -##### [validate](../wyatt_authentication_bloc/BaseEditAccountCubit/validate.md)() [FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> - - - - -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePassword/onPasswordUpdated.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePassword/onPasswordUpdated.md deleted file mode 100644 index b0354384..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePassword/onPasswordUpdated.md +++ /dev/null @@ -1,39 +0,0 @@ - - - -# onPasswordUpdated method - - - - - *[](https://dart.dev/null-safety)* - - - - -FutureOrResult<Data?> onPasswordUpdated -(Result<[Account](../../wyatt_authentication_bloc/Account-class.md), AppException> result, WyattForm form) - - - - - -

This callback is triggered when a user edits his password.

- - - -## Implementation - -```dart -FutureOrResult onPasswordUpdated( - Result result, - WyattForm form, -); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePassword/passwordChanged.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePassword/passwordChanged.md deleted file mode 100644 index 8db9fda0..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePassword/passwordChanged.md +++ /dev/null @@ -1,46 +0,0 @@ - - - -# passwordChanged method - - - - - *[](https://dart.dev/null-safety)* - - - - -void passwordChanged -([String](https://api.flutter.dev/flutter/dart-core/String-class.html) value) - - - - - - - - -## Implementation - -```dart -void passwordChanged(String value) { - final passwordValidatorType = formRepository - .accessForm(formName) - .validatorOf(AuthFormField.password) - .runtimeType; - assert( - passwordValidatorType == Password, - 'Use passwordCustomChanged(...) with validator $passwordValidatorType', - ); - final Password password = Password.dirty(value); - dataChanged(AuthFormField.password, password); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePassword/passwordCustomChanged.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePassword/passwordCustomChanged.md deleted file mode 100644 index 2cb08454..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePassword/passwordCustomChanged.md +++ /dev/null @@ -1,42 +0,0 @@ - - - -# passwordCustomChanged<Validator extends FormInputValidator<String?, ValidationError>> method - - - - - *[](https://dart.dev/null-safety)* - - - - -void passwordCustomChanged -<Validator extends FormInputValidator<String?, ValidationError>>(Validator validator) - - - - - -

Same as passwordChanged but with a custom Validator.

-

Sort of short hand for dataChanged.

- - - -## Implementation - -```dart -void passwordCustomChanged< - Validator extends FormInputValidator>( - Validator validator, -) { - dataChanged(AuthFormField.password, validator); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePassword/updatePassword.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePassword/updatePassword.md deleted file mode 100644 index fae26194..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePassword/updatePassword.md +++ /dev/null @@ -1,103 +0,0 @@ - - - -# updatePassword method - - - - - *[](https://dart.dev/null-safety)* - - - - -[FutureOr](https://api.flutter.dev/flutter/dart-async/FutureOr-class.html)<void> updatePassword -() - - - - - -

Update or add password.

-

Throws a UpdatePasswordFailureInterface if -an exception occurs.

- - - -## Implementation - -```dart -FutureOr updatePassword() async { - if (state.status.isSubmissionInProgress) { - return; - } - - if (!state.status.isValidated) { - return; - } - - final form = formRepository.accessForm(formName); - emit( - EditAccountState( - form: form, - status: FormStatus.submissionInProgress, - ), - ); - - final password = form.valueOf(AuthFormField.password); - - if (password.isNullOrEmpty) { - emit( - EditAccountState( - form: form, - errorMessage: 'An error occured while retrieving data from the form.', - status: FormStatus.submissionFailure, - ), - ); - } - - return CustomRoutine( - routine: () => authenticationRepository.updatePassword( - password: password!, - ), - attachedLogic: (routineResult) => onPasswordUpdated( - routineResult, - form, - ), - onError: (error) { - emit( - EditAccountState( - form: form, - errorMessage: error.message, - status: FormStatus.submissionFailure, - ), - ); - addError(error); - }, - onSuccess: (account, data) { - authenticationRepository.addSession( - SessionWrapper( - event: SignedInEvent(account: account), - session: Session( - account: account, - data: data, - ), - ), - ); - emit( - EditAccountState( - form: form, - status: FormStatus.submissionSuccess, - ), - ); - }, - ).call(); -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePasswordFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePasswordFailureFirebase-class.md deleted file mode 100644 index 75e3bd3b..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePasswordFailureFirebase-class.md +++ /dev/null @@ -1,137 +0,0 @@ - - - -# UpdatePasswordFailureFirebase class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown during the password modification process if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- [UpdatePasswordFailureInterface](../wyatt_authentication_bloc/UpdatePasswordFailureInterface-class.md) -- UpdatePasswordFailureFirebase - - - - - - - - -## Constructors - -[UpdatePasswordFailureFirebase](../wyatt_authentication_bloc/UpdatePasswordFailureFirebase/UpdatePasswordFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - -[UpdatePasswordFailureFirebase.fromCode](../wyatt_authentication_bloc/UpdatePasswordFailureFirebase/UpdatePasswordFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePasswordFailureFirebase/UpdatePasswordFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePasswordFailureFirebase/UpdatePasswordFailureFirebase.fromCode.md deleted file mode 100644 index 1aa2ae7c..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePasswordFailureFirebase/UpdatePasswordFailureFirebase.fromCode.md +++ /dev/null @@ -1,42 +0,0 @@ - - - -# UpdatePasswordFailureFirebase.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -UpdatePasswordFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - - -## Implementation - -```dart -UpdatePasswordFailureFirebase.fromCode(String code) : super.fromCode(code) { - switch (code) { - case 'weak-password': - msg = 'Please enter a stronger password.'; - break; - case 'requires-recent-login': - msg = "User's last sign-in time does not meet the security threshold."; - break; - default: - this.code = 'unknown'; - msg = 'An unknown error occurred.'; - } -} -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePasswordFailureFirebase/UpdatePasswordFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePasswordFailureFirebase/UpdatePasswordFailureFirebase.md deleted file mode 100644 index 0f38d6b8..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePasswordFailureFirebase/UpdatePasswordFailureFirebase.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# UpdatePasswordFailureFirebase constructor - - - - - *[](https://dart.dev/null-safety)* - - - -UpdatePasswordFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - - - -## Implementation - -```dart -UpdatePasswordFailureFirebase([String? code, String? msg]) - : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePasswordFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePasswordFailureInterface-class.md deleted file mode 100644 index d7a95cd8..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePasswordFailureInterface-class.md +++ /dev/null @@ -1,139 +0,0 @@ - - - -# UpdatePasswordFailureInterface class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown during the password modification process if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- UpdatePasswordFailureInterface - - - -**Implementers** - -- [UpdatePasswordFailureFirebase](../wyatt_authentication_bloc/UpdatePasswordFailureFirebase-class.md) - - - - - -## Constructors - -[UpdatePasswordFailureInterface](../wyatt_authentication_bloc/UpdatePasswordFailureInterface/UpdatePasswordFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - - - -[UpdatePasswordFailureInterface.fromCode](../wyatt_authentication_bloc/UpdatePasswordFailureInterface/UpdatePasswordFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePasswordFailureInterface/UpdatePasswordFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePasswordFailureInterface/UpdatePasswordFailureInterface.fromCode.md deleted file mode 100644 index d459010f..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePasswordFailureInterface/UpdatePasswordFailureInterface.fromCode.md +++ /dev/null @@ -1,30 +0,0 @@ - - - -# UpdatePasswordFailureInterface.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -UpdatePasswordFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - - -## Implementation - -```dart -UpdatePasswordFailureInterface.fromCode(super.code) : super.fromCode(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePasswordFailureInterface/UpdatePasswordFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePasswordFailureInterface/UpdatePasswordFailureInterface.md deleted file mode 100644 index bbba2c50..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatePasswordFailureInterface/UpdatePasswordFailureInterface.md +++ /dev/null @@ -1,30 +0,0 @@ - - - -# UpdatePasswordFailureInterface constructor - - - - - *[](https://dart.dev/null-safety)* - - - -UpdatePasswordFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - - - - - -## Implementation - -```dart -UpdatePasswordFailureInterface(super.code, super.msg); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatedEvent-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatedEvent-class.md deleted file mode 100644 index 1097b97b..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatedEvent-class.md +++ /dev/null @@ -1,135 +0,0 @@ - - - -# UpdatedEvent class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

When the user's account has been updated.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [Equatable](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable-class.html) -- [AuthenticationChangeEvent](../wyatt_authentication_bloc/AuthenticationChangeEvent-class.md) -- UpdatedEvent - - - - - - - - -## Constructors - -[UpdatedEvent](../wyatt_authentication_bloc/UpdatedEvent/UpdatedEvent.md) ({required [Account](../wyatt_authentication_bloc/Account-class.md) account}) - - _const_ - - -## Properties - -##### [account](../wyatt_authentication_bloc/UpdatedEvent/account.md) → [Account](../wyatt_authentication_bloc/Account-class.md) - - - - -_final_ - - - -##### [hashCode](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [props](../wyatt_authentication_bloc/UpdatedEvent/props.md) → [List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> - - - -The list of properties that will be used to determine whether -two instances are equal. -_read-onlyoverride_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - -##### [stringify](../wyatt_authentication_bloc/AuthenticationChangeEvent/stringify.md) → [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -If set to true, the toString method will be overridden to output -this instance's props. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/toString.html)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://pub.dev/documentation/equatable/2.0.5/equatable/Equatable/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatedEvent/UpdatedEvent.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatedEvent/UpdatedEvent.md deleted file mode 100644 index cb29ebfe..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatedEvent/UpdatedEvent.md +++ /dev/null @@ -1,30 +0,0 @@ - - - -# UpdatedEvent constructor - - - - - *[](https://dart.dev/null-safety)* - - -const -UpdatedEvent({required [Account](../../wyatt_authentication_bloc/Account-class.md) account}) - - - - - -## Implementation - -```dart -const UpdatedEvent({required this.account}); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatedEvent/account.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatedEvent/account.md deleted file mode 100644 index 671e197e..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatedEvent/account.md +++ /dev/null @@ -1,33 +0,0 @@ - - - -# account property - - - - - *[](https://dart.dev/null-safety)* - - - -[Account](../../wyatt_authentication_bloc/Account-class.md) account - -_final_ - - - - - - -## Implementation - -```dart -final Account account; -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatedEvent/props.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatedEvent/props.md deleted file mode 100644 index fbde09d1..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/UpdatedEvent/props.md +++ /dev/null @@ -1,42 +0,0 @@ - - - -# props property - - - - - *[](https://dart.dev/null-safety)* - - - - - -**Annotations** - -- @[override](https://api.flutter.dev/flutter/dart-core/override-constant.html) -[List](https://api.flutter.dev/flutter/dart-core/List-class.html)<[Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)?> props - -_override_ - - - -

The list of properties that will be used to determine whether -two instances are equal.

- - - -## Implementation - -```dart -@override -List get props => [account]; -``` - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/VerifyPasswordResetCodeFailureFirebase-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/VerifyPasswordResetCodeFailureFirebase-class.md deleted file mode 100644 index 3a40b1bd..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/VerifyPasswordResetCodeFailureFirebase-class.md +++ /dev/null @@ -1,137 +0,0 @@ - - - -# VerifyPasswordResetCodeFailureFirebase class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown during the password reset process if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- [VerifyPasswordResetCodeFailureInterface](../wyatt_authentication_bloc/VerifyPasswordResetCodeFailureInterface-class.md) -- VerifyPasswordResetCodeFailureFirebase - - - - - - - - -## Constructors - -[VerifyPasswordResetCodeFailureFirebase](../wyatt_authentication_bloc/VerifyPasswordResetCodeFailureFirebase/VerifyPasswordResetCodeFailureFirebase.md) ([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - -[VerifyPasswordResetCodeFailureFirebase.fromCode](../wyatt_authentication_bloc/VerifyPasswordResetCodeFailureFirebase/VerifyPasswordResetCodeFailureFirebase.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/VerifyPasswordResetCodeFailureFirebase/VerifyPasswordResetCodeFailureFirebase.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/VerifyPasswordResetCodeFailureFirebase/VerifyPasswordResetCodeFailureFirebase.fromCode.md deleted file mode 100644 index 7b721f98..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/VerifyPasswordResetCodeFailureFirebase/VerifyPasswordResetCodeFailureFirebase.fromCode.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# VerifyPasswordResetCodeFailureFirebase.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -VerifyPasswordResetCodeFailureFirebase.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - - - - -## Implementation - -```dart -VerifyPasswordResetCodeFailureFirebase.fromCode(super.code) - : super.fromCode(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/VerifyPasswordResetCodeFailureFirebase/VerifyPasswordResetCodeFailureFirebase.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/VerifyPasswordResetCodeFailureFirebase/VerifyPasswordResetCodeFailureFirebase.md deleted file mode 100644 index 22f49092..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/VerifyPasswordResetCodeFailureFirebase/VerifyPasswordResetCodeFailureFirebase.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# VerifyPasswordResetCodeFailureFirebase constructor - - - - - *[](https://dart.dev/null-safety)* - - - -VerifyPasswordResetCodeFailureFirebase([[String](https://api.flutter.dev/flutter/dart-core/String-class.html)? code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html)? msg]) - - - - - -## Implementation - -```dart -VerifyPasswordResetCodeFailureFirebase([String? code, String? msg]) - : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/VerifyPasswordResetCodeFailureInterface-class.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/VerifyPasswordResetCodeFailureInterface-class.md deleted file mode 100644 index 47e2e9b2..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/VerifyPasswordResetCodeFailureInterface-class.md +++ /dev/null @@ -1,139 +0,0 @@ - - - -# VerifyPasswordResetCodeFailureInterface class - - - - - - - *[](https://dart.dev/null-safety)* - - - -

Thrown during the password reset process if a failure occurs.

- - - -**Inheritance** - -- [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) -- [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) -- VerifyPasswordResetCodeFailureInterface - - - -**Implementers** - -- [VerifyPasswordResetCodeFailureFirebase](../wyatt_authentication_bloc/VerifyPasswordResetCodeFailureFirebase-class.md) - - - - - -## Constructors - -[VerifyPasswordResetCodeFailureInterface](../wyatt_authentication_bloc/VerifyPasswordResetCodeFailureInterface/VerifyPasswordResetCodeFailureInterface.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - -Thrown during the password reset process if a failure occurs. - -[VerifyPasswordResetCodeFailureInterface.fromCode](../wyatt_authentication_bloc/VerifyPasswordResetCodeFailureInterface/VerifyPasswordResetCodeFailureInterface.fromCode.md) ([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - -Thrown during the password reset process if a failure occurs. - - -## Properties - -##### [code](../wyatt_authentication_bloc/AuthenticationFailureInterface/code.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [hashCode](https://api.flutter.dev/flutter/dart-core/Object/hashCode.html) → [int](https://api.flutter.dev/flutter/dart-core/int-class.html) - - - -The hash code for this object. -_read-onlyinherited_ - - - -##### [message](../wyatt_authentication_bloc/AuthenticationFailureInterface/message.md) → [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read-onlyinherited_ - - - -##### [msg](../wyatt_authentication_bloc/AuthenticationFailureInterface/msg.md) ↔ [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - - -_read / writeinherited_ - - - -##### [runtimeType](https://api.flutter.dev/flutter/dart-core/Object/runtimeType.html) → [Type](https://api.flutter.dev/flutter/dart-core/Type-class.html) - - - -A representation of the runtime type of the object. -_read-onlyinherited_ - - - - - -## Methods - -##### [noSuchMethod](https://api.flutter.dev/flutter/dart-core/Object/noSuchMethod.html)([Invocation](https://api.flutter.dev/flutter/dart-core/Invocation-class.html) invocation) dynamic - - - -Invoked when a non-existent method or property is accessed. -_inherited_ - - - -##### [toString](../wyatt_authentication_bloc/AuthenticationFailureInterface/toString.md)() [String](https://api.flutter.dev/flutter/dart-core/String-class.html) - - - -A string representation of this object. -_inherited_ - - - - - -## Operators - -##### [operator ==](https://api.flutter.dev/flutter/dart-core/Object/operator_equals.html)([Object](https://api.flutter.dev/flutter/dart-core/Object-class.html) other) [bool](https://api.flutter.dev/flutter/dart-core/bool-class.html) - - - -The equality operator. -_inherited_ - - - - - - - - - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/VerifyPasswordResetCodeFailureInterface/VerifyPasswordResetCodeFailureInterface.fromCode.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/VerifyPasswordResetCodeFailureInterface/VerifyPasswordResetCodeFailureInterface.fromCode.md deleted file mode 100644 index ed57be88..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/VerifyPasswordResetCodeFailureInterface/VerifyPasswordResetCodeFailureInterface.fromCode.md +++ /dev/null @@ -1,32 +0,0 @@ - - - -# VerifyPasswordResetCodeFailureInterface.fromCode constructor - - - - - *[](https://dart.dev/null-safety)* - - - -VerifyPasswordResetCodeFailureInterface.fromCode([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code) - - -

Thrown during the password reset process if a failure occurs.

- - - -## Implementation - -```dart -VerifyPasswordResetCodeFailureInterface.fromCode(super.code) - : super.fromCode(); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/VerifyPasswordResetCodeFailureInterface/VerifyPasswordResetCodeFailureInterface.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/VerifyPasswordResetCodeFailureInterface/VerifyPasswordResetCodeFailureInterface.md deleted file mode 100644 index e03ad3b7..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/VerifyPasswordResetCodeFailureInterface/VerifyPasswordResetCodeFailureInterface.md +++ /dev/null @@ -1,31 +0,0 @@ - - - -# VerifyPasswordResetCodeFailureInterface constructor - - - - - *[](https://dart.dev/null-safety)* - - - -VerifyPasswordResetCodeFailureInterface([String](https://api.flutter.dev/flutter/dart-core/String-class.html) code, [String](https://api.flutter.dev/flutter/dart-core/String-class.html) msg) - - -

Thrown during the password reset process if a failure occurs.

- - - -## Implementation - -```dart -VerifyPasswordResetCodeFailureInterface(super.code, super.msg); -``` - - - - - - - diff --git a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/wyatt_authentication_bloc-library.md b/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/wyatt_authentication_bloc-library.md deleted file mode 100644 index 46d7f563..00000000 --- a/packages/wyatt_authentication_bloc/doc/api/wyatt_authentication_bloc/wyatt_authentication_bloc-library.md +++ /dev/null @@ -1,727 +0,0 @@ - - - - -# wyatt_authentication_bloc library - - - - - - - *[](https://dart.dev/null-safety)* - - - -

An authentication library for BLoC.

- - -## Classes - -##### [Account](../wyatt_authentication_bloc/Account-class.md) - - - -Represents a user Account in the -various identity provisioning systems. - - -##### [AccountModel](../wyatt_authentication_bloc/AccountModel-class.md) - - - -Account Model to parse Firebase User data - - -##### [AuthenticationBuilder](../wyatt_authentication_bloc/AuthenticationBuilder-class.md)<Data> - - - - - - -##### [AuthenticationChangeEvent](../wyatt_authentication_bloc/AuthenticationChangeEvent-class.md) - - - -Represents an event initiated by a change in -the user's authentication status. - - -##### [AuthenticationCubit](../wyatt_authentication_bloc/AuthenticationCubit-class.md)<Data> - - - -Abstract authentication cubit class needs to be implemented in application. - - -##### [AuthenticationFirebaseDataSourceImpl](../wyatt_authentication_bloc/AuthenticationFirebaseDataSourceImpl-class.md)<Data> - - - - - - -##### [AuthenticationRemoteDataSource](../wyatt_authentication_bloc/AuthenticationRemoteDataSource-class.md)<Data> - - - -Is responsible for abstracting the provenance of the data. - - -##### [AuthenticationRepository](../wyatt_authentication_bloc/AuthenticationRepository-class.md)<Data> - - - - - - -##### [AuthenticationRepositoryImpl](../wyatt_authentication_bloc/AuthenticationRepositoryImpl-class.md)<Data extends [Object](https://api.flutter.dev/flutter/dart-core/Object-class.html)> - - - - - - -##### [AuthenticationState](../wyatt_authentication_bloc/AuthenticationState-class.md)<Data> - - - - - - -##### [AuthFormField](../wyatt_authentication_bloc/AuthFormField-class.md) - - - -Default authentication form fields name - - -##### [AuthFormName](../wyatt_authentication_bloc/AuthFormName-class.md) - - - -Default authentication form name - - -##### [BaseEditAccountCubit](../wyatt_authentication_bloc/BaseEditAccountCubit-class.md)<Data> - - - -Abstract edit account cubit useful for implementing a cubit with fine -granularity by adding only the required mixins. - - -##### [BaseSignInCubit](../wyatt_authentication_bloc/BaseSignInCubit-class.md)<Data> - - - -Abstract sign in cubit useful for implementing a cubit with fine -granularity by adding only the required mixins. - - -##### [BaseSignUpCubit](../wyatt_authentication_bloc/BaseSignUpCubit-class.md)<Data> - - - -Abstract sign up cubit useful for implementing a cubit with fine -granularity by adding only the required mixins. - - -##### [CustomRoutine](../wyatt_authentication_bloc/CustomRoutine-class.md)<R, Data> - - - -Calls on each cubit action of this package. - - -##### [DeletedEvent](../wyatt_authentication_bloc/DeletedEvent-class.md) - - - -When a user deleted his account. - - -##### [EditAccountCubit](../wyatt_authentication_bloc/EditAccountCubit-class.md)<Data> - - - -Fully featured edit account cubit. - - -##### [EditAccountListener](../wyatt_authentication_bloc/EditAccountListener-class.md)<Data> - - - -Widget that listens and builds a child based on the state of -the edit account cubit - - -##### [EditAccountState](../wyatt_authentication_bloc/EditAccountState-class.md) - - - -Edit account cubit state to manage the form. - - -##### [EmailVerificationBuilder](../wyatt_authentication_bloc/EmailVerificationBuilder-class.md)<Extra> - - - - - - -##### [EmailVerificationCubit](../wyatt_authentication_bloc/EmailVerificationCubit-class.md)<Data> - - - - - - -##### [EmailVerificationState](../wyatt_authentication_bloc/EmailVerificationState-class.md) - - - - - - -##### [PasswordResetCubit](../wyatt_authentication_bloc/PasswordResetCubit-class.md)<Extra> - - - -Cubit that allows user to reset his password - - -##### [PasswordResetState](../wyatt_authentication_bloc/PasswordResetState-class.md) - - - - - - -##### [ReauthenticatedEvent](../wyatt_authentication_bloc/ReauthenticatedEvent-class.md) - - - -When a user re-authenticates (from the logged in state to the -logged in state with a different and fresh access -token and a different login time) - - -##### [RefreshedEvent](../wyatt_authentication_bloc/RefreshedEvent-class.md) - - - -When a user access token is refreshed (from the logged in state to the -logged in state with a different access token) - - -##### [Session](../wyatt_authentication_bloc/Session-class.md)<Data> - - - -The Session object is used to transport and propagate -the connected user Account and personalized Data in the application. - - -##### [SessionWrapper](../wyatt_authentication_bloc/SessionWrapper-class.md)<Data> - - - -Contains the AuthenticationChangeEvent initiating the state -change and the current Session. - - -##### [SignedInEvent](../wyatt_authentication_bloc/SignedInEvent-class.md) - - - -When a user authenticates (from not logged in to logged in). - - -##### [SignedInFromCacheEvent](../wyatt_authentication_bloc/SignedInFromCacheEvent-class.md) - - - -When a user authenticates automatically (from not logged in to logged in). - - -##### [SignedOutEvent](../wyatt_authentication_bloc/SignedOutEvent-class.md) - - - -When a user logs out. - - -##### [SignedUpEvent](../wyatt_authentication_bloc/SignedUpEvent-class.md) - - - -When a user creates an account. - - -##### [SignInCubit](../wyatt_authentication_bloc/SignInCubit-class.md)<Data> - - - -Fully featured sign in cubit. - - -##### [SignInListener](../wyatt_authentication_bloc/SignInListener-class.md)<Data> - - - -Widget that listens and builds a child based on the state of -the sign in cubit - - -##### [SignInState](../wyatt_authentication_bloc/SignInState-class.md) - - - -Sign in cubit state to manage the form. - - -##### [SignUpCubit](../wyatt_authentication_bloc/SignUpCubit-class.md)<Data> - - - -Fully featured sign up cubit. - - -##### [SignUpListener](../wyatt_authentication_bloc/SignUpListener-class.md)<Data> - - - -Widget that listens and builds a child based on the state of -the sign up cubit - - -##### [SignUpState](../wyatt_authentication_bloc/SignUpState-class.md) - - - -Sign up cubit state to manage the form. - - -##### [UnknownAuthenticationEvent](../wyatt_authentication_bloc/UnknownAuthenticationEvent-class.md) - - - -When a user's login status is unknown. - - -##### [UpdatedEvent](../wyatt_authentication_bloc/UpdatedEvent-class.md) - - - -When the user's account has been updated. - - - -## Mixins - -##### [SignInAnonymously](../wyatt_authentication_bloc/SignInAnonymously-mixin.md)<Data> - - - -Sign in mixin. - - -##### [SignInWithEmailPassword](../wyatt_authentication_bloc/SignInWithEmailPassword-mixin.md)<Data> - - - -Sign in mixin. - - -##### [SignInWithGoogle](../wyatt_authentication_bloc/SignInWithGoogle-mixin.md)<Data> - - - -Sign in mixin. - - -##### [SignUpWithEmailPassword](../wyatt_authentication_bloc/SignUpWithEmailPassword-mixin.md)<Data> - - - -Sign up mixin. - - -##### [UpdateEmail](../wyatt_authentication_bloc/UpdateEmail-mixin.md)<Data> - - - -Edit account mixin. - - -##### [UpdatePassword](../wyatt_authentication_bloc/UpdatePassword-mixin.md)<Data> - - - -Edit account mixin. - - - -## Extensions - -##### [BuildContextExtension](../wyatt_authentication_bloc/BuildContextExtension.md) - - - -Extension that helps to quickly access useful resources like wrapper, -session, account or data. - - - - - - -## Enums - -##### [AuthenticationStatus](../wyatt_authentication_bloc/AuthenticationStatus.md) - - - -Different authentication status - - - - -## Exceptions / Errors - -##### [ApplyActionCodeFailureFirebase](../wyatt_authentication_bloc/ApplyActionCodeFailureFirebase-class.md) - - - -Thrown if during the apply action code process if a failure occurs. - - -##### [ApplyActionCodeFailureInterface](../wyatt_authentication_bloc/ApplyActionCodeFailureInterface-class.md) - - - -Thrown if during the apply action code process if a failure occurs. - - -##### [AuthenticationFailureInterface](../wyatt_authentication_bloc/AuthenticationFailureInterface-class.md) - - - -Base exception used in Wyatt Authentication - - -##### [ConfirmPasswordResetFailureFirebase](../wyatt_authentication_bloc/ConfirmPasswordResetFailureFirebase-class.md) - - - -Thrown during the password reset process if a failure occurs. - - -##### [ConfirmPasswordResetFailureInterface](../wyatt_authentication_bloc/ConfirmPasswordResetFailureInterface-class.md) - - - -Thrown during the password reset process if a failure occurs. - - -##### [DeleteAccountFailureFirebase](../wyatt_authentication_bloc/DeleteAccountFailureFirebase-class.md) - - - -Thrown during the account deletion if a failure occurs. - - -##### [DeleteAccountFailureInterface](../wyatt_authentication_bloc/DeleteAccountFailureInterface-class.md) - - - -Thrown during the account deletion if a failure occurs. - - -##### [FetchSignInMethodsForEmailFailureFirebase](../wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureFirebase-class.md) - - - -Thrown during the fetch sign in methods if a failure occurs. - - -##### [FetchSignInMethodsForEmailFailureInterface](../wyatt_authentication_bloc/FetchSignInMethodsForEmailFailureInterface-class.md) - - - -Thrown during the fetch sign in methods if a failure occurs. - - -##### [ModelParsingFailureFirebase](../wyatt_authentication_bloc/ModelParsingFailureFirebase-class.md) - - - -Thrown during the model parsing process if a failure occurs. - - -##### [ModelParsingFailureInterface](../wyatt_authentication_bloc/ModelParsingFailureInterface-class.md) - - - -Thrown during the model parsing process if a failure occurs. - - -##### [ReauthenticateFailureFirebase](../wyatt_authentication_bloc/ReauthenticateFailureFirebase-class.md) - - - -Thrown during the reauthentication process if a failure occurs. - - -##### [ReauthenticateFailureInterface](../wyatt_authentication_bloc/ReauthenticateFailureInterface-class.md) - - - -Thrown during the reauthentication process if a failure occurs. - - -##### [RefreshFailureFirebase](../wyatt_authentication_bloc/RefreshFailureFirebase-class.md) - - - -Thrown during the refresh process if a failure occurs. - - -##### [RefreshFailureInterface](../wyatt_authentication_bloc/RefreshFailureInterface-class.md) - - - -Thrown during the refresh process if a failure occurs. - - -##### [SendEmailVerificationFailureFirebase](../wyatt_authentication_bloc/SendEmailVerificationFailureFirebase-class.md) - - - -Thrown during the email verification process if a failure occurs. - - -##### [SendEmailVerificationFailureInterface](../wyatt_authentication_bloc/SendEmailVerificationFailureInterface-class.md) - - - -Thrown during the email verification process if a failure occurs. - - -##### [SendPasswordResetEmailFailureFirebase](../wyatt_authentication_bloc/SendPasswordResetEmailFailureFirebase-class.md) - - - -Thrown during the password reset process if a failure occurs. - - -##### [SendPasswordResetEmailFailureInterface](../wyatt_authentication_bloc/SendPasswordResetEmailFailureInterface-class.md) - - - -Thrown during the password reset process if a failure occurs. - - -##### [SendSignInLinkEmailFailureFirebase](../wyatt_authentication_bloc/SendSignInLinkEmailFailureFirebase-class.md) - - - -Thrown during the sign in link process if a failure occurs. - - -##### [SendSignInLinkEmailFailureInterface](../wyatt_authentication_bloc/SendSignInLinkEmailFailureInterface-class.md) - - - -Thrown during the sign in link process if a failure occurs. - - -##### [SignInAnonymouslyFailureFirebase](../wyatt_authentication_bloc/SignInAnonymouslyFailureFirebase-class.md) - - - -Thrown during the sign in process if a failure occurs. - - -##### [SignInAnonymouslyFailureInterface](../wyatt_authentication_bloc/SignInAnonymouslyFailureInterface-class.md) - - - -Thrown during the sign in process if a failure occurs. - - -##### [SignInWithAppleFailureFirebase](../wyatt_authentication_bloc/SignInWithAppleFailureFirebase-class.md) - - - -Thrown during the sign in process if a failure occurs. - - -##### [SignInWithAppleFailureInterface](../wyatt_authentication_bloc/SignInWithAppleFailureInterface-class.md) - - - -Thrown during the sign in process if a failure occurs. - - -##### [SignInWithCredentialFailureFirebase](../wyatt_authentication_bloc/SignInWithCredentialFailureFirebase-class.md) - - - -Thrown during the sign in process if a failure occurs. - - -##### [SignInWithCredentialFailureInterface](../wyatt_authentication_bloc/SignInWithCredentialFailureInterface-class.md) - - - -Thrown during the sign in process if a failure occurs. - - -##### [SignInWithEmailAndPasswordFailureFirebase](../wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureFirebase-class.md) - - - -Thrown during the sign in process if a failure occurs. - - -##### [SignInWithEmailAndPasswordFailureInterface](../wyatt_authentication_bloc/SignInWithEmailAndPasswordFailureInterface-class.md) - - - -Thrown during the sign in process if a failure occurs. - - -##### [SignInWithEmailLinkFailureFirebase](../wyatt_authentication_bloc/SignInWithEmailLinkFailureFirebase-class.md) - - - -Thrown during the sign in process if a failure occurs. - - -##### [SignInWithEmailLinkFailureInterface](../wyatt_authentication_bloc/SignInWithEmailLinkFailureInterface-class.md) - - - -Thrown during the sign in process if a failure occurs. - - -##### [SignInWithFacebookFailureFirebase](../wyatt_authentication_bloc/SignInWithFacebookFailureFirebase-class.md) - - - -Thrown during the sign in process if a failure occurs. - - -##### [SignInWithFacebookFailureInterface](../wyatt_authentication_bloc/SignInWithFacebookFailureInterface-class.md) - - - -Thrown during the sign in process if a failure occurs. - - -##### [SignInWithGoogleFailureFirebase](../wyatt_authentication_bloc/SignInWithGoogleFailureFirebase-class.md) - - - -Thrown during the sign in process if a failure occurs. - - -##### [SignInWithGoogleFailureInterface](../wyatt_authentication_bloc/SignInWithGoogleFailureInterface-class.md) - - - -Thrown during the sign in process if a failure occurs. - - -##### [SignInWithTwitterFailureFirebase](../wyatt_authentication_bloc/SignInWithTwitterFailureFirebase-class.md) - - - -Thrown during the sign in process if a failure occurs. - - -##### [SignInWithTwitterFailureInterface](../wyatt_authentication_bloc/SignInWithTwitterFailureInterface-class.md) - - - -Thrown during the sign in process if a failure occurs. - - -##### [SignOutFailureFirebase](../wyatt_authentication_bloc/SignOutFailureFirebase-class.md) - - - -Thrown during the sign out process if a failure occurs. - - -##### [SignOutFailureInterface](../wyatt_authentication_bloc/SignOutFailureInterface-class.md) - - - -Thrown during the sign out process if a failure occurs. - - -##### [SignUpWithEmailAndPasswordFailureFirebase](../wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureFirebase-class.md) - - - -Thrown if during the sign up process if a failure occurs. - - -##### [SignUpWithEmailAndPasswordFailureInterface](../wyatt_authentication_bloc/SignUpWithEmailAndPasswordFailureInterface-class.md) - - - -Thrown if during the sign up process if a failure occurs. - - -##### [UpdateEmailFailureFirebase](../wyatt_authentication_bloc/UpdateEmailFailureFirebase-class.md) - - - -Thrown during the email modification process if a failure occurs. - - -##### [UpdateEmailFailureInterface](../wyatt_authentication_bloc/UpdateEmailFailureInterface-class.md) - - - -Thrown during the email modification process if a failure occurs. - - -##### [UpdatePasswordFailureFirebase](../wyatt_authentication_bloc/UpdatePasswordFailureFirebase-class.md) - - - -Thrown during the password modification process if a failure occurs. - - -##### [UpdatePasswordFailureInterface](../wyatt_authentication_bloc/UpdatePasswordFailureInterface-class.md) - - - -Thrown during the password modification process if a failure occurs. - - -##### [VerifyPasswordResetCodeFailureFirebase](../wyatt_authentication_bloc/VerifyPasswordResetCodeFailureFirebase-class.md) - - - -Thrown during the password reset process if a failure occurs. - - -##### [VerifyPasswordResetCodeFailureInterface](../wyatt_authentication_bloc/VerifyPasswordResetCodeFailureInterface-class.md) - - - -Thrown during the password reset process if a failure occurs. - - - - - - - diff --git a/packages/wyatt_authentication_bloc/example/lib/core/dependency_injection/get_it.dart b/packages/wyatt_authentication_bloc/example/lib/core/dependency_injection/get_it.dart index a4833f56..2961e7cb 100644 --- a/packages/wyatt_authentication_bloc/example/lib/core/dependency_injection/get_it.dart +++ b/packages/wyatt_authentication_bloc/example/lib/core/dependency_injection/get_it.dart @@ -19,8 +19,10 @@ import 'dart:async'; import 'package:example_router/core/enums/dev_mode.dart'; import 'package:example_router/core/flavors/flavor.dart'; import 'package:example_router/firebase_options.dart'; +import 'package:firebase_auth/firebase_auth.dart'; import 'package:firebase_core/firebase_core.dart'; import 'package:get_it/get_it.dart'; +import 'package:google_sign_in/google_sign_in.dart'; import 'package:wyatt_authentication_bloc/wyatt_authentication_bloc.dart'; final getIt = GetIt.I; diff --git a/packages/wyatt_authentication_bloc/example/pubspec.yaml b/packages/wyatt_authentication_bloc/example/pubspec.yaml index 28001220..e1fbdb31 100644 --- a/packages/wyatt_authentication_bloc/example/pubspec.yaml +++ b/packages/wyatt_authentication_bloc/example/pubspec.yaml @@ -33,6 +33,8 @@ dependencies: go_router: ^5.1.5 firebase_core: ^2.1.1 flutter_bloc: ^8.1.1 + firebase_auth: ^4.2.0 + google_sign_in: ^5.4.2 get_it: ^7.2.0 wyatt_authentication_bloc: diff --git a/packages/wyatt_authentication_bloc/lib/src/core/constants/storage.dart b/packages/wyatt_authentication_bloc/lib/src/core/constants/storage.dart index e3875066..5211fe72 100644 --- a/packages/wyatt_authentication_bloc/lib/src/core/constants/storage.dart +++ b/packages/wyatt_authentication_bloc/lib/src/core/constants/storage.dart @@ -14,9 +14,17 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . +/// Default name for storage keys abstract class AuthStorage { + /// Refresh token, `wyattRefreshToken` static const String refreshToken = 'wyattRefreshToken'; + + /// Access token, `wyattAccessToken` static const String accessToken = 'wyattAccessToken'; + + /// User email, `wyattEmail` static const String email = 'wyattEmail'; + + /// User id, `wyattId` static const String id = 'wyattId'; } diff --git a/packages/wyatt_authentication_bloc/lib/src/data/data_sources/local/authentication_firebase_cache_data_source_impl.dart b/packages/wyatt_authentication_bloc/lib/src/data/data_sources/local/authentication_firebase_cache_data_source_impl.dart index 910887c2..53aef590 100644 --- a/packages/wyatt_authentication_bloc/lib/src/data/data_sources/local/authentication_firebase_cache_data_source_impl.dart +++ b/packages/wyatt_authentication_bloc/lib/src/data/data_sources/local/authentication_firebase_cache_data_source_impl.dart @@ -14,7 +14,7 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . -import 'package:wyatt_authentication_bloc/src/domain/data_sources/local/authentication_cache_data_source.dart'; +import 'package:firebase_auth/firebase_auth.dart'; import 'package:wyatt_authentication_bloc/wyatt_authentication_bloc.dart'; /// {@template authentication_firebase_cache_data_source_impl} diff --git a/packages/wyatt_authentication_bloc/lib/wyatt_authentication_bloc.dart b/packages/wyatt_authentication_bloc/lib/wyatt_authentication_bloc.dart index b8c28dca..4ed48bd0 100644 --- a/packages/wyatt_authentication_bloc/lib/wyatt_authentication_bloc.dart +++ b/packages/wyatt_authentication_bloc/lib/wyatt_authentication_bloc.dart @@ -17,7 +17,4 @@ /// An authentication library for BLoC. library wyatt_authentication_bloc; -export 'package:firebase_auth/firebase_auth.dart'; -export 'package:google_sign_in/google_sign_in.dart'; - export 'src/src.dart'; diff --git a/packages/wyatt_authentication_bloc/pubspec.yaml b/packages/wyatt_authentication_bloc/pubspec.yaml index 429aa524..6c8e1f57 100644 --- a/packages/wyatt_authentication_bloc/pubspec.yaml +++ b/packages/wyatt_authentication_bloc/pubspec.yaml @@ -39,4 +39,4 @@ dev_dependencies: wyatt_analysis: hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub/ - version: 2.4.1 + version: ^2.4.1 -- 2.47.2 From 6152436411ecce038526e1212ea32aab460cc7c3 Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Thu, 13 Apr 2023 23:44:25 +0200 Subject: [PATCH 46/47] test(auth): fix mock --- .../test/authentication/authentication_cubit_test.dart | 3 +++ 1 file changed, 3 insertions(+) diff --git a/packages/wyatt_authentication_bloc/test/authentication/authentication_cubit_test.dart b/packages/wyatt_authentication_bloc/test/authentication/authentication_cubit_test.dart index f5c26033..5469c51b 100644 --- a/packages/wyatt_authentication_bloc/test/authentication/authentication_cubit_test.dart +++ b/packages/wyatt_authentication_bloc/test/authentication/authentication_cubit_test.dart @@ -67,6 +67,9 @@ void main() { when(() => authenticationRepository.sessionStream()).thenAnswer( (_) => const Stream.empty(), ); + when(() => authenticationRepository.checkForCachedAccount()).thenAnswer( + (_) => Future.value(), + ); }); test('initial auth state is `unknown`', () { -- 2.47.2 From b427aff63d74aa6f715bc7809eb1289eb75f4785 Mon Sep 17 00:00:00 2001 From: Hugo Pointcheval Date: Thu, 13 Apr 2023 23:47:19 +0200 Subject: [PATCH 47/47] style: dart format fix --- .../authentication/authentication_cubit.dart | 11 ++++---- .../sign_in/blocs/sign_in_cubit.dart | 7 +++--- .../sign_up/blocs/sign_up_cubit.dart | 3 ++- .../blocs/edit_account_cubit.dart | 5 ++-- .../src/core/exceptions/exceptions_mock.dart | 24 ++++++------------ .../email_verification_cubit_test.dart | 4 +-- .../password_reset_cubit_test.dart | 2 +- .../test/sign_in/sign_in_cubit_test.dart | 4 +-- .../test/sign_up/sign_up_cubit_test.dart | 2 +- .../lib/src/core/mixins/operation.dart | 12 ++++++--- .../wyatt_http_client/lib/src/pipeline.dart | 2 +- .../bars/widgets/navigation_item.dart | 25 ++++++++++--------- 12 files changed, 51 insertions(+), 50 deletions(-) diff --git a/packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/authentication_cubit.dart b/packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/authentication_cubit.dart index ba34a213..04153f31 100644 --- a/packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/authentication_cubit.dart +++ b/packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/authentication_cubit.dart @@ -14,6 +14,7 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . +import 'package:flutter/foundation.dart'; import 'package:wyatt_architecture/wyatt_architecture.dart'; import 'package:wyatt_authentication_bloc/wyatt_authentication_bloc.dart'; import 'package:wyatt_type_utils/wyatt_type_utils.dart'; @@ -24,35 +25,35 @@ class ExampleAuthenticationCubit extends AuthenticationCubit { @override FutureOrResult onReauthenticate( Result result) async { - print('onReauthenticate'); + debugPrint('onReauthenticate'); return const Ok(1); } @override FutureOrResult onRefresh(Result result) { - print('onRefresh'); + debugPrint('onRefresh'); return const Ok(1); } @override FutureOrResult onSignInFromCache(AuthenticationSession session) { - print('onSignInFromCache'); + debugPrint('onSignInFromCache'); return const Ok(1); } @override FutureOrResult onSignOut() { - print('onSignOut'); + debugPrint('onSignOut'); return const Ok(null); } @override FutureOrResult onDelete() { - print('onDelete'); + debugPrint('onDelete'); return const Ok(null); } diff --git a/packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/sign_in/blocs/sign_in_cubit.dart b/packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/sign_in/blocs/sign_in_cubit.dart index f8ad2ba2..0b391624 100644 --- a/packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/sign_in/blocs/sign_in_cubit.dart +++ b/packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/sign_in/blocs/sign_in_cubit.dart @@ -14,6 +14,7 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . +import 'package:flutter/foundation.dart'; import 'package:wyatt_architecture/wyatt_architecture.dart'; import 'package:wyatt_authentication_bloc/wyatt_authentication_bloc.dart'; import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; @@ -27,7 +28,7 @@ class ExampleSignInCubit extends SignInCubit { @override FutureOrResult onSignInWithEmailAndPassword( Result result, WyattForm form) { - print('onSignInWithEmailAndPassword: ${result.ok?.accessToken}'); + debugPrint('onSignInWithEmailAndPassword: ${result.ok?.accessToken}'); return const Ok(1); } @@ -35,7 +36,7 @@ class ExampleSignInCubit extends SignInCubit { @override FutureOrResult onSignInAnonymously( Result result, WyattForm form) { - print('onSignInAnonymously'); + debugPrint('onSignInAnonymously'); return const Ok(1); } @@ -43,7 +44,7 @@ class ExampleSignInCubit extends SignInCubit { @override FutureOrResult onSignInWithGoogle( Result result, WyattForm form) { - print('onSignInWithGoogle'); + debugPrint('onSignInWithGoogle'); return const Ok(1); } diff --git a/packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/sign_up/blocs/sign_up_cubit.dart b/packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/sign_up/blocs/sign_up_cubit.dart index 3f5bb9a1..93c4509e 100644 --- a/packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/sign_up/blocs/sign_up_cubit.dart +++ b/packages/wyatt_authentication_bloc/example/lib/presentation/features/authentication/sign_up/blocs/sign_up_cubit.dart @@ -14,6 +14,7 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . +import 'package:flutter/foundation.dart'; import 'package:wyatt_architecture/wyatt_architecture.dart'; import 'package:wyatt_authentication_bloc/wyatt_authentication_bloc.dart'; import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; @@ -27,7 +28,7 @@ class ExampleSignUpCubit extends SignUpCubit { @override FutureOrResult onSignUpWithEmailAndPassword( Result result, WyattForm form) async { - print('onSignUpWithEmailAndPassword'); + debugPrint('onSignUpWithEmailAndPassword'); return const Ok(1); } diff --git a/packages/wyatt_authentication_bloc/example/lib/presentation/features/edit_account/blocs/edit_account_cubit.dart b/packages/wyatt_authentication_bloc/example/lib/presentation/features/edit_account/blocs/edit_account_cubit.dart index 1a5d2b8c..ae964202 100644 --- a/packages/wyatt_authentication_bloc/example/lib/presentation/features/edit_account/blocs/edit_account_cubit.dart +++ b/packages/wyatt_authentication_bloc/example/lib/presentation/features/edit_account/blocs/edit_account_cubit.dart @@ -14,6 +14,7 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . +import 'package:flutter/foundation.dart'; import 'package:wyatt_architecture/wyatt_architecture.dart'; import 'package:wyatt_authentication_bloc/wyatt_authentication_bloc.dart'; import 'package:wyatt_form_bloc/wyatt_form_bloc.dart'; @@ -25,7 +26,7 @@ class ExampleEditAccountCubit extends EditAccountCubit { @override FutureOrResult onEmailUpdated( Result result, WyattForm form) async { - print('onEmailUpdated'); + debugPrint('onEmailUpdated'); return const Ok(1); } @@ -33,7 +34,7 @@ class ExampleEditAccountCubit extends EditAccountCubit { @override FutureOrResult onPasswordUpdated( Result result, WyattForm form) async { - print('onPasswordUpdated'); + debugPrint('onPasswordUpdated'); return const Ok(1); } diff --git a/packages/wyatt_authentication_bloc/lib/src/core/exceptions/exceptions_mock.dart b/packages/wyatt_authentication_bloc/lib/src/core/exceptions/exceptions_mock.dart index ad8b6826..57a960e4 100644 --- a/packages/wyatt_authentication_bloc/lib/src/core/exceptions/exceptions_mock.dart +++ b/packages/wyatt_authentication_bloc/lib/src/core/exceptions/exceptions_mock.dart @@ -91,12 +91,10 @@ class FetchSignInMethodsForEmailFailureMock } /// {@macro sign_in_anonymously_failure} -class SignInAnonymouslyFailureMock - extends SignInAnonymouslyFailureInterface { +class SignInAnonymouslyFailureMock extends SignInAnonymouslyFailureInterface { SignInAnonymouslyFailureMock([String? code, String? msg]) : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); - SignInAnonymouslyFailureMock.fromCode(String code) - : super.fromCode(code) { + SignInAnonymouslyFailureMock.fromCode(String code) : super.fromCode(code) { switch (code) { case 'operation-not-allowed': msg = 'Operation is not allowed. Please contact support.'; @@ -113,8 +111,7 @@ class SignInWithCredentialFailureMock extends SignInWithCredentialFailureInterface { SignInWithCredentialFailureMock([String? code, String? msg]) : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); - SignInWithCredentialFailureMock.fromCode(String code) - : super.fromCode(code) { + SignInWithCredentialFailureMock.fromCode(String code) : super.fromCode(code) { switch (code) { case 'account-exists-with-different-credential': msg = 'Account exists with different credentials.'; @@ -148,16 +145,14 @@ class SignInWithCredentialFailureMock } /// {@macro sign_in_with_google_failure} -class SignInWithGoogleFailureMock - extends SignInWithCredentialFailureMock +class SignInWithGoogleFailureMock extends SignInWithCredentialFailureMock implements SignInWithGoogleFailureInterface { SignInWithGoogleFailureMock([super.code, super.msg]); SignInWithGoogleFailureMock.fromCode(super.code) : super.fromCode(); } /// {@macro sign_in_with_facebook_failure} -class SignInWithFacebookFailureMock - extends SignInWithCredentialFailureMock +class SignInWithFacebookFailureMock extends SignInWithCredentialFailureMock implements SignInWithFacebookFailureInterface { SignInWithFacebookFailureMock([super.code, super.msg]); SignInWithFacebookFailureMock.fromCode(super.code) : super.fromCode(); @@ -171,8 +166,7 @@ class SignInWithAppleFailureMock extends SignInWithCredentialFailureMock } /// {@macro sign_in_with_twitter_failure} -class SignInWithTwitterFailureMock - extends SignInWithCredentialFailureMock +class SignInWithTwitterFailureMock extends SignInWithCredentialFailureMock implements SignInWithAppleFailureInterface { SignInWithTwitterFailureMock([super.code, super.msg]); SignInWithTwitterFailureMock.fromCode(super.code) : super.fromCode(); @@ -183,8 +177,7 @@ class SignInWithEmailLinkFailureMock extends SignInWithEmailLinkFailureInterface { SignInWithEmailLinkFailureMock([String? code, String? msg]) : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); - SignInWithEmailLinkFailureMock.fromCode(String code) - : super.fromCode(code) { + SignInWithEmailLinkFailureMock.fromCode(String code) : super.fromCode(code) { switch (code) { case 'expired-action-code': msg = 'Action code has expired.'; @@ -270,8 +263,7 @@ class VerifyPasswordResetCodeFailureMock VerifyPasswordResetCodeFailureMock([String? code, String? msg]) : super(code ?? 'unknown', msg ?? 'An unknown error occurred.'); - VerifyPasswordResetCodeFailureMock.fromCode(super.code) - : super.fromCode(); + VerifyPasswordResetCodeFailureMock.fromCode(super.code) : super.fromCode(); } /// {@macro refresh_failure} diff --git a/packages/wyatt_authentication_bloc/test/email_verification/email_verification_cubit_test.dart b/packages/wyatt_authentication_bloc/test/email_verification/email_verification_cubit_test.dart index c6b944c5..29e0c9b4 100644 --- a/packages/wyatt_authentication_bloc/test/email_verification/email_verification_cubit_test.dart +++ b/packages/wyatt_authentication_bloc/test/email_verification/email_verification_cubit_test.dart @@ -121,7 +121,7 @@ void main() { 'emits failure', setUp: () { when(() => authenticationRepository.sendEmailVerification()) - .thenAnswer((_) async => Err(ServerException('erreur'))); + .thenAnswer((_) async => const Err(ServerException('erreur'))); }, build: () => EmailVerificationCubit( authenticationRepository: authenticationRepository, @@ -222,7 +222,7 @@ void main() { 'emits failure on refresh error', setUp: () { when(() => authenticationRepository.refresh()) - .thenAnswer((_) async => Err(ServerException('erreur'))); + .thenAnswer((_) async => const Err(ServerException('erreur'))); }, build: () => EmailVerificationCubit( authenticationRepository: authenticationRepository, diff --git a/packages/wyatt_authentication_bloc/test/password_reset/password_reset_cubit_test.dart b/packages/wyatt_authentication_bloc/test/password_reset/password_reset_cubit_test.dart index a668a948..11c98b59 100644 --- a/packages/wyatt_authentication_bloc/test/password_reset/password_reset_cubit_test.dart +++ b/packages/wyatt_authentication_bloc/test/password_reset/password_reset_cubit_test.dart @@ -272,7 +272,7 @@ void main() { () => authenticationRepository.sendPasswordResetEmail( email: any(named: 'email'), ), - ).thenAnswer((_) async => Err(ServerException())); + ).thenAnswer((_) async => const Err(ServerException())); when( () => formRepository.accessForm(AuthFormName.passwordResetForm), ).thenAnswer( diff --git a/packages/wyatt_authentication_bloc/test/sign_in/sign_in_cubit_test.dart b/packages/wyatt_authentication_bloc/test/sign_in/sign_in_cubit_test.dart index 62d9d5b9..bc517187 100644 --- a/packages/wyatt_authentication_bloc/test/sign_in/sign_in_cubit_test.dart +++ b/packages/wyatt_authentication_bloc/test/sign_in/sign_in_cubit_test.dart @@ -435,7 +435,7 @@ void main() { email: any(named: 'email'), password: any(named: 'password'), ), - ).thenAnswer((_) async => Err(ServerException())); + ).thenAnswer((_) async => const Err(ServerException())); when( () => formRepository.accessForm(AuthFormName.signInForm), ).thenAnswer( @@ -615,7 +615,7 @@ void main() { setUp: () { when( () => authenticationRepository.signInAnonymously(), - ).thenAnswer((_) async => Err(ServerException())); + ).thenAnswer((_) async => const Err(ServerException())); }, build: () => SignInCubit( authenticationRepository: authenticationRepository, diff --git a/packages/wyatt_authentication_bloc/test/sign_up/sign_up_cubit_test.dart b/packages/wyatt_authentication_bloc/test/sign_up/sign_up_cubit_test.dart index 7524bc0b..d437c339 100644 --- a/packages/wyatt_authentication_bloc/test/sign_up/sign_up_cubit_test.dart +++ b/packages/wyatt_authentication_bloc/test/sign_up/sign_up_cubit_test.dart @@ -406,7 +406,7 @@ void main() { email: any(named: 'email'), password: any(named: 'password'), ), - ).thenAnswer((_) async => Err(ServerException())); + ).thenAnswer((_) async => const Err(ServerException())); when( () => formRepository.accessForm(AuthFormName.signUpForm), ).thenAnswer( diff --git a/packages/wyatt_crud_bloc/lib/src/core/mixins/operation.dart b/packages/wyatt_crud_bloc/lib/src/core/mixins/operation.dart index 7a1b9b09..dbfc08ff 100644 --- a/packages/wyatt_crud_bloc/lib/src/core/mixins/operation.dart +++ b/packages/wyatt_crud_bloc/lib/src/core/mixins/operation.dart @@ -18,13 +18,17 @@ import 'package:wyatt_architecture/wyatt_architecture.dart'; import 'package:wyatt_crud_bloc/src/domain/entities/object_model.dart'; /// Defines every write operation in CRUD. -mixin CreateOperation on AsyncUseCase {} +mixin CreateOperation + on AsyncUseCase {} /// Defines every read operation in CRUD. -mixin ReadOperation on AsyncUseCase {} +mixin ReadOperation + on AsyncUseCase {} /// Defines every update operation in CRUD. -mixin UpdateOperation on AsyncUseCase {} +mixin UpdateOperation + on AsyncUseCase {} /// Defines every delete operation in CRUD. -mixin DeleteOperation on AsyncUseCase {} +mixin DeleteOperation + on AsyncUseCase {} diff --git a/packages/wyatt_http_client/lib/src/pipeline.dart b/packages/wyatt_http_client/lib/src/pipeline.dart index 7e1c2900..d68e7e39 100644 --- a/packages/wyatt_http_client/lib/src/pipeline.dart +++ b/packages/wyatt_http_client/lib/src/pipeline.dart @@ -29,7 +29,7 @@ class Pipeline { /// {@macro pipeline} Pipeline.fromIterable(Iterable middlewares) : _middlewares = middlewares.toList(); - + final List _middlewares; /// The length of the [Pipeline]. diff --git a/packages/wyatt_ui_kit/lib/src/components/bars/widgets/navigation_item.dart b/packages/wyatt_ui_kit/lib/src/components/bars/widgets/navigation_item.dart index 8b608cb0..5750eb26 100644 --- a/packages/wyatt_ui_kit/lib/src/components/bars/widgets/navigation_item.dart +++ b/packages/wyatt_ui_kit/lib/src/components/bars/widgets/navigation_item.dart @@ -38,7 +38,7 @@ class NavigationItem extends StatelessWidget { context .themeExtension() ?.selectedIndicatorHeight, - // TODO: move default value + // TODO(wyatt): move default value 5, ], valueValidator: (value) => value != null, @@ -49,7 +49,7 @@ class NavigationItem extends StatelessWidget { context .themeExtension() ?.selectedIndicatorWidth, - // TODO: move default value + // TODO(wyatt): move default value 70, ], valueValidator: (value) => value != null, @@ -72,16 +72,17 @@ class NavigationItem extends StatelessWidget { ConstrainedBox( constraints: BoxConstraints( minWidth: ThemeHelper.getThemeElement( - [ - context - .themeExtension() - ?.selectedIndicatorWidth, - // TODO: move default value - 70, - ], - valueValidator: (value) => value != null, - transform: (value) => value, - ) ?? double.infinity, + [ + context + .themeExtension() + ?.selectedIndicatorWidth, + // TODO(wyatt): move default value + 70, + ], + valueValidator: (value) => value != null, + transform: (value) => value, + ) ?? + double.infinity, ), child: SizedBox( height: 50, -- 2.47.2