feat: introduce UTxO RPC interop (#260)
This commit is contained in:
parent
fb22d1b0e2
commit
4a849eec25
7 changed files with 515 additions and 1 deletions
|
|
@ -81,7 +81,21 @@ impl<'b> MultiEraAsset<'b> {
|
|||
}
|
||||
}
|
||||
|
||||
pub fn coin(&self) -> i128 {
|
||||
pub fn mint_coin(&self) -> Option<i64> {
|
||||
match self {
|
||||
MultiEraAsset::AlonzoCompatibleMint(_, _, x) => Some(*x),
|
||||
MultiEraAsset::AlonzoCompatibleOutput(_, _, _) => None,
|
||||
}
|
||||
}
|
||||
|
||||
pub fn output_coin(&self) -> Option<u64> {
|
||||
match self {
|
||||
MultiEraAsset::AlonzoCompatibleOutput(_, _, x) => Some(*x),
|
||||
MultiEraAsset::AlonzoCompatibleMint(_, _, _) => None,
|
||||
}
|
||||
}
|
||||
|
||||
pub fn any_coin(&self) -> i128 {
|
||||
match self {
|
||||
MultiEraAsset::AlonzoCompatibleOutput(_, _, x) => *x as i128,
|
||||
MultiEraAsset::AlonzoCompatibleMint(_, _, x) => *x as i128,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue