1 20 21 22 26 package org.apache.ojb.odmg.shared; 27 28 import java.util.Collection ; 29 import java.io.Serializable ; 30 31 import org.apache.commons.lang.builder.ToStringBuilder; 32 33 public class Project implements Serializable 34 { 35 private int id; 36 private String title; 37 private String description; 38 private Collection members; 39 private Collection roles; 40 41 42 public Project() 43 { 44 } 45 46 public Project(int pId, String pTitle, String pDescription) 47 { 48 id = pId; 49 title = pTitle; 50 description = pDescription; 51 } 52 53 public Collection getRoles() 54 { 55 return roles; 56 } 57 58 public void setRoles(Collection roles) 59 { 60 this.roles = roles; 61 } 62 63 public int getId() 64 { 65 return id; 66 } 67 68 public void setId(int id) 69 { 70 this.id = id; 71 } 72 73 public String getTitle() 74 { 75 return title; 76 } 77 78 public void setTitle(String title) 79 { 80 this.title = title; 81 } 82 83 public String getDescription() 84 { 85 return description; 86 } 87 88 public void setDescription(String description) 89 { 90 this.description = description; 91 } 92 93 public Collection getMembers() 94 { 95 return members; 96 } 97 98 public void setMembers(Collection members) 99 { 100 this.members = members; 101 } 102 103 104 public String toString() 105 { 106 return new ToStringBuilder(this) 107 .append("id", id) 108 .append("title", title) 109 .append("description", description) 110 .append("Memberss size", members != null ? members.size() : 0) 111 .append("Roles size", members != null ? members.size() : 0) 112 .toString(); 113 } 114 } 115 | Popular Tags |