Open Lighting Architecture: ola::io::UnmanagedFileDescriptor Class Reference

| Open Lighting Architecture 0.10.9

Loading...
Searching...
No Matches
Public Member Functions | Protected Attributes | List of all members
ola::io::UnmanagedFileDescriptor Class Reference
I/O & Event Management

## Detailed Description

Allows a FD created by a library to be used with the SelectServer.

Inheritance diagram for ola::io::UnmanagedFileDescriptor:

## Public Member Functions
| UnmanagedFileDescriptor (int fd)
| Create a new UnmanagedFileDescriptor.
DescriptorHandle | ReadDescriptor () const
| Returns the read descriptor for this socket.
DescriptorHandle | WriteDescriptor () const
| Returns the write descriptor for this socket.
Public Member Functions inherited from ola::io::BidirectionalFileDescriptor
void | SetOnData (ola::Callback0< void > *on_read)
| Set the callback to be run when data is available for reading.
void | SetOnWritable (ola::Callback0< void > *on_write)
| Set the callback to be run when the descriptor can be written to.
void | PerformRead ()
| Called when there is data available on the descriptor.
void | PerformWrite ()
| Called when the descriptor can be written to.
Public Member Functions inherited from ola::io::ReadFileDescriptor
bool | ValidReadDescriptor () const
| Check if this file descriptor is valid.
Public Member Functions inherited from ola::io::WriteFileDescriptor
bool | ValidWriteDescriptor () const
| Check if this file descriptor is valid.

## Protected Attributes
DescriptorHandle | m_handle

## Constructor & Destructor Documentation

## ◆ UnmanagedFileDescriptor()

ola::io::UnmanagedFileDescriptor::UnmanagedFileDescriptor | ( | int | fd | ) |
| explicit

Create a new UnmanagedFileDescriptor.

Parameters

  fd | the file descriptor to use

## Member Function Documentation

## ◆ ReadDescriptor()

DescriptorHandle ola::io::UnmanagedFileDescriptor::ReadDescriptor | ( |  | ) | const
| inlinevirtual

Returns the read descriptor for this socket.

Returns
  the DescriptorHandle for this descriptor.

Implements ola::io::ReadFileDescriptor.

## ◆ WriteDescriptor()

DescriptorHandle ola::io::UnmanagedFileDescriptor::WriteDescriptor | ( |  | ) | const
| inlinevirtual

Returns the write descriptor for this socket.

Returns
  the DescriptorHandle for this descriptor.

Implements ola::io::WriteFileDescriptor.

The documentation for this class was generated from the following files:

- include/ola/io/Descriptor.h
- common/io/Descriptor.cpp