17#import "OFKernelEventObserver.h"
21OF_ASSUME_NONNULL_BEGIN
49 id _Nullable exception);
72 didReceiveIntoBuffer: (
void *)buffer
73 length: (
size_t)length
75 exception: (nullable
id)exception;
87 didSendData: (
OFData *)data
89 exception: (nullable
id)exception;
107 OFSocketHandle _socket;
114 bool _canSendToBroadcastAddresses;
116 id <OFDatagramSocketDelegate> _Nullable _delegate;
128@property (nonatomic)
bool canBlock;
136@property (nonatomic)
bool canSendToBroadcastAddresses;
144@property OF_NULLABLE_PROPERTY (assign, nonatomic)
145 id <OFDatagramSocketDelegate> delegate;
152+ (instancetype)socket;
167- (size_t)receiveIntoBuffer: (
void *)buffer
168 length: (
size_t)length
180- (void)asyncReceiveIntoBuffer: (
void *)buffer length: (
size_t)length;
193- (void)asyncReceiveIntoBuffer: (
void *)buffer
194 length: (
size_t)length
213- (void)asyncReceiveIntoBuffer: (
void *)buffer
214 length: (
size_t)length
234- (void)asyncReceiveIntoBuffer: (
void *)buffer
235 length: (
size_t)length
250- (void)sendBuffer: (const
void *)buffer
251 length: (
size_t)length
261- (void)asyncSendData: (
OFData *)data
273- (void)asyncSendData: (
OFData *)data
288- (void)asyncSendData: (
OFData *)data
304- (void)asyncSendData: (
OFData *)data
320- (void)releaseSocketFromCurrentThread;
332- (void)obtainSocketForCurrentThread;
337- (void)cancelAsyncRequests;
OFData *(^ OFDatagramSocketAsyncSendDataBlock)(id exception)
A block which is called when a packet has been sent.
Definition OFDatagramSocket.h:48
bool(^ OFDatagramSocketAsyncReceiveBlock)(size_t length, const OFSocketAddress *sender, id exception)
A block which is called when a packet has been received.
Definition OFDatagramSocket.h:38
A class for storing constant strings using the @"" literal.
Definition OFConstantString.h:38
A class for storing arbitrary data in an array.
Definition OFData.h:42
A base class for datagram sockets.
Definition OFDatagramSocket.h:107
The root class for all other classes inside ObjFW.
Definition OFObject.h:688
A protocol for the creation of copies.
Definition OFObject.h:1346
This protocol is implemented by classes which can be observed for readiness for reading by OFKernelEv...
Definition OFKernelEventObserver.h:84
This protocol is implemented by classes which can be observed for readiness for writing by OFKernelEv...
Definition OFKernelEventObserver.h:99
A struct which represents a host / port pair for a socket.
Definition OFSocket.h:182