Yust class
Yust is the easiest way to connect a full stack Dart app to Firebase.
It is supporting Firebase Auth, Cloud Firestore and Cloud Storage. You can use Yust in a flutter and for a server app.
Constructors
- Yust({required bool forUI, DatabaseLogCallback? dbLogCallback, bool useSubcollections = false, String envCollectionName = 'envs', OnChangeCallback? onChange})
-
Initializes Yust.
If you will use yust in combination with e.g. YustUI in a flutter app set
forUIto true. - Yust.mocked({required bool forUI, bool useSubcollections = false, String envCollectionName = 'envs', DatabaseLogCallback? dbLogCallback, OnChangeCallback? onChange})
-
Initializes Yust in a mocked way => use in memory db instead of a real connection to firebase.
If you will use yust in combination with e.g. YustUI in a flutter app set
forUIto true.
Properties
- authClient ↔ Client?
-
getter/setter pair
- dbLogCallback → DatabaseLogCallback?
-
final
- dbService ↔ YustDatabaseService
-
getter/setter pair
- envCollectionName → String
-
final
- forUI ↔ bool
-
Whether this Yust instance is used for a UI application.
getter/setter pair
- hashCode → int
-
The hash code for this object.
no setterinherited
- mocked ↔ bool
-
getter/setter pair
- onChange → OnChangeCallback?
-
final
- pushService ↔ YustPushService
-
getter/setter pair
- readTime ← DateTime?
-
no getter
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- useSubcollections → bool
-
final
Methods
-
closeClient(
) → void -
initialize(
{Map< String, String> ? firebaseOptions, ServiceAccountCredentials? credentials, required String projectId, String? emulatorAddress, YustDocSetup<YustUser> ? userSetup, DatabaseLogCallback? dbLogCallback, String? originalCdnBaseUrl, String? thumbnailCdnBaseUrl, String? backendAuthId, String? userAgent}) → Future<void> -
Initializes Yust.
This method should be called before any usage of the yust package.
Use
firebaseOptionsto connect to Firebase if your are using Flutter. Usecredentialsto pass service account credentials directly with Dart. Set theemulatorAddress, if you want to emulate Firebase.userSetuplet you overwrite the defaultUserSetup. If useSubcollections is set to true (default), Yust is creating subcollections for each tenant automatically. envCollectionName represents the collection name for the tenants. UseprojectIdto override / set the project id otherwise gathered from the execution environment. UsedbLogCallbackto provide a function that will get called on each DatabaseCall -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Properties
- authService ↔ YustAuthService
-
getter/setter pair
- databaseService → YustDatabaseService
-
When using Yust with Flutter, you can access the databaseService of the
only instance of Yust with this getter.
no setter
- fileAccessService ↔ IYustFileAccessService
-
Service to handle file access and URL signing requests.
getter/setter pair
- fileService ↔ YustFileService
-
getter/setter pair
- helpers ↔ YustHelpers
-
getter/setter pair
- instance → Yust
-
When using Yust with Flutter, you can access the instance of Yust with
this getter.
no setter
- projectId ↔ String
-
getter/setter pair
-
userSetup
↔ YustDocSetup<
YustUser> -
getter/setter pair