Documentation ¶
Index ¶
- Variables
- type CraftingSchema
- func (*CraftingSchema) Descriptor() ([]byte, []int)deprecated
- func (x *CraftingSchema) GetEnvAllowList() []string
- func (x *CraftingSchema) GetMaterials() []*CraftingSchema_Material
- func (x *CraftingSchema) GetRunner() *CraftingSchema_Runner
- func (x *CraftingSchema) GetSchemaVersion() string
- func (*CraftingSchema) ProtoMessage()
- func (x *CraftingSchema) ProtoReflect() protoreflect.Message
- func (x *CraftingSchema) Reset()
- func (x *CraftingSchema) String() string
- func (m *CraftingSchema) Validate() error
- func (m *CraftingSchema) ValidateAll() error
- func (schema *CraftingSchema) ValidateUniqueMaterialName() error
- type CraftingSchemaMultiError
- type CraftingSchemaValidationError
- func (e CraftingSchemaValidationError) Cause() error
- func (e CraftingSchemaValidationError) Error() string
- func (e CraftingSchemaValidationError) ErrorName() string
- func (e CraftingSchemaValidationError) Field() string
- func (e CraftingSchemaValidationError) Key() bool
- func (e CraftingSchemaValidationError) Reason() string
- type CraftingSchema_Material
- func (*CraftingSchema_Material) Descriptor() ([]byte, []int)deprecated
- func (x *CraftingSchema_Material) GetName() string
- func (x *CraftingSchema_Material) GetOptional() bool
- func (x *CraftingSchema_Material) GetOutput() bool
- func (x *CraftingSchema_Material) GetType() CraftingSchema_Material_MaterialType
- func (*CraftingSchema_Material) ProtoMessage()
- func (x *CraftingSchema_Material) ProtoReflect() protoreflect.Message
- func (x *CraftingSchema_Material) Reset()
- func (x *CraftingSchema_Material) String() string
- func (m *CraftingSchema_Material) Validate() error
- func (m *CraftingSchema_Material) ValidateAll() error
- type CraftingSchema_MaterialMultiError
- type CraftingSchema_MaterialValidationError
- func (e CraftingSchema_MaterialValidationError) Cause() error
- func (e CraftingSchema_MaterialValidationError) Error() string
- func (e CraftingSchema_MaterialValidationError) ErrorName() string
- func (e CraftingSchema_MaterialValidationError) Field() string
- func (e CraftingSchema_MaterialValidationError) Key() bool
- func (e CraftingSchema_MaterialValidationError) Reason() string
- type CraftingSchema_Material_MaterialType
- func (CraftingSchema_Material_MaterialType) Descriptor() protoreflect.EnumDescriptor
- func (x CraftingSchema_Material_MaterialType) Enum() *CraftingSchema_Material_MaterialType
- func (CraftingSchema_Material_MaterialType) EnumDescriptor() ([]byte, []int)deprecated
- func (x CraftingSchema_Material_MaterialType) Number() protoreflect.EnumNumber
- func (x CraftingSchema_Material_MaterialType) String() string
- func (CraftingSchema_Material_MaterialType) Type() protoreflect.EnumType
- type CraftingSchema_Runner
- func (*CraftingSchema_Runner) Descriptor() ([]byte, []int)deprecated
- func (x *CraftingSchema_Runner) GetType() CraftingSchema_Runner_RunnerType
- func (*CraftingSchema_Runner) ProtoMessage()
- func (x *CraftingSchema_Runner) ProtoReflect() protoreflect.Message
- func (x *CraftingSchema_Runner) Reset()
- func (x *CraftingSchema_Runner) String() string
- func (m *CraftingSchema_Runner) Validate() error
- func (m *CraftingSchema_Runner) ValidateAll() error
- type CraftingSchema_RunnerMultiError
- type CraftingSchema_RunnerValidationError
- func (e CraftingSchema_RunnerValidationError) Cause() error
- func (e CraftingSchema_RunnerValidationError) Error() string
- func (e CraftingSchema_RunnerValidationError) ErrorName() string
- func (e CraftingSchema_RunnerValidationError) Field() string
- func (e CraftingSchema_RunnerValidationError) Key() bool
- func (e CraftingSchema_RunnerValidationError) Reason() string
- type CraftingSchema_Runner_RunnerType
- func (CraftingSchema_Runner_RunnerType) Descriptor() protoreflect.EnumDescriptor
- func (x CraftingSchema_Runner_RunnerType) Enum() *CraftingSchema_Runner_RunnerType
- func (CraftingSchema_Runner_RunnerType) EnumDescriptor() ([]byte, []int)deprecated
- func (x CraftingSchema_Runner_RunnerType) Number() protoreflect.EnumNumber
- func (x CraftingSchema_Runner_RunnerType) String() string
- func (CraftingSchema_Runner_RunnerType) Type() protoreflect.EnumType
Constants ¶
This section is empty.
Variables ¶
var ( CraftingSchema_Runner_RunnerType_name = map[int32]string{ 0: "RUNNER_TYPE_UNSPECIFIED", 1: "GITHUB_ACTION", 2: "GITLAB_PIPELINE", } CraftingSchema_Runner_RunnerType_value = map[string]int32{ "RUNNER_TYPE_UNSPECIFIED": 0, "GITHUB_ACTION": 1, "GITLAB_PIPELINE": 2, } )
Enum value maps for CraftingSchema_Runner_RunnerType.
var ( CraftingSchema_Material_MaterialType_name = map[int32]string{ 0: "MATERIAL_TYPE_UNSPECIFIED", 1: "STRING", 2: "CONTAINER_IMAGE", 3: "ARTIFACT", 4: "SBOM_CYCLONEDX_JSON", 5: "SBOM_SPDX_JSON", 6: "JUNIT_XML", } CraftingSchema_Material_MaterialType_value = map[string]int32{ "MATERIAL_TYPE_UNSPECIFIED": 0, "STRING": 1, "CONTAINER_IMAGE": 2, "ARTIFACT": 3, "SBOM_CYCLONEDX_JSON": 4, "SBOM_SPDX_JSON": 5, "JUNIT_XML": 6, } )
Enum value maps for CraftingSchema_Material_MaterialType.
var File_workflowcontract_v1_crafting_schema_proto protoreflect.FileDescriptor
Functions ¶
This section is empty.
Types ¶
type CraftingSchema ¶
type CraftingSchema struct { // Version of the schema, do not confuse with the revision of the content SchemaVersion string `protobuf:"bytes,1,opt,name=schema_version,json=schemaVersion,proto3" json:"schema_version,omitempty"` Materials []*CraftingSchema_Material `protobuf:"bytes,2,rep,name=materials,proto3" json:"materials,omitempty"` EnvAllowList []string `protobuf:"bytes,3,rep,name=env_allow_list,json=envAllowList,proto3" json:"env_allow_list,omitempty"` Runner *CraftingSchema_Runner `protobuf:"bytes,4,opt,name=runner,proto3" json:"runner,omitempty"` // contains filtered or unexported fields }
Schema definition provided by the user to the tool that defines the schema of the workflowRun
func (*CraftingSchema) Descriptor
deprecated
func (*CraftingSchema) Descriptor() ([]byte, []int)
Deprecated: Use CraftingSchema.ProtoReflect.Descriptor instead.
func (*CraftingSchema) GetEnvAllowList ¶
func (x *CraftingSchema) GetEnvAllowList() []string
func (*CraftingSchema) GetMaterials ¶
func (x *CraftingSchema) GetMaterials() []*CraftingSchema_Material
func (*CraftingSchema) GetRunner ¶
func (x *CraftingSchema) GetRunner() *CraftingSchema_Runner
func (*CraftingSchema) GetSchemaVersion ¶
func (x *CraftingSchema) GetSchemaVersion() string
func (*CraftingSchema) ProtoMessage ¶
func (*CraftingSchema) ProtoMessage()
func (*CraftingSchema) ProtoReflect ¶
func (x *CraftingSchema) ProtoReflect() protoreflect.Message
func (*CraftingSchema) Reset ¶
func (x *CraftingSchema) Reset()
func (*CraftingSchema) String ¶
func (x *CraftingSchema) String() string
func (*CraftingSchema) Validate ¶
func (m *CraftingSchema) Validate() error
Validate checks the field values on CraftingSchema with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.
func (*CraftingSchema) ValidateAll ¶
func (m *CraftingSchema) ValidateAll() error
ValidateAll checks the field values on CraftingSchema with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in CraftingSchemaMultiError, or nil if none found.
func (*CraftingSchema) ValidateUniqueMaterialName ¶
func (schema *CraftingSchema) ValidateUniqueMaterialName() error
ValidateUniqueMaterialName validates that only one material definition with the same ID is present in the schema
type CraftingSchemaMultiError ¶
type CraftingSchemaMultiError []error
CraftingSchemaMultiError is an error wrapping multiple validation errors returned by CraftingSchema.ValidateAll() if the designated constraints aren't met.
func (CraftingSchemaMultiError) AllErrors ¶
func (m CraftingSchemaMultiError) AllErrors() []error
AllErrors returns a list of validation violation errors.
func (CraftingSchemaMultiError) Error ¶
func (m CraftingSchemaMultiError) Error() string
Error returns a concatenation of all the error messages it wraps.
type CraftingSchemaValidationError ¶
type CraftingSchemaValidationError struct {
// contains filtered or unexported fields
}
CraftingSchemaValidationError is the validation error returned by CraftingSchema.Validate if the designated constraints aren't met.
func (CraftingSchemaValidationError) Cause ¶
func (e CraftingSchemaValidationError) Cause() error
Cause function returns cause value.
func (CraftingSchemaValidationError) Error ¶
func (e CraftingSchemaValidationError) Error() string
Error satisfies the builtin error interface
func (CraftingSchemaValidationError) ErrorName ¶
func (e CraftingSchemaValidationError) ErrorName() string
ErrorName returns error name.
func (CraftingSchemaValidationError) Field ¶
func (e CraftingSchemaValidationError) Field() string
Field function returns field value.
func (CraftingSchemaValidationError) Key ¶
func (e CraftingSchemaValidationError) Key() bool
Key function returns key value.
func (CraftingSchemaValidationError) Reason ¶
func (e CraftingSchemaValidationError) Reason() string
Reason function returns reason value.
type CraftingSchema_Material ¶
type CraftingSchema_Material struct { Type CraftingSchema_Material_MaterialType `protobuf:"varint,1,opt,name=type,proto3,enum=workflowcontract.v1.CraftingSchema_Material_MaterialType" json:"type,omitempty"` Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"` // Single word optionally separated with _ or - Optional bool `protobuf:"varint,3,opt,name=optional,proto3" json:"optional,omitempty"` // If a material is set as output it will get added to the subject in the statement Output bool `protobuf:"varint,4,opt,name=output,proto3" json:"output,omitempty"` // contains filtered or unexported fields }
func (*CraftingSchema_Material) Descriptor
deprecated
func (*CraftingSchema_Material) Descriptor() ([]byte, []int)
Deprecated: Use CraftingSchema_Material.ProtoReflect.Descriptor instead.
func (*CraftingSchema_Material) GetName ¶
func (x *CraftingSchema_Material) GetName() string
func (*CraftingSchema_Material) GetOptional ¶
func (x *CraftingSchema_Material) GetOptional() bool
func (*CraftingSchema_Material) GetOutput ¶
func (x *CraftingSchema_Material) GetOutput() bool
func (*CraftingSchema_Material) GetType ¶
func (x *CraftingSchema_Material) GetType() CraftingSchema_Material_MaterialType
func (*CraftingSchema_Material) ProtoMessage ¶
func (*CraftingSchema_Material) ProtoMessage()
func (*CraftingSchema_Material) ProtoReflect ¶
func (x *CraftingSchema_Material) ProtoReflect() protoreflect.Message
func (*CraftingSchema_Material) Reset ¶
func (x *CraftingSchema_Material) Reset()
func (*CraftingSchema_Material) String ¶
func (x *CraftingSchema_Material) String() string
func (*CraftingSchema_Material) Validate ¶
func (m *CraftingSchema_Material) Validate() error
Validate checks the field values on CraftingSchema_Material with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.
func (*CraftingSchema_Material) ValidateAll ¶
func (m *CraftingSchema_Material) ValidateAll() error
ValidateAll checks the field values on CraftingSchema_Material with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in CraftingSchema_MaterialMultiError, or nil if none found.
type CraftingSchema_MaterialMultiError ¶
type CraftingSchema_MaterialMultiError []error
CraftingSchema_MaterialMultiError is an error wrapping multiple validation errors returned by CraftingSchema_Material.ValidateAll() if the designated constraints aren't met.
func (CraftingSchema_MaterialMultiError) AllErrors ¶
func (m CraftingSchema_MaterialMultiError) AllErrors() []error
AllErrors returns a list of validation violation errors.
func (CraftingSchema_MaterialMultiError) Error ¶
func (m CraftingSchema_MaterialMultiError) Error() string
Error returns a concatenation of all the error messages it wraps.
type CraftingSchema_MaterialValidationError ¶
type CraftingSchema_MaterialValidationError struct {
// contains filtered or unexported fields
}
CraftingSchema_MaterialValidationError is the validation error returned by CraftingSchema_Material.Validate if the designated constraints aren't met.
func (CraftingSchema_MaterialValidationError) Cause ¶
func (e CraftingSchema_MaterialValidationError) Cause() error
Cause function returns cause value.
func (CraftingSchema_MaterialValidationError) Error ¶
func (e CraftingSchema_MaterialValidationError) Error() string
Error satisfies the builtin error interface
func (CraftingSchema_MaterialValidationError) ErrorName ¶
func (e CraftingSchema_MaterialValidationError) ErrorName() string
ErrorName returns error name.
func (CraftingSchema_MaterialValidationError) Field ¶
func (e CraftingSchema_MaterialValidationError) Field() string
Field function returns field value.
func (CraftingSchema_MaterialValidationError) Key ¶
func (e CraftingSchema_MaterialValidationError) Key() bool
Key function returns key value.
func (CraftingSchema_MaterialValidationError) Reason ¶
func (e CraftingSchema_MaterialValidationError) Reason() string
Reason function returns reason value.
type CraftingSchema_Material_MaterialType ¶
type CraftingSchema_Material_MaterialType int32
const ( CraftingSchema_Material_MATERIAL_TYPE_UNSPECIFIED CraftingSchema_Material_MaterialType = 0 CraftingSchema_Material_STRING CraftingSchema_Material_MaterialType = 1 CraftingSchema_Material_CONTAINER_IMAGE CraftingSchema_Material_MaterialType = 2 CraftingSchema_Material_ARTIFACT CraftingSchema_Material_MaterialType = 3 CraftingSchema_Material_SBOM_CYCLONEDX_JSON CraftingSchema_Material_MaterialType = 4 CraftingSchema_Material_SBOM_SPDX_JSON CraftingSchema_Material_MaterialType = 5 CraftingSchema_Material_JUNIT_XML CraftingSchema_Material_MaterialType = 6 // SARIF = 5; )
func (CraftingSchema_Material_MaterialType) Descriptor ¶
func (CraftingSchema_Material_MaterialType) Descriptor() protoreflect.EnumDescriptor
func (CraftingSchema_Material_MaterialType) Enum ¶
func (x CraftingSchema_Material_MaterialType) Enum() *CraftingSchema_Material_MaterialType
func (CraftingSchema_Material_MaterialType) EnumDescriptor
deprecated
func (CraftingSchema_Material_MaterialType) EnumDescriptor() ([]byte, []int)
Deprecated: Use CraftingSchema_Material_MaterialType.Descriptor instead.
func (CraftingSchema_Material_MaterialType) Number ¶
func (x CraftingSchema_Material_MaterialType) Number() protoreflect.EnumNumber
func (CraftingSchema_Material_MaterialType) String ¶
func (x CraftingSchema_Material_MaterialType) String() string
func (CraftingSchema_Material_MaterialType) Type ¶
func (CraftingSchema_Material_MaterialType) Type() protoreflect.EnumType
type CraftingSchema_Runner ¶
type CraftingSchema_Runner struct { Type CraftingSchema_Runner_RunnerType `protobuf:"varint,1,opt,name=type,proto3,enum=workflowcontract.v1.CraftingSchema_Runner_RunnerType" json:"type,omitempty"` // contains filtered or unexported fields }
func (*CraftingSchema_Runner) Descriptor
deprecated
func (*CraftingSchema_Runner) Descriptor() ([]byte, []int)
Deprecated: Use CraftingSchema_Runner.ProtoReflect.Descriptor instead.
func (*CraftingSchema_Runner) GetType ¶
func (x *CraftingSchema_Runner) GetType() CraftingSchema_Runner_RunnerType
func (*CraftingSchema_Runner) ProtoMessage ¶
func (*CraftingSchema_Runner) ProtoMessage()
func (*CraftingSchema_Runner) ProtoReflect ¶
func (x *CraftingSchema_Runner) ProtoReflect() protoreflect.Message
func (*CraftingSchema_Runner) Reset ¶
func (x *CraftingSchema_Runner) Reset()
func (*CraftingSchema_Runner) String ¶
func (x *CraftingSchema_Runner) String() string
func (*CraftingSchema_Runner) Validate ¶
func (m *CraftingSchema_Runner) Validate() error
Validate checks the field values on CraftingSchema_Runner with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.
func (*CraftingSchema_Runner) ValidateAll ¶
func (m *CraftingSchema_Runner) ValidateAll() error
ValidateAll checks the field values on CraftingSchema_Runner with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in CraftingSchema_RunnerMultiError, or nil if none found.
type CraftingSchema_RunnerMultiError ¶
type CraftingSchema_RunnerMultiError []error
CraftingSchema_RunnerMultiError is an error wrapping multiple validation errors returned by CraftingSchema_Runner.ValidateAll() if the designated constraints aren't met.
func (CraftingSchema_RunnerMultiError) AllErrors ¶
func (m CraftingSchema_RunnerMultiError) AllErrors() []error
AllErrors returns a list of validation violation errors.
func (CraftingSchema_RunnerMultiError) Error ¶
func (m CraftingSchema_RunnerMultiError) Error() string
Error returns a concatenation of all the error messages it wraps.
type CraftingSchema_RunnerValidationError ¶
type CraftingSchema_RunnerValidationError struct {
// contains filtered or unexported fields
}
CraftingSchema_RunnerValidationError is the validation error returned by CraftingSchema_Runner.Validate if the designated constraints aren't met.
func (CraftingSchema_RunnerValidationError) Cause ¶
func (e CraftingSchema_RunnerValidationError) Cause() error
Cause function returns cause value.
func (CraftingSchema_RunnerValidationError) Error ¶
func (e CraftingSchema_RunnerValidationError) Error() string
Error satisfies the builtin error interface
func (CraftingSchema_RunnerValidationError) ErrorName ¶
func (e CraftingSchema_RunnerValidationError) ErrorName() string
ErrorName returns error name.
func (CraftingSchema_RunnerValidationError) Field ¶
func (e CraftingSchema_RunnerValidationError) Field() string
Field function returns field value.
func (CraftingSchema_RunnerValidationError) Key ¶
func (e CraftingSchema_RunnerValidationError) Key() bool
Key function returns key value.
func (CraftingSchema_RunnerValidationError) Reason ¶
func (e CraftingSchema_RunnerValidationError) Reason() string
Reason function returns reason value.
type CraftingSchema_Runner_RunnerType ¶
type CraftingSchema_Runner_RunnerType int32
const ( CraftingSchema_Runner_RUNNER_TYPE_UNSPECIFIED CraftingSchema_Runner_RunnerType = 0 CraftingSchema_Runner_GITHUB_ACTION CraftingSchema_Runner_RunnerType = 1 CraftingSchema_Runner_GITLAB_PIPELINE CraftingSchema_Runner_RunnerType = 2 )
func (CraftingSchema_Runner_RunnerType) Descriptor ¶
func (CraftingSchema_Runner_RunnerType) Descriptor() protoreflect.EnumDescriptor
func (CraftingSchema_Runner_RunnerType) Enum ¶
func (x CraftingSchema_Runner_RunnerType) Enum() *CraftingSchema_Runner_RunnerType
func (CraftingSchema_Runner_RunnerType) EnumDescriptor
deprecated
func (CraftingSchema_Runner_RunnerType) EnumDescriptor() ([]byte, []int)
Deprecated: Use CraftingSchema_Runner_RunnerType.Descriptor instead.
func (CraftingSchema_Runner_RunnerType) Number ¶
func (x CraftingSchema_Runner_RunnerType) Number() protoreflect.EnumNumber
func (CraftingSchema_Runner_RunnerType) String ¶
func (x CraftingSchema_Runner_RunnerType) String() string
func (CraftingSchema_Runner_RunnerType) Type ¶
func (CraftingSchema_Runner_RunnerType) Type() protoreflect.EnumType