Documentation ¶
Index ¶
- Variables
- func IsSafeName(name string) bool
- func RandomName(randReader io.Reader, n int) (string, error)
- type Auth
- type Builder
- func (b *Builder) Auth(auth Auth) *Builder
- func (b *Builder) Build() (*User, error)
- func (b *Builder) Description(description string) *Builder
- func (b *Builder) DisplayName(displayName string) *Builder
- func (b *Builder) ID(id ID) *Builder
- func (b *Builder) Lang(lang language.Tag) *Builder
- func (b *Builder) LangFrom(lang string) *Builder
- func (b *Builder) Name(name string) *Builder
- func (b *Builder) NewID() *Builder
- func (b *Builder) Organizations(organizations []OrganizationID) *Builder
- type ID
- type Organization
- type OrganizationBuilder
- func (b *OrganizationBuilder) Active(active bool) *OrganizationBuilder
- func (b *OrganizationBuilder) Build() *Organization
- func (b *OrganizationBuilder) Description(description string) *OrganizationBuilder
- func (b *OrganizationBuilder) DisplayName(displayName string) *OrganizationBuilder
- func (b *OrganizationBuilder) ID(id OrganizationID) *OrganizationBuilder
- func (b *OrganizationBuilder) Name(name string) *OrganizationBuilder
- func (b *OrganizationBuilder) NewID() *OrganizationBuilder
- type OrganizationID
- type OrganizationIDs
- type User
- func (u *User) AddOrganization(organizationID OrganizationID)
- func (u *User) Auth() Auth
- func (u *User) Description() string
- func (u *User) DisplayName() string
- func (u *User) ID() ID
- func (u *User) IDRef() *ID
- func (u *User) Lang() language.Tag
- func (u *User) Name() string
- func (u *User) Organizations() OrganizationIDs
- func (u *User) SetDescription(description string)
- func (u *User) SetDisplayName(displayName string)
- func (u *User) SetLang(lang language.Tag)
- func (u *User) SetName(name string)
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrInvalidID = id.ErrInvalidID
View Source
var NewID = id.NewUserID
View Source
var NewOrganizationID = id.NewOrganizationID
Functions ¶
func IsSafeName ¶
Types ¶
type Auth ¶
func AuthFromOIDCSub ¶
type Builder ¶
type Builder struct {
// contains filtered or unexported fields
}
func (*Builder) Description ¶
func (*Builder) DisplayName ¶
func (*Builder) Organizations ¶
func (b *Builder) Organizations(organizations []OrganizationID) *Builder
type Organization ¶
type Organization struct {
// contains filtered or unexported fields
}
func (Organization) Active ¶
func (o Organization) Active() bool
func (Organization) Description ¶
func (o Organization) Description() string
func (Organization) DisplayName ¶
func (o Organization) DisplayName() string
func (Organization) ID ¶
func (o Organization) ID() OrganizationID
func (Organization) Name ¶
func (o Organization) Name() string
type OrganizationBuilder ¶
type OrganizationBuilder struct {
// contains filtered or unexported fields
}
func NewOrganization ¶
func NewOrganization() *OrganizationBuilder
func (*OrganizationBuilder) Active ¶
func (b *OrganizationBuilder) Active(active bool) *OrganizationBuilder
func (*OrganizationBuilder) Build ¶
func (b *OrganizationBuilder) Build() *Organization
func (*OrganizationBuilder) Description ¶
func (b *OrganizationBuilder) Description(description string) *OrganizationBuilder
func (*OrganizationBuilder) DisplayName ¶
func (b *OrganizationBuilder) DisplayName(displayName string) *OrganizationBuilder
func (*OrganizationBuilder) ID ¶
func (b *OrganizationBuilder) ID(id OrganizationID) *OrganizationBuilder
func (*OrganizationBuilder) Name ¶
func (b *OrganizationBuilder) Name(name string) *OrganizationBuilder
func (*OrganizationBuilder) NewID ¶
func (b *OrganizationBuilder) NewID() *OrganizationBuilder
type OrganizationID ¶
type OrganizationID = id.OrganizationID
type OrganizationIDs ¶
type OrganizationIDs = id.OrganizationIDList
type User ¶
type User struct {
// contains filtered or unexported fields
}
func (*User) AddOrganization ¶
func (u *User) AddOrganization(organizationID OrganizationID)
func (*User) Description ¶
func (*User) DisplayName ¶
func (*User) Organizations ¶
func (u *User) Organizations() OrganizationIDs
func (*User) SetDescription ¶
func (*User) SetDisplayName ¶
Click to show internal directories.
Click to hide internal directories.