NVIDIA Holoscan SDK v3.5.0

Class FragmentService

Derived Types

class FragmentService

Base interface for services that enable sharing of resources and functionality between operators within a fragment or across distributed fragments.

FragmentService provides a common interface for services that manage shared resources accessible to multiple operators. Services implementing this interface can be registered with a Fragment and accessed by operators through the Fragment’s service registry.

This interface is typically implemented by resource managers, shared data structures, or other facilities that need to be shared across operators while maintaining a single instance per fragment.

Subclassed by holoscan::DefaultFragmentService, holoscan::DistributedAppService

Public Functions

FragmentService() = default
virtual ~FragmentService() = default
virtual std::shared_ptr<Resource> resource() const = 0

Get the underlying resource managed by this service.

Returns

Shared pointer to the managed resource.

virtual void resource(const std::shared_ptr<Resource> &resource) = 0

Set the underlying resource managed by this service.

Parameters

resource – Shared pointer to the resource to be managed.

Previous Class FragmentScheduler
Next Class FragmentServiceProvider
© Copyright 2022-2025, NVIDIA. Last updated on Sep 4, 2025.