graph.getNeighbors(element [, opt])
Get all the neighbors of element
in the graph. Neighbors are all the elements connected
to element
via either an inbound or an outbound link. If opt.inbound
is true
,
only inbound neighbords (all neighbors connected with a link who's target
is the element
) will be returned. Similarly, if opt.outbound
is true
, only
outbound neighbors will be returned. If opt.deep
is true
,
return also all the neighbors of all the elements embedded inside element
.