You are here: Symbol Reference > MtxExpr Namespace > Classes > Matrix Record > public > WriteValues Method > Matrix.WriteValues Method (TStream, TPrecision, TRounding)
MtxVec VCL
ContentsIndex
PreviousUpNext
Matrix.WriteValues Method (TStream, TPrecision, TRounding)

Writes object Values content to a stream.

Pascal
procedure WriteValues(const Dst: TStream; Precision: TPrecision; Rounding: TRounding = rnTrunc); overload;

Writes the calling object Values content to the DstStream stream. No other values describing the data type or length are written to the DstStream. Number type is defined by the Precision parameter. Rounding defines the rounding for integer types. When saving double precision as single precision, all overflows are saved as INF (-INF). When saving to integer types all overflows are clipped. Attempt to save single precision as double precision will raise an exception. The paramateres must be the same as for the WriteHeader method.

Use this method separately only, if you want user defined storage format.

var b: Matrix; AStream: TFileStream; begin b.SetIt(2,2,False,[0,0,1,3,2]); AStream := TFileStream.Create('C:test.Vec',fmCreate); try b.WriteHeader(AStream); // Write info for b b.WriteValues(AStream); // Write values of b finally AStream.Free; end; end;
Examples on GitHub
Copyright (c) 1999-2024 by Dew Research. All rights reserved.
What do you think about this topic? Send feedback!