org.sciplore.resources
Class Person

java.lang.Object
  extended by org.sciplore.resources.Resource
      extended by org.sciplore.resources.Person

@Entity
public class Person
extends Resource


Constructor Summary
Person()
           
Person(Integer id)
           
Person(Integer id, String nameLast, String nameMiddle, String nameFirst)
           
Person(String name)
           
 
Method Summary
 void addContact(Contact contact)
           
 void addHomonym(PersonHomonym homonym)
           
 void addHomonym(String homonym)
           
 void addXref(PersonXref x)
           
 Set<Contact> getContacts()
           
 Date getDob()
           
 Set<DocumentPerson> getDocuments()
           
 Set<PersonHomonym> getHomonyms()
           
 Integer getId()
           
 Institution getInstitution()
           
 String getNameFirst()
           
 String getNameLast()
           
 String getNameMiddle()
           
static Person getPerson(Integer id)
           
static Person getPerson(String name)
           
 Short getValid()
           
 Set<PersonXref> getXrefs()
           
 void setContacts(Set<Contact> contacts)
           
 void setDob(Date dob)
           
 void setDocuments(Set<DocumentPerson> documents)
           
 void setHomonyms(Set<PersonHomonym> homonyms)
           
 void setId(Integer id)
           
 void setInstitution(Institution institution)
           
 Person setName(String name)
           
 void setNameFirst(String nameFirst)
           
 void setNameLast(String nameLast)
           
 void setNameMiddle(String nameMiddle)
           
 void setValid(Short valid)
           
 void setXrefs(Set<PersonXref> xrefs)
           
static Person sync(Person person)
           
 String toString()
           
 
Methods inherited from class org.sciplore.resources.Resource
save
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Person

public Person()

Person

public Person(Integer id)
       throws ResourceException
Throws:
ResourceException

Person

public Person(String name)

Person

public Person(Integer id,
              String nameLast,
              String nameMiddle,
              String nameFirst)
Method Detail

getPerson

public static Person getPerson(Integer id)

getPerson

public static Person getPerson(String name)

getId

public Integer getId()
Returns:
the id

setId

public void setId(Integer id)
Parameters:
id - the id to set

getNameFirst

public String getNameFirst()
Returns:
the nameFirst

setNameFirst

public void setNameFirst(String nameFirst)
Parameters:
nameFirst - the nameFirst to set

getNameMiddle

public String getNameMiddle()
Returns:
the nameMiddle

setNameMiddle

public void setNameMiddle(String nameMiddle)
Parameters:
nameMiddle - the nameMiddle to set

getNameLast

public String getNameLast()
Returns:
the nameLast

setNameLast

public void setNameLast(String nameLast)
Parameters:
nameLast - the nameLast to set

getDob

public Date getDob()
Returns:
the dob

setDob

public void setDob(Date dob)
Parameters:
dob - the dob to set

getValid

public Short getValid()
Returns:
the valid

setValid

public void setValid(Short valid)
Parameters:
valid - the valid to set

getInstitution

public Institution getInstitution()
Returns:
the institution

setInstitution

public void setInstitution(Institution institution)
Parameters:
institution - the institution to set

setName

public Person setName(String name)

addContact

public void addContact(Contact contact)

getContacts

public Set<Contact> getContacts()
Returns:
the contacts

setContacts

public void setContacts(Set<Contact> contacts)
Parameters:
contacts - the contacts to set

getHomonyms

public Set<PersonHomonym> getHomonyms()
Returns:
the homonyms

setHomonyms

public void setHomonyms(Set<PersonHomonym> homonyms)
Parameters:
homonyms - the homonyms to set

addHomonym

public void addHomonym(PersonHomonym homonym)

addHomonym

public void addHomonym(String homonym)

getDocuments

public Set<DocumentPerson> getDocuments()
Returns:
the documents

setDocuments

public void setDocuments(Set<DocumentPerson> documents)
Parameters:
documents - the documents to set

getXrefs

public Set<PersonXref> getXrefs()
Returns:
the xrefs

setXrefs

public void setXrefs(Set<PersonXref> xrefs)
Parameters:
xrefs - the xrefs to set

addXref

public void addXref(PersonXref x)

toString

public String toString()
Overrides:
toString in class Object

sync

public static Person sync(Person person)