TGuidHelper.Create

Initialize a TGUID instance from data.

Declaration

Source position: syshelph.inc line 36

default 
  class function Create(const Data; BigEndian: Boolean) : TGUID;  Overload
                       ;  Static;
  class function Create(const Data: Array of Byte; AStartIndex: Cardinal; 
                       BigEndian: Boolean) : TGUID;  Overload;  Static;
  class function Create(const Data; DataEndian: TEndian) : TGUID
                       ;  Overload;  Static;
  class function Create(const B: TBytes; DataEndian: TEndian) : TGUID
                       ;  Overload;  Static;
  class function Create(const B: TBytes; AStartIndex: Cardinal; 
                       DataEndian: TEndian) : TGUID;  Overload;  Static;
  class function Create(const S: string) : TGUID;  Overload;  Static;
  class function Create(A: Integer; B: SmallInt; C: SmallInt; 
                       const D: TBytes) : TGUID;  Overload;  Static;
  class function Create(A: Integer; B: SmallInt; C: SmallInt; D: Byte; 
                       E: Byte; F: Byte; G: Byte; H: Byte; I: Byte; 
                       J: Byte; K: Byte) : TGUID;  Overload;  Static;
  class function Create(A: Cardinal; B: Word; C: Word; D: Byte; E: Byte; 
                       F: Byte; G: Byte; H: Byte; I: Byte; J: Byte; 
                       K: Byte) : TGUID;  Overload;  Static;

Description

Create will initialize a TGUID]() from byte data. The byte-data can come in different forms

Data
can be a plain buffer. The GUID Data will be read from the buffer (SizeOf(TGUID) bytes), according to the BigEndian argument.
Data
can be an array of bytes. SizeOf(TGUID) bytes will be read from the array, starting at index StartIndex (default 0). The GUID Data will be read according to the BigEndian argument.
S
can be a string containing a string representation of the GUID, which is converted using StringToGUID .
A,B,C,D (optionally E,F,G,H,I,J,K)
where the arguments are simply the various components of the GUID.

See also

Name Description
StringToGUID Convert a string to a native TGUID type.
TGUID Standard GUID representation type.