Struct google_cloud_storage::http::error::ErrorResponse
source · pub struct ErrorResponse {
pub code: u16,
pub errors: Vec<ErrorResponseItem>,
pub message: String,
}Expand description
An error response returned from Google Cloud Storage.
See the HTTP status and error codes for JSON documentation for more details.
Fields§
§code: u16An HTTP status value, without the textual description.
Example values include: 400 (Bad Request), 401 (Unauthorized), and 404 (Not Found).
errors: Vec<ErrorResponseItem>A container for the error details.
message: StringDescription of the error. Same as errors.message.
Implementations§
source§impl ErrorResponse
impl ErrorResponse
sourcepub fn is_retriable(&self) -> bool
pub fn is_retriable(&self) -> bool
Returns true if the error is retriable according to the GCS documentation.
Trait Implementations§
source§impl Debug for ErrorResponse
impl Debug for ErrorResponse
source§impl<'de> Deserialize<'de> for ErrorResponse
impl<'de> Deserialize<'de> for ErrorResponse
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where __D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl Display for ErrorResponse
impl Display for ErrorResponse
source§impl Error for ErrorResponse
impl Error for ErrorResponse
1.30.0 · source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
The lower-level source of this error, if any. Read more
1.0.0 · source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()
source§impl From<ErrorResponse> for Error
impl From<ErrorResponse> for Error
source§fn from(source: ErrorResponse) -> Self
fn from(source: ErrorResponse) -> Self
Converts to this type from the input type.