AttachedProperty<TValue>.

AttachedProperty(string, Type, StyledPropertyMetadata<TValue>, bool, Func<TValue, bool>) Constructor

Summary

Initializes a new instance of the AttachedProperty<TValue> class.
Namespace
Avalonia
Containing Type
AttachedProperty<TValue>

Syntax

public AttachedProperty(string name, Type ownerType, StyledPropertyMetadata<TValue> metadata, bool inherits = false, Func<TValue, bool> validate = null)

Parameters

Name Type Description
name string The name of the property.
ownerType Type The class that is registering the property.
metadata StyledPropertyMetadata<TValue> The property metadata.
inherits bool Whether the property inherits its value.
validate Func<TValue, bool> A value validation callback.

Return Value

Type Description
void