Mercurial > hg > Database > jungle-network
view src/alice/jungle/persistence/PersistentChangeList.java @ 87:f142dd4abc74
Implemented getTreeName and uuid method in some classes
author | one |
---|---|
date | Tue, 05 Nov 2013 08:41:12 +0900 (2013-11-04) |
parents | bcaf28f8244d |
children | 0c98717f186e |
line wrap: on
line source
package alice.jungle.persistence; import java.util.Iterator; import alice.jungle.operations.NetworkTreeOperationLog; import jp.ac.u_ryukyu.ie.cr.shoshi.jungle.persistent.ChangeList; import jp.ac.u_ryukyu.ie.cr.shoshi.jungle.store.impl.logger.TreeOperationLog; import jp.ac.u_ryukyu.ie.cr.shoshi.jungle.store.operations.TreeOperation; public class PersistentChangeList implements ChangeList { public NetworkTreeOperationLog log; public String treeName; public String uuid; public PersistentChangeList(String _uuid, String _treeName, TreeOperationLog _log) { uuid = _uuid; treeName = _treeName; log = new NetworkTreeOperationLog(_log); } public PersistentChangeList(NetworkTreeOperationLog _log) { log = _log; treeName = _log.getTreeName(); uuid = _log.getUUID(); } public PersistentChangeList(PersistentChangeSet cs) { treeName = cs.getTreeName(); uuid = cs.uuid(); log = new NetworkTreeOperationLog(cs.getChangeList()); } @Override public Iterator<TreeOperation> iterator() { return log.iterator(); } public NetworkTreeOperationLog getTreeOperationLog() { return log; } public String getTreeName() { return treeName; } public String uuid() { return uuid; } }