Struct dittolive_ditto::store::live_query::LiveQuery
source · [−]pub struct LiveQuery {
pub query: Box,
pub collection_name: Box,
pub subscription: Option<Box<Subscription>>,
pub event_handler: Pin<Box<dyn EventHandler>>,
pub id: i64,
/* private fields */
}
Fields
query: Box
collection_name: Box
subscription: Option<Box<Subscription>>
If created via observe
contains the associated Subscription
for the
LiveQuery
event_handler: Pin<Box<dyn EventHandler>>
An OWNED event handler, which is borrowed on the other side of the FFI.
As such, retain
and release
methods for the handler can be None.
id: i64
Implementations
sourceimpl LiveQuery
impl LiveQuery
pub fn with_handler<F>(
ditto: Arc<BoxedDitto>,
query: Box,
query_args: Option<Vec<u8>>,
collection_name: Box,
order_by: &[COrderByParam<'_>],
limit: i32,
offset: u32,
subscription: Option<Box<Subscription>>,
event_handler: F
) -> Result<Self, DittoError> where
F: EventHandler,
Trait Implementations
Auto Trait Implementations
impl !RefUnwindSafe for LiveQuery
impl Send for LiveQuery
impl !Sync for LiveQuery
impl Unpin for LiveQuery
impl !UnwindSafe for LiveQuery
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more