org.gedcomx.source
Class SourceReference

java.lang.Object
  extended by org.gedcomx.common.ExtensibleData
      extended by org.gedcomx.links.HypermediaEnabledData
          extended by org.gedcomx.source.SourceReference
All Implemented Interfaces:
Attributable, HasTransientProperties, SupportsLinks, SupportsExtensionElements

public class SourceReference
extends HypermediaEnabledData
implements Attributable

An attributable reference to a description of a source.

Author:
Ryan Heaton

Field Summary
 
Fields inherited from class org.gedcomx.common.ExtensibleData
extensionElements, transientProperties
 
Constructor Summary
SourceReference()
           
 
Method Summary
 void accept(GedcomxModelVisitor visitor)
          Accept a visitor.
 void addQualifier(Qualifier qualifier)
          Add a qualifier.
 SourceReference attribution(Attribution attribution)
          Build up this source reference with attribution.
 SourceReference description(SourceDescription description)
          Build up this source reference with a description reference.
 SourceReference descriptionRef(URI descriptionRef)
          Build up this source reference with a description reference.
 Attribution getAttribution()
          The attribution metadata for this source reference.
 URI getDescriptionRef()
          A reference to a description of the source being referenced.
 List<Qualifier> getQualifiers()
          The qualifiers associated with this source reference.
 SourceReference id(String id)
          Build up this object with an id.
 SourceReference link(Link link)
          Build up this data with a link.
 SourceReference link(String rel, URI href)
          Build up this data with a link.
 SourceReference qualifier(Qualifier qualifier)
          Build up this source reference with a qualifier.
 void setAttribution(Attribution attribution)
          The attribution metadata for this source reference.
 void setDescriptionRef(URI descriptionRef)
          A reference to a description of the source being referenced.
 void setQualifiers(List<Qualifier> qualifiers)
          Set the qualifiers associated with this source reference.
 
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, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

SourceReference

public SourceReference()
Method Detail

id

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

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

link

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

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

link

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

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

getAttribution

public Attribution getAttribution()
The attribution metadata for this source reference.

Specified by:
getAttribution in interface Attributable
Returns:
The attribution metadata for this source reference.

setAttribution

public void setAttribution(Attribution attribution)
The attribution metadata for this source reference.

Specified by:
setAttribution in interface Attributable
Parameters:
attribution - The attribution metadata for this source reference.

attribution

public SourceReference attribution(Attribution attribution)
Build up this source reference with attribution.

Parameters:
attribution - The attribution.
Returns:
this.

getDescriptionRef

public URI getDescriptionRef()
A reference to a description of the source being referenced.

Returns:
A reference to a description of the source being referenced.

setDescriptionRef

public void setDescriptionRef(URI descriptionRef)
A reference to a description of the source being referenced.

Parameters:
descriptionRef - A reference to a description of the source being referenced.

descriptionRef

public SourceReference descriptionRef(URI descriptionRef)
Build up this source reference with a description reference.

Parameters:
descriptionRef - The description ref.
Returns:
this.

description

public SourceReference description(SourceDescription description)
Build up this source reference with a description reference.

Parameters:
description - The description.
Returns:
this.

getQualifiers

public List<Qualifier> getQualifiers()
The qualifiers associated with this source reference.

Returns:
The qualifiers associated with this source reference.

setQualifiers

public void setQualifiers(List<Qualifier> qualifiers)
Set the qualifiers associated with this source reference.

Parameters:
qualifiers - qualifiers to associate with this source reference.

qualifier

public SourceReference qualifier(Qualifier qualifier)
Build up this source reference with a qualifier.

Parameters:
qualifier - The qualifier.
Returns:
this.

addQualifier

public void addQualifier(Qualifier qualifier)
Add a qualifier.

Parameters:
qualifier - The qualifier.

accept

public void accept(GedcomxModelVisitor visitor)
Accept a visitor.

Parameters:
visitor - The visitor.


Copyright © 2015. All rights reserved.