Struct aws_sdk_mediapackage::model::hls_ingest::Builder
source · pub struct Builder { /* private fields */ }
Expand description
A builder for HlsIngest
.
Implementations§
source§impl Builder
impl Builder
sourcepub fn ingest_endpoints(self, input: IngestEndpoint) -> Self
pub fn ingest_endpoints(self, input: IngestEndpoint) -> Self
Appends an item to ingest_endpoints
.
To override the contents of this collection use set_ingest_endpoints
.
A list of endpoints to which the source stream should be sent.
sourcepub fn set_ingest_endpoints(self, input: Option<Vec<IngestEndpoint>>) -> Self
pub fn set_ingest_endpoints(self, input: Option<Vec<IngestEndpoint>>) -> Self
A list of endpoints to which the source stream should be sent.
Examples found in repository?
src/json_deser.rs (lines 1858-1860)
1836 1837 1838 1839 1840 1841 1842 1843 1844 1845 1846 1847 1848 1849 1850 1851 1852 1853 1854 1855 1856 1857 1858 1859 1860 1861 1862 1863 1864 1865 1866 1867 1868 1869 1870 1871 1872 1873 1874 1875 1876 1877 1878 1879 1880 1881 1882 1883
pub(crate) fn deser_structure_crate_model_hls_ingest<'a, I>(
tokens: &mut std::iter::Peekable<I>,
) -> Result<Option<crate::model::HlsIngest>, aws_smithy_json::deserialize::error::DeserializeError>
where
I: Iterator<
Item = Result<
aws_smithy_json::deserialize::Token<'a>,
aws_smithy_json::deserialize::error::DeserializeError,
>,
>,
{
match tokens.next().transpose()? {
Some(aws_smithy_json::deserialize::Token::ValueNull { .. }) => Ok(None),
Some(aws_smithy_json::deserialize::Token::StartObject { .. }) => {
#[allow(unused_mut)]
let mut builder = crate::model::hls_ingest::Builder::default();
loop {
match tokens.next().transpose()? {
Some(aws_smithy_json::deserialize::Token::EndObject { .. }) => break,
Some(aws_smithy_json::deserialize::Token::ObjectKey { key, .. }) => {
match key.to_unescaped()?.as_ref() {
"ingestEndpoints" => {
builder = builder.set_ingest_endpoints(
crate::json_deser::deser_list_com_amazonaws_mediapackage___list_of_ingest_endpoint(tokens)?
);
}
_ => aws_smithy_json::deserialize::token::skip_value(tokens)?,
}
}
other => {
return Err(
aws_smithy_json::deserialize::error::DeserializeError::custom(format!(
"expected object key or end object, found: {:?}",
other
)),
)
}
}
}
Ok(Some(builder.build()))
}
_ => Err(
aws_smithy_json::deserialize::error::DeserializeError::custom(
"expected start object or null",
),
),
}
}
sourcepub fn build(self) -> HlsIngest
pub fn build(self) -> HlsIngest
Consumes the builder and constructs a HlsIngest
.
Examples found in repository?
src/json_deser.rs (line 1875)
1836 1837 1838 1839 1840 1841 1842 1843 1844 1845 1846 1847 1848 1849 1850 1851 1852 1853 1854 1855 1856 1857 1858 1859 1860 1861 1862 1863 1864 1865 1866 1867 1868 1869 1870 1871 1872 1873 1874 1875 1876 1877 1878 1879 1880 1881 1882 1883
pub(crate) fn deser_structure_crate_model_hls_ingest<'a, I>(
tokens: &mut std::iter::Peekable<I>,
) -> Result<Option<crate::model::HlsIngest>, aws_smithy_json::deserialize::error::DeserializeError>
where
I: Iterator<
Item = Result<
aws_smithy_json::deserialize::Token<'a>,
aws_smithy_json::deserialize::error::DeserializeError,
>,
>,
{
match tokens.next().transpose()? {
Some(aws_smithy_json::deserialize::Token::ValueNull { .. }) => Ok(None),
Some(aws_smithy_json::deserialize::Token::StartObject { .. }) => {
#[allow(unused_mut)]
let mut builder = crate::model::hls_ingest::Builder::default();
loop {
match tokens.next().transpose()? {
Some(aws_smithy_json::deserialize::Token::EndObject { .. }) => break,
Some(aws_smithy_json::deserialize::Token::ObjectKey { key, .. }) => {
match key.to_unescaped()?.as_ref() {
"ingestEndpoints" => {
builder = builder.set_ingest_endpoints(
crate::json_deser::deser_list_com_amazonaws_mediapackage___list_of_ingest_endpoint(tokens)?
);
}
_ => aws_smithy_json::deserialize::token::skip_value(tokens)?,
}
}
other => {
return Err(
aws_smithy_json::deserialize::error::DeserializeError::custom(format!(
"expected object key or end object, found: {:?}",
other
)),
)
}
}
}
Ok(Some(builder.build()))
}
_ => Err(
aws_smithy_json::deserialize::error::DeserializeError::custom(
"expected start object or null",
),
),
}
}