#[non_exhaustive]pub struct LambdaEventSourceBuilder { /* private fields */ }
Expand description
A builder for LambdaEventSource
.
Implementations§
source§impl LambdaEventSourceBuilder
impl LambdaEventSourceBuilder
sourcepub fn topic(self, input: impl Into<String>) -> Self
pub fn topic(self, input: impl Into<String>) -> Self
The topic to which to subscribe to receive event messages.
This field is required.sourcepub fn set_topic(self, input: Option<String>) -> Self
pub fn set_topic(self, input: Option<String>) -> Self
The topic to which to subscribe to receive event messages.
sourcepub fn get_topic(&self) -> &Option<String>
pub fn get_topic(&self) -> &Option<String>
The topic to which to subscribe to receive event messages.
sourcepub fn type(self, input: LambdaEventSourceType) -> Self
pub fn type(self, input: LambdaEventSourceType) -> Self
The type of event source. Choose from the following options:
-
PUB_SUB
– Subscribe to local publish/subscribe messages. This event source type doesn't support MQTT wildcards (+
and#
) in the event source topic. -
IOT_CORE
– Subscribe to Amazon Web Services IoT Core MQTT messages. This event source type supports MQTT wildcards (+
and#
) in the event source topic.
sourcepub fn set_type(self, input: Option<LambdaEventSourceType>) -> Self
pub fn set_type(self, input: Option<LambdaEventSourceType>) -> Self
The type of event source. Choose from the following options:
-
PUB_SUB
– Subscribe to local publish/subscribe messages. This event source type doesn't support MQTT wildcards (+
and#
) in the event source topic. -
IOT_CORE
– Subscribe to Amazon Web Services IoT Core MQTT messages. This event source type supports MQTT wildcards (+
and#
) in the event source topic.
sourcepub fn get_type(&self) -> &Option<LambdaEventSourceType>
pub fn get_type(&self) -> &Option<LambdaEventSourceType>
The type of event source. Choose from the following options:
-
PUB_SUB
– Subscribe to local publish/subscribe messages. This event source type doesn't support MQTT wildcards (+
and#
) in the event source topic. -
IOT_CORE
– Subscribe to Amazon Web Services IoT Core MQTT messages. This event source type supports MQTT wildcards (+
and#
) in the event source topic.
sourcepub fn build(self) -> Result<LambdaEventSource, BuildError>
pub fn build(self) -> Result<LambdaEventSource, BuildError>
Consumes the builder and constructs a LambdaEventSource
.
This method will fail if any of the following fields are not set:
Trait Implementations§
source§impl Clone for LambdaEventSourceBuilder
impl Clone for LambdaEventSourceBuilder
source§fn clone(&self) -> LambdaEventSourceBuilder
fn clone(&self) -> LambdaEventSourceBuilder
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for LambdaEventSourceBuilder
impl Debug for LambdaEventSourceBuilder
source§impl Default for LambdaEventSourceBuilder
impl Default for LambdaEventSourceBuilder
source§fn default() -> LambdaEventSourceBuilder
fn default() -> LambdaEventSourceBuilder
source§impl PartialEq for LambdaEventSourceBuilder
impl PartialEq for LambdaEventSourceBuilder
source§fn eq(&self, other: &LambdaEventSourceBuilder) -> bool
fn eq(&self, other: &LambdaEventSourceBuilder) -> bool
self
and other
values to be equal, and is used
by ==
.impl StructuralPartialEq for LambdaEventSourceBuilder
Auto Trait Implementations§
impl Freeze for LambdaEventSourceBuilder
impl RefUnwindSafe for LambdaEventSourceBuilder
impl Send for LambdaEventSourceBuilder
impl Sync for LambdaEventSourceBuilder
impl Unpin for LambdaEventSourceBuilder
impl UnwindSafe for LambdaEventSourceBuilder
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> 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> IntoEither for T
impl<T> IntoEither for T
source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moresource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more