IMetabaseObject.CachingMode

Fore Syntax

CachingMode: MetabaseObjectCachingMode;

Fore.NET Syntax

CachingMode: Prognoz.Platform.Interop.Metabase.MetabaseObjectCachingMode;

Description

The CachingMode property sets caching mode.

Comments

Caching mode can be changed for dictionaries, including MDM dictionaries of any type.

Fore Example

Executing the example requires a dictionary with the 16009 key.

Add a link to the Metabase system assembly.

Sub UserProc;
Var
    MB: IMetabase;
    MDesc: IMetabaseObjectDescriptor;
    MObj: IMetabaseObject;
Begin
    MB := MetabaseClass.Active;
    MDesc := MB.Item(16009);
    MObj := MDesc.Edit;
    MObj.CachingMode := MetabaseObjectCachingMode.FlushCacheByTimestamp;
    MDesc.UpdateTimestamp;
    MObj.Save;
End Sub UserProc;

After executing the example the FlushCacheByTimestamp caching mode is set for the selected dictionary.

Fore.NET Example

The requirements and result of the Fore.NET example execution match with those in the Fore example.

Imports Prognoz.Platform.Interop.Metabase;

Public Shared Sub Main(Params: StartParams);
Var
    MB: IMetabase;
    MDesc: IMetabaseObjectDescriptor;
    MObj: IMetabaseObject;
Begin
    MB := Params.Metabase;
    MDesc := MB.Item[16009];
    MObj := MDesc.Edit();
    MObj.CachingMode := MetabaseObjectCachingMode.mocmFlushCacheByTimestamp;
    MDesc.UpdateTimestamp();
    MObj.Save();
End Sub;

See also:

IMetabaseObject