Documentation ¶
Index ¶
- func Create(g *d2graph.Graph, boardPath []string, key string) (_ *d2graph.Graph, newKey string, err error)
- func Delete(g *d2graph.Graph, boardPath []string, key string) (_ *d2graph.Graph, err error)
- func DeleteIDDeltas(g *d2graph.Graph, boardPath []string, key string) (deltas map[string]string, err error)
- func GetBoardGraph(g *d2graph.Graph, boardPath []string) *d2graph.Graph
- func GetChildrenIDs(g *d2graph.Graph, boardPath []string, absID string) (ids []string, _ error)
- func GetEdge(g *d2graph.Graph, boardPath []string, absID string) *d2graph.Edge
- func GetID(key string) string
- func GetObj(g *d2graph.Graph, boardPath []string, absID string) *d2graph.Object
- func GetObjOrder(g *d2graph.Graph, boardPath []string) ([]string, error)
- func GetParentID(g *d2graph.Graph, boardPath []string, absID string) (string, error)
- func IsLabelKeyID(key, label string) bool
- func Move(g *d2graph.Graph, boardPath []string, key, newKey string, ...) (_ *d2graph.Graph, err error)
- func MoveIDDeltas(g *d2graph.Graph, key, newKey string, includeDescendants bool) (deltas map[string]string, err error)
- func ReconnectEdge(g *d2graph.Graph, boardPath []string, edgeKey string, srcKey, dstKey *string) (_ *d2graph.Graph, err error)
- func ReconnectEdgeIDDeltas(g *d2graph.Graph, boardPath []string, edgeKey string, srcKey, dstKey *string) (deltas map[string]string, err error)
- func Rename(g *d2graph.Graph, boardPath []string, key, newName string) (_ *d2graph.Graph, newKey string, err error)
- func RenameIDDeltas(g *d2graph.Graph, boardPath []string, key, newName string) (deltas map[string]string, err error)
- func ReparentIDDelta(g *d2graph.Graph, boardPath []string, key, parentKey string) (string, error)
- func ReplaceBoardNode(ast, ast2 *d2ast.Map, boardPath []string) bool
- func Set(g *d2graph.Graph, boardPath []string, key string, tag, value *string) (_ *d2graph.Graph, err error)
- type OutsideScopeError
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DeleteIDDeltas ¶
func GetChildrenIDs ¶
func GetParentID ¶
func IsLabelKeyID ¶
func Move ¶
func Move(g *d2graph.Graph, boardPath []string, key, newKey string, includeDescendants bool) (_ *d2graph.Graph, err error)
Does not handle edge keys, on account of edge keys can only be reserved, e.g. (a->b).style.color: red
func MoveIDDeltas ¶
func ReconnectEdge ¶
func ReconnectEdgeIDDeltas ¶
func RenameIDDeltas ¶
func ReparentIDDelta ¶
Types ¶
type OutsideScopeError ¶
type OutsideScopeError struct{}
func (OutsideScopeError) Error ¶
func (e OutsideScopeError) Error() string
Click to show internal directories.
Click to hide internal directories.