|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.dasein.attributes.DataType<Currency>
org.dasein.attributes.types.CurrencyFactory.CurrencyAttribute
public static class CurrencyFactory.CurrencyAttribute
Implementation of rules for currency attributes.
Last modified: $Date: 2006/03/25 06:17:05 $
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class org.dasein.attributes.DataType |
|---|
DataType.InputType |
| Constructor Summary | |
|---|---|
CurrencyFactory.CurrencyAttribute(boolean ml,
boolean mv,
boolean req)
Constructs a currency attribute that enables users to select among all installed currencies on the system. |
|
CurrencyFactory.CurrencyAttribute(boolean ml,
boolean mv,
boolean req,
String codes)
Constructs a currency attribute instance in which the type parameters define a specific list of allowed currency codes. |
|
| Method Summary | |
|---|---|
Collection<Currency> |
getChoices()
Provides a list of values considered valid for this data type. |
DataTypeFactory<Currency> |
getFactory()
|
DataType.InputType |
getInputType()
|
Currency |
getValue(Object val)
Provides a currency value based on a raw value. |
boolean |
isValidChoice(Currency curr)
Validates that the specified currency is a valid value for this data type. |
String |
toString()
|
| Methods inherited from class org.dasein.attributes.DataType |
|---|
equals, getName, getParameters, getSize, getTranslatedValue, getValues, hashCode, isMultiLingual, isMultiValued, isRequired |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public CurrencyFactory.CurrencyAttribute(boolean ml,
boolean mv,
boolean req)
ml - is the attribute multi-lingual?mv - does the attribute allow multiple values?req - is a value required for this attribute?
public CurrencyFactory.CurrencyAttribute(boolean ml,
boolean mv,
boolean req,
String codes)
ml - is this data type multi-lingual?mv - does this data type allow multiple values?req - does this data type require a value?codes - a comma-delimited string defining acceptable currency codes| Method Detail |
|---|
public Collection<Currency> getChoices()
DataTypenull.
getChoices in class DataType<Currency>public DataTypeFactory<Currency> getFactory()
getFactory in class DataType<Currency>public DataType.InputType getInputType()
getInputType in class DataType<Currency>InputType#MULTI_SELECT, otherwise
InputType#SELECTpublic Currency getValue(Object val)
Currency instances or currency codes as strings.
getValue in class DataType<Currency>val - the raw value
public boolean isValidChoice(Currency curr)
isValidChoice in class DataType<Currency>curr - the currency being validated
public String toString()
toString in class DataType<Currency>
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||