Class SourceListDescriptor
Extracts and manages properties schema information from an underlying list and maintains an System.ComponentModel.ItemPropertiesVersion counter that is increased every time the underlying collection of System.ComponentModel.PropertyDescriptor objects is changed.
Inheritance
Implements
Inherited Members
Namespace: Syncfusion.Grouping
Assembly: Syncfusion.Grouping.Base.dll
Syntax
public class SourceListDescriptor : DescriptorBase, ICustomTypeDescriptor, IDisposable, ITypedList, IItemPropertiesSource
Constructors
SourceListDescriptor()
Initializes a new empty SourceListDescriptor.
Declaration
public SourceListDescriptor()
SourceListDescriptor(Object)
Initializes a new SourceListDescriptor and initializes the ItemProperties collection from properties of the specified list.
Declaration
public SourceListDescriptor(object list)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Object | list | A list from which the collection has to be created. |
SourceListDescriptor(String, PropertyDescriptorCollection)
Initializes a new SourceListDescriptor and initializes the ItemProperties collection from properties of the specified System.ComponentModel.PropertyDescriptorCollection.
Declaration
public SourceListDescriptor(string name, PropertyDescriptorCollection itemProperties)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | name | The name value. |
| System.ComponentModel.PropertyDescriptorCollection | itemProperties | A collection of properties. |
SourceListDescriptor(Type)
Initializes a new SourceListDescriptor and initalializes the ItemProperties collection from properties of the specified type.
Declaration
public SourceListDescriptor(Type type)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Type | type | The Type value. |
Properties
IgnoreSetItemProperties
Gets or sets a property indicating whether subsequent calls to SetItemProperties on this TableDescriptor should be ignored. The default is false. You should set this property True if you manually want to add/merge PropertyDescriptors. It will prevent that the grid does not reinitialize the ItemProperties with results from calls to ITypedList.GetItemProperties later on.
Declaration
public bool IgnoreSetItemProperties { get; set; }
Property Value
| Type |
|---|
| System.Boolean |
ItemProperties
Gets or sets the System.ComponentModel.PropertyDescriptorCollection with properties for each record in the table.
Declaration
public virtual PropertyDescriptorCollection ItemProperties { get; set; }
Property Value
| Type |
|---|
| System.ComponentModel.PropertyDescriptorCollection |
ItemPropertiesVersion
Gets or sets the version of the ItemProperties collection. This value is increased each time the ItemProperties collection is modified.
Declaration
public int ItemPropertiesVersion { get; set; }
Property Value
| Type |
|---|
| System.Int32 |
Name
Gets or sets the name of this table.
Declaration
public virtual string Name { get; set; }
Property Value
| Type |
|---|
| System.String |
SourceListSet
Gets or sets a reference to a SourceListDescriptor. A SourceListSet manages multiple SourceListDescriptor objects (or TableDescriptor objects) that belong to the same Engine object.
Declaration
public SourceListSet SourceListSet { get; set; }
Property Value
| Type |
|---|
| SourceListSet |
Methods
Dispose(Boolean)
Declaration
protected override void Dispose(bool disposing)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Boolean | disposing |
Overrides
GetName()
Gets the descriptor name.
Declaration
public override string GetName()
Returns
| Type | Description |
|---|---|
| System.String | Descriptor name. |
Overrides
OnInitializeItemProperties(EventArgs)
Raises the InitializeItemProperties event.
Declaration
protected virtual void OnInitializeItemProperties(EventArgs e)
Parameters
| Type | Name | Description |
|---|---|---|
| System.EventArgs | e |
OnItemPropertiesChanged(EventArgs)
Raises the ItemPropertiesChanged event.
Declaration
protected virtual void OnItemPropertiesChanged(EventArgs e)
Parameters
| Type | Name | Description |
|---|---|---|
| System.EventArgs | e | The System.EventArgsthat contains event data. |
OnItemPropertiesChanging(EventArgs)
Raises the ItemPropertiesChanging event.
Declaration
protected virtual void OnItemPropertiesChanging(EventArgs e)
Parameters
| Type | Name | Description |
|---|---|---|
| System.EventArgs | e | The System.EventArgsthat contains event data. |
OnListChanged(ListChangedEventArgs)
Raises the ListChanged event.
Declaration
protected virtual void OnListChanged(ListChangedEventArgs e)
Parameters
| Type | Name | Description |
|---|---|---|
| System.ComponentModel.ListChangedEventArgs | e | The System.ComponentModel.ListChangedEventArgsthat contains event data. |
OnListChanging(ListChangedEventArgs)
Raises the ListChanging event.
Declaration
protected virtual void OnListChanging(ListChangedEventArgs e)
Parameters
| Type | Name | Description |
|---|---|---|
| System.ComponentModel.ListChangedEventArgs | e | The System.ComponentModel.ListChangedEventArgsthat contains event data. |
OnNameChanged(EventArgs)
Raises the NameChanged event.
Declaration
protected virtual void OnNameChanged(EventArgs e)
Parameters
| Type | Name | Description |
|---|---|---|
| System.EventArgs | e | The System.EventArgsthat contains event data. |
OnNameChanging(EventArgs)
Raises the NameChanging event.
Declaration
protected virtual void OnNameChanging(EventArgs e)
Parameters
| Type | Name | Description |
|---|---|---|
| System.EventArgs | e | The System.EventArgsthat contains event data. |
Reset()
Resets this object and clears cached properties.
Declaration
public override void Reset()
Overrides
ResetItemProperties()
For internal use.
Declaration
public void ResetItemProperties()
ResetName()
Resets the Name to its default value.
Declaration
public void ResetName()
SetItemProperties(PropertyDescriptorCollection)
Initializes a new instance of the ItemProperties collection.
Declaration
public void SetItemProperties(PropertyDescriptorCollection properties)
Parameters
| Type | Name | Description |
|---|---|---|
| System.ComponentModel.PropertyDescriptorCollection | properties | The properties. |
SetItemProperties(Object)
Initializes the ItemProperties collection from the instance properties of the specified list.
Declaration
public void SetItemProperties(object list)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Object | list | The list with properties. |
SetItemProperties(Type)
Initializes the ItemProperties collection from the properties of the specified type.
Declaration
public void SetItemProperties(Type type)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Type | type | The type with public properties. |
ShouldSerializeItemProperties()
Determines if the ItemProperties was initialized.
Declaration
public bool ShouldSerializeItemProperties()
Returns
| Type | Description |
|---|---|
| System.Boolean | True if the object should be serialized; False otherwise. |
ShouldSerializeName()
Determines if the Name was modified from its default value.
Declaration
public virtual bool ShouldSerializeName()
Returns
| Type | Description |
|---|---|
| System.Boolean | True if it was modified. |
Events
InitializeItemProperties
Occurs when the ItemProperties is accessed for the first time and has not been initialized before.
Declaration
public event EventHandler InitializeItemProperties
Event Type
| Type |
|---|
| System.EventHandler |
ItemPropertiesChanged
Occurs after the ItemProperties collection of this table was changed.
Declaration
public event EventHandler ItemPropertiesChanged
Event Type
| Type |
|---|
| System.EventHandler |
ItemPropertiesChanging
Occurs before the ItemProperties collection of this table is changed.
Declaration
public event EventHandler ItemPropertiesChanging
Event Type
| Type |
|---|
| System.EventHandler |
ListChanged
Occurs after the underlying collection was changed. When an System.ComponentModel.IBindingList.ListChanged event is handled, this event is raised after the ItemProperties collection is updated.
Declaration
public event ListChangedEventHandler ListChanged
Event Type
| Type |
|---|
| System.ComponentModel.ListChangedEventHandler |
ListChanging
Occurs before the underlying collection is changed. When an System.ComponentModel.IBindingList.ListChanged event is handled, this event is raised before the ItemProperties collection is updated.
Declaration
public event ListChangedEventHandler ListChanging
Event Type
| Type |
|---|
| System.ComponentModel.ListChangedEventHandler |
NameChanged
Occurs after the Name of this table is changed.
Declaration
public event EventHandler NameChanged
Event Type
| Type |
|---|
| System.EventHandler |
NameChanging
Occurs before the Name of this table is changed.
Declaration
public event EventHandler NameChanging
Event Type
| Type |
|---|
| System.EventHandler |
Explicit Interface Implementations
IItemPropertiesSource.GetItemProperties()
Declaration
PropertyDescriptorCollection IItemPropertiesSource.GetItemProperties()
Returns
| Type |
|---|
| System.ComponentModel.PropertyDescriptorCollection |