hooks_rs::api

Function trace

Source
pub fn trace(msg: &[u8], data: &[u8], data_repr: DataRepr) -> Result<u64>
Expand description

Write the contents of a buffer to the XRPLD trace log

ยงExample

The first argument will be shown on the left side of the log and the second argument will be shown on the right side of the log.

Usually you would want to use the first argument to specify what the data is and the second argument to specify the data itself.

let _ = trace(b"left", b"right", DataRepr::AsUTF8);