#[repr(i32)]pub enum PublishPolicy {
Optional = 0,
Required = 1,
Disabled = 2,
}Expand description
Policy of how a video or an audio media type can be published in a
WebRtcPublishEndpoint.
Variants§
Optional = 0
Media type MAY be published.
Media server will try to initialize publishing, but won’t produce any errors if user application fails to (or chooses not to) acquire the required media track. Media server will approve user requests to stop and to restart publishing the specified media type.
Required = 1
Media type MUST be published.
Media server will try to initialize publishing, and if the required media track cannot be acquired, then an error will be thrown. Media server will deny all requests to stop publishing.
Disabled = 2
Media type MUST NOT be published.
Media server will not try to initialize publishing.
Implementations§
Source§impl PublishPolicy
impl PublishPolicy
Source§impl PublishPolicy
impl PublishPolicy
Sourcepub fn as_str_name(&self) -> &'static str
pub fn as_str_name(&self) -> &'static str
String value of the enum field names used in the ProtoBuf definition.
The values are not transformed in any way and thus are considered stable (if the ProtoBuf definition does not change) and safe for programmatic use.
Sourcepub fn from_str_name(value: &str) -> Option<Self>
pub fn from_str_name(value: &str) -> Option<Self>
Creates an enum from field names used in the ProtoBuf definition.
Trait Implementations§
Source§impl Clone for PublishPolicy
impl Clone for PublishPolicy
Source§fn clone(&self) -> PublishPolicy
fn clone(&self) -> PublishPolicy
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for PublishPolicy
impl Debug for PublishPolicy
Source§impl Default for PublishPolicy
impl Default for PublishPolicy
Source§fn default() -> PublishPolicy
fn default() -> PublishPolicy
Source§impl From<Policy> for PublishPolicy
impl From<Policy> for PublishPolicy
Source§impl From<PublishPolicy> for Policy
impl From<PublishPolicy> for Policy
Source§fn from(val: PublishPolicy) -> Self
fn from(val: PublishPolicy) -> Self
Source§impl From<PublishPolicy> for i32
impl From<PublishPolicy> for i32
Source§fn from(value: PublishPolicy) -> i32
fn from(value: PublishPolicy) -> i32
Source§impl Hash for PublishPolicy
impl Hash for PublishPolicy
Source§impl Ord for PublishPolicy
impl Ord for PublishPolicy
Source§fn cmp(&self, other: &PublishPolicy) -> Ordering
fn cmp(&self, other: &PublishPolicy) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Source§impl PartialEq for PublishPolicy
impl PartialEq for PublishPolicy
Source§impl PartialOrd for PublishPolicy
impl PartialOrd for PublishPolicy
Source§impl TryFrom<i32> for PublishPolicy
impl TryFrom<i32> for PublishPolicy
Source§type Error = UnknownEnumValue
type Error = UnknownEnumValue
Source§fn try_from(value: i32) -> Result<PublishPolicy, UnknownEnumValue>
fn try_from(value: i32) -> Result<PublishPolicy, UnknownEnumValue>
impl Copy for PublishPolicy
impl Eq for PublishPolicy
impl StructuralPartialEq for PublishPolicy
Auto Trait Implementations§
impl Freeze for PublishPolicy
impl RefUnwindSafe for PublishPolicy
impl Send for PublishPolicy
impl Sync for PublishPolicy
impl Unpin for PublishPolicy
impl UnwindSafe for PublishPolicy
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::Request