public static void saveAsXML(NSObject root,File out) throws IOException {
  File parent=out.getParentFile();
  if (!parent.exists() && !parent.mkdirs()) {
    throw new IOException("The output directory does not exist and could not be created.");
  }
  FileOutputStream fous=new FileOutputStream(out);
  saveAsXML(root,fous);
  fous.close();
}

public static void saveAsXML ( NSObject root , File out ) throws IOException { File parent = out . getParentFile ( ) ; if ( ! parent . exists ( ) && ! parent . mkdirs ( ) ) { throw new IOException ( "The output directory does not exist and could not be created." ) ; } FileOutputStream fous = new FileOutputStream ( out ) ; saveAsXML ( root , fous ) ; fous . close ( ) ; }
saves a property list with the given object as root into a xml file .
