Documentation
¶
Index ¶
- Constants
- type AcyclicGraph
- func (g *AcyclicGraph) AddEdge(from, to string) error
- func (g *AcyclicGraph) AddVertex(value interface{}) (string, error)
- func (g *AcyclicGraph) GetOrder() int
- func (g *AcyclicGraph) GetSize() int
- func (g *AcyclicGraph) GetVertex(id string) (*node, error)
- func (g *AcyclicGraph) TraverseBF(tAction traverseAction)
- func (g *AcyclicGraph) TraverseBFFrom(start string, tAction traverseAction)
- type CircularDependencyError
- type ConfigType
- type DuplicateEdgeError
- type EdgeCycleError
- type EdgeExistsError
- type IDInterface
- type InjectorError
- type InvalidLifetimeError
- type ServiceError
- type Traverser
- type UnknownError
- type VertexExistsError
Constants ¶
View Source
const StaticLifetime string = "Static"
Constant to ID Static lifetimes
View Source
const TransientLifetime string = "Transient"
Constant to ID Transient lifetimes
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AcyclicGraph ¶
type AcyclicGraph struct {
// contains filtered or unexported fields
}
AcyclicGraph represents a directed acyclic AcyclicGraph
func (*AcyclicGraph) AddEdge ¶
func (g *AcyclicGraph) AddEdge(from, to string) error
AddEdge adds a directed edge from one node to another
func (*AcyclicGraph) AddVertex ¶
func (g *AcyclicGraph) AddVertex(value interface{}) (string, error)
AddVertex adds a node to the graph
func (*AcyclicGraph) GetOrder ¶
func (g *AcyclicGraph) GetOrder() int
func (*AcyclicGraph) GetSize ¶
func (g *AcyclicGraph) GetSize() int
func (*AcyclicGraph) GetVertex ¶
func (g *AcyclicGraph) GetVertex(id string) (*node, error)
func (*AcyclicGraph) TraverseBF ¶
func (g *AcyclicGraph) TraverseBF(tAction traverseAction)
Traverse the entire graph breadth-first
func (*AcyclicGraph) TraverseBFFrom ¶
func (g *AcyclicGraph) TraverseBFFrom(start string, tAction traverseAction)
Traverse the graph breadth-first from a specified start node ID
type CircularDependencyError ¶
type CircularDependencyError struct { SpecType reflect.Type // contains filtered or unexported fields }
func NewCircularDependencyError ¶
func NewCircularDependencyError(err error, spec reflect.Type) *CircularDependencyError
func (*CircularDependencyError) Error ¶
func (e *CircularDependencyError) Error() string
type ConfigType ¶ added in v0.4.0
type ConfigType int
const ( JsonConfig ConfigType = iota YamlConfig )
type DuplicateEdgeError ¶
type DuplicateEdgeError struct { VertexId string SpecType reflect.Type // contains filtered or unexported fields }
func NewDuplicateEdgeError ¶
func NewDuplicateEdgeError(err error, id string, spec reflect.Type) *DuplicateEdgeError
func (*DuplicateEdgeError) Error ¶
func (e *DuplicateEdgeError) Error() string
type EdgeCycleError ¶
type EdgeCycleError struct{}
func (*EdgeCycleError) Error ¶
func (e *EdgeCycleError) Error() string
type EdgeExistsError ¶
type EdgeExistsError struct{}
func (*EdgeExistsError) Error ¶
func (e *EdgeExistsError) Error() string
type IDInterface ¶
type IDInterface interface {
ID() string
}
type InjectorError ¶
func NewInjectorError ¶
func NewInjectorError(spec reflect.Type) *InjectorError
func (*InjectorError) Error ¶
func (e *InjectorError) Error() string
type InvalidLifetimeError ¶
type InvalidLifetimeError struct { SpecType reflect.Type // contains filtered or unexported fields }
func NewInvalidLifetimeError ¶
func NewInvalidLifetimeError(err error, spec reflect.Type) *InvalidLifetimeError
func (*InvalidLifetimeError) Error ¶
func (e *InvalidLifetimeError) Error() string
type ServiceError ¶
func NewServiceError ¶
func NewServiceError(spec reflect.Type, impl reflect.Type) *ServiceError
func (*ServiceError) Error ¶
func (e *ServiceError) Error() string
type UnknownError ¶
type UnknownError struct {
// contains filtered or unexported fields
}
func NewUnknownError ¶
func NewUnknownError(err error) *UnknownError
func (*UnknownError) Error ¶
func (e *UnknownError) Error() string
type VertexExistsError ¶
type VertexExistsError struct{}
func (*VertexExistsError) Error ¶
func (e *VertexExistsError) Error() string
Click to show internal directories.
Click to hide internal directories.