QAbstractIpcInterface Class Reference
|
Constant | Value | Description |
---|---|---|
QAbstractIpcInterface::Client | 0 | Object is operating in client mode. |
QAbstractIpcInterface::Server | 1 | Object is operating in server mode. |
QAbstractIpcInterface::Invalid | 2 | Object is invalid. This indicates that the connection to the server could not be established, or it has been lost. |
Defines whether interface values should be published by QAbstractIpcInterface::setValue() immediately or not.
Constant | Value | Description |
---|---|---|
QAbstractIpcInterface::Immediate | 0 | Synchronize values with the client immediately. |
QAbstractIpcInterface::Delayed | 1 | Delay synchronization until the server re-enters the Qt event loop. |
Construct a new interface object for the interface called interfaceName on groupName and attach it to parent. If mode is Server, then the object is constructed in server mode and groupName must not be empty. If mode is Client, then the object is constructed in client mode and groupName may be empty to indicate the default group that implements this type of interface.
The valueSpaceLocation parameter specifies the location the value space to place all information about this interface. Subclasses such as QCommInterface will set this to a particular value meeting their requirements.
Destroy this interface object. If the object is operating in client mode, then the connection to the server will be severed. If the object is operating in server mode, then it will be deregistered and all communicating clients will receive the disconnected() signal.
Returns true if the server is available for use; otherwise returns false. This is normally used by a client just after the constructor is called to determine if the constructor could locate a suitable server.
See also mode().
Signal that is emitted on the client if the server disconnects before the client object is destroyed, or if the client could not connect at all because the server does not exist. Not used on the server.
The mode() of the interface object will be Invalid when this signal is emitted.
See also mode().
Initializes server-side functionality within this interface after all interfaces in the group have been created. This is called by QAbstractIpcInterfaceGroup::initialize() after all interface handling objects on group have been created. It will not be called if the interface is not associated with a QAbstractIpcInterfaceGroup instance.
Subclasses typically override this method so that they can connect to signals on other interfaces which may not have existed when the interface constructor was called.
See also QAbstractIpcInterfaceGroup::initialize().
Returns the name of the group associated with this interface object.
See also interfaceName().
Returns the interface name associated with this interface object. If this object is known by more than one interface name, the interface name passed in the last call to proxyAll() will be returned.
See also groupName().
Performs a call to the zero-argument slot name from the client to the server. Ignored on the server.
This is an overloaded member function, provided for convenience.
Performs a call to the one-argument slot name from the client to the server, with the argument arg1. Ignored on the server.
This is an overloaded member function, provided for convenience.
Performs a call to the two-argument slot name from the client to the server, with the arguments arg1 and arg2. Ignored on the server.
This is an overloaded member function, provided for convenience.
Performs a call to the three-argument slot name from the client to the server, with the arguments arg1, arg2, and arg3. Ignored on the server.
This is an overloaded member function, provided for convenience.
Performs a call to the multi-argument slot name from the client to the server, with the arguments in the list args. Ignored on the server.
Returns the mode that this interface object is operating in. Returns QAbstractIpcInterface::Client for client mode, QAbstractIpcInterface::Server for server mode, and QAbstractIpcInterface::Invalid if the client's connection to the server could not be established or has been lost.
See also available().
Proxies member so that it will be delivered between the client and server. This is typically called from the constructor of the immediate subclass of QAbstractIpcInterface for all signals and slots that will cross the client/server boundary.
This method is useful when the subclass has only a few signals and slots that need to be proxied. Or it contains signals and slots that must not be proxied because they are private to the client or server sides. The related proxyAll() method is simpler to use if the subclass has many signals and slots and they must all be proxied.
See also proxyAll().
Sets up remote invocation proxies for all signals and public slots on this object, starting at the class specified by meta.
Normally meta will be the staticMetaObject value for the immediate subclass of QAbstractIpcInterface. It allows the proxying to be limited to a subset of the class hierarchy if more derived classes have signals and slots that should not be proxied.
This method is useful when the subclass has many signals and slots, and it would be error-prone to proxy them individually with proxy().
See also proxy().
This is an overloaded member function, provided for convenience.
Sets up remote invocation proxies for all signals and public slots on this object, starting at the class specified by meta. Also register subInterfaceName as a sub-interface name for this object's primary interface name. After this call, interfaceName() will return subInterfaceName.
Removes the value associated with name from the auxiliary value space.
If sync is Delayed, then delay publication of the value to clients until the server re-enters the Qt event loop. This may be more efficient if the server needs to set or remove several values at once. The default value for sync is Immediate.
See also value() and setValue().
Sets the priority of this server to value. Ignored on the client.
Sets name to value in the auxiliary value space for this interface object. This is called by the server to notify clients of a change in name. Ignored on the client.
If sync is Delayed, then delay publication of the value to clients until the server re-enters the Qt event loop. This may be more efficient if the server needs to set or remove several values at once. The default value for sync is Immediate.
See also value() and removeValue().
Returns the value associated with name in the auxiliary value space for this interface object. Returns def if the name does not exist. This can be called on either the client or the server (but usually the client).
See also setValue() and removeValue().
Returns a list of all value names in the auxiliary value space for this interface object contained within path.
See also value().
Cette page est une traduction d'une page de la documentation de Qt, écrite par Nokia Corporation and/or its subsidiary(-ies). Les éventuels problèmes résultant d'une mauvaise traduction ne sont pas imputables à Nokia. | Qt qtextended4.4 | |
Copyright © 2012 Developpez LLC. Tous droits réservés Developpez LLC. Aucune reproduction, même partielle, ne peut être faite de ce site et de l'ensemble de son contenu : textes, documents et images sans l'autorisation expresse de Developpez LLC. Sinon, vous encourez selon la loi jusqu'à 3 ans de prison et jusqu'à 300 000 E de dommages et intérêts. Cette page est déposée à la SACD. | ||
Vous avez déniché une erreur ? Un bug ? Une redirection cassée ? Ou tout autre problème, quel qu'il soit ? Ou bien vous désirez participer à ce projet de traduction ? N'hésitez pas à nous contacter ou par MP ! |
Copyright © 2000-2012 - www.developpez.com