pub struct SymbolicRepresentationCollection { /* private fields */ }Expand description
Collection of symbolic representations for an IFC model
Implementations§
Source§impl SymbolicRepresentationCollection
impl SymbolicRepresentationCollection
Sourcepub fn get_express_ids(&self) -> Vec<u32>
pub fn get_express_ids(&self) -> Vec<u32>
Get all express IDs that have symbolic representations
Sourcepub fn polyline_count(&self) -> usize
pub fn polyline_count(&self) -> usize
Get number of polylines
Sourcepub fn circle_count(&self) -> usize
pub fn circle_count(&self) -> usize
Get number of circles/arcs
Sourcepub fn text_count(&self) -> usize
pub fn text_count(&self) -> usize
Get number of text annotations
Sourcepub fn fill_count(&self) -> usize
pub fn fill_count(&self) -> usize
Get number of fill areas
Sourcepub fn total_count(&self) -> usize
pub fn total_count(&self) -> usize
Get total count of all symbolic items
Sourcepub fn is_empty(&self) -> bool
pub fn is_empty(&self) -> bool
Check if collection is empty. A TRUNCATED result never is, even with no
primitives; the reasoning and the parity test are in symbolic_truncation.rs.
Sourcepub fn get_polyline(&self, index: usize) -> Option<SymbolicPolyline>
pub fn get_polyline(&self, index: usize) -> Option<SymbolicPolyline>
Get polyline at index
Sourcepub fn get_circle(&self, index: usize) -> Option<SymbolicCircle>
pub fn get_circle(&self, index: usize) -> Option<SymbolicCircle>
Get circle at index
Sourcepub fn get_text(&self, index: usize) -> Option<SymbolicText>
pub fn get_text(&self, index: usize) -> Option<SymbolicText>
Get text annotation at index.
Sourcepub fn get_fill(&self, index: usize) -> Option<SymbolicFillArea>
pub fn get_fill(&self, index: usize) -> Option<SymbolicFillArea>
Get fill area at index.
Source§impl SymbolicRepresentationCollection
impl SymbolicRepresentationCollection
pub fn new() -> Self
pub fn with_capacity(polyline_capacity: usize, circle_capacity: usize) -> Self
pub fn add_polyline(&mut self, polyline: SymbolicPolyline)
pub fn add_circle(&mut self, circle: SymbolicCircle)
pub fn add_text(&mut self, text: SymbolicText)
pub fn add_fill(&mut self, fill: SymbolicFillArea)
Source§impl SymbolicRepresentationCollection
impl SymbolicRepresentationCollection
Sourcepub fn from_data(data: SymbolicData) -> Self
pub fn from_data(data: SymbolicData) -> Self
Convert from the canonical ifc_lite_processing::SymbolicData
(issue #843 follow-up — full parity refactor). The WASM-side
extractor now delegates to the processing crate and converts the
result here so the browser and the HTTP server produce bit-
identical symbol streams from one canonical implementation.
“Bit-identical” is the contract, so every field of every primitive has to cross — a field this function forgets is a field the browser silently never sees, while the server’s JSON for the same file still carries it.
Sourcepub fn from_data_with_provenance(data: SymbolicDataWithProvenance) -> Self
pub fn from_data_with_provenance(data: SymbolicDataWithProvenance) -> Self
Convert canonical symbols with the extraction-bound fill sidecar.
Source§impl SymbolicRepresentationCollection
impl SymbolicRepresentationCollection
Sourcepub fn truncated_at(&self) -> Option<usize>
pub fn truncated_at(&self) -> Option<usize>
Primitive count at which extraction stopped, else undefined.
Sourcepub fn truncated_reason(&self) -> Option<String>
pub fn truncated_reason(&self) -> Option<String>
Which bound stopped extraction, else undefined. One of
element-count, output-bytes, item-depth, item-revisits,
item-cycle — the same kebab-case strings the JSON path emits, so a
consumer reading either surface reads one vocabulary.
Sourcepub fn truncated_limit(&self) -> Option<usize>
pub fn truncated_limit(&self) -> Option<usize>
The bound’s numeric value, when the reason has one, else undefined.
Absent for the per-item reasons, whose bound is per item and not
comparable with truncatedAt.
Trait Implementations§
Source§impl From<SymbolicRepresentationCollection> for JsValue
impl From<SymbolicRepresentationCollection> for JsValue
Source§fn from(value: SymbolicRepresentationCollection) -> Self
fn from(value: SymbolicRepresentationCollection) -> Self
Source§impl LongRefFromWasmAbi for SymbolicRepresentationCollection
impl LongRefFromWasmAbi for SymbolicRepresentationCollection
Source§type Abi = WasmPtr<WasmRefCell<SymbolicRepresentationCollection>>
type Abi = WasmPtr<WasmRefCell<SymbolicRepresentationCollection>>
RefFromWasmAbi::AbiSource§type Anchor = RcRef<SymbolicRepresentationCollection>
type Anchor = RcRef<SymbolicRepresentationCollection>
RefFromWasmAbi::AnchorSource§unsafe fn long_ref_from_abi(js: Self::Abi) -> Self::Anchor
unsafe fn long_ref_from_abi(js: Self::Abi) -> Self::Anchor
RefFromWasmAbi::ref_from_abiSource§impl RefFromWasmAbi for SymbolicRepresentationCollection
impl RefFromWasmAbi for SymbolicRepresentationCollection
Source§type Abi = WasmPtr<WasmRefCell<SymbolicRepresentationCollection>>
type Abi = WasmPtr<WasmRefCell<SymbolicRepresentationCollection>>
Self are recovered from.Source§type Anchor = RcRef<SymbolicRepresentationCollection>
type Anchor = RcRef<SymbolicRepresentationCollection>
Self for the duration of the
invocation of the function that has an &Self parameter. This is
required to ensure that the lifetimes don’t persist beyond one function
call, and so that they remain anonymous.Source§impl RefMutFromWasmAbi for SymbolicRepresentationCollection
impl RefMutFromWasmAbi for SymbolicRepresentationCollection
Source§type Abi = WasmPtr<WasmRefCell<SymbolicRepresentationCollection>>
type Abi = WasmPtr<WasmRefCell<SymbolicRepresentationCollection>>
RefFromWasmAbi::AbiSource§type Anchor = RcRefMut<SymbolicRepresentationCollection>
type Anchor = RcRefMut<SymbolicRepresentationCollection>
RefFromWasmAbi::AnchorSource§unsafe fn ref_mut_from_abi(js: Self::Abi) -> Self::Anchor
unsafe fn ref_mut_from_abi(js: Self::Abi) -> Self::Anchor
RefFromWasmAbi::ref_from_abiSource§impl VectorFromWasmAbi for SymbolicRepresentationCollection
impl VectorFromWasmAbi for SymbolicRepresentationCollection
type Abi = <Box<[JsValue]> as FromWasmAbi>::Abi
unsafe fn vector_from_abi( js: Self::Abi, ) -> Box<[SymbolicRepresentationCollection]>
Source§impl VectorIntoWasmAbi for SymbolicRepresentationCollection
impl VectorIntoWasmAbi for SymbolicRepresentationCollection
type Abi = <Box<[JsValue]> as IntoWasmAbi>::Abi
fn vector_into_abi(vector: Box<[SymbolicRepresentationCollection]>) -> Self::Abi
Source§impl WasmDescribeVector for SymbolicRepresentationCollection
impl WasmDescribeVector for SymbolicRepresentationCollection
impl SupportsConstructor for SymbolicRepresentationCollection
impl SupportsInstanceProperty for SymbolicRepresentationCollection
impl SupportsStaticProperty for SymbolicRepresentationCollection
Auto Trait Implementations§
impl Freeze for SymbolicRepresentationCollection
impl RefUnwindSafe for SymbolicRepresentationCollection
impl Send for SymbolicRepresentationCollection
impl Sync for SymbolicRepresentationCollection
impl Unpin for SymbolicRepresentationCollection
impl UnwindSafe for SymbolicRepresentationCollection
Blanket Implementations§
§impl<U> As for U
impl<U> As for U
§fn as_<T>(self) -> Twhere
T: CastFrom<U>,
fn as_<T>(self) -> Twhere
T: CastFrom<U>,
self to type T. The semantics of numeric casting with the as operator are followed, so <T as As>::as_::<U> can be used in the same way as T as U for numeric conversions. Read moreSource§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
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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>
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>
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§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<T> ReturnWasmAbi for Twhere
T: IntoWasmAbi,
impl<T> ReturnWasmAbi for Twhere
T: IntoWasmAbi,
Source§type Abi = <T as IntoWasmAbi>::Abi
type Abi = <T as IntoWasmAbi>::Abi
IntoWasmAbi::AbiSource§fn return_abi(self) -> <T as ReturnWasmAbi>::Abi
fn return_abi(self) -> <T as ReturnWasmAbi>::Abi
IntoWasmAbi::into_abi, except that it may throw and never
return in the case of Err.§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
self from the equivalent element of its
superset. Read more§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
self is actually part of its subset T (and can be converted to it).§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
self.to_subset but without any property checks. Always succeeds.§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
self to the equivalent element of its superset.