Class ArchiveConfigurationProviderBase
This base class provides common functionality for Dynamic MDO list providers that convert the list of supported columns or list of supported entities of an IArchiveProvider into MDO lists for use in a selection GUI. Derived classes provide functionality specific to column and entity lists, and further derivation brings us to the concrete level that also splices in current configuration data, if known.
Inheritance
Inherited Members
Namespace: SuperOffice.CRM.ArchiveLists
Assembly: SoDataBase.dll
Syntax
public abstract class ArchiveConfigurationProviderBase : IDynamicMDOProvider, ISoListProvider, ISoList
Remarks
Specializations that override behaviour on a per-archive bases should probably be made from the ChooseColumnsProvider or the ChooseEntityProvider classes. This top level and the level below (ArchiveColumnsProviderBase and ArchiveEntitiesProviderBase) contain functionality that is quite generic. Also keep in mind that setting mandatory columns and excluding columns is done through the GUI configuration XML, not through code at this level.
Overriding the ChooseColumnsProvider is indicated if you want to retrieve the current configuration from a non-standard source.Constructors
ArchiveConfigurationProviderBase()
Constructor
Declaration
protected ArchiveConfigurationProviderBase()
Remarks
Specializations that override behaviour on a per-archive bases should probably be made from the ChooseColumnsProvider or the ChooseEntityProvider classes. This top level and the level below (ArchiveColumnsProviderBase and ArchiveEntitiesProviderBase) contain functionality that is quite generic. Also keep in mind that setting mandatory columns and excluding columns is done through the GUI configuration XML, not through code at this level.
Overriding the ChooseColumnsProvider is indicated if you want to retrieve the current configuration from a non-standard source.Fields
_additionalInfo
This base class provides common functionality for Dynamic MDO list providers that convert the list of supported columns or list of supported entities of an IArchiveProvider into MDO lists for use in a selection GUI. Derived classes provide functionality specific to column and entity lists, and further derivation brings us to the concrete level that also splices in current configuration data, if known.
Declaration
protected string _additionalInfo
Field Value
Type | Description |
---|---|
string |
Remarks
Specializations that override behaviour on a per-archive bases should probably be made from the ChooseColumnsProvider or the ChooseEntityProvider classes. This top level and the level below (ArchiveColumnsProviderBase and ArchiveEntitiesProviderBase) contain functionality that is quite generic. Also keep in mind that setting mandatory columns and excluding columns is done through the GUI configuration XML, not through code at this level.
Overriding the ChooseColumnsProvider is indicated if you want to retrieve the current configuration from a non-standard source._headingItems
This base class provides common functionality for Dynamic MDO list providers that convert the list of supported columns or list of supported entities of an IArchiveProvider into MDO lists for use in a selection GUI. Derived classes provide functionality specific to column and entity lists, and further derivation brings us to the concrete level that also splices in current configuration data, if known.
Declaration
protected List<ISoListHeading> _headingItems
Field Value
Type | Description |
---|---|
List<ISoListHeading> |
Remarks
Specializations that override behaviour on a per-archive bases should probably be made from the ChooseColumnsProvider or the ChooseEntityProvider classes. This top level and the level below (ArchiveColumnsProviderBase and ArchiveEntitiesProviderBase) contain functionality that is quite generic. Also keep in mind that setting mandatory columns and excluding columns is done through the GUI configuration XML, not through code at this level.
Overriding the ChooseColumnsProvider is indicated if you want to retrieve the current configuration from a non-standard source._historyItems
This base class provides common functionality for Dynamic MDO list providers that convert the list of supported columns or list of supported entities of an IArchiveProvider into MDO lists for use in a selection GUI. Derived classes provide functionality specific to column and entity lists, and further derivation brings us to the concrete level that also splices in current configuration data, if known.
Declaration
protected List<ISoListItem> _historyItems
Field Value
Type | Description |
---|---|
List<ISoListItem> |
Remarks
Specializations that override behaviour on a per-archive bases should probably be made from the ChooseColumnsProvider or the ChooseEntityProvider classes. This top level and the level below (ArchiveColumnsProviderBase and ArchiveEntitiesProviderBase) contain functionality that is quite generic. Also keep in mind that setting mandatory columns and excluding columns is done through the GUI configuration XML, not through code at this level.
Overriding the ChooseColumnsProvider is indicated if you want to retrieve the current configuration from a non-standard source._rootItems
This base class provides common functionality for Dynamic MDO list providers that convert the list of supported columns or list of supported entities of an IArchiveProvider into MDO lists for use in a selection GUI. Derived classes provide functionality specific to column and entity lists, and further derivation brings us to the concrete level that also splices in current configuration data, if known.
Declaration
protected List<ISoListItem> _rootItems
Field Value
Type | Description |
---|---|
List<ISoListItem> |
Remarks
Specializations that override behaviour on a per-archive bases should probably be made from the ChooseColumnsProvider or the ChooseEntityProvider classes. This top level and the level below (ArchiveColumnsProviderBase and ArchiveEntitiesProviderBase) contain functionality that is quite generic. Also keep in mind that setting mandatory columns and excluding columns is done through the GUI configuration XML, not through code at this level.
Overriding the ChooseColumnsProvider is indicated if you want to retrieve the current configuration from a non-standard source.Properties
AllItems
This property provides an iterator that will go through all items as if we have a flat list, regardless of the actual structure (flat or with headings). Heading items are skipped.
Declaration
public IEnumerable<ISelectableListItem> AllItems { get; }
Property Value
Type | Description |
---|---|
IEnumerable<ISelectableListItem> |
Remarks
Specializations that override behaviour on a per-archive bases should probably be made from the ChooseColumnsProvider or the ChooseEntityProvider classes. This top level and the level below (ArchiveColumnsProviderBase and ArchiveEntitiesProviderBase) contain functionality that is quite generic. Also keep in mind that setting mandatory columns and excluding columns is done through the GUI configuration XML, not through code at this level.
Overriding the ChooseColumnsProvider is indicated if you want to retrieve the current configuration from a non-standard source.HeadingItems
Return the heading items; this may be an empty list if we are in flat mode or there were no display name prefixes in the underlying providers' column lists. If a gui control name was passed in as extraInfo to the provider factory, the Selected property reflects whether the current configuration for that gui control has selected this column for display. The ExtraInfo property contains an orderby indicator; either Y or N or an existing orderby specification of the form n:A or n:D.
Declaration
public List<ISoListHeading> HeadingItems { get; }
Property Value
Type | Description |
---|---|
List<ISoListHeading> |
Remarks
Specializations that override behaviour on a per-archive bases should probably be made from the ChooseColumnsProvider or the ChooseEntityProvider classes. This top level and the level below (ArchiveColumnsProviderBase and ArchiveEntitiesProviderBase) contain functionality that is quite generic. Also keep in mind that setting mandatory columns and excluding columns is done through the GUI configuration XML, not through code at this level.
Overriding the ChooseColumnsProvider is indicated if you want to retrieve the current configuration from a non-standard source.HistoryInfo
Return history information, part of the interface. Not valid for this kind of provider, so returns null.
Declaration
public HistoryInfo HistoryInfo { get; }
Property Value
Type | Description |
---|---|
HistoryInfo |
Remarks
Specializations that override behaviour on a per-archive bases should probably be made from the ChooseColumnsProvider or the ChooseEntityProvider classes. This top level and the level below (ArchiveColumnsProviderBase and ArchiveEntitiesProviderBase) contain functionality that is quite generic. Also keep in mind that setting mandatory columns and excluding columns is done through the GUI configuration XML, not through code at this level.
Overriding the ChooseColumnsProvider is indicated if you want to retrieve the current configuration from a non-standard source.HistoryItems
Return the history items. This is always an empty list.
Declaration
public List<ISoListItem> HistoryItems { get; }
Property Value
Type | Description |
---|---|
List<ISoListItem> |
Remarks
Specializations that override behaviour on a per-archive bases should probably be made from the ChooseColumnsProvider or the ChooseEntityProvider classes. This top level and the level below (ArchiveColumnsProviderBase and ArchiveEntitiesProviderBase) contain functionality that is quite generic. Also keep in mind that setting mandatory columns and excluding columns is done through the GUI configuration XML, not through code at this level.
Overriding the ChooseColumnsProvider is indicated if you want to retrieve the current configuration from a non-standard source.InternalNamePrefix
This property should return the name prefix used to build the SoList provider name from the archive data provider name
Declaration
protected abstract string InternalNamePrefix { get; }
Property Value
Type | Description |
---|---|
string |
Remarks
Specializations that override behaviour on a per-archive bases should probably be made from the ChooseColumnsProvider or the ChooseEntityProvider classes. This top level and the level below (ArchiveColumnsProviderBase and ArchiveEntitiesProviderBase) contain functionality that is quite generic. Also keep in mind that setting mandatory columns and excluding columns is done through the GUI configuration XML, not through code at this level.
Overriding the ChooseColumnsProvider is indicated if you want to retrieve the current configuration from a non-standard source.RootItems
Return the root items. If a gui control name was passed in as extraInfo to the provider factory, the Selected property reflects whether the current configuration for that gui control has selected this column for display. The ExtraInfo property contains an orderby indicator; either Y or N or an existing orderby specification of the form n:A or n:D.
Declaration
public List<ISoListItem> RootItems { get; }
Property Value
Type | Description |
---|---|
List<ISoListItem> |
Remarks
Specializations that override behaviour on a per-archive bases should probably be made from the ChooseColumnsProvider or the ChooseEntityProvider classes. This top level and the level below (ArchiveColumnsProviderBase and ArchiveEntitiesProviderBase) contain functionality that is quite generic. Also keep in mind that setting mandatory columns and excluding columns is done through the GUI configuration XML, not through code at this level.
Overriding the ChooseColumnsProvider is indicated if you want to retrieve the current configuration from a non-standard source.SupportedLists
Return the list of supported lists; here, that means the list of archive data providers whose column lists are handled by this provider. The SoListProviderFactory will sort providers according to priority and eliminate duplicates.
Declaration
public HistoryInfo[] SupportedLists { get; }
Property Value
Type | Description |
---|---|
HistoryInfo[] |
Remarks
Specializations that override behaviour on a per-archive bases should probably be made from the ChooseColumnsProvider or the ChooseEntityProvider classes. This top level and the level below (ArchiveColumnsProviderBase and ArchiveEntitiesProviderBase) contain functionality that is quite generic. Also keep in mind that setting mandatory columns and excluding columns is done through the GUI configuration XML, not through code at this level.
Overriding the ChooseColumnsProvider is indicated if you want to retrieve the current configuration from a non-standard source.Methods
AcceptProvider(string)
This method is called once for every archive provider in the system. If it returns true, it means that this archive should be handled by this MDO column list provider. The generic ChooseDisplayColumnsProvider and ChooseDisplayEntitiesProvider will handle any archives not handled by other, more specific implementations.
Declaration
protected virtual bool AcceptProvider(string providerName)
Parameters
Type | Name | Description |
---|---|---|
string | providerName | Name of archive provider |
Returns
Type | Description |
---|---|
bool | true if this archive is to be handled by this MDO provider |
Remarks
Specializations that override behaviour on a per-archive bases should probably be made from the ChooseColumnsProvider or the ChooseEntityProvider classes. This top level and the level below (ArchiveColumnsProviderBase and ArchiveEntitiesProviderBase) contain functionality that is quite generic. Also keep in mind that setting mandatory columns and excluding columns is done through the GUI configuration XML, not through code at this level.
Overriding the ChooseColumnsProvider is indicated if you want to retrieve the current configuration from a non-standard source.BuildList(string, string, string, bool)
This method is called during stage 2 of the two-phase construction process (from the Construct(string, string, int[], bool, string, bool) method). The actual implementation of the list construction, including new'ing the _rootItems and _headingItems collections should be placed in this method. Note that _historyItems is by default always empty for this kind of list, so it is pre-allocated as such by this base class; implementers can override this behaviour if it makes sense to them.
Declaration
protected abstract void BuildList(string providerName, string guiControl, string searchValue, bool forceFlatList)
Parameters
Type | Name | Description |
---|---|---|
string | providerName | |
string | guiControl | Name of GUI control, if provided by caller |
string | searchValue | Search value, if provided by caller |
bool | forceFlatList | Should the resulting list be forced to flat format (root items only) |
Remarks
Specializations that override behaviour on a per-archive bases should probably be made from the ChooseColumnsProvider or the ChooseEntityProvider classes. This top level and the level below (ArchiveColumnsProviderBase and ArchiveEntitiesProviderBase) contain functionality that is quite generic. Also keep in mind that setting mandatory columns and excluding columns is done through the GUI configuration XML, not through code at this level.
Overriding the ChooseColumnsProvider is indicated if you want to retrieve the current configuration from a non-standard source.Construct(string, string, int[], bool, string, bool)
Construct the list provider, according to the given parameters; if a GUI name is given as additionalInfo then we will also fetch and indicate the 'selected' status, i.e., the current configuration of that archive
Declaration
public void Construct(string listName, string additionalInfo, int[] historyIDs, bool onlyReadHistory, string searchValue, bool forceFlatList)
Parameters
Type | Name | Description |
---|---|---|
string | listName | List name must be NamePrefix + an archive provider name, i.e., one of 'our' list names |
string | additionalInfo | If given, must be the GUI name associated with the control. |
int[] | historyIDs | Ignored, we have no history concept |
bool | onlyReadHistory | If true, an empty list will be returned |
string | searchValue | If set, only column names starting with the given string will be returned |
bool | forceFlatList | If true, no grouping will occur |
Remarks
Specializations that override behaviour on a per-archive bases should probably be made from the ChooseColumnsProvider or the ChooseEntityProvider classes. This top level and the level below (ArchiveColumnsProviderBase and ArchiveEntitiesProviderBase) contain functionality that is quite generic. Also keep in mind that setting mandatory columns and excluding columns is done through the GUI configuration XML, not through code at this level.
Overriding the ChooseColumnsProvider is indicated if you want to retrieve the current configuration from a non-standard source.MergeInCurrentConfiguration(string, object)
Given the name of a gui control and the current state of the MDO list, fetch and merge in the current state of that gui control (i.e., the currently selected controls, and current orderby constraints)
Declaration
protected void MergeInCurrentConfiguration(string guiName, object extraInfo)
Parameters
Type | Name | Description |
---|---|---|
string | guiName | Name of gui control |
object | extraInfo |
Remarks
Specializations that override behaviour on a per-archive bases should probably be made from the ChooseColumnsProvider or the ChooseEntityProvider classes. This top level and the level below (ArchiveColumnsProviderBase and ArchiveEntitiesProviderBase) contain functionality that is quite generic. Also keep in mind that setting mandatory columns and excluding columns is done through the GUI configuration XML, not through code at this level.
Overriding the ChooseColumnsProvider is indicated if you want to retrieve the current configuration from a non-standard source.MergeInCurrentConfiguration(string, object, string)
Given the name of a gui control and the current state of the MDO list and the owner keys, fetch and merge in the current state of that gui control (i.e., the currently selected controls, and current orderby constraints)
Declaration
protected abstract void MergeInCurrentConfiguration(string guiName, object extraInfo, string ownerKeys)
Parameters
Type | Name | Description |
---|---|---|
string | guiName | Name of gui control |
object | extraInfo | |
string | ownerKeys |
Remarks
Specializations that override behaviour on a per-archive bases should probably be made from the ChooseColumnsProvider or the ChooseEntityProvider classes. This top level and the level below (ArchiveColumnsProviderBase and ArchiveEntitiesProviderBase) contain functionality that is quite generic. Also keep in mind that setting mandatory columns and excluding columns is done through the GUI configuration XML, not through code at this level.
Overriding the ChooseColumnsProvider is indicated if you want to retrieve the current configuration from a non-standard source.