pub mod ipc {
#![allow(unknown_lints)]
#![allow(clippy::all)]
#![cfg_attr(rustfmt, rustfmt_skip)]
#![allow(box_pointers)]
#![allow(dead_code)]
#![allow(missing_docs)]
#![allow(non_camel_case_types)]
#![allow(non_snake_case)]
#![allow(non_upper_case_globals)]
#![allow(trivial_casts)]
#![allow(unsafe_code)]
#![allow(unused_imports)]
#![allow(unused_results)]
use protobuf::Message as Message_imported_for_functions;
use protobuf::ProtobufEnum as ProtobufEnum_imported_for_functions;
const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_2_8_2;
#[derive(PartialEq,Clone,Default)]
pub struct DeployCode {
pub code: ::std::vec::Vec<u8>,
pub args: ::std::vec::Vec<u8>,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a DeployCode {
fn default() -> &'a DeployCode {
<DeployCode as ::protobuf::Message>::default_instance()
}
}
impl DeployCode {
pub fn new() -> DeployCode {
::std::default::Default::default()
}
pub fn get_code(&self) -> &[u8] {
&self.code
}
pub fn clear_code(&mut self) {
self.code.clear();
}
pub fn set_code(&mut self, v: ::std::vec::Vec<u8>) {
self.code = v;
}
pub fn mut_code(&mut self) -> &mut ::std::vec::Vec<u8> {
&mut self.code
}
pub fn take_code(&mut self) -> ::std::vec::Vec<u8> {
::std::mem::replace(&mut self.code, ::std::vec::Vec::new())
}
pub fn get_args(&self) -> &[u8] {
&self.args
}
pub fn clear_args(&mut self) {
self.args.clear();
}
pub fn set_args(&mut self, v: ::std::vec::Vec<u8>) {
self.args = v;
}
pub fn mut_args(&mut self) -> &mut ::std::vec::Vec<u8> {
&mut self.args
}
pub fn take_args(&mut self) -> ::std::vec::Vec<u8> {
::std::mem::replace(&mut self.args, ::std::vec::Vec::new())
}
}
impl ::protobuf::Message for DeployCode {
fn is_initialized(&self) -> bool {
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
::protobuf::rt::read_singular_proto3_bytes_into(wire_type, is, &mut self.code)?;
},
2 => {
::protobuf::rt::read_singular_proto3_bytes_into(wire_type, is, &mut self.args)?;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if !self.code.is_empty() {
my_size += ::protobuf::rt::bytes_size(1, &self.code);
}
if !self.args.is_empty() {
my_size += ::protobuf::rt::bytes_size(2, &self.args);
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if !self.code.is_empty() {
os.write_bytes(1, &self.code)?;
}
if !self.args.is_empty() {
os.write_bytes(2, &self.args)?;
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> DeployCode {
DeployCode::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
"code",
|m: &DeployCode| { &m.code },
|m: &mut DeployCode| { &mut m.code },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
"args",
|m: &DeployCode| { &m.args },
|m: &mut DeployCode| { &mut m.args },
));
::protobuf::reflect::MessageDescriptor::new::<DeployCode>(
"DeployCode",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static DeployCode {
static mut instance: ::protobuf::lazy::Lazy<DeployCode> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const DeployCode,
};
unsafe {
instance.get(DeployCode::new)
}
}
}
impl ::protobuf::Clear for DeployCode {
fn clear(&mut self) {
self.code.clear();
self.args.clear();
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for DeployCode {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for DeployCode {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct StoredContractHash {
pub hash: ::std::vec::Vec<u8>,
pub args: ::std::vec::Vec<u8>,
pub entry_point_name: ::std::string::String,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a StoredContractHash {
fn default() -> &'a StoredContractHash {
<StoredContractHash as ::protobuf::Message>::default_instance()
}
}
impl StoredContractHash {
pub fn new() -> StoredContractHash {
::std::default::Default::default()
}
pub fn get_hash(&self) -> &[u8] {
&self.hash
}
pub fn clear_hash(&mut self) {
self.hash.clear();
}
pub fn set_hash(&mut self, v: ::std::vec::Vec<u8>) {
self.hash = v;
}
pub fn mut_hash(&mut self) -> &mut ::std::vec::Vec<u8> {
&mut self.hash
}
pub fn take_hash(&mut self) -> ::std::vec::Vec<u8> {
::std::mem::replace(&mut self.hash, ::std::vec::Vec::new())
}
pub fn get_args(&self) -> &[u8] {
&self.args
}
pub fn clear_args(&mut self) {
self.args.clear();
}
pub fn set_args(&mut self, v: ::std::vec::Vec<u8>) {
self.args = v;
}
pub fn mut_args(&mut self) -> &mut ::std::vec::Vec<u8> {
&mut self.args
}
pub fn take_args(&mut self) -> ::std::vec::Vec<u8> {
::std::mem::replace(&mut self.args, ::std::vec::Vec::new())
}
pub fn get_entry_point_name(&self) -> &str {
&self.entry_point_name
}
pub fn clear_entry_point_name(&mut self) {
self.entry_point_name.clear();
}
pub fn set_entry_point_name(&mut self, v: ::std::string::String) {
self.entry_point_name = v;
}
pub fn mut_entry_point_name(&mut self) -> &mut ::std::string::String {
&mut self.entry_point_name
}
pub fn take_entry_point_name(&mut self) -> ::std::string::String {
::std::mem::replace(&mut self.entry_point_name, ::std::string::String::new())
}
}
impl ::protobuf::Message for StoredContractHash {
fn is_initialized(&self) -> bool {
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
::protobuf::rt::read_singular_proto3_bytes_into(wire_type, is, &mut self.hash)?;
},
2 => {
::protobuf::rt::read_singular_proto3_bytes_into(wire_type, is, &mut self.args)?;
},
3 => {
::protobuf::rt::read_singular_proto3_string_into(wire_type, is, &mut self.entry_point_name)?;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if !self.hash.is_empty() {
my_size += ::protobuf::rt::bytes_size(1, &self.hash);
}
if !self.args.is_empty() {
my_size += ::protobuf::rt::bytes_size(2, &self.args);
}
if !self.entry_point_name.is_empty() {
my_size += ::protobuf::rt::string_size(3, &self.entry_point_name);
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if !self.hash.is_empty() {
os.write_bytes(1, &self.hash)?;
}
if !self.args.is_empty() {
os.write_bytes(2, &self.args)?;
}
if !self.entry_point_name.is_empty() {
os.write_string(3, &self.entry_point_name)?;
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> StoredContractHash {
StoredContractHash::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
"hash",
|m: &StoredContractHash| { &m.hash },
|m: &mut StoredContractHash| { &mut m.hash },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
"args",
|m: &StoredContractHash| { &m.args },
|m: &mut StoredContractHash| { &mut m.args },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeString>(
"entry_point_name",
|m: &StoredContractHash| { &m.entry_point_name },
|m: &mut StoredContractHash| { &mut m.entry_point_name },
));
::protobuf::reflect::MessageDescriptor::new::<StoredContractHash>(
"StoredContractHash",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static StoredContractHash {
static mut instance: ::protobuf::lazy::Lazy<StoredContractHash> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const StoredContractHash,
};
unsafe {
instance.get(StoredContractHash::new)
}
}
}
impl ::protobuf::Clear for StoredContractHash {
fn clear(&mut self) {
self.hash.clear();
self.args.clear();
self.entry_point_name.clear();
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for StoredContractHash {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for StoredContractHash {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct StoredContractName {
pub name: ::std::string::String,
pub args: ::std::vec::Vec<u8>,
pub entry_point_name: ::std::string::String,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a StoredContractName {
fn default() -> &'a StoredContractName {
<StoredContractName as ::protobuf::Message>::default_instance()
}
}
impl StoredContractName {
pub fn new() -> StoredContractName {
::std::default::Default::default()
}
pub fn get_name(&self) -> &str {
&self.name
}
pub fn clear_name(&mut self) {
self.name.clear();
}
pub fn set_name(&mut self, v: ::std::string::String) {
self.name = v;
}
pub fn mut_name(&mut self) -> &mut ::std::string::String {
&mut self.name
}
pub fn take_name(&mut self) -> ::std::string::String {
::std::mem::replace(&mut self.name, ::std::string::String::new())
}
pub fn get_args(&self) -> &[u8] {
&self.args
}
pub fn clear_args(&mut self) {
self.args.clear();
}
pub fn set_args(&mut self, v: ::std::vec::Vec<u8>) {
self.args = v;
}
pub fn mut_args(&mut self) -> &mut ::std::vec::Vec<u8> {
&mut self.args
}
pub fn take_args(&mut self) -> ::std::vec::Vec<u8> {
::std::mem::replace(&mut self.args, ::std::vec::Vec::new())
}
pub fn get_entry_point_name(&self) -> &str {
&self.entry_point_name
}
pub fn clear_entry_point_name(&mut self) {
self.entry_point_name.clear();
}
pub fn set_entry_point_name(&mut self, v: ::std::string::String) {
self.entry_point_name = v;
}
pub fn mut_entry_point_name(&mut self) -> &mut ::std::string::String {
&mut self.entry_point_name
}
pub fn take_entry_point_name(&mut self) -> ::std::string::String {
::std::mem::replace(&mut self.entry_point_name, ::std::string::String::new())
}
}
impl ::protobuf::Message for StoredContractName {
fn is_initialized(&self) -> bool {
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
::protobuf::rt::read_singular_proto3_string_into(wire_type, is, &mut self.name)?;
},
2 => {
::protobuf::rt::read_singular_proto3_bytes_into(wire_type, is, &mut self.args)?;
},
3 => {
::protobuf::rt::read_singular_proto3_string_into(wire_type, is, &mut self.entry_point_name)?;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if !self.name.is_empty() {
my_size += ::protobuf::rt::string_size(1, &self.name);
}
if !self.args.is_empty() {
my_size += ::protobuf::rt::bytes_size(2, &self.args);
}
if !self.entry_point_name.is_empty() {
my_size += ::protobuf::rt::string_size(3, &self.entry_point_name);
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if !self.name.is_empty() {
os.write_string(1, &self.name)?;
}
if !self.args.is_empty() {
os.write_bytes(2, &self.args)?;
}
if !self.entry_point_name.is_empty() {
os.write_string(3, &self.entry_point_name)?;
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> StoredContractName {
StoredContractName::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeString>(
"name",
|m: &StoredContractName| { &m.name },
|m: &mut StoredContractName| { &mut m.name },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
"args",
|m: &StoredContractName| { &m.args },
|m: &mut StoredContractName| { &mut m.args },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeString>(
"entry_point_name",
|m: &StoredContractName| { &m.entry_point_name },
|m: &mut StoredContractName| { &mut m.entry_point_name },
));
::protobuf::reflect::MessageDescriptor::new::<StoredContractName>(
"StoredContractName",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static StoredContractName {
static mut instance: ::protobuf::lazy::Lazy<StoredContractName> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const StoredContractName,
};
unsafe {
instance.get(StoredContractName::new)
}
}
}
impl ::protobuf::Clear for StoredContractName {
fn clear(&mut self) {
self.name.clear();
self.args.clear();
self.entry_point_name.clear();
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for StoredContractName {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for StoredContractName {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct StoredContractPackage {
pub name: ::std::string::String,
pub entry_point_name: ::std::string::String,
pub args: ::std::vec::Vec<u8>,
pub optional_version: ::std::option::Option<StoredContractPackage_oneof_optional_version>,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a StoredContractPackage {
fn default() -> &'a StoredContractPackage {
<StoredContractPackage as ::protobuf::Message>::default_instance()
}
}
#[derive(Clone,PartialEq,Debug)]
pub enum StoredContractPackage_oneof_optional_version {
version(u32),
}
impl StoredContractPackage {
pub fn new() -> StoredContractPackage {
::std::default::Default::default()
}
pub fn get_name(&self) -> &str {
&self.name
}
pub fn clear_name(&mut self) {
self.name.clear();
}
pub fn set_name(&mut self, v: ::std::string::String) {
self.name = v;
}
pub fn mut_name(&mut self) -> &mut ::std::string::String {
&mut self.name
}
pub fn take_name(&mut self) -> ::std::string::String {
::std::mem::replace(&mut self.name, ::std::string::String::new())
}
pub fn get_version(&self) -> u32 {
match self.optional_version {
::std::option::Option::Some(StoredContractPackage_oneof_optional_version::version(v)) => v,
_ => 0,
}
}
pub fn clear_version(&mut self) {
self.optional_version = ::std::option::Option::None;
}
pub fn has_version(&self) -> bool {
match self.optional_version {
::std::option::Option::Some(StoredContractPackage_oneof_optional_version::version(..)) => true,
_ => false,
}
}
pub fn set_version(&mut self, v: u32) {
self.optional_version = ::std::option::Option::Some(StoredContractPackage_oneof_optional_version::version(v))
}
pub fn get_entry_point_name(&self) -> &str {
&self.entry_point_name
}
pub fn clear_entry_point_name(&mut self) {
self.entry_point_name.clear();
}
pub fn set_entry_point_name(&mut self, v: ::std::string::String) {
self.entry_point_name = v;
}
pub fn mut_entry_point_name(&mut self) -> &mut ::std::string::String {
&mut self.entry_point_name
}
pub fn take_entry_point_name(&mut self) -> ::std::string::String {
::std::mem::replace(&mut self.entry_point_name, ::std::string::String::new())
}
pub fn get_args(&self) -> &[u8] {
&self.args
}
pub fn clear_args(&mut self) {
self.args.clear();
}
pub fn set_args(&mut self, v: ::std::vec::Vec<u8>) {
self.args = v;
}
pub fn mut_args(&mut self) -> &mut ::std::vec::Vec<u8> {
&mut self.args
}
pub fn take_args(&mut self) -> ::std::vec::Vec<u8> {
::std::mem::replace(&mut self.args, ::std::vec::Vec::new())
}
}
impl ::protobuf::Message for StoredContractPackage {
fn is_initialized(&self) -> bool {
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
::protobuf::rt::read_singular_proto3_string_into(wire_type, is, &mut self.name)?;
},
2 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
self.optional_version = ::std::option::Option::Some(StoredContractPackage_oneof_optional_version::version(is.read_uint32()?));
},
3 => {
::protobuf::rt::read_singular_proto3_string_into(wire_type, is, &mut self.entry_point_name)?;
},
4 => {
::protobuf::rt::read_singular_proto3_bytes_into(wire_type, is, &mut self.args)?;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if !self.name.is_empty() {
my_size += ::protobuf::rt::string_size(1, &self.name);
}
if !self.entry_point_name.is_empty() {
my_size += ::protobuf::rt::string_size(3, &self.entry_point_name);
}
if !self.args.is_empty() {
my_size += ::protobuf::rt::bytes_size(4, &self.args);
}
if let ::std::option::Option::Some(ref v) = self.optional_version {
match v {
&StoredContractPackage_oneof_optional_version::version(v) => {
my_size += ::protobuf::rt::value_size(2, v, ::protobuf::wire_format::WireTypeVarint);
},
};
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if !self.name.is_empty() {
os.write_string(1, &self.name)?;
}
if !self.entry_point_name.is_empty() {
os.write_string(3, &self.entry_point_name)?;
}
if !self.args.is_empty() {
os.write_bytes(4, &self.args)?;
}
if let ::std::option::Option::Some(ref v) = self.optional_version {
match v {
&StoredContractPackage_oneof_optional_version::version(v) => {
os.write_uint32(2, v)?;
},
};
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> StoredContractPackage {
StoredContractPackage::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeString>(
"name",
|m: &StoredContractPackage| { &m.name },
|m: &mut StoredContractPackage| { &mut m.name },
));
fields.push(::protobuf::reflect::accessor::make_singular_u32_accessor::<_>(
"version",
StoredContractPackage::has_version,
StoredContractPackage::get_version,
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeString>(
"entry_point_name",
|m: &StoredContractPackage| { &m.entry_point_name },
|m: &mut StoredContractPackage| { &mut m.entry_point_name },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
"args",
|m: &StoredContractPackage| { &m.args },
|m: &mut StoredContractPackage| { &mut m.args },
));
::protobuf::reflect::MessageDescriptor::new::<StoredContractPackage>(
"StoredContractPackage",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static StoredContractPackage {
static mut instance: ::protobuf::lazy::Lazy<StoredContractPackage> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const StoredContractPackage,
};
unsafe {
instance.get(StoredContractPackage::new)
}
}
}
impl ::protobuf::Clear for StoredContractPackage {
fn clear(&mut self) {
self.name.clear();
self.optional_version = ::std::option::Option::None;
self.entry_point_name.clear();
self.args.clear();
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for StoredContractPackage {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for StoredContractPackage {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct StoredContractPackageHash {
pub hash: ::std::vec::Vec<u8>,
pub entry_point_name: ::std::string::String,
pub args: ::std::vec::Vec<u8>,
pub optional_version: ::std::option::Option<StoredContractPackageHash_oneof_optional_version>,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a StoredContractPackageHash {
fn default() -> &'a StoredContractPackageHash {
<StoredContractPackageHash as ::protobuf::Message>::default_instance()
}
}
#[derive(Clone,PartialEq,Debug)]
pub enum StoredContractPackageHash_oneof_optional_version {
version(u32),
}
impl StoredContractPackageHash {
pub fn new() -> StoredContractPackageHash {
::std::default::Default::default()
}
pub fn get_hash(&self) -> &[u8] {
&self.hash
}
pub fn clear_hash(&mut self) {
self.hash.clear();
}
pub fn set_hash(&mut self, v: ::std::vec::Vec<u8>) {
self.hash = v;
}
pub fn mut_hash(&mut self) -> &mut ::std::vec::Vec<u8> {
&mut self.hash
}
pub fn take_hash(&mut self) -> ::std::vec::Vec<u8> {
::std::mem::replace(&mut self.hash, ::std::vec::Vec::new())
}
pub fn get_version(&self) -> u32 {
match self.optional_version {
::std::option::Option::Some(StoredContractPackageHash_oneof_optional_version::version(v)) => v,
_ => 0,
}
}
pub fn clear_version(&mut self) {
self.optional_version = ::std::option::Option::None;
}
pub fn has_version(&self) -> bool {
match self.optional_version {
::std::option::Option::Some(StoredContractPackageHash_oneof_optional_version::version(..)) => true,
_ => false,
}
}
pub fn set_version(&mut self, v: u32) {
self.optional_version = ::std::option::Option::Some(StoredContractPackageHash_oneof_optional_version::version(v))
}
pub fn get_entry_point_name(&self) -> &str {
&self.entry_point_name
}
pub fn clear_entry_point_name(&mut self) {
self.entry_point_name.clear();
}
pub fn set_entry_point_name(&mut self, v: ::std::string::String) {
self.entry_point_name = v;
}
pub fn mut_entry_point_name(&mut self) -> &mut ::std::string::String {
&mut self.entry_point_name
}
pub fn take_entry_point_name(&mut self) -> ::std::string::String {
::std::mem::replace(&mut self.entry_point_name, ::std::string::String::new())
}
pub fn get_args(&self) -> &[u8] {
&self.args
}
pub fn clear_args(&mut self) {
self.args.clear();
}
pub fn set_args(&mut self, v: ::std::vec::Vec<u8>) {
self.args = v;
}
pub fn mut_args(&mut self) -> &mut ::std::vec::Vec<u8> {
&mut self.args
}
pub fn take_args(&mut self) -> ::std::vec::Vec<u8> {
::std::mem::replace(&mut self.args, ::std::vec::Vec::new())
}
}
impl ::protobuf::Message for StoredContractPackageHash {
fn is_initialized(&self) -> bool {
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
::protobuf::rt::read_singular_proto3_bytes_into(wire_type, is, &mut self.hash)?;
},
2 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
self.optional_version = ::std::option::Option::Some(StoredContractPackageHash_oneof_optional_version::version(is.read_uint32()?));
},
3 => {
::protobuf::rt::read_singular_proto3_string_into(wire_type, is, &mut self.entry_point_name)?;
},
4 => {
::protobuf::rt::read_singular_proto3_bytes_into(wire_type, is, &mut self.args)?;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if !self.hash.is_empty() {
my_size += ::protobuf::rt::bytes_size(1, &self.hash);
}
if !self.entry_point_name.is_empty() {
my_size += ::protobuf::rt::string_size(3, &self.entry_point_name);
}
if !self.args.is_empty() {
my_size += ::protobuf::rt::bytes_size(4, &self.args);
}
if let ::std::option::Option::Some(ref v) = self.optional_version {
match v {
&StoredContractPackageHash_oneof_optional_version::version(v) => {
my_size += ::protobuf::rt::value_size(2, v, ::protobuf::wire_format::WireTypeVarint);
},
};
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if !self.hash.is_empty() {
os.write_bytes(1, &self.hash)?;
}
if !self.entry_point_name.is_empty() {
os.write_string(3, &self.entry_point_name)?;
}
if !self.args.is_empty() {
os.write_bytes(4, &self.args)?;
}
if let ::std::option::Option::Some(ref v) = self.optional_version {
match v {
&StoredContractPackageHash_oneof_optional_version::version(v) => {
os.write_uint32(2, v)?;
},
};
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> StoredContractPackageHash {
StoredContractPackageHash::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
"hash",
|m: &StoredContractPackageHash| { &m.hash },
|m: &mut StoredContractPackageHash| { &mut m.hash },
));
fields.push(::protobuf::reflect::accessor::make_singular_u32_accessor::<_>(
"version",
StoredContractPackageHash::has_version,
StoredContractPackageHash::get_version,
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeString>(
"entry_point_name",
|m: &StoredContractPackageHash| { &m.entry_point_name },
|m: &mut StoredContractPackageHash| { &mut m.entry_point_name },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
"args",
|m: &StoredContractPackageHash| { &m.args },
|m: &mut StoredContractPackageHash| { &mut m.args },
));
::protobuf::reflect::MessageDescriptor::new::<StoredContractPackageHash>(
"StoredContractPackageHash",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static StoredContractPackageHash {
static mut instance: ::protobuf::lazy::Lazy<StoredContractPackageHash> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const StoredContractPackageHash,
};
unsafe {
instance.get(StoredContractPackageHash::new)
}
}
}
impl ::protobuf::Clear for StoredContractPackageHash {
fn clear(&mut self) {
self.hash.clear();
self.optional_version = ::std::option::Option::None;
self.entry_point_name.clear();
self.args.clear();
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for StoredContractPackageHash {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for StoredContractPackageHash {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct Transfer {
pub args: ::std::vec::Vec<u8>,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a Transfer {
fn default() -> &'a Transfer {
<Transfer as ::protobuf::Message>::default_instance()
}
}
impl Transfer {
pub fn new() -> Transfer {
::std::default::Default::default()
}
pub fn get_args(&self) -> &[u8] {
&self.args
}
pub fn clear_args(&mut self) {
self.args.clear();
}
pub fn set_args(&mut self, v: ::std::vec::Vec<u8>) {
self.args = v;
}
pub fn mut_args(&mut self) -> &mut ::std::vec::Vec<u8> {
&mut self.args
}
pub fn take_args(&mut self) -> ::std::vec::Vec<u8> {
::std::mem::replace(&mut self.args, ::std::vec::Vec::new())
}
}
impl ::protobuf::Message for Transfer {
fn is_initialized(&self) -> bool {
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
::protobuf::rt::read_singular_proto3_bytes_into(wire_type, is, &mut self.args)?;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if !self.args.is_empty() {
my_size += ::protobuf::rt::bytes_size(1, &self.args);
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if !self.args.is_empty() {
os.write_bytes(1, &self.args)?;
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> Transfer {
Transfer::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
"args",
|m: &Transfer| { &m.args },
|m: &mut Transfer| { &mut m.args },
));
::protobuf::reflect::MessageDescriptor::new::<Transfer>(
"Transfer",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static Transfer {
static mut instance: ::protobuf::lazy::Lazy<Transfer> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const Transfer,
};
unsafe {
instance.get(Transfer::new)
}
}
}
impl ::protobuf::Clear for Transfer {
fn clear(&mut self) {
self.args.clear();
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for Transfer {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for Transfer {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct DeployPayload {
pub payload: ::std::option::Option<DeployPayload_oneof_payload>,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a DeployPayload {
fn default() -> &'a DeployPayload {
<DeployPayload as ::protobuf::Message>::default_instance()
}
}
#[derive(Clone,PartialEq,Debug)]
pub enum DeployPayload_oneof_payload {
deploy_code(DeployCode),
stored_contract_hash(StoredContractHash),
stored_contract_name(StoredContractName),
stored_package_by_name(StoredContractPackage),
stored_package_by_hash(StoredContractPackageHash),
transfer(Transfer),
}
impl DeployPayload {
pub fn new() -> DeployPayload {
::std::default::Default::default()
}
pub fn get_deploy_code(&self) -> &DeployCode {
match self.payload {
::std::option::Option::Some(DeployPayload_oneof_payload::deploy_code(ref v)) => v,
_ => DeployCode::default_instance(),
}
}
pub fn clear_deploy_code(&mut self) {
self.payload = ::std::option::Option::None;
}
pub fn has_deploy_code(&self) -> bool {
match self.payload {
::std::option::Option::Some(DeployPayload_oneof_payload::deploy_code(..)) => true,
_ => false,
}
}
pub fn set_deploy_code(&mut self, v: DeployCode) {
self.payload = ::std::option::Option::Some(DeployPayload_oneof_payload::deploy_code(v))
}
pub fn mut_deploy_code(&mut self) -> &mut DeployCode {
if let ::std::option::Option::Some(DeployPayload_oneof_payload::deploy_code(_)) = self.payload {
} else {
self.payload = ::std::option::Option::Some(DeployPayload_oneof_payload::deploy_code(DeployCode::new()));
}
match self.payload {
::std::option::Option::Some(DeployPayload_oneof_payload::deploy_code(ref mut v)) => v,
_ => panic!(),
}
}
pub fn take_deploy_code(&mut self) -> DeployCode {
if self.has_deploy_code() {
match self.payload.take() {
::std::option::Option::Some(DeployPayload_oneof_payload::deploy_code(v)) => v,
_ => panic!(),
}
} else {
DeployCode::new()
}
}
pub fn get_stored_contract_hash(&self) -> &StoredContractHash {
match self.payload {
::std::option::Option::Some(DeployPayload_oneof_payload::stored_contract_hash(ref v)) => v,
_ => StoredContractHash::default_instance(),
}
}
pub fn clear_stored_contract_hash(&mut self) {
self.payload = ::std::option::Option::None;
}
pub fn has_stored_contract_hash(&self) -> bool {
match self.payload {
::std::option::Option::Some(DeployPayload_oneof_payload::stored_contract_hash(..)) => true,
_ => false,
}
}
pub fn set_stored_contract_hash(&mut self, v: StoredContractHash) {
self.payload = ::std::option::Option::Some(DeployPayload_oneof_payload::stored_contract_hash(v))
}
pub fn mut_stored_contract_hash(&mut self) -> &mut StoredContractHash {
if let ::std::option::Option::Some(DeployPayload_oneof_payload::stored_contract_hash(_)) = self.payload {
} else {
self.payload = ::std::option::Option::Some(DeployPayload_oneof_payload::stored_contract_hash(StoredContractHash::new()));
}
match self.payload {
::std::option::Option::Some(DeployPayload_oneof_payload::stored_contract_hash(ref mut v)) => v,
_ => panic!(),
}
}
pub fn take_stored_contract_hash(&mut self) -> StoredContractHash {
if self.has_stored_contract_hash() {
match self.payload.take() {
::std::option::Option::Some(DeployPayload_oneof_payload::stored_contract_hash(v)) => v,
_ => panic!(),
}
} else {
StoredContractHash::new()
}
}
pub fn get_stored_contract_name(&self) -> &StoredContractName {
match self.payload {
::std::option::Option::Some(DeployPayload_oneof_payload::stored_contract_name(ref v)) => v,
_ => StoredContractName::default_instance(),
}
}
pub fn clear_stored_contract_name(&mut self) {
self.payload = ::std::option::Option::None;
}
pub fn has_stored_contract_name(&self) -> bool {
match self.payload {
::std::option::Option::Some(DeployPayload_oneof_payload::stored_contract_name(..)) => true,
_ => false,
}
}
pub fn set_stored_contract_name(&mut self, v: StoredContractName) {
self.payload = ::std::option::Option::Some(DeployPayload_oneof_payload::stored_contract_name(v))
}
pub fn mut_stored_contract_name(&mut self) -> &mut StoredContractName {
if let ::std::option::Option::Some(DeployPayload_oneof_payload::stored_contract_name(_)) = self.payload {
} else {
self.payload = ::std::option::Option::Some(DeployPayload_oneof_payload::stored_contract_name(StoredContractName::new()));
}
match self.payload {
::std::option::Option::Some(DeployPayload_oneof_payload::stored_contract_name(ref mut v)) => v,
_ => panic!(),
}
}
pub fn take_stored_contract_name(&mut self) -> StoredContractName {
if self.has_stored_contract_name() {
match self.payload.take() {
::std::option::Option::Some(DeployPayload_oneof_payload::stored_contract_name(v)) => v,
_ => panic!(),
}
} else {
StoredContractName::new()
}
}
pub fn get_stored_package_by_name(&self) -> &StoredContractPackage {
match self.payload {
::std::option::Option::Some(DeployPayload_oneof_payload::stored_package_by_name(ref v)) => v,
_ => StoredContractPackage::default_instance(),
}
}
pub fn clear_stored_package_by_name(&mut self) {
self.payload = ::std::option::Option::None;
}
pub fn has_stored_package_by_name(&self) -> bool {
match self.payload {
::std::option::Option::Some(DeployPayload_oneof_payload::stored_package_by_name(..)) => true,
_ => false,
}
}
pub fn set_stored_package_by_name(&mut self, v: StoredContractPackage) {
self.payload = ::std::option::Option::Some(DeployPayload_oneof_payload::stored_package_by_name(v))
}
pub fn mut_stored_package_by_name(&mut self) -> &mut StoredContractPackage {
if let ::std::option::Option::Some(DeployPayload_oneof_payload::stored_package_by_name(_)) = self.payload {
} else {
self.payload = ::std::option::Option::Some(DeployPayload_oneof_payload::stored_package_by_name(StoredContractPackage::new()));
}
match self.payload {
::std::option::Option::Some(DeployPayload_oneof_payload::stored_package_by_name(ref mut v)) => v,
_ => panic!(),
}
}
pub fn take_stored_package_by_name(&mut self) -> StoredContractPackage {
if self.has_stored_package_by_name() {
match self.payload.take() {
::std::option::Option::Some(DeployPayload_oneof_payload::stored_package_by_name(v)) => v,
_ => panic!(),
}
} else {
StoredContractPackage::new()
}
}
pub fn get_stored_package_by_hash(&self) -> &StoredContractPackageHash {
match self.payload {
::std::option::Option::Some(DeployPayload_oneof_payload::stored_package_by_hash(ref v)) => v,
_ => StoredContractPackageHash::default_instance(),
}
}
pub fn clear_stored_package_by_hash(&mut self) {
self.payload = ::std::option::Option::None;
}
pub fn has_stored_package_by_hash(&self) -> bool {
match self.payload {
::std::option::Option::Some(DeployPayload_oneof_payload::stored_package_by_hash(..)) => true,
_ => false,
}
}
pub fn set_stored_package_by_hash(&mut self, v: StoredContractPackageHash) {
self.payload = ::std::option::Option::Some(DeployPayload_oneof_payload::stored_package_by_hash(v))
}
pub fn mut_stored_package_by_hash(&mut self) -> &mut StoredContractPackageHash {
if let ::std::option::Option::Some(DeployPayload_oneof_payload::stored_package_by_hash(_)) = self.payload {
} else {
self.payload = ::std::option::Option::Some(DeployPayload_oneof_payload::stored_package_by_hash(StoredContractPackageHash::new()));
}
match self.payload {
::std::option::Option::Some(DeployPayload_oneof_payload::stored_package_by_hash(ref mut v)) => v,
_ => panic!(),
}
}
pub fn take_stored_package_by_hash(&mut self) -> StoredContractPackageHash {
if self.has_stored_package_by_hash() {
match self.payload.take() {
::std::option::Option::Some(DeployPayload_oneof_payload::stored_package_by_hash(v)) => v,
_ => panic!(),
}
} else {
StoredContractPackageHash::new()
}
}
pub fn get_transfer(&self) -> &Transfer {
match self.payload {
::std::option::Option::Some(DeployPayload_oneof_payload::transfer(ref v)) => v,
_ => Transfer::default_instance(),
}
}
pub fn clear_transfer(&mut self) {
self.payload = ::std::option::Option::None;
}
pub fn has_transfer(&self) -> bool {
match self.payload {
::std::option::Option::Some(DeployPayload_oneof_payload::transfer(..)) => true,
_ => false,
}
}
pub fn set_transfer(&mut self, v: Transfer) {
self.payload = ::std::option::Option::Some(DeployPayload_oneof_payload::transfer(v))
}
pub fn mut_transfer(&mut self) -> &mut Transfer {
if let ::std::option::Option::Some(DeployPayload_oneof_payload::transfer(_)) = self.payload {
} else {
self.payload = ::std::option::Option::Some(DeployPayload_oneof_payload::transfer(Transfer::new()));
}
match self.payload {
::std::option::Option::Some(DeployPayload_oneof_payload::transfer(ref mut v)) => v,
_ => panic!(),
}
}
pub fn take_transfer(&mut self) -> Transfer {
if self.has_transfer() {
match self.payload.take() {
::std::option::Option::Some(DeployPayload_oneof_payload::transfer(v)) => v,
_ => panic!(),
}
} else {
Transfer::new()
}
}
}
impl ::protobuf::Message for DeployPayload {
fn is_initialized(&self) -> bool {
if let Some(DeployPayload_oneof_payload::deploy_code(ref v)) = self.payload {
if !v.is_initialized() {
return false;
}
}
if let Some(DeployPayload_oneof_payload::stored_contract_hash(ref v)) = self.payload {
if !v.is_initialized() {
return false;
}
}
if let Some(DeployPayload_oneof_payload::stored_contract_name(ref v)) = self.payload {
if !v.is_initialized() {
return false;
}
}
if let Some(DeployPayload_oneof_payload::stored_package_by_name(ref v)) = self.payload {
if !v.is_initialized() {
return false;
}
}
if let Some(DeployPayload_oneof_payload::stored_package_by_hash(ref v)) = self.payload {
if !v.is_initialized() {
return false;
}
}
if let Some(DeployPayload_oneof_payload::transfer(ref v)) = self.payload {
if !v.is_initialized() {
return false;
}
}
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
if wire_type != ::protobuf::wire_format::WireTypeLengthDelimited {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
self.payload = ::std::option::Option::Some(DeployPayload_oneof_payload::deploy_code(is.read_message()?));
},
2 => {
if wire_type != ::protobuf::wire_format::WireTypeLengthDelimited {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
self.payload = ::std::option::Option::Some(DeployPayload_oneof_payload::stored_contract_hash(is.read_message()?));
},
3 => {
if wire_type != ::protobuf::wire_format::WireTypeLengthDelimited {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
self.payload = ::std::option::Option::Some(DeployPayload_oneof_payload::stored_contract_name(is.read_message()?));
},
5 => {
if wire_type != ::protobuf::wire_format::WireTypeLengthDelimited {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
self.payload = ::std::option::Option::Some(DeployPayload_oneof_payload::stored_package_by_name(is.read_message()?));
},
6 => {
if wire_type != ::protobuf::wire_format::WireTypeLengthDelimited {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
self.payload = ::std::option::Option::Some(DeployPayload_oneof_payload::stored_package_by_hash(is.read_message()?));
},
7 => {
if wire_type != ::protobuf::wire_format::WireTypeLengthDelimited {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
self.payload = ::std::option::Option::Some(DeployPayload_oneof_payload::transfer(is.read_message()?));
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if let ::std::option::Option::Some(ref v) = self.payload {
match v {
&DeployPayload_oneof_payload::deploy_code(ref v) => {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
},
&DeployPayload_oneof_payload::stored_contract_hash(ref v) => {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
},
&DeployPayload_oneof_payload::stored_contract_name(ref v) => {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
},
&DeployPayload_oneof_payload::stored_package_by_name(ref v) => {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
},
&DeployPayload_oneof_payload::stored_package_by_hash(ref v) => {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
},
&DeployPayload_oneof_payload::transfer(ref v) => {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
},
};
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if let ::std::option::Option::Some(ref v) = self.payload {
match v {
&DeployPayload_oneof_payload::deploy_code(ref v) => {
os.write_tag(1, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
},
&DeployPayload_oneof_payload::stored_contract_hash(ref v) => {
os.write_tag(2, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
},
&DeployPayload_oneof_payload::stored_contract_name(ref v) => {
os.write_tag(3, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
},
&DeployPayload_oneof_payload::stored_package_by_name(ref v) => {
os.write_tag(5, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
},
&DeployPayload_oneof_payload::stored_package_by_hash(ref v) => {
os.write_tag(6, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
},
&DeployPayload_oneof_payload::transfer(ref v) => {
os.write_tag(7, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
},
};
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> DeployPayload {
DeployPayload::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_singular_message_accessor::<_, DeployCode>(
"deploy_code",
DeployPayload::has_deploy_code,
DeployPayload::get_deploy_code,
));
fields.push(::protobuf::reflect::accessor::make_singular_message_accessor::<_, StoredContractHash>(
"stored_contract_hash",
DeployPayload::has_stored_contract_hash,
DeployPayload::get_stored_contract_hash,
));
fields.push(::protobuf::reflect::accessor::make_singular_message_accessor::<_, StoredContractName>(
"stored_contract_name",
DeployPayload::has_stored_contract_name,
DeployPayload::get_stored_contract_name,
));
fields.push(::protobuf::reflect::accessor::make_singular_message_accessor::<_, StoredContractPackage>(
"stored_package_by_name",
DeployPayload::has_stored_package_by_name,
DeployPayload::get_stored_package_by_name,
));
fields.push(::protobuf::reflect::accessor::make_singular_message_accessor::<_, StoredContractPackageHash>(
"stored_package_by_hash",
DeployPayload::has_stored_package_by_hash,
DeployPayload::get_stored_package_by_hash,
));
fields.push(::protobuf::reflect::accessor::make_singular_message_accessor::<_, Transfer>(
"transfer",
DeployPayload::has_transfer,
DeployPayload::get_transfer,
));
::protobuf::reflect::MessageDescriptor::new::<DeployPayload>(
"DeployPayload",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static DeployPayload {
static mut instance: ::protobuf::lazy::Lazy<DeployPayload> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const DeployPayload,
};
unsafe {
instance.get(DeployPayload::new)
}
}
}
impl ::protobuf::Clear for DeployPayload {
fn clear(&mut self) {
self.payload = ::std::option::Option::None;
self.payload = ::std::option::Option::None;
self.payload = ::std::option::Option::None;
self.payload = ::std::option::Option::None;
self.payload = ::std::option::Option::None;
self.payload = ::std::option::Option::None;
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for DeployPayload {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for DeployPayload {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct DeployItem {
pub address: ::std::vec::Vec<u8>,
pub session: ::protobuf::SingularPtrField<DeployPayload>,
pub payment: ::protobuf::SingularPtrField<DeployPayload>,
pub gas_price: u64,
pub authorization_keys: ::protobuf::RepeatedField<::std::vec::Vec<u8>>,
pub deploy_hash: ::std::vec::Vec<u8>,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a DeployItem {
fn default() -> &'a DeployItem {
<DeployItem as ::protobuf::Message>::default_instance()
}
}
impl DeployItem {
pub fn new() -> DeployItem {
::std::default::Default::default()
}
pub fn get_address(&self) -> &[u8] {
&self.address
}
pub fn clear_address(&mut self) {
self.address.clear();
}
pub fn set_address(&mut self, v: ::std::vec::Vec<u8>) {
self.address = v;
}
pub fn mut_address(&mut self) -> &mut ::std::vec::Vec<u8> {
&mut self.address
}
pub fn take_address(&mut self) -> ::std::vec::Vec<u8> {
::std::mem::replace(&mut self.address, ::std::vec::Vec::new())
}
pub fn get_session(&self) -> &DeployPayload {
self.session.as_ref().unwrap_or_else(|| DeployPayload::default_instance())
}
pub fn clear_session(&mut self) {
self.session.clear();
}
pub fn has_session(&self) -> bool {
self.session.is_some()
}
pub fn set_session(&mut self, v: DeployPayload) {
self.session = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_session(&mut self) -> &mut DeployPayload {
if self.session.is_none() {
self.session.set_default();
}
self.session.as_mut().unwrap()
}
pub fn take_session(&mut self) -> DeployPayload {
self.session.take().unwrap_or_else(|| DeployPayload::new())
}
pub fn get_payment(&self) -> &DeployPayload {
self.payment.as_ref().unwrap_or_else(|| DeployPayload::default_instance())
}
pub fn clear_payment(&mut self) {
self.payment.clear();
}
pub fn has_payment(&self) -> bool {
self.payment.is_some()
}
pub fn set_payment(&mut self, v: DeployPayload) {
self.payment = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_payment(&mut self) -> &mut DeployPayload {
if self.payment.is_none() {
self.payment.set_default();
}
self.payment.as_mut().unwrap()
}
pub fn take_payment(&mut self) -> DeployPayload {
self.payment.take().unwrap_or_else(|| DeployPayload::new())
}
pub fn get_gas_price(&self) -> u64 {
self.gas_price
}
pub fn clear_gas_price(&mut self) {
self.gas_price = 0;
}
pub fn set_gas_price(&mut self, v: u64) {
self.gas_price = v;
}
pub fn get_authorization_keys(&self) -> &[::std::vec::Vec<u8>] {
&self.authorization_keys
}
pub fn clear_authorization_keys(&mut self) {
self.authorization_keys.clear();
}
pub fn set_authorization_keys(&mut self, v: ::protobuf::RepeatedField<::std::vec::Vec<u8>>) {
self.authorization_keys = v;
}
pub fn mut_authorization_keys(&mut self) -> &mut ::protobuf::RepeatedField<::std::vec::Vec<u8>> {
&mut self.authorization_keys
}
pub fn take_authorization_keys(&mut self) -> ::protobuf::RepeatedField<::std::vec::Vec<u8>> {
::std::mem::replace(&mut self.authorization_keys, ::protobuf::RepeatedField::new())
}
pub fn get_deploy_hash(&self) -> &[u8] {
&self.deploy_hash
}
pub fn clear_deploy_hash(&mut self) {
self.deploy_hash.clear();
}
pub fn set_deploy_hash(&mut self, v: ::std::vec::Vec<u8>) {
self.deploy_hash = v;
}
pub fn mut_deploy_hash(&mut self) -> &mut ::std::vec::Vec<u8> {
&mut self.deploy_hash
}
pub fn take_deploy_hash(&mut self) -> ::std::vec::Vec<u8> {
::std::mem::replace(&mut self.deploy_hash, ::std::vec::Vec::new())
}
}
impl ::protobuf::Message for DeployItem {
fn is_initialized(&self) -> bool {
for v in &self.session {
if !v.is_initialized() {
return false;
}
};
for v in &self.payment {
if !v.is_initialized() {
return false;
}
};
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
::protobuf::rt::read_singular_proto3_bytes_into(wire_type, is, &mut self.address)?;
},
3 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.session)?;
},
4 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.payment)?;
},
6 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_uint64()?;
self.gas_price = tmp;
},
8 => {
::protobuf::rt::read_repeated_bytes_into(wire_type, is, &mut self.authorization_keys)?;
},
9 => {
::protobuf::rt::read_singular_proto3_bytes_into(wire_type, is, &mut self.deploy_hash)?;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if !self.address.is_empty() {
my_size += ::protobuf::rt::bytes_size(1, &self.address);
}
if let Some(ref v) = self.session.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.payment.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if self.gas_price != 0 {
my_size += ::protobuf::rt::value_size(6, self.gas_price, ::protobuf::wire_format::WireTypeVarint);
}
for value in &self.authorization_keys {
my_size += ::protobuf::rt::bytes_size(8, &value);
};
if !self.deploy_hash.is_empty() {
my_size += ::protobuf::rt::bytes_size(9, &self.deploy_hash);
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if !self.address.is_empty() {
os.write_bytes(1, &self.address)?;
}
if let Some(ref v) = self.session.as_ref() {
os.write_tag(3, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.payment.as_ref() {
os.write_tag(4, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if self.gas_price != 0 {
os.write_uint64(6, self.gas_price)?;
}
for v in &self.authorization_keys {
os.write_bytes(8, &v)?;
};
if !self.deploy_hash.is_empty() {
os.write_bytes(9, &self.deploy_hash)?;
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> DeployItem {
DeployItem::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
"address",
|m: &DeployItem| { &m.address },
|m: &mut DeployItem| { &mut m.address },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<DeployPayload>>(
"session",
|m: &DeployItem| { &m.session },
|m: &mut DeployItem| { &mut m.session },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<DeployPayload>>(
"payment",
|m: &DeployItem| { &m.payment },
|m: &mut DeployItem| { &mut m.payment },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeUint64>(
"gas_price",
|m: &DeployItem| { &m.gas_price },
|m: &mut DeployItem| { &mut m.gas_price },
));
fields.push(::protobuf::reflect::accessor::make_repeated_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
"authorization_keys",
|m: &DeployItem| { &m.authorization_keys },
|m: &mut DeployItem| { &mut m.authorization_keys },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
"deploy_hash",
|m: &DeployItem| { &m.deploy_hash },
|m: &mut DeployItem| { &mut m.deploy_hash },
));
::protobuf::reflect::MessageDescriptor::new::<DeployItem>(
"DeployItem",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static DeployItem {
static mut instance: ::protobuf::lazy::Lazy<DeployItem> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const DeployItem,
};
unsafe {
instance.get(DeployItem::new)
}
}
}
impl ::protobuf::Clear for DeployItem {
fn clear(&mut self) {
self.address.clear();
self.session.clear();
self.payment.clear();
self.gas_price = 0;
self.authorization_keys.clear();
self.deploy_hash.clear();
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for DeployItem {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for DeployItem {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct ExecuteRequest {
pub parent_state_hash: ::std::vec::Vec<u8>,
pub block_time: u64,
pub deploys: ::protobuf::RepeatedField<DeployItem>,
pub protocol_version: ::protobuf::SingularPtrField<super::state::ProtocolVersion>,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a ExecuteRequest {
fn default() -> &'a ExecuteRequest {
<ExecuteRequest as ::protobuf::Message>::default_instance()
}
}
impl ExecuteRequest {
pub fn new() -> ExecuteRequest {
::std::default::Default::default()
}
pub fn get_parent_state_hash(&self) -> &[u8] {
&self.parent_state_hash
}
pub fn clear_parent_state_hash(&mut self) {
self.parent_state_hash.clear();
}
pub fn set_parent_state_hash(&mut self, v: ::std::vec::Vec<u8>) {
self.parent_state_hash = v;
}
pub fn mut_parent_state_hash(&mut self) -> &mut ::std::vec::Vec<u8> {
&mut self.parent_state_hash
}
pub fn take_parent_state_hash(&mut self) -> ::std::vec::Vec<u8> {
::std::mem::replace(&mut self.parent_state_hash, ::std::vec::Vec::new())
}
pub fn get_block_time(&self) -> u64 {
self.block_time
}
pub fn clear_block_time(&mut self) {
self.block_time = 0;
}
pub fn set_block_time(&mut self, v: u64) {
self.block_time = v;
}
pub fn get_deploys(&self) -> &[DeployItem] {
&self.deploys
}
pub fn clear_deploys(&mut self) {
self.deploys.clear();
}
pub fn set_deploys(&mut self, v: ::protobuf::RepeatedField<DeployItem>) {
self.deploys = v;
}
pub fn mut_deploys(&mut self) -> &mut ::protobuf::RepeatedField<DeployItem> {
&mut self.deploys
}
pub fn take_deploys(&mut self) -> ::protobuf::RepeatedField<DeployItem> {
::std::mem::replace(&mut self.deploys, ::protobuf::RepeatedField::new())
}
pub fn get_protocol_version(&self) -> &super::state::ProtocolVersion {
self.protocol_version.as_ref().unwrap_or_else(|| super::state::ProtocolVersion::default_instance())
}
pub fn clear_protocol_version(&mut self) {
self.protocol_version.clear();
}
pub fn has_protocol_version(&self) -> bool {
self.protocol_version.is_some()
}
pub fn set_protocol_version(&mut self, v: super::state::ProtocolVersion) {
self.protocol_version = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_protocol_version(&mut self) -> &mut super::state::ProtocolVersion {
if self.protocol_version.is_none() {
self.protocol_version.set_default();
}
self.protocol_version.as_mut().unwrap()
}
pub fn take_protocol_version(&mut self) -> super::state::ProtocolVersion {
self.protocol_version.take().unwrap_or_else(|| super::state::ProtocolVersion::new())
}
}
impl ::protobuf::Message for ExecuteRequest {
fn is_initialized(&self) -> bool {
for v in &self.deploys {
if !v.is_initialized() {
return false;
}
};
for v in &self.protocol_version {
if !v.is_initialized() {
return false;
}
};
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
::protobuf::rt::read_singular_proto3_bytes_into(wire_type, is, &mut self.parent_state_hash)?;
},
2 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_uint64()?;
self.block_time = tmp;
},
3 => {
::protobuf::rt::read_repeated_message_into(wire_type, is, &mut self.deploys)?;
},
4 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.protocol_version)?;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if !self.parent_state_hash.is_empty() {
my_size += ::protobuf::rt::bytes_size(1, &self.parent_state_hash);
}
if self.block_time != 0 {
my_size += ::protobuf::rt::value_size(2, self.block_time, ::protobuf::wire_format::WireTypeVarint);
}
for value in &self.deploys {
let len = value.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
};
if let Some(ref v) = self.protocol_version.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if !self.parent_state_hash.is_empty() {
os.write_bytes(1, &self.parent_state_hash)?;
}
if self.block_time != 0 {
os.write_uint64(2, self.block_time)?;
}
for v in &self.deploys {
os.write_tag(3, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
};
if let Some(ref v) = self.protocol_version.as_ref() {
os.write_tag(4, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> ExecuteRequest {
ExecuteRequest::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
"parent_state_hash",
|m: &ExecuteRequest| { &m.parent_state_hash },
|m: &mut ExecuteRequest| { &mut m.parent_state_hash },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeUint64>(
"block_time",
|m: &ExecuteRequest| { &m.block_time },
|m: &mut ExecuteRequest| { &mut m.block_time },
));
fields.push(::protobuf::reflect::accessor::make_repeated_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<DeployItem>>(
"deploys",
|m: &ExecuteRequest| { &m.deploys },
|m: &mut ExecuteRequest| { &mut m.deploys },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<super::state::ProtocolVersion>>(
"protocol_version",
|m: &ExecuteRequest| { &m.protocol_version },
|m: &mut ExecuteRequest| { &mut m.protocol_version },
));
::protobuf::reflect::MessageDescriptor::new::<ExecuteRequest>(
"ExecuteRequest",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static ExecuteRequest {
static mut instance: ::protobuf::lazy::Lazy<ExecuteRequest> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ExecuteRequest,
};
unsafe {
instance.get(ExecuteRequest::new)
}
}
}
impl ::protobuf::Clear for ExecuteRequest {
fn clear(&mut self) {
self.parent_state_hash.clear();
self.block_time = 0;
self.deploys.clear();
self.protocol_version.clear();
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for ExecuteRequest {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for ExecuteRequest {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct ExecuteResponse {
pub result: ::std::option::Option<ExecuteResponse_oneof_result>,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a ExecuteResponse {
fn default() -> &'a ExecuteResponse {
<ExecuteResponse as ::protobuf::Message>::default_instance()
}
}
#[derive(Clone,PartialEq,Debug)]
pub enum ExecuteResponse_oneof_result {
success(ExecResult),
missing_parent(RootNotFound),
}
impl ExecuteResponse {
pub fn new() -> ExecuteResponse {
::std::default::Default::default()
}
pub fn get_success(&self) -> &ExecResult {
match self.result {
::std::option::Option::Some(ExecuteResponse_oneof_result::success(ref v)) => v,
_ => ExecResult::default_instance(),
}
}
pub fn clear_success(&mut self) {
self.result = ::std::option::Option::None;
}
pub fn has_success(&self) -> bool {
match self.result {
::std::option::Option::Some(ExecuteResponse_oneof_result::success(..)) => true,
_ => false,
}
}
pub fn set_success(&mut self, v: ExecResult) {
self.result = ::std::option::Option::Some(ExecuteResponse_oneof_result::success(v))
}
pub fn mut_success(&mut self) -> &mut ExecResult {
if let ::std::option::Option::Some(ExecuteResponse_oneof_result::success(_)) = self.result {
} else {
self.result = ::std::option::Option::Some(ExecuteResponse_oneof_result::success(ExecResult::new()));
}
match self.result {
::std::option::Option::Some(ExecuteResponse_oneof_result::success(ref mut v)) => v,
_ => panic!(),
}
}
pub fn take_success(&mut self) -> ExecResult {
if self.has_success() {
match self.result.take() {
::std::option::Option::Some(ExecuteResponse_oneof_result::success(v)) => v,
_ => panic!(),
}
} else {
ExecResult::new()
}
}
pub fn get_missing_parent(&self) -> &RootNotFound {
match self.result {
::std::option::Option::Some(ExecuteResponse_oneof_result::missing_parent(ref v)) => v,
_ => RootNotFound::default_instance(),
}
}
pub fn clear_missing_parent(&mut self) {
self.result = ::std::option::Option::None;
}
pub fn has_missing_parent(&self) -> bool {
match self.result {
::std::option::Option::Some(ExecuteResponse_oneof_result::missing_parent(..)) => true,
_ => false,
}
}
pub fn set_missing_parent(&mut self, v: RootNotFound) {
self.result = ::std::option::Option::Some(ExecuteResponse_oneof_result::missing_parent(v))
}
pub fn mut_missing_parent(&mut self) -> &mut RootNotFound {
if let ::std::option::Option::Some(ExecuteResponse_oneof_result::missing_parent(_)) = self.result {
} else {
self.result = ::std::option::Option::Some(ExecuteResponse_oneof_result::missing_parent(RootNotFound::new()));
}
match self.result {
::std::option::Option::Some(ExecuteResponse_oneof_result::missing_parent(ref mut v)) => v,
_ => panic!(),
}
}
pub fn take_missing_parent(&mut self) -> RootNotFound {
if self.has_missing_parent() {
match self.result.take() {
::std::option::Option::Some(ExecuteResponse_oneof_result::missing_parent(v)) => v,
_ => panic!(),
}
} else {
RootNotFound::new()
}
}
}
impl ::protobuf::Message for ExecuteResponse {
fn is_initialized(&self) -> bool {
if let Some(ExecuteResponse_oneof_result::success(ref v)) = self.result {
if !v.is_initialized() {
return false;
}
}
if let Some(ExecuteResponse_oneof_result::missing_parent(ref v)) = self.result {
if !v.is_initialized() {
return false;
}
}
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
if wire_type != ::protobuf::wire_format::WireTypeLengthDelimited {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
self.result = ::std::option::Option::Some(ExecuteResponse_oneof_result::success(is.read_message()?));
},
2 => {
if wire_type != ::protobuf::wire_format::WireTypeLengthDelimited {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
self.result = ::std::option::Option::Some(ExecuteResponse_oneof_result::missing_parent(is.read_message()?));
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if let ::std::option::Option::Some(ref v) = self.result {
match v {
&ExecuteResponse_oneof_result::success(ref v) => {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
},
&ExecuteResponse_oneof_result::missing_parent(ref v) => {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
},
};
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if let ::std::option::Option::Some(ref v) = self.result {
match v {
&ExecuteResponse_oneof_result::success(ref v) => {
os.write_tag(1, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
},
&ExecuteResponse_oneof_result::missing_parent(ref v) => {
os.write_tag(2, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
},
};
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> ExecuteResponse {
ExecuteResponse::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_singular_message_accessor::<_, ExecResult>(
"success",
ExecuteResponse::has_success,
ExecuteResponse::get_success,
));
fields.push(::protobuf::reflect::accessor::make_singular_message_accessor::<_, RootNotFound>(
"missing_parent",
ExecuteResponse::has_missing_parent,
ExecuteResponse::get_missing_parent,
));
::protobuf::reflect::MessageDescriptor::new::<ExecuteResponse>(
"ExecuteResponse",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static ExecuteResponse {
static mut instance: ::protobuf::lazy::Lazy<ExecuteResponse> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ExecuteResponse,
};
unsafe {
instance.get(ExecuteResponse::new)
}
}
}
impl ::protobuf::Clear for ExecuteResponse {
fn clear(&mut self) {
self.result = ::std::option::Option::None;
self.result = ::std::option::Option::None;
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for ExecuteResponse {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for ExecuteResponse {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct ExecResult {
pub deploy_results: ::protobuf::RepeatedField<DeployResult>,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a ExecResult {
fn default() -> &'a ExecResult {
<ExecResult as ::protobuf::Message>::default_instance()
}
}
impl ExecResult {
pub fn new() -> ExecResult {
::std::default::Default::default()
}
pub fn get_deploy_results(&self) -> &[DeployResult] {
&self.deploy_results
}
pub fn clear_deploy_results(&mut self) {
self.deploy_results.clear();
}
pub fn set_deploy_results(&mut self, v: ::protobuf::RepeatedField<DeployResult>) {
self.deploy_results = v;
}
pub fn mut_deploy_results(&mut self) -> &mut ::protobuf::RepeatedField<DeployResult> {
&mut self.deploy_results
}
pub fn take_deploy_results(&mut self) -> ::protobuf::RepeatedField<DeployResult> {
::std::mem::replace(&mut self.deploy_results, ::protobuf::RepeatedField::new())
}
}
impl ::protobuf::Message for ExecResult {
fn is_initialized(&self) -> bool {
for v in &self.deploy_results {
if !v.is_initialized() {
return false;
}
};
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
2 => {
::protobuf::rt::read_repeated_message_into(wire_type, is, &mut self.deploy_results)?;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
for value in &self.deploy_results {
let len = value.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
};
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
for v in &self.deploy_results {
os.write_tag(2, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
};
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> ExecResult {
ExecResult::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_repeated_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<DeployResult>>(
"deploy_results",
|m: &ExecResult| { &m.deploy_results },
|m: &mut ExecResult| { &mut m.deploy_results },
));
::protobuf::reflect::MessageDescriptor::new::<ExecResult>(
"ExecResult",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static ExecResult {
static mut instance: ::protobuf::lazy::Lazy<ExecResult> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ExecResult,
};
unsafe {
instance.get(ExecResult::new)
}
}
}
impl ::protobuf::Clear for ExecResult {
fn clear(&mut self) {
self.deploy_results.clear();
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for ExecResult {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for ExecResult {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct RootNotFound {
pub hash: ::std::vec::Vec<u8>,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a RootNotFound {
fn default() -> &'a RootNotFound {
<RootNotFound as ::protobuf::Message>::default_instance()
}
}
impl RootNotFound {
pub fn new() -> RootNotFound {
::std::default::Default::default()
}
pub fn get_hash(&self) -> &[u8] {
&self.hash
}
pub fn clear_hash(&mut self) {
self.hash.clear();
}
pub fn set_hash(&mut self, v: ::std::vec::Vec<u8>) {
self.hash = v;
}
pub fn mut_hash(&mut self) -> &mut ::std::vec::Vec<u8> {
&mut self.hash
}
pub fn take_hash(&mut self) -> ::std::vec::Vec<u8> {
::std::mem::replace(&mut self.hash, ::std::vec::Vec::new())
}
}
impl ::protobuf::Message for RootNotFound {
fn is_initialized(&self) -> bool {
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
::protobuf::rt::read_singular_proto3_bytes_into(wire_type, is, &mut self.hash)?;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if !self.hash.is_empty() {
my_size += ::protobuf::rt::bytes_size(1, &self.hash);
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if !self.hash.is_empty() {
os.write_bytes(1, &self.hash)?;
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> RootNotFound {
RootNotFound::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
"hash",
|m: &RootNotFound| { &m.hash },
|m: &mut RootNotFound| { &mut m.hash },
));
::protobuf::reflect::MessageDescriptor::new::<RootNotFound>(
"RootNotFound",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static RootNotFound {
static mut instance: ::protobuf::lazy::Lazy<RootNotFound> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const RootNotFound,
};
unsafe {
instance.get(RootNotFound::new)
}
}
}
impl ::protobuf::Clear for RootNotFound {
fn clear(&mut self) {
self.hash.clear();
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for RootNotFound {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for RootNotFound {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct CommitRequest {
pub prestate_hash: ::std::vec::Vec<u8>,
pub effects: ::protobuf::RepeatedField<super::transforms::TransformEntry>,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a CommitRequest {
fn default() -> &'a CommitRequest {
<CommitRequest as ::protobuf::Message>::default_instance()
}
}
impl CommitRequest {
pub fn new() -> CommitRequest {
::std::default::Default::default()
}
pub fn get_prestate_hash(&self) -> &[u8] {
&self.prestate_hash
}
pub fn clear_prestate_hash(&mut self) {
self.prestate_hash.clear();
}
pub fn set_prestate_hash(&mut self, v: ::std::vec::Vec<u8>) {
self.prestate_hash = v;
}
pub fn mut_prestate_hash(&mut self) -> &mut ::std::vec::Vec<u8> {
&mut self.prestate_hash
}
pub fn take_prestate_hash(&mut self) -> ::std::vec::Vec<u8> {
::std::mem::replace(&mut self.prestate_hash, ::std::vec::Vec::new())
}
pub fn get_effects(&self) -> &[super::transforms::TransformEntry] {
&self.effects
}
pub fn clear_effects(&mut self) {
self.effects.clear();
}
pub fn set_effects(&mut self, v: ::protobuf::RepeatedField<super::transforms::TransformEntry>) {
self.effects = v;
}
pub fn mut_effects(&mut self) -> &mut ::protobuf::RepeatedField<super::transforms::TransformEntry> {
&mut self.effects
}
pub fn take_effects(&mut self) -> ::protobuf::RepeatedField<super::transforms::TransformEntry> {
::std::mem::replace(&mut self.effects, ::protobuf::RepeatedField::new())
}
}
impl ::protobuf::Message for CommitRequest {
fn is_initialized(&self) -> bool {
for v in &self.effects {
if !v.is_initialized() {
return false;
}
};
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
::protobuf::rt::read_singular_proto3_bytes_into(wire_type, is, &mut self.prestate_hash)?;
},
2 => {
::protobuf::rt::read_repeated_message_into(wire_type, is, &mut self.effects)?;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if !self.prestate_hash.is_empty() {
my_size += ::protobuf::rt::bytes_size(1, &self.prestate_hash);
}
for value in &self.effects {
let len = value.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
};
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if !self.prestate_hash.is_empty() {
os.write_bytes(1, &self.prestate_hash)?;
}
for v in &self.effects {
os.write_tag(2, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
};
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> CommitRequest {
CommitRequest::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
"prestate_hash",
|m: &CommitRequest| { &m.prestate_hash },
|m: &mut CommitRequest| { &mut m.prestate_hash },
));
fields.push(::protobuf::reflect::accessor::make_repeated_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<super::transforms::TransformEntry>>(
"effects",
|m: &CommitRequest| { &m.effects },
|m: &mut CommitRequest| { &mut m.effects },
));
::protobuf::reflect::MessageDescriptor::new::<CommitRequest>(
"CommitRequest",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static CommitRequest {
static mut instance: ::protobuf::lazy::Lazy<CommitRequest> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const CommitRequest,
};
unsafe {
instance.get(CommitRequest::new)
}
}
}
impl ::protobuf::Clear for CommitRequest {
fn clear(&mut self) {
self.prestate_hash.clear();
self.effects.clear();
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for CommitRequest {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for CommitRequest {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct CommitResult {
pub poststate_hash: ::std::vec::Vec<u8>,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a CommitResult {
fn default() -> &'a CommitResult {
<CommitResult as ::protobuf::Message>::default_instance()
}
}
impl CommitResult {
pub fn new() -> CommitResult {
::std::default::Default::default()
}
pub fn get_poststate_hash(&self) -> &[u8] {
&self.poststate_hash
}
pub fn clear_poststate_hash(&mut self) {
self.poststate_hash.clear();
}
pub fn set_poststate_hash(&mut self, v: ::std::vec::Vec<u8>) {
self.poststate_hash = v;
}
pub fn mut_poststate_hash(&mut self) -> &mut ::std::vec::Vec<u8> {
&mut self.poststate_hash
}
pub fn take_poststate_hash(&mut self) -> ::std::vec::Vec<u8> {
::std::mem::replace(&mut self.poststate_hash, ::std::vec::Vec::new())
}
}
impl ::protobuf::Message for CommitResult {
fn is_initialized(&self) -> bool {
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
::protobuf::rt::read_singular_proto3_bytes_into(wire_type, is, &mut self.poststate_hash)?;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if !self.poststate_hash.is_empty() {
my_size += ::protobuf::rt::bytes_size(1, &self.poststate_hash);
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if !self.poststate_hash.is_empty() {
os.write_bytes(1, &self.poststate_hash)?;
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> CommitResult {
CommitResult::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
"poststate_hash",
|m: &CommitResult| { &m.poststate_hash },
|m: &mut CommitResult| { &mut m.poststate_hash },
));
::protobuf::reflect::MessageDescriptor::new::<CommitResult>(
"CommitResult",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static CommitResult {
static mut instance: ::protobuf::lazy::Lazy<CommitResult> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const CommitResult,
};
unsafe {
instance.get(CommitResult::new)
}
}
}
impl ::protobuf::Clear for CommitResult {
fn clear(&mut self) {
self.poststate_hash.clear();
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for CommitResult {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for CommitResult {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct CommitResponse {
pub result: ::std::option::Option<CommitResponse_oneof_result>,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a CommitResponse {
fn default() -> &'a CommitResponse {
<CommitResponse as ::protobuf::Message>::default_instance()
}
}
#[derive(Clone,PartialEq,Debug)]
pub enum CommitResponse_oneof_result {
success(CommitResult),
missing_prestate(RootNotFound),
key_not_found(super::state::Key),
type_mismatch(super::transforms::TypeMismatch),
failed_transform(PostEffectsError),
}
impl CommitResponse {
pub fn new() -> CommitResponse {
::std::default::Default::default()
}
pub fn get_success(&self) -> &CommitResult {
match self.result {
::std::option::Option::Some(CommitResponse_oneof_result::success(ref v)) => v,
_ => CommitResult::default_instance(),
}
}
pub fn clear_success(&mut self) {
self.result = ::std::option::Option::None;
}
pub fn has_success(&self) -> bool {
match self.result {
::std::option::Option::Some(CommitResponse_oneof_result::success(..)) => true,
_ => false,
}
}
pub fn set_success(&mut self, v: CommitResult) {
self.result = ::std::option::Option::Some(CommitResponse_oneof_result::success(v))
}
pub fn mut_success(&mut self) -> &mut CommitResult {
if let ::std::option::Option::Some(CommitResponse_oneof_result::success(_)) = self.result {
} else {
self.result = ::std::option::Option::Some(CommitResponse_oneof_result::success(CommitResult::new()));
}
match self.result {
::std::option::Option::Some(CommitResponse_oneof_result::success(ref mut v)) => v,
_ => panic!(),
}
}
pub fn take_success(&mut self) -> CommitResult {
if self.has_success() {
match self.result.take() {
::std::option::Option::Some(CommitResponse_oneof_result::success(v)) => v,
_ => panic!(),
}
} else {
CommitResult::new()
}
}
pub fn get_missing_prestate(&self) -> &RootNotFound {
match self.result {
::std::option::Option::Some(CommitResponse_oneof_result::missing_prestate(ref v)) => v,
_ => RootNotFound::default_instance(),
}
}
pub fn clear_missing_prestate(&mut self) {
self.result = ::std::option::Option::None;
}
pub fn has_missing_prestate(&self) -> bool {
match self.result {
::std::option::Option::Some(CommitResponse_oneof_result::missing_prestate(..)) => true,
_ => false,
}
}
pub fn set_missing_prestate(&mut self, v: RootNotFound) {
self.result = ::std::option::Option::Some(CommitResponse_oneof_result::missing_prestate(v))
}
pub fn mut_missing_prestate(&mut self) -> &mut RootNotFound {
if let ::std::option::Option::Some(CommitResponse_oneof_result::missing_prestate(_)) = self.result {
} else {
self.result = ::std::option::Option::Some(CommitResponse_oneof_result::missing_prestate(RootNotFound::new()));
}
match self.result {
::std::option::Option::Some(CommitResponse_oneof_result::missing_prestate(ref mut v)) => v,
_ => panic!(),
}
}
pub fn take_missing_prestate(&mut self) -> RootNotFound {
if self.has_missing_prestate() {
match self.result.take() {
::std::option::Option::Some(CommitResponse_oneof_result::missing_prestate(v)) => v,
_ => panic!(),
}
} else {
RootNotFound::new()
}
}
pub fn get_key_not_found(&self) -> &super::state::Key {
match self.result {
::std::option::Option::Some(CommitResponse_oneof_result::key_not_found(ref v)) => v,
_ => super::state::Key::default_instance(),
}
}
pub fn clear_key_not_found(&mut self) {
self.result = ::std::option::Option::None;
}
pub fn has_key_not_found(&self) -> bool {
match self.result {
::std::option::Option::Some(CommitResponse_oneof_result::key_not_found(..)) => true,
_ => false,
}
}
pub fn set_key_not_found(&mut self, v: super::state::Key) {
self.result = ::std::option::Option::Some(CommitResponse_oneof_result::key_not_found(v))
}
pub fn mut_key_not_found(&mut self) -> &mut super::state::Key {
if let ::std::option::Option::Some(CommitResponse_oneof_result::key_not_found(_)) = self.result {
} else {
self.result = ::std::option::Option::Some(CommitResponse_oneof_result::key_not_found(super::state::Key::new()));
}
match self.result {
::std::option::Option::Some(CommitResponse_oneof_result::key_not_found(ref mut v)) => v,
_ => panic!(),
}
}
pub fn take_key_not_found(&mut self) -> super::state::Key {
if self.has_key_not_found() {
match self.result.take() {
::std::option::Option::Some(CommitResponse_oneof_result::key_not_found(v)) => v,
_ => panic!(),
}
} else {
super::state::Key::new()
}
}
pub fn get_type_mismatch(&self) -> &super::transforms::TypeMismatch {
match self.result {
::std::option::Option::Some(CommitResponse_oneof_result::type_mismatch(ref v)) => v,
_ => super::transforms::TypeMismatch::default_instance(),
}
}
pub fn clear_type_mismatch(&mut self) {
self.result = ::std::option::Option::None;
}
pub fn has_type_mismatch(&self) -> bool {
match self.result {
::std::option::Option::Some(CommitResponse_oneof_result::type_mismatch(..)) => true,
_ => false,
}
}
pub fn set_type_mismatch(&mut self, v: super::transforms::TypeMismatch) {
self.result = ::std::option::Option::Some(CommitResponse_oneof_result::type_mismatch(v))
}
pub fn mut_type_mismatch(&mut self) -> &mut super::transforms::TypeMismatch {
if let ::std::option::Option::Some(CommitResponse_oneof_result::type_mismatch(_)) = self.result {
} else {
self.result = ::std::option::Option::Some(CommitResponse_oneof_result::type_mismatch(super::transforms::TypeMismatch::new()));
}
match self.result {
::std::option::Option::Some(CommitResponse_oneof_result::type_mismatch(ref mut v)) => v,
_ => panic!(),
}
}
pub fn take_type_mismatch(&mut self) -> super::transforms::TypeMismatch {
if self.has_type_mismatch() {
match self.result.take() {
::std::option::Option::Some(CommitResponse_oneof_result::type_mismatch(v)) => v,
_ => panic!(),
}
} else {
super::transforms::TypeMismatch::new()
}
}
pub fn get_failed_transform(&self) -> &PostEffectsError {
match self.result {
::std::option::Option::Some(CommitResponse_oneof_result::failed_transform(ref v)) => v,
_ => PostEffectsError::default_instance(),
}
}
pub fn clear_failed_transform(&mut self) {
self.result = ::std::option::Option::None;
}
pub fn has_failed_transform(&self) -> bool {
match self.result {
::std::option::Option::Some(CommitResponse_oneof_result::failed_transform(..)) => true,
_ => false,
}
}
pub fn set_failed_transform(&mut self, v: PostEffectsError) {
self.result = ::std::option::Option::Some(CommitResponse_oneof_result::failed_transform(v))
}
pub fn mut_failed_transform(&mut self) -> &mut PostEffectsError {
if let ::std::option::Option::Some(CommitResponse_oneof_result::failed_transform(_)) = self.result {
} else {
self.result = ::std::option::Option::Some(CommitResponse_oneof_result::failed_transform(PostEffectsError::new()));
}
match self.result {
::std::option::Option::Some(CommitResponse_oneof_result::failed_transform(ref mut v)) => v,
_ => panic!(),
}
}
pub fn take_failed_transform(&mut self) -> PostEffectsError {
if self.has_failed_transform() {
match self.result.take() {
::std::option::Option::Some(CommitResponse_oneof_result::failed_transform(v)) => v,
_ => panic!(),
}
} else {
PostEffectsError::new()
}
}
}
impl ::protobuf::Message for CommitResponse {
fn is_initialized(&self) -> bool {
if let Some(CommitResponse_oneof_result::success(ref v)) = self.result {
if !v.is_initialized() {
return false;
}
}
if let Some(CommitResponse_oneof_result::missing_prestate(ref v)) = self.result {
if !v.is_initialized() {
return false;
}
}
if let Some(CommitResponse_oneof_result::key_not_found(ref v)) = self.result {
if !v.is_initialized() {
return false;
}
}
if let Some(CommitResponse_oneof_result::type_mismatch(ref v)) = self.result {
if !v.is_initialized() {
return false;
}
}
if let Some(CommitResponse_oneof_result::failed_transform(ref v)) = self.result {
if !v.is_initialized() {
return false;
}
}
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
if wire_type != ::protobuf::wire_format::WireTypeLengthDelimited {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
self.result = ::std::option::Option::Some(CommitResponse_oneof_result::success(is.read_message()?));
},
2 => {
if wire_type != ::protobuf::wire_format::WireTypeLengthDelimited {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
self.result = ::std::option::Option::Some(CommitResponse_oneof_result::missing_prestate(is.read_message()?));
},
3 => {
if wire_type != ::protobuf::wire_format::WireTypeLengthDelimited {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
self.result = ::std::option::Option::Some(CommitResponse_oneof_result::key_not_found(is.read_message()?));
},
4 => {
if wire_type != ::protobuf::wire_format::WireTypeLengthDelimited {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
self.result = ::std::option::Option::Some(CommitResponse_oneof_result::type_mismatch(is.read_message()?));
},
5 => {
if wire_type != ::protobuf::wire_format::WireTypeLengthDelimited {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
self.result = ::std::option::Option::Some(CommitResponse_oneof_result::failed_transform(is.read_message()?));
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if let ::std::option::Option::Some(ref v) = self.result {
match v {
&CommitResponse_oneof_result::success(ref v) => {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
},
&CommitResponse_oneof_result::missing_prestate(ref v) => {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
},
&CommitResponse_oneof_result::key_not_found(ref v) => {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
},
&CommitResponse_oneof_result::type_mismatch(ref v) => {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
},
&CommitResponse_oneof_result::failed_transform(ref v) => {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
},
};
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if let ::std::option::Option::Some(ref v) = self.result {
match v {
&CommitResponse_oneof_result::success(ref v) => {
os.write_tag(1, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
},
&CommitResponse_oneof_result::missing_prestate(ref v) => {
os.write_tag(2, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
},
&CommitResponse_oneof_result::key_not_found(ref v) => {
os.write_tag(3, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
},
&CommitResponse_oneof_result::type_mismatch(ref v) => {
os.write_tag(4, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
},
&CommitResponse_oneof_result::failed_transform(ref v) => {
os.write_tag(5, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
},
};
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> CommitResponse {
CommitResponse::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_singular_message_accessor::<_, CommitResult>(
"success",
CommitResponse::has_success,
CommitResponse::get_success,
));
fields.push(::protobuf::reflect::accessor::make_singular_message_accessor::<_, RootNotFound>(
"missing_prestate",
CommitResponse::has_missing_prestate,
CommitResponse::get_missing_prestate,
));
fields.push(::protobuf::reflect::accessor::make_singular_message_accessor::<_, super::state::Key>(
"key_not_found",
CommitResponse::has_key_not_found,
CommitResponse::get_key_not_found,
));
fields.push(::protobuf::reflect::accessor::make_singular_message_accessor::<_, super::transforms::TypeMismatch>(
"type_mismatch",
CommitResponse::has_type_mismatch,
CommitResponse::get_type_mismatch,
));
fields.push(::protobuf::reflect::accessor::make_singular_message_accessor::<_, PostEffectsError>(
"failed_transform",
CommitResponse::has_failed_transform,
CommitResponse::get_failed_transform,
));
::protobuf::reflect::MessageDescriptor::new::<CommitResponse>(
"CommitResponse",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static CommitResponse {
static mut instance: ::protobuf::lazy::Lazy<CommitResponse> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const CommitResponse,
};
unsafe {
instance.get(CommitResponse::new)
}
}
}
impl ::protobuf::Clear for CommitResponse {
fn clear(&mut self) {
self.result = ::std::option::Option::None;
self.result = ::std::option::Option::None;
self.result = ::std::option::Option::None;
self.result = ::std::option::Option::None;
self.result = ::std::option::Option::None;
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for CommitResponse {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for CommitResponse {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct Op {
pub op_instance: ::std::option::Option<Op_oneof_op_instance>,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a Op {
fn default() -> &'a Op {
<Op as ::protobuf::Message>::default_instance()
}
}
#[derive(Clone,PartialEq,Debug)]
pub enum Op_oneof_op_instance {
read(ReadOp),
write(WriteOp),
add(AddOp),
noop(NoOp),
}
impl Op {
pub fn new() -> Op {
::std::default::Default::default()
}
pub fn get_read(&self) -> &ReadOp {
match self.op_instance {
::std::option::Option::Some(Op_oneof_op_instance::read(ref v)) => v,
_ => ReadOp::default_instance(),
}
}
pub fn clear_read(&mut self) {
self.op_instance = ::std::option::Option::None;
}
pub fn has_read(&self) -> bool {
match self.op_instance {
::std::option::Option::Some(Op_oneof_op_instance::read(..)) => true,
_ => false,
}
}
pub fn set_read(&mut self, v: ReadOp) {
self.op_instance = ::std::option::Option::Some(Op_oneof_op_instance::read(v))
}
pub fn mut_read(&mut self) -> &mut ReadOp {
if let ::std::option::Option::Some(Op_oneof_op_instance::read(_)) = self.op_instance {
} else {
self.op_instance = ::std::option::Option::Some(Op_oneof_op_instance::read(ReadOp::new()));
}
match self.op_instance {
::std::option::Option::Some(Op_oneof_op_instance::read(ref mut v)) => v,
_ => panic!(),
}
}
pub fn take_read(&mut self) -> ReadOp {
if self.has_read() {
match self.op_instance.take() {
::std::option::Option::Some(Op_oneof_op_instance::read(v)) => v,
_ => panic!(),
}
} else {
ReadOp::new()
}
}
pub fn get_write(&self) -> &WriteOp {
match self.op_instance {
::std::option::Option::Some(Op_oneof_op_instance::write(ref v)) => v,
_ => WriteOp::default_instance(),
}
}
pub fn clear_write(&mut self) {
self.op_instance = ::std::option::Option::None;
}
pub fn has_write(&self) -> bool {
match self.op_instance {
::std::option::Option::Some(Op_oneof_op_instance::write(..)) => true,
_ => false,
}
}
pub fn set_write(&mut self, v: WriteOp) {
self.op_instance = ::std::option::Option::Some(Op_oneof_op_instance::write(v))
}
pub fn mut_write(&mut self) -> &mut WriteOp {
if let ::std::option::Option::Some(Op_oneof_op_instance::write(_)) = self.op_instance {
} else {
self.op_instance = ::std::option::Option::Some(Op_oneof_op_instance::write(WriteOp::new()));
}
match self.op_instance {
::std::option::Option::Some(Op_oneof_op_instance::write(ref mut v)) => v,
_ => panic!(),
}
}
pub fn take_write(&mut self) -> WriteOp {
if self.has_write() {
match self.op_instance.take() {
::std::option::Option::Some(Op_oneof_op_instance::write(v)) => v,
_ => panic!(),
}
} else {
WriteOp::new()
}
}
pub fn get_add(&self) -> &AddOp {
match self.op_instance {
::std::option::Option::Some(Op_oneof_op_instance::add(ref v)) => v,
_ => AddOp::default_instance(),
}
}
pub fn clear_add(&mut self) {
self.op_instance = ::std::option::Option::None;
}
pub fn has_add(&self) -> bool {
match self.op_instance {
::std::option::Option::Some(Op_oneof_op_instance::add(..)) => true,
_ => false,
}
}
pub fn set_add(&mut self, v: AddOp) {
self.op_instance = ::std::option::Option::Some(Op_oneof_op_instance::add(v))
}
pub fn mut_add(&mut self) -> &mut AddOp {
if let ::std::option::Option::Some(Op_oneof_op_instance::add(_)) = self.op_instance {
} else {
self.op_instance = ::std::option::Option::Some(Op_oneof_op_instance::add(AddOp::new()));
}
match self.op_instance {
::std::option::Option::Some(Op_oneof_op_instance::add(ref mut v)) => v,
_ => panic!(),
}
}
pub fn take_add(&mut self) -> AddOp {
if self.has_add() {
match self.op_instance.take() {
::std::option::Option::Some(Op_oneof_op_instance::add(v)) => v,
_ => panic!(),
}
} else {
AddOp::new()
}
}
pub fn get_noop(&self) -> &NoOp {
match self.op_instance {
::std::option::Option::Some(Op_oneof_op_instance::noop(ref v)) => v,
_ => NoOp::default_instance(),
}
}
pub fn clear_noop(&mut self) {
self.op_instance = ::std::option::Option::None;
}
pub fn has_noop(&self) -> bool {
match self.op_instance {
::std::option::Option::Some(Op_oneof_op_instance::noop(..)) => true,
_ => false,
}
}
pub fn set_noop(&mut self, v: NoOp) {
self.op_instance = ::std::option::Option::Some(Op_oneof_op_instance::noop(v))
}
pub fn mut_noop(&mut self) -> &mut NoOp {
if let ::std::option::Option::Some(Op_oneof_op_instance::noop(_)) = self.op_instance {
} else {
self.op_instance = ::std::option::Option::Some(Op_oneof_op_instance::noop(NoOp::new()));
}
match self.op_instance {
::std::option::Option::Some(Op_oneof_op_instance::noop(ref mut v)) => v,
_ => panic!(),
}
}
pub fn take_noop(&mut self) -> NoOp {
if self.has_noop() {
match self.op_instance.take() {
::std::option::Option::Some(Op_oneof_op_instance::noop(v)) => v,
_ => panic!(),
}
} else {
NoOp::new()
}
}
}
impl ::protobuf::Message for Op {
fn is_initialized(&self) -> bool {
if let Some(Op_oneof_op_instance::read(ref v)) = self.op_instance {
if !v.is_initialized() {
return false;
}
}
if let Some(Op_oneof_op_instance::write(ref v)) = self.op_instance {
if !v.is_initialized() {
return false;
}
}
if let Some(Op_oneof_op_instance::add(ref v)) = self.op_instance {
if !v.is_initialized() {
return false;
}
}
if let Some(Op_oneof_op_instance::noop(ref v)) = self.op_instance {
if !v.is_initialized() {
return false;
}
}
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
if wire_type != ::protobuf::wire_format::WireTypeLengthDelimited {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
self.op_instance = ::std::option::Option::Some(Op_oneof_op_instance::read(is.read_message()?));
},
2 => {
if wire_type != ::protobuf::wire_format::WireTypeLengthDelimited {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
self.op_instance = ::std::option::Option::Some(Op_oneof_op_instance::write(is.read_message()?));
},
3 => {
if wire_type != ::protobuf::wire_format::WireTypeLengthDelimited {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
self.op_instance = ::std::option::Option::Some(Op_oneof_op_instance::add(is.read_message()?));
},
4 => {
if wire_type != ::protobuf::wire_format::WireTypeLengthDelimited {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
self.op_instance = ::std::option::Option::Some(Op_oneof_op_instance::noop(is.read_message()?));
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if let ::std::option::Option::Some(ref v) = self.op_instance {
match v {
&Op_oneof_op_instance::read(ref v) => {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
},
&Op_oneof_op_instance::write(ref v) => {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
},
&Op_oneof_op_instance::add(ref v) => {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
},
&Op_oneof_op_instance::noop(ref v) => {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
},
};
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if let ::std::option::Option::Some(ref v) = self.op_instance {
match v {
&Op_oneof_op_instance::read(ref v) => {
os.write_tag(1, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
},
&Op_oneof_op_instance::write(ref v) => {
os.write_tag(2, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
},
&Op_oneof_op_instance::add(ref v) => {
os.write_tag(3, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
},
&Op_oneof_op_instance::noop(ref v) => {
os.write_tag(4, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
},
};
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> Op {
Op::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_singular_message_accessor::<_, ReadOp>(
"read",
Op::has_read,
Op::get_read,
));
fields.push(::protobuf::reflect::accessor::make_singular_message_accessor::<_, WriteOp>(
"write",
Op::has_write,
Op::get_write,
));
fields.push(::protobuf::reflect::accessor::make_singular_message_accessor::<_, AddOp>(
"add",
Op::has_add,
Op::get_add,
));
fields.push(::protobuf::reflect::accessor::make_singular_message_accessor::<_, NoOp>(
"noop",
Op::has_noop,
Op::get_noop,
));
::protobuf::reflect::MessageDescriptor::new::<Op>(
"Op",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static Op {
static mut instance: ::protobuf::lazy::Lazy<Op> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const Op,
};
unsafe {
instance.get(Op::new)
}
}
}
impl ::protobuf::Clear for Op {
fn clear(&mut self) {
self.op_instance = ::std::option::Option::None;
self.op_instance = ::std::option::Option::None;
self.op_instance = ::std::option::Option::None;
self.op_instance = ::std::option::Option::None;
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for Op {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for Op {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct ReadOp {
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a ReadOp {
fn default() -> &'a ReadOp {
<ReadOp as ::protobuf::Message>::default_instance()
}
}
impl ReadOp {
pub fn new() -> ReadOp {
::std::default::Default::default()
}
}
impl ::protobuf::Message for ReadOp {
fn is_initialized(&self) -> bool {
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> ReadOp {
ReadOp::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let fields = ::std::vec::Vec::new();
::protobuf::reflect::MessageDescriptor::new::<ReadOp>(
"ReadOp",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static ReadOp {
static mut instance: ::protobuf::lazy::Lazy<ReadOp> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ReadOp,
};
unsafe {
instance.get(ReadOp::new)
}
}
}
impl ::protobuf::Clear for ReadOp {
fn clear(&mut self) {
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for ReadOp {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for ReadOp {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct WriteOp {
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a WriteOp {
fn default() -> &'a WriteOp {
<WriteOp as ::protobuf::Message>::default_instance()
}
}
impl WriteOp {
pub fn new() -> WriteOp {
::std::default::Default::default()
}
}
impl ::protobuf::Message for WriteOp {
fn is_initialized(&self) -> bool {
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> WriteOp {
WriteOp::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let fields = ::std::vec::Vec::new();
::protobuf::reflect::MessageDescriptor::new::<WriteOp>(
"WriteOp",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static WriteOp {
static mut instance: ::protobuf::lazy::Lazy<WriteOp> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const WriteOp,
};
unsafe {
instance.get(WriteOp::new)
}
}
}
impl ::protobuf::Clear for WriteOp {
fn clear(&mut self) {
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for WriteOp {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for WriteOp {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct AddOp {
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a AddOp {
fn default() -> &'a AddOp {
<AddOp as ::protobuf::Message>::default_instance()
}
}
impl AddOp {
pub fn new() -> AddOp {
::std::default::Default::default()
}
}
impl ::protobuf::Message for AddOp {
fn is_initialized(&self) -> bool {
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> AddOp {
AddOp::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let fields = ::std::vec::Vec::new();
::protobuf::reflect::MessageDescriptor::new::<AddOp>(
"AddOp",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static AddOp {
static mut instance: ::protobuf::lazy::Lazy<AddOp> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const AddOp,
};
unsafe {
instance.get(AddOp::new)
}
}
}
impl ::protobuf::Clear for AddOp {
fn clear(&mut self) {
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for AddOp {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for AddOp {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct NoOp {
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a NoOp {
fn default() -> &'a NoOp {
<NoOp as ::protobuf::Message>::default_instance()
}
}
impl NoOp {
pub fn new() -> NoOp {
::std::default::Default::default()
}
}
impl ::protobuf::Message for NoOp {
fn is_initialized(&self) -> bool {
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> NoOp {
NoOp::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let fields = ::std::vec::Vec::new();
::protobuf::reflect::MessageDescriptor::new::<NoOp>(
"NoOp",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static NoOp {
static mut instance: ::protobuf::lazy::Lazy<NoOp> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const NoOp,
};
unsafe {
instance.get(NoOp::new)
}
}
}
impl ::protobuf::Clear for NoOp {
fn clear(&mut self) {
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for NoOp {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for NoOp {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct StorageError {
pub error_instance: ::std::option::Option<StorageError_oneof_error_instance>,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a StorageError {
fn default() -> &'a StorageError {
<StorageError as ::protobuf::Message>::default_instance()
}
}
#[derive(Clone,PartialEq,Debug)]
pub enum StorageError_oneof_error_instance {
bytes_repr(BytesReprError),
rkv(RkvError),
}
impl StorageError {
pub fn new() -> StorageError {
::std::default::Default::default()
}
pub fn get_bytes_repr(&self) -> &BytesReprError {
match self.error_instance {
::std::option::Option::Some(StorageError_oneof_error_instance::bytes_repr(ref v)) => v,
_ => BytesReprError::default_instance(),
}
}
pub fn clear_bytes_repr(&mut self) {
self.error_instance = ::std::option::Option::None;
}
pub fn has_bytes_repr(&self) -> bool {
match self.error_instance {
::std::option::Option::Some(StorageError_oneof_error_instance::bytes_repr(..)) => true,
_ => false,
}
}
pub fn set_bytes_repr(&mut self, v: BytesReprError) {
self.error_instance = ::std::option::Option::Some(StorageError_oneof_error_instance::bytes_repr(v))
}
pub fn mut_bytes_repr(&mut self) -> &mut BytesReprError {
if let ::std::option::Option::Some(StorageError_oneof_error_instance::bytes_repr(_)) = self.error_instance {
} else {
self.error_instance = ::std::option::Option::Some(StorageError_oneof_error_instance::bytes_repr(BytesReprError::new()));
}
match self.error_instance {
::std::option::Option::Some(StorageError_oneof_error_instance::bytes_repr(ref mut v)) => v,
_ => panic!(),
}
}
pub fn take_bytes_repr(&mut self) -> BytesReprError {
if self.has_bytes_repr() {
match self.error_instance.take() {
::std::option::Option::Some(StorageError_oneof_error_instance::bytes_repr(v)) => v,
_ => panic!(),
}
} else {
BytesReprError::new()
}
}
pub fn get_rkv(&self) -> &RkvError {
match self.error_instance {
::std::option::Option::Some(StorageError_oneof_error_instance::rkv(ref v)) => v,
_ => RkvError::default_instance(),
}
}
pub fn clear_rkv(&mut self) {
self.error_instance = ::std::option::Option::None;
}
pub fn has_rkv(&self) -> bool {
match self.error_instance {
::std::option::Option::Some(StorageError_oneof_error_instance::rkv(..)) => true,
_ => false,
}
}
pub fn set_rkv(&mut self, v: RkvError) {
self.error_instance = ::std::option::Option::Some(StorageError_oneof_error_instance::rkv(v))
}
pub fn mut_rkv(&mut self) -> &mut RkvError {
if let ::std::option::Option::Some(StorageError_oneof_error_instance::rkv(_)) = self.error_instance {
} else {
self.error_instance = ::std::option::Option::Some(StorageError_oneof_error_instance::rkv(RkvError::new()));
}
match self.error_instance {
::std::option::Option::Some(StorageError_oneof_error_instance::rkv(ref mut v)) => v,
_ => panic!(),
}
}
pub fn take_rkv(&mut self) -> RkvError {
if self.has_rkv() {
match self.error_instance.take() {
::std::option::Option::Some(StorageError_oneof_error_instance::rkv(v)) => v,
_ => panic!(),
}
} else {
RkvError::new()
}
}
}
impl ::protobuf::Message for StorageError {
fn is_initialized(&self) -> bool {
if let Some(StorageError_oneof_error_instance::bytes_repr(ref v)) = self.error_instance {
if !v.is_initialized() {
return false;
}
}
if let Some(StorageError_oneof_error_instance::rkv(ref v)) = self.error_instance {
if !v.is_initialized() {
return false;
}
}
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
if wire_type != ::protobuf::wire_format::WireTypeLengthDelimited {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
self.error_instance = ::std::option::Option::Some(StorageError_oneof_error_instance::bytes_repr(is.read_message()?));
},
2 => {
if wire_type != ::protobuf::wire_format::WireTypeLengthDelimited {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
self.error_instance = ::std::option::Option::Some(StorageError_oneof_error_instance::rkv(is.read_message()?));
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if let ::std::option::Option::Some(ref v) = self.error_instance {
match v {
&StorageError_oneof_error_instance::bytes_repr(ref v) => {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
},
&StorageError_oneof_error_instance::rkv(ref v) => {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
},
};
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if let ::std::option::Option::Some(ref v) = self.error_instance {
match v {
&StorageError_oneof_error_instance::bytes_repr(ref v) => {
os.write_tag(1, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
},
&StorageError_oneof_error_instance::rkv(ref v) => {
os.write_tag(2, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
},
};
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> StorageError {
StorageError::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_singular_message_accessor::<_, BytesReprError>(
"bytes_repr",
StorageError::has_bytes_repr,
StorageError::get_bytes_repr,
));
fields.push(::protobuf::reflect::accessor::make_singular_message_accessor::<_, RkvError>(
"rkv",
StorageError::has_rkv,
StorageError::get_rkv,
));
::protobuf::reflect::MessageDescriptor::new::<StorageError>(
"StorageError",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static StorageError {
static mut instance: ::protobuf::lazy::Lazy<StorageError> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const StorageError,
};
unsafe {
instance.get(StorageError::new)
}
}
}
impl ::protobuf::Clear for StorageError {
fn clear(&mut self) {
self.error_instance = ::std::option::Option::None;
self.error_instance = ::std::option::Option::None;
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for StorageError {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for StorageError {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct BytesReprError {
pub error_instance: ::std::option::Option<BytesReprError_oneof_error_instance>,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a BytesReprError {
fn default() -> &'a BytesReprError {
<BytesReprError as ::protobuf::Message>::default_instance()
}
}
#[derive(Clone,PartialEq,Debug)]
pub enum BytesReprError_oneof_error_instance {
early_end(EarlyEndOfStream),
formatting(FormattingError),
left_over(LeftOverBytes),
}
impl BytesReprError {
pub fn new() -> BytesReprError {
::std::default::Default::default()
}
pub fn get_early_end(&self) -> &EarlyEndOfStream {
match self.error_instance {
::std::option::Option::Some(BytesReprError_oneof_error_instance::early_end(ref v)) => v,
_ => EarlyEndOfStream::default_instance(),
}
}
pub fn clear_early_end(&mut self) {
self.error_instance = ::std::option::Option::None;
}
pub fn has_early_end(&self) -> bool {
match self.error_instance {
::std::option::Option::Some(BytesReprError_oneof_error_instance::early_end(..)) => true,
_ => false,
}
}
pub fn set_early_end(&mut self, v: EarlyEndOfStream) {
self.error_instance = ::std::option::Option::Some(BytesReprError_oneof_error_instance::early_end(v))
}
pub fn mut_early_end(&mut self) -> &mut EarlyEndOfStream {
if let ::std::option::Option::Some(BytesReprError_oneof_error_instance::early_end(_)) = self.error_instance {
} else {
self.error_instance = ::std::option::Option::Some(BytesReprError_oneof_error_instance::early_end(EarlyEndOfStream::new()));
}
match self.error_instance {
::std::option::Option::Some(BytesReprError_oneof_error_instance::early_end(ref mut v)) => v,
_ => panic!(),
}
}
pub fn take_early_end(&mut self) -> EarlyEndOfStream {
if self.has_early_end() {
match self.error_instance.take() {
::std::option::Option::Some(BytesReprError_oneof_error_instance::early_end(v)) => v,
_ => panic!(),
}
} else {
EarlyEndOfStream::new()
}
}
pub fn get_formatting(&self) -> &FormattingError {
match self.error_instance {
::std::option::Option::Some(BytesReprError_oneof_error_instance::formatting(ref v)) => v,
_ => FormattingError::default_instance(),
}
}
pub fn clear_formatting(&mut self) {
self.error_instance = ::std::option::Option::None;
}
pub fn has_formatting(&self) -> bool {
match self.error_instance {
::std::option::Option::Some(BytesReprError_oneof_error_instance::formatting(..)) => true,
_ => false,
}
}
pub fn set_formatting(&mut self, v: FormattingError) {
self.error_instance = ::std::option::Option::Some(BytesReprError_oneof_error_instance::formatting(v))
}
pub fn mut_formatting(&mut self) -> &mut FormattingError {
if let ::std::option::Option::Some(BytesReprError_oneof_error_instance::formatting(_)) = self.error_instance {
} else {
self.error_instance = ::std::option::Option::Some(BytesReprError_oneof_error_instance::formatting(FormattingError::new()));
}
match self.error_instance {
::std::option::Option::Some(BytesReprError_oneof_error_instance::formatting(ref mut v)) => v,
_ => panic!(),
}
}
pub fn take_formatting(&mut self) -> FormattingError {
if self.has_formatting() {
match self.error_instance.take() {
::std::option::Option::Some(BytesReprError_oneof_error_instance::formatting(v)) => v,
_ => panic!(),
}
} else {
FormattingError::new()
}
}
pub fn get_left_over(&self) -> &LeftOverBytes {
match self.error_instance {
::std::option::Option::Some(BytesReprError_oneof_error_instance::left_over(ref v)) => v,
_ => LeftOverBytes::default_instance(),
}
}
pub fn clear_left_over(&mut self) {
self.error_instance = ::std::option::Option::None;
}
pub fn has_left_over(&self) -> bool {
match self.error_instance {
::std::option::Option::Some(BytesReprError_oneof_error_instance::left_over(..)) => true,
_ => false,
}
}
pub fn set_left_over(&mut self, v: LeftOverBytes) {
self.error_instance = ::std::option::Option::Some(BytesReprError_oneof_error_instance::left_over(v))
}
pub fn mut_left_over(&mut self) -> &mut LeftOverBytes {
if let ::std::option::Option::Some(BytesReprError_oneof_error_instance::left_over(_)) = self.error_instance {
} else {
self.error_instance = ::std::option::Option::Some(BytesReprError_oneof_error_instance::left_over(LeftOverBytes::new()));
}
match self.error_instance {
::std::option::Option::Some(BytesReprError_oneof_error_instance::left_over(ref mut v)) => v,
_ => panic!(),
}
}
pub fn take_left_over(&mut self) -> LeftOverBytes {
if self.has_left_over() {
match self.error_instance.take() {
::std::option::Option::Some(BytesReprError_oneof_error_instance::left_over(v)) => v,
_ => panic!(),
}
} else {
LeftOverBytes::new()
}
}
}
impl ::protobuf::Message for BytesReprError {
fn is_initialized(&self) -> bool {
if let Some(BytesReprError_oneof_error_instance::early_end(ref v)) = self.error_instance {
if !v.is_initialized() {
return false;
}
}
if let Some(BytesReprError_oneof_error_instance::formatting(ref v)) = self.error_instance {
if !v.is_initialized() {
return false;
}
}
if let Some(BytesReprError_oneof_error_instance::left_over(ref v)) = self.error_instance {
if !v.is_initialized() {
return false;
}
}
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
if wire_type != ::protobuf::wire_format::WireTypeLengthDelimited {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
self.error_instance = ::std::option::Option::Some(BytesReprError_oneof_error_instance::early_end(is.read_message()?));
},
2 => {
if wire_type != ::protobuf::wire_format::WireTypeLengthDelimited {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
self.error_instance = ::std::option::Option::Some(BytesReprError_oneof_error_instance::formatting(is.read_message()?));
},
3 => {
if wire_type != ::protobuf::wire_format::WireTypeLengthDelimited {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
self.error_instance = ::std::option::Option::Some(BytesReprError_oneof_error_instance::left_over(is.read_message()?));
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if let ::std::option::Option::Some(ref v) = self.error_instance {
match v {
&BytesReprError_oneof_error_instance::early_end(ref v) => {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
},
&BytesReprError_oneof_error_instance::formatting(ref v) => {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
},
&BytesReprError_oneof_error_instance::left_over(ref v) => {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
},
};
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if let ::std::option::Option::Some(ref v) = self.error_instance {
match v {
&BytesReprError_oneof_error_instance::early_end(ref v) => {
os.write_tag(1, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
},
&BytesReprError_oneof_error_instance::formatting(ref v) => {
os.write_tag(2, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
},
&BytesReprError_oneof_error_instance::left_over(ref v) => {
os.write_tag(3, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
},
};
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> BytesReprError {
BytesReprError::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_singular_message_accessor::<_, EarlyEndOfStream>(
"early_end",
BytesReprError::has_early_end,
BytesReprError::get_early_end,
));
fields.push(::protobuf::reflect::accessor::make_singular_message_accessor::<_, FormattingError>(
"formatting",
BytesReprError::has_formatting,
BytesReprError::get_formatting,
));
fields.push(::protobuf::reflect::accessor::make_singular_message_accessor::<_, LeftOverBytes>(
"left_over",
BytesReprError::has_left_over,
BytesReprError::get_left_over,
));
::protobuf::reflect::MessageDescriptor::new::<BytesReprError>(
"BytesReprError",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static BytesReprError {
static mut instance: ::protobuf::lazy::Lazy<BytesReprError> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const BytesReprError,
};
unsafe {
instance.get(BytesReprError::new)
}
}
}
impl ::protobuf::Clear for BytesReprError {
fn clear(&mut self) {
self.error_instance = ::std::option::Option::None;
self.error_instance = ::std::option::Option::None;
self.error_instance = ::std::option::Option::None;
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for BytesReprError {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for BytesReprError {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct EarlyEndOfStream {
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a EarlyEndOfStream {
fn default() -> &'a EarlyEndOfStream {
<EarlyEndOfStream as ::protobuf::Message>::default_instance()
}
}
impl EarlyEndOfStream {
pub fn new() -> EarlyEndOfStream {
::std::default::Default::default()
}
}
impl ::protobuf::Message for EarlyEndOfStream {
fn is_initialized(&self) -> bool {
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> EarlyEndOfStream {
EarlyEndOfStream::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let fields = ::std::vec::Vec::new();
::protobuf::reflect::MessageDescriptor::new::<EarlyEndOfStream>(
"EarlyEndOfStream",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static EarlyEndOfStream {
static mut instance: ::protobuf::lazy::Lazy<EarlyEndOfStream> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const EarlyEndOfStream,
};
unsafe {
instance.get(EarlyEndOfStream::new)
}
}
}
impl ::protobuf::Clear for EarlyEndOfStream {
fn clear(&mut self) {
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for EarlyEndOfStream {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for EarlyEndOfStream {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct FormattingError {
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a FormattingError {
fn default() -> &'a FormattingError {
<FormattingError as ::protobuf::Message>::default_instance()
}
}
impl FormattingError {
pub fn new() -> FormattingError {
::std::default::Default::default()
}
}
impl ::protobuf::Message for FormattingError {
fn is_initialized(&self) -> bool {
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> FormattingError {
FormattingError::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let fields = ::std::vec::Vec::new();
::protobuf::reflect::MessageDescriptor::new::<FormattingError>(
"FormattingError",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static FormattingError {
static mut instance: ::protobuf::lazy::Lazy<FormattingError> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const FormattingError,
};
unsafe {
instance.get(FormattingError::new)
}
}
}
impl ::protobuf::Clear for FormattingError {
fn clear(&mut self) {
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for FormattingError {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for FormattingError {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct LeftOverBytes {
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a LeftOverBytes {
fn default() -> &'a LeftOverBytes {
<LeftOverBytes as ::protobuf::Message>::default_instance()
}
}
impl LeftOverBytes {
pub fn new() -> LeftOverBytes {
::std::default::Default::default()
}
}
impl ::protobuf::Message for LeftOverBytes {
fn is_initialized(&self) -> bool {
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> LeftOverBytes {
LeftOverBytes::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let fields = ::std::vec::Vec::new();
::protobuf::reflect::MessageDescriptor::new::<LeftOverBytes>(
"LeftOverBytes",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static LeftOverBytes {
static mut instance: ::protobuf::lazy::Lazy<LeftOverBytes> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const LeftOverBytes,
};
unsafe {
instance.get(LeftOverBytes::new)
}
}
}
impl ::protobuf::Clear for LeftOverBytes {
fn clear(&mut self) {
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for LeftOverBytes {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for LeftOverBytes {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct RkvError {
pub error_msg: ::std::string::String,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a RkvError {
fn default() -> &'a RkvError {
<RkvError as ::protobuf::Message>::default_instance()
}
}
impl RkvError {
pub fn new() -> RkvError {
::std::default::Default::default()
}
pub fn get_error_msg(&self) -> &str {
&self.error_msg
}
pub fn clear_error_msg(&mut self) {
self.error_msg.clear();
}
pub fn set_error_msg(&mut self, v: ::std::string::String) {
self.error_msg = v;
}
pub fn mut_error_msg(&mut self) -> &mut ::std::string::String {
&mut self.error_msg
}
pub fn take_error_msg(&mut self) -> ::std::string::String {
::std::mem::replace(&mut self.error_msg, ::std::string::String::new())
}
}
impl ::protobuf::Message for RkvError {
fn is_initialized(&self) -> bool {
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
::protobuf::rt::read_singular_proto3_string_into(wire_type, is, &mut self.error_msg)?;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if !self.error_msg.is_empty() {
my_size += ::protobuf::rt::string_size(1, &self.error_msg);
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if !self.error_msg.is_empty() {
os.write_string(1, &self.error_msg)?;
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> RkvError {
RkvError::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeString>(
"error_msg",
|m: &RkvError| { &m.error_msg },
|m: &mut RkvError| { &mut m.error_msg },
));
::protobuf::reflect::MessageDescriptor::new::<RkvError>(
"RkvError",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static RkvError {
static mut instance: ::protobuf::lazy::Lazy<RkvError> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const RkvError,
};
unsafe {
instance.get(RkvError::new)
}
}
}
impl ::protobuf::Clear for RkvError {
fn clear(&mut self) {
self.error_msg.clear();
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for RkvError {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for RkvError {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct OpEntry {
pub key: ::protobuf::SingularPtrField<super::state::Key>,
pub operation: ::protobuf::SingularPtrField<Op>,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a OpEntry {
fn default() -> &'a OpEntry {
<OpEntry as ::protobuf::Message>::default_instance()
}
}
impl OpEntry {
pub fn new() -> OpEntry {
::std::default::Default::default()
}
pub fn get_key(&self) -> &super::state::Key {
self.key.as_ref().unwrap_or_else(|| super::state::Key::default_instance())
}
pub fn clear_key(&mut self) {
self.key.clear();
}
pub fn has_key(&self) -> bool {
self.key.is_some()
}
pub fn set_key(&mut self, v: super::state::Key) {
self.key = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_key(&mut self) -> &mut super::state::Key {
if self.key.is_none() {
self.key.set_default();
}
self.key.as_mut().unwrap()
}
pub fn take_key(&mut self) -> super::state::Key {
self.key.take().unwrap_or_else(|| super::state::Key::new())
}
pub fn get_operation(&self) -> &Op {
self.operation.as_ref().unwrap_or_else(|| Op::default_instance())
}
pub fn clear_operation(&mut self) {
self.operation.clear();
}
pub fn has_operation(&self) -> bool {
self.operation.is_some()
}
pub fn set_operation(&mut self, v: Op) {
self.operation = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_operation(&mut self) -> &mut Op {
if self.operation.is_none() {
self.operation.set_default();
}
self.operation.as_mut().unwrap()
}
pub fn take_operation(&mut self) -> Op {
self.operation.take().unwrap_or_else(|| Op::new())
}
}
impl ::protobuf::Message for OpEntry {
fn is_initialized(&self) -> bool {
for v in &self.key {
if !v.is_initialized() {
return false;
}
};
for v in &self.operation {
if !v.is_initialized() {
return false;
}
};
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.key)?;
},
2 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.operation)?;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if let Some(ref v) = self.key.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.operation.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if let Some(ref v) = self.key.as_ref() {
os.write_tag(1, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.operation.as_ref() {
os.write_tag(2, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> OpEntry {
OpEntry::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<super::state::Key>>(
"key",
|m: &OpEntry| { &m.key },
|m: &mut OpEntry| { &mut m.key },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<Op>>(
"operation",
|m: &OpEntry| { &m.operation },
|m: &mut OpEntry| { &mut m.operation },
));
::protobuf::reflect::MessageDescriptor::new::<OpEntry>(
"OpEntry",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static OpEntry {
static mut instance: ::protobuf::lazy::Lazy<OpEntry> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const OpEntry,
};
unsafe {
instance.get(OpEntry::new)
}
}
}
impl ::protobuf::Clear for OpEntry {
fn clear(&mut self) {
self.key.clear();
self.operation.clear();
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for OpEntry {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for OpEntry {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct ExecutionEffect {
pub op_map: ::protobuf::RepeatedField<OpEntry>,
pub transform_map: ::protobuf::RepeatedField<super::transforms::TransformEntry>,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a ExecutionEffect {
fn default() -> &'a ExecutionEffect {
<ExecutionEffect as ::protobuf::Message>::default_instance()
}
}
impl ExecutionEffect {
pub fn new() -> ExecutionEffect {
::std::default::Default::default()
}
pub fn get_op_map(&self) -> &[OpEntry] {
&self.op_map
}
pub fn clear_op_map(&mut self) {
self.op_map.clear();
}
pub fn set_op_map(&mut self, v: ::protobuf::RepeatedField<OpEntry>) {
self.op_map = v;
}
pub fn mut_op_map(&mut self) -> &mut ::protobuf::RepeatedField<OpEntry> {
&mut self.op_map
}
pub fn take_op_map(&mut self) -> ::protobuf::RepeatedField<OpEntry> {
::std::mem::replace(&mut self.op_map, ::protobuf::RepeatedField::new())
}
pub fn get_transform_map(&self) -> &[super::transforms::TransformEntry] {
&self.transform_map
}
pub fn clear_transform_map(&mut self) {
self.transform_map.clear();
}
pub fn set_transform_map(&mut self, v: ::protobuf::RepeatedField<super::transforms::TransformEntry>) {
self.transform_map = v;
}
pub fn mut_transform_map(&mut self) -> &mut ::protobuf::RepeatedField<super::transforms::TransformEntry> {
&mut self.transform_map
}
pub fn take_transform_map(&mut self) -> ::protobuf::RepeatedField<super::transforms::TransformEntry> {
::std::mem::replace(&mut self.transform_map, ::protobuf::RepeatedField::new())
}
}
impl ::protobuf::Message for ExecutionEffect {
fn is_initialized(&self) -> bool {
for v in &self.op_map {
if !v.is_initialized() {
return false;
}
};
for v in &self.transform_map {
if !v.is_initialized() {
return false;
}
};
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
::protobuf::rt::read_repeated_message_into(wire_type, is, &mut self.op_map)?;
},
2 => {
::protobuf::rt::read_repeated_message_into(wire_type, is, &mut self.transform_map)?;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
for value in &self.op_map {
let len = value.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
};
for value in &self.transform_map {
let len = value.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
};
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
for v in &self.op_map {
os.write_tag(1, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
};
for v in &self.transform_map {
os.write_tag(2, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
};
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> ExecutionEffect {
ExecutionEffect::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_repeated_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<OpEntry>>(
"op_map",
|m: &ExecutionEffect| { &m.op_map },
|m: &mut ExecutionEffect| { &mut m.op_map },
));
fields.push(::protobuf::reflect::accessor::make_repeated_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<super::transforms::TransformEntry>>(
"transform_map",
|m: &ExecutionEffect| { &m.transform_map },
|m: &mut ExecutionEffect| { &mut m.transform_map },
));
::protobuf::reflect::MessageDescriptor::new::<ExecutionEffect>(
"ExecutionEffect",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static ExecutionEffect {
static mut instance: ::protobuf::lazy::Lazy<ExecutionEffect> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ExecutionEffect,
};
unsafe {
instance.get(ExecutionEffect::new)
}
}
}
impl ::protobuf::Clear for ExecutionEffect {
fn clear(&mut self) {
self.op_map.clear();
self.transform_map.clear();
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for ExecutionEffect {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for ExecutionEffect {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct DeployError {
pub value: ::std::option::Option<DeployError_oneof_value>,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a DeployError {
fn default() -> &'a DeployError {
<DeployError as ::protobuf::Message>::default_instance()
}
}
#[derive(Clone,PartialEq,Debug)]
pub enum DeployError_oneof_value {
gas_error(DeployError_OutOfGasError),
exec_error(DeployError_ExecutionError),
}
impl DeployError {
pub fn new() -> DeployError {
::std::default::Default::default()
}
pub fn get_gas_error(&self) -> &DeployError_OutOfGasError {
match self.value {
::std::option::Option::Some(DeployError_oneof_value::gas_error(ref v)) => v,
_ => DeployError_OutOfGasError::default_instance(),
}
}
pub fn clear_gas_error(&mut self) {
self.value = ::std::option::Option::None;
}
pub fn has_gas_error(&self) -> bool {
match self.value {
::std::option::Option::Some(DeployError_oneof_value::gas_error(..)) => true,
_ => false,
}
}
pub fn set_gas_error(&mut self, v: DeployError_OutOfGasError) {
self.value = ::std::option::Option::Some(DeployError_oneof_value::gas_error(v))
}
pub fn mut_gas_error(&mut self) -> &mut DeployError_OutOfGasError {
if let ::std::option::Option::Some(DeployError_oneof_value::gas_error(_)) = self.value {
} else {
self.value = ::std::option::Option::Some(DeployError_oneof_value::gas_error(DeployError_OutOfGasError::new()));
}
match self.value {
::std::option::Option::Some(DeployError_oneof_value::gas_error(ref mut v)) => v,
_ => panic!(),
}
}
pub fn take_gas_error(&mut self) -> DeployError_OutOfGasError {
if self.has_gas_error() {
match self.value.take() {
::std::option::Option::Some(DeployError_oneof_value::gas_error(v)) => v,
_ => panic!(),
}
} else {
DeployError_OutOfGasError::new()
}
}
pub fn get_exec_error(&self) -> &DeployError_ExecutionError {
match self.value {
::std::option::Option::Some(DeployError_oneof_value::exec_error(ref v)) => v,
_ => DeployError_ExecutionError::default_instance(),
}
}
pub fn clear_exec_error(&mut self) {
self.value = ::std::option::Option::None;
}
pub fn has_exec_error(&self) -> bool {
match self.value {
::std::option::Option::Some(DeployError_oneof_value::exec_error(..)) => true,
_ => false,
}
}
pub fn set_exec_error(&mut self, v: DeployError_ExecutionError) {
self.value = ::std::option::Option::Some(DeployError_oneof_value::exec_error(v))
}
pub fn mut_exec_error(&mut self) -> &mut DeployError_ExecutionError {
if let ::std::option::Option::Some(DeployError_oneof_value::exec_error(_)) = self.value {
} else {
self.value = ::std::option::Option::Some(DeployError_oneof_value::exec_error(DeployError_ExecutionError::new()));
}
match self.value {
::std::option::Option::Some(DeployError_oneof_value::exec_error(ref mut v)) => v,
_ => panic!(),
}
}
pub fn take_exec_error(&mut self) -> DeployError_ExecutionError {
if self.has_exec_error() {
match self.value.take() {
::std::option::Option::Some(DeployError_oneof_value::exec_error(v)) => v,
_ => panic!(),
}
} else {
DeployError_ExecutionError::new()
}
}
}
impl ::protobuf::Message for DeployError {
fn is_initialized(&self) -> bool {
if let Some(DeployError_oneof_value::gas_error(ref v)) = self.value {
if !v.is_initialized() {
return false;
}
}
if let Some(DeployError_oneof_value::exec_error(ref v)) = self.value {
if !v.is_initialized() {
return false;
}
}
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
if wire_type != ::protobuf::wire_format::WireTypeLengthDelimited {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
self.value = ::std::option::Option::Some(DeployError_oneof_value::gas_error(is.read_message()?));
},
2 => {
if wire_type != ::protobuf::wire_format::WireTypeLengthDelimited {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
self.value = ::std::option::Option::Some(DeployError_oneof_value::exec_error(is.read_message()?));
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if let ::std::option::Option::Some(ref v) = self.value {
match v {
&DeployError_oneof_value::gas_error(ref v) => {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
},
&DeployError_oneof_value::exec_error(ref v) => {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
},
};
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if let ::std::option::Option::Some(ref v) = self.value {
match v {
&DeployError_oneof_value::gas_error(ref v) => {
os.write_tag(1, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
},
&DeployError_oneof_value::exec_error(ref v) => {
os.write_tag(2, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
},
};
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> DeployError {
DeployError::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_singular_message_accessor::<_, DeployError_OutOfGasError>(
"gas_error",
DeployError::has_gas_error,
DeployError::get_gas_error,
));
fields.push(::protobuf::reflect::accessor::make_singular_message_accessor::<_, DeployError_ExecutionError>(
"exec_error",
DeployError::has_exec_error,
DeployError::get_exec_error,
));
::protobuf::reflect::MessageDescriptor::new::<DeployError>(
"DeployError",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static DeployError {
static mut instance: ::protobuf::lazy::Lazy<DeployError> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const DeployError,
};
unsafe {
instance.get(DeployError::new)
}
}
}
impl ::protobuf::Clear for DeployError {
fn clear(&mut self) {
self.value = ::std::option::Option::None;
self.value = ::std::option::Option::None;
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for DeployError {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for DeployError {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct DeployError_OutOfGasError {
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a DeployError_OutOfGasError {
fn default() -> &'a DeployError_OutOfGasError {
<DeployError_OutOfGasError as ::protobuf::Message>::default_instance()
}
}
impl DeployError_OutOfGasError {
pub fn new() -> DeployError_OutOfGasError {
::std::default::Default::default()
}
}
impl ::protobuf::Message for DeployError_OutOfGasError {
fn is_initialized(&self) -> bool {
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> DeployError_OutOfGasError {
DeployError_OutOfGasError::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let fields = ::std::vec::Vec::new();
::protobuf::reflect::MessageDescriptor::new::<DeployError_OutOfGasError>(
"DeployError_OutOfGasError",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static DeployError_OutOfGasError {
static mut instance: ::protobuf::lazy::Lazy<DeployError_OutOfGasError> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const DeployError_OutOfGasError,
};
unsafe {
instance.get(DeployError_OutOfGasError::new)
}
}
}
impl ::protobuf::Clear for DeployError_OutOfGasError {
fn clear(&mut self) {
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for DeployError_OutOfGasError {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for DeployError_OutOfGasError {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct DeployError_ExecutionError {
pub message: ::std::string::String,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a DeployError_ExecutionError {
fn default() -> &'a DeployError_ExecutionError {
<DeployError_ExecutionError as ::protobuf::Message>::default_instance()
}
}
impl DeployError_ExecutionError {
pub fn new() -> DeployError_ExecutionError {
::std::default::Default::default()
}
pub fn get_message(&self) -> &str {
&self.message
}
pub fn clear_message(&mut self) {
self.message.clear();
}
pub fn set_message(&mut self, v: ::std::string::String) {
self.message = v;
}
pub fn mut_message(&mut self) -> &mut ::std::string::String {
&mut self.message
}
pub fn take_message(&mut self) -> ::std::string::String {
::std::mem::replace(&mut self.message, ::std::string::String::new())
}
}
impl ::protobuf::Message for DeployError_ExecutionError {
fn is_initialized(&self) -> bool {
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
::protobuf::rt::read_singular_proto3_string_into(wire_type, is, &mut self.message)?;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if !self.message.is_empty() {
my_size += ::protobuf::rt::string_size(1, &self.message);
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if !self.message.is_empty() {
os.write_string(1, &self.message)?;
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> DeployError_ExecutionError {
DeployError_ExecutionError::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeString>(
"message",
|m: &DeployError_ExecutionError| { &m.message },
|m: &mut DeployError_ExecutionError| { &mut m.message },
));
::protobuf::reflect::MessageDescriptor::new::<DeployError_ExecutionError>(
"DeployError_ExecutionError",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static DeployError_ExecutionError {
static mut instance: ::protobuf::lazy::Lazy<DeployError_ExecutionError> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const DeployError_ExecutionError,
};
unsafe {
instance.get(DeployError_ExecutionError::new)
}
}
}
impl ::protobuf::Clear for DeployError_ExecutionError {
fn clear(&mut self) {
self.message.clear();
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for DeployError_ExecutionError {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for DeployError_ExecutionError {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct DeployResult {
pub value: ::std::option::Option<DeployResult_oneof_value>,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a DeployResult {
fn default() -> &'a DeployResult {
<DeployResult as ::protobuf::Message>::default_instance()
}
}
#[derive(Clone,PartialEq,Debug)]
pub enum DeployResult_oneof_value {
precondition_failure(DeployResult_PreconditionFailure),
execution_result(DeployResult_ExecutionResult),
}
impl DeployResult {
pub fn new() -> DeployResult {
::std::default::Default::default()
}
pub fn get_precondition_failure(&self) -> &DeployResult_PreconditionFailure {
match self.value {
::std::option::Option::Some(DeployResult_oneof_value::precondition_failure(ref v)) => v,
_ => DeployResult_PreconditionFailure::default_instance(),
}
}
pub fn clear_precondition_failure(&mut self) {
self.value = ::std::option::Option::None;
}
pub fn has_precondition_failure(&self) -> bool {
match self.value {
::std::option::Option::Some(DeployResult_oneof_value::precondition_failure(..)) => true,
_ => false,
}
}
pub fn set_precondition_failure(&mut self, v: DeployResult_PreconditionFailure) {
self.value = ::std::option::Option::Some(DeployResult_oneof_value::precondition_failure(v))
}
pub fn mut_precondition_failure(&mut self) -> &mut DeployResult_PreconditionFailure {
if let ::std::option::Option::Some(DeployResult_oneof_value::precondition_failure(_)) = self.value {
} else {
self.value = ::std::option::Option::Some(DeployResult_oneof_value::precondition_failure(DeployResult_PreconditionFailure::new()));
}
match self.value {
::std::option::Option::Some(DeployResult_oneof_value::precondition_failure(ref mut v)) => v,
_ => panic!(),
}
}
pub fn take_precondition_failure(&mut self) -> DeployResult_PreconditionFailure {
if self.has_precondition_failure() {
match self.value.take() {
::std::option::Option::Some(DeployResult_oneof_value::precondition_failure(v)) => v,
_ => panic!(),
}
} else {
DeployResult_PreconditionFailure::new()
}
}
pub fn get_execution_result(&self) -> &DeployResult_ExecutionResult {
match self.value {
::std::option::Option::Some(DeployResult_oneof_value::execution_result(ref v)) => v,
_ => DeployResult_ExecutionResult::default_instance(),
}
}
pub fn clear_execution_result(&mut self) {
self.value = ::std::option::Option::None;
}
pub fn has_execution_result(&self) -> bool {
match self.value {
::std::option::Option::Some(DeployResult_oneof_value::execution_result(..)) => true,
_ => false,
}
}
pub fn set_execution_result(&mut self, v: DeployResult_ExecutionResult) {
self.value = ::std::option::Option::Some(DeployResult_oneof_value::execution_result(v))
}
pub fn mut_execution_result(&mut self) -> &mut DeployResult_ExecutionResult {
if let ::std::option::Option::Some(DeployResult_oneof_value::execution_result(_)) = self.value {
} else {
self.value = ::std::option::Option::Some(DeployResult_oneof_value::execution_result(DeployResult_ExecutionResult::new()));
}
match self.value {
::std::option::Option::Some(DeployResult_oneof_value::execution_result(ref mut v)) => v,
_ => panic!(),
}
}
pub fn take_execution_result(&mut self) -> DeployResult_ExecutionResult {
if self.has_execution_result() {
match self.value.take() {
::std::option::Option::Some(DeployResult_oneof_value::execution_result(v)) => v,
_ => panic!(),
}
} else {
DeployResult_ExecutionResult::new()
}
}
}
impl ::protobuf::Message for DeployResult {
fn is_initialized(&self) -> bool {
if let Some(DeployResult_oneof_value::precondition_failure(ref v)) = self.value {
if !v.is_initialized() {
return false;
}
}
if let Some(DeployResult_oneof_value::execution_result(ref v)) = self.value {
if !v.is_initialized() {
return false;
}
}
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
2 => {
if wire_type != ::protobuf::wire_format::WireTypeLengthDelimited {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
self.value = ::std::option::Option::Some(DeployResult_oneof_value::precondition_failure(is.read_message()?));
},
3 => {
if wire_type != ::protobuf::wire_format::WireTypeLengthDelimited {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
self.value = ::std::option::Option::Some(DeployResult_oneof_value::execution_result(is.read_message()?));
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if let ::std::option::Option::Some(ref v) = self.value {
match v {
&DeployResult_oneof_value::precondition_failure(ref v) => {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
},
&DeployResult_oneof_value::execution_result(ref v) => {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
},
};
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if let ::std::option::Option::Some(ref v) = self.value {
match v {
&DeployResult_oneof_value::precondition_failure(ref v) => {
os.write_tag(2, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
},
&DeployResult_oneof_value::execution_result(ref v) => {
os.write_tag(3, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
},
};
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> DeployResult {
DeployResult::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_singular_message_accessor::<_, DeployResult_PreconditionFailure>(
"precondition_failure",
DeployResult::has_precondition_failure,
DeployResult::get_precondition_failure,
));
fields.push(::protobuf::reflect::accessor::make_singular_message_accessor::<_, DeployResult_ExecutionResult>(
"execution_result",
DeployResult::has_execution_result,
DeployResult::get_execution_result,
));
::protobuf::reflect::MessageDescriptor::new::<DeployResult>(
"DeployResult",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static DeployResult {
static mut instance: ::protobuf::lazy::Lazy<DeployResult> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const DeployResult,
};
unsafe {
instance.get(DeployResult::new)
}
}
}
impl ::protobuf::Clear for DeployResult {
fn clear(&mut self) {
self.value = ::std::option::Option::None;
self.value = ::std::option::Option::None;
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for DeployResult {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for DeployResult {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct DeployResult_PreconditionFailure {
pub message: ::std::string::String,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a DeployResult_PreconditionFailure {
fn default() -> &'a DeployResult_PreconditionFailure {
<DeployResult_PreconditionFailure as ::protobuf::Message>::default_instance()
}
}
impl DeployResult_PreconditionFailure {
pub fn new() -> DeployResult_PreconditionFailure {
::std::default::Default::default()
}
pub fn get_message(&self) -> &str {
&self.message
}
pub fn clear_message(&mut self) {
self.message.clear();
}
pub fn set_message(&mut self, v: ::std::string::String) {
self.message = v;
}
pub fn mut_message(&mut self) -> &mut ::std::string::String {
&mut self.message
}
pub fn take_message(&mut self) -> ::std::string::String {
::std::mem::replace(&mut self.message, ::std::string::String::new())
}
}
impl ::protobuf::Message for DeployResult_PreconditionFailure {
fn is_initialized(&self) -> bool {
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
::protobuf::rt::read_singular_proto3_string_into(wire_type, is, &mut self.message)?;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if !self.message.is_empty() {
my_size += ::protobuf::rt::string_size(1, &self.message);
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if !self.message.is_empty() {
os.write_string(1, &self.message)?;
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> DeployResult_PreconditionFailure {
DeployResult_PreconditionFailure::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeString>(
"message",
|m: &DeployResult_PreconditionFailure| { &m.message },
|m: &mut DeployResult_PreconditionFailure| { &mut m.message },
));
::protobuf::reflect::MessageDescriptor::new::<DeployResult_PreconditionFailure>(
"DeployResult_PreconditionFailure",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static DeployResult_PreconditionFailure {
static mut instance: ::protobuf::lazy::Lazy<DeployResult_PreconditionFailure> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const DeployResult_PreconditionFailure,
};
unsafe {
instance.get(DeployResult_PreconditionFailure::new)
}
}
}
impl ::protobuf::Clear for DeployResult_PreconditionFailure {
fn clear(&mut self) {
self.message.clear();
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for DeployResult_PreconditionFailure {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for DeployResult_PreconditionFailure {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct DeployResult_ExecutionResult {
pub effects: ::protobuf::SingularPtrField<ExecutionEffect>,
pub error: ::protobuf::SingularPtrField<DeployError>,
pub cost: ::protobuf::SingularPtrField<super::state::BigInt>,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a DeployResult_ExecutionResult {
fn default() -> &'a DeployResult_ExecutionResult {
<DeployResult_ExecutionResult as ::protobuf::Message>::default_instance()
}
}
impl DeployResult_ExecutionResult {
pub fn new() -> DeployResult_ExecutionResult {
::std::default::Default::default()
}
pub fn get_effects(&self) -> &ExecutionEffect {
self.effects.as_ref().unwrap_or_else(|| ExecutionEffect::default_instance())
}
pub fn clear_effects(&mut self) {
self.effects.clear();
}
pub fn has_effects(&self) -> bool {
self.effects.is_some()
}
pub fn set_effects(&mut self, v: ExecutionEffect) {
self.effects = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_effects(&mut self) -> &mut ExecutionEffect {
if self.effects.is_none() {
self.effects.set_default();
}
self.effects.as_mut().unwrap()
}
pub fn take_effects(&mut self) -> ExecutionEffect {
self.effects.take().unwrap_or_else(|| ExecutionEffect::new())
}
pub fn get_error(&self) -> &DeployError {
self.error.as_ref().unwrap_or_else(|| DeployError::default_instance())
}
pub fn clear_error(&mut self) {
self.error.clear();
}
pub fn has_error(&self) -> bool {
self.error.is_some()
}
pub fn set_error(&mut self, v: DeployError) {
self.error = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_error(&mut self) -> &mut DeployError {
if self.error.is_none() {
self.error.set_default();
}
self.error.as_mut().unwrap()
}
pub fn take_error(&mut self) -> DeployError {
self.error.take().unwrap_or_else(|| DeployError::new())
}
pub fn get_cost(&self) -> &super::state::BigInt {
self.cost.as_ref().unwrap_or_else(|| super::state::BigInt::default_instance())
}
pub fn clear_cost(&mut self) {
self.cost.clear();
}
pub fn has_cost(&self) -> bool {
self.cost.is_some()
}
pub fn set_cost(&mut self, v: super::state::BigInt) {
self.cost = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_cost(&mut self) -> &mut super::state::BigInt {
if self.cost.is_none() {
self.cost.set_default();
}
self.cost.as_mut().unwrap()
}
pub fn take_cost(&mut self) -> super::state::BigInt {
self.cost.take().unwrap_or_else(|| super::state::BigInt::new())
}
}
impl ::protobuf::Message for DeployResult_ExecutionResult {
fn is_initialized(&self) -> bool {
for v in &self.effects {
if !v.is_initialized() {
return false;
}
};
for v in &self.error {
if !v.is_initialized() {
return false;
}
};
for v in &self.cost {
if !v.is_initialized() {
return false;
}
};
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.effects)?;
},
2 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.error)?;
},
3 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.cost)?;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if let Some(ref v) = self.effects.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.error.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.cost.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if let Some(ref v) = self.effects.as_ref() {
os.write_tag(1, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.error.as_ref() {
os.write_tag(2, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.cost.as_ref() {
os.write_tag(3, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> DeployResult_ExecutionResult {
DeployResult_ExecutionResult::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ExecutionEffect>>(
"effects",
|m: &DeployResult_ExecutionResult| { &m.effects },
|m: &mut DeployResult_ExecutionResult| { &mut m.effects },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<DeployError>>(
"error",
|m: &DeployResult_ExecutionResult| { &m.error },
|m: &mut DeployResult_ExecutionResult| { &mut m.error },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<super::state::BigInt>>(
"cost",
|m: &DeployResult_ExecutionResult| { &m.cost },
|m: &mut DeployResult_ExecutionResult| { &mut m.cost },
));
::protobuf::reflect::MessageDescriptor::new::<DeployResult_ExecutionResult>(
"DeployResult_ExecutionResult",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static DeployResult_ExecutionResult {
static mut instance: ::protobuf::lazy::Lazy<DeployResult_ExecutionResult> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const DeployResult_ExecutionResult,
};
unsafe {
instance.get(DeployResult_ExecutionResult::new)
}
}
}
impl ::protobuf::Clear for DeployResult_ExecutionResult {
fn clear(&mut self) {
self.effects.clear();
self.error.clear();
self.cost.clear();
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for DeployResult_ExecutionResult {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for DeployResult_ExecutionResult {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct PostEffectsError {
pub message: ::std::string::String,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a PostEffectsError {
fn default() -> &'a PostEffectsError {
<PostEffectsError as ::protobuf::Message>::default_instance()
}
}
impl PostEffectsError {
pub fn new() -> PostEffectsError {
::std::default::Default::default()
}
pub fn get_message(&self) -> &str {
&self.message
}
pub fn clear_message(&mut self) {
self.message.clear();
}
pub fn set_message(&mut self, v: ::std::string::String) {
self.message = v;
}
pub fn mut_message(&mut self) -> &mut ::std::string::String {
&mut self.message
}
pub fn take_message(&mut self) -> ::std::string::String {
::std::mem::replace(&mut self.message, ::std::string::String::new())
}
}
impl ::protobuf::Message for PostEffectsError {
fn is_initialized(&self) -> bool {
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
::protobuf::rt::read_singular_proto3_string_into(wire_type, is, &mut self.message)?;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if !self.message.is_empty() {
my_size += ::protobuf::rt::string_size(1, &self.message);
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if !self.message.is_empty() {
os.write_string(1, &self.message)?;
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> PostEffectsError {
PostEffectsError::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeString>(
"message",
|m: &PostEffectsError| { &m.message },
|m: &mut PostEffectsError| { &mut m.message },
));
::protobuf::reflect::MessageDescriptor::new::<PostEffectsError>(
"PostEffectsError",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static PostEffectsError {
static mut instance: ::protobuf::lazy::Lazy<PostEffectsError> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const PostEffectsError,
};
unsafe {
instance.get(PostEffectsError::new)
}
}
}
impl ::protobuf::Clear for PostEffectsError {
fn clear(&mut self) {
self.message.clear();
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for PostEffectsError {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for PostEffectsError {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct QueryRequest {
pub state_hash: ::std::vec::Vec<u8>,
pub base_key: ::protobuf::SingularPtrField<super::state::Key>,
pub path: ::protobuf::RepeatedField<::std::string::String>,
pub protocol_version: ::protobuf::SingularPtrField<super::state::ProtocolVersion>,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a QueryRequest {
fn default() -> &'a QueryRequest {
<QueryRequest as ::protobuf::Message>::default_instance()
}
}
impl QueryRequest {
pub fn new() -> QueryRequest {
::std::default::Default::default()
}
pub fn get_state_hash(&self) -> &[u8] {
&self.state_hash
}
pub fn clear_state_hash(&mut self) {
self.state_hash.clear();
}
pub fn set_state_hash(&mut self, v: ::std::vec::Vec<u8>) {
self.state_hash = v;
}
pub fn mut_state_hash(&mut self) -> &mut ::std::vec::Vec<u8> {
&mut self.state_hash
}
pub fn take_state_hash(&mut self) -> ::std::vec::Vec<u8> {
::std::mem::replace(&mut self.state_hash, ::std::vec::Vec::new())
}
pub fn get_base_key(&self) -> &super::state::Key {
self.base_key.as_ref().unwrap_or_else(|| super::state::Key::default_instance())
}
pub fn clear_base_key(&mut self) {
self.base_key.clear();
}
pub fn has_base_key(&self) -> bool {
self.base_key.is_some()
}
pub fn set_base_key(&mut self, v: super::state::Key) {
self.base_key = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_base_key(&mut self) -> &mut super::state::Key {
if self.base_key.is_none() {
self.base_key.set_default();
}
self.base_key.as_mut().unwrap()
}
pub fn take_base_key(&mut self) -> super::state::Key {
self.base_key.take().unwrap_or_else(|| super::state::Key::new())
}
pub fn get_path(&self) -> &[::std::string::String] {
&self.path
}
pub fn clear_path(&mut self) {
self.path.clear();
}
pub fn set_path(&mut self, v: ::protobuf::RepeatedField<::std::string::String>) {
self.path = v;
}
pub fn mut_path(&mut self) -> &mut ::protobuf::RepeatedField<::std::string::String> {
&mut self.path
}
pub fn take_path(&mut self) -> ::protobuf::RepeatedField<::std::string::String> {
::std::mem::replace(&mut self.path, ::protobuf::RepeatedField::new())
}
pub fn get_protocol_version(&self) -> &super::state::ProtocolVersion {
self.protocol_version.as_ref().unwrap_or_else(|| super::state::ProtocolVersion::default_instance())
}
pub fn clear_protocol_version(&mut self) {
self.protocol_version.clear();
}
pub fn has_protocol_version(&self) -> bool {
self.protocol_version.is_some()
}
pub fn set_protocol_version(&mut self, v: super::state::ProtocolVersion) {
self.protocol_version = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_protocol_version(&mut self) -> &mut super::state::ProtocolVersion {
if self.protocol_version.is_none() {
self.protocol_version.set_default();
}
self.protocol_version.as_mut().unwrap()
}
pub fn take_protocol_version(&mut self) -> super::state::ProtocolVersion {
self.protocol_version.take().unwrap_or_else(|| super::state::ProtocolVersion::new())
}
}
impl ::protobuf::Message for QueryRequest {
fn is_initialized(&self) -> bool {
for v in &self.base_key {
if !v.is_initialized() {
return false;
}
};
for v in &self.protocol_version {
if !v.is_initialized() {
return false;
}
};
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
::protobuf::rt::read_singular_proto3_bytes_into(wire_type, is, &mut self.state_hash)?;
},
2 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.base_key)?;
},
3 => {
::protobuf::rt::read_repeated_string_into(wire_type, is, &mut self.path)?;
},
4 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.protocol_version)?;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if !self.state_hash.is_empty() {
my_size += ::protobuf::rt::bytes_size(1, &self.state_hash);
}
if let Some(ref v) = self.base_key.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
for value in &self.path {
my_size += ::protobuf::rt::string_size(3, &value);
};
if let Some(ref v) = self.protocol_version.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if !self.state_hash.is_empty() {
os.write_bytes(1, &self.state_hash)?;
}
if let Some(ref v) = self.base_key.as_ref() {
os.write_tag(2, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
for v in &self.path {
os.write_string(3, &v)?;
};
if let Some(ref v) = self.protocol_version.as_ref() {
os.write_tag(4, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> QueryRequest {
QueryRequest::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
"state_hash",
|m: &QueryRequest| { &m.state_hash },
|m: &mut QueryRequest| { &mut m.state_hash },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<super::state::Key>>(
"base_key",
|m: &QueryRequest| { &m.base_key },
|m: &mut QueryRequest| { &mut m.base_key },
));
fields.push(::protobuf::reflect::accessor::make_repeated_field_accessor::<_, ::protobuf::types::ProtobufTypeString>(
"path",
|m: &QueryRequest| { &m.path },
|m: &mut QueryRequest| { &mut m.path },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<super::state::ProtocolVersion>>(
"protocol_version",
|m: &QueryRequest| { &m.protocol_version },
|m: &mut QueryRequest| { &mut m.protocol_version },
));
::protobuf::reflect::MessageDescriptor::new::<QueryRequest>(
"QueryRequest",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static QueryRequest {
static mut instance: ::protobuf::lazy::Lazy<QueryRequest> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const QueryRequest,
};
unsafe {
instance.get(QueryRequest::new)
}
}
}
impl ::protobuf::Clear for QueryRequest {
fn clear(&mut self) {
self.state_hash.clear();
self.base_key.clear();
self.path.clear();
self.protocol_version.clear();
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for QueryRequest {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for QueryRequest {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct QueryResponse {
pub result: ::std::option::Option<QueryResponse_oneof_result>,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a QueryResponse {
fn default() -> &'a QueryResponse {
<QueryResponse as ::protobuf::Message>::default_instance()
}
}
#[derive(Clone,PartialEq,Debug)]
pub enum QueryResponse_oneof_result {
success(::std::vec::Vec<u8>),
failure(::std::string::String),
}
impl QueryResponse {
pub fn new() -> QueryResponse {
::std::default::Default::default()
}
pub fn get_success(&self) -> &[u8] {
match self.result {
::std::option::Option::Some(QueryResponse_oneof_result::success(ref v)) => v,
_ => &[],
}
}
pub fn clear_success(&mut self) {
self.result = ::std::option::Option::None;
}
pub fn has_success(&self) -> bool {
match self.result {
::std::option::Option::Some(QueryResponse_oneof_result::success(..)) => true,
_ => false,
}
}
pub fn set_success(&mut self, v: ::std::vec::Vec<u8>) {
self.result = ::std::option::Option::Some(QueryResponse_oneof_result::success(v))
}
pub fn mut_success(&mut self) -> &mut ::std::vec::Vec<u8> {
if let ::std::option::Option::Some(QueryResponse_oneof_result::success(_)) = self.result {
} else {
self.result = ::std::option::Option::Some(QueryResponse_oneof_result::success(::std::vec::Vec::new()));
}
match self.result {
::std::option::Option::Some(QueryResponse_oneof_result::success(ref mut v)) => v,
_ => panic!(),
}
}
pub fn take_success(&mut self) -> ::std::vec::Vec<u8> {
if self.has_success() {
match self.result.take() {
::std::option::Option::Some(QueryResponse_oneof_result::success(v)) => v,
_ => panic!(),
}
} else {
::std::vec::Vec::new()
}
}
pub fn get_failure(&self) -> &str {
match self.result {
::std::option::Option::Some(QueryResponse_oneof_result::failure(ref v)) => v,
_ => "",
}
}
pub fn clear_failure(&mut self) {
self.result = ::std::option::Option::None;
}
pub fn has_failure(&self) -> bool {
match self.result {
::std::option::Option::Some(QueryResponse_oneof_result::failure(..)) => true,
_ => false,
}
}
pub fn set_failure(&mut self, v: ::std::string::String) {
self.result = ::std::option::Option::Some(QueryResponse_oneof_result::failure(v))
}
pub fn mut_failure(&mut self) -> &mut ::std::string::String {
if let ::std::option::Option::Some(QueryResponse_oneof_result::failure(_)) = self.result {
} else {
self.result = ::std::option::Option::Some(QueryResponse_oneof_result::failure(::std::string::String::new()));
}
match self.result {
::std::option::Option::Some(QueryResponse_oneof_result::failure(ref mut v)) => v,
_ => panic!(),
}
}
pub fn take_failure(&mut self) -> ::std::string::String {
if self.has_failure() {
match self.result.take() {
::std::option::Option::Some(QueryResponse_oneof_result::failure(v)) => v,
_ => panic!(),
}
} else {
::std::string::String::new()
}
}
}
impl ::protobuf::Message for QueryResponse {
fn is_initialized(&self) -> bool {
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
3 => {
if wire_type != ::protobuf::wire_format::WireTypeLengthDelimited {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
self.result = ::std::option::Option::Some(QueryResponse_oneof_result::success(is.read_bytes()?));
},
2 => {
if wire_type != ::protobuf::wire_format::WireTypeLengthDelimited {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
self.result = ::std::option::Option::Some(QueryResponse_oneof_result::failure(is.read_string()?));
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if let ::std::option::Option::Some(ref v) = self.result {
match v {
&QueryResponse_oneof_result::success(ref v) => {
my_size += ::protobuf::rt::bytes_size(3, &v);
},
&QueryResponse_oneof_result::failure(ref v) => {
my_size += ::protobuf::rt::string_size(2, &v);
},
};
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if let ::std::option::Option::Some(ref v) = self.result {
match v {
&QueryResponse_oneof_result::success(ref v) => {
os.write_bytes(3, v)?;
},
&QueryResponse_oneof_result::failure(ref v) => {
os.write_string(2, v)?;
},
};
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> QueryResponse {
QueryResponse::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_singular_bytes_accessor::<_>(
"success",
QueryResponse::has_success,
QueryResponse::get_success,
));
fields.push(::protobuf::reflect::accessor::make_singular_string_accessor::<_>(
"failure",
QueryResponse::has_failure,
QueryResponse::get_failure,
));
::protobuf::reflect::MessageDescriptor::new::<QueryResponse>(
"QueryResponse",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static QueryResponse {
static mut instance: ::protobuf::lazy::Lazy<QueryResponse> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const QueryResponse,
};
unsafe {
instance.get(QueryResponse::new)
}
}
}
impl ::protobuf::Clear for QueryResponse {
fn clear(&mut self) {
self.result = ::std::option::Option::None;
self.result = ::std::option::Option::None;
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for QueryResponse {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for QueryResponse {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct GenesisResult {
pub poststate_hash: ::std::vec::Vec<u8>,
pub effect: ::protobuf::SingularPtrField<ExecutionEffect>,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a GenesisResult {
fn default() -> &'a GenesisResult {
<GenesisResult as ::protobuf::Message>::default_instance()
}
}
impl GenesisResult {
pub fn new() -> GenesisResult {
::std::default::Default::default()
}
pub fn get_poststate_hash(&self) -> &[u8] {
&self.poststate_hash
}
pub fn clear_poststate_hash(&mut self) {
self.poststate_hash.clear();
}
pub fn set_poststate_hash(&mut self, v: ::std::vec::Vec<u8>) {
self.poststate_hash = v;
}
pub fn mut_poststate_hash(&mut self) -> &mut ::std::vec::Vec<u8> {
&mut self.poststate_hash
}
pub fn take_poststate_hash(&mut self) -> ::std::vec::Vec<u8> {
::std::mem::replace(&mut self.poststate_hash, ::std::vec::Vec::new())
}
pub fn get_effect(&self) -> &ExecutionEffect {
self.effect.as_ref().unwrap_or_else(|| ExecutionEffect::default_instance())
}
pub fn clear_effect(&mut self) {
self.effect.clear();
}
pub fn has_effect(&self) -> bool {
self.effect.is_some()
}
pub fn set_effect(&mut self, v: ExecutionEffect) {
self.effect = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_effect(&mut self) -> &mut ExecutionEffect {
if self.effect.is_none() {
self.effect.set_default();
}
self.effect.as_mut().unwrap()
}
pub fn take_effect(&mut self) -> ExecutionEffect {
self.effect.take().unwrap_or_else(|| ExecutionEffect::new())
}
}
impl ::protobuf::Message for GenesisResult {
fn is_initialized(&self) -> bool {
for v in &self.effect {
if !v.is_initialized() {
return false;
}
};
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
::protobuf::rt::read_singular_proto3_bytes_into(wire_type, is, &mut self.poststate_hash)?;
},
2 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.effect)?;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if !self.poststate_hash.is_empty() {
my_size += ::protobuf::rt::bytes_size(1, &self.poststate_hash);
}
if let Some(ref v) = self.effect.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if !self.poststate_hash.is_empty() {
os.write_bytes(1, &self.poststate_hash)?;
}
if let Some(ref v) = self.effect.as_ref() {
os.write_tag(2, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> GenesisResult {
GenesisResult::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
"poststate_hash",
|m: &GenesisResult| { &m.poststate_hash },
|m: &mut GenesisResult| { &mut m.poststate_hash },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ExecutionEffect>>(
"effect",
|m: &GenesisResult| { &m.effect },
|m: &mut GenesisResult| { &mut m.effect },
));
::protobuf::reflect::MessageDescriptor::new::<GenesisResult>(
"GenesisResult",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static GenesisResult {
static mut instance: ::protobuf::lazy::Lazy<GenesisResult> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const GenesisResult,
};
unsafe {
instance.get(GenesisResult::new)
}
}
}
impl ::protobuf::Clear for GenesisResult {
fn clear(&mut self) {
self.poststate_hash.clear();
self.effect.clear();
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for GenesisResult {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for GenesisResult {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct GenesisDeployError {
pub message: ::std::string::String,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a GenesisDeployError {
fn default() -> &'a GenesisDeployError {
<GenesisDeployError as ::protobuf::Message>::default_instance()
}
}
impl GenesisDeployError {
pub fn new() -> GenesisDeployError {
::std::default::Default::default()
}
pub fn get_message(&self) -> &str {
&self.message
}
pub fn clear_message(&mut self) {
self.message.clear();
}
pub fn set_message(&mut self, v: ::std::string::String) {
self.message = v;
}
pub fn mut_message(&mut self) -> &mut ::std::string::String {
&mut self.message
}
pub fn take_message(&mut self) -> ::std::string::String {
::std::mem::replace(&mut self.message, ::std::string::String::new())
}
}
impl ::protobuf::Message for GenesisDeployError {
fn is_initialized(&self) -> bool {
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
::protobuf::rt::read_singular_proto3_string_into(wire_type, is, &mut self.message)?;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if !self.message.is_empty() {
my_size += ::protobuf::rt::string_size(1, &self.message);
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if !self.message.is_empty() {
os.write_string(1, &self.message)?;
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> GenesisDeployError {
GenesisDeployError::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeString>(
"message",
|m: &GenesisDeployError| { &m.message },
|m: &mut GenesisDeployError| { &mut m.message },
));
::protobuf::reflect::MessageDescriptor::new::<GenesisDeployError>(
"GenesisDeployError",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static GenesisDeployError {
static mut instance: ::protobuf::lazy::Lazy<GenesisDeployError> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const GenesisDeployError,
};
unsafe {
instance.get(GenesisDeployError::new)
}
}
}
impl ::protobuf::Clear for GenesisDeployError {
fn clear(&mut self) {
self.message.clear();
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for GenesisDeployError {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for GenesisDeployError {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct RunGenesisRequest {
pub genesis_config_hash: ::std::vec::Vec<u8>,
pub protocol_version: ::protobuf::SingularPtrField<super::state::ProtocolVersion>,
pub ee_config: ::protobuf::SingularPtrField<ChainSpec_GenesisConfig_ExecConfig>,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a RunGenesisRequest {
fn default() -> &'a RunGenesisRequest {
<RunGenesisRequest as ::protobuf::Message>::default_instance()
}
}
impl RunGenesisRequest {
pub fn new() -> RunGenesisRequest {
::std::default::Default::default()
}
pub fn get_genesis_config_hash(&self) -> &[u8] {
&self.genesis_config_hash
}
pub fn clear_genesis_config_hash(&mut self) {
self.genesis_config_hash.clear();
}
pub fn set_genesis_config_hash(&mut self, v: ::std::vec::Vec<u8>) {
self.genesis_config_hash = v;
}
pub fn mut_genesis_config_hash(&mut self) -> &mut ::std::vec::Vec<u8> {
&mut self.genesis_config_hash
}
pub fn take_genesis_config_hash(&mut self) -> ::std::vec::Vec<u8> {
::std::mem::replace(&mut self.genesis_config_hash, ::std::vec::Vec::new())
}
pub fn get_protocol_version(&self) -> &super::state::ProtocolVersion {
self.protocol_version.as_ref().unwrap_or_else(|| super::state::ProtocolVersion::default_instance())
}
pub fn clear_protocol_version(&mut self) {
self.protocol_version.clear();
}
pub fn has_protocol_version(&self) -> bool {
self.protocol_version.is_some()
}
pub fn set_protocol_version(&mut self, v: super::state::ProtocolVersion) {
self.protocol_version = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_protocol_version(&mut self) -> &mut super::state::ProtocolVersion {
if self.protocol_version.is_none() {
self.protocol_version.set_default();
}
self.protocol_version.as_mut().unwrap()
}
pub fn take_protocol_version(&mut self) -> super::state::ProtocolVersion {
self.protocol_version.take().unwrap_or_else(|| super::state::ProtocolVersion::new())
}
pub fn get_ee_config(&self) -> &ChainSpec_GenesisConfig_ExecConfig {
self.ee_config.as_ref().unwrap_or_else(|| ChainSpec_GenesisConfig_ExecConfig::default_instance())
}
pub fn clear_ee_config(&mut self) {
self.ee_config.clear();
}
pub fn has_ee_config(&self) -> bool {
self.ee_config.is_some()
}
pub fn set_ee_config(&mut self, v: ChainSpec_GenesisConfig_ExecConfig) {
self.ee_config = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_ee_config(&mut self) -> &mut ChainSpec_GenesisConfig_ExecConfig {
if self.ee_config.is_none() {
self.ee_config.set_default();
}
self.ee_config.as_mut().unwrap()
}
pub fn take_ee_config(&mut self) -> ChainSpec_GenesisConfig_ExecConfig {
self.ee_config.take().unwrap_or_else(|| ChainSpec_GenesisConfig_ExecConfig::new())
}
}
impl ::protobuf::Message for RunGenesisRequest {
fn is_initialized(&self) -> bool {
for v in &self.protocol_version {
if !v.is_initialized() {
return false;
}
};
for v in &self.ee_config {
if !v.is_initialized() {
return false;
}
};
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
::protobuf::rt::read_singular_proto3_bytes_into(wire_type, is, &mut self.genesis_config_hash)?;
},
2 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.protocol_version)?;
},
3 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.ee_config)?;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if !self.genesis_config_hash.is_empty() {
my_size += ::protobuf::rt::bytes_size(1, &self.genesis_config_hash);
}
if let Some(ref v) = self.protocol_version.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.ee_config.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if !self.genesis_config_hash.is_empty() {
os.write_bytes(1, &self.genesis_config_hash)?;
}
if let Some(ref v) = self.protocol_version.as_ref() {
os.write_tag(2, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.ee_config.as_ref() {
os.write_tag(3, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> RunGenesisRequest {
RunGenesisRequest::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
"genesis_config_hash",
|m: &RunGenesisRequest| { &m.genesis_config_hash },
|m: &mut RunGenesisRequest| { &mut m.genesis_config_hash },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<super::state::ProtocolVersion>>(
"protocol_version",
|m: &RunGenesisRequest| { &m.protocol_version },
|m: &mut RunGenesisRequest| { &mut m.protocol_version },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_GenesisConfig_ExecConfig>>(
"ee_config",
|m: &RunGenesisRequest| { &m.ee_config },
|m: &mut RunGenesisRequest| { &mut m.ee_config },
));
::protobuf::reflect::MessageDescriptor::new::<RunGenesisRequest>(
"RunGenesisRequest",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static RunGenesisRequest {
static mut instance: ::protobuf::lazy::Lazy<RunGenesisRequest> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const RunGenesisRequest,
};
unsafe {
instance.get(RunGenesisRequest::new)
}
}
}
impl ::protobuf::Clear for RunGenesisRequest {
fn clear(&mut self) {
self.genesis_config_hash.clear();
self.protocol_version.clear();
self.ee_config.clear();
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for RunGenesisRequest {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for RunGenesisRequest {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct GenesisResponse {
pub result: ::std::option::Option<GenesisResponse_oneof_result>,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a GenesisResponse {
fn default() -> &'a GenesisResponse {
<GenesisResponse as ::protobuf::Message>::default_instance()
}
}
#[derive(Clone,PartialEq,Debug)]
pub enum GenesisResponse_oneof_result {
success(GenesisResult),
failed_deploy(GenesisDeployError),
}
impl GenesisResponse {
pub fn new() -> GenesisResponse {
::std::default::Default::default()
}
pub fn get_success(&self) -> &GenesisResult {
match self.result {
::std::option::Option::Some(GenesisResponse_oneof_result::success(ref v)) => v,
_ => GenesisResult::default_instance(),
}
}
pub fn clear_success(&mut self) {
self.result = ::std::option::Option::None;
}
pub fn has_success(&self) -> bool {
match self.result {
::std::option::Option::Some(GenesisResponse_oneof_result::success(..)) => true,
_ => false,
}
}
pub fn set_success(&mut self, v: GenesisResult) {
self.result = ::std::option::Option::Some(GenesisResponse_oneof_result::success(v))
}
pub fn mut_success(&mut self) -> &mut GenesisResult {
if let ::std::option::Option::Some(GenesisResponse_oneof_result::success(_)) = self.result {
} else {
self.result = ::std::option::Option::Some(GenesisResponse_oneof_result::success(GenesisResult::new()));
}
match self.result {
::std::option::Option::Some(GenesisResponse_oneof_result::success(ref mut v)) => v,
_ => panic!(),
}
}
pub fn take_success(&mut self) -> GenesisResult {
if self.has_success() {
match self.result.take() {
::std::option::Option::Some(GenesisResponse_oneof_result::success(v)) => v,
_ => panic!(),
}
} else {
GenesisResult::new()
}
}
pub fn get_failed_deploy(&self) -> &GenesisDeployError {
match self.result {
::std::option::Option::Some(GenesisResponse_oneof_result::failed_deploy(ref v)) => v,
_ => GenesisDeployError::default_instance(),
}
}
pub fn clear_failed_deploy(&mut self) {
self.result = ::std::option::Option::None;
}
pub fn has_failed_deploy(&self) -> bool {
match self.result {
::std::option::Option::Some(GenesisResponse_oneof_result::failed_deploy(..)) => true,
_ => false,
}
}
pub fn set_failed_deploy(&mut self, v: GenesisDeployError) {
self.result = ::std::option::Option::Some(GenesisResponse_oneof_result::failed_deploy(v))
}
pub fn mut_failed_deploy(&mut self) -> &mut GenesisDeployError {
if let ::std::option::Option::Some(GenesisResponse_oneof_result::failed_deploy(_)) = self.result {
} else {
self.result = ::std::option::Option::Some(GenesisResponse_oneof_result::failed_deploy(GenesisDeployError::new()));
}
match self.result {
::std::option::Option::Some(GenesisResponse_oneof_result::failed_deploy(ref mut v)) => v,
_ => panic!(),
}
}
pub fn take_failed_deploy(&mut self) -> GenesisDeployError {
if self.has_failed_deploy() {
match self.result.take() {
::std::option::Option::Some(GenesisResponse_oneof_result::failed_deploy(v)) => v,
_ => panic!(),
}
} else {
GenesisDeployError::new()
}
}
}
impl ::protobuf::Message for GenesisResponse {
fn is_initialized(&self) -> bool {
if let Some(GenesisResponse_oneof_result::success(ref v)) = self.result {
if !v.is_initialized() {
return false;
}
}
if let Some(GenesisResponse_oneof_result::failed_deploy(ref v)) = self.result {
if !v.is_initialized() {
return false;
}
}
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
if wire_type != ::protobuf::wire_format::WireTypeLengthDelimited {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
self.result = ::std::option::Option::Some(GenesisResponse_oneof_result::success(is.read_message()?));
},
2 => {
if wire_type != ::protobuf::wire_format::WireTypeLengthDelimited {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
self.result = ::std::option::Option::Some(GenesisResponse_oneof_result::failed_deploy(is.read_message()?));
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if let ::std::option::Option::Some(ref v) = self.result {
match v {
&GenesisResponse_oneof_result::success(ref v) => {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
},
&GenesisResponse_oneof_result::failed_deploy(ref v) => {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
},
};
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if let ::std::option::Option::Some(ref v) = self.result {
match v {
&GenesisResponse_oneof_result::success(ref v) => {
os.write_tag(1, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
},
&GenesisResponse_oneof_result::failed_deploy(ref v) => {
os.write_tag(2, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
},
};
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> GenesisResponse {
GenesisResponse::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_singular_message_accessor::<_, GenesisResult>(
"success",
GenesisResponse::has_success,
GenesisResponse::get_success,
));
fields.push(::protobuf::reflect::accessor::make_singular_message_accessor::<_, GenesisDeployError>(
"failed_deploy",
GenesisResponse::has_failed_deploy,
GenesisResponse::get_failed_deploy,
));
::protobuf::reflect::MessageDescriptor::new::<GenesisResponse>(
"GenesisResponse",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static GenesisResponse {
static mut instance: ::protobuf::lazy::Lazy<GenesisResponse> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const GenesisResponse,
};
unsafe {
instance.get(GenesisResponse::new)
}
}
}
impl ::protobuf::Clear for GenesisResponse {
fn clear(&mut self) {
self.result = ::std::option::Option::None;
self.result = ::std::option::Option::None;
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for GenesisResponse {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for GenesisResponse {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct ChainSpec {
pub genesis: ::protobuf::SingularPtrField<ChainSpec_GenesisConfig>,
pub upgrades: ::protobuf::RepeatedField<ChainSpec_UpgradePoint>,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a ChainSpec {
fn default() -> &'a ChainSpec {
<ChainSpec as ::protobuf::Message>::default_instance()
}
}
impl ChainSpec {
pub fn new() -> ChainSpec {
::std::default::Default::default()
}
pub fn get_genesis(&self) -> &ChainSpec_GenesisConfig {
self.genesis.as_ref().unwrap_or_else(|| ChainSpec_GenesisConfig::default_instance())
}
pub fn clear_genesis(&mut self) {
self.genesis.clear();
}
pub fn has_genesis(&self) -> bool {
self.genesis.is_some()
}
pub fn set_genesis(&mut self, v: ChainSpec_GenesisConfig) {
self.genesis = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_genesis(&mut self) -> &mut ChainSpec_GenesisConfig {
if self.genesis.is_none() {
self.genesis.set_default();
}
self.genesis.as_mut().unwrap()
}
pub fn take_genesis(&mut self) -> ChainSpec_GenesisConfig {
self.genesis.take().unwrap_or_else(|| ChainSpec_GenesisConfig::new())
}
pub fn get_upgrades(&self) -> &[ChainSpec_UpgradePoint] {
&self.upgrades
}
pub fn clear_upgrades(&mut self) {
self.upgrades.clear();
}
pub fn set_upgrades(&mut self, v: ::protobuf::RepeatedField<ChainSpec_UpgradePoint>) {
self.upgrades = v;
}
pub fn mut_upgrades(&mut self) -> &mut ::protobuf::RepeatedField<ChainSpec_UpgradePoint> {
&mut self.upgrades
}
pub fn take_upgrades(&mut self) -> ::protobuf::RepeatedField<ChainSpec_UpgradePoint> {
::std::mem::replace(&mut self.upgrades, ::protobuf::RepeatedField::new())
}
}
impl ::protobuf::Message for ChainSpec {
fn is_initialized(&self) -> bool {
for v in &self.genesis {
if !v.is_initialized() {
return false;
}
};
for v in &self.upgrades {
if !v.is_initialized() {
return false;
}
};
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.genesis)?;
},
2 => {
::protobuf::rt::read_repeated_message_into(wire_type, is, &mut self.upgrades)?;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if let Some(ref v) = self.genesis.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
for value in &self.upgrades {
let len = value.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
};
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if let Some(ref v) = self.genesis.as_ref() {
os.write_tag(1, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
for v in &self.upgrades {
os.write_tag(2, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
};
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> ChainSpec {
ChainSpec::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_GenesisConfig>>(
"genesis",
|m: &ChainSpec| { &m.genesis },
|m: &mut ChainSpec| { &mut m.genesis },
));
fields.push(::protobuf::reflect::accessor::make_repeated_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_UpgradePoint>>(
"upgrades",
|m: &ChainSpec| { &m.upgrades },
|m: &mut ChainSpec| { &mut m.upgrades },
));
::protobuf::reflect::MessageDescriptor::new::<ChainSpec>(
"ChainSpec",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static ChainSpec {
static mut instance: ::protobuf::lazy::Lazy<ChainSpec> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ChainSpec,
};
unsafe {
instance.get(ChainSpec::new)
}
}
}
impl ::protobuf::Clear for ChainSpec {
fn clear(&mut self) {
self.genesis.clear();
self.upgrades.clear();
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for ChainSpec {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for ChainSpec {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct ChainSpec_GenesisConfig {
pub name: ::std::string::String,
pub timestamp: u64,
pub protocol_version: ::protobuf::SingularPtrField<super::state::ProtocolVersion>,
pub deploy_config: ::protobuf::SingularPtrField<ChainSpec_DeployConfig>,
pub highway_config: ::protobuf::SingularPtrField<ChainSpec_HighwayConfig>,
pub ee_config: ::protobuf::SingularPtrField<ChainSpec_GenesisConfig_ExecConfig>,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a ChainSpec_GenesisConfig {
fn default() -> &'a ChainSpec_GenesisConfig {
<ChainSpec_GenesisConfig as ::protobuf::Message>::default_instance()
}
}
impl ChainSpec_GenesisConfig {
pub fn new() -> ChainSpec_GenesisConfig {
::std::default::Default::default()
}
pub fn get_name(&self) -> &str {
&self.name
}
pub fn clear_name(&mut self) {
self.name.clear();
}
pub fn set_name(&mut self, v: ::std::string::String) {
self.name = v;
}
pub fn mut_name(&mut self) -> &mut ::std::string::String {
&mut self.name
}
pub fn take_name(&mut self) -> ::std::string::String {
::std::mem::replace(&mut self.name, ::std::string::String::new())
}
pub fn get_timestamp(&self) -> u64 {
self.timestamp
}
pub fn clear_timestamp(&mut self) {
self.timestamp = 0;
}
pub fn set_timestamp(&mut self, v: u64) {
self.timestamp = v;
}
pub fn get_protocol_version(&self) -> &super::state::ProtocolVersion {
self.protocol_version.as_ref().unwrap_or_else(|| super::state::ProtocolVersion::default_instance())
}
pub fn clear_protocol_version(&mut self) {
self.protocol_version.clear();
}
pub fn has_protocol_version(&self) -> bool {
self.protocol_version.is_some()
}
pub fn set_protocol_version(&mut self, v: super::state::ProtocolVersion) {
self.protocol_version = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_protocol_version(&mut self) -> &mut super::state::ProtocolVersion {
if self.protocol_version.is_none() {
self.protocol_version.set_default();
}
self.protocol_version.as_mut().unwrap()
}
pub fn take_protocol_version(&mut self) -> super::state::ProtocolVersion {
self.protocol_version.take().unwrap_or_else(|| super::state::ProtocolVersion::new())
}
pub fn get_deploy_config(&self) -> &ChainSpec_DeployConfig {
self.deploy_config.as_ref().unwrap_or_else(|| ChainSpec_DeployConfig::default_instance())
}
pub fn clear_deploy_config(&mut self) {
self.deploy_config.clear();
}
pub fn has_deploy_config(&self) -> bool {
self.deploy_config.is_some()
}
pub fn set_deploy_config(&mut self, v: ChainSpec_DeployConfig) {
self.deploy_config = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_deploy_config(&mut self) -> &mut ChainSpec_DeployConfig {
if self.deploy_config.is_none() {
self.deploy_config.set_default();
}
self.deploy_config.as_mut().unwrap()
}
pub fn take_deploy_config(&mut self) -> ChainSpec_DeployConfig {
self.deploy_config.take().unwrap_or_else(|| ChainSpec_DeployConfig::new())
}
pub fn get_highway_config(&self) -> &ChainSpec_HighwayConfig {
self.highway_config.as_ref().unwrap_or_else(|| ChainSpec_HighwayConfig::default_instance())
}
pub fn clear_highway_config(&mut self) {
self.highway_config.clear();
}
pub fn has_highway_config(&self) -> bool {
self.highway_config.is_some()
}
pub fn set_highway_config(&mut self, v: ChainSpec_HighwayConfig) {
self.highway_config = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_highway_config(&mut self) -> &mut ChainSpec_HighwayConfig {
if self.highway_config.is_none() {
self.highway_config.set_default();
}
self.highway_config.as_mut().unwrap()
}
pub fn take_highway_config(&mut self) -> ChainSpec_HighwayConfig {
self.highway_config.take().unwrap_or_else(|| ChainSpec_HighwayConfig::new())
}
pub fn get_ee_config(&self) -> &ChainSpec_GenesisConfig_ExecConfig {
self.ee_config.as_ref().unwrap_or_else(|| ChainSpec_GenesisConfig_ExecConfig::default_instance())
}
pub fn clear_ee_config(&mut self) {
self.ee_config.clear();
}
pub fn has_ee_config(&self) -> bool {
self.ee_config.is_some()
}
pub fn set_ee_config(&mut self, v: ChainSpec_GenesisConfig_ExecConfig) {
self.ee_config = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_ee_config(&mut self) -> &mut ChainSpec_GenesisConfig_ExecConfig {
if self.ee_config.is_none() {
self.ee_config.set_default();
}
self.ee_config.as_mut().unwrap()
}
pub fn take_ee_config(&mut self) -> ChainSpec_GenesisConfig_ExecConfig {
self.ee_config.take().unwrap_or_else(|| ChainSpec_GenesisConfig_ExecConfig::new())
}
}
impl ::protobuf::Message for ChainSpec_GenesisConfig {
fn is_initialized(&self) -> bool {
for v in &self.protocol_version {
if !v.is_initialized() {
return false;
}
};
for v in &self.deploy_config {
if !v.is_initialized() {
return false;
}
};
for v in &self.highway_config {
if !v.is_initialized() {
return false;
}
};
for v in &self.ee_config {
if !v.is_initialized() {
return false;
}
};
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
::protobuf::rt::read_singular_proto3_string_into(wire_type, is, &mut self.name)?;
},
2 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_uint64()?;
self.timestamp = tmp;
},
3 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.protocol_version)?;
},
8 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.deploy_config)?;
},
9 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.highway_config)?;
},
11 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.ee_config)?;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if !self.name.is_empty() {
my_size += ::protobuf::rt::string_size(1, &self.name);
}
if self.timestamp != 0 {
my_size += ::protobuf::rt::value_size(2, self.timestamp, ::protobuf::wire_format::WireTypeVarint);
}
if let Some(ref v) = self.protocol_version.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.deploy_config.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.highway_config.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.ee_config.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if !self.name.is_empty() {
os.write_string(1, &self.name)?;
}
if self.timestamp != 0 {
os.write_uint64(2, self.timestamp)?;
}
if let Some(ref v) = self.protocol_version.as_ref() {
os.write_tag(3, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.deploy_config.as_ref() {
os.write_tag(8, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.highway_config.as_ref() {
os.write_tag(9, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.ee_config.as_ref() {
os.write_tag(11, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> ChainSpec_GenesisConfig {
ChainSpec_GenesisConfig::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeString>(
"name",
|m: &ChainSpec_GenesisConfig| { &m.name },
|m: &mut ChainSpec_GenesisConfig| { &mut m.name },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeUint64>(
"timestamp",
|m: &ChainSpec_GenesisConfig| { &m.timestamp },
|m: &mut ChainSpec_GenesisConfig| { &mut m.timestamp },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<super::state::ProtocolVersion>>(
"protocol_version",
|m: &ChainSpec_GenesisConfig| { &m.protocol_version },
|m: &mut ChainSpec_GenesisConfig| { &mut m.protocol_version },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_DeployConfig>>(
"deploy_config",
|m: &ChainSpec_GenesisConfig| { &m.deploy_config },
|m: &mut ChainSpec_GenesisConfig| { &mut m.deploy_config },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_HighwayConfig>>(
"highway_config",
|m: &ChainSpec_GenesisConfig| { &m.highway_config },
|m: &mut ChainSpec_GenesisConfig| { &mut m.highway_config },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_GenesisConfig_ExecConfig>>(
"ee_config",
|m: &ChainSpec_GenesisConfig| { &m.ee_config },
|m: &mut ChainSpec_GenesisConfig| { &mut m.ee_config },
));
::protobuf::reflect::MessageDescriptor::new::<ChainSpec_GenesisConfig>(
"ChainSpec_GenesisConfig",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static ChainSpec_GenesisConfig {
static mut instance: ::protobuf::lazy::Lazy<ChainSpec_GenesisConfig> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ChainSpec_GenesisConfig,
};
unsafe {
instance.get(ChainSpec_GenesisConfig::new)
}
}
}
impl ::protobuf::Clear for ChainSpec_GenesisConfig {
fn clear(&mut self) {
self.name.clear();
self.timestamp = 0;
self.protocol_version.clear();
self.deploy_config.clear();
self.highway_config.clear();
self.ee_config.clear();
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for ChainSpec_GenesisConfig {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for ChainSpec_GenesisConfig {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct ChainSpec_GenesisConfig_ExecConfig {
pub mint_installer: ::std::vec::Vec<u8>,
pub pos_installer: ::std::vec::Vec<u8>,
pub standard_payment_installer: ::std::vec::Vec<u8>,
pub auction_installer: ::std::vec::Vec<u8>,
pub accounts: ::protobuf::RepeatedField<ChainSpec_GenesisConfig_ExecConfig_GenesisAccount>,
pub wasm_config: ::protobuf::SingularPtrField<ChainSpec_WasmConfig>,
pub validator_slots: u32,
pub auction_delay: u64,
pub locked_funds_period: u64,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a ChainSpec_GenesisConfig_ExecConfig {
fn default() -> &'a ChainSpec_GenesisConfig_ExecConfig {
<ChainSpec_GenesisConfig_ExecConfig as ::protobuf::Message>::default_instance()
}
}
impl ChainSpec_GenesisConfig_ExecConfig {
pub fn new() -> ChainSpec_GenesisConfig_ExecConfig {
::std::default::Default::default()
}
pub fn get_mint_installer(&self) -> &[u8] {
&self.mint_installer
}
pub fn clear_mint_installer(&mut self) {
self.mint_installer.clear();
}
pub fn set_mint_installer(&mut self, v: ::std::vec::Vec<u8>) {
self.mint_installer = v;
}
pub fn mut_mint_installer(&mut self) -> &mut ::std::vec::Vec<u8> {
&mut self.mint_installer
}
pub fn take_mint_installer(&mut self) -> ::std::vec::Vec<u8> {
::std::mem::replace(&mut self.mint_installer, ::std::vec::Vec::new())
}
pub fn get_pos_installer(&self) -> &[u8] {
&self.pos_installer
}
pub fn clear_pos_installer(&mut self) {
self.pos_installer.clear();
}
pub fn set_pos_installer(&mut self, v: ::std::vec::Vec<u8>) {
self.pos_installer = v;
}
pub fn mut_pos_installer(&mut self) -> &mut ::std::vec::Vec<u8> {
&mut self.pos_installer
}
pub fn take_pos_installer(&mut self) -> ::std::vec::Vec<u8> {
::std::mem::replace(&mut self.pos_installer, ::std::vec::Vec::new())
}
pub fn get_standard_payment_installer(&self) -> &[u8] {
&self.standard_payment_installer
}
pub fn clear_standard_payment_installer(&mut self) {
self.standard_payment_installer.clear();
}
pub fn set_standard_payment_installer(&mut self, v: ::std::vec::Vec<u8>) {
self.standard_payment_installer = v;
}
pub fn mut_standard_payment_installer(&mut self) -> &mut ::std::vec::Vec<u8> {
&mut self.standard_payment_installer
}
pub fn take_standard_payment_installer(&mut self) -> ::std::vec::Vec<u8> {
::std::mem::replace(&mut self.standard_payment_installer, ::std::vec::Vec::new())
}
pub fn get_auction_installer(&self) -> &[u8] {
&self.auction_installer
}
pub fn clear_auction_installer(&mut self) {
self.auction_installer.clear();
}
pub fn set_auction_installer(&mut self, v: ::std::vec::Vec<u8>) {
self.auction_installer = v;
}
pub fn mut_auction_installer(&mut self) -> &mut ::std::vec::Vec<u8> {
&mut self.auction_installer
}
pub fn take_auction_installer(&mut self) -> ::std::vec::Vec<u8> {
::std::mem::replace(&mut self.auction_installer, ::std::vec::Vec::new())
}
pub fn get_accounts(&self) -> &[ChainSpec_GenesisConfig_ExecConfig_GenesisAccount] {
&self.accounts
}
pub fn clear_accounts(&mut self) {
self.accounts.clear();
}
pub fn set_accounts(&mut self, v: ::protobuf::RepeatedField<ChainSpec_GenesisConfig_ExecConfig_GenesisAccount>) {
self.accounts = v;
}
pub fn mut_accounts(&mut self) -> &mut ::protobuf::RepeatedField<ChainSpec_GenesisConfig_ExecConfig_GenesisAccount> {
&mut self.accounts
}
pub fn take_accounts(&mut self) -> ::protobuf::RepeatedField<ChainSpec_GenesisConfig_ExecConfig_GenesisAccount> {
::std::mem::replace(&mut self.accounts, ::protobuf::RepeatedField::new())
}
pub fn get_wasm_config(&self) -> &ChainSpec_WasmConfig {
self.wasm_config.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig::default_instance())
}
pub fn clear_wasm_config(&mut self) {
self.wasm_config.clear();
}
pub fn has_wasm_config(&self) -> bool {
self.wasm_config.is_some()
}
pub fn set_wasm_config(&mut self, v: ChainSpec_WasmConfig) {
self.wasm_config = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_wasm_config(&mut self) -> &mut ChainSpec_WasmConfig {
if self.wasm_config.is_none() {
self.wasm_config.set_default();
}
self.wasm_config.as_mut().unwrap()
}
pub fn take_wasm_config(&mut self) -> ChainSpec_WasmConfig {
self.wasm_config.take().unwrap_or_else(|| ChainSpec_WasmConfig::new())
}
pub fn get_validator_slots(&self) -> u32 {
self.validator_slots
}
pub fn clear_validator_slots(&mut self) {
self.validator_slots = 0;
}
pub fn set_validator_slots(&mut self, v: u32) {
self.validator_slots = v;
}
pub fn get_auction_delay(&self) -> u64 {
self.auction_delay
}
pub fn clear_auction_delay(&mut self) {
self.auction_delay = 0;
}
pub fn set_auction_delay(&mut self, v: u64) {
self.auction_delay = v;
}
pub fn get_locked_funds_period(&self) -> u64 {
self.locked_funds_period
}
pub fn clear_locked_funds_period(&mut self) {
self.locked_funds_period = 0;
}
pub fn set_locked_funds_period(&mut self, v: u64) {
self.locked_funds_period = v;
}
}
impl ::protobuf::Message for ChainSpec_GenesisConfig_ExecConfig {
fn is_initialized(&self) -> bool {
for v in &self.accounts {
if !v.is_initialized() {
return false;
}
};
for v in &self.wasm_config {
if !v.is_initialized() {
return false;
}
};
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
::protobuf::rt::read_singular_proto3_bytes_into(wire_type, is, &mut self.mint_installer)?;
},
2 => {
::protobuf::rt::read_singular_proto3_bytes_into(wire_type, is, &mut self.pos_installer)?;
},
3 => {
::protobuf::rt::read_singular_proto3_bytes_into(wire_type, is, &mut self.standard_payment_installer)?;
},
6 => {
::protobuf::rt::read_singular_proto3_bytes_into(wire_type, is, &mut self.auction_installer)?;
},
4 => {
::protobuf::rt::read_repeated_message_into(wire_type, is, &mut self.accounts)?;
},
5 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.wasm_config)?;
},
7 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_uint32()?;
self.validator_slots = tmp;
},
8 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_uint64()?;
self.auction_delay = tmp;
},
10 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_uint64()?;
self.locked_funds_period = tmp;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if !self.mint_installer.is_empty() {
my_size += ::protobuf::rt::bytes_size(1, &self.mint_installer);
}
if !self.pos_installer.is_empty() {
my_size += ::protobuf::rt::bytes_size(2, &self.pos_installer);
}
if !self.standard_payment_installer.is_empty() {
my_size += ::protobuf::rt::bytes_size(3, &self.standard_payment_installer);
}
if !self.auction_installer.is_empty() {
my_size += ::protobuf::rt::bytes_size(6, &self.auction_installer);
}
for value in &self.accounts {
let len = value.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
};
if let Some(ref v) = self.wasm_config.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if self.validator_slots != 0 {
my_size += ::protobuf::rt::value_size(7, self.validator_slots, ::protobuf::wire_format::WireTypeVarint);
}
if self.auction_delay != 0 {
my_size += ::protobuf::rt::value_size(8, self.auction_delay, ::protobuf::wire_format::WireTypeVarint);
}
if self.locked_funds_period != 0 {
my_size += ::protobuf::rt::value_size(10, self.locked_funds_period, ::protobuf::wire_format::WireTypeVarint);
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if !self.mint_installer.is_empty() {
os.write_bytes(1, &self.mint_installer)?;
}
if !self.pos_installer.is_empty() {
os.write_bytes(2, &self.pos_installer)?;
}
if !self.standard_payment_installer.is_empty() {
os.write_bytes(3, &self.standard_payment_installer)?;
}
if !self.auction_installer.is_empty() {
os.write_bytes(6, &self.auction_installer)?;
}
for v in &self.accounts {
os.write_tag(4, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
};
if let Some(ref v) = self.wasm_config.as_ref() {
os.write_tag(5, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if self.validator_slots != 0 {
os.write_uint32(7, self.validator_slots)?;
}
if self.auction_delay != 0 {
os.write_uint64(8, self.auction_delay)?;
}
if self.locked_funds_period != 0 {
os.write_uint64(10, self.locked_funds_period)?;
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> ChainSpec_GenesisConfig_ExecConfig {
ChainSpec_GenesisConfig_ExecConfig::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
"mint_installer",
|m: &ChainSpec_GenesisConfig_ExecConfig| { &m.mint_installer },
|m: &mut ChainSpec_GenesisConfig_ExecConfig| { &mut m.mint_installer },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
"pos_installer",
|m: &ChainSpec_GenesisConfig_ExecConfig| { &m.pos_installer },
|m: &mut ChainSpec_GenesisConfig_ExecConfig| { &mut m.pos_installer },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
"standard_payment_installer",
|m: &ChainSpec_GenesisConfig_ExecConfig| { &m.standard_payment_installer },
|m: &mut ChainSpec_GenesisConfig_ExecConfig| { &mut m.standard_payment_installer },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
"auction_installer",
|m: &ChainSpec_GenesisConfig_ExecConfig| { &m.auction_installer },
|m: &mut ChainSpec_GenesisConfig_ExecConfig| { &mut m.auction_installer },
));
fields.push(::protobuf::reflect::accessor::make_repeated_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_GenesisConfig_ExecConfig_GenesisAccount>>(
"accounts",
|m: &ChainSpec_GenesisConfig_ExecConfig| { &m.accounts },
|m: &mut ChainSpec_GenesisConfig_ExecConfig| { &mut m.accounts },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig>>(
"wasm_config",
|m: &ChainSpec_GenesisConfig_ExecConfig| { &m.wasm_config },
|m: &mut ChainSpec_GenesisConfig_ExecConfig| { &mut m.wasm_config },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeUint32>(
"validator_slots",
|m: &ChainSpec_GenesisConfig_ExecConfig| { &m.validator_slots },
|m: &mut ChainSpec_GenesisConfig_ExecConfig| { &mut m.validator_slots },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeUint64>(
"auction_delay",
|m: &ChainSpec_GenesisConfig_ExecConfig| { &m.auction_delay },
|m: &mut ChainSpec_GenesisConfig_ExecConfig| { &mut m.auction_delay },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeUint64>(
"locked_funds_period",
|m: &ChainSpec_GenesisConfig_ExecConfig| { &m.locked_funds_period },
|m: &mut ChainSpec_GenesisConfig_ExecConfig| { &mut m.locked_funds_period },
));
::protobuf::reflect::MessageDescriptor::new::<ChainSpec_GenesisConfig_ExecConfig>(
"ChainSpec_GenesisConfig_ExecConfig",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static ChainSpec_GenesisConfig_ExecConfig {
static mut instance: ::protobuf::lazy::Lazy<ChainSpec_GenesisConfig_ExecConfig> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ChainSpec_GenesisConfig_ExecConfig,
};
unsafe {
instance.get(ChainSpec_GenesisConfig_ExecConfig::new)
}
}
}
impl ::protobuf::Clear for ChainSpec_GenesisConfig_ExecConfig {
fn clear(&mut self) {
self.mint_installer.clear();
self.pos_installer.clear();
self.standard_payment_installer.clear();
self.auction_installer.clear();
self.accounts.clear();
self.wasm_config.clear();
self.validator_slots = 0;
self.auction_delay = 0;
self.locked_funds_period = 0;
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for ChainSpec_GenesisConfig_ExecConfig {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for ChainSpec_GenesisConfig_ExecConfig {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct ChainSpec_GenesisConfig_ExecConfig_GenesisAccount {
pub public_key_bytes: ::std::vec::Vec<u8>,
pub account_hash_bytes: ::std::vec::Vec<u8>,
pub balance: ::protobuf::SingularPtrField<super::state::BigInt>,
pub bonded_amount: ::protobuf::SingularPtrField<super::state::BigInt>,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a ChainSpec_GenesisConfig_ExecConfig_GenesisAccount {
fn default() -> &'a ChainSpec_GenesisConfig_ExecConfig_GenesisAccount {
<ChainSpec_GenesisConfig_ExecConfig_GenesisAccount as ::protobuf::Message>::default_instance()
}
}
impl ChainSpec_GenesisConfig_ExecConfig_GenesisAccount {
pub fn new() -> ChainSpec_GenesisConfig_ExecConfig_GenesisAccount {
::std::default::Default::default()
}
pub fn get_public_key_bytes(&self) -> &[u8] {
&self.public_key_bytes
}
pub fn clear_public_key_bytes(&mut self) {
self.public_key_bytes.clear();
}
pub fn set_public_key_bytes(&mut self, v: ::std::vec::Vec<u8>) {
self.public_key_bytes = v;
}
pub fn mut_public_key_bytes(&mut self) -> &mut ::std::vec::Vec<u8> {
&mut self.public_key_bytes
}
pub fn take_public_key_bytes(&mut self) -> ::std::vec::Vec<u8> {
::std::mem::replace(&mut self.public_key_bytes, ::std::vec::Vec::new())
}
pub fn get_account_hash_bytes(&self) -> &[u8] {
&self.account_hash_bytes
}
pub fn clear_account_hash_bytes(&mut self) {
self.account_hash_bytes.clear();
}
pub fn set_account_hash_bytes(&mut self, v: ::std::vec::Vec<u8>) {
self.account_hash_bytes = v;
}
pub fn mut_account_hash_bytes(&mut self) -> &mut ::std::vec::Vec<u8> {
&mut self.account_hash_bytes
}
pub fn take_account_hash_bytes(&mut self) -> ::std::vec::Vec<u8> {
::std::mem::replace(&mut self.account_hash_bytes, ::std::vec::Vec::new())
}
pub fn get_balance(&self) -> &super::state::BigInt {
self.balance.as_ref().unwrap_or_else(|| super::state::BigInt::default_instance())
}
pub fn clear_balance(&mut self) {
self.balance.clear();
}
pub fn has_balance(&self) -> bool {
self.balance.is_some()
}
pub fn set_balance(&mut self, v: super::state::BigInt) {
self.balance = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_balance(&mut self) -> &mut super::state::BigInt {
if self.balance.is_none() {
self.balance.set_default();
}
self.balance.as_mut().unwrap()
}
pub fn take_balance(&mut self) -> super::state::BigInt {
self.balance.take().unwrap_or_else(|| super::state::BigInt::new())
}
pub fn get_bonded_amount(&self) -> &super::state::BigInt {
self.bonded_amount.as_ref().unwrap_or_else(|| super::state::BigInt::default_instance())
}
pub fn clear_bonded_amount(&mut self) {
self.bonded_amount.clear();
}
pub fn has_bonded_amount(&self) -> bool {
self.bonded_amount.is_some()
}
pub fn set_bonded_amount(&mut self, v: super::state::BigInt) {
self.bonded_amount = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_bonded_amount(&mut self) -> &mut super::state::BigInt {
if self.bonded_amount.is_none() {
self.bonded_amount.set_default();
}
self.bonded_amount.as_mut().unwrap()
}
pub fn take_bonded_amount(&mut self) -> super::state::BigInt {
self.bonded_amount.take().unwrap_or_else(|| super::state::BigInt::new())
}
}
impl ::protobuf::Message for ChainSpec_GenesisConfig_ExecConfig_GenesisAccount {
fn is_initialized(&self) -> bool {
for v in &self.balance {
if !v.is_initialized() {
return false;
}
};
for v in &self.bonded_amount {
if !v.is_initialized() {
return false;
}
};
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
::protobuf::rt::read_singular_proto3_bytes_into(wire_type, is, &mut self.public_key_bytes)?;
},
4 => {
::protobuf::rt::read_singular_proto3_bytes_into(wire_type, is, &mut self.account_hash_bytes)?;
},
2 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.balance)?;
},
3 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.bonded_amount)?;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if !self.public_key_bytes.is_empty() {
my_size += ::protobuf::rt::bytes_size(1, &self.public_key_bytes);
}
if !self.account_hash_bytes.is_empty() {
my_size += ::protobuf::rt::bytes_size(4, &self.account_hash_bytes);
}
if let Some(ref v) = self.balance.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.bonded_amount.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if !self.public_key_bytes.is_empty() {
os.write_bytes(1, &self.public_key_bytes)?;
}
if !self.account_hash_bytes.is_empty() {
os.write_bytes(4, &self.account_hash_bytes)?;
}
if let Some(ref v) = self.balance.as_ref() {
os.write_tag(2, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.bonded_amount.as_ref() {
os.write_tag(3, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> ChainSpec_GenesisConfig_ExecConfig_GenesisAccount {
ChainSpec_GenesisConfig_ExecConfig_GenesisAccount::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
"public_key_bytes",
|m: &ChainSpec_GenesisConfig_ExecConfig_GenesisAccount| { &m.public_key_bytes },
|m: &mut ChainSpec_GenesisConfig_ExecConfig_GenesisAccount| { &mut m.public_key_bytes },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
"account_hash_bytes",
|m: &ChainSpec_GenesisConfig_ExecConfig_GenesisAccount| { &m.account_hash_bytes },
|m: &mut ChainSpec_GenesisConfig_ExecConfig_GenesisAccount| { &mut m.account_hash_bytes },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<super::state::BigInt>>(
"balance",
|m: &ChainSpec_GenesisConfig_ExecConfig_GenesisAccount| { &m.balance },
|m: &mut ChainSpec_GenesisConfig_ExecConfig_GenesisAccount| { &mut m.balance },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<super::state::BigInt>>(
"bonded_amount",
|m: &ChainSpec_GenesisConfig_ExecConfig_GenesisAccount| { &m.bonded_amount },
|m: &mut ChainSpec_GenesisConfig_ExecConfig_GenesisAccount| { &mut m.bonded_amount },
));
::protobuf::reflect::MessageDescriptor::new::<ChainSpec_GenesisConfig_ExecConfig_GenesisAccount>(
"ChainSpec_GenesisConfig_ExecConfig_GenesisAccount",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static ChainSpec_GenesisConfig_ExecConfig_GenesisAccount {
static mut instance: ::protobuf::lazy::Lazy<ChainSpec_GenesisConfig_ExecConfig_GenesisAccount> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ChainSpec_GenesisConfig_ExecConfig_GenesisAccount,
};
unsafe {
instance.get(ChainSpec_GenesisConfig_ExecConfig_GenesisAccount::new)
}
}
}
impl ::protobuf::Clear for ChainSpec_GenesisConfig_ExecConfig_GenesisAccount {
fn clear(&mut self) {
self.public_key_bytes.clear();
self.account_hash_bytes.clear();
self.balance.clear();
self.bonded_amount.clear();
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for ChainSpec_GenesisConfig_ExecConfig_GenesisAccount {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for ChainSpec_GenesisConfig_ExecConfig_GenesisAccount {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct ChainSpec_DeployConfig {
pub max_ttl_millis: u32,
pub max_dependencies: u32,
pub max_block_size_bytes: u32,
pub max_block_cost: u64,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a ChainSpec_DeployConfig {
fn default() -> &'a ChainSpec_DeployConfig {
<ChainSpec_DeployConfig as ::protobuf::Message>::default_instance()
}
}
impl ChainSpec_DeployConfig {
pub fn new() -> ChainSpec_DeployConfig {
::std::default::Default::default()
}
pub fn get_max_ttl_millis(&self) -> u32 {
self.max_ttl_millis
}
pub fn clear_max_ttl_millis(&mut self) {
self.max_ttl_millis = 0;
}
pub fn set_max_ttl_millis(&mut self, v: u32) {
self.max_ttl_millis = v;
}
pub fn get_max_dependencies(&self) -> u32 {
self.max_dependencies
}
pub fn clear_max_dependencies(&mut self) {
self.max_dependencies = 0;
}
pub fn set_max_dependencies(&mut self, v: u32) {
self.max_dependencies = v;
}
pub fn get_max_block_size_bytes(&self) -> u32 {
self.max_block_size_bytes
}
pub fn clear_max_block_size_bytes(&mut self) {
self.max_block_size_bytes = 0;
}
pub fn set_max_block_size_bytes(&mut self, v: u32) {
self.max_block_size_bytes = v;
}
pub fn get_max_block_cost(&self) -> u64 {
self.max_block_cost
}
pub fn clear_max_block_cost(&mut self) {
self.max_block_cost = 0;
}
pub fn set_max_block_cost(&mut self, v: u64) {
self.max_block_cost = v;
}
}
impl ::protobuf::Message for ChainSpec_DeployConfig {
fn is_initialized(&self) -> bool {
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
2 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_uint32()?;
self.max_ttl_millis = tmp;
},
3 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_uint32()?;
self.max_dependencies = tmp;
},
4 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_uint32()?;
self.max_block_size_bytes = tmp;
},
5 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_uint64()?;
self.max_block_cost = tmp;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if self.max_ttl_millis != 0 {
my_size += ::protobuf::rt::value_size(2, self.max_ttl_millis, ::protobuf::wire_format::WireTypeVarint);
}
if self.max_dependencies != 0 {
my_size += ::protobuf::rt::value_size(3, self.max_dependencies, ::protobuf::wire_format::WireTypeVarint);
}
if self.max_block_size_bytes != 0 {
my_size += ::protobuf::rt::value_size(4, self.max_block_size_bytes, ::protobuf::wire_format::WireTypeVarint);
}
if self.max_block_cost != 0 {
my_size += ::protobuf::rt::value_size(5, self.max_block_cost, ::protobuf::wire_format::WireTypeVarint);
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if self.max_ttl_millis != 0 {
os.write_uint32(2, self.max_ttl_millis)?;
}
if self.max_dependencies != 0 {
os.write_uint32(3, self.max_dependencies)?;
}
if self.max_block_size_bytes != 0 {
os.write_uint32(4, self.max_block_size_bytes)?;
}
if self.max_block_cost != 0 {
os.write_uint64(5, self.max_block_cost)?;
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> ChainSpec_DeployConfig {
ChainSpec_DeployConfig::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeUint32>(
"max_ttl_millis",
|m: &ChainSpec_DeployConfig| { &m.max_ttl_millis },
|m: &mut ChainSpec_DeployConfig| { &mut m.max_ttl_millis },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeUint32>(
"max_dependencies",
|m: &ChainSpec_DeployConfig| { &m.max_dependencies },
|m: &mut ChainSpec_DeployConfig| { &mut m.max_dependencies },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeUint32>(
"max_block_size_bytes",
|m: &ChainSpec_DeployConfig| { &m.max_block_size_bytes },
|m: &mut ChainSpec_DeployConfig| { &mut m.max_block_size_bytes },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeUint64>(
"max_block_cost",
|m: &ChainSpec_DeployConfig| { &m.max_block_cost },
|m: &mut ChainSpec_DeployConfig| { &mut m.max_block_cost },
));
::protobuf::reflect::MessageDescriptor::new::<ChainSpec_DeployConfig>(
"ChainSpec_DeployConfig",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static ChainSpec_DeployConfig {
static mut instance: ::protobuf::lazy::Lazy<ChainSpec_DeployConfig> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ChainSpec_DeployConfig,
};
unsafe {
instance.get(ChainSpec_DeployConfig::new)
}
}
}
impl ::protobuf::Clear for ChainSpec_DeployConfig {
fn clear(&mut self) {
self.max_ttl_millis = 0;
self.max_dependencies = 0;
self.max_block_size_bytes = 0;
self.max_block_cost = 0;
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for ChainSpec_DeployConfig {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for ChainSpec_DeployConfig {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct ChainSpec_HighwayConfig {
pub genesis_era_start_timestamp: u64,
pub era_duration_millis: u64,
pub booking_duration_millis: u64,
pub entropy_duration_millis: u64,
pub voting_period_duration_millis: u64,
pub voting_period_summit_level: u32,
pub ftt: f64,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a ChainSpec_HighwayConfig {
fn default() -> &'a ChainSpec_HighwayConfig {
<ChainSpec_HighwayConfig as ::protobuf::Message>::default_instance()
}
}
impl ChainSpec_HighwayConfig {
pub fn new() -> ChainSpec_HighwayConfig {
::std::default::Default::default()
}
pub fn get_genesis_era_start_timestamp(&self) -> u64 {
self.genesis_era_start_timestamp
}
pub fn clear_genesis_era_start_timestamp(&mut self) {
self.genesis_era_start_timestamp = 0;
}
pub fn set_genesis_era_start_timestamp(&mut self, v: u64) {
self.genesis_era_start_timestamp = v;
}
pub fn get_era_duration_millis(&self) -> u64 {
self.era_duration_millis
}
pub fn clear_era_duration_millis(&mut self) {
self.era_duration_millis = 0;
}
pub fn set_era_duration_millis(&mut self, v: u64) {
self.era_duration_millis = v;
}
pub fn get_booking_duration_millis(&self) -> u64 {
self.booking_duration_millis
}
pub fn clear_booking_duration_millis(&mut self) {
self.booking_duration_millis = 0;
}
pub fn set_booking_duration_millis(&mut self, v: u64) {
self.booking_duration_millis = v;
}
pub fn get_entropy_duration_millis(&self) -> u64 {
self.entropy_duration_millis
}
pub fn clear_entropy_duration_millis(&mut self) {
self.entropy_duration_millis = 0;
}
pub fn set_entropy_duration_millis(&mut self, v: u64) {
self.entropy_duration_millis = v;
}
pub fn get_voting_period_duration_millis(&self) -> u64 {
self.voting_period_duration_millis
}
pub fn clear_voting_period_duration_millis(&mut self) {
self.voting_period_duration_millis = 0;
}
pub fn set_voting_period_duration_millis(&mut self, v: u64) {
self.voting_period_duration_millis = v;
}
pub fn get_voting_period_summit_level(&self) -> u32 {
self.voting_period_summit_level
}
pub fn clear_voting_period_summit_level(&mut self) {
self.voting_period_summit_level = 0;
}
pub fn set_voting_period_summit_level(&mut self, v: u32) {
self.voting_period_summit_level = v;
}
pub fn get_ftt(&self) -> f64 {
self.ftt
}
pub fn clear_ftt(&mut self) {
self.ftt = 0.;
}
pub fn set_ftt(&mut self, v: f64) {
self.ftt = v;
}
}
impl ::protobuf::Message for ChainSpec_HighwayConfig {
fn is_initialized(&self) -> bool {
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_uint64()?;
self.genesis_era_start_timestamp = tmp;
},
2 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_uint64()?;
self.era_duration_millis = tmp;
},
3 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_uint64()?;
self.booking_duration_millis = tmp;
},
4 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_uint64()?;
self.entropy_duration_millis = tmp;
},
5 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_uint64()?;
self.voting_period_duration_millis = tmp;
},
6 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_uint32()?;
self.voting_period_summit_level = tmp;
},
7 => {
if wire_type != ::protobuf::wire_format::WireTypeFixed64 {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_double()?;
self.ftt = tmp;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if self.genesis_era_start_timestamp != 0 {
my_size += ::protobuf::rt::value_size(1, self.genesis_era_start_timestamp, ::protobuf::wire_format::WireTypeVarint);
}
if self.era_duration_millis != 0 {
my_size += ::protobuf::rt::value_size(2, self.era_duration_millis, ::protobuf::wire_format::WireTypeVarint);
}
if self.booking_duration_millis != 0 {
my_size += ::protobuf::rt::value_size(3, self.booking_duration_millis, ::protobuf::wire_format::WireTypeVarint);
}
if self.entropy_duration_millis != 0 {
my_size += ::protobuf::rt::value_size(4, self.entropy_duration_millis, ::protobuf::wire_format::WireTypeVarint);
}
if self.voting_period_duration_millis != 0 {
my_size += ::protobuf::rt::value_size(5, self.voting_period_duration_millis, ::protobuf::wire_format::WireTypeVarint);
}
if self.voting_period_summit_level != 0 {
my_size += ::protobuf::rt::value_size(6, self.voting_period_summit_level, ::protobuf::wire_format::WireTypeVarint);
}
if self.ftt != 0. {
my_size += 9;
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if self.genesis_era_start_timestamp != 0 {
os.write_uint64(1, self.genesis_era_start_timestamp)?;
}
if self.era_duration_millis != 0 {
os.write_uint64(2, self.era_duration_millis)?;
}
if self.booking_duration_millis != 0 {
os.write_uint64(3, self.booking_duration_millis)?;
}
if self.entropy_duration_millis != 0 {
os.write_uint64(4, self.entropy_duration_millis)?;
}
if self.voting_period_duration_millis != 0 {
os.write_uint64(5, self.voting_period_duration_millis)?;
}
if self.voting_period_summit_level != 0 {
os.write_uint32(6, self.voting_period_summit_level)?;
}
if self.ftt != 0. {
os.write_double(7, self.ftt)?;
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> ChainSpec_HighwayConfig {
ChainSpec_HighwayConfig::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeUint64>(
"genesis_era_start_timestamp",
|m: &ChainSpec_HighwayConfig| { &m.genesis_era_start_timestamp },
|m: &mut ChainSpec_HighwayConfig| { &mut m.genesis_era_start_timestamp },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeUint64>(
"era_duration_millis",
|m: &ChainSpec_HighwayConfig| { &m.era_duration_millis },
|m: &mut ChainSpec_HighwayConfig| { &mut m.era_duration_millis },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeUint64>(
"booking_duration_millis",
|m: &ChainSpec_HighwayConfig| { &m.booking_duration_millis },
|m: &mut ChainSpec_HighwayConfig| { &mut m.booking_duration_millis },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeUint64>(
"entropy_duration_millis",
|m: &ChainSpec_HighwayConfig| { &m.entropy_duration_millis },
|m: &mut ChainSpec_HighwayConfig| { &mut m.entropy_duration_millis },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeUint64>(
"voting_period_duration_millis",
|m: &ChainSpec_HighwayConfig| { &m.voting_period_duration_millis },
|m: &mut ChainSpec_HighwayConfig| { &mut m.voting_period_duration_millis },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeUint32>(
"voting_period_summit_level",
|m: &ChainSpec_HighwayConfig| { &m.voting_period_summit_level },
|m: &mut ChainSpec_HighwayConfig| { &mut m.voting_period_summit_level },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeDouble>(
"ftt",
|m: &ChainSpec_HighwayConfig| { &m.ftt },
|m: &mut ChainSpec_HighwayConfig| { &mut m.ftt },
));
::protobuf::reflect::MessageDescriptor::new::<ChainSpec_HighwayConfig>(
"ChainSpec_HighwayConfig",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static ChainSpec_HighwayConfig {
static mut instance: ::protobuf::lazy::Lazy<ChainSpec_HighwayConfig> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ChainSpec_HighwayConfig,
};
unsafe {
instance.get(ChainSpec_HighwayConfig::new)
}
}
}
impl ::protobuf::Clear for ChainSpec_HighwayConfig {
fn clear(&mut self) {
self.genesis_era_start_timestamp = 0;
self.era_duration_millis = 0;
self.booking_duration_millis = 0;
self.entropy_duration_millis = 0;
self.voting_period_duration_millis = 0;
self.voting_period_summit_level = 0;
self.ftt = 0.;
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for ChainSpec_HighwayConfig {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for ChainSpec_HighwayConfig {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct ChainSpec_WasmConfig {
pub initial_memory: u32,
pub max_stack_height: u32,
pub opcode_costs: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_OpcodeCosts>,
pub storage_costs: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_StorageCosts>,
pub host_function_costs: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_HostFunctionCosts>,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a ChainSpec_WasmConfig {
fn default() -> &'a ChainSpec_WasmConfig {
<ChainSpec_WasmConfig as ::protobuf::Message>::default_instance()
}
}
impl ChainSpec_WasmConfig {
pub fn new() -> ChainSpec_WasmConfig {
::std::default::Default::default()
}
pub fn get_initial_memory(&self) -> u32 {
self.initial_memory
}
pub fn clear_initial_memory(&mut self) {
self.initial_memory = 0;
}
pub fn set_initial_memory(&mut self, v: u32) {
self.initial_memory = v;
}
pub fn get_max_stack_height(&self) -> u32 {
self.max_stack_height
}
pub fn clear_max_stack_height(&mut self) {
self.max_stack_height = 0;
}
pub fn set_max_stack_height(&mut self, v: u32) {
self.max_stack_height = v;
}
pub fn get_opcode_costs(&self) -> &ChainSpec_WasmConfig_OpcodeCosts {
self.opcode_costs.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_OpcodeCosts::default_instance())
}
pub fn clear_opcode_costs(&mut self) {
self.opcode_costs.clear();
}
pub fn has_opcode_costs(&self) -> bool {
self.opcode_costs.is_some()
}
pub fn set_opcode_costs(&mut self, v: ChainSpec_WasmConfig_OpcodeCosts) {
self.opcode_costs = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_opcode_costs(&mut self) -> &mut ChainSpec_WasmConfig_OpcodeCosts {
if self.opcode_costs.is_none() {
self.opcode_costs.set_default();
}
self.opcode_costs.as_mut().unwrap()
}
pub fn take_opcode_costs(&mut self) -> ChainSpec_WasmConfig_OpcodeCosts {
self.opcode_costs.take().unwrap_or_else(|| ChainSpec_WasmConfig_OpcodeCosts::new())
}
pub fn get_storage_costs(&self) -> &ChainSpec_WasmConfig_StorageCosts {
self.storage_costs.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_StorageCosts::default_instance())
}
pub fn clear_storage_costs(&mut self) {
self.storage_costs.clear();
}
pub fn has_storage_costs(&self) -> bool {
self.storage_costs.is_some()
}
pub fn set_storage_costs(&mut self, v: ChainSpec_WasmConfig_StorageCosts) {
self.storage_costs = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_storage_costs(&mut self) -> &mut ChainSpec_WasmConfig_StorageCosts {
if self.storage_costs.is_none() {
self.storage_costs.set_default();
}
self.storage_costs.as_mut().unwrap()
}
pub fn take_storage_costs(&mut self) -> ChainSpec_WasmConfig_StorageCosts {
self.storage_costs.take().unwrap_or_else(|| ChainSpec_WasmConfig_StorageCosts::new())
}
pub fn get_host_function_costs(&self) -> &ChainSpec_WasmConfig_HostFunctionCosts {
self.host_function_costs.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts::default_instance())
}
pub fn clear_host_function_costs(&mut self) {
self.host_function_costs.clear();
}
pub fn has_host_function_costs(&self) -> bool {
self.host_function_costs.is_some()
}
pub fn set_host_function_costs(&mut self, v: ChainSpec_WasmConfig_HostFunctionCosts) {
self.host_function_costs = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_host_function_costs(&mut self) -> &mut ChainSpec_WasmConfig_HostFunctionCosts {
if self.host_function_costs.is_none() {
self.host_function_costs.set_default();
}
self.host_function_costs.as_mut().unwrap()
}
pub fn take_host_function_costs(&mut self) -> ChainSpec_WasmConfig_HostFunctionCosts {
self.host_function_costs.take().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts::new())
}
}
impl ::protobuf::Message for ChainSpec_WasmConfig {
fn is_initialized(&self) -> bool {
for v in &self.opcode_costs {
if !v.is_initialized() {
return false;
}
};
for v in &self.storage_costs {
if !v.is_initialized() {
return false;
}
};
for v in &self.host_function_costs {
if !v.is_initialized() {
return false;
}
};
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_uint32()?;
self.initial_memory = tmp;
},
2 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_uint32()?;
self.max_stack_height = tmp;
},
3 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.opcode_costs)?;
},
4 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.storage_costs)?;
},
5 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.host_function_costs)?;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if self.initial_memory != 0 {
my_size += ::protobuf::rt::value_size(1, self.initial_memory, ::protobuf::wire_format::WireTypeVarint);
}
if self.max_stack_height != 0 {
my_size += ::protobuf::rt::value_size(2, self.max_stack_height, ::protobuf::wire_format::WireTypeVarint);
}
if let Some(ref v) = self.opcode_costs.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.storage_costs.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.host_function_costs.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if self.initial_memory != 0 {
os.write_uint32(1, self.initial_memory)?;
}
if self.max_stack_height != 0 {
os.write_uint32(2, self.max_stack_height)?;
}
if let Some(ref v) = self.opcode_costs.as_ref() {
os.write_tag(3, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.storage_costs.as_ref() {
os.write_tag(4, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.host_function_costs.as_ref() {
os.write_tag(5, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> ChainSpec_WasmConfig {
ChainSpec_WasmConfig::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeUint32>(
"initial_memory",
|m: &ChainSpec_WasmConfig| { &m.initial_memory },
|m: &mut ChainSpec_WasmConfig| { &mut m.initial_memory },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeUint32>(
"max_stack_height",
|m: &ChainSpec_WasmConfig| { &m.max_stack_height },
|m: &mut ChainSpec_WasmConfig| { &mut m.max_stack_height },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_OpcodeCosts>>(
"opcode_costs",
|m: &ChainSpec_WasmConfig| { &m.opcode_costs },
|m: &mut ChainSpec_WasmConfig| { &mut m.opcode_costs },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_StorageCosts>>(
"storage_costs",
|m: &ChainSpec_WasmConfig| { &m.storage_costs },
|m: &mut ChainSpec_WasmConfig| { &mut m.storage_costs },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_HostFunctionCosts>>(
"host_function_costs",
|m: &ChainSpec_WasmConfig| { &m.host_function_costs },
|m: &mut ChainSpec_WasmConfig| { &mut m.host_function_costs },
));
::protobuf::reflect::MessageDescriptor::new::<ChainSpec_WasmConfig>(
"ChainSpec_WasmConfig",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static ChainSpec_WasmConfig {
static mut instance: ::protobuf::lazy::Lazy<ChainSpec_WasmConfig> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ChainSpec_WasmConfig,
};
unsafe {
instance.get(ChainSpec_WasmConfig::new)
}
}
}
impl ::protobuf::Clear for ChainSpec_WasmConfig {
fn clear(&mut self) {
self.initial_memory = 0;
self.max_stack_height = 0;
self.opcode_costs.clear();
self.storage_costs.clear();
self.host_function_costs.clear();
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for ChainSpec_WasmConfig {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for ChainSpec_WasmConfig {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct ChainSpec_WasmConfig_OpcodeCosts {
pub bit: u32,
pub add: u32,
pub mul: u32,
pub div: u32,
pub load: u32,
pub store: u32,
pub field_const: u32,
pub local: u32,
pub global: u32,
pub control_flow: u32,
pub integer_comparsion: u32,
pub conversion: u32,
pub unreachable: u32,
pub nop: u32,
pub current_memory: u32,
pub grow_memory: u32,
pub regular: u32,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a ChainSpec_WasmConfig_OpcodeCosts {
fn default() -> &'a ChainSpec_WasmConfig_OpcodeCosts {
<ChainSpec_WasmConfig_OpcodeCosts as ::protobuf::Message>::default_instance()
}
}
impl ChainSpec_WasmConfig_OpcodeCosts {
pub fn new() -> ChainSpec_WasmConfig_OpcodeCosts {
::std::default::Default::default()
}
pub fn get_bit(&self) -> u32 {
self.bit
}
pub fn clear_bit(&mut self) {
self.bit = 0;
}
pub fn set_bit(&mut self, v: u32) {
self.bit = v;
}
pub fn get_add(&self) -> u32 {
self.add
}
pub fn clear_add(&mut self) {
self.add = 0;
}
pub fn set_add(&mut self, v: u32) {
self.add = v;
}
pub fn get_mul(&self) -> u32 {
self.mul
}
pub fn clear_mul(&mut self) {
self.mul = 0;
}
pub fn set_mul(&mut self, v: u32) {
self.mul = v;
}
pub fn get_div(&self) -> u32 {
self.div
}
pub fn clear_div(&mut self) {
self.div = 0;
}
pub fn set_div(&mut self, v: u32) {
self.div = v;
}
pub fn get_load(&self) -> u32 {
self.load
}
pub fn clear_load(&mut self) {
self.load = 0;
}
pub fn set_load(&mut self, v: u32) {
self.load = v;
}
pub fn get_store(&self) -> u32 {
self.store
}
pub fn clear_store(&mut self) {
self.store = 0;
}
pub fn set_store(&mut self, v: u32) {
self.store = v;
}
pub fn get_field_const(&self) -> u32 {
self.field_const
}
pub fn clear_field_const(&mut self) {
self.field_const = 0;
}
pub fn set_field_const(&mut self, v: u32) {
self.field_const = v;
}
pub fn get_local(&self) -> u32 {
self.local
}
pub fn clear_local(&mut self) {
self.local = 0;
}
pub fn set_local(&mut self, v: u32) {
self.local = v;
}
pub fn get_global(&self) -> u32 {
self.global
}
pub fn clear_global(&mut self) {
self.global = 0;
}
pub fn set_global(&mut self, v: u32) {
self.global = v;
}
pub fn get_control_flow(&self) -> u32 {
self.control_flow
}
pub fn clear_control_flow(&mut self) {
self.control_flow = 0;
}
pub fn set_control_flow(&mut self, v: u32) {
self.control_flow = v;
}
pub fn get_integer_comparsion(&self) -> u32 {
self.integer_comparsion
}
pub fn clear_integer_comparsion(&mut self) {
self.integer_comparsion = 0;
}
pub fn set_integer_comparsion(&mut self, v: u32) {
self.integer_comparsion = v;
}
pub fn get_conversion(&self) -> u32 {
self.conversion
}
pub fn clear_conversion(&mut self) {
self.conversion = 0;
}
pub fn set_conversion(&mut self, v: u32) {
self.conversion = v;
}
pub fn get_unreachable(&self) -> u32 {
self.unreachable
}
pub fn clear_unreachable(&mut self) {
self.unreachable = 0;
}
pub fn set_unreachable(&mut self, v: u32) {
self.unreachable = v;
}
pub fn get_nop(&self) -> u32 {
self.nop
}
pub fn clear_nop(&mut self) {
self.nop = 0;
}
pub fn set_nop(&mut self, v: u32) {
self.nop = v;
}
pub fn get_current_memory(&self) -> u32 {
self.current_memory
}
pub fn clear_current_memory(&mut self) {
self.current_memory = 0;
}
pub fn set_current_memory(&mut self, v: u32) {
self.current_memory = v;
}
pub fn get_grow_memory(&self) -> u32 {
self.grow_memory
}
pub fn clear_grow_memory(&mut self) {
self.grow_memory = 0;
}
pub fn set_grow_memory(&mut self, v: u32) {
self.grow_memory = v;
}
pub fn get_regular(&self) -> u32 {
self.regular
}
pub fn clear_regular(&mut self) {
self.regular = 0;
}
pub fn set_regular(&mut self, v: u32) {
self.regular = v;
}
}
impl ::protobuf::Message for ChainSpec_WasmConfig_OpcodeCosts {
fn is_initialized(&self) -> bool {
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_uint32()?;
self.bit = tmp;
},
2 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_uint32()?;
self.add = tmp;
},
3 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_uint32()?;
self.mul = tmp;
},
4 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_uint32()?;
self.div = tmp;
},
5 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_uint32()?;
self.load = tmp;
},
6 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_uint32()?;
self.store = tmp;
},
7 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_uint32()?;
self.field_const = tmp;
},
8 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_uint32()?;
self.local = tmp;
},
9 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_uint32()?;
self.global = tmp;
},
10 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_uint32()?;
self.control_flow = tmp;
},
11 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_uint32()?;
self.integer_comparsion = tmp;
},
12 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_uint32()?;
self.conversion = tmp;
},
14 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_uint32()?;
self.unreachable = tmp;
},
15 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_uint32()?;
self.nop = tmp;
},
16 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_uint32()?;
self.current_memory = tmp;
},
17 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_uint32()?;
self.grow_memory = tmp;
},
18 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_uint32()?;
self.regular = tmp;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if self.bit != 0 {
my_size += ::protobuf::rt::value_size(1, self.bit, ::protobuf::wire_format::WireTypeVarint);
}
if self.add != 0 {
my_size += ::protobuf::rt::value_size(2, self.add, ::protobuf::wire_format::WireTypeVarint);
}
if self.mul != 0 {
my_size += ::protobuf::rt::value_size(3, self.mul, ::protobuf::wire_format::WireTypeVarint);
}
if self.div != 0 {
my_size += ::protobuf::rt::value_size(4, self.div, ::protobuf::wire_format::WireTypeVarint);
}
if self.load != 0 {
my_size += ::protobuf::rt::value_size(5, self.load, ::protobuf::wire_format::WireTypeVarint);
}
if self.store != 0 {
my_size += ::protobuf::rt::value_size(6, self.store, ::protobuf::wire_format::WireTypeVarint);
}
if self.field_const != 0 {
my_size += ::protobuf::rt::value_size(7, self.field_const, ::protobuf::wire_format::WireTypeVarint);
}
if self.local != 0 {
my_size += ::protobuf::rt::value_size(8, self.local, ::protobuf::wire_format::WireTypeVarint);
}
if self.global != 0 {
my_size += ::protobuf::rt::value_size(9, self.global, ::protobuf::wire_format::WireTypeVarint);
}
if self.control_flow != 0 {
my_size += ::protobuf::rt::value_size(10, self.control_flow, ::protobuf::wire_format::WireTypeVarint);
}
if self.integer_comparsion != 0 {
my_size += ::protobuf::rt::value_size(11, self.integer_comparsion, ::protobuf::wire_format::WireTypeVarint);
}
if self.conversion != 0 {
my_size += ::protobuf::rt::value_size(12, self.conversion, ::protobuf::wire_format::WireTypeVarint);
}
if self.unreachable != 0 {
my_size += ::protobuf::rt::value_size(14, self.unreachable, ::protobuf::wire_format::WireTypeVarint);
}
if self.nop != 0 {
my_size += ::protobuf::rt::value_size(15, self.nop, ::protobuf::wire_format::WireTypeVarint);
}
if self.current_memory != 0 {
my_size += ::protobuf::rt::value_size(16, self.current_memory, ::protobuf::wire_format::WireTypeVarint);
}
if self.grow_memory != 0 {
my_size += ::protobuf::rt::value_size(17, self.grow_memory, ::protobuf::wire_format::WireTypeVarint);
}
if self.regular != 0 {
my_size += ::protobuf::rt::value_size(18, self.regular, ::protobuf::wire_format::WireTypeVarint);
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if self.bit != 0 {
os.write_uint32(1, self.bit)?;
}
if self.add != 0 {
os.write_uint32(2, self.add)?;
}
if self.mul != 0 {
os.write_uint32(3, self.mul)?;
}
if self.div != 0 {
os.write_uint32(4, self.div)?;
}
if self.load != 0 {
os.write_uint32(5, self.load)?;
}
if self.store != 0 {
os.write_uint32(6, self.store)?;
}
if self.field_const != 0 {
os.write_uint32(7, self.field_const)?;
}
if self.local != 0 {
os.write_uint32(8, self.local)?;
}
if self.global != 0 {
os.write_uint32(9, self.global)?;
}
if self.control_flow != 0 {
os.write_uint32(10, self.control_flow)?;
}
if self.integer_comparsion != 0 {
os.write_uint32(11, self.integer_comparsion)?;
}
if self.conversion != 0 {
os.write_uint32(12, self.conversion)?;
}
if self.unreachable != 0 {
os.write_uint32(14, self.unreachable)?;
}
if self.nop != 0 {
os.write_uint32(15, self.nop)?;
}
if self.current_memory != 0 {
os.write_uint32(16, self.current_memory)?;
}
if self.grow_memory != 0 {
os.write_uint32(17, self.grow_memory)?;
}
if self.regular != 0 {
os.write_uint32(18, self.regular)?;
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> ChainSpec_WasmConfig_OpcodeCosts {
ChainSpec_WasmConfig_OpcodeCosts::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeUint32>(
"bit",
|m: &ChainSpec_WasmConfig_OpcodeCosts| { &m.bit },
|m: &mut ChainSpec_WasmConfig_OpcodeCosts| { &mut m.bit },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeUint32>(
"add",
|m: &ChainSpec_WasmConfig_OpcodeCosts| { &m.add },
|m: &mut ChainSpec_WasmConfig_OpcodeCosts| { &mut m.add },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeUint32>(
"mul",
|m: &ChainSpec_WasmConfig_OpcodeCosts| { &m.mul },
|m: &mut ChainSpec_WasmConfig_OpcodeCosts| { &mut m.mul },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeUint32>(
"div",
|m: &ChainSpec_WasmConfig_OpcodeCosts| { &m.div },
|m: &mut ChainSpec_WasmConfig_OpcodeCosts| { &mut m.div },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeUint32>(
"load",
|m: &ChainSpec_WasmConfig_OpcodeCosts| { &m.load },
|m: &mut ChainSpec_WasmConfig_OpcodeCosts| { &mut m.load },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeUint32>(
"store",
|m: &ChainSpec_WasmConfig_OpcodeCosts| { &m.store },
|m: &mut ChainSpec_WasmConfig_OpcodeCosts| { &mut m.store },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeUint32>(
"const",
|m: &ChainSpec_WasmConfig_OpcodeCosts| { &m.field_const },
|m: &mut ChainSpec_WasmConfig_OpcodeCosts| { &mut m.field_const },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeUint32>(
"local",
|m: &ChainSpec_WasmConfig_OpcodeCosts| { &m.local },
|m: &mut ChainSpec_WasmConfig_OpcodeCosts| { &mut m.local },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeUint32>(
"global",
|m: &ChainSpec_WasmConfig_OpcodeCosts| { &m.global },
|m: &mut ChainSpec_WasmConfig_OpcodeCosts| { &mut m.global },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeUint32>(
"control_flow",
|m: &ChainSpec_WasmConfig_OpcodeCosts| { &m.control_flow },
|m: &mut ChainSpec_WasmConfig_OpcodeCosts| { &mut m.control_flow },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeUint32>(
"integer_comparsion",
|m: &ChainSpec_WasmConfig_OpcodeCosts| { &m.integer_comparsion },
|m: &mut ChainSpec_WasmConfig_OpcodeCosts| { &mut m.integer_comparsion },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeUint32>(
"conversion",
|m: &ChainSpec_WasmConfig_OpcodeCosts| { &m.conversion },
|m: &mut ChainSpec_WasmConfig_OpcodeCosts| { &mut m.conversion },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeUint32>(
"unreachable",
|m: &ChainSpec_WasmConfig_OpcodeCosts| { &m.unreachable },
|m: &mut ChainSpec_WasmConfig_OpcodeCosts| { &mut m.unreachable },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeUint32>(
"nop",
|m: &ChainSpec_WasmConfig_OpcodeCosts| { &m.nop },
|m: &mut ChainSpec_WasmConfig_OpcodeCosts| { &mut m.nop },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeUint32>(
"current_memory",
|m: &ChainSpec_WasmConfig_OpcodeCosts| { &m.current_memory },
|m: &mut ChainSpec_WasmConfig_OpcodeCosts| { &mut m.current_memory },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeUint32>(
"grow_memory",
|m: &ChainSpec_WasmConfig_OpcodeCosts| { &m.grow_memory },
|m: &mut ChainSpec_WasmConfig_OpcodeCosts| { &mut m.grow_memory },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeUint32>(
"regular",
|m: &ChainSpec_WasmConfig_OpcodeCosts| { &m.regular },
|m: &mut ChainSpec_WasmConfig_OpcodeCosts| { &mut m.regular },
));
::protobuf::reflect::MessageDescriptor::new::<ChainSpec_WasmConfig_OpcodeCosts>(
"ChainSpec_WasmConfig_OpcodeCosts",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static ChainSpec_WasmConfig_OpcodeCosts {
static mut instance: ::protobuf::lazy::Lazy<ChainSpec_WasmConfig_OpcodeCosts> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ChainSpec_WasmConfig_OpcodeCosts,
};
unsafe {
instance.get(ChainSpec_WasmConfig_OpcodeCosts::new)
}
}
}
impl ::protobuf::Clear for ChainSpec_WasmConfig_OpcodeCosts {
fn clear(&mut self) {
self.bit = 0;
self.add = 0;
self.mul = 0;
self.div = 0;
self.load = 0;
self.store = 0;
self.field_const = 0;
self.local = 0;
self.global = 0;
self.control_flow = 0;
self.integer_comparsion = 0;
self.conversion = 0;
self.unreachable = 0;
self.nop = 0;
self.current_memory = 0;
self.grow_memory = 0;
self.regular = 0;
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for ChainSpec_WasmConfig_OpcodeCosts {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for ChainSpec_WasmConfig_OpcodeCosts {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct ChainSpec_WasmConfig_StorageCosts {
pub gas_per_byte: u32,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a ChainSpec_WasmConfig_StorageCosts {
fn default() -> &'a ChainSpec_WasmConfig_StorageCosts {
<ChainSpec_WasmConfig_StorageCosts as ::protobuf::Message>::default_instance()
}
}
impl ChainSpec_WasmConfig_StorageCosts {
pub fn new() -> ChainSpec_WasmConfig_StorageCosts {
::std::default::Default::default()
}
pub fn get_gas_per_byte(&self) -> u32 {
self.gas_per_byte
}
pub fn clear_gas_per_byte(&mut self) {
self.gas_per_byte = 0;
}
pub fn set_gas_per_byte(&mut self, v: u32) {
self.gas_per_byte = v;
}
}
impl ::protobuf::Message for ChainSpec_WasmConfig_StorageCosts {
fn is_initialized(&self) -> bool {
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_uint32()?;
self.gas_per_byte = tmp;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if self.gas_per_byte != 0 {
my_size += ::protobuf::rt::value_size(1, self.gas_per_byte, ::protobuf::wire_format::WireTypeVarint);
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if self.gas_per_byte != 0 {
os.write_uint32(1, self.gas_per_byte)?;
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> ChainSpec_WasmConfig_StorageCosts {
ChainSpec_WasmConfig_StorageCosts::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeUint32>(
"gas_per_byte",
|m: &ChainSpec_WasmConfig_StorageCosts| { &m.gas_per_byte },
|m: &mut ChainSpec_WasmConfig_StorageCosts| { &mut m.gas_per_byte },
));
::protobuf::reflect::MessageDescriptor::new::<ChainSpec_WasmConfig_StorageCosts>(
"ChainSpec_WasmConfig_StorageCosts",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static ChainSpec_WasmConfig_StorageCosts {
static mut instance: ::protobuf::lazy::Lazy<ChainSpec_WasmConfig_StorageCosts> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ChainSpec_WasmConfig_StorageCosts,
};
unsafe {
instance.get(ChainSpec_WasmConfig_StorageCosts::new)
}
}
}
impl ::protobuf::Clear for ChainSpec_WasmConfig_StorageCosts {
fn clear(&mut self) {
self.gas_per_byte = 0;
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for ChainSpec_WasmConfig_StorageCosts {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for ChainSpec_WasmConfig_StorageCosts {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct ChainSpec_WasmConfig_HostFunctionCosts {
pub read_value: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>,
pub read_value_local: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>,
pub write: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>,
pub write_local: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>,
pub add: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>,
pub new_uref: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>,
pub load_named_keys: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>,
pub ret: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>,
pub get_key: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>,
pub has_key: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>,
pub put_key: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>,
pub remove_key: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>,
pub revert: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>,
pub is_valid_uref: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>,
pub add_associated_key: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>,
pub remove_associated_key: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>,
pub update_associated_key: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>,
pub set_action_threshold: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>,
pub get_caller: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>,
pub get_blocktime: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>,
pub create_purse: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>,
pub transfer_to_account: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>,
pub transfer_from_purse_to_account: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>,
pub transfer_from_purse_to_purse: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>,
pub get_balance: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>,
pub get_phase: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>,
pub get_system_contract: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>,
pub get_main_purse: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>,
pub read_host_buffer: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>,
pub create_contract_package_at_hash: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>,
pub create_contract_user_group: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>,
pub add_contract_version: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>,
pub disable_contract_version: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>,
pub call_contract: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>,
pub call_versioned_contract: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>,
pub get_named_arg_size: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>,
pub get_named_arg: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>,
pub remove_contract_user_group: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>,
pub provision_contract_user_group_uref: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>,
pub remove_contract_user_group_urefs: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>,
pub print: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>,
pub blake2b: ::protobuf::SingularPtrField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a ChainSpec_WasmConfig_HostFunctionCosts {
fn default() -> &'a ChainSpec_WasmConfig_HostFunctionCosts {
<ChainSpec_WasmConfig_HostFunctionCosts as ::protobuf::Message>::default_instance()
}
}
impl ChainSpec_WasmConfig_HostFunctionCosts {
pub fn new() -> ChainSpec_WasmConfig_HostFunctionCosts {
::std::default::Default::default()
}
pub fn get_read_value(&self) -> &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.read_value.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::default_instance())
}
pub fn clear_read_value(&mut self) {
self.read_value.clear();
}
pub fn has_read_value(&self) -> bool {
self.read_value.is_some()
}
pub fn set_read_value(&mut self, v: ChainSpec_WasmConfig_HostFunctionCosts_HostFunction) {
self.read_value = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_read_value(&mut self) -> &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
if self.read_value.is_none() {
self.read_value.set_default();
}
self.read_value.as_mut().unwrap()
}
pub fn take_read_value(&mut self) -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.read_value.take().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::new())
}
pub fn get_read_value_local(&self) -> &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.read_value_local.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::default_instance())
}
pub fn clear_read_value_local(&mut self) {
self.read_value_local.clear();
}
pub fn has_read_value_local(&self) -> bool {
self.read_value_local.is_some()
}
pub fn set_read_value_local(&mut self, v: ChainSpec_WasmConfig_HostFunctionCosts_HostFunction) {
self.read_value_local = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_read_value_local(&mut self) -> &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
if self.read_value_local.is_none() {
self.read_value_local.set_default();
}
self.read_value_local.as_mut().unwrap()
}
pub fn take_read_value_local(&mut self) -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.read_value_local.take().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::new())
}
pub fn get_write(&self) -> &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.write.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::default_instance())
}
pub fn clear_write(&mut self) {
self.write.clear();
}
pub fn has_write(&self) -> bool {
self.write.is_some()
}
pub fn set_write(&mut self, v: ChainSpec_WasmConfig_HostFunctionCosts_HostFunction) {
self.write = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_write(&mut self) -> &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
if self.write.is_none() {
self.write.set_default();
}
self.write.as_mut().unwrap()
}
pub fn take_write(&mut self) -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.write.take().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::new())
}
pub fn get_write_local(&self) -> &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.write_local.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::default_instance())
}
pub fn clear_write_local(&mut self) {
self.write_local.clear();
}
pub fn has_write_local(&self) -> bool {
self.write_local.is_some()
}
pub fn set_write_local(&mut self, v: ChainSpec_WasmConfig_HostFunctionCosts_HostFunction) {
self.write_local = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_write_local(&mut self) -> &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
if self.write_local.is_none() {
self.write_local.set_default();
}
self.write_local.as_mut().unwrap()
}
pub fn take_write_local(&mut self) -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.write_local.take().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::new())
}
pub fn get_add(&self) -> &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.add.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::default_instance())
}
pub fn clear_add(&mut self) {
self.add.clear();
}
pub fn has_add(&self) -> bool {
self.add.is_some()
}
pub fn set_add(&mut self, v: ChainSpec_WasmConfig_HostFunctionCosts_HostFunction) {
self.add = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_add(&mut self) -> &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
if self.add.is_none() {
self.add.set_default();
}
self.add.as_mut().unwrap()
}
pub fn take_add(&mut self) -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.add.take().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::new())
}
pub fn get_new_uref(&self) -> &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.new_uref.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::default_instance())
}
pub fn clear_new_uref(&mut self) {
self.new_uref.clear();
}
pub fn has_new_uref(&self) -> bool {
self.new_uref.is_some()
}
pub fn set_new_uref(&mut self, v: ChainSpec_WasmConfig_HostFunctionCosts_HostFunction) {
self.new_uref = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_new_uref(&mut self) -> &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
if self.new_uref.is_none() {
self.new_uref.set_default();
}
self.new_uref.as_mut().unwrap()
}
pub fn take_new_uref(&mut self) -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.new_uref.take().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::new())
}
pub fn get_load_named_keys(&self) -> &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.load_named_keys.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::default_instance())
}
pub fn clear_load_named_keys(&mut self) {
self.load_named_keys.clear();
}
pub fn has_load_named_keys(&self) -> bool {
self.load_named_keys.is_some()
}
pub fn set_load_named_keys(&mut self, v: ChainSpec_WasmConfig_HostFunctionCosts_HostFunction) {
self.load_named_keys = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_load_named_keys(&mut self) -> &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
if self.load_named_keys.is_none() {
self.load_named_keys.set_default();
}
self.load_named_keys.as_mut().unwrap()
}
pub fn take_load_named_keys(&mut self) -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.load_named_keys.take().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::new())
}
pub fn get_ret(&self) -> &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.ret.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::default_instance())
}
pub fn clear_ret(&mut self) {
self.ret.clear();
}
pub fn has_ret(&self) -> bool {
self.ret.is_some()
}
pub fn set_ret(&mut self, v: ChainSpec_WasmConfig_HostFunctionCosts_HostFunction) {
self.ret = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_ret(&mut self) -> &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
if self.ret.is_none() {
self.ret.set_default();
}
self.ret.as_mut().unwrap()
}
pub fn take_ret(&mut self) -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.ret.take().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::new())
}
pub fn get_get_key(&self) -> &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.get_key.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::default_instance())
}
pub fn clear_get_key(&mut self) {
self.get_key.clear();
}
pub fn has_get_key(&self) -> bool {
self.get_key.is_some()
}
pub fn set_get_key(&mut self, v: ChainSpec_WasmConfig_HostFunctionCosts_HostFunction) {
self.get_key = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_get_key(&mut self) -> &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
if self.get_key.is_none() {
self.get_key.set_default();
}
self.get_key.as_mut().unwrap()
}
pub fn take_get_key(&mut self) -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.get_key.take().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::new())
}
pub fn get_has_key(&self) -> &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.has_key.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::default_instance())
}
pub fn clear_has_key(&mut self) {
self.has_key.clear();
}
pub fn has_has_key(&self) -> bool {
self.has_key.is_some()
}
pub fn set_has_key(&mut self, v: ChainSpec_WasmConfig_HostFunctionCosts_HostFunction) {
self.has_key = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_has_key(&mut self) -> &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
if self.has_key.is_none() {
self.has_key.set_default();
}
self.has_key.as_mut().unwrap()
}
pub fn take_has_key(&mut self) -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.has_key.take().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::new())
}
pub fn get_put_key(&self) -> &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.put_key.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::default_instance())
}
pub fn clear_put_key(&mut self) {
self.put_key.clear();
}
pub fn has_put_key(&self) -> bool {
self.put_key.is_some()
}
pub fn set_put_key(&mut self, v: ChainSpec_WasmConfig_HostFunctionCosts_HostFunction) {
self.put_key = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_put_key(&mut self) -> &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
if self.put_key.is_none() {
self.put_key.set_default();
}
self.put_key.as_mut().unwrap()
}
pub fn take_put_key(&mut self) -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.put_key.take().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::new())
}
pub fn get_remove_key(&self) -> &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.remove_key.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::default_instance())
}
pub fn clear_remove_key(&mut self) {
self.remove_key.clear();
}
pub fn has_remove_key(&self) -> bool {
self.remove_key.is_some()
}
pub fn set_remove_key(&mut self, v: ChainSpec_WasmConfig_HostFunctionCosts_HostFunction) {
self.remove_key = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_remove_key(&mut self) -> &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
if self.remove_key.is_none() {
self.remove_key.set_default();
}
self.remove_key.as_mut().unwrap()
}
pub fn take_remove_key(&mut self) -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.remove_key.take().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::new())
}
pub fn get_revert(&self) -> &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.revert.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::default_instance())
}
pub fn clear_revert(&mut self) {
self.revert.clear();
}
pub fn has_revert(&self) -> bool {
self.revert.is_some()
}
pub fn set_revert(&mut self, v: ChainSpec_WasmConfig_HostFunctionCosts_HostFunction) {
self.revert = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_revert(&mut self) -> &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
if self.revert.is_none() {
self.revert.set_default();
}
self.revert.as_mut().unwrap()
}
pub fn take_revert(&mut self) -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.revert.take().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::new())
}
pub fn get_is_valid_uref(&self) -> &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.is_valid_uref.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::default_instance())
}
pub fn clear_is_valid_uref(&mut self) {
self.is_valid_uref.clear();
}
pub fn has_is_valid_uref(&self) -> bool {
self.is_valid_uref.is_some()
}
pub fn set_is_valid_uref(&mut self, v: ChainSpec_WasmConfig_HostFunctionCosts_HostFunction) {
self.is_valid_uref = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_is_valid_uref(&mut self) -> &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
if self.is_valid_uref.is_none() {
self.is_valid_uref.set_default();
}
self.is_valid_uref.as_mut().unwrap()
}
pub fn take_is_valid_uref(&mut self) -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.is_valid_uref.take().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::new())
}
pub fn get_add_associated_key(&self) -> &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.add_associated_key.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::default_instance())
}
pub fn clear_add_associated_key(&mut self) {
self.add_associated_key.clear();
}
pub fn has_add_associated_key(&self) -> bool {
self.add_associated_key.is_some()
}
pub fn set_add_associated_key(&mut self, v: ChainSpec_WasmConfig_HostFunctionCosts_HostFunction) {
self.add_associated_key = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_add_associated_key(&mut self) -> &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
if self.add_associated_key.is_none() {
self.add_associated_key.set_default();
}
self.add_associated_key.as_mut().unwrap()
}
pub fn take_add_associated_key(&mut self) -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.add_associated_key.take().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::new())
}
pub fn get_remove_associated_key(&self) -> &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.remove_associated_key.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::default_instance())
}
pub fn clear_remove_associated_key(&mut self) {
self.remove_associated_key.clear();
}
pub fn has_remove_associated_key(&self) -> bool {
self.remove_associated_key.is_some()
}
pub fn set_remove_associated_key(&mut self, v: ChainSpec_WasmConfig_HostFunctionCosts_HostFunction) {
self.remove_associated_key = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_remove_associated_key(&mut self) -> &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
if self.remove_associated_key.is_none() {
self.remove_associated_key.set_default();
}
self.remove_associated_key.as_mut().unwrap()
}
pub fn take_remove_associated_key(&mut self) -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.remove_associated_key.take().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::new())
}
pub fn get_update_associated_key(&self) -> &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.update_associated_key.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::default_instance())
}
pub fn clear_update_associated_key(&mut self) {
self.update_associated_key.clear();
}
pub fn has_update_associated_key(&self) -> bool {
self.update_associated_key.is_some()
}
pub fn set_update_associated_key(&mut self, v: ChainSpec_WasmConfig_HostFunctionCosts_HostFunction) {
self.update_associated_key = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_update_associated_key(&mut self) -> &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
if self.update_associated_key.is_none() {
self.update_associated_key.set_default();
}
self.update_associated_key.as_mut().unwrap()
}
pub fn take_update_associated_key(&mut self) -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.update_associated_key.take().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::new())
}
pub fn get_set_action_threshold(&self) -> &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.set_action_threshold.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::default_instance())
}
pub fn clear_set_action_threshold(&mut self) {
self.set_action_threshold.clear();
}
pub fn has_set_action_threshold(&self) -> bool {
self.set_action_threshold.is_some()
}
pub fn set_set_action_threshold(&mut self, v: ChainSpec_WasmConfig_HostFunctionCosts_HostFunction) {
self.set_action_threshold = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_set_action_threshold(&mut self) -> &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
if self.set_action_threshold.is_none() {
self.set_action_threshold.set_default();
}
self.set_action_threshold.as_mut().unwrap()
}
pub fn take_set_action_threshold(&mut self) -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.set_action_threshold.take().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::new())
}
pub fn get_get_caller(&self) -> &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.get_caller.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::default_instance())
}
pub fn clear_get_caller(&mut self) {
self.get_caller.clear();
}
pub fn has_get_caller(&self) -> bool {
self.get_caller.is_some()
}
pub fn set_get_caller(&mut self, v: ChainSpec_WasmConfig_HostFunctionCosts_HostFunction) {
self.get_caller = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_get_caller(&mut self) -> &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
if self.get_caller.is_none() {
self.get_caller.set_default();
}
self.get_caller.as_mut().unwrap()
}
pub fn take_get_caller(&mut self) -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.get_caller.take().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::new())
}
pub fn get_get_blocktime(&self) -> &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.get_blocktime.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::default_instance())
}
pub fn clear_get_blocktime(&mut self) {
self.get_blocktime.clear();
}
pub fn has_get_blocktime(&self) -> bool {
self.get_blocktime.is_some()
}
pub fn set_get_blocktime(&mut self, v: ChainSpec_WasmConfig_HostFunctionCosts_HostFunction) {
self.get_blocktime = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_get_blocktime(&mut self) -> &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
if self.get_blocktime.is_none() {
self.get_blocktime.set_default();
}
self.get_blocktime.as_mut().unwrap()
}
pub fn take_get_blocktime(&mut self) -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.get_blocktime.take().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::new())
}
pub fn get_create_purse(&self) -> &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.create_purse.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::default_instance())
}
pub fn clear_create_purse(&mut self) {
self.create_purse.clear();
}
pub fn has_create_purse(&self) -> bool {
self.create_purse.is_some()
}
pub fn set_create_purse(&mut self, v: ChainSpec_WasmConfig_HostFunctionCosts_HostFunction) {
self.create_purse = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_create_purse(&mut self) -> &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
if self.create_purse.is_none() {
self.create_purse.set_default();
}
self.create_purse.as_mut().unwrap()
}
pub fn take_create_purse(&mut self) -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.create_purse.take().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::new())
}
pub fn get_transfer_to_account(&self) -> &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.transfer_to_account.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::default_instance())
}
pub fn clear_transfer_to_account(&mut self) {
self.transfer_to_account.clear();
}
pub fn has_transfer_to_account(&self) -> bool {
self.transfer_to_account.is_some()
}
pub fn set_transfer_to_account(&mut self, v: ChainSpec_WasmConfig_HostFunctionCosts_HostFunction) {
self.transfer_to_account = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_transfer_to_account(&mut self) -> &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
if self.transfer_to_account.is_none() {
self.transfer_to_account.set_default();
}
self.transfer_to_account.as_mut().unwrap()
}
pub fn take_transfer_to_account(&mut self) -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.transfer_to_account.take().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::new())
}
pub fn get_transfer_from_purse_to_account(&self) -> &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.transfer_from_purse_to_account.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::default_instance())
}
pub fn clear_transfer_from_purse_to_account(&mut self) {
self.transfer_from_purse_to_account.clear();
}
pub fn has_transfer_from_purse_to_account(&self) -> bool {
self.transfer_from_purse_to_account.is_some()
}
pub fn set_transfer_from_purse_to_account(&mut self, v: ChainSpec_WasmConfig_HostFunctionCosts_HostFunction) {
self.transfer_from_purse_to_account = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_transfer_from_purse_to_account(&mut self) -> &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
if self.transfer_from_purse_to_account.is_none() {
self.transfer_from_purse_to_account.set_default();
}
self.transfer_from_purse_to_account.as_mut().unwrap()
}
pub fn take_transfer_from_purse_to_account(&mut self) -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.transfer_from_purse_to_account.take().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::new())
}
pub fn get_transfer_from_purse_to_purse(&self) -> &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.transfer_from_purse_to_purse.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::default_instance())
}
pub fn clear_transfer_from_purse_to_purse(&mut self) {
self.transfer_from_purse_to_purse.clear();
}
pub fn has_transfer_from_purse_to_purse(&self) -> bool {
self.transfer_from_purse_to_purse.is_some()
}
pub fn set_transfer_from_purse_to_purse(&mut self, v: ChainSpec_WasmConfig_HostFunctionCosts_HostFunction) {
self.transfer_from_purse_to_purse = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_transfer_from_purse_to_purse(&mut self) -> &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
if self.transfer_from_purse_to_purse.is_none() {
self.transfer_from_purse_to_purse.set_default();
}
self.transfer_from_purse_to_purse.as_mut().unwrap()
}
pub fn take_transfer_from_purse_to_purse(&mut self) -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.transfer_from_purse_to_purse.take().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::new())
}
pub fn get_get_balance(&self) -> &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.get_balance.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::default_instance())
}
pub fn clear_get_balance(&mut self) {
self.get_balance.clear();
}
pub fn has_get_balance(&self) -> bool {
self.get_balance.is_some()
}
pub fn set_get_balance(&mut self, v: ChainSpec_WasmConfig_HostFunctionCosts_HostFunction) {
self.get_balance = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_get_balance(&mut self) -> &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
if self.get_balance.is_none() {
self.get_balance.set_default();
}
self.get_balance.as_mut().unwrap()
}
pub fn take_get_balance(&mut self) -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.get_balance.take().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::new())
}
pub fn get_get_phase(&self) -> &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.get_phase.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::default_instance())
}
pub fn clear_get_phase(&mut self) {
self.get_phase.clear();
}
pub fn has_get_phase(&self) -> bool {
self.get_phase.is_some()
}
pub fn set_get_phase(&mut self, v: ChainSpec_WasmConfig_HostFunctionCosts_HostFunction) {
self.get_phase = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_get_phase(&mut self) -> &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
if self.get_phase.is_none() {
self.get_phase.set_default();
}
self.get_phase.as_mut().unwrap()
}
pub fn take_get_phase(&mut self) -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.get_phase.take().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::new())
}
pub fn get_get_system_contract(&self) -> &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.get_system_contract.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::default_instance())
}
pub fn clear_get_system_contract(&mut self) {
self.get_system_contract.clear();
}
pub fn has_get_system_contract(&self) -> bool {
self.get_system_contract.is_some()
}
pub fn set_get_system_contract(&mut self, v: ChainSpec_WasmConfig_HostFunctionCosts_HostFunction) {
self.get_system_contract = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_get_system_contract(&mut self) -> &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
if self.get_system_contract.is_none() {
self.get_system_contract.set_default();
}
self.get_system_contract.as_mut().unwrap()
}
pub fn take_get_system_contract(&mut self) -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.get_system_contract.take().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::new())
}
pub fn get_get_main_purse(&self) -> &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.get_main_purse.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::default_instance())
}
pub fn clear_get_main_purse(&mut self) {
self.get_main_purse.clear();
}
pub fn has_get_main_purse(&self) -> bool {
self.get_main_purse.is_some()
}
pub fn set_get_main_purse(&mut self, v: ChainSpec_WasmConfig_HostFunctionCosts_HostFunction) {
self.get_main_purse = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_get_main_purse(&mut self) -> &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
if self.get_main_purse.is_none() {
self.get_main_purse.set_default();
}
self.get_main_purse.as_mut().unwrap()
}
pub fn take_get_main_purse(&mut self) -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.get_main_purse.take().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::new())
}
pub fn get_read_host_buffer(&self) -> &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.read_host_buffer.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::default_instance())
}
pub fn clear_read_host_buffer(&mut self) {
self.read_host_buffer.clear();
}
pub fn has_read_host_buffer(&self) -> bool {
self.read_host_buffer.is_some()
}
pub fn set_read_host_buffer(&mut self, v: ChainSpec_WasmConfig_HostFunctionCosts_HostFunction) {
self.read_host_buffer = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_read_host_buffer(&mut self) -> &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
if self.read_host_buffer.is_none() {
self.read_host_buffer.set_default();
}
self.read_host_buffer.as_mut().unwrap()
}
pub fn take_read_host_buffer(&mut self) -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.read_host_buffer.take().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::new())
}
pub fn get_create_contract_package_at_hash(&self) -> &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.create_contract_package_at_hash.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::default_instance())
}
pub fn clear_create_contract_package_at_hash(&mut self) {
self.create_contract_package_at_hash.clear();
}
pub fn has_create_contract_package_at_hash(&self) -> bool {
self.create_contract_package_at_hash.is_some()
}
pub fn set_create_contract_package_at_hash(&mut self, v: ChainSpec_WasmConfig_HostFunctionCosts_HostFunction) {
self.create_contract_package_at_hash = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_create_contract_package_at_hash(&mut self) -> &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
if self.create_contract_package_at_hash.is_none() {
self.create_contract_package_at_hash.set_default();
}
self.create_contract_package_at_hash.as_mut().unwrap()
}
pub fn take_create_contract_package_at_hash(&mut self) -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.create_contract_package_at_hash.take().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::new())
}
pub fn get_create_contract_user_group(&self) -> &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.create_contract_user_group.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::default_instance())
}
pub fn clear_create_contract_user_group(&mut self) {
self.create_contract_user_group.clear();
}
pub fn has_create_contract_user_group(&self) -> bool {
self.create_contract_user_group.is_some()
}
pub fn set_create_contract_user_group(&mut self, v: ChainSpec_WasmConfig_HostFunctionCosts_HostFunction) {
self.create_contract_user_group = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_create_contract_user_group(&mut self) -> &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
if self.create_contract_user_group.is_none() {
self.create_contract_user_group.set_default();
}
self.create_contract_user_group.as_mut().unwrap()
}
pub fn take_create_contract_user_group(&mut self) -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.create_contract_user_group.take().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::new())
}
pub fn get_add_contract_version(&self) -> &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.add_contract_version.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::default_instance())
}
pub fn clear_add_contract_version(&mut self) {
self.add_contract_version.clear();
}
pub fn has_add_contract_version(&self) -> bool {
self.add_contract_version.is_some()
}
pub fn set_add_contract_version(&mut self, v: ChainSpec_WasmConfig_HostFunctionCosts_HostFunction) {
self.add_contract_version = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_add_contract_version(&mut self) -> &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
if self.add_contract_version.is_none() {
self.add_contract_version.set_default();
}
self.add_contract_version.as_mut().unwrap()
}
pub fn take_add_contract_version(&mut self) -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.add_contract_version.take().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::new())
}
pub fn get_disable_contract_version(&self) -> &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.disable_contract_version.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::default_instance())
}
pub fn clear_disable_contract_version(&mut self) {
self.disable_contract_version.clear();
}
pub fn has_disable_contract_version(&self) -> bool {
self.disable_contract_version.is_some()
}
pub fn set_disable_contract_version(&mut self, v: ChainSpec_WasmConfig_HostFunctionCosts_HostFunction) {
self.disable_contract_version = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_disable_contract_version(&mut self) -> &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
if self.disable_contract_version.is_none() {
self.disable_contract_version.set_default();
}
self.disable_contract_version.as_mut().unwrap()
}
pub fn take_disable_contract_version(&mut self) -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.disable_contract_version.take().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::new())
}
pub fn get_call_contract(&self) -> &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.call_contract.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::default_instance())
}
pub fn clear_call_contract(&mut self) {
self.call_contract.clear();
}
pub fn has_call_contract(&self) -> bool {
self.call_contract.is_some()
}
pub fn set_call_contract(&mut self, v: ChainSpec_WasmConfig_HostFunctionCosts_HostFunction) {
self.call_contract = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_call_contract(&mut self) -> &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
if self.call_contract.is_none() {
self.call_contract.set_default();
}
self.call_contract.as_mut().unwrap()
}
pub fn take_call_contract(&mut self) -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.call_contract.take().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::new())
}
pub fn get_call_versioned_contract(&self) -> &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.call_versioned_contract.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::default_instance())
}
pub fn clear_call_versioned_contract(&mut self) {
self.call_versioned_contract.clear();
}
pub fn has_call_versioned_contract(&self) -> bool {
self.call_versioned_contract.is_some()
}
pub fn set_call_versioned_contract(&mut self, v: ChainSpec_WasmConfig_HostFunctionCosts_HostFunction) {
self.call_versioned_contract = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_call_versioned_contract(&mut self) -> &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
if self.call_versioned_contract.is_none() {
self.call_versioned_contract.set_default();
}
self.call_versioned_contract.as_mut().unwrap()
}
pub fn take_call_versioned_contract(&mut self) -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.call_versioned_contract.take().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::new())
}
pub fn get_get_named_arg_size(&self) -> &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.get_named_arg_size.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::default_instance())
}
pub fn clear_get_named_arg_size(&mut self) {
self.get_named_arg_size.clear();
}
pub fn has_get_named_arg_size(&self) -> bool {
self.get_named_arg_size.is_some()
}
pub fn set_get_named_arg_size(&mut self, v: ChainSpec_WasmConfig_HostFunctionCosts_HostFunction) {
self.get_named_arg_size = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_get_named_arg_size(&mut self) -> &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
if self.get_named_arg_size.is_none() {
self.get_named_arg_size.set_default();
}
self.get_named_arg_size.as_mut().unwrap()
}
pub fn take_get_named_arg_size(&mut self) -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.get_named_arg_size.take().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::new())
}
pub fn get_get_named_arg(&self) -> &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.get_named_arg.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::default_instance())
}
pub fn clear_get_named_arg(&mut self) {
self.get_named_arg.clear();
}
pub fn has_get_named_arg(&self) -> bool {
self.get_named_arg.is_some()
}
pub fn set_get_named_arg(&mut self, v: ChainSpec_WasmConfig_HostFunctionCosts_HostFunction) {
self.get_named_arg = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_get_named_arg(&mut self) -> &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
if self.get_named_arg.is_none() {
self.get_named_arg.set_default();
}
self.get_named_arg.as_mut().unwrap()
}
pub fn take_get_named_arg(&mut self) -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.get_named_arg.take().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::new())
}
pub fn get_remove_contract_user_group(&self) -> &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.remove_contract_user_group.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::default_instance())
}
pub fn clear_remove_contract_user_group(&mut self) {
self.remove_contract_user_group.clear();
}
pub fn has_remove_contract_user_group(&self) -> bool {
self.remove_contract_user_group.is_some()
}
pub fn set_remove_contract_user_group(&mut self, v: ChainSpec_WasmConfig_HostFunctionCosts_HostFunction) {
self.remove_contract_user_group = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_remove_contract_user_group(&mut self) -> &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
if self.remove_contract_user_group.is_none() {
self.remove_contract_user_group.set_default();
}
self.remove_contract_user_group.as_mut().unwrap()
}
pub fn take_remove_contract_user_group(&mut self) -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.remove_contract_user_group.take().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::new())
}
pub fn get_provision_contract_user_group_uref(&self) -> &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.provision_contract_user_group_uref.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::default_instance())
}
pub fn clear_provision_contract_user_group_uref(&mut self) {
self.provision_contract_user_group_uref.clear();
}
pub fn has_provision_contract_user_group_uref(&self) -> bool {
self.provision_contract_user_group_uref.is_some()
}
pub fn set_provision_contract_user_group_uref(&mut self, v: ChainSpec_WasmConfig_HostFunctionCosts_HostFunction) {
self.provision_contract_user_group_uref = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_provision_contract_user_group_uref(&mut self) -> &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
if self.provision_contract_user_group_uref.is_none() {
self.provision_contract_user_group_uref.set_default();
}
self.provision_contract_user_group_uref.as_mut().unwrap()
}
pub fn take_provision_contract_user_group_uref(&mut self) -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.provision_contract_user_group_uref.take().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::new())
}
pub fn get_remove_contract_user_group_urefs(&self) -> &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.remove_contract_user_group_urefs.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::default_instance())
}
pub fn clear_remove_contract_user_group_urefs(&mut self) {
self.remove_contract_user_group_urefs.clear();
}
pub fn has_remove_contract_user_group_urefs(&self) -> bool {
self.remove_contract_user_group_urefs.is_some()
}
pub fn set_remove_contract_user_group_urefs(&mut self, v: ChainSpec_WasmConfig_HostFunctionCosts_HostFunction) {
self.remove_contract_user_group_urefs = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_remove_contract_user_group_urefs(&mut self) -> &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
if self.remove_contract_user_group_urefs.is_none() {
self.remove_contract_user_group_urefs.set_default();
}
self.remove_contract_user_group_urefs.as_mut().unwrap()
}
pub fn take_remove_contract_user_group_urefs(&mut self) -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.remove_contract_user_group_urefs.take().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::new())
}
pub fn get_print(&self) -> &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.print.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::default_instance())
}
pub fn clear_print(&mut self) {
self.print.clear();
}
pub fn has_print(&self) -> bool {
self.print.is_some()
}
pub fn set_print(&mut self, v: ChainSpec_WasmConfig_HostFunctionCosts_HostFunction) {
self.print = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_print(&mut self) -> &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
if self.print.is_none() {
self.print.set_default();
}
self.print.as_mut().unwrap()
}
pub fn take_print(&mut self) -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.print.take().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::new())
}
pub fn get_blake2b(&self) -> &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.blake2b.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::default_instance())
}
pub fn clear_blake2b(&mut self) {
self.blake2b.clear();
}
pub fn has_blake2b(&self) -> bool {
self.blake2b.is_some()
}
pub fn set_blake2b(&mut self, v: ChainSpec_WasmConfig_HostFunctionCosts_HostFunction) {
self.blake2b = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_blake2b(&mut self) -> &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
if self.blake2b.is_none() {
self.blake2b.set_default();
}
self.blake2b.as_mut().unwrap()
}
pub fn take_blake2b(&mut self) -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
self.blake2b.take().unwrap_or_else(|| ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::new())
}
}
impl ::protobuf::Message for ChainSpec_WasmConfig_HostFunctionCosts {
fn is_initialized(&self) -> bool {
for v in &self.read_value {
if !v.is_initialized() {
return false;
}
};
for v in &self.read_value_local {
if !v.is_initialized() {
return false;
}
};
for v in &self.write {
if !v.is_initialized() {
return false;
}
};
for v in &self.write_local {
if !v.is_initialized() {
return false;
}
};
for v in &self.add {
if !v.is_initialized() {
return false;
}
};
for v in &self.new_uref {
if !v.is_initialized() {
return false;
}
};
for v in &self.load_named_keys {
if !v.is_initialized() {
return false;
}
};
for v in &self.ret {
if !v.is_initialized() {
return false;
}
};
for v in &self.get_key {
if !v.is_initialized() {
return false;
}
};
for v in &self.has_key {
if !v.is_initialized() {
return false;
}
};
for v in &self.put_key {
if !v.is_initialized() {
return false;
}
};
for v in &self.remove_key {
if !v.is_initialized() {
return false;
}
};
for v in &self.revert {
if !v.is_initialized() {
return false;
}
};
for v in &self.is_valid_uref {
if !v.is_initialized() {
return false;
}
};
for v in &self.add_associated_key {
if !v.is_initialized() {
return false;
}
};
for v in &self.remove_associated_key {
if !v.is_initialized() {
return false;
}
};
for v in &self.update_associated_key {
if !v.is_initialized() {
return false;
}
};
for v in &self.set_action_threshold {
if !v.is_initialized() {
return false;
}
};
for v in &self.get_caller {
if !v.is_initialized() {
return false;
}
};
for v in &self.get_blocktime {
if !v.is_initialized() {
return false;
}
};
for v in &self.create_purse {
if !v.is_initialized() {
return false;
}
};
for v in &self.transfer_to_account {
if !v.is_initialized() {
return false;
}
};
for v in &self.transfer_from_purse_to_account {
if !v.is_initialized() {
return false;
}
};
for v in &self.transfer_from_purse_to_purse {
if !v.is_initialized() {
return false;
}
};
for v in &self.get_balance {
if !v.is_initialized() {
return false;
}
};
for v in &self.get_phase {
if !v.is_initialized() {
return false;
}
};
for v in &self.get_system_contract {
if !v.is_initialized() {
return false;
}
};
for v in &self.get_main_purse {
if !v.is_initialized() {
return false;
}
};
for v in &self.read_host_buffer {
if !v.is_initialized() {
return false;
}
};
for v in &self.create_contract_package_at_hash {
if !v.is_initialized() {
return false;
}
};
for v in &self.create_contract_user_group {
if !v.is_initialized() {
return false;
}
};
for v in &self.add_contract_version {
if !v.is_initialized() {
return false;
}
};
for v in &self.disable_contract_version {
if !v.is_initialized() {
return false;
}
};
for v in &self.call_contract {
if !v.is_initialized() {
return false;
}
};
for v in &self.call_versioned_contract {
if !v.is_initialized() {
return false;
}
};
for v in &self.get_named_arg_size {
if !v.is_initialized() {
return false;
}
};
for v in &self.get_named_arg {
if !v.is_initialized() {
return false;
}
};
for v in &self.remove_contract_user_group {
if !v.is_initialized() {
return false;
}
};
for v in &self.provision_contract_user_group_uref {
if !v.is_initialized() {
return false;
}
};
for v in &self.remove_contract_user_group_urefs {
if !v.is_initialized() {
return false;
}
};
for v in &self.print {
if !v.is_initialized() {
return false;
}
};
for v in &self.blake2b {
if !v.is_initialized() {
return false;
}
};
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.read_value)?;
},
2 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.read_value_local)?;
},
3 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.write)?;
},
4 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.write_local)?;
},
5 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.add)?;
},
6 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.new_uref)?;
},
7 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.load_named_keys)?;
},
8 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.ret)?;
},
9 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.get_key)?;
},
10 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.has_key)?;
},
11 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.put_key)?;
},
12 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.remove_key)?;
},
13 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.revert)?;
},
14 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.is_valid_uref)?;
},
15 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.add_associated_key)?;
},
16 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.remove_associated_key)?;
},
17 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.update_associated_key)?;
},
18 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.set_action_threshold)?;
},
19 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.get_caller)?;
},
20 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.get_blocktime)?;
},
21 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.create_purse)?;
},
22 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.transfer_to_account)?;
},
23 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.transfer_from_purse_to_account)?;
},
24 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.transfer_from_purse_to_purse)?;
},
25 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.get_balance)?;
},
26 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.get_phase)?;
},
27 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.get_system_contract)?;
},
28 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.get_main_purse)?;
},
29 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.read_host_buffer)?;
},
30 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.create_contract_package_at_hash)?;
},
31 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.create_contract_user_group)?;
},
32 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.add_contract_version)?;
},
33 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.disable_contract_version)?;
},
34 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.call_contract)?;
},
35 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.call_versioned_contract)?;
},
36 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.get_named_arg_size)?;
},
37 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.get_named_arg)?;
},
38 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.remove_contract_user_group)?;
},
39 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.provision_contract_user_group_uref)?;
},
40 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.remove_contract_user_group_urefs)?;
},
41 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.print)?;
},
42 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.blake2b)?;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if let Some(ref v) = self.read_value.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.read_value_local.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.write.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.write_local.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.add.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.new_uref.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.load_named_keys.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.ret.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.get_key.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.has_key.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.put_key.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.remove_key.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.revert.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.is_valid_uref.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.add_associated_key.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.remove_associated_key.as_ref() {
let len = v.compute_size();
my_size += 2 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.update_associated_key.as_ref() {
let len = v.compute_size();
my_size += 2 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.set_action_threshold.as_ref() {
let len = v.compute_size();
my_size += 2 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.get_caller.as_ref() {
let len = v.compute_size();
my_size += 2 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.get_blocktime.as_ref() {
let len = v.compute_size();
my_size += 2 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.create_purse.as_ref() {
let len = v.compute_size();
my_size += 2 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.transfer_to_account.as_ref() {
let len = v.compute_size();
my_size += 2 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.transfer_from_purse_to_account.as_ref() {
let len = v.compute_size();
my_size += 2 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.transfer_from_purse_to_purse.as_ref() {
let len = v.compute_size();
my_size += 2 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.get_balance.as_ref() {
let len = v.compute_size();
my_size += 2 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.get_phase.as_ref() {
let len = v.compute_size();
my_size += 2 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.get_system_contract.as_ref() {
let len = v.compute_size();
my_size += 2 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.get_main_purse.as_ref() {
let len = v.compute_size();
my_size += 2 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.read_host_buffer.as_ref() {
let len = v.compute_size();
my_size += 2 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.create_contract_package_at_hash.as_ref() {
let len = v.compute_size();
my_size += 2 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.create_contract_user_group.as_ref() {
let len = v.compute_size();
my_size += 2 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.add_contract_version.as_ref() {
let len = v.compute_size();
my_size += 2 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.disable_contract_version.as_ref() {
let len = v.compute_size();
my_size += 2 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.call_contract.as_ref() {
let len = v.compute_size();
my_size += 2 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.call_versioned_contract.as_ref() {
let len = v.compute_size();
my_size += 2 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.get_named_arg_size.as_ref() {
let len = v.compute_size();
my_size += 2 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.get_named_arg.as_ref() {
let len = v.compute_size();
my_size += 2 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.remove_contract_user_group.as_ref() {
let len = v.compute_size();
my_size += 2 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.provision_contract_user_group_uref.as_ref() {
let len = v.compute_size();
my_size += 2 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.remove_contract_user_group_urefs.as_ref() {
let len = v.compute_size();
my_size += 2 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.print.as_ref() {
let len = v.compute_size();
my_size += 2 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.blake2b.as_ref() {
let len = v.compute_size();
my_size += 2 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if let Some(ref v) = self.read_value.as_ref() {
os.write_tag(1, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.read_value_local.as_ref() {
os.write_tag(2, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.write.as_ref() {
os.write_tag(3, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.write_local.as_ref() {
os.write_tag(4, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.add.as_ref() {
os.write_tag(5, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.new_uref.as_ref() {
os.write_tag(6, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.load_named_keys.as_ref() {
os.write_tag(7, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.ret.as_ref() {
os.write_tag(8, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.get_key.as_ref() {
os.write_tag(9, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.has_key.as_ref() {
os.write_tag(10, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.put_key.as_ref() {
os.write_tag(11, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.remove_key.as_ref() {
os.write_tag(12, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.revert.as_ref() {
os.write_tag(13, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.is_valid_uref.as_ref() {
os.write_tag(14, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.add_associated_key.as_ref() {
os.write_tag(15, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.remove_associated_key.as_ref() {
os.write_tag(16, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.update_associated_key.as_ref() {
os.write_tag(17, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.set_action_threshold.as_ref() {
os.write_tag(18, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.get_caller.as_ref() {
os.write_tag(19, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.get_blocktime.as_ref() {
os.write_tag(20, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.create_purse.as_ref() {
os.write_tag(21, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.transfer_to_account.as_ref() {
os.write_tag(22, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.transfer_from_purse_to_account.as_ref() {
os.write_tag(23, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.transfer_from_purse_to_purse.as_ref() {
os.write_tag(24, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.get_balance.as_ref() {
os.write_tag(25, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.get_phase.as_ref() {
os.write_tag(26, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.get_system_contract.as_ref() {
os.write_tag(27, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.get_main_purse.as_ref() {
os.write_tag(28, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.read_host_buffer.as_ref() {
os.write_tag(29, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.create_contract_package_at_hash.as_ref() {
os.write_tag(30, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.create_contract_user_group.as_ref() {
os.write_tag(31, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.add_contract_version.as_ref() {
os.write_tag(32, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.disable_contract_version.as_ref() {
os.write_tag(33, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.call_contract.as_ref() {
os.write_tag(34, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.call_versioned_contract.as_ref() {
os.write_tag(35, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.get_named_arg_size.as_ref() {
os.write_tag(36, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.get_named_arg.as_ref() {
os.write_tag(37, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.remove_contract_user_group.as_ref() {
os.write_tag(38, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.provision_contract_user_group_uref.as_ref() {
os.write_tag(39, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.remove_contract_user_group_urefs.as_ref() {
os.write_tag(40, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.print.as_ref() {
os.write_tag(41, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.blake2b.as_ref() {
os.write_tag(42, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> ChainSpec_WasmConfig_HostFunctionCosts {
ChainSpec_WasmConfig_HostFunctionCosts::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>>(
"read_value",
|m: &ChainSpec_WasmConfig_HostFunctionCosts| { &m.read_value },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts| { &mut m.read_value },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>>(
"read_value_local",
|m: &ChainSpec_WasmConfig_HostFunctionCosts| { &m.read_value_local },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts| { &mut m.read_value_local },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>>(
"write",
|m: &ChainSpec_WasmConfig_HostFunctionCosts| { &m.write },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts| { &mut m.write },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>>(
"write_local",
|m: &ChainSpec_WasmConfig_HostFunctionCosts| { &m.write_local },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts| { &mut m.write_local },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>>(
"add",
|m: &ChainSpec_WasmConfig_HostFunctionCosts| { &m.add },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts| { &mut m.add },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>>(
"new_uref",
|m: &ChainSpec_WasmConfig_HostFunctionCosts| { &m.new_uref },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts| { &mut m.new_uref },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>>(
"load_named_keys",
|m: &ChainSpec_WasmConfig_HostFunctionCosts| { &m.load_named_keys },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts| { &mut m.load_named_keys },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>>(
"ret",
|m: &ChainSpec_WasmConfig_HostFunctionCosts| { &m.ret },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts| { &mut m.ret },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>>(
"get_key",
|m: &ChainSpec_WasmConfig_HostFunctionCosts| { &m.get_key },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts| { &mut m.get_key },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>>(
"has_key",
|m: &ChainSpec_WasmConfig_HostFunctionCosts| { &m.has_key },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts| { &mut m.has_key },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>>(
"put_key",
|m: &ChainSpec_WasmConfig_HostFunctionCosts| { &m.put_key },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts| { &mut m.put_key },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>>(
"remove_key",
|m: &ChainSpec_WasmConfig_HostFunctionCosts| { &m.remove_key },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts| { &mut m.remove_key },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>>(
"revert",
|m: &ChainSpec_WasmConfig_HostFunctionCosts| { &m.revert },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts| { &mut m.revert },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>>(
"is_valid_uref",
|m: &ChainSpec_WasmConfig_HostFunctionCosts| { &m.is_valid_uref },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts| { &mut m.is_valid_uref },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>>(
"add_associated_key",
|m: &ChainSpec_WasmConfig_HostFunctionCosts| { &m.add_associated_key },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts| { &mut m.add_associated_key },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>>(
"remove_associated_key",
|m: &ChainSpec_WasmConfig_HostFunctionCosts| { &m.remove_associated_key },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts| { &mut m.remove_associated_key },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>>(
"update_associated_key",
|m: &ChainSpec_WasmConfig_HostFunctionCosts| { &m.update_associated_key },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts| { &mut m.update_associated_key },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>>(
"set_action_threshold",
|m: &ChainSpec_WasmConfig_HostFunctionCosts| { &m.set_action_threshold },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts| { &mut m.set_action_threshold },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>>(
"get_caller",
|m: &ChainSpec_WasmConfig_HostFunctionCosts| { &m.get_caller },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts| { &mut m.get_caller },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>>(
"get_blocktime",
|m: &ChainSpec_WasmConfig_HostFunctionCosts| { &m.get_blocktime },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts| { &mut m.get_blocktime },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>>(
"create_purse",
|m: &ChainSpec_WasmConfig_HostFunctionCosts| { &m.create_purse },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts| { &mut m.create_purse },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>>(
"transfer_to_account",
|m: &ChainSpec_WasmConfig_HostFunctionCosts| { &m.transfer_to_account },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts| { &mut m.transfer_to_account },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>>(
"transfer_from_purse_to_account",
|m: &ChainSpec_WasmConfig_HostFunctionCosts| { &m.transfer_from_purse_to_account },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts| { &mut m.transfer_from_purse_to_account },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>>(
"transfer_from_purse_to_purse",
|m: &ChainSpec_WasmConfig_HostFunctionCosts| { &m.transfer_from_purse_to_purse },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts| { &mut m.transfer_from_purse_to_purse },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>>(
"get_balance",
|m: &ChainSpec_WasmConfig_HostFunctionCosts| { &m.get_balance },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts| { &mut m.get_balance },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>>(
"get_phase",
|m: &ChainSpec_WasmConfig_HostFunctionCosts| { &m.get_phase },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts| { &mut m.get_phase },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>>(
"get_system_contract",
|m: &ChainSpec_WasmConfig_HostFunctionCosts| { &m.get_system_contract },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts| { &mut m.get_system_contract },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>>(
"get_main_purse",
|m: &ChainSpec_WasmConfig_HostFunctionCosts| { &m.get_main_purse },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts| { &mut m.get_main_purse },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>>(
"read_host_buffer",
|m: &ChainSpec_WasmConfig_HostFunctionCosts| { &m.read_host_buffer },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts| { &mut m.read_host_buffer },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>>(
"create_contract_package_at_hash",
|m: &ChainSpec_WasmConfig_HostFunctionCosts| { &m.create_contract_package_at_hash },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts| { &mut m.create_contract_package_at_hash },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>>(
"create_contract_user_group",
|m: &ChainSpec_WasmConfig_HostFunctionCosts| { &m.create_contract_user_group },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts| { &mut m.create_contract_user_group },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>>(
"add_contract_version",
|m: &ChainSpec_WasmConfig_HostFunctionCosts| { &m.add_contract_version },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts| { &mut m.add_contract_version },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>>(
"disable_contract_version",
|m: &ChainSpec_WasmConfig_HostFunctionCosts| { &m.disable_contract_version },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts| { &mut m.disable_contract_version },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>>(
"call_contract",
|m: &ChainSpec_WasmConfig_HostFunctionCosts| { &m.call_contract },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts| { &mut m.call_contract },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>>(
"call_versioned_contract",
|m: &ChainSpec_WasmConfig_HostFunctionCosts| { &m.call_versioned_contract },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts| { &mut m.call_versioned_contract },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>>(
"get_named_arg_size",
|m: &ChainSpec_WasmConfig_HostFunctionCosts| { &m.get_named_arg_size },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts| { &mut m.get_named_arg_size },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>>(
"get_named_arg",
|m: &ChainSpec_WasmConfig_HostFunctionCosts| { &m.get_named_arg },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts| { &mut m.get_named_arg },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>>(
"remove_contract_user_group",
|m: &ChainSpec_WasmConfig_HostFunctionCosts| { &m.remove_contract_user_group },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts| { &mut m.remove_contract_user_group },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>>(
"provision_contract_user_group_uref",
|m: &ChainSpec_WasmConfig_HostFunctionCosts| { &m.provision_contract_user_group_uref },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts| { &mut m.provision_contract_user_group_uref },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>>(
"remove_contract_user_group_urefs",
|m: &ChainSpec_WasmConfig_HostFunctionCosts| { &m.remove_contract_user_group_urefs },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts| { &mut m.remove_contract_user_group_urefs },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>>(
"print",
|m: &ChainSpec_WasmConfig_HostFunctionCosts| { &m.print },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts| { &mut m.print },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>>(
"blake2b",
|m: &ChainSpec_WasmConfig_HostFunctionCosts| { &m.blake2b },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts| { &mut m.blake2b },
));
::protobuf::reflect::MessageDescriptor::new::<ChainSpec_WasmConfig_HostFunctionCosts>(
"ChainSpec_WasmConfig_HostFunctionCosts",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static ChainSpec_WasmConfig_HostFunctionCosts {
static mut instance: ::protobuf::lazy::Lazy<ChainSpec_WasmConfig_HostFunctionCosts> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ChainSpec_WasmConfig_HostFunctionCosts,
};
unsafe {
instance.get(ChainSpec_WasmConfig_HostFunctionCosts::new)
}
}
}
impl ::protobuf::Clear for ChainSpec_WasmConfig_HostFunctionCosts {
fn clear(&mut self) {
self.read_value.clear();
self.read_value_local.clear();
self.write.clear();
self.write_local.clear();
self.add.clear();
self.new_uref.clear();
self.load_named_keys.clear();
self.ret.clear();
self.get_key.clear();
self.has_key.clear();
self.put_key.clear();
self.remove_key.clear();
self.revert.clear();
self.is_valid_uref.clear();
self.add_associated_key.clear();
self.remove_associated_key.clear();
self.update_associated_key.clear();
self.set_action_threshold.clear();
self.get_caller.clear();
self.get_blocktime.clear();
self.create_purse.clear();
self.transfer_to_account.clear();
self.transfer_from_purse_to_account.clear();
self.transfer_from_purse_to_purse.clear();
self.get_balance.clear();
self.get_phase.clear();
self.get_system_contract.clear();
self.get_main_purse.clear();
self.read_host_buffer.clear();
self.create_contract_package_at_hash.clear();
self.create_contract_user_group.clear();
self.add_contract_version.clear();
self.disable_contract_version.clear();
self.call_contract.clear();
self.call_versioned_contract.clear();
self.get_named_arg_size.clear();
self.get_named_arg.clear();
self.remove_contract_user_group.clear();
self.provision_contract_user_group_uref.clear();
self.remove_contract_user_group_urefs.clear();
self.print.clear();
self.blake2b.clear();
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for ChainSpec_WasmConfig_HostFunctionCosts {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for ChainSpec_WasmConfig_HostFunctionCosts {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
pub cost: u32,
pub arguments: ::protobuf::RepeatedField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction_Argument>,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
fn default() -> &'a ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction as ::protobuf::Message>::default_instance()
}
}
impl ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
pub fn new() -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
::std::default::Default::default()
}
pub fn get_cost(&self) -> u32 {
self.cost
}
pub fn clear_cost(&mut self) {
self.cost = 0;
}
pub fn set_cost(&mut self, v: u32) {
self.cost = v;
}
pub fn get_arguments(&self) -> &[ChainSpec_WasmConfig_HostFunctionCosts_HostFunction_Argument] {
&self.arguments
}
pub fn clear_arguments(&mut self) {
self.arguments.clear();
}
pub fn set_arguments(&mut self, v: ::protobuf::RepeatedField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction_Argument>) {
self.arguments = v;
}
pub fn mut_arguments(&mut self) -> &mut ::protobuf::RepeatedField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction_Argument> {
&mut self.arguments
}
pub fn take_arguments(&mut self) -> ::protobuf::RepeatedField<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction_Argument> {
::std::mem::replace(&mut self.arguments, ::protobuf::RepeatedField::new())
}
}
impl ::protobuf::Message for ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
fn is_initialized(&self) -> bool {
for v in &self.arguments {
if !v.is_initialized() {
return false;
}
};
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_uint32()?;
self.cost = tmp;
},
2 => {
::protobuf::rt::read_repeated_message_into(wire_type, is, &mut self.arguments)?;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if self.cost != 0 {
my_size += ::protobuf::rt::value_size(1, self.cost, ::protobuf::wire_format::WireTypeVarint);
}
for value in &self.arguments {
let len = value.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
};
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if self.cost != 0 {
os.write_uint32(1, self.cost)?;
}
for v in &self.arguments {
os.write_tag(2, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
};
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeUint32>(
"cost",
|m: &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction| { &m.cost },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction| { &mut m.cost },
));
fields.push(::protobuf::reflect::accessor::make_repeated_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction_Argument>>(
"arguments",
|m: &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction| { &m.arguments },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction| { &mut m.arguments },
));
::protobuf::reflect::MessageDescriptor::new::<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction>(
"ChainSpec_WasmConfig_HostFunctionCosts_HostFunction",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
static mut instance: ::protobuf::lazy::Lazy<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ChainSpec_WasmConfig_HostFunctionCosts_HostFunction,
};
unsafe {
instance.get(ChainSpec_WasmConfig_HostFunctionCosts_HostFunction::new)
}
}
}
impl ::protobuf::Clear for ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
fn clear(&mut self) {
self.cost = 0;
self.arguments.clear();
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for ChainSpec_WasmConfig_HostFunctionCosts_HostFunction {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct ChainSpec_WasmConfig_HostFunctionCosts_HostFunction_Argument {
pub weight: u32,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a ChainSpec_WasmConfig_HostFunctionCosts_HostFunction_Argument {
fn default() -> &'a ChainSpec_WasmConfig_HostFunctionCosts_HostFunction_Argument {
<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction_Argument as ::protobuf::Message>::default_instance()
}
}
impl ChainSpec_WasmConfig_HostFunctionCosts_HostFunction_Argument {
pub fn new() -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction_Argument {
::std::default::Default::default()
}
pub fn get_weight(&self) -> u32 {
self.weight
}
pub fn clear_weight(&mut self) {
self.weight = 0;
}
pub fn set_weight(&mut self, v: u32) {
self.weight = v;
}
}
impl ::protobuf::Message for ChainSpec_WasmConfig_HostFunctionCosts_HostFunction_Argument {
fn is_initialized(&self) -> bool {
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_uint32()?;
self.weight = tmp;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if self.weight != 0 {
my_size += ::protobuf::rt::value_size(1, self.weight, ::protobuf::wire_format::WireTypeVarint);
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if self.weight != 0 {
os.write_uint32(1, self.weight)?;
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> ChainSpec_WasmConfig_HostFunctionCosts_HostFunction_Argument {
ChainSpec_WasmConfig_HostFunctionCosts_HostFunction_Argument::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeUint32>(
"weight",
|m: &ChainSpec_WasmConfig_HostFunctionCosts_HostFunction_Argument| { &m.weight },
|m: &mut ChainSpec_WasmConfig_HostFunctionCosts_HostFunction_Argument| { &mut m.weight },
));
::protobuf::reflect::MessageDescriptor::new::<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction_Argument>(
"ChainSpec_WasmConfig_HostFunctionCosts_HostFunction_Argument",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static ChainSpec_WasmConfig_HostFunctionCosts_HostFunction_Argument {
static mut instance: ::protobuf::lazy::Lazy<ChainSpec_WasmConfig_HostFunctionCosts_HostFunction_Argument> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ChainSpec_WasmConfig_HostFunctionCosts_HostFunction_Argument,
};
unsafe {
instance.get(ChainSpec_WasmConfig_HostFunctionCosts_HostFunction_Argument::new)
}
}
}
impl ::protobuf::Clear for ChainSpec_WasmConfig_HostFunctionCosts_HostFunction_Argument {
fn clear(&mut self) {
self.weight = 0;
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for ChainSpec_WasmConfig_HostFunctionCosts_HostFunction_Argument {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for ChainSpec_WasmConfig_HostFunctionCosts_HostFunction_Argument {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct ChainSpec_UpgradePoint {
pub activation_point: ::protobuf::SingularPtrField<ChainSpec_ActivationPoint>,
pub protocol_version: ::protobuf::SingularPtrField<super::state::ProtocolVersion>,
pub upgrade_installer: ::protobuf::SingularPtrField<DeployCode>,
pub new_wasm_config: ::protobuf::SingularPtrField<ChainSpec_WasmConfig>,
pub new_deploy_config: ::protobuf::SingularPtrField<ChainSpec_DeployConfig>,
pub new_validator_slots: ::protobuf::SingularPtrField<ChainSpec_NewValidatorSlots>,
pub new_auction_delay: ::protobuf::SingularPtrField<ChainSpec_NewAuctionDelay>,
pub new_locked_funds_period: ::protobuf::SingularPtrField<ChainSpec_NewLockedFundsPeriod>,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a ChainSpec_UpgradePoint {
fn default() -> &'a ChainSpec_UpgradePoint {
<ChainSpec_UpgradePoint as ::protobuf::Message>::default_instance()
}
}
impl ChainSpec_UpgradePoint {
pub fn new() -> ChainSpec_UpgradePoint {
::std::default::Default::default()
}
pub fn get_activation_point(&self) -> &ChainSpec_ActivationPoint {
self.activation_point.as_ref().unwrap_or_else(|| ChainSpec_ActivationPoint::default_instance())
}
pub fn clear_activation_point(&mut self) {
self.activation_point.clear();
}
pub fn has_activation_point(&self) -> bool {
self.activation_point.is_some()
}
pub fn set_activation_point(&mut self, v: ChainSpec_ActivationPoint) {
self.activation_point = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_activation_point(&mut self) -> &mut ChainSpec_ActivationPoint {
if self.activation_point.is_none() {
self.activation_point.set_default();
}
self.activation_point.as_mut().unwrap()
}
pub fn take_activation_point(&mut self) -> ChainSpec_ActivationPoint {
self.activation_point.take().unwrap_or_else(|| ChainSpec_ActivationPoint::new())
}
pub fn get_protocol_version(&self) -> &super::state::ProtocolVersion {
self.protocol_version.as_ref().unwrap_or_else(|| super::state::ProtocolVersion::default_instance())
}
pub fn clear_protocol_version(&mut self) {
self.protocol_version.clear();
}
pub fn has_protocol_version(&self) -> bool {
self.protocol_version.is_some()
}
pub fn set_protocol_version(&mut self, v: super::state::ProtocolVersion) {
self.protocol_version = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_protocol_version(&mut self) -> &mut super::state::ProtocolVersion {
if self.protocol_version.is_none() {
self.protocol_version.set_default();
}
self.protocol_version.as_mut().unwrap()
}
pub fn take_protocol_version(&mut self) -> super::state::ProtocolVersion {
self.protocol_version.take().unwrap_or_else(|| super::state::ProtocolVersion::new())
}
pub fn get_upgrade_installer(&self) -> &DeployCode {
self.upgrade_installer.as_ref().unwrap_or_else(|| DeployCode::default_instance())
}
pub fn clear_upgrade_installer(&mut self) {
self.upgrade_installer.clear();
}
pub fn has_upgrade_installer(&self) -> bool {
self.upgrade_installer.is_some()
}
pub fn set_upgrade_installer(&mut self, v: DeployCode) {
self.upgrade_installer = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_upgrade_installer(&mut self) -> &mut DeployCode {
if self.upgrade_installer.is_none() {
self.upgrade_installer.set_default();
}
self.upgrade_installer.as_mut().unwrap()
}
pub fn take_upgrade_installer(&mut self) -> DeployCode {
self.upgrade_installer.take().unwrap_or_else(|| DeployCode::new())
}
pub fn get_new_wasm_config(&self) -> &ChainSpec_WasmConfig {
self.new_wasm_config.as_ref().unwrap_or_else(|| ChainSpec_WasmConfig::default_instance())
}
pub fn clear_new_wasm_config(&mut self) {
self.new_wasm_config.clear();
}
pub fn has_new_wasm_config(&self) -> bool {
self.new_wasm_config.is_some()
}
pub fn set_new_wasm_config(&mut self, v: ChainSpec_WasmConfig) {
self.new_wasm_config = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_new_wasm_config(&mut self) -> &mut ChainSpec_WasmConfig {
if self.new_wasm_config.is_none() {
self.new_wasm_config.set_default();
}
self.new_wasm_config.as_mut().unwrap()
}
pub fn take_new_wasm_config(&mut self) -> ChainSpec_WasmConfig {
self.new_wasm_config.take().unwrap_or_else(|| ChainSpec_WasmConfig::new())
}
pub fn get_new_deploy_config(&self) -> &ChainSpec_DeployConfig {
self.new_deploy_config.as_ref().unwrap_or_else(|| ChainSpec_DeployConfig::default_instance())
}
pub fn clear_new_deploy_config(&mut self) {
self.new_deploy_config.clear();
}
pub fn has_new_deploy_config(&self) -> bool {
self.new_deploy_config.is_some()
}
pub fn set_new_deploy_config(&mut self, v: ChainSpec_DeployConfig) {
self.new_deploy_config = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_new_deploy_config(&mut self) -> &mut ChainSpec_DeployConfig {
if self.new_deploy_config.is_none() {
self.new_deploy_config.set_default();
}
self.new_deploy_config.as_mut().unwrap()
}
pub fn take_new_deploy_config(&mut self) -> ChainSpec_DeployConfig {
self.new_deploy_config.take().unwrap_or_else(|| ChainSpec_DeployConfig::new())
}
pub fn get_new_validator_slots(&self) -> &ChainSpec_NewValidatorSlots {
self.new_validator_slots.as_ref().unwrap_or_else(|| ChainSpec_NewValidatorSlots::default_instance())
}
pub fn clear_new_validator_slots(&mut self) {
self.new_validator_slots.clear();
}
pub fn has_new_validator_slots(&self) -> bool {
self.new_validator_slots.is_some()
}
pub fn set_new_validator_slots(&mut self, v: ChainSpec_NewValidatorSlots) {
self.new_validator_slots = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_new_validator_slots(&mut self) -> &mut ChainSpec_NewValidatorSlots {
if self.new_validator_slots.is_none() {
self.new_validator_slots.set_default();
}
self.new_validator_slots.as_mut().unwrap()
}
pub fn take_new_validator_slots(&mut self) -> ChainSpec_NewValidatorSlots {
self.new_validator_slots.take().unwrap_or_else(|| ChainSpec_NewValidatorSlots::new())
}
pub fn get_new_auction_delay(&self) -> &ChainSpec_NewAuctionDelay {
self.new_auction_delay.as_ref().unwrap_or_else(|| ChainSpec_NewAuctionDelay::default_instance())
}
pub fn clear_new_auction_delay(&mut self) {
self.new_auction_delay.clear();
}
pub fn has_new_auction_delay(&self) -> bool {
self.new_auction_delay.is_some()
}
pub fn set_new_auction_delay(&mut self, v: ChainSpec_NewAuctionDelay) {
self.new_auction_delay = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_new_auction_delay(&mut self) -> &mut ChainSpec_NewAuctionDelay {
if self.new_auction_delay.is_none() {
self.new_auction_delay.set_default();
}
self.new_auction_delay.as_mut().unwrap()
}
pub fn take_new_auction_delay(&mut self) -> ChainSpec_NewAuctionDelay {
self.new_auction_delay.take().unwrap_or_else(|| ChainSpec_NewAuctionDelay::new())
}
pub fn get_new_locked_funds_period(&self) -> &ChainSpec_NewLockedFundsPeriod {
self.new_locked_funds_period.as_ref().unwrap_or_else(|| ChainSpec_NewLockedFundsPeriod::default_instance())
}
pub fn clear_new_locked_funds_period(&mut self) {
self.new_locked_funds_period.clear();
}
pub fn has_new_locked_funds_period(&self) -> bool {
self.new_locked_funds_period.is_some()
}
pub fn set_new_locked_funds_period(&mut self, v: ChainSpec_NewLockedFundsPeriod) {
self.new_locked_funds_period = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_new_locked_funds_period(&mut self) -> &mut ChainSpec_NewLockedFundsPeriod {
if self.new_locked_funds_period.is_none() {
self.new_locked_funds_period.set_default();
}
self.new_locked_funds_period.as_mut().unwrap()
}
pub fn take_new_locked_funds_period(&mut self) -> ChainSpec_NewLockedFundsPeriod {
self.new_locked_funds_period.take().unwrap_or_else(|| ChainSpec_NewLockedFundsPeriod::new())
}
}
impl ::protobuf::Message for ChainSpec_UpgradePoint {
fn is_initialized(&self) -> bool {
for v in &self.activation_point {
if !v.is_initialized() {
return false;
}
};
for v in &self.protocol_version {
if !v.is_initialized() {
return false;
}
};
for v in &self.upgrade_installer {
if !v.is_initialized() {
return false;
}
};
for v in &self.new_wasm_config {
if !v.is_initialized() {
return false;
}
};
for v in &self.new_deploy_config {
if !v.is_initialized() {
return false;
}
};
for v in &self.new_validator_slots {
if !v.is_initialized() {
return false;
}
};
for v in &self.new_auction_delay {
if !v.is_initialized() {
return false;
}
};
for v in &self.new_locked_funds_period {
if !v.is_initialized() {
return false;
}
};
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.activation_point)?;
},
2 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.protocol_version)?;
},
3 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.upgrade_installer)?;
},
4 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.new_wasm_config)?;
},
5 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.new_deploy_config)?;
},
6 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.new_validator_slots)?;
},
7 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.new_auction_delay)?;
},
9 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.new_locked_funds_period)?;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if let Some(ref v) = self.activation_point.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.protocol_version.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.upgrade_installer.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.new_wasm_config.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.new_deploy_config.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.new_validator_slots.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.new_auction_delay.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.new_locked_funds_period.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if let Some(ref v) = self.activation_point.as_ref() {
os.write_tag(1, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.protocol_version.as_ref() {
os.write_tag(2, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.upgrade_installer.as_ref() {
os.write_tag(3, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.new_wasm_config.as_ref() {
os.write_tag(4, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.new_deploy_config.as_ref() {
os.write_tag(5, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.new_validator_slots.as_ref() {
os.write_tag(6, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.new_auction_delay.as_ref() {
os.write_tag(7, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.new_locked_funds_period.as_ref() {
os.write_tag(9, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> ChainSpec_UpgradePoint {
ChainSpec_UpgradePoint::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_ActivationPoint>>(
"activation_point",
|m: &ChainSpec_UpgradePoint| { &m.activation_point },
|m: &mut ChainSpec_UpgradePoint| { &mut m.activation_point },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<super::state::ProtocolVersion>>(
"protocol_version",
|m: &ChainSpec_UpgradePoint| { &m.protocol_version },
|m: &mut ChainSpec_UpgradePoint| { &mut m.protocol_version },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<DeployCode>>(
"upgrade_installer",
|m: &ChainSpec_UpgradePoint| { &m.upgrade_installer },
|m: &mut ChainSpec_UpgradePoint| { &mut m.upgrade_installer },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_WasmConfig>>(
"new_wasm_config",
|m: &ChainSpec_UpgradePoint| { &m.new_wasm_config },
|m: &mut ChainSpec_UpgradePoint| { &mut m.new_wasm_config },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_DeployConfig>>(
"new_deploy_config",
|m: &ChainSpec_UpgradePoint| { &m.new_deploy_config },
|m: &mut ChainSpec_UpgradePoint| { &mut m.new_deploy_config },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_NewValidatorSlots>>(
"new_validator_slots",
|m: &ChainSpec_UpgradePoint| { &m.new_validator_slots },
|m: &mut ChainSpec_UpgradePoint| { &mut m.new_validator_slots },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_NewAuctionDelay>>(
"new_auction_delay",
|m: &ChainSpec_UpgradePoint| { &m.new_auction_delay },
|m: &mut ChainSpec_UpgradePoint| { &mut m.new_auction_delay },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_NewLockedFundsPeriod>>(
"new_locked_funds_period",
|m: &ChainSpec_UpgradePoint| { &m.new_locked_funds_period },
|m: &mut ChainSpec_UpgradePoint| { &mut m.new_locked_funds_period },
));
::protobuf::reflect::MessageDescriptor::new::<ChainSpec_UpgradePoint>(
"ChainSpec_UpgradePoint",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static ChainSpec_UpgradePoint {
static mut instance: ::protobuf::lazy::Lazy<ChainSpec_UpgradePoint> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ChainSpec_UpgradePoint,
};
unsafe {
instance.get(ChainSpec_UpgradePoint::new)
}
}
}
impl ::protobuf::Clear for ChainSpec_UpgradePoint {
fn clear(&mut self) {
self.activation_point.clear();
self.protocol_version.clear();
self.upgrade_installer.clear();
self.new_wasm_config.clear();
self.new_deploy_config.clear();
self.new_validator_slots.clear();
self.new_auction_delay.clear();
self.new_locked_funds_period.clear();
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for ChainSpec_UpgradePoint {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for ChainSpec_UpgradePoint {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct ChainSpec_NewValidatorSlots {
pub new_validator_slots: u32,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a ChainSpec_NewValidatorSlots {
fn default() -> &'a ChainSpec_NewValidatorSlots {
<ChainSpec_NewValidatorSlots as ::protobuf::Message>::default_instance()
}
}
impl ChainSpec_NewValidatorSlots {
pub fn new() -> ChainSpec_NewValidatorSlots {
::std::default::Default::default()
}
pub fn get_new_validator_slots(&self) -> u32 {
self.new_validator_slots
}
pub fn clear_new_validator_slots(&mut self) {
self.new_validator_slots = 0;
}
pub fn set_new_validator_slots(&mut self, v: u32) {
self.new_validator_slots = v;
}
}
impl ::protobuf::Message for ChainSpec_NewValidatorSlots {
fn is_initialized(&self) -> bool {
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_uint32()?;
self.new_validator_slots = tmp;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if self.new_validator_slots != 0 {
my_size += ::protobuf::rt::value_size(1, self.new_validator_slots, ::protobuf::wire_format::WireTypeVarint);
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if self.new_validator_slots != 0 {
os.write_uint32(1, self.new_validator_slots)?;
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> ChainSpec_NewValidatorSlots {
ChainSpec_NewValidatorSlots::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeUint32>(
"new_validator_slots",
|m: &ChainSpec_NewValidatorSlots| { &m.new_validator_slots },
|m: &mut ChainSpec_NewValidatorSlots| { &mut m.new_validator_slots },
));
::protobuf::reflect::MessageDescriptor::new::<ChainSpec_NewValidatorSlots>(
"ChainSpec_NewValidatorSlots",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static ChainSpec_NewValidatorSlots {
static mut instance: ::protobuf::lazy::Lazy<ChainSpec_NewValidatorSlots> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ChainSpec_NewValidatorSlots,
};
unsafe {
instance.get(ChainSpec_NewValidatorSlots::new)
}
}
}
impl ::protobuf::Clear for ChainSpec_NewValidatorSlots {
fn clear(&mut self) {
self.new_validator_slots = 0;
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for ChainSpec_NewValidatorSlots {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for ChainSpec_NewValidatorSlots {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct ChainSpec_NewAuctionDelay {
pub new_auction_delay: u64,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a ChainSpec_NewAuctionDelay {
fn default() -> &'a ChainSpec_NewAuctionDelay {
<ChainSpec_NewAuctionDelay as ::protobuf::Message>::default_instance()
}
}
impl ChainSpec_NewAuctionDelay {
pub fn new() -> ChainSpec_NewAuctionDelay {
::std::default::Default::default()
}
pub fn get_new_auction_delay(&self) -> u64 {
self.new_auction_delay
}
pub fn clear_new_auction_delay(&mut self) {
self.new_auction_delay = 0;
}
pub fn set_new_auction_delay(&mut self, v: u64) {
self.new_auction_delay = v;
}
}
impl ::protobuf::Message for ChainSpec_NewAuctionDelay {
fn is_initialized(&self) -> bool {
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_uint64()?;
self.new_auction_delay = tmp;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if self.new_auction_delay != 0 {
my_size += ::protobuf::rt::value_size(1, self.new_auction_delay, ::protobuf::wire_format::WireTypeVarint);
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if self.new_auction_delay != 0 {
os.write_uint64(1, self.new_auction_delay)?;
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> ChainSpec_NewAuctionDelay {
ChainSpec_NewAuctionDelay::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeUint64>(
"new_auction_delay",
|m: &ChainSpec_NewAuctionDelay| { &m.new_auction_delay },
|m: &mut ChainSpec_NewAuctionDelay| { &mut m.new_auction_delay },
));
::protobuf::reflect::MessageDescriptor::new::<ChainSpec_NewAuctionDelay>(
"ChainSpec_NewAuctionDelay",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static ChainSpec_NewAuctionDelay {
static mut instance: ::protobuf::lazy::Lazy<ChainSpec_NewAuctionDelay> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ChainSpec_NewAuctionDelay,
};
unsafe {
instance.get(ChainSpec_NewAuctionDelay::new)
}
}
}
impl ::protobuf::Clear for ChainSpec_NewAuctionDelay {
fn clear(&mut self) {
self.new_auction_delay = 0;
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for ChainSpec_NewAuctionDelay {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for ChainSpec_NewAuctionDelay {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct ChainSpec_NewLockedFundsPeriod {
pub new_locked_funds_period: u64,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a ChainSpec_NewLockedFundsPeriod {
fn default() -> &'a ChainSpec_NewLockedFundsPeriod {
<ChainSpec_NewLockedFundsPeriod as ::protobuf::Message>::default_instance()
}
}
impl ChainSpec_NewLockedFundsPeriod {
pub fn new() -> ChainSpec_NewLockedFundsPeriod {
::std::default::Default::default()
}
pub fn get_new_locked_funds_period(&self) -> u64 {
self.new_locked_funds_period
}
pub fn clear_new_locked_funds_period(&mut self) {
self.new_locked_funds_period = 0;
}
pub fn set_new_locked_funds_period(&mut self, v: u64) {
self.new_locked_funds_period = v;
}
}
impl ::protobuf::Message for ChainSpec_NewLockedFundsPeriod {
fn is_initialized(&self) -> bool {
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_uint64()?;
self.new_locked_funds_period = tmp;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if self.new_locked_funds_period != 0 {
my_size += ::protobuf::rt::value_size(1, self.new_locked_funds_period, ::protobuf::wire_format::WireTypeVarint);
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if self.new_locked_funds_period != 0 {
os.write_uint64(1, self.new_locked_funds_period)?;
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> ChainSpec_NewLockedFundsPeriod {
ChainSpec_NewLockedFundsPeriod::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeUint64>(
"new_locked_funds_period",
|m: &ChainSpec_NewLockedFundsPeriod| { &m.new_locked_funds_period },
|m: &mut ChainSpec_NewLockedFundsPeriod| { &mut m.new_locked_funds_period },
));
::protobuf::reflect::MessageDescriptor::new::<ChainSpec_NewLockedFundsPeriod>(
"ChainSpec_NewLockedFundsPeriod",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static ChainSpec_NewLockedFundsPeriod {
static mut instance: ::protobuf::lazy::Lazy<ChainSpec_NewLockedFundsPeriod> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ChainSpec_NewLockedFundsPeriod,
};
unsafe {
instance.get(ChainSpec_NewLockedFundsPeriod::new)
}
}
}
impl ::protobuf::Clear for ChainSpec_NewLockedFundsPeriod {
fn clear(&mut self) {
self.new_locked_funds_period = 0;
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for ChainSpec_NewLockedFundsPeriod {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for ChainSpec_NewLockedFundsPeriod {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct ChainSpec_ActivationPoint {
pub height: u64,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a ChainSpec_ActivationPoint {
fn default() -> &'a ChainSpec_ActivationPoint {
<ChainSpec_ActivationPoint as ::protobuf::Message>::default_instance()
}
}
impl ChainSpec_ActivationPoint {
pub fn new() -> ChainSpec_ActivationPoint {
::std::default::Default::default()
}
pub fn get_height(&self) -> u64 {
self.height
}
pub fn clear_height(&mut self) {
self.height = 0;
}
pub fn set_height(&mut self, v: u64) {
self.height = v;
}
}
impl ::protobuf::Message for ChainSpec_ActivationPoint {
fn is_initialized(&self) -> bool {
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_uint64()?;
self.height = tmp;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if self.height != 0 {
my_size += ::protobuf::rt::value_size(1, self.height, ::protobuf::wire_format::WireTypeVarint);
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if self.height != 0 {
os.write_uint64(1, self.height)?;
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> ChainSpec_ActivationPoint {
ChainSpec_ActivationPoint::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeUint64>(
"height",
|m: &ChainSpec_ActivationPoint| { &m.height },
|m: &mut ChainSpec_ActivationPoint| { &mut m.height },
));
::protobuf::reflect::MessageDescriptor::new::<ChainSpec_ActivationPoint>(
"ChainSpec_ActivationPoint",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static ChainSpec_ActivationPoint {
static mut instance: ::protobuf::lazy::Lazy<ChainSpec_ActivationPoint> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ChainSpec_ActivationPoint,
};
unsafe {
instance.get(ChainSpec_ActivationPoint::new)
}
}
}
impl ::protobuf::Clear for ChainSpec_ActivationPoint {
fn clear(&mut self) {
self.height = 0;
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for ChainSpec_ActivationPoint {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for ChainSpec_ActivationPoint {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct UpgradeRequest {
pub parent_state_hash: ::std::vec::Vec<u8>,
pub upgrade_point: ::protobuf::SingularPtrField<ChainSpec_UpgradePoint>,
pub protocol_version: ::protobuf::SingularPtrField<super::state::ProtocolVersion>,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a UpgradeRequest {
fn default() -> &'a UpgradeRequest {
<UpgradeRequest as ::protobuf::Message>::default_instance()
}
}
impl UpgradeRequest {
pub fn new() -> UpgradeRequest {
::std::default::Default::default()
}
pub fn get_parent_state_hash(&self) -> &[u8] {
&self.parent_state_hash
}
pub fn clear_parent_state_hash(&mut self) {
self.parent_state_hash.clear();
}
pub fn set_parent_state_hash(&mut self, v: ::std::vec::Vec<u8>) {
self.parent_state_hash = v;
}
pub fn mut_parent_state_hash(&mut self) -> &mut ::std::vec::Vec<u8> {
&mut self.parent_state_hash
}
pub fn take_parent_state_hash(&mut self) -> ::std::vec::Vec<u8> {
::std::mem::replace(&mut self.parent_state_hash, ::std::vec::Vec::new())
}
pub fn get_upgrade_point(&self) -> &ChainSpec_UpgradePoint {
self.upgrade_point.as_ref().unwrap_or_else(|| ChainSpec_UpgradePoint::default_instance())
}
pub fn clear_upgrade_point(&mut self) {
self.upgrade_point.clear();
}
pub fn has_upgrade_point(&self) -> bool {
self.upgrade_point.is_some()
}
pub fn set_upgrade_point(&mut self, v: ChainSpec_UpgradePoint) {
self.upgrade_point = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_upgrade_point(&mut self) -> &mut ChainSpec_UpgradePoint {
if self.upgrade_point.is_none() {
self.upgrade_point.set_default();
}
self.upgrade_point.as_mut().unwrap()
}
pub fn take_upgrade_point(&mut self) -> ChainSpec_UpgradePoint {
self.upgrade_point.take().unwrap_or_else(|| ChainSpec_UpgradePoint::new())
}
pub fn get_protocol_version(&self) -> &super::state::ProtocolVersion {
self.protocol_version.as_ref().unwrap_or_else(|| super::state::ProtocolVersion::default_instance())
}
pub fn clear_protocol_version(&mut self) {
self.protocol_version.clear();
}
pub fn has_protocol_version(&self) -> bool {
self.protocol_version.is_some()
}
pub fn set_protocol_version(&mut self, v: super::state::ProtocolVersion) {
self.protocol_version = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_protocol_version(&mut self) -> &mut super::state::ProtocolVersion {
if self.protocol_version.is_none() {
self.protocol_version.set_default();
}
self.protocol_version.as_mut().unwrap()
}
pub fn take_protocol_version(&mut self) -> super::state::ProtocolVersion {
self.protocol_version.take().unwrap_or_else(|| super::state::ProtocolVersion::new())
}
}
impl ::protobuf::Message for UpgradeRequest {
fn is_initialized(&self) -> bool {
for v in &self.upgrade_point {
if !v.is_initialized() {
return false;
}
};
for v in &self.protocol_version {
if !v.is_initialized() {
return false;
}
};
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
::protobuf::rt::read_singular_proto3_bytes_into(wire_type, is, &mut self.parent_state_hash)?;
},
2 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.upgrade_point)?;
},
3 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.protocol_version)?;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if !self.parent_state_hash.is_empty() {
my_size += ::protobuf::rt::bytes_size(1, &self.parent_state_hash);
}
if let Some(ref v) = self.upgrade_point.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
if let Some(ref v) = self.protocol_version.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if !self.parent_state_hash.is_empty() {
os.write_bytes(1, &self.parent_state_hash)?;
}
if let Some(ref v) = self.upgrade_point.as_ref() {
os.write_tag(2, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
if let Some(ref v) = self.protocol_version.as_ref() {
os.write_tag(3, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> UpgradeRequest {
UpgradeRequest::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
"parent_state_hash",
|m: &UpgradeRequest| { &m.parent_state_hash },
|m: &mut UpgradeRequest| { &mut m.parent_state_hash },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChainSpec_UpgradePoint>>(
"upgrade_point",
|m: &UpgradeRequest| { &m.upgrade_point },
|m: &mut UpgradeRequest| { &mut m.upgrade_point },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<super::state::ProtocolVersion>>(
"protocol_version",
|m: &UpgradeRequest| { &m.protocol_version },
|m: &mut UpgradeRequest| { &mut m.protocol_version },
));
::protobuf::reflect::MessageDescriptor::new::<UpgradeRequest>(
"UpgradeRequest",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static UpgradeRequest {
static mut instance: ::protobuf::lazy::Lazy<UpgradeRequest> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const UpgradeRequest,
};
unsafe {
instance.get(UpgradeRequest::new)
}
}
}
impl ::protobuf::Clear for UpgradeRequest {
fn clear(&mut self) {
self.parent_state_hash.clear();
self.upgrade_point.clear();
self.protocol_version.clear();
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for UpgradeRequest {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for UpgradeRequest {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct UpgradeResult {
pub post_state_hash: ::std::vec::Vec<u8>,
pub effect: ::protobuf::SingularPtrField<ExecutionEffect>,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a UpgradeResult {
fn default() -> &'a UpgradeResult {
<UpgradeResult as ::protobuf::Message>::default_instance()
}
}
impl UpgradeResult {
pub fn new() -> UpgradeResult {
::std::default::Default::default()
}
pub fn get_post_state_hash(&self) -> &[u8] {
&self.post_state_hash
}
pub fn clear_post_state_hash(&mut self) {
self.post_state_hash.clear();
}
pub fn set_post_state_hash(&mut self, v: ::std::vec::Vec<u8>) {
self.post_state_hash = v;
}
pub fn mut_post_state_hash(&mut self) -> &mut ::std::vec::Vec<u8> {
&mut self.post_state_hash
}
pub fn take_post_state_hash(&mut self) -> ::std::vec::Vec<u8> {
::std::mem::replace(&mut self.post_state_hash, ::std::vec::Vec::new())
}
pub fn get_effect(&self) -> &ExecutionEffect {
self.effect.as_ref().unwrap_or_else(|| ExecutionEffect::default_instance())
}
pub fn clear_effect(&mut self) {
self.effect.clear();
}
pub fn has_effect(&self) -> bool {
self.effect.is_some()
}
pub fn set_effect(&mut self, v: ExecutionEffect) {
self.effect = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_effect(&mut self) -> &mut ExecutionEffect {
if self.effect.is_none() {
self.effect.set_default();
}
self.effect.as_mut().unwrap()
}
pub fn take_effect(&mut self) -> ExecutionEffect {
self.effect.take().unwrap_or_else(|| ExecutionEffect::new())
}
}
impl ::protobuf::Message for UpgradeResult {
fn is_initialized(&self) -> bool {
for v in &self.effect {
if !v.is_initialized() {
return false;
}
};
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
::protobuf::rt::read_singular_proto3_bytes_into(wire_type, is, &mut self.post_state_hash)?;
},
2 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.effect)?;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if !self.post_state_hash.is_empty() {
my_size += ::protobuf::rt::bytes_size(1, &self.post_state_hash);
}
if let Some(ref v) = self.effect.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if !self.post_state_hash.is_empty() {
os.write_bytes(1, &self.post_state_hash)?;
}
if let Some(ref v) = self.effect.as_ref() {
os.write_tag(2, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> UpgradeResult {
UpgradeResult::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
"post_state_hash",
|m: &UpgradeResult| { &m.post_state_hash },
|m: &mut UpgradeResult| { &mut m.post_state_hash },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ExecutionEffect>>(
"effect",
|m: &UpgradeResult| { &m.effect },
|m: &mut UpgradeResult| { &mut m.effect },
));
::protobuf::reflect::MessageDescriptor::new::<UpgradeResult>(
"UpgradeResult",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static UpgradeResult {
static mut instance: ::protobuf::lazy::Lazy<UpgradeResult> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const UpgradeResult,
};
unsafe {
instance.get(UpgradeResult::new)
}
}
}
impl ::protobuf::Clear for UpgradeResult {
fn clear(&mut self) {
self.post_state_hash.clear();
self.effect.clear();
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for UpgradeResult {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for UpgradeResult {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct UpgradeDeployError {
pub message: ::std::string::String,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a UpgradeDeployError {
fn default() -> &'a UpgradeDeployError {
<UpgradeDeployError as ::protobuf::Message>::default_instance()
}
}
impl UpgradeDeployError {
pub fn new() -> UpgradeDeployError {
::std::default::Default::default()
}
pub fn get_message(&self) -> &str {
&self.message
}
pub fn clear_message(&mut self) {
self.message.clear();
}
pub fn set_message(&mut self, v: ::std::string::String) {
self.message = v;
}
pub fn mut_message(&mut self) -> &mut ::std::string::String {
&mut self.message
}
pub fn take_message(&mut self) -> ::std::string::String {
::std::mem::replace(&mut self.message, ::std::string::String::new())
}
}
impl ::protobuf::Message for UpgradeDeployError {
fn is_initialized(&self) -> bool {
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
::protobuf::rt::read_singular_proto3_string_into(wire_type, is, &mut self.message)?;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if !self.message.is_empty() {
my_size += ::protobuf::rt::string_size(1, &self.message);
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if !self.message.is_empty() {
os.write_string(1, &self.message)?;
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> UpgradeDeployError {
UpgradeDeployError::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeString>(
"message",
|m: &UpgradeDeployError| { &m.message },
|m: &mut UpgradeDeployError| { &mut m.message },
));
::protobuf::reflect::MessageDescriptor::new::<UpgradeDeployError>(
"UpgradeDeployError",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static UpgradeDeployError {
static mut instance: ::protobuf::lazy::Lazy<UpgradeDeployError> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const UpgradeDeployError,
};
unsafe {
instance.get(UpgradeDeployError::new)
}
}
}
impl ::protobuf::Clear for UpgradeDeployError {
fn clear(&mut self) {
self.message.clear();
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for UpgradeDeployError {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for UpgradeDeployError {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct UpgradeResponse {
pub result: ::std::option::Option<UpgradeResponse_oneof_result>,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a UpgradeResponse {
fn default() -> &'a UpgradeResponse {
<UpgradeResponse as ::protobuf::Message>::default_instance()
}
}
#[derive(Clone,PartialEq,Debug)]
pub enum UpgradeResponse_oneof_result {
success(UpgradeResult),
failed_deploy(UpgradeDeployError),
}
impl UpgradeResponse {
pub fn new() -> UpgradeResponse {
::std::default::Default::default()
}
pub fn get_success(&self) -> &UpgradeResult {
match self.result {
::std::option::Option::Some(UpgradeResponse_oneof_result::success(ref v)) => v,
_ => UpgradeResult::default_instance(),
}
}
pub fn clear_success(&mut self) {
self.result = ::std::option::Option::None;
}
pub fn has_success(&self) -> bool {
match self.result {
::std::option::Option::Some(UpgradeResponse_oneof_result::success(..)) => true,
_ => false,
}
}
pub fn set_success(&mut self, v: UpgradeResult) {
self.result = ::std::option::Option::Some(UpgradeResponse_oneof_result::success(v))
}
pub fn mut_success(&mut self) -> &mut UpgradeResult {
if let ::std::option::Option::Some(UpgradeResponse_oneof_result::success(_)) = self.result {
} else {
self.result = ::std::option::Option::Some(UpgradeResponse_oneof_result::success(UpgradeResult::new()));
}
match self.result {
::std::option::Option::Some(UpgradeResponse_oneof_result::success(ref mut v)) => v,
_ => panic!(),
}
}
pub fn take_success(&mut self) -> UpgradeResult {
if self.has_success() {
match self.result.take() {
::std::option::Option::Some(UpgradeResponse_oneof_result::success(v)) => v,
_ => panic!(),
}
} else {
UpgradeResult::new()
}
}
pub fn get_failed_deploy(&self) -> &UpgradeDeployError {
match self.result {
::std::option::Option::Some(UpgradeResponse_oneof_result::failed_deploy(ref v)) => v,
_ => UpgradeDeployError::default_instance(),
}
}
pub fn clear_failed_deploy(&mut self) {
self.result = ::std::option::Option::None;
}
pub fn has_failed_deploy(&self) -> bool {
match self.result {
::std::option::Option::Some(UpgradeResponse_oneof_result::failed_deploy(..)) => true,
_ => false,
}
}
pub fn set_failed_deploy(&mut self, v: UpgradeDeployError) {
self.result = ::std::option::Option::Some(UpgradeResponse_oneof_result::failed_deploy(v))
}
pub fn mut_failed_deploy(&mut self) -> &mut UpgradeDeployError {
if let ::std::option::Option::Some(UpgradeResponse_oneof_result::failed_deploy(_)) = self.result {
} else {
self.result = ::std::option::Option::Some(UpgradeResponse_oneof_result::failed_deploy(UpgradeDeployError::new()));
}
match self.result {
::std::option::Option::Some(UpgradeResponse_oneof_result::failed_deploy(ref mut v)) => v,
_ => panic!(),
}
}
pub fn take_failed_deploy(&mut self) -> UpgradeDeployError {
if self.has_failed_deploy() {
match self.result.take() {
::std::option::Option::Some(UpgradeResponse_oneof_result::failed_deploy(v)) => v,
_ => panic!(),
}
} else {
UpgradeDeployError::new()
}
}
}
impl ::protobuf::Message for UpgradeResponse {
fn is_initialized(&self) -> bool {
if let Some(UpgradeResponse_oneof_result::success(ref v)) = self.result {
if !v.is_initialized() {
return false;
}
}
if let Some(UpgradeResponse_oneof_result::failed_deploy(ref v)) = self.result {
if !v.is_initialized() {
return false;
}
}
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
if wire_type != ::protobuf::wire_format::WireTypeLengthDelimited {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
self.result = ::std::option::Option::Some(UpgradeResponse_oneof_result::success(is.read_message()?));
},
2 => {
if wire_type != ::protobuf::wire_format::WireTypeLengthDelimited {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
self.result = ::std::option::Option::Some(UpgradeResponse_oneof_result::failed_deploy(is.read_message()?));
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if let ::std::option::Option::Some(ref v) = self.result {
match v {
&UpgradeResponse_oneof_result::success(ref v) => {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
},
&UpgradeResponse_oneof_result::failed_deploy(ref v) => {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
},
};
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if let ::std::option::Option::Some(ref v) = self.result {
match v {
&UpgradeResponse_oneof_result::success(ref v) => {
os.write_tag(1, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
},
&UpgradeResponse_oneof_result::failed_deploy(ref v) => {
os.write_tag(2, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
},
};
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> UpgradeResponse {
UpgradeResponse::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_singular_message_accessor::<_, UpgradeResult>(
"success",
UpgradeResponse::has_success,
UpgradeResponse::get_success,
));
fields.push(::protobuf::reflect::accessor::make_singular_message_accessor::<_, UpgradeDeployError>(
"failed_deploy",
UpgradeResponse::has_failed_deploy,
UpgradeResponse::get_failed_deploy,
));
::protobuf::reflect::MessageDescriptor::new::<UpgradeResponse>(
"UpgradeResponse",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static UpgradeResponse {
static mut instance: ::protobuf::lazy::Lazy<UpgradeResponse> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const UpgradeResponse,
};
unsafe {
instance.get(UpgradeResponse::new)
}
}
}
impl ::protobuf::Clear for UpgradeResponse {
fn clear(&mut self) {
self.result = ::std::option::Option::None;
self.result = ::std::option::Option::None;
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for UpgradeResponse {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for UpgradeResponse {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct GetEraValidatorsRequest {
pub parent_state_hash: ::std::vec::Vec<u8>,
pub era_id: u64,
pub protocol_version: ::protobuf::SingularPtrField<super::state::ProtocolVersion>,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a GetEraValidatorsRequest {
fn default() -> &'a GetEraValidatorsRequest {
<GetEraValidatorsRequest as ::protobuf::Message>::default_instance()
}
}
impl GetEraValidatorsRequest {
pub fn new() -> GetEraValidatorsRequest {
::std::default::Default::default()
}
pub fn get_parent_state_hash(&self) -> &[u8] {
&self.parent_state_hash
}
pub fn clear_parent_state_hash(&mut self) {
self.parent_state_hash.clear();
}
pub fn set_parent_state_hash(&mut self, v: ::std::vec::Vec<u8>) {
self.parent_state_hash = v;
}
pub fn mut_parent_state_hash(&mut self) -> &mut ::std::vec::Vec<u8> {
&mut self.parent_state_hash
}
pub fn take_parent_state_hash(&mut self) -> ::std::vec::Vec<u8> {
::std::mem::replace(&mut self.parent_state_hash, ::std::vec::Vec::new())
}
pub fn get_era_id(&self) -> u64 {
self.era_id
}
pub fn clear_era_id(&mut self) {
self.era_id = 0;
}
pub fn set_era_id(&mut self, v: u64) {
self.era_id = v;
}
pub fn get_protocol_version(&self) -> &super::state::ProtocolVersion {
self.protocol_version.as_ref().unwrap_or_else(|| super::state::ProtocolVersion::default_instance())
}
pub fn clear_protocol_version(&mut self) {
self.protocol_version.clear();
}
pub fn has_protocol_version(&self) -> bool {
self.protocol_version.is_some()
}
pub fn set_protocol_version(&mut self, v: super::state::ProtocolVersion) {
self.protocol_version = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_protocol_version(&mut self) -> &mut super::state::ProtocolVersion {
if self.protocol_version.is_none() {
self.protocol_version.set_default();
}
self.protocol_version.as_mut().unwrap()
}
pub fn take_protocol_version(&mut self) -> super::state::ProtocolVersion {
self.protocol_version.take().unwrap_or_else(|| super::state::ProtocolVersion::new())
}
}
impl ::protobuf::Message for GetEraValidatorsRequest {
fn is_initialized(&self) -> bool {
for v in &self.protocol_version {
if !v.is_initialized() {
return false;
}
};
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
::protobuf::rt::read_singular_proto3_bytes_into(wire_type, is, &mut self.parent_state_hash)?;
},
2 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_uint64()?;
self.era_id = tmp;
},
3 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.protocol_version)?;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if !self.parent_state_hash.is_empty() {
my_size += ::protobuf::rt::bytes_size(1, &self.parent_state_hash);
}
if self.era_id != 0 {
my_size += ::protobuf::rt::value_size(2, self.era_id, ::protobuf::wire_format::WireTypeVarint);
}
if let Some(ref v) = self.protocol_version.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if !self.parent_state_hash.is_empty() {
os.write_bytes(1, &self.parent_state_hash)?;
}
if self.era_id != 0 {
os.write_uint64(2, self.era_id)?;
}
if let Some(ref v) = self.protocol_version.as_ref() {
os.write_tag(3, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> GetEraValidatorsRequest {
GetEraValidatorsRequest::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
"parent_state_hash",
|m: &GetEraValidatorsRequest| { &m.parent_state_hash },
|m: &mut GetEraValidatorsRequest| { &mut m.parent_state_hash },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeUint64>(
"era_id",
|m: &GetEraValidatorsRequest| { &m.era_id },
|m: &mut GetEraValidatorsRequest| { &mut m.era_id },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<super::state::ProtocolVersion>>(
"protocol_version",
|m: &GetEraValidatorsRequest| { &m.protocol_version },
|m: &mut GetEraValidatorsRequest| { &mut m.protocol_version },
));
::protobuf::reflect::MessageDescriptor::new::<GetEraValidatorsRequest>(
"GetEraValidatorsRequest",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static GetEraValidatorsRequest {
static mut instance: ::protobuf::lazy::Lazy<GetEraValidatorsRequest> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const GetEraValidatorsRequest,
};
unsafe {
instance.get(GetEraValidatorsRequest::new)
}
}
}
impl ::protobuf::Clear for GetEraValidatorsRequest {
fn clear(&mut self) {
self.parent_state_hash.clear();
self.era_id = 0;
self.protocol_version.clear();
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for GetEraValidatorsRequest {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for GetEraValidatorsRequest {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct GetEraValidatorsResponse {
pub result: ::std::option::Option<GetEraValidatorsResponse_oneof_result>,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a GetEraValidatorsResponse {
fn default() -> &'a GetEraValidatorsResponse {
<GetEraValidatorsResponse as ::protobuf::Message>::default_instance()
}
}
#[derive(Clone,PartialEq,Debug)]
pub enum GetEraValidatorsResponse_oneof_result {
success(GetEraValidatorsResponse_ValidatorWeights),
missing_prestate(RootNotFound),
error(GetEraValidatorsResponse_GetEraValidatorsError),
}
impl GetEraValidatorsResponse {
pub fn new() -> GetEraValidatorsResponse {
::std::default::Default::default()
}
pub fn get_success(&self) -> &GetEraValidatorsResponse_ValidatorWeights {
match self.result {
::std::option::Option::Some(GetEraValidatorsResponse_oneof_result::success(ref v)) => v,
_ => GetEraValidatorsResponse_ValidatorWeights::default_instance(),
}
}
pub fn clear_success(&mut self) {
self.result = ::std::option::Option::None;
}
pub fn has_success(&self) -> bool {
match self.result {
::std::option::Option::Some(GetEraValidatorsResponse_oneof_result::success(..)) => true,
_ => false,
}
}
pub fn set_success(&mut self, v: GetEraValidatorsResponse_ValidatorWeights) {
self.result = ::std::option::Option::Some(GetEraValidatorsResponse_oneof_result::success(v))
}
pub fn mut_success(&mut self) -> &mut GetEraValidatorsResponse_ValidatorWeights {
if let ::std::option::Option::Some(GetEraValidatorsResponse_oneof_result::success(_)) = self.result {
} else {
self.result = ::std::option::Option::Some(GetEraValidatorsResponse_oneof_result::success(GetEraValidatorsResponse_ValidatorWeights::new()));
}
match self.result {
::std::option::Option::Some(GetEraValidatorsResponse_oneof_result::success(ref mut v)) => v,
_ => panic!(),
}
}
pub fn take_success(&mut self) -> GetEraValidatorsResponse_ValidatorWeights {
if self.has_success() {
match self.result.take() {
::std::option::Option::Some(GetEraValidatorsResponse_oneof_result::success(v)) => v,
_ => panic!(),
}
} else {
GetEraValidatorsResponse_ValidatorWeights::new()
}
}
pub fn get_missing_prestate(&self) -> &RootNotFound {
match self.result {
::std::option::Option::Some(GetEraValidatorsResponse_oneof_result::missing_prestate(ref v)) => v,
_ => RootNotFound::default_instance(),
}
}
pub fn clear_missing_prestate(&mut self) {
self.result = ::std::option::Option::None;
}
pub fn has_missing_prestate(&self) -> bool {
match self.result {
::std::option::Option::Some(GetEraValidatorsResponse_oneof_result::missing_prestate(..)) => true,
_ => false,
}
}
pub fn set_missing_prestate(&mut self, v: RootNotFound) {
self.result = ::std::option::Option::Some(GetEraValidatorsResponse_oneof_result::missing_prestate(v))
}
pub fn mut_missing_prestate(&mut self) -> &mut RootNotFound {
if let ::std::option::Option::Some(GetEraValidatorsResponse_oneof_result::missing_prestate(_)) = self.result {
} else {
self.result = ::std::option::Option::Some(GetEraValidatorsResponse_oneof_result::missing_prestate(RootNotFound::new()));
}
match self.result {
::std::option::Option::Some(GetEraValidatorsResponse_oneof_result::missing_prestate(ref mut v)) => v,
_ => panic!(),
}
}
pub fn take_missing_prestate(&mut self) -> RootNotFound {
if self.has_missing_prestate() {
match self.result.take() {
::std::option::Option::Some(GetEraValidatorsResponse_oneof_result::missing_prestate(v)) => v,
_ => panic!(),
}
} else {
RootNotFound::new()
}
}
pub fn get_error(&self) -> &GetEraValidatorsResponse_GetEraValidatorsError {
match self.result {
::std::option::Option::Some(GetEraValidatorsResponse_oneof_result::error(ref v)) => v,
_ => GetEraValidatorsResponse_GetEraValidatorsError::default_instance(),
}
}
pub fn clear_error(&mut self) {
self.result = ::std::option::Option::None;
}
pub fn has_error(&self) -> bool {
match self.result {
::std::option::Option::Some(GetEraValidatorsResponse_oneof_result::error(..)) => true,
_ => false,
}
}
pub fn set_error(&mut self, v: GetEraValidatorsResponse_GetEraValidatorsError) {
self.result = ::std::option::Option::Some(GetEraValidatorsResponse_oneof_result::error(v))
}
pub fn mut_error(&mut self) -> &mut GetEraValidatorsResponse_GetEraValidatorsError {
if let ::std::option::Option::Some(GetEraValidatorsResponse_oneof_result::error(_)) = self.result {
} else {
self.result = ::std::option::Option::Some(GetEraValidatorsResponse_oneof_result::error(GetEraValidatorsResponse_GetEraValidatorsError::new()));
}
match self.result {
::std::option::Option::Some(GetEraValidatorsResponse_oneof_result::error(ref mut v)) => v,
_ => panic!(),
}
}
pub fn take_error(&mut self) -> GetEraValidatorsResponse_GetEraValidatorsError {
if self.has_error() {
match self.result.take() {
::std::option::Option::Some(GetEraValidatorsResponse_oneof_result::error(v)) => v,
_ => panic!(),
}
} else {
GetEraValidatorsResponse_GetEraValidatorsError::new()
}
}
}
impl ::protobuf::Message for GetEraValidatorsResponse {
fn is_initialized(&self) -> bool {
if let Some(GetEraValidatorsResponse_oneof_result::success(ref v)) = self.result {
if !v.is_initialized() {
return false;
}
}
if let Some(GetEraValidatorsResponse_oneof_result::missing_prestate(ref v)) = self.result {
if !v.is_initialized() {
return false;
}
}
if let Some(GetEraValidatorsResponse_oneof_result::error(ref v)) = self.result {
if !v.is_initialized() {
return false;
}
}
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
if wire_type != ::protobuf::wire_format::WireTypeLengthDelimited {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
self.result = ::std::option::Option::Some(GetEraValidatorsResponse_oneof_result::success(is.read_message()?));
},
2 => {
if wire_type != ::protobuf::wire_format::WireTypeLengthDelimited {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
self.result = ::std::option::Option::Some(GetEraValidatorsResponse_oneof_result::missing_prestate(is.read_message()?));
},
5 => {
if wire_type != ::protobuf::wire_format::WireTypeLengthDelimited {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
self.result = ::std::option::Option::Some(GetEraValidatorsResponse_oneof_result::error(is.read_message()?));
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if let ::std::option::Option::Some(ref v) = self.result {
match v {
&GetEraValidatorsResponse_oneof_result::success(ref v) => {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
},
&GetEraValidatorsResponse_oneof_result::missing_prestate(ref v) => {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
},
&GetEraValidatorsResponse_oneof_result::error(ref v) => {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
},
};
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if let ::std::option::Option::Some(ref v) = self.result {
match v {
&GetEraValidatorsResponse_oneof_result::success(ref v) => {
os.write_tag(1, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
},
&GetEraValidatorsResponse_oneof_result::missing_prestate(ref v) => {
os.write_tag(2, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
},
&GetEraValidatorsResponse_oneof_result::error(ref v) => {
os.write_tag(5, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
},
};
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> GetEraValidatorsResponse {
GetEraValidatorsResponse::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_singular_message_accessor::<_, GetEraValidatorsResponse_ValidatorWeights>(
"success",
GetEraValidatorsResponse::has_success,
GetEraValidatorsResponse::get_success,
));
fields.push(::protobuf::reflect::accessor::make_singular_message_accessor::<_, RootNotFound>(
"missing_prestate",
GetEraValidatorsResponse::has_missing_prestate,
GetEraValidatorsResponse::get_missing_prestate,
));
fields.push(::protobuf::reflect::accessor::make_singular_message_accessor::<_, GetEraValidatorsResponse_GetEraValidatorsError>(
"error",
GetEraValidatorsResponse::has_error,
GetEraValidatorsResponse::get_error,
));
::protobuf::reflect::MessageDescriptor::new::<GetEraValidatorsResponse>(
"GetEraValidatorsResponse",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static GetEraValidatorsResponse {
static mut instance: ::protobuf::lazy::Lazy<GetEraValidatorsResponse> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const GetEraValidatorsResponse,
};
unsafe {
instance.get(GetEraValidatorsResponse::new)
}
}
}
impl ::protobuf::Clear for GetEraValidatorsResponse {
fn clear(&mut self) {
self.result = ::std::option::Option::None;
self.result = ::std::option::Option::None;
self.result = ::std::option::Option::None;
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for GetEraValidatorsResponse {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for GetEraValidatorsResponse {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct GetEraValidatorsResponse_ValidatorWeights {
pub validator_weights: ::protobuf::RepeatedField<GetEraValidatorsResponse_ValidatorWeights_ValidatorWeight>,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a GetEraValidatorsResponse_ValidatorWeights {
fn default() -> &'a GetEraValidatorsResponse_ValidatorWeights {
<GetEraValidatorsResponse_ValidatorWeights as ::protobuf::Message>::default_instance()
}
}
impl GetEraValidatorsResponse_ValidatorWeights {
pub fn new() -> GetEraValidatorsResponse_ValidatorWeights {
::std::default::Default::default()
}
pub fn get_validator_weights(&self) -> &[GetEraValidatorsResponse_ValidatorWeights_ValidatorWeight] {
&self.validator_weights
}
pub fn clear_validator_weights(&mut self) {
self.validator_weights.clear();
}
pub fn set_validator_weights(&mut self, v: ::protobuf::RepeatedField<GetEraValidatorsResponse_ValidatorWeights_ValidatorWeight>) {
self.validator_weights = v;
}
pub fn mut_validator_weights(&mut self) -> &mut ::protobuf::RepeatedField<GetEraValidatorsResponse_ValidatorWeights_ValidatorWeight> {
&mut self.validator_weights
}
pub fn take_validator_weights(&mut self) -> ::protobuf::RepeatedField<GetEraValidatorsResponse_ValidatorWeights_ValidatorWeight> {
::std::mem::replace(&mut self.validator_weights, ::protobuf::RepeatedField::new())
}
}
impl ::protobuf::Message for GetEraValidatorsResponse_ValidatorWeights {
fn is_initialized(&self) -> bool {
for v in &self.validator_weights {
if !v.is_initialized() {
return false;
}
};
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
::protobuf::rt::read_repeated_message_into(wire_type, is, &mut self.validator_weights)?;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
for value in &self.validator_weights {
let len = value.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
};
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
for v in &self.validator_weights {
os.write_tag(1, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
};
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> GetEraValidatorsResponse_ValidatorWeights {
GetEraValidatorsResponse_ValidatorWeights::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_repeated_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<GetEraValidatorsResponse_ValidatorWeights_ValidatorWeight>>(
"validator_weights",
|m: &GetEraValidatorsResponse_ValidatorWeights| { &m.validator_weights },
|m: &mut GetEraValidatorsResponse_ValidatorWeights| { &mut m.validator_weights },
));
::protobuf::reflect::MessageDescriptor::new::<GetEraValidatorsResponse_ValidatorWeights>(
"GetEraValidatorsResponse_ValidatorWeights",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static GetEraValidatorsResponse_ValidatorWeights {
static mut instance: ::protobuf::lazy::Lazy<GetEraValidatorsResponse_ValidatorWeights> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const GetEraValidatorsResponse_ValidatorWeights,
};
unsafe {
instance.get(GetEraValidatorsResponse_ValidatorWeights::new)
}
}
}
impl ::protobuf::Clear for GetEraValidatorsResponse_ValidatorWeights {
fn clear(&mut self) {
self.validator_weights.clear();
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for GetEraValidatorsResponse_ValidatorWeights {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for GetEraValidatorsResponse_ValidatorWeights {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct GetEraValidatorsResponse_ValidatorWeights_ValidatorWeight {
pub public_key_bytes: ::std::vec::Vec<u8>,
pub weight: ::protobuf::SingularPtrField<super::state::BigInt>,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a GetEraValidatorsResponse_ValidatorWeights_ValidatorWeight {
fn default() -> &'a GetEraValidatorsResponse_ValidatorWeights_ValidatorWeight {
<GetEraValidatorsResponse_ValidatorWeights_ValidatorWeight as ::protobuf::Message>::default_instance()
}
}
impl GetEraValidatorsResponse_ValidatorWeights_ValidatorWeight {
pub fn new() -> GetEraValidatorsResponse_ValidatorWeights_ValidatorWeight {
::std::default::Default::default()
}
pub fn get_public_key_bytes(&self) -> &[u8] {
&self.public_key_bytes
}
pub fn clear_public_key_bytes(&mut self) {
self.public_key_bytes.clear();
}
pub fn set_public_key_bytes(&mut self, v: ::std::vec::Vec<u8>) {
self.public_key_bytes = v;
}
pub fn mut_public_key_bytes(&mut self) -> &mut ::std::vec::Vec<u8> {
&mut self.public_key_bytes
}
pub fn take_public_key_bytes(&mut self) -> ::std::vec::Vec<u8> {
::std::mem::replace(&mut self.public_key_bytes, ::std::vec::Vec::new())
}
pub fn get_weight(&self) -> &super::state::BigInt {
self.weight.as_ref().unwrap_or_else(|| super::state::BigInt::default_instance())
}
pub fn clear_weight(&mut self) {
self.weight.clear();
}
pub fn has_weight(&self) -> bool {
self.weight.is_some()
}
pub fn set_weight(&mut self, v: super::state::BigInt) {
self.weight = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_weight(&mut self) -> &mut super::state::BigInt {
if self.weight.is_none() {
self.weight.set_default();
}
self.weight.as_mut().unwrap()
}
pub fn take_weight(&mut self) -> super::state::BigInt {
self.weight.take().unwrap_or_else(|| super::state::BigInt::new())
}
}
impl ::protobuf::Message for GetEraValidatorsResponse_ValidatorWeights_ValidatorWeight {
fn is_initialized(&self) -> bool {
for v in &self.weight {
if !v.is_initialized() {
return false;
}
};
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
::protobuf::rt::read_singular_proto3_bytes_into(wire_type, is, &mut self.public_key_bytes)?;
},
2 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.weight)?;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if !self.public_key_bytes.is_empty() {
my_size += ::protobuf::rt::bytes_size(1, &self.public_key_bytes);
}
if let Some(ref v) = self.weight.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if !self.public_key_bytes.is_empty() {
os.write_bytes(1, &self.public_key_bytes)?;
}
if let Some(ref v) = self.weight.as_ref() {
os.write_tag(2, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> GetEraValidatorsResponse_ValidatorWeights_ValidatorWeight {
GetEraValidatorsResponse_ValidatorWeights_ValidatorWeight::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
"public_key_bytes",
|m: &GetEraValidatorsResponse_ValidatorWeights_ValidatorWeight| { &m.public_key_bytes },
|m: &mut GetEraValidatorsResponse_ValidatorWeights_ValidatorWeight| { &mut m.public_key_bytes },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<super::state::BigInt>>(
"weight",
|m: &GetEraValidatorsResponse_ValidatorWeights_ValidatorWeight| { &m.weight },
|m: &mut GetEraValidatorsResponse_ValidatorWeights_ValidatorWeight| { &mut m.weight },
));
::protobuf::reflect::MessageDescriptor::new::<GetEraValidatorsResponse_ValidatorWeights_ValidatorWeight>(
"GetEraValidatorsResponse_ValidatorWeights_ValidatorWeight",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static GetEraValidatorsResponse_ValidatorWeights_ValidatorWeight {
static mut instance: ::protobuf::lazy::Lazy<GetEraValidatorsResponse_ValidatorWeights_ValidatorWeight> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const GetEraValidatorsResponse_ValidatorWeights_ValidatorWeight,
};
unsafe {
instance.get(GetEraValidatorsResponse_ValidatorWeights_ValidatorWeight::new)
}
}
}
impl ::protobuf::Clear for GetEraValidatorsResponse_ValidatorWeights_ValidatorWeight {
fn clear(&mut self) {
self.public_key_bytes.clear();
self.weight.clear();
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for GetEraValidatorsResponse_ValidatorWeights_ValidatorWeight {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for GetEraValidatorsResponse_ValidatorWeights_ValidatorWeight {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct GetEraValidatorsResponse_GetEraValidatorsError {
pub message: ::std::string::String,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a GetEraValidatorsResponse_GetEraValidatorsError {
fn default() -> &'a GetEraValidatorsResponse_GetEraValidatorsError {
<GetEraValidatorsResponse_GetEraValidatorsError as ::protobuf::Message>::default_instance()
}
}
impl GetEraValidatorsResponse_GetEraValidatorsError {
pub fn new() -> GetEraValidatorsResponse_GetEraValidatorsError {
::std::default::Default::default()
}
pub fn get_message(&self) -> &str {
&self.message
}
pub fn clear_message(&mut self) {
self.message.clear();
}
pub fn set_message(&mut self, v: ::std::string::String) {
self.message = v;
}
pub fn mut_message(&mut self) -> &mut ::std::string::String {
&mut self.message
}
pub fn take_message(&mut self) -> ::std::string::String {
::std::mem::replace(&mut self.message, ::std::string::String::new())
}
}
impl ::protobuf::Message for GetEraValidatorsResponse_GetEraValidatorsError {
fn is_initialized(&self) -> bool {
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
::protobuf::rt::read_singular_proto3_string_into(wire_type, is, &mut self.message)?;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if !self.message.is_empty() {
my_size += ::protobuf::rt::string_size(1, &self.message);
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if !self.message.is_empty() {
os.write_string(1, &self.message)?;
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> GetEraValidatorsResponse_GetEraValidatorsError {
GetEraValidatorsResponse_GetEraValidatorsError::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeString>(
"message",
|m: &GetEraValidatorsResponse_GetEraValidatorsError| { &m.message },
|m: &mut GetEraValidatorsResponse_GetEraValidatorsError| { &mut m.message },
));
::protobuf::reflect::MessageDescriptor::new::<GetEraValidatorsResponse_GetEraValidatorsError>(
"GetEraValidatorsResponse_GetEraValidatorsError",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static GetEraValidatorsResponse_GetEraValidatorsError {
static mut instance: ::protobuf::lazy::Lazy<GetEraValidatorsResponse_GetEraValidatorsError> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const GetEraValidatorsResponse_GetEraValidatorsError,
};
unsafe {
instance.get(GetEraValidatorsResponse_GetEraValidatorsError::new)
}
}
}
impl ::protobuf::Clear for GetEraValidatorsResponse_GetEraValidatorsError {
fn clear(&mut self) {
self.message.clear();
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for GetEraValidatorsResponse_GetEraValidatorsError {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for GetEraValidatorsResponse_GetEraValidatorsError {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct StepRequest {
pub parent_state_hash: ::std::vec::Vec<u8>,
pub protocol_version: ::protobuf::SingularPtrField<super::state::ProtocolVersion>,
pub slash_items: ::protobuf::RepeatedField<SlashItem>,
pub reward_items: ::protobuf::RepeatedField<RewardItem>,
pub run_auction: bool,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a StepRequest {
fn default() -> &'a StepRequest {
<StepRequest as ::protobuf::Message>::default_instance()
}
}
impl StepRequest {
pub fn new() -> StepRequest {
::std::default::Default::default()
}
pub fn get_parent_state_hash(&self) -> &[u8] {
&self.parent_state_hash
}
pub fn clear_parent_state_hash(&mut self) {
self.parent_state_hash.clear();
}
pub fn set_parent_state_hash(&mut self, v: ::std::vec::Vec<u8>) {
self.parent_state_hash = v;
}
pub fn mut_parent_state_hash(&mut self) -> &mut ::std::vec::Vec<u8> {
&mut self.parent_state_hash
}
pub fn take_parent_state_hash(&mut self) -> ::std::vec::Vec<u8> {
::std::mem::replace(&mut self.parent_state_hash, ::std::vec::Vec::new())
}
pub fn get_protocol_version(&self) -> &super::state::ProtocolVersion {
self.protocol_version.as_ref().unwrap_or_else(|| super::state::ProtocolVersion::default_instance())
}
pub fn clear_protocol_version(&mut self) {
self.protocol_version.clear();
}
pub fn has_protocol_version(&self) -> bool {
self.protocol_version.is_some()
}
pub fn set_protocol_version(&mut self, v: super::state::ProtocolVersion) {
self.protocol_version = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_protocol_version(&mut self) -> &mut super::state::ProtocolVersion {
if self.protocol_version.is_none() {
self.protocol_version.set_default();
}
self.protocol_version.as_mut().unwrap()
}
pub fn take_protocol_version(&mut self) -> super::state::ProtocolVersion {
self.protocol_version.take().unwrap_or_else(|| super::state::ProtocolVersion::new())
}
pub fn get_slash_items(&self) -> &[SlashItem] {
&self.slash_items
}
pub fn clear_slash_items(&mut self) {
self.slash_items.clear();
}
pub fn set_slash_items(&mut self, v: ::protobuf::RepeatedField<SlashItem>) {
self.slash_items = v;
}
pub fn mut_slash_items(&mut self) -> &mut ::protobuf::RepeatedField<SlashItem> {
&mut self.slash_items
}
pub fn take_slash_items(&mut self) -> ::protobuf::RepeatedField<SlashItem> {
::std::mem::replace(&mut self.slash_items, ::protobuf::RepeatedField::new())
}
pub fn get_reward_items(&self) -> &[RewardItem] {
&self.reward_items
}
pub fn clear_reward_items(&mut self) {
self.reward_items.clear();
}
pub fn set_reward_items(&mut self, v: ::protobuf::RepeatedField<RewardItem>) {
self.reward_items = v;
}
pub fn mut_reward_items(&mut self) -> &mut ::protobuf::RepeatedField<RewardItem> {
&mut self.reward_items
}
pub fn take_reward_items(&mut self) -> ::protobuf::RepeatedField<RewardItem> {
::std::mem::replace(&mut self.reward_items, ::protobuf::RepeatedField::new())
}
pub fn get_run_auction(&self) -> bool {
self.run_auction
}
pub fn clear_run_auction(&mut self) {
self.run_auction = false;
}
pub fn set_run_auction(&mut self, v: bool) {
self.run_auction = v;
}
}
impl ::protobuf::Message for StepRequest {
fn is_initialized(&self) -> bool {
for v in &self.protocol_version {
if !v.is_initialized() {
return false;
}
};
for v in &self.slash_items {
if !v.is_initialized() {
return false;
}
};
for v in &self.reward_items {
if !v.is_initialized() {
return false;
}
};
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
::protobuf::rt::read_singular_proto3_bytes_into(wire_type, is, &mut self.parent_state_hash)?;
},
2 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.protocol_version)?;
},
3 => {
::protobuf::rt::read_repeated_message_into(wire_type, is, &mut self.slash_items)?;
},
4 => {
::protobuf::rt::read_repeated_message_into(wire_type, is, &mut self.reward_items)?;
},
5 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_bool()?;
self.run_auction = tmp;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if !self.parent_state_hash.is_empty() {
my_size += ::protobuf::rt::bytes_size(1, &self.parent_state_hash);
}
if let Some(ref v) = self.protocol_version.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
for value in &self.slash_items {
let len = value.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
};
for value in &self.reward_items {
let len = value.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
};
if self.run_auction != false {
my_size += 2;
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if !self.parent_state_hash.is_empty() {
os.write_bytes(1, &self.parent_state_hash)?;
}
if let Some(ref v) = self.protocol_version.as_ref() {
os.write_tag(2, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
for v in &self.slash_items {
os.write_tag(3, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
};
for v in &self.reward_items {
os.write_tag(4, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
};
if self.run_auction != false {
os.write_bool(5, self.run_auction)?;
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> StepRequest {
StepRequest::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
"parent_state_hash",
|m: &StepRequest| { &m.parent_state_hash },
|m: &mut StepRequest| { &mut m.parent_state_hash },
));
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<super::state::ProtocolVersion>>(
"protocol_version",
|m: &StepRequest| { &m.protocol_version },
|m: &mut StepRequest| { &mut m.protocol_version },
));
fields.push(::protobuf::reflect::accessor::make_repeated_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<SlashItem>>(
"slash_items",
|m: &StepRequest| { &m.slash_items },
|m: &mut StepRequest| { &mut m.slash_items },
));
fields.push(::protobuf::reflect::accessor::make_repeated_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<RewardItem>>(
"reward_items",
|m: &StepRequest| { &m.reward_items },
|m: &mut StepRequest| { &mut m.reward_items },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeBool>(
"run_auction",
|m: &StepRequest| { &m.run_auction },
|m: &mut StepRequest| { &mut m.run_auction },
));
::protobuf::reflect::MessageDescriptor::new::<StepRequest>(
"StepRequest",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static StepRequest {
static mut instance: ::protobuf::lazy::Lazy<StepRequest> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const StepRequest,
};
unsafe {
instance.get(StepRequest::new)
}
}
}
impl ::protobuf::Clear for StepRequest {
fn clear(&mut self) {
self.parent_state_hash.clear();
self.protocol_version.clear();
self.slash_items.clear();
self.reward_items.clear();
self.run_auction = false;
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for StepRequest {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for StepRequest {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct SlashItem {
pub validator_id: ::std::vec::Vec<u8>,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a SlashItem {
fn default() -> &'a SlashItem {
<SlashItem as ::protobuf::Message>::default_instance()
}
}
impl SlashItem {
pub fn new() -> SlashItem {
::std::default::Default::default()
}
pub fn get_validator_id(&self) -> &[u8] {
&self.validator_id
}
pub fn clear_validator_id(&mut self) {
self.validator_id.clear();
}
pub fn set_validator_id(&mut self, v: ::std::vec::Vec<u8>) {
self.validator_id = v;
}
pub fn mut_validator_id(&mut self) -> &mut ::std::vec::Vec<u8> {
&mut self.validator_id
}
pub fn take_validator_id(&mut self) -> ::std::vec::Vec<u8> {
::std::mem::replace(&mut self.validator_id, ::std::vec::Vec::new())
}
}
impl ::protobuf::Message for SlashItem {
fn is_initialized(&self) -> bool {
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
::protobuf::rt::read_singular_proto3_bytes_into(wire_type, is, &mut self.validator_id)?;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if !self.validator_id.is_empty() {
my_size += ::protobuf::rt::bytes_size(1, &self.validator_id);
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if !self.validator_id.is_empty() {
os.write_bytes(1, &self.validator_id)?;
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> SlashItem {
SlashItem::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
"validator_id",
|m: &SlashItem| { &m.validator_id },
|m: &mut SlashItem| { &mut m.validator_id },
));
::protobuf::reflect::MessageDescriptor::new::<SlashItem>(
"SlashItem",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static SlashItem {
static mut instance: ::protobuf::lazy::Lazy<SlashItem> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const SlashItem,
};
unsafe {
instance.get(SlashItem::new)
}
}
}
impl ::protobuf::Clear for SlashItem {
fn clear(&mut self) {
self.validator_id.clear();
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for SlashItem {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for SlashItem {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct RewardItem {
pub validator_id: ::std::vec::Vec<u8>,
pub value: u64,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a RewardItem {
fn default() -> &'a RewardItem {
<RewardItem as ::protobuf::Message>::default_instance()
}
}
impl RewardItem {
pub fn new() -> RewardItem {
::std::default::Default::default()
}
pub fn get_validator_id(&self) -> &[u8] {
&self.validator_id
}
pub fn clear_validator_id(&mut self) {
self.validator_id.clear();
}
pub fn set_validator_id(&mut self, v: ::std::vec::Vec<u8>) {
self.validator_id = v;
}
pub fn mut_validator_id(&mut self) -> &mut ::std::vec::Vec<u8> {
&mut self.validator_id
}
pub fn take_validator_id(&mut self) -> ::std::vec::Vec<u8> {
::std::mem::replace(&mut self.validator_id, ::std::vec::Vec::new())
}
pub fn get_value(&self) -> u64 {
self.value
}
pub fn clear_value(&mut self) {
self.value = 0;
}
pub fn set_value(&mut self, v: u64) {
self.value = v;
}
}
impl ::protobuf::Message for RewardItem {
fn is_initialized(&self) -> bool {
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
::protobuf::rt::read_singular_proto3_bytes_into(wire_type, is, &mut self.validator_id)?;
},
2 => {
if wire_type != ::protobuf::wire_format::WireTypeVarint {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
let tmp = is.read_uint64()?;
self.value = tmp;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if !self.validator_id.is_empty() {
my_size += ::protobuf::rt::bytes_size(1, &self.validator_id);
}
if self.value != 0 {
my_size += ::protobuf::rt::value_size(2, self.value, ::protobuf::wire_format::WireTypeVarint);
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if !self.validator_id.is_empty() {
os.write_bytes(1, &self.validator_id)?;
}
if self.value != 0 {
os.write_uint64(2, self.value)?;
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> RewardItem {
RewardItem::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
"validator_id",
|m: &RewardItem| { &m.validator_id },
|m: &mut RewardItem| { &mut m.validator_id },
));
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeUint64>(
"value",
|m: &RewardItem| { &m.value },
|m: &mut RewardItem| { &mut m.value },
));
::protobuf::reflect::MessageDescriptor::new::<RewardItem>(
"RewardItem",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static RewardItem {
static mut instance: ::protobuf::lazy::Lazy<RewardItem> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const RewardItem,
};
unsafe {
instance.get(RewardItem::new)
}
}
}
impl ::protobuf::Clear for RewardItem {
fn clear(&mut self) {
self.validator_id.clear();
self.value = 0;
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for RewardItem {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for RewardItem {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct StepResponse {
pub step_result: ::protobuf::SingularPtrField<StepResponse_StepResult>,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a StepResponse {
fn default() -> &'a StepResponse {
<StepResponse as ::protobuf::Message>::default_instance()
}
}
impl StepResponse {
pub fn new() -> StepResponse {
::std::default::Default::default()
}
pub fn get_step_result(&self) -> &StepResponse_StepResult {
self.step_result.as_ref().unwrap_or_else(|| StepResponse_StepResult::default_instance())
}
pub fn clear_step_result(&mut self) {
self.step_result.clear();
}
pub fn has_step_result(&self) -> bool {
self.step_result.is_some()
}
pub fn set_step_result(&mut self, v: StepResponse_StepResult) {
self.step_result = ::protobuf::SingularPtrField::some(v);
}
pub fn mut_step_result(&mut self) -> &mut StepResponse_StepResult {
if self.step_result.is_none() {
self.step_result.set_default();
}
self.step_result.as_mut().unwrap()
}
pub fn take_step_result(&mut self) -> StepResponse_StepResult {
self.step_result.take().unwrap_or_else(|| StepResponse_StepResult::new())
}
}
impl ::protobuf::Message for StepResponse {
fn is_initialized(&self) -> bool {
for v in &self.step_result {
if !v.is_initialized() {
return false;
}
};
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.step_result)?;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if let Some(ref v) = self.step_result.as_ref() {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if let Some(ref v) = self.step_result.as_ref() {
os.write_tag(1, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> StepResponse {
StepResponse::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<StepResponse_StepResult>>(
"step_result",
|m: &StepResponse| { &m.step_result },
|m: &mut StepResponse| { &mut m.step_result },
));
::protobuf::reflect::MessageDescriptor::new::<StepResponse>(
"StepResponse",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static StepResponse {
static mut instance: ::protobuf::lazy::Lazy<StepResponse> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const StepResponse,
};
unsafe {
instance.get(StepResponse::new)
}
}
}
impl ::protobuf::Clear for StepResponse {
fn clear(&mut self) {
self.step_result.clear();
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for StepResponse {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for StepResponse {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct StepResponse_StepError {
pub message: ::std::string::String,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a StepResponse_StepError {
fn default() -> &'a StepResponse_StepError {
<StepResponse_StepError as ::protobuf::Message>::default_instance()
}
}
impl StepResponse_StepError {
pub fn new() -> StepResponse_StepError {
::std::default::Default::default()
}
pub fn get_message(&self) -> &str {
&self.message
}
pub fn clear_message(&mut self) {
self.message.clear();
}
pub fn set_message(&mut self, v: ::std::string::String) {
self.message = v;
}
pub fn mut_message(&mut self) -> &mut ::std::string::String {
&mut self.message
}
pub fn take_message(&mut self) -> ::std::string::String {
::std::mem::replace(&mut self.message, ::std::string::String::new())
}
}
impl ::protobuf::Message for StepResponse_StepError {
fn is_initialized(&self) -> bool {
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
::protobuf::rt::read_singular_proto3_string_into(wire_type, is, &mut self.message)?;
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if !self.message.is_empty() {
my_size += ::protobuf::rt::string_size(1, &self.message);
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if !self.message.is_empty() {
os.write_string(1, &self.message)?;
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> StepResponse_StepError {
StepResponse_StepError::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_simple_field_accessor::<_, ::protobuf::types::ProtobufTypeString>(
"message",
|m: &StepResponse_StepError| { &m.message },
|m: &mut StepResponse_StepError| { &mut m.message },
));
::protobuf::reflect::MessageDescriptor::new::<StepResponse_StepError>(
"StepResponse_StepError",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static StepResponse_StepError {
static mut instance: ::protobuf::lazy::Lazy<StepResponse_StepError> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const StepResponse_StepError,
};
unsafe {
instance.get(StepResponse_StepError::new)
}
}
}
impl ::protobuf::Clear for StepResponse_StepError {
fn clear(&mut self) {
self.message.clear();
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for StepResponse_StepError {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for StepResponse_StepError {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
#[derive(PartialEq,Clone,Default)]
pub struct StepResponse_StepResult {
pub step_result: ::std::option::Option<StepResponse_StepResult_oneof_step_result>,
pub unknown_fields: ::protobuf::UnknownFields,
pub cached_size: ::protobuf::CachedSize,
}
impl<'a> ::std::default::Default for &'a StepResponse_StepResult {
fn default() -> &'a StepResponse_StepResult {
<StepResponse_StepResult as ::protobuf::Message>::default_instance()
}
}
#[derive(Clone,PartialEq,Debug)]
pub enum StepResponse_StepResult_oneof_step_result {
success(CommitResult),
missing_parent(RootNotFound),
error(StepResponse_StepError),
}
impl StepResponse_StepResult {
pub fn new() -> StepResponse_StepResult {
::std::default::Default::default()
}
pub fn get_success(&self) -> &CommitResult {
match self.step_result {
::std::option::Option::Some(StepResponse_StepResult_oneof_step_result::success(ref v)) => v,
_ => CommitResult::default_instance(),
}
}
pub fn clear_success(&mut self) {
self.step_result = ::std::option::Option::None;
}
pub fn has_success(&self) -> bool {
match self.step_result {
::std::option::Option::Some(StepResponse_StepResult_oneof_step_result::success(..)) => true,
_ => false,
}
}
pub fn set_success(&mut self, v: CommitResult) {
self.step_result = ::std::option::Option::Some(StepResponse_StepResult_oneof_step_result::success(v))
}
pub fn mut_success(&mut self) -> &mut CommitResult {
if let ::std::option::Option::Some(StepResponse_StepResult_oneof_step_result::success(_)) = self.step_result {
} else {
self.step_result = ::std::option::Option::Some(StepResponse_StepResult_oneof_step_result::success(CommitResult::new()));
}
match self.step_result {
::std::option::Option::Some(StepResponse_StepResult_oneof_step_result::success(ref mut v)) => v,
_ => panic!(),
}
}
pub fn take_success(&mut self) -> CommitResult {
if self.has_success() {
match self.step_result.take() {
::std::option::Option::Some(StepResponse_StepResult_oneof_step_result::success(v)) => v,
_ => panic!(),
}
} else {
CommitResult::new()
}
}
pub fn get_missing_parent(&self) -> &RootNotFound {
match self.step_result {
::std::option::Option::Some(StepResponse_StepResult_oneof_step_result::missing_parent(ref v)) => v,
_ => RootNotFound::default_instance(),
}
}
pub fn clear_missing_parent(&mut self) {
self.step_result = ::std::option::Option::None;
}
pub fn has_missing_parent(&self) -> bool {
match self.step_result {
::std::option::Option::Some(StepResponse_StepResult_oneof_step_result::missing_parent(..)) => true,
_ => false,
}
}
pub fn set_missing_parent(&mut self, v: RootNotFound) {
self.step_result = ::std::option::Option::Some(StepResponse_StepResult_oneof_step_result::missing_parent(v))
}
pub fn mut_missing_parent(&mut self) -> &mut RootNotFound {
if let ::std::option::Option::Some(StepResponse_StepResult_oneof_step_result::missing_parent(_)) = self.step_result {
} else {
self.step_result = ::std::option::Option::Some(StepResponse_StepResult_oneof_step_result::missing_parent(RootNotFound::new()));
}
match self.step_result {
::std::option::Option::Some(StepResponse_StepResult_oneof_step_result::missing_parent(ref mut v)) => v,
_ => panic!(),
}
}
pub fn take_missing_parent(&mut self) -> RootNotFound {
if self.has_missing_parent() {
match self.step_result.take() {
::std::option::Option::Some(StepResponse_StepResult_oneof_step_result::missing_parent(v)) => v,
_ => panic!(),
}
} else {
RootNotFound::new()
}
}
pub fn get_error(&self) -> &StepResponse_StepError {
match self.step_result {
::std::option::Option::Some(StepResponse_StepResult_oneof_step_result::error(ref v)) => v,
_ => StepResponse_StepError::default_instance(),
}
}
pub fn clear_error(&mut self) {
self.step_result = ::std::option::Option::None;
}
pub fn has_error(&self) -> bool {
match self.step_result {
::std::option::Option::Some(StepResponse_StepResult_oneof_step_result::error(..)) => true,
_ => false,
}
}
pub fn set_error(&mut self, v: StepResponse_StepError) {
self.step_result = ::std::option::Option::Some(StepResponse_StepResult_oneof_step_result::error(v))
}
pub fn mut_error(&mut self) -> &mut StepResponse_StepError {
if let ::std::option::Option::Some(StepResponse_StepResult_oneof_step_result::error(_)) = self.step_result {
} else {
self.step_result = ::std::option::Option::Some(StepResponse_StepResult_oneof_step_result::error(StepResponse_StepError::new()));
}
match self.step_result {
::std::option::Option::Some(StepResponse_StepResult_oneof_step_result::error(ref mut v)) => v,
_ => panic!(),
}
}
pub fn take_error(&mut self) -> StepResponse_StepError {
if self.has_error() {
match self.step_result.take() {
::std::option::Option::Some(StepResponse_StepResult_oneof_step_result::error(v)) => v,
_ => panic!(),
}
} else {
StepResponse_StepError::new()
}
}
}
impl ::protobuf::Message for StepResponse_StepResult {
fn is_initialized(&self) -> bool {
if let Some(StepResponse_StepResult_oneof_step_result::success(ref v)) = self.step_result {
if !v.is_initialized() {
return false;
}
}
if let Some(StepResponse_StepResult_oneof_step_result::missing_parent(ref v)) = self.step_result {
if !v.is_initialized() {
return false;
}
}
if let Some(StepResponse_StepResult_oneof_step_result::error(ref v)) = self.step_result {
if !v.is_initialized() {
return false;
}
}
true
}
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
while !is.eof()? {
let (field_number, wire_type) = is.read_tag_unpack()?;
match field_number {
1 => {
if wire_type != ::protobuf::wire_format::WireTypeLengthDelimited {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
self.step_result = ::std::option::Option::Some(StepResponse_StepResult_oneof_step_result::success(is.read_message()?));
},
2 => {
if wire_type != ::protobuf::wire_format::WireTypeLengthDelimited {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
self.step_result = ::std::option::Option::Some(StepResponse_StepResult_oneof_step_result::missing_parent(is.read_message()?));
},
3 => {
if wire_type != ::protobuf::wire_format::WireTypeLengthDelimited {
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
}
self.step_result = ::std::option::Option::Some(StepResponse_StepResult_oneof_step_result::error(is.read_message()?));
},
_ => {
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
},
};
}
::std::result::Result::Ok(())
}
#[allow(unused_variables)]
fn compute_size(&self) -> u32 {
let mut my_size = 0;
if let ::std::option::Option::Some(ref v) = self.step_result {
match v {
&StepResponse_StepResult_oneof_step_result::success(ref v) => {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
},
&StepResponse_StepResult_oneof_step_result::missing_parent(ref v) => {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
},
&StepResponse_StepResult_oneof_step_result::error(ref v) => {
let len = v.compute_size();
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
},
};
}
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
self.cached_size.set(my_size);
my_size
}
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
if let ::std::option::Option::Some(ref v) = self.step_result {
match v {
&StepResponse_StepResult_oneof_step_result::success(ref v) => {
os.write_tag(1, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
},
&StepResponse_StepResult_oneof_step_result::missing_parent(ref v) => {
os.write_tag(2, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
},
&StepResponse_StepResult_oneof_step_result::error(ref v) => {
os.write_tag(3, ::protobuf::wire_format::WireTypeLengthDelimited)?;
os.write_raw_varint32(v.get_cached_size())?;
v.write_to_with_cached_sizes(os)?;
},
};
}
os.write_unknown_fields(self.get_unknown_fields())?;
::std::result::Result::Ok(())
}
fn get_cached_size(&self) -> u32 {
self.cached_size.get()
}
fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
&self.unknown_fields
}
fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
&mut self.unknown_fields
}
fn as_any(&self) -> &dyn (::std::any::Any) {
self as &dyn (::std::any::Any)
}
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
self as &mut dyn (::std::any::Any)
}
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
self
}
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
Self::descriptor_static()
}
fn new() -> StepResponse_StepResult {
StepResponse_StepResult::new()
}
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
};
unsafe {
descriptor.get(|| {
let mut fields = ::std::vec::Vec::new();
fields.push(::protobuf::reflect::accessor::make_singular_message_accessor::<_, CommitResult>(
"success",
StepResponse_StepResult::has_success,
StepResponse_StepResult::get_success,
));
fields.push(::protobuf::reflect::accessor::make_singular_message_accessor::<_, RootNotFound>(
"missing_parent",
StepResponse_StepResult::has_missing_parent,
StepResponse_StepResult::get_missing_parent,
));
fields.push(::protobuf::reflect::accessor::make_singular_message_accessor::<_, StepResponse_StepError>(
"error",
StepResponse_StepResult::has_error,
StepResponse_StepResult::get_error,
));
::protobuf::reflect::MessageDescriptor::new::<StepResponse_StepResult>(
"StepResponse_StepResult",
fields,
file_descriptor_proto()
)
})
}
}
fn default_instance() -> &'static StepResponse_StepResult {
static mut instance: ::protobuf::lazy::Lazy<StepResponse_StepResult> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const StepResponse_StepResult,
};
unsafe {
instance.get(StepResponse_StepResult::new)
}
}
}
impl ::protobuf::Clear for StepResponse_StepResult {
fn clear(&mut self) {
self.step_result = ::std::option::Option::None;
self.step_result = ::std::option::Option::None;
self.step_result = ::std::option::Option::None;
self.unknown_fields.clear();
}
}
impl ::std::fmt::Debug for StepResponse_StepResult {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
::protobuf::text_format::fmt(self, f)
}
}
impl ::protobuf::reflect::ProtobufValue for StepResponse_StepResult {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Message(self)
}
}
static file_descriptor_proto_data: &'static [u8] = b"\
\n\x10casper/ipc.proto\x12\ncasper.ipc\x1a\x12casper/state.proto\x1a\x17\
casper/transforms.proto\"4\n\nDeployCode\x12\x12\n\x04code\x18\x01\x20\
\x01(\x0cR\x04code\x12\x12\n\x04args\x18\x02\x20\x01(\x0cR\x04args\"f\n\
\x12StoredContractHash\x12\x12\n\x04hash\x18\x01\x20\x01(\x0cR\x04hash\
\x12\x12\n\x04args\x18\x02\x20\x01(\x0cR\x04args\x12(\n\x10entry_point_n\
ame\x18\x03\x20\x01(\tR\x0eentryPointName\"f\n\x12StoredContractName\x12\
\x12\n\x04name\x18\x01\x20\x01(\tR\x04name\x12\x12\n\x04args\x18\x02\x20\
\x01(\x0cR\x04args\x12(\n\x10entry_point_name\x18\x03\x20\x01(\tR\x0eent\
ryPointName\"\x99\x01\n\x15StoredContractPackage\x12\x12\n\x04name\x18\
\x01\x20\x01(\tR\x04name\x12\x1a\n\x07version\x18\x02\x20\x01(\rH\0R\x07\
version\x12(\n\x10entry_point_name\x18\x03\x20\x01(\tR\x0eentryPointName\
\x12\x12\n\x04args\x18\x04\x20\x01(\x0cR\x04argsB\x12\n\x10optional_vers\
ion\"\x9d\x01\n\x19StoredContractPackageHash\x12\x12\n\x04hash\x18\x01\
\x20\x01(\x0cR\x04hash\x12\x1a\n\x07version\x18\x02\x20\x01(\rH\0R\x07ve\
rsion\x12(\n\x10entry_point_name\x18\x03\x20\x01(\tR\x0eentryPointName\
\x12\x12\n\x04args\x18\x04\x20\x01(\x0cR\x04argsB\x12\n\x10optional_vers\
ion\"\x1e\n\x08Transfer\x12\x12\n\x04args\x18\x01\x20\x01(\x0cR\x04args\
\"\xef\x03\n\rDeployPayload\x129\n\x0bdeploy_code\x18\x01\x20\x01(\x0b2\
\x16.casper.ipc.DeployCodeH\0R\ndeployCode\x12R\n\x14stored_contract_has\
h\x18\x02\x20\x01(\x0b2\x1e.casper.ipc.StoredContractHashH\0R\x12storedC\
ontractHash\x12R\n\x14stored_contract_name\x18\x03\x20\x01(\x0b2\x1e.cas\
per.ipc.StoredContractNameH\0R\x12storedContractName\x12X\n\x16stored_pa\
ckage_by_name\x18\x05\x20\x01(\x0b2!.casper.ipc.StoredContractPackageH\0\
R\x13storedPackageByName\x12\\\n\x16stored_package_by_hash\x18\x06\x20\
\x01(\x0b2%.casper.ipc.StoredContractPackageHashH\0R\x13storedPackageByH\
ash\x122\n\x08transfer\x18\x07\x20\x01(\x0b2\x14.casper.ipc.TransferH\0R\
\x08transferB\t\n\x07payloadJ\x04\x08\x04\x10\x05\"\x89\x02\n\nDeployIte\
m\x12\x18\n\x07address\x18\x01\x20\x01(\x0cR\x07address\x123\n\x07sessio\
n\x18\x03\x20\x01(\x0b2\x19.casper.ipc.DeployPayloadR\x07session\x123\n\
\x07payment\x18\x04\x20\x01(\x0b2\x19.casper.ipc.DeployPayloadR\x07payme\
nt\x12\x1b\n\tgas_price\x18\x06\x20\x01(\x04R\x08gasPrice\x12-\n\x12auth\
orization_keys\x18\x08\x20\x03(\x0cR\x11authorizationKeys\x12\x1f\n\x0bd\
eploy_hash\x18\t\x20\x01(\x0cR\ndeployHashJ\x04\x08\x05\x10\x06J\x04\x08\
\x07\x10\x08\"\xd7\x01\n\x0eExecuteRequest\x12*\n\x11parent_state_hash\
\x18\x01\x20\x01(\x0cR\x0fparentStateHash\x12\x1d\n\nblock_time\x18\x02\
\x20\x01(\x04R\tblockTime\x120\n\x07deploys\x18\x03\x20\x03(\x0b2\x16.ca\
sper.ipc.DeployItemR\x07deploys\x12H\n\x10protocol_version\x18\x04\x20\
\x01(\x0b2\x1d.casper.state.ProtocolVersionR\x0fprotocolVersion\"\x92\
\x01\n\x0fExecuteResponse\x122\n\x07success\x18\x01\x20\x01(\x0b2\x16.ca\
sper.ipc.ExecResultH\0R\x07success\x12A\n\x0emissing_parent\x18\x02\x20\
\x01(\x0b2\x18.casper.ipc.RootNotFoundH\0R\rmissingParentB\x08\n\x06resu\
lt\"M\n\nExecResult\x12?\n\x0edeploy_results\x18\x02\x20\x03(\x0b2\x18.c\
asper.ipc.DeployResultR\rdeployResults\"\"\n\x0cRootNotFound\x12\x12\n\
\x04hash\x18\x01\x20\x01(\x0cR\x04hash\"q\n\rCommitRequest\x12#\n\rprest\
ate_hash\x18\x01\x20\x01(\x0cR\x0cprestateHash\x12;\n\x07effects\x18\x02\
\x20\x03(\x0b2!.casper.transforms.TransformEntryR\x07effects\"5\n\x0cCom\
mitResult\x12%\n\x0epoststate_hash\x18\x01\x20\x01(\x0cR\rpoststateHash\
\"\xe3\x02\n\x0eCommitResponse\x124\n\x07success\x18\x01\x20\x01(\x0b2\
\x18.casper.ipc.CommitResultH\0R\x07success\x12E\n\x10missing_prestate\
\x18\x02\x20\x01(\x0b2\x18.casper.ipc.RootNotFoundH\0R\x0fmissingPrestat\
e\x127\n\rkey_not_found\x18\x03\x20\x01(\x0b2\x11.casper.state.KeyH\0R\
\x0bkeyNotFound\x12F\n\rtype_mismatch\x18\x04\x20\x01(\x0b2\x1f.casper.t\
ransforms.TypeMismatchH\0R\x0ctypeMismatch\x12I\n\x10failed_transform\
\x18\x05\x20\x01(\x0b2\x1c.casper.ipc.PostEffectsErrorH\0R\x0ffailedTran\
sformB\x08\n\x06result\"\xb9\x01\n\x02Op\x12(\n\x04read\x18\x01\x20\x01(\
\x0b2\x12.casper.ipc.ReadOpH\0R\x04read\x12+\n\x05write\x18\x02\x20\x01(\
\x0b2\x13.casper.ipc.WriteOpH\0R\x05write\x12%\n\x03add\x18\x03\x20\x01(\
\x0b2\x11.casper.ipc.AddOpH\0R\x03add\x12&\n\x04noop\x18\x04\x20\x01(\
\x0b2\x10.casper.ipc.NoOpH\0R\x04noopB\r\n\x0bop_instance\"\x08\n\x06Rea\
dOp\"\t\n\x07WriteOp\"\x07\n\x05AddOp\"\x06\n\x04NoOp\"\x87\x01\n\x0cSto\
rageError\x12;\n\nbytes_repr\x18\x01\x20\x01(\x0b2\x1a.casper.ipc.BytesR\
eprErrorH\0R\tbytesRepr\x12(\n\x03rkv\x18\x02\x20\x01(\x0b2\x14.casper.i\
pc.RkvErrorH\0R\x03rkvB\x10\n\x0eerror_instance\"\xd8\x01\n\x0eBytesRepr\
Error\x12;\n\tearly_end\x18\x01\x20\x01(\x0b2\x1c.casper.ipc.EarlyEndOfS\
treamH\0R\x08earlyEnd\x12=\n\nformatting\x18\x02\x20\x01(\x0b2\x1b.caspe\
r.ipc.FormattingErrorH\0R\nformatting\x128\n\tleft_over\x18\x03\x20\x01(\
\x0b2\x19.casper.ipc.LeftOverBytesH\0R\x08leftOverB\x10\n\x0eerror_insta\
nce\"\x12\n\x10EarlyEndOfStream\"\x11\n\x0fFormattingError\"\x0f\n\rLeft\
OverBytes\"'\n\x08RkvError\x12\x1b\n\terror_msg\x18\x01\x20\x01(\tR\x08e\
rrorMsg\"\\\n\x07OpEntry\x12#\n\x03key\x18\x01\x20\x01(\x0b2\x11.casper.\
state.KeyR\x03key\x12,\n\toperation\x18\x02\x20\x01(\x0b2\x0e.casper.ipc\
.OpR\toperation\"\x85\x01\n\x0fExecutionEffect\x12*\n\x06op_map\x18\x01\
\x20\x03(\x0b2\x13.casper.ipc.OpEntryR\x05opMap\x12F\n\rtransform_map\
\x18\x02\x20\x03(\x0b2!.casper.transforms.TransformEntryR\x0ctransformMa\
p\"\xe2\x01\n\x0bDeployError\x12D\n\tgas_error\x18\x01\x20\x01(\x0b2%.ca\
sper.ipc.DeployError.OutOfGasErrorH\0R\x08gasError\x12G\n\nexec_error\
\x18\x02\x20\x01(\x0b2&.casper.ipc.DeployError.ExecutionErrorH\0R\texecE\
rror\x1a\x0f\n\rOutOfGasError\x1a*\n\x0eExecutionError\x12\x18\n\x07mess\
age\x18\x01\x20\x01(\tR\x07messageB\x07\n\x05value\"\xa6\x03\n\x0cDeploy\
Result\x12a\n\x14precondition_failure\x18\x02\x20\x01(\x0b2,.casper.ipc.\
DeployResult.PreconditionFailureH\0R\x13preconditionFailure\x12U\n\x10ex\
ecution_result\x18\x03\x20\x01(\x0b2(.casper.ipc.DeployResult.ExecutionR\
esultH\0R\x0fexecutionResult\x1a/\n\x13PreconditionFailure\x12\x18\n\x07\
message\x18\x01\x20\x01(\tR\x07message\x1a\xa1\x01\n\x0fExecutionResult\
\x125\n\x07effects\x18\x01\x20\x01(\x0b2\x1b.casper.ipc.ExecutionEffectR\
\x07effects\x12-\n\x05error\x18\x02\x20\x01(\x0b2\x17.casper.ipc.DeployE\
rrorR\x05error\x12(\n\x04cost\x18\x03\x20\x01(\x0b2\x14.casper.state.Big\
IntR\x04costB\x07\n\x05value\",\n\x10PostEffectsError\x12\x18\n\x07messa\
ge\x18\x01\x20\x01(\tR\x07message\"\xb9\x01\n\x0cQueryRequest\x12\x1d\n\
\nstate_hash\x18\x01\x20\x01(\x0cR\tstateHash\x12,\n\x08base_key\x18\x02\
\x20\x01(\x0b2\x11.casper.state.KeyR\x07baseKey\x12\x12\n\x04path\x18\
\x03\x20\x03(\tR\x04path\x12H\n\x10protocol_version\x18\x04\x20\x01(\x0b\
2\x1d.casper.state.ProtocolVersionR\x0fprotocolVersion\"W\n\rQueryRespon\
se\x12\x1a\n\x07success\x18\x03\x20\x01(\x0cH\0R\x07success\x12\x1a\n\
\x07failure\x18\x02\x20\x01(\tH\0R\x07failureB\x08\n\x06resultJ\x04\x08\
\x01\x10\x02\"k\n\rGenesisResult\x12%\n\x0epoststate_hash\x18\x01\x20\
\x01(\x0cR\rpoststateHash\x123\n\x06effect\x18\x02\x20\x01(\x0b2\x1b.cas\
per.ipc.ExecutionEffectR\x06effect\".\n\x12GenesisDeployError\x12\x18\n\
\x07message\x18\x01\x20\x01(\tR\x07message\"\xda\x01\n\x11RunGenesisRequ\
est\x12.\n\x13genesis_config_hash\x18\x01\x20\x01(\x0cR\x11genesisConfig\
Hash\x12H\n\x10protocol_version\x18\x02\x20\x01(\x0b2\x1d.casper.state.P\
rotocolVersionR\x0fprotocolVersion\x12K\n\tee_config\x18\x03\x20\x01(\
\x0b2..casper.ipc.ChainSpec.GenesisConfig.ExecConfigR\x08eeConfig\"\x99\
\x01\n\x0fGenesisResponse\x125\n\x07success\x18\x01\x20\x01(\x0b2\x19.ca\
sper.ipc.GenesisResultH\0R\x07success\x12E\n\rfailed_deploy\x18\x02\x20\
\x01(\x0b2\x1e.casper.ipc.GenesisDeployErrorH\0R\x0cfailedDeployB\x08\n\
\x06result\"\xcf@\n\tChainSpec\x12=\n\x07genesis\x18\x01\x20\x01(\x0b2#.\
casper.ipc.ChainSpec.GenesisConfigR\x07genesis\x12>\n\x08upgrades\x18\
\x02\x20\x03(\x0b2\".casper.ipc.ChainSpec.UpgradePointR\x08upgrades\x1a\
\xc3\x08\n\rGenesisConfig\x12\x12\n\x04name\x18\x01\x20\x01(\tR\x04name\
\x12\x1c\n\ttimestamp\x18\x02\x20\x01(\x04R\ttimestamp\x12H\n\x10protoco\
l_version\x18\x03\x20\x01(\x0b2\x1d.casper.state.ProtocolVersionR\x0fpro\
tocolVersion\x12G\n\rdeploy_config\x18\x08\x20\x01(\x0b2\".casper.ipc.Ch\
ainSpec.DeployConfigR\x0cdeployConfig\x12J\n\x0ehighway_config\x18\t\x20\
\x01(\x0b2#.casper.ipc.ChainSpec.HighwayConfigR\rhighwayConfig\x12K\n\te\
e_config\x18\x0b\x20\x01(\x0b2..casper.ipc.ChainSpec.GenesisConfig.ExecC\
onfigR\x08eeConfig\x1a\xb5\x05\n\nExecConfig\x12%\n\x0emint_installer\
\x18\x01\x20\x01(\x0cR\rmintInstaller\x12#\n\rpos_installer\x18\x02\x20\
\x01(\x0cR\x0cposInstaller\x12<\n\x1astandard_payment_installer\x18\x03\
\x20\x01(\x0cR\x18standardPaymentInstaller\x12+\n\x11auction_installer\
\x18\x06\x20\x01(\x0cR\x10auctionInstaller\x12Y\n\x08accounts\x18\x04\
\x20\x03(\x0b2=.casper.ipc.ChainSpec.GenesisConfig.ExecConfig.GenesisAcc\
ountR\x08accounts\x12A\n\x0bwasm_config\x18\x05\x20\x01(\x0b2\x20.casper\
.ipc.ChainSpec.WasmConfigR\nwasmConfig\x12'\n\x0fvalidator_slots\x18\x07\
\x20\x01(\rR\x0evalidatorSlots\x12#\n\rauction_delay\x18\x08\x20\x01(\
\x04R\x0cauctionDelay\x12.\n\x13locked_funds_period\x18\n\x20\x01(\x04R\
\x11lockedFundsPeriod\x1a\xd3\x01\n\x0eGenesisAccount\x12(\n\x10public_k\
ey_bytes\x18\x01\x20\x01(\x0cR\x0epublicKeyBytes\x12,\n\x12account_hash_\
bytes\x18\x04\x20\x01(\x0cR\x10accountHashBytes\x12.\n\x07balance\x18\
\x02\x20\x01(\x0b2\x14.casper.state.BigIntR\x07balance\x129\n\rbonded_am\
ount\x18\x03\x20\x01(\x0b2\x14.casper.state.BigIntR\x0cbondedAmountJ\x04\
\x08\x04\x10\x05J\x04\x08\x05\x10\x06J\x04\x08\n\x10\x0bJ\x04\x08\x06\
\x10\x07J\x04\x08\x07\x10\x08\x1a\xb6\x01\n\x0cDeployConfig\x12$\n\x0ema\
x_ttl_millis\x18\x02\x20\x01(\rR\x0cmaxTtlMillis\x12)\n\x10max_dependenc\
ies\x18\x03\x20\x01(\rR\x0fmaxDependencies\x12/\n\x14max_block_size_byte\
s\x18\x04\x20\x01(\rR\x11maxBlockSizeBytes\x12$\n\x0emax_block_cost\x18\
\x05\x20\x01(\x04R\x0cmaxBlockCost\x1a\x80\x03\n\rHighwayConfig\x12=\n\
\x1bgenesis_era_start_timestamp\x18\x01\x20\x01(\x04R\x18genesisEraStart\
Timestamp\x12.\n\x13era_duration_millis\x18\x02\x20\x01(\x04R\x11eraDura\
tionMillis\x126\n\x17booking_duration_millis\x18\x03\x20\x01(\x04R\x15bo\
okingDurationMillis\x126\n\x17entropy_duration_millis\x18\x04\x20\x01(\
\x04R\x15entropyDurationMillis\x12A\n\x1dvoting_period_duration_millis\
\x18\x05\x20\x01(\x04R\x1avotingPeriodDurationMillis\x12;\n\x1avoting_pe\
riod_summit_level\x18\x06\x20\x01(\rR\x17votingPeriodSummitLevel\x12\x10\
\n\x03ftt\x18\x07\x20\x01(\x01R\x03ftt\x1a\xa7+\n\nWasmConfig\x12%\n\x0e\
initial_memory\x18\x01\x20\x01(\rR\rinitialMemory\x12(\n\x10max_stack_he\
ight\x18\x02\x20\x01(\rR\x0emaxStackHeight\x12O\n\x0copcode_costs\x18\
\x03\x20\x01(\x0b2,.casper.ipc.ChainSpec.WasmConfig.OpcodeCostsR\x0bopco\
deCosts\x12R\n\rstorage_costs\x18\x04\x20\x01(\x0b2-.casper.ipc.ChainSpe\
c.WasmConfig.StorageCostsR\x0cstorageCosts\x12b\n\x13host_function_costs\
\x18\x05\x20\x01(\x0b22.casper.ipc.ChainSpec.WasmConfig.HostFunctionCost\
sR\x11hostFunctionCosts\x1a\xcb\x03\n\x0bOpcodeCosts\x12\x10\n\x03bit\
\x18\x01\x20\x01(\rR\x03bit\x12\x10\n\x03add\x18\x02\x20\x01(\rR\x03add\
\x12\x10\n\x03mul\x18\x03\x20\x01(\rR\x03mul\x12\x10\n\x03div\x18\x04\
\x20\x01(\rR\x03div\x12\x12\n\x04load\x18\x05\x20\x01(\rR\x04load\x12\
\x14\n\x05store\x18\x06\x20\x01(\rR\x05store\x12\x14\n\x05const\x18\x07\
\x20\x01(\rR\x05const\x12\x14\n\x05local\x18\x08\x20\x01(\rR\x05local\
\x12\x16\n\x06global\x18\t\x20\x01(\rR\x06global\x12!\n\x0ccontrol_flow\
\x18\n\x20\x01(\rR\x0bcontrolFlow\x12-\n\x12integer_comparsion\x18\x0b\
\x20\x01(\rR\x11integerComparsion\x12\x1e\n\nconversion\x18\x0c\x20\x01(\
\rR\nconversion\x12\x20\n\x0bunreachable\x18\x0e\x20\x01(\rR\x0bunreacha\
ble\x12\x10\n\x03nop\x18\x0f\x20\x01(\rR\x03nop\x12%\n\x0ecurrent_memory\
\x18\x10\x20\x01(\rR\rcurrentMemory\x12\x1f\n\x0bgrow_memory\x18\x11\x20\
\x01(\rR\ngrowMemory\x12\x18\n\x07regular\x18\x12\x20\x01(\rR\x07regular\
\x1a0\n\x0cStorageCosts\x12\x20\n\x0cgas_per_byte\x18\x01\x20\x01(\rR\ng\
asPerByte\x1a\xbe$\n\x11HostFunctionCosts\x12^\n\nread_value\x18\x01\x20\
\x01(\x0b2?.casper.ipc.ChainSpec.WasmConfig.HostFunctionCosts.HostFuncti\
onR\treadValue\x12i\n\x10read_value_local\x18\x02\x20\x01(\x0b2?.casper.\
ipc.ChainSpec.WasmConfig.HostFunctionCosts.HostFunctionR\x0ereadValueLoc\
al\x12U\n\x05write\x18\x03\x20\x01(\x0b2?.casper.ipc.ChainSpec.WasmConfi\
g.HostFunctionCosts.HostFunctionR\x05write\x12`\n\x0bwrite_local\x18\x04\
\x20\x01(\x0b2?.casper.ipc.ChainSpec.WasmConfig.HostFunctionCosts.HostFu\
nctionR\nwriteLocal\x12Q\n\x03add\x18\x05\x20\x01(\x0b2?.casper.ipc.Chai\
nSpec.WasmConfig.HostFunctionCosts.HostFunctionR\x03add\x12Z\n\x08new_ur\
ef\x18\x06\x20\x01(\x0b2?.casper.ipc.ChainSpec.WasmConfig.HostFunctionCo\
sts.HostFunctionR\x07newUref\x12g\n\x0fload_named_keys\x18\x07\x20\x01(\
\x0b2?.casper.ipc.ChainSpec.WasmConfig.HostFunctionCosts.HostFunctionR\r\
loadNamedKeys\x12Q\n\x03ret\x18\x08\x20\x01(\x0b2?.casper.ipc.ChainSpec.\
WasmConfig.HostFunctionCosts.HostFunctionR\x03ret\x12X\n\x07get_key\x18\
\t\x20\x01(\x0b2?.casper.ipc.ChainSpec.WasmConfig.HostFunctionCosts.Host\
FunctionR\x06getKey\x12X\n\x07has_key\x18\n\x20\x01(\x0b2?.casper.ipc.Ch\
ainSpec.WasmConfig.HostFunctionCosts.HostFunctionR\x06hasKey\x12X\n\x07p\
ut_key\x18\x0b\x20\x01(\x0b2?.casper.ipc.ChainSpec.WasmConfig.HostFuncti\
onCosts.HostFunctionR\x06putKey\x12^\n\nremove_key\x18\x0c\x20\x01(\x0b2\
?.casper.ipc.ChainSpec.WasmConfig.HostFunctionCosts.HostFunctionR\tremov\
eKey\x12W\n\x06revert\x18\r\x20\x01(\x0b2?.casper.ipc.ChainSpec.WasmConf\
ig.HostFunctionCosts.HostFunctionR\x06revert\x12c\n\ris_valid_uref\x18\
\x0e\x20\x01(\x0b2?.casper.ipc.ChainSpec.WasmConfig.HostFunctionCosts.Ho\
stFunctionR\x0bisValidUref\x12m\n\x12add_associated_key\x18\x0f\x20\x01(\
\x0b2?.casper.ipc.ChainSpec.WasmConfig.HostFunctionCosts.HostFunctionR\
\x10addAssociatedKey\x12s\n\x15remove_associated_key\x18\x10\x20\x01(\
\x0b2?.casper.ipc.ChainSpec.WasmConfig.HostFunctionCosts.HostFunctionR\
\x13removeAssociatedKey\x12s\n\x15update_associated_key\x18\x11\x20\x01(\
\x0b2?.casper.ipc.ChainSpec.WasmConfig.HostFunctionCosts.HostFunctionR\
\x13updateAssociatedKey\x12q\n\x14set_action_threshold\x18\x12\x20\x01(\
\x0b2?.casper.ipc.ChainSpec.WasmConfig.HostFunctionCosts.HostFunctionR\
\x12setActionThreshold\x12^\n\nget_caller\x18\x13\x20\x01(\x0b2?.casper.\
ipc.ChainSpec.WasmConfig.HostFunctionCosts.HostFunctionR\tgetCaller\x12d\
\n\rget_blocktime\x18\x14\x20\x01(\x0b2?.casper.ipc.ChainSpec.WasmConfig\
.HostFunctionCosts.HostFunctionR\x0cgetBlocktime\x12b\n\x0ccreate_purse\
\x18\x15\x20\x01(\x0b2?.casper.ipc.ChainSpec.WasmConfig.HostFunctionCost\
s.HostFunctionR\x0bcreatePurse\x12o\n\x13transfer_to_account\x18\x16\x20\
\x01(\x0b2?.casper.ipc.ChainSpec.WasmConfig.HostFunctionCosts.HostFuncti\
onR\x11transferToAccount\x12\x83\x01\n\x1etransfer_from_purse_to_account\
\x18\x17\x20\x01(\x0b2?.casper.ipc.ChainSpec.WasmConfig.HostFunctionCost\
s.HostFunctionR\x1atransferFromPurseToAccount\x12\x7f\n\x1ctransfer_from\
_purse_to_purse\x18\x18\x20\x01(\x0b2?.casper.ipc.ChainSpec.WasmConfig.H\
ostFunctionCosts.HostFunctionR\x18transferFromPurseToPurse\x12`\n\x0bget\
_balance\x18\x19\x20\x01(\x0b2?.casper.ipc.ChainSpec.WasmConfig.HostFunc\
tionCosts.HostFunctionR\ngetBalance\x12\\\n\tget_phase\x18\x1a\x20\x01(\
\x0b2?.casper.ipc.ChainSpec.WasmConfig.HostFunctionCosts.HostFunctionR\
\x08getPhase\x12o\n\x13get_system_contract\x18\x1b\x20\x01(\x0b2?.casper\
.ipc.ChainSpec.WasmConfig.HostFunctionCosts.HostFunctionR\x11getSystemCo\
ntract\x12e\n\x0eget_main_purse\x18\x1c\x20\x01(\x0b2?.casper.ipc.ChainS\
pec.WasmConfig.HostFunctionCosts.HostFunctionR\x0cgetMainPurse\x12i\n\
\x10read_host_buffer\x18\x1d\x20\x01(\x0b2?.casper.ipc.ChainSpec.WasmCon\
fig.HostFunctionCosts.HostFunctionR\x0ereadHostBuffer\x12\x85\x01\n\x1fc\
reate_contract_package_at_hash\x18\x1e\x20\x01(\x0b2?.casper.ipc.ChainSp\
ec.WasmConfig.HostFunctionCosts.HostFunctionR\x1bcreateContractPackageAt\
Hash\x12|\n\x1acreate_contract_user_group\x18\x1f\x20\x01(\x0b2?.casper.\
ipc.ChainSpec.WasmConfig.HostFunctionCosts.HostFunctionR\x17createContra\
ctUserGroup\x12q\n\x14add_contract_version\x18\x20\x20\x01(\x0b2?.casper\
.ipc.ChainSpec.WasmConfig.HostFunctionCosts.HostFunctionR\x12addContract\
Version\x12y\n\x18disable_contract_version\x18!\x20\x01(\x0b2?.casper.ip\
c.ChainSpec.WasmConfig.HostFunctionCosts.HostFunctionR\x16disableContrac\
tVersion\x12d\n\rcall_contract\x18\"\x20\x01(\x0b2?.casper.ipc.ChainSpec\
.WasmConfig.HostFunctionCosts.HostFunctionR\x0ccallContract\x12w\n\x17ca\
ll_versioned_contract\x18#\x20\x01(\x0b2?.casper.ipc.ChainSpec.WasmConfi\
g.HostFunctionCosts.HostFunctionR\x15callVersionedContract\x12l\n\x12get\
_named_arg_size\x18$\x20\x01(\x0b2?.casper.ipc.ChainSpec.WasmConfig.Host\
FunctionCosts.HostFunctionR\x0fgetNamedArgSize\x12c\n\rget_named_arg\x18\
%\x20\x01(\x0b2?.casper.ipc.ChainSpec.WasmConfig.HostFunctionCosts.HostF\
unctionR\x0bgetNamedArg\x12|\n\x1aremove_contract_user_group\x18&\x20\
\x01(\x0b2?.casper.ipc.ChainSpec.WasmConfig.HostFunctionCosts.HostFuncti\
onR\x17removeContractUserGroup\x12\x8b\x01\n\"provision_contract_user_gr\
oup_uref\x18'\x20\x01(\x0b2?.casper.ipc.ChainSpec.WasmConfig.HostFunctio\
nCosts.HostFunctionR\x1eprovisionContractUserGroupUref\x12\x87\x01\n\x20\
remove_contract_user_group_urefs\x18(\x20\x01(\x0b2?.casper.ipc.ChainSpe\
c.WasmConfig.HostFunctionCosts.HostFunctionR\x1cremoveContractUserGroupU\
refs\x12U\n\x05print\x18)\x20\x01(\x0b2?.casper.ipc.ChainSpec.WasmConfig\
.HostFunctionCosts.HostFunctionR\x05print\x12Y\n\x07blake2b\x18*\x20\x01\
(\x0b2?.casper.ipc.ChainSpec.WasmConfig.HostFunctionCosts.HostFunctionR\
\x07blake2b\x1a\xae\x01\n\x0cHostFunction\x12\x12\n\x04cost\x18\x01\x20\
\x01(\rR\x04cost\x12f\n\targuments\x18\x02\x20\x03(\x0b2H.casper.ipc.Cha\
inSpec.WasmConfig.HostFunctionCosts.HostFunction.ArgumentR\targuments\
\x1a\"\n\x08Argument\x12\x16\n\x06weight\x18\x01\x20\x01(\rR\x06weight\
\x1a\x98\x05\n\x0cUpgradePoint\x12P\n\x10activation_point\x18\x01\x20\
\x01(\x0b2%.casper.ipc.ChainSpec.ActivationPointR\x0factivationPoint\x12\
H\n\x10protocol_version\x18\x02\x20\x01(\x0b2\x1d.casper.state.ProtocolV\
ersionR\x0fprotocolVersion\x12C\n\x11upgrade_installer\x18\x03\x20\x01(\
\x0b2\x16.casper.ipc.DeployCodeR\x10upgradeInstaller\x12H\n\x0fnew_wasm_\
config\x18\x04\x20\x01(\x0b2\x20.casper.ipc.ChainSpec.WasmConfigR\rnewWa\
smConfig\x12N\n\x11new_deploy_config\x18\x05\x20\x01(\x0b2\".casper.ipc.\
ChainSpec.DeployConfigR\x0fnewDeployConfig\x12W\n\x13new_validator_slots\
\x18\x06\x20\x01(\x0b2'.casper.ipc.ChainSpec.NewValidatorSlotsR\x11newVa\
lidatorSlots\x12Q\n\x11new_auction_delay\x18\x07\x20\x01(\x0b2%.casper.i\
pc.ChainSpec.NewAuctionDelayR\x0fnewAuctionDelay\x12a\n\x17new_locked_fu\
nds_period\x18\t\x20\x01(\x0b2*.casper.ipc.ChainSpec.NewLockedFundsPerio\
dR\x14newLockedFundsPeriod\x1aC\n\x11NewValidatorSlots\x12.\n\x13new_val\
idator_slots\x18\x01\x20\x01(\rR\x11newValidatorSlots\x1a=\n\x0fNewAucti\
onDelay\x12*\n\x11new_auction_delay\x18\x01\x20\x01(\x04R\x0fnewAuctionD\
elay\x1aM\n\x14NewLockedFundsPeriod\x125\n\x17new_locked_funds_period\
\x18\x01\x20\x01(\x04R\x14newLockedFundsPeriod\x1a)\n\x0fActivationPoint\
\x12\x16\n\x06height\x18\x01\x20\x01(\x04R\x06height\"\xcf\x01\n\x0eUpgr\
adeRequest\x12*\n\x11parent_state_hash\x18\x01\x20\x01(\x0cR\x0fparentSt\
ateHash\x12G\n\rupgrade_point\x18\x02\x20\x01(\x0b2\".casper.ipc.ChainSp\
ec.UpgradePointR\x0cupgradePoint\x12H\n\x10protocol_version\x18\x03\x20\
\x01(\x0b2\x1d.casper.state.ProtocolVersionR\x0fprotocolVersion\"l\n\rUp\
gradeResult\x12&\n\x0fpost_state_hash\x18\x01\x20\x01(\x0cR\rpostStateHa\
sh\x123\n\x06effect\x18\x02\x20\x01(\x0b2\x1b.casper.ipc.ExecutionEffect\
R\x06effect\".\n\x12UpgradeDeployError\x12\x18\n\x07message\x18\x01\x20\
\x01(\tR\x07message\"\x99\x01\n\x0fUpgradeResponse\x125\n\x07success\x18\
\x01\x20\x01(\x0b2\x19.casper.ipc.UpgradeResultH\0R\x07success\x12E\n\rf\
ailed_deploy\x18\x02\x20\x01(\x0b2\x1e.casper.ipc.UpgradeDeployErrorH\0R\
\x0cfailedDeployB\x08\n\x06result\"\xa6\x01\n\x17GetEraValidatorsRequest\
\x12*\n\x11parent_state_hash\x18\x01\x20\x01(\x0cR\x0fparentStateHash\
\x12\x15\n\x06era_id\x18\x02\x20\x01(\x04R\x05eraId\x12H\n\x10protocol_v\
ersion\x18\x03\x20\x01(\x0b2\x1d.casper.state.ProtocolVersionR\x0fprotoc\
olVersion\"\xb9\x04\n\x18GetEraValidatorsResponse\x12Q\n\x07success\x18\
\x01\x20\x01(\x0b25.casper.ipc.GetEraValidatorsResponse.ValidatorWeights\
H\0R\x07success\x12E\n\x10missing_prestate\x18\x02\x20\x01(\x0b2\x18.cas\
per.ipc.RootNotFoundH\0R\x0fmissingPrestate\x12R\n\x05error\x18\x05\x20\
\x01(\x0b2:.casper.ipc.GetEraValidatorsResponse.GetEraValidatorsErrorH\0\
R\x05error\x1a\xf1\x01\n\x10ValidatorWeights\x12r\n\x11validator_weights\
\x18\x01\x20\x03(\x0b2E.casper.ipc.GetEraValidatorsResponse.ValidatorWei\
ghts.ValidatorWeightR\x10validatorWeights\x1ai\n\x0fValidatorWeight\x12(\
\n\x10public_key_bytes\x18\x01\x20\x01(\x0cR\x0epublicKeyBytes\x12,\n\
\x06weight\x18\x02\x20\x01(\x0b2\x14.casper.state.BigIntR\x06weight\x1a1\
\n\x15GetEraValidatorsError\x12\x18\n\x07message\x18\x01\x20\x01(\tR\x07\
messageB\x08\n\x06result\"\x97\x02\n\x0bStepRequest\x12*\n\x11parent_sta\
te_hash\x18\x01\x20\x01(\x0cR\x0fparentStateHash\x12H\n\x10protocol_vers\
ion\x18\x02\x20\x01(\x0b2\x1d.casper.state.ProtocolVersionR\x0fprotocolV\
ersion\x126\n\x0bslash_items\x18\x03\x20\x03(\x0b2\x15.casper.ipc.SlashI\
temR\nslashItems\x129\n\x0creward_items\x18\x04\x20\x03(\x0b2\x16.casper\
.ipc.RewardItemR\x0brewardItems\x12\x1f\n\x0brun_auction\x18\x05\x20\x01\
(\x08R\nrunAuction\".\n\tSlashItem\x12!\n\x0cvalidator_id\x18\x01\x20\
\x01(\x0cR\x0bvalidatorId\"E\n\nRewardItem\x12!\n\x0cvalidator_id\x18\
\x01\x20\x01(\x0cR\x0bvalidatorId\x12\x14\n\x05value\x18\x02\x20\x01(\
\x04R\x05value\"\xce\x02\n\x0cStepResponse\x12D\n\x0bstep_result\x18\x01\
\x20\x01(\x0b2#.casper.ipc.StepResponse.StepResultR\nstepResult\x1a%\n\t\
StepError\x12\x18\n\x07message\x18\x01\x20\x01(\tR\x07message\x1a\xd0\
\x01\n\nStepResult\x124\n\x07success\x18\x01\x20\x01(\x0b2\x18.casper.ip\
c.CommitResultH\0R\x07success\x12A\n\x0emissing_parent\x18\x02\x20\x01(\
\x0b2\x18.casper.ipc.RootNotFoundH\0R\rmissingParent\x12:\n\x05error\x18\
\x03\x20\x01(\x0b2\".casper.ipc.StepResponse.StepErrorH\0R\x05errorB\r\n\
\x0bstep_result2\x94\x04\n\x16ExecutionEngineService\x12A\n\x06commit\
\x12\x19.casper.ipc.CommitRequest\x1a\x1a.casper.ipc.CommitResponse\"\0\
\x12>\n\x05query\x12\x18.casper.ipc.QueryRequest\x1a\x19.casper.ipc.Quer\
yResponse\"\0\x12D\n\x07execute\x12\x1a.casper.ipc.ExecuteRequest\x1a\
\x1b.casper.ipc.ExecuteResponse\"\0\x12K\n\x0brun_genesis\x12\x1d.casper\
.ipc.RunGenesisRequest\x1a\x1b.casper.ipc.GenesisResponse\"\0\x12D\n\x07\
upgrade\x12\x1a.casper.ipc.UpgradeRequest\x1a\x1b.casper.ipc.UpgradeResp\
onse\"\0\x12a\n\x12get_era_validators\x12#.casper.ipc.GetEraValidatorsRe\
quest\x1a$.casper.ipc.GetEraValidatorsResponse\"\0\x12;\n\x04step\x12\
\x17.casper.ipc.StepRequest\x1a\x18.casper.ipc.StepResponse\"\0b\x06prot\
o3\
";
static mut file_descriptor_proto_lazy: ::protobuf::lazy::Lazy<::protobuf::descriptor::FileDescriptorProto> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::descriptor::FileDescriptorProto,
};
fn parse_descriptor_proto() -> ::protobuf::descriptor::FileDescriptorProto {
::protobuf::parse_from_bytes(file_descriptor_proto_data).unwrap()
}
pub fn file_descriptor_proto() -> &'static ::protobuf::descriptor::FileDescriptorProto {
unsafe {
file_descriptor_proto_lazy.get(|| {
parse_descriptor_proto()
})
}
}
}