pub struct Code(/* private fields */);
Expand description

Error codes for Check responses.

Implementations§

Source§

impl Code

Source

pub const ERROR_CODE_UNSPECIFIED: Code

This is never used in CheckResponse.

Source

pub const NOT_FOUND: Code

The consumer’s project id, network container, or resource container was not found. Same as [google.rpc.Code.NOT_FOUND][google.rpc.Code.NOT_FOUND].

Source

pub const PERMISSION_DENIED: Code

The consumer doesn’t have access to the specified resource. Same as [google.rpc.Code.PERMISSION_DENIED][google.rpc.Code.PERMISSION_DENIED].

Source

pub const RESOURCE_EXHAUSTED: Code

Quota check failed. Same as [google.rpc.Code.RESOURCE_EXHAUSTED][google.rpc.Code.RESOURCE_EXHAUSTED].

Source

pub const SERVICE_NOT_ACTIVATED: Code

The consumer hasn’t activated the service.

Source

pub const BILLING_DISABLED: Code

The consumer cannot access the service because billing is disabled.

Source

pub const PROJECT_DELETED: Code

The consumer’s project has been marked as deleted (soft deletion).

Source

pub const PROJECT_INVALID: Code

The consumer’s project number or id does not represent a valid project.

Source

pub const CONSUMER_INVALID: Code

The input consumer info does not represent a valid consumer folder or organization.

Source

pub const IP_ADDRESS_BLOCKED: Code

The IP address of the consumer is invalid for the specific consumer project.

Source

pub const REFERER_BLOCKED: Code

The referer address of the consumer request is invalid for the specific consumer project.

Source

pub const CLIENT_APP_BLOCKED: Code

The client application of the consumer request is invalid for the specific consumer project.

Source

pub const API_TARGET_BLOCKED: Code

The API targeted by this request is invalid for the specified consumer project.

Source

pub const API_KEY_INVALID: Code

The consumer’s API key is invalid.

Source

pub const API_KEY_EXPIRED: Code

The consumer’s API Key has expired.

Source

pub const API_KEY_NOT_FOUND: Code

The consumer’s API Key was not found in config record.

Source

pub const INVALID_CREDENTIAL: Code

The credential in the request can not be verified.

Source

pub const NAMESPACE_LOOKUP_UNAVAILABLE: Code

The backend server for looking up project id/number is unavailable.

Source

pub const SERVICE_STATUS_UNAVAILABLE: Code

The backend server for checking service status is unavailable.

Source

pub const BILLING_STATUS_UNAVAILABLE: Code

The backend server for checking billing status is unavailable.

Source

pub const CLOUD_RESOURCE_MANAGER_BACKEND_UNAVAILABLE: Code

Cloud Resource Manager backend server is unavailable.

Source

pub fn value(&self) -> i32

Gets the enum value.

Source

pub fn as_str_name(&self) -> Cow<'static, str>

Gets the enum value as a string.

Source

pub fn from_str_name(name: &str) -> Option<Self>

Creates an enum value from the value name.

Trait Implementations§

Source§

impl Clone for Code

Source§

fn clone(&self) -> Code

Returns a copy of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for Code

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Default for Code

Source§

fn default() -> Self

Returns the “default value” for a type. Read more
Source§

impl<'de> Deserialize<'de> for Code

Source§

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 From<i32> for Code

Source§

fn from(value: i32) -> Self

Converts to this type from the input type.
Source§

impl PartialEq for Code

Source§

fn eq(&self, other: &Code) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl Serialize for Code

Source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
Source§

impl StructuralPartialEq for Code

Auto Trait Implementations§

§

impl Freeze for Code

§

impl RefUnwindSafe for Code

§

impl Send for Code

§

impl Sync for Code

§

impl Unpin for Code

§

impl UnwindSafe for Code

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

Source§

fn vzip(self) -> V

Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,

Source§

impl<T> ErasedDestructor for T
where T: 'static,

Source§

impl<T> MaybeSendSync for T