Documentation
¶
Overview ¶
Code generated by MockGen. DO NOT EDIT. Source: ../pkg/environment/types.go
Generated by this command:
mockgen -source ../pkg/environment/types.go -destination ../pkg/environment/mocks.go -package=environment
Package environment is a generated GoMock package.
Index ¶
- Constants
- func AppendPropertySources(propertySources ...properties.PropertySource)
- func GetPropertySources() []properties.PropertySource
- type DefaultEnvironment
- func (environment *DefaultEnvironment) AppendPropertySources(propertySources ...feather_commons_properties.PropertySource)
- func (environment *DefaultEnvironment) GetPropertySources() []feather_commons_properties.PropertySource
- func (environment *DefaultEnvironment) GetValue(property string) EnvVar
- func (environment *DefaultEnvironment) GetValueOrDefault(property string, defaultValue string) EnvVar
- type DefaultEnvironmentOption
- type EnvVar
- type Environment
- type MockEnvironment
- func (m *MockEnvironment) AppendPropertySources(propertySources ...properties.PropertySource)
- func (m *MockEnvironment) EXPECT() *MockEnvironmentMockRecorder
- func (m *MockEnvironment) GetPropertySources() []properties.PropertySource
- func (m *MockEnvironment) GetValue(property string) EnvVar
- func (m *MockEnvironment) GetValueOrDefault(property, defaultValue string) EnvVar
- type MockEnvironmentMockRecorder
- func (mr *MockEnvironmentMockRecorder) AppendPropertySources(propertySources ...any) *gomock.Call
- func (mr *MockEnvironmentMockRecorder) GetPropertySources() *gomock.Call
- func (mr *MockEnvironmentMockRecorder) GetValue(property any) *gomock.Call
- func (mr *MockEnvironmentMockRecorder) GetValueOrDefault(property, defaultValue any) *gomock.Call
Constants ¶
const ( OsPropertySourceName = "OS_PROPERTY_SOURCE_NAME" CmdPropertySourceName = "CMD_PROPERTY_SOURCE_NAME" //nolint:gosec )
Variables ¶
This section is empty.
Functions ¶
func AppendPropertySources ¶ added in v0.70.0
func AppendPropertySources(propertySources ...properties.PropertySource)
func GetPropertySources ¶ added in v0.70.0
func GetPropertySources() []properties.PropertySource
Types ¶
type DefaultEnvironment ¶
type DefaultEnvironment struct {
// contains filtered or unexported fields
}
func NewDefaultEnvironment ¶
func NewDefaultEnvironment(options ...DefaultEnvironmentOption) *DefaultEnvironment
func (*DefaultEnvironment) AppendPropertySources ¶
func (environment *DefaultEnvironment) AppendPropertySources(propertySources ...feather_commons_properties.PropertySource)
func (*DefaultEnvironment) GetPropertySources ¶
func (environment *DefaultEnvironment) GetPropertySources() []feather_commons_properties.PropertySource
func (*DefaultEnvironment) GetValue ¶
func (environment *DefaultEnvironment) GetValue(property string) EnvVar
func (*DefaultEnvironment) GetValueOrDefault ¶
func (environment *DefaultEnvironment) GetValueOrDefault(property string, defaultValue string) EnvVar
type DefaultEnvironmentOption ¶
type DefaultEnvironmentOption func(environment *DefaultEnvironment)
func WithArraySource ¶ added in v0.5.2
func WithArraySource(name string, array []string) DefaultEnvironmentOption
func WithArrays ¶ added in v0.5.2
func WithArrays(osArgsArray []string, cmdArgsArray []string) DefaultEnvironmentOption
func WithPropertySources ¶
func WithPropertySources(propertySources ...feather_commons_properties.PropertySource) DefaultEnvironmentOption
type Environment ¶
type Environment interface { GetValue(property string) EnvVar GetValueOrDefault(property string, defaultValue string) EnvVar GetPropertySources() []feather_commons_properties.PropertySource AppendPropertySources(propertySources ...feather_commons_properties.PropertySource) }
func Custom ¶ added in v0.70.0
func Custom(cmdArgsArray []string) Environment
func Default ¶ added in v0.70.0
func Default() Environment
type MockEnvironment ¶
type MockEnvironment struct {
// contains filtered or unexported fields
}
MockEnvironment is a mock of Environment interface.
func NewMockEnvironment ¶
func NewMockEnvironment(ctrl *gomock.Controller) *MockEnvironment
NewMockEnvironment creates a new mock instance.
func (*MockEnvironment) AppendPropertySources ¶
func (m *MockEnvironment) AppendPropertySources(propertySources ...properties.PropertySource)
AppendPropertySources mocks base method.
func (*MockEnvironment) EXPECT ¶
func (m *MockEnvironment) EXPECT() *MockEnvironmentMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
func (*MockEnvironment) GetPropertySources ¶
func (m *MockEnvironment) GetPropertySources() []properties.PropertySource
GetPropertySources mocks base method.
func (*MockEnvironment) GetValue ¶
func (m *MockEnvironment) GetValue(property string) EnvVar
GetValue mocks base method.
func (*MockEnvironment) GetValueOrDefault ¶
func (m *MockEnvironment) GetValueOrDefault(property, defaultValue string) EnvVar
GetValueOrDefault mocks base method.
type MockEnvironmentMockRecorder ¶
type MockEnvironmentMockRecorder struct {
// contains filtered or unexported fields
}
MockEnvironmentMockRecorder is the mock recorder for MockEnvironment.
func (*MockEnvironmentMockRecorder) AppendPropertySources ¶
func (mr *MockEnvironmentMockRecorder) AppendPropertySources(propertySources ...any) *gomock.Call
AppendPropertySources indicates an expected call of AppendPropertySources.
func (*MockEnvironmentMockRecorder) GetPropertySources ¶
func (mr *MockEnvironmentMockRecorder) GetPropertySources() *gomock.Call
GetPropertySources indicates an expected call of GetPropertySources.
func (*MockEnvironmentMockRecorder) GetValue ¶
func (mr *MockEnvironmentMockRecorder) GetValue(property any) *gomock.Call
GetValue indicates an expected call of GetValue.
func (*MockEnvironmentMockRecorder) GetValueOrDefault ¶
func (mr *MockEnvironmentMockRecorder) GetValueOrDefault(property, defaultValue any) *gomock.Call
GetValueOrDefault indicates an expected call of GetValueOrDefault.