mirror of
https://github.com/vcmi/vcmi.git
synced 2025-11-06 09:09:40 +02:00
Logging cleanup (server).
This commit is contained in:
@@ -278,7 +278,9 @@ void CConnection::enableSmartVectorMemberSerializatoin()
|
||||
CSerializer::smartVectorMembersSerialization = true;
|
||||
}
|
||||
|
||||
std::ostream & operator<<(std::ostream &str, const CConnection &cpc)
|
||||
{
|
||||
return str << "Connection with " << cpc.name << " (ID: " << cpc.connectionID << /*", " << (cpc.host ? "host" : "guest") <<*/ ")";
|
||||
}
|
||||
std::string CConnection::toString() const
|
||||
{
|
||||
boost::format fmt("Connection with %s (ID: %d)");
|
||||
fmt % name % connectionID;
|
||||
return fmt.str();
|
||||
}
|
||||
|
||||
@@ -90,6 +90,8 @@ public:
|
||||
void prepareForSendingHeroes(); //disables sending vectorized, enables smart pointer serialization, clears saved/loaded ptr cache
|
||||
void enterPregameConnectionMode();
|
||||
|
||||
std::string toString() const;
|
||||
|
||||
template<class T>
|
||||
CConnection & operator>>(T &t)
|
||||
{
|
||||
@@ -104,5 +106,3 @@ public:
|
||||
return * this;
|
||||
}
|
||||
};
|
||||
|
||||
DLL_LINKAGE std::ostream &operator<<(std::ostream &str, const CConnection &cpc);
|
||||
|
||||
Reference in New Issue
Block a user