RAD Studio VCL Reference
ContentsIndex
PreviousUpNext
TAbstractFieldValuesAdapter.GetValueIndex Method

Returns an index that identifies the current adapter field value.

Pascal
function GetValueIndex: Integer;
C++
__fastcall int GetValueIndex();

Although this adapter only includes a single adapter field, that field may have several values (for example, if it represents a column in a table). When the field has several values, GetValueIndex is the index of the current value. This index may be the same as the value that the GetIteratorIndex method returns if the application is using the adapter's iteration support. However, TAbstractFieldValuesAdapter introduces GetValueIndex as a separate method for descendants that support multiple values that change using some other mechanism. 

GetValueIndex calls the abstract or, in C++ terminology, pure virtual ImplGetValueIndex method to obtain the index of the current value. Descendant classes override ImplGetValueIndex to provide the underlying implementation for GetValueIndex. 

 

Copyright(C) 2009 Embarcadero Technologies, Inc. All Rights Reserved.
What do you think about this topic? Send feedback!