mirror of
https://github.com/logos-blockchain/lssa.git
synced 2026-01-03 22:03:06 +00:00
rename
This commit is contained in:
parent
dfab1d6fa8
commit
64048ccf1d
@ -452,7 +452,7 @@ pub async fn test_success_token_program() {
|
|||||||
|
|
||||||
pub async fn test_success_private_transfer_to_another_owned_account() {
|
pub async fn test_success_private_transfer_to_another_owned_account() {
|
||||||
info!("test_success_private_transfer_to_another_owned_account");
|
info!("test_success_private_transfer_to_another_owned_account");
|
||||||
let command = Command::SendNativeTokenTransferPrivate {
|
let command = Command::SendNativeTokenTransferPrivateOwnedAccount {
|
||||||
from: ACC_SENDER_PRIVATE.to_string(),
|
from: ACC_SENDER_PRIVATE.to_string(),
|
||||||
to: ACC_RECEIVER_PRIVATE.to_string(),
|
to: ACC_RECEIVER_PRIVATE.to_string(),
|
||||||
amount: 100,
|
amount: 100,
|
||||||
|
|||||||
@ -216,7 +216,7 @@ pub enum Command {
|
|||||||
///Send native token transfer from `from` to `to` for `amount`
|
///Send native token transfer from `from` to `to` for `amount`
|
||||||
///
|
///
|
||||||
/// Private operation
|
/// Private operation
|
||||||
SendNativeTokenTransferPrivate {
|
SendNativeTokenTransferPrivateOwnedAccount {
|
||||||
///from - valid 32 byte hex string
|
///from - valid 32 byte hex string
|
||||||
#[arg(long)]
|
#[arg(long)]
|
||||||
from: String,
|
from: String,
|
||||||
@ -401,12 +401,12 @@ pub async fn execute_subcommand(command: Command) -> Result<SubcommandReturnValu
|
|||||||
|
|
||||||
SubcommandReturnValue::Empty
|
SubcommandReturnValue::Empty
|
||||||
}
|
}
|
||||||
Command::SendNativeTokenTransferPrivate { from, to, amount } => {
|
Command::SendNativeTokenTransferPrivateOwnedAccount { from, to, amount } => {
|
||||||
let from = produce_account_addr_from_hex(from)?;
|
let from = produce_account_addr_from_hex(from)?;
|
||||||
let to = produce_account_addr_from_hex(to)?;
|
let to = produce_account_addr_from_hex(to)?;
|
||||||
|
|
||||||
let (res, secret) = wallet_core
|
let (res, secret) = wallet_core
|
||||||
.send_private_native_token_transfer(from, to, amount)
|
.send_private_native_token_transfer_owned_account(from, to, amount)
|
||||||
.await?;
|
.await?;
|
||||||
|
|
||||||
println!("Results of tx send is {res:#?}");
|
println!("Results of tx send is {res:#?}");
|
||||||
@ -614,7 +614,7 @@ pub async fn execute_subcommand(command: Command) -> Result<SubcommandReturnValu
|
|||||||
nssa_core::encryption::shared_key_derivation::Secp256k1Point(to_ipk.to_vec());
|
nssa_core::encryption::shared_key_derivation::Secp256k1Point(to_ipk.to_vec());
|
||||||
|
|
||||||
let (res, secret) = wallet_core
|
let (res, secret) = wallet_core
|
||||||
.send_shielded_native_token_transfer_maybe_outer_account(
|
.send_shielded_native_token_transfer_outer_account(
|
||||||
from, to_npk, to_ipk, amount,
|
from, to_npk, to_ipk, amount,
|
||||||
)
|
)
|
||||||
.await?;
|
.await?;
|
||||||
|
|||||||
@ -110,7 +110,7 @@ impl WalletCore {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
pub async fn send_private_native_token_transfer(
|
pub async fn send_private_native_token_transfer_owned_account(
|
||||||
&self,
|
&self,
|
||||||
from: Address,
|
from: Address,
|
||||||
to: Address,
|
to: Address,
|
||||||
|
|||||||
@ -98,7 +98,7 @@ impl WalletCore {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
pub async fn send_shielded_native_token_transfer_maybe_outer_account(
|
pub async fn send_shielded_native_token_transfer_outer_account(
|
||||||
&self,
|
&self,
|
||||||
from: Address,
|
from: Address,
|
||||||
to_npk: nssa_core::NullifierPublicKey,
|
to_npk: nssa_core::NullifierPublicKey,
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user