[−][src]Struct script::Builder
Script builder
Methods
impl Builder[src]
impl Builderpub fn build_p2pkh(address: &AddressHash) -> Script[src]
pub fn build_p2pkh(address: &AddressHash) -> ScriptBuilds p2pkh script pubkey
pub fn build_p2sh(address: &AddressHash) -> Script[src]
pub fn build_p2sh(address: &AddressHash) -> ScriptBuilds p2sh script pubkey
pub fn build_nulldata(bytes: &[u8]) -> Script[src]
pub fn build_nulldata(bytes: &[u8]) -> ScriptBuilds op_return script
pub fn push_opcode(self, opcode: Opcode) -> Self[src]
pub fn push_opcode(self, opcode: Opcode) -> SelfPushes opcode to the end of script
pub fn push_bool(self, value: bool) -> Self[src]
pub fn push_bool(self, value: bool) -> SelfAppends bool push operation to the end of script
pub fn push_num(self, num: Num) -> Self[src]
pub fn push_num(self, num: Num) -> SelfAppends num push operation to the end of script
pub fn push_bytes(self, bytes: &[u8]) -> Self[src]
pub fn push_bytes(self, bytes: &[u8]) -> SelfAppends bytes push operation to the end od script
pub fn push_data(self, data: &[u8]) -> Self[src]
pub fn push_data(self, data: &[u8]) -> SelfAppends data push operation to the end of script
pub fn return_bytes(self, bytes: &[u8]) -> Self[src]
pub fn return_bytes(self, bytes: &[u8]) -> SelfAppends OP_RETURN operation to the end of script
pub fn push_invalid_opcode(self) -> Self[src]
pub fn push_invalid_opcode(self) -> SelfPushes invalid opcode to the end of script
pub fn into_script(self) -> Script[src]
pub fn into_script(self) -> ScriptBuilds final script
ⓘImportant traits for Bytespub fn into_bytes(self) -> Bytes[src]
pub fn into_bytes(self) -> BytesBuilds final script bytes
Trait Implementations
Auto Trait Implementations
Blanket Implementations
impl<T> From for T[src]
impl<T> From for Timpl<T, U> Into for T where
U: From<T>, [src]
impl<T, U> Into for T where
U: From<T>, impl<T, U> TryFrom for T where
T: From<U>, [src]
impl<T, U> TryFrom for T where
T: From<U>, type Error = !
try_from)The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>[src]
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>try_from)Performs the conversion.
impl<T> Borrow for T where
T: ?Sized, [src]
impl<T> Borrow for T where
T: ?Sized, ⓘImportant traits for &'a mut Rfn borrow(&self) -> &T[src]
fn borrow(&self) -> &TImmutably borrows from an owned value. Read more
impl<T, U> TryInto for T where
U: TryFrom<T>, [src]
impl<T, U> TryInto for T where
U: TryFrom<T>, type Error = <U as TryFrom<T>>::Error
try_from)The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>[src]
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>try_from)Performs the conversion.
impl<T> BorrowMut for T where
T: ?Sized, [src]
impl<T> BorrowMut for T where
T: ?Sized, ⓘImportant traits for &'a mut Rfn borrow_mut(&mut self) -> &mut T[src]
fn borrow_mut(&mut self) -> &mut TMutably borrows from an owned value. Read more
impl<T> Any for T where
T: 'static + ?Sized, [src]
impl<T> Any for T where
T: 'static + ?Sized, fn get_type_id(&self) -> TypeId[src]
fn get_type_id(&self) -> TypeId🔬 This is a nightly-only experimental API. (get_type_id)
this method will likely be replaced by an associated static
Gets the TypeId of self. Read more