IAuditLog.OpenOperations

Syntax

OpenOperations(Session: Integer): IAuditOperations;

OpenOperations(System.UInt32): Prognoz.Platform.Interop.Metabase.IAuditOperations;

Parameters

Session. Session number.

Description

The OpenOperations method returns the list of operations that were performed in the repository, in the linear form.

Comments

To get information about connections with repository, use the IAuditLog.OpenLogons property.

Example

To execute the example, add links to the Metabase, ForeSystem (for the Fore.NET example) system assemblies.

Sub UserProc;
Var
    MB: IMetabase;
    MS: IMetabaseSecurity;
    AL: IAuditLog;
    ALogs: IAuditLogons;
    AOperat: IAuditOperations;
    s: Array[
0..10Of String;
    i: Integer;
    Lic: Object;
Begin
    MB := MetabaseClass.Active;
    
// Check out license to work with security manager
    Lic := MB.RequestLicense(UiLicenseFeatureType.Adm);
    MS := MB.Security;
    
// Open access protocol
    AL := MS.OpenAuditLog;
    
// Disable using of access protocol filter
    ALogs := AL.OpenLogons(False);
    
// Create list of operations
    AOperat := AL.OpenOperations(ALogs.Session);
    
// Display numbers of current session to the console
    Debug.WriteLine("Session " + ALogs.Session.ToString + ": ");
    
For i := 0 To 9 Do
        s[i] := AOperat.Name;
        Debug.WriteLine(s[i]);
        AOperat.Next;
    
End For;
    
// Check in license
    Lic := Null;
End Sub UserProc;

Imports Prognoz.Platform.Interop.Metabase;
Imports Prognoz.Platform.Interop.ForeSystem;

Public Shared Sub Main(Params: StartParams);
Var
    MB: IMetabase;
    MS: IMetabaseSecurity;
    AL: IAuditLog;
    ALogs: IAuditLogons;
    AOperat: IAuditOperations;
    s: Array[
0..10Of String;
    i: Integer;
    Lic: Object;
Begin
    MB := Params.Metabase;
    
// Check out license to work with security manager
    Lic := MB.RequestLicense(UiLicenseFeatureType.lftAdm);
    MS := MB.Security;
    
// Open access protocol
    AL := MS.OpenAuditLog();
    
// Disable using filter of access protocol
    ALogs := AL.OpenLogons(False);
    
// Create list of operations
    AOperat := AL.OpenOperations(ALogs.Session);
    
// Display numbers of current session to console
    System.Diagnostics.Debug.WriteLine("Session " + ALogs.Session.ToString() + ": ");
    
For i := 0 To 9 Do
        s[i] := AOperat.Name;
        System.Diagnostics.Debug.WriteLine(s[i]);
        AOperat.Next();
    
End For;
    
// Check in license
    Lic := Null;
End Sub;

After executing this example the console displays names of the last ten operations on objects of the current repository session.

See also:

IAuditLog