class Rubyvis::Layout::Network::Link

Represents a link in a network layout. This class mostly serves to document the attributes that are used on links in network layouts. For hierarchical layouts, this class is used to represent the parent-child links.

@see pv.Layout.Network @name pv.Layout.Network.Link

Attributes

source[RW]

Alias for sourceNode, as expressed by the index of the source node. This attribute is not populated automatically, but may be used as a more convenient identification of the link’s source, for example in a static JSON representation.

@type number

source_node[RW]

The link’s source node. If not set, this value will be derived from the source attribute index.

@type pv.Layout.Network.Node

target[RW]

Alias for targetNode, as expressed by the index of the target node. This attribute is not populated automatically, but may be used as a more convenient identification of the link’s target, for example in a static JSON representation.

@type number

target_node[RW]

The link’s target node. If not set, this value will be derived from the target attribute index.

@type pv.Layout.Network.Node

value[RW]

Alias for linkValue. This attribute is not populated automatically, but may be used instead of the linkValue attribute when specifying links.

@type number

Public Class Methods

new(opts) click to toggle source
# File lib/rubyvis/layout/network.rb, line 287
def initialize(opts)
  @source_node=opts.delete :source_node
  @target_node=opts.delete :target_node
  @link_value=opts.delete :link_value
end