pub enum AdviserAnswer {
Noul {
keep: bool,
confidence_bp: u16,
},
Score {
score_bp: u16,
},
Choice {
chosen: String,
},
}Expand description
How the adviser answered.
The tag is the question, and the answer types are the three answer shapes: this is why one enum rather than one answer type with three optional fields, which would let a line hold an answer to a question nobody asked.
Variants§
Noul
keep is the answer to “is this still needed?”; confidence_bp
is how sure the adviser was, in basis points of one. A
probability reaches the ledger scaled to an integer, because no
payload here carries a float.
Score
The density, in basis points of one.
Choice
The chosen option, as the asking side spelled it in the question.
Trait Implementations§
Source§impl Clone for AdviserAnswer
impl Clone for AdviserAnswer
Source§impl Debug for AdviserAnswer
impl Debug for AdviserAnswer
Source§impl<'de> Deserialize<'de> for AdviserAnswer
impl<'de> Deserialize<'de> for AdviserAnswer
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for AdviserAnswer
Source§impl PartialEq for AdviserAnswer
impl PartialEq for AdviserAnswer
Source§impl Serialize for AdviserAnswer
impl Serialize for AdviserAnswer
impl StructuralPartialEq for AdviserAnswer
Auto Trait Implementations§
impl Freeze for AdviserAnswer
impl RefUnwindSafe for AdviserAnswer
impl Send for AdviserAnswer
impl Sync for AdviserAnswer
impl Unpin for AdviserAnswer
impl UnsafeUnpin for AdviserAnswer
impl UnwindSafe for AdviserAnswer
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more