ContainedBindComponent#

Qualified name: delphivcl.ContainedBindComponent

class ContainedBindComponent#

Bases: BasicBindComponent

Base class for all common binding components descending from it. TContainedBindComponent is an abstract class that is the base class for TCommonBindComponent.

Methods

BindMethodsToEvents

Connects methods to component events if they are named using the following pattern: Prefix_ComponentName_EventName.

CanSetControlComponent

Returns whether the control component can be set a given value.

Create

Creates an instance of the TContainedBindComponent class.

Destroy

Destroys an instance of the TContainedBindComponent class.

GetParentComponent

Returns the containing component.

HasParent

Verifies whether the contained binding component has a parent.

SetParentComponent

Sets the parent component of this component.

Attributes

BindingsList

Specifies a list that holds the binding expressions.

Category

Specifies a category for this component.

ClassName

Returns the TObject.ClassName

ComObject

Specifies the interface reference implemented by the component.

ComponentCount

Returns the owned component count

ComponentIndex

Indicates the position of the component in its owner's Components property array.

ComponentState

Describes the current state of the component, indicating when a component needs to avoid certain actions.

ComponentStyle

Governs the behavior of the component.

Components

Returns an iterator over the owned components

ControlComponent

Specifies the component that will be bound to the source component, by means of LiveBindings.

DesignInfo

Contains information used by the Form designer.

DisplayName

Returns a string containing the name of this component.

Index

Returns the index of this component in the bindings list.

Name

Specifies the name of the component as referenced in code.

Observers

Indicates the TObservers object added to the TComponent.

Owner

Returns the Component Owner

Tag

Stores a NativeInt integral value as a part of a component.

VCLComObject

Represents information used internally by components that support COM.

BindMethodsToEvents(prefix)#

Connects methods to component events if they are named using the following pattern: Prefix_ComponentName_EventName. Example: def handle_button1_OnClick(Sender): pass The function returns a list of tuples. Each tuple contains the name of the component, the name of the event and the method object assigned to the event. Note that the prefix parameter is optional and will default to “handle_”.

BindingsList#

Specifies a list that holds the binding expressions.

CanSetControlComponent(Value: Component) Boolean#

Returns whether the control component can be set a given value. As implemented in TContainedBindComponent, CanSetControlComponent always returns True, but in descendants it actually returns whether the given Value (that is itself a TComponent) can be assigned to the control component.

Category#

Specifies a category for this component. For example, for a binding expression called BindExpressionForm121, of type TBindExpression, the following code:

ShowMessage(BindExpressionForm121.Category);

shows the following message: Binding Expressions.

ComponentCount#

Returns the owned component count

Components#

Returns an iterator over the owned components

ControlComponent#

Specifies the component that will be bound to the source component, by means of LiveBindings.

Create(AOwner: Component)#

Creates an instance of the TContainedBindComponent class.

Destroy()#

Destroys an instance of the TContainedBindComponent class.

DisplayName#

Returns a string containing the name of this component.

GetParentComponent()#

Returns the containing component. GetParentComponent returns a reference to the component that contains the current component, or nil if there is no container. Use HasParent to determine whether a component has a containing component.

HasParent()#

Verifies whether the contained binding component has a parent. HasParent returns True if the contained binding component has a parent, False otherwise.

Index#

Returns the index of this component in the bindings list.

Owner#

Returns the Component Owner

SetParentComponent(AParent: Component)#

Sets the parent component of this component. SetParentComponent is used internally in the component streaming system. It is not necessary to call it directly.