Skip to content
Reference > Methods

encodeDouble64(value)

Definition

String encodeDouble64(Number value)

Description

Encodes a double to a base64 string prepended with an F. This is the same encoding used in AmiClient::addMessageParamDoubleEncoded

Parameter Definition

Name Type Description
value Number double value to encode

Examples

1
2
3
String r1 = encodeDouble64(123.0D); // r1 == DEBewAAAAAAA
String r2 = encodeDouble64(-123.0D); // r2 == D8BewAAAAAAA
String r3 = encodeDouble64(0.0D); // r3 == DAAAAAAAAAAA