示例#1
0
 /**
  * Delete all the generated source files made during the execution of this environment (those that
  * have been registered with the "addGeneratedFile" method).
  */
 public void deleteGeneratedFiles() {
   synchronized (generatedFiles) {
     Enumeration<File> enumeration = generatedFiles.elements();
     while (enumeration.hasMoreElements()) {
       File file = enumeration.nextElement();
       file.delete();
     }
     generatedFiles.removeAllElements();
   }
 }
  private void applyUpdates() throws SAXException {
    // now handle any updates
    if (updates.size() > 0) {
      try {
        Object upd[];
        Iterator<?> i = updates.iterator();
        while (i.hasNext()) {
          upd = (Object[]) i.next();
          idx = ((Integer) upd[0]).intValue();

          if (!(lastval.equals(upd[1]))) {
            insertValue((String) (upd[1]));
          }
        }

        rs.updateRow();
      } catch (SQLException ex) {
        throw new SAXException(
            MessageFormat.format(
                resBundle.handleGetObject("xmlrch.errupdrow").toString(), ex.getMessage()));
      }
      updates.removeAllElements();
    }
  }
 /** Disables all the attribute names. */
 public synchronized void disableAllAttributes() {
   enabledAttributes.removeAllElements();
 }
示例#4
0
 /**
  * Removes all of the elements from this Vector. The Vector will be empty after this call returns
  * (unless it throws an exception).
  *
  * @since 1.2
  */
 public void clear() {
   removeAllElements();
 }