Add comments
This commit is contained in:
@@ -1,5 +1,8 @@
|
||||
#include <sstp/clientsocketsender.hpp>
|
||||
|
||||
/// @brief Establish a connection to the socket specified by ipAddress and port
|
||||
/// @param ipAddress The ipAddress
|
||||
/// @param port The port
|
||||
ClientSocketSender::ClientSocketSender(String ipAddress, int port)
|
||||
: mIPAddress(ipAddress), mPort(port)
|
||||
{
|
||||
@@ -26,11 +29,15 @@ ClientSocketSender::ClientSocketSender(String ipAddress, int port)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/// @brief Close the connection on destruction
|
||||
ClientSocketSender::~ClientSocketSender()
|
||||
{
|
||||
close();
|
||||
}
|
||||
|
||||
/// @brief Closes the connection
|
||||
/// @param
|
||||
void ClientSocketSender::close(void)
|
||||
{
|
||||
if(-1!=mSocket)
|
||||
@@ -40,6 +47,9 @@ void ClientSocketSender::close(void)
|
||||
}
|
||||
}
|
||||
|
||||
/// @brief Send the specified file through the connection
|
||||
/// @param pathFileName The file to send
|
||||
/// @return Returns true if successful
|
||||
bool ClientSocketSender::sendFile(String &pathFileName)
|
||||
{
|
||||
Profiler profiler;
|
||||
|
||||
Reference in New Issue
Block a user