Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // Admin : 管理者ユーザーロール Admin = gorbac.NewStdRole("admin") // User : 一般ユーザーロール User = gorbac.NewStdRole("user") // Bot : Botユーザーロール Bot = gorbac.NewStdRole("bot") // ReadUser : 読み取り専用ユーザーロール ReadUser = gorbac.NewStdRole("read") // WriteUser : 書き込み専用ユーザーロール WriteUser = gorbac.NewStdRole("write") // PrivateReadUser : プライベートチャンネル読み取り専用ユーザーロール PrivateReadUser = gorbac.NewStdRole("private_read") // PrivateWriteUser : プライベートチャンネル書き込み専用ユーザーロール PrivateWriteUser = gorbac.NewStdRole("private_write") )
Functions ¶
Types ¶
type CompositeRole ¶
type CompositeRole struct {
// contains filtered or unexported fields
}
CompositeRole : 複合ロール gorbacの継承が使いづらい
func NewCompositeRole ¶
func NewCompositeRole(roles ...gorbac.Role) *CompositeRole
NewCompositeRole : 複合ロールを生成します
func (*CompositeRole) Permit ¶
func (r *CompositeRole) Permit(p gorbac.Permission) bool
Permit returns true if the role has specific permission.
Click to show internal directories.
Click to hide internal directories.