Struct wasmer_backend_api::types::Id

#[repr(transparent)]
pub struct Id(String);
Expand description

A GraphQL ID

Any field in a GraphQL schema that has the type ID should be represented by this struct.

Tuple Fields§

§0: String

Implementations§

§

impl Id

pub fn new(s: impl Into<String>) -> Id

Constructs an ID from a String, &str or similar

cynic::Id::new("123");

pub fn inner(&self) -> &str

Returns a reference to the value of this Id

pub fn into_inner(self) -> String

Converts this Id into its inner value

pub fn from_ref(s: &String) -> &Id

Converts a reference to a String to a reference to an Id

To be used when you can access an &String which you want to assume is an Id for use in Cynic structures without reallocating

If you don’t have a String at hand but only an &str, you should know that these can be used directly in InputObjects as well when the target GraphQL type is an Id.

Trait Implementations§

§

impl Clone for Id

§

fn clone(&self) -> Id

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
§

impl Debug for Id

§

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

Formats the value using the given formatter. Read more
§

impl<'de> Deserialize<'de> for Id

§

fn deserialize<__D>( __deserializer: __D, ) -> Result<Id, <__D as Deserializer<'de>>::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
§

impl<'a> From<&'a String> for &'a Id

§

fn from(s: &'a String) -> &'a Id

Converts to this type from the input type.
§

impl<T> From<T> for Id
where T: Into<String>,

§

fn from(s: T) -> Id

Converts to this type from the input type.
§

impl Hash for Id

§

fn hash<__H>(&self, state: &mut __H)
where __H: Hasher,

Feeds this value into the given Hasher. Read more
1.3.0 · source§

fn hash_slice<H>(data: &[Self], state: &mut H)
where H: Hasher, Self: Sized,

Feeds a slice of this type into the given Hasher. Read more
§

impl IsScalar<Id> for Id

§

type SchemaType = Id

The schema marker type this scalar represents.
§

impl NamedType for Id

§

const NAME: &'static str = "ID"

The name of this type
§

impl PartialEq for Id

§

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

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

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

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

impl RefCast for Id

§

type From = String

§

fn ref_cast(_from: &<Id as RefCast>::From) -> &Id

§

fn ref_cast_mut(_from: &mut <Id as RefCast>::From) -> &mut Id

§

impl Serialize for Id

§

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

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

impl Variable for Id

source§

const TYPE: VariableType = _

§

impl CoercesTo<Id> for Id

§

impl CoercesTo<Id> for str

§

impl CoercesTo<Option<Id>> for Id

§

impl CoercesTo<Option<Option<Id>>> for Id

§

impl CoercesTo<Option<Vec<Id>>> for Id

§

impl CoercesTo<Option<Vec<Option<Id>>>> for Id

§

impl CoercesTo<Vec<Id>> for Id

§

impl CoercesTo<Vec<Vec<Id>>> for Id

§

impl Eq for Id

source§

impl HasInputField<appId, Id> for BanAppInput

source§

impl HasInputField<appId, Id> for ClaimPerishableAppInput

source§

impl HasInputField<appId, Id> for DetachAppFromAutobuildInput

source§

impl HasInputField<appId, Id> for DisableAppInput

source§

impl HasInputField<appId, Id> for EnableAppInput

source§

impl HasInputField<appId, Id> for RequestAppTransferInput

source§

impl HasInputField<appId, Id> for UnbanAppInput

source§

impl HasInputField<appId, Id> for UpdateAutobuildConfigForAppInput

source§

impl HasInputField<appId, Id> for UpsertAppDomainInput

source§

impl HasInputField<appId, Id> for UpsertAppSecretInput

source§

impl HasInputField<appId, Id> for UpsertAppSecretsInput

source§

impl HasInputField<appTransferRequestId, Id> for AcceptAppTransferRequestInput

source§

impl HasInputField<appTransferRequestId, Id> for RemoveAppTransferRequestInput

source§

impl HasInputField<appVersion, Id> for MarkAppVersionAsActiveInput

source§

impl HasInputField<domainId, Id> for DeleteDomainInput

source§

impl HasInputField<domainId, Id> for VerifyAppDomainInput

source§

impl HasInputField<id, Id> for CreateAppDBInput

source§

impl HasInputField<id, Id> for DeleteAppDBInput

source§

impl HasInputField<id, Id> for DeleteAppDomainInput

source§

impl HasInputField<id, Id> for DeleteAppInput

source§

impl HasInputField<id, Id> for DeleteAppSecretInput

source§

impl HasInputField<id, Id> for InvalidateNonceInput

source§

impl HasInputField<id, Id> for MakePackagePublicInput

source§

impl HasInputField<id, Id> for PurgeCacheForAppVersionInput

source§

impl HasInputField<id, Id> for RedeployActiveVersionInput

source§

impl HasInputField<id, Id> for RemoveWebhookInput

source§

impl HasInputField<id, Id> for RenameAppAliasInput

source§

impl HasInputField<id, Id> for RenameAppInput

source§

impl HasInputField<id, Id> for RotateCredentialsForAppDBInput

source§

impl HasInputField<id, Id> for RotateS3SecretsForAppInput

source§

impl HasInputField<id, Id> for ToggleForceHTTPSInput

source§

impl HasInputField<id, Id> for ValidateNonceInput

source§

impl HasInputField<installationId, Id> for InstallGithubAppInput

source§

impl HasInputField<inviteId, Id> for AcceptNamespaceCollaboratorInviteInput

source§

impl HasInputField<inviteId, Id> for AcceptPackageCollaboratorInviteInput

source§

impl HasInputField<inviteId, Id> for RemoveNamespaceCollaboratorInviteInput

source§

impl HasInputField<inviteId, Id> for RemovePackageCollaboratorInviteInput

source§

impl HasInputField<namespaceCollaboratorId, Id> for RemoveNamespaceCollaboratorInput

source§

impl HasInputField<namespaceCollaboratorId, Id> for UpdateNamespaceCollaboratorRoleInput

source§

impl HasInputField<namespaceCollaboratorInviteId, Id> for UpdateNamespaceCollaboratorInviteRoleInput

source§

impl HasInputField<namespaceId, Id> for DeleteNamespaceInput

source§

impl HasInputField<namespaceId, Id> for InviteNamespaceCollaboratorInput

source§

impl HasInputField<namespaceId, Id> for UpdateNamespaceInput

source§

impl HasInputField<newOwnerId, Id> for RequestAppTransferInput

source§

impl HasInputField<newOwnerId, Id> for RequestPackageTransferInput

source§

impl HasInputField<notificationId, Id> for ReadNotificationInput

source§

impl HasInputField<packageCollaboratorId, Id> for RemovePackageCollaboratorInput

source§

impl HasInputField<packageCollaboratorId, Id> for UpdatePackageCollaboratorRoleInput

source§

impl HasInputField<packageCollaboratorInviteId, Id> for UpdatePackageCollaboratorInviteRoleInput

source§

impl HasInputField<packageId, Id> for ArchivePackageInput

source§

impl HasInputField<packageId, Id> for LikePackageInput

source§

impl HasInputField<packageId, Id> for RenamePackageInput

source§

impl HasInputField<packageId, Id> for RequestPackageTransferInput

source§

impl HasInputField<packageId, Id> for UnlikePackageInput

source§

impl HasInputField<packageId, Id> for UnwatchPackageInput

source§

impl HasInputField<packageId, Id> for UpdatePackageInput

source§

impl HasInputField<packageId, Id> for WatchPackageInput

source§

impl HasInputField<packageReleaseId, Id> for TagPackageReleaseInput

source§

impl HasInputField<packageTransferRequestId, Id> for AcceptPackageTransferRequestInput

source§

impl HasInputField<packageTransferRequestId, Id> for RemovePackageTransferRequestInput

source§

impl HasInputField<packageVersionId, Id> for ChangePackageVersionArchivedStatusInput

source§

impl HasInputField<paymentMethod, Id> for DetachPaymentMethodInput

source§

impl HasInputField<paymentMethod, Id> for SetDefaultPaymentMethodInput

source§

impl HasInputField<priceId, Id> for GenerateCheckoutUrlInput

source§

impl HasInputField<recordId, Id> for DeleteDNSRecordInput

source§

impl HasInputField<templateId, Id> for CreateRepoForAppTemplateInput

§

impl StructuralPartialEq for Id

Auto Trait Implementations§

§

impl Freeze for Id

§

impl RefUnwindSafe for Id

§

impl Send for Id

§

impl Sync for Id

§

impl Unpin for Id

§

impl UnwindSafe for Id

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
§

impl<T> ArchivePointee for T

§

type ArchivedMetadata = ()

The archived version of the pointer metadata for this type.
§

fn pointer_metadata( _: &<T as ArchivePointee>::ArchivedMetadata, ) -> <T as Pointee>::Metadata

Converts some archived metadata to the pointer metadata for itself.
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§

default unsafe fn clone_to_uninit(&self, dst: *mut T)

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

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

§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

§

fn equivalent(&self, key: &K) -> bool

Checks if this value is equivalent to the given key. Read more
§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

§

fn equivalent(&self, key: &K) -> bool

Compare self to key and return true if they are equal.
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

§

impl<T> Instrument for T

§

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

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

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> IntoEither for T

source§

fn into_either(self, into_left: bool) -> Either<Self, Self>

Converts self into a Left variant of Either<Self, Self> if into_left is true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

Converts self into a Left variant of Either<Self, Self> if into_left(&self) returns true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
§

impl<T> LayoutRaw for T

§

fn layout_raw(_: <T as Pointee>::Metadata) -> Result<Layout, LayoutError>

Returns the layout of the type.
§

impl<T, N1, N2> Niching<NichedOption<T, N1>> for N2
where T: SharedNiching<N1, N2>, N1: Niching<T>, N2: Niching<T>,

§

unsafe fn is_niched(niched: *const NichedOption<T, N1>) -> bool

Returns whether the given value has been niched. Read more
§

fn resolve_niched(out: Place<NichedOption<T, N1>>)

Writes data to out indicating that a T is niched.
§

impl<T> Pointable for T

§

const ALIGN: usize = _

The alignment of pointer.
§

type Init = T

The type for initializers.
§

unsafe fn init(init: <T as Pointable>::Init) -> usize

Initializes a with the given initializer. Read more
§

unsafe fn deref<'a>(ptr: usize) -> &'a T

Dereferences the given pointer. Read more
§

unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T

Mutably dereferences the given pointer. Read more
§

unsafe fn drop(ptr: usize)

Drops the object pointed to by the given pointer. Read more
§

impl<T> Pointee for T

§

type Metadata = ()

The metadata type for pointers and references to this type.
source§

impl<T> Same for T

§

type Output = T

Should always be Self
source§

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

§

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>,

§

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>,

§

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.
§

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

§

fn vzip(self) -> V

§

impl<T> WithSubscriber for T

§

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
§

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>,

§

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

§

impl<A, B, T> HttpServerConnExec<A, B> for T
where B: Body,

§

impl<T> IsFieldType<T> for T

§

impl<T> MaybeSendSync for T