origin

package
v0.0.0-...-3ca5dd0 Latest Latest
Warning

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

Go to latest
Published: Oct 22, 2019 License: CC0-1.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetSourceMappings

func GetSourceMappings() map[Key]SrcMapping

GetSourceMappings returns a mapping of each control origination to their respective sources.

Types

type Key

type Key uint8

Key is a unique value that represents the different types of possible control origination value.

const (
	NoOrigin Key = iota
	ServiceProviderCorporateOrigination
	ServiceProviderSystemSpecificOrigination
	ServiceProviderHybridOrigination
	ConfiguredByCustomerOrigination
	ProvidedByCustomerOrigination
	SharedOrigination
	InheritedOrigination
)

Origination prefixes.

func ConvertSetToKeys

func ConvertSetToKeys(s set.Interface) []Key

ConvertSetToKeys will convert the set, which each value is of type interface{} to the Key.

type SrcMapping

type SrcMapping map[source.Source]string

SrcMapping is a data structure that represents the text for a particular control origination in a particular source.

func (SrcMapping) IsDocMappingASubstrOf

func (o SrcMapping) IsDocMappingASubstrOf(value string) bool

IsDocMappingASubstrOf is wrapper that checks if the input string contains the SSP mapping. This is useful because the input string value may have extra characters so we can't do a == (equal to) check.

func (SrcMapping) IsYAMLMappingEqualTo

func (o SrcMapping) IsYAMLMappingEqualTo(value string) bool

IsYAMLMappingEqualTo is a wrapper that checks if the input string equals to the YAML mapping.

Jump to

Keyboard shortcuts

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