196 |
/** |
/** |
197 |
* Creates a new visible {@link AttributeMetadata} with default (no) values. |
* Creates a new visible {@link AttributeMetadata} with default (no) values. |
198 |
*/ |
*/ |
199 |
public AttributeMetadata(final String localName, final String defaultTitle) { |
public AttributeMetadata(final String localName, final String defaultTitle, List<String> langs) { |
200 |
this(localName, true, new Translation(defaultTitle), new Translation(), |
this(localName, true, new Translation(langs, defaultTitle), new Translation(), |
201 |
""); |
""); |
202 |
} |
} |
203 |
|
|
204 |
/** |
/** |
205 |
* Creates a new visible {@link AttributeMetadata} with default (no) values. |
* Creates a new visible {@link AttributeMetadata} with default (no) values. |
206 |
*/ |
*/ |
207 |
public AttributeMetadata(final Name name, final String defaultTitle) { |
public AttributeMetadata(final Name name, final String defaultTitle, List<String> langs) { |
208 |
this(name, true, new Translation(defaultTitle), new Translation(), ""); |
this(name, true, new Translation(langs, defaultTitle), new Translation(), ""); |
209 |
} |
} |
210 |
|
|
211 |
/** |
/** |
212 |
* Creates a new visible {@link AttributeMetadata} with default (no) values. |
* Creates a new visible {@link AttributeMetadata} with default (no) values. |
213 |
*/ |
*/ |
214 |
public AttributeMetadata(final Name name) { |
public AttributeMetadata(final Name name, List<String> langs) { |
215 |
this(name, true, new Translation(name.getLocalPart()), |
this(name, true, new Translation(langs, name.getLocalPart()), |
216 |
new Translation(), ""); |
new Translation(), ""); |
217 |
} |
} |
218 |
|
|
219 |
/** |
/** |
220 |
* Creates a new visible {@link AttributeMetadata} with default (no) values. |
* Creates a new visible {@link AttributeMetadata} with default (no) values. |
221 |
*/ |
*/ |
222 |
public AttributeMetadata(final String localName) { |
public AttributeMetadata(final String localName, List<String> langs) { |
223 |
this(localName, true, new Translation(localName), new Translation(), ""); |
this(localName, true, new Translation(langs, localName), new Translation(), ""); |
224 |
} |
} |
225 |
|
|
226 |
/** Only used for {@link Copyable<AttributeMetaData>#copy()} **/ |
/** Only used for {@link Copyable<AttributeMetaData>#copy()} **/ |
227 |
private AttributeMetadata() { |
private AttributeMetadata() { |
228 |
} |
} |
229 |
|
|
230 |
public AttributeMetadata(AttributeDescriptor attDesc) { |
public AttributeMetadata(AttributeDescriptor attDesc, List<String> langs) { |
231 |
this(attDesc.getName()); |
this(attDesc.getName(), langs); |
232 |
} |
} |
233 |
|
|
234 |
public AttributeMetadata(AttributeDescriptor attDesc, int weight) { |
public AttributeMetadata(AttributeDescriptor attDesc, int weight, List<String> langs) { |
235 |
this(attDesc.getName()); |
this(attDesc.getName(), langs); |
236 |
setWeight(weight); |
setWeight(weight); |
237 |
} |
} |
238 |
|
|