Skip to content

Role🔗

Definition🔗

type Role struct {
    // The role identifier `managed:builtins:editor:permissions`
    Name string `json:"name"`
    // Optional display
    DisplayName *string `json:"displayName,omitempty"`
    // Name of the team.
    GroupName *string `json:"groupName,omitempty"`
    // Role description
    Description *string `json:"description,omitempty"`
    // Do not show this role
    Hidden bool `json:"hidden"`
}

Methods🔗

UnmarshalJSONStrict🔗

UnmarshalJSONStrict implements a custom JSON unmarshalling logic to decode Role from JSON.

Note: the unmarshalling done by this function is strict. It will fail over required fields being absent from the input, fields having an incorrect type, unexpected fields being present, …

func (role *Role) UnmarshalJSONStrict(raw []byte) error

Equals🔗

Equals tests the equality of two Role objects.

func (role *Role) Equals(other Role) bool

Validate🔗

Validate checks all the validation constraints that may be defined on Role fields for violations and returns them.

func (role *Role) Validate() error

See also🔗