signals with adaptors and interfaces

Vitaly V. Ch vitaly.v.ch at gmail.com
Mon Nov 12 06:21:07 PST 2007


> > for example at now I catch signals in following way:
> >
> > MainClass::MainClass(const QDBusConnection & _connection_)
> >
> > :   connection(_connection_)
> >
> > {
> >     // add our D-Bus interface and connect to D-Bus
> >     new Sim300Adaptor(this);
> >     connection.registerObject("/", this);
> >
> >     connection.connect(QString(), QString(), "com.i_zum.sim300",
> > "send_data",      this, SLOT(countersSlot(QByteArray)));
> >     connection.connect(QString(), QString(), "com.i_zum.sim300",
> > "get_money_atd",  this, SLOT(get_money_atd()));
> >     connection.connect(QString(), QString(), "com.i_zum.sim300",
> > "get_money_cusd", this, SLOT(get_money_cusd()));
> >     connection.connect(QString(), QString(), "com.i_zum.sim300",
> > "get_csq",        this, SLOT(get_csq()));
> >     connection.connect(QString(), QString(), "com.i_zum.sim300",
> > "get_opers_list", this, SLOT(get_opers_list()));
> >     connection.connect(QString(), QString(), "com.i_zum.sim300",
> > "set_oper",       this, SLOT(set_oper(QString)));
> > }
>
> You're using wildcard connections, so the code above is syntactically correct.
> It just seems odd that you're connecting signals called get-something. Your
> signal design seems weird, to say the least.
>
Why? Can You explain detailed?

\\wbr Vitaly


More information about the dbus mailing list