SupabaseDatabaseAdapter class

The Database Adapter for supabase

WARNING: Supabase uses PostgreSQL which like MySQL relies on predefined tables.

Mixed in types

Constructors

SupabaseDatabaseAdapter({required String supabaseInstallationUrl, required String supabaseApiKey, String name = 'supabase', String? supabaseSchema})
The Database Adapter for supabase

Properties

hashCode int
The hash code for this object.
no setterinherited
name String
The name of the adapter. Must be unique when registering this DatabaseAdapter
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
supabaseApiKey String
The api key that is used to comunicate with supabase
final
supabaseInstallationUrl String
The URL where supabase is running on
final
supabaseSchema String?
On which schema the adapter should operate.
final

Methods

create(Query query, SupabaseClient client) Future<QueryResult>
Tries to store queries payload in supabase
inherited
delete(Query query, SupabaseClient client) Future<QueryResult>
Tries to delete payload from supabase
inherited
executeQuery(Query query) Future<QueryResult>
Executes the query and returns the result. The method should not throw but rather return a QueryResult.failed
getCreateQuery(DatabaseStorable element) → Query
generates a query that execute a create operation on the database
inherited
getDeleteQuery(DatabaseStorable element) → Query
generates a query that execute a delete operation on the database
inherited
getReadAllQuery({required Type type}) → Query
generates a query that execute a read operation on the database fetching all objects
inherited
getReadAllWhereQuery({required Type type, List<Constraint> where = const [], int? limit}) → Query
generates a query that execute a read operation on the database by applying a search function
inherited
getReadQuery(String id, {required Type type}) → Query
generates a query that execute a read operation on the database for an object with a given id.
inherited
getStoreQuery(DatabaseStorable element, {bool updateIfExists = false}) → Query
generates a create or update query depending if the object should be updated if it exists
inherited
getUpdateQuery(DatabaseStorable element) → Query
generates a query that execute a update operation on the database
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
read(Query query, SupabaseClient client) Future<QueryResult>
Tries to fetch payload from supabase
inherited
toString() String
A string representation of this object.
inherited
update(Query query, SupabaseClient client) Future<QueryResult>
Tries to store queries payload in supabase
inherited

Operators

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