CreateValueEdge returns a DirectedEdge with the given subject. The predicate, language, and facet values are derived from the NQuad.
(subjectUid uint64)
| 132 | // CreateValueEdge returns a DirectedEdge with the given subject. The predicate, |
| 133 | // language, and facet values are derived from the NQuad. |
| 134 | func (nq NQuad) CreateValueEdge(subjectUid uint64) (*pb.DirectedEdge, error) { |
| 135 | var err error |
| 136 | |
| 137 | out := nq.createEdgePrototype(subjectUid) |
| 138 | if err = copyValue(out, nq); err != nil { |
| 139 | return &emptyEdge, err |
| 140 | } |
| 141 | return out, nil |
| 142 | } |
| 143 | |
| 144 | // ToDeletePredEdge takes an NQuad of the form '* p *' and returns the equivalent |
| 145 | // directed edge. Returns an error if the NQuad does not have the expected form. |
no test coverage detected