@Entity public abstract class SpecimenOrObservationBase<S extends IIdentifiableEntityCacheStrategy<?>> extends IdentifiableEntity<S> implements IMultiLanguageTextHolder, IIntextReferenceTarget, IDescribable<DescriptionBase<S>>, IPublishable
Modifier and Type | Field and Description |
---|---|
protected java.util.Map<Language,LanguageString> |
definition |
protected java.util.Set<DerivationEvent> |
derivationEvents |
cacheStrategy, NOT_PROTECTED, PROTECTED, protectedTitleCache, titleCache
annotations, markers
CLOB_LENGTH, uuid
Modifier | Constructor and Description |
---|---|
protected |
SpecimenOrObservationBase()
Deprecated.
|
protected |
SpecimenOrObservationBase(SpecimenOrObservationType recordBasis) |
Modifier and Type | Method and Description |
---|---|
void |
addDerivationEvent(DerivationEvent derivationEvent) |
void |
addDescription(DescriptionBase description)
Adds a new description to this specimen or observation
|
void |
addDetermination(DeterminationEvent determination) |
java.util.Collection<DescriptionElementBase> |
characterData()
Returns a list of all description items which
|
java.lang.Object |
clone()
Clones this versionable entity.
|
java.util.Map<Language,LanguageString> |
getDefinition() |
java.util.Set<DerivationEvent> |
getDerivationEvents() |
java.util.Set<DescriptionBase<S>> |
getDescriptions()
The descriptions this specimen or observation is part of.
A specimen can not only have it's own specimen description
but can also be part of a taxon description or a
taxon name description . |
java.util.Set<DeterminationEvent> |
getDeterminations() |
java.lang.String |
getIdentityCache() |
java.lang.String |
getIndividualCount() |
DefinedTerm |
getKindOfUnit() |
DefinedTerm |
getLifeStage() |
SpecimenOrObservationBase |
getOriginalUnit()
for derived units get the single next higher parental/original unit.
|
java.net.URI |
getPreferredStableUri() |
SpecimenOrObservationType |
getRecordBasis() |
DefinedTerm |
getSex() |
java.util.Set<SpecimenDescription> |
getSpecimenDescriptionImageGallery()
Returns the
specimen descriptions which act as an image gallery
and which this specimen is part of. |
java.util.Set<SpecimenDescription> |
getSpecimenDescriptions()
Returns the
specimen descriptions this specimen is part of. |
java.util.Set<SpecimenDescription> |
getSpecimenDescriptions(boolean includeImageGallery)
Returns the
specimen descriptions this specimen is part of. |
boolean |
hasCharacterData() |
protected abstract void |
initDefaultCacheStrategy()
Subclasses should implement setting the default cache strate
|
boolean |
isProtectedIdentityCache() |
boolean |
isPublish()
Returns the boolean value indicating if this specimen or observation should be withheld
(
publish=false ) or not (publish=true ) during any publication
process to the general public. |
void |
putDefinition(LanguageString description)
adds the
description to the multilanguage text
used to define this specimen or observation. |
void |
putDefinition(Language language,
java.lang.String text)
Creates a
language string based on the given text string
and the given language and adds it to the multilanguage text
used to define this specimen or observation. |
void |
removeDefinition(Language lang) |
void |
removeDerivationEvent(DerivationEvent derivationEvent) |
void |
removeDescription(DescriptionBase description)
Removes a specimen from a description (removes a description from this specimen)
|
void |
removeDetermination(DeterminationEvent determination) |
void |
setIdentityCache(java.lang.String identityCache)
Deprecated.
|
void |
setIdentityCache(java.lang.String identityCache,
boolean isProtected) |
void |
setIndividualCount(java.lang.String individualCount) |
void |
setKindOfUnit(DefinedTerm kindOfUnit) |
void |
setLifeStage(DefinedTerm lifeStage) |
void |
setPreferredStableUri(java.net.URI preferredStableUri) |
void |
setProtectedIdentityCache(boolean protectedIdentityCache) |
void |
setPublish(boolean publish) |
void |
setRecordBasis(SpecimenOrObservationType recordBasis) |
void |
setSex(DefinedTerm sex) |
boolean |
updateCaches() |
addCredit, addCredit, addExtension, addExtension, addIdentifier, addIdentifier, addIdentifier, addRights, addSource, addSources, createNewSource, generateTitle, getCacheStrategy, getCredits, getCredits, getData, getExtensions, getExtensions, getExtensions, getExtensionsConcat, getExtensionsConcat, getFilteredExtensions, getIdentifiers, getIdentifiers, getIdentifiers, getLsid, getRights, getTitleCache, getTruncatedCache, hasEmptyTitleCache, hasExtension, hasExtension, initListener, isProtectedTitleCache, removeCredit, removeCredit, removeExtension, removeIdentifier, removeIdentifier, removeRights, replaceCredit, replaceIdentifier, resetTitleCache, setCacheStrategy, setLsid, setProtectedTitleCache, setTitleCache, setTitleCache, toString, updateCaches
addAggregationSource, addImportSource, addPrimaryTaxonomicSource, addPrimaryTaxonomicSource, addSource, addSource, getSources, removeSource, removeSources
addAnnotation, addMarker, addMarker, getAnnotations, getAnnotations, getMarkers, getMarkers, hasMarker, hasMarker, markerValue, removeAnnotation, removeMarker, removeMarker, setAnnotations
cloneLanguageString, equals, getUpdated, getUpdatedBy, setUpdated, setUpdatedBy
addPropertyChangeListener, addPropertyChangeListener, addToSetWithChangeEvent, deproxy, deproxy, fireOnCreateEvent, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getCreated, getCreatedBy, getId, getUserFriendlyDescription, getUserFriendlyFieldName, getUserFriendlyTypeName, getUuid, hashCode, hasListeners, instanceToString, invokeSetMethod, invokeSetMethodWithNull, isBlank, isInstanceOf, isNotBlank, isPersited, removeFromSetWithChangeEvent, removePropertyChangeListener, removePropertyChangeListener, replaceInList, setCreated, setCreatedBy, setId, setNewEntityListener, setUuid
finalize, getClass, notify, notifyAll, wait, wait, wait
addAnnotation, addMarker, getAnnotations, getMarkers, getMarkers, hasMarker, hasMarker, markerValue, removeAnnotation, removeMarker, removeMarker
getUpdated, getUpdatedBy, setUpdated, setUpdatedBy
getCreated, getCreatedBy, getId, getUuid, isInstanceOf, isPersited, setCreated, setCreatedBy, setId, setUuid
removeSources
addAggregationSource, addImportSource, addPrimaryTaxonomicSource, addPrimaryTaxonomicSource, addSource, addSource, getSources, removeSource
@IndexedEmbedded @NotNull protected java.util.Map<Language,LanguageString> definition
@NotNull protected java.util.Set<DerivationEvent> derivationEvents
@Deprecated protected SpecimenOrObservationBase()
protected SpecimenOrObservationBase(SpecimenOrObservationType recordBasis)
protected abstract void initDefaultCacheStrategy()
public SpecimenOrObservationType getRecordBasis()
recordBasis
public void setRecordBasis(SpecimenOrObservationType recordBasis)
recordBasis
public java.lang.String getIdentityCache()
@Deprecated public void setIdentityCache(java.lang.String identityCache)
public void setIdentityCache(java.lang.String identityCache, boolean isProtected)
public boolean isProtectedIdentityCache()
public void setProtectedIdentityCache(boolean protectedIdentityCache)
protectedIdentityCache
- the protectedIdentityCache to setpublic java.net.URI getPreferredStableUri()
preferredStableUri
public void setPreferredStableUri(java.net.URI preferredStableUri)
preferredStableUri
public boolean isPublish()
publish=false
) or not (publish=true
) during any publication
process to the general public.
This publish flag implementation is preliminary and may be replaced by a more general
implementation of READ rights in future.true
.isPublish
in interface IPublishable
public void setPublish(boolean publish)
setPublish
in interface IPublishable
publish
- isPublish()
public java.util.Set<DescriptionBase<S>> getDescriptions()
specimen description
but can also be part of a taxon description
or a
taxon name description
.getDescriptions
in interface IDescribable<DescriptionBase<S extends IIdentifiableEntityCacheStrategy<?>>>
getSpecimenDescriptions()
public java.util.Set<SpecimenDescription> getSpecimenDescriptions()
specimen descriptions
this specimen is part of.getDescriptions()
public java.util.Set<SpecimenDescription> getSpecimenDescriptions(boolean includeImageGallery)
specimen descriptions
this specimen is part of.getDescriptions()
public java.util.Set<SpecimenDescription> getSpecimenDescriptionImageGallery()
specimen descriptions
which act as an image gallery
and which this specimen is part of.getDescriptions()
public void addDescription(DescriptionBase description)
addDescription
in interface IDescribable<DescriptionBase<S extends IIdentifiableEntityCacheStrategy<?>>>
description
- public void removeDescription(DescriptionBase description)
removeDescription
in interface IDescribable<DescriptionBase<S extends IIdentifiableEntityCacheStrategy<?>>>
description
- IDescribable.getDescriptions()
,
#addDescription(TaxonDescription)
,
TaxonDescription.getTaxon()
public java.util.Set<DerivationEvent> getDerivationEvents()
public void addDerivationEvent(DerivationEvent derivationEvent)
public void removeDerivationEvent(DerivationEvent derivationEvent)
public java.util.Set<DeterminationEvent> getDeterminations()
public void addDetermination(DeterminationEvent determination)
public void removeDetermination(DeterminationEvent determination)
public DefinedTerm getSex()
public void setSex(DefinedTerm sex)
public DefinedTerm getLifeStage()
public void setLifeStage(DefinedTerm lifeStage)
public DefinedTerm getKindOfUnit()
kindOfUnit
public void setKindOfUnit(DefinedTerm kindOfUnit)
kindOfUnit
- kindOfUnit
public java.lang.String getIndividualCount()
public void setIndividualCount(java.lang.String individualCount)
public java.util.Map<Language,LanguageString> getDefinition()
public void putDefinition(LanguageString description)
description
to the multilanguage text
used to define this specimen or observation.description
- the languageString in with the title string and the given languagegetDefinition()
,
putDefinition(Language, String)
public void putDefinition(Language language, java.lang.String text)
language string
based on the given text string
and the given language
and adds it to the multilanguage text
used to define this specimen or observation.language
- the language in which the title string is formulatedtext
- the definition in a particular languagegetDefinition()
,
putDefinition(LanguageString)
public void removeDefinition(Language lang)
public SpecimenOrObservationBase getOriginalUnit()
public boolean hasCharacterData()
public java.util.Collection<DescriptionElementBase> characterData()
public boolean updateCaches()
updateCaches
in class IdentifiableEntity<S extends IIdentifiableEntityCacheStrategy<?>>
public java.lang.Object clone() throws java.lang.CloneNotSupportedException
VersionableEntity
clone
in class IdentifiableEntity<S extends IIdentifiableEntityCacheStrategy<?>>
java.lang.CloneNotSupportedException
Object.clone()
Copyright © 2007-2020 EDIT. All Rights Reserved.