mirror of
https://github.com/Nanaloveyuki/BitLogger.git
synced 2026-05-30 15:42:25 +00:00
✨ Add native async logger adapter package
This commit is contained in:
+11
-1
@@ -15,7 +15,7 @@ pub struct Record {
|
||||
fields : Array[Field]
|
||||
}
|
||||
|
||||
fn record(
|
||||
pub fn Record::new(
|
||||
level : Level,
|
||||
message : String,
|
||||
timestamp_ms~ : UInt64 = 0UL,
|
||||
@@ -24,3 +24,13 @@ fn record(
|
||||
) -> Record {
|
||||
{ level, timestamp_ms, target, message, fields }
|
||||
}
|
||||
|
||||
fn record(
|
||||
level : Level,
|
||||
message : String,
|
||||
timestamp_ms~ : UInt64 = 0UL,
|
||||
target~ : String = "",
|
||||
fields~ : Array[Field] = [],
|
||||
) -> Record {
|
||||
Record::new(level, message, timestamp_ms=timestamp_ms, target=target, fields=fields)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user