private void readObject(ObjectInputStream ois) throws IOException, ClassNotFoundException {
  try {
    ois.defaultReadObject();
    initPlot();
  }
 catch (  Exception ex) {
    ex.printStackTrace();
  }
}

private void readObject ( ObjectInputStream ois ) throws IOException , ClassNotFoundException { try { ois . defaultReadObject ( ) ; initPlot ( ) ; } catch ( Exception ex ) { ex . printStackTrace ( ) ; } }
provide some necessary initialization after object has been deserialized .
