变体记录
TMsg02 = packed record
case _DT: Byte of
$01: (_Msg0201: TMsg0201);
$02: (_Msg0202: TMsg0202);
$03: (_Msg0203: TMsg0203);
$04: (_Msg0204: TMsg0204);
$05: (_Msg0205: TMsg0205);
$06: (_Msg0206: TMsg0206);
$07: (_Msg0207: TMsg0207);
$08: (_Msg0208: TMsg0208);
end;
Char($02): case Dt of
Char($01): Result := Sizeof(_X._Msg02._Msg0201);
Char($02): Result := Sizeof(_X._Msg02._Msg0202);
Char($03): Result := Sizeof(_X._Msg02._Msg0203);
Char($04): Result := Sizeof(_X._Msg02._Msg0204);
Char($05): Result := Sizeof(_X._Msg02._Msg0205);
Char($06): Result := Sizeof(_X._Msg02._Msg0206);
Char($07): Result := Sizeof(_X._Msg02._Msg0207);
Char($08): Result := Sizeof(_X._Msg02._Msg0208);
end;
本文来自博客园,作者:{咏南中间件},转载请注明原文链接:https://www.cnblogs.com/hnxxcxg/archive/2010/09/18/2940674.html