insertAspect Method

Insert a new ElementAspect into the iModel.

insertAspect(aspectProps: ElementAspectProps): string

@throws IModelError if unable to insert the ElementAspect.

@returns the id of the newly inserted aspect.

@note Aspect Ids may collide with element Ids, so don't put both in a container like Set or Map use EntityReference for that instead.

Parameter Type Description
aspectProps ElementAspectProps The properties of the new ElementAspect.

Returns - string

the id of the newly inserted aspect.

Defined in

Last Updated: 16 April, 2024