IAuditLog.OpenOperations

Syntax

OpenOperations(Session: Integer): 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

For details about repository connections see the IAuditLog.OpenLogons property. To get the current session key, use the ILogonSession.Key property.

Example

To execute the example, add a link to the Metabase system assembly.

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;

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

See also:

IAuditLog