39 lines
416 B
C++
39 lines
416 B
C++
|
#include "Socket.h"
|
||
|
|
||
|
Socket::Socket()
|
||
|
: mPort(8888),
|
||
|
mMessage()
|
||
|
{
|
||
|
|
||
|
}
|
||
|
|
||
|
Socket::~Socket()
|
||
|
{
|
||
|
|
||
|
}
|
||
|
|
||
|
std::shared_ptr<Socket> Socket::Create()
|
||
|
{
|
||
|
return std::make_shared<Socket>();
|
||
|
}
|
||
|
|
||
|
std::string Socket::GetMessage()
|
||
|
{
|
||
|
return mMessage;
|
||
|
}
|
||
|
|
||
|
void Socket::SetMessage(const std::string& message)
|
||
|
{
|
||
|
mMessage = message;
|
||
|
}
|
||
|
|
||
|
void Socket::SetPort(unsigned port)
|
||
|
{
|
||
|
mPort = port;
|
||
|
}
|
||
|
|
||
|
unsigned Socket::GetPort()
|
||
|
{
|
||
|
return mPort;
|
||
|
}
|