pub struct GimbalServiceClient<T> { /* private fields */ }Expand description
Provide control over a gimbal.
Implementations§
Source§impl<T> GimbalServiceClient<T>where
T: GrpcService<BoxBody>,
T::ResponseBody: Body + Send + Sync + 'static,
T::Error: Into<StdError>,
<T::ResponseBody as Body>::Error: Into<StdError> + Send,
impl<T> GimbalServiceClient<T>where
T: GrpcService<BoxBody>,
T::ResponseBody: Body + Send + Sync + 'static,
T::Error: Into<StdError>,
<T::ResponseBody as Body>::Error: Into<StdError> + Send,
pub fn new(inner: T) -> Self
pub fn with_interceptor<F>(
inner: T,
interceptor: F,
) -> GimbalServiceClient<InterceptedService<T, F>>where
F: Interceptor,
T: Service<Request<BoxBody>, Response = Response<<T as GrpcService<BoxBody>>::ResponseBody>>,
<T as Service<Request<BoxBody>>>::Error: Into<StdError> + Send + Sync,
Sourcepub fn send_gzip(self) -> Self
pub fn send_gzip(self) -> Self
Compress requests with gzip.
This requires the server to support it otherwise it might respond with an error.
Sourcepub fn accept_gzip(self) -> Self
pub fn accept_gzip(self) -> Self
Enable decompressing responses with gzip.
Sourcepub async fn set_pitch_and_yaw(
&mut self,
request: impl IntoRequest<SetPitchAndYawRequest>,
) -> Result<Response<SetPitchAndYawResponse>, Status>
pub async fn set_pitch_and_yaw( &mut self, request: impl IntoRequest<SetPitchAndYawRequest>, ) -> Result<Response<SetPitchAndYawResponse>, Status>
Set gimbal pitch and yaw angles.
This sets the desired pitch and yaw angles of a gimbal. Will return when the command is accepted, however, it might take the gimbal longer to actually be set to the new angles.
Sourcepub async fn set_mode(
&mut self,
request: impl IntoRequest<SetModeRequest>,
) -> Result<Response<SetModeResponse>, Status>
pub async fn set_mode( &mut self, request: impl IntoRequest<SetModeRequest>, ) -> Result<Response<SetModeResponse>, Status>
Set gimbal mode.
This sets the desired yaw mode of a gimbal. Will return when the command is accepted. However, it might take the gimbal longer to actually be set to the new angles.
Sourcepub async fn set_roi_location(
&mut self,
request: impl IntoRequest<SetRoiLocationRequest>,
) -> Result<Response<SetRoiLocationResponse>, Status>
pub async fn set_roi_location( &mut self, request: impl IntoRequest<SetRoiLocationRequest>, ) -> Result<Response<SetRoiLocationResponse>, Status>
Set gimbal region of interest (ROI).
This sets a region of interest that the gimbal will point to. The gimbal will continue to point to the specified region until it receives a new command. The function will return when the command is accepted, however, it might take the gimbal longer to actually rotate to the ROI.
Trait Implementations§
Source§impl<T: Clone> Clone for GimbalServiceClient<T>
impl<T: Clone> Clone for GimbalServiceClient<T>
Source§fn clone(&self) -> GimbalServiceClient<T>
fn clone(&self) -> GimbalServiceClient<T>
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreAuto Trait Implementations§
impl<T> Freeze for GimbalServiceClient<T>where
T: Freeze,
impl<T> RefUnwindSafe for GimbalServiceClient<T>where
T: RefUnwindSafe,
impl<T> Send for GimbalServiceClient<T>where
T: Send,
impl<T> Sync for GimbalServiceClient<T>where
T: Sync,
impl<T> Unpin for GimbalServiceClient<T>where
T: Unpin,
impl<T> UnwindSafe for GimbalServiceClient<T>where
T: UnwindSafe,
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
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>
T in a tonic::Request