Revision a7f996b4
Added by Katja Luther over 13 years ago
cdmlib-model/src/main/java/eu/etaxonomy/cdm/model/description/IndividualsAssociation.java | ||
---|---|---|
133 | 133 |
* @param description the language string describing the individuals association |
134 | 134 |
* in a particular language |
135 | 135 |
* @see #getDescription() |
136 |
* @see #addDescription(String, Language) |
|
136 |
* @see #putDescription(Language, String) |
|
137 |
* @deprecated should follow the put semantic of maps, this method will be removed in v4.0 |
|
138 |
* Use the {@link #putDescription(LanguageString) putDescription} method instead |
|
137 | 139 |
*/ |
138 | 140 |
public void addDescription(LanguageString description){ |
141 |
this.putDescription(description); |
|
142 |
} |
|
143 |
|
|
144 |
/** |
|
145 |
* Adds a translated {@link LanguageString text in a particular language} |
|
146 |
* to the {@link MultilanguageText multilanguage text} used to describe |
|
147 |
* <i>this</i> individuals association. |
|
148 |
* |
|
149 |
* @param description the language string describing the individuals association |
|
150 |
* in a particular language |
|
151 |
* @see #getDescription() |
|
152 |
* @see #putDescription(Language, String) |
|
153 |
* |
|
154 |
*/ |
|
155 |
public void putDescription(LanguageString description){ |
|
139 | 156 |
this.description.put(description.getLanguage(),description); |
140 | 157 |
} |
141 | 158 |
/** |
... | ... | |
147 | 164 |
* in a particular language |
148 | 165 |
* @param language the language in which the text string is formulated |
149 | 166 |
* @see #getDescription() |
150 |
* @see #addDescription(LanguageString)
|
|
167 |
* @see #putDescription(LanguageString)
|
|
151 | 168 |
*/ |
152 |
public void addDescription(String text, Language language){
|
|
169 |
public void putDescription(Language language, String text){
|
|
153 | 170 |
this.description.put(language, LanguageString.NewInstance(text, language)); |
154 | 171 |
} |
172 |
|
|
173 |
/** |
|
174 |
* Creates a {@link LanguageString language string} based on the given text string |
|
175 |
* and the given {@link Language language} and adds it to the {@link MultilanguageText multilanguage text} |
|
176 |
* used to describe <i>this</i> individuals association. |
|
177 |
* |
|
178 |
* @param text the string describing the individuals association |
|
179 |
* in a particular language |
|
180 |
* @param language the language in which the text string is formulated |
|
181 |
* @see #getDescription() |
|
182 |
* @see #putDescription(LanguageString) |
|
183 |
* @deprecated should follow the put semantic of maps, this method will be removed in v4.0 |
|
184 |
* Use the {@link #putDescription(Language, String) putDescription} method instead |
|
185 |
*/ |
|
186 |
public void addDescription(String text, Language language){ |
|
187 |
this.putDescription(language, text); |
|
188 |
} |
|
155 | 189 |
/** |
156 | 190 |
* Removes from the {@link MultilanguageText multilanguage text} used to describe |
157 | 191 |
* <i>this</i> individuals association the one {@link LanguageString language string} |
Also available in: Unified diff
the deprecated methods call the new methods (#2176)