pub struct GraphServiceProcessor<P, H, R> { /* private fields */ }
Implementations§
Source§impl<P, H, R> GraphServiceProcessor<P, H, R>
impl<P, H, R> GraphServiceProcessor<P, H, R>
pub fn new(service: H) -> Self
pub fn into_inner(self) -> H
Trait Implementations§
Source§impl<P: Clone, H: Clone, R: Clone> Clone for GraphServiceProcessor<P, H, R>
impl<P: Clone, H: Clone, R: Clone> Clone for GraphServiceProcessor<P, H, R>
Source§fn clone(&self) -> GraphServiceProcessor<P, H, R>
fn clone(&self) -> GraphServiceProcessor<P, H, R>
Returns a duplicate 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 moreSource§impl<P, H, R> ServiceProcessor<P> for GraphServiceProcessor<P, H, R>where
P: Protocol + Send + Sync + 'static,
P::Deserializer: Send,
H: GraphService,
R: Send + Sync + 'static,
impl<P, H, R> ServiceProcessor<P> for GraphServiceProcessor<P, H, R>where
P: Protocol + Send + Sync + 'static,
P::Deserializer: Send,
H: GraphService,
R: Send + Sync + 'static,
type RequestContext = R
Source§fn method_idx(&self, name: &[u8]) -> Result<usize, ApplicationException>
fn method_idx(&self, name: &[u8]) -> Result<usize, ApplicationException>
Given a method name, return a reference to the processor for that index.
Source§fn handle_method<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
idx: usize,
_p: &'life1 mut P::Deserializer,
_r: &'life2 R,
_seqid: u32,
) -> Pin<Box<dyn Future<Output = Result<ProtocolEncodedFinal<P>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn handle_method<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
idx: usize,
_p: &'life1 mut P::Deserializer,
_r: &'life2 R,
_seqid: u32,
) -> Pin<Box<dyn Future<Output = Result<ProtocolEncodedFinal<P>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Given a method index and the remains of the message input, get a future
for the result of the method. This will only be called if the corresponding
method_idx()
returns an (index, ServiceProcessor) tuple.
frame
is a reference to the frame containing the request.
request
is a deserializer instance set up to decode the request.Source§impl<P, H, R> ThriftService<<P as Protocol>::Frame> for GraphServiceProcessor<P, H, R>where
P: Protocol + Send + Sync + 'static,
P::Deserializer: Send,
P::Frame: Send + 'static,
H: GraphService,
R: Send + Sync + 'static,
impl<P, H, R> ThriftService<<P as Protocol>::Frame> for GraphServiceProcessor<P, H, R>where
P: Protocol + Send + Sync + 'static,
P::Deserializer: Send,
P::Frame: Send + 'static,
H: GraphService,
R: Send + Sync + 'static,
type Handler = H
type RequestContext = R
fn call<'life0, 'life1, 'async_trait>(
&'life0 self,
req: ProtocolDecoded<P>,
req_ctxt: &'life1 R,
) -> Pin<Box<dyn Future<Output = Result<ProtocolEncodedFinal<P>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Auto Trait Implementations§
impl<P, H, R> Freeze for GraphServiceProcessor<P, H, R>where
H: Freeze,
impl<P, H, R> RefUnwindSafe for GraphServiceProcessor<P, H, R>
impl<P, H, R> Send for GraphServiceProcessor<P, H, R>
impl<P, H, R> Sync for GraphServiceProcessor<P, H, R>
impl<P, H, R> Unpin for GraphServiceProcessor<P, H, R>
impl<P, H, R> UnwindSafe for GraphServiceProcessor<P, H, R>
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