GeometryStreamIterator Class

GeometryStreamIterator is a helper class for iterating a GeometryStreamProps. A GeometricElement's GeometryStream must be specifically requested using ElementLoadProps.wantGeometry. Each GeometryStreamIteratorEntry returned by the iterator represents exactly one geometric primitive in the stream.

Implements

Methods

Name Description
constructor(geometryStream: GeometryStreamProps, categoryOrGeometryParams?: string | GeometryParams, localToWorld?: Transform): GeometryStreamIterator Construct a new GeometryStreamIterator given a GeometryStreamProps from either a GeometricElement3d, GeometricElement2d, or GeometryPart.  
[iterator](): IterableIterator<GeometryStreamIteratorEntry>    
next(): IteratorResult<GeometryStreamIteratorEntry, any> Advance to next displayable geometric entry while updating the current GeometryParams from appearance related entries.  
partToWorld(): undefined | Transform Get the transform that if applied to a GeometryPart's GeometryStream entries would return them in world coordinates.  
fromGeometricElement2d(element: GeometricElement2dProps): GeometryStreamIterator Static Create a new GeometryStream iterator for a GeometricElement2d.  
fromGeometricElement3d(element: GeometricElement3dProps): GeometryStreamIterator Static Create a new GeometryStream iterator for a GeometricElement3d.  
fromGeometryPart(geomPart: GeometryPartProps, geomParams?: GeometryParams, partTransform?: Transform): GeometryStreamIterator Static Create a new GeometryStream iterator for a GeometryPart.  

Properties

Name Type Description
flags Readonly GeometryStreamFlags Flags applied to the entire geometry stream.  
geometryStream GeometryStreamProps GeometryStream entries  

Defined in

Last Updated: 11 June, 2024