gEdge-class              package:graph              R Documentation

_C_l_a_s_s "_g_E_d_g_e"

_D_e_s_c_r_i_p_t_i_o_n:

     A very generic class for describing the edges of a graph.

_O_b_j_e_c_t_s _f_r_o_m _t_h_e _C_l_a_s_s:

     Objects can be created by calls of the form 'new("gEdge", ...)'.

_S_l_o_t_s:

     '_e_d_g_e_I_D': Object of class '"Ruuid"' a unique identifier for the
          edge. 

     '_e_d_g_e_T_y_p_e': Object of class '"character"' the type of edge. 

     '_b_N_o_d_e': Object of class '"Ruuid"' identifier of beginning node
          for the edge. 

     '_e_N_o_d_e': Object of class '"integer"' identifier of ending node for
          the edge. 

     '_p_r_o_p_e_r_t_y': Object of class '"list"', holds properties associated
          with the edge. It always contains at least one element of
          type numeric named "weight"

_E_x_t_e_n_d_s:

     Class '"propertyHolder"', directly.

_M_e_t_h_o_d_s:

     _b_N_o_d_e 'signature(object = "gEdge")': A method that returns the
          identifier for the begining node of the edge.

     _e_N_o_d_e 'signature(object = "gEdge")': A method that returns the
          identifier for the ending node of the edge.

     _e_d_g_e_I_D 'signature(object = "gEdge")': A method that returns the
          edge identifier. 

     _i_d_s_t_r_i_n_g 'signature(x = "gEdge")': A method that returns the edge
          identifier as a character string.

     _i_n_i_t_i_a_l_i_z_e 'signature(.Object = "gEdge", ...)': initializer for
          '"gEdge"' class.

_N_o_t_e:

     Based on GXL's definition of edges.

_A_u_t_h_o_r(_s):

     R. Gentleman and Saikat DebRoy

_S_e_e _A_l_s_o:

     'gNode-class'

_E_x_a_m_p_l_e_s:

     nodeA <- new("gNode", label="A")
     nodeB <- new("gNode", label="A")
     edgeAB <- new("gEdge", bNode=nodeA, eNode=nodeB)
     idstring(edgeAB)
     bNode(edgeAB) == nodeID(nodeA)
     eNode(edgeAB) == nodeID(nodeB)
     fromEdges(nodeA) <- fromEdges(nodeB) <- list(edgeAB)
     toEdges(nodeA) <- toEdges(nodeB) <- list(edgeAB)
     fromEdges(nodeA)
     toEdges(nodeA)
     fromEdges(nodeB)
     toEdges(nodeB)

