Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DefinitionClient ¶
type DefinitionClient interface { GetWorkloadDefinition(name string) (*v1alpha2.WorkloadDefinition, error) GetTraitDefition(name string) (*v1alpha2.TraitDefinition, error) }
DefinitionClient is a interface
type Factory ¶
type Factory struct {
// contains filtered or unexported fields
}
Factory can get wd|td|app
func NewDefinitionClient ¶
NewDefinitionClient generate definition fetcher
func (*Factory) GetTraitDefition ¶
func (f *Factory) GetTraitDefition(name string) (*v1alpha2.TraitDefinition, error)
GetTraitDefition Get TraitDefition
func (*Factory) GetWorkloadDefinition ¶
func (f *Factory) GetWorkloadDefinition(name string) (*v1alpha2.WorkloadDefinition, error)
GetWorkloadDefinition Get WorkloadDefinition
type MockClient ¶
type MockClient struct {
// contains filtered or unexported fields
}
MockClient simulate the behavior of client
func (*MockClient) AddTD ¶
func (mock *MockClient) AddTD(s string) error
AddTD add triat definition to Mock Manager
func (*MockClient) AddWD ¶
func (mock *MockClient) AddWD(s string) error
AddWD add workload definition to Mock Manager
func (*MockClient) GetTraitDefition ¶
func (mock *MockClient) GetTraitDefition(name string) (*v1alpha2.TraitDefinition, error)
GetTraitDefition Get TraitDefition
func (*MockClient) GetWorkloadDefinition ¶
func (mock *MockClient) GetWorkloadDefinition(name string) (*v1alpha2.WorkloadDefinition, error)
GetWorkloadDefinition Get WorkloadDefinition
Click to show internal directories.
Click to hide internal directories.