debian-forge-composer/internal/osbuild2/input.go
Achilleas Koutsou 6debb62758 osbuild2: separate input base types into new file
Keep input base types / interfaces separately from stages for
readability.
Cleaned up some unused interfaces in the process.
2021-07-24 15:54:00 +02:00

26 lines
497 B
Go

package osbuild2
// Collection of Inputs for a Stage
type Inputs interface {
isStageInputs()
}
// Single Input for a Stage
type Input interface {
isInput()
}
// Fields shared between all Input types (should be embedded in each instance)
type inputCommon struct {
Type string `json:"type"`
// Origin should be either 'org.osbuild.source' or 'org.osbuild.pipeline'
Origin string `json:"origin"`
}
type StageInput interface {
isStageInput()
}
type References interface {
isReferences()
}