public interface IIdentifiableEntity extends ISourceable<IdentifiableSource>, IAnnotatableEntity
Modifier and Type | Method and Description |
---|---|
void |
addCredit(Credit credig) |
void |
addCredit(Credit credit,
int index) |
void |
addExtension(Extension extension) |
void |
addExtension(java.lang.String value,
ExtensionType extensionType) |
void |
addIdentifier(Identifier identifier) |
void |
addIdentifier(java.lang.Integer index,
Identifier identifier)
Adds an identifier at the given position.
|
Identifier |
addIdentifier(java.lang.String identifier,
DefinedTerm identifierType)
Create and add a new identifier.
|
void |
addRights(Rights right) |
java.lang.String |
generateTitle()
Returns a title cache String created by the according cache strategy
with the given identifiable entity WITHOUT setting the titleCache
of
this object. |
java.util.List<Credit> |
getCredits() |
Credit |
getCredits(java.lang.Integer index) |
byte[] |
getData() |
java.util.Set<Extension> |
getExtensions() |
java.util.List<Identifier> |
getIdentifiers()
Returns the list of
alternative identifiers . |
LSID |
getLsid() |
java.util.Set<Rights> |
getRights() |
java.lang.String |
getTitleCache()
Returns the title cache.
|
boolean |
isProtectedTitleCache() |
void |
removeCredit(Credit credit) |
void |
removeCredit(int index) |
void |
removeExtension(Extension extension) |
void |
removeIdentifier(Identifier identifier)
Removes an identifier
|
void |
removeIdentifier(int index)
Removes an identifier at the given position.
|
void |
removeRights(Rights right) |
void |
removeSources() |
boolean |
replaceCredit(Credit newObject,
Credit oldObject)
Replaces all occurrences of oldObject in the credits list with newObject
|
boolean |
replaceIdentifier(Identifier newObject,
Identifier oldObject)
Replaces all occurrences of oldObject in the identifiers list with newObject
|
java.lang.String |
resetTitleCache()
Recomputes the titleCache if it is not protected and returns
the new value;
|
void |
setLsid(LSID lsid) |
void |
setProtectedTitleCache(boolean protectedTitleCache) |
void |
setTitleCache(java.lang.String titleCache)
Deprecated.
this method only exists to be in line with the Java Beans Specification (JSR 220 or JSR 273) .
As it will set the
protected flag to false the title cache value
may be automatically recomputed later. There are only very rare use cases were a programmer may
want to use this method directly.
Better use setTitleCache(String, boolean) with second parameter protectCache
set to true . |
void |
setTitleCache(java.lang.String titleCache,
boolean protectCache)
Sets the title cache.
NOTE: In most cases the protectCache argument should be set to true . |
java.lang.String |
toString()
Overrides
CdmBase.toString() . |
addAggregationSource, addImportSource, addPrimaryTaxonomicSource, addPrimaryTaxonomicSource, addSource, addSource, addSource, addSources, getSources, removeSource
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
LSID getLsid()
void setLsid(LSID lsid)
java.lang.String generateTitle()
this
object.
This method is meant for internal use and usually not needed for
external use. Use getTitleCache()
instead.getTitleCache()
java.lang.String getTitleCache()
generateTitle()
java.lang.String resetTitleCache()
@Deprecated void setTitleCache(java.lang.String titleCache)
protected
flag to false the title cache value
may be automatically recomputed later. There are only very rare use cases were a programmer may
want to use this method directly.
Better use setTitleCache(String, boolean)
with second parameter protectCache
set to true
.protectCache
flag.false
the titleCache
may be
recomputed with the next call of getTitleCache()
, which is automatically the case when
the object is persisted.titleCache
- setTitleCache(String, boolean)
,
getTitleCache()
void setTitleCache(java.lang.String titleCache, boolean protectCache)
protectCache
argument should be set to true
.
See comments at setTitleCache(String)
titleCache
- the new title cacheprotectCache
- the protect flag, should in most cases be set to true
boolean isProtectedTitleCache()
void setProtectedTitleCache(boolean protectedTitleCache)
java.util.Set<Rights> getRights()
void addRights(Rights right)
void removeRights(Rights right)
java.util.List<Credit> getCredits()
Credit getCredits(java.lang.Integer index)
void addCredit(Credit credig)
void addCredit(Credit credit, int index)
void removeCredit(Credit credit)
void removeCredit(int index)
boolean replaceCredit(Credit newObject, Credit oldObject)
newObject
- the replacement objectoldObject
- the object to be replacedjava.util.Set<Extension> getExtensions()
void addExtension(Extension extension)
void addExtension(java.lang.String value, ExtensionType extensionType)
void removeExtension(Extension extension)
java.util.List<Identifier> getIdentifiers()
alternative identifiers
.
In case the order of these identifiers is important it should be
implemented such that the first item in the list is the most
important/most current identifier. Identifier addIdentifier(java.lang.String identifier, DefinedTerm identifierType)
identifier
- identifierType
- getIdentifiers()
void addIdentifier(Identifier identifier)
identifier
- getIdentifiers()
void addIdentifier(java.lang.Integer index, Identifier identifier)
index
see List.add(int, Object)
and .
If index
is null
the identifier is added to the end
of the list.index
- the list indexidentifier
- the identifiergetIdentifiers()
void removeIdentifier(int index)
index
see List.add(int, Object)
and index
- the list indexvoid removeIdentifier(Identifier identifier)
identifier
- getIdentifiers()
boolean replaceIdentifier(Identifier newObject, Identifier oldObject)
newObject
- the replacement objectoldObject
- the object to be replacedjava.lang.String toString()
CdmBase.toString()
.
This returns an String that identifies the object well without beeing necessarily unique.
Specification: This method should never call other object' methods so it can be well used for debugging
without problems like lazy loading, unreal states etc.
Note: If overriding this method's javadoc always copy or link the above requirement.
If not overwritten by a subclass method returns the class, id and uuid as a string for any CDM object.
For example: Taxon#13toString
in class java.lang.Object
Object.toString()
byte[] getData()
void removeSources()
Copyright © 2007-2020 EDIT. All Rights Reserved.