diff options
| author | Paul Buetow <paul@buetow.org> | 2013-04-06 13:14:48 +0200 |
|---|---|---|
| committer | Paul Buetow <paul@buetow.org> | 2013-04-06 13:14:48 +0200 |
| commit | bf5fc4cc4a15e8e57db58c2e065e0f5adbd8e800 (patch) | |
| tree | 855a98aec6d09361074c9725e08063553044ecfb /src/chat/sess.cpp | |
| parent | d9c4a95345bd758e45196b29368bd2ff0f2790e3 (diff) | |
tagging ychat-0.7.9.3ychat-0.7.9.3
Diffstat (limited to 'src/chat/sess.cpp')
| -rwxr-xr-x | src/chat/sess.cpp | 39 |
1 files changed, 33 insertions, 6 deletions
diff --git a/src/chat/sess.cpp b/src/chat/sess.cpp index b41c8ce..dc9ba9b 100755 --- a/src/chat/sess.cpp +++ b/src/chat/sess.cpp @@ -3,27 +3,54 @@ #include "sess.h" -sess::sess( string s_id ) +sess::sess( string s_tmpid ) { - this->sess_id=s_id; + this->p_user = NULL; + this->s_tmpid = s_tmpid; } sess::~sess() +{} + +string +sess::get_tmpid() { - + return s_tmpid; } string -sess::get_id() +sess::get_name() +{ + if ( p_user = NULL ) + return ""; + + return p_user->get_name(); +} + +void +sess::set_name(string s_name) +{ + if ( p_user != NULL ) + p_user->set_name(s_name); +} + +user* +sess::get_user() +{ + return p_user; +} + +void +sess::set_user(user* p_user) { - return this->sess_id; + this->p_user = p_user; } void sess::invalidate() { - this->sess_id = "0"; + this->s_tmpid = "0"; } #endif |
