- 01
- 02
- 03
- 04
- 05
- 06
- 07
- 08
- 09
- 10
- 11
- 12
- 13
- 14
- 15
- 16
- 17
- 18
- 19
- 20
- 21
- 22
- 23
- 24
- 25
- 26
- 27
- 28
- 29
- 30
- 31
- 32
- 33
- 34
- 35
- 36
- 37
value =
(obj instanceof ParameterAlias)
? "@" + ((ParameterAlias) obj).getAlias()
: (obj instanceof Boolean)
? BooleanUtils.toStringTrueFalse((Boolean) obj)
: (obj instanceof UUID)
? obj.toString()
: (obj instanceof byte[])
? EdmBinary.getInstance().toUriLiteral(Hex.encodeHexString((byte[]) obj))
: (obj instanceof Timestamp)
? timestamp((Timestamp) obj)
: (obj instanceof Calendar)
? calendar((Calendar) obj)
: (obj instanceof Duration)
? duration((Duration) obj)
: (obj instanceof BigDecimal)
? EdmDecimal.getInstance().valueToString(obj, null, null,
Constants.DEFAULT_PRECISION, Constants.DEFAULT_SCALE, null)
: (obj instanceof Double)
? EdmDouble.getInstance().valueToString(obj, null, null,
Constants.DEFAULT_PRECISION, Constants.DEFAULT_SCALE, null)
: (obj instanceof Float)
? EdmSingle.getInstance().valueToString(obj, null, null,
Constants.DEFAULT_PRECISION, Constants.DEFAULT_SCALE, null)
: (obj instanceof Long)
? EdmInt64.getInstance().valueToString(obj, null, null,
Constants.DEFAULT_PRECISION, Constants.DEFAULT_SCALE, null)
: (obj instanceof Geospatial)
? Encoder.encode(EdmPrimitiveTypeFactory.getInstance(
((Geospatial) obj).getEdmPrimitiveTypeKind()).
valueToString(obj, null, null,
Constants.DEFAULT_PRECISION,
Constants.DEFAULT_SCALE, null))
: (obj instanceof String)
? quoteString((String) obj, singleQuoteEscape)
: obj.toString();