Position p = (Position) iter.next(); if ((offset <= p.getOffset()) && (p.getOffset() <= (offset + length))) refPos.add(p);
Mark m = (Mark) iter.next(); if (offset <= m.mark && m.mark <= offset + length) refPos.add(new UndoPosRef(m));
  protected Vector getPositionsInRange(Vector v,                                       int offset,                                       int length)  {    Vector refPos = new Vector();    Iterator iter = this.positions.iterator();    while(iter.hasNext())      {        Position p = (Position) iter.next();        if ((offset <= p.getOffset())            && (p.getOffset() <= (offset + length)))          refPos.add(p);      }    return refPos;  }