Enum cargo_swift::Target
source · pub enum Target {
Single {
architecture: &'static str,
display_name: &'static str,
platform: ApplePlatform,
},
Universal {
universal_name: &'static str,
architectures: NonEmpty<&'static str>,
display_name: &'static str,
platform: ApplePlatform,
},
}
Variants§
Implementations§
source§impl Target
impl Target
sourcepub fn commands(
&self,
lib_name: &str,
mode: Mode,
lib_type: LibType,
features: &FeatureOptions
) -> Vec<Command>
pub fn commands( &self, lib_name: &str, mode: Mode, lib_type: LibType, features: &FeatureOptions ) -> Vec<Command>
Generates all commands necessary to build this target
This function returns a list of commands that should be executed in their given order to build this target (and bundle architecture targets with lipo if it is a universal target).
sourcepub fn architectures(&self) -> NonEmpty<&'static str>
pub fn architectures(&self) -> NonEmpty<&'static str>
Returns the names of all target architectures for this target
If this target is a single target, the returned vector will always contain exactly one element. The names returned here exactly match the identifiers of the respective official Rust targets.
pub fn display_name(&self) -> &'static str
pub fn platform(&self) -> ApplePlatform
pub fn library_directory(&self, mode: Mode) -> String
pub fn library_path( &self, lib_name: &str, mode: Mode, lib_type: LibType ) -> String
Trait Implementations§
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
source§impl<T> IntoEither for T
impl<T> IntoEither for T
source§fn into_either(self, into_left: bool) -> Either<Self, Self>
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 moresource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
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