rule

package
v1.0.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 27, 2022 License: Apache-2.0 Imports: 3 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ACLValidator

type ACLValidator interface {
	Validate(pnode *ptree.PermNode) (bool, error)
}

ACLValidator interface defines common interface for ACL Validator Validator only validate account/ak with 1~2 level height

type ACLValidatorFactory

type ACLValidatorFactory struct {
}

ACLValidatorFactory create ACLValidator for specified permission model

func (*ACLValidatorFactory) GetACLValidator

func (vf *ACLValidatorFactory) GetACLValidator(pr pb.PermissionRule) (ACLValidator, error)

GetACLValidator returns ACLValidator for specified permission model

type AKSetsValidator

type AKSetsValidator struct{}

AKSetsValidator is Valiator for AkSets permission model

func NewAKSetsValidator

func NewAKSetsValidator() *AKSetsValidator

NewAKSetsValidator return instance of AKSetsValidator

func (*AKSetsValidator) Validate

func (asv *AKSetsValidator) Validate(pnode *ptree.PermNode) (bool, error)

Validate implements the interface of ACLValidator

type ThresholdValidator

type ThresholdValidator struct{}

ThresholdValidator is Valiator for Threshold permission model

func NewThresholdValidator

func NewThresholdValidator() *ThresholdValidator

NewThresholdValidator return instance of ThresholdValidator

func (*ThresholdValidator) Validate

func (tv *ThresholdValidator) Validate(pnode *ptree.PermNode) (bool, error)

Validate implements the interface of ACLValidator

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL