2019-11-06 15:38:30 +00:00
|
|
|
// This file is generated by rust-protobuf 2.8.1. Do not edit
|
2016-11-21 02:48:17 +00:00
|
|
|
// @generated
|
|
|
|
|
|
|
|
// https://github.com/Manishearth/rust-clippy/issues/702
|
|
|
|
#![allow(unknown_lints)]
|
2019-07-18 03:07:27 +00:00
|
|
|
#![allow(clippy::all)]
|
2016-11-21 02:48:17 +00:00
|
|
|
|
|
|
|
#![cfg_attr(rustfmt, rustfmt_skip)]
|
|
|
|
|
|
|
|
#![allow(box_pointers)]
|
|
|
|
#![allow(dead_code)]
|
2017-09-30 22:51:05 +00:00
|
|
|
#![allow(missing_docs)]
|
2016-11-21 02:48:17 +00:00
|
|
|
#![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)]
|
2019-07-18 03:07:27 +00:00
|
|
|
//! Generated file from `authentication.proto`
|
2016-11-21 02:48:17 +00:00
|
|
|
|
|
|
|
use protobuf::Message as Message_imported_for_functions;
|
|
|
|
use protobuf::ProtobufEnum as ProtobufEnum_imported_for_functions;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
/// Generated files are compatible only with the same version
|
|
|
|
/// of protobuf runtime.
|
2019-11-06 15:38:30 +00:00
|
|
|
const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_2_8_1;
|
2019-07-18 03:07:27 +00:00
|
|
|
|
2017-01-18 05:58:12 +00:00
|
|
|
#[derive(PartialEq,Clone,Default)]
|
2016-11-21 02:48:17 +00:00
|
|
|
pub struct ClientResponseEncrypted {
|
|
|
|
// message fields
|
|
|
|
login_credentials: ::protobuf::SingularPtrField<LoginCredentials>,
|
|
|
|
account_creation: ::std::option::Option<AccountCreation>,
|
|
|
|
fingerprint_response: ::protobuf::SingularPtrField<FingerprintResponseUnion>,
|
|
|
|
peer_ticket: ::protobuf::SingularPtrField<PeerTicketUnion>,
|
|
|
|
system_info: ::protobuf::SingularPtrField<SystemInfo>,
|
|
|
|
platform_model: ::protobuf::SingularField<::std::string::String>,
|
|
|
|
version_string: ::protobuf::SingularField<::std::string::String>,
|
|
|
|
appkey: ::protobuf::SingularPtrField<LibspotifyAppKey>,
|
|
|
|
client_info: ::protobuf::SingularPtrField<ClientInfo>,
|
|
|
|
// special fields
|
2019-07-18 03:07:27 +00:00
|
|
|
pub unknown_fields: ::protobuf::UnknownFields,
|
|
|
|
pub cached_size: ::protobuf::CachedSize,
|
|
|
|
}
|
|
|
|
|
|
|
|
impl<'a> ::std::default::Default for &'a ClientResponseEncrypted {
|
|
|
|
fn default() -> &'a ClientResponseEncrypted {
|
|
|
|
<ClientResponseEncrypted as ::protobuf::Message>::default_instance()
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
impl ClientResponseEncrypted {
|
|
|
|
pub fn new() -> ClientResponseEncrypted {
|
|
|
|
::std::default::Default::default()
|
|
|
|
}
|
|
|
|
|
|
|
|
// required .LoginCredentials login_credentials = 10;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
|
|
|
|
pub fn get_login_credentials(&self) -> &LoginCredentials {
|
|
|
|
self.login_credentials.as_ref().unwrap_or_else(|| LoginCredentials::default_instance())
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
pub fn clear_login_credentials(&mut self) {
|
|
|
|
self.login_credentials.clear();
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_login_credentials(&self) -> bool {
|
|
|
|
self.login_credentials.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_login_credentials(&mut self, v: LoginCredentials) {
|
|
|
|
self.login_credentials = ::protobuf::SingularPtrField::some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// Mutable pointer to the field.
|
|
|
|
// If field is not initialized, it is initialized with default value first.
|
|
|
|
pub fn mut_login_credentials(&mut self) -> &mut LoginCredentials {
|
|
|
|
if self.login_credentials.is_none() {
|
|
|
|
self.login_credentials.set_default();
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
self.login_credentials.as_mut().unwrap()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Take field
|
|
|
|
pub fn take_login_credentials(&mut self) -> LoginCredentials {
|
|
|
|
self.login_credentials.take().unwrap_or_else(|| LoginCredentials::new())
|
|
|
|
}
|
|
|
|
|
|
|
|
// optional .AccountCreation account_creation = 20;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
|
|
|
|
pub fn get_account_creation(&self) -> AccountCreation {
|
|
|
|
self.account_creation.unwrap_or(AccountCreation::ACCOUNT_CREATION_ALWAYS_PROMPT)
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
pub fn clear_account_creation(&mut self) {
|
|
|
|
self.account_creation = ::std::option::Option::None;
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_account_creation(&self) -> bool {
|
|
|
|
self.account_creation.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_account_creation(&mut self, v: AccountCreation) {
|
|
|
|
self.account_creation = ::std::option::Option::Some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// optional .FingerprintResponseUnion fingerprint_response = 30;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
|
|
|
|
pub fn get_fingerprint_response(&self) -> &FingerprintResponseUnion {
|
|
|
|
self.fingerprint_response.as_ref().unwrap_or_else(|| FingerprintResponseUnion::default_instance())
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
pub fn clear_fingerprint_response(&mut self) {
|
|
|
|
self.fingerprint_response.clear();
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_fingerprint_response(&self) -> bool {
|
|
|
|
self.fingerprint_response.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_fingerprint_response(&mut self, v: FingerprintResponseUnion) {
|
|
|
|
self.fingerprint_response = ::protobuf::SingularPtrField::some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// Mutable pointer to the field.
|
|
|
|
// If field is not initialized, it is initialized with default value first.
|
|
|
|
pub fn mut_fingerprint_response(&mut self) -> &mut FingerprintResponseUnion {
|
|
|
|
if self.fingerprint_response.is_none() {
|
|
|
|
self.fingerprint_response.set_default();
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
self.fingerprint_response.as_mut().unwrap()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Take field
|
|
|
|
pub fn take_fingerprint_response(&mut self) -> FingerprintResponseUnion {
|
|
|
|
self.fingerprint_response.take().unwrap_or_else(|| FingerprintResponseUnion::new())
|
|
|
|
}
|
|
|
|
|
|
|
|
// optional .PeerTicketUnion peer_ticket = 40;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
|
|
|
|
pub fn get_peer_ticket(&self) -> &PeerTicketUnion {
|
|
|
|
self.peer_ticket.as_ref().unwrap_or_else(|| PeerTicketUnion::default_instance())
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
pub fn clear_peer_ticket(&mut self) {
|
|
|
|
self.peer_ticket.clear();
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_peer_ticket(&self) -> bool {
|
|
|
|
self.peer_ticket.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_peer_ticket(&mut self, v: PeerTicketUnion) {
|
|
|
|
self.peer_ticket = ::protobuf::SingularPtrField::some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// Mutable pointer to the field.
|
|
|
|
// If field is not initialized, it is initialized with default value first.
|
|
|
|
pub fn mut_peer_ticket(&mut self) -> &mut PeerTicketUnion {
|
|
|
|
if self.peer_ticket.is_none() {
|
|
|
|
self.peer_ticket.set_default();
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
self.peer_ticket.as_mut().unwrap()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Take field
|
|
|
|
pub fn take_peer_ticket(&mut self) -> PeerTicketUnion {
|
|
|
|
self.peer_ticket.take().unwrap_or_else(|| PeerTicketUnion::new())
|
|
|
|
}
|
|
|
|
|
|
|
|
// required .SystemInfo system_info = 50;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
|
|
|
|
pub fn get_system_info(&self) -> &SystemInfo {
|
|
|
|
self.system_info.as_ref().unwrap_or_else(|| SystemInfo::default_instance())
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
pub fn clear_system_info(&mut self) {
|
|
|
|
self.system_info.clear();
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_system_info(&self) -> bool {
|
|
|
|
self.system_info.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_system_info(&mut self, v: SystemInfo) {
|
|
|
|
self.system_info = ::protobuf::SingularPtrField::some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// Mutable pointer to the field.
|
|
|
|
// If field is not initialized, it is initialized with default value first.
|
|
|
|
pub fn mut_system_info(&mut self) -> &mut SystemInfo {
|
|
|
|
if self.system_info.is_none() {
|
|
|
|
self.system_info.set_default();
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
self.system_info.as_mut().unwrap()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Take field
|
|
|
|
pub fn take_system_info(&mut self) -> SystemInfo {
|
|
|
|
self.system_info.take().unwrap_or_else(|| SystemInfo::new())
|
|
|
|
}
|
|
|
|
|
|
|
|
// optional string platform_model = 60;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
|
|
|
|
pub fn get_platform_model(&self) -> &str {
|
|
|
|
match self.platform_model.as_ref() {
|
|
|
|
Some(v) => &v,
|
|
|
|
None => "",
|
|
|
|
}
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
pub fn clear_platform_model(&mut self) {
|
|
|
|
self.platform_model.clear();
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_platform_model(&self) -> bool {
|
|
|
|
self.platform_model.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_platform_model(&mut self, v: ::std::string::String) {
|
|
|
|
self.platform_model = ::protobuf::SingularField::some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// Mutable pointer to the field.
|
|
|
|
// If field is not initialized, it is initialized with default value first.
|
|
|
|
pub fn mut_platform_model(&mut self) -> &mut ::std::string::String {
|
|
|
|
if self.platform_model.is_none() {
|
|
|
|
self.platform_model.set_default();
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
self.platform_model.as_mut().unwrap()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Take field
|
|
|
|
pub fn take_platform_model(&mut self) -> ::std::string::String {
|
|
|
|
self.platform_model.take().unwrap_or_else(|| ::std::string::String::new())
|
|
|
|
}
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
// optional string version_string = 70;
|
|
|
|
|
|
|
|
|
|
|
|
pub fn get_version_string(&self) -> &str {
|
|
|
|
match self.version_string.as_ref() {
|
2016-11-21 02:48:17 +00:00
|
|
|
Some(v) => &v,
|
|
|
|
None => "",
|
|
|
|
}
|
|
|
|
}
|
|
|
|
pub fn clear_version_string(&mut self) {
|
|
|
|
self.version_string.clear();
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_version_string(&self) -> bool {
|
|
|
|
self.version_string.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_version_string(&mut self, v: ::std::string::String) {
|
|
|
|
self.version_string = ::protobuf::SingularField::some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// Mutable pointer to the field.
|
|
|
|
// If field is not initialized, it is initialized with default value first.
|
|
|
|
pub fn mut_version_string(&mut self) -> &mut ::std::string::String {
|
|
|
|
if self.version_string.is_none() {
|
|
|
|
self.version_string.set_default();
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
self.version_string.as_mut().unwrap()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Take field
|
|
|
|
pub fn take_version_string(&mut self) -> ::std::string::String {
|
|
|
|
self.version_string.take().unwrap_or_else(|| ::std::string::String::new())
|
|
|
|
}
|
|
|
|
|
|
|
|
// optional .LibspotifyAppKey appkey = 80;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
|
|
|
|
pub fn get_appkey(&self) -> &LibspotifyAppKey {
|
|
|
|
self.appkey.as_ref().unwrap_or_else(|| LibspotifyAppKey::default_instance())
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
pub fn clear_appkey(&mut self) {
|
|
|
|
self.appkey.clear();
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_appkey(&self) -> bool {
|
|
|
|
self.appkey.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_appkey(&mut self, v: LibspotifyAppKey) {
|
|
|
|
self.appkey = ::protobuf::SingularPtrField::some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// Mutable pointer to the field.
|
|
|
|
// If field is not initialized, it is initialized with default value first.
|
|
|
|
pub fn mut_appkey(&mut self) -> &mut LibspotifyAppKey {
|
|
|
|
if self.appkey.is_none() {
|
|
|
|
self.appkey.set_default();
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
self.appkey.as_mut().unwrap()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Take field
|
|
|
|
pub fn take_appkey(&mut self) -> LibspotifyAppKey {
|
|
|
|
self.appkey.take().unwrap_or_else(|| LibspotifyAppKey::new())
|
|
|
|
}
|
|
|
|
|
|
|
|
// optional .ClientInfo client_info = 90;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
|
|
|
|
pub fn get_client_info(&self) -> &ClientInfo {
|
|
|
|
self.client_info.as_ref().unwrap_or_else(|| ClientInfo::default_instance())
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
pub fn clear_client_info(&mut self) {
|
|
|
|
self.client_info.clear();
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_client_info(&self) -> bool {
|
|
|
|
self.client_info.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_client_info(&mut self, v: ClientInfo) {
|
|
|
|
self.client_info = ::protobuf::SingularPtrField::some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// Mutable pointer to the field.
|
|
|
|
// If field is not initialized, it is initialized with default value first.
|
|
|
|
pub fn mut_client_info(&mut self) -> &mut ClientInfo {
|
|
|
|
if self.client_info.is_none() {
|
|
|
|
self.client_info.set_default();
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
self.client_info.as_mut().unwrap()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Take field
|
|
|
|
pub fn take_client_info(&mut self) -> ClientInfo {
|
|
|
|
self.client_info.take().unwrap_or_else(|| ClientInfo::new())
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
impl ::protobuf::Message for ClientResponseEncrypted {
|
|
|
|
fn is_initialized(&self) -> bool {
|
|
|
|
if self.login_credentials.is_none() {
|
|
|
|
return false;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
if self.system_info.is_none() {
|
|
|
|
return false;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
for v in &self.login_credentials {
|
|
|
|
if !v.is_initialized() {
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
};
|
|
|
|
for v in &self.fingerprint_response {
|
|
|
|
if !v.is_initialized() {
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
};
|
|
|
|
for v in &self.peer_ticket {
|
|
|
|
if !v.is_initialized() {
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
};
|
|
|
|
for v in &self.system_info {
|
|
|
|
if !v.is_initialized() {
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
};
|
|
|
|
for v in &self.appkey {
|
|
|
|
if !v.is_initialized() {
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
};
|
|
|
|
for v in &self.client_info {
|
|
|
|
if !v.is_initialized() {
|
|
|
|
return false;
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
};
|
|
|
|
true
|
|
|
|
}
|
|
|
|
|
2019-11-06 15:38:30 +00:00
|
|
|
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
|
2017-01-18 05:58:12 +00:00
|
|
|
while !is.eof()? {
|
|
|
|
let (field_number, wire_type) = is.read_tag_unpack()?;
|
2016-11-21 02:48:17 +00:00
|
|
|
match field_number {
|
|
|
|
10 => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.login_credentials)?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
20 => {
|
2018-09-28 10:02:38 +00:00
|
|
|
::protobuf::rt::read_proto2_enum_with_unknown_fields_into(wire_type, is, &mut self.account_creation, 20, &mut self.unknown_fields)?
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
30 => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.fingerprint_response)?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
40 => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.peer_ticket)?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
50 => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.system_info)?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
60 => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_singular_string_into(wire_type, is, &mut self.platform_model)?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
70 => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_singular_string_into(wire_type, is, &mut self.version_string)?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
80 => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.appkey)?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
90 => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.client_info)?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
_ => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
};
|
|
|
|
}
|
|
|
|
::std::result::Result::Ok(())
|
|
|
|
}
|
|
|
|
|
|
|
|
// Compute sizes of nested messages
|
|
|
|
#[allow(unused_variables)]
|
|
|
|
fn compute_size(&self) -> u32 {
|
|
|
|
let mut my_size = 0;
|
2018-09-28 10:02:38 +00:00
|
|
|
if let Some(ref v) = self.login_credentials.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
let len = v.compute_size();
|
2016-11-21 02:48:17 +00:00
|
|
|
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2017-01-18 05:58:12 +00:00
|
|
|
if let Some(v) = self.account_creation {
|
|
|
|
my_size += ::protobuf::rt::enum_size(20, v);
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.fingerprint_response.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
let len = v.compute_size();
|
2016-11-21 02:48:17 +00:00
|
|
|
my_size += 2 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.peer_ticket.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
let len = v.compute_size();
|
2016-11-21 02:48:17 +00:00
|
|
|
my_size += 2 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.system_info.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
let len = v.compute_size();
|
2016-11-21 02:48:17 +00:00
|
|
|
my_size += 2 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.platform_model.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
my_size += ::protobuf::rt::string_size(60, &v);
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.version_string.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
my_size += ::protobuf::rt::string_size(70, &v);
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.appkey.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
let len = v.compute_size();
|
2016-11-21 02:48:17 +00:00
|
|
|
my_size += 2 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.client_info.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
let len = v.compute_size();
|
2016-11-21 02:48:17 +00:00
|
|
|
my_size += 2 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
|
|
|
|
self.cached_size.set(my_size);
|
|
|
|
my_size
|
|
|
|
}
|
|
|
|
|
2019-11-06 15:38:30 +00:00
|
|
|
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
|
2018-09-28 10:02:38 +00:00
|
|
|
if let Some(ref v) = self.login_credentials.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_tag(10, ::protobuf::wire_format::WireTypeLengthDelimited)?;
|
|
|
|
os.write_raw_varint32(v.get_cached_size())?;
|
|
|
|
v.write_to_with_cached_sizes(os)?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
if let Some(v) = self.account_creation {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_enum(20, v.value())?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.fingerprint_response.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_tag(30, ::protobuf::wire_format::WireTypeLengthDelimited)?;
|
|
|
|
os.write_raw_varint32(v.get_cached_size())?;
|
|
|
|
v.write_to_with_cached_sizes(os)?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.peer_ticket.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_tag(40, ::protobuf::wire_format::WireTypeLengthDelimited)?;
|
|
|
|
os.write_raw_varint32(v.get_cached_size())?;
|
|
|
|
v.write_to_with_cached_sizes(os)?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.system_info.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_tag(50, ::protobuf::wire_format::WireTypeLengthDelimited)?;
|
|
|
|
os.write_raw_varint32(v.get_cached_size())?;
|
|
|
|
v.write_to_with_cached_sizes(os)?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.platform_model.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_string(60, &v)?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.version_string.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_string(70, &v)?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.appkey.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_tag(80, ::protobuf::wire_format::WireTypeLengthDelimited)?;
|
|
|
|
os.write_raw_varint32(v.get_cached_size())?;
|
|
|
|
v.write_to_with_cached_sizes(os)?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.client_info.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_tag(90, ::protobuf::wire_format::WireTypeLengthDelimited)?;
|
|
|
|
os.write_raw_varint32(v.get_cached_size())?;
|
|
|
|
v.write_to_with_cached_sizes(os)?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_unknown_fields(self.get_unknown_fields())?;
|
2016-11-21 02:48:17 +00:00
|
|
|
::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
|
|
|
|
}
|
|
|
|
|
2019-07-27 17:09:03 +00:00
|
|
|
fn as_any(&self) -> &dyn (::std::any::Any) {
|
|
|
|
self as &dyn (::std::any::Any)
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
2019-07-27 17:09:03 +00:00
|
|
|
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
|
|
|
|
self as &mut dyn (::std::any::Any)
|
2017-09-30 22:51:05 +00:00
|
|
|
}
|
2019-07-27 17:09:03 +00:00
|
|
|
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
|
2017-09-30 22:51:05 +00:00
|
|
|
self
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
|
|
|
|
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
|
2018-09-28 10:02:38 +00:00
|
|
|
Self::descriptor_static()
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
fn new() -> ClientResponseEncrypted {
|
|
|
|
ClientResponseEncrypted::new()
|
|
|
|
}
|
|
|
|
|
2018-09-28 10:02:38 +00:00
|
|
|
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
|
2016-11-21 02:48:17 +00:00
|
|
|
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();
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<LoginCredentials>>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"login_credentials",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &ClientResponseEncrypted| { &m.login_credentials },
|
|
|
|
|m: &mut ClientResponseEncrypted| { &mut m.login_credentials },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_option_accessor::<_, ::protobuf::types::ProtobufTypeEnum<AccountCreation>>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"account_creation",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &ClientResponseEncrypted| { &m.account_creation },
|
|
|
|
|m: &mut ClientResponseEncrypted| { &mut m.account_creation },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<FingerprintResponseUnion>>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"fingerprint_response",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &ClientResponseEncrypted| { &m.fingerprint_response },
|
|
|
|
|m: &mut ClientResponseEncrypted| { &mut m.fingerprint_response },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<PeerTicketUnion>>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"peer_ticket",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &ClientResponseEncrypted| { &m.peer_ticket },
|
|
|
|
|m: &mut ClientResponseEncrypted| { &mut m.peer_ticket },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<SystemInfo>>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"system_info",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &ClientResponseEncrypted| { &m.system_info },
|
|
|
|
|m: &mut ClientResponseEncrypted| { &mut m.system_info },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_singular_field_accessor::<_, ::protobuf::types::ProtobufTypeString>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"platform_model",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &ClientResponseEncrypted| { &m.platform_model },
|
|
|
|
|m: &mut ClientResponseEncrypted| { &mut m.platform_model },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_singular_field_accessor::<_, ::protobuf::types::ProtobufTypeString>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"version_string",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &ClientResponseEncrypted| { &m.version_string },
|
|
|
|
|m: &mut ClientResponseEncrypted| { &mut m.version_string },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<LibspotifyAppKey>>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"appkey",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &ClientResponseEncrypted| { &m.appkey },
|
|
|
|
|m: &mut ClientResponseEncrypted| { &mut m.appkey },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ClientInfo>>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"client_info",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &ClientResponseEncrypted| { &m.client_info },
|
|
|
|
|m: &mut ClientResponseEncrypted| { &mut m.client_info },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
|
|
|
::protobuf::reflect::MessageDescriptor::new::<ClientResponseEncrypted>(
|
|
|
|
"ClientResponseEncrypted",
|
|
|
|
fields,
|
|
|
|
file_descriptor_proto()
|
|
|
|
)
|
|
|
|
})
|
|
|
|
}
|
|
|
|
}
|
2018-09-28 10:02:38 +00:00
|
|
|
|
|
|
|
fn default_instance() -> &'static ClientResponseEncrypted {
|
|
|
|
static mut instance: ::protobuf::lazy::Lazy<ClientResponseEncrypted> = ::protobuf::lazy::Lazy {
|
|
|
|
lock: ::protobuf::lazy::ONCE_INIT,
|
|
|
|
ptr: 0 as *const ClientResponseEncrypted,
|
|
|
|
};
|
|
|
|
unsafe {
|
|
|
|
instance.get(ClientResponseEncrypted::new)
|
|
|
|
}
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
impl ::protobuf::Clear for ClientResponseEncrypted {
|
|
|
|
fn clear(&mut self) {
|
2019-07-18 03:07:27 +00:00
|
|
|
self.login_credentials.clear();
|
|
|
|
self.account_creation = ::std::option::Option::None;
|
|
|
|
self.fingerprint_response.clear();
|
|
|
|
self.peer_ticket.clear();
|
|
|
|
self.system_info.clear();
|
|
|
|
self.platform_model.clear();
|
|
|
|
self.version_string.clear();
|
|
|
|
self.appkey.clear();
|
|
|
|
self.client_info.clear();
|
2016-11-21 02:48:17 +00:00
|
|
|
self.unknown_fields.clear();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
impl ::std::fmt::Debug for ClientResponseEncrypted {
|
2019-11-06 15:38:30 +00:00
|
|
|
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
|
2016-11-21 02:48:17 +00:00
|
|
|
::protobuf::text_format::fmt(self, f)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2017-01-18 05:58:12 +00:00
|
|
|
impl ::protobuf::reflect::ProtobufValue for ClientResponseEncrypted {
|
|
|
|
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
|
|
|
|
::protobuf::reflect::ProtobufValueRef::Message(self)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
#[derive(PartialEq,Clone,Default)]
|
2016-11-21 02:48:17 +00:00
|
|
|
pub struct LoginCredentials {
|
|
|
|
// message fields
|
|
|
|
username: ::protobuf::SingularField<::std::string::String>,
|
|
|
|
typ: ::std::option::Option<AuthenticationType>,
|
|
|
|
auth_data: ::protobuf::SingularField<::std::vec::Vec<u8>>,
|
|
|
|
// special fields
|
2019-07-18 03:07:27 +00:00
|
|
|
pub unknown_fields: ::protobuf::UnknownFields,
|
|
|
|
pub cached_size: ::protobuf::CachedSize,
|
|
|
|
}
|
|
|
|
|
|
|
|
impl<'a> ::std::default::Default for &'a LoginCredentials {
|
|
|
|
fn default() -> &'a LoginCredentials {
|
|
|
|
<LoginCredentials as ::protobuf::Message>::default_instance()
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
impl LoginCredentials {
|
|
|
|
pub fn new() -> LoginCredentials {
|
|
|
|
::std::default::Default::default()
|
|
|
|
}
|
|
|
|
|
|
|
|
// optional string username = 10;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
|
|
|
|
pub fn get_username(&self) -> &str {
|
|
|
|
match self.username.as_ref() {
|
|
|
|
Some(v) => &v,
|
|
|
|
None => "",
|
|
|
|
}
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
pub fn clear_username(&mut self) {
|
|
|
|
self.username.clear();
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_username(&self) -> bool {
|
|
|
|
self.username.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_username(&mut self, v: ::std::string::String) {
|
|
|
|
self.username = ::protobuf::SingularField::some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// Mutable pointer to the field.
|
|
|
|
// If field is not initialized, it is initialized with default value first.
|
|
|
|
pub fn mut_username(&mut self) -> &mut ::std::string::String {
|
|
|
|
if self.username.is_none() {
|
|
|
|
self.username.set_default();
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
self.username.as_mut().unwrap()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Take field
|
|
|
|
pub fn take_username(&mut self) -> ::std::string::String {
|
|
|
|
self.username.take().unwrap_or_else(|| ::std::string::String::new())
|
|
|
|
}
|
|
|
|
|
|
|
|
// required .AuthenticationType typ = 20;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
|
|
|
|
pub fn get_typ(&self) -> AuthenticationType {
|
|
|
|
self.typ.unwrap_or(AuthenticationType::AUTHENTICATION_USER_PASS)
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
pub fn clear_typ(&mut self) {
|
|
|
|
self.typ = ::std::option::Option::None;
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_typ(&self) -> bool {
|
|
|
|
self.typ.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_typ(&mut self, v: AuthenticationType) {
|
|
|
|
self.typ = ::std::option::Option::Some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// optional bytes auth_data = 30;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
|
|
|
|
pub fn get_auth_data(&self) -> &[u8] {
|
|
|
|
match self.auth_data.as_ref() {
|
|
|
|
Some(v) => &v,
|
|
|
|
None => &[],
|
|
|
|
}
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
pub fn clear_auth_data(&mut self) {
|
|
|
|
self.auth_data.clear();
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_auth_data(&self) -> bool {
|
|
|
|
self.auth_data.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_auth_data(&mut self, v: ::std::vec::Vec<u8>) {
|
|
|
|
self.auth_data = ::protobuf::SingularField::some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// Mutable pointer to the field.
|
|
|
|
// If field is not initialized, it is initialized with default value first.
|
|
|
|
pub fn mut_auth_data(&mut self) -> &mut ::std::vec::Vec<u8> {
|
|
|
|
if self.auth_data.is_none() {
|
|
|
|
self.auth_data.set_default();
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
self.auth_data.as_mut().unwrap()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Take field
|
|
|
|
pub fn take_auth_data(&mut self) -> ::std::vec::Vec<u8> {
|
|
|
|
self.auth_data.take().unwrap_or_else(|| ::std::vec::Vec::new())
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
impl ::protobuf::Message for LoginCredentials {
|
|
|
|
fn is_initialized(&self) -> bool {
|
|
|
|
if self.typ.is_none() {
|
|
|
|
return false;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
true
|
|
|
|
}
|
|
|
|
|
2019-11-06 15:38:30 +00:00
|
|
|
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
|
2017-01-18 05:58:12 +00:00
|
|
|
while !is.eof()? {
|
|
|
|
let (field_number, wire_type) = is.read_tag_unpack()?;
|
2016-11-21 02:48:17 +00:00
|
|
|
match field_number {
|
|
|
|
10 => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_singular_string_into(wire_type, is, &mut self.username)?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
20 => {
|
2018-09-28 10:02:38 +00:00
|
|
|
::protobuf::rt::read_proto2_enum_with_unknown_fields_into(wire_type, is, &mut self.typ, 20, &mut self.unknown_fields)?
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
30 => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_singular_bytes_into(wire_type, is, &mut self.auth_data)?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
_ => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
};
|
|
|
|
}
|
|
|
|
::std::result::Result::Ok(())
|
|
|
|
}
|
|
|
|
|
|
|
|
// Compute sizes of nested messages
|
|
|
|
#[allow(unused_variables)]
|
|
|
|
fn compute_size(&self) -> u32 {
|
|
|
|
let mut my_size = 0;
|
2018-09-28 10:02:38 +00:00
|
|
|
if let Some(ref v) = self.username.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
my_size += ::protobuf::rt::string_size(10, &v);
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2017-01-18 05:58:12 +00:00
|
|
|
if let Some(v) = self.typ {
|
|
|
|
my_size += ::protobuf::rt::enum_size(20, v);
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.auth_data.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
my_size += ::protobuf::rt::bytes_size(30, &v);
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
|
|
|
|
self.cached_size.set(my_size);
|
|
|
|
my_size
|
|
|
|
}
|
|
|
|
|
2019-11-06 15:38:30 +00:00
|
|
|
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
|
2018-09-28 10:02:38 +00:00
|
|
|
if let Some(ref v) = self.username.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_string(10, &v)?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
if let Some(v) = self.typ {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_enum(20, v.value())?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.auth_data.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_bytes(30, &v)?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_unknown_fields(self.get_unknown_fields())?;
|
2016-11-21 02:48:17 +00:00
|
|
|
::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
|
|
|
|
}
|
|
|
|
|
2019-07-27 17:09:03 +00:00
|
|
|
fn as_any(&self) -> &dyn (::std::any::Any) {
|
|
|
|
self as &dyn (::std::any::Any)
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
2019-07-27 17:09:03 +00:00
|
|
|
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
|
|
|
|
self as &mut dyn (::std::any::Any)
|
2017-09-30 22:51:05 +00:00
|
|
|
}
|
2019-07-27 17:09:03 +00:00
|
|
|
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
|
2017-09-30 22:51:05 +00:00
|
|
|
self
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
|
|
|
|
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
|
2018-09-28 10:02:38 +00:00
|
|
|
Self::descriptor_static()
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
fn new() -> LoginCredentials {
|
|
|
|
LoginCredentials::new()
|
|
|
|
}
|
|
|
|
|
2018-09-28 10:02:38 +00:00
|
|
|
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
|
2016-11-21 02:48:17 +00:00
|
|
|
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();
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_singular_field_accessor::<_, ::protobuf::types::ProtobufTypeString>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"username",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &LoginCredentials| { &m.username },
|
|
|
|
|m: &mut LoginCredentials| { &mut m.username },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_option_accessor::<_, ::protobuf::types::ProtobufTypeEnum<AuthenticationType>>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"typ",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &LoginCredentials| { &m.typ },
|
|
|
|
|m: &mut LoginCredentials| { &mut m.typ },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_singular_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"auth_data",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &LoginCredentials| { &m.auth_data },
|
|
|
|
|m: &mut LoginCredentials| { &mut m.auth_data },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
|
|
|
::protobuf::reflect::MessageDescriptor::new::<LoginCredentials>(
|
|
|
|
"LoginCredentials",
|
|
|
|
fields,
|
|
|
|
file_descriptor_proto()
|
|
|
|
)
|
|
|
|
})
|
|
|
|
}
|
|
|
|
}
|
2018-09-28 10:02:38 +00:00
|
|
|
|
|
|
|
fn default_instance() -> &'static LoginCredentials {
|
|
|
|
static mut instance: ::protobuf::lazy::Lazy<LoginCredentials> = ::protobuf::lazy::Lazy {
|
|
|
|
lock: ::protobuf::lazy::ONCE_INIT,
|
|
|
|
ptr: 0 as *const LoginCredentials,
|
|
|
|
};
|
|
|
|
unsafe {
|
|
|
|
instance.get(LoginCredentials::new)
|
|
|
|
}
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
impl ::protobuf::Clear for LoginCredentials {
|
|
|
|
fn clear(&mut self) {
|
2019-07-18 03:07:27 +00:00
|
|
|
self.username.clear();
|
|
|
|
self.typ = ::std::option::Option::None;
|
|
|
|
self.auth_data.clear();
|
2016-11-21 02:48:17 +00:00
|
|
|
self.unknown_fields.clear();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
impl ::std::fmt::Debug for LoginCredentials {
|
2019-11-06 15:38:30 +00:00
|
|
|
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
|
2016-11-21 02:48:17 +00:00
|
|
|
::protobuf::text_format::fmt(self, f)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2017-01-18 05:58:12 +00:00
|
|
|
impl ::protobuf::reflect::ProtobufValue for LoginCredentials {
|
|
|
|
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
|
|
|
|
::protobuf::reflect::ProtobufValueRef::Message(self)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
#[derive(PartialEq,Clone,Default)]
|
2016-11-21 02:48:17 +00:00
|
|
|
pub struct FingerprintResponseUnion {
|
|
|
|
// message fields
|
|
|
|
grain: ::protobuf::SingularPtrField<FingerprintGrainResponse>,
|
|
|
|
hmac_ripemd: ::protobuf::SingularPtrField<FingerprintHmacRipemdResponse>,
|
|
|
|
// special fields
|
2019-07-18 03:07:27 +00:00
|
|
|
pub unknown_fields: ::protobuf::UnknownFields,
|
|
|
|
pub cached_size: ::protobuf::CachedSize,
|
|
|
|
}
|
|
|
|
|
|
|
|
impl<'a> ::std::default::Default for &'a FingerprintResponseUnion {
|
|
|
|
fn default() -> &'a FingerprintResponseUnion {
|
|
|
|
<FingerprintResponseUnion as ::protobuf::Message>::default_instance()
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
impl FingerprintResponseUnion {
|
|
|
|
pub fn new() -> FingerprintResponseUnion {
|
|
|
|
::std::default::Default::default()
|
|
|
|
}
|
|
|
|
|
|
|
|
// optional .FingerprintGrainResponse grain = 10;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
|
|
|
|
pub fn get_grain(&self) -> &FingerprintGrainResponse {
|
|
|
|
self.grain.as_ref().unwrap_or_else(|| FingerprintGrainResponse::default_instance())
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
pub fn clear_grain(&mut self) {
|
|
|
|
self.grain.clear();
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_grain(&self) -> bool {
|
|
|
|
self.grain.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_grain(&mut self, v: FingerprintGrainResponse) {
|
|
|
|
self.grain = ::protobuf::SingularPtrField::some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// Mutable pointer to the field.
|
|
|
|
// If field is not initialized, it is initialized with default value first.
|
|
|
|
pub fn mut_grain(&mut self) -> &mut FingerprintGrainResponse {
|
|
|
|
if self.grain.is_none() {
|
|
|
|
self.grain.set_default();
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
self.grain.as_mut().unwrap()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Take field
|
|
|
|
pub fn take_grain(&mut self) -> FingerprintGrainResponse {
|
|
|
|
self.grain.take().unwrap_or_else(|| FingerprintGrainResponse::new())
|
|
|
|
}
|
|
|
|
|
|
|
|
// optional .FingerprintHmacRipemdResponse hmac_ripemd = 20;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
|
|
|
|
pub fn get_hmac_ripemd(&self) -> &FingerprintHmacRipemdResponse {
|
|
|
|
self.hmac_ripemd.as_ref().unwrap_or_else(|| FingerprintHmacRipemdResponse::default_instance())
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
pub fn clear_hmac_ripemd(&mut self) {
|
|
|
|
self.hmac_ripemd.clear();
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_hmac_ripemd(&self) -> bool {
|
|
|
|
self.hmac_ripemd.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_hmac_ripemd(&mut self, v: FingerprintHmacRipemdResponse) {
|
|
|
|
self.hmac_ripemd = ::protobuf::SingularPtrField::some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// Mutable pointer to the field.
|
|
|
|
// If field is not initialized, it is initialized with default value first.
|
|
|
|
pub fn mut_hmac_ripemd(&mut self) -> &mut FingerprintHmacRipemdResponse {
|
|
|
|
if self.hmac_ripemd.is_none() {
|
|
|
|
self.hmac_ripemd.set_default();
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
self.hmac_ripemd.as_mut().unwrap()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Take field
|
|
|
|
pub fn take_hmac_ripemd(&mut self) -> FingerprintHmacRipemdResponse {
|
|
|
|
self.hmac_ripemd.take().unwrap_or_else(|| FingerprintHmacRipemdResponse::new())
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
impl ::protobuf::Message for FingerprintResponseUnion {
|
|
|
|
fn is_initialized(&self) -> bool {
|
2018-09-28 10:02:38 +00:00
|
|
|
for v in &self.grain {
|
|
|
|
if !v.is_initialized() {
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
};
|
|
|
|
for v in &self.hmac_ripemd {
|
|
|
|
if !v.is_initialized() {
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
};
|
2016-11-21 02:48:17 +00:00
|
|
|
true
|
|
|
|
}
|
|
|
|
|
2019-11-06 15:38:30 +00:00
|
|
|
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
|
2017-01-18 05:58:12 +00:00
|
|
|
while !is.eof()? {
|
|
|
|
let (field_number, wire_type) = is.read_tag_unpack()?;
|
2016-11-21 02:48:17 +00:00
|
|
|
match field_number {
|
|
|
|
10 => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.grain)?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
20 => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.hmac_ripemd)?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
_ => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
};
|
|
|
|
}
|
|
|
|
::std::result::Result::Ok(())
|
|
|
|
}
|
|
|
|
|
|
|
|
// Compute sizes of nested messages
|
|
|
|
#[allow(unused_variables)]
|
|
|
|
fn compute_size(&self) -> u32 {
|
|
|
|
let mut my_size = 0;
|
2018-09-28 10:02:38 +00:00
|
|
|
if let Some(ref v) = self.grain.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
let len = v.compute_size();
|
2016-11-21 02:48:17 +00:00
|
|
|
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.hmac_ripemd.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
let len = v.compute_size();
|
2016-11-21 02:48:17 +00:00
|
|
|
my_size += 2 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
|
|
|
|
self.cached_size.set(my_size);
|
|
|
|
my_size
|
|
|
|
}
|
|
|
|
|
2019-11-06 15:38:30 +00:00
|
|
|
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
|
2018-09-28 10:02:38 +00:00
|
|
|
if let Some(ref v) = self.grain.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_tag(10, ::protobuf::wire_format::WireTypeLengthDelimited)?;
|
|
|
|
os.write_raw_varint32(v.get_cached_size())?;
|
|
|
|
v.write_to_with_cached_sizes(os)?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.hmac_ripemd.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_tag(20, ::protobuf::wire_format::WireTypeLengthDelimited)?;
|
|
|
|
os.write_raw_varint32(v.get_cached_size())?;
|
|
|
|
v.write_to_with_cached_sizes(os)?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_unknown_fields(self.get_unknown_fields())?;
|
2016-11-21 02:48:17 +00:00
|
|
|
::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
|
|
|
|
}
|
|
|
|
|
2019-07-27 17:09:03 +00:00
|
|
|
fn as_any(&self) -> &dyn (::std::any::Any) {
|
|
|
|
self as &dyn (::std::any::Any)
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
2019-07-27 17:09:03 +00:00
|
|
|
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
|
|
|
|
self as &mut dyn (::std::any::Any)
|
2017-09-30 22:51:05 +00:00
|
|
|
}
|
2019-07-27 17:09:03 +00:00
|
|
|
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
|
2017-09-30 22:51:05 +00:00
|
|
|
self
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
|
|
|
|
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
|
2018-09-28 10:02:38 +00:00
|
|
|
Self::descriptor_static()
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
fn new() -> FingerprintResponseUnion {
|
|
|
|
FingerprintResponseUnion::new()
|
|
|
|
}
|
|
|
|
|
2018-09-28 10:02:38 +00:00
|
|
|
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
|
2016-11-21 02:48:17 +00:00
|
|
|
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();
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<FingerprintGrainResponse>>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"grain",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &FingerprintResponseUnion| { &m.grain },
|
|
|
|
|m: &mut FingerprintResponseUnion| { &mut m.grain },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<FingerprintHmacRipemdResponse>>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"hmac_ripemd",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &FingerprintResponseUnion| { &m.hmac_ripemd },
|
|
|
|
|m: &mut FingerprintResponseUnion| { &mut m.hmac_ripemd },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
|
|
|
::protobuf::reflect::MessageDescriptor::new::<FingerprintResponseUnion>(
|
|
|
|
"FingerprintResponseUnion",
|
|
|
|
fields,
|
|
|
|
file_descriptor_proto()
|
|
|
|
)
|
|
|
|
})
|
|
|
|
}
|
|
|
|
}
|
2018-09-28 10:02:38 +00:00
|
|
|
|
|
|
|
fn default_instance() -> &'static FingerprintResponseUnion {
|
|
|
|
static mut instance: ::protobuf::lazy::Lazy<FingerprintResponseUnion> = ::protobuf::lazy::Lazy {
|
|
|
|
lock: ::protobuf::lazy::ONCE_INIT,
|
|
|
|
ptr: 0 as *const FingerprintResponseUnion,
|
|
|
|
};
|
|
|
|
unsafe {
|
|
|
|
instance.get(FingerprintResponseUnion::new)
|
|
|
|
}
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
impl ::protobuf::Clear for FingerprintResponseUnion {
|
|
|
|
fn clear(&mut self) {
|
2019-07-18 03:07:27 +00:00
|
|
|
self.grain.clear();
|
|
|
|
self.hmac_ripemd.clear();
|
2016-11-21 02:48:17 +00:00
|
|
|
self.unknown_fields.clear();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
impl ::std::fmt::Debug for FingerprintResponseUnion {
|
2019-11-06 15:38:30 +00:00
|
|
|
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
|
2016-11-21 02:48:17 +00:00
|
|
|
::protobuf::text_format::fmt(self, f)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2017-01-18 05:58:12 +00:00
|
|
|
impl ::protobuf::reflect::ProtobufValue for FingerprintResponseUnion {
|
|
|
|
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
|
|
|
|
::protobuf::reflect::ProtobufValueRef::Message(self)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
#[derive(PartialEq,Clone,Default)]
|
2016-11-21 02:48:17 +00:00
|
|
|
pub struct FingerprintGrainResponse {
|
|
|
|
// message fields
|
|
|
|
encrypted_key: ::protobuf::SingularField<::std::vec::Vec<u8>>,
|
|
|
|
// special fields
|
2019-07-18 03:07:27 +00:00
|
|
|
pub unknown_fields: ::protobuf::UnknownFields,
|
|
|
|
pub cached_size: ::protobuf::CachedSize,
|
|
|
|
}
|
|
|
|
|
|
|
|
impl<'a> ::std::default::Default for &'a FingerprintGrainResponse {
|
|
|
|
fn default() -> &'a FingerprintGrainResponse {
|
|
|
|
<FingerprintGrainResponse as ::protobuf::Message>::default_instance()
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
impl FingerprintGrainResponse {
|
|
|
|
pub fn new() -> FingerprintGrainResponse {
|
|
|
|
::std::default::Default::default()
|
|
|
|
}
|
|
|
|
|
|
|
|
// required bytes encrypted_key = 10;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
|
|
|
|
pub fn get_encrypted_key(&self) -> &[u8] {
|
|
|
|
match self.encrypted_key.as_ref() {
|
|
|
|
Some(v) => &v,
|
|
|
|
None => &[],
|
|
|
|
}
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
pub fn clear_encrypted_key(&mut self) {
|
|
|
|
self.encrypted_key.clear();
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_encrypted_key(&self) -> bool {
|
|
|
|
self.encrypted_key.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_encrypted_key(&mut self, v: ::std::vec::Vec<u8>) {
|
|
|
|
self.encrypted_key = ::protobuf::SingularField::some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// Mutable pointer to the field.
|
|
|
|
// If field is not initialized, it is initialized with default value first.
|
|
|
|
pub fn mut_encrypted_key(&mut self) -> &mut ::std::vec::Vec<u8> {
|
|
|
|
if self.encrypted_key.is_none() {
|
|
|
|
self.encrypted_key.set_default();
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
self.encrypted_key.as_mut().unwrap()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Take field
|
|
|
|
pub fn take_encrypted_key(&mut self) -> ::std::vec::Vec<u8> {
|
|
|
|
self.encrypted_key.take().unwrap_or_else(|| ::std::vec::Vec::new())
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
impl ::protobuf::Message for FingerprintGrainResponse {
|
|
|
|
fn is_initialized(&self) -> bool {
|
|
|
|
if self.encrypted_key.is_none() {
|
|
|
|
return false;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
true
|
|
|
|
}
|
|
|
|
|
2019-11-06 15:38:30 +00:00
|
|
|
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
|
2017-01-18 05:58:12 +00:00
|
|
|
while !is.eof()? {
|
|
|
|
let (field_number, wire_type) = is.read_tag_unpack()?;
|
2016-11-21 02:48:17 +00:00
|
|
|
match field_number {
|
|
|
|
10 => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_singular_bytes_into(wire_type, is, &mut self.encrypted_key)?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
_ => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
};
|
|
|
|
}
|
|
|
|
::std::result::Result::Ok(())
|
|
|
|
}
|
|
|
|
|
|
|
|
// Compute sizes of nested messages
|
|
|
|
#[allow(unused_variables)]
|
|
|
|
fn compute_size(&self) -> u32 {
|
|
|
|
let mut my_size = 0;
|
2018-09-28 10:02:38 +00:00
|
|
|
if let Some(ref v) = self.encrypted_key.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
my_size += ::protobuf::rt::bytes_size(10, &v);
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
|
|
|
|
self.cached_size.set(my_size);
|
|
|
|
my_size
|
|
|
|
}
|
|
|
|
|
2019-11-06 15:38:30 +00:00
|
|
|
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
|
2018-09-28 10:02:38 +00:00
|
|
|
if let Some(ref v) = self.encrypted_key.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_bytes(10, &v)?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_unknown_fields(self.get_unknown_fields())?;
|
2016-11-21 02:48:17 +00:00
|
|
|
::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
|
|
|
|
}
|
|
|
|
|
2019-07-27 17:09:03 +00:00
|
|
|
fn as_any(&self) -> &dyn (::std::any::Any) {
|
|
|
|
self as &dyn (::std::any::Any)
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
2019-07-27 17:09:03 +00:00
|
|
|
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
|
|
|
|
self as &mut dyn (::std::any::Any)
|
2017-09-30 22:51:05 +00:00
|
|
|
}
|
2019-07-27 17:09:03 +00:00
|
|
|
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
|
2017-09-30 22:51:05 +00:00
|
|
|
self
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
|
|
|
|
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
|
2018-09-28 10:02:38 +00:00
|
|
|
Self::descriptor_static()
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
fn new() -> FingerprintGrainResponse {
|
|
|
|
FingerprintGrainResponse::new()
|
|
|
|
}
|
|
|
|
|
2018-09-28 10:02:38 +00:00
|
|
|
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
|
2016-11-21 02:48:17 +00:00
|
|
|
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();
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_singular_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"encrypted_key",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &FingerprintGrainResponse| { &m.encrypted_key },
|
|
|
|
|m: &mut FingerprintGrainResponse| { &mut m.encrypted_key },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
|
|
|
::protobuf::reflect::MessageDescriptor::new::<FingerprintGrainResponse>(
|
|
|
|
"FingerprintGrainResponse",
|
|
|
|
fields,
|
|
|
|
file_descriptor_proto()
|
|
|
|
)
|
|
|
|
})
|
|
|
|
}
|
|
|
|
}
|
2018-09-28 10:02:38 +00:00
|
|
|
|
|
|
|
fn default_instance() -> &'static FingerprintGrainResponse {
|
|
|
|
static mut instance: ::protobuf::lazy::Lazy<FingerprintGrainResponse> = ::protobuf::lazy::Lazy {
|
|
|
|
lock: ::protobuf::lazy::ONCE_INIT,
|
|
|
|
ptr: 0 as *const FingerprintGrainResponse,
|
|
|
|
};
|
|
|
|
unsafe {
|
|
|
|
instance.get(FingerprintGrainResponse::new)
|
|
|
|
}
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
impl ::protobuf::Clear for FingerprintGrainResponse {
|
|
|
|
fn clear(&mut self) {
|
2019-07-18 03:07:27 +00:00
|
|
|
self.encrypted_key.clear();
|
2016-11-21 02:48:17 +00:00
|
|
|
self.unknown_fields.clear();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
impl ::std::fmt::Debug for FingerprintGrainResponse {
|
2019-11-06 15:38:30 +00:00
|
|
|
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
|
2016-11-21 02:48:17 +00:00
|
|
|
::protobuf::text_format::fmt(self, f)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2017-01-18 05:58:12 +00:00
|
|
|
impl ::protobuf::reflect::ProtobufValue for FingerprintGrainResponse {
|
|
|
|
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
|
|
|
|
::protobuf::reflect::ProtobufValueRef::Message(self)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
#[derive(PartialEq,Clone,Default)]
|
2016-11-21 02:48:17 +00:00
|
|
|
pub struct FingerprintHmacRipemdResponse {
|
|
|
|
// message fields
|
|
|
|
hmac: ::protobuf::SingularField<::std::vec::Vec<u8>>,
|
|
|
|
// special fields
|
2019-07-18 03:07:27 +00:00
|
|
|
pub unknown_fields: ::protobuf::UnknownFields,
|
|
|
|
pub cached_size: ::protobuf::CachedSize,
|
|
|
|
}
|
|
|
|
|
|
|
|
impl<'a> ::std::default::Default for &'a FingerprintHmacRipemdResponse {
|
|
|
|
fn default() -> &'a FingerprintHmacRipemdResponse {
|
|
|
|
<FingerprintHmacRipemdResponse as ::protobuf::Message>::default_instance()
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
impl FingerprintHmacRipemdResponse {
|
|
|
|
pub fn new() -> FingerprintHmacRipemdResponse {
|
|
|
|
::std::default::Default::default()
|
|
|
|
}
|
|
|
|
|
|
|
|
// required bytes hmac = 10;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
|
|
|
|
pub fn get_hmac(&self) -> &[u8] {
|
|
|
|
match self.hmac.as_ref() {
|
|
|
|
Some(v) => &v,
|
|
|
|
None => &[],
|
|
|
|
}
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
pub fn clear_hmac(&mut self) {
|
|
|
|
self.hmac.clear();
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_hmac(&self) -> bool {
|
|
|
|
self.hmac.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_hmac(&mut self, v: ::std::vec::Vec<u8>) {
|
|
|
|
self.hmac = ::protobuf::SingularField::some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// Mutable pointer to the field.
|
|
|
|
// If field is not initialized, it is initialized with default value first.
|
|
|
|
pub fn mut_hmac(&mut self) -> &mut ::std::vec::Vec<u8> {
|
|
|
|
if self.hmac.is_none() {
|
|
|
|
self.hmac.set_default();
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
self.hmac.as_mut().unwrap()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Take field
|
|
|
|
pub fn take_hmac(&mut self) -> ::std::vec::Vec<u8> {
|
|
|
|
self.hmac.take().unwrap_or_else(|| ::std::vec::Vec::new())
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
impl ::protobuf::Message for FingerprintHmacRipemdResponse {
|
|
|
|
fn is_initialized(&self) -> bool {
|
|
|
|
if self.hmac.is_none() {
|
|
|
|
return false;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
true
|
|
|
|
}
|
|
|
|
|
2019-11-06 15:38:30 +00:00
|
|
|
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
|
2017-01-18 05:58:12 +00:00
|
|
|
while !is.eof()? {
|
|
|
|
let (field_number, wire_type) = is.read_tag_unpack()?;
|
2016-11-21 02:48:17 +00:00
|
|
|
match field_number {
|
|
|
|
10 => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_singular_bytes_into(wire_type, is, &mut self.hmac)?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
_ => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
};
|
|
|
|
}
|
|
|
|
::std::result::Result::Ok(())
|
|
|
|
}
|
|
|
|
|
|
|
|
// Compute sizes of nested messages
|
|
|
|
#[allow(unused_variables)]
|
|
|
|
fn compute_size(&self) -> u32 {
|
|
|
|
let mut my_size = 0;
|
2018-09-28 10:02:38 +00:00
|
|
|
if let Some(ref v) = self.hmac.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
my_size += ::protobuf::rt::bytes_size(10, &v);
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
|
|
|
|
self.cached_size.set(my_size);
|
|
|
|
my_size
|
|
|
|
}
|
|
|
|
|
2019-11-06 15:38:30 +00:00
|
|
|
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
|
2018-09-28 10:02:38 +00:00
|
|
|
if let Some(ref v) = self.hmac.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_bytes(10, &v)?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_unknown_fields(self.get_unknown_fields())?;
|
2016-11-21 02:48:17 +00:00
|
|
|
::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
|
|
|
|
}
|
|
|
|
|
2019-07-27 17:09:03 +00:00
|
|
|
fn as_any(&self) -> &dyn (::std::any::Any) {
|
|
|
|
self as &dyn (::std::any::Any)
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
2019-07-27 17:09:03 +00:00
|
|
|
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
|
|
|
|
self as &mut dyn (::std::any::Any)
|
2017-09-30 22:51:05 +00:00
|
|
|
}
|
2019-07-27 17:09:03 +00:00
|
|
|
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
|
2017-09-30 22:51:05 +00:00
|
|
|
self
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
|
|
|
|
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
|
2018-09-28 10:02:38 +00:00
|
|
|
Self::descriptor_static()
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
fn new() -> FingerprintHmacRipemdResponse {
|
|
|
|
FingerprintHmacRipemdResponse::new()
|
|
|
|
}
|
|
|
|
|
2018-09-28 10:02:38 +00:00
|
|
|
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
|
2016-11-21 02:48:17 +00:00
|
|
|
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();
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_singular_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"hmac",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &FingerprintHmacRipemdResponse| { &m.hmac },
|
|
|
|
|m: &mut FingerprintHmacRipemdResponse| { &mut m.hmac },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
|
|
|
::protobuf::reflect::MessageDescriptor::new::<FingerprintHmacRipemdResponse>(
|
|
|
|
"FingerprintHmacRipemdResponse",
|
|
|
|
fields,
|
|
|
|
file_descriptor_proto()
|
|
|
|
)
|
|
|
|
})
|
|
|
|
}
|
|
|
|
}
|
2018-09-28 10:02:38 +00:00
|
|
|
|
|
|
|
fn default_instance() -> &'static FingerprintHmacRipemdResponse {
|
|
|
|
static mut instance: ::protobuf::lazy::Lazy<FingerprintHmacRipemdResponse> = ::protobuf::lazy::Lazy {
|
|
|
|
lock: ::protobuf::lazy::ONCE_INIT,
|
|
|
|
ptr: 0 as *const FingerprintHmacRipemdResponse,
|
|
|
|
};
|
|
|
|
unsafe {
|
|
|
|
instance.get(FingerprintHmacRipemdResponse::new)
|
|
|
|
}
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
impl ::protobuf::Clear for FingerprintHmacRipemdResponse {
|
|
|
|
fn clear(&mut self) {
|
2019-07-18 03:07:27 +00:00
|
|
|
self.hmac.clear();
|
2016-11-21 02:48:17 +00:00
|
|
|
self.unknown_fields.clear();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
impl ::std::fmt::Debug for FingerprintHmacRipemdResponse {
|
2019-11-06 15:38:30 +00:00
|
|
|
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
|
2016-11-21 02:48:17 +00:00
|
|
|
::protobuf::text_format::fmt(self, f)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2017-01-18 05:58:12 +00:00
|
|
|
impl ::protobuf::reflect::ProtobufValue for FingerprintHmacRipemdResponse {
|
|
|
|
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
|
|
|
|
::protobuf::reflect::ProtobufValueRef::Message(self)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
#[derive(PartialEq,Clone,Default)]
|
2016-11-21 02:48:17 +00:00
|
|
|
pub struct PeerTicketUnion {
|
|
|
|
// message fields
|
|
|
|
public_key: ::protobuf::SingularPtrField<PeerTicketPublicKey>,
|
|
|
|
old_ticket: ::protobuf::SingularPtrField<PeerTicketOld>,
|
|
|
|
// special fields
|
2019-07-18 03:07:27 +00:00
|
|
|
pub unknown_fields: ::protobuf::UnknownFields,
|
|
|
|
pub cached_size: ::protobuf::CachedSize,
|
|
|
|
}
|
|
|
|
|
|
|
|
impl<'a> ::std::default::Default for &'a PeerTicketUnion {
|
|
|
|
fn default() -> &'a PeerTicketUnion {
|
|
|
|
<PeerTicketUnion as ::protobuf::Message>::default_instance()
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
impl PeerTicketUnion {
|
|
|
|
pub fn new() -> PeerTicketUnion {
|
|
|
|
::std::default::Default::default()
|
|
|
|
}
|
|
|
|
|
|
|
|
// optional .PeerTicketPublicKey public_key = 10;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
|
|
|
|
pub fn get_public_key(&self) -> &PeerTicketPublicKey {
|
|
|
|
self.public_key.as_ref().unwrap_or_else(|| PeerTicketPublicKey::default_instance())
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
pub fn clear_public_key(&mut self) {
|
|
|
|
self.public_key.clear();
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_public_key(&self) -> bool {
|
|
|
|
self.public_key.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_public_key(&mut self, v: PeerTicketPublicKey) {
|
|
|
|
self.public_key = ::protobuf::SingularPtrField::some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// Mutable pointer to the field.
|
|
|
|
// If field is not initialized, it is initialized with default value first.
|
|
|
|
pub fn mut_public_key(&mut self) -> &mut PeerTicketPublicKey {
|
|
|
|
if self.public_key.is_none() {
|
|
|
|
self.public_key.set_default();
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
self.public_key.as_mut().unwrap()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Take field
|
|
|
|
pub fn take_public_key(&mut self) -> PeerTicketPublicKey {
|
|
|
|
self.public_key.take().unwrap_or_else(|| PeerTicketPublicKey::new())
|
|
|
|
}
|
|
|
|
|
|
|
|
// optional .PeerTicketOld old_ticket = 20;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
|
|
|
|
pub fn get_old_ticket(&self) -> &PeerTicketOld {
|
|
|
|
self.old_ticket.as_ref().unwrap_or_else(|| PeerTicketOld::default_instance())
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
pub fn clear_old_ticket(&mut self) {
|
|
|
|
self.old_ticket.clear();
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_old_ticket(&self) -> bool {
|
|
|
|
self.old_ticket.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_old_ticket(&mut self, v: PeerTicketOld) {
|
|
|
|
self.old_ticket = ::protobuf::SingularPtrField::some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// Mutable pointer to the field.
|
|
|
|
// If field is not initialized, it is initialized with default value first.
|
|
|
|
pub fn mut_old_ticket(&mut self) -> &mut PeerTicketOld {
|
|
|
|
if self.old_ticket.is_none() {
|
|
|
|
self.old_ticket.set_default();
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
self.old_ticket.as_mut().unwrap()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Take field
|
|
|
|
pub fn take_old_ticket(&mut self) -> PeerTicketOld {
|
|
|
|
self.old_ticket.take().unwrap_or_else(|| PeerTicketOld::new())
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
impl ::protobuf::Message for PeerTicketUnion {
|
|
|
|
fn is_initialized(&self) -> bool {
|
2018-09-28 10:02:38 +00:00
|
|
|
for v in &self.public_key {
|
|
|
|
if !v.is_initialized() {
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
};
|
|
|
|
for v in &self.old_ticket {
|
|
|
|
if !v.is_initialized() {
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
};
|
2016-11-21 02:48:17 +00:00
|
|
|
true
|
|
|
|
}
|
|
|
|
|
2019-11-06 15:38:30 +00:00
|
|
|
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
|
2017-01-18 05:58:12 +00:00
|
|
|
while !is.eof()? {
|
|
|
|
let (field_number, wire_type) = is.read_tag_unpack()?;
|
2016-11-21 02:48:17 +00:00
|
|
|
match field_number {
|
|
|
|
10 => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.public_key)?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
20 => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.old_ticket)?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
_ => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
};
|
|
|
|
}
|
|
|
|
::std::result::Result::Ok(())
|
|
|
|
}
|
|
|
|
|
|
|
|
// Compute sizes of nested messages
|
|
|
|
#[allow(unused_variables)]
|
|
|
|
fn compute_size(&self) -> u32 {
|
|
|
|
let mut my_size = 0;
|
2018-09-28 10:02:38 +00:00
|
|
|
if let Some(ref v) = self.public_key.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
let len = v.compute_size();
|
2016-11-21 02:48:17 +00:00
|
|
|
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.old_ticket.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
let len = v.compute_size();
|
2016-11-21 02:48:17 +00:00
|
|
|
my_size += 2 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
|
|
|
|
self.cached_size.set(my_size);
|
|
|
|
my_size
|
|
|
|
}
|
|
|
|
|
2019-11-06 15:38:30 +00:00
|
|
|
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
|
2018-09-28 10:02:38 +00:00
|
|
|
if let Some(ref v) = self.public_key.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_tag(10, ::protobuf::wire_format::WireTypeLengthDelimited)?;
|
|
|
|
os.write_raw_varint32(v.get_cached_size())?;
|
|
|
|
v.write_to_with_cached_sizes(os)?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.old_ticket.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_tag(20, ::protobuf::wire_format::WireTypeLengthDelimited)?;
|
|
|
|
os.write_raw_varint32(v.get_cached_size())?;
|
|
|
|
v.write_to_with_cached_sizes(os)?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_unknown_fields(self.get_unknown_fields())?;
|
2016-11-21 02:48:17 +00:00
|
|
|
::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
|
|
|
|
}
|
|
|
|
|
2019-07-27 17:09:03 +00:00
|
|
|
fn as_any(&self) -> &dyn (::std::any::Any) {
|
|
|
|
self as &dyn (::std::any::Any)
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
2019-07-27 17:09:03 +00:00
|
|
|
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
|
|
|
|
self as &mut dyn (::std::any::Any)
|
2017-09-30 22:51:05 +00:00
|
|
|
}
|
2019-07-27 17:09:03 +00:00
|
|
|
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
|
2017-09-30 22:51:05 +00:00
|
|
|
self
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
|
|
|
|
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
|
2018-09-28 10:02:38 +00:00
|
|
|
Self::descriptor_static()
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
fn new() -> PeerTicketUnion {
|
|
|
|
PeerTicketUnion::new()
|
|
|
|
}
|
|
|
|
|
2018-09-28 10:02:38 +00:00
|
|
|
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
|
2016-11-21 02:48:17 +00:00
|
|
|
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();
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<PeerTicketPublicKey>>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"public_key",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &PeerTicketUnion| { &m.public_key },
|
|
|
|
|m: &mut PeerTicketUnion| { &mut m.public_key },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<PeerTicketOld>>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"old_ticket",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &PeerTicketUnion| { &m.old_ticket },
|
|
|
|
|m: &mut PeerTicketUnion| { &mut m.old_ticket },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
|
|
|
::protobuf::reflect::MessageDescriptor::new::<PeerTicketUnion>(
|
|
|
|
"PeerTicketUnion",
|
|
|
|
fields,
|
|
|
|
file_descriptor_proto()
|
|
|
|
)
|
|
|
|
})
|
|
|
|
}
|
|
|
|
}
|
2018-09-28 10:02:38 +00:00
|
|
|
|
|
|
|
fn default_instance() -> &'static PeerTicketUnion {
|
|
|
|
static mut instance: ::protobuf::lazy::Lazy<PeerTicketUnion> = ::protobuf::lazy::Lazy {
|
|
|
|
lock: ::protobuf::lazy::ONCE_INIT,
|
|
|
|
ptr: 0 as *const PeerTicketUnion,
|
|
|
|
};
|
|
|
|
unsafe {
|
|
|
|
instance.get(PeerTicketUnion::new)
|
|
|
|
}
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
impl ::protobuf::Clear for PeerTicketUnion {
|
|
|
|
fn clear(&mut self) {
|
2019-07-18 03:07:27 +00:00
|
|
|
self.public_key.clear();
|
|
|
|
self.old_ticket.clear();
|
2016-11-21 02:48:17 +00:00
|
|
|
self.unknown_fields.clear();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
impl ::std::fmt::Debug for PeerTicketUnion {
|
2019-11-06 15:38:30 +00:00
|
|
|
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
|
2016-11-21 02:48:17 +00:00
|
|
|
::protobuf::text_format::fmt(self, f)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2017-01-18 05:58:12 +00:00
|
|
|
impl ::protobuf::reflect::ProtobufValue for PeerTicketUnion {
|
|
|
|
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
|
|
|
|
::protobuf::reflect::ProtobufValueRef::Message(self)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
#[derive(PartialEq,Clone,Default)]
|
2016-11-21 02:48:17 +00:00
|
|
|
pub struct PeerTicketPublicKey {
|
|
|
|
// message fields
|
|
|
|
public_key: ::protobuf::SingularField<::std::vec::Vec<u8>>,
|
|
|
|
// special fields
|
2019-07-18 03:07:27 +00:00
|
|
|
pub unknown_fields: ::protobuf::UnknownFields,
|
|
|
|
pub cached_size: ::protobuf::CachedSize,
|
|
|
|
}
|
|
|
|
|
|
|
|
impl<'a> ::std::default::Default for &'a PeerTicketPublicKey {
|
|
|
|
fn default() -> &'a PeerTicketPublicKey {
|
|
|
|
<PeerTicketPublicKey as ::protobuf::Message>::default_instance()
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
impl PeerTicketPublicKey {
|
|
|
|
pub fn new() -> PeerTicketPublicKey {
|
|
|
|
::std::default::Default::default()
|
|
|
|
}
|
|
|
|
|
|
|
|
// required bytes public_key = 10;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
|
|
|
|
pub fn get_public_key(&self) -> &[u8] {
|
|
|
|
match self.public_key.as_ref() {
|
|
|
|
Some(v) => &v,
|
|
|
|
None => &[],
|
|
|
|
}
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
pub fn clear_public_key(&mut self) {
|
|
|
|
self.public_key.clear();
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_public_key(&self) -> bool {
|
|
|
|
self.public_key.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_public_key(&mut self, v: ::std::vec::Vec<u8>) {
|
|
|
|
self.public_key = ::protobuf::SingularField::some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// Mutable pointer to the field.
|
|
|
|
// If field is not initialized, it is initialized with default value first.
|
|
|
|
pub fn mut_public_key(&mut self) -> &mut ::std::vec::Vec<u8> {
|
|
|
|
if self.public_key.is_none() {
|
|
|
|
self.public_key.set_default();
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
self.public_key.as_mut().unwrap()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Take field
|
|
|
|
pub fn take_public_key(&mut self) -> ::std::vec::Vec<u8> {
|
|
|
|
self.public_key.take().unwrap_or_else(|| ::std::vec::Vec::new())
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
impl ::protobuf::Message for PeerTicketPublicKey {
|
|
|
|
fn is_initialized(&self) -> bool {
|
|
|
|
if self.public_key.is_none() {
|
|
|
|
return false;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
true
|
|
|
|
}
|
|
|
|
|
2019-11-06 15:38:30 +00:00
|
|
|
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
|
2017-01-18 05:58:12 +00:00
|
|
|
while !is.eof()? {
|
|
|
|
let (field_number, wire_type) = is.read_tag_unpack()?;
|
2016-11-21 02:48:17 +00:00
|
|
|
match field_number {
|
|
|
|
10 => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_singular_bytes_into(wire_type, is, &mut self.public_key)?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
_ => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
};
|
|
|
|
}
|
|
|
|
::std::result::Result::Ok(())
|
|
|
|
}
|
|
|
|
|
|
|
|
// Compute sizes of nested messages
|
|
|
|
#[allow(unused_variables)]
|
|
|
|
fn compute_size(&self) -> u32 {
|
|
|
|
let mut my_size = 0;
|
2018-09-28 10:02:38 +00:00
|
|
|
if let Some(ref v) = self.public_key.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
my_size += ::protobuf::rt::bytes_size(10, &v);
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
|
|
|
|
self.cached_size.set(my_size);
|
|
|
|
my_size
|
|
|
|
}
|
|
|
|
|
2019-11-06 15:38:30 +00:00
|
|
|
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
|
2018-09-28 10:02:38 +00:00
|
|
|
if let Some(ref v) = self.public_key.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_bytes(10, &v)?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_unknown_fields(self.get_unknown_fields())?;
|
2016-11-21 02:48:17 +00:00
|
|
|
::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
|
|
|
|
}
|
|
|
|
|
2019-07-27 17:09:03 +00:00
|
|
|
fn as_any(&self) -> &dyn (::std::any::Any) {
|
|
|
|
self as &dyn (::std::any::Any)
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
2019-07-27 17:09:03 +00:00
|
|
|
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
|
|
|
|
self as &mut dyn (::std::any::Any)
|
2017-09-30 22:51:05 +00:00
|
|
|
}
|
2019-07-27 17:09:03 +00:00
|
|
|
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
|
2017-09-30 22:51:05 +00:00
|
|
|
self
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
|
|
|
|
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
|
2018-09-28 10:02:38 +00:00
|
|
|
Self::descriptor_static()
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
fn new() -> PeerTicketPublicKey {
|
|
|
|
PeerTicketPublicKey::new()
|
|
|
|
}
|
|
|
|
|
2018-09-28 10:02:38 +00:00
|
|
|
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
|
2016-11-21 02:48:17 +00:00
|
|
|
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();
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_singular_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"public_key",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &PeerTicketPublicKey| { &m.public_key },
|
|
|
|
|m: &mut PeerTicketPublicKey| { &mut m.public_key },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
|
|
|
::protobuf::reflect::MessageDescriptor::new::<PeerTicketPublicKey>(
|
|
|
|
"PeerTicketPublicKey",
|
|
|
|
fields,
|
|
|
|
file_descriptor_proto()
|
|
|
|
)
|
|
|
|
})
|
|
|
|
}
|
|
|
|
}
|
2018-09-28 10:02:38 +00:00
|
|
|
|
|
|
|
fn default_instance() -> &'static PeerTicketPublicKey {
|
|
|
|
static mut instance: ::protobuf::lazy::Lazy<PeerTicketPublicKey> = ::protobuf::lazy::Lazy {
|
|
|
|
lock: ::protobuf::lazy::ONCE_INIT,
|
|
|
|
ptr: 0 as *const PeerTicketPublicKey,
|
|
|
|
};
|
|
|
|
unsafe {
|
|
|
|
instance.get(PeerTicketPublicKey::new)
|
|
|
|
}
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
impl ::protobuf::Clear for PeerTicketPublicKey {
|
|
|
|
fn clear(&mut self) {
|
2019-07-18 03:07:27 +00:00
|
|
|
self.public_key.clear();
|
2016-11-21 02:48:17 +00:00
|
|
|
self.unknown_fields.clear();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
impl ::std::fmt::Debug for PeerTicketPublicKey {
|
2019-11-06 15:38:30 +00:00
|
|
|
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
|
2016-11-21 02:48:17 +00:00
|
|
|
::protobuf::text_format::fmt(self, f)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2017-01-18 05:58:12 +00:00
|
|
|
impl ::protobuf::reflect::ProtobufValue for PeerTicketPublicKey {
|
|
|
|
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
|
|
|
|
::protobuf::reflect::ProtobufValueRef::Message(self)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
#[derive(PartialEq,Clone,Default)]
|
2016-11-21 02:48:17 +00:00
|
|
|
pub struct PeerTicketOld {
|
|
|
|
// message fields
|
|
|
|
peer_ticket: ::protobuf::SingularField<::std::vec::Vec<u8>>,
|
|
|
|
peer_ticket_signature: ::protobuf::SingularField<::std::vec::Vec<u8>>,
|
|
|
|
// special fields
|
2019-07-18 03:07:27 +00:00
|
|
|
pub unknown_fields: ::protobuf::UnknownFields,
|
|
|
|
pub cached_size: ::protobuf::CachedSize,
|
|
|
|
}
|
|
|
|
|
|
|
|
impl<'a> ::std::default::Default for &'a PeerTicketOld {
|
|
|
|
fn default() -> &'a PeerTicketOld {
|
|
|
|
<PeerTicketOld as ::protobuf::Message>::default_instance()
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
impl PeerTicketOld {
|
|
|
|
pub fn new() -> PeerTicketOld {
|
|
|
|
::std::default::Default::default()
|
|
|
|
}
|
|
|
|
|
|
|
|
// required bytes peer_ticket = 10;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
|
|
|
|
pub fn get_peer_ticket(&self) -> &[u8] {
|
|
|
|
match self.peer_ticket.as_ref() {
|
|
|
|
Some(v) => &v,
|
|
|
|
None => &[],
|
|
|
|
}
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
pub fn clear_peer_ticket(&mut self) {
|
|
|
|
self.peer_ticket.clear();
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_peer_ticket(&self) -> bool {
|
|
|
|
self.peer_ticket.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_peer_ticket(&mut self, v: ::std::vec::Vec<u8>) {
|
|
|
|
self.peer_ticket = ::protobuf::SingularField::some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// Mutable pointer to the field.
|
|
|
|
// If field is not initialized, it is initialized with default value first.
|
|
|
|
pub fn mut_peer_ticket(&mut self) -> &mut ::std::vec::Vec<u8> {
|
|
|
|
if self.peer_ticket.is_none() {
|
|
|
|
self.peer_ticket.set_default();
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
self.peer_ticket.as_mut().unwrap()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Take field
|
|
|
|
pub fn take_peer_ticket(&mut self) -> ::std::vec::Vec<u8> {
|
|
|
|
self.peer_ticket.take().unwrap_or_else(|| ::std::vec::Vec::new())
|
|
|
|
}
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
// required bytes peer_ticket_signature = 20;
|
|
|
|
|
|
|
|
|
|
|
|
pub fn get_peer_ticket_signature(&self) -> &[u8] {
|
|
|
|
match self.peer_ticket_signature.as_ref() {
|
2016-11-21 02:48:17 +00:00
|
|
|
Some(v) => &v,
|
|
|
|
None => &[],
|
|
|
|
}
|
|
|
|
}
|
|
|
|
pub fn clear_peer_ticket_signature(&mut self) {
|
|
|
|
self.peer_ticket_signature.clear();
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_peer_ticket_signature(&self) -> bool {
|
|
|
|
self.peer_ticket_signature.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_peer_ticket_signature(&mut self, v: ::std::vec::Vec<u8>) {
|
|
|
|
self.peer_ticket_signature = ::protobuf::SingularField::some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// Mutable pointer to the field.
|
|
|
|
// If field is not initialized, it is initialized with default value first.
|
|
|
|
pub fn mut_peer_ticket_signature(&mut self) -> &mut ::std::vec::Vec<u8> {
|
|
|
|
if self.peer_ticket_signature.is_none() {
|
|
|
|
self.peer_ticket_signature.set_default();
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
self.peer_ticket_signature.as_mut().unwrap()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Take field
|
|
|
|
pub fn take_peer_ticket_signature(&mut self) -> ::std::vec::Vec<u8> {
|
|
|
|
self.peer_ticket_signature.take().unwrap_or_else(|| ::std::vec::Vec::new())
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
impl ::protobuf::Message for PeerTicketOld {
|
|
|
|
fn is_initialized(&self) -> bool {
|
|
|
|
if self.peer_ticket.is_none() {
|
|
|
|
return false;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
if self.peer_ticket_signature.is_none() {
|
|
|
|
return false;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
true
|
|
|
|
}
|
|
|
|
|
2019-11-06 15:38:30 +00:00
|
|
|
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
|
2017-01-18 05:58:12 +00:00
|
|
|
while !is.eof()? {
|
|
|
|
let (field_number, wire_type) = is.read_tag_unpack()?;
|
2016-11-21 02:48:17 +00:00
|
|
|
match field_number {
|
|
|
|
10 => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_singular_bytes_into(wire_type, is, &mut self.peer_ticket)?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
20 => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_singular_bytes_into(wire_type, is, &mut self.peer_ticket_signature)?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
_ => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
};
|
|
|
|
}
|
|
|
|
::std::result::Result::Ok(())
|
|
|
|
}
|
|
|
|
|
|
|
|
// Compute sizes of nested messages
|
|
|
|
#[allow(unused_variables)]
|
|
|
|
fn compute_size(&self) -> u32 {
|
|
|
|
let mut my_size = 0;
|
2018-09-28 10:02:38 +00:00
|
|
|
if let Some(ref v) = self.peer_ticket.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
my_size += ::protobuf::rt::bytes_size(10, &v);
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.peer_ticket_signature.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
my_size += ::protobuf::rt::bytes_size(20, &v);
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
|
|
|
|
self.cached_size.set(my_size);
|
|
|
|
my_size
|
|
|
|
}
|
|
|
|
|
2019-11-06 15:38:30 +00:00
|
|
|
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
|
2018-09-28 10:02:38 +00:00
|
|
|
if let Some(ref v) = self.peer_ticket.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_bytes(10, &v)?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.peer_ticket_signature.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_bytes(20, &v)?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_unknown_fields(self.get_unknown_fields())?;
|
2016-11-21 02:48:17 +00:00
|
|
|
::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
|
|
|
|
}
|
|
|
|
|
2019-07-27 17:09:03 +00:00
|
|
|
fn as_any(&self) -> &dyn (::std::any::Any) {
|
|
|
|
self as &dyn (::std::any::Any)
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
2019-07-27 17:09:03 +00:00
|
|
|
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
|
|
|
|
self as &mut dyn (::std::any::Any)
|
2017-09-30 22:51:05 +00:00
|
|
|
}
|
2019-07-27 17:09:03 +00:00
|
|
|
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
|
2017-09-30 22:51:05 +00:00
|
|
|
self
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
|
|
|
|
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
|
2018-09-28 10:02:38 +00:00
|
|
|
Self::descriptor_static()
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
fn new() -> PeerTicketOld {
|
|
|
|
PeerTicketOld::new()
|
|
|
|
}
|
|
|
|
|
2018-09-28 10:02:38 +00:00
|
|
|
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
|
2016-11-21 02:48:17 +00:00
|
|
|
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();
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_singular_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"peer_ticket",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &PeerTicketOld| { &m.peer_ticket },
|
|
|
|
|m: &mut PeerTicketOld| { &mut m.peer_ticket },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_singular_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"peer_ticket_signature",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &PeerTicketOld| { &m.peer_ticket_signature },
|
|
|
|
|m: &mut PeerTicketOld| { &mut m.peer_ticket_signature },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
|
|
|
::protobuf::reflect::MessageDescriptor::new::<PeerTicketOld>(
|
|
|
|
"PeerTicketOld",
|
|
|
|
fields,
|
|
|
|
file_descriptor_proto()
|
|
|
|
)
|
|
|
|
})
|
|
|
|
}
|
|
|
|
}
|
2018-09-28 10:02:38 +00:00
|
|
|
|
|
|
|
fn default_instance() -> &'static PeerTicketOld {
|
|
|
|
static mut instance: ::protobuf::lazy::Lazy<PeerTicketOld> = ::protobuf::lazy::Lazy {
|
|
|
|
lock: ::protobuf::lazy::ONCE_INIT,
|
|
|
|
ptr: 0 as *const PeerTicketOld,
|
|
|
|
};
|
|
|
|
unsafe {
|
|
|
|
instance.get(PeerTicketOld::new)
|
|
|
|
}
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
impl ::protobuf::Clear for PeerTicketOld {
|
|
|
|
fn clear(&mut self) {
|
2019-07-18 03:07:27 +00:00
|
|
|
self.peer_ticket.clear();
|
|
|
|
self.peer_ticket_signature.clear();
|
2016-11-21 02:48:17 +00:00
|
|
|
self.unknown_fields.clear();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
impl ::std::fmt::Debug for PeerTicketOld {
|
2019-11-06 15:38:30 +00:00
|
|
|
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
|
2016-11-21 02:48:17 +00:00
|
|
|
::protobuf::text_format::fmt(self, f)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2017-01-18 05:58:12 +00:00
|
|
|
impl ::protobuf::reflect::ProtobufValue for PeerTicketOld {
|
|
|
|
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
|
|
|
|
::protobuf::reflect::ProtobufValueRef::Message(self)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
#[derive(PartialEq,Clone,Default)]
|
2016-11-21 02:48:17 +00:00
|
|
|
pub struct SystemInfo {
|
|
|
|
// message fields
|
|
|
|
cpu_family: ::std::option::Option<CpuFamily>,
|
|
|
|
cpu_subtype: ::std::option::Option<u32>,
|
|
|
|
cpu_ext: ::std::option::Option<u32>,
|
|
|
|
brand: ::std::option::Option<Brand>,
|
|
|
|
brand_flags: ::std::option::Option<u32>,
|
|
|
|
os: ::std::option::Option<Os>,
|
|
|
|
os_version: ::std::option::Option<u32>,
|
|
|
|
os_ext: ::std::option::Option<u32>,
|
|
|
|
system_information_string: ::protobuf::SingularField<::std::string::String>,
|
|
|
|
device_id: ::protobuf::SingularField<::std::string::String>,
|
|
|
|
// special fields
|
2019-07-18 03:07:27 +00:00
|
|
|
pub unknown_fields: ::protobuf::UnknownFields,
|
|
|
|
pub cached_size: ::protobuf::CachedSize,
|
|
|
|
}
|
|
|
|
|
|
|
|
impl<'a> ::std::default::Default for &'a SystemInfo {
|
|
|
|
fn default() -> &'a SystemInfo {
|
|
|
|
<SystemInfo as ::protobuf::Message>::default_instance()
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
impl SystemInfo {
|
|
|
|
pub fn new() -> SystemInfo {
|
|
|
|
::std::default::Default::default()
|
|
|
|
}
|
|
|
|
|
|
|
|
// required .CpuFamily cpu_family = 10;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
|
|
|
|
pub fn get_cpu_family(&self) -> CpuFamily {
|
|
|
|
self.cpu_family.unwrap_or(CpuFamily::CPU_UNKNOWN)
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
pub fn clear_cpu_family(&mut self) {
|
|
|
|
self.cpu_family = ::std::option::Option::None;
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_cpu_family(&self) -> bool {
|
|
|
|
self.cpu_family.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_cpu_family(&mut self, v: CpuFamily) {
|
|
|
|
self.cpu_family = ::std::option::Option::Some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// optional uint32 cpu_subtype = 20;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
|
|
|
|
pub fn get_cpu_subtype(&self) -> u32 {
|
|
|
|
self.cpu_subtype.unwrap_or(0)
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
pub fn clear_cpu_subtype(&mut self) {
|
|
|
|
self.cpu_subtype = ::std::option::Option::None;
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_cpu_subtype(&self) -> bool {
|
|
|
|
self.cpu_subtype.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_cpu_subtype(&mut self, v: u32) {
|
|
|
|
self.cpu_subtype = ::std::option::Option::Some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// optional uint32 cpu_ext = 30;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
|
|
|
|
pub fn get_cpu_ext(&self) -> u32 {
|
|
|
|
self.cpu_ext.unwrap_or(0)
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
pub fn clear_cpu_ext(&mut self) {
|
|
|
|
self.cpu_ext = ::std::option::Option::None;
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_cpu_ext(&self) -> bool {
|
|
|
|
self.cpu_ext.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_cpu_ext(&mut self, v: u32) {
|
|
|
|
self.cpu_ext = ::std::option::Option::Some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// optional .Brand brand = 40;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
|
|
|
|
pub fn get_brand(&self) -> Brand {
|
|
|
|
self.brand.unwrap_or(Brand::BRAND_UNBRANDED)
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
pub fn clear_brand(&mut self) {
|
|
|
|
self.brand = ::std::option::Option::None;
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_brand(&self) -> bool {
|
|
|
|
self.brand.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_brand(&mut self, v: Brand) {
|
|
|
|
self.brand = ::std::option::Option::Some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// optional uint32 brand_flags = 50;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
|
|
|
|
pub fn get_brand_flags(&self) -> u32 {
|
|
|
|
self.brand_flags.unwrap_or(0)
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
pub fn clear_brand_flags(&mut self) {
|
|
|
|
self.brand_flags = ::std::option::Option::None;
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_brand_flags(&self) -> bool {
|
|
|
|
self.brand_flags.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_brand_flags(&mut self, v: u32) {
|
|
|
|
self.brand_flags = ::std::option::Option::Some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// required .Os os = 60;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
|
|
|
|
pub fn get_os(&self) -> Os {
|
|
|
|
self.os.unwrap_or(Os::OS_UNKNOWN)
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
pub fn clear_os(&mut self) {
|
|
|
|
self.os = ::std::option::Option::None;
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_os(&self) -> bool {
|
|
|
|
self.os.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_os(&mut self, v: Os) {
|
|
|
|
self.os = ::std::option::Option::Some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// optional uint32 os_version = 70;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
|
|
|
|
pub fn get_os_version(&self) -> u32 {
|
|
|
|
self.os_version.unwrap_or(0)
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
pub fn clear_os_version(&mut self) {
|
|
|
|
self.os_version = ::std::option::Option::None;
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_os_version(&self) -> bool {
|
|
|
|
self.os_version.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_os_version(&mut self, v: u32) {
|
|
|
|
self.os_version = ::std::option::Option::Some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// optional uint32 os_ext = 80;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
|
|
|
|
pub fn get_os_ext(&self) -> u32 {
|
|
|
|
self.os_ext.unwrap_or(0)
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
pub fn clear_os_ext(&mut self) {
|
|
|
|
self.os_ext = ::std::option::Option::None;
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_os_ext(&self) -> bool {
|
|
|
|
self.os_ext.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_os_ext(&mut self, v: u32) {
|
|
|
|
self.os_ext = ::std::option::Option::Some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// optional string system_information_string = 90;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
|
|
|
|
pub fn get_system_information_string(&self) -> &str {
|
|
|
|
match self.system_information_string.as_ref() {
|
|
|
|
Some(v) => &v,
|
|
|
|
None => "",
|
|
|
|
}
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
pub fn clear_system_information_string(&mut self) {
|
|
|
|
self.system_information_string.clear();
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_system_information_string(&self) -> bool {
|
|
|
|
self.system_information_string.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_system_information_string(&mut self, v: ::std::string::String) {
|
|
|
|
self.system_information_string = ::protobuf::SingularField::some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// Mutable pointer to the field.
|
|
|
|
// If field is not initialized, it is initialized with default value first.
|
|
|
|
pub fn mut_system_information_string(&mut self) -> &mut ::std::string::String {
|
|
|
|
if self.system_information_string.is_none() {
|
|
|
|
self.system_information_string.set_default();
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
self.system_information_string.as_mut().unwrap()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Take field
|
|
|
|
pub fn take_system_information_string(&mut self) -> ::std::string::String {
|
|
|
|
self.system_information_string.take().unwrap_or_else(|| ::std::string::String::new())
|
|
|
|
}
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
// optional string device_id = 100;
|
|
|
|
|
|
|
|
|
|
|
|
pub fn get_device_id(&self) -> &str {
|
|
|
|
match self.device_id.as_ref() {
|
2016-11-21 02:48:17 +00:00
|
|
|
Some(v) => &v,
|
|
|
|
None => "",
|
|
|
|
}
|
|
|
|
}
|
|
|
|
pub fn clear_device_id(&mut self) {
|
|
|
|
self.device_id.clear();
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_device_id(&self) -> bool {
|
|
|
|
self.device_id.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_device_id(&mut self, v: ::std::string::String) {
|
|
|
|
self.device_id = ::protobuf::SingularField::some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// Mutable pointer to the field.
|
|
|
|
// If field is not initialized, it is initialized with default value first.
|
|
|
|
pub fn mut_device_id(&mut self) -> &mut ::std::string::String {
|
|
|
|
if self.device_id.is_none() {
|
|
|
|
self.device_id.set_default();
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
self.device_id.as_mut().unwrap()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Take field
|
|
|
|
pub fn take_device_id(&mut self) -> ::std::string::String {
|
|
|
|
self.device_id.take().unwrap_or_else(|| ::std::string::String::new())
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
impl ::protobuf::Message for SystemInfo {
|
|
|
|
fn is_initialized(&self) -> bool {
|
|
|
|
if self.cpu_family.is_none() {
|
|
|
|
return false;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
if self.os.is_none() {
|
|
|
|
return false;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
true
|
|
|
|
}
|
|
|
|
|
2019-11-06 15:38:30 +00:00
|
|
|
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
|
2017-01-18 05:58:12 +00:00
|
|
|
while !is.eof()? {
|
|
|
|
let (field_number, wire_type) = is.read_tag_unpack()?;
|
2016-11-21 02:48:17 +00:00
|
|
|
match field_number {
|
|
|
|
10 => {
|
2018-09-28 10:02:38 +00:00
|
|
|
::protobuf::rt::read_proto2_enum_with_unknown_fields_into(wire_type, is, &mut self.cpu_family, 10, &mut self.unknown_fields)?
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
20 => {
|
|
|
|
if wire_type != ::protobuf::wire_format::WireTypeVarint {
|
|
|
|
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2017-01-18 05:58:12 +00:00
|
|
|
let tmp = is.read_uint32()?;
|
2016-11-21 02:48:17 +00:00
|
|
|
self.cpu_subtype = ::std::option::Option::Some(tmp);
|
|
|
|
},
|
|
|
|
30 => {
|
|
|
|
if wire_type != ::protobuf::wire_format::WireTypeVarint {
|
|
|
|
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2017-01-18 05:58:12 +00:00
|
|
|
let tmp = is.read_uint32()?;
|
2016-11-21 02:48:17 +00:00
|
|
|
self.cpu_ext = ::std::option::Option::Some(tmp);
|
|
|
|
},
|
|
|
|
40 => {
|
2018-09-28 10:02:38 +00:00
|
|
|
::protobuf::rt::read_proto2_enum_with_unknown_fields_into(wire_type, is, &mut self.brand, 40, &mut self.unknown_fields)?
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
50 => {
|
|
|
|
if wire_type != ::protobuf::wire_format::WireTypeVarint {
|
|
|
|
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2017-01-18 05:58:12 +00:00
|
|
|
let tmp = is.read_uint32()?;
|
2016-11-21 02:48:17 +00:00
|
|
|
self.brand_flags = ::std::option::Option::Some(tmp);
|
|
|
|
},
|
|
|
|
60 => {
|
2018-09-28 10:02:38 +00:00
|
|
|
::protobuf::rt::read_proto2_enum_with_unknown_fields_into(wire_type, is, &mut self.os, 60, &mut self.unknown_fields)?
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
70 => {
|
|
|
|
if wire_type != ::protobuf::wire_format::WireTypeVarint {
|
|
|
|
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2017-01-18 05:58:12 +00:00
|
|
|
let tmp = is.read_uint32()?;
|
2016-11-21 02:48:17 +00:00
|
|
|
self.os_version = ::std::option::Option::Some(tmp);
|
|
|
|
},
|
|
|
|
80 => {
|
|
|
|
if wire_type != ::protobuf::wire_format::WireTypeVarint {
|
|
|
|
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2017-01-18 05:58:12 +00:00
|
|
|
let tmp = is.read_uint32()?;
|
2016-11-21 02:48:17 +00:00
|
|
|
self.os_ext = ::std::option::Option::Some(tmp);
|
|
|
|
},
|
|
|
|
90 => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_singular_string_into(wire_type, is, &mut self.system_information_string)?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
100 => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_singular_string_into(wire_type, is, &mut self.device_id)?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
_ => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
};
|
|
|
|
}
|
|
|
|
::std::result::Result::Ok(())
|
|
|
|
}
|
|
|
|
|
|
|
|
// Compute sizes of nested messages
|
|
|
|
#[allow(unused_variables)]
|
|
|
|
fn compute_size(&self) -> u32 {
|
|
|
|
let mut my_size = 0;
|
2017-01-18 05:58:12 +00:00
|
|
|
if let Some(v) = self.cpu_family {
|
|
|
|
my_size += ::protobuf::rt::enum_size(10, v);
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2017-01-18 05:58:12 +00:00
|
|
|
if let Some(v) = self.cpu_subtype {
|
|
|
|
my_size += ::protobuf::rt::value_size(20, v, ::protobuf::wire_format::WireTypeVarint);
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2017-01-18 05:58:12 +00:00
|
|
|
if let Some(v) = self.cpu_ext {
|
|
|
|
my_size += ::protobuf::rt::value_size(30, v, ::protobuf::wire_format::WireTypeVarint);
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2017-01-18 05:58:12 +00:00
|
|
|
if let Some(v) = self.brand {
|
|
|
|
my_size += ::protobuf::rt::enum_size(40, v);
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2017-01-18 05:58:12 +00:00
|
|
|
if let Some(v) = self.brand_flags {
|
|
|
|
my_size += ::protobuf::rt::value_size(50, v, ::protobuf::wire_format::WireTypeVarint);
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2017-01-18 05:58:12 +00:00
|
|
|
if let Some(v) = self.os {
|
|
|
|
my_size += ::protobuf::rt::enum_size(60, v);
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2017-01-18 05:58:12 +00:00
|
|
|
if let Some(v) = self.os_version {
|
|
|
|
my_size += ::protobuf::rt::value_size(70, v, ::protobuf::wire_format::WireTypeVarint);
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2017-01-18 05:58:12 +00:00
|
|
|
if let Some(v) = self.os_ext {
|
|
|
|
my_size += ::protobuf::rt::value_size(80, v, ::protobuf::wire_format::WireTypeVarint);
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.system_information_string.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
my_size += ::protobuf::rt::string_size(90, &v);
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.device_id.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
my_size += ::protobuf::rt::string_size(100, &v);
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
|
|
|
|
self.cached_size.set(my_size);
|
|
|
|
my_size
|
|
|
|
}
|
|
|
|
|
2019-11-06 15:38:30 +00:00
|
|
|
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
|
2016-11-21 02:48:17 +00:00
|
|
|
if let Some(v) = self.cpu_family {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_enum(10, v.value())?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
if let Some(v) = self.cpu_subtype {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_uint32(20, v)?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
if let Some(v) = self.cpu_ext {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_uint32(30, v)?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
if let Some(v) = self.brand {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_enum(40, v.value())?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
if let Some(v) = self.brand_flags {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_uint32(50, v)?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
if let Some(v) = self.os {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_enum(60, v.value())?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
if let Some(v) = self.os_version {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_uint32(70, v)?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
if let Some(v) = self.os_ext {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_uint32(80, v)?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.system_information_string.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_string(90, &v)?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.device_id.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_string(100, &v)?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_unknown_fields(self.get_unknown_fields())?;
|
2016-11-21 02:48:17 +00:00
|
|
|
::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
|
|
|
|
}
|
|
|
|
|
2019-07-27 17:09:03 +00:00
|
|
|
fn as_any(&self) -> &dyn (::std::any::Any) {
|
|
|
|
self as &dyn (::std::any::Any)
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
2019-07-27 17:09:03 +00:00
|
|
|
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
|
|
|
|
self as &mut dyn (::std::any::Any)
|
2017-09-30 22:51:05 +00:00
|
|
|
}
|
2019-07-27 17:09:03 +00:00
|
|
|
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
|
2017-09-30 22:51:05 +00:00
|
|
|
self
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
|
|
|
|
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
|
2018-09-28 10:02:38 +00:00
|
|
|
Self::descriptor_static()
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
fn new() -> SystemInfo {
|
|
|
|
SystemInfo::new()
|
|
|
|
}
|
|
|
|
|
2018-09-28 10:02:38 +00:00
|
|
|
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
|
2016-11-21 02:48:17 +00:00
|
|
|
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();
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_option_accessor::<_, ::protobuf::types::ProtobufTypeEnum<CpuFamily>>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"cpu_family",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &SystemInfo| { &m.cpu_family },
|
|
|
|
|m: &mut SystemInfo| { &mut m.cpu_family },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_option_accessor::<_, ::protobuf::types::ProtobufTypeUint32>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"cpu_subtype",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &SystemInfo| { &m.cpu_subtype },
|
|
|
|
|m: &mut SystemInfo| { &mut m.cpu_subtype },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_option_accessor::<_, ::protobuf::types::ProtobufTypeUint32>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"cpu_ext",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &SystemInfo| { &m.cpu_ext },
|
|
|
|
|m: &mut SystemInfo| { &mut m.cpu_ext },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_option_accessor::<_, ::protobuf::types::ProtobufTypeEnum<Brand>>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"brand",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &SystemInfo| { &m.brand },
|
|
|
|
|m: &mut SystemInfo| { &mut m.brand },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_option_accessor::<_, ::protobuf::types::ProtobufTypeUint32>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"brand_flags",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &SystemInfo| { &m.brand_flags },
|
|
|
|
|m: &mut SystemInfo| { &mut m.brand_flags },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_option_accessor::<_, ::protobuf::types::ProtobufTypeEnum<Os>>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"os",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &SystemInfo| { &m.os },
|
|
|
|
|m: &mut SystemInfo| { &mut m.os },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_option_accessor::<_, ::protobuf::types::ProtobufTypeUint32>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"os_version",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &SystemInfo| { &m.os_version },
|
|
|
|
|m: &mut SystemInfo| { &mut m.os_version },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_option_accessor::<_, ::protobuf::types::ProtobufTypeUint32>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"os_ext",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &SystemInfo| { &m.os_ext },
|
|
|
|
|m: &mut SystemInfo| { &mut m.os_ext },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_singular_field_accessor::<_, ::protobuf::types::ProtobufTypeString>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"system_information_string",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &SystemInfo| { &m.system_information_string },
|
|
|
|
|m: &mut SystemInfo| { &mut m.system_information_string },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_singular_field_accessor::<_, ::protobuf::types::ProtobufTypeString>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"device_id",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &SystemInfo| { &m.device_id },
|
|
|
|
|m: &mut SystemInfo| { &mut m.device_id },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
|
|
|
::protobuf::reflect::MessageDescriptor::new::<SystemInfo>(
|
|
|
|
"SystemInfo",
|
|
|
|
fields,
|
|
|
|
file_descriptor_proto()
|
|
|
|
)
|
|
|
|
})
|
|
|
|
}
|
|
|
|
}
|
2018-09-28 10:02:38 +00:00
|
|
|
|
|
|
|
fn default_instance() -> &'static SystemInfo {
|
|
|
|
static mut instance: ::protobuf::lazy::Lazy<SystemInfo> = ::protobuf::lazy::Lazy {
|
|
|
|
lock: ::protobuf::lazy::ONCE_INIT,
|
|
|
|
ptr: 0 as *const SystemInfo,
|
|
|
|
};
|
|
|
|
unsafe {
|
|
|
|
instance.get(SystemInfo::new)
|
|
|
|
}
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
impl ::protobuf::Clear for SystemInfo {
|
|
|
|
fn clear(&mut self) {
|
2019-07-18 03:07:27 +00:00
|
|
|
self.cpu_family = ::std::option::Option::None;
|
|
|
|
self.cpu_subtype = ::std::option::Option::None;
|
|
|
|
self.cpu_ext = ::std::option::Option::None;
|
|
|
|
self.brand = ::std::option::Option::None;
|
|
|
|
self.brand_flags = ::std::option::Option::None;
|
|
|
|
self.os = ::std::option::Option::None;
|
|
|
|
self.os_version = ::std::option::Option::None;
|
|
|
|
self.os_ext = ::std::option::Option::None;
|
|
|
|
self.system_information_string.clear();
|
|
|
|
self.device_id.clear();
|
2016-11-21 02:48:17 +00:00
|
|
|
self.unknown_fields.clear();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
impl ::std::fmt::Debug for SystemInfo {
|
2019-11-06 15:38:30 +00:00
|
|
|
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
|
2016-11-21 02:48:17 +00:00
|
|
|
::protobuf::text_format::fmt(self, f)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2017-01-18 05:58:12 +00:00
|
|
|
impl ::protobuf::reflect::ProtobufValue for SystemInfo {
|
|
|
|
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
|
|
|
|
::protobuf::reflect::ProtobufValueRef::Message(self)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
#[derive(PartialEq,Clone,Default)]
|
2016-11-21 02:48:17 +00:00
|
|
|
pub struct LibspotifyAppKey {
|
|
|
|
// message fields
|
|
|
|
version: ::std::option::Option<u32>,
|
|
|
|
devkey: ::protobuf::SingularField<::std::vec::Vec<u8>>,
|
|
|
|
signature: ::protobuf::SingularField<::std::vec::Vec<u8>>,
|
|
|
|
useragent: ::protobuf::SingularField<::std::string::String>,
|
|
|
|
callback_hash: ::protobuf::SingularField<::std::vec::Vec<u8>>,
|
|
|
|
// special fields
|
2019-07-18 03:07:27 +00:00
|
|
|
pub unknown_fields: ::protobuf::UnknownFields,
|
|
|
|
pub cached_size: ::protobuf::CachedSize,
|
|
|
|
}
|
|
|
|
|
|
|
|
impl<'a> ::std::default::Default for &'a LibspotifyAppKey {
|
|
|
|
fn default() -> &'a LibspotifyAppKey {
|
|
|
|
<LibspotifyAppKey as ::protobuf::Message>::default_instance()
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
impl LibspotifyAppKey {
|
|
|
|
pub fn new() -> LibspotifyAppKey {
|
|
|
|
::std::default::Default::default()
|
|
|
|
}
|
|
|
|
|
|
|
|
// required uint32 version = 1;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
|
|
|
|
pub fn get_version(&self) -> u32 {
|
|
|
|
self.version.unwrap_or(0)
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
pub fn clear_version(&mut self) {
|
|
|
|
self.version = ::std::option::Option::None;
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_version(&self) -> bool {
|
|
|
|
self.version.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_version(&mut self, v: u32) {
|
|
|
|
self.version = ::std::option::Option::Some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// required bytes devkey = 2;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
|
|
|
|
pub fn get_devkey(&self) -> &[u8] {
|
|
|
|
match self.devkey.as_ref() {
|
|
|
|
Some(v) => &v,
|
|
|
|
None => &[],
|
|
|
|
}
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
pub fn clear_devkey(&mut self) {
|
|
|
|
self.devkey.clear();
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_devkey(&self) -> bool {
|
|
|
|
self.devkey.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_devkey(&mut self, v: ::std::vec::Vec<u8>) {
|
|
|
|
self.devkey = ::protobuf::SingularField::some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// Mutable pointer to the field.
|
|
|
|
// If field is not initialized, it is initialized with default value first.
|
|
|
|
pub fn mut_devkey(&mut self) -> &mut ::std::vec::Vec<u8> {
|
|
|
|
if self.devkey.is_none() {
|
|
|
|
self.devkey.set_default();
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
self.devkey.as_mut().unwrap()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Take field
|
|
|
|
pub fn take_devkey(&mut self) -> ::std::vec::Vec<u8> {
|
|
|
|
self.devkey.take().unwrap_or_else(|| ::std::vec::Vec::new())
|
|
|
|
}
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
// required bytes signature = 3;
|
|
|
|
|
|
|
|
|
|
|
|
pub fn get_signature(&self) -> &[u8] {
|
|
|
|
match self.signature.as_ref() {
|
2016-11-21 02:48:17 +00:00
|
|
|
Some(v) => &v,
|
|
|
|
None => &[],
|
|
|
|
}
|
|
|
|
}
|
|
|
|
pub fn clear_signature(&mut self) {
|
|
|
|
self.signature.clear();
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_signature(&self) -> bool {
|
|
|
|
self.signature.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_signature(&mut self, v: ::std::vec::Vec<u8>) {
|
|
|
|
self.signature = ::protobuf::SingularField::some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// Mutable pointer to the field.
|
|
|
|
// If field is not initialized, it is initialized with default value first.
|
|
|
|
pub fn mut_signature(&mut self) -> &mut ::std::vec::Vec<u8> {
|
|
|
|
if self.signature.is_none() {
|
|
|
|
self.signature.set_default();
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
self.signature.as_mut().unwrap()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Take field
|
|
|
|
pub fn take_signature(&mut self) -> ::std::vec::Vec<u8> {
|
|
|
|
self.signature.take().unwrap_or_else(|| ::std::vec::Vec::new())
|
|
|
|
}
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
// required string useragent = 4;
|
|
|
|
|
|
|
|
|
|
|
|
pub fn get_useragent(&self) -> &str {
|
|
|
|
match self.useragent.as_ref() {
|
2016-11-21 02:48:17 +00:00
|
|
|
Some(v) => &v,
|
2019-07-18 03:07:27 +00:00
|
|
|
None => "",
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
pub fn clear_useragent(&mut self) {
|
|
|
|
self.useragent.clear();
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_useragent(&self) -> bool {
|
|
|
|
self.useragent.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_useragent(&mut self, v: ::std::string::String) {
|
|
|
|
self.useragent = ::protobuf::SingularField::some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// Mutable pointer to the field.
|
|
|
|
// If field is not initialized, it is initialized with default value first.
|
|
|
|
pub fn mut_useragent(&mut self) -> &mut ::std::string::String {
|
|
|
|
if self.useragent.is_none() {
|
|
|
|
self.useragent.set_default();
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
self.useragent.as_mut().unwrap()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Take field
|
|
|
|
pub fn take_useragent(&mut self) -> ::std::string::String {
|
|
|
|
self.useragent.take().unwrap_or_else(|| ::std::string::String::new())
|
|
|
|
}
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
// required bytes callback_hash = 5;
|
|
|
|
|
|
|
|
|
|
|
|
pub fn get_callback_hash(&self) -> &[u8] {
|
|
|
|
match self.callback_hash.as_ref() {
|
2016-11-21 02:48:17 +00:00
|
|
|
Some(v) => &v,
|
2019-07-18 03:07:27 +00:00
|
|
|
None => &[],
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
pub fn clear_callback_hash(&mut self) {
|
|
|
|
self.callback_hash.clear();
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_callback_hash(&self) -> bool {
|
|
|
|
self.callback_hash.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_callback_hash(&mut self, v: ::std::vec::Vec<u8>) {
|
|
|
|
self.callback_hash = ::protobuf::SingularField::some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// Mutable pointer to the field.
|
|
|
|
// If field is not initialized, it is initialized with default value first.
|
|
|
|
pub fn mut_callback_hash(&mut self) -> &mut ::std::vec::Vec<u8> {
|
|
|
|
if self.callback_hash.is_none() {
|
|
|
|
self.callback_hash.set_default();
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
self.callback_hash.as_mut().unwrap()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Take field
|
|
|
|
pub fn take_callback_hash(&mut self) -> ::std::vec::Vec<u8> {
|
|
|
|
self.callback_hash.take().unwrap_or_else(|| ::std::vec::Vec::new())
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
impl ::protobuf::Message for LibspotifyAppKey {
|
|
|
|
fn is_initialized(&self) -> bool {
|
|
|
|
if self.version.is_none() {
|
|
|
|
return false;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
if self.devkey.is_none() {
|
|
|
|
return false;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
if self.signature.is_none() {
|
|
|
|
return false;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
if self.useragent.is_none() {
|
|
|
|
return false;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
if self.callback_hash.is_none() {
|
|
|
|
return false;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
true
|
|
|
|
}
|
|
|
|
|
2019-11-06 15:38:30 +00:00
|
|
|
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
|
2017-01-18 05:58:12 +00:00
|
|
|
while !is.eof()? {
|
|
|
|
let (field_number, wire_type) = is.read_tag_unpack()?;
|
2016-11-21 02:48:17 +00:00
|
|
|
match field_number {
|
|
|
|
1 => {
|
|
|
|
if wire_type != ::protobuf::wire_format::WireTypeVarint {
|
|
|
|
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2017-01-18 05:58:12 +00:00
|
|
|
let tmp = is.read_uint32()?;
|
2016-11-21 02:48:17 +00:00
|
|
|
self.version = ::std::option::Option::Some(tmp);
|
|
|
|
},
|
|
|
|
2 => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_singular_bytes_into(wire_type, is, &mut self.devkey)?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
3 => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_singular_bytes_into(wire_type, is, &mut self.signature)?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
4 => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_singular_string_into(wire_type, is, &mut self.useragent)?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
5 => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_singular_bytes_into(wire_type, is, &mut self.callback_hash)?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
_ => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
};
|
|
|
|
}
|
|
|
|
::std::result::Result::Ok(())
|
|
|
|
}
|
|
|
|
|
|
|
|
// Compute sizes of nested messages
|
|
|
|
#[allow(unused_variables)]
|
|
|
|
fn compute_size(&self) -> u32 {
|
|
|
|
let mut my_size = 0;
|
2017-01-18 05:58:12 +00:00
|
|
|
if let Some(v) = self.version {
|
|
|
|
my_size += ::protobuf::rt::value_size(1, v, ::protobuf::wire_format::WireTypeVarint);
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.devkey.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
my_size += ::protobuf::rt::bytes_size(2, &v);
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.signature.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
my_size += ::protobuf::rt::bytes_size(3, &v);
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.useragent.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
my_size += ::protobuf::rt::string_size(4, &v);
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.callback_hash.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
my_size += ::protobuf::rt::bytes_size(5, &v);
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
|
|
|
|
self.cached_size.set(my_size);
|
|
|
|
my_size
|
|
|
|
}
|
|
|
|
|
2019-11-06 15:38:30 +00:00
|
|
|
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
|
2016-11-21 02:48:17 +00:00
|
|
|
if let Some(v) = self.version {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_uint32(1, v)?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.devkey.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_bytes(2, &v)?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.signature.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_bytes(3, &v)?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.useragent.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_string(4, &v)?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.callback_hash.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_bytes(5, &v)?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_unknown_fields(self.get_unknown_fields())?;
|
2016-11-21 02:48:17 +00:00
|
|
|
::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
|
|
|
|
}
|
|
|
|
|
2019-07-27 17:09:03 +00:00
|
|
|
fn as_any(&self) -> &dyn (::std::any::Any) {
|
|
|
|
self as &dyn (::std::any::Any)
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
2019-07-27 17:09:03 +00:00
|
|
|
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
|
|
|
|
self as &mut dyn (::std::any::Any)
|
2017-09-30 22:51:05 +00:00
|
|
|
}
|
2019-07-27 17:09:03 +00:00
|
|
|
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
|
2017-09-30 22:51:05 +00:00
|
|
|
self
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
|
|
|
|
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
|
2018-09-28 10:02:38 +00:00
|
|
|
Self::descriptor_static()
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
fn new() -> LibspotifyAppKey {
|
|
|
|
LibspotifyAppKey::new()
|
|
|
|
}
|
|
|
|
|
2018-09-28 10:02:38 +00:00
|
|
|
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
|
2016-11-21 02:48:17 +00:00
|
|
|
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();
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_option_accessor::<_, ::protobuf::types::ProtobufTypeUint32>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"version",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &LibspotifyAppKey| { &m.version },
|
|
|
|
|m: &mut LibspotifyAppKey| { &mut m.version },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_singular_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"devkey",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &LibspotifyAppKey| { &m.devkey },
|
|
|
|
|m: &mut LibspotifyAppKey| { &mut m.devkey },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_singular_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"signature",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &LibspotifyAppKey| { &m.signature },
|
|
|
|
|m: &mut LibspotifyAppKey| { &mut m.signature },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_singular_field_accessor::<_, ::protobuf::types::ProtobufTypeString>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"useragent",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &LibspotifyAppKey| { &m.useragent },
|
|
|
|
|m: &mut LibspotifyAppKey| { &mut m.useragent },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_singular_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"callback_hash",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &LibspotifyAppKey| { &m.callback_hash },
|
|
|
|
|m: &mut LibspotifyAppKey| { &mut m.callback_hash },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
|
|
|
::protobuf::reflect::MessageDescriptor::new::<LibspotifyAppKey>(
|
|
|
|
"LibspotifyAppKey",
|
|
|
|
fields,
|
|
|
|
file_descriptor_proto()
|
|
|
|
)
|
|
|
|
})
|
|
|
|
}
|
|
|
|
}
|
2018-09-28 10:02:38 +00:00
|
|
|
|
|
|
|
fn default_instance() -> &'static LibspotifyAppKey {
|
|
|
|
static mut instance: ::protobuf::lazy::Lazy<LibspotifyAppKey> = ::protobuf::lazy::Lazy {
|
|
|
|
lock: ::protobuf::lazy::ONCE_INIT,
|
|
|
|
ptr: 0 as *const LibspotifyAppKey,
|
|
|
|
};
|
|
|
|
unsafe {
|
|
|
|
instance.get(LibspotifyAppKey::new)
|
|
|
|
}
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
impl ::protobuf::Clear for LibspotifyAppKey {
|
|
|
|
fn clear(&mut self) {
|
2019-07-18 03:07:27 +00:00
|
|
|
self.version = ::std::option::Option::None;
|
|
|
|
self.devkey.clear();
|
|
|
|
self.signature.clear();
|
|
|
|
self.useragent.clear();
|
|
|
|
self.callback_hash.clear();
|
2016-11-21 02:48:17 +00:00
|
|
|
self.unknown_fields.clear();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
impl ::std::fmt::Debug for LibspotifyAppKey {
|
2019-11-06 15:38:30 +00:00
|
|
|
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
|
2016-11-21 02:48:17 +00:00
|
|
|
::protobuf::text_format::fmt(self, f)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2017-01-18 05:58:12 +00:00
|
|
|
impl ::protobuf::reflect::ProtobufValue for LibspotifyAppKey {
|
|
|
|
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
|
|
|
|
::protobuf::reflect::ProtobufValueRef::Message(self)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
#[derive(PartialEq,Clone,Default)]
|
2016-11-21 02:48:17 +00:00
|
|
|
pub struct ClientInfo {
|
|
|
|
// message fields
|
|
|
|
limited: ::std::option::Option<bool>,
|
|
|
|
fb: ::protobuf::SingularPtrField<ClientInfoFacebook>,
|
|
|
|
language: ::protobuf::SingularField<::std::string::String>,
|
|
|
|
// special fields
|
2019-07-18 03:07:27 +00:00
|
|
|
pub unknown_fields: ::protobuf::UnknownFields,
|
|
|
|
pub cached_size: ::protobuf::CachedSize,
|
|
|
|
}
|
|
|
|
|
|
|
|
impl<'a> ::std::default::Default for &'a ClientInfo {
|
|
|
|
fn default() -> &'a ClientInfo {
|
|
|
|
<ClientInfo as ::protobuf::Message>::default_instance()
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
impl ClientInfo {
|
|
|
|
pub fn new() -> ClientInfo {
|
|
|
|
::std::default::Default::default()
|
|
|
|
}
|
|
|
|
|
|
|
|
// optional bool limited = 1;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
|
|
|
|
pub fn get_limited(&self) -> bool {
|
|
|
|
self.limited.unwrap_or(false)
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
pub fn clear_limited(&mut self) {
|
|
|
|
self.limited = ::std::option::Option::None;
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_limited(&self) -> bool {
|
|
|
|
self.limited.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_limited(&mut self, v: bool) {
|
|
|
|
self.limited = ::std::option::Option::Some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// optional .ClientInfoFacebook fb = 2;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
|
|
|
|
pub fn get_fb(&self) -> &ClientInfoFacebook {
|
|
|
|
self.fb.as_ref().unwrap_or_else(|| ClientInfoFacebook::default_instance())
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
pub fn clear_fb(&mut self) {
|
|
|
|
self.fb.clear();
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_fb(&self) -> bool {
|
|
|
|
self.fb.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_fb(&mut self, v: ClientInfoFacebook) {
|
|
|
|
self.fb = ::protobuf::SingularPtrField::some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// Mutable pointer to the field.
|
|
|
|
// If field is not initialized, it is initialized with default value first.
|
|
|
|
pub fn mut_fb(&mut self) -> &mut ClientInfoFacebook {
|
|
|
|
if self.fb.is_none() {
|
|
|
|
self.fb.set_default();
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
self.fb.as_mut().unwrap()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Take field
|
|
|
|
pub fn take_fb(&mut self) -> ClientInfoFacebook {
|
|
|
|
self.fb.take().unwrap_or_else(|| ClientInfoFacebook::new())
|
|
|
|
}
|
|
|
|
|
|
|
|
// optional string language = 3;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
|
|
|
|
pub fn get_language(&self) -> &str {
|
|
|
|
match self.language.as_ref() {
|
|
|
|
Some(v) => &v,
|
|
|
|
None => "",
|
|
|
|
}
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
pub fn clear_language(&mut self) {
|
|
|
|
self.language.clear();
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_language(&self) -> bool {
|
|
|
|
self.language.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_language(&mut self, v: ::std::string::String) {
|
|
|
|
self.language = ::protobuf::SingularField::some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// Mutable pointer to the field.
|
|
|
|
// If field is not initialized, it is initialized with default value first.
|
|
|
|
pub fn mut_language(&mut self) -> &mut ::std::string::String {
|
|
|
|
if self.language.is_none() {
|
|
|
|
self.language.set_default();
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
self.language.as_mut().unwrap()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Take field
|
|
|
|
pub fn take_language(&mut self) -> ::std::string::String {
|
|
|
|
self.language.take().unwrap_or_else(|| ::std::string::String::new())
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
impl ::protobuf::Message for ClientInfo {
|
|
|
|
fn is_initialized(&self) -> bool {
|
2018-09-28 10:02:38 +00:00
|
|
|
for v in &self.fb {
|
|
|
|
if !v.is_initialized() {
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
};
|
2016-11-21 02:48:17 +00:00
|
|
|
true
|
|
|
|
}
|
|
|
|
|
2019-11-06 15:38:30 +00:00
|
|
|
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
|
2017-01-18 05:58:12 +00:00
|
|
|
while !is.eof()? {
|
|
|
|
let (field_number, wire_type) = is.read_tag_unpack()?;
|
2016-11-21 02:48:17 +00:00
|
|
|
match field_number {
|
|
|
|
1 => {
|
|
|
|
if wire_type != ::protobuf::wire_format::WireTypeVarint {
|
|
|
|
return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2017-01-18 05:58:12 +00:00
|
|
|
let tmp = is.read_bool()?;
|
2016-11-21 02:48:17 +00:00
|
|
|
self.limited = ::std::option::Option::Some(tmp);
|
|
|
|
},
|
|
|
|
2 => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.fb)?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
3 => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_singular_string_into(wire_type, is, &mut self.language)?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
_ => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
};
|
|
|
|
}
|
|
|
|
::std::result::Result::Ok(())
|
|
|
|
}
|
|
|
|
|
|
|
|
// Compute sizes of nested messages
|
|
|
|
#[allow(unused_variables)]
|
|
|
|
fn compute_size(&self) -> u32 {
|
|
|
|
let mut my_size = 0;
|
2017-01-18 05:58:12 +00:00
|
|
|
if let Some(v) = self.limited {
|
2016-11-21 02:48:17 +00:00
|
|
|
my_size += 2;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.fb.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
let len = v.compute_size();
|
2016-11-21 02:48:17 +00:00
|
|
|
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.language.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
my_size += ::protobuf::rt::string_size(3, &v);
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
|
|
|
|
self.cached_size.set(my_size);
|
|
|
|
my_size
|
|
|
|
}
|
|
|
|
|
2019-11-06 15:38:30 +00:00
|
|
|
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
|
2016-11-21 02:48:17 +00:00
|
|
|
if let Some(v) = self.limited {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_bool(1, v)?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.fb.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_tag(2, ::protobuf::wire_format::WireTypeLengthDelimited)?;
|
|
|
|
os.write_raw_varint32(v.get_cached_size())?;
|
|
|
|
v.write_to_with_cached_sizes(os)?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.language.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_string(3, &v)?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_unknown_fields(self.get_unknown_fields())?;
|
2016-11-21 02:48:17 +00:00
|
|
|
::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
|
|
|
|
}
|
|
|
|
|
2019-07-27 17:09:03 +00:00
|
|
|
fn as_any(&self) -> &dyn (::std::any::Any) {
|
|
|
|
self as &dyn (::std::any::Any)
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
2019-07-27 17:09:03 +00:00
|
|
|
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
|
|
|
|
self as &mut dyn (::std::any::Any)
|
2017-09-30 22:51:05 +00:00
|
|
|
}
|
2019-07-27 17:09:03 +00:00
|
|
|
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
|
2017-09-30 22:51:05 +00:00
|
|
|
self
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
|
|
|
|
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
|
2018-09-28 10:02:38 +00:00
|
|
|
Self::descriptor_static()
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
fn new() -> ClientInfo {
|
|
|
|
ClientInfo::new()
|
|
|
|
}
|
|
|
|
|
2018-09-28 10:02:38 +00:00
|
|
|
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
|
2016-11-21 02:48:17 +00:00
|
|
|
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();
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_option_accessor::<_, ::protobuf::types::ProtobufTypeBool>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"limited",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &ClientInfo| { &m.limited },
|
|
|
|
|m: &mut ClientInfo| { &mut m.limited },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ClientInfoFacebook>>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"fb",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &ClientInfo| { &m.fb },
|
|
|
|
|m: &mut ClientInfo| { &mut m.fb },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_singular_field_accessor::<_, ::protobuf::types::ProtobufTypeString>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"language",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &ClientInfo| { &m.language },
|
|
|
|
|m: &mut ClientInfo| { &mut m.language },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
|
|
|
::protobuf::reflect::MessageDescriptor::new::<ClientInfo>(
|
|
|
|
"ClientInfo",
|
|
|
|
fields,
|
|
|
|
file_descriptor_proto()
|
|
|
|
)
|
|
|
|
})
|
|
|
|
}
|
|
|
|
}
|
2018-09-28 10:02:38 +00:00
|
|
|
|
|
|
|
fn default_instance() -> &'static ClientInfo {
|
|
|
|
static mut instance: ::protobuf::lazy::Lazy<ClientInfo> = ::protobuf::lazy::Lazy {
|
|
|
|
lock: ::protobuf::lazy::ONCE_INIT,
|
|
|
|
ptr: 0 as *const ClientInfo,
|
|
|
|
};
|
|
|
|
unsafe {
|
|
|
|
instance.get(ClientInfo::new)
|
|
|
|
}
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
impl ::protobuf::Clear for ClientInfo {
|
|
|
|
fn clear(&mut self) {
|
2019-07-18 03:07:27 +00:00
|
|
|
self.limited = ::std::option::Option::None;
|
|
|
|
self.fb.clear();
|
|
|
|
self.language.clear();
|
2016-11-21 02:48:17 +00:00
|
|
|
self.unknown_fields.clear();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
impl ::std::fmt::Debug for ClientInfo {
|
2019-11-06 15:38:30 +00:00
|
|
|
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
|
2016-11-21 02:48:17 +00:00
|
|
|
::protobuf::text_format::fmt(self, f)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2017-01-18 05:58:12 +00:00
|
|
|
impl ::protobuf::reflect::ProtobufValue for ClientInfo {
|
|
|
|
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
|
|
|
|
::protobuf::reflect::ProtobufValueRef::Message(self)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
#[derive(PartialEq,Clone,Default)]
|
2016-11-21 02:48:17 +00:00
|
|
|
pub struct ClientInfoFacebook {
|
|
|
|
// message fields
|
|
|
|
machine_id: ::protobuf::SingularField<::std::string::String>,
|
|
|
|
// special fields
|
2019-07-18 03:07:27 +00:00
|
|
|
pub unknown_fields: ::protobuf::UnknownFields,
|
|
|
|
pub cached_size: ::protobuf::CachedSize,
|
|
|
|
}
|
|
|
|
|
|
|
|
impl<'a> ::std::default::Default for &'a ClientInfoFacebook {
|
|
|
|
fn default() -> &'a ClientInfoFacebook {
|
|
|
|
<ClientInfoFacebook as ::protobuf::Message>::default_instance()
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
impl ClientInfoFacebook {
|
|
|
|
pub fn new() -> ClientInfoFacebook {
|
|
|
|
::std::default::Default::default()
|
|
|
|
}
|
|
|
|
|
|
|
|
// optional string machine_id = 1;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
|
|
|
|
pub fn get_machine_id(&self) -> &str {
|
|
|
|
match self.machine_id.as_ref() {
|
|
|
|
Some(v) => &v,
|
|
|
|
None => "",
|
|
|
|
}
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
pub fn clear_machine_id(&mut self) {
|
|
|
|
self.machine_id.clear();
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_machine_id(&self) -> bool {
|
|
|
|
self.machine_id.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_machine_id(&mut self, v: ::std::string::String) {
|
|
|
|
self.machine_id = ::protobuf::SingularField::some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// Mutable pointer to the field.
|
|
|
|
// If field is not initialized, it is initialized with default value first.
|
|
|
|
pub fn mut_machine_id(&mut self) -> &mut ::std::string::String {
|
|
|
|
if self.machine_id.is_none() {
|
|
|
|
self.machine_id.set_default();
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
self.machine_id.as_mut().unwrap()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Take field
|
|
|
|
pub fn take_machine_id(&mut self) -> ::std::string::String {
|
|
|
|
self.machine_id.take().unwrap_or_else(|| ::std::string::String::new())
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
impl ::protobuf::Message for ClientInfoFacebook {
|
|
|
|
fn is_initialized(&self) -> bool {
|
|
|
|
true
|
|
|
|
}
|
|
|
|
|
2019-11-06 15:38:30 +00:00
|
|
|
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
|
2017-01-18 05:58:12 +00:00
|
|
|
while !is.eof()? {
|
|
|
|
let (field_number, wire_type) = is.read_tag_unpack()?;
|
2016-11-21 02:48:17 +00:00
|
|
|
match field_number {
|
|
|
|
1 => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_singular_string_into(wire_type, is, &mut self.machine_id)?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
_ => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
};
|
|
|
|
}
|
|
|
|
::std::result::Result::Ok(())
|
|
|
|
}
|
|
|
|
|
|
|
|
// Compute sizes of nested messages
|
|
|
|
#[allow(unused_variables)]
|
|
|
|
fn compute_size(&self) -> u32 {
|
|
|
|
let mut my_size = 0;
|
2018-09-28 10:02:38 +00:00
|
|
|
if let Some(ref v) = self.machine_id.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
my_size += ::protobuf::rt::string_size(1, &v);
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
|
|
|
|
self.cached_size.set(my_size);
|
|
|
|
my_size
|
|
|
|
}
|
|
|
|
|
2019-11-06 15:38:30 +00:00
|
|
|
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
|
2018-09-28 10:02:38 +00:00
|
|
|
if let Some(ref v) = self.machine_id.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_string(1, &v)?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_unknown_fields(self.get_unknown_fields())?;
|
2016-11-21 02:48:17 +00:00
|
|
|
::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
|
|
|
|
}
|
|
|
|
|
2019-07-27 17:09:03 +00:00
|
|
|
fn as_any(&self) -> &dyn (::std::any::Any) {
|
|
|
|
self as &dyn (::std::any::Any)
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
2019-07-27 17:09:03 +00:00
|
|
|
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
|
|
|
|
self as &mut dyn (::std::any::Any)
|
2017-09-30 22:51:05 +00:00
|
|
|
}
|
2019-07-27 17:09:03 +00:00
|
|
|
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
|
2017-09-30 22:51:05 +00:00
|
|
|
self
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
|
|
|
|
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
|
2018-09-28 10:02:38 +00:00
|
|
|
Self::descriptor_static()
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
fn new() -> ClientInfoFacebook {
|
|
|
|
ClientInfoFacebook::new()
|
|
|
|
}
|
|
|
|
|
2018-09-28 10:02:38 +00:00
|
|
|
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
|
2016-11-21 02:48:17 +00:00
|
|
|
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();
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_singular_field_accessor::<_, ::protobuf::types::ProtobufTypeString>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"machine_id",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &ClientInfoFacebook| { &m.machine_id },
|
|
|
|
|m: &mut ClientInfoFacebook| { &mut m.machine_id },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
|
|
|
::protobuf::reflect::MessageDescriptor::new::<ClientInfoFacebook>(
|
|
|
|
"ClientInfoFacebook",
|
|
|
|
fields,
|
|
|
|
file_descriptor_proto()
|
|
|
|
)
|
|
|
|
})
|
|
|
|
}
|
|
|
|
}
|
2018-09-28 10:02:38 +00:00
|
|
|
|
|
|
|
fn default_instance() -> &'static ClientInfoFacebook {
|
|
|
|
static mut instance: ::protobuf::lazy::Lazy<ClientInfoFacebook> = ::protobuf::lazy::Lazy {
|
|
|
|
lock: ::protobuf::lazy::ONCE_INIT,
|
|
|
|
ptr: 0 as *const ClientInfoFacebook,
|
|
|
|
};
|
|
|
|
unsafe {
|
|
|
|
instance.get(ClientInfoFacebook::new)
|
|
|
|
}
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
impl ::protobuf::Clear for ClientInfoFacebook {
|
|
|
|
fn clear(&mut self) {
|
2019-07-18 03:07:27 +00:00
|
|
|
self.machine_id.clear();
|
2016-11-21 02:48:17 +00:00
|
|
|
self.unknown_fields.clear();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
impl ::std::fmt::Debug for ClientInfoFacebook {
|
2019-11-06 15:38:30 +00:00
|
|
|
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
|
2016-11-21 02:48:17 +00:00
|
|
|
::protobuf::text_format::fmt(self, f)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2017-01-18 05:58:12 +00:00
|
|
|
impl ::protobuf::reflect::ProtobufValue for ClientInfoFacebook {
|
|
|
|
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
|
|
|
|
::protobuf::reflect::ProtobufValueRef::Message(self)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
#[derive(PartialEq,Clone,Default)]
|
2016-11-21 02:48:17 +00:00
|
|
|
pub struct APWelcome {
|
|
|
|
// message fields
|
|
|
|
canonical_username: ::protobuf::SingularField<::std::string::String>,
|
|
|
|
account_type_logged_in: ::std::option::Option<AccountType>,
|
|
|
|
credentials_type_logged_in: ::std::option::Option<AccountType>,
|
|
|
|
reusable_auth_credentials_type: ::std::option::Option<AuthenticationType>,
|
|
|
|
reusable_auth_credentials: ::protobuf::SingularField<::std::vec::Vec<u8>>,
|
|
|
|
lfs_secret: ::protobuf::SingularField<::std::vec::Vec<u8>>,
|
|
|
|
account_info: ::protobuf::SingularPtrField<AccountInfo>,
|
|
|
|
fb: ::protobuf::SingularPtrField<AccountInfoFacebook>,
|
|
|
|
// special fields
|
2019-07-18 03:07:27 +00:00
|
|
|
pub unknown_fields: ::protobuf::UnknownFields,
|
|
|
|
pub cached_size: ::protobuf::CachedSize,
|
|
|
|
}
|
|
|
|
|
|
|
|
impl<'a> ::std::default::Default for &'a APWelcome {
|
|
|
|
fn default() -> &'a APWelcome {
|
|
|
|
<APWelcome as ::protobuf::Message>::default_instance()
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
impl APWelcome {
|
|
|
|
pub fn new() -> APWelcome {
|
|
|
|
::std::default::Default::default()
|
|
|
|
}
|
|
|
|
|
|
|
|
// required string canonical_username = 10;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
|
|
|
|
pub fn get_canonical_username(&self) -> &str {
|
|
|
|
match self.canonical_username.as_ref() {
|
|
|
|
Some(v) => &v,
|
|
|
|
None => "",
|
|
|
|
}
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
pub fn clear_canonical_username(&mut self) {
|
|
|
|
self.canonical_username.clear();
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_canonical_username(&self) -> bool {
|
|
|
|
self.canonical_username.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_canonical_username(&mut self, v: ::std::string::String) {
|
|
|
|
self.canonical_username = ::protobuf::SingularField::some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// Mutable pointer to the field.
|
|
|
|
// If field is not initialized, it is initialized with default value first.
|
|
|
|
pub fn mut_canonical_username(&mut self) -> &mut ::std::string::String {
|
|
|
|
if self.canonical_username.is_none() {
|
|
|
|
self.canonical_username.set_default();
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
self.canonical_username.as_mut().unwrap()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Take field
|
|
|
|
pub fn take_canonical_username(&mut self) -> ::std::string::String {
|
|
|
|
self.canonical_username.take().unwrap_or_else(|| ::std::string::String::new())
|
|
|
|
}
|
|
|
|
|
|
|
|
// required .AccountType account_type_logged_in = 20;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
|
|
|
|
pub fn get_account_type_logged_in(&self) -> AccountType {
|
|
|
|
self.account_type_logged_in.unwrap_or(AccountType::Spotify)
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
pub fn clear_account_type_logged_in(&mut self) {
|
|
|
|
self.account_type_logged_in = ::std::option::Option::None;
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_account_type_logged_in(&self) -> bool {
|
|
|
|
self.account_type_logged_in.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_account_type_logged_in(&mut self, v: AccountType) {
|
|
|
|
self.account_type_logged_in = ::std::option::Option::Some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// required .AccountType credentials_type_logged_in = 25;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
|
|
|
|
pub fn get_credentials_type_logged_in(&self) -> AccountType {
|
|
|
|
self.credentials_type_logged_in.unwrap_or(AccountType::Spotify)
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
pub fn clear_credentials_type_logged_in(&mut self) {
|
|
|
|
self.credentials_type_logged_in = ::std::option::Option::None;
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_credentials_type_logged_in(&self) -> bool {
|
|
|
|
self.credentials_type_logged_in.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_credentials_type_logged_in(&mut self, v: AccountType) {
|
|
|
|
self.credentials_type_logged_in = ::std::option::Option::Some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// required .AuthenticationType reusable_auth_credentials_type = 30;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
|
|
|
|
pub fn get_reusable_auth_credentials_type(&self) -> AuthenticationType {
|
|
|
|
self.reusable_auth_credentials_type.unwrap_or(AuthenticationType::AUTHENTICATION_USER_PASS)
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
pub fn clear_reusable_auth_credentials_type(&mut self) {
|
|
|
|
self.reusable_auth_credentials_type = ::std::option::Option::None;
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_reusable_auth_credentials_type(&self) -> bool {
|
|
|
|
self.reusable_auth_credentials_type.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_reusable_auth_credentials_type(&mut self, v: AuthenticationType) {
|
|
|
|
self.reusable_auth_credentials_type = ::std::option::Option::Some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// required bytes reusable_auth_credentials = 40;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
|
|
|
|
pub fn get_reusable_auth_credentials(&self) -> &[u8] {
|
|
|
|
match self.reusable_auth_credentials.as_ref() {
|
|
|
|
Some(v) => &v,
|
|
|
|
None => &[],
|
|
|
|
}
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
pub fn clear_reusable_auth_credentials(&mut self) {
|
|
|
|
self.reusable_auth_credentials.clear();
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_reusable_auth_credentials(&self) -> bool {
|
|
|
|
self.reusable_auth_credentials.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_reusable_auth_credentials(&mut self, v: ::std::vec::Vec<u8>) {
|
|
|
|
self.reusable_auth_credentials = ::protobuf::SingularField::some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// Mutable pointer to the field.
|
|
|
|
// If field is not initialized, it is initialized with default value first.
|
|
|
|
pub fn mut_reusable_auth_credentials(&mut self) -> &mut ::std::vec::Vec<u8> {
|
|
|
|
if self.reusable_auth_credentials.is_none() {
|
|
|
|
self.reusable_auth_credentials.set_default();
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
self.reusable_auth_credentials.as_mut().unwrap()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Take field
|
|
|
|
pub fn take_reusable_auth_credentials(&mut self) -> ::std::vec::Vec<u8> {
|
|
|
|
self.reusable_auth_credentials.take().unwrap_or_else(|| ::std::vec::Vec::new())
|
|
|
|
}
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
// optional bytes lfs_secret = 50;
|
|
|
|
|
|
|
|
|
|
|
|
pub fn get_lfs_secret(&self) -> &[u8] {
|
|
|
|
match self.lfs_secret.as_ref() {
|
2016-11-21 02:48:17 +00:00
|
|
|
Some(v) => &v,
|
|
|
|
None => &[],
|
|
|
|
}
|
|
|
|
}
|
|
|
|
pub fn clear_lfs_secret(&mut self) {
|
|
|
|
self.lfs_secret.clear();
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_lfs_secret(&self) -> bool {
|
|
|
|
self.lfs_secret.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_lfs_secret(&mut self, v: ::std::vec::Vec<u8>) {
|
|
|
|
self.lfs_secret = ::protobuf::SingularField::some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// Mutable pointer to the field.
|
|
|
|
// If field is not initialized, it is initialized with default value first.
|
|
|
|
pub fn mut_lfs_secret(&mut self) -> &mut ::std::vec::Vec<u8> {
|
|
|
|
if self.lfs_secret.is_none() {
|
|
|
|
self.lfs_secret.set_default();
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
self.lfs_secret.as_mut().unwrap()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Take field
|
|
|
|
pub fn take_lfs_secret(&mut self) -> ::std::vec::Vec<u8> {
|
|
|
|
self.lfs_secret.take().unwrap_or_else(|| ::std::vec::Vec::new())
|
|
|
|
}
|
|
|
|
|
|
|
|
// optional .AccountInfo account_info = 60;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
|
|
|
|
pub fn get_account_info(&self) -> &AccountInfo {
|
|
|
|
self.account_info.as_ref().unwrap_or_else(|| AccountInfo::default_instance())
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
pub fn clear_account_info(&mut self) {
|
|
|
|
self.account_info.clear();
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_account_info(&self) -> bool {
|
|
|
|
self.account_info.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_account_info(&mut self, v: AccountInfo) {
|
|
|
|
self.account_info = ::protobuf::SingularPtrField::some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// Mutable pointer to the field.
|
|
|
|
// If field is not initialized, it is initialized with default value first.
|
|
|
|
pub fn mut_account_info(&mut self) -> &mut AccountInfo {
|
|
|
|
if self.account_info.is_none() {
|
|
|
|
self.account_info.set_default();
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
self.account_info.as_mut().unwrap()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Take field
|
|
|
|
pub fn take_account_info(&mut self) -> AccountInfo {
|
|
|
|
self.account_info.take().unwrap_or_else(|| AccountInfo::new())
|
|
|
|
}
|
|
|
|
|
|
|
|
// optional .AccountInfoFacebook fb = 70;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
|
|
|
|
pub fn get_fb(&self) -> &AccountInfoFacebook {
|
|
|
|
self.fb.as_ref().unwrap_or_else(|| AccountInfoFacebook::default_instance())
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
pub fn clear_fb(&mut self) {
|
|
|
|
self.fb.clear();
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_fb(&self) -> bool {
|
|
|
|
self.fb.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_fb(&mut self, v: AccountInfoFacebook) {
|
|
|
|
self.fb = ::protobuf::SingularPtrField::some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// Mutable pointer to the field.
|
|
|
|
// If field is not initialized, it is initialized with default value first.
|
|
|
|
pub fn mut_fb(&mut self) -> &mut AccountInfoFacebook {
|
|
|
|
if self.fb.is_none() {
|
|
|
|
self.fb.set_default();
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
self.fb.as_mut().unwrap()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Take field
|
|
|
|
pub fn take_fb(&mut self) -> AccountInfoFacebook {
|
|
|
|
self.fb.take().unwrap_or_else(|| AccountInfoFacebook::new())
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
impl ::protobuf::Message for APWelcome {
|
|
|
|
fn is_initialized(&self) -> bool {
|
|
|
|
if self.canonical_username.is_none() {
|
|
|
|
return false;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
if self.account_type_logged_in.is_none() {
|
|
|
|
return false;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
if self.credentials_type_logged_in.is_none() {
|
|
|
|
return false;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
if self.reusable_auth_credentials_type.is_none() {
|
|
|
|
return false;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
if self.reusable_auth_credentials.is_none() {
|
|
|
|
return false;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
for v in &self.account_info {
|
|
|
|
if !v.is_initialized() {
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
};
|
|
|
|
for v in &self.fb {
|
|
|
|
if !v.is_initialized() {
|
|
|
|
return false;
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
};
|
|
|
|
true
|
|
|
|
}
|
|
|
|
|
2019-11-06 15:38:30 +00:00
|
|
|
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
|
2017-01-18 05:58:12 +00:00
|
|
|
while !is.eof()? {
|
|
|
|
let (field_number, wire_type) = is.read_tag_unpack()?;
|
2016-11-21 02:48:17 +00:00
|
|
|
match field_number {
|
|
|
|
10 => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_singular_string_into(wire_type, is, &mut self.canonical_username)?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
20 => {
|
2018-09-28 10:02:38 +00:00
|
|
|
::protobuf::rt::read_proto2_enum_with_unknown_fields_into(wire_type, is, &mut self.account_type_logged_in, 20, &mut self.unknown_fields)?
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
25 => {
|
2018-09-28 10:02:38 +00:00
|
|
|
::protobuf::rt::read_proto2_enum_with_unknown_fields_into(wire_type, is, &mut self.credentials_type_logged_in, 25, &mut self.unknown_fields)?
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
30 => {
|
2018-09-28 10:02:38 +00:00
|
|
|
::protobuf::rt::read_proto2_enum_with_unknown_fields_into(wire_type, is, &mut self.reusable_auth_credentials_type, 30, &mut self.unknown_fields)?
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
40 => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_singular_bytes_into(wire_type, is, &mut self.reusable_auth_credentials)?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
50 => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_singular_bytes_into(wire_type, is, &mut self.lfs_secret)?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
60 => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.account_info)?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
70 => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.fb)?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
_ => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
};
|
|
|
|
}
|
|
|
|
::std::result::Result::Ok(())
|
|
|
|
}
|
|
|
|
|
|
|
|
// Compute sizes of nested messages
|
|
|
|
#[allow(unused_variables)]
|
|
|
|
fn compute_size(&self) -> u32 {
|
|
|
|
let mut my_size = 0;
|
2018-09-28 10:02:38 +00:00
|
|
|
if let Some(ref v) = self.canonical_username.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
my_size += ::protobuf::rt::string_size(10, &v);
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2017-01-18 05:58:12 +00:00
|
|
|
if let Some(v) = self.account_type_logged_in {
|
|
|
|
my_size += ::protobuf::rt::enum_size(20, v);
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2017-01-18 05:58:12 +00:00
|
|
|
if let Some(v) = self.credentials_type_logged_in {
|
|
|
|
my_size += ::protobuf::rt::enum_size(25, v);
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2017-01-18 05:58:12 +00:00
|
|
|
if let Some(v) = self.reusable_auth_credentials_type {
|
|
|
|
my_size += ::protobuf::rt::enum_size(30, v);
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.reusable_auth_credentials.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
my_size += ::protobuf::rt::bytes_size(40, &v);
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.lfs_secret.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
my_size += ::protobuf::rt::bytes_size(50, &v);
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.account_info.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
let len = v.compute_size();
|
2016-11-21 02:48:17 +00:00
|
|
|
my_size += 2 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.fb.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
let len = v.compute_size();
|
2016-11-21 02:48:17 +00:00
|
|
|
my_size += 2 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
|
|
|
|
self.cached_size.set(my_size);
|
|
|
|
my_size
|
|
|
|
}
|
|
|
|
|
2019-11-06 15:38:30 +00:00
|
|
|
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
|
2018-09-28 10:02:38 +00:00
|
|
|
if let Some(ref v) = self.canonical_username.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_string(10, &v)?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
if let Some(v) = self.account_type_logged_in {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_enum(20, v.value())?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
if let Some(v) = self.credentials_type_logged_in {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_enum(25, v.value())?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
if let Some(v) = self.reusable_auth_credentials_type {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_enum(30, v.value())?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.reusable_auth_credentials.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_bytes(40, &v)?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.lfs_secret.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_bytes(50, &v)?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.account_info.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_tag(60, ::protobuf::wire_format::WireTypeLengthDelimited)?;
|
|
|
|
os.write_raw_varint32(v.get_cached_size())?;
|
|
|
|
v.write_to_with_cached_sizes(os)?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.fb.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_tag(70, ::protobuf::wire_format::WireTypeLengthDelimited)?;
|
|
|
|
os.write_raw_varint32(v.get_cached_size())?;
|
|
|
|
v.write_to_with_cached_sizes(os)?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_unknown_fields(self.get_unknown_fields())?;
|
2016-11-21 02:48:17 +00:00
|
|
|
::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
|
|
|
|
}
|
|
|
|
|
2019-07-27 17:09:03 +00:00
|
|
|
fn as_any(&self) -> &dyn (::std::any::Any) {
|
|
|
|
self as &dyn (::std::any::Any)
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
2019-07-27 17:09:03 +00:00
|
|
|
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
|
|
|
|
self as &mut dyn (::std::any::Any)
|
2017-09-30 22:51:05 +00:00
|
|
|
}
|
2019-07-27 17:09:03 +00:00
|
|
|
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
|
2017-09-30 22:51:05 +00:00
|
|
|
self
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
|
|
|
|
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
|
2018-09-28 10:02:38 +00:00
|
|
|
Self::descriptor_static()
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
fn new() -> APWelcome {
|
|
|
|
APWelcome::new()
|
|
|
|
}
|
|
|
|
|
2018-09-28 10:02:38 +00:00
|
|
|
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
|
2016-11-21 02:48:17 +00:00
|
|
|
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();
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_singular_field_accessor::<_, ::protobuf::types::ProtobufTypeString>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"canonical_username",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &APWelcome| { &m.canonical_username },
|
|
|
|
|m: &mut APWelcome| { &mut m.canonical_username },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_option_accessor::<_, ::protobuf::types::ProtobufTypeEnum<AccountType>>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"account_type_logged_in",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &APWelcome| { &m.account_type_logged_in },
|
|
|
|
|m: &mut APWelcome| { &mut m.account_type_logged_in },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_option_accessor::<_, ::protobuf::types::ProtobufTypeEnum<AccountType>>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"credentials_type_logged_in",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &APWelcome| { &m.credentials_type_logged_in },
|
|
|
|
|m: &mut APWelcome| { &mut m.credentials_type_logged_in },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_option_accessor::<_, ::protobuf::types::ProtobufTypeEnum<AuthenticationType>>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"reusable_auth_credentials_type",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &APWelcome| { &m.reusable_auth_credentials_type },
|
|
|
|
|m: &mut APWelcome| { &mut m.reusable_auth_credentials_type },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_singular_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"reusable_auth_credentials",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &APWelcome| { &m.reusable_auth_credentials },
|
|
|
|
|m: &mut APWelcome| { &mut m.reusable_auth_credentials },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_singular_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"lfs_secret",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &APWelcome| { &m.lfs_secret },
|
|
|
|
|m: &mut APWelcome| { &mut m.lfs_secret },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<AccountInfo>>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"account_info",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &APWelcome| { &m.account_info },
|
|
|
|
|m: &mut APWelcome| { &mut m.account_info },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<AccountInfoFacebook>>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"fb",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &APWelcome| { &m.fb },
|
|
|
|
|m: &mut APWelcome| { &mut m.fb },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
|
|
|
::protobuf::reflect::MessageDescriptor::new::<APWelcome>(
|
|
|
|
"APWelcome",
|
|
|
|
fields,
|
|
|
|
file_descriptor_proto()
|
|
|
|
)
|
|
|
|
})
|
|
|
|
}
|
|
|
|
}
|
2018-09-28 10:02:38 +00:00
|
|
|
|
|
|
|
fn default_instance() -> &'static APWelcome {
|
|
|
|
static mut instance: ::protobuf::lazy::Lazy<APWelcome> = ::protobuf::lazy::Lazy {
|
|
|
|
lock: ::protobuf::lazy::ONCE_INIT,
|
|
|
|
ptr: 0 as *const APWelcome,
|
|
|
|
};
|
|
|
|
unsafe {
|
|
|
|
instance.get(APWelcome::new)
|
|
|
|
}
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
impl ::protobuf::Clear for APWelcome {
|
|
|
|
fn clear(&mut self) {
|
2019-07-18 03:07:27 +00:00
|
|
|
self.canonical_username.clear();
|
|
|
|
self.account_type_logged_in = ::std::option::Option::None;
|
|
|
|
self.credentials_type_logged_in = ::std::option::Option::None;
|
|
|
|
self.reusable_auth_credentials_type = ::std::option::Option::None;
|
|
|
|
self.reusable_auth_credentials.clear();
|
|
|
|
self.lfs_secret.clear();
|
|
|
|
self.account_info.clear();
|
|
|
|
self.fb.clear();
|
2016-11-21 02:48:17 +00:00
|
|
|
self.unknown_fields.clear();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
impl ::std::fmt::Debug for APWelcome {
|
2019-11-06 15:38:30 +00:00
|
|
|
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
|
2016-11-21 02:48:17 +00:00
|
|
|
::protobuf::text_format::fmt(self, f)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2017-01-18 05:58:12 +00:00
|
|
|
impl ::protobuf::reflect::ProtobufValue for APWelcome {
|
|
|
|
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
|
|
|
|
::protobuf::reflect::ProtobufValueRef::Message(self)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
#[derive(PartialEq,Clone,Default)]
|
2016-11-21 02:48:17 +00:00
|
|
|
pub struct AccountInfo {
|
|
|
|
// message fields
|
|
|
|
spotify: ::protobuf::SingularPtrField<AccountInfoSpotify>,
|
|
|
|
facebook: ::protobuf::SingularPtrField<AccountInfoFacebook>,
|
|
|
|
// special fields
|
2019-07-18 03:07:27 +00:00
|
|
|
pub unknown_fields: ::protobuf::UnknownFields,
|
|
|
|
pub cached_size: ::protobuf::CachedSize,
|
|
|
|
}
|
|
|
|
|
|
|
|
impl<'a> ::std::default::Default for &'a AccountInfo {
|
|
|
|
fn default() -> &'a AccountInfo {
|
|
|
|
<AccountInfo as ::protobuf::Message>::default_instance()
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
impl AccountInfo {
|
|
|
|
pub fn new() -> AccountInfo {
|
|
|
|
::std::default::Default::default()
|
|
|
|
}
|
|
|
|
|
|
|
|
// optional .AccountInfoSpotify spotify = 1;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
|
|
|
|
pub fn get_spotify(&self) -> &AccountInfoSpotify {
|
|
|
|
self.spotify.as_ref().unwrap_or_else(|| AccountInfoSpotify::default_instance())
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
pub fn clear_spotify(&mut self) {
|
|
|
|
self.spotify.clear();
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_spotify(&self) -> bool {
|
|
|
|
self.spotify.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_spotify(&mut self, v: AccountInfoSpotify) {
|
|
|
|
self.spotify = ::protobuf::SingularPtrField::some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// Mutable pointer to the field.
|
|
|
|
// If field is not initialized, it is initialized with default value first.
|
|
|
|
pub fn mut_spotify(&mut self) -> &mut AccountInfoSpotify {
|
|
|
|
if self.spotify.is_none() {
|
|
|
|
self.spotify.set_default();
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
self.spotify.as_mut().unwrap()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Take field
|
|
|
|
pub fn take_spotify(&mut self) -> AccountInfoSpotify {
|
|
|
|
self.spotify.take().unwrap_or_else(|| AccountInfoSpotify::new())
|
|
|
|
}
|
|
|
|
|
|
|
|
// optional .AccountInfoFacebook facebook = 2;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
|
|
|
|
pub fn get_facebook(&self) -> &AccountInfoFacebook {
|
|
|
|
self.facebook.as_ref().unwrap_or_else(|| AccountInfoFacebook::default_instance())
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
pub fn clear_facebook(&mut self) {
|
|
|
|
self.facebook.clear();
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_facebook(&self) -> bool {
|
|
|
|
self.facebook.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_facebook(&mut self, v: AccountInfoFacebook) {
|
|
|
|
self.facebook = ::protobuf::SingularPtrField::some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// Mutable pointer to the field.
|
|
|
|
// If field is not initialized, it is initialized with default value first.
|
|
|
|
pub fn mut_facebook(&mut self) -> &mut AccountInfoFacebook {
|
|
|
|
if self.facebook.is_none() {
|
|
|
|
self.facebook.set_default();
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
self.facebook.as_mut().unwrap()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Take field
|
|
|
|
pub fn take_facebook(&mut self) -> AccountInfoFacebook {
|
|
|
|
self.facebook.take().unwrap_or_else(|| AccountInfoFacebook::new())
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
impl ::protobuf::Message for AccountInfo {
|
|
|
|
fn is_initialized(&self) -> bool {
|
2018-09-28 10:02:38 +00:00
|
|
|
for v in &self.spotify {
|
|
|
|
if !v.is_initialized() {
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
};
|
|
|
|
for v in &self.facebook {
|
|
|
|
if !v.is_initialized() {
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
};
|
2016-11-21 02:48:17 +00:00
|
|
|
true
|
|
|
|
}
|
|
|
|
|
2019-11-06 15:38:30 +00:00
|
|
|
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
|
2017-01-18 05:58:12 +00:00
|
|
|
while !is.eof()? {
|
|
|
|
let (field_number, wire_type) = is.read_tag_unpack()?;
|
2016-11-21 02:48:17 +00:00
|
|
|
match field_number {
|
|
|
|
1 => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.spotify)?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
2 => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.facebook)?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
_ => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
};
|
|
|
|
}
|
|
|
|
::std::result::Result::Ok(())
|
|
|
|
}
|
|
|
|
|
|
|
|
// Compute sizes of nested messages
|
|
|
|
#[allow(unused_variables)]
|
|
|
|
fn compute_size(&self) -> u32 {
|
|
|
|
let mut my_size = 0;
|
2018-09-28 10:02:38 +00:00
|
|
|
if let Some(ref v) = self.spotify.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
let len = v.compute_size();
|
2016-11-21 02:48:17 +00:00
|
|
|
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.facebook.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
let len = v.compute_size();
|
2016-11-21 02:48:17 +00:00
|
|
|
my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
|
|
|
|
self.cached_size.set(my_size);
|
|
|
|
my_size
|
|
|
|
}
|
|
|
|
|
2019-11-06 15:38:30 +00:00
|
|
|
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
|
2018-09-28 10:02:38 +00:00
|
|
|
if let Some(ref v) = self.spotify.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_tag(1, ::protobuf::wire_format::WireTypeLengthDelimited)?;
|
|
|
|
os.write_raw_varint32(v.get_cached_size())?;
|
|
|
|
v.write_to_with_cached_sizes(os)?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.facebook.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_tag(2, ::protobuf::wire_format::WireTypeLengthDelimited)?;
|
|
|
|
os.write_raw_varint32(v.get_cached_size())?;
|
|
|
|
v.write_to_with_cached_sizes(os)?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_unknown_fields(self.get_unknown_fields())?;
|
2016-11-21 02:48:17 +00:00
|
|
|
::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
|
|
|
|
}
|
|
|
|
|
2019-07-27 17:09:03 +00:00
|
|
|
fn as_any(&self) -> &dyn (::std::any::Any) {
|
|
|
|
self as &dyn (::std::any::Any)
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
2019-07-27 17:09:03 +00:00
|
|
|
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
|
|
|
|
self as &mut dyn (::std::any::Any)
|
2017-09-30 22:51:05 +00:00
|
|
|
}
|
2019-07-27 17:09:03 +00:00
|
|
|
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
|
2017-09-30 22:51:05 +00:00
|
|
|
self
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
|
|
|
|
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
|
2018-09-28 10:02:38 +00:00
|
|
|
Self::descriptor_static()
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
fn new() -> AccountInfo {
|
|
|
|
AccountInfo::new()
|
|
|
|
}
|
|
|
|
|
2018-09-28 10:02:38 +00:00
|
|
|
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
|
2016-11-21 02:48:17 +00:00
|
|
|
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();
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<AccountInfoSpotify>>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"spotify",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &AccountInfo| { &m.spotify },
|
|
|
|
|m: &mut AccountInfo| { &mut m.spotify },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<AccountInfoFacebook>>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"facebook",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &AccountInfo| { &m.facebook },
|
|
|
|
|m: &mut AccountInfo| { &mut m.facebook },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
|
|
|
::protobuf::reflect::MessageDescriptor::new::<AccountInfo>(
|
|
|
|
"AccountInfo",
|
|
|
|
fields,
|
|
|
|
file_descriptor_proto()
|
|
|
|
)
|
|
|
|
})
|
|
|
|
}
|
|
|
|
}
|
2018-09-28 10:02:38 +00:00
|
|
|
|
|
|
|
fn default_instance() -> &'static AccountInfo {
|
|
|
|
static mut instance: ::protobuf::lazy::Lazy<AccountInfo> = ::protobuf::lazy::Lazy {
|
|
|
|
lock: ::protobuf::lazy::ONCE_INIT,
|
|
|
|
ptr: 0 as *const AccountInfo,
|
|
|
|
};
|
|
|
|
unsafe {
|
|
|
|
instance.get(AccountInfo::new)
|
|
|
|
}
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
impl ::protobuf::Clear for AccountInfo {
|
|
|
|
fn clear(&mut self) {
|
2019-07-18 03:07:27 +00:00
|
|
|
self.spotify.clear();
|
|
|
|
self.facebook.clear();
|
2016-11-21 02:48:17 +00:00
|
|
|
self.unknown_fields.clear();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
impl ::std::fmt::Debug for AccountInfo {
|
2019-11-06 15:38:30 +00:00
|
|
|
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
|
2016-11-21 02:48:17 +00:00
|
|
|
::protobuf::text_format::fmt(self, f)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2017-01-18 05:58:12 +00:00
|
|
|
impl ::protobuf::reflect::ProtobufValue for AccountInfo {
|
|
|
|
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
|
|
|
|
::protobuf::reflect::ProtobufValueRef::Message(self)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
#[derive(PartialEq,Clone,Default)]
|
2016-11-21 02:48:17 +00:00
|
|
|
pub struct AccountInfoSpotify {
|
|
|
|
// special fields
|
2019-07-18 03:07:27 +00:00
|
|
|
pub unknown_fields: ::protobuf::UnknownFields,
|
|
|
|
pub cached_size: ::protobuf::CachedSize,
|
|
|
|
}
|
|
|
|
|
|
|
|
impl<'a> ::std::default::Default for &'a AccountInfoSpotify {
|
|
|
|
fn default() -> &'a AccountInfoSpotify {
|
|
|
|
<AccountInfoSpotify as ::protobuf::Message>::default_instance()
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
impl AccountInfoSpotify {
|
|
|
|
pub fn new() -> AccountInfoSpotify {
|
|
|
|
::std::default::Default::default()
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
impl ::protobuf::Message for AccountInfoSpotify {
|
|
|
|
fn is_initialized(&self) -> bool {
|
|
|
|
true
|
|
|
|
}
|
|
|
|
|
2019-11-06 15:38:30 +00:00
|
|
|
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
|
2017-01-18 05:58:12 +00:00
|
|
|
while !is.eof()? {
|
|
|
|
let (field_number, wire_type) = is.read_tag_unpack()?;
|
2016-11-21 02:48:17 +00:00
|
|
|
match field_number {
|
|
|
|
_ => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
};
|
|
|
|
}
|
|
|
|
::std::result::Result::Ok(())
|
|
|
|
}
|
|
|
|
|
|
|
|
// Compute sizes of nested messages
|
|
|
|
#[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
|
|
|
|
}
|
|
|
|
|
2019-11-06 15:38:30 +00:00
|
|
|
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_unknown_fields(self.get_unknown_fields())?;
|
2016-11-21 02:48:17 +00:00
|
|
|
::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
|
|
|
|
}
|
|
|
|
|
2019-07-27 17:09:03 +00:00
|
|
|
fn as_any(&self) -> &dyn (::std::any::Any) {
|
|
|
|
self as &dyn (::std::any::Any)
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
2019-07-27 17:09:03 +00:00
|
|
|
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
|
|
|
|
self as &mut dyn (::std::any::Any)
|
2017-09-30 22:51:05 +00:00
|
|
|
}
|
2019-07-27 17:09:03 +00:00
|
|
|
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
|
2017-09-30 22:51:05 +00:00
|
|
|
self
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
|
|
|
|
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
|
2018-09-28 10:02:38 +00:00
|
|
|
Self::descriptor_static()
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
fn new() -> AccountInfoSpotify {
|
|
|
|
AccountInfoSpotify::new()
|
|
|
|
}
|
|
|
|
|
2018-09-28 10:02:38 +00:00
|
|
|
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
|
2016-11-21 02:48:17 +00:00
|
|
|
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::<AccountInfoSpotify>(
|
|
|
|
"AccountInfoSpotify",
|
|
|
|
fields,
|
|
|
|
file_descriptor_proto()
|
|
|
|
)
|
|
|
|
})
|
|
|
|
}
|
|
|
|
}
|
2018-09-28 10:02:38 +00:00
|
|
|
|
|
|
|
fn default_instance() -> &'static AccountInfoSpotify {
|
|
|
|
static mut instance: ::protobuf::lazy::Lazy<AccountInfoSpotify> = ::protobuf::lazy::Lazy {
|
|
|
|
lock: ::protobuf::lazy::ONCE_INIT,
|
|
|
|
ptr: 0 as *const AccountInfoSpotify,
|
|
|
|
};
|
|
|
|
unsafe {
|
|
|
|
instance.get(AccountInfoSpotify::new)
|
|
|
|
}
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
impl ::protobuf::Clear for AccountInfoSpotify {
|
|
|
|
fn clear(&mut self) {
|
|
|
|
self.unknown_fields.clear();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
impl ::std::fmt::Debug for AccountInfoSpotify {
|
2019-11-06 15:38:30 +00:00
|
|
|
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
|
2016-11-21 02:48:17 +00:00
|
|
|
::protobuf::text_format::fmt(self, f)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2017-01-18 05:58:12 +00:00
|
|
|
impl ::protobuf::reflect::ProtobufValue for AccountInfoSpotify {
|
|
|
|
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
|
|
|
|
::protobuf::reflect::ProtobufValueRef::Message(self)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
#[derive(PartialEq,Clone,Default)]
|
2016-11-21 02:48:17 +00:00
|
|
|
pub struct AccountInfoFacebook {
|
|
|
|
// message fields
|
|
|
|
access_token: ::protobuf::SingularField<::std::string::String>,
|
|
|
|
machine_id: ::protobuf::SingularField<::std::string::String>,
|
|
|
|
// special fields
|
2019-07-18 03:07:27 +00:00
|
|
|
pub unknown_fields: ::protobuf::UnknownFields,
|
|
|
|
pub cached_size: ::protobuf::CachedSize,
|
|
|
|
}
|
|
|
|
|
|
|
|
impl<'a> ::std::default::Default for &'a AccountInfoFacebook {
|
|
|
|
fn default() -> &'a AccountInfoFacebook {
|
|
|
|
<AccountInfoFacebook as ::protobuf::Message>::default_instance()
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
impl AccountInfoFacebook {
|
|
|
|
pub fn new() -> AccountInfoFacebook {
|
|
|
|
::std::default::Default::default()
|
|
|
|
}
|
|
|
|
|
|
|
|
// optional string access_token = 1;
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
|
|
|
|
pub fn get_access_token(&self) -> &str {
|
|
|
|
match self.access_token.as_ref() {
|
|
|
|
Some(v) => &v,
|
|
|
|
None => "",
|
|
|
|
}
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
pub fn clear_access_token(&mut self) {
|
|
|
|
self.access_token.clear();
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_access_token(&self) -> bool {
|
|
|
|
self.access_token.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_access_token(&mut self, v: ::std::string::String) {
|
|
|
|
self.access_token = ::protobuf::SingularField::some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// Mutable pointer to the field.
|
|
|
|
// If field is not initialized, it is initialized with default value first.
|
|
|
|
pub fn mut_access_token(&mut self) -> &mut ::std::string::String {
|
|
|
|
if self.access_token.is_none() {
|
|
|
|
self.access_token.set_default();
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
self.access_token.as_mut().unwrap()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Take field
|
|
|
|
pub fn take_access_token(&mut self) -> ::std::string::String {
|
|
|
|
self.access_token.take().unwrap_or_else(|| ::std::string::String::new())
|
|
|
|
}
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
// optional string machine_id = 2;
|
|
|
|
|
|
|
|
|
|
|
|
pub fn get_machine_id(&self) -> &str {
|
|
|
|
match self.machine_id.as_ref() {
|
2016-11-21 02:48:17 +00:00
|
|
|
Some(v) => &v,
|
|
|
|
None => "",
|
|
|
|
}
|
|
|
|
}
|
|
|
|
pub fn clear_machine_id(&mut self) {
|
|
|
|
self.machine_id.clear();
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn has_machine_id(&self) -> bool {
|
|
|
|
self.machine_id.is_some()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Param is passed by value, moved
|
|
|
|
pub fn set_machine_id(&mut self, v: ::std::string::String) {
|
|
|
|
self.machine_id = ::protobuf::SingularField::some(v);
|
|
|
|
}
|
|
|
|
|
|
|
|
// Mutable pointer to the field.
|
|
|
|
// If field is not initialized, it is initialized with default value first.
|
|
|
|
pub fn mut_machine_id(&mut self) -> &mut ::std::string::String {
|
|
|
|
if self.machine_id.is_none() {
|
|
|
|
self.machine_id.set_default();
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
self.machine_id.as_mut().unwrap()
|
|
|
|
}
|
|
|
|
|
|
|
|
// Take field
|
|
|
|
pub fn take_machine_id(&mut self) -> ::std::string::String {
|
|
|
|
self.machine_id.take().unwrap_or_else(|| ::std::string::String::new())
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
impl ::protobuf::Message for AccountInfoFacebook {
|
|
|
|
fn is_initialized(&self) -> bool {
|
|
|
|
true
|
|
|
|
}
|
|
|
|
|
2019-11-06 15:38:30 +00:00
|
|
|
fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
|
2017-01-18 05:58:12 +00:00
|
|
|
while !is.eof()? {
|
|
|
|
let (field_number, wire_type) = is.read_tag_unpack()?;
|
2016-11-21 02:48:17 +00:00
|
|
|
match field_number {
|
|
|
|
1 => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_singular_string_into(wire_type, is, &mut self.access_token)?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
2 => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_singular_string_into(wire_type, is, &mut self.machine_id)?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
_ => {
|
2017-01-18 05:58:12 +00:00
|
|
|
::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
|
2016-11-21 02:48:17 +00:00
|
|
|
},
|
|
|
|
};
|
|
|
|
}
|
|
|
|
::std::result::Result::Ok(())
|
|
|
|
}
|
|
|
|
|
|
|
|
// Compute sizes of nested messages
|
|
|
|
#[allow(unused_variables)]
|
|
|
|
fn compute_size(&self) -> u32 {
|
|
|
|
let mut my_size = 0;
|
2018-09-28 10:02:38 +00:00
|
|
|
if let Some(ref v) = self.access_token.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
my_size += ::protobuf::rt::string_size(1, &v);
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.machine_id.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
my_size += ::protobuf::rt::string_size(2, &v);
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
|
|
|
|
self.cached_size.set(my_size);
|
|
|
|
my_size
|
|
|
|
}
|
|
|
|
|
2019-11-06 15:38:30 +00:00
|
|
|
fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
|
2018-09-28 10:02:38 +00:00
|
|
|
if let Some(ref v) = self.access_token.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_string(1, &v)?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
|
|
|
if let Some(ref v) = self.machine_id.as_ref() {
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_string(2, &v)?;
|
2018-09-28 10:02:38 +00:00
|
|
|
}
|
2017-01-18 05:58:12 +00:00
|
|
|
os.write_unknown_fields(self.get_unknown_fields())?;
|
2016-11-21 02:48:17 +00:00
|
|
|
::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
|
|
|
|
}
|
|
|
|
|
2019-07-27 17:09:03 +00:00
|
|
|
fn as_any(&self) -> &dyn (::std::any::Any) {
|
|
|
|
self as &dyn (::std::any::Any)
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
2019-07-27 17:09:03 +00:00
|
|
|
fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
|
|
|
|
self as &mut dyn (::std::any::Any)
|
2017-09-30 22:51:05 +00:00
|
|
|
}
|
2019-07-27 17:09:03 +00:00
|
|
|
fn into_any(self: Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
|
2017-09-30 22:51:05 +00:00
|
|
|
self
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
|
|
|
|
fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
|
2018-09-28 10:02:38 +00:00
|
|
|
Self::descriptor_static()
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
fn new() -> AccountInfoFacebook {
|
|
|
|
AccountInfoFacebook::new()
|
|
|
|
}
|
|
|
|
|
2018-09-28 10:02:38 +00:00
|
|
|
fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
|
2016-11-21 02:48:17 +00:00
|
|
|
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();
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_singular_field_accessor::<_, ::protobuf::types::ProtobufTypeString>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"access_token",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &AccountInfoFacebook| { &m.access_token },
|
|
|
|
|m: &mut AccountInfoFacebook| { &mut m.access_token },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
2017-01-18 05:58:12 +00:00
|
|
|
fields.push(::protobuf::reflect::accessor::make_singular_field_accessor::<_, ::protobuf::types::ProtobufTypeString>(
|
2016-11-21 02:48:17 +00:00
|
|
|
"machine_id",
|
2018-09-28 10:02:38 +00:00
|
|
|
|m: &AccountInfoFacebook| { &m.machine_id },
|
|
|
|
|m: &mut AccountInfoFacebook| { &mut m.machine_id },
|
2016-11-21 02:48:17 +00:00
|
|
|
));
|
|
|
|
::protobuf::reflect::MessageDescriptor::new::<AccountInfoFacebook>(
|
|
|
|
"AccountInfoFacebook",
|
|
|
|
fields,
|
|
|
|
file_descriptor_proto()
|
|
|
|
)
|
|
|
|
})
|
|
|
|
}
|
|
|
|
}
|
2018-09-28 10:02:38 +00:00
|
|
|
|
|
|
|
fn default_instance() -> &'static AccountInfoFacebook {
|
|
|
|
static mut instance: ::protobuf::lazy::Lazy<AccountInfoFacebook> = ::protobuf::lazy::Lazy {
|
|
|
|
lock: ::protobuf::lazy::ONCE_INIT,
|
|
|
|
ptr: 0 as *const AccountInfoFacebook,
|
|
|
|
};
|
|
|
|
unsafe {
|
|
|
|
instance.get(AccountInfoFacebook::new)
|
|
|
|
}
|
|
|
|
}
|
2016-11-21 02:48:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
impl ::protobuf::Clear for AccountInfoFacebook {
|
|
|
|
fn clear(&mut self) {
|
2019-07-18 03:07:27 +00:00
|
|
|
self.access_token.clear();
|
|
|
|
self.machine_id.clear();
|
2016-11-21 02:48:17 +00:00
|
|
|
self.unknown_fields.clear();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
impl ::std::fmt::Debug for AccountInfoFacebook {
|
2019-11-06 15:38:30 +00:00
|
|
|
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
|
2016-11-21 02:48:17 +00:00
|
|
|
::protobuf::text_format::fmt(self, f)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2017-01-18 05:58:12 +00:00
|
|
|
impl ::protobuf::reflect::ProtobufValue for AccountInfoFacebook {
|
|
|
|
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
|
|
|
|
::protobuf::reflect::ProtobufValueRef::Message(self)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2016-11-21 02:48:17 +00:00
|
|
|
#[derive(Clone,PartialEq,Eq,Debug,Hash)]
|
|
|
|
pub enum AuthenticationType {
|
|
|
|
AUTHENTICATION_USER_PASS = 0,
|
|
|
|
AUTHENTICATION_STORED_SPOTIFY_CREDENTIALS = 1,
|
|
|
|
AUTHENTICATION_STORED_FACEBOOK_CREDENTIALS = 2,
|
|
|
|
AUTHENTICATION_SPOTIFY_TOKEN = 3,
|
|
|
|
AUTHENTICATION_FACEBOOK_TOKEN = 4,
|
|
|
|
}
|
|
|
|
|
|
|
|
impl ::protobuf::ProtobufEnum for AuthenticationType {
|
|
|
|
fn value(&self) -> i32 {
|
|
|
|
*self as i32
|
|
|
|
}
|
|
|
|
|
|
|
|
fn from_i32(value: i32) -> ::std::option::Option<AuthenticationType> {
|
|
|
|
match value {
|
|
|
|
0 => ::std::option::Option::Some(AuthenticationType::AUTHENTICATION_USER_PASS),
|
|
|
|
1 => ::std::option::Option::Some(AuthenticationType::AUTHENTICATION_STORED_SPOTIFY_CREDENTIALS),
|
|
|
|
2 => ::std::option::Option::Some(AuthenticationType::AUTHENTICATION_STORED_FACEBOOK_CREDENTIALS),
|
|
|
|
3 => ::std::option::Option::Some(AuthenticationType::AUTHENTICATION_SPOTIFY_TOKEN),
|
|
|
|
4 => ::std::option::Option::Some(AuthenticationType::AUTHENTICATION_FACEBOOK_TOKEN),
|
|
|
|
_ => ::std::option::Option::None
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
fn values() -> &'static [Self] {
|
|
|
|
static values: &'static [AuthenticationType] = &[
|
|
|
|
AuthenticationType::AUTHENTICATION_USER_PASS,
|
|
|
|
AuthenticationType::AUTHENTICATION_STORED_SPOTIFY_CREDENTIALS,
|
|
|
|
AuthenticationType::AUTHENTICATION_STORED_FACEBOOK_CREDENTIALS,
|
|
|
|
AuthenticationType::AUTHENTICATION_SPOTIFY_TOKEN,
|
|
|
|
AuthenticationType::AUTHENTICATION_FACEBOOK_TOKEN,
|
|
|
|
];
|
|
|
|
values
|
|
|
|
}
|
|
|
|
|
2018-09-28 10:02:38 +00:00
|
|
|
fn enum_descriptor_static() -> &'static ::protobuf::reflect::EnumDescriptor {
|
2016-11-21 02:48:17 +00:00
|
|
|
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::EnumDescriptor> = ::protobuf::lazy::Lazy {
|
|
|
|
lock: ::protobuf::lazy::ONCE_INIT,
|
|
|
|
ptr: 0 as *const ::protobuf::reflect::EnumDescriptor,
|
|
|
|
};
|
|
|
|
unsafe {
|
|
|
|
descriptor.get(|| {
|
|
|
|
::protobuf::reflect::EnumDescriptor::new("AuthenticationType", file_descriptor_proto())
|
|
|
|
})
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
impl ::std::marker::Copy for AuthenticationType {
|
|
|
|
}
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
impl ::std::default::Default for AuthenticationType {
|
|
|
|
fn default() -> Self {
|
|
|
|
AuthenticationType::AUTHENTICATION_USER_PASS
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2017-01-18 05:58:12 +00:00
|
|
|
impl ::protobuf::reflect::ProtobufValue for AuthenticationType {
|
|
|
|
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
|
|
|
|
::protobuf::reflect::ProtobufValueRef::Enum(self.descriptor())
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2016-11-21 02:48:17 +00:00
|
|
|
#[derive(Clone,PartialEq,Eq,Debug,Hash)]
|
|
|
|
pub enum AccountCreation {
|
|
|
|
ACCOUNT_CREATION_ALWAYS_PROMPT = 1,
|
|
|
|
ACCOUNT_CREATION_ALWAYS_CREATE = 3,
|
|
|
|
}
|
|
|
|
|
|
|
|
impl ::protobuf::ProtobufEnum for AccountCreation {
|
|
|
|
fn value(&self) -> i32 {
|
|
|
|
*self as i32
|
|
|
|
}
|
|
|
|
|
|
|
|
fn from_i32(value: i32) -> ::std::option::Option<AccountCreation> {
|
|
|
|
match value {
|
|
|
|
1 => ::std::option::Option::Some(AccountCreation::ACCOUNT_CREATION_ALWAYS_PROMPT),
|
|
|
|
3 => ::std::option::Option::Some(AccountCreation::ACCOUNT_CREATION_ALWAYS_CREATE),
|
|
|
|
_ => ::std::option::Option::None
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
fn values() -> &'static [Self] {
|
|
|
|
static values: &'static [AccountCreation] = &[
|
|
|
|
AccountCreation::ACCOUNT_CREATION_ALWAYS_PROMPT,
|
|
|
|
AccountCreation::ACCOUNT_CREATION_ALWAYS_CREATE,
|
|
|
|
];
|
|
|
|
values
|
|
|
|
}
|
|
|
|
|
2018-09-28 10:02:38 +00:00
|
|
|
fn enum_descriptor_static() -> &'static ::protobuf::reflect::EnumDescriptor {
|
2016-11-21 02:48:17 +00:00
|
|
|
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::EnumDescriptor> = ::protobuf::lazy::Lazy {
|
|
|
|
lock: ::protobuf::lazy::ONCE_INIT,
|
|
|
|
ptr: 0 as *const ::protobuf::reflect::EnumDescriptor,
|
|
|
|
};
|
|
|
|
unsafe {
|
|
|
|
descriptor.get(|| {
|
|
|
|
::protobuf::reflect::EnumDescriptor::new("AccountCreation", file_descriptor_proto())
|
|
|
|
})
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
impl ::std::marker::Copy for AccountCreation {
|
|
|
|
}
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
// Note, `Default` is implemented although default value is not 0
|
|
|
|
impl ::std::default::Default for AccountCreation {
|
|
|
|
fn default() -> Self {
|
|
|
|
AccountCreation::ACCOUNT_CREATION_ALWAYS_PROMPT
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2017-01-18 05:58:12 +00:00
|
|
|
impl ::protobuf::reflect::ProtobufValue for AccountCreation {
|
|
|
|
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
|
|
|
|
::protobuf::reflect::ProtobufValueRef::Enum(self.descriptor())
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2016-11-21 02:48:17 +00:00
|
|
|
#[derive(Clone,PartialEq,Eq,Debug,Hash)]
|
|
|
|
pub enum CpuFamily {
|
|
|
|
CPU_UNKNOWN = 0,
|
|
|
|
CPU_X86 = 1,
|
|
|
|
CPU_X86_64 = 2,
|
|
|
|
CPU_PPC = 3,
|
|
|
|
CPU_PPC_64 = 4,
|
|
|
|
CPU_ARM = 5,
|
|
|
|
CPU_IA64 = 6,
|
|
|
|
CPU_SH = 7,
|
|
|
|
CPU_MIPS = 8,
|
|
|
|
CPU_BLACKFIN = 9,
|
|
|
|
}
|
|
|
|
|
|
|
|
impl ::protobuf::ProtobufEnum for CpuFamily {
|
|
|
|
fn value(&self) -> i32 {
|
|
|
|
*self as i32
|
|
|
|
}
|
|
|
|
|
|
|
|
fn from_i32(value: i32) -> ::std::option::Option<CpuFamily> {
|
|
|
|
match value {
|
|
|
|
0 => ::std::option::Option::Some(CpuFamily::CPU_UNKNOWN),
|
|
|
|
1 => ::std::option::Option::Some(CpuFamily::CPU_X86),
|
|
|
|
2 => ::std::option::Option::Some(CpuFamily::CPU_X86_64),
|
|
|
|
3 => ::std::option::Option::Some(CpuFamily::CPU_PPC),
|
|
|
|
4 => ::std::option::Option::Some(CpuFamily::CPU_PPC_64),
|
|
|
|
5 => ::std::option::Option::Some(CpuFamily::CPU_ARM),
|
|
|
|
6 => ::std::option::Option::Some(CpuFamily::CPU_IA64),
|
|
|
|
7 => ::std::option::Option::Some(CpuFamily::CPU_SH),
|
|
|
|
8 => ::std::option::Option::Some(CpuFamily::CPU_MIPS),
|
|
|
|
9 => ::std::option::Option::Some(CpuFamily::CPU_BLACKFIN),
|
|
|
|
_ => ::std::option::Option::None
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
fn values() -> &'static [Self] {
|
|
|
|
static values: &'static [CpuFamily] = &[
|
|
|
|
CpuFamily::CPU_UNKNOWN,
|
|
|
|
CpuFamily::CPU_X86,
|
|
|
|
CpuFamily::CPU_X86_64,
|
|
|
|
CpuFamily::CPU_PPC,
|
|
|
|
CpuFamily::CPU_PPC_64,
|
|
|
|
CpuFamily::CPU_ARM,
|
|
|
|
CpuFamily::CPU_IA64,
|
|
|
|
CpuFamily::CPU_SH,
|
|
|
|
CpuFamily::CPU_MIPS,
|
|
|
|
CpuFamily::CPU_BLACKFIN,
|
|
|
|
];
|
|
|
|
values
|
|
|
|
}
|
|
|
|
|
2018-09-28 10:02:38 +00:00
|
|
|
fn enum_descriptor_static() -> &'static ::protobuf::reflect::EnumDescriptor {
|
2016-11-21 02:48:17 +00:00
|
|
|
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::EnumDescriptor> = ::protobuf::lazy::Lazy {
|
|
|
|
lock: ::protobuf::lazy::ONCE_INIT,
|
|
|
|
ptr: 0 as *const ::protobuf::reflect::EnumDescriptor,
|
|
|
|
};
|
|
|
|
unsafe {
|
|
|
|
descriptor.get(|| {
|
|
|
|
::protobuf::reflect::EnumDescriptor::new("CpuFamily", file_descriptor_proto())
|
|
|
|
})
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
impl ::std::marker::Copy for CpuFamily {
|
|
|
|
}
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
impl ::std::default::Default for CpuFamily {
|
|
|
|
fn default() -> Self {
|
|
|
|
CpuFamily::CPU_UNKNOWN
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2017-01-18 05:58:12 +00:00
|
|
|
impl ::protobuf::reflect::ProtobufValue for CpuFamily {
|
|
|
|
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
|
|
|
|
::protobuf::reflect::ProtobufValueRef::Enum(self.descriptor())
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2016-11-21 02:48:17 +00:00
|
|
|
#[derive(Clone,PartialEq,Eq,Debug,Hash)]
|
|
|
|
pub enum Brand {
|
|
|
|
BRAND_UNBRANDED = 0,
|
|
|
|
BRAND_INQ = 1,
|
|
|
|
BRAND_HTC = 2,
|
|
|
|
BRAND_NOKIA = 3,
|
|
|
|
}
|
|
|
|
|
|
|
|
impl ::protobuf::ProtobufEnum for Brand {
|
|
|
|
fn value(&self) -> i32 {
|
|
|
|
*self as i32
|
|
|
|
}
|
|
|
|
|
|
|
|
fn from_i32(value: i32) -> ::std::option::Option<Brand> {
|
|
|
|
match value {
|
|
|
|
0 => ::std::option::Option::Some(Brand::BRAND_UNBRANDED),
|
|
|
|
1 => ::std::option::Option::Some(Brand::BRAND_INQ),
|
|
|
|
2 => ::std::option::Option::Some(Brand::BRAND_HTC),
|
|
|
|
3 => ::std::option::Option::Some(Brand::BRAND_NOKIA),
|
|
|
|
_ => ::std::option::Option::None
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
fn values() -> &'static [Self] {
|
|
|
|
static values: &'static [Brand] = &[
|
|
|
|
Brand::BRAND_UNBRANDED,
|
|
|
|
Brand::BRAND_INQ,
|
|
|
|
Brand::BRAND_HTC,
|
|
|
|
Brand::BRAND_NOKIA,
|
|
|
|
];
|
|
|
|
values
|
|
|
|
}
|
|
|
|
|
2018-09-28 10:02:38 +00:00
|
|
|
fn enum_descriptor_static() -> &'static ::protobuf::reflect::EnumDescriptor {
|
2016-11-21 02:48:17 +00:00
|
|
|
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::EnumDescriptor> = ::protobuf::lazy::Lazy {
|
|
|
|
lock: ::protobuf::lazy::ONCE_INIT,
|
|
|
|
ptr: 0 as *const ::protobuf::reflect::EnumDescriptor,
|
|
|
|
};
|
|
|
|
unsafe {
|
|
|
|
descriptor.get(|| {
|
|
|
|
::protobuf::reflect::EnumDescriptor::new("Brand", file_descriptor_proto())
|
|
|
|
})
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
impl ::std::marker::Copy for Brand {
|
|
|
|
}
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
impl ::std::default::Default for Brand {
|
|
|
|
fn default() -> Self {
|
|
|
|
Brand::BRAND_UNBRANDED
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2017-01-18 05:58:12 +00:00
|
|
|
impl ::protobuf::reflect::ProtobufValue for Brand {
|
|
|
|
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
|
|
|
|
::protobuf::reflect::ProtobufValueRef::Enum(self.descriptor())
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2016-11-21 02:48:17 +00:00
|
|
|
#[derive(Clone,PartialEq,Eq,Debug,Hash)]
|
|
|
|
pub enum Os {
|
|
|
|
OS_UNKNOWN = 0,
|
|
|
|
OS_WINDOWS = 1,
|
|
|
|
OS_OSX = 2,
|
|
|
|
OS_IPHONE = 3,
|
|
|
|
OS_S60 = 4,
|
|
|
|
OS_LINUX = 5,
|
|
|
|
OS_WINDOWS_CE = 6,
|
|
|
|
OS_ANDROID = 7,
|
|
|
|
OS_PALM = 8,
|
|
|
|
OS_FREEBSD = 9,
|
|
|
|
OS_BLACKBERRY = 10,
|
|
|
|
OS_SONOS = 11,
|
|
|
|
OS_LOGITECH = 12,
|
|
|
|
OS_WP7 = 13,
|
|
|
|
OS_ONKYO = 14,
|
|
|
|
OS_PHILIPS = 15,
|
|
|
|
OS_WD = 16,
|
|
|
|
OS_VOLVO = 17,
|
|
|
|
OS_TIVO = 18,
|
|
|
|
OS_AWOX = 19,
|
|
|
|
OS_MEEGO = 20,
|
|
|
|
OS_QNXNTO = 21,
|
|
|
|
OS_BCO = 22,
|
|
|
|
}
|
|
|
|
|
|
|
|
impl ::protobuf::ProtobufEnum for Os {
|
|
|
|
fn value(&self) -> i32 {
|
|
|
|
*self as i32
|
|
|
|
}
|
|
|
|
|
|
|
|
fn from_i32(value: i32) -> ::std::option::Option<Os> {
|
|
|
|
match value {
|
|
|
|
0 => ::std::option::Option::Some(Os::OS_UNKNOWN),
|
|
|
|
1 => ::std::option::Option::Some(Os::OS_WINDOWS),
|
|
|
|
2 => ::std::option::Option::Some(Os::OS_OSX),
|
|
|
|
3 => ::std::option::Option::Some(Os::OS_IPHONE),
|
|
|
|
4 => ::std::option::Option::Some(Os::OS_S60),
|
|
|
|
5 => ::std::option::Option::Some(Os::OS_LINUX),
|
|
|
|
6 => ::std::option::Option::Some(Os::OS_WINDOWS_CE),
|
|
|
|
7 => ::std::option::Option::Some(Os::OS_ANDROID),
|
|
|
|
8 => ::std::option::Option::Some(Os::OS_PALM),
|
|
|
|
9 => ::std::option::Option::Some(Os::OS_FREEBSD),
|
|
|
|
10 => ::std::option::Option::Some(Os::OS_BLACKBERRY),
|
|
|
|
11 => ::std::option::Option::Some(Os::OS_SONOS),
|
|
|
|
12 => ::std::option::Option::Some(Os::OS_LOGITECH),
|
|
|
|
13 => ::std::option::Option::Some(Os::OS_WP7),
|
|
|
|
14 => ::std::option::Option::Some(Os::OS_ONKYO),
|
|
|
|
15 => ::std::option::Option::Some(Os::OS_PHILIPS),
|
|
|
|
16 => ::std::option::Option::Some(Os::OS_WD),
|
|
|
|
17 => ::std::option::Option::Some(Os::OS_VOLVO),
|
|
|
|
18 => ::std::option::Option::Some(Os::OS_TIVO),
|
|
|
|
19 => ::std::option::Option::Some(Os::OS_AWOX),
|
|
|
|
20 => ::std::option::Option::Some(Os::OS_MEEGO),
|
|
|
|
21 => ::std::option::Option::Some(Os::OS_QNXNTO),
|
|
|
|
22 => ::std::option::Option::Some(Os::OS_BCO),
|
|
|
|
_ => ::std::option::Option::None
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
fn values() -> &'static [Self] {
|
|
|
|
static values: &'static [Os] = &[
|
|
|
|
Os::OS_UNKNOWN,
|
|
|
|
Os::OS_WINDOWS,
|
|
|
|
Os::OS_OSX,
|
|
|
|
Os::OS_IPHONE,
|
|
|
|
Os::OS_S60,
|
|
|
|
Os::OS_LINUX,
|
|
|
|
Os::OS_WINDOWS_CE,
|
|
|
|
Os::OS_ANDROID,
|
|
|
|
Os::OS_PALM,
|
|
|
|
Os::OS_FREEBSD,
|
|
|
|
Os::OS_BLACKBERRY,
|
|
|
|
Os::OS_SONOS,
|
|
|
|
Os::OS_LOGITECH,
|
|
|
|
Os::OS_WP7,
|
|
|
|
Os::OS_ONKYO,
|
|
|
|
Os::OS_PHILIPS,
|
|
|
|
Os::OS_WD,
|
|
|
|
Os::OS_VOLVO,
|
|
|
|
Os::OS_TIVO,
|
|
|
|
Os::OS_AWOX,
|
|
|
|
Os::OS_MEEGO,
|
|
|
|
Os::OS_QNXNTO,
|
|
|
|
Os::OS_BCO,
|
|
|
|
];
|
|
|
|
values
|
|
|
|
}
|
|
|
|
|
2018-09-28 10:02:38 +00:00
|
|
|
fn enum_descriptor_static() -> &'static ::protobuf::reflect::EnumDescriptor {
|
2016-11-21 02:48:17 +00:00
|
|
|
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::EnumDescriptor> = ::protobuf::lazy::Lazy {
|
|
|
|
lock: ::protobuf::lazy::ONCE_INIT,
|
|
|
|
ptr: 0 as *const ::protobuf::reflect::EnumDescriptor,
|
|
|
|
};
|
|
|
|
unsafe {
|
|
|
|
descriptor.get(|| {
|
|
|
|
::protobuf::reflect::EnumDescriptor::new("Os", file_descriptor_proto())
|
|
|
|
})
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
impl ::std::marker::Copy for Os {
|
|
|
|
}
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
impl ::std::default::Default for Os {
|
|
|
|
fn default() -> Self {
|
|
|
|
Os::OS_UNKNOWN
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2017-01-18 05:58:12 +00:00
|
|
|
impl ::protobuf::reflect::ProtobufValue for Os {
|
|
|
|
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
|
|
|
|
::protobuf::reflect::ProtobufValueRef::Enum(self.descriptor())
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2016-11-21 02:48:17 +00:00
|
|
|
#[derive(Clone,PartialEq,Eq,Debug,Hash)]
|
|
|
|
pub enum AccountType {
|
|
|
|
Spotify = 0,
|
|
|
|
Facebook = 1,
|
|
|
|
}
|
|
|
|
|
|
|
|
impl ::protobuf::ProtobufEnum for AccountType {
|
|
|
|
fn value(&self) -> i32 {
|
|
|
|
*self as i32
|
|
|
|
}
|
|
|
|
|
|
|
|
fn from_i32(value: i32) -> ::std::option::Option<AccountType> {
|
|
|
|
match value {
|
|
|
|
0 => ::std::option::Option::Some(AccountType::Spotify),
|
|
|
|
1 => ::std::option::Option::Some(AccountType::Facebook),
|
|
|
|
_ => ::std::option::Option::None
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
fn values() -> &'static [Self] {
|
|
|
|
static values: &'static [AccountType] = &[
|
|
|
|
AccountType::Spotify,
|
|
|
|
AccountType::Facebook,
|
|
|
|
];
|
|
|
|
values
|
|
|
|
}
|
|
|
|
|
2018-09-28 10:02:38 +00:00
|
|
|
fn enum_descriptor_static() -> &'static ::protobuf::reflect::EnumDescriptor {
|
2016-11-21 02:48:17 +00:00
|
|
|
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::EnumDescriptor> = ::protobuf::lazy::Lazy {
|
|
|
|
lock: ::protobuf::lazy::ONCE_INIT,
|
|
|
|
ptr: 0 as *const ::protobuf::reflect::EnumDescriptor,
|
|
|
|
};
|
|
|
|
unsafe {
|
|
|
|
descriptor.get(|| {
|
|
|
|
::protobuf::reflect::EnumDescriptor::new("AccountType", file_descriptor_proto())
|
|
|
|
})
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
impl ::std::marker::Copy for AccountType {
|
|
|
|
}
|
|
|
|
|
2019-07-18 03:07:27 +00:00
|
|
|
impl ::std::default::Default for AccountType {
|
|
|
|
fn default() -> Self {
|
|
|
|
AccountType::Spotify
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2017-01-18 05:58:12 +00:00
|
|
|
impl ::protobuf::reflect::ProtobufValue for AccountType {
|
|
|
|
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
|
|
|
|
::protobuf::reflect::ProtobufValueRef::Enum(self.descriptor())
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2018-09-28 10:02:38 +00:00
|
|
|
static file_descriptor_proto_data: &'static [u8] = b"\
|
2019-07-18 03:07:27 +00:00
|
|
|
\n\x14authentication.proto\x12\0\"\xfe\x02\n\x17ClientResponseEncrypted\
|
|
|
|
\x12.\n\x11login_credentials\x18\n\x20\x02(\x0b2\x11.LoginCredentialsB\0\
|
|
|
|
\x12,\n\x10account_creation\x18\x14\x20\x01(\x0e2\x10.AccountCreationB\0\
|
|
|
|
\x129\n\x14fingerprint_response\x18\x1e\x20\x01(\x0b2\x19.FingerprintRes\
|
|
|
|
ponseUnionB\0\x12'\n\x0bpeer_ticket\x18(\x20\x01(\x0b2\x10.PeerTicketUni\
|
|
|
|
onB\0\x12\"\n\x0bsystem_info\x182\x20\x02(\x0b2\x0b.SystemInfoB\0\x12\
|
|
|
|
\x18\n\x0eplatform_model\x18<\x20\x01(\tB\0\x12\x18\n\x0eversion_string\
|
|
|
|
\x18F\x20\x01(\tB\0\x12#\n\x06appkey\x18P\x20\x01(\x0b2\x11.LibspotifyAp\
|
|
|
|
pKeyB\0\x12\"\n\x0bclient_info\x18Z\x20\x01(\x0b2\x0b.ClientInfoB\0:\0\"\
|
|
|
|
a\n\x10LoginCredentials\x12\x12\n\x08username\x18\n\x20\x01(\tB\0\x12\"\
|
|
|
|
\n\x03typ\x18\x14\x20\x02(\x0e2\x13.AuthenticationTypeB\0\x12\x13\n\taut\
|
|
|
|
h_data\x18\x1e\x20\x01(\x0cB\0:\0\"\x7f\n\x18FingerprintResponseUnion\
|
|
|
|
\x12*\n\x05grain\x18\n\x20\x01(\x0b2\x19.FingerprintGrainResponseB\0\x12\
|
|
|
|
5\n\x0bhmac_ripemd\x18\x14\x20\x01(\x0b2\x1e.FingerprintHmacRipemdRespon\
|
|
|
|
seB\0:\0\"5\n\x18FingerprintGrainResponse\x12\x17\n\rencrypted_key\x18\n\
|
|
|
|
\x20\x02(\x0cB\0:\0\"1\n\x1dFingerprintHmacRipemdResponse\x12\x0e\n\x04h\
|
|
|
|
mac\x18\n\x20\x02(\x0cB\0:\0\"e\n\x0fPeerTicketUnion\x12*\n\npublic_key\
|
|
|
|
\x18\n\x20\x01(\x0b2\x14.PeerTicketPublicKeyB\0\x12$\n\nold_ticket\x18\
|
|
|
|
\x14\x20\x01(\x0b2\x0e.PeerTicketOldB\0:\0\"-\n\x13PeerTicketPublicKey\
|
|
|
|
\x12\x14\n\npublic_key\x18\n\x20\x02(\x0cB\0:\0\"I\n\rPeerTicketOld\x12\
|
|
|
|
\x15\n\x0bpeer_ticket\x18\n\x20\x02(\x0cB\0\x12\x1f\n\x15peer_ticket_sig\
|
|
|
|
nature\x18\x14\x20\x02(\x0cB\0:\0\"\xff\x01\n\nSystemInfo\x12\x20\n\ncpu\
|
|
|
|
_family\x18\n\x20\x02(\x0e2\n.CpuFamilyB\0\x12\x15\n\x0bcpu_subtype\x18\
|
|
|
|
\x14\x20\x01(\rB\0\x12\x11\n\x07cpu_ext\x18\x1e\x20\x01(\rB\0\x12\x17\n\
|
|
|
|
\x05brand\x18(\x20\x01(\x0e2\x06.BrandB\0\x12\x15\n\x0bbrand_flags\x182\
|
|
|
|
\x20\x01(\rB\0\x12\x11\n\x02os\x18<\x20\x02(\x0e2\x03.OsB\0\x12\x14\n\no\
|
|
|
|
s_version\x18F\x20\x01(\rB\0\x12\x10\n\x06os_ext\x18P\x20\x01(\rB\0\x12#\
|
|
|
|
\n\x19system_information_string\x18Z\x20\x01(\tB\0\x12\x13\n\tdevice_id\
|
|
|
|
\x18d\x20\x01(\tB\0:\0\"|\n\x10LibspotifyAppKey\x12\x11\n\x07version\x18\
|
|
|
|
\x01\x20\x02(\rB\0\x12\x10\n\x06devkey\x18\x02\x20\x02(\x0cB\0\x12\x13\n\
|
|
|
|
\tsignature\x18\x03\x20\x02(\x0cB\0\x12\x13\n\tuseragent\x18\x04\x20\x02\
|
|
|
|
(\tB\0\x12\x17\n\rcallback_hash\x18\x05\x20\x02(\x0cB\0:\0\"X\n\nClientI\
|
|
|
|
nfo\x12\x11\n\x07limited\x18\x01\x20\x01(\x08B\0\x12!\n\x02fb\x18\x02\
|
|
|
|
\x20\x01(\x0b2\x13.ClientInfoFacebookB\0\x12\x12\n\x08language\x18\x03\
|
|
|
|
\x20\x01(\tB\0:\0\",\n\x12ClientInfoFacebook\x12\x14\n\nmachine_id\x18\
|
|
|
|
\x01\x20\x01(\tB\0:\0\"\xd3\x02\n\tAPWelcome\x12\x1c\n\x12canonical_user\
|
|
|
|
name\x18\n\x20\x02(\tB\0\x12.\n\x16account_type_logged_in\x18\x14\x20\
|
|
|
|
\x02(\x0e2\x0c.AccountTypeB\0\x122\n\x1acredentials_type_logged_in\x18\
|
|
|
|
\x19\x20\x02(\x0e2\x0c.AccountTypeB\0\x12=\n\x1ereusable_auth_credential\
|
|
|
|
s_type\x18\x1e\x20\x02(\x0e2\x13.AuthenticationTypeB\0\x12#\n\x19reusabl\
|
|
|
|
e_auth_credentials\x18(\x20\x02(\x0cB\0\x12\x14\n\nlfs_secret\x182\x20\
|
|
|
|
\x01(\x0cB\0\x12$\n\x0caccount_info\x18<\x20\x01(\x0b2\x0c.AccountInfoB\
|
|
|
|
\0\x12\"\n\x02fb\x18F\x20\x01(\x0b2\x14.AccountInfoFacebookB\0:\0\"a\n\
|
|
|
|
\x0bAccountInfo\x12&\n\x07spotify\x18\x01\x20\x01(\x0b2\x13.AccountInfoS\
|
|
|
|
potifyB\0\x12(\n\x08facebook\x18\x02\x20\x01(\x0b2\x14.AccountInfoFacebo\
|
|
|
|
okB\0:\0\"\x16\n\x12AccountInfoSpotify:\0\"E\n\x13AccountInfoFacebook\
|
|
|
|
\x12\x16\n\x0caccess_token\x18\x01\x20\x01(\tB\0\x12\x14\n\nmachine_id\
|
|
|
|
\x18\x02\x20\x01(\tB\0:\0*\xd8\x01\n\x12AuthenticationType\x12\x1c\n\x18\
|
|
|
|
AUTHENTICATION_USER_PASS\x10\0\x12-\n)AUTHENTICATION_STORED_SPOTIFY_CRED\
|
|
|
|
ENTIALS\x10\x01\x12.\n*AUTHENTICATION_STORED_FACEBOOK_CREDENTIALS\x10\
|
|
|
|
\x02\x12\x20\n\x1cAUTHENTICATION_SPOTIFY_TOKEN\x10\x03\x12!\n\x1dAUTHENT\
|
|
|
|
ICATION_FACEBOOK_TOKEN\x10\x04\x1a\0*[\n\x0fAccountCreation\x12\"\n\x1eA\
|
|
|
|
CCOUNT_CREATION_ALWAYS_PROMPT\x10\x01\x12\"\n\x1eACCOUNT_CREATION_ALWAYS\
|
|
|
|
_CREATE\x10\x03\x1a\0*\x9f\x01\n\tCpuFamily\x12\x0f\n\x0bCPU_UNKNOWN\x10\
|
|
|
|
\0\x12\x0b\n\x07CPU_X86\x10\x01\x12\x0e\n\nCPU_X86_64\x10\x02\x12\x0b\n\
|
|
|
|
\x07CPU_PPC\x10\x03\x12\x0e\n\nCPU_PPC_64\x10\x04\x12\x0b\n\x07CPU_ARM\
|
|
|
|
\x10\x05\x12\x0c\n\x08CPU_IA64\x10\x06\x12\n\n\x06CPU_SH\x10\x07\x12\x0c\
|
|
|
|
\n\x08CPU_MIPS\x10\x08\x12\x10\n\x0cCPU_BLACKFIN\x10\t\x1a\0*M\n\x05Bran\
|
|
|
|
d\x12\x13\n\x0fBRAND_UNBRANDED\x10\0\x12\r\n\tBRAND_INQ\x10\x01\x12\r\n\
|
|
|
|
\tBRAND_HTC\x10\x02\x12\x0f\n\x0bBRAND_NOKIA\x10\x03\x1a\0*\xd3\x02\n\
|
|
|
|
\x02Os\x12\x0e\n\nOS_UNKNOWN\x10\0\x12\x0e\n\nOS_WINDOWS\x10\x01\x12\n\n\
|
|
|
|
\x06OS_OSX\x10\x02\x12\r\n\tOS_IPHONE\x10\x03\x12\n\n\x06OS_S60\x10\x04\
|
|
|
|
\x12\x0c\n\x08OS_LINUX\x10\x05\x12\x11\n\rOS_WINDOWS_CE\x10\x06\x12\x0e\
|
|
|
|
\n\nOS_ANDROID\x10\x07\x12\x0b\n\x07OS_PALM\x10\x08\x12\x0e\n\nOS_FREEBS\
|
|
|
|
D\x10\t\x12\x11\n\rOS_BLACKBERRY\x10\n\x12\x0c\n\x08OS_SONOS\x10\x0b\x12\
|
|
|
|
\x0f\n\x0bOS_LOGITECH\x10\x0c\x12\n\n\x06OS_WP7\x10\r\x12\x0c\n\x08OS_ON\
|
|
|
|
KYO\x10\x0e\x12\x0e\n\nOS_PHILIPS\x10\x0f\x12\t\n\x05OS_WD\x10\x10\x12\
|
|
|
|
\x0c\n\x08OS_VOLVO\x10\x11\x12\x0b\n\x07OS_TIVO\x10\x12\x12\x0b\n\x07OS_\
|
|
|
|
AWOX\x10\x13\x12\x0c\n\x08OS_MEEGO\x10\x14\x12\r\n\tOS_QNXNTO\x10\x15\
|
|
|
|
\x12\n\n\x06OS_BCO\x10\x16\x1a\0**\n\x0bAccountType\x12\x0b\n\x07Spotify\
|
|
|
|
\x10\0\x12\x0c\n\x08Facebook\x10\x01\x1a\0B\0b\x06proto2\
|
2018-09-28 10:02:38 +00:00
|
|
|
";
|
2016-11-21 02:48:17 +00:00
|
|
|
|
|
|
|
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()
|
|
|
|
})
|
|
|
|
}
|
|
|
|
}
|