예제 #1
0
  public void insertLine(String line, Class clazz) {
    int index = getRowCount();
    // Err.pr( "===S/be adding line number " + index + " to block: " + block);
    CombinationExtent ext = block.getCombinationExtent();
    // Err.pr( "===In state " + block.getCurrentState());
    String args[] = new String[1];
    args[0] = line;

    Object newObj = ObjectFoundryUtils.factory(clazz, args);
    if (index != 0) {
      ext.insert(newObj, index);
    } else {
      ext.insert(newObj, 0);
    }
  }
예제 #2
0
 public void removeLine(int index) {
   CombinationExtent ext = block.getCombinationExtent();
   ext.removeElementAt(index);
 }