Network: Fix some move stuff
Former-commit-id: 33b24a038319b444b9a3b84cfeea38c8305e6568
This commit is contained in:
@@ -35,6 +35,9 @@ namespace Nz
|
||||
|
||||
unsigned int QueryAvailableBytes() const;
|
||||
|
||||
AbstractSocket& operator=(const AbstractSocket&) = delete;
|
||||
AbstractSocket& operator=(AbstractSocket&& abstractSocket);
|
||||
|
||||
// Signals:
|
||||
NazaraSignal(OnStateChange, const AbstractSocket* /*socket*/, SocketState /*newState*/);
|
||||
|
||||
|
||||
@@ -21,7 +21,7 @@ namespace Nz
|
||||
|
||||
public:
|
||||
inline TcpClient();
|
||||
inline TcpClient(TcpClient&& tcpClient);
|
||||
TcpClient(TcpClient&& tcpClient) = default;
|
||||
~TcpClient() = default;
|
||||
|
||||
SocketState Connect(const IpAddress& remoteAddress);
|
||||
@@ -50,6 +50,8 @@ namespace Nz
|
||||
|
||||
bool WaitForConnected(UInt64 msTimeout = 3000);
|
||||
|
||||
inline TcpClient& operator=(TcpClient&& tcpClient) = default;
|
||||
|
||||
private:
|
||||
void FlushStream() override;
|
||||
|
||||
|
||||
@@ -17,17 +17,6 @@ namespace Nz
|
||||
{
|
||||
}
|
||||
|
||||
inline TcpClient::TcpClient(TcpClient&& tcpClient) :
|
||||
AbstractSocket(std::move(tcpClient)),
|
||||
Stream(std::move(tcpClient)),
|
||||
m_peerAddress(std::move(tcpClient.m_peerAddress)),
|
||||
m_keepAliveInterval(tcpClient.m_keepAliveInterval),
|
||||
m_keepAliveTime(tcpClient.m_keepAliveTime),
|
||||
m_isLowDelayEnabled(tcpClient.m_isLowDelayEnabled),
|
||||
m_isKeepAliveEnabled(tcpClient.m_isKeepAliveEnabled)
|
||||
{
|
||||
}
|
||||
|
||||
inline void TcpClient::Disconnect()
|
||||
{
|
||||
Close();
|
||||
|
||||
Reference in New Issue
Block a user