#include <User.h>
Public Member Functions | |
virtual const char *const | getNick () const throw (Exception &) |
Returns the nick of the user. | |
virtual const char *const | getPrefix () const throw (Exception &) |
Returns the prefix of the user. | |
virtual bool | hasVoice () const throw (Exception &) |
Returns whether or not the user represented by this object has voice. | |
virtual bool | isOp () const throw (Exception &) |
Returns whether or not the user represented by this object is an operator. | |
void | operator delete (void *p) |
All delete's will be handled through this dll. | |
void * | operator new (unsigned int size) |
All new's will be handled through this dll. | |
bool | operator< (const User &rhs) const |
Returns the result of calling the compareTo method on lowercased nicks. | |
User & | operator= (const User &rhs) |
Performs a deep copy of this object. | |
bool | operator== (const User &rhs) const |
Returns true if the nick represented by this User object is the same as the nick of the User object given as an argument. | |
bool | operator> (const User &rhs) const |
Returns the result of calling the compareTo method on lowercased nicks. | |
virtual const char *const | toString () const throw (Exception &) |
Returns the nick of the user complete with their prefix if they have one, e.g. | |
User (const User &user) | |
The copy constructor. | |
User (const char *const prefix, const char *const nick) throw (Exception &) | |
Constructs a User object with a known prefix and nick. | |
User () throw (Exception &) | |
Constructs a User object with empty string for the prefix and the nick. | |
virtual | ~User () |
Default virtual destructor. | |
Private Attributes | |
UserImpl * | m_pimpl |
The private implementation in which you cannot get access to. | |
Friends | |
class | UserImpl |
Instances of this class are returned by the getUsers method in the PircBot class.
|
Constructs a User object with empty string for the prefix and the nick.
|
|
Constructs a User object with a known prefix and nick.
|
|
The copy constructor. Performs a deep copy of the object.
|
|
Default virtual destructor. It will delete the private implementation (pimpl) |
|
Returns the nick of the user.
|
|
Returns the prefix of the user. If the User object has been obtained from a list of users in a channel, then this will reflect the user's status in that channel.
|
|
Returns whether or not the user represented by this object has voice. If the User object has been obtained from a list of users in a channel, then this will reflect the user's voice status in that channel.
|
|
Returns whether or not the user represented by this object is an operator. If the User object has been obtained from a list of users in a channel, then this will reflect the user's operator status in that channel.
|
|
All delete's will be handled through this dll. This is required for dll boundary safety. Instead of allowing the compiler to choose if it wants to inline this we have made it so that it cannot. If we let the compiler choose to inline or not inline this and the "new operator" we can run into dll boundary issues. The issue would be that the compiler would inline one and not the other. Thus, your executable with its own heap would allocate/delete and this dll would do the other. That's a dll boundary safety violation.
|
|
All new's will be handled through this dll. This is required for dll boundary safety. Instead of allowing the compiler to choose if it wants to inline this we have made it so that it cannot. If we let the compiler choose to inline or not inline this and the "delete operator" we can run into dll boundary issues. The issue would be that the compiler would inline one and not the other. Thus, your executable with its own heap would allocate/delete and this dll would do the other. That's a dll boundary safety violation.
|
|
Returns the result of calling the compareTo method on lowercased nicks. This is useful for sorting lists of User objects.
|
|
Performs a deep copy of this object.
|
|
Returns true if the nick represented by this User object is the same as the nick of the User object given as an argument. A case insensitive comparison is made.
|
|
Returns the result of calling the compareTo method on lowercased nicks. This is useful for sorting lists of User objects.
|
|
Returns the nick of the user complete with their prefix if they have one, e.g. "@Dave". C++ note. I cannot overload the "<<" without having to pull in C++ libraries. And once I pull in an std, then there's no guarantee of dll boundary safety.
|
|
The private implementation in which you cannot get access to. This shared_ptr holds the private methods and private member variables of this class. This makes ABI (Application Binary Interface) more resilient to change. See the private implementation idiom on the internet for more information about this. |