示例#1
0
 public Row<T> insertRowBeneath() {
   Row<T> newRow = new Row<T>(parent, this, nextRow);
   if (nextRow == null) {
     parent.lastRow = newRow;
   } else {
     getNextRow().prevRow = newRow;
   }
   parent.height++;
   nextRow = newRow;
   return newRow;
 }
示例#2
0
    private void _remove() {
      this.parent.height--;
      if (prevRow == null) {
        parent.firstRow = nextRow;
      } else {
        this.prevRow.nextRow = nextRow;
      }
      if (nextRow == null) {
        parent.lastRow = prevRow;
      } else {
        this.nextRow.prevRow = prevRow;
      }

      this.firstCell = null;
      this.lastCell = null;
      this.prevRow = null;
      this.nextRow = null;
      this.parent = null;
    }