public void writeBatch() throws IOException {
  if (getRetrieval() == INCREMENTAL)   throw new IOException("Batch and incremental saving cannot be mixed.");
  if (getInstances() == null)   throw new IOException("No instances to save");
  setRetrieval(BATCH);
  if (m_objectstream == null)   throw new IOException("No output for serialization.");
  setWriteMode(WRITE);
  m_objectstream.writeObject(getInstances());
  m_objectstream.flush();
  m_objectstream.close();
  setWriteMode(WAIT);
  resetWriter();
  setWriteMode(CANCEL);
}

public void writeBatch ( ) throws IOException { if ( getRetrieval ( ) == INCREMENTAL ) throw new IOException ( "Batch and incremental saving cannot be mixed." ) ; if ( getInstances ( ) == null ) throw new IOException ( "No instances to save" ) ; setRetrieval ( BATCH ) ; if ( m_objectstream == null ) throw new IOException ( "No output for serialization." ) ; setWriteMode ( WRITE ) ; m_objectstream . writeObject ( getInstances ( ) ) ; m_objectstream . flush ( ) ; m_objectstream . close ( ) ; setWriteMode ( WAIT ) ; resetWriter ( ) ; setWriteMode ( CANCEL ) ; }
writes a batch of instances .
