code: @Override
      public final void to(File f) throws IOException {
          if (f == null) throw new NullPointerException();
          FileOutputStream fos = null;
          try {
              fos = new FileOutputStream(f);
              ObjectOutputStream oos = new ObjectOutputStream(fos);
              to(oos);
          } finally {
              if (fos != null) fos.close();
          }
      }
docs: {@inheritDoc}