comparison src/main/csharp/jp.ac.u-ryukyu.ie.cr/jungle-main/store/operations/DeleteAttributeOperation.cs @ 10:abe0c247f5a5

Add Network module. but, unComplete NetworkDefaultJungleTreeEditor.cs
author Kazuma Takeda <kazuma-arashi@hotmail.co.jp>
date Sun, 23 Oct 2016 07:40:50 +0900
parents
children
comparison
equal deleted inserted replaced
9:e6ad9016601c 10:abe0c247f5a5
1 using UnityEngine;
2 using System.Collections;
3 using System;
4
5 public class DeleteAttributeOperation : NodeOperation {
6 private string key;
7
8 public DeleteAttributeOperation(string _key) {
9 key = _key;
10 }
11
12 public Command getCommand() {
13 return Command.DELETE_ATTRIBUTE;
14 }
15
16 public Either<Error, TreeNode> invoke(TreeNode _target) {
17 return _target.getAttributes ().delete (key);
18 }
19
20 public int getPosition() {
21 return -1;
22 }
23
24 public string getKey() {
25 return key;
26 }
27
28 public byte[] getValue() {
29 return new byte[1]{0};
30 }
31
32 }