if (offset < 0 || offset > getLength()) throw new BadLocationException(getText(0, getLength()), offset);  return new Position() { public int getOffset() { return offset; } };
return content.createPosition(offset);
  public Position createPosition(final int offset) throws BadLocationException    {    if (offset < 0 || offset > getLength())      throw new BadLocationException(getText(0, getLength()), offset);	return new Position() 	    {		public int getOffset()		{	  return offset;		}	    };    }