diff --git a/iceoryx2-ffi/cxx/include/iox2/file_descriptor.hpp b/iceoryx2-ffi/cxx/include/iox2/file_descriptor.hpp index 2c0ee692c..1c7bfe963 100644 --- a/iceoryx2-ffi/cxx/include/iox2/file_descriptor.hpp +++ b/iceoryx2-ffi/cxx/include/iox2/file_descriptor.hpp @@ -35,15 +35,7 @@ class FileDescriptorBased { /// A view to a [`FileDescriptor`]. class FileDescriptorView : public FileDescriptorBased { - private: - template <ServiceType> - friend class WaitSet; - friend class FileDescriptor; - template <ServiceType> - friend class Listener; - - explicit FileDescriptorView(iox2_file_descriptor_ptr handle); - + public: /// Returns a [`FileDescriptorView`] to the underlying [`FileDescriptor`]. auto file_descriptor() const -> FileDescriptorView override; @@ -57,6 +49,15 @@ class FileDescriptorView : public FileDescriptorBased { /// auto unsafe_native_handle() const -> int32_t; + private: + template <ServiceType> + friend class WaitSet; + friend class FileDescriptor; + template <ServiceType> + friend class Listener; + + explicit FileDescriptorView(iox2_file_descriptor_ptr handle); + iox2_file_descriptor_ptr m_handle = nullptr; };