]> git.argeo.org Git - lgpl/argeo-commons.git/blob - SimpleObject.java
29718807a38be2df447b257da70cd16a517f3335
[lgpl/argeo-commons.git] / SimpleObject.java
1 package org.argeo.jcr;
2
3 import java.util.UUID;
4
5 public class SimpleObject {
6 private String string;
7 private String uuid = UUID.randomUUID().toString();
8 private Integer integer;
9 private OtherObject otherObject;
10 private OtherObject anotherObject;
11
12 public String getString() {
13 return string;
14 }
15
16 public void setString(String sting) {
17 this.string = sting;
18 }
19
20 public Integer getInteger() {
21 return integer;
22 }
23
24 public void setInteger(Integer integer) {
25 this.integer = integer;
26 }
27
28 public OtherObject getOtherObject() {
29 return otherObject;
30 }
31
32 public void setOtherObject(OtherObject otherObject) {
33 this.otherObject = otherObject;
34 }
35
36 public OtherObject getAnotherObject() {
37 return anotherObject;
38 }
39
40 public void setAnotherObject(OtherObject anotherObject) {
41 this.anotherObject = anotherObject;
42 }
43
44 @Override
45 public boolean equals(Object obj) {
46 return string.equals(((SimpleObject) obj).string);
47 }
48
49 @Override
50 public int hashCode() {
51 return string.hashCode();
52 }
53
54 public void setUuid(String uuid) {
55 this.uuid = uuid;
56 }
57
58 public String getUuid() {
59 return uuid;
60 }
61
62 }