AddPolicyCtx adds a policy rule to the storage with context.
(ctx context.Context, params ...interface{})
| 160 | |
| 161 | // AddPolicyCtx adds a policy rule to the storage with context. |
| 162 | func (e *ContextEnforcer) AddPolicyCtx(ctx context.Context, params ...interface{}) (bool, error) { |
| 163 | return e.AddNamedPolicyCtx(ctx, "p", params...) |
| 164 | } |
| 165 | |
| 166 | // AddPoliciesCtx adds policy rules to the storage with context. |
| 167 | func (e *ContextEnforcer) AddPoliciesCtx(ctx context.Context, rules [][]string) (bool, error) { |