public class QueueElement extends Object implements Comparable<QueueElement>
| Modifier and Type | Field and Description |
|---|---|
int |
from
边的起点
|
int |
index
边的终点在顶点数组中的下标
|
QueueElement |
next
下一个,这是一个链表结构的最小堆
|
double |
weight
权重
|
| Constructor and Description |
|---|
QueueElement(int from,
int index,
double weight)
构造一个边节点
|
public int from
public int index
public double weight
public QueueElement next
public QueueElement(int from,
int index,
double weight)
from - 边的起点index - 边的终点weight - 权重public int compareTo(QueueElement other)
compareTo in interface Comparable<QueueElement>Copyright © 2014–2021 码农场. All rights reserved.