#[repr(u8)]pub enum SighashFlag {
All = 1,
None = 2,
Single = 3,
}
Variants§
All = 1
0x1: Sign all outputs.
None = 2
0x2: Sign no outputs — anyone can choose the destination.
Single = 3
0x3: Sign the output whose index matches this input’s index. If none
exists, sign the hash
0000000000000000000000000000000000000000000000000000000000000001
.
(This rule is probably an unintentional C++ism, but it’s consensus, so
we have to follow it.)
Trait Implementations§
Source§impl Clone for SighashFlag
impl Clone for SighashFlag
Source§fn clone(&self) -> SighashFlag
fn clone(&self) -> SighashFlag
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for SighashFlag
impl Debug for SighashFlag
Source§impl Default for SighashFlag
impl Default for SighashFlag
Source§fn default() -> SighashFlag
fn default() -> SighashFlag
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for SighashFlag
impl<'de> Deserialize<'de> for SighashFlag
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
Source§impl Display for SighashFlag
impl Display for SighashFlag
Source§impl From<SighashFlag> for u8
impl From<SighashFlag> for u8
Source§fn from(value: SighashFlag) -> u8
fn from(value: SighashFlag) -> u8
Converts to this type from the input type.
Source§impl Hash for SighashFlag
impl Hash for SighashFlag
Source§impl PartialEq for SighashFlag
impl PartialEq for SighashFlag
Source§impl Serialize for SighashFlag
impl Serialize for SighashFlag
Source§impl StrictDecode for SighashFlag
impl StrictDecode for SighashFlag
fn strict_decode(reader: &mut impl TypedRead) -> Result<Self, DecodeError>
fn strict_read(reader: impl ReadRaw) -> Result<Self, DecodeError>
Source§impl StrictEncode for SighashFlag
impl StrictEncode for SighashFlag
fn strict_encode<W: TypedWrite>(&self, writer: W) -> Result<W>
fn strict_write(&self, writer: impl WriteRaw) -> Result<(), Error>
Source§impl StrictEnum for SighashFlag
impl StrictEnum for SighashFlag
fn from_variant_name( name: &VariantName, ) -> Result<Self, VariantError<&VariantName>>
fn strict_type_info() -> TypeInfo<Self>
Source§impl StrictSum for SighashFlag
impl StrictSum for SighashFlag
const ALL_VARIANTS: &'static [(u8, &'static str)]
fn variant_name(&self) -> &'static str
fn strict_check_variants()
fn variant_name_by_tag(tag: u8) -> Option<VariantName>
fn variant_ord(&self) -> u8
Source§impl StrictType for SighashFlag
impl StrictType for SighashFlag
const STRICT_LIB_NAME: &'static str = LIB_NAME_BITCOIN
fn strict_name() -> Option<TypeName>
Source§impl TryFrom<u8> for SighashFlag
impl TryFrom<u8> for SighashFlag
impl Copy for SighashFlag
impl Eq for SighashFlag
impl StructuralPartialEq for SighashFlag
Auto Trait Implementations§
impl Freeze for SighashFlag
impl RefUnwindSafe for SighashFlag
impl Send for SighashFlag
impl Sync for SighashFlag
impl Unpin for SighashFlag
impl UnwindSafe for SighashFlag
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.