pub struct StreamingLinkList {
pub expires: DateTime<Utc>,
pub hosts: Vec<String>,
pub path: String,
}
Expand description
A struct that represents a list of streaming links with metadata such as expiration date and hosts.
Fields§
§expires: DateTime<Utc>
The expiration date and time of the streaming links.
hosts: Vec<String>
The list of available host URLs for streaming.
path: String
The path to the resource to be streamed.
Implementations§
Source§impl StreamingLinkList
impl StreamingLinkList
Sourcepub fn first_link(&self) -> Option<StreamingLink<'_>>
pub fn first_link(&self) -> Option<StreamingLink<'_>>
Returns the first streaming link using the first host in the list.
§Returns
An optional StreamingLink
, which may be None
if the list of hosts is empty.
Sourcepub fn last_link(&self) -> Option<StreamingLink<'_>>
pub fn last_link(&self) -> Option<StreamingLink<'_>>
Returns the last streaming link using the last host in the list.
§Returns
An optional StreamingLink
, which may be None
if the list of hosts is empty.
Sourcepub fn links(&self) -> impl Iterator<Item = StreamingLink<'_>>
pub fn links(&self) -> impl Iterator<Item = StreamingLink<'_>>
Returns an iterator over all available streaming links.
This will create a StreamingLink
for each host in the list using the common path.
§Returns
An iterator over StreamingLink
instances.
Trait Implementations§
Source§impl Debug for StreamingLinkList
impl Debug for StreamingLinkList
Source§impl<'de> Deserialize<'de> for StreamingLinkList
impl<'de> Deserialize<'de> for StreamingLinkList
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for StreamingLinkList
impl RefUnwindSafe for StreamingLinkList
impl Send for StreamingLinkList
impl Sync for StreamingLinkList
impl Unpin for StreamingLinkList
impl UnwindSafe for StreamingLinkList
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
Mutably borrows from an owned value. Read more