Skip to content

InfragisticsGridCustomizer

InfragisticsGridCustomizer is the core in-memory state manager for a single UltraWebGrid's customizable column visibility and paging, backing Customize and apply grid column visibility and paging. It initializes its column list from the target grid, loads any previously-saved column/paging preferences, and applies the resulting state back onto the live grid on demand.

Purpose

  • Builds and maintains a HidableInfragisticsColumn per target-grid column, tracking each column's current visibility and its always-visible/always-hidden/normal visibility mode, enforcing BR-AJAX-002.
  • Validates that configured always-visible/always-hidden column keys actually exist on the target grid at construction time, enforcing BR-AJAX-003.
  • Loads and saves column-selection and page-size preferences to/from a clsPreferences store, keyed by the target grid's ID.
  • Applies (ManipulateGrid) the current in-memory visibility/paging state onto a live UltraWebGrid instance by inserting/removing UltraGridColumns from its Columns collection.

Context

  • Namespace: SAIF.Presentation.Web.Controls.V2.AJAX
  • Assembly/package: SAIF.Presentation.Web.Controls.AJAX.Infragistics103

Public members

Member Signature Purpose
DefaultPageSize Public Const DefaultPageSize As Integer = 50 Fallback page size used when no preference and no existing grid paging setting is found
MinimumPagesForDisplay Public Const MinimumPagesForDisplay As Integer = 2 Minimum page count enforced on the grid's pager when ControlPaging is enabled
TargetGridId ReadOnly Property TargetGridId() As String The ID of the UltraWebGrid this customizer manages
PageSize Property PageSize() As Integer The currently configured page size for the target grid
ControlPaging Property ControlPaging() As Boolean Indicates whether this customizer manages the target grid's paging settings
VisibleItems ReadOnly Property VisibleItems() As Generic.List(Of HidableInfragisticsColumn) The subset of tracked columns that ManipulateGrid should keep rendered on the live grid, filtering out those the user or an always-hidden override has suppressed
Item Default Shadows ReadOnly Property Item(inColumnKey As String) As HidableInfragisticsColumn Looks up a tracked column by its grid column key
ListItems ReadOnly Property ListItems() As Generic.List(Of ListItem) Builds the checkbox-list items (caption, key, selected, enabled) shown in the customization popup, excluding always-hidden columns
PreferenceData ReadOnly Property PreferenceData() As String Serializes the current column selections into the delimited preference string format
New Sub New(inModel As Object, inGrid As UltraWebGrid, inAlwaysVisibleColumnKeys As String, inAlwaysHiddenColumnKeys As String, inControlPaging As Boolean) Initializes the customizer from the grid's current column set, validates visibility overrides, and loads saved preferences
GetPreferenceData Shared Function GetPreferenceData(inListItems As ListItemCollection) As String Serializes a checkbox-list selection into the delimited preference string format
Update Sub Update(inColumnInfo As ListItemCollection, inPageSize As Integer) Updates in-memory column visibility flags and page size from user-submitted checkbox selections
ManipulateGrid Sub ManipulateGrid(inGrid As UltraWebGrid) Applies the current in-memory visibility/paging state onto the live target grid's Columns and DisplayLayout.Pager
BindObjectBinder Sub BindObjectBinder(inObjectBinder As SAIF.Presentation.Web.Binding.clsObjectBindManager, inGrid As UltraWebGrid) Rebinds the target grid via the page's clsObjectBindManager
BindGrid Sub BindGrid(inGrid As UltraWebGrid) Rebinds the target grid by calling its native DataBind()

Inherited public members

Members in this section are inherited from Generic.List(Of HidableInfragisticsColumn) in the .NET Framework Base Class Library. They are available on this type through inheritance.

Member Signature Purpose Origin
Count ReadOnly Property Count As Integer The number of tracked columns (HidableInfragisticsColumn entries) on the target grid mscorlib — System.Collections.Generic.List(Of T)
Add Sub Add(item As HidableInfragisticsColumn) Adds a tracked column entry to the customizer's internal column list mscorlib — System.Collections.Generic.List(Of T)
GetEnumerator Function GetEnumerator() As List(Of HidableInfragisticsColumn).Enumerator Supports For Each iteration over the tracked columns mscorlib — System.Collections.Generic.List(Of T)
Find Function Find(match As Predicate(Of HidableInfragisticsColumn)) As HidableInfragisticsColumn Locates the first tracked column matching a predicate (e.g., by key) mscorlib — System.Collections.Generic.List(Of T)

Behavioral notes

  • LoadColumnPreferences silently skips any saved preference whose column key no longer exists on the target grid, rather than failing*.
  • SavePreferences (Protected Friend, invoked via ModalGridCustomizer) serializes selections through ColumnPreferenceList and calls Preferences.Save(), whose underlying persistence mechanism is inferred to be SAIF.Framework.Preferences**.

Constraints and usage notes

  • Construction throws ApplicationException if a configured always-visible/always-hidden column key does not exist on the target grid, per BR-AJAX-003.

Note: Statements marked with * were inferred from code structure, naming conventions, or contextual evidence where direct confirmation was not available in source artifacts. Statements marked with ** could not be confirmed; treat as unknown until verified.

Sources

  • SAIF.Presentation.Web.Controls.AJAX.Infragistics103\InfragisticsGridCustomizer.vb