pub enum TrimmingPreference {
Cartesian,
Parameter,
Unspecified,
}Expand description
IfcTrimmingPreference: which trim representation is authoritative.
Variants§
Cartesian
The IfcCartesianPoint wins where both are supplied.
Parameter
The IfcParameterValue wins where both are supplied.
Unspecified
Neither is preferred; the consumer must choose.
Common in exported files even when both forms are present, which is exactly when a choice is needed. Treat it as “use what you have, prefer the parameter for a conic” rather than as an error.
Implementations§
Source§impl TrimmingPreference
impl TrimmingPreference
Sourcepub fn from_token(token: &str) -> Option<Self>
pub fn from_token(token: &str) -> Option<Self>
Parse the enumeration token, e.g. CARTESIAN.
Returns None for an unrecognised token rather than defaulting, so a
caller can tell a typo in the file from an honest .UNSPECIFIED..
Sourcepub fn token(self) -> &'static str
pub fn token(self) -> &'static str
The EXPRESS token, the inverse of Self::from_token.
Kept beside the parser so the two cannot drift: a token added to one without the other stops compiling here.
Trait Implementations§
Source§impl Clone for TrimmingPreference
impl Clone for TrimmingPreference
Source§fn clone(&self) -> TrimmingPreference
fn clone(&self) -> TrimmingPreference
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 moreimpl Copy for TrimmingPreference
Source§impl Debug for TrimmingPreference
impl Debug for TrimmingPreference
impl Eq for TrimmingPreference
Source§impl PartialEq for TrimmingPreference
impl PartialEq for TrimmingPreference
impl StructuralPartialEq for TrimmingPreference
Auto Trait Implementations§
impl Freeze for TrimmingPreference
impl RefUnwindSafe for TrimmingPreference
impl Send for TrimmingPreference
impl Sync for TrimmingPreference
impl Unpin for TrimmingPreference
impl UnsafeUnpin for TrimmingPreference
impl UnwindSafe for TrimmingPreference
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