Documentation
¶
Index ¶
- Constants
- Variables
- func ApplyLayer(ctx *ls.Context, g graph.Graph, layer *ls.Layer, reinterpretValues bool) error
- func JoinValues(values []string, delimiter string) string
- func Reingest(ctx *ls.Context, sourceNode graph.Node, target ls.GraphBuilder, ...) error
- type ErrMultipleValues
- type ErrReingest
- type ErrReshape
- type Reshaper
Constants ¶
const TRANSFORM = ls.LS + "transform/"
Variables ¶
var EvaluateTerm = ls.NewTerm(TRANSFORM, "evaluate", false, false, ls.SetComposition, EvaluateTermSemantics)
var EvaluateTermSemantics = evaluateTermSemantics{}
var JoinWithTerm = ls.NewTerm(TRANSFORM, "joinWith", false, false, ls.OverrideComposition, nil)
JoinWithTerm specifies how to join multiple values. JoinWith: " " will join them using a space.
var MapContextSemantics = mapContextSemantics{}
var MapContextTerm = ls.NewTerm(TRANSFORM, "mapContext", false, false, ls.OverrideComposition, MapContextSemantics)
MapContextTerm gives an opencypher expression that results in a node. That node will be used as the context for the map operations under that node
var MapPropertyTerm = ls.NewTerm(TRANSFORM, "mapProperty", false, false, ls.OverrideComposition, nil)
MapPropertyTerm defines the name of the property in the source graph nodes that contain the mapped schema node id. The contents of the nodes under the mapContext that have prop:schemaNodeId will be assigned to the current node
var MultipleTerm = ls.NewTerm(TRANSFORM, "multi", false, false, ls.OverrideComposition, nil)
MultipleTerm is used to specify if multiple values are allowed. If so, one node will be constructed for each value
var ValueExprTerm = ls.NewTerm(TRANSFORM, "valueExpr", false, false, ls.OverrideComposition, ValueExprTermSemantics)
var ValueExprTermSemantics = valueExprTermSemantics{}
Functions ¶
func ApplyLayer ¶
ApplyLayer applies the given layer onto the graph.
The annotations of the given layer will be composed with all matching nodes of the graph. If reinterpretValues is set, the operation will get the node value, compose, and set it back, so this can be used for type conversions.
func JoinValues ¶
Types ¶
type ErrMultipleValues ¶
type ErrMultipleValues struct{}
func (ErrMultipleValues) Error ¶
func (e ErrMultipleValues) Error() string
type ErrReingest ¶
func (ErrReingest) Error ¶
func (e ErrReingest) Error() string
func (ErrReingest) Unwrap ¶
func (e ErrReingest) Unwrap() error
type ErrReshape ¶
func (ErrReshape) Error ¶
func (e ErrReshape) Error() string
func (ErrReshape) Unwrap ¶
func (e ErrReshape) Unwrap() error