Skip to content

Commit

Permalink
123
Browse files Browse the repository at this point in the history
  • Loading branch information
elasticLove1 committed Jul 1, 2024
1 parent 7406ba1 commit 94269bf
Show file tree
Hide file tree
Showing 443 changed files with 1,387 additions and 3,455 deletions.
5 changes: 1 addition & 4 deletions tvm_api/src/ton/accountaddress.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
use serde_derive::Deserialize;
use serde_derive::Serialize;
use serde_derive::{Deserialize, Serialize};
#[derive(Debug, Default, Clone, PartialEq)]
#[doc = "TL-derived from `accountAddress`\n\n```text\naccountAddress account_address:string = AccountAddress;\n```\n"]
pub struct AccountAddress {
Expand All @@ -10,7 +9,6 @@ impl crate::BareSerialize for AccountAddress {
fn constructor(&self) -> crate::ConstructorNumber {
crate::ConstructorNumber(0x2d09bdab)
}

fn serialize_bare(&self, _ser: &mut crate::Serializer) -> crate::Result<()> {
let AccountAddress { account_address } = self;
_ser.write_bare::<crate::ton::string>(account_address)?;
Expand All @@ -27,7 +25,6 @@ impl crate::BareDeserialize for AccountAddress {
}
impl crate::IntoBoxed for AccountAddress {
type Boxed = crate::ton::AccountAddress;

fn into_boxed(self) -> crate::ton::AccountAddress {
crate::ton::AccountAddress::AccountAddress(self)
}
Expand Down
5 changes: 1 addition & 4 deletions tvm_api/src/ton/accountlist.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
use serde_derive::Deserialize;
use serde_derive::Serialize;
use serde_derive::{Deserialize, Serialize};
#[derive(Debug, Default, Clone, PartialEq)]
#[doc = "TL-derived from `accountList`\n\n```text\naccountList accounts:vector<fullAccountState> = AccountList;\n```\n"]
pub struct AccountList {
Expand All @@ -11,7 +10,6 @@ impl crate::BareSerialize for AccountList {
fn constructor(&self) -> crate::ConstructorNumber {
crate::ConstructorNumber(0x783eb255)
}

fn serialize_bare(&self, _ser: &mut crate::Serializer) -> crate::Result<()> {
let AccountList { accounts } = self;
_ser . write_bare :: < crate :: ton :: vector < crate :: ton :: Bare , crate :: ton :: fullaccountstate :: FullAccountState > > (accounts) ? ;
Expand All @@ -31,7 +29,6 @@ impl crate::BareDeserialize for AccountList {
}
impl crate::IntoBoxed for AccountList {
type Boxed = crate::ton::AccountList;

fn into_boxed(self) -> crate::ton::AccountList {
crate::ton::AccountList::AccountList(self)
}
Expand Down
5 changes: 1 addition & 4 deletions tvm_api/src/ton/accountrevisionlist.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
use serde_derive::Deserialize;
use serde_derive::Serialize;
use serde_derive::{Deserialize, Serialize};
#[derive(Debug, Default, Clone, PartialEq)]
#[doc = "TL-derived from `accountRevisionList`\n\n```text\naccountRevisionList revisions:vector<fullAccountState> = AccountRevisionList;\n```\n"]
pub struct AccountRevisionList {
Expand All @@ -11,7 +10,6 @@ impl crate::BareSerialize for AccountRevisionList {
fn constructor(&self) -> crate::ConstructorNumber {
crate::ConstructorNumber(0x1f6c64ca)
}

fn serialize_bare(&self, _ser: &mut crate::Serializer) -> crate::Result<()> {
let AccountRevisionList { revisions } = self;
_ser . write_bare :: < crate :: ton :: vector < crate :: ton :: Bare , crate :: ton :: fullaccountstate :: FullAccountState > > (revisions) ? ;
Expand All @@ -31,7 +29,6 @@ impl crate::BareDeserialize for AccountRevisionList {
}
impl crate::IntoBoxed for AccountRevisionList {
type Boxed = crate::ton::AccountRevisionList;

fn into_boxed(self) -> crate::ton::AccountRevisionList {
crate::ton::AccountRevisionList::AccountRevisionList(self)
}
Expand Down
11 changes: 1 addition & 10 deletions tvm_api/src/ton/action.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
use serde_derive::Deserialize;
use serde_derive::Serialize;
use serde_derive::{Deserialize, Serialize};
#[derive(Debug, Default, Clone, PartialEq)]
#[doc = "TL-derived from `actionDns`\n\n```text\nactionDns actions:vector<dns.Action> = Action;\n```\n"]
pub struct ActionDns {
Expand All @@ -10,7 +9,6 @@ impl crate::BareSerialize for ActionDns {
fn constructor(&self) -> crate::ConstructorNumber {
crate::ConstructorNumber(0x47273021)
}

fn serialize_bare(&self, _ser: &mut crate::Serializer) -> crate::Result<()> {
let ActionDns { actions } = self;
_ser.write_bare::<crate::ton::vector<crate::ton::Boxed, crate::ton::dns::Action>>(actions)?;
Expand All @@ -28,7 +26,6 @@ impl crate::BareDeserialize for ActionDns {
}
impl crate::IntoBoxed for ActionDns {
type Boxed = crate::ton::Action;

fn into_boxed(self) -> crate::ton::Action {
crate::ton::Action::ActionDns(self)
}
Expand All @@ -44,7 +41,6 @@ impl crate::BareSerialize for ActionMsg {
fn constructor(&self) -> crate::ConstructorNumber {
crate::ConstructorNumber(0x0eb67750)
}

fn serialize_bare(&self, _ser: &mut crate::Serializer) -> crate::Result<()> {
let ActionMsg { messages, allow_send_to_uninited } = self;
_ser.write_bare::<crate::ton::vector<crate::ton::Bare, crate::ton::msg::message::Message>>(
Expand All @@ -65,7 +61,6 @@ impl crate::BareDeserialize for ActionMsg {
}
impl crate::IntoBoxed for ActionMsg {
type Boxed = crate::ton::Action;

fn into_boxed(self) -> crate::ton::Action {
crate::ton::Action::ActionMsg(self)
}
Expand All @@ -80,7 +75,6 @@ impl crate::BareSerialize for ActionPchan {
fn constructor(&self) -> crate::ConstructorNumber {
crate::ConstructorNumber(0xa72dc5e1)
}

fn serialize_bare(&self, _ser: &mut crate::Serializer) -> crate::Result<()> {
let ActionPchan { action } = self;
_ser.write_boxed::<crate::ton::pchan::Action>(action)?;
Expand All @@ -97,7 +91,6 @@ impl crate::BareDeserialize for ActionPchan {
}
impl crate::IntoBoxed for ActionPchan {
type Boxed = crate::ton::Action;

fn into_boxed(self) -> crate::ton::Action {
crate::ton::Action::ActionPchan(self)
}
Expand All @@ -112,7 +105,6 @@ impl crate::BareSerialize for ActionRwallet {
fn constructor(&self) -> crate::ConstructorNumber {
crate::ConstructorNumber(0xf90237c5)
}

fn serialize_bare(&self, _ser: &mut crate::Serializer) -> crate::Result<()> {
let ActionRwallet { action } = self;
_ser.write_bare::<crate::ton::rwallet::actioninit::ActionInit>(action)?;
Expand All @@ -129,7 +121,6 @@ impl crate::BareDeserialize for ActionRwallet {
}
impl crate::IntoBoxed for ActionRwallet {
type Boxed = crate::ton::Action;

fn into_boxed(self) -> crate::ton::Action {
crate::ton::Action::ActionRwallet(self)
}
Expand Down
9 changes: 1 addition & 8 deletions tvm_api/src/ton/adnl/address/address.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
use serde_derive::Deserialize;
use serde_derive::Serialize;
use serde_derive::{Deserialize, Serialize};
#[derive(Debug, Default, Clone, PartialEq)]
#[doc = "TL-derived from `adnl.address.tunnel`\n\n```text\nadnl.address.tunnel to:int256 pubkey:PublicKey = adnl.Address;\n```\n"]
pub struct Tunnel {
Expand All @@ -11,7 +10,6 @@ impl crate::BareSerialize for Tunnel {
fn constructor(&self) -> crate::ConstructorNumber {
crate::ConstructorNumber(0x092b02eb)
}

fn serialize_bare(&self, _ser: &mut crate::Serializer) -> crate::Result<()> {
let Tunnel { to, pubkey } = self;
_ser.write_bare::<crate::ton::int256>(to)?;
Expand All @@ -30,7 +28,6 @@ impl crate::BareDeserialize for Tunnel {
}
impl crate::IntoBoxed for Tunnel {
type Boxed = crate::ton::adnl::Address;

fn into_boxed(self) -> crate::ton::adnl::Address {
crate::ton::adnl::Address::Adnl_Address_Tunnel(self)
}
Expand All @@ -46,7 +43,6 @@ impl crate::BareSerialize for Udp {
fn constructor(&self) -> crate::ConstructorNumber {
crate::ConstructorNumber(0x670da6e7)
}

fn serialize_bare(&self, _ser: &mut crate::Serializer) -> crate::Result<()> {
let Udp { ip, port } = self;
_ser.write_bare::<crate::ton::int>(ip)?;
Expand All @@ -65,7 +61,6 @@ impl crate::BareDeserialize for Udp {
}
impl crate::IntoBoxed for Udp {
type Boxed = crate::ton::adnl::Address;

fn into_boxed(self) -> crate::ton::adnl::Address {
crate::ton::adnl::Address::Adnl_Address_Udp(self)
}
Expand All @@ -81,7 +76,6 @@ impl crate::BareSerialize for Udp6 {
fn constructor(&self) -> crate::ConstructorNumber {
crate::ConstructorNumber(0xe31d63fa)
}

fn serialize_bare(&self, _ser: &mut crate::Serializer) -> crate::Result<()> {
let Udp6 { ip, port } = self;
_ser.write_bare::<crate::ton::int128>(ip)?;
Expand All @@ -100,7 +94,6 @@ impl crate::BareDeserialize for Udp6 {
}
impl crate::IntoBoxed for Udp6 {
type Boxed = crate::ton::adnl::Address;

fn into_boxed(self) -> crate::ton::adnl::Address {
crate::ton::adnl::Address::Adnl_Address_Udp6(self)
}
Expand Down
3 changes: 1 addition & 2 deletions tvm_api/src/ton/adnl/address/mod.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,2 @@
use serde_derive::Deserialize;
use serde_derive::Serialize;
use serde_derive::{Deserialize, Serialize};
pub mod address;
5 changes: 1 addition & 4 deletions tvm_api/src/ton/adnl/addresslist.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
use serde_derive::Deserialize;
use serde_derive::Serialize;
use serde_derive::{Deserialize, Serialize};
#[derive(Debug, Default, Clone, PartialEq)]
#[doc = "TL-derived from `adnl.addressList`\n\n```text\nadnl.addressList addrs:(vector adnl.Address) version:int reinit_date:int priority:int expire_at:int = adnl.AddressList;\n```\n"]
pub struct AddressList {
Expand All @@ -14,7 +13,6 @@ impl crate::BareSerialize for AddressList {
fn constructor(&self) -> crate::ConstructorNumber {
crate::ConstructorNumber(0x2227e658)
}

fn serialize_bare(&self, _ser: &mut crate::Serializer) -> crate::Result<()> {
let AddressList { addrs, version, reinit_date, priority, expire_at } = self;
_ser.write_bare::<crate::ton::vector<crate::ton::Boxed, crate::ton::adnl::Address>>(addrs)?;
Expand All @@ -40,7 +38,6 @@ impl crate::BareDeserialize for AddressList {
}
impl crate::IntoBoxed for AddressList {
type Boxed = crate::ton::adnl::AddressList;

fn into_boxed(self) -> crate::ton::adnl::AddressList {
crate::ton::adnl::AddressList::Adnl_AddressList(self)
}
Expand Down
5 changes: 1 addition & 4 deletions tvm_api/src/ton/adnl/config/global.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
use serde_derive::Deserialize;
use serde_derive::Serialize;
use serde_derive::{Deserialize, Serialize};
#[derive(Debug, Default, Clone, PartialEq)]
#[doc = "TL-derived from `adnl.config.global`\n\n```text\nadnl.config.global static_nodes:adnl.nodes = adnl.config.Global;\n```\n"]
pub struct Global {
Expand All @@ -10,7 +9,6 @@ impl crate::BareSerialize for Global {
fn constructor(&self) -> crate::ConstructorNumber {
crate::ConstructorNumber(0xbe6f80d0)
}

fn serialize_bare(&self, _ser: &mut crate::Serializer) -> crate::Result<()> {
let Global { static_nodes } = self;
_ser.write_bare::<crate::ton::adnl::nodes::Nodes>(static_nodes)?;
Expand All @@ -27,7 +25,6 @@ impl crate::BareDeserialize for Global {
}
impl crate::IntoBoxed for Global {
type Boxed = crate::ton::adnl::config::Global;

fn into_boxed(self) -> crate::ton::adnl::config::Global {
crate::ton::adnl::config::Global::Adnl_Config_Global(self)
}
Expand Down
5 changes: 1 addition & 4 deletions tvm_api/src/ton/adnl/config/mod.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
use serde_derive::Deserialize;
use serde_derive::Serialize;
use serde_derive::{Deserialize, Serialize};
#[derive(Debug, Clone, PartialEq)]
#[doc = "TL-derived from `adnl.config.Global`\n\n```text\nadnl.config.global static_nodes:adnl.nodes = adnl.config.Global;\n```\n"]
pub enum Global {
Expand All @@ -11,7 +10,6 @@ impl Global {
Global::Adnl_Config_Global(ref x) => &x.static_nodes,
}
}

pub fn only(self) -> crate::ton::adnl::config::global::Global {
match self {
Global::Adnl_Config_Global(x) => x,
Expand All @@ -35,7 +33,6 @@ impl crate::BoxedDeserialize for Global {
fn possible_constructors() -> Vec<crate::ConstructorNumber> {
vec![crate::ConstructorNumber(0xbe6f80d0)]
}

fn deserialize_boxed(
_id: crate::ConstructorNumber,
_de: &mut crate::Deserializer,
Expand Down
6 changes: 1 addition & 5 deletions tvm_api/src/ton/adnl/db/mod.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
use serde_derive::Deserialize;
use serde_derive::Serialize;
use serde_derive::{Deserialize, Serialize};
#[derive(Debug, Clone, PartialEq)]
#[doc = "TL-derived from `adnl.db.Key`\n\n```text\nadnl.db.node.key local_id:int256 peer_id:int256 = adnl.db.Key;\n```\n"]
pub enum Key {
Expand All @@ -11,13 +10,11 @@ impl Key {
Key::Adnl_Db_Node_Key(ref x) => &x.local_id,
}
}

pub fn peer_id(&self) -> &crate::ton::int256 {
match self {
Key::Adnl_Db_Node_Key(ref x) => &x.peer_id,
}
}

pub fn only(self) -> crate::ton::adnl::db::node::key::Key {
match self {
Key::Adnl_Db_Node_Key(x) => x,
Expand All @@ -41,7 +38,6 @@ impl crate::BoxedDeserialize for Key {
fn possible_constructors() -> Vec<crate::ConstructorNumber> {
vec![crate::ConstructorNumber(0xc5a3e42e)]
}

fn deserialize_boxed(
_id: crate::ConstructorNumber,
_de: &mut crate::Deserializer,
Expand Down
5 changes: 1 addition & 4 deletions tvm_api/src/ton/adnl/db/node/key.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
use serde_derive::Deserialize;
use serde_derive::Serialize;
use serde_derive::{Deserialize, Serialize};
#[derive(Debug, Default, Clone, PartialEq)]
#[doc = "TL-derived from `adnl.db.node.key`\n\n```text\nadnl.db.node.key local_id:int256 peer_id:int256 = adnl.db.Key;\n```\n"]
pub struct Key {
Expand All @@ -11,7 +10,6 @@ impl crate::BareSerialize for Key {
fn constructor(&self) -> crate::ConstructorNumber {
crate::ConstructorNumber(0xc5a3e42e)
}

fn serialize_bare(&self, _ser: &mut crate::Serializer) -> crate::Result<()> {
let Key { local_id, peer_id } = self;
_ser.write_bare::<crate::ton::int256>(local_id)?;
Expand All @@ -30,7 +28,6 @@ impl crate::BareDeserialize for Key {
}
impl crate::IntoBoxed for Key {
type Boxed = crate::ton::adnl::db::Key;

fn into_boxed(self) -> crate::ton::adnl::db::Key {
crate::ton::adnl::db::Key::Adnl_Db_Node_Key(self)
}
Expand Down
8 changes: 1 addition & 7 deletions tvm_api/src/ton/adnl/db/node/mod.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
use serde_derive::Deserialize;
use serde_derive::Serialize;
use serde_derive::{Deserialize, Serialize};
#[derive(Debug, Clone, PartialEq)]
#[doc = "TL-derived from `adnl.db.node.Value`\n\n```text\nadnl.db.node.value date:int id:PublicKey addr_list:adnl.addressList priority_addr_list:adnl.addressList = adnl.db.node.Value;\n```\n"]
pub enum Value {
Expand All @@ -11,25 +10,21 @@ impl Value {
Value::Adnl_Db_Node_Value(ref x) => &x.addr_list,
}
}

pub fn date(&self) -> &crate::ton::int {
match self {
Value::Adnl_Db_Node_Value(ref x) => &x.date,
}
}

pub fn id(&self) -> &crate::ton::PublicKey {
match self {
Value::Adnl_Db_Node_Value(ref x) => &x.id,
}
}

pub fn priority_addr_list(&self) -> &crate::ton::adnl::addresslist::AddressList {
match self {
Value::Adnl_Db_Node_Value(ref x) => &x.priority_addr_list,
}
}

pub fn only(self) -> crate::ton::adnl::db::node::value::Value {
match self {
Value::Adnl_Db_Node_Value(x) => x,
Expand All @@ -53,7 +48,6 @@ impl crate::BoxedDeserialize for Value {
fn possible_constructors() -> Vec<crate::ConstructorNumber> {
vec![crate::ConstructorNumber(0x545d2707)]
}

fn deserialize_boxed(
_id: crate::ConstructorNumber,
_de: &mut crate::Deserializer,
Expand Down
5 changes: 1 addition & 4 deletions tvm_api/src/ton/adnl/db/node/value.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
use serde_derive::Deserialize;
use serde_derive::Serialize;
use serde_derive::{Deserialize, Serialize};
#[derive(Debug, Default, Clone, PartialEq)]
#[doc = "TL-derived from `adnl.db.node.value`\n\n```text\nadnl.db.node.value date:int id:PublicKey addr_list:adnl.addressList priority_addr_list:adnl.addressList = adnl.db.node.Value;\n```\n"]
pub struct Value {
Expand All @@ -13,7 +12,6 @@ impl crate::BareSerialize for Value {
fn constructor(&self) -> crate::ConstructorNumber {
crate::ConstructorNumber(0x545d2707)
}

fn serialize_bare(&self, _ser: &mut crate::Serializer) -> crate::Result<()> {
let Value { date, id, addr_list, priority_addr_list } = self;
_ser.write_bare::<crate::ton::int>(date)?;
Expand All @@ -37,7 +35,6 @@ impl crate::BareDeserialize for Value {
}
impl crate::IntoBoxed for Value {
type Boxed = crate::ton::adnl::db::node::Value;

fn into_boxed(self) -> crate::ton::adnl::db::node::Value {
crate::ton::adnl::db::node::Value::Adnl_Db_Node_Value(self)
}
Expand Down
Loading

0 comments on commit 94269bf

Please sign in to comment.