org.gedcomx.conclusion
Class Event

java.lang.Object
  extended by org.gedcomx.common.ExtensibleData
      extended by org.gedcomx.links.HypermediaEnabledData
          extended by org.gedcomx.conclusion.Conclusion
              extended by org.gedcomx.conclusion.Subject
                  extended by org.gedcomx.conclusion.Event
All Implemented Interfaces:
Attributable, HasNotes, HasTransientProperties, HasDateAndPlace, SupportsLinks, SupportsExtensionElements, ReferencesSources

public class Event
extends Subject
implements HasDateAndPlace

A historical event.

Author:
Ryan Heaton

Field Summary
 
Fields inherited from class org.gedcomx.common.ExtensibleData
extensionElements, transientProperties
 
Constructor Summary
Event()
          Create an event.
Event(EventType EventType)
          Create an event with the passed in type and values.
Event(EventType EventType, Date date, PlaceReference place)
          Create a date/place event with the passed in type and values.
 
Method Summary
 void accept(GedcomxModelVisitor visitor)
          Accept a visitor.
 void addRole(EventRole role)
          Add a role to the list of roles played in this event.
 Event analysis(Document analysis)
          Add a reference to the analysis for this conclusion.
 Event analysis(ResourceReference analysis)
          Add a reference to the analysis for this conclusion.
 Event analysis(URI analysis)
          Add a reference to the analysis for this conclusion.
 Event attribution(Attribution attribution)
          Build up this conclusion with attribution.
 Event confidence(ConfidenceLevel confidence)
          Build up this conclusion with a confidence level.
 Event confidence(URI confidence)
          Build up this conclusion with a confidence level.
 Event date(Date date)
          Build up this event with a date.
 void embed(Event event)
          Embed another event.
 Event evidence(Event evidence)
           
 Event evidence(EvidenceReference evidence)
          Build up this subject with an evidence reference.
 Event extracted(Boolean extracted)
          Build up this subject with an extracted flag.
 Date getDate()
          The date of this event.
 EventType getKnownType()
          The enum referencing the known type of the event, or EventType.OTHER if not known.
 PlaceReference getPlace()
          The place of this event.
 List<EventRole> getRoles()
          The roles played in this event.
 URI getType()
          The type of the event.
 Event id(String id)
          Build up this object with an id.
 Event identifier(Identifier identifier)
          Build up this subject with an identifier.
 Event lang(String lang)
          Build up this conclusion with a lang.
 Event link(Link link)
          Build up this data with a link.
 Event link(String rel, URI href)
          Build up this data with a link.
 Event media(SourceDescription media)
          Build up this subject with a media reference.
 Event media(SourceReference media)
          Build up this subject with a media reference.
 Event note(Note note)
          Build up this conclusion with a note.
 Event place(PlaceReference place)
          Build up this event with a place.
 Event role(EventRole role)
          Build up this event with a role.
 void setDate(Date date)
          The date of this event.
 void setKnownType(EventType knownType)
          Set the type of this event from a known enumeration of event types.
 void setPlace(PlaceReference place)
          The place of this event.
 void setRoles(List<EventRole> roles)
          The roles played in this event.
 void setType(URI type)
          The type of the event.
 Event sortKey(String sortKey)
          Build up this fact with a sort key.
 Event source(SourceDescription source)
          Build up this conclusion with a source reference.
 Event source(SourceReference sourceReference)
          Build up this conclusion with a source reference.
 Event type(EventType type)
          Build up this event with a type.
 Event type(URI type)
          Build up this event with a type.
 
Methods inherited from class org.gedcomx.conclusion.Subject
addEvidence, addIdentifier, addMedia, embed, getEvidence, getExtracted, getIdentifiers, getMedia, getPersistentId, setEvidence, setExtracted, setIdentifiers, setMedia, setPersistentId
 
Methods inherited from class org.gedcomx.conclusion.Conclusion
addNote, addSource, embed, getAnalysis, getAttribution, getConfidence, getKnownConfidenceLevel, getLang, getNotes, getSortKey, getSources, setAnalysis, setAttribution, setConfidence, setKnownConfidenceLevel, setLang, setNotes, setSortKey, setSources, toString
 
Methods inherited from class org.gedcomx.links.HypermediaEnabledData
addLink, addLink, addTemplatedLink, embed, getLink, getLinks, getLinks, setLinks
 
Methods inherited from class org.gedcomx.common.ExtensibleData
addExtensionElement, embed, findExtensionOfType, findExtensionOfType, findExtensionsOfType, findExtensionsOfType, getExtensionElements, getId, getTransientProperties, getTransientProperty, removeExtensionElements, setExtensionElement, setExtensionElements, setId, setTransientProperty
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.gedcomx.common.Attributable
getAttribution, setAttribution
 

Constructor Detail

Event

public Event()
Create an event.


Event

public Event(EventType EventType)
Create an event with the passed in type and values.

Parameters:
EventType - the event type.

Event

public Event(EventType EventType,
             Date date,
             PlaceReference place)
Create a date/place event with the passed in type and values.

Parameters:
EventType - the event type.
date - The date of applicability of this event.
place - The place of applicability of this event.
Method Detail

id

public Event id(String id)
Description copied from class: ExtensibleData
Build up this object with an id.

Overrides:
id in class Subject
Parameters:
id - The id.

link

public Event link(String rel,
                  URI href)
Description copied from class: HypermediaEnabledData
Build up this data with a link.

Overrides:
link in class Subject
Parameters:
rel - The rel.
href - The href.
Returns:
this.

link

public Event link(Link link)
Description copied from class: HypermediaEnabledData
Build up this data with a link.

Overrides:
link in class Subject
Parameters:
link - The link.
Returns:
this.

lang

public Event lang(String lang)
Description copied from class: Conclusion
Build up this conclusion with a lang.

Overrides:
lang in class Subject
Parameters:
lang - The lang.
Returns:
this.

confidence

public Event confidence(URI confidence)
Description copied from class: Conclusion
Build up this conclusion with a confidence level.

Overrides:
confidence in class Subject
Parameters:
confidence - The confidence level.
Returns:
this.

confidence

public Event confidence(ConfidenceLevel confidence)
Description copied from class: Conclusion
Build up this conclusion with a confidence level.

Overrides:
confidence in class Subject
Parameters:
confidence - The confidence level.
Returns:
this.

source

public Event source(SourceReference sourceReference)
Description copied from class: Conclusion
Build up this conclusion with a source reference.

Overrides:
source in class Subject
Parameters:
sourceReference - The source reference.
Returns:
this.

source

public Event source(SourceDescription source)
Description copied from class: Conclusion
Build up this conclusion with a source reference.

Overrides:
source in class Subject
Parameters:
source - The source description being referenced.
Returns:
this.

note

public Event note(Note note)
Description copied from class: Conclusion
Build up this conclusion with a note.

Overrides:
note in class Subject
Parameters:
note - The note.
Returns:
this.

analysis

public Event analysis(ResourceReference analysis)
Description copied from class: Conclusion
Add a reference to the analysis for this conclusion.

Overrides:
analysis in class Subject
Parameters:
analysis - The analysis.
Returns:
this.

attribution

public Event attribution(Attribution attribution)
Description copied from class: Conclusion
Build up this conclusion with attribution.

Overrides:
attribution in class Subject
Parameters:
attribution - The attribution.
Returns:
this.

analysis

public Event analysis(Document analysis)
Description copied from class: Conclusion
Add a reference to the analysis for this conclusion.

Overrides:
analysis in class Subject
Parameters:
analysis - The analysis.
Returns:
this.

analysis

public Event analysis(URI analysis)
Description copied from class: Conclusion
Add a reference to the analysis for this conclusion.

Overrides:
analysis in class Subject
Parameters:
analysis - The analysis.
Returns:
this.

extracted

public Event extracted(Boolean extracted)
Description copied from class: Subject
Build up this subject with an extracted flag.

Overrides:
extracted in class Subject
Parameters:
extracted - The extracted flag.
Returns:
this.

identifier

public Event identifier(Identifier identifier)
Description copied from class: Subject
Build up this subject with an identifier.

Overrides:
identifier in class Subject
Parameters:
identifier - The identifier.
Returns:
this.

evidence

public Event evidence(EvidenceReference evidence)
Description copied from class: Subject
Build up this subject with an evidence reference.

Overrides:
evidence in class Subject
Parameters:
evidence - The evidence reference.
Returns:
this.

sortKey

public Event sortKey(String sortKey)
Description copied from class: Conclusion
Build up this fact with a sort key.

Overrides:
sortKey in class Subject
Parameters:
sortKey - The sort key.
Returns:
this.

evidence

public Event evidence(Event evidence)

media

public Event media(SourceReference media)
Description copied from class: Subject
Build up this subject with a media reference.

Overrides:
media in class Subject
Parameters:
media - The media reference.
Returns:
this.

media

public Event media(SourceDescription media)
Description copied from class: Subject
Build up this subject with a media reference.

Overrides:
media in class Subject
Parameters:
media - The media reference.
Returns:
this.

getType

public URI getType()
The type of the event.

Returns:
The type of the event.

setType

public void setType(URI type)
The type of the event.

Parameters:
type - The type of the event.

type

public Event type(URI type)
Build up this event with a type.

Parameters:
type - The type of the event.
Returns:
this.

type

public Event type(EventType type)
Build up this event with a type.

Parameters:
type - The type of the event.
Returns:
this.

getKnownType

public EventType getKnownType()
The enum referencing the known type of the event, or EventType.OTHER if not known.

Returns:
The enum referencing the known type of the event, or EventType.OTHER if not known.

setKnownType

public void setKnownType(EventType knownType)
Set the type of this event from a known enumeration of event types.

Parameters:
knownType - the event type.

getDate

public Date getDate()
The date of this event.

Specified by:
getDate in interface HasDateAndPlace
Returns:
The date of this event.

setDate

public void setDate(Date date)
The date of this event.

Specified by:
setDate in interface HasDateAndPlace
Parameters:
date - The date of this event.

date

public Event date(Date date)
Build up this event with a date.

Parameters:
date - The date.
Returns:
this.

getPlace

public PlaceReference getPlace()
The place of this event.

Specified by:
getPlace in interface HasDateAndPlace
Returns:
The place of this event.

setPlace

public void setPlace(PlaceReference place)
The place of this event.

Specified by:
setPlace in interface HasDateAndPlace
Parameters:
place - The place of this event.

place

public Event place(PlaceReference place)
Build up this event with a place.

Parameters:
place - The place.
Returns:
this.

getRoles

public List<EventRole> getRoles()
The roles played in this event.

Returns:
The roles played in this event.

setRoles

public void setRoles(List<EventRole> roles)
The roles played in this event.

Parameters:
roles - The roles played in this event.

role

public Event role(EventRole role)
Build up this event with a role.

Parameters:
role - The role.
Returns:
this.

addRole

public void addRole(EventRole role)
Add a role to the list of roles played in this event.

Parameters:
role - The role to be added.

accept

public void accept(GedcomxModelVisitor visitor)
Accept a visitor.

Parameters:
visitor - The visitor.

embed

public void embed(Event event)
Embed another event.

Parameters:
event - The event to embed.


Copyright © 2015. All rights reserved.