Sphyrnidae Common Library  2.0.1
Shared Utilities/Library
Sphyrnidae.Common.Lookup.ILookupSettings< T > Interface Template Reference

Interface definition for looking up settings (Variables, features, user preferences, etc) More...

Inheritance diagram for Sphyrnidae.Common.Lookup.ILookupSettings< T >:
Sphyrnidae.Common.Lookup.BaseLookupSetting< T >

Public Member Functions

Task< IEnumerable< T > > GetAll ()
 Retrieves all of the settings at once so that these can be cached locally More...
 
GetItem (CaseInsensitiveBinaryList< T > settingsCollection, string key)
 Retrieves a single setting from the settingsCollection (populated from GetAll) More...
 
string GetValue (T setting)
 Retrieves the value from the setting More...
 

Properties

string Key [get]
 Name of the unique key for this setting (can be sub-divided) More...
 
int CachingSeconds [get]
 How long should the full collection of settings be cached More...
 

Detailed Description

Interface definition for looking up settings (Variables, features, user preferences, etc)

This interface is not meant to be directly inherited from. You should inherit your specific interface from this

Type Constraints
T :LookupSetting 

Member Function Documentation

◆ GetAll()

Task<IEnumerable<T> > Sphyrnidae.Common.Lookup.ILookupSettings< T >.GetAll ( )

Retrieves all of the settings at once so that these can be cached locally

Returns
The full collection of settings

Implemented in Sphyrnidae.Common.Lookup.BaseLookupSetting< T >.

◆ GetItem()

T Sphyrnidae.Common.Lookup.ILookupSettings< T >.GetItem ( CaseInsensitiveBinaryList< T >  settingsCollection,
string  key 
)

Retrieves a single setting from the settingsCollection (populated from GetAll)

Parameters
settingsCollectionThe full collection of settings
keyThe key to match on
Returns
The setting (or default if not found)

Implemented in Sphyrnidae.Common.Lookup.BaseLookupSetting< T >.

◆ GetValue()

string Sphyrnidae.Common.Lookup.ILookupSettings< T >.GetValue ( setting)

Retrieves the value from the setting

Parameters
settingThe setting
Returns
The value

Implemented in Sphyrnidae.Common.Lookup.BaseLookupSetting< T >.

Property Documentation

◆ CachingSeconds

int Sphyrnidae.Common.Lookup.ILookupSettings< T >.CachingSeconds
get

How long should the full collection of settings be cached

Returns
A value in seconds

◆ Key

Name of the unique key for this setting (can be sub-divided)


The documentation for this interface was generated from the following file: