/[projects]/miscJava/bukkit-minecraft-plugins/HoerupUtils/src/main/java/dk/thoerup/bukkit/hoeruputils/chests/ChestBean.java
ViewVC logotype

Annotation of /miscJava/bukkit-minecraft-plugins/HoerupUtils/src/main/java/dk/thoerup/bukkit/hoeruputils/chests/ChestBean.java

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1871 - (hide annotations) (download)
Thu Nov 8 19:47:51 2012 UTC (11 years, 6 months ago) by torben
File size: 1895 byte(s)
only log comment string if there's actually a comment
1 torben 1805 package dk.thoerup.bukkit.hoeruputils.chests;
2    
3    
4     import javax.persistence.Entity;
5     import javax.persistence.GeneratedValue;
6     import javax.persistence.Id;
7    
8    
9    
10     @Entity
11 torben 1807 public class ChestBean {
12     final static int LOCKED = 1;
13     final static int SNITCHING = 2;
14    
15    
16 torben 1805 @Id
17     @GeneratedValue
18     int id;
19    
20     String owner;
21     String description;
22    
23     String world;
24     int x;
25     int y;
26     int z;
27    
28     boolean doublechest = false;
29    
30 torben 1807 String modifyPlayers;
31    
32     int chestType;
33 torben 1805
34 torben 1869 String comment = "";
35 torben 1805
36    
37    
38 torben 1807 public int getChestType() {
39     return chestType;
40     }
41     public void setChestType(int chestType) {
42     this.chestType = chestType;
43     }
44 torben 1805 public String getOwner() {
45     return owner;
46     }
47     public void setOwner(String owner) {
48     this.owner = owner;
49     }
50     public String getDescription() {
51     return description;
52     }
53     public void setDescription(String description) {
54     this.description = description;
55     }
56    
57     public int getId() {
58     return id;
59     }
60    
61     public void setId(int id) {
62     this.id = id;
63     }
64    
65     public String getWorld() {
66     return world;
67     }
68    
69     public void setWorld(String world) {
70     this.world = world;
71     }
72    
73     public int getX() {
74     return x;
75     }
76    
77     public void setX(int x) {
78     this.x = x;
79     }
80    
81     public int getY() {
82     return y;
83     }
84    
85     public void setY(int y) {
86     this.y = y;
87     }
88    
89     public int getZ() {
90     return z;
91     }
92    
93     public void setZ(int z) {
94     this.z = z;
95     }
96     public boolean isDoublechest() {
97     return doublechest;
98     }
99     public void setDoublechest(boolean doublechest) {
100     this.doublechest = doublechest;
101     }
102    
103     public String getModifyPlayers() {
104     return modifyPlayers;
105     }
106     public void setModifyPlayers(String modifyPlayers) {
107     this.modifyPlayers = modifyPlayers;
108     }
109 torben 1869
110     public String getComment() {
111     return comment;
112     }
113     public void setComment(String comment) {
114 torben 1871 this.comment = comment.trim();
115 torben 1869 }
116 torben 1871
117     public String getCommentString() {
118     if (this.comment == null || this.comment.length() == 0)
119     return "";
120    
121     return " (Comment: " + this.comment + ")";
122     }
123 torben 1805
124     }

  ViewVC Help
Powered by ViewVC 1.1.20