ExplodeService

class wvc.ExplodeService()

IExplodeService

Index

Constructors

Properties

Accessors

Methods

Constructors

wvc.ExplodeService.constructor()
ExplodeService(): ExplodeService

Returns: ExplodeService

Properties

wvc.ExplodeService.serviceName

readonly

serviceName: “ExplodeService”

Accessors

wvc.ExplodeService.webViewer()
get webViewer(): (undefined | IWebViewer)

Returns: (undefined | IWebViewer)

set webViewer(value: (undefined | IWebViewer)): void

Parameters

value: (undefined | IWebViewer)

Returns: void

Methods

wvc.ExplodeService.getActive()
getActive(): boolean

Indicates whether there is a currently active explode operation.

Returns: boolean

boolean value indicating if there is an active explode operation.
wvc.ExplodeService.getMagnitude()
getMagnitude(): number

Gets the current explode magnitude. This will always return 0 when there is no active explode operation.

Returns: number

the current explode magnitude.
wvc.ExplodeService.reset()
reset(): void

Resets the explode service, clearing any active operations.

Returns: void

wvc.ExplodeService.setMagnitude()
setMagnitude(magnitude: number): Promise

Sets the explosion magnitude if there is an active explosion operation. A value of 1.0 indicates that the distance between a part’s exploded center, and exploded center will be double.

Parameters

magnitude: number

the magnitude for the explosion.

Returns: Promise

a promise that resolves when this operation is complete.
wvc.ExplodeService.start()
start(nodeIds: number[], explosionVector: IPoint3): Promise

Starts an explode operation. This will cancel any currently active explode operation.

Parameters

nodeIds: number[]

an array of node Ids for the parts that should be exploded. If this parameter is omitted or is an empty array, the entire model will be considered for explosion.

explosionVector: IPoint3

the vector to use for the center of the explosion.

Returns: Promise

a promise that resolves when this operation is complete.
wvc.ExplodeService.stop()
stop(): Promise

Terminates any active explode operation.

Returns: Promise

a promise that resolves when this operation is complete.