RAD Studio VCL Reference
ContentsIndex
PreviousUpNext
TAdapterSubComponent.CanAddClass Method

Indicates whether an object of a specified type can be added to this collection.

Pascal
function CanAddClass(AParent: TComponent; AClass: TClass): Boolean;
C++
__fastcall Boolean CanAddClass(TComponent * AParent, TClass AClass);

The IDE calls CanAddClass to determine what Web items can be added to this list. This method allows the IDE to limit the actions or fields in the collection to those that are appropriate for the associated adapter. 

AParent is the TAdapterSubComponent descendant to which the Web item will be added. 

AClass is the class of the proposed child item. 

CanAddClass returns true if the TAdapterSubComponent descendant can include a child of type AClass, false otherwise. 

CanAddClass calls the virtual ImplCanAddClass method to determine whether a class of Web item is valid. 

 

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