本文整理了Java中com.github.rinde.rinsim.geom.Graph.removeConnection()
方法的一些代码示例,展示了Graph.removeConnection()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Graph.removeConnection()
方法的具体详情如下:
包路径:com.github.rinde.rinsim.geom.Graph
类名称:Graph
方法名:removeConnection
[英]Removes connection between from
and to
.
[中]删除from
和to
之间的连接。
代码示例来源:origin: rinde/RinSim
@Override
public void removeConnection(Point from, Point to) {
delegate.removeConnection(from, to);
}
代码示例来源:origin: com.github.rinde/rinsim-geom
@Override
public void removeConnection(Point from, Point to) {
delegate.removeConnection(from, to);
}
代码示例来源:origin: com.github.rinde/rinsim-geom
@Override
public void removeConnection(Point from, Point to) {
final Connection<?> conn = delegate.getConnection(from, to);
delegate.removeConnection(from, to);
eventDispatcher
.dispatchEvent(new GraphEvent(
EventTypes.REMOVE_CONNECTION, this, conn));
}
代码示例来源:origin: rinde/RinSim
@Override
public void removeConnection(Point from, Point to) {
final Connection<?> conn = delegate.getConnection(from, to);
delegate.removeConnection(from, to);
eventDispatcher
.dispatchEvent(new GraphEvent(
EventTypes.REMOVE_CONNECTION, this, conn));
}
代码示例来源:origin: rinde/RinSim
@Test(expected = UnsupportedOperationException.class)
public void unmodRemoveConnection() {
Graphs.unmodifiableGraph(graph).removeConnection(null, null);
}
代码示例来源:origin: rinde/RinSim
@Test(expected = IllegalArgumentException.class)
public void removeConnectionFail() {
graph.removeConnection(new Point(0, 0), new Point(1, 0));
}
代码示例来源:origin: rinde/RinSim
assertEquals(g1, g2);
g1.removeConnection(N, E);
assertFalse(g1.equals(graph));
assertFalse(g1.equals(graph));
graph.removeConnection(N, E);
graph.addConnection(N, E, LengthData.create(10));
assertFalse(g1.equals(graph));
assertEquals(graph, g3);
g3.removeConnection(N, E);
g3.addConnection(N, E, LengthData.create(9));
assertFalse(g3.equals(graph));
代码示例来源:origin: rinde/RinSim
@Test
public void isEmtpy() {
assertTrue(graph.isEmpty());
graph.addConnection(new Point(0, 0), new Point(1, 0));
assertFalse(graph.isEmpty());
graph.removeConnection(new Point(0, 0), new Point(1, 0));
assertTrue(graph.isEmpty());
}
内容来源于网络,如有侵权,请联系作者删除!