UNPKG

diffusion

Version:

Diffusion JavaScript client

34 lines (32 loc) 1.13 kB
var _interface = require('util/interface')._interface; /** * Signed 64-bit integer. Provides a means to read integer values larger than supported natively by JavaScript. * <P> * Used as the value type of the Int64 data type: * <code> * var datatype = diffusion.datatypes.int64(); * var value = new datatype.Int64("12498352809328592352350908124"); * </code> * <P> * * @class diffusion.datatypes.Int64 * @since 6.0 */ module.exports = _interface('Int64', [ /** * Read this value as a string. * * @param {Number} [radix=10] - The radix to use. Defaults to base <code>10</code>. * @return {String} the string representation of the int64 value. * @function diffusion.datatypes.Int64#toString */ 'toString', /** * Read this value as a number. The validity of the returned number can only be guaranteed for values up to * <code>Math.pow(2, 53) - 1</code> due to underlying platform limitations of JavaScript. * * @return {Number} the numerical value of this int64, as a 53-bit integer. * @function diffusion.datatypes.Int64#toNumber */ 'toNumber' ]);