pub enum PackageSource {
Ident(PackageIdent),
Path(String),
Url(Url),
}
Expand description
Source location of a package.
Variants§
Ident(PackageIdent)
An identifier in the format prescribed by [WebcIdent
].
Path(String)
An absolute or relative (dot-leading) path.
Url(Url)
Implementations§
Trait Implementations§
Source§impl Clone for PackageSource
impl Clone for PackageSource
Source§fn clone(&self) -> PackageSource
fn clone(&self) -> PackageSource
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for PackageSource
impl Debug for PackageSource
Source§impl<'de> Deserialize<'de> for PackageSource
impl<'de> Deserialize<'de> for PackageSource
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 PackageSource
impl Display for PackageSource
Source§impl From<NamedPackageId> for PackageSource
impl From<NamedPackageId> for PackageSource
Source§fn from(value: NamedPackageId) -> Self
fn from(value: NamedPackageId) -> Self
Converts to this type from the input type.
Source§impl From<NamedPackageIdent> for PackageSource
impl From<NamedPackageIdent> for PackageSource
Source§fn from(value: NamedPackageIdent) -> Self
fn from(value: NamedPackageIdent) -> Self
Converts to this type from the input type.
Source§impl From<PackageHash> for PackageSource
impl From<PackageHash> for PackageSource
Source§fn from(value: PackageHash) -> Self
fn from(value: PackageHash) -> Self
Converts to this type from the input type.
Source§impl From<PackageId> for PackageSource
impl From<PackageId> for PackageSource
Source§impl From<PackageIdent> for PackageSource
impl From<PackageIdent> for PackageSource
Source§fn from(id: PackageIdent) -> Self
fn from(id: PackageIdent) -> Self
Converts to this type from the input type.
Source§impl FromStr for PackageSource
impl FromStr for PackageSource
Source§impl Hash for PackageSource
impl Hash for PackageSource
Source§impl JsonSchema for PackageSource
impl JsonSchema for PackageSource
Source§fn schema_name() -> String
fn schema_name() -> String
The name of the generated JSON Schema. Read more
Source§fn json_schema(gen: &mut SchemaGenerator) -> Schema
fn json_schema(gen: &mut SchemaGenerator) -> Schema
Generates a JSON Schema for this type. Read more
Source§fn is_referenceable() -> bool
fn is_referenceable() -> bool
Whether JSON Schemas generated for this type should be re-used where possible using the
$ref
keyword. Read moreSource§impl PartialEq for PackageSource
impl PartialEq for PackageSource
Source§impl Serialize for PackageSource
impl Serialize for PackageSource
impl Eq for PackageSource
impl StructuralPartialEq for PackageSource
Auto Trait Implementations§
impl Freeze for PackageSource
impl RefUnwindSafe for PackageSource
impl Send for PackageSource
impl Sync for PackageSource
impl Unpin for PackageSource
impl UnwindSafe for PackageSource
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
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.