#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct Ab {
#[prost(message, optional, tag = "1")]
pub glance: ::core::option::Option<Glance>,
#[prost(enumeration = "Group", tag = "2")]
pub group: i32,
}
impl ::prost::Name for Ab {
const NAME: &'static str = "AB";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.AB".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.AB".into()
}
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct ArcConf {
#[prost(bool, tag = "1")]
pub is_support: bool,
#[prost(bool, tag = "2")]
pub disabled: bool,
#[prost(message, optional, tag = "3")]
pub extra_content: ::core::option::Option<ExtraContent>,
#[prost(int64, repeated, tag = "4")]
pub unsupport_scene: ::prost::alloc::vec::Vec<i64>,
}
impl ::prost::Name for ArcConf {
const NAME: &'static str = "ArcConf";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.ArcConf".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.ArcConf".into()
}
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct ButtonInfo {
#[prost(string, tag = "1")]
pub text: ::prost::alloc::string::String,
#[prost(string, tag = "2")]
pub text_color: ::prost::alloc::string::String,
#[prost(string, tag = "3")]
pub text_color_night: ::prost::alloc::string::String,
#[prost(string, tag = "4")]
pub bg_color: ::prost::alloc::string::String,
#[prost(string, tag = "5")]
pub bg_color_night: ::prost::alloc::string::String,
#[prost(string, tag = "6")]
pub link: ::prost::alloc::string::String,
#[prost(enumeration = "ButtonAction", tag = "7")]
pub action_type: i32,
#[prost(message, optional, tag = "8")]
pub report: ::core::option::Option<Report>,
#[prost(string, tag = "9")]
pub frame_color: ::prost::alloc::string::String,
#[prost(string, tag = "10")]
pub icon: ::prost::alloc::string::String,
}
impl ::prost::Name for ButtonInfo {
const NAME: &'static str = "ButtonInfo";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.ButtonInfo".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.ButtonInfo".into()
}
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct ButtonStyle {
#[prost(string, tag = "1")]
pub text: ::prost::alloc::string::String,
#[prost(string, tag = "2")]
pub text_color: ::prost::alloc::string::String,
#[prost(string, tag = "3")]
pub bg_color: ::prost::alloc::string::String,
#[prost(string, tag = "4")]
pub jump_link: ::prost::alloc::string::String,
}
impl ::prost::Name for ButtonStyle {
const NAME: &'static str = "ButtonStyle";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.ButtonStyle".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.ButtonStyle".into()
}
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct Chronos {
#[prost(string, tag = "1")]
pub md5: ::prost::alloc::string::String,
#[prost(string, tag = "2")]
pub file: ::prost::alloc::string::String,
}
impl ::prost::Name for Chronos {
const NAME: &'static str = "Chronos";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.Chronos".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.Chronos".into()
}
}
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct CloudConf {
#[prost(bool, tag = "1")]
pub show: bool,
#[prost(enumeration = "ConfType", tag = "2")]
pub conf_type: i32,
#[prost(message, optional, tag = "3")]
pub field_value: ::core::option::Option<FieldValue>,
#[prost(message, optional, tag = "4")]
pub conf_value: ::core::option::Option<ConfValue>,
}
impl ::prost::Name for CloudConf {
const NAME: &'static str = "CloudConf";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.CloudConf".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.CloudConf".into()
}
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct ComprehensiveToast {
#[prost(enumeration = "ToastType", tag = "1")]
pub r#type: i32,
#[prost(message, optional, tag = "2")]
pub button: ::core::option::Option<ButtonInfo>,
#[prost(string, tag = "3")]
pub icon: ::prost::alloc::string::String,
#[prost(message, optional, tag = "4")]
pub toast_text: ::core::option::Option<TextInfo>,
#[prost(message, optional, tag = "5")]
pub report: ::core::option::Option<Report>,
}
impl ::prost::Name for ComprehensiveToast {
const NAME: &'static str = "ComprehensiveToast";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.ComprehensiveToast".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.ComprehensiveToast".into()
}
}
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct ConfValue {
#[prost(oneof = "conf_value::Value", tags = "1, 2")]
pub value: ::core::option::Option<conf_value::Value>,
}
pub mod conf_value {
#[derive(Clone, Copy, PartialEq, ::prost::Oneof)]
pub enum Value {
#[prost(bool, tag = "1")]
SwitchVal(bool),
#[prost(int64, tag = "2")]
SelectedVal(i64),
}
}
impl ::prost::Name for ConfValue {
const NAME: &'static str = "ConfValue";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.ConfValue".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.ConfValue".into()
}
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct DashItem {
#[prost(int32, tag = "1")]
pub id: i32,
#[prost(string, tag = "2")]
pub base_url: ::prost::alloc::string::String,
#[prost(string, repeated, tag = "3")]
pub backup_url: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
#[prost(int32, tag = "4")]
pub bandwidth: i32,
#[prost(int32, tag = "5")]
pub codecid: i32,
#[prost(string, tag = "6")]
pub md5: ::prost::alloc::string::String,
#[prost(int64, tag = "7")]
pub size: i64,
#[prost(string, tag = "8")]
pub frame_rate: ::prost::alloc::string::String,
#[prost(string, tag = "9")]
pub widevine_pssh: ::prost::alloc::string::String,
#[prost(string, tag = "10")]
pub bilidrm_uri: ::prost::alloc::string::String,
}
impl ::prost::Name for DashItem {
const NAME: &'static str = "DashItem";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.DashItem".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.DashItem".into()
}
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct DashVideo {
#[prost(string, tag = "1")]
pub base_url: ::prost::alloc::string::String,
#[prost(string, repeated, tag = "2")]
pub backup_url: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
#[prost(int32, tag = "3")]
pub bandwidth: i32,
#[prost(int32, tag = "4")]
pub codecid: i32,
#[prost(string, tag = "5")]
pub md5: ::prost::alloc::string::String,
#[prost(int64, tag = "6")]
pub size: i64,
#[prost(int32, tag = "7")]
pub audio_id: i32,
#[prost(bool, tag = "8")]
pub no_rexcode: bool,
#[prost(string, tag = "9")]
pub frame_rate: ::prost::alloc::string::String,
#[prost(int32, tag = "10")]
pub width: i32,
#[prost(int32, tag = "11")]
pub height: i32,
#[prost(string, tag = "12")]
pub widevine_pssh: ::prost::alloc::string::String,
#[prost(string, tag = "13")]
pub bilidrm_uri: ::prost::alloc::string::String,
}
impl ::prost::Name for DashVideo {
const NAME: &'static str = "DashVideo";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.DashVideo".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.DashVideo".into()
}
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct Dialog {
#[prost(enumeration = "GuideStyle", tag = "1")]
pub style_type: i32,
#[prost(message, optional, tag = "2")]
pub report: ::core::option::Option<Report>,
#[prost(message, optional, tag = "3")]
pub title: ::core::option::Option<TextInfo>,
#[prost(message, optional, tag = "4")]
pub subtitle: ::core::option::Option<TextInfo>,
#[prost(message, repeated, tag = "5")]
pub button: ::prost::alloc::vec::Vec<ButtonInfo>,
}
impl ::prost::Name for Dialog {
const NAME: &'static str = "Dialog";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.Dialog".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.Dialog".into()
}
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct DolbyItem {
#[prost(enumeration = "dolby_item::Type", tag = "1")]
pub r#type: i32,
#[prost(message, repeated, tag = "2")]
pub audio: ::prost::alloc::vec::Vec<DashItem>,
}
pub mod dolby_item {
#[derive(
Clone,
Copy,
Debug,
PartialEq,
Eq,
Hash,
PartialOrd,
Ord,
::prost::Enumeration
)]
#[repr(i32)]
pub enum Type {
None = 0,
Common = 1,
Atmos = 2,
}
impl Type {
pub fn as_str_name(&self) -> &'static str {
match self {
Self::None => "NONE",
Self::Common => "COMMON",
Self::Atmos => "ATMOS",
}
}
pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
match value {
"NONE" => Some(Self::None),
"COMMON" => Some(Self::Common),
"ATMOS" => Some(Self::Atmos),
_ => None,
}
}
}
}
impl ::prost::Name for DolbyItem {
const NAME: &'static str = "DolbyItem";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.DolbyItem".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.DolbyItem".into()
}
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct Event {
#[prost(message, optional, tag = "1")]
pub shake: ::core::option::Option<Shake>,
}
impl ::prost::Name for Event {
const NAME: &'static str = "Event";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.Event".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.Event".into()
}
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct ExtraContent {
#[prost(string, tag = "1")]
pub disabled_reason: ::prost::alloc::string::String,
#[prost(int64, tag = "2")]
pub disabled_code: i64,
}
impl ::prost::Name for ExtraContent {
const NAME: &'static str = "ExtraContent";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.ExtraContent".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.ExtraContent".into()
}
}
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct FieldValue {
#[prost(oneof = "field_value::Value", tags = "1")]
pub value: ::core::option::Option<field_value::Value>,
}
pub mod field_value {
#[derive(Clone, Copy, PartialEq, ::prost::Oneof)]
pub enum Value {
#[prost(bool, tag = "1")]
Switch(bool),
}
}
impl ::prost::Name for FieldValue {
const NAME: &'static str = "FieldValue";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.FieldValue".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.FieldValue".into()
}
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct FormatDescription {
#[prost(int32, tag = "1")]
pub quality: i32,
#[prost(string, tag = "2")]
pub format: ::prost::alloc::string::String,
#[prost(string, tag = "3")]
pub description: ::prost::alloc::string::String,
#[prost(string, tag = "4")]
pub new_description: ::prost::alloc::string::String,
#[prost(string, tag = "5")]
pub display_desc: ::prost::alloc::string::String,
#[prost(string, tag = "6")]
pub superscript: ::prost::alloc::string::String,
}
impl ::prost::Name for FormatDescription {
const NAME: &'static str = "FormatDescription";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.FormatDescription".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.FormatDescription".into()
}
}
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct Glance {
#[prost(bool, tag = "1")]
pub can_watch: bool,
#[prost(int64, tag = "2")]
pub times: i64,
#[prost(int64, tag = "3")]
pub duration: i64,
}
impl ::prost::Name for Glance {
const NAME: &'static str = "Glance";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.Glance".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.Glance".into()
}
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct LossLessItem {
#[prost(bool, tag = "1")]
pub is_lossless_audio: bool,
#[prost(message, optional, tag = "2")]
pub audio: ::core::option::Option<DashItem>,
#[prost(bool, tag = "3")]
pub need_vip: bool,
}
impl ::prost::Name for LossLessItem {
const NAME: &'static str = "LossLessItem";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.LossLessItem".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.LossLessItem".into()
}
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct MultiDashVideo {
#[prost(message, repeated, tag = "1")]
pub dash_videos: ::prost::alloc::vec::Vec<DashVideo>,
}
impl ::prost::Name for MultiDashVideo {
const NAME: &'static str = "MultiDashVideo";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.MultiDashVideo".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.MultiDashVideo".into()
}
}
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct PlayAbilityConf {
#[prost(message, optional, tag = "1")]
pub background_play_conf: ::core::option::Option<CloudConf>,
#[prost(message, optional, tag = "2")]
pub flip_conf: ::core::option::Option<CloudConf>,
#[prost(message, optional, tag = "3")]
pub cast_conf: ::core::option::Option<CloudConf>,
#[prost(message, optional, tag = "4")]
pub feedback_conf: ::core::option::Option<CloudConf>,
#[prost(message, optional, tag = "5")]
pub subtitle_conf: ::core::option::Option<CloudConf>,
#[prost(message, optional, tag = "6")]
pub playback_rate_conf: ::core::option::Option<CloudConf>,
#[prost(message, optional, tag = "7")]
pub time_up_conf: ::core::option::Option<CloudConf>,
#[prost(message, optional, tag = "8")]
pub playback_mode_conf: ::core::option::Option<CloudConf>,
#[prost(message, optional, tag = "9")]
pub scale_mode_conf: ::core::option::Option<CloudConf>,
#[prost(message, optional, tag = "10")]
pub like_conf: ::core::option::Option<CloudConf>,
#[prost(message, optional, tag = "11")]
pub dislike_conf: ::core::option::Option<CloudConf>,
#[prost(message, optional, tag = "12")]
pub coin_conf: ::core::option::Option<CloudConf>,
#[prost(message, optional, tag = "13")]
pub elec_conf: ::core::option::Option<CloudConf>,
#[prost(message, optional, tag = "14")]
pub share_conf: ::core::option::Option<CloudConf>,
#[prost(message, optional, tag = "15")]
pub screen_shot_conf: ::core::option::Option<CloudConf>,
#[prost(message, optional, tag = "16")]
pub lock_screen_conf: ::core::option::Option<CloudConf>,
#[prost(message, optional, tag = "17")]
pub recommend_conf: ::core::option::Option<CloudConf>,
#[prost(message, optional, tag = "18")]
pub playback_speed_conf: ::core::option::Option<CloudConf>,
#[prost(message, optional, tag = "19")]
pub definition_conf: ::core::option::Option<CloudConf>,
#[prost(message, optional, tag = "20")]
pub selections_conf: ::core::option::Option<CloudConf>,
#[prost(message, optional, tag = "21")]
pub next_conf: ::core::option::Option<CloudConf>,
#[prost(message, optional, tag = "22")]
pub edit_dm_conf: ::core::option::Option<CloudConf>,
#[prost(message, optional, tag = "23")]
pub small_window_conf: ::core::option::Option<CloudConf>,
#[prost(message, optional, tag = "24")]
pub shake_conf: ::core::option::Option<CloudConf>,
#[prost(message, optional, tag = "25")]
pub outer_dm_conf: ::core::option::Option<CloudConf>,
#[prost(message, optional, tag = "26")]
pub inner_dm_conf: ::core::option::Option<CloudConf>,
#[prost(message, optional, tag = "27")]
pub panorama_conf: ::core::option::Option<CloudConf>,
#[prost(message, optional, tag = "28")]
pub dolby_conf: ::core::option::Option<CloudConf>,
#[prost(message, optional, tag = "29")]
pub color_filter_conf: ::core::option::Option<CloudConf>,
#[prost(message, optional, tag = "30")]
pub loss_less_conf: ::core::option::Option<CloudConf>,
}
impl ::prost::Name for PlayAbilityConf {
const NAME: &'static str = "PlayAbilityConf";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.PlayAbilityConf".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.PlayAbilityConf".into()
}
}
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct PlayArc {
#[prost(bool, tag = "1")]
pub is_preview: bool,
}
impl ::prost::Name for PlayArc {
const NAME: &'static str = "PlayArc";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.PlayArc".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.PlayArc".into()
}
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct PlayArcConf {
#[prost(message, optional, tag = "1")]
pub background_play_conf: ::core::option::Option<ArcConf>,
#[prost(message, optional, tag = "2")]
pub flip_conf: ::core::option::Option<ArcConf>,
#[prost(message, optional, tag = "3")]
pub cast_conf: ::core::option::Option<ArcConf>,
#[prost(message, optional, tag = "4")]
pub feedback_conf: ::core::option::Option<ArcConf>,
#[prost(message, optional, tag = "5")]
pub subtitle_conf: ::core::option::Option<ArcConf>,
#[prost(message, optional, tag = "6")]
pub playback_rate_conf: ::core::option::Option<ArcConf>,
#[prost(message, optional, tag = "7")]
pub time_up_conf: ::core::option::Option<ArcConf>,
#[prost(message, optional, tag = "8")]
pub playback_mode_conf: ::core::option::Option<ArcConf>,
#[prost(message, optional, tag = "9")]
pub scale_mode_conf: ::core::option::Option<ArcConf>,
#[prost(message, optional, tag = "10")]
pub like_conf: ::core::option::Option<ArcConf>,
#[prost(message, optional, tag = "11")]
pub dislike_conf: ::core::option::Option<ArcConf>,
#[prost(message, optional, tag = "12")]
pub coin_conf: ::core::option::Option<ArcConf>,
#[prost(message, optional, tag = "13")]
pub elec_conf: ::core::option::Option<ArcConf>,
#[prost(message, optional, tag = "14")]
pub share_conf: ::core::option::Option<ArcConf>,
#[prost(message, optional, tag = "15")]
pub screen_shot_conf: ::core::option::Option<ArcConf>,
#[prost(message, optional, tag = "16")]
pub lock_screen_conf: ::core::option::Option<ArcConf>,
#[prost(message, optional, tag = "17")]
pub recommend_conf: ::core::option::Option<ArcConf>,
#[prost(message, optional, tag = "18")]
pub playback_speed_conf: ::core::option::Option<ArcConf>,
#[prost(message, optional, tag = "19")]
pub definition_conf: ::core::option::Option<ArcConf>,
#[prost(message, optional, tag = "20")]
pub selections_conf: ::core::option::Option<ArcConf>,
#[prost(message, optional, tag = "21")]
pub next_conf: ::core::option::Option<ArcConf>,
#[prost(message, optional, tag = "22")]
pub edit_dm_conf: ::core::option::Option<ArcConf>,
#[prost(message, optional, tag = "23")]
pub small_window_conf: ::core::option::Option<ArcConf>,
#[prost(message, optional, tag = "24")]
pub shake_conf: ::core::option::Option<ArcConf>,
#[prost(message, optional, tag = "25")]
pub outer_dm_conf: ::core::option::Option<ArcConf>,
#[prost(message, optional, tag = "26")]
pub inner_dm_conf: ::core::option::Option<ArcConf>,
#[prost(message, optional, tag = "27")]
pub panorama_conf: ::core::option::Option<ArcConf>,
#[prost(message, optional, tag = "28")]
pub dolby_conf: ::core::option::Option<ArcConf>,
#[prost(message, optional, tag = "29")]
pub screen_recording_conf: ::core::option::Option<ArcConf>,
#[prost(message, optional, tag = "30")]
pub color_filter_conf: ::core::option::Option<ArcConf>,
#[prost(message, optional, tag = "31")]
pub loss_less_conf: ::core::option::Option<ArcConf>,
#[prost(message, optional, tag = "32")]
pub system_record_conf: ::core::option::Option<ArcConf>,
}
impl ::prost::Name for PlayArcConf {
const NAME: &'static str = "PlayArcConf";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.PlayArcConf".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.PlayArcConf".into()
}
}
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct PlayConfEditReply {}
impl ::prost::Name for PlayConfEditReply {
const NAME: &'static str = "PlayConfEditReply";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.PlayConfEditReply".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.PlayConfEditReply".into()
}
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct PlayConfEditReq {
#[prost(message, repeated, tag = "1")]
pub play_conf: ::prost::alloc::vec::Vec<PlayConfState>,
}
impl ::prost::Name for PlayConfEditReq {
const NAME: &'static str = "PlayConfEditReq";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.PlayConfEditReq".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.PlayConfEditReq".into()
}
}
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct PlayConfReply {
#[prost(message, optional, tag = "1")]
pub play_conf: ::core::option::Option<PlayAbilityConf>,
}
impl ::prost::Name for PlayConfReply {
const NAME: &'static str = "PlayConfReply";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.PlayConfReply".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.PlayConfReply".into()
}
}
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct PlayConfReq {}
impl ::prost::Name for PlayConfReq {
const NAME: &'static str = "PlayConfReq";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.PlayConfReq".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.PlayConfReq".into()
}
}
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct PlayConfState {
#[prost(enumeration = "ConfType", tag = "1")]
pub conf_type: i32,
#[prost(bool, tag = "2")]
pub show: bool,
#[prost(message, optional, tag = "3")]
pub field_value: ::core::option::Option<FieldValue>,
#[prost(message, optional, tag = "4")]
pub conf_value: ::core::option::Option<ConfValue>,
}
impl ::prost::Name for PlayConfState {
const NAME: &'static str = "PlayConfState";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.PlayConfState".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.PlayConfState".into()
}
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct PlayLimit {
#[prost(enumeration = "PlayLimitCode", tag = "1")]
pub code: i32,
#[prost(string, tag = "2")]
pub message: ::prost::alloc::string::String,
#[prost(string, tag = "3")]
pub sub_message: ::prost::alloc::string::String,
#[prost(message, optional, tag = "4")]
pub button: ::core::option::Option<ButtonStyle>,
}
impl ::prost::Name for PlayLimit {
const NAME: &'static str = "PlayLimit";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.PlayLimit".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.PlayLimit".into()
}
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct PlayUrlReply {
#[prost(int32, tag = "1")]
pub quality: i32,
#[prost(string, tag = "2")]
pub format: ::prost::alloc::string::String,
#[prost(int64, tag = "3")]
pub timelength: i64,
#[prost(int32, tag = "4")]
pub video_codecid: i32,
#[prost(int32, tag = "5")]
pub fnver: i32,
#[prost(int32, tag = "6")]
pub fnval: i32,
#[prost(bool, tag = "7")]
pub video_project: bool,
#[prost(message, repeated, tag = "8")]
pub durl: ::prost::alloc::vec::Vec<ResponseUrl>,
#[prost(message, optional, tag = "9")]
pub dash: ::core::option::Option<ResponseDash>,
#[prost(int32, tag = "10")]
pub no_rexcode: i32,
#[prost(message, optional, tag = "11")]
pub upgrade_limit: ::core::option::Option<UpgradeLimit>,
#[prost(message, repeated, tag = "12")]
pub support_formats: ::prost::alloc::vec::Vec<FormatDescription>,
#[prost(enumeration = "VideoType", tag = "13")]
pub r#type: i32,
#[prost(message, optional, tag = "14")]
pub vip_risk: ::core::option::Option<VipRisk>,
}
impl ::prost::Name for PlayUrlReply {
const NAME: &'static str = "PlayURLReply";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.PlayURLReply".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.PlayURLReply".into()
}
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct PlayUrlReq {
#[prost(int64, tag = "1")]
pub aid: i64,
#[prost(int64, tag = "2")]
pub cid: i64,
#[prost(int64, tag = "3")]
pub qn: i64,
#[prost(int32, tag = "4")]
pub fnver: i32,
#[prost(int32, tag = "5")]
pub fnval: i32,
#[prost(int32, tag = "6")]
pub download: i32,
#[prost(int32, tag = "7")]
pub force_host: i32,
#[prost(bool, tag = "8")]
pub fourk: bool,
#[prost(string, tag = "9")]
pub spmid: ::prost::alloc::string::String,
#[prost(string, tag = "10")]
pub from_spmid: ::prost::alloc::string::String,
}
impl ::prost::Name for PlayUrlReq {
const NAME: &'static str = "PlayURLReq";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.PlayURLReq".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.PlayURLReq".into()
}
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct PlayViewReply {
#[prost(message, optional, tag = "1")]
pub video_info: ::core::option::Option<VideoInfo>,
#[prost(message, optional, tag = "2")]
pub play_conf: ::core::option::Option<PlayAbilityConf>,
#[prost(message, optional, tag = "3")]
pub upgrade_limit: ::core::option::Option<UpgradeLimit>,
#[prost(message, optional, tag = "4")]
pub chronos: ::core::option::Option<Chronos>,
#[prost(message, optional, tag = "5")]
pub play_arc: ::core::option::Option<PlayArcConf>,
#[prost(message, optional, tag = "6")]
pub event: ::core::option::Option<Event>,
#[prost(message, optional, tag = "7")]
pub ab: ::core::option::Option<Ab>,
#[prost(message, optional, tag = "8")]
pub play_limit: ::core::option::Option<PlayLimit>,
#[prost(message, optional, tag = "9")]
pub view_info: ::core::option::Option<ViewInfo>,
#[prost(message, optional, tag = "10")]
pub arc: ::core::option::Option<PlayArc>,
}
impl ::prost::Name for PlayViewReply {
const NAME: &'static str = "PlayViewReply";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.PlayViewReply".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.PlayViewReply".into()
}
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct PlayViewReq {
#[prost(int64, tag = "1")]
pub aid: i64,
#[prost(int64, tag = "2")]
pub cid: i64,
#[prost(int64, tag = "3")]
pub qn: i64,
#[prost(int32, tag = "4")]
pub fnver: i32,
#[prost(int32, tag = "5")]
pub fnval: i32,
#[prost(int32, tag = "6")]
pub download: i32,
#[prost(int32, tag = "7")]
pub force_host: i32,
#[prost(bool, tag = "8")]
pub fourk: bool,
#[prost(string, tag = "9")]
pub spmid: ::prost::alloc::string::String,
#[prost(string, tag = "10")]
pub from_spmid: ::prost::alloc::string::String,
#[prost(int32, tag = "11")]
pub teenagers_mode: i32,
#[prost(enumeration = "CodeType", tag = "12")]
pub prefer_codec_type: i32,
#[prost(enumeration = "Business", tag = "13")]
pub business: i32,
#[prost(int64, tag = "14")]
pub voice_balance: i64,
}
impl ::prost::Name for PlayViewReq {
const NAME: &'static str = "PlayViewReq";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.PlayViewReq".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.PlayViewReq".into()
}
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct ProjectReply {
#[prost(message, optional, tag = "1")]
pub project: ::core::option::Option<PlayUrlReply>,
}
impl ::prost::Name for ProjectReply {
const NAME: &'static str = "ProjectReply";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.ProjectReply".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.ProjectReply".into()
}
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct ProjectReq {
#[prost(int64, tag = "1")]
pub aid: i64,
#[prost(int64, tag = "2")]
pub cid: i64,
#[prost(int64, tag = "3")]
pub qn: i64,
#[prost(int32, tag = "4")]
pub fnver: i32,
#[prost(int32, tag = "5")]
pub fnval: i32,
#[prost(int32, tag = "6")]
pub download: i32,
#[prost(int32, tag = "7")]
pub force_host: i32,
#[prost(bool, tag = "8")]
pub fourk: bool,
#[prost(string, tag = "9")]
pub spmid: ::prost::alloc::string::String,
#[prost(string, tag = "10")]
pub from_spmid: ::prost::alloc::string::String,
#[prost(int32, tag = "11")]
pub protocol: i32,
#[prost(int32, tag = "12")]
pub device_type: i32,
}
impl ::prost::Name for ProjectReq {
const NAME: &'static str = "ProjectReq";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.ProjectReq".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.ProjectReq".into()
}
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct PromptBar {
#[prost(message, optional, tag = "1")]
pub title: ::core::option::Option<TextInfo>,
#[prost(message, optional, tag = "2")]
pub sub_title: ::core::option::Option<TextInfo>,
#[prost(string, tag = "3")]
pub sub_title_icon: ::prost::alloc::string::String,
#[prost(string, tag = "4")]
pub bg_image: ::prost::alloc::string::String,
#[prost(message, repeated, tag = "5")]
pub button: ::prost::alloc::vec::Vec<ButtonInfo>,
#[prost(message, optional, tag = "6")]
pub report: ::core::option::Option<Report>,
}
impl ::prost::Name for PromptBar {
const NAME: &'static str = "PromptBar";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.PromptBar".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.PromptBar".into()
}
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct Report {
#[prost(string, tag = "1")]
pub show_event_id: ::prost::alloc::string::String,
#[prost(string, tag = "2")]
pub click_event_id: ::prost::alloc::string::String,
#[prost(string, tag = "3")]
pub extends: ::prost::alloc::string::String,
}
impl ::prost::Name for Report {
const NAME: &'static str = "Report";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.Report".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.Report".into()
}
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct ResponseDash {
#[prost(message, repeated, tag = "1")]
pub video: ::prost::alloc::vec::Vec<DashItem>,
#[prost(message, repeated, tag = "2")]
pub audio: ::prost::alloc::vec::Vec<DashItem>,
}
impl ::prost::Name for ResponseDash {
const NAME: &'static str = "ResponseDash";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.ResponseDash".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.ResponseDash".into()
}
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct ResponseUrl {
#[prost(int32, tag = "1")]
pub order: i32,
#[prost(int64, tag = "2")]
pub length: i64,
#[prost(int64, tag = "3")]
pub size: i64,
#[prost(string, tag = "4")]
pub url: ::prost::alloc::string::String,
#[prost(string, repeated, tag = "5")]
pub backup_url: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
#[prost(string, tag = "6")]
pub md5: ::prost::alloc::string::String,
#[prost(int32, tag = "7")]
pub quality: i32,
}
impl ::prost::Name for ResponseUrl {
const NAME: &'static str = "ResponseUrl";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.ResponseUrl".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.ResponseUrl".into()
}
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct Scheme {
#[prost(enumeration = "scheme::ActionType", tag = "1")]
pub action_type: i32,
#[prost(string, tag = "2")]
pub toast: ::prost::alloc::string::String,
}
pub mod scheme {
#[derive(
Clone,
Copy,
Debug,
PartialEq,
Eq,
Hash,
PartialOrd,
Ord,
::prost::Enumeration
)]
#[repr(i32)]
pub enum ActionType {
UnknownActionType = 0,
ShowToast = 1,
}
impl ActionType {
pub fn as_str_name(&self) -> &'static str {
match self {
Self::UnknownActionType => "UNKNOWN_ActionType",
Self::ShowToast => "SHOW_TOAST",
}
}
pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
match value {
"UNKNOWN_ActionType" => Some(Self::UnknownActionType),
"SHOW_TOAST" => Some(Self::ShowToast),
_ => None,
}
}
}
}
impl ::prost::Name for Scheme {
const NAME: &'static str = "Scheme";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.Scheme".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.Scheme".into()
}
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct SegmentVideo {
#[prost(message, repeated, tag = "1")]
pub segment: ::prost::alloc::vec::Vec<ResponseUrl>,
}
impl ::prost::Name for SegmentVideo {
const NAME: &'static str = "SegmentVideo";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.SegmentVideo".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.SegmentVideo".into()
}
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct Shake {
#[prost(string, tag = "1")]
pub file: ::prost::alloc::string::String,
}
impl ::prost::Name for Shake {
const NAME: &'static str = "Shake";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.Shake".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.Shake".into()
}
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct Stream {
#[prost(message, optional, tag = "1")]
pub stream_info: ::core::option::Option<StreamInfo>,
#[prost(oneof = "stream::Content", tags = "2, 3, 4")]
pub content: ::core::option::Option<stream::Content>,
}
pub mod stream {
#[derive(Clone, PartialEq, ::prost::Oneof)]
pub enum Content {
#[prost(message, tag = "2")]
DashVideo(super::DashVideo),
#[prost(message, tag = "3")]
SegmentVideo(super::SegmentVideo),
#[prost(message, tag = "4")]
MultiDashVideo(super::MultiDashVideo),
}
}
impl ::prost::Name for Stream {
const NAME: &'static str = "Stream";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.Stream".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.Stream".into()
}
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct StreamInfo {
#[prost(int32, tag = "1")]
pub quality: i32,
#[prost(string, tag = "2")]
pub format: ::prost::alloc::string::String,
#[prost(string, tag = "3")]
pub description: ::prost::alloc::string::String,
#[prost(enumeration = "PlayErr", tag = "4")]
pub err_code: i32,
#[prost(message, optional, tag = "5")]
pub limit: ::core::option::Option<StreamLimit>,
#[prost(bool, tag = "6")]
pub need_vip: bool,
#[prost(bool, tag = "7")]
pub need_login: bool,
#[prost(bool, tag = "8")]
pub intact: bool,
#[prost(bool, tag = "9")]
pub no_rexcode: bool,
#[prost(int64, tag = "10")]
pub attribute: i64,
#[prost(string, tag = "11")]
pub new_description: ::prost::alloc::string::String,
#[prost(string, tag = "12")]
pub display_desc: ::prost::alloc::string::String,
#[prost(string, tag = "13")]
pub superscript: ::prost::alloc::string::String,
#[prost(bool, tag = "14")]
pub vip_free: bool,
#[prost(string, tag = "15")]
pub subtitle: ::prost::alloc::string::String,
#[prost(message, optional, tag = "16")]
pub scheme: ::core::option::Option<Scheme>,
#[prost(bool, tag = "17")]
pub support_drm: bool,
#[prost(bool, tag = "18")]
pub has_preview: bool,
#[prost(int64, tag = "19")]
pub extend_attribute: i64,
}
impl ::prost::Name for StreamInfo {
const NAME: &'static str = "StreamInfo";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.StreamInfo".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.StreamInfo".into()
}
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct StreamLimit {
#[prost(string, tag = "1")]
pub title: ::prost::alloc::string::String,
#[prost(string, tag = "2")]
pub uri: ::prost::alloc::string::String,
#[prost(string, tag = "3")]
pub msg: ::prost::alloc::string::String,
}
impl ::prost::Name for StreamLimit {
const NAME: &'static str = "StreamLimit";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.StreamLimit".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.StreamLimit".into()
}
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct TextInfo {
#[prost(string, tag = "1")]
pub text: ::prost::alloc::string::String,
#[prost(string, tag = "2")]
pub text_color: ::prost::alloc::string::String,
#[prost(string, tag = "3")]
pub text_color_night: ::prost::alloc::string::String,
}
impl ::prost::Name for TextInfo {
const NAME: &'static str = "TextInfo";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.TextInfo".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.TextInfo".into()
}
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct UpgradeButton {
#[prost(string, tag = "1")]
pub title: ::prost::alloc::string::String,
#[prost(string, tag = "2")]
pub link: ::prost::alloc::string::String,
}
impl ::prost::Name for UpgradeButton {
const NAME: &'static str = "UpgradeButton";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.UpgradeButton".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.UpgradeButton".into()
}
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct UpgradeLimit {
#[prost(int32, tag = "1")]
pub code: i32,
#[prost(string, tag = "2")]
pub message: ::prost::alloc::string::String,
#[prost(string, tag = "3")]
pub image: ::prost::alloc::string::String,
#[prost(message, optional, tag = "4")]
pub button: ::core::option::Option<UpgradeButton>,
}
impl ::prost::Name for UpgradeLimit {
const NAME: &'static str = "UpgradeLimit";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.UpgradeLimit".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.UpgradeLimit".into()
}
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct VideoInfo {
#[prost(int32, tag = "1")]
pub quality: i32,
#[prost(string, tag = "2")]
pub format: ::prost::alloc::string::String,
#[prost(int64, tag = "3")]
pub timelength: i64,
#[prost(int32, tag = "4")]
pub video_codecid: i32,
#[prost(message, repeated, tag = "5")]
pub stream_list: ::prost::alloc::vec::Vec<Stream>,
#[prost(message, repeated, tag = "6")]
pub dash_audio: ::prost::alloc::vec::Vec<DashItem>,
#[prost(message, optional, tag = "7")]
pub dolby: ::core::option::Option<DolbyItem>,
#[prost(message, optional, tag = "8")]
pub volume: ::core::option::Option<VolumeInfo>,
#[prost(message, optional, tag = "9")]
pub loss_less_item: ::core::option::Option<LossLessItem>,
#[prost(int64, tag = "10")]
pub main_timelength: i64,
}
impl ::prost::Name for VideoInfo {
const NAME: &'static str = "VideoInfo";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.VideoInfo".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.VideoInfo".into()
}
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct ViewInfo {
#[prost(map = "string, message", tag = "1")]
pub dialog_map: ::std::collections::HashMap<::prost::alloc::string::String, Dialog>,
#[prost(message, optional, tag = "2")]
pub prompt_bar: ::core::option::Option<PromptBar>,
#[prost(message, repeated, tag = "3")]
pub toasts: ::prost::alloc::vec::Vec<ComprehensiveToast>,
}
impl ::prost::Name for ViewInfo {
const NAME: &'static str = "ViewInfo";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.ViewInfo".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.ViewInfo".into()
}
}
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct VipRisk {
#[prost(bool, tag = "1")]
pub allow: bool,
#[prost(int64, tag = "2")]
pub r#type: i64,
#[prost(int64, tag = "3")]
pub reason: i64,
#[prost(int64, tag = "4")]
pub device_status: i64,
}
impl ::prost::Name for VipRisk {
const NAME: &'static str = "VipRisk";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.VipRisk".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.VipRisk".into()
}
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct VolumeInfo {
#[prost(double, tag = "1")]
pub measured_i: f64,
#[prost(double, tag = "2")]
pub measured_lra: f64,
#[prost(double, tag = "3")]
pub measured_tp: f64,
#[prost(double, tag = "4")]
pub measured_threshold: f64,
#[prost(double, tag = "5")]
pub target_offset: f64,
#[prost(double, tag = "6")]
pub target_i: f64,
#[prost(double, tag = "7")]
pub target_tp: f64,
#[prost(map = "string, string", tag = "8")]
pub multi_scene_args: ::std::collections::HashMap<
::prost::alloc::string::String,
::prost::alloc::string::String,
>,
}
impl ::prost::Name for VolumeInfo {
const NAME: &'static str = "VolumeInfo";
const PACKAGE: &'static str = "bilibili.app.playurl.v1";
fn full_name() -> ::prost::alloc::string::String {
"bilibili.app.playurl.v1.VolumeInfo".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/bilibili.app.playurl.v1.VolumeInfo".into()
}
}
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
#[repr(i32)]
pub enum Business {
Unknown = 0,
Story = 1,
}
impl Business {
pub fn as_str_name(&self) -> &'static str {
match self {
Self::Unknown => "UNKNOWN",
Self::Story => "STORY",
}
}
pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
match value {
"UNKNOWN" => Some(Self::Unknown),
"STORY" => Some(Self::Story),
_ => None,
}
}
}
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
#[repr(i32)]
pub enum ButtonAction {
ButtonUnknown = 0,
Chargingplus = 1,
}
impl ButtonAction {
pub fn as_str_name(&self) -> &'static str {
match self {
Self::ButtonUnknown => "BUTTON_UNKNOWN",
Self::Chargingplus => "CHARGINGPLUS",
}
}
pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
match value {
"BUTTON_UNKNOWN" => Some(Self::ButtonUnknown),
"CHARGINGPLUS" => Some(Self::Chargingplus),
_ => None,
}
}
}
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
#[repr(i32)]
pub enum CodeType {
Nocode = 0,
Code264 = 1,
Code265 = 2,
Codeav1 = 3,
}
impl CodeType {
pub fn as_str_name(&self) -> &'static str {
match self {
Self::Nocode => "NOCODE",
Self::Code264 => "CODE264",
Self::Code265 => "CODE265",
Self::Codeav1 => "CODEAV1",
}
}
pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
match value {
"NOCODE" => Some(Self::Nocode),
"CODE264" => Some(Self::Code264),
"CODE265" => Some(Self::Code265),
"CODEAV1" => Some(Self::Codeav1),
_ => None,
}
}
}
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
#[repr(i32)]
pub enum ConfType {
NoType = 0,
Flipconf = 1,
Castconf = 2,
Feedback = 3,
Subtitle = 4,
Playbackrate = 5,
Timeup = 6,
Playbackmode = 7,
Scalemode = 8,
Backgroundplay = 9,
Like = 10,
Dislike = 11,
Coin = 12,
Elec = 13,
Share = 14,
Screenshot = 15,
Lockscreen = 16,
Recommend = 17,
Playbackspeed = 18,
Definition = 19,
Selections = 20,
Next = 21,
Editdm = 22,
Smallwindow = 23,
Shake = 24,
Outerdm = 25,
Innerdm = 26,
Panorama = 27,
Dolby = 28,
Colorfilter = 29,
Lossless = 30,
}
impl ConfType {
pub fn as_str_name(&self) -> &'static str {
match self {
Self::NoType => "NoType",
Self::Flipconf => "FLIPCONF",
Self::Castconf => "CASTCONF",
Self::Feedback => "FEEDBACK",
Self::Subtitle => "SUBTITLE",
Self::Playbackrate => "PLAYBACKRATE",
Self::Timeup => "TIMEUP",
Self::Playbackmode => "PLAYBACKMODE",
Self::Scalemode => "SCALEMODE",
Self::Backgroundplay => "BACKGROUNDPLAY",
Self::Like => "LIKE",
Self::Dislike => "DISLIKE",
Self::Coin => "COIN",
Self::Elec => "ELEC",
Self::Share => "SHARE",
Self::Screenshot => "SCREENSHOT",
Self::Lockscreen => "LOCKSCREEN",
Self::Recommend => "RECOMMEND",
Self::Playbackspeed => "PLAYBACKSPEED",
Self::Definition => "DEFINITION",
Self::Selections => "SELECTIONS",
Self::Next => "NEXT",
Self::Editdm => "EDITDM",
Self::Smallwindow => "SMALLWINDOW",
Self::Shake => "SHAKE",
Self::Outerdm => "OUTERDM",
Self::Innerdm => "INNERDM",
Self::Panorama => "PANORAMA",
Self::Dolby => "DOLBY",
Self::Colorfilter => "COLORFILTER",
Self::Lossless => "LOSSLESS",
}
}
pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
match value {
"NoType" => Some(Self::NoType),
"FLIPCONF" => Some(Self::Flipconf),
"CASTCONF" => Some(Self::Castconf),
"FEEDBACK" => Some(Self::Feedback),
"SUBTITLE" => Some(Self::Subtitle),
"PLAYBACKRATE" => Some(Self::Playbackrate),
"TIMEUP" => Some(Self::Timeup),
"PLAYBACKMODE" => Some(Self::Playbackmode),
"SCALEMODE" => Some(Self::Scalemode),
"BACKGROUNDPLAY" => Some(Self::Backgroundplay),
"LIKE" => Some(Self::Like),
"DISLIKE" => Some(Self::Dislike),
"COIN" => Some(Self::Coin),
"ELEC" => Some(Self::Elec),
"SHARE" => Some(Self::Share),
"SCREENSHOT" => Some(Self::Screenshot),
"LOCKSCREEN" => Some(Self::Lockscreen),
"RECOMMEND" => Some(Self::Recommend),
"PLAYBACKSPEED" => Some(Self::Playbackspeed),
"DEFINITION" => Some(Self::Definition),
"SELECTIONS" => Some(Self::Selections),
"NEXT" => Some(Self::Next),
"EDITDM" => Some(Self::Editdm),
"SMALLWINDOW" => Some(Self::Smallwindow),
"SHAKE" => Some(Self::Shake),
"OUTERDM" => Some(Self::Outerdm),
"INNERDM" => Some(Self::Innerdm),
"PANORAMA" => Some(Self::Panorama),
"DOLBY" => Some(Self::Dolby),
"COLORFILTER" => Some(Self::Colorfilter),
"LOSSLESS" => Some(Self::Lossless),
_ => None,
}
}
}
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
#[repr(i32)]
pub enum Group {
UnknownGroup = 0,
A = 1,
B = 2,
C = 3,
}
impl Group {
pub fn as_str_name(&self) -> &'static str {
match self {
Self::UnknownGroup => "UnknownGroup",
Self::A => "A",
Self::B => "B",
Self::C => "C",
}
}
pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
match value {
"UnknownGroup" => Some(Self::UnknownGroup),
"A" => Some(Self::A),
"B" => Some(Self::B),
"C" => Some(Self::C),
_ => None,
}
}
}
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
#[repr(i32)]
pub enum GuideStyle {
StyleUnknown = 0,
ChargingText = 1,
}
impl GuideStyle {
pub fn as_str_name(&self) -> &'static str {
match self {
Self::StyleUnknown => "STYLE_UNKNOWN",
Self::ChargingText => "CHARGING_TEXT",
}
}
pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
match value {
"STYLE_UNKNOWN" => Some(Self::StyleUnknown),
"CHARGING_TEXT" => Some(Self::ChargingText),
_ => None,
}
}
}
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
#[repr(i32)]
pub enum PlayErr {
NoErr = 0,
WithMultiDeviceLoginErr = 1,
}
impl PlayErr {
pub fn as_str_name(&self) -> &'static str {
match self {
Self::NoErr => "NoErr",
Self::WithMultiDeviceLoginErr => "WithMultiDeviceLoginErr",
}
}
pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
match value {
"NoErr" => Some(Self::NoErr),
"WithMultiDeviceLoginErr" => Some(Self::WithMultiDeviceLoginErr),
_ => None,
}
}
}
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
#[repr(i32)]
pub enum PlayLimitCode {
PlcUnkown = 0,
PlcUgcNotPayed = 1,
PlcChargingPlusNotPass = 2,
PlcChargingPlusUpgrade = 3,
}
impl PlayLimitCode {
pub fn as_str_name(&self) -> &'static str {
match self {
Self::PlcUnkown => "PLCUnkown",
Self::PlcUgcNotPayed => "PLCUgcNotPayed",
Self::PlcChargingPlusNotPass => "PLCChargingPlusNotPass",
Self::PlcChargingPlusUpgrade => "PLCChargingPlusUpgrade",
}
}
pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
match value {
"PLCUnkown" => Some(Self::PlcUnkown),
"PLCUgcNotPayed" => Some(Self::PlcUgcNotPayed),
"PLCChargingPlusNotPass" => Some(Self::PlcChargingPlusNotPass),
"PLCChargingPlusUpgrade" => Some(Self::PlcChargingPlusUpgrade),
_ => None,
}
}
}
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
#[repr(i32)]
pub enum ToastType {
Unknown = 0,
ChargingToast = 1,
}
impl ToastType {
pub fn as_str_name(&self) -> &'static str {
match self {
Self::Unknown => "TOAST_TYPE_UNKNOWN",
Self::ChargingToast => "CHARGING_TOAST",
}
}
pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
match value {
"TOAST_TYPE_UNKNOWN" => Some(Self::Unknown),
"CHARGING_TOAST" => Some(Self::ChargingToast),
_ => None,
}
}
}
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
#[repr(i32)]
pub enum VideoType {
Unknown = 0,
Flv = 1,
Dash = 2,
Mp4 = 3,
}
impl VideoType {
pub fn as_str_name(&self) -> &'static str {
match self {
Self::Unknown => "Unknown",
Self::Flv => "FLV",
Self::Dash => "DASH",
Self::Mp4 => "MP4",
}
}
pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
match value {
"Unknown" => Some(Self::Unknown),
"FLV" => Some(Self::Flv),
"DASH" => Some(Self::Dash),
"MP4" => Some(Self::Mp4),
_ => None,
}
}
}
#[cfg(feature = "feat-enable-generated-client")]
pub mod play_url_client {
#![allow(
unused_variables,
dead_code,
missing_docs,
clippy::wildcard_imports,
clippy::let_unit_value,
)]
use tonic::codegen::*;
use tonic::codegen::http::Uri;
#[derive(Debug, Clone)]
pub struct PlayUrlClient<T> {
inner: tonic::client::Grpc<T>,
}
impl<T> PlayUrlClient<T>
where
T: tonic::client::GrpcService<tonic::body::Body>,
T::Error: Into<StdError>,
T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
<T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
{
pub fn new(inner: T) -> Self {
let inner = tonic::client::Grpc::new(inner);
Self { inner }
}
pub fn with_origin(inner: T, origin: Uri) -> Self {
let inner = tonic::client::Grpc::with_origin(inner, origin);
Self { inner }
}
pub fn with_interceptor<F>(
inner: T,
interceptor: F,
) -> PlayUrlClient<InterceptedService<T, F>>
where
F: tonic::service::Interceptor,
T::ResponseBody: Default,
T: tonic::codegen::Service<
http::Request<tonic::body::Body>,
Response = http::Response<
<T as tonic::client::GrpcService<tonic::body::Body>>::ResponseBody,
>,
>,
<T as tonic::codegen::Service<
http::Request<tonic::body::Body>,
>>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
{
PlayUrlClient::new(InterceptedService::new(inner, interceptor))
}
#[must_use]
pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
self.inner = self.inner.send_compressed(encoding);
self
}
#[must_use]
pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
self.inner = self.inner.accept_compressed(encoding);
self
}
#[must_use]
pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
self.inner = self.inner.max_decoding_message_size(limit);
self
}
#[must_use]
pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
self.inner = self.inner.max_encoding_message_size(limit);
self
}
pub async fn play_conf(
&mut self,
request: impl tonic::IntoRequest<super::PlayConfReq>,
) -> std::result::Result<tonic::Response<super::PlayConfReply>, tonic::Status> {
self.inner
.ready()
.await
.map_err(|e| {
tonic::Status::unknown(
format!("Service was not ready: {}", e.into()),
)
})?;
let codec = tonic::codec::ProstCodec::default();
let path = http::uri::PathAndQuery::from_static(
"/bilibili.app.playurl.v1.PlayURL/PlayConf",
);
let mut req = request.into_request();
req.extensions_mut()
.insert(GrpcMethod::new("bilibili.app.playurl.v1.PlayURL", "PlayConf"));
self.inner.unary(req, path, codec).await
}
pub async fn play_conf_edit(
&mut self,
request: impl tonic::IntoRequest<super::PlayConfEditReq>,
) -> std::result::Result<
tonic::Response<super::PlayConfEditReply>,
tonic::Status,
> {
self.inner
.ready()
.await
.map_err(|e| {
tonic::Status::unknown(
format!("Service was not ready: {}", e.into()),
)
})?;
let codec = tonic::codec::ProstCodec::default();
let path = http::uri::PathAndQuery::from_static(
"/bilibili.app.playurl.v1.PlayURL/PlayConfEdit",
);
let mut req = request.into_request();
req.extensions_mut()
.insert(
GrpcMethod::new("bilibili.app.playurl.v1.PlayURL", "PlayConfEdit"),
);
self.inner.unary(req, path, codec).await
}
pub async fn play_url(
&mut self,
request: impl tonic::IntoRequest<super::PlayUrlReq>,
) -> std::result::Result<tonic::Response<super::PlayUrlReply>, tonic::Status> {
self.inner
.ready()
.await
.map_err(|e| {
tonic::Status::unknown(
format!("Service was not ready: {}", e.into()),
)
})?;
let codec = tonic::codec::ProstCodec::default();
let path = http::uri::PathAndQuery::from_static(
"/bilibili.app.playurl.v1.PlayURL/PlayURL",
);
let mut req = request.into_request();
req.extensions_mut()
.insert(GrpcMethod::new("bilibili.app.playurl.v1.PlayURL", "PlayURL"));
self.inner.unary(req, path, codec).await
}
pub async fn play_view(
&mut self,
request: impl tonic::IntoRequest<super::PlayViewReq>,
) -> std::result::Result<tonic::Response<super::PlayViewReply>, tonic::Status> {
self.inner
.ready()
.await
.map_err(|e| {
tonic::Status::unknown(
format!("Service was not ready: {}", e.into()),
)
})?;
let codec = tonic::codec::ProstCodec::default();
let path = http::uri::PathAndQuery::from_static(
"/bilibili.app.playurl.v1.PlayURL/PlayView",
);
let mut req = request.into_request();
req.extensions_mut()
.insert(GrpcMethod::new("bilibili.app.playurl.v1.PlayURL", "PlayView"));
self.inner.unary(req, path, codec).await
}
pub async fn project(
&mut self,
request: impl tonic::IntoRequest<super::ProjectReq>,
) -> std::result::Result<tonic::Response<super::ProjectReply>, tonic::Status> {
self.inner
.ready()
.await
.map_err(|e| {
tonic::Status::unknown(
format!("Service was not ready: {}", e.into()),
)
})?;
let codec = tonic::codec::ProstCodec::default();
let path = http::uri::PathAndQuery::from_static(
"/bilibili.app.playurl.v1.PlayURL/Project",
);
let mut req = request.into_request();
req.extensions_mut()
.insert(GrpcMethod::new("bilibili.app.playurl.v1.PlayURL", "Project"));
self.inner.unary(req, path, codec).await
}
}
}
#[cfg(feature = "feat-enable-generated-server")]
pub mod play_url_server {
#![allow(
unused_variables,
dead_code,
missing_docs,
clippy::wildcard_imports,
clippy::let_unit_value,
)]
use tonic::codegen::*;
#[async_trait]
pub trait PlayUrl: std::marker::Send + std::marker::Sync + 'static {
async fn play_conf(
&self,
request: tonic::Request<super::PlayConfReq>,
) -> std::result::Result<tonic::Response<super::PlayConfReply>, tonic::Status>;
async fn play_conf_edit(
&self,
request: tonic::Request<super::PlayConfEditReq>,
) -> std::result::Result<
tonic::Response<super::PlayConfEditReply>,
tonic::Status,
>;
async fn play_url(
&self,
request: tonic::Request<super::PlayUrlReq>,
) -> std::result::Result<tonic::Response<super::PlayUrlReply>, tonic::Status>;
async fn play_view(
&self,
request: tonic::Request<super::PlayViewReq>,
) -> std::result::Result<tonic::Response<super::PlayViewReply>, tonic::Status>;
async fn project(
&self,
request: tonic::Request<super::ProjectReq>,
) -> std::result::Result<tonic::Response<super::ProjectReply>, tonic::Status>;
}
#[derive(Debug)]
pub struct PlayUrlServer<T> {
inner: Arc<T>,
accept_compression_encodings: EnabledCompressionEncodings,
send_compression_encodings: EnabledCompressionEncodings,
max_decoding_message_size: Option<usize>,
max_encoding_message_size: Option<usize>,
}
impl<T> PlayUrlServer<T> {
pub fn new(inner: T) -> Self {
Self::from_arc(Arc::new(inner))
}
pub fn from_arc(inner: Arc<T>) -> Self {
Self {
inner,
accept_compression_encodings: Default::default(),
send_compression_encodings: Default::default(),
max_decoding_message_size: None,
max_encoding_message_size: None,
}
}
pub fn with_interceptor<F>(
inner: T,
interceptor: F,
) -> InterceptedService<Self, F>
where
F: tonic::service::Interceptor,
{
InterceptedService::new(Self::new(inner), interceptor)
}
#[must_use]
pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
self.accept_compression_encodings.enable(encoding);
self
}
#[must_use]
pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
self.send_compression_encodings.enable(encoding);
self
}
#[must_use]
pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
self.max_decoding_message_size = Some(limit);
self
}
#[must_use]
pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
self.max_encoding_message_size = Some(limit);
self
}
}
impl<T, B> tonic::codegen::Service<http::Request<B>> for PlayUrlServer<T>
where
T: PlayUrl,
B: Body + std::marker::Send + 'static,
B::Error: Into<StdError> + std::marker::Send + 'static,
{
type Response = http::Response<tonic::body::Body>;
type Error = std::convert::Infallible;
type Future = BoxFuture<Self::Response, Self::Error>;
fn poll_ready(
&mut self,
_cx: &mut Context<'_>,
) -> Poll<std::result::Result<(), Self::Error>> {
Poll::Ready(Ok(()))
}
fn call(&mut self, req: http::Request<B>) -> Self::Future {
match req.uri().path() {
"/bilibili.app.playurl.v1.PlayURL/PlayConf" => {
#[allow(non_camel_case_types)]
struct PlayConfSvc<T: PlayUrl>(pub Arc<T>);
impl<T: PlayUrl> tonic::server::UnaryService<super::PlayConfReq>
for PlayConfSvc<T> {
type Response = super::PlayConfReply;
type Future = BoxFuture<
tonic::Response<Self::Response>,
tonic::Status,
>;
fn call(
&mut self,
request: tonic::Request<super::PlayConfReq>,
) -> Self::Future {
let inner = Arc::clone(&self.0);
let fut = async move {
<T as PlayUrl>::play_conf(&inner, request).await
};
Box::pin(fut)
}
}
let accept_compression_encodings = self.accept_compression_encodings;
let send_compression_encodings = self.send_compression_encodings;
let max_decoding_message_size = self.max_decoding_message_size;
let max_encoding_message_size = self.max_encoding_message_size;
let inner = self.inner.clone();
let fut = async move {
let method = PlayConfSvc(inner);
let codec = tonic::codec::ProstCodec::default();
let mut grpc = tonic::server::Grpc::new(codec)
.apply_compression_config(
accept_compression_encodings,
send_compression_encodings,
)
.apply_max_message_size_config(
max_decoding_message_size,
max_encoding_message_size,
);
let res = grpc.unary(method, req).await;
Ok(res)
};
Box::pin(fut)
}
"/bilibili.app.playurl.v1.PlayURL/PlayConfEdit" => {
#[allow(non_camel_case_types)]
struct PlayConfEditSvc<T: PlayUrl>(pub Arc<T>);
impl<T: PlayUrl> tonic::server::UnaryService<super::PlayConfEditReq>
for PlayConfEditSvc<T> {
type Response = super::PlayConfEditReply;
type Future = BoxFuture<
tonic::Response<Self::Response>,
tonic::Status,
>;
fn call(
&mut self,
request: tonic::Request<super::PlayConfEditReq>,
) -> Self::Future {
let inner = Arc::clone(&self.0);
let fut = async move {
<T as PlayUrl>::play_conf_edit(&inner, request).await
};
Box::pin(fut)
}
}
let accept_compression_encodings = self.accept_compression_encodings;
let send_compression_encodings = self.send_compression_encodings;
let max_decoding_message_size = self.max_decoding_message_size;
let max_encoding_message_size = self.max_encoding_message_size;
let inner = self.inner.clone();
let fut = async move {
let method = PlayConfEditSvc(inner);
let codec = tonic::codec::ProstCodec::default();
let mut grpc = tonic::server::Grpc::new(codec)
.apply_compression_config(
accept_compression_encodings,
send_compression_encodings,
)
.apply_max_message_size_config(
max_decoding_message_size,
max_encoding_message_size,
);
let res = grpc.unary(method, req).await;
Ok(res)
};
Box::pin(fut)
}
"/bilibili.app.playurl.v1.PlayURL/PlayURL" => {
#[allow(non_camel_case_types)]
struct PlayURLSvc<T: PlayUrl>(pub Arc<T>);
impl<T: PlayUrl> tonic::server::UnaryService<super::PlayUrlReq>
for PlayURLSvc<T> {
type Response = super::PlayUrlReply;
type Future = BoxFuture<
tonic::Response<Self::Response>,
tonic::Status,
>;
fn call(
&mut self,
request: tonic::Request<super::PlayUrlReq>,
) -> Self::Future {
let inner = Arc::clone(&self.0);
let fut = async move {
<T as PlayUrl>::play_url(&inner, request).await
};
Box::pin(fut)
}
}
let accept_compression_encodings = self.accept_compression_encodings;
let send_compression_encodings = self.send_compression_encodings;
let max_decoding_message_size = self.max_decoding_message_size;
let max_encoding_message_size = self.max_encoding_message_size;
let inner = self.inner.clone();
let fut = async move {
let method = PlayURLSvc(inner);
let codec = tonic::codec::ProstCodec::default();
let mut grpc = tonic::server::Grpc::new(codec)
.apply_compression_config(
accept_compression_encodings,
send_compression_encodings,
)
.apply_max_message_size_config(
max_decoding_message_size,
max_encoding_message_size,
);
let res = grpc.unary(method, req).await;
Ok(res)
};
Box::pin(fut)
}
"/bilibili.app.playurl.v1.PlayURL/PlayView" => {
#[allow(non_camel_case_types)]
struct PlayViewSvc<T: PlayUrl>(pub Arc<T>);
impl<T: PlayUrl> tonic::server::UnaryService<super::PlayViewReq>
for PlayViewSvc<T> {
type Response = super::PlayViewReply;
type Future = BoxFuture<
tonic::Response<Self::Response>,
tonic::Status,
>;
fn call(
&mut self,
request: tonic::Request<super::PlayViewReq>,
) -> Self::Future {
let inner = Arc::clone(&self.0);
let fut = async move {
<T as PlayUrl>::play_view(&inner, request).await
};
Box::pin(fut)
}
}
let accept_compression_encodings = self.accept_compression_encodings;
let send_compression_encodings = self.send_compression_encodings;
let max_decoding_message_size = self.max_decoding_message_size;
let max_encoding_message_size = self.max_encoding_message_size;
let inner = self.inner.clone();
let fut = async move {
let method = PlayViewSvc(inner);
let codec = tonic::codec::ProstCodec::default();
let mut grpc = tonic::server::Grpc::new(codec)
.apply_compression_config(
accept_compression_encodings,
send_compression_encodings,
)
.apply_max_message_size_config(
max_decoding_message_size,
max_encoding_message_size,
);
let res = grpc.unary(method, req).await;
Ok(res)
};
Box::pin(fut)
}
"/bilibili.app.playurl.v1.PlayURL/Project" => {
#[allow(non_camel_case_types)]
struct ProjectSvc<T: PlayUrl>(pub Arc<T>);
impl<T: PlayUrl> tonic::server::UnaryService<super::ProjectReq>
for ProjectSvc<T> {
type Response = super::ProjectReply;
type Future = BoxFuture<
tonic::Response<Self::Response>,
tonic::Status,
>;
fn call(
&mut self,
request: tonic::Request<super::ProjectReq>,
) -> Self::Future {
let inner = Arc::clone(&self.0);
let fut = async move {
<T as PlayUrl>::project(&inner, request).await
};
Box::pin(fut)
}
}
let accept_compression_encodings = self.accept_compression_encodings;
let send_compression_encodings = self.send_compression_encodings;
let max_decoding_message_size = self.max_decoding_message_size;
let max_encoding_message_size = self.max_encoding_message_size;
let inner = self.inner.clone();
let fut = async move {
let method = ProjectSvc(inner);
let codec = tonic::codec::ProstCodec::default();
let mut grpc = tonic::server::Grpc::new(codec)
.apply_compression_config(
accept_compression_encodings,
send_compression_encodings,
)
.apply_max_message_size_config(
max_decoding_message_size,
max_encoding_message_size,
);
let res = grpc.unary(method, req).await;
Ok(res)
};
Box::pin(fut)
}
_ => {
Box::pin(async move {
let mut response = http::Response::new(
tonic::body::Body::default(),
);
let headers = response.headers_mut();
headers
.insert(
tonic::Status::GRPC_STATUS,
(tonic::Code::Unimplemented as i32).into(),
);
headers
.insert(
http::header::CONTENT_TYPE,
tonic::metadata::GRPC_CONTENT_TYPE,
);
Ok(response)
})
}
}
}
}
impl<T> Clone for PlayUrlServer<T> {
fn clone(&self) -> Self {
let inner = self.inner.clone();
Self {
inner,
accept_compression_encodings: self.accept_compression_encodings,
send_compression_encodings: self.send_compression_encodings,
max_decoding_message_size: self.max_decoding_message_size,
max_encoding_message_size: self.max_encoding_message_size,
}
}
}
pub const SERVICE_NAME: &str = "bilibili.app.playurl.v1.PlayURL";
impl<T> tonic::server::NamedService for PlayUrlServer<T> {
const NAME: &'static str = SERVICE_NAME;
}
}