Class RMShapeTable

java.lang.Object
com.inductiveautomation.rm.shape.RMShapeTable

public class RMShapeTable extends Object
Defines a region of coordinates along with a list of shapes that occupy that region.
  • Constructor Details

    • RMShapeTable

      public RMShapeTable(List<RMShape> theShapes)
      Creates a table from a list of shapes.
  • Method Details

    • getShapes

      public List<RMShape> getShapes()
      Returns the list of table shapes.
    • getRowCount

      public int getRowCount()
      Returns the number of rows.
    • getRow

      public RMShapeTable.Row getRow(int anIndex)
      Returns the individual row at given index.
    • getRows

      public List<RMShapeTable.Row> getRows()
      Returns a list of rows.
    • getColumn

      public RMShapeTable.Column getColumn(int anIndex)
      Returns the individual column at given index.
    • getColumnCount

      public int getColumnCount()
      Returns the number of columns.
    • getColumns

      public List<RMShapeTable.Column> getColumns()
      Returns a list of columns.
    • getRowDividers

      public List<Double> getRowDividers()
      Returns the list of row dividers.
    • getColumnDividers

      public List<Double> getColumnDividers()
      Returns the list of column dividers.
    • getCellCount

      public int getCellCount()
      Returns the number of cells.
    • getCell

      public RMShapeTable.Cell getCell(int anIndex)
      Returns the individual cell at the given index.
    • getCell

      public RMShapeTable.Cell getCell(int aRow, int aColumn)
      Returns the individual cell at the given row and column.
    • getCells

      public RMShapeTable.Cell[][] getCells()
      Returns the cells.
    • getShapes

      public List<RMShape> getShapes(int aRow, int aColumn, int aRowMax, int aColumnMax)
      Returns the list of shapes from given rows and columns.
    • isEmpty

      public boolean isEmpty(int aRow, int aColumn, int aRowMax, int aColumnMax)
      Returns whether given range of cells is empty.
    • contains

      public boolean contains(int aRow, int aColumn, int aRowMax, int aColumnMax, RMShape aShape)
      Returns whether given range of cells contains given shape.
    • getSpanX

      public static RMShapeTable.Span getSpanX(RMShape aShape)
      Returns the horizontal span of a given shape.
    • getSpanY

      public static RMShapeTable.Span getSpanY(RMShape aShape)
      Returns the vertical span of a given shape.
    • addDouble

      public void addDouble(List<Double> aDoubleList, Double aDouble)
      Adds a double to a list.
    • equals

      public boolean equals(double aValue1, double aValue2)
      Returns whether double values are equal to the precision of the table.