Show / Hide Table of Contents

Class PreferenceLineItemProvider

MDO Provider for preferences that have a list of possible values in the database

Inheritance
Object
LiteralsOnlyBase
PreferenceLineItemProvider
Implements
ISoListProvider
ISoList
Inherited Members
LiteralsOnlyBase.Construct(String, String, Int32[], Boolean, String, Boolean)
LiteralsOnlyBase.ListName
LiteralsOnlyBase.ExtraInfo
LiteralsOnlyBase.SearchValue
LiteralsOnlyBase.RawRootItems
LiteralsOnlyBase.RawHeadingItems
LiteralsOnlyBase.RawHistoryItems
LiteralsOnlyBase.HistoryInfo
LiteralsOnlyBase.HistoryItems
LiteralsOnlyBase.RootItems
LiteralsOnlyBase.HeadingItems
Object.ToString()
Object.Equals(Object)
Object.Equals(Object, Object)
Object.ReferenceEquals(Object, Object)
Object.GetHashCode()
Object.GetType()
Object.MemberwiseClone()
Namespace: SuperOffice.CRM.Lists
Assembly: SoDataBase.dll
Syntax
[MDOProviderPlugin("PreferenceLineItem")]
[MDOAdditionalInfoSeparator("|")]
[MDOAdditionalInfo("Preference section | preference key", "Functions|DisableContactDogEar")]
public class PreferenceLineItemProvider : LiteralsOnlyBase, ISoListProvider, ISoList, IPlugin
Remarks

Some preferences have a set of possible values that does not correspond to any existing list. In such cases, rows in the prefdescline table are used to create a list. This provider will take an additionalInfo of the form section|key and return the list of possible values. If the key or section does not exist or do not have such a list of possible values, an empty list is returned.

Consider using the CreateAdditionalInfo(String, String) method to avoid coding formatting dependencies. Use the UserPreferenceStrings class to avoid (mis)coding preference section and key names as strings.

The actual preference value to set, corresponding to each choice, is in the extraInfo of each list item.

Constructors

PreferenceLineItemProvider()

Declaration
public PreferenceLineItemProvider()

Fields

ProviderName

Declaration
public const string ProviderName = "PreferenceLineItem"
Field Value
Type Description
String

SectionKeyDelimiter

Delimiter to use between section name and key name in the additionalInfo parameter. Consider using the CreateAdditionalInfo(String, String) method to avoid coding dependencies.

Declaration
public const string SectionKeyDelimiter = "|"
Field Value
Type Description
String

Methods

AddItems()

Declaration
protected override void AddItems()
Overrides
LiteralsOnlyBase.AddItems()

CreateAdditionalInfo(String, String)

Create a correctly formatted AdditionalInfo parameter based on a section and key

Declaration
public static string CreateAdditionalInfo(string section, string key)
Parameters
Type Name Description
String section

Desired preference section

String key

Desired preference key

Returns
Type Description
String

String suitable as the additionalInfo parameter

Implements

ISoListProvider
ISoList

Extension Methods

EnumUtil.MapEnums<From, To>(From)
ObjectExtensions.AssignByReflection<T>(T, T)
ObjectExtensions.GraphCopy<T>(T)
Converters.MapEnums<From, To>(From)
© SuperOffice. All rights reserved.
SuperOffice |  Community |  Release Notes |  Privacy |  Site feedback |  Search Docs |  About Docs |  Contribute |  Back to top