RegularGridModel

public class RegularGridModel<E> implements SpatialModel<E>

Constructors

Link copied to clipboard
public void RegularGridModel(int rows, int columns, E weight)

Properties

Link copied to clipboard
public final int columns
Link copied to clipboard
public final int rows
Link copied to clipboard
public final E weight

Functions

Link copied to clipboard
public static SpatialModel<MoonLightRecord> buildSpatialModelFromAdjacencyList(int locations, RecordHandler edgeRecordHandler, Array<Array<double>> data)
This is an utility method that builds a SpatialModel from an adjacency list represented as an array of doubles.
public static SpatialModel<MoonLightRecord> buildSpatialModelFromAdjacencyList(int locations, RecordHandler edgeRecordHandler, Array<Array<String>> data)
This is an utility method that builds a SpatialModel from an adjacency list represented as an array of String.
Link copied to clipboard
public static SpatialModel<MoonLightRecord> buildSpatialModelFromAdjacencyMatrix(int locations, RecordHandler edgeRecordHandler, Array<Array<Array<double>>> objects)
public static SpatialModel<MoonLightRecord> buildSpatialModelFromAdjacencyMatrix(int locations, RecordHandler edgeRecordHandler, Array<Array<Array<String>>> data)
This is an utility method that builds a SpatialModel from an adjacency matrix represented as an array of doubles.
Link copied to clipboard
public int fromCoordinates(int x, int y)
Link copied to clipboard
public E get(int source, int target)
Returns the value of the edge connecting src to trg.
Link copied to clipboard
public int getColumns()
Link copied to clipboard
public Array<int> getNeighboursArray(int node)
Link copied to clipboard
public int getRows()
Link copied to clipboard
public E getWeight()
Link copied to clipboard
public static Boolean isFull(Array<double> array)
public static Boolean isFull(Array<String> array)
Link copied to clipboard
public List<Pair<Integer, E>> next(int location)
Returns the list of exiting edges from l.
Link copied to clipboard
public List<Pair<Integer, E>> previous(int location)
Returns the list of incoming edges in l.
Link copied to clipboard
public int size()
Link copied to clipboard
public Array<int> toCoordinates(int location)
Link copied to clipboard
public Array<int> unsafeToCoordinates(int location)