4#ifndef QBLUETOOTHSOCKET_OSX_P_H
5#define QBLUETOOTHSOCKET_OSX_P_H
18#ifdef QT_OSX_BLUETOOTH
26#ifndef QPRIVATELINEARBUFFER_BUFFERSIZE
27#define QPRIVATELINEARBUFFER_BUFFERSIZE Q_INT64_C(16384)
30#include <QtCore/qbytearray.h>
33#include <QtCore/qglobal.h>
34#include <QtCore/QIODevice>
35#include <QtCore/QList>
36#include <QtCore/QObject>
37#include <QtCore/QScopedPointer>
38#include <QtCore/QString>
50 QBluetoothSocketPrivateDarwin();
51 ~QBluetoothSocketPrivateDarwin();
64 void abort()
override;
65 void close()
override;
76 QBluetoothSocket::OpenMode openMode)
override;
79 QIODevice::OpenMode openMode)
override;
81 QIODevice::OpenMode openMode)
override;
83 QIODevice::OpenMode openMode)
override;
86 QIODevice::OpenMode openMode)
override;
88 void _q_writeNotify();
92 bool setRFCOMChannel(
void *
channel);
93 bool setL2CAPChannel(
void *
channel);
96 void setChannelError(IOReturn errorCode)
override;
97 void channelOpenComplete()
override;
98 void channelClosed()
override;
99 void readChannelData(
void *
data, std::size_t
size)
override;
100 void writeComplete()
override;
105 L2CAPChannel l2capChannel;
107 using RFCOMMChannel = L2CAPChannel;
108 RFCOMMChannel rfcommChannel;
110 bool isConnecting =
false;
IOBluetoothL2CAPChannel * channel
Protocol
This enum describes the socket protocol used by the service.
virtual QString peerName() const =0
virtual QBluetoothAddress peerAddress() const =0
virtual void connectToService(const QBluetoothServiceInfo &service, QIODevice::OpenMode openMode)=0
virtual bool setSocketDescriptor(int socketDescriptor, QBluetoothServiceInfo::Protocol socketType, QBluetoothSocket::SocketState socketState=QBluetoothSocket::SocketState::ConnectedState, QBluetoothSocket::OpenMode openMode=QBluetoothSocket::ReadWrite)=0
virtual qint64 bytesAvailable() const =0
virtual qint64 bytesToWrite() const =0
virtual QString localName() const =0
virtual QBluetoothAddress localAddress() const =0
virtual bool canReadLine() const =0
virtual qint64 writeData(const char *data, qint64 maxSize)=0
virtual quint16 localPort() const =0
virtual void connectToServiceHelper(const QBluetoothAddress &address, quint16 port, QIODevice::OpenMode openMode)=0
virtual quint16 peerPort() const =0
virtual bool ensureNativeSocket(QBluetoothServiceInfo::Protocol type)=0
SocketState
This enum describes the state of the Bluetooth socket.
\macro QT_RESTRICTED_CAST_FROM_ASCII
Combined button and popup list for selecting options.
static QT_BEGIN_NAMESPACE const char * socketType(QSocketNotifier::Type type)
GLenum GLuint GLintptr GLsizeiptr size
[1]
GLint GLsizei GLsizei GLenum GLenum GLsizei void * data
GLuint GLuint64EXT address