writeFloat

[ Function ]

public writeFloat(value: number): this;

Encodes a floating point number with an accuracy of seven significant digits in four bytes and appends them to the data.

Parameter

Name

Type

Description

value

number

The value to be written

Return value

Type

Description

Base64BinaryWriter

This method returns its parent object to allow concatenation of method calls.

Sample - JavaScript

var writer = new TcHmi.Base64BinaryWriter();
var result1 = writer.writeFloat(3.1415926).getEncodedString(); // '2g9JQA=='
writeFloat 1:

Available from version 1.10