Package io.keikai.api

Class AreaRef

  • All Implemented Interfaces:
    Serializable
    Direct Known Subclasses:
    AreaRefWithType, MergedRect

    public class AreaRef
    extends Object
    implements Serializable
    A class that represents an area reference with 4 value : row(top row), column(left column), last row(bottom row) and last column(right column)
    Since:
    3.0.0
    Author:
    Dennis.Chen
    See Also:
    Serialized Form
    • Field Detail

      • _column

        protected int _column
      • _row

        protected int _row
      • _lastColumn

        protected int _lastColumn
      • _lastRow

        protected int _lastRow
    • Constructor Detail

      • AreaRef

        public AreaRef()
      • AreaRef

        public AreaRef​(int row,
                       int column,
                       int lastRow,
                       int lastColumn)
      • AreaRef

        public AreaRef​(String areaReference)
    • Method Detail

      • setArea

        public void setArea​(int row,
                            int column,
                            int lastRow,
                            int lastColumn)
      • getColumn

        public int getColumn()
      • setColumn

        public void setColumn​(int column)
      • getRow

        public int getRow()
      • setRow

        public void setRow​(int row)
      • getLastColumn

        public int getLastColumn()
      • setLastColumn

        public void setLastColumn​(int lastColumn)
      • getLastRow

        public int getLastRow()
      • setLastRow

        public void setLastRow​(int lastRow)
      • cloneSelf

        public AreaRef cloneSelf()
      • contains

        public boolean contains​(int tRow,
                                int lCol,
                                int bRow,
                                int rCol)
      • overlap

        public boolean overlap​(int bTopRow,
                               int bLeftCol,
                               int bBottomRow,
                               int bRightCol)
      • asString

        public String asString()
        Returns:
        reference string, e.x A1:B2
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Object