Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Result ¶
Result holds the information about the result of a check
func (*Result) IsFailureState ¶
IsFailureState returns true if Value is boolean and it is false.
func (*Result) IsSuccessState ¶
IsSuccessState returns true if Value is boolean and it is true.
type ResultCollection ¶
type ResultCollection []*Result
ResultCollection is a collection of Result
func NewResultCollection ¶
func NewResultCollection() *ResultCollection
NewResultCollection returns an empty ResultCollection.
func NewResultCollectionFromRegoResultSet ¶
func NewResultCollectionFromRegoResultSet(rs *rego.ResultSet) (*ResultCollection, error)
NewResultCollectionFromRegoResultSet creates a new ResultCollection from a rego.ResultSet.
func Parse ¶
func Parse(rawResult []byte) (*ResultCollection, error)
Parse takes the raw result of evaluating a set of rego rules in preflight and returns a ResultCollection collection.
func (*ResultCollection) Add ¶
func (r *ResultCollection) Add(rr []*Result)
Add adds a slice of results to the collection.
func (*ResultCollection) ByID ¶
func (r *ResultCollection) ByID() map[string]*Result
ByID returns a map of results by ID.
func (*ResultCollection) ListFailing ¶
func (r *ResultCollection) ListFailing() []*Result
ListFailing returns a subset of the results that have failed.
func (*ResultCollection) ListPassing ¶
func (r *ResultCollection) ListPassing() []*Result
ListPassing returns a subset of the results that have passed.
func (*ResultCollection) Raw ¶ added in v0.1.9
func (r *ResultCollection) Raw() []*Result