The QDBusServer class provides peer-to-peer communication between processes on the same computer. 更多...
| 头: | #include <QDBusServer> | 
| qmake: | QT += dbus | 
| 继承: | QObject | 
| QDBusServer (const QString & address , QObject * parent = Q_NULLPTR) | |
| QDBusServer (QObject * parent = Q_NULLPTR) | |
| virtual | ~QDBusServer () | 
| QString | address () const | 
| bool | isAnonymousAuthenticationAllowed () const | 
| bool | isConnected () const | 
| QDBusError | lastError () const | 
| void | setAnonymousAuthenticationAllowed (bool value ) | 
| void | newConnection (const QDBusConnection & connection ) | 
The QDBusServer class provides peer-to-peer communication between processes on the same computer.
构造 QDBusServer 采用给定 address ,和给定 parent .
						构造
						
							QDBusServer
						
						采用给定
						
							parent
						
						。服务器将监听连接在
						
/tmp
						
						(在 Unix 系统) 或在绑定到本地主机 (其它地方) 的 TCP 端口。
					
[虚拟]
						
						QDBusServer::
						
							~QDBusServer
						
						()
						
					销毁 QDBusServer
返回此服务器关联的地址。
返回 true 若允许匿名身份验证。
该函数在 Qt 5.3 引入。
另请参阅 setAnonymousAuthenticationAllowed ().
						返回
						
true
						
						若此
						
							QDBusServer
						
						对象被连接。
					
若未连接,需要再次调用构造函数。
返回此服务器最后发生的错误。
此函数是为低级代码提供的。
[signal]
						
						
							void
						
						QDBusServer::
						
							newConnection
						
						(const
						
							
								QDBusConnection
							
						
						&
						
							connection
						
						)
						
					此信号被发射,当新客户端连接 connection 到服务器已建立。
若 value 被设为 true,传入连接可以继续进行,即使作为用户连接客户端未通过身份验证。
默认情况下,此值为 false。
该函数在 Qt 5.3 引入。
另请参阅 isAnonymousAuthenticationAllowed ().