RAD Studio VCL Reference
ContentsIndex
PreviousUpNext
TCustomVariantType.Clear Method

Sets the data for this custom Variant type to a blank or unassigned value.

Pascal
procedure Clear(var V: TVarData); virtual; abstract;
C++
virtual __fastcall Clear(TVarData V) = 0;

Override Clear to implement the way this custom Variant type represents a blank or unassigned value. 

V is a TVarData record that represents the data from a Variant of this custom type that needs to be cleared. 

In TCustomVariantType, Clear is an abstract method. Descendant classes must override this method to provide an implementation. If the custom Variant type stores its data in a manner that includes memory that needs to be freed, Clear should free that memory. Once any memory is freed, Clear can call the SimplisticClear method, which re-initializes the TVarData record, or set the VType field to varEmpty. 

 

Copyright(C) 2008 CodeGear(TM). All Rights Reserved.
What do you think about this topic? Send feedback!