schema

package
v1.1.6 Latest Latest
Warning

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

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

Documentation

Index

Constants

View Source
const (
	// ErrMalformedV1_0_0YamlPrefix is just the prefix to the error message for when the program is unable to parse
	// data into the v1.0.0 yaml struct.
	ErrMalformedV1_0_0YamlPrefix = "Unable to parse yaml data"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Dependencies

type Dependencies struct {
	Certifications []VCSEntry `yaml:"certifications"`
	Systems        []VCSEntry `yaml:",flow"`
	Standards      []VCSEntry `yaml:",flow"`
}

Dependencies contains all the dependencies for the system

type Metadata

type Metadata struct {
	Description string   `yaml:"description"`
	Maintainers []string `yaml:",flow"`
}

Metadata contains metadata about the system.

type OpenControl

type OpenControl struct {
	Meta           Metadata     `yaml:"metadata"`
	Name           string       `yaml:"name"`
	Components     []string     `yaml:",flow"`
	Certifications []string     `yaml:",flow"`
	Standards      []string     `yaml:",flow"`
	Dependencies   Dependencies `yaml:"dependencies"`
}

OpenControl contains the structs for the v1.0.0 schema

func (OpenControl) GetCertifications

func (o OpenControl) GetCertifications() []string

GetCertifications retrieves the list of certifications

func (OpenControl) GetCertificationsDependencies

func (o OpenControl) GetCertificationsDependencies() []common.RemoteSource

GetCertificationsDependencies retrieves the list of certifications that this config will inherit.

func (OpenControl) GetComponents

func (o OpenControl) GetComponents() []string

GetComponents retrieves the list of components

func (OpenControl) GetComponentsDependencies

func (o OpenControl) GetComponentsDependencies() []common.RemoteSource

GetComponentsDependencies retrieves the list of components / systems that this config will inherit.

func (OpenControl) GetStandards

func (o OpenControl) GetStandards() []string

GetStandards retrieves the list of standards

func (OpenControl) GetStandardsDependencies

func (o OpenControl) GetStandardsDependencies() []common.RemoteSource

GetStandardsDependencies retrieves the list of standards that this config will inherit.

type VCSEntry

type VCSEntry struct {
	URL        string `yaml:"url"`
	Revision   string `yaml:"revision"`
	ContextDir string `yaml:"contextdir"`
	Path       string `yaml:"path"`
}

VCSEntry is a generic holder for handling the specific location and revision of a resource.

func (VCSEntry) GetConfigFile

func (e VCSEntry) GetConfigFile() string

GetConfigFile is a getter for the config file name. Will return DefaultConfigYaml value if none has been set.

func (VCSEntry) GetContextDir

func (e VCSEntry) GetContextDir() string

GetContextDir returns the dir containing content in the vcs resource.

func (VCSEntry) GetRevision

func (e VCSEntry) GetRevision() string

GetRevision returns the specific revision of the vcs resource.

func (VCSEntry) GetURL

func (e VCSEntry) GetURL() string

GetURL returns the URL of the vcs resource.

Jump to

Keyboard shortcuts

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