OCEL.CSharp
1.2.0
See the version list below for details.
dotnet add package OCEL.CSharp --version 1.2.0
NuGet\Install-Package OCEL.CSharp -Version 1.2.0
<PackageReference Include="OCEL.CSharp" Version="1.2.0" />
paket add OCEL.CSharp --version 1.2.0
#r "nuget: OCEL.CSharp, 1.2.0"
// Install OCEL.CSharp as a Cake Addin #addin nuget:?package=OCEL.CSharp&version=1.2.0 // Install OCEL.CSharp as a Cake Tool #tool nuget:?package=OCEL.CSharp&version=1.2.0
OCEL.CSharp
Object-Centric Event Log (OCEL) is a standard interchange format for object-centric event data with multiple case notions [1]. This library aims to implement this standard in .NET with a high degree of type safety.
Supported formats
The OCEL standard is defined for both JSON and XML. Both include a validation schema that is used by the library to validate input.
An additional useful format is to store OCEL data in document databases such as MongoDB [2]. A very good alternative for .NET is LiteDB, which is an embedded NoSQL database that is similar to MongoDB. It allows writing to files directly and does not require a database server to use. Support for MongoDB will be evaluated in the future.
Format | Status |
---|---|
JSON | Implemented |
XML | Implemented |
LiteDB | Implemented |
MongoDB | TBD |
Libraries
The library is written in F# and can be used directly by all .NET languages. For idiomatic usage in C#, a wrapper library is provided that mainly converts between appropriate types for the parsed logs.
Both libraries are available on NuGet:
Library | NuGet Link |
---|---|
F# | https://www.nuget.org/packages/OCEL |
C# | https://www.nuget.org/packages/OCEL.CSharp |
Examples
Validating an OCEL file
var json = File.ReadAllText("minimal.jsonocel");
var valid = OCEL.CSharp.OcelJson.Validate(json);
var (valid, errors) = OCEL.CSharp.OcelJson.ValidateWithErrorMessages(json);
Parsing a JSON-OCEL and XML-OCEL string
var json = File.ReadAllText("minimal.jsonocel");
var xml = File.ReadAllText("minimal.xmlocel");
var fromJson = OCEL.CSharp.OcelJson.Deserialize(json);
var fromXml = OCEL.CSharp.OcelXml.Deserialize(xml);
Writing and reading from a LiteDB database
var log = OCEL.CSharp.OcelJson.Deserialize(File.ReadAllText("minimal.jsonocel"));
var db = new LiteDatabase(":memory:");
OCEL.CSharp.OcelLiteDB.Serialize(db, log);
var serializedLog = OCEL.CSharp.OcelLiteDB.Deserialize(db);
Converting between formats
var json = File.ReadAllText("minimal.jsonocel");
var parsed = OCEL.CSharp.OcelJson.Deserialize(json);
var xml = OCEL.CSharp.OcelXml.Serialize(parsed, OCEL.Types.Formatting.Indented);
References
[1] Farhang, A., Park, G. G., Berti, A., & Aalst, W. Van Der. (2020). OCEL Standard. http://ocel-standard.org/
[2] Berti, A., Ghahfarokhi, A. F., Park, G., & van der Aalst, W. M. P. (2021). A Scalable Database for the Storage of Object-Centric Event Logs. CEUR Workshop Proceedings, 3098, 19–20. https://arxiv.org/abs/2202.05639.
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net5.0 was computed. net5.0-windows was computed. net6.0 is compatible. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 was computed. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. net8.0 was computed. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. |
.NET Core | netcoreapp2.0 was computed. netcoreapp2.1 was computed. netcoreapp2.2 was computed. netcoreapp3.0 was computed. netcoreapp3.1 was computed. |
.NET Standard | netstandard2.0 is compatible. netstandard2.1 was computed. |
.NET Framework | net461 was computed. net462 was computed. net463 was computed. net47 was computed. net471 was computed. net472 was computed. net48 was computed. net481 was computed. |
MonoAndroid | monoandroid was computed. |
MonoMac | monomac was computed. |
MonoTouch | monotouch was computed. |
Tizen | tizen40 was computed. tizen60 was computed. |
Xamarin.iOS | xamarinios was computed. |
Xamarin.Mac | xamarinmac was computed. |
Xamarin.TVOS | xamarintvos was computed. |
Xamarin.WatchOS | xamarinwatchos was computed. |
NuGet packages (2)
Showing the top 2 NuGet packages that depend on OCEL.CSharp:
Package | Downloads |
---|---|
Serilog.Sinks.OCEL
Serilog sinks that write events to Object-Centric Event Logs (OCEL) |
|
pm4net
A general-purpose Process Mining library for .NET, primarily focusing on techniques concerning Object-Centric Event Logs. |
GitHub repositories
This package is not used by any popular GitHub repositories.
Version | Downloads | Last updated |
---|---|---|
1.4.3 | 209 | 9/20/2023 |
1.4.2 | 147 | 9/19/2023 |
1.4.1 | 136 | 9/18/2023 |
1.4.0 | 317 | 9/18/2023 |
1.3.6 | 376 | 9/5/2023 |
1.3.5 | 358 | 8/17/2023 |
1.3.3 | 445 | 8/10/2023 |
1.3.2 | 176 | 7/26/2023 |
1.3.1 | 217 | 4/19/2023 |
1.3.0 | 435 | 3/8/2023 |
1.2.11 | 642 | 3/7/2023 |
1.2.10 | 309 | 2/8/2023 |
1.2.9 | 266 | 2/8/2023 |
1.2.8 | 301 | 2/4/2023 |
1.2.7 | 310 | 2/2/2023 |
1.2.6 | 314 | 2/2/2023 |
1.2.5 | 310 | 2/1/2023 |
1.2.4 | 580 | 1/11/2023 |
1.2.3 | 311 | 1/9/2023 |
1.2.2 | 325 | 1/4/2023 |
1.2.1 | 332 | 12/20/2022 |
1.2.0 | 365 | 12/7/2022 |
1.1.0 | 324 | 12/7/2022 |
1.0.0 | 337 | 11/30/2022 |