2 * Copyright (C) 2007 EDIT
3 * European Distributed Institute of Taxonomy
4 * http://www.e-taxonomy.eu
6 * The contents of this file are subject to the Mozilla Public License Version 1.1
7 * See LICENSE.TXT at the top of this package for the full license terms.
10 package eu
.etaxonomy
.cdm
.model
.name
;
13 import javax
.persistence
.Entity
;
14 import javax
.persistence
.ManyToOne
;
15 import javax
.persistence
.Transient
;
16 import javax
.xml
.bind
.annotation
.XmlAccessType
;
17 import javax
.xml
.bind
.annotation
.XmlAccessorType
;
18 import javax
.xml
.bind
.annotation
.XmlAnyElement
;
19 import javax
.xml
.bind
.annotation
.XmlElement
;
20 import javax
.xml
.bind
.annotation
.XmlIDREF
;
21 import javax
.xml
.bind
.annotation
.XmlRootElement
;
22 import javax
.xml
.bind
.annotation
.XmlType
;
24 import org
.apache
.log4j
.Logger
;
25 import org
.hibernate
.annotations
.Cascade
;
26 import org
.hibernate
.annotations
.CascadeType
;
27 import org
.hibernate
.annotations
.Target
;
29 import eu
.etaxonomy
.cdm
.model
.agent
.INomenclaturalAuthor
;
30 import eu
.etaxonomy
.cdm
.model
.agent
.TeamOrPersonBase
;
31 import eu
.etaxonomy
.cdm
.model
.reference
.INomenclaturalReference
;
32 import eu
.etaxonomy
.cdm
.strategy
.cache
.name
.INonViralNameCacheStrategy
;
33 import eu
.etaxonomy
.cdm
.strategy
.cache
.name
.NonViralNameDefaultCacheStrategy
;
36 * The taxon name class for all non viral taxa. Parenthetical authorship is derived
37 * from basionym relationship. The scientific name including author strings and
38 * maybe year can be stored as a string in the inherited {@link common.IdentifiableEntity#getTitleCache() titleCache} attribute.
39 * The year itself is an information obtained from the {@link reference.INomenclaturalReference#getYear() nomenclatural reference}.
40 * The scientific name string without author strings and year can be stored in the {@link #getNameCache() nameCache} attribute.
44 * @created 08-Nov-2007 13:06:39
46 @XmlAccessorType(XmlAccessType
.FIELD
)
47 @XmlType(name
= "", propOrder
= {
50 "infraGenericEpithet",
52 "infraSpecificEpithet",
53 "combinationAuthorTeam",
54 "exCombinationAuthorTeam",
56 "exBasionymAuthorTeam",
58 "protectedAuthorshipCache",
62 @XmlRootElement(name
= "NonViralName")
64 public class NonViralName
<T
extends NonViralName
> extends TaxonNameBase
<NonViralName
, INonViralNameCacheStrategy
> {
66 private static final Logger logger
= Logger
.getLogger(NonViralName
.class);
68 @XmlElement(name
= "NameCache")
69 private String nameCache
;
71 @XmlElement(name
= "GenusOrUninomial")
72 private String genusOrUninomial
;
74 @XmlElement(name
= "InfraGenericEpithet")
75 private String infraGenericEpithet
;
77 @XmlElement(name
= "SpecificEpithet")
78 private String specificEpithet
;
80 @XmlElement(name
= "InfraSpecificEpithet")
81 private String infraSpecificEpithet
;
85 //@XmlSchemaType(name = "IDREF")
86 private INomenclaturalAuthor combinationAuthorTeam
;
90 //@XmlSchemaType(name = "IDREF")
91 private INomenclaturalAuthor exCombinationAuthorTeam
;
95 //@XmlSchemaType(name = "IDREF")
96 private INomenclaturalAuthor basionymAuthorTeam
;
99 private INomenclaturalAuthor exBasionymAuthorTeam
;
101 @XmlElement(name
= "AuthorshipCache")
102 private String authorshipCache
;
104 @XmlElement(name
= "ProtectedAuthorshipCache")
105 protected boolean protectedAuthorshipCache
;
107 @XmlElement(name
= "ProtectedNameCache")
108 protected boolean protectedNameCache
;
111 protected INonViralNameCacheStrategy cacheStrategy
;
113 // ************* CONSTRUCTORS *************/
115 //needed by hibernate
117 * Class constructor: creates a new non viral taxon name instance
118 * only containing the {@link eu.etaxonomy.cdm.strategy.cache.name.NonViralNameDefaultCacheStrategy default cache strategy}.
120 * @see #NonViralName(Rank, HomotypicalGroup)
121 * @see #NonViralName(Rank, String, String, String, TeamOrPersonBase, INomenclaturalReference, String, HomotypicalGroup)
122 * @see eu.etaxonomy.cdm.strategy.cache.name.INonViralNameCacheStrategy
123 * @see eu.etaxonomy.cdm.strategy.cache.name.INameCacheStrategy
124 * @see eu.etaxonomy.cdm.strategy.cache.common.IIdentifiableEntityCacheStrategy
126 protected NonViralName(){
128 setNameCacheStrategy();
132 * Class constructor: creates a new non viral taxon name instance
133 * only containing its {@link common.Rank rank},
134 * its {@link common.HomotypicalGroup homotypical group} and
135 * the {@link eu.etaxonomy.cdm.strategy.cache.name.NonViralNameDefaultCacheStrategy default cache strategy}.
137 * @param rank the rank to be assigned to this non viral taxon name
138 * @param homotypicalGroup the homotypical group to which this non viral taxon name belongs
139 * @see #NonViralName()
140 * @see #NonViralName(Rank, String, String, String, String, TeamOrPersonBase, INomenclaturalReference, String, HomotypicalGroup)
141 * @see #NewInstance(Rank, HomotypicalGroup)
142 * @see eu.etaxonomy.cdm.strategy.cache.name.INonViralNameCacheStrategy
143 * @see eu.etaxonomy.cdm.strategy.cache.name.INameCacheStrategy
144 * @see eu.etaxonomy.cdm.strategy.cache.common.IIdentifiableEntityCacheStrategy
146 protected NonViralName(Rank rank
, HomotypicalGroup homotypicalGroup
) {
147 super(rank
, homotypicalGroup
);
148 setNameCacheStrategy();
151 * Class constructor: creates a new non viral taxon name instance
152 * containing its {@link common.Rank rank},
153 * its {@link common.HomotypicalGroup homotypical group},
154 * its scientific name components, its {@link agent.TeamOrPersonBase author(team)},
155 * its {@link reference.INomenclaturalReference nomenclatural reference} and
156 * the {@link eu.etaxonomy.cdm.strategy.cache.name.NonViralNameDefaultCacheStrategy default cache strategy}.
158 * @param rank the rank to be assigned to this non viral taxon name
159 * @param genusOrUninomial the string for this taxon name
160 * if its rank is genus or higher or for the genus part
161 * if its rank is lower than genus
162 * @param infraGenericEpithet the string for the first epithet of
163 * this non viral taxon name if its rank is lower than genus
164 * and higher than species aggregate
165 * @param specificEpithet the string for the first epithet of
166 * this non viral taxon name if its rank is species aggregate or lower
167 * @param infraSpecificEpithet the string for the second epithet of
168 * this non viral taxon name if its rank is lower than species
169 * @param combinationAuthorTeam the author or the team who published this non viral taxon name
170 * @param nomenclaturalReference the nomenclatural reference where this non viral taxon name was published
171 * @param nomenclMicroRef the string with the details for precise location within the nomenclatural reference
172 * @param homotypicalGroup the homotypical group to which this non viral taxon name belongs
173 * @see #NonViralName()
174 * @see #NonViralName(Rank, HomotypicalGroup)
175 * @see #NewInstance(Rank, HomotypicalGroup)
176 * @see eu.etaxonomy.cdm.strategy.cache.name.INonViralNameCacheStrategy
177 * @see eu.etaxonomy.cdm.strategy.cache.name.INameCacheStrategy
178 * @see eu.etaxonomy.cdm.strategy.cache.common.IIdentifiableEntityCacheStrategy
180 protected NonViralName(Rank rank
, String genusOrUninomial
, String infraGenericEpithet
, String specificEpithet
, String infraSpecificEpithet
, TeamOrPersonBase combinationAuthorTeam
, INomenclaturalReference nomenclaturalReference
, String nomenclMicroRef
, HomotypicalGroup homotypicalGroup
) {
181 super(rank
, homotypicalGroup
);
182 setNameCacheStrategy();
183 setGenusOrUninomial(genusOrUninomial
);
184 setInfraGenericEpithet (infraGenericEpithet
);
185 setSpecificEpithet(specificEpithet
);
186 setInfraSpecificEpithet(infraSpecificEpithet
);
187 setCombinationAuthorTeam(combinationAuthorTeam
);
188 setNomenclaturalReference(nomenclaturalReference
);
189 this.setNomenclaturalMicroReference(nomenclMicroRef
);
192 //********* METHODS **************************************/
194 * Creates a new non viral taxon name instance
195 * only containing its {@link common.Rank rank} and
196 * the {@link eu.etaxonomy.cdm.strategy.cache.name.NonViralNameDefaultCacheStrategy default cache strategy}.
198 * @param rank the rank to be assigned to this non viral taxon name
199 * @see #NewInstance(Rank, HomotypicalGroup)
200 * @see #NonViralName(Rank, HomotypicalGroup)
201 * @see #NonViralName()
202 * @see #NonViralName(Rank, String, String, String, TeamOrPersonBase, INomenclaturalReference, String, HomotypicalGroup)
203 * @see eu.etaxonomy.cdm.strategy.cache.name.INonViralNameCacheStrategy
204 * @see eu.etaxonomy.cdm.strategy.cache.name.INameCacheStrategy
205 * @see eu.etaxonomy.cdm.strategy.cache.common.IIdentifiableEntityCacheStrategy
207 public static NonViralName
NewInstance(Rank rank
){
208 return new NonViralName(rank
, null);
212 * Creates a new non viral taxon name instance
213 * only containing its {@link common.Rank rank} and
214 * its {@link common.HomotypicalGroup homotypical group} and
215 * the {@link eu.etaxonomy.cdm.strategy.cache.name.NonViralNameDefaultCacheStrategy default cache strategy}.
216 * The new non viral taxon name instance will be also added to the set of
217 * non viral taxon names belonging to this homotypical group. If the homotypical
218 * group does not exist a new instance will be created for it.
220 * @param rank the rank to be assigned to this non viral taxon name
221 * @param homotypicalGroup the homotypical group to which this non viral taxon name belongs
222 * @see #NewInstance(Rank)
223 * @see #NonViralName(Rank, HomotypicalGroup)
224 * @see #NonViralName()
225 * @see #NonViralName(Rank, String, String, String, TeamOrPersonBase, INomenclaturalReference, String, HomotypicalGroup)
226 * @see eu.etaxonomy.cdm.strategy.cache.name.INonViralNameCacheStrategy
227 * @see eu.etaxonomy.cdm.strategy.cache.name.INameCacheStrategy
228 * @see eu.etaxonomy.cdm.strategy.cache.common.IIdentifiableEntityCacheStrategy
230 public static NonViralName
NewInstance(Rank rank
, HomotypicalGroup homotypicalGroup
){
231 return new NonViralName(rank
, homotypicalGroup
);
234 private void setNameCacheStrategy(){
235 if (getClass() == NonViralName
.class){
236 this.cacheStrategy
= NonViralNameDefaultCacheStrategy
.NewInstance();
243 * Returns the {@link eu.etaxonomy.cdm.strategy.cache.name.INonViralNameCacheStrategy cache strategy} used to generate
244 * several strings corresponding to this non viral taxon name
245 * (in particular taxon name caches and author strings).
247 * @return the cache strategy used for this non viral taxon name
248 * @see eu.etaxonomy.cdm.strategy.cache.name.INonViralNameCacheStrategy
249 * @see eu.etaxonomy.cdm.strategy.cache.name.INameCacheStrategy
250 * @see eu.etaxonomy.cdm.strategy.cache.common.IIdentifiableEntityCacheStrategy
254 public INonViralNameCacheStrategy
getCacheStrategy() {
255 return cacheStrategy
;
258 * @see #getCacheStrategy()
261 public void setCacheStrategy(INonViralNameCacheStrategy cacheStrategy
) {
262 this.cacheStrategy
= cacheStrategy
;
268 * Returns the {@link agent.INomenclaturalAuthor author (team)} that published this non viral
271 * @return the nomenclatural author (team) of this non viral taxon name
272 * @see agent.INomenclaturalAuthor
273 * @see agent.TeamOrPersonBase#getNomenclaturalTitle()
276 @Cascade({CascadeType
.SAVE_UPDATE
})
277 @Target(TeamOrPersonBase
.class)
278 public INomenclaturalAuthor
getCombinationAuthorTeam(){
279 return this.combinationAuthorTeam
;
282 * @see #getCombinationAuthorTeam()
284 public void setCombinationAuthorTeam(INomenclaturalAuthor combinationAuthorTeam
){
285 this.combinationAuthorTeam
= combinationAuthorTeam
;
289 * Returns the {@link agent.INomenclaturalAuthor author (team)} that contributed to
290 * the publication of this non viral taxon name as generally stated by
291 * the {@link #getCombinationAuthorTeam() combination author (team)} itself.
292 * The presence of an author (team) of this non viral taxon name is a
293 * condition for the existence of an ex author (team) for this same name.
295 * @return the nomenclatural ex author (team) of this non viral taxon name
296 * @see #getCombinationAuthorTeam()
297 * @see agent.INomenclaturalAuthor
298 * @see agent.TeamOrPersonBase#getNomenclaturalTitle()
301 @Cascade({CascadeType
.SAVE_UPDATE
})
302 @Target(TeamOrPersonBase
.class)
303 public INomenclaturalAuthor
getExCombinationAuthorTeam(){
304 return this.exCombinationAuthorTeam
;
307 * @see #getExCombinationAuthorTeam()
309 public void setExCombinationAuthorTeam(INomenclaturalAuthor exCombinationAuthorTeam
){
310 this.exCombinationAuthorTeam
= exCombinationAuthorTeam
;
314 * Returns the {@link agent.INomenclaturalAuthor author (team)} that published the original combination
315 * on which this non viral taxon name is nomenclaturally based. Such an
316 * author (team) can only exist if this non viral taxon name is a new
317 * combination due to a taxonomical revision.
319 * @return the nomenclatural basionym author (team) of this non viral taxon name
320 * @see #getCombinationAuthorTeam()
321 * @see agent.INomenclaturalAuthor
322 * @see agent.TeamOrPersonBase#getNomenclaturalTitle()
325 @Cascade({CascadeType
.SAVE_UPDATE
})
326 @Target(TeamOrPersonBase
.class)
327 public INomenclaturalAuthor
getBasionymAuthorTeam(){
328 return basionymAuthorTeam
;
331 * @see #getBasionymAuthorTeam()
333 public void setBasionymAuthorTeam(INomenclaturalAuthor basionymAuthorTeam
) {
334 this.basionymAuthorTeam
= basionymAuthorTeam
;
338 * Returns the {@link agent.INomenclaturalAuthor author (team)} that contributed to
339 * the publication of the original combination this non viral taxon name is
340 * based on. This should have been generally stated by
341 * the {@link #getCombinationAuthorTeam() basionym author (team)} itself.
342 * The presence of a basionym author (team) of this non viral taxon name is a
343 * condition for the existence of an ex basionym author (team)
344 * for this same name.
346 * @return the nomenclatural ex basionym author (team) of this non viral taxon name
347 * @see #getBasionymAuthorTeam()
348 * @see #getCombinationAuthorTeam()
349 * @see agent.INomenclaturalAuthor
350 * @see agent.TeamOrPersonBase#getNomenclaturalTitle()
353 @Cascade({CascadeType
.SAVE_UPDATE
})
354 @Target(TeamOrPersonBase
.class)
355 public INomenclaturalAuthor
getExBasionymAuthorTeam(){
356 return exBasionymAuthorTeam
;
359 * @see #getExBasionymAuthorTeam()
361 public void setExBasionymAuthorTeam(INomenclaturalAuthor exBasionymAuthorTeam
) {
362 this.exBasionymAuthorTeam
= exBasionymAuthorTeam
;
365 * Returns either the scientific name string (without authorship) for this
366 * non viral taxon name if its rank is genus or higher (monomial) or the string for
367 * the genus part of it if its {@link Rank rank} is lower than genus (bi- or trinomial).
368 * Genus or uninomial strings begin with an upper case letter.
370 * @return the string containing the suprageneric name, the genus name or the genus part of this non viral taxon name
371 * @see #getNameCache()
373 public String
getGenusOrUninomial() {
374 return genusOrUninomial
;
378 * @see #getGenusOrUninomial()
380 public void setGenusOrUninomial(String genusOrUninomial
) {
381 this.genusOrUninomial
= genusOrUninomial
;
385 * Returns the genus subdivision epithet string (infrageneric part) for
386 * this non viral taxon name if its {@link Rank rank} is infrageneric (lower than genus and
387 * higher than species aggregate). Genus subdivision epithet strings begin
388 * with an upper case letter.
390 * @return the string containing the infrageneric part of this non viral taxon name
391 * @see #getNameCache()
393 public String
getInfraGenericEpithet(){
394 return this.infraGenericEpithet
;
398 * @see #getInfraGenericEpithet()
400 public void setInfraGenericEpithet(String infraGenericEpithet
){
401 this.infraGenericEpithet
= infraGenericEpithet
;
405 * Returns the species epithet string for this non viral taxon name if its {@link Rank rank} is
406 * species aggregate or lower. Species epithet strings begin with a
409 * @return the string containing the species epithet of this non viral taxon name
410 * @see #getNameCache()
412 public String
getSpecificEpithet(){
413 return this.specificEpithet
;
417 * @see #getSpecificEpithet()
419 public void setSpecificEpithet(String specificEpithet
){
420 this.specificEpithet
= specificEpithet
;
424 * Returns the species subdivision epithet string (infraspecific part) for
425 * this non viral taxon name if its {@link Rank rank} is infraspecific (lower than species).
426 * Species subdivision epithet strings begin with a lower case letter.
428 * @return the string containing the infraspecific part of this non viral taxon name
429 * @see #getNameCache()
431 public String
getInfraSpecificEpithet(){
432 return this.infraSpecificEpithet
;
436 * @see #getInfraSpecificEpithet()
438 public void setInfraSpecificEpithet(String infraSpecificEpithet
){
439 this.infraSpecificEpithet
= infraSpecificEpithet
;
443 * Generates and returns the string with the scientific name of this
444 * non viral taxon name including author strings and maybe year according to
445 * the strategy defined in
446 * {@link eu.etaxonomy.cdm.strategy.cache.name.INonViralNameCacheStrategy INonViralNameCacheStrategy}.
447 * This string may be stored in the inherited
448 * {@link common.IdentifiableEntity#getTitleCache() titleCache} attribute.
449 * This method overrides the generic and inherited
450 * TaxonNameBase#generateTitle() method.
452 * @return the string with the composed name of this non viral taxon name with authorship (and maybe year)
453 * @see common.IdentifiableEntity#generateTitle()
454 * @see common.IdentifiableEntity#getTitleCache()
455 * @see TaxonNameBase#generateTitle()
458 public String
generateTitle(){
459 if (cacheStrategy
== null){
460 logger
.warn("No CacheStrategy defined for nonViralName: " + this.getUuid());
463 return cacheStrategy
.getTitleCache(this);
468 * Generates the composed name string of this non viral taxon name without author
469 * strings or year according to the strategy defined in
470 * {@link eu.etaxonomy.cdm.strategy.cache.name.INonViralNameCacheStrategy INonViralNameCacheStrategy}.
471 * The result might be stored in {@link #getNameCache() nameCache} if the
472 * flag {@link #isProtectedNameCache() protectedNameCache} is not set.
474 * @return the string with the composed name of this non viral taxon name without authors or year
475 * @see #getNameCache()
477 protected String
generateNameCache(){
478 if (cacheStrategy
== null){
479 logger
.warn("No CacheStrategy defined for taxonName: " + this.toString());
482 return cacheStrategy
.getNameCache(this);
487 * Returns or generates the nameCache (scientific name
488 * without author strings and year) string for this non viral taxon name. If the
489 * {@link #isProtectedNameCache() protectedNameCache} flag is not set (False)
490 * the string will be generated according to a defined strategy,
491 * otherwise the value of the actual nameCache string will be returned.
493 * @return the string which identifies this non viral taxon name (without authors or year)
494 * @see #generateNameCache()
496 public String
getNameCache() {
497 if (protectedNameCache
){
498 return this.nameCache
;
500 // is title dirty, i.e. equal NULL?
501 if (nameCache
== null){
502 this.nameCache
= generateNameCache();
508 * Assigns a nameCache string to this non viral taxon name and protects it from being overwritten.
510 * @param nameCache the string which identifies this non viral taxon name (without authors or year)
511 * @see #getNameCache()
513 public void setNameCache(String nameCache
){
514 this.nameCache
= nameCache
;
515 this.setProtectedTitleCache(false);
516 this.setProtectedNameCache(true);
520 * Returns the boolean value of the flag intended to protect (true)
521 * or not (false) the {@link #getNameCache() nameCache} (scientific name without author strings and year)
522 * string of this non viral taxon name.
524 * @return the boolean value of the protectedNameCache flag
525 * @see #getNameCache()
527 public boolean isProtectedNameCache() {
528 return protectedNameCache
;
532 * @see #isProtectedNameCache()
534 public void setProtectedNameCache(boolean protectedNameCache
) {
535 this.protectedNameCache
= protectedNameCache
;
540 * Generates and returns a concatenated and formated authorteams string
541 * including basionym and combination authors of this non viral taxon name
542 * according to the strategy defined in
543 * {@link eu.etaxonomy.cdm.strategy.cache.name.INonViralNameCacheStrategy#getAuthorshipCache(NonViralName) INonViralNameCacheStrategy}.
545 * @return the string with the concatenated and formated authorteams for this non viral taxon name
546 * @see eu.etaxonomy.cdm.strategy.cache.name.INonViralNameCacheStrategy#getAuthorshipCache(NonViralName)
548 public String
generateAuthorship(){
549 if (cacheStrategy
== null){
550 logger
.warn("No CacheStrategy defined for nonViralName: " + this.getUuid());
553 return ((INonViralNameCacheStrategy
<T
>)cacheStrategy
).getAuthorshipCache((T
)this);
558 * Returns the concatenated and formated authorteams string including
559 * basionym and combination authors of this non viral taxon name.
560 * If the protectedAuthorshipCache flag is set this method returns the
561 * string stored in the the authorshipCache attribute, otherwise it
562 * generates the complete authorship string, returns it and stores it in
563 * the authorshipCache attribute.
565 * @return the string with the concatenated and formated authorteams for this non viral taxon name
566 * @see #generateAuthorship()
568 public String
getAuthorshipCache() {
569 if (protectedAuthorshipCache
){
570 return this.authorshipCache
;
572 // is title dirty, i.e. equal NULL?
573 if (authorshipCache
== null){
574 this.authorshipCache
= generateAuthorship();
576 //TODO get is Dirty of authors
577 this.authorshipCache
= generateAuthorship();
579 return authorshipCache
;
583 * Assigns an authorshipCache string to this non viral taxon name.
585 * @param authorshipCache the string which identifies the complete authorship of this non viral taxon name
586 * @see #getAuthorshipCache()
588 public void setAuthorshipCache(String authorshipCache
) {
589 this.authorshipCache
= authorshipCache
;
595 * Returns the boolean value "false" since the components of this taxon name
596 * cannot follow the rules of a corresponding {@link NomenclaturalCode nomenclatural code}
597 * which is not defined for this class. The nomenclature code depends on
598 * the concrete name subclass ({@link BacterialName BacterialName},
599 * {@link BotanicalName BotanicalName}, {@link CultivarPlantName CultivarPlantName} or
600 * {@link ZoologicalName ZoologicalName} to which this non viral taxon name belongs.
601 * This method overrides the isCodeCompliant method from the abstract
602 * {@link TaxonNameBase#isCodeCompliant() TaxonNameBase} class.
605 * @see TaxonNameBase#isCodeCompliant()
609 public boolean isCodeCompliant() {
611 logger
.warn("is CodeCompliant not yet implemented");
616 * @see eu.etaxonomy.cdm.model.name.TaxonNameBase#getNomeclaturalCode()
619 * Returns null as {@link NomenclaturalCode nomenclatural code} that governs
620 * the construction of this non viral taxon name since there is no specific
621 * nomenclatural code defined. The real implementention takes place in the
622 * subclasses {@link BacterialName BacterialName},
623 * {@link BotanicalName BotanicalName}, {@link CultivarPlantName CultivarPlantName} and
624 * {@link ZoologicalName ZoologicalName}.
625 * This method overrides the getNomeclaturalCode method from {@link TaxonNameBase#getNomeclaturalCode() TaxonNameBase}.
628 * @see #isCodeCompliant()
629 * @see TaxonNameBase#getHasProblem()
633 public NomenclaturalCode
getNomenclaturalCode() {
634 //TODO What is the purpose of overriding the inherited method?
635 logger
.warn("Non Viral Name has no specific Code defined. Use subclasses");
640 * Returns the boolean value of the flag intended to protect (true)
641 * or not (false) the {@link #getAuthorshipCache() authorshipCache} (complete authorship string)
642 * of this non viral taxon name.
644 * @return the boolean value of the protectedAuthorshipCache flag
645 * @see #getAuthorshipCache()
647 public boolean isProtectedAuthorshipCache() {
648 return protectedAuthorshipCache
;
652 * @see #isProtectedAuthorshipCache()
653 * @see #getAuthorshipCache()
655 public void setProtectedAuthorshipCache(boolean protectedAuthorshipCache
) {
656 this.protectedAuthorshipCache
= protectedAuthorshipCache
;