throw new WGIllegalStateException("You cannot save a workspace plugin set");
}
// Write first to ByteArrayOutputStream and create hash to see if it changed
ByteArrayOutputStream out = new ByteArrayOutputStream();
MD5HashingOutputStream hashOut = new MD5HashingOutputStream(out);
XStreamUtils.writeUtf8ToOutputStream(this, XSTREAM, hashOut);
// Only write if the hash differs
String newHash = hashOut.getHash();
if (!newHash.equals(_hash)) {
FileOutputStream fileOut = new FileOutputStream(file);
fileOut.write(out.toByteArray());
fileOut.close();
_hash = newHash;