forked from aws-samples/eb-java-scorekeep
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMove.java
More file actions
73 lines (61 loc) · 1.67 KB
/
Move.java
File metadata and controls
73 lines (61 loc) · 1.67 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
package scorekeep;
import java.util.Set;
import java.util.HashSet;
import java.util.Date;
import com.amazonaws.services.dynamodbv2.datamodeling.DynamoDBAttribute;
import com.amazonaws.services.dynamodbv2.datamodeling.DynamoDBHashKey;
import com.amazonaws.services.dynamodbv2.datamodeling.DynamoDBIndexHashKey;
import com.amazonaws.services.dynamodbv2.datamodeling.DynamoDBIgnore;
import com.amazonaws.services.dynamodbv2.datamodeling.DynamoDBTable;
@DynamoDBTable( tableName = Constants.MOVE_TABLE )
public class Move {
private String id;
private String game;
private String session;
private String user;
private String move;
public Move() {
}
public Move(String id, String session, String game, String user, String move) {
this.id = id;
this.session = session;
this.game = game;
this.user = user;
this.move = move;
}
@DynamoDBHashKey(attributeName="id")
public String getId() {
return id;
}
public void setId(String id){
this.id = id;
}
@DynamoDBIndexHashKey(globalSecondaryIndexName="game-index",attributeName="game")
public String getGame() {
return game;
}
public void setGame(String gameId){
this.game = gameId;
}
@DynamoDBAttribute(attributeName="session")
public String getSession() {
return session;
}
public void setSession(String sessionId) {
this.session = sessionId;
}
@DynamoDBAttribute(attributeName="user")
public String getUser() {
return user;
}
public void setUser(String userId) {
this.user = userId;
}
@DynamoDBAttribute(attributeName="move")
public String getMove() {
return move;
}
public void setMove(String moveId) {
this.move = moveId;
}
}