Summary: "Porting" this feature from PHP; I find it useful in the Synapse client.
Reviewed By: mcslee
Test Plan: It compiles, ship it!
Revert: svn
git-svn-id: https://svn.apache.org/repos/asf/incubator/thrift/trunk@665304
13f79535-47bb-0310-9956-
ffa450edef68
}
}
+std::string TSocket::getHost() {
+ return host_;
+}
+
+int TSocket::getPort() {
+ return port_;
+}
+
void TSocket::setHost(string host) {
host_ = host;
}
*/
void write(const uint8_t* buf, uint32_t len);
+ /**
+ * Get the host that the socket is connected to
+ *
+ * @return string host identifier
+ */
+ std::string getHost();
+
+ /**
+ * Get the port that the socket is connected to
+ *
+ * @return int port number
+ */
+ int getPort();
+
/**
* Set the host that socket will connect to
*