pub struct OffboardServiceServer<T: OffboardService> { /* private fields */ }Expand description
Control a drone with position, velocity, attitude or motor commands.
The module is called offboard because the commands can be sent from external sources as opposed to onboard control right inside the autopilot “board”.
Client code must specify a setpoint before starting offboard mode. Mavsdk automatically sends setpoints at 20Hz (PX4 Offboard mode requires that setpoints are minimally sent at 2Hz).
Implementations§
Source§impl<T: OffboardService> OffboardServiceServer<T>
impl<T: OffboardService> OffboardServiceServer<T>
pub fn new(inner: T) -> Self
pub fn with_interceptor<F>(
inner: T,
interceptor: F,
) -> InterceptedService<Self, F>where
F: Interceptor,
Trait Implementations§
Source§impl<T: OffboardService> Clone for OffboardServiceServer<T>
impl<T: OffboardService> Clone for OffboardServiceServer<T>
Source§impl<T: Debug + OffboardService> Debug for OffboardServiceServer<T>
impl<T: Debug + OffboardService> Debug for OffboardServiceServer<T>
Source§impl<T: OffboardService> NamedService for OffboardServiceServer<T>
impl<T: OffboardService> NamedService for OffboardServiceServer<T>
Source§impl<T, B> Service<Request<B>> for OffboardServiceServer<T>
impl<T, B> Service<Request<B>> for OffboardServiceServer<T>
Source§type Future = Pin<Box<dyn Future<Output = Result<<OffboardServiceServer<T> as Service<Request<B>>>::Response, <OffboardServiceServer<T> as Service<Request<B>>>::Error>> + Send>>
type Future = Pin<Box<dyn Future<Output = Result<<OffboardServiceServer<T> as Service<Request<B>>>::Response, <OffboardServiceServer<T> as Service<Request<B>>>::Error>> + Send>>
The future response value.
Auto Trait Implementations§
impl<T> Freeze for OffboardServiceServer<T>
impl<T> RefUnwindSafe for OffboardServiceServer<T>where
T: RefUnwindSafe,
impl<T> Send for OffboardServiceServer<T>
impl<T> Sync for OffboardServiceServer<T>
impl<T> Unpin for OffboardServiceServer<T>
impl<T> UnwindSafe for OffboardServiceServer<T>where
T: RefUnwindSafe,
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, ReqBody, ResBody> GrpcService<ReqBody> for T
impl<T, ReqBody, ResBody> GrpcService<ReqBody> for T
Source§type ResponseBody = ResBody
type ResponseBody = ResBody
Responses body given by the service.
Source§fn poll_ready(
&mut self,
cx: &mut Context<'_>,
) -> Poll<Result<(), <T as GrpcService<ReqBody>>::Error>>
fn poll_ready( &mut self, cx: &mut Context<'_>, ) -> Poll<Result<(), <T as GrpcService<ReqBody>>::Error>>
Returns
Ready when the service is able to process requests. Read moreSource§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::RequestSource§impl<T, Request> ServiceExt<Request> for T
impl<T, Request> ServiceExt<Request> for T
Source§fn ready(&mut self) -> Ready<'_, Self, Request>where
Self: Sized,
fn ready(&mut self) -> Ready<'_, Self, Request>where
Self: Sized,
Yields a mutable reference to the service when it is ready to accept a request.
Source§fn ready_and(&mut self) -> Ready<'_, Self, Request>where
Self: Sized,
fn ready_and(&mut self) -> Ready<'_, Self, Request>where
Self: Sized,
👎Deprecated since 0.4.6: please use the
ServiceExt::ready method insteadYields a mutable reference to the service when it is ready to accept a request.
Source§fn ready_oneshot(self) -> ReadyOneshot<Self, Request>where
Self: Sized,
fn ready_oneshot(self) -> ReadyOneshot<Self, Request>where
Self: Sized,
Yields the service when it is ready to accept a request.
Source§fn oneshot(self, req: Request) -> Oneshot<Self, Request>where
Self: Sized,
fn oneshot(self, req: Request) -> Oneshot<Self, Request>where
Self: Sized,
Consume this
Service, calling with the providing request once it is ready.Source§fn and_then<F>(self, f: F) -> AndThen<Self, F>
fn and_then<F>(self, f: F) -> AndThen<Self, F>
Executes a new future after this service’s future resolves. This does
not alter the behaviour of the
poll_ready method. Read moreSource§fn map_response<F, Response>(self, f: F) -> MapResponse<Self, F>
fn map_response<F, Response>(self, f: F) -> MapResponse<Self, F>
Maps this service’s response value to a different value. This does not
alter the behaviour of the
poll_ready method. Read moreSource§fn map_err<F, Error>(self, f: F) -> MapErr<Self, F>
fn map_err<F, Error>(self, f: F) -> MapErr<Self, F>
Maps this service’s error value to a different value. This does not
alter the behaviour of the
poll_ready method. Read moreSource§fn map_result<F, Response, Error>(self, f: F) -> MapResult<Self, F>
fn map_result<F, Response, Error>(self, f: F) -> MapResult<Self, F>
Maps this service’s result type (
Result<Self::Response, Self::Error>)
to a different value, regardless of whether the future succeeds or
fails. Read moreSource§fn map_request<F, NewRequest>(self, f: F) -> MapRequest<Self, F>
fn map_request<F, NewRequest>(self, f: F) -> MapRequest<Self, F>
Composes a function in front of the service. Read more