PropertyItem

StockSharp.Xaml.PropertyGrid.Maui

Represents a property item in the property grid.

Implements: INotifyPropertyChanged

Constructors

PropertyItem
public PropertyItem(PropertyInfo propertyInfo, object target)
propertyItem = PropertyItem(propertyInfo, target)

Creates a new property item.

Properties

Category
public string Category { get; }
value = propertyItem.Category

Category name (from CategoryAttribute).

Description
public string Description { get; }
value = propertyItem.Description

Property description (from DescriptionAttribute).

DisplayName
public string DisplayName { get; }
value = propertyItem.DisplayName

Display name (from DisplayAttribute or DisplayNameAttribute).

EnumValues
public Array EnumValues { get; }
value = propertyItem.EnumValues

Enum values for enum properties.

IsBasic
public bool IsBasic { get; }
value = propertyItem.IsBasic

Whether this is a basic property (shown in basic mode).

IsBool
public bool IsBool { get; }
value = propertyItem.IsBool

Whether the property is a boolean.

IsEnum
public bool IsEnum { get; }
value = propertyItem.IsEnum

Whether the property is an enum.

IsNumeric
public bool IsNumeric { get; }
value = propertyItem.IsNumeric

Whether the property is numeric.

IsReadOnly
public bool IsReadOnly { get; set; }
value = propertyItem.IsReadOnly
propertyItem.IsReadOnly = value

Whether the property is read-only.

IsText
public bool IsText { get; }
value = propertyItem.IsText

Whether the property is a string or simple text type.

Name
public string Name { get; }
value = propertyItem.Name

Property name.

Order
public int Order { get; }
value = propertyItem.Order

Display order.

PropertyInfo
public PropertyInfo PropertyInfo { get; }
value = propertyItem.PropertyInfo

The PropertyInfo for reflection.

PropertyType
public Type PropertyType { get; }
value = propertyItem.PropertyType

Property type.

Target
public object Target { get; }
value = propertyItem.Target

The target object.

Value
public object Value { get; set; }
value = propertyItem.Value
propertyItem.Value = value

Current property value.

ValueAsBool
public bool ValueAsBool { get; set; }
value = propertyItem.ValueAsBool
propertyItem.ValueAsBool = value

Value as bool for switch binding.

ValueAsString
public string ValueAsString { get; set; }
value = propertyItem.ValueAsString
propertyItem.ValueAsString = value

Value as string for display.

Methods

OnPropertyChanged
protected virtual void OnPropertyChanged(string propertyName)
propertyItem.OnPropertyChanged(propertyName)

Raises the PropertyChanged event.

RefreshValue
public void RefreshValue()
propertyItem.RefreshValue()

Refreshes the value from the target object.

Events

PropertyChanged
public event PropertyChangedEventHandler PropertyChanged
propertyItem.PropertyChanged += handler

Property changed event.