CopperSpice DBUS  1.7.4
QDBusServer Class Reference

The QDBusServer class provides peer-to-peer communication between processes on the same computer. More...

Inherits QObject.

Public Signals

void newConnection (const QDBusConnection &connection)
 

Public Methods

 QDBusServer (const QString &address, QObject *parent=nullptr)
 
 QDBusServer (QObject *parent=nullptr)
 
virtual ~QDBusServer ()
 
QString address () const
 
bool isAnonymousAuthenticationAllowed () const
 
bool isConnected () const
 
QDBusError lastError () const
 
void setAnonymousAuthenticationAllowed (bool value)
 

Detailed Description

The QDBusServer class provides peer-to-peer communication between processes on the same computer.

See also
setAnonymousAuthenticationAllowed()

Constructor & Destructor Documentation

QDBusServer::QDBusServer ( const QString &  address,
QObject *  parent = nullptr 
)
explicit

Constructs a QDBusServer with the given address, and the given parent.

QDBusServer::QDBusServer ( QObject *  parent = nullptr)
explicit

Constructs a QDBusServer with the given parent. The server will listen for connections in /tmp (on Unix systems) or on a TCP port bound to localhost (elsewhere).

QDBusServer::~QDBusServer ( )
virtual

Destructs the current QDBusServer.

Method Documentation

QString QDBusServer::address ( ) const

Returns the address this server is associated with.

bool QDBusServer::isAnonymousAuthenticationAllowed ( ) const

Returns true if anonymous authentication is allowed.

See also
setAnonymousAuthenticationAllowed()
bool QDBusServer::isConnected ( ) const

Returns true if this QDBusServer object is connected. If it is not connected, then call the constructor again.

QDBusError QDBusServer::lastError ( ) const

Returns the last error that happened in this server. This method is provided for low-level code.

void QDBusServer::newConnection ( const QDBusConnection connection)
signal

This signal is emitted when a new client connection is established to the server.

void QDBusServer::setAnonymousAuthenticationAllowed ( bool  value)

If value is set to true an incoming connection can proceed even if the connecting client is not authenticated as a user. By default, this value is false.

See also
isAnonymousAuthenticationAllowed()