ModelValidationQueryUserType enum

Specify the target user for which you want to specify ModelValidationQueryPermissionType.

ModelValidationQueryPermissionTypeを指定する対象のユーザーを指定します。

Inheritance

Constructors

ModelValidationQueryUserType()
const

Values

allUsers → const ModelValidationQueryUserType

All users.

すべてのユーザー。

authUsers → const ModelValidationQueryUserType

Authenticated users.

If DatabaseValidator.onRetrieveUserId does not return Null, this is the user.

If allUsers is specified, it takes precedence.

認証済みのユーザー。

DatabaseValidator.onRetrieveUserIdNullを返さない場合このユーザーとなります。

allUsersが指定されている場合はそちらが優先されます。

userFromPathIndex → const ModelValidationQueryUserType

An authenticated user whose user ID matches the dynamic value specified by the index number in the document or collection path and the user ID authenticated on the app.

You can specify odd numbers such as 1 or 3 even if you specify a collection since it will always be compared to a document.

If allUsers or authUsers is specified, it takes precedence.

userFromData can be specified at the same time.

認証済みユーザーのうち、ドキュメントやコレクションのパス中のインデックス番号で指定する動的な値とアプリ上で認証しているユーザーIDが一致するユーザー。

必ずドキュメントとの比較になるのでコレクションを指定した場合でも13などの奇数番号を指定可能です。

allUsersauthUsersが指定されている場合はそちらが優先されます。

userFromDataとは同時に指定可能です。

// Path definition
/collection/:document_id
// Actual path
/collection/ABCDEFG
// Definition
ModelValidationQueryUserType.userFromPathIndex(1)
-> Allow users whose user ID is `ABCDEFG
userFromData → const ModelValidationQueryUserType

An authenticated user whose user ID matches the value of a field with key in the document to be read or written and the user ID authenticated on the app.

If @uid is specified, a comparison with the document ID is performed.

If allUsers or authUsers is specified, it takes precedence.

userFromPathIndex can be specified at the same time.

認証済みユーザーのうち、読み込みや書き込み対象のドキュメント中にkeyを持つフィールドの値ととアプリ上で認証しているユーザーIDが一致するユーザー。

@uidが指定されている場合ドキュメントIDとの比較が行われます。

allUsersauthUsersが指定されている場合はそちらが優先されます。

userFromPathIndexとは同時に指定可能です。

// Document data
{
  "user": "ABCDEFG",
  "name": "ABCD",
  "age": 20,
}
// Definition
ModelValidationQueryUserType.userFromData("user")
-> Allow users whose user ID is `ABCDEFG

Properties

hashCode int
The hash code for this object.
no setterinherited
index int
A numeric identifier for the enumerated value.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

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

Constants

values → const List<ModelValidationQueryUserType>
A constant List of the values in this enum, in order of their declaration.