SelectionItem
- class Communicator.Selection.SelectionItem()
Methods
Methods
equals
- SelectionItem.equals(selectionItem)
Determines if two selection items are equal.
- Arguments
selectionItem (
SelectionItem()) – The selection item to test against.
- Return type
boolean
- Returns
whether or not the two items are equal.
forJson
- SelectionItem.forJson()
- Deprecated
Use
toJsoninstead.- Return type
Object
getFaceEntity
- SelectionItem.getFaceEntity()
Gets the face entity for this selection.
- Return type
FaceEntity()| null- Returns
the face entity if one was selected, otherwise null
getIncludeId
- SelectionItem.getIncludeId()
- Deprecated
Use
getInclusionKeyinstead.- Return type
SC.InclusionKey | null
getInclusionKey
- SelectionItem.getInclusionKey()
Gets the include id for this selection.
- Return type
SC.InclusionKey | null
- Returns
the inclusion key associated with this selection item
getLineEntity
- SelectionItem.getLineEntity()
Gets the line entity for this selection.
- Return type
LineEntity()| null- Returns
the line entity if one was selected, otherwise null
getNodeId
getPointEntity
- SelectionItem.getPointEntity()
Gets the point entity for this selection.
- Return type
PointEntity()| null- Returns
the point entity if one was selected, otherwise null
getPosition
- SelectionItem.getPosition()
Convenience method for getting the world space position of the selection point.
SelectionItemwith a type ofSelectionType.Partwill not have a position and null will be returned.- Return type
Point3()| null- Returns
World space position of the selection point if it can be determined.
getSelectionType
- SelectionItem.getSelectionType()
- Return type
isEntitySelection
- SelectionItem.isEntitySelection()
- Return type
this
- Returns
true if the object has the fields required for an
EntitySelectionItemThis function can be used as a TypeScript type guard.
isFaceSelection
- SelectionItem.isFaceSelection()
- Return type
this
- Returns
true if the object has the fields required for a
FaceSelectionItemThis function can be used as a TypeScript type guard.
isLineSelection
- SelectionItem.isLineSelection()
- Return type
this
- Returns
true if the object has the fields required for a
LineSelectionItemThis function can be used as a TypeScript type guard.
isNodeEntitySelection
- SelectionItem.isNodeEntitySelection()
- Return type
this
- Returns
true if the object has the fields required for a
NodeEntitySelectionItemThis function can be used as a TypeScript type guard.
isNodeSelection
- SelectionItem.isNodeSelection()
- Return type
this
- Returns
true if the object has the fields required for a
NodeSelectionItemThis function can be used as a TypeScript type guard.
isPointSelection
- SelectionItem.isPointSelection()
- Return type
this
- Returns
true if the object has the fields required for a
PointSelectionItemThis function can be used as a TypeScript type guard.
overlayIndex
- SelectionItem.overlayIndex()
Gets the overlay index for this selection.
- Return type
OverlayIndex | null
- Returns
the overlay index associated with this selection item
toJson
- SelectionItem.toJson()
Creates an object ready for JSON serialization.
- Return type
Object
- Returns
The prepared object.
static create
- SelectionItem.create(nodeId, inclusionKey, faceEntity[, lineEntity[, pointEntity]])
Create a new
FaceSelectionItem- Arguments
nodeId (NodeId) –
inclusionKey (
SC.InclusionKey | null | undefined()) –faceEntity (
FaceEntity()) –lineEntity (
LineEntity()| null) – optionalpointEntity (
PointEntity()| null) – optional
- Return type
- SelectionItem.create(nodeId, inclusionKey, faceEntity, lineEntity[, pointEntity])
Create a new
LineSelectionItem- Arguments
nodeId (NodeId) –
inclusionKey (
SC.InclusionKey | null | undefined()) –faceEntity (
FaceEntity()| null | undefined) –lineEntity (
LineEntity()) –pointEntity (
PointEntity()| null) – optional
- Return type
- SelectionItem.create(nodeId, inclusionKey, faceEntity, lineEntity, pointEntity)
Create a new
PointSelectionItem- Arguments
nodeId (NodeId) –
inclusionKey (
SC.InclusionKey | null | undefined()) –faceEntity (
FaceEntity()| null | undefined) –lineEntity (
LineEntity()| null | undefined) –pointEntity (
PointEntity()) –
- Return type
- SelectionItem.create(nodeId, inclusionKey, faceEntity[, lineEntity[, pointEntity]])
Create a new
EntitySelectionItem- Arguments
nodeId (NodeId | null | undefined) –
inclusionKey (
SC.InclusionKey | null | undefined()) –faceEntity (
FaceEntity()) –lineEntity (
LineEntity()| null) – optionalpointEntity (
PointEntity()| null) – optional
- Return type
- SelectionItem.create(nodeId, inclusionKey, faceEntity, lineEntity[, pointEntity])
Create a new
EntitySelectionItem- Arguments
nodeId (NodeId | null | undefined) –
inclusionKey (
SC.InclusionKey | null | undefined()) –faceEntity (
FaceEntity()| null | undefined) –lineEntity (
LineEntity()) –pointEntity (
PointEntity()| null) – optional
- Return type
- SelectionItem.create(nodeId, inclusionKey, faceEntity, lineEntity, pointEntity)
Create a new
EntitySelectionItem- Arguments
nodeId (NodeId | null | undefined) –
inclusionKey (
SC.InclusionKey | null | undefined()) –faceEntity (
FaceEntity()| null | undefined) –lineEntity (
LineEntity()| null | undefined) –pointEntity (
PointEntity()) –
- Return type
- SelectionItem.create(nodeId[, inclusionKey[, faceEntity[, lineEntity[, pointEntity]]]])
Create a new
NodeSelectionItem- Arguments
nodeId (NodeId) –
inclusionKey (
SC.InclusionKey | null()) – optionalfaceEntity (
FaceEntity()| null) – optionallineEntity (
LineEntity()| null) – optionalpointEntity (
PointEntity()| null) – optional
- Return type
- SelectionItem.create([nodeId[, inclusionKey[, faceEntity[, lineEntity[, pointEntity]]]]])
Create a new
SelectionItem- Arguments
nodeId (NodeId | null) – optional
inclusionKey (
SC.InclusionKey | null()) – optionalfaceEntity (
FaceEntity()| null) – optionallineEntity (
LineEntity()| null) – optionalpointEntity (
PointEntity()| null) – optional
- Return type