pub struct FoundryOutputBuilder { /* private fields */ }Expand description
Implementations§
Source§impl FoundryOutputBuilder
impl FoundryOutputBuilder
Sourcepub fn new_with_amount(
amount: u64,
serial_number: u32,
token_scheme: TokenScheme,
) -> Self
pub fn new_with_amount( amount: u64, serial_number: u32, token_scheme: TokenScheme, ) -> Self
Creates a FoundryOutputBuilder with a provided amount.
Sourcepub fn with_amount(self, amount: u64) -> Self
pub fn with_amount(self, amount: u64) -> Self
Sets the amount to the provided value.
Sourcepub fn add_native_token(self, native_token: NativeToken) -> Self
pub fn add_native_token(self, native_token: NativeToken) -> Self
Sourcepub fn with_native_tokens(
self,
native_tokens: impl IntoIterator<Item = NativeToken>,
) -> Self
pub fn with_native_tokens( self, native_tokens: impl IntoIterator<Item = NativeToken>, ) -> Self
Sourcepub fn with_serial_number(self, serial_number: u32) -> Self
pub fn with_serial_number(self, serial_number: u32) -> Self
Sets the serial number to the provided value.
Sourcepub fn with_token_scheme(self, token_scheme: TokenScheme) -> Self
pub fn with_token_scheme(self, token_scheme: TokenScheme) -> Self
Sets the token scheme to the provided value.
Sourcepub fn add_unlock_condition(
self,
unlock_condition: impl Into<UnlockCondition>,
) -> Self
pub fn add_unlock_condition( self, unlock_condition: impl Into<UnlockCondition>, ) -> Self
Adds an UnlockCondition to the builder, if one does not already
exist of that type.
Sourcepub fn with_unlock_conditions(
self,
unlock_conditions: impl IntoIterator<Item = impl Into<UnlockCondition>>,
) -> Self
pub fn with_unlock_conditions( self, unlock_conditions: impl IntoIterator<Item = impl Into<UnlockCondition>>, ) -> Self
Sets the UnlockConditionss in the builder, overwriting any existing
values.
Sourcepub fn replace_unlock_condition(
self,
unlock_condition: impl Into<UnlockCondition>,
) -> Self
pub fn replace_unlock_condition( self, unlock_condition: impl Into<UnlockCondition>, ) -> Self
Replaces an UnlockCondition of the builder with a new one, or adds
it.
Sourcepub fn clear_unlock_conditions(self) -> Self
pub fn clear_unlock_conditions(self) -> Self
Clears all UnlockConditionss from the builder.
Sourcepub fn add_feature(self, feature: impl Into<Feature>) -> Self
pub fn add_feature(self, feature: impl Into<Feature>) -> Self
Adds a Feature to the builder, if one does not already exist of that
type.
Sourcepub fn with_features(
self,
features: impl IntoIterator<Item = impl Into<Feature>>,
) -> Self
pub fn with_features( self, features: impl IntoIterator<Item = impl Into<Feature>>, ) -> Self
Sets the Features in the builder, overwriting any existing values.
Sourcepub fn replace_feature(self, feature: impl Into<Feature>) -> Self
pub fn replace_feature(self, feature: impl Into<Feature>) -> Self
Replaces a Feature of the builder with a new one, or adds it.
Sourcepub fn clear_features(self) -> Self
pub fn clear_features(self) -> Self
Clears all Features from the builder.
Sourcepub fn add_immutable_feature(
self,
immutable_feature: impl Into<Feature>,
) -> Self
pub fn add_immutable_feature( self, immutable_feature: impl Into<Feature>, ) -> Self
Adds an immutable Feature to the builder, if one does not already
exist of that type.
Sourcepub fn with_immutable_features(
self,
immutable_features: impl IntoIterator<Item = impl Into<Feature>>,
) -> Self
pub fn with_immutable_features( self, immutable_features: impl IntoIterator<Item = impl Into<Feature>>, ) -> Self
Sets the immutable Features in the builder, overwriting any existing
values.
Sourcepub fn replace_immutable_feature(
self,
immutable_feature: impl Into<Feature>,
) -> Self
pub fn replace_immutable_feature( self, immutable_feature: impl Into<Feature>, ) -> Self
Replaces an immutable Feature of the builder with a new one, or adds
it.
Sourcepub fn clear_immutable_features(self) -> Self
pub fn clear_immutable_features(self) -> Self
Clears all immutable Features from the builder.
Sourcepub fn finish(self) -> Result<FoundryOutput, Error>
pub fn finish(self) -> Result<FoundryOutput, Error>
Trait Implementations§
Source§impl Clone for FoundryOutputBuilder
impl Clone for FoundryOutputBuilder
Source§fn clone(&self) -> FoundryOutputBuilder
fn clone(&self) -> FoundryOutputBuilder
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more