
###########################
HoopsServiceRegistryElement
###########################

.. js:class:: wvc.HoopsServiceRegistryElement

   HoopsServiceRegistryElement is a LitElement-based web component that provides centralized service registration and management for the Hoops web viewer application.
   
   This component acts as a dependency injection container, automatically registering all core services when connected to the DOM. It provides a convenient way to bootstrap the entire service ecosystem with sensible defaults while allowing for easy customization.
   
   Features:
   
   
   - Automatic registration of all core services
   - Service customization through properties
   - Type-safe service retrieval methods
   - Zero-configuration setup with sensible defaults
   - Service locator pattern implementation
   
   .. rubric:: Examples
   
   
   .. code-block:: html
   
      <hoops-service-registry></hoops-service-registry>
      
      <script>
        const measurementService = document.getElementsByTagName('hoops-service-registry')[0].getService('MeasurementService');
      </script>
   
   .. rubric:: Custom Element
   
   
   ``hoops-service-registry``
   
   .. rubric:: Since
   
   
   ``2025.8.0``
   
   
   Index
   =====
   
   .. rubric:: Constructors
   
   
   .. rst-class:: api-xref-list
   
   
   * :js:func:`~wvc.HoopsServiceRegistryElement.constructor`
   
   .. rubric:: Properties
   
   
   .. rst-class:: api-xref-list
   
   
   * :js:data:`~wvc.HoopsServiceRegistryElement.cameraService`
   * :js:data:`~wvc.HoopsServiceRegistryElement.cuttingService`
   * :js:data:`~wvc.HoopsServiceRegistryElement.explodeService`
   * :js:data:`~wvc.HoopsServiceRegistryElement.floorplanService`
   * :js:data:`~wvc.HoopsServiceRegistryElement.ifcRelationshipsService`
   * :js:data:`~wvc.HoopsServiceRegistryElement.logService`
   * :js:data:`~wvc.HoopsServiceRegistryElement.materialService`
   * :js:data:`~wvc.HoopsServiceRegistryElement.measurementService`
   * :js:data:`~wvc.HoopsServiceRegistryElement.noteTextService`
   * :js:data:`~wvc.HoopsServiceRegistryElement.pmiService`
   * :js:data:`~wvc.HoopsServiceRegistryElement.redlineService`
   * :js:data:`~wvc.HoopsServiceRegistryElement.renderOptionsService`
   * :js:data:`~wvc.HoopsServiceRegistryElement.selectionService`
   * :js:data:`~wvc.HoopsServiceRegistryElement.sheetService`
   * :js:data:`~wvc.HoopsServiceRegistryElement.spaceMouseService`
   * :js:data:`~wvc.HoopsServiceRegistryElement.viewService`
   * :js:data:`~wvc.HoopsServiceRegistryElement.walkOperatorService`
   
   .. rubric:: Methods
   
   
   .. rst-class:: api-xref-list
   
   
   * :js:meth:`~wvc.HoopsServiceRegistryElement.connectedCallback`
   * :js:meth:`~wvc.HoopsServiceRegistryElement.getService`
   * :js:meth:`~wvc.HoopsServiceRegistryElement.tryGetService`
   
   



.. rst-class:: kind-group kind-constructors

.. rubric:: Constructors
   :class: kind-group-title


.. js:method:: wvc.HoopsServiceRegistryElement.constructor

      .. rst-class:: sig-pretty-signature
      
         | HoopsServiceRegistryElement(): :js:class:`HoopsServiceRegistryElement <wvc.HoopsServiceRegistryElement>`
      
      **Returns**\ : :js:class:`HoopsServiceRegistryElement <wvc.HoopsServiceRegistryElement>`
      



.. rst-class:: kind-group kind-properties

.. rubric:: Properties
   :class: kind-group-title


.. js:data:: wvc.HoopsServiceRegistryElement.cameraService

      .. rst-class:: sig-pretty-signature
      
         | cameraService: :js:class:`ICameraService <wvc.ICameraService>`
      
      Service for controlling camera movement and positioning. Manages camera animations, transitions, and view manipulations.
      
      .. rubric:: Default
      
      
      `````ts
      new CameraService()
      `````
      



.. js:data:: wvc.HoopsServiceRegistryElement.cuttingService

      .. rst-class:: sig-pretty-signature
      
         | cuttingService: :js:class:`ICuttingService <wvc.ICuttingService>`
      
      Service for providing cutting plane functionality. Enables sectioning of 3D models with interactive cutting planes.
      
      .. rubric:: Default
      
      
      `````ts
      new CuttingService()
      `````
      



.. js:data:: wvc.HoopsServiceRegistryElement.explodeService

      .. rst-class:: sig-pretty-signature
      
         | explodeService: :js:class:`IExplodeService <wvc.IExplodeService>`
      
      Service for providing assembly explosion functionality. Enables visual separation of assembly components for better understanding.
      
      .. rubric:: Default
      
      
      `````ts
      new ExplodeService()
      `````
      



.. js:data:: wvc.HoopsServiceRegistryElement.floorplanService

      .. rst-class:: sig-pretty-signature
      
         | floorplanService: *IFloorplanService*
      
      Service for managing floorplan functionality and 2D representations. Provides tools for working with architectural floor plans and layouts.
      
      .. rubric:: Default
      
      
      `````ts
      new FloorplanService()
      `````
      



.. js:data:: wvc.HoopsServiceRegistryElement.ifcRelationshipsService

      .. rst-class:: sig-pretty-signature
      
         | ifcRelationshipsService: :js:class:`IIFCRelationshipsService <wvc.IIFCRelationshipsService>`
      
      Service for managing IFC (Industry Foundation Classes) model relationships. Handles building information modeling data and relationships between elements.
      
      .. rubric:: Default
      
      
      `````ts
      new IFCRelationshipsService()
      `````
      



.. js:data:: wvc.HoopsServiceRegistryElement.logService

      .. rst-class:: sig-pretty-signature
      
         | logService: :js:class:`ILogService <wvc.ILogService>`
      
      Service for logging messages, warnings, and errors. Provides a centralized logging mechanism for debugging and monitoring.
      
      .. rubric:: Default
      
      
      `````ts
      new LogService()
      `````
      



.. js:data:: wvc.HoopsServiceRegistryElement.materialService

      .. rst-class:: sig-pretty-signature
      
         | materialService: :js:class:`IMaterialService <wvc.IMaterialService>`
      
      Service for managing custom shaders. Provides support for custom shaders.
      
      .. rubric:: Default
      
      
      `````ts
      new MaterialService()
      `````
      



.. js:data:: wvc.HoopsServiceRegistryElement.measurementService

      .. rst-class:: sig-pretty-signature
      
         | measurementService: *IMeasurementService*
      
      Service for handling measurement tools and calculations. Supports distance, angle, area, and volume measurements.
      
      .. rubric:: Default
      
      
      `````ts
      new MeasurementService()
      `````
      



.. js:data:: wvc.HoopsServiceRegistryElement.noteTextService

      .. rst-class:: sig-pretty-signature
      
         | noteTextService: *INoteTextService*
      
      Service for managing text notes and comments. Provides functionality for adding, editing, and organizing textual annotations.
      
      .. rubric:: Default
      
      
      `````ts
      new NoteTextService()
      `````
      



.. js:data:: wvc.HoopsServiceRegistryElement.pmiService

      .. rst-class:: sig-pretty-signature
      
         | pmiService: :js:class:`IPmiService <wvc.IPmiService>`
      
      Service for handling Product Manufacturing Information (PMI). Manages annotations, dimensions, tolerances, and other manufacturing data.
      
      .. rubric:: Default
      
      
      `````ts
      new PmiService()
      `````
      



.. js:data:: wvc.HoopsServiceRegistryElement.redlineService

      .. rst-class:: sig-pretty-signature
      
         | redlineService: :js:class:`IRedlineService <wvc.IRedlineService>`
      
      Service for managing redline markup and annotations. Handles creation, editing, and persistence of redline elements.
      
      .. rubric:: Default
      
      
      `````ts
      new RedlineService()
      `````
      



.. js:data:: wvc.HoopsServiceRegistryElement.renderOptionsService

      .. rst-class:: sig-pretty-signature
      
         | renderOptionsService: :js:class:`IRenderOptionsService <wvc.IRenderOptionsService>`
      
      Service for controlling rendering settings and visual options. Manages display modes, lighting, materials, and other rendering parameters.
      
      .. rubric:: Default
      
      
      `````ts
      new RenderOptionsService()
      `````
      



.. js:data:: wvc.HoopsServiceRegistryElement.selectionService

      .. rst-class:: sig-pretty-signature
      
         | selectionService: :js:class:`ISelectionService <wvc.ISelectionService>`
      
      Service for managing object selection and highlighting. Handles single and multi-selection, selection events, and highlight visualization.
      
      .. rubric:: Default
      
      
      `````ts
      new SelectionService()
      `````
      



.. js:data:: wvc.HoopsServiceRegistryElement.sheetService

      .. rst-class:: sig-pretty-signature
      
         | sheetService: :js:class:`ISheetService <wvc.ISheetService>`
      
      Service for managing drawing sheets and layouts. Handles 2D technical drawings, sheet navigation, and layout management.
      
      .. rubric:: Default
      
      
      `````ts
      new SheetService()
      `````
      



.. js:data:: wvc.HoopsServiceRegistryElement.spaceMouseService

      .. rst-class:: sig-pretty-signature
      
         | spaceMouseService: :js:class:`ISpaceMouseService <wvc.ISpaceMouseService>`
      
      Service for integrating 3D SpaceMouse navigation devices. Provides support for professional 3D input devices for enhanced navigation.
      
      .. rubric:: Default
      
      
      `````ts
      new SpaceMouseService()
      `````
      



.. js:data:: wvc.HoopsServiceRegistryElement.viewService

      .. rst-class:: sig-pretty-signature
      
         | viewService: :js:class:`IViewService <wvc.IViewService>`
      
      Service for handling view management and navigation. Controls camera positions, view states, and navigation modes.
      
      .. rubric:: Default
      
      
      `````ts
      new ViewService()
      `````
      



.. js:data:: wvc.HoopsServiceRegistryElement.walkOperatorService

      .. rst-class:: sig-pretty-signature
      
         | walkOperatorService: :js:class:`IWalkOperatorService <wvc.IWalkOperatorService>`
      
      Service for handling walk-through navigation mode. Provides first-person navigation experience for architectural models.
      
      .. rubric:: Default
      
      
      `````ts
      new WalkOperatorService()
      `````
      



.. rst-class:: kind-group kind-methods

.. rubric:: Methods
   :class: kind-group-title


.. js:method:: wvc.HoopsServiceRegistryElement.connectedCallback

      .. rst-class:: sig-pretty-signature
      
         | connectedCallback(): *void*
      
      Lifecycle callback invoked when the element is connected to the DOM. Automatically registers all configured services in the global service registry, making them available throughout the application.
      
      Services are registered in a specific order to handle any potential dependencies. If a service with the same name already exists, it will be overwritten with a warning.
      
      **Returns**\ : *void*
      
      
      



.. js:method:: wvc.HoopsServiceRegistryElement.getService

      .. rst-class:: sig-pretty-signature
      
         | getService(**serviceName**\ : :js:data:`ServiceName <wvc.ServiceName>`\ ): T
      
      Retrieves a service from the global service registry by its name. This is a type-safe wrapper around the global getService function.
      
      **Parameters**
      
      
         **serviceName**\ : :js:data:`ServiceName <wvc.ServiceName>`
      
      
            The unique name of the service to retrieve
      
      
      
      **Returns**\ : T
      
      
         The requested service instance
      
      
      .. rubric:: Examples
      
      
      .. code-block:: typescript
      
         const measurementService = registry.getService<IMeasurementService>('MeasurementService');
         measurementService.startMeasurement();
      
      .. rubric:: Throws
      
      
      If the service with the given name is not registered
      



.. js:method:: wvc.HoopsServiceRegistryElement.tryGetService

      .. rst-class:: sig-pretty-signature
      
         | tryGetService(**serviceName**\ : :js:data:`ServiceName <wvc.ServiceName>`\ ): (*undefined* | T)
      
      Attempts to retrieve a service from the global service registry by its name. Returns undefined if the service is not found, making it safe for optional services.
      
      **Parameters**
      
      
         **serviceName**\ : :js:data:`ServiceName <wvc.ServiceName>`
      
      
            The unique name of the service to retrieve
      
      
      
      **Returns**\ : (*undefined* \| T)
      
      
         The service instance if found, undefined otherwise
      
      
      .. rubric:: Examples
      
      
      .. code-block:: typescript
      
         const customService = registry.tryGetService<ICustomService>('CustomService');
         if (customService) {
           customService.performCustomAction();
         }
      




