Documentation ¶
Index ¶
- func GetPullerPlan(storage Storage) (PullerPlan, *Error)
- type Cycle
- type CycleList
- type Error
- func Create(startTable string, relReader RelationReader, storage Storage) *Error
- func Export(storage Storage, exporter Exporter) *Error
- func SetChildLookup(relation string, flag bool, storage Storage) *Error
- func SetParentLookup(relation string, flag bool, storage Storage) *Error
- func SetStartTable(table Table, storage Storage) *Error
- type Exporter
- type IngressDescriptor
- type IngressRelation
- type IngressRelationList
- type MockCycle
- type MockCycleList
- type MockExporter
- type MockIngressDescriptor
- type MockIngressRelation
- type MockIngressRelationList
- type MockPullerPlan
- type MockRelation
- type MockRelationList
- type MockRelationReader
- type MockStep
- func (_m *MockStep) Cycles() CycleList
- func (_m *MockStep) Entry() Table
- func (_m *MockStep) Following() IngressRelation
- func (_m *MockStep) Index() uint
- func (_m *MockStep) PreviousStep() uint
- func (_m *MockStep) Relations() IngressRelationList
- func (_m *MockStep) String() string
- func (_m *MockStep) Tables() TableList
- type MockStorage
- type MockTable
- type MockTableList
- type PullerPlan
- type Relation
- type RelationList
- type RelationReader
- type Step
- type Storage
- type Table
- type TableList
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetPullerPlan ¶
func GetPullerPlan(storage Storage) (PullerPlan, *Error)
GetPullerPlan returns the calculated puller plan.
Types ¶
type CycleList ¶
A CycleList in the puller plan.
func NewCycleList ¶
func NewCycleList(cycles []IngressRelationList) CycleList
NewCycleList initialize a new CycleList object
type Error ¶
type Error struct {
Description string
}
Error is the error type returned by the domain
func Create ¶
func Create(startTable string, relReader RelationReader, storage Storage) *Error
Create and store ingress descriptor for the given start table and relation set.
func SetChildLookup ¶
SetChildLookup update child lookup relation's parameter in ingress descriptor
func SetParentLookup ¶
SetParentLookup update parent lookup relation's parameter in ingress descriptor
func SetStartTable ¶
SetStartTable update ingress descriptor start table
type Exporter ¶
type Exporter interface {
Export(PullerPlan) *Error
}
Exporter export the puller plan.
type IngressDescriptor ¶
type IngressDescriptor interface { StartTable() Table Relations() IngressRelationList String() string }
IngressDescriptor from which the puller plan will be computed.
func NewIngressDescriptor ¶
func NewIngressDescriptor(start Table, relations IngressRelationList) IngressDescriptor
NewIngressDescriptor initialize a new IngressDescriptor object
type IngressRelation ¶
IngressRelation describe how a relation will be accessed.
func NewIngressRelation ¶
func NewIngressRelation(rel Relation, lookUpParent bool, lookUpChild bool) IngressRelation
NewIngressRelation initialize a new IngressRelation object
type IngressRelationList ¶
type IngressRelationList interface { Len() uint Relation(idx uint) IngressRelation Contains(string) bool String() string }
IngressRelationList involved in an puller plan.
func NewIngressRelationList ¶
func NewIngressRelationList(relations []IngressRelation) IngressRelationList
NewIngressRelationList initialize a new IngressRelationList object
type MockCycle ¶
MockCycle is an autogenerated mock type for the Cycle type
func (*MockCycle) Relation ¶
func (_m *MockCycle) Relation(idx uint) IngressRelation
Relation provides a mock function with given fields: idx
type MockCycleList ¶
MockCycleList is an autogenerated mock type for the CycleList type
func (*MockCycleList) Cycle ¶
func (_m *MockCycleList) Cycle(idx uint) Cycle
Cycle provides a mock function with given fields: idx
func (*MockCycleList) Len ¶
func (_m *MockCycleList) Len() uint
Len provides a mock function with given fields:
func (*MockCycleList) String ¶
func (_m *MockCycleList) String() string
String provides a mock function with given fields:
type MockExporter ¶
MockExporter is an autogenerated mock type for the Exporter type
func (*MockExporter) Export ¶
func (_m *MockExporter) Export(_a0 PullerPlan) *Error
Export provides a mock function with given fields: _a0
type MockIngressDescriptor ¶
MockIngressDescriptor is an autogenerated mock type for the IngressDescriptor type
func (*MockIngressDescriptor) Relations ¶
func (_m *MockIngressDescriptor) Relations() IngressRelationList
Relations provides a mock function with given fields:
func (*MockIngressDescriptor) StartTable ¶
func (_m *MockIngressDescriptor) StartTable() Table
StartTable provides a mock function with given fields:
func (*MockIngressDescriptor) String ¶
func (_m *MockIngressDescriptor) String() string
String provides a mock function with given fields:
type MockIngressRelation ¶
MockIngressRelation is an autogenerated mock type for the IngressRelation type
func (*MockIngressRelation) Child ¶
func (_m *MockIngressRelation) Child() Table
Child provides a mock function with given fields:
func (*MockIngressRelation) LookUpChild ¶
func (_m *MockIngressRelation) LookUpChild() bool
LookUpChild provides a mock function with given fields:
func (*MockIngressRelation) LookUpParent ¶
func (_m *MockIngressRelation) LookUpParent() bool
LookUpParent provides a mock function with given fields:
func (*MockIngressRelation) Name ¶
func (_m *MockIngressRelation) Name() string
Name provides a mock function with given fields:
func (*MockIngressRelation) Parent ¶
func (_m *MockIngressRelation) Parent() Table
Parent provides a mock function with given fields:
func (*MockIngressRelation) String ¶
func (_m *MockIngressRelation) String() string
String provides a mock function with given fields:
type MockIngressRelationList ¶
MockIngressRelationList is an autogenerated mock type for the IngressRelationList type
func (*MockIngressRelationList) Contains ¶
func (_m *MockIngressRelationList) Contains(_a0 string) bool
Contains provides a mock function with given fields: _a0
func (*MockIngressRelationList) Len ¶
func (_m *MockIngressRelationList) Len() uint
Len provides a mock function with given fields:
func (*MockIngressRelationList) Relation ¶
func (_m *MockIngressRelationList) Relation(idx uint) IngressRelation
Relation provides a mock function with given fields: idx
func (*MockIngressRelationList) String ¶
func (_m *MockIngressRelationList) String() string
String provides a mock function with given fields:
type MockPullerPlan ¶
MockPullerPlan is an autogenerated mock type for the PullerPlan type
func (*MockPullerPlan) Len ¶
func (_m *MockPullerPlan) Len() uint
Len provides a mock function with given fields:
func (*MockPullerPlan) Relations ¶
func (_m *MockPullerPlan) Relations() IngressRelationList
Relations provides a mock function with given fields:
func (*MockPullerPlan) Step ¶
func (_m *MockPullerPlan) Step(idx uint) Step
Step provides a mock function with given fields: idx
func (*MockPullerPlan) String ¶
func (_m *MockPullerPlan) String() string
String provides a mock function with given fields:
func (*MockPullerPlan) Tables ¶
func (_m *MockPullerPlan) Tables() TableList
Tables provides a mock function with given fields:
type MockRelation ¶
MockRelation is an autogenerated mock type for the Relation type
func (*MockRelation) Child ¶
func (_m *MockRelation) Child() Table
Child provides a mock function with given fields:
func (*MockRelation) Name ¶
func (_m *MockRelation) Name() string
Name provides a mock function with given fields:
func (*MockRelation) Parent ¶
func (_m *MockRelation) Parent() Table
Parent provides a mock function with given fields:
func (*MockRelation) String ¶
func (_m *MockRelation) String() string
String provides a mock function with given fields:
type MockRelationList ¶
MockRelationList is an autogenerated mock type for the RelationList type
func (*MockRelationList) Contains ¶
func (_m *MockRelationList) Contains(_a0 string) bool
Contains provides a mock function with given fields: _a0
func (*MockRelationList) Len ¶
func (_m *MockRelationList) Len() uint
Len provides a mock function with given fields:
func (*MockRelationList) Relation ¶
func (_m *MockRelationList) Relation(idx uint) Relation
Relation provides a mock function with given fields: idx
func (*MockRelationList) String ¶
func (_m *MockRelationList) String() string
String provides a mock function with given fields:
type MockRelationReader ¶
MockRelationReader is an autogenerated mock type for the RelationReader type
func (*MockRelationReader) Read ¶
func (_m *MockRelationReader) Read() (RelationList, *Error)
Read provides a mock function with given fields:
type MockStep ¶
MockStep is an autogenerated mock type for the Step type
func (*MockStep) Following ¶
func (_m *MockStep) Following() IngressRelation
Following provides a mock function with given fields:
func (*MockStep) PreviousStep ¶
PreviousStep provides a mock function with given fields:
func (*MockStep) Relations ¶
func (_m *MockStep) Relations() IngressRelationList
Relations provides a mock function with given fields:
type MockStorage ¶
MockStorage is an autogenerated mock type for the Storage type
func (*MockStorage) Read ¶
func (_m *MockStorage) Read() (IngressDescriptor, *Error)
Read provides a mock function with given fields:
func (*MockStorage) Store ¶
func (_m *MockStorage) Store(_a0 IngressDescriptor) *Error
Store provides a mock function with given fields: _a0
type MockTable ¶
MockTable is an autogenerated mock type for the Table type
type MockTableList ¶
MockTableList is an autogenerated mock type for the TableList type
func (*MockTableList) Contains ¶
func (_m *MockTableList) Contains(_a0 string) bool
Contains provides a mock function with given fields: _a0
func (*MockTableList) Len ¶
func (_m *MockTableList) Len() uint
Len provides a mock function with given fields:
func (*MockTableList) String ¶
func (_m *MockTableList) String() string
String provides a mock function with given fields:
func (*MockTableList) Table ¶
func (_m *MockTableList) Table(idx uint) Table
Table provides a mock function with given fields: idx
type PullerPlan ¶
type PullerPlan interface { Len() uint Step(idx uint) Step Relations() IngressRelationList Tables() TableList String() string }
PullerPlan is the computed plan that lists all steps required to pull data.
func NewPullerPlan ¶
func NewPullerPlan(steps []Step, relations IngressRelationList, tables TableList) PullerPlan
NewPullerPlan initialize a new PullerPlan object
type RelationList ¶
type RelationList interface { Len() uint Relation(idx uint) Relation Contains(string) bool String() string }
RelationList involved in an puller plan.
func NewRelationList ¶
func NewRelationList(relations []Relation) RelationList
NewRelationList initialize a new RelationList object
type RelationReader ¶
type RelationReader interface {
Read() (RelationList, *Error)
}
RelationReader read relations from a source.
type Step ¶
type Step interface { Index() uint Entry() Table Following() IngressRelation Relations() IngressRelationList Tables() TableList Cycles() CycleList PreviousStep() uint String() string }
An Step gives required information to pull data.
func NewStep ¶
func NewStep(index uint, entry Table, following IngressRelation, relations IngressRelationList, tables TableList, cycles CycleList, previousStep uint) Step
NewStep initialize a new Step object
type Storage ¶
type Storage interface { Store(IngressDescriptor) *Error Read() (IngressDescriptor, *Error) }
Storage allows to store and retrieve ingress descriptor objects.
Source Files ¶
- driven.go
- driver.go
- graph.go
- graph_condense.go
- graph_connect.go
- graph_cycles.go
- graph_traverse.go
- mock_Cycle.go
- mock_CycleList.go
- mock_Exporter.go
- mock_IngressDescriptor.go
- mock_IngressRelation.go
- mock_IngressRelationList.go
- mock_PullerPlan.go
- mock_Relation.go
- mock_RelationList.go
- mock_RelationReader.go
- mock_Step.go
- mock_Storage.go
- mock_Table.go
- mock_TableList.go
- model.go
- model_ad.go
- model_cycle.go
- model_relation.go
- model_step.go
- model_table.go
- set.go
- stack.go