public boolean equals(Object arg) {
   if (arg instanceof XMLInputSaxField) {
     XMLInputSaxField f = (XMLInputSaxField) arg;
     if (this.name.equals(f.getName())
         && this.getFieldPositionsCode().equals(f.getFieldPositionsCode())) {
       return true;
     } else {
       return false;
     }
   } else {
     return false;
   }
 }
  public Object clone() {
    try {
      XMLInputSaxField retval = (XMLInputSaxField) super.clone();

      if (fieldPosition != null) {
        XMLInputSaxFieldPosition[] positions = new XMLInputSaxFieldPosition[fieldPosition.length];
        for (int i = 0; i < fieldPosition.length; i++) {
          positions[i] = (XMLInputSaxFieldPosition) fieldPosition[i].clone();
        }
        retval.setFieldPosition(positions);
      }

      return retval;
    } catch (CloneNotSupportedException e) {
      return null;
    }
  }