nl.surfnet.coin.teams.domain
Class Member

java.lang.Object
  extended by nl.surfnet.coin.teams.domain.Member
All Implemented Interfaces:
Serializable

public class Member
extends Object
implements Serializable

A member of a Team

See Also:
Serialized Form

Field Summary
static Set<Role> member
           
 
Constructor Summary
Member(Set<Role> roles, nl.surfnet.coin.api.client.domain.Person person)
           
Member(Set<Role> roles, String name, String id, String email)
           
 
Method Summary
 void addMemberAttribute(MemberAttribute memberAttribute)
          Adds one MemberAttribute to the list
 boolean addRole(Role role)
           
 Member copy()
          Copy the Member
 boolean equals(Object obj)
          
 String getEmail()
           
 String getId()
           
 List<MemberAttribute> getMemberAttributes()
           
 String getName()
           
 Set<Role> getRoles()
           
 int hashCode()
          
 boolean isGuest()
          Defines if the Member has a guest status
 boolean removeRole(Role role)
           
 void setGuest(boolean isGuest)
          Sets the value that indicates if the Member has guest status
 void setMemberAttributes(List<MemberAttribute> memberAttributes)
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

member

public static final Set<Role> member
Constructor Detail

Member

public Member(Set<Role> roles,
              String name,
              String id,
              String email)
Parameters:
roles - Set of Role's for this member
name - full name
id - uuid of the member
email - address of the member

Member

public Member(Set<Role> roles,
              nl.surfnet.coin.api.client.domain.Person person)
Parameters:
roles - Set of Role's for this member
person - Person that represents this member
Method Detail

getName

public String getName()
Returns:
the name

getId

public String getId()
Returns:
the id

getEmail

public String getEmail()
Returns:
the email

getRoles

public Set<Role> getRoles()
Returns:
the roles

addRole

public boolean addRole(Role role)
Parameters:
role - the role to be added
Returns:
boolean is successful

removeRole

public boolean removeRole(Role role)
Parameters:
role - the role to be removed
Returns:
boolean is successful

getMemberAttributes

public List<MemberAttribute> getMemberAttributes()
Returns:
List of (custom) MemberAttribute's, can be empty but not null

setMemberAttributes

public void setMemberAttributes(List<MemberAttribute> memberAttributes)
Parameters:
memberAttributes - List of (custom) MemberAttribute's

addMemberAttribute

public void addMemberAttribute(MemberAttribute memberAttribute)
Adds one MemberAttribute to the list

Parameters:
memberAttribute - MemberAttribute to add

copy

public Member copy()
Copy the Member

Returns:
copy of this instance

isGuest

public boolean isGuest()
Defines if the Member has a guest status

Returns:
true if the Member has a guest status

setGuest

public void setGuest(boolean isGuest)
Sets the value that indicates if the Member has guest status

Parameters:
isGuest -

hashCode

public int hashCode()

Overrides:
hashCode in class Object

equals

public boolean equals(Object obj)

Overrides:
equals in class Object


Copyright © 2009-2012 SURFnet bv, The Netherlands. All Rights Reserved.