org.psjava.ds.graph.SimpleUndirectedEdge Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of psjava Show documentation
Show all versions of psjava Show documentation
Problem Solving Library for Java
The newest version!
package org.psjava.ds.graph;
public class SimpleUndirectedEdge {
public static UndirectedEdge create(final V v1, final V v2) {
return new UndirectedEdge() {
@Override
public V v1() {
return v1;
}
@Override
public V v2() {
return v2;
}
@Override
public String toString() {
return v1 + "-" + v2;
}
};
}
private SimpleUndirectedEdge() {
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy