Mercurial > hg > Members > nobuyasu > jungle-network
comparison src/alice/jungle/persistence/PersistentChangeListWriter.java @ 86:bcaf28f8244d
Added PersistentChageList and PersistentJournalTest
author | one |
---|---|
date | Tue, 29 Oct 2013 16:52:12 +0900 |
parents | e641f559559c |
children | f142dd4abc74 |
comparison
equal
deleted
inserted
replaced
85:e641f559559c | 86:bcaf28f8244d |
---|---|
32 return Result.SUCCESS; | 32 return Result.SUCCESS; |
33 } | 33 } |
34 | 34 |
35 public Result write(PersistentChangeSet cs) | 35 public Result write(PersistentChangeSet cs) |
36 { | 36 { |
37 NetworkTreeOperationLog log = new NetworkTreeOperationLog(cs.uuid(),cs.getChangeList()); | 37 NetworkTreeOperationLog log = new NetworkTreeOperationLog(cs.uuid(), cs.getTreeName(),cs.getChangeList()); |
38 try { | 38 try { |
39 msgpack.write(out, cs.getTreeName()); | |
40 msgpack.write(out, log); | 39 msgpack.write(out, log); |
41 out.flush(); | 40 out.flush(); |
42 } catch (IOException e) { | 41 } catch (IOException e) { |
43 return null; | 42 return null; |
44 } | 43 } |