Trait dharitri_wasm::api::LogApi
source · pub trait LogApi {
// Required methods
fn write_event_log(&self, topics_buffer: &ArgBuffer, data: &[u8]);
fn write_legacy_log(&self, topics: &[[u8; 32]], data: &[u8]);
fn managed_write_log(&self, topics_handle: Handle, data_handle: Handle);
}
Expand description
Interface to only be used by code generated by the macros. The smart contract code doesn’t have access to these methods directly.
Required Methods§
sourcefn write_event_log(&self, topics_buffer: &ArgBuffer, data: &[u8])
fn write_event_log(&self, topics_buffer: &ArgBuffer, data: &[u8])
Saves an event log.
sourcefn write_legacy_log(&self, topics: &[[u8; 32]], data: &[u8])
fn write_legacy_log(&self, topics: &[[u8; 32]], data: &[u8])
The legacy Arwen hook for saving event logs. It does the same, but only accepts 32-byte topics. Only kept for backwards compatibility.