pub struct Target(/* private fields */);
Expand description
An object representing a specific build target for an artifact being managed by fluvio-index.
This type is generally constructed using FromStr
via the
parse
method.
§Example
let target: Target = "x86_64-unknown-linux-musl".parse().unwrap();
Implementations§
Source§impl Target
impl Target
pub const X86_64AppleDarwin: Target
pub const X86_64UnknownLinuxMusl: Target
pub const ALL_TARGETS: &'static [Target]
pub fn as_str(&self) -> &str
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Target
impl<'de> Deserialize<'de> for Target
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 FromStr for Target
impl FromStr for Target
Source§fn from_str(s: &str) -> Result<Self, Self::Err>
fn from_str(s: &str) -> Result<Self, Self::Err>
When parsing from a string, here is the chance to make any
edits or to collapse multiple target names into one. An
example of this is how we transform the target name
x86_64-unknown-linux-gnu
into x86_64-unknown-linux-musl
.
Additionally, if there are any “target strings” that we know for a fact that we cannot support, we can identify those strings here and manually reject them in order to prevent downstream tooling from incorrectly allowing those targets.
All other target names should pass through unchanged.
impl Eq for Target
impl StructuralPartialEq for Target
Auto Trait Implementations§
impl Freeze for Target
impl RefUnwindSafe for Target
impl Send for Target
impl Sync for Target
impl Unpin for Target
impl UnwindSafe for Target
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