Mercurial > hg > Database > jungle-sharp
comparison Main/jungle-main/store/operations/DeleteChildAtOperation.cs @ 20:1f99e150f336
fix folder and add Object Mapper.
author | Kazuma Takeda |
---|---|
date | Thu, 15 Dec 2016 22:52:48 +0900 |
parents | |
children | 1466993c104c |
comparison
equal
deleted
inserted
replaced
19:0865819106cf | 20:1f99e150f336 |
---|---|
1 using UnityEngine; | |
2 using System.Collections; | |
3 using System; | |
4 | |
5 namespace JungleDB { | |
6 public class DeleteChildAtOperation : NodeOperation { | |
7 private int pos; | |
8 | |
9 public DeleteChildAtOperation(int _pos) | |
10 { | |
11 pos = _pos; | |
12 } | |
13 | |
14 | |
15 public Command getCommand() | |
16 { | |
17 return Command.DELETE_CHILD; | |
18 } | |
19 | |
20 public Either<Error, TreeNode> invoke(TreeNode _target) | |
21 { | |
22 return _target.getChildren().deleteChildAt(pos); | |
23 } | |
24 | |
25 public int getPosition() | |
26 { | |
27 return pos; | |
28 } | |
29 | |
30 public string getKey() | |
31 { | |
32 return null; | |
33 } | |
34 | |
35 public byte[] getValue() | |
36 { | |
37 return new byte[1]{0}; | |
38 } | |
39 | |
40 } | |
41 } |