Source code: org/jbpm/workflow/organisation/impl/MembershipImpl.java
1 package org.jbpm.workflow.organisation.impl;
2
3 import org.jbpm.workflow.organisation.*;
4
5 /**
6 * @hibernate.class table="JBPM_MEMBERSHIP"
7 */
8 public class MembershipImpl implements Membership {
9
10 // persistent properties
11 /**
12 * @hibernate.id column="id" type="long" unsaved-value="null" generator-class="org.jbpm.util.db.IdGenerator"
13 */
14 public Long getId() { return id; }
15 public void setId(Long id) { this.id = id; }
16
17 /**
18 * @hibernate.property type="string" column="role"
19 */
20 public String getRole() { return role; }
21 public void setRole(String role) { this.role = role; }
22
23 /**
24 * @hibernate.property type="string" column="type_"
25 */
26 public String getType() { return type; }
27 public void setType(String type) { this.type = type; }
28
29 /**
30 * @hibernate.many-to-one class="org.jbpm.workflow.organisation.impl.GroupImpl"
31 * cascade="all" column="group_"
32 */
33 public Group getGroup() { return group; }
34 public void setGroup(Group group) { this.group = group; }
35
36 /**
37 * @hibernate.many-to-one class="org.jbpm.workflow.organisation.impl.UserImpl"
38 * cascade="all" column="user_"
39 */
40 public User getUser() { return user; }
41 public void setUser(User user) { this.user = user; }
42
43 // toString
44 public String toString() {
45 return "Membership[" + id + "|" + user.getName() + "|" + group.getName() + "]";
46 }
47
48 // private members
49 private Long id = null;
50 private String role = null;
51 private String type = null;
52 private Group group = null;
53 private User user = null;
54 }