Record Class Permission
java.lang.Object
java.lang.Record
net.flectone.pulse.config.Permission
public record Permission(Permission.PermissionEntry module, Permission.Command command, Permission.Integration integration, Permission.Message message)
extends Record
Configuration for permissions in FlectonePulse.
Contains all permissions and their types.
- Since:
- 1.0
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final recordstatic final recordstatic final recordstatic classstatic final recordstatic enum -
Constructor Summary
ConstructorsConstructorDescriptionPermission(Permission.PermissionEntry module, Permission.Command command, Permission.Integration integration, Permission.Message message) Creates an instance of aPermissionrecord class. -
Method Summary
Modifier and TypeMethodDescriptionstatic Permission.PermissionBuilderbuilder()command()Returns the value of thecommandrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.Returns the value of theintegrationrecord component.message()Returns the value of themessagerecord component.module()Returns the value of themodulerecord component.final StringtoString()Returns a string representation of this record class.withCommand(Permission.Command command) withIntegration(Permission.Integration integration) withMessage(Permission.Message message) withModule(Permission.PermissionEntry module)
-
Constructor Details
-
Permission
public Permission(@JsonPropertyDescription(" https://flectone.net/pulse/docs/config/module") Permission.PermissionEntry module, @JsonPropertyDescription(" https://flectone.net/pulse/docs/command") Permission.Command command, @JsonPropertyDescription(" https://flectone.net/pulse/docs/integration") Permission.Integration integration, @JsonPropertyDescription(" https://flectone.net/pulse/docs/message") Permission.Message message) Creates an instance of aPermissionrecord class.- Parameters:
module- the value for themodulerecord componentcommand- the value for thecommandrecord componentintegration- the value for theintegrationrecord componentmessage- the value for themessagerecord component
-
-
Method Details
-
builder
-
toBuilder
-
withModule
- Returns:
- a clone of this object, except with this updated property (returns
thisif an identical value is passed).
-
withCommand
- Returns:
- a clone of this object, except with this updated property (returns
thisif an identical value is passed).
-
withIntegration
- Returns:
- a clone of this object, except with this updated property (returns
thisif an identical value is passed).
-
withMessage
- Returns:
- a clone of this object, except with this updated property (returns
thisif an identical value is passed).
-
toString
-
hashCode
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object). -
module
@JsonPropertyDescription(" https://flectone.net/pulse/docs/config/module") public Permission.PermissionEntry module()Returns the value of themodulerecord component.- Returns:
- the value of the
modulerecord component
-
command
@JsonPropertyDescription(" https://flectone.net/pulse/docs/command") public Permission.Command command()Returns the value of thecommandrecord component.- Returns:
- the value of the
commandrecord component
-
integration
@JsonPropertyDescription(" https://flectone.net/pulse/docs/integration") public Permission.Integration integration()Returns the value of theintegrationrecord component.- Returns:
- the value of the
integrationrecord component
-
message
@JsonPropertyDescription(" https://flectone.net/pulse/docs/message") public Permission.Message message()Returns the value of themessagerecord component.- Returns:
- the value of the
messagerecord component
-