New to Telerik UI for WinFormsStart a free 30-day trial

Represents a disposable object that stores its properties within a dynamic property bag, enabling efficient property management for charting objects.

Definition

Namespace:Telerik.Charting

Assembly:Telerik.WinControls.dll

Syntax:

C#
public abstract class PropertyBagObject : DisposableObject, IDisposable

Inheritance: objectDisposableObjectPropertyBagObject

Derived Classes: ChartNodeSparkNode

Implements: IDisposable

Inherited Members DisposableObject.Dispose()DisposableObject.DisposeUnmanagedResources()DisposableObject.IsDisposingDisposableObject.IsDisposedDisposableObject.EventsDisposableObject.DisposingDisposableObject.Disposed...

Constructors

Initializes a new instance of the PropertyBagObject class.

C#
protected PropertyBagObject()

Properties

Gets the underlying property store that manages dynamic properties.

C#
public FastPropertyStore PropertyStore { get; }
Property Value:

The fast property store instance.

Methods

Clears the value of a property from the property store.

C#
public bool ClearValue(int key)
Parameters:keyint

The property key to clear.

Returns:

bool

true if the value was cleared successfully; otherwise, false.

Core implementation for clearing a property value. Override to provide custom clearing logic.

C#
public virtual bool ClearValueCore(int key)
Parameters:keyint

The property key to clear.

Returns:

bool

true if the value was cleared successfully; otherwise, false.

Disposes all managed resources allocated by this instance.

C#
protected override void DisposeManagedResources()

Overrides: DisposableObject.DisposeManagedResources()

Gets a strongly-typed property value with a default fallback.

C#
public T GetTypedValue<T>(int key, T defaultValue)
Parameters:keyint

The property key.

defaultValueT

The default value to return if the property is not set.

Returns:

T

The typed property value or the default value if not found.

Gets the value of a property from the property store.

C#
public object GetValue(int key)
Parameters:keyint

The property key.

Returns:

object

The property value, or null if not found.

Determines whether a property value is set locally in the property store.

C#
public bool IsLocalValue(int key)
Parameters:keyint

The property key to check.

Returns:

bool

true if the property has a local value; otherwise, false.

Sets the value of a property in the property store.

C#
public bool SetValue(int key, object value)
Parameters:keyint

The property key.

valueobject

The property value to set.

Returns:

bool

true if the value was set successfully; otherwise, false.

Core implementation for setting a property value. Override to provide custom setting logic.

C#
public virtual bool SetValueCore(int key, object value)
Parameters:keyint

The property key.

valueobject

The property value to set.

Returns:

bool

true if the value was set successfully; otherwise, false.