Class GregorianCalendarDatatype
java.lang.Object
org.faktorips.datatype.AbstractDatatype
org.faktorips.datatype.ValueClassNameDatatype
org.faktorips.datatype.classtypes.GregorianCalendarDatatype
- All Implemented Interfaces:
Comparable<Datatype>,Datatype,ValueDatatype
- Direct Known Subclasses:
GregorianCalendarAsDateDatatype
-
Field Summary
Fields inherited from interface org.faktorips.datatype.Datatype
BIG_DECIMAL, BOOLEAN, DECIMAL, DOUBLE, GREGORIAN_CALENDAR, INTEGER, LONG, MONEY, PRIMITIVE_BOOLEAN, PRIMITIVE_INT, PRIMITIVE_LONG, STRING, VOID -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionThis method parses the given string and returns the value as an instance of the class this value datatype represents.booleanReturnstrueif this is a mutable datatype,falseif it is an immutable datatype.booleanisParsable(String value) Returnstrueif the given string can be parsed to a value of this datatype.booleanvalueToString(Object value) Returns the string representation of the given value.Methods inherited from class org.faktorips.datatype.ValueClassNameDatatype
areValuesEqual, compare, getDefaultValue, getName, getQualifiedName, getWrapperType, hasNullObject, isAbstract, isImmutable, isNull, isPrimitive, isValueDatatypeMethods inherited from class org.faktorips.datatype.AbstractDatatype
checkReadyToUse, compareTo, equals, hashCode, isEnum, isVoid, matchDatatype, toStringMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface java.lang.Comparable
compareToMethods inherited from interface org.faktorips.datatype.ValueDatatype
checkReadyToUse, getNullObjectId
-
Constructor Details
-
GregorianCalendarDatatype
-
-
Method Details
-
isMutable
public boolean isMutable()Description copied from interface:ValueDatatypeReturnstrueif this is a mutable datatype,falseif it is an immutable datatype.- Specified by:
isMutablein interfaceValueDatatype- Overrides:
isMutablein classValueClassNameDatatype- Returns:
- whether this is a mutable datatype
-
getValue
Description copied from class:ValueClassNameDatatypeThis method parses the given string and returns the value as an instance of the class this value datatype represents. Use with caution: During development time Faktor-IPS maintains all values with their string representation. This allows to change the value's datatype without the need to convert the value from one class to another (e.g. if the string representation is 42 you can change the datatype from integer to string without converting the integer object to a string object.- Specified by:
getValuein interfaceValueDatatype- Specified by:
getValuein classValueClassNameDatatype- Parameters:
value- string representation of the value- Returns:
- The value as instance of the class this datatype represents.
- See Also:
-
isParsable
Description copied from interface:ValueDatatypeReturnstrueif the given string can be parsed to a value of this datatype. Returnsfalseotherwise.- Specified by:
isParsablein interfaceValueDatatype- Overrides:
isParsablein classValueClassNameDatatype
-
valueToString
Description copied from class:ValueClassNameDatatypeReturns the string representation of the given value. The String value returned by this method must be parsable by theValueClassNameDatatype.getValue(String)method.- Specified by:
valueToStringin interfaceValueDatatype- Overrides:
valueToStringin classValueClassNameDatatype- Parameters:
value- a value of this datatype- Returns:
- the value's string representation
- See Also:
-
supportsCompare
public boolean supportsCompare()- Returns:
trueif this datatype is able to compare two values.
-