func (e *Edge) From() store.Node {
	return e.from
}
From returns the from node of the edge
package entity
import (
	"github.com/milosgajdos/kraph/pkg/attrs"
	"github.com/milosgajdos/kraph/pkg/metadata"
	"github.com/milosgajdos/kraph/pkg/store"
	"gonum.org/v1/gonum/graph/encoding"
)
type Edge struct {
	uid  string
	from store.Node
	to   store.Node
	opts Options
}
func NewEdge(uid string, from, to store.Node, opts ...Option) *Edge {
	edgeOpts := NewOptions()
	for _, apply := range opts {
		apply(&edgeOpts)
	}
	return &Edge{
		uid:  uid,
		from: from,
		to:   to,
		opts: edgeOpts,
	}
}
func (e *Edge) UID() string {
	return e.uid
}
func (e *Edge) Attrs() attrs.Attrs {
	return e.opts.Attrs
}
func (e *Edge) Attributes() []encoding.Attribute {
	return attrs.DOTAttrs(e.opts.Attrs)
}
func (e *Edge) Metadata() metadata.Metadata {
	return e.opts.Metadata
}