33 const U32 send_timeout_seconds,
34 const U32 send_timeout_microseconds) {
35 return m_socket.
configure(hostname, port, send_timeout_seconds, send_timeout_microseconds);
41 return this->m_socket.
startup();
62 this->
recv_out(0, buffer, recvStatus);
PlatformIntType NATIVE_INT_TYPE
C++-compatible configuration header for fprime configuration.
Auto-generated base for ByteStreamDriverModel component.
void ready_out(NATIVE_INT_TYPE portNum)
Invoke output port ready.
bool isConnected_ready_OutputPort(NATIVE_INT_TYPE portNum)
void deallocate_out(NATIVE_INT_TYPE portNum, Fw::Buffer &fwBuffer)
Invoke output port deallocate.
void recv_out(NATIVE_INT_TYPE portNum, Fw::Buffer &recvBuffer, const Drv::RecvStatus &recvStatus)
Invoke output port recv.
Fw::Buffer allocate_out(NATIVE_INT_TYPE portNum, U32 size)
Invoke output port allocate.
Helper base-class for setting up Berkley sockets.
SocketIpStatus send(const U8 *const data, const U32 size)
send data out the IP socket from the given buffer
SocketIpStatus configure(const char *hostname, const U16 port, const U32 send_timeout_seconds, const U32 send_timeout_microseconds)
configure the ip socket with host and transmission timeouts
@ POLL_ERROR
Error received when polling.
@ RECV_OK
Receive worked as expected.
@ RECV_ERROR
Receive error occurred retrying may succeed.
@ SEND_RETRY
Data send should be retried.
@ SEND_ERROR
Send error occurred retrying may succeed.
@ SEND_OK
Send worked as expected.
supports a task to read a given socket adaptation
~TcpServerComponentImpl()
Destroy the component.
SocketIpStatus startup()
startup the TcpServer
Fw::Buffer getBuffer()
returns a buffer to fill with data
void shutdown()
shutdown the TcpServer
void sendBuffer(Fw::Buffer buffer, SocketIpStatus status)
sends a buffer to be filled with data
TcpServerComponentImpl(const char *const compName)
construct the TcpClient component.
IpSocket & getSocketHandler()
returns a reference to the socket handler
SocketIpStatus configure(const char *hostname, const U16 port, const U32 send_timeout_seconds=SOCKET_SEND_TIMEOUT_SECONDS, const U32 send_timeout_microseconds=SOCKET_SEND_TIMEOUT_MICROSECONDS)
Configures the TcpClient settings but does not open the connection.
void connected()
called when the IPv4 system has been connected
void shutdown()
Shutdown client socket, and listening server socket.
SocketIpStatus startup()
Opens the server socket and listens, does not block.
void init()
Object initializer.
SocketIpStatus
Status enumeration for socket return values.
@ SOCK_SUCCESS
Socket operation successful.
@ SOCK_INTERRUPTED_TRY_AGAIN
Interrupted status for retries.