AppTreeObjDictProviderT< TAbstractProduct, TKey > Class Reference

An application tree objects provider for the objects having keys of type TKey. More...

Inheritance diagram for AppTreeObjDictProviderT< TAbstractProduct, TKey >:

IHavingKeyT< TKey > List of all members.

Public Member Functions

void Init (AppTreeObjFactoryT< TAbstractProduct > productFactory, InitContext initCtx)
 Initializes provider.
TAbstractProduct Get (TKey key)
 Gets a product for the given key by creating it or from cache.
void Forget (TKey key)
 Clears the product cache entry for key.
void ForgetAll ()
 Clears the product cache at all.

Properties

AppTreeObjFactoryT< TAbstractProductProductFactory
 Product factory instance.
InitContext InitCtx
 InitContext instance.
IDictionaryOfHavingKeyT< TKey,
TAbstractProduct
Products
 Products cache.
IReadOnlyDictionaryT< TKey,
TAbstractProduct
ProductsCollection
 Read-only products cache.

Detailed Description

An application tree objects provider for the objects having keys of type TKey.

The provider contains a dictionary-like cache for already created objects.

<typeparam name="TAbstractProduct">product type</typeparam> <typeparam name="TKey">key type</typeparam>


Member Function Documentation

void Init AppTreeObjFactoryT< TAbstractProduct productFactory,
InitContext  initCtx
 

Initializes provider.

Parameters:
productFactory product factory
initCtx init ctx

TAbstractProduct Get TKey  key  ) 
 

Gets a product for the given key by creating it or from cache.

Parameters:
key key
Returns:
product

void Forget TKey  key  ) 
 

Clears the product cache entry for key.

Parameters:
key key

void ForgetAll  ) 
 

Clears the product cache at all.


Property Documentation

AppTreeObjFactoryT<TAbstractProduct> ProductFactory [get, protected]
 

Product factory instance.

InitContext InitCtx [get]
 

InitContext instance.

IDictionaryOfHavingKeyT<TKey, TAbstractProduct> Products [get, protected]
 

Products cache.

IReadOnlyDictionaryT<TKey, TAbstractProduct> ProductsCollection [get]
 

Read-only products cache.


Generated on Sun May 28 08:45:06 2006 for Acmx.Common documentation by  doxygen 1.4.5