Documentation
¶
Index ¶
- type Area
- type CacherDiscoverer
- type DijkstrasDiscoverer
- type Discoverer
- type HashmapSight
- func (h *HashmapSight) Access(dot types.Dot) (interface{}, bool)
- func (h *HashmapSight) AccessDefault(dot types.Dot, defaultValue interface{}) interface{}
- func (h *HashmapSight) Assign(dot types.Dot, v interface{})
- func (h *HashmapSight) Flush()
- func (h *HashmapSight) ForEach(f func(dot types.Dot, v interface{}))
- func (h *HashmapSight) Reflect() *HashmapSight
- type Map
- type Position
- type Queue
- type Sight
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Area ¶
func (Area) FitDistance ¶
type CacherDiscoverer ¶
type CacherDiscoverer struct {
// contains filtered or unexported fields
}
func (*CacherDiscoverer) Discover ¶
func (d *CacherDiscoverer) Discover(head types.Dot, area Area, sight Sight, scores *HashmapSight) []types.Dot
type DijkstrasDiscoverer ¶
type DijkstrasDiscoverer struct {
// contains filtered or unexported fields
}
DijkstrasDiscoverer discoves paths. It is based on Dijkstra's algorithm.
Link: https://en.wikipedia.org/wiki/Dijkstra%27s_algorithm
func (*DijkstrasDiscoverer) Discover ¶
func (d *DijkstrasDiscoverer) Discover(head types.Dot, area Area, sight Sight, scores *HashmapSight) []types.Dot
type Discoverer ¶
type Discoverer interface { Discover(head types.Dot, area Area, sight Sight, scores *HashmapSight) []types.Dot }
func NewCacherDiscoverer ¶
func NewCacherDiscoverer(discoverer Discoverer) Discoverer
func NewDijkstrasDiscoverer ¶
func NewDijkstrasDiscoverer(r *rand.Rand) Discoverer
type HashmapSight ¶
type HashmapSight struct {
// contains filtered or unexported fields
}
func NewHashmapSight ¶
func NewHashmapSight(s Sight) *HashmapSight
func (*HashmapSight) AccessDefault ¶
func (h *HashmapSight) AccessDefault(dot types.Dot, defaultValue interface{}) interface{}
func (*HashmapSight) Assign ¶
func (h *HashmapSight) Assign(dot types.Dot, v interface{})
func (*HashmapSight) Flush ¶
func (h *HashmapSight) Flush()
func (*HashmapSight) ForEach ¶
func (h *HashmapSight) ForEach(f func(dot types.Dot, v interface{}))
func (*HashmapSight) Reflect ¶
func (h *HashmapSight) Reflect() *HashmapSight
type Map ¶
type Map struct {
// contains filtered or unexported fields
}
func (*Map) LookAround ¶
func (m *Map) LookAround(s Sight) *HashmapSight
func (*Map) SaveObject ¶
Click to show internal directories.
Click to hide internal directories.