summaryrefslogtreecommitdiff
path: root/cpp/demo/Ice/session/SessionI.cpp
diff options
context:
space:
mode:
authorMarc Laukien <marc@zeroc.com>2005-04-20 11:17:45 +0000
committerMarc Laukien <marc@zeroc.com>2005-04-20 11:17:45 +0000
commit1549f7bdb9709e6b0c31560abfb98af4fe5fae1a (patch)
treed4395897b9bb59c8ea824c3591a989112abd0698 /cpp/demo/Ice/session/SessionI.cpp
parentFixed a number of race conditions and made some destructor assertions safe. (diff)
downloadice-1549f7bdb9709e6b0c31560abfb98af4fe5fae1a.tar.bz2
ice-1549f7bdb9709e6b0c31560abfb98af4fe5fae1a.tar.xz
ice-1549f7bdb9709e6b0c31560abfb98af4fe5fae1a.zip
more comments
Diffstat (limited to 'cpp/demo/Ice/session/SessionI.cpp')
-rwxr-xr-xcpp/demo/Ice/session/SessionI.cpp8
1 files changed, 6 insertions, 2 deletions
diff --git a/cpp/demo/Ice/session/SessionI.cpp b/cpp/demo/Ice/session/SessionI.cpp
index 36643f949dd..c21cfd7b5cc 100755
--- a/cpp/demo/Ice/session/SessionI.cpp
+++ b/cpp/demo/Ice/session/SessionI.cpp
@@ -24,13 +24,14 @@ public:
virtual ~HelloI()
{
- cout << "Hello object " << _id << " for session " << _name << " destroyed" << endl;
+ cout << "Hello object #" << _id << " for session `" << _name << "' destroyed" << endl;
}
void
sayHello(const Ice::Current&) const
{
- cout << "Hello object " << _id << " says 'Hello " << _name << "!'" << endl;
+ cout << "Hello object #" << _id << " for session `" << _name << "' says:\n"
+ << "Hello " << _name << "!" << endl;
}
private:
@@ -43,6 +44,7 @@ HelloPrx
SessionI::createHello(const Ice::Current& c)
{
Lock sync(*this);
+
if(_destroy)
{
throw Ice::ObjectNotExistException(__FILE__, __LINE__);
@@ -57,6 +59,7 @@ void
SessionI::refresh(const Ice::Current& c)
{
Lock sync(*this);
+
if(_destroy)
{
throw Ice::ObjectNotExistException(__FILE__, __LINE__);
@@ -69,6 +72,7 @@ string
SessionI::getName(const Ice::Current&) const
{
Lock sync(*this);
+
if(_destroy)
{
throw Ice::ObjectNotExistException(__FILE__, __LINE__);