-
Notifications
You must be signed in to change notification settings - Fork 144
Permissions
Wrapper for a bitfield that is more specifically used to represent Discord
permissions. See the permission
enumeration for acceptible permission values.
**Returns: **`Permissions
Constructs a new Permissions object that represents all has all known Discord permissions enabled.
- ...: Permissions Resolveable(s)
Enables a specific permission or permissions. See the permission
enumeration
for acceptible permission values.
- ...: Permissions Resolveable(s)
Disables a specific permission or permissions. See the permission
enumeration
for acceptible permission values.
- ...: Permissions Resolveable(s) **Returns: **`boolean
Returns whether this set has a specific permission or permissions. See the
permission
enumeration for acceptible permission values.
Enables all permissions values.
Disables all permissions values.
**Returns: **`string
Returns the hexadecimal string that represents the permissions value.
**Returns: **`table
Returns a table that represents the permissions value, where the keys are the
permission names and the values are true
or false
.
**Returns: **`table
Returns an array of the names of the permissions that this objects represents.
- other: Permissions **Returns: **`Permissions
Returns a new Permissions object that contains the permissions that are in
either self
or other
(bitwise OR).
- other: Permissions **Returns: **`Permissions
Returns a new Permissions object that contains the permissions that are in
both self
and other
(bitwise AND).
- other: Permissions **Returns: **`Permissions
Returns a new Permissions object that contains the permissions that are not
in self
or other
(bitwise XOR).
- **Returns: **`Permissions
Returnsa new Permissions object that contains the permissions that are not in
self
, but are in other
(or the set of all permissions if omitted).
**Returns: **`Permissions
Returns a new copy of the original permissions object.
@property value: number
The raw decimal value that represents the permissions value.