Sum returns the total weight for a set of nodes.
()
| 1145 | |
| 1146 | // Sum returns the total weight for a set of nodes. |
| 1147 | func (e EdgeMap) Sum() int64 { |
| 1148 | var ret int64 |
| 1149 | for _, edge := range e { |
| 1150 | ret += edge.Weight |
| 1151 | } |
| 1152 | return ret |
| 1153 | } |
| 1154 | |
| 1155 | type edgeList []*Edge |
| 1156 |
nothing calls this directly
no outgoing calls
no test coverage detected