Re: Object IllegalStateException Problem



This is the getSaveFile() method:

private FileInfo getSaveFile() throws IOException {
if (object == null) {
throw new IllegalStateException("Please load a version of
an object before saving!");
}

// get the uncommitted version if it is there
FileInfo saveFile =
getConfigurationVersions().get(ConfigurationVersion.UNCOMMITTED);

if (saveFile == null) {
// otherwise create a new temp file
saveFile =
FileInfo.createTempFile(getConfigurationFileName(),
getConfigurationDirectory());
}

return saveFile;
}

Paolo
.



Relevant Pages

  • Re: Object IllegalStateException Problem
    ... private FileInfo getSaveFile() throws IOException { ... throw new IllegalStateException("Please load a version of ... FileInfo saveFile = ...
    (comp.lang.java.programmer)
  • Re: Object IllegalStateException Problem
    ... private FileInfo getSaveFile() throws IOException { ... throw new IllegalStateException("Please load a version of ... FileInfo saveFile = ...
    (comp.lang.java.programmer)
  • Re: savefile design
    ... and delete monster and item types without breaking savefile ... With appropriate player warning, and possibly ... only see,,can load older save files'' before upgrading.) ...
    (rec.games.roguelike.development)
  • Re: POSband on OS X?
    ... >> it appends a second one.) ... > If you have just a *.gz file, it won't load. ... You get a "savefile ... i don't know whether this is a satisfactory fix. ...
    (rec.games.roguelike.angband)
  • Re: POSband on OS X?
    ... > it appends a second one.) ... checks for non-existence of savefiles ... If you have just a *.gz file, it won't load. ... You get a "savefile ...
    (rec.games.roguelike.angband)