Project

General

Profile

Download (2.51 KB) Statistics
| Branch: | Tag: | Revision:
1
/**
2
* Copyright (C) 2009 EDIT
3
* European Distributed Institute of Taxonomy
4
* http://www.e-taxonomy.eu
5
*
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.
8
*/
9

    
10
package eu.etaxonomy.cdm.strategy.cache.reference;
11

    
12
import eu.etaxonomy.cdm.model.reference.INomenclaturalReference;
13
import eu.etaxonomy.cdm.model.reference.Reference;
14

    
15
/**
16
 * A reference formatting strategy for all references implementing INomenclaturalReference.
17
 * As we handle all references in one class now, this could also be merged with {@link IReferenceCacheStrategy}.
18
 *
19
 * @author a.mueller
20
 *
21
 */
22
public interface INomenclaturalReferenceCacheStrategy extends IReferenceCacheStrategy {
23

    
24
	/**
25
	 * Returns the character sequence before the micro reference (e.g. ": ")
26
	 * @return
27
	 */
28
	public String getBeforeMicroReference();
29

    
30
	/**
31
	 * Returns a formatted string containing the entire citation used for
32
	 * nomenclatural purposes based on the {@link Reference reference} supplied - including
33
	 * (abbreviated) title  but not authors - and on the given details.<BR>
34
	 * The returned string is build according to the corresponding
35
	 * {@link INomenclaturalReferenceCacheStrategy cache strategy}.
36
	 *
37
	 * @param  nomenclaturalReference the nomenclatural reference
38
	 * @param  microReference	the string with the details (generally pages)
39
	 * 							corresponding to the nomenclatural reference supplied
40
	 * 							as the first argument
41
	 * @return					the formatted string representing the
42
	 * 							nomenclatural citation
43
	 * @see  					INomenclaturalReference#getNomenclaturalCitation(String)
44
	 * @see 					name.TaxonNameBase#getNomenclaturalReference()
45
	 */
46
	public String getNomenclaturalCitation(Reference nomenclaturalReference, String microReference);
47

    
48

    
49
	/**
50
	 * Computes the nomenclatural cache. This is the
51
	 * {@link #getNomenclaturalCitation(Reference, String) nomenclaturalCitation} without microReference.<BR>
52
	 * It is meant for searching and therefore cached in the Reference class.
53
	 * It is not meant for use on its own as a valid representation of a Reference.<BR>
54
	 * Note: often this string is not unique and can not be used as an identifier as e.g.
55
	 * multiple articles in the same volume of a journal may have the same nomenclatural cache.
56

    
57
     * @param  reference the reference
58
	 *
59
	 * @return the formatted string representing the nomenclatural cache
60
	 */
61
	public String getNomenclaturalCache(Reference reference);
62
}
(2-2/4)