Project

General

Profile

« Previous | Next » 

Revision 892efc69

Added by Andreas Kohlbecker almost 14 years ago

merging /branches/cdmlib/SPRINT-Chichorieae1/ to trunk

View differences:

cdmlib-model/src/main/java/eu/etaxonomy/cdm/model/reference/ReferenceType.java
46 46
	@XmlEnumValue("Generic")
47 47
	Generic("Generic", GenericDefaultCacheStrategy.class),
48 48
	@XmlEnumValue("Inproceedings")
49
	InProceedings("Inproceedings", ReferenceBaseDefaultCacheStrategy.class),
49
	InProceedings("In Proceedings", ReferenceBaseDefaultCacheStrategy.class),
50 50
	@XmlEnumValue("Journal")
51 51
	Journal("Journal", JournalDefaultCacheStrategy.class),
52 52
	@XmlEnumValue("Map")
......
66 66
	@XmlEnumValue("Web Page")
67 67
	WebPage("Web Page", ReferenceBaseDefaultCacheStrategy.class), 
68 68
	@XmlEnumValue("Printed Unit Base")
69
	@Deprecated // all references are ReferenceBases this type should not longer be used. Use isPrintedUnit() for tests against this type instead.
69 70
	PrintedUnitBase("Printed Unit Base", ReferenceBaseDefaultCacheStrategy.class), 
70 71
	@XmlEnumValue("Publication Base")
72
	@Deprecated // all references are ReferenceBases this type should not longer be used. Use isPublication() for tests against this type instead.
71 73
	PublicationBase("Publication Base", ReferenceBaseDefaultCacheStrategy.class);
72 74
	
73 75
	
......
109 111
	}
110 112
	
111 113
	public boolean isVolumeReference(){
112
		return (isPrintedUnit() || this == Generic || this == Article);
114
		return (this == Article || isPrintedUnit());
113 115
	}
114 116
	
115 117
	public boolean isPublication(){
116 118
		return (this == CdDvd || this == Database || this == Generic
117
				|| this == Journal || this == Map || this == Book
118
				|| this == Proceedings || this == PrintSeries
119
				|| this == Report || this == Thesis || this == WebPage);			
119
				|| this == Journal || isPrintedUnit() ||  this == PrintSeries
120
				|| this == Proceedings || this == Report 
121
				|| this == Thesis || this == WebPage);			
120 122
	}
121 123
	
122 124
	public boolean isPrintedUnit(){
123
		return (this == Book || this == Proceedings);
125
		return (this == Book);
124 126
	}
125 127
	
126 128
	public boolean isSection(){
127
		return (this == BookSection || this == InProceedings);
129
		return (this == BookSection || this == InProceedings || isVolumeReference());
128 130
	}
129 131
	
130 132
}

Also available in: Unified diff