Documentation ¶
Index ¶
- Constants
- func MachineAlreadyCreated() errors.BusinessError
- func NewMachineCreatedDomainEvent(machineID MachineID) base.DomainEvent
- func NewMachineInterface(interfaceName string, systemName string, chassisID string, portID string, ...) metalv1alpha4.Interface
- type Loopbacks
- type Machine
- type MachineAlreadyExist
- type MachineCreatedDomainEvent
- type MachineID
- type MachineIDGenerator
Constants ¶
View Source
const ( InterfaceRedundancySingle = "Single" InterfaceRedundancyHighAvailability = "HighAvailability" InterfaceRedundancyNone = "None" )
Variables ¶
This section is empty.
Functions ¶
func MachineAlreadyCreated ¶
func MachineAlreadyCreated() errors.BusinessError
func NewMachineCreatedDomainEvent ¶
func NewMachineCreatedDomainEvent( machineID MachineID, ) base.DomainEvent
func NewMachineInterface ¶
Types ¶
type Machine ¶
type Machine struct { base.DomainEntity ID MachineID UUID string Namespace string ASN uint32 SKU string SerialNumber string Interfaces []metalv1alpha4.Interface Loopbacks Loopbacks Size map[string]string }
func CreateMachine ¶
func CreateMachine( idGenerator MachineIDGenerator, machineAlreadyExist MachineAlreadyExist, UUID string, namespace string, SKU string, serialNumber string, interfaces []metalv1alpha4.Interface, loopbacks Loopbacks, size map[string]string, ) (Machine, errors.BusinessError)
func NewMachine ¶
func (*Machine) SetMachineSizes ¶
type MachineAlreadyExist ¶
type MachineCreatedDomainEvent ¶
type MachineCreatedDomainEvent struct {
// contains filtered or unexported fields
}
func (*MachineCreatedDomainEvent) ID ¶
func (m *MachineCreatedDomainEvent) ID() string
func (*MachineCreatedDomainEvent) Type ¶
func (m *MachineCreatedDomainEvent) Type() string
type MachineID ¶
type MachineID struct {
// contains filtered or unexported fields
}
func NewMachineID ¶
type MachineIDGenerator ¶
type MachineIDGenerator interface {
Generate() MachineID
}
Click to show internal directories.
Click to hide internal directories.