Frappe class

Class for handling Frappe-specific functionality.

Inheritance

Constructors

Frappe(RenovationConfig config)

Properties

allAppVersions List<AppVersion>
Returns all the apps as a List of AppVersion.
no setter
appVersionsLoaded bool
Whether the app versions are loaded
getter/setter pair
config RenovationConfig
finalinherited
frappeVersion AppVersion?
Returns the AppVersion of the app frappe.
no setter
hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

checkAppInstalled({required List<String> features, bool throwError = true, String appName = 'renovation_core'}) Future<void>
Silent method throwing an error AppNotInstalled if appName is not installed in the backend and throwError is set.
clearCache() → void
Clears the cache or residual objects.
override
fetchId() Future<RequestResponse<String?>>
Helper method to get the ID from the backend
getAppsVersion(String appName) AppVersion?
Returns the AppVersion of a certain app appName.
getCore() Renovation
Gets the reference to the Renovation instance
inherited
getFCMNotifications({bool? seen, int limitStart = 0, int limitPageLength = 20, dynamic filters}) Future<RequestResponse<List<FCMNotification>?>>
Returns a list of FCMNotification of a user.
getHostUrl() String
Returns the configured host URL towards the backend
inherited
handleError(String errorId, ErrorDetail error) → ErrorDetail
Returns the ErrorDetail after manipulating an existing one.
loadAppVersions() Future<RequestResponse<bool?>>
Loads the apps installed in Frappé site and their versions.
markFCMNotificationsAsSeen(String messageId) Future<RequestResponse>
Mark notification as seen in the backend.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
registerFCMToken(String token) Future<RequestResponse<String?>>
Register the currently signed in user with an FCM Token.
toString() String
A string representation of this object.
inherited
unregisterFCMToken(String token) Future<RequestResponse<FrappeResponse?>>
Removes the token from the currently signed in user.
updateClientId() Future<RequestResponse>
Calls renovation_manager frappe site and the server will set. x-client-site cookie which is helpful in routing the requests.
verifyClientId(String? id) Future<RequestResponse<String?>>
Verify the client ID from the backend.

Operators

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