pub struct ProgramTarget {
pub schema_version: u16,
pub profile: String,
pub cohort: ProgramTargetCohort,
pub native: Option<NativeTargetIdentity>,
}Fields§
§schema_version: u16§profile: String§cohort: ProgramTargetCohort§native: Option<NativeTargetIdentity>Implementations§
Source§impl ProgramTarget
impl ProgramTarget
pub fn portable(profile: impl Into<String>) -> Self
pub fn native(profile: impl Into<String>, target: NativeTargetIdentity) -> Self
pub fn validate(&self) -> ArtifactResult<()>
pub fn validate_form(&self, form: ExecutableForm) -> ArtifactResult<()>
pub fn validate_for_portable_host(&self) -> ArtifactResult<()>
pub fn validate_for_native_host( &self, host: &NativeTargetIdentity, ) -> ArtifactResult<()>
pub fn canonical_bytes(&self) -> ArtifactResult<Vec<u8>>
pub fn from_canonical_bytes(bytes: &[u8]) -> ArtifactResult<Self>
Trait Implementations§
Source§impl Clone for ProgramTarget
impl Clone for ProgramTarget
Source§fn clone(&self) -> ProgramTarget
fn clone(&self) -> ProgramTarget
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · 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 ProgramTarget
impl Debug for ProgramTarget
Source§impl<'de> Deserialize<'de> for ProgramTarget
impl<'de> Deserialize<'de> for ProgramTarget
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
impl Eq for ProgramTarget
Source§impl PartialEq for ProgramTarget
impl PartialEq for ProgramTarget
Source§impl Serialize for ProgramTarget
impl Serialize for ProgramTarget
impl StructuralPartialEq for ProgramTarget
Auto Trait Implementations§
impl Freeze for ProgramTarget
impl RefUnwindSafe for ProgramTarget
impl Send for ProgramTarget
impl Sync for ProgramTarget
impl Unpin for ProgramTarget
impl UnsafeUnpin for ProgramTarget
impl UnwindSafe for ProgramTarget
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,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
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.