MCPcopy
hub / github.com/apache/casbin / LoadFilteredPolicyCtx

Method LoadFilteredPolicyCtx

enforcer_context.go:88–91  ·  view source on GitHub ↗

LoadFilteredPolicyCtx loads all policy rules from the storage with context and filter.

(ctx context.Context, filter interface{})

Source from the content-addressed store, hash-verified

86
87// LoadFilteredPolicyCtx loads all policy rules from the storage with context and filter.
88func (e *Enforcer) LoadFilteredPolicyCtx(ctx context.Context, filter interface{}) error {
89 e.model.ClearPolicy()
90 return e.loadFilteredPolicyCtx(ctx, filter)
91}
92
93// LoadIncrementalFilteredPolicyCtx append a filtered policy from file/database with context.
94func (e *Enforcer) LoadIncrementalFilteredPolicyCtx(ctx context.Context, filter interface{}) error {

Callers

nothing calls this directly

Calls 2

loadFilteredPolicyCtxMethod · 0.95
ClearPolicyMethod · 0.65

Tested by

no test coverage detected