#[non_exhaustive]pub enum Error {
Show 16 variants
Request(Error),
NotAuthenticated,
InvalidDataSource(String),
InvalidUsername(String),
InvalidConnectionId(String),
InvalidSharingProfileId(String),
InvalidUserGroupId(String),
InvalidConnectionGroupId(String),
InvalidTunnelId(String),
InvalidToken(String),
InvalidQueryParam {
name: String,
reason: String,
},
Unauthorized {
body: String,
},
Forbidden {
body: String,
},
NotFound {
resource: String,
body: String,
},
RateLimited {
retry_after: Option<Duration>,
},
Api {
status: StatusCode,
body: String,
},
}Expand description
Errors returned by the Guacamole client.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Request(Error)
An underlying HTTP request failed.
NotAuthenticated
No authentication token is available; call login() first.
InvalidDataSource(String)
The supplied data source name is invalid.
InvalidUsername(String)
The supplied username is invalid.
InvalidConnectionId(String)
The supplied connection ID is invalid.
InvalidSharingProfileId(String)
The supplied sharing profile ID is invalid.
InvalidUserGroupId(String)
The supplied user group ID is invalid.
InvalidConnectionGroupId(String)
The supplied connection group ID is invalid.
InvalidTunnelId(String)
The supplied tunnel ID is invalid.
InvalidToken(String)
The authentication token is invalid (contains unsafe characters).
InvalidQueryParam
A query parameter value is invalid (contains unsafe characters).
The API returned 401 Unauthorized.
Fields
Response body from the server.
Forbidden
The API returned 403 Forbidden.
NotFound
The requested resource was not found (404).
Fields
RateLimited
The API returned 429 Too Many Requests.
Api
Any other non-success HTTP status code.
Trait Implementations§
Source§impl Error for Error
impl Error for Error
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()
Auto Trait Implementations§
impl Freeze for Error
impl !RefUnwindSafe for Error
impl Send for Error
impl Sync for Error
impl Unpin for Error
impl UnsafeUnpin for Error
impl !UnwindSafe for Error
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> 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> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
Source§impl<T> ToStringFallible for Twhere
T: Display,
impl<T> ToStringFallible for Twhere
T: Display,
Source§fn try_to_string(&self) -> Result<String, TryReserveError>
fn try_to_string(&self) -> Result<String, TryReserveError>
ToString::to_string, but without panic on OOM.