cdc.graphs.core.GraphBase Maven / Gradle / Ivy
package cdc.graphs.core;
import cdc.graphs.GraphAdapter;
import cdc.util.lang.Checks;
/**
* Base class used to create graph algorithms.
*
* @author Damien Carbonne
*
* @param Node class
* @param Edge class
*/
public class GraphBase {
protected final GraphAdapter adapter;
public GraphBase(GraphAdapter adapter) {
Checks.isNotNull(adapter, "adapter");
this.adapter = adapter;
}
public final GraphAdapter getAdapter() {
return adapter;
}
}