tx.rs 430 B

12345678910111213141516171819
  1. use darkfi_serial::{Encodable, Decodable, SerialDecodable, SerialEncodable};
  2. use crate::{
  3. consensus::{EncryptedTxRcpt, TransferStx},
  4. };
  5. /// transfer transaction
  6. #[derive(Debug, Clone, SerialDecodable, SerialEncodable)]
  7. pub struct Tx {
  8. pub xfer: TransferStx,
  9. pub cipher: EncryptedTxRcpt,
  10. }
  11. impl Tx {
  12. /// verify transfer transaction
  13. pub fn verify(&self) -> bool{
  14. //TODO: verify tx
  15. true
  16. }
  17. }