Main Class Reference

Inheritance diagram for Main:
Object

List of all members.

Public Member Functions

 Main (bool savecon, bool dodiscon, bool doglobalsig)
void hello ()
 ~Main ()

Private Attributes

Aa
Cc
Connection connection
bool save_connect
bool disconnect

Detailed Description

Definition at line 39 of file test-conn.cc.


Constructor & Destructor Documentation

Main::Main ( bool  savecon,
bool  dodiscon,
bool  doglobalsig 
) [inline]

Definition at line 48 of file test-conn.cc.

References a, B::beep(), c, connection, global_sig, hello(), save_connect, A::Set(), and C::sig.

00049         : save_connect(savecon), disconnect(dodiscon) {
00050  
00051         c = new C;
00052         a = new A; 
00053         B* b = manage(new B);
00054         a->Set(b);
00055         if (save_connect)
00056             connection = c->sig.connect(bind(slot(*b,&B::beep),c));
00057         else
00058             c->sig.connect(bind(slot(*b,&B::beep),c));
00059 
00060         if (doglobalsig)
00061             global_sig.connect(slot(*this,&Main::hello));
00062 
00063     }

Main::~Main (  )  [inline]

Definition at line 65 of file test-conn.cc.

References a, c, connection, disconnect, and save_connect.

00065             {
00066         cerr << "In ~Main\n";
00067         if (save_connect && disconnect) connection.disconnect();
00068         delete a;
00069         delete c;
00070     }        


Member Function Documentation

void Main::hello (  )  [inline]

Definition at line 64 of file test-conn.cc.

Referenced by Main().

00064 { cerr << "Hello!\n"; }


Member Data Documentation

A* Main::a [private]

Definition at line 41 of file test-conn.cc.

Referenced by Main(), and ~Main().

C* Main::c [private]

Definition at line 42 of file test-conn.cc.

Referenced by Main(), and ~Main().

Connection Main::connection [private]

Definition at line 43 of file test-conn.cc.

Referenced by Main(), and ~Main().

bool Main::disconnect [private]

Definition at line 45 of file test-conn.cc.

Referenced by ~Main().

bool Main::save_connect [private]

Definition at line 44 of file test-conn.cc.

Referenced by Main(), and ~Main().


The documentation for this class was generated from the following file:

Generated on 17 Jun 2018 for loon by  doxygen 1.6.1