MCPcopy Create free account
hub / github.com/evilsocket/cake / fmt

Method fmt

cake-core/src/models/mod.rs:74–84  ·  view source on GitHub ↗
(&self, f: &mut std::fmt::Formatter<'_>)

Source from the content-addressed store, hash-verified

72
73impl std::fmt::Display for Token {
74 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
75 write!(
76 f,
77 "{}",
78 if let Some(text) = &self.text {
79 text.clone()
80 } else {
81 format!("<token {}>", self.id)
82 }
83 )
84 }
85}
86
87/// A model must implement this trait in order to be usable by the Cake framework.

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected