@Override
 public boolean equals(Object obj) {
   if (!(obj instanceof TerminalPosition)) {
     return false;
   }
   TerminalPosition otherPosition = (TerminalPosition) obj;
   return new EqualsBuilder()
       .append(getRow(), otherPosition.getRow())
       .append(getColumn(), otherPosition.getColumn())
       .isEquals();
 }
  public void setCursorPosition(TerminalPosition cursorPosition) {
    if (cursorPosition == null) {
      return;
    }

    // use an XML serialization position
    TerminalPositionBean newCursorPosition = new TerminalPositionBean();
    newCursorPosition.setRow(cursorPosition.getRow());
    newCursorPosition.setColumn(cursorPosition.getColumn());
    this.cursorPosition = newCursorPosition;
  }
 public static TerminalPositionBean newInstance(TerminalPosition position) {
   TerminalPositionBean newPosition = new TerminalPositionBean();
   newPosition.setRow(position.getRow());
   newPosition.setColumn(position.getColumn());
   return newPosition;
 }