LLDB  mainline
Public Types | Public Member Functions | Static Public Attributes | Protected Attributes | List of all members
lldb_private::IOObject Class Referenceabstract

#include <IOObject.h>

Inheritance diagram for lldb_private::IOObject:
Inheritance graph
[legend]
Collaboration diagram for lldb_private::IOObject:
Collaboration graph
[legend]

Public Types

enum  FDType { eFDTypeFile, eFDTypeSocket }
 
typedef int WaitableHandle
 

Public Member Functions

 IOObject (FDType type, bool should_close)
 
virtual ~IOObject ()
 
virtual Status Read (void *buf, size_t &num_bytes)=0
 
virtual Status Write (const void *buf, size_t &num_bytes)=0
 
virtual bool IsValid () const =0
 
virtual Status Close ()=0
 
FDType GetFdType () const
 
virtual WaitableHandle GetWaitableHandle ()=0
 

Static Public Attributes

static const WaitableHandle kInvalidHandleValue = -1
 

Protected Attributes

FDType m_fd_type
 
bool m_should_close_fd
 

Detailed Description

Definition at line 20 of file IOObject.h.

Member Typedef Documentation

◆ WaitableHandle

Definition at line 29 of file IOObject.h.

Member Enumeration Documentation

◆ FDType

Enumerator
eFDTypeFile 
eFDTypeSocket 

Definition at line 22 of file IOObject.h.

Constructor & Destructor Documentation

◆ IOObject()

lldb_private::IOObject::IOObject ( FDType  type,
bool  should_close 
)
inline

Definition at line 32 of file IOObject.h.

References Close(), IsValid(), Read(), Write(), and ~IOObject().

◆ ~IOObject()

IOObject::~IOObject ( )
virtualdefault

Referenced by IOObject().

Member Function Documentation

◆ Close()

virtual Status lldb_private::IOObject::Close ( )
pure virtual

Implemented in lldb_private::File, and lldb_private::Socket.

Referenced by IOObject().

◆ GetFdType()

FDType lldb_private::IOObject::GetFdType ( ) const
inline

Definition at line 41 of file IOObject.h.

References GetWaitableHandle(), and m_fd_type.

◆ GetWaitableHandle()

virtual WaitableHandle lldb_private::IOObject::GetWaitableHandle ( )
pure virtual

Implemented in lldb_private::File, and lldb_private::Socket.

Referenced by GetFdType().

◆ IsValid()

virtual bool lldb_private::IOObject::IsValid ( ) const
pure virtual

◆ Read()

virtual Status lldb_private::IOObject::Read ( void *  buf,
size_t &  num_bytes 
)
pure virtual

Implemented in lldb_private::File, and lldb_private::Socket.

Referenced by IOObject().

◆ Write()

virtual Status lldb_private::IOObject::Write ( const void *  buf,
size_t &  num_bytes 
)
pure virtual

Implemented in lldb_private::File, and lldb_private::Socket.

Referenced by IOObject().

Member Data Documentation

◆ kInvalidHandleValue

const IOObject::WaitableHandle IOObject::kInvalidHandleValue = -1
static

Definition at line 30 of file IOObject.h.

Referenced by lldb_private::ConnectionFileDescriptor::BytesAvailable().

◆ m_fd_type

FDType lldb_private::IOObject::m_fd_type
protected

Definition at line 46 of file IOObject.h.

Referenced by GetFdType().

◆ m_should_close_fd

bool lldb_private::IOObject::m_should_close_fd
protected

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