Documentation
¶
Index ¶
- func InitializeDefault() error
- type Container
- func (c *Container) CreateLogger(component string) domain.Logger
- func (c *Container) GetBedrockRepository() repository.BedrockRepository
- func (c *Container) GetBedrockService() usecase.BedrockService
- func (c *Container) GetCLIController() interface{}
- func (c *Container) GetCSVExportService() usecase.CSVExportService
- func (c *Container) GetCcRepository() repository.CcRepository
- func (c *Container) GetCcService() usecase.CcService
- func (c *Container) GetConfig() *config.AppConfig
- func (c *Container) GetConfigRepository() repository.ConfigRepository
- func (c *Container) GetConfigService() usecase.ConfigService
- func (c *Container) GetConsolePresenter() presenter.ConsolePresenter
- func (c *Container) GetCursorAPIRepository() repository.CursorAPIRepository
- func (c *Container) GetCursorService() usecase.CursorService
- func (c *Container) GetCursorTokenRepository() repository.CursorTokenRepository
- func (c *Container) GetDaemonController() interface{}
- func (c *Container) GetJSONPresenter() presenter.JSONPresenter
- func (c *Container) GetLogger() domain.Logger
- func (c *Container) GetLoggerFactory() domain.LoggerFactory
- func (c *Container) GetMetricsRepository() repository.MetricsRepository
- func (c *Container) GetMetricsService() usecase.MetricsService
- func (c *Container) GetRestartManager() usecase.RestartManager
- func (c *Container) GetStatusService() usecase.StatusService
- func (c *Container) GetSystrayController() interface{}
- func (c *Container) GetTimezoneService() repository.TimezoneService
- func (c *Container) GetVertexAIRepository() repository.VertexAIRepository
- func (c *Container) GetVertexAIService() usecase.VertexAIService
- func (c *Container) InitDaemonComponents() error
- type ContainerBuilder
- func (b *ContainerBuilder) Build() (*Container, error)
- func (b *ContainerBuilder) WithCcRepository(repo repository.CcRepository) *ContainerBuilder
- func (b *ContainerBuilder) WithConfig(cfg *config.AppConfig) *ContainerBuilder
- func (b *ContainerBuilder) WithConfigRepository(repo repository.ConfigRepository) *ContainerBuilder
- func (b *ContainerBuilder) WithCursorAPIRepository(repo repository.CursorAPIRepository) *ContainerBuilder
- func (b *ContainerBuilder) WithCursorTokenRepository(repo repository.CursorTokenRepository) *ContainerBuilder
- func (b *ContainerBuilder) WithMetricsRepository(repo repository.MetricsRepository) *ContainerBuilder
- type ContainerOption
- type DarwinContainer
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func InitializeDefault ¶
func InitializeDefault() error
InitializeDefault initializes the default container
Types ¶
type Container ¶
type Container struct {
// contains filtered or unexported fields
}
Container is the dependency injection container
func GetDefaultContainer ¶
GetDefaultContainer returns the default container
func NewContainer ¶
func NewContainer(opts ...ContainerOption) (*Container, error)
NewContainer creates a new DI container
func (*Container) CreateLogger ¶
CreateLogger creates a new logger for a specific component
func (*Container) GetBedrockRepository ¶ added in v1.0.10
func (c *Container) GetBedrockRepository() repository.BedrockRepository
GetBedrockRepository returns the Bedrock repository
func (*Container) GetBedrockService ¶ added in v1.0.10
func (c *Container) GetBedrockService() usecase.BedrockService
GetBedrockService returns the Bedrock service
func (*Container) GetCLIController ¶
func (c *Container) GetCLIController() interface{}
GetCLIController returns the CLI controller
func (*Container) GetCSVExportService ¶ added in v1.0.12
func (c *Container) GetCSVExportService() usecase.CSVExportService
GetCSVExportService returns the CSV export service
func (*Container) GetCcRepository ¶
func (c *Container) GetCcRepository() repository.CcRepository
GetCcRepository returns the usage repository
func (*Container) GetCcService ¶
GetCcService returns the usage service
func (*Container) GetConfigRepository ¶
func (c *Container) GetConfigRepository() repository.ConfigRepository
GetConfigRepository returns the config repository
func (*Container) GetConfigService ¶
func (c *Container) GetConfigService() usecase.ConfigService
GetConfigService returns the config service
func (*Container) GetConsolePresenter ¶
func (c *Container) GetConsolePresenter() presenter.ConsolePresenter
GetConsolePresenter returns the console presenter
func (*Container) GetCursorAPIRepository ¶
func (c *Container) GetCursorAPIRepository() repository.CursorAPIRepository
GetCursorAPIRepository returns the Cursor API repository
func (*Container) GetCursorService ¶
func (c *Container) GetCursorService() usecase.CursorService
GetCursorService returns the Cursor service
func (*Container) GetCursorTokenRepository ¶
func (c *Container) GetCursorTokenRepository() repository.CursorTokenRepository
GetCursorTokenRepository returns the Cursor token repository
func (*Container) GetDaemonController ¶
func (c *Container) GetDaemonController() interface{}
GetDaemonController returns nil on non-Darwin platforms
func (*Container) GetJSONPresenter ¶
func (c *Container) GetJSONPresenter() presenter.JSONPresenter
GetJSONPresenter returns the JSON presenter
func (*Container) GetLoggerFactory ¶
func (c *Container) GetLoggerFactory() domain.LoggerFactory
GetLoggerFactory returns the logger factory
func (*Container) GetMetricsRepository ¶
func (c *Container) GetMetricsRepository() repository.MetricsRepository
GetMetricsRepository returns the metrics repository
func (*Container) GetMetricsService ¶
func (c *Container) GetMetricsService() usecase.MetricsService
GetMetricsService returns the metrics service
func (*Container) GetRestartManager ¶
func (c *Container) GetRestartManager() usecase.RestartManager
GetRestartManager returns the restart manager
func (*Container) GetStatusService ¶
func (c *Container) GetStatusService() usecase.StatusService
GetStatusService returns the status service
func (*Container) GetSystrayController ¶
func (c *Container) GetSystrayController() interface{}
GetSystrayController returns nil on non-Darwin platforms
func (*Container) GetTimezoneService ¶
func (c *Container) GetTimezoneService() repository.TimezoneService
GetTimezoneService returns the timezone service
func (*Container) GetVertexAIRepository ¶ added in v1.0.10
func (c *Container) GetVertexAIRepository() repository.VertexAIRepository
GetVertexAIRepository returns the Vertex AI repository
func (*Container) GetVertexAIService ¶ added in v1.0.10
func (c *Container) GetVertexAIService() usecase.VertexAIService
GetVertexAIService returns the Vertex AI service
func (*Container) InitDaemonComponents ¶ added in v1.0.9
InitDaemonComponents initializes daemon components on demand
type ContainerBuilder ¶
type ContainerBuilder struct {
// contains filtered or unexported fields
}
ContainerBuilder builds a custom container
func NewContainerBuilder ¶
func NewContainerBuilder() *ContainerBuilder
NewContainerBuilder creates a new container builder
func (*ContainerBuilder) Build ¶
func (b *ContainerBuilder) Build() (*Container, error)
Build builds the container with custom components
func (*ContainerBuilder) WithCcRepository ¶
func (b *ContainerBuilder) WithCcRepository(repo repository.CcRepository) *ContainerBuilder
WithCcRepository sets a custom usage repository
func (*ContainerBuilder) WithConfig ¶
func (b *ContainerBuilder) WithConfig(cfg *config.AppConfig) *ContainerBuilder
WithConfig sets a custom configuration
func (*ContainerBuilder) WithConfigRepository ¶
func (b *ContainerBuilder) WithConfigRepository(repo repository.ConfigRepository) *ContainerBuilder
WithConfigRepository sets a custom config repository
func (*ContainerBuilder) WithCursorAPIRepository ¶
func (b *ContainerBuilder) WithCursorAPIRepository(repo repository.CursorAPIRepository) *ContainerBuilder
WithCursorAPIRepository sets a custom Cursor API repository
func (*ContainerBuilder) WithCursorTokenRepository ¶
func (b *ContainerBuilder) WithCursorTokenRepository(repo repository.CursorTokenRepository) *ContainerBuilder
WithCursorTokenRepository sets a custom Cursor token repository
func (*ContainerBuilder) WithMetricsRepository ¶
func (b *ContainerBuilder) WithMetricsRepository(repo repository.MetricsRepository) *ContainerBuilder
WithMetricsRepository sets a custom metrics repository
type ContainerOption ¶
type ContainerOption func(*Container)
ContainerOption is a function that configures the container
func WithBedrockEnabled ¶ added in v1.0.10
func WithBedrockEnabled(enabled bool) ContainerOption
WithBedrockEnabled sets the Bedrock enabled mode
func WithDebugMode ¶
func WithDebugMode(debug bool) ContainerOption
WithDebugMode sets the debug mode
func WithVertexAIEnabled ¶ added in v1.0.10
func WithVertexAIEnabled(enabled bool) ContainerOption
WithVertexAIEnabled sets the Vertex AI enabled mode
type DarwinContainer ¶ added in v1.0.10
type DarwinContainer struct{}
DarwinContainer holds Darwin-specific components (stub for non-Darwin)