ParseRole class

Represents a Role on the Parse server. ParseRoles represent groupings of ParseUsers for the purposes of granting permissions (e.g. specifying a ParseACL for a ParseObject). Roles are specified by their sets of child users and child roles, all of which are granted any permissions that the parent role has.

Roles must have a name (which cannot be changed after creation of the role), and must specify an ACL.

Inheritance

Constructors

ParseRole({required dynamic json})
Constructs a new ParseRole with JSON.
ParseRole.create(String name, ParseACL acl)
Constructs a new ParseRole with the given name.
ParseRole.fromJson({required dynamic json})
Factory constructor of a new ParseRole with JSON.
factory

Properties

acl ParseACL
The default ParseACL of this Role
final
asMap → dynamic
Return map of pointer
no setteroverride
asPointer → dynamic
Return Map<String, dynamic> of pointer object
no setterinherited
className String
Accessor to the class name.
finalinherited
copy ParseObject
Return the copy of this instance
no setterinherited
createdAt DateTime?
This reports time as the server sees it, so that if you create a ParseObject, then wait a while, and then call save, the creation time will be the time of the first save call rather than the time the object was created locally.
no setterinherited
hashCode int
The hash code for this object.
no setterinherited
isComplete bool
Return true if this object already fetched
no setterinherited
isDeleted bool
Return true if this is already deleted
no setterinherited
name String
The name of this Role
final
objectId String?
Accessor to the object id. An object id is assigned as soon as an object is saved to the server. The combination of a className and an objectId uniquely identifies an object in your application.
no setterinherited
operations Map<String, dynamic>
no setterinherited
path String
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
updatedAt DateTime?
This reports time as the server sees it, so that if you make changes to a ParseObject, then wait a while, and then call save, the updated time will be the time of the save call rather than the time the object was changed locally.
no setterinherited

Methods

add(String key, dynamic value) → void
Atomically adds an object to the end of the array associated with a given key.
inherited
addAll(String key, List values) → void
Atomically adds the objects contained in a List to the end of the array associated with a given key.
inherited
addAllUnique(String key, List values) → void
Atomically adds the objects contained in a List to the array associated with a given key, only adding elements which are not already present in the array. The position of the insert is not guaranteed.
inherited
addUnique(String key, dynamic value) → void
Atomically adds an object to the array associated with a given key, only if it is not already present in the array. The position of the insert is not guaranteed.
inherited
decrement(dynamic key, {int by = -1}) → void
Atomically decrements the given key by the given number.
inherited
delete({bool useMasterKey = false}) Future<void>
Deletes this object on the server.
inherited
fetch({List<String>? includes, bool useMasterKey = false}) Future<ParseObject>
Fetches this object with the data from the server.
inherited
fetchIfNeeded({bool useMasterKey = false}) Future<ParseObject>
If this ParseObject has not been fetched (i.e. isComplete returns false), fetches this object with the data from the server.
inherited
get(String key) → dynamic
Access a value. In most cases it is more convenient to use a helper function such as getString or getInteger.
inherited
getBoolean(String key) bool?
Access a bool value.
inherited
getDateTime(String key) DateTime?
Access a DateTime value.
inherited
getDouble(String key) double?
Access a double value.
inherited
getInteger(String key) int?
Access an int value.
inherited
getList<T>(String key) List<T>?
Access a List value.
inherited
getMap<T>(String key) Map<String, T>?
Access a Map value.
inherited
getNumber(String key) num?
Access a num value.
inherited
getParseACL() ParseACL?
Access a ParseACL value.
inherited
getParseFile(String key) ParseFile?
Access a ParseFile value.
inherited
getParseGeoPoint(String key) ParseGeoPoint?
Access a ParseGeoPoint value.
inherited
getParseObject(String key) ParseObject?
Access a ParseObject value.
inherited
getParseRole(String key) ParseRole?
Access a ParseRole value.
inherited
getParseUser(String key) ParseUser?
Access a ParseUser value.
inherited
getString(String key) String?
Access a String value.
inherited
increment(dynamic key, {int by = 1}) → void
Atomically increments the given key by the given number.
inherited
isKeyMutable(String key) bool
inherited
mergeJson(dynamic json, {bool fromFetch = false}) → void
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
remove(String key) → void
Removes a key from this object's data if it exists.
inherited
removeAll(String key, List values) → void
Atomically removes all instances of the objects contained in a List from the array associated with a given key.
inherited
save({bool useMasterKey = false}) Future<ParseObject>
Saves this object to the server.
inherited
set(String key, dynamic value) → void
Add a key-value pair to this object. It is recommended to name keys in camelCaseLikeThis.
inherited
setACL(ParseACL acl) → void
Setup ParseACL into this object
inherited
toString() String
A string representation of this object.
inherited
uploadFiles() Future<void>
Uploading ParseFile's when there is any file to upload
inherited

Operators

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

Static Properties

query ParseQuery<ParseObject>
no setter