annotate app/models/NodeModel.java @ 12:ef434ebd64ae

fix NodeModel.java
author one
date Tue, 02 Oct 2012 10:38:08 +0900
parents 7b314898fddd
children 9b677755cb93
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
3
d0ee9edfff28 add libs, models/NodeModel.java
one
parents:
diff changeset
1 package models;
d0ee9edfff28 add libs, models/NodeModel.java
one
parents:
diff changeset
2
d0ee9edfff28 add libs, models/NodeModel.java
one
parents:
diff changeset
3 import java.util.HashMap;
d0ee9edfff28 add libs, models/NodeModel.java
one
parents:
diff changeset
4 import java.util.Iterator;
d0ee9edfff28 add libs, models/NodeModel.java
one
parents:
diff changeset
5
d0ee9edfff28 add libs, models/NodeModel.java
one
parents:
diff changeset
6 import com.tinkerpop.blueprints.Vertex;
d0ee9edfff28 add libs, models/NodeModel.java
one
parents:
diff changeset
7
d0ee9edfff28 add libs, models/NodeModel.java
one
parents:
diff changeset
8 public class NodeModel {
d0ee9edfff28 add libs, models/NodeModel.java
one
parents:
diff changeset
9
7
2122c50278bd add Global.java, ande models/*
one
parents: 4
diff changeset
10 protected Vertex vertex;
2122c50278bd add Global.java, ande models/*
one
parents: 4
diff changeset
11 protected Object id;
3
d0ee9edfff28 add libs, models/NodeModel.java
one
parents:
diff changeset
12
7
2122c50278bd add Global.java, ande models/*
one
parents: 4
diff changeset
13 protected final String ID = "id";
3
d0ee9edfff28 add libs, models/NodeModel.java
one
parents:
diff changeset
14
7
2122c50278bd add Global.java, ande models/*
one
parents: 4
diff changeset
15 protected final String TOULMIN = "toulmin";
2122c50278bd add Global.java, ande models/*
one
parents: 4
diff changeset
16 protected final String TITLE = "title";
2122c50278bd add Global.java, ande models/*
one
parents: 4
diff changeset
17 protected final String CONTENTS = "contents";
2122c50278bd add Global.java, ande models/*
one
parents: 4
diff changeset
18 protected final String DATA = "d";
2122c50278bd add Global.java, ande models/*
one
parents: 4
diff changeset
19 protected final String WARRANT = "w";
2122c50278bd add Global.java, ande models/*
one
parents: 4
diff changeset
20 protected final String BACKING = "b";
2122c50278bd add Global.java, ande models/*
one
parents: 4
diff changeset
21 protected final String REBUTTLE = "r";
2122c50278bd add Global.java, ande models/*
one
parents: 4
diff changeset
22 protected final String AUTHOR = "author";
2122c50278bd add Global.java, ande models/*
one
parents: 4
diff changeset
23 protected final String USERS = "users";
2122c50278bd add Global.java, ande models/*
one
parents: 4
diff changeset
24 protected final String TYPE = "type";
2122c50278bd add Global.java, ande models/*
one
parents: 4
diff changeset
25 protected final String MENTIONS = "mentions";
3
d0ee9edfff28 add libs, models/NodeModel.java
one
parents:
diff changeset
26
7
2122c50278bd add Global.java, ande models/*
one
parents: 4
diff changeset
27 protected final String STATUS = "status";
2122c50278bd add Global.java, ande models/*
one
parents: 4
diff changeset
28 protected final String PASS = "pass";
2122c50278bd add Global.java, ande models/*
one
parents: 4
diff changeset
29 protected final String FAIL = "fail";
2122c50278bd add Global.java, ande models/*
one
parents: 4
diff changeset
30 protected final String AGREED = "agreed";
2122c50278bd add Global.java, ande models/*
one
parents: 4
diff changeset
31 protected final String DENIED = "denied";
3
d0ee9edfff28 add libs, models/NodeModel.java
one
parents:
diff changeset
32
7
2122c50278bd add Global.java, ande models/*
one
parents: 4
diff changeset
33 protected final String QUESTION = "question";
2122c50278bd add Global.java, ande models/*
one
parents: 4
diff changeset
34 protected final String REFUTATION = "refutation";
3
d0ee9edfff28 add libs, models/NodeModel.java
one
parents:
diff changeset
35
7
2122c50278bd add Global.java, ande models/*
one
parents: 4
diff changeset
36 protected final String MAJORITY = "majority";
2122c50278bd add Global.java, ande models/*
one
parents: 4
diff changeset
37 protected final String UNANIMOUSLY = "unanimously";
3
d0ee9edfff28 add libs, models/NodeModel.java
one
parents:
diff changeset
38
d0ee9edfff28 add libs, models/NodeModel.java
one
parents:
diff changeset
39
d0ee9edfff28 add libs, models/NodeModel.java
one
parents:
diff changeset
40 public NodeModel(Vertex vertex) {
d0ee9edfff28 add libs, models/NodeModel.java
one
parents:
diff changeset
41 this.vertex = vertex;
d0ee9edfff28 add libs, models/NodeModel.java
one
parents:
diff changeset
42 this.id = vertex.getId();
d0ee9edfff28 add libs, models/NodeModel.java
one
parents:
diff changeset
43 }
7
2122c50278bd add Global.java, ande models/*
one
parents: 4
diff changeset
44
3
d0ee9edfff28 add libs, models/NodeModel.java
one
parents:
diff changeset
45 public void setId(Object id) {
d0ee9edfff28 add libs, models/NodeModel.java
one
parents:
diff changeset
46 this.id = id;
d0ee9edfff28 add libs, models/NodeModel.java
one
parents:
diff changeset
47 }
d0ee9edfff28 add libs, models/NodeModel.java
one
parents:
diff changeset
48
d0ee9edfff28 add libs, models/NodeModel.java
one
parents:
diff changeset
49 public Object getId() {
d0ee9edfff28 add libs, models/NodeModel.java
one
parents:
diff changeset
50 return this.id;
d0ee9edfff28 add libs, models/NodeModel.java
one
parents:
diff changeset
51 }
d0ee9edfff28 add libs, models/NodeModel.java
one
parents:
diff changeset
52
d0ee9edfff28 add libs, models/NodeModel.java
one
parents:
diff changeset
53 public Vertex getVertex() {
d0ee9edfff28 add libs, models/NodeModel.java
one
parents:
diff changeset
54 return this.vertex;
d0ee9edfff28 add libs, models/NodeModel.java
one
parents:
diff changeset
55 }
7
2122c50278bd add Global.java, ande models/*
one
parents: 4
diff changeset
56
12
ef434ebd64ae fix NodeModel.java
one
parents: 8
diff changeset
57
3
d0ee9edfff28 add libs, models/NodeModel.java
one
parents:
diff changeset
58 }