Class: Permission
Represents a Permission.
Properties
actions
actions:
string[]
The actions allowed by the permission.
resources?
optionalresources?:$Properties|null
The resources the permission applies to.
Methods
toJSON()
toJSON():
object
Converts this Permission to JSON.
Returns
object
JSON object
create()
Call Signature
staticcreate(properties?):Permission&$Properties
Creates a new Permission instance using the specified properties.
Parameters
properties?
Properties to set
Returns
Permission & $Properties
Permission instance
Call Signature
staticcreate(properties?):Permission
Creates a new Permission instance using the specified properties.
Parameters
properties?
Properties to set
Returns
Permission
Permission instance
decode()
staticdecode(reader,length?):Permission&$Properties
Decodes a Permission message from the specified reader or buffer.
Parameters
reader
Uint8Array<ArrayBufferLike> | Reader
Reader or buffer to decode from
length?
number
Message length if known beforehand
Returns
Permission & $Properties
Permission
Throws
If the payload is not a reader or valid buffer
Throws
If required fields are missing
decodeDelimited()
staticdecodeDelimited(reader):Permission&$Properties
Decodes a Permission message from the specified reader or buffer, length delimited.
Parameters
reader
Uint8Array<ArrayBufferLike> | Reader
Reader or buffer to decode from
Returns
Permission & $Properties
Permission
Throws
If the payload is not a reader or valid buffer
Throws
If required fields are missing
encode()
staticencode(message,writer?):Writer
Encodes the specified Permission message. Does not implicitly temporal.api.cloud.identity.v1.CustomRoleSpec.Permission.verify|verify messages.
Parameters
message
Permission message or plain object to encode
writer?
Writer
Writer to encode to
Returns
Writer
Writer
encodeDelimited()
staticencodeDelimited(message,writer?):Writer
Encodes the specified Permission message, length delimited. Does not implicitly temporal.api.cloud.identity.v1.CustomRoleSpec.Permission.verify|verify messages.
Parameters
message
Permission message or plain object to encode
writer?
Writer
Writer to encode to
Returns
Writer
Writer
fromObject()
staticfromObject(object):Permission
Creates a Permission message from a plain object. Also converts values to their respective internal types.
Parameters
object
{[k: string]: any; }
Plain object
Returns
Permission
Permission
toObject()
statictoObject(message,options?):object
Creates a plain object from a Permission message. Also converts values to other types if specified.
Parameters
message
Permission
Permission
options?
IConversionOptions
Conversion options
Returns
object
Plain object