pub trait AsyncVideoService<O> {
type GetPlaylistBody: AsyncWriteBody<O> + 'static + Send;
type GetPlaylistInBoundsBody: AsyncWriteBody<O> + 'static + Send;
Show 16 methods
// Required methods
fn get(
&self,
auth_: BearerToken,
video_rid: VideoRid,
) -> impl Future<Output = Result<Video, Error>> + Send;
fn batch_get(
&self,
auth_: BearerToken,
request: GetVideosRequest,
) -> impl Future<Output = Result<GetVideosResponse, Error>> + Send;
fn search(
&self,
auth_: BearerToken,
request: SearchVideosRequest,
) -> impl Future<Output = Result<SearchVideosResponse, Error>> + Send;
fn create(
&self,
auth_: BearerToken,
request: CreateVideoRequest,
) -> impl Future<Output = Result<Video, Error>> + Send;
fn update_metadata(
&self,
auth_: BearerToken,
video_rid: VideoRid,
request: UpdateVideoMetadataRequest,
) -> impl Future<Output = Result<Video, Error>> + Send;
fn update_ingest_status(
&self,
auth_: BearerToken,
video_rid: VideoRid,
request: UpdateIngestStatus,
) -> impl Future<Output = Result<(), Error>> + Send;
fn get_ingest_status(
&self,
auth_: BearerToken,
video_rid: VideoRid,
) -> impl Future<Output = Result<DetailedIngestStatus, Error>> + Send;
fn batch_get_ingest_status(
&self,
auth_: BearerToken,
video_rids: BTreeSet<VideoRid>,
) -> impl Future<Output = Result<BTreeMap<VideoRid, DetailedIngestStatus>, Error>> + Send;
fn get_enriched_ingest_status(
&self,
auth_: BearerToken,
request: GetEnrichedVideoIngestStatusRequest,
) -> impl Future<Output = Result<Option<EnrichedVideoIngestStatus>, Error>> + Send;
fn archive(
&self,
auth_: BearerToken,
video_rid: VideoRid,
) -> impl Future<Output = Result<(), Error>> + Send;
fn unarchive(
&self,
auth_: BearerToken,
video_rid: VideoRid,
) -> impl Future<Output = Result<(), Error>> + Send;
fn get_playlist(
&self,
auth_: BearerToken,
video_rid: VideoRid,
) -> impl Future<Output = Result<Self::GetPlaylistBody, Error>> + Send;
fn get_segment_summaries(
&self,
auth_: BearerToken,
video_rid: VideoRid,
) -> impl Future<Output = Result<Vec<SegmentSummary>, Error>> + Send;
fn get_playlist_in_bounds(
&self,
auth_: BearerToken,
video_rid: VideoRid,
request: GetPlaylistInBoundsRequest,
) -> impl Future<Output = Result<Self::GetPlaylistInBoundsBody, Error>> + Send;
fn get_segment_summaries_in_bounds(
&self,
auth_: BearerToken,
video_rid: VideoRid,
request: GetSegmentSummariesInBoundsRequest,
) -> impl Future<Output = Result<Vec<SegmentSummary>, Error>> + Send;
fn get_file_summaries(
&self,
auth_: BearerToken,
video_rid: VideoRid,
request: GetFileSummariesRequest,
) -> impl Future<Output = Result<GetFileSummariesResponse, Error>> + Send;
}
Expand description
The video service manages videos and video metadata.
Required Associated Types§
Sourcetype GetPlaylistBody: AsyncWriteBody<O> + 'static + Send
type GetPlaylistBody: AsyncWriteBody<O> + 'static + Send
The body type returned by the get_playlist
method.
Sourcetype GetPlaylistInBoundsBody: AsyncWriteBody<O> + 'static + Send
type GetPlaylistInBoundsBody: AsyncWriteBody<O> + 'static + Send
The body type returned by the get_playlist_in_bounds
method.
Required Methods§
Sourcefn get(
&self,
auth_: BearerToken,
video_rid: VideoRid,
) -> impl Future<Output = Result<Video, Error>> + Send
fn get( &self, auth_: BearerToken, video_rid: VideoRid, ) -> impl Future<Output = Result<Video, Error>> + Send
Returns video metadata associated with a video rid.
Sourcefn batch_get(
&self,
auth_: BearerToken,
request: GetVideosRequest,
) -> impl Future<Output = Result<GetVideosResponse, Error>> + Send
fn batch_get( &self, auth_: BearerToken, request: GetVideosRequest, ) -> impl Future<Output = Result<GetVideosResponse, Error>> + Send
Returns video metadata about each video given a set of video rids.
Sourcefn search(
&self,
auth_: BearerToken,
request: SearchVideosRequest,
) -> impl Future<Output = Result<SearchVideosResponse, Error>> + Send
fn search( &self, auth_: BearerToken, request: SearchVideosRequest, ) -> impl Future<Output = Result<SearchVideosResponse, Error>> + Send
Returns metadata about videos that match a given query.
Sourcefn create(
&self,
auth_: BearerToken,
request: CreateVideoRequest,
) -> impl Future<Output = Result<Video, Error>> + Send
fn create( &self, auth_: BearerToken, request: CreateVideoRequest, ) -> impl Future<Output = Result<Video, Error>> + Send
Creates and persists a video entity with the given metadata.
Sourcefn update_metadata(
&self,
auth_: BearerToken,
video_rid: VideoRid,
request: UpdateVideoMetadataRequest,
) -> impl Future<Output = Result<Video, Error>> + Send
fn update_metadata( &self, auth_: BearerToken, video_rid: VideoRid, request: UpdateVideoMetadataRequest, ) -> impl Future<Output = Result<Video, Error>> + Send
Updates the metadata for a video associated with the given video rid.
fn update_ingest_status( &self, auth_: BearerToken, video_rid: VideoRid, request: UpdateIngestStatus, ) -> impl Future<Output = Result<(), Error>> + Send
fn get_ingest_status( &self, auth_: BearerToken, video_rid: VideoRid, ) -> impl Future<Output = Result<DetailedIngestStatus, Error>> + Send
fn batch_get_ingest_status( &self, auth_: BearerToken, video_rids: BTreeSet<VideoRid>, ) -> impl Future<Output = Result<BTreeMap<VideoRid, DetailedIngestStatus>, Error>> + Send
fn get_enriched_ingest_status( &self, auth_: BearerToken, request: GetEnrichedVideoIngestStatusRequest, ) -> impl Future<Output = Result<Option<EnrichedVideoIngestStatus>, Error>> + Send
Sourcefn archive(
&self,
auth_: BearerToken,
video_rid: VideoRid,
) -> impl Future<Output = Result<(), Error>> + Send
fn archive( &self, auth_: BearerToken, video_rid: VideoRid, ) -> impl Future<Output = Result<(), Error>> + Send
Archives a video, which excludes it from search and hides it from being publicly visible, but does not permanently delete it. Archived videos can be unarchived.
Sourcefn unarchive(
&self,
auth_: BearerToken,
video_rid: VideoRid,
) -> impl Future<Output = Result<(), Error>> + Send
fn unarchive( &self, auth_: BearerToken, video_rid: VideoRid, ) -> impl Future<Output = Result<(), Error>> + Send
Unarchives a previously archived video.
Sourcefn get_playlist(
&self,
auth_: BearerToken,
video_rid: VideoRid,
) -> impl Future<Output = Result<Self::GetPlaylistBody, Error>> + Send
fn get_playlist( &self, auth_: BearerToken, video_rid: VideoRid, ) -> impl Future<Output = Result<Self::GetPlaylistBody, Error>> + Send
Generates an HLS playlist for a video with the given video rid to enable playback. The HLS playlist will contain links to all of the segments in the video in sequential order.
Sourcefn get_segment_summaries(
&self,
auth_: BearerToken,
video_rid: VideoRid,
) -> impl Future<Output = Result<Vec<SegmentSummary>, Error>> + Send
fn get_segment_summaries( &self, auth_: BearerToken, video_rid: VideoRid, ) -> impl Future<Output = Result<Vec<SegmentSummary>, Error>> + Send
Returns the min and max absolute and media timestamps for each segment in a video. To be used during frame-timestamp mapping.
Sourcefn get_playlist_in_bounds(
&self,
auth_: BearerToken,
video_rid: VideoRid,
request: GetPlaylistInBoundsRequest,
) -> impl Future<Output = Result<Self::GetPlaylistInBoundsBody, Error>> + Send
fn get_playlist_in_bounds( &self, auth_: BearerToken, video_rid: VideoRid, request: GetPlaylistInBoundsRequest, ) -> impl Future<Output = Result<Self::GetPlaylistInBoundsBody, Error>> + Send
Generates an HLS playlist for a video with the given video rid to enable playback within an optional set of bounds. The HLS playlist will contain links to all of the segments in the video that overlap with the given bounds. playlist will be limited to the given bounds.
Sourcefn get_segment_summaries_in_bounds(
&self,
auth_: BearerToken,
video_rid: VideoRid,
request: GetSegmentSummariesInBoundsRequest,
) -> impl Future<Output = Result<Vec<SegmentSummary>, Error>> + Send
fn get_segment_summaries_in_bounds( &self, auth_: BearerToken, video_rid: VideoRid, request: GetSegmentSummariesInBoundsRequest, ) -> impl Future<Output = Result<Vec<SegmentSummary>, Error>> + Send
Returns the min and max absolute and media timestamps for each segment in a video that overlap with an optional set of bounds.
Sourcefn get_file_summaries(
&self,
auth_: BearerToken,
video_rid: VideoRid,
request: GetFileSummariesRequest,
) -> impl Future<Output = Result<GetFileSummariesResponse, Error>> + Send
fn get_file_summaries( &self, auth_: BearerToken, video_rid: VideoRid, request: GetFileSummariesRequest, ) -> impl Future<Output = Result<GetFileSummariesResponse, Error>> + Send
Returns the min and max absolute timestamps from non-archived video files associated with a given video that overlap with an optional set of bounds. The files on the edges of the bounds will be truncated to segments that are inside or overlap with the bounds.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.