Contents · Forum Home · StreamSec Tools 4.1.5.363 documentation

StreamSec.Snif.Conversion

Feature notes: Snif remoting framework (concepts)

Classes, interfaces and records

classEsnifError

inherits from Exception

Root of the snif exception hierarchy. Declared here because StreamSec.Snif.Conversion is the deepest unit of the family - it depends on nothing but the RTL and stDERUtils - so every other snif unit can reach it without a new dependency.

(no public members)

classEsnifConversion

inherits from EsnifError

A value could not be marshalled onto, or read back off, the wire: the payload length does not match the type, the RTTI kind has no wire representation, or a TsnipValue was read as the wrong kind.

(no public members)

interfaceIsnipValueData

(no public members)

recordTsnipValueRecord

(no public members)

recordTsnifNamedValue

fName: string; fValue: TsnipValueRecord;

recordTsnipValue

property IsArray: Boolean read GetIsArray; property IsRecord: Boolean read GetIsRecord; property IsBytes: Boolean read GetIsBytes; property IsString: Boolean read GetIsString; property IsValue: Boolean read GetIsValue;

interfaceIsnipValueData

function GetArray: TsnifArray; function GetRecord: TsnifRecord;

recordTsnifRecordWrapper

procedure Init(aType: TRttiRecordType); overload; procedure Init(aType: TRttiRecordType; aInstance: Pointer); overload; function GetField(const aName: string): TValue; procedure SetField(const aName: string; const aValue: TsnipValue); class function Convert(const aSrc: TsnifRecord; aType: TRttiRecordType): TValue; static; class procedure ConvertRaw(const aSrc: TsnifRecord; aType: TRttiRecordType; aDst: Pointer); static; class function Revert(const aValue: TValue; aType: TRttiRecordType): TsnifRecord; static; class function RevertString(const aValue: TValue; aType: TRttiRecordType): TsnifRecord; static; class function RevertBytes(const aValue: TValue; aType: TRttiRecordType): TsnifRecord; static;

recordTsnifArrayWrapper

class function Convert(const aSrc: TsnifArray; aType: TRttiType): TValue; overload; static; class function Convert(const aSrc: TsnifArray; aType: TRttiArrayType): TValue; overload; static; class function Convert(const aSrc: TsnifArray; aType: TRttiDynamicArrayType): TValue; overload; static; class function Revert(const aValue: TValue): TsnifArray; static; class function RevertString(const aValue: TValue): TsnifArray; static; class function RevertBytes(const aValue: TValue): TsnifArray; static;

classTsnifConversions

class function CanConvert(aType: PTypeInfo): Boolean; static; class function CanConvertSimple(aType: PTypeInfo): Boolean; static; class function Convert(const aSrc: TsnipValue; aType: PTypeInfo): TValue; static; class function Revert(const aSrc: TValue): TsnipValue; overload; static; class function Revert(const aSrc: TValue; aKind: TsnifConversionKind): TsnipValue; overload; static; class function RevertString(const aSrc: TValue): TsnipValue; static; class function RevertBytes(const aSrc: TValue): TsnipValue; static; class function RevertNone(const aSrc: TValue): TsnipValue; static;
Delegates to TsnipValue, forwarding aSrc, and returns its result.

Types (enumerations, sets, aliases)

enumTsnifConversionKind

  TsnifConversionKind = (ckBytes,ckStrings,ckStructuredOnly,ckNone);

enumTsnifValueKind

  TsnifValueKind = (vkBytes,vkString,vkValue,vkRecord,vkArray);

arrayTsnifArray

  TsnifArray = array of TsnipValueRecord;

arrayTsnifRecord

  TsnifRecord = array of TsnifNamedValue;