FORMAT_CURRENCY
Take a currency and local format and create a formatted string.
Declaration
FORMAT_CURRENCY(currencyNumber, localeString) -> formattedString
Parameters
currencyNumber - number - A number representing a currency.
localeString - string - String representing the locale to match the format (e.g. "en-US").
Return Values
formattedString - string - A formatted string created by taking the currencyNumber and applying the local format to it.
FORMAT_NUMBER
Given a number and a local, produce a correctly formatted number string
Declaration
FORMAT_NUMBER(number, localFormat) -> formattedString
Parameters
number - number - The number to be formatted.
localFormat - string - String representing the local to format for.
Return Values
formattedString - string - A string created by taking the number and applying the local format to it.
FORMAT_PHONE
take in a phone number string and format the output to the corresponding format.
Declaration
FORMAT_PHONE(stringPhoneNumber, formatString) -> formatedPhoneNumber
Parameters
stringPhoneNumber - string - Phone number in string format.
formatString - string - String representing the output format (any of "E164", "INTERNATIONAL", "NATIONAL", "RFC3966").
Return Values
formatedPhoneNumber - string - String with the formatted phone number.
LATLNGDISTANCE
Declaration
LATLNGDISTANCE(latitude1, longitude1, latitude2, longitude2, measureString) -> resultNumber
LATLNGDISTANCE(latitude1, longitude1, latitude2, longitude2) -> resultNumber
Parameters
latitude1 - number - Number represenation of the latitude for first position.
longitude1 - number - Number representation of the longitude for the first position.
latitude2 - number - Number representation of the latitude of the second position.
longitude2 - number - Number representation of the longitude of the second position.
measureString - string - What distance we should use for the measure.
Return Values
resultNumber - number - Number of units of the distance between the two points.
RANDOM
Return a random number with optional min, max and shouldFloor parameters.
Declaration
RANDOM(minOrMaxNumber, max, shouldFloor) -> randomNumber
Parameters
minOrMaxNumber - number - If the max is present this is the min value. If not this value will be the max value.
max - number - If present this is the maximum.
shouldFloor - boolean - Boolean to indicate whether the return value should be a real number or an integer.
Return Values
randomNumber - number - A random number between in the range specified.
Comments
0 comments
Please sign in to leave a comment.