.. role:: ts-api-decorator

#################
ClientSideHitItem
#################

.. js:module:: cee.ug
   :noindex:

.. container:: ts-api-section

   .. js:class:: ClientSideHitItem

      The result of a client side picking call on a ``RemoteModel``.

      Returned by ``RemoteModel.clientSideRayIntersect`` and ``TrianglePicker``.

      This class only contains data available on the client. For hit items with objectType = PART, ``QueryElementInfo.executeQueryByClientSideHitItems`` can
      be used to fetch complete data from the server.



.. container:: api-index-section

   .. rubric:: Accessors

   .. rst-class:: api-index-list-item api-kind-accessor api-parent-kind-class

   * :js:attr:`~cee.ug.ClientSideHitItem.geometryIndex`
   * :js:attr:`~cee.ug.ClientSideHitItem.intersectionPoint`
   * :js:attr:`~cee.ug.ClientSideHitItem.objectId`
   * :js:attr:`~cee.ug.ClientSideHitItem.objectType`
   * :js:attr:`~cee.ug.ClientSideHitItem.vertices`





------------

Accessors
=========

.. container:: ts-api-section

   .. js:function:: ClientSideHitItem.geometryIndex()



      The index of the CAE geometry.

      In almost all cases this will be 0. If using a partially adaptive model with remeshing only on parts of the model (e.g. in a Forging process)
      the concept of multiple geometries might be relevant.


      :rtype: number



.. container:: ts-api-section

   .. js:function:: ClientSideHitItem.intersectionPoint()



      The 3d point (in world coordinates) on the surface that was hit.

      This is the actual point that was hit.

      Note that this property is only set by rayIntersect(). It is left to null by TrianglePicker.


      :rtype: Vec3



.. container:: ts-api-section

   .. js:function:: ClientSideHitItem.objectId()



      The id of the object (part/iso/cut/isovol) that was hit


      :rtype: number



.. container:: ts-api-section

   .. js:function:: ClientSideHitItem.objectType()



      The type of object (part/iso/cut/isovol) that was hit


      :rtype: ObjectType



.. container:: ts-api-section

   .. js:function:: ClientSideHitItem.vertices()



      The triangle vertices of the geometry that was hit


      :rtype: [number]



