REC RPC library
Public Member Functions | Public Attributes | List of all members
rec::rpc::ClientInfo Class Reference

RPC client info. More...

#include <rec_rpc_ClientInfo.h>

Inheritance diagram for rec::rpc::ClientInfo:
Inheritance graph
[legend]
Collaboration diagram for rec::rpc::ClientInfo:
Collaboration graph
[legend]

Public Member Functions

 ClientInfo ()
 Default constructor. More...
 
 ClientInfo (const QHostAddress &address_, const int port_, const QString &name_=QString::null)
 Constructor with initializations. More...
 
 ClientInfo (const ClientInfo &other)
 Copy constructor. More...
 
ClientInfooperator= (const ClientInfo &other)
 Assignment operator. More...
 
bool isNull () const
 Null check. More...
 
bool isLocal () const
 Check if client it connected via local socket. More...
 
void clear ()
 Clear all data. More...
 
bool operator== (const ClientInfo &other) const
 Equality test. More...
 
bool operator!= (const ClientInfo &other) const
 Unequality test. More...
 
QString toString () const
 

Public Attributes

QHostAddress address
 Client's network address. More...
 
int port
 Client's TCP port. More...
 
QString name
 Name (can be empty) More...
 

Detailed Description

RPC client info.

Class that stores information about RPC clients.

Definition at line 46 of file rec_rpc_ClientInfo.h.

Constructor & Destructor Documentation

rec::rpc::ClientInfo::ClientInfo ( )
inline

Default constructor.

Definition at line 50 of file rec_rpc_ClientInfo.h.

rec::rpc::ClientInfo::ClientInfo ( const QHostAddress &  address_,
const int  port_,
const QString &  name_ = QString::null 
)
inline

Constructor with initializations.

Parameters
address_Client's network address
port_Client's TCP port
name_Name (can be empty)

Definition at line 62 of file rec_rpc_ClientInfo.h.

rec::rpc::ClientInfo::ClientInfo ( const ClientInfo other)
inline

Copy constructor.

Parameters
otherClientInfo to copy

Definition at line 74 of file rec_rpc_ClientInfo.h.

Member Function Documentation

void rec::rpc::ClientInfo::clear ( )
inline

Clear all data.

Definition at line 115 of file rec_rpc_ClientInfo.h.

References address, name, and port.

bool rec::rpc::ClientInfo::isLocal ( ) const
inline

Check if client it connected via local socket.

Returns
True if the client is local

Definition at line 109 of file rec_rpc_ClientInfo.h.

References address, and port.

bool rec::rpc::ClientInfo::isNull ( ) const
inline

Null check.

Returns
True if the port number is -1

Definition at line 99 of file rec_rpc_ClientInfo.h.

References port.

bool rec::rpc::ClientInfo::operator!= ( const ClientInfo other) const
inline

Unequality test.

Parameters
otherOther ClientInfo to compare with
Returns
true if *this != other

Definition at line 144 of file rec_rpc_ClientInfo.h.

References address, and port.

ClientInfo& rec::rpc::ClientInfo::operator= ( const ClientInfo other)
inline

Assignment operator.

Parameters
otherClientInfo to copy

Definition at line 86 of file rec_rpc_ClientInfo.h.

References address, name, and port.

bool rec::rpc::ClientInfo::operator== ( const ClientInfo other) const
inline

Equality test.

Parameters
otherOther ClientInfo to compare with
Returns
true if *this == other

Definition at line 128 of file rec_rpc_ClientInfo.h.

References address, and port.

QString rec::rpc::ClientInfo::toString ( ) const
inline

Definition at line 154 of file rec_rpc_ClientInfo.h.

References address, name, and port.

Member Data Documentation

QHostAddress rec::rpc::ClientInfo::address

Client's network address.

Definition at line 162 of file rec_rpc_ClientInfo.h.

Referenced by clear(), isLocal(), operator!=(), operator=(), operator==(), and toString().

QString rec::rpc::ClientInfo::name

Name (can be empty)

Definition at line 166 of file rec_rpc_ClientInfo.h.

Referenced by clear(), operator=(), and toString().

int rec::rpc::ClientInfo::port

Client's TCP port.

Definition at line 164 of file rec_rpc_ClientInfo.h.

Referenced by clear(), isLocal(), isNull(), operator!=(), operator=(), operator==(), and toString().


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