immaculater_dart library

Constants

inboxUid → const Int64
rootFolderUid → const Int64

Properties

sanityCheckForResponse ↔ Int64
getter/setter pair

Functions

createChecksumAndData(ToDoList tdl) ChecksumAndData
createJsonWebToken({required String? username, required String? password, required Client client, required String backendUrl}) Future<String>
Mints a new JSON Web Token (JWT) that you may later use with JsonWebTokenAuthorizer. Note that the client should use UsernamePasswordAuthorizer; see withClient3.
emptyMergeRequest() Uint8List
Returns the serialization of a minimal, sane MergeToDoListRequest
isSaneResponse(MergeToDoListResponse respPb) bool
Returns true iff respPb.sanityCheck is sane.
merge({required String? backendUrl, required Client client, required Uint8List body, bool? verbose = false}) Future<MergeToDoListResponse?>
Calls /todo/mergeprotobufs which might be a read or a write (that also does a read). Returns null when and only when you did a write and the server did not merge, meaning that you have the latest result and there is no need to update your state with the merged pyatdl.ToDoList. Raises ApiException and errors from package:http.
newAction({required String name, required Random prng, String? note}) Action
now() → Int64
Returns the current time suitable for pb.Timestamp usage.
randomUid(Random prng) → Int64
Returns a uniformly pseudorandom UID u such that -263 <= u < 0 or 2 < u < 263
readToDoList({required String? backendUrl, required Client client}) Future<MergeToDoListResponse?>
Reads in the latest ToDoList, wrapped up in a MergeToDoListResponse.
saneMergeRequest() MergeToDoListRequest
Returns a sane MergeToDoListRequest
withClient<T>(Future<T> fn({required String? backendUrl, required Uint8List body, required Client client, bool? verbose}), {required Authorizer authorizer, required String? backendUrl, required Uint8List body, required bool verbose}) Future<T>
withClient2<T>(Future<T> fn({required String? backendUrl, required Client client}), {required Authorizer authorizer, required String? backendUrl}) Future<T>
withClient3<T>(Future<T> fn({required String backendUrl, required Client client, required String? password, required String? username}), {required String backendUrl, required String? username, required String? password}) Future<T>