MCPcopy Index your code
hub / github.com/apache/casbin / SelfRemoveFilteredPolicyCtx

Method SelfRemoveFilteredPolicyCtx

enforcer_context.go:398–400  ·  view source on GitHub ↗

SelfRemoveFilteredPolicyCtx removes policy rules that match the filter from the current policy with context.

(ctx context.Context, sec string, ptype string, fieldIndex int, fieldValues ...string)

Source from the content-addressed store, hash-verified

396
397// SelfRemoveFilteredPolicyCtx removes policy rules that match the filter from the current policy with context.
398func (e *ContextEnforcer) SelfRemoveFilteredPolicyCtx(ctx context.Context, sec string, ptype string, fieldIndex int, fieldValues ...string) (bool, error) {
399 return e.removeFilteredPolicyWithoutNotifyCtx(ctx, sec, ptype, fieldIndex, fieldValues)
400}
401
402// SelfUpdatePolicyCtx updates a policy rule in the current policy with context.
403func (e *ContextEnforcer) SelfUpdatePolicyCtx(ctx context.Context, sec string, ptype string, oldRule, newRule []string) (bool, error) {

Callers

nothing calls this directly

Tested by

no test coverage detected