Documentation ¶
Index ¶
- Constants
- type TenantPluginMgr
- type TenantPluginOperator
- func (t *TenantPluginOperator) AddTenantPlugin(tenantID, pluginID string) (ok bool, err error)
- func (t *TenantPluginOperator) DeleteTenantPlugin(tenantID, pluginID string) (ok bool, err error)
- func (t *TenantPluginOperator) ListTenantPlugins(tenantID string) (pluginIDs []string)
- func (t *TenantPluginOperator) OnCreateTenant(tenantID string) (ok bool, err error)
- func (t *TenantPluginOperator) TenantPluginPermissible(tenantID, pluginID string) (ok bool, err error)
Constants ¶
View Source
const ( // SysTenant Abstract tenant. SysTenant = "_systenant" SysPluginActionUse = "_use" SysRole = "_role" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type TenantPluginMgr ¶
type TenantPluginMgr interface { AddTenantPlugin(tenantID, pluginID string) (bool, error) DeleteTenantPlugin(tenantID, pluginID string) (bool, error) ListTenantPlugins(tenantID string) []string TenantPluginPermissible(tenantID, pluginID string) (bool, error) OnCreateTenant(tenantID string) (bool, error) }
func NewTenantPluginOperator ¶
func NewTenantPluginOperator(opt *casbin.SyncedEnforcer) TenantPluginMgr
type TenantPluginOperator ¶
type TenantPluginOperator struct {
RBACOperator *casbin.SyncedEnforcer
}
func (*TenantPluginOperator) AddTenantPlugin ¶
func (t *TenantPluginOperator) AddTenantPlugin(tenantID, pluginID string) (ok bool, err error)
func (*TenantPluginOperator) DeleteTenantPlugin ¶
func (t *TenantPluginOperator) DeleteTenantPlugin(tenantID, pluginID string) (ok bool, err error)
func (*TenantPluginOperator) ListTenantPlugins ¶
func (t *TenantPluginOperator) ListTenantPlugins(tenantID string) (pluginIDs []string)
func (*TenantPluginOperator) OnCreateTenant ¶
func (t *TenantPluginOperator) OnCreateTenant(tenantID string) (ok bool, err error)
func (*TenantPluginOperator) TenantPluginPermissible ¶
func (t *TenantPluginOperator) TenantPluginPermissible(tenantID, pluginID string) (ok bool, err error)
Click to show internal directories.
Click to hide internal directories.