CSLA .NET 10.0.0
A home for your business logic
Loading...
Searching...
No Matches
Csla.NameValueListBase< K, V > Class Template Referenceabstract

This is the base class from which readonly name/value collections should be derived. More...

Inheritance diagram for Csla.NameValueListBase< K, V >:
Csla.Core.IUseApplicationContext

Classes

class  NameValuePair
 Contains a key and value pair. More...

Public Member Functions

V? Value (K key)
 Returns the value corresponding to the specified key.
K? Key (V value)
 Returns the key corresponding to the first occurance of the specified value in the list.
bool ContainsKey (K key)
 Gets a value indicating whether the list contains the specified key.
bool ContainsValue (V value)
 Gets a value indicating whether the list contains the specified value.
NameValuePairGetItemByValue (V value)
 Get the item for the first matching value in the collection.
NameValuePairGetItemByKey (K key)
 Get the item for the first matching key in the collection.
 NameValuePair ()
 Creates an instance of the type (for use by MobileFormatter only).
 NameValuePair (K key, V value)
 Creates an instance of the type.
override string ToString ()
 Returns a string representation of the value for this item.
NameValueListBase< K, V > Clone ()
 Creates a clone of the object.
async Task WaitForIdle ()
 Await this method to ensure business object is not busy.

Protected Member Functions

 NameValueListBase ()
 Creates an instance of the type.
virtual void Initialize ()
 Override this method to set up event handlers so user code in a partial class can respond to events raised by generated code.
override void OnGetState (SerializationInfo info, StateMode mode)
 Override this method to manually get custom field values from the serialization stream.
override void OnSetState (SerializationInfo info, StateMode mode)
 Override this method to manually set custom field values into the serialization stream.
override void OnGetMetastate (BinaryWriter writer)
override void OnSetMetastate (BinaryReader reader)
virtual object GetClone ()
 Creates a clone of the object.
virtual void DataPortal_OnDataPortalInvoke (DataPortalEventArgs e)
 Called by the server-side DataPortal prior to calling the requested DataPortal_XYZ method.
virtual void DataPortal_OnDataPortalInvokeComplete (DataPortalEventArgs e)
 Called by the server-side DataPortal after calling the requested DataPortal_XYZ method.
virtual void DataPortal_OnDataPortalException (DataPortalEventArgs e, Exception ex)
 Called by the server-side DataPortal if an exception occurs during data access.

Properties

ApplicationContext ApplicationContext [get]
 Gets the current ApplicationContext.
Key [get]
 The Key or Name value.
Value [get]
 The Value corresponding to the key/name.

Detailed Description

This is the base class from which readonly name/value collections should be derived.

Template Parameters
KType of the key values.
VType of the values.
Type Constraints
K :notnull 
V :notnull 

Member Function Documentation

◆ Clone()

NameValueListBase< K, V > Csla.NameValueListBase< K, V >.Clone ( )
inline

Creates a clone of the object.

◆ ContainsKey()

bool Csla.NameValueListBase< K, V >.ContainsKey ( K key)
inline

Gets a value indicating whether the list contains the specified key.

Parameters
keyKey value for which to search.
Exceptions
ArgumentNullExceptionkey is null.

◆ ContainsValue()

bool Csla.NameValueListBase< K, V >.ContainsValue ( V value)
inline

Gets a value indicating whether the list contains the specified value.

Parameters
valueValue for which to search.
Exceptions
ArgumentNullExceptionvalue is null.

◆ DataPortal_OnDataPortalException()

virtual void Csla.NameValueListBase< K, V >.DataPortal_OnDataPortalException ( DataPortalEventArgs e,
Exception ex )
inlineprotectedvirtual

Called by the server-side DataPortal if an exception occurs during data access.

Parameters
eThe DataPortalContext object passed to the DataPortal.
exThe Exception thrown during data access.

◆ DataPortal_OnDataPortalInvoke()

virtual void Csla.NameValueListBase< K, V >.DataPortal_OnDataPortalInvoke ( DataPortalEventArgs e)
inlineprotectedvirtual

Called by the server-side DataPortal prior to calling the requested DataPortal_XYZ method.

Parameters
eThe DataPortalContext object passed to the DataPortal.

◆ DataPortal_OnDataPortalInvokeComplete()

virtual void Csla.NameValueListBase< K, V >.DataPortal_OnDataPortalInvokeComplete ( DataPortalEventArgs e)
inlineprotectedvirtual

Called by the server-side DataPortal after calling the requested DataPortal_XYZ method.

Parameters
eThe DataPortalContext object passed to the DataPortal.

◆ GetClone()

virtual object Csla.NameValueListBase< K, V >.GetClone ( )
inlineprotectedvirtual

Creates a clone of the object.

Returns
A new object containing the exact data of the original object.

◆ GetItemByKey()

NameValuePair? Csla.NameValueListBase< K, V >.GetItemByKey ( K key)
inline

Get the item for the first matching key in the collection.

Parameters
keyKey to search for in the list.
Returns
Item from the list.
Exceptions
ArgumentNullExceptionkey is null.

◆ GetItemByValue()

NameValuePair? Csla.NameValueListBase< K, V >.GetItemByValue ( V value)
inline

Get the item for the first matching value in the collection.

Parameters
valueValue to search for in the list.
Returns
Item from the list.
Exceptions
ArgumentNullExceptionvalue is null.

◆ Initialize()

virtual void Csla.NameValueListBase< K, V >.Initialize ( )
inlineprotectedvirtual

Override this method to set up event handlers so user code in a partial class can respond to events raised by generated code.

◆ Key()

K? Csla.NameValueListBase< K, V >.Key ( V value)
inline

Returns the key corresponding to the first occurance of the specified value in the list.

Parameters
valueValue for which to retrieve the key.
Exceptions
ArgumentNullExceptionvalue is null.

◆ NameValueListBase()

Csla.NameValueListBase< K, V >.NameValueListBase ( )
inlineprotected

Creates an instance of the type.

◆ NameValuePair() [1/2]

Csla.NameValueListBase< K, V >.NameValuePair ( )
inline

Creates an instance of the type (for use by MobileFormatter only).

◆ NameValuePair() [2/2]

Csla.NameValueListBase< K, V >.NameValuePair ( K key,
V value )
inline

Creates an instance of the type.

Parameters
keyThe key.
valueThe value.
Exceptions
ArgumentNullExceptionkey is null.

◆ OnGetMetastate()

override void Csla.NameValueListBase< K, V >.OnGetMetastate ( BinaryWriter writer)
inlineprotected

◆ OnGetState()

override void Csla.NameValueListBase< K, V >.OnGetState ( SerializationInfo info,
StateMode mode )
inlineprotected

Override this method to manually get custom field values from the serialization stream.

Parameters
infoSerialization info.
modeSerialization mode.

◆ OnSetMetastate()

override void Csla.NameValueListBase< K, V >.OnSetMetastate ( BinaryReader reader)
inlineprotected

◆ OnSetState()

override void Csla.NameValueListBase< K, V >.OnSetState ( SerializationInfo info,
StateMode mode )
inlineprotected

Override this method to manually set custom field values into the serialization stream.

Parameters
infoSerialization info.
modeSerialization mode.

◆ ToString()

override string Csla.NameValueListBase< K, V >.ToString ( )
inline

Returns a string representation of the value for this item.

◆ Value()

V? Csla.NameValueListBase< K, V >.Value ( K key)
inline

Returns the value corresponding to the specified key.

Parameters
keyKey value for which to retrieve a value.
Exceptions
ArgumentNullExceptionkey is null.

◆ WaitForIdle()

async Task Csla.NameValueListBase< K, V >.WaitForIdle ( )
inline

Await this method to ensure business object is not busy.

Property Documentation

◆ ApplicationContext

ApplicationContext Csla.NameValueListBase< K, V >.ApplicationContext
getprotected

◆ Key

K Csla.NameValueListBase< K, V >.Key
get

The Key or Name value.

◆ Value

V Csla.NameValueListBase< K, V >.Value
get

The Value corresponding to the key/name.


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