SimpleLogV1 Constructor

Initializes a new instance of the SimpleLogV1 class.

Namespace: Gamanet.C4.SimpleInterfaces
Assembly: Gamanet.C4.SimpleInterfaces (in Gamanet.C4.SimpleInterfaces.dll) Version: 2026.0.0.242
Syntax
C#
public SimpleLogV1(
	Guid id,
	string name,
	Guid parentId,
	Guid categoryId
)

Parameters

id  Guid
The identifier.
name  String
The name.
parentId  Guid
The parent identifier.
categoryId  Guid
The category identifier.
Remarks

Supported from

  • 2020
  • Example
    The following example illustrates how to create SimpleLog
    C#
    using Gamanet.C4.SDK.Enums.Core;
    using Gamanet.C4.SimpleInterfaces;
    using Gamanet.C4.SDK.Enums.Logs;
    using System;
    
    public class CreateSimpleLogObject
    {
        static void Main()
        {
             // create new instance of simple log
             var log = new SimpleLog(
                 Guid.NewGuid(), // new Id
                 "",
                 Guid.Empty,
                 LogCategory.AccessLevelCreated); // category Id specifies the log type
    
             // all the remaining data is stored in the Data property
             log.Data["CreateTime"] = DateTime.Now;
             log.Data["SourceTime"] = DateTime.Now;
             log.Data["CategoryId"] = DeviceCategory.AccessLevel;
             log.Data["ParentIdName"] = "AccessLevelRoot";
             log.Data["ParentId"] = EntityRoot.AccessLevelRoot;
             log.Data["AccessLevelIdName"] = "Secure level";
             log.Data["AccessLevelId"] = Guid.Parse("D14788AB-1854-45BD-9C62-2B88ED1223FA");
        }
    }
    See Also

    Reference

    SimpleLogV1 Class
    Gamanet.C4.SimpleInterfaces Namespace