Package org.gedcomx.records
Class FieldValue
- java.lang.Object
-
- org.gedcomx.common.ExtensibleData
-
- org.gedcomx.links.HypermediaEnabledData
-
- org.gedcomx.conclusion.Conclusion
-
- org.gedcomx.records.FieldValue
-
- All Implemented Interfaces:
Attributable,HasNotes,HasTransientProperties,SupportsLinks,SupportsExtensionElements,ReferencesSources
public final class FieldValue extends Conclusion
An element representing a value in a record field.
-
-
Field Summary
-
Fields inherited from class org.gedcomx.common.ExtensibleData
extensionElements, transientProperties
-
-
Constructor Summary
Constructors Constructor Description FieldValue()FieldValue(String text)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaccept(GedcomxModelVisitor visitor)Accept a visitor.FieldValueanalysis(ResourceReference analysis)Add a reference to the analysis for this conclusion.FieldValueanalysis(URI analysis)Add a reference to the analysis for this conclusion.FieldValueanalysis(Document analysis)Add a reference to the analysis for this conclusion.FieldValueattribution(Attribution attribution)Build up this conclusion with attribution.FieldValueconfidence(URI confidence)Build up this conclusion with a confidence level.FieldValueconfidence(ConfidenceLevel confidence)Build up this conclusion with a confidence level.FieldValuedatatype(URI datatype)Build out this field value with a data type.booleanequals(Object o)FieldValueextensionElement(Object element)URIgetDatatype()The datatype of the text value of the field.FieldValueStatusTypegetKnownStatus()The known type of the field.FieldValueTypegetKnownType()The known type of the field value.StringgetLabelId()The id of the label applicable to this field value.URIgetResource()URI that resolves to the value of the field.URIgetStatus()The status of this FieldValue.StringgetText()The text value.URIgetType()The type of the field value.inthashCode()FieldValueid(String id)Build up this object with an id.FieldValuelabelId(String labelId)Build out this field value with a label id.FieldValuelang(String lang)Build up this conclusion with a lang.FieldValuelink(String rel, URI href)Build up this data with a link.FieldValuelink(Link link)Build up this data with a link.FieldValuenote(Note note)Build up this conclusion with a note.FieldValueresource(URI resource)Build out this field value with a resource.voidsetDatatype(URI datatype)The datatype of the text value of the field.voidsetKnownStatus(FieldValueStatusType status)The type of the field.voidsetKnownType(FieldValueType type)The type of the field value.voidsetLabelId(String labelId)The id of the label applicable to this field value.voidsetResource(URI resource)URI that resolves to the value of the field.voidsetStatus(URI status)The status of this FieldValue.voidsetText(String text)The text value.voidsetType(URI type)The type of the field value.FieldValuesortKey(String sortKey)Build up this fact with a sort key.FieldValuesource(SourceDescription source)Build up this conclusion with a source reference.FieldValuesource(SourceReference sourceReference)Build up this conclusion with a source reference.FieldValuetext(String text)Build out this field value with text.StringtoString()Provide a simple toString() method.FieldValuetype(URI type)Build out this field value with a type.FieldValuetype(FieldValueType type)Build out this field value with a type.-
Methods inherited from class org.gedcomx.conclusion.Conclusion
addNote, addSource, embed, getAnalysis, getAttribution, getConfidence, getKnownConfidenceLevel, getLang, getNotes, getSortKey, getSources, notes, setAnalysis, setAttribution, setConfidence, setKnownConfidenceLevel, setLang, setNotes, setSortKey, setSources, sources
-
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
-
-
-
-
Constructor Detail
-
FieldValue
public FieldValue()
-
FieldValue
public FieldValue(String text)
-
-
Method Detail
-
id
public FieldValue id(String id)
Description copied from class:ExtensibleDataBuild up this object with an id.- Overrides:
idin classConclusion- Parameters:
id- The id.- Returns:
- this.
-
extensionElement
public FieldValue extensionElement(Object element)
- Overrides:
extensionElementin classConclusion
-
link
public FieldValue link(String rel, URI href)
Description copied from class:HypermediaEnabledDataBuild up this data with a link.- Overrides:
linkin classConclusion- Parameters:
rel- The rel.href- The href.- Returns:
- this.
-
link
public FieldValue link(Link link)
Description copied from class:HypermediaEnabledDataBuild up this data with a link.- Overrides:
linkin classConclusion- Parameters:
link- The link.- Returns:
- this.
-
lang
public FieldValue lang(String lang)
Description copied from class:ConclusionBuild up this conclusion with a lang.- Overrides:
langin classConclusion- Parameters:
lang- The lang.- Returns:
- this.
-
confidence
public FieldValue confidence(URI confidence)
Description copied from class:ConclusionBuild up this conclusion with a confidence level.- Overrides:
confidencein classConclusion- Parameters:
confidence- The confidence level.- Returns:
- this.
-
confidence
public FieldValue confidence(ConfidenceLevel confidence)
Description copied from class:ConclusionBuild up this conclusion with a confidence level.- Overrides:
confidencein classConclusion- Parameters:
confidence- The confidence level.- Returns:
- this.
-
source
public FieldValue source(SourceReference sourceReference)
Description copied from class:ConclusionBuild up this conclusion with a source reference.- Overrides:
sourcein classConclusion- Parameters:
sourceReference- The source reference.- Returns:
- this.
-
source
public FieldValue source(SourceDescription source)
Description copied from class:ConclusionBuild up this conclusion with a source reference.- Overrides:
sourcein classConclusion- Parameters:
source- The source description being referenced.- Returns:
- this.
-
note
public FieldValue note(Note note)
Description copied from class:ConclusionBuild up this conclusion with a note.- Overrides:
notein classConclusion- Parameters:
note- The note.- Returns:
- this.
-
attribution
public FieldValue attribution(Attribution attribution)
Description copied from class:ConclusionBuild up this conclusion with attribution.- Overrides:
attributionin classConclusion- Parameters:
attribution- The attribution.- Returns:
- this.
-
analysis
public FieldValue analysis(ResourceReference analysis)
Description copied from class:ConclusionAdd a reference to the analysis for this conclusion.- Overrides:
analysisin classConclusion- Parameters:
analysis- The analysis.- Returns:
- this.
-
analysis
public FieldValue analysis(Document analysis)
Description copied from class:ConclusionAdd a reference to the analysis for this conclusion.- Overrides:
analysisin classConclusion- Parameters:
analysis- The analysis.- Returns:
- this.
-
analysis
public FieldValue analysis(URI analysis)
Description copied from class:ConclusionAdd a reference to the analysis for this conclusion.- Overrides:
analysisin classConclusion- Parameters:
analysis- The analysis.- Returns:
- this.
-
sortKey
public FieldValue sortKey(String sortKey)
Description copied from class:ConclusionBuild up this fact with a sort key.- Overrides:
sortKeyin classConclusion- Parameters:
sortKey- The sort key.- Returns:
- this.
-
getType
public URI getType()
The type of the field value.- Returns:
- The type of the field value.
-
setType
public void setType(URI type)
The type of the field value.- Parameters:
type- The type of the field value.
-
type
public FieldValue type(URI type)
Build out this field value with a type.- Parameters:
type- The type.- Returns:
- this.
-
type
public FieldValue type(FieldValueType type)
Build out this field value with a type.- Parameters:
type- The type.- Returns:
- this.
-
getKnownType
public FieldValueType getKnownType()
The known type of the field value.- Returns:
- The type of the field value.
-
setKnownType
public void setKnownType(FieldValueType type)
The type of the field value.- Parameters:
type- The type of the field value.
-
getLabelId
public String getLabelId()
The id of the label applicable to this field value.- Returns:
- The id of the label applicable to this field value.
-
setLabelId
public void setLabelId(String labelId)
The id of the label applicable to this field value.- Parameters:
labelId- The id of the label applicable to this field value.
-
labelId
public FieldValue labelId(String labelId)
Build out this field value with a label id.- Parameters:
labelId- The label id.- Returns:
- this.
-
getText
public String getText()
The text value.- Returns:
- The text value.
-
setText
public void setText(String text)
The text value.- Parameters:
text- The text value.
-
text
public FieldValue text(String text)
Build out this field value with text.- Parameters:
text- the text.- Returns:
- this.
-
getDatatype
public URI getDatatype()
The datatype of the text value of the field.- Returns:
- The datatype of the text value of the field.
-
setDatatype
public void setDatatype(URI datatype)
The datatype of the text value of the field.- Parameters:
datatype- The datatype of the text value of the field.
-
datatype
public FieldValue datatype(URI datatype)
Build out this field value with a data type.- Parameters:
datatype- The data type.- Returns:
- this
-
getResource
public URI getResource()
URI that resolves to the value of the field.- Returns:
- URI that resolves to the value of the field.
-
setResource
public void setResource(URI resource)
URI that resolves to the value of the field.- Parameters:
resource- URI that resolves to the value of the field.
-
resource
public FieldValue resource(URI resource)
Build out this field value with a resource.- Parameters:
resource- The resource.- Returns:
- this.
-
getStatus
public URI getStatus()
The status of this FieldValue.- Returns:
- URI of the field value status type of this field value.
- See Also:
FieldValueStatusType
-
setStatus
public void setStatus(URI status)
The status of this FieldValue.- Parameters:
status- The status.- See Also:
FieldValueStatusType
-
getKnownStatus
public FieldValueStatusType getKnownStatus()
The known type of the field.- Returns:
- The type of the field.
-
setKnownStatus
public void setKnownStatus(FieldValueStatusType status)
The type of the field.- Parameters:
status- The field value status type of the field.
-
accept
public void accept(GedcomxModelVisitor visitor)
Accept a visitor.- Parameters:
visitor- The visitor to accept.
-
toString
public String toString()
Provide a simple toString() method.- Overrides:
toStringin classConclusion
-
-