Enum SegmentReferenceScheme (0.5.0)

The segment reference scheme for a DASH manifest.

Working with unknown values

This enum is defined as #[non_exhaustive] because Google Cloud may add additional enum variants at any time. Adding new variants is not considered a breaking change. Applications should write their code in anticipation of:

  • New values appearing in future releases of the client library, and
  • New values received dynamically, without application changes.

Please consult the Working with enums section in the user guide for some guidelines.

Enum Variants

Name Description
Unspecified

The segment reference scheme is not specified.

SegmentList

Explicitly lists the URLs of media files for each segment. For example, if SegmentSettings.individual_segments is true, then the manifest contains fields similar to the following:

<Initialization sourceURL="my-hd-stream-init.m4s"/>
  <SegmentList presentationTimeOffset="0" duration="1000"
  timescale="10000">
    <SegmentURL media="hd-stream0000000000.m4s"/>
    <SegmentURL media="hd-stream0000000001.m4s"/>
    ...
SegmentTemplateNumber

SegmentSettings.individual_segments must be set to true to use this segment reference scheme. Uses the DASH specification <SegmentTemplate> tag to determine the URLs of media files for each segment. For example:

<SegmentTemplate presentationTimeOffset="0" timescale="10000"
      initialization="my-hd-stream-init.m4s"
      media="hd-stream$Number%010d$.m4s" startNumber="0">
  ...
UnknownValue

If set, the enum was initialized with an unknown value.

Applications can examine the value using [SegmentReferenceScheme::value] or [SegmentReferenceScheme::name].

Implementations

Name Description
value
 fn value(self: &Self) -> std::option::Option<i32>

Gets the enum value.

Returns None if the enum contains an unknown value deserialized from the string representation of enums.

name
 fn name(self: &Self) -> std::option::Option<&str>

Gets the enum value as a string.

Returns None if the enum contains an unknown value deserialized from the integer representation of enums.