#[non_exhaustive]pub struct Model {
pub name: String,
pub id: Option<u64>,
pub kind: ModelKind,
pub is_3d: bool,
pub entities: Vec<Entity>,
pub props: Props,
}Expand description
A space that holds drawn entities: model space, a paper-space layout or a DGN model.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.name: StringDisplay name.
id: Option<u64>Native identifier.
kind: ModelKindKind of space.
is_3d: boolModel stores 3D geometry.
entities: Vec<Entity>Entities in drawing order.
props: PropsFormat-specific extras.
Implementations§
Source§impl Model
impl Model
Sourcepub fn with_is_3d(self, value: bool) -> Self
pub fn with_is_3d(self, value: bool) -> Self
Sets Self::is_3d.
Sourcepub fn with_entities(self, value: Vec<Entity>) -> Self
pub fn with_entities(self, value: Vec<Entity>) -> Self
Sets Self::entities.
Sourcepub fn with_props(self, value: Props) -> Self
pub fn with_props(self, value: Props) -> Self
Sets Self::props.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Model
impl<'de> Deserialize<'de> for Model
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 StructuralPartialEq for Model
Auto Trait Implementations§
impl Forget for Model
impl Freeze for Model
impl Move for Model
impl RefUnwindSafe for Model
impl Send for Model
impl Sync for Model
impl Unpin for Model
impl UnsafeUnpin for Model
impl UnwindSafe for Model
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