pub struct DataStreamReader { /* private fields */ }
Expand description
DataStreamReader represents the entrypoint to create a streaming DataFrame
Implementations§
Source§impl DataStreamReader
impl DataStreamReader
pub fn new(spark_session: SparkSession) -> Self
Sourcepub fn schema(self, schema: &str) -> Self
pub fn schema(self, schema: &str) -> Self
Schema of the stream in DDL format (e.g. "name string, age int"
)
Sourcepub fn option(self, key: &str, value: &str) -> Self
pub fn option(self, key: &str, value: &str) -> Self
Add an input option for the underlying data source
Sourcepub fn options<I, K, V>(self, options: I) -> Self
pub fn options<I, K, V>(self, options: I) -> Self
Set many input options based on an iterator of (key/value pairs) for the underlying data source
pub fn load(self, path: Option<&str>) -> Result<DataFrame, SparkError>
Trait Implementations§
Source§impl Clone for DataStreamReader
impl Clone for DataStreamReader
Source§fn clone(&self) -> DataStreamReader
fn clone(&self) -> DataStreamReader
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreAuto Trait Implementations§
impl Freeze for DataStreamReader
impl !RefUnwindSafe for DataStreamReader
impl Send for DataStreamReader
impl Sync for DataStreamReader
impl Unpin for DataStreamReader
impl !UnwindSafe for DataStreamReader
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T
in a tonic::Request