pub enum TransactionPayloadBuilderError<'a> {
MetadataDecodingError(MetadataDecodingError<'a>),
TooManyArguments(u8),
InvalidOutputIndex(u8),
PayloadTooLarge,
TooManyOutputs,
NumberOfOutputsMismatch {
expected: u8,
actual: usize,
},
TooManySlotReferences {
num_slots: u8,
num_references: usize,
},
TooManyInputReferences {
num_inputs: u8,
num_references: usize,
},
UnusedOutput(u8),
PayloadRule(TransactionPayloadDecoderError),
}Expand description
Errors for TransactionPayloadBuilder
Variants§
MetadataDecodingError(MetadataDecodingError<'a>)
Metadata decoding error
TooManyArguments(u8)
Too many arguments
InvalidOutputIndex(u8)
An output index of MAX_OUTPUTS or more, which tags can’t hold
PayloadTooLarge
The payload doesn’t fit into the maximum size given to TransactionPayloadBuilder::new()
TooManyOutputs
More than MAX_OUTPUTS outputs declared
NumberOfOutputsMismatch
MethodCallReferences::outputs doesn’t have exactly one entry for each output of the
method
TooManySlotReferences
MethodCallReferences::slots has more entries than the method has slots
TooManyInputReferences
MethodCallReferences::inputs has more entries than the method has inputs
UnusedOutput(u8)
No method call writes the declared output with this index, see
TransactionPayloadBuilder::into_aligned_bytes()
PayloadRule(TransactionPayloadDecoderError)
The method call breaks a rule of the payload format, with the error that
TransactionPayloadDecoder returns for such a payload, see
TransactionPayloadBuilder::with_method_call()
Trait Implementations§
Source§impl<'a> Debug for TransactionPayloadBuilderError<'a>
impl<'a> Debug for TransactionPayloadBuilderError<'a>
Source§impl<'a> Display for TransactionPayloadBuilderError<'a>
impl<'a> Display for TransactionPayloadBuilderError<'a>
Source§impl<'a> Error for TransactionPayloadBuilderError<'a>
impl<'a> Error for TransactionPayloadBuilderError<'a>
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()
Auto Trait Implementations§
impl<'a> Freeze for TransactionPayloadBuilderError<'a>
impl<'a> RefUnwindSafe for TransactionPayloadBuilderError<'a>
impl<'a> Send for TransactionPayloadBuilderError<'a>
impl<'a> Sync for TransactionPayloadBuilderError<'a>
impl<'a> Unpin for TransactionPayloadBuilderError<'a>
impl<'a> UnsafeUnpin for TransactionPayloadBuilderError<'a>
impl<'a> UnwindSafe for TransactionPayloadBuilderError<'a>
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
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more