diff src/main/java/jp/ac/u_ryukyu/ie/cr/shoshi/jungle/store/impl/logger/LoggingChildren.java @ 103:bed3afd5c2e2

add Index but Not use
author one
date Fri, 12 Sep 2014 14:37:09 +0900
parents 14ce7a0dedca
children 74723b26ad96
line wrap: on
line diff
--- a/src/main/java/jp/ac/u_ryukyu/ie/cr/shoshi/jungle/store/impl/logger/LoggingChildren.java	Thu Sep 11 16:38:26 2014 +0900
+++ b/src/main/java/jp/ac/u_ryukyu/ie/cr/shoshi/jungle/store/impl/logger/LoggingChildren.java	Fri Sep 12 14:37:09 2014 +0900
@@ -10,6 +10,7 @@
 import jp.ac.u_ryukyu.ie.cr.shoshi.jungle.util.DefaultEither;
 import jp.ac.u_ryukyu.ie.cr.shoshi.jungle.util.Either;
 import jp.ac.u_ryukyu.ie.cr.shoshi.jungle.util.Error;
+import jp.ac.u_ryukyu.ie.cr.tatsuki.jungle.store.index.Logging;
 
 public class LoggingChildren //implements EditableChildren
 {
@@ -36,7 +37,7 @@
 		return children.iterator();
 	}*/
 	
-	public Either<Error,LoggingNode> edit(NodeOperation _op)
+	public Either<Error,Logging> edit(NodeOperation _op)
 	{
 		Either<Error,TreeNode> either = _op.invoke(wrap);
 		if(either.isA()){
@@ -45,23 +46,23 @@
 		
 		TreeNode newWrap = either.b();
 		OperationLog newLog = log.add(_op);
-		LoggingNode newLoggingNode = new LoggingNode(newWrap,newLog);
+		Logging newLoggingNode = new LoggingNode(newWrap,newLog);
 		return DefaultEither.newB(newLoggingNode);
 	}
 	
-	public Either<Error,LoggingNode> addNewChildAt(final int _pos)
+	public Either<Error,Logging> addNewChildAt(final int _pos)
 	{
 		NodeOperation addNewChildAt = new AppendChildAtOperation(_pos);
 		return edit(addNewChildAt);
 	}
 
-	public Either<Error,LoggingNode> deleteChildAt(final int _pos)
+	public Either<Error,Logging> deleteChildAt(final int _pos)
 	{
 		NodeOperation deleteChildAt = new DeleteChildAtOperation(_pos);
 		return edit(deleteChildAt);
 	}
 
-	public Either<Error,LoggingNode> at(int _pos)
+	public Either<Error,Logging> at(int _pos)
 	{
 		Children children = wrap.getChildren();
 		Either<Error,TreeNode> either = children.at(_pos);
@@ -70,6 +71,7 @@
 		}
 		
 		TreeNode node = either.b();
-		return DefaultEither.newB(new LoggingNode(node));
+		Logging logNode = new LoggingNode(node);
+		return DefaultEither.newB(logNode);
 	}
 }