-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
656b21b
commit 2d50e82
Showing
5 changed files
with
22 additions
and
15 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
[package] | ||
name = "omni-transaction-rs" | ||
name = "omni-transaction" | ||
version = "0.1.0" | ||
authors = ["Pagoda <[email protected]>"] | ||
edition = "2021" | ||
|
@@ -20,8 +20,9 @@ overflow-checks = true | |
[dependencies] | ||
rlp = "0.5.2" | ||
hex = "0.4.3" | ||
borsh = "1.0.0" | ||
near-crypto = "0.23.0" | ||
near-primitives = "0.23.0" | ||
borsh = { version = "1.0.0", features = ["derive"] } | ||
near-primitives = { version = "0.23" } | ||
near-crypto = { version = "0.23" } | ||
near-sdk = "5.2.0" | ||
|
||
[dev-dependencies] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,5 +2,5 @@ | |
mod ethereum; | ||
mod near; | ||
|
||
mod transaction; | ||
mod types; | ||
pub mod transaction; | ||
pub mod types; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,18 @@ | ||
use near_sdk::serde::{Serialize, Deserialize}; | ||
use near_sdk::borsh::{BorshDeserialize, BorshSerialize}; | ||
|
||
#[derive(Serialize, Deserialize, BorshDeserialize, BorshSerialize, Clone, PartialEq, Eq, PartialOrd, Hash)] | ||
#[serde(crate = "near_sdk::serde")] | ||
pub enum ChainKind { | ||
NEAR, | ||
EVM { chain_id: u64 }, | ||
Solana, | ||
Cosmos { chain_id: String }, | ||
} | ||
|
||
#[derive(Serialize, Deserialize, BorshDeserialize, BorshSerialize, PartialEq, Eq)] | ||
#[serde(crate = "near_sdk::serde")] | ||
pub struct OmniAddress { | ||
chain_kind: ChainKind, | ||
address: String, | ||
pub chain_kind: ChainKind, | ||
pub address: String, | ||
} |