pub struct PostIndex { /* private fields */ }
Implementations
sourceimpl PostIndex
impl PostIndex
pub fn new(client: Arc<Elasticsearch>, name: String) -> Self
pub fn index(&self) -> &Arc<Index>
pub fn client(&self) -> &Elasticsearch
pub fn name(&self) -> &str
sourcepub async fn find_posts_for_medias(
&self,
media_guids: &[&str]
) -> Result<Vec<String>, IndexError>
pub async fn find_posts_for_medias(
&self,
media_guids: &[&str]
) -> Result<Vec<String>, IndexError>
Find all posts that reference any of a list of media ids.
pub async fn index_post_by_id(
&self,
db: &CouchDB,
id: &str
) -> Result<BulkPutResponse>
pub async fn index_changes(
&self,
db: &CouchDB,
changes: &[UntypedRecord]
) -> Result<()>
Trait Implementations
Auto Trait Implementations
impl !RefUnwindSafe for PostIndex
impl Send for PostIndex
impl Sync for PostIndex
impl Unpin for PostIndex
impl !UnwindSafe for PostIndex
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> Instrument for T
impl<T> Instrument for T
sourcefn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
sourcefn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
impl<T> IntoCollection<T> for T
impl<T> IntoCollection<T> for T
fn into_collection<A>(self) -> SmallVec<A>where
A: Array<Item = T>,
fn into_collection<A>(self) -> SmallVec<A>where
A: Array<Item = T>,
Converts
self
into a collection.fn mapped<U, F, A>(self, f: F) -> SmallVec<A>where
F: FnMut(T) -> U,
A: Array<Item = U>,
impl<T> Same<T> for T
impl<T> Same<T> for T
type Output = T
type Output = T
Should always be
Self