public class DefaultUser extends DefaultStaleable implements User
User
.Constructor and Description |
---|
DefaultUser(Client.WithManagement client,
@NonNull String name,
@Nullable String account,
@Nullable String awayMessage,
@NonNull String nick,
@NonNull String user,
@NonNull String host,
boolean isAway,
@Nullable String operString,
@Nullable String realName,
@Nullable String server,
@NonNull Set<String> channels)
Constructs the object.
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object o) |
@NonNull Optional<String> |
getAccount()
Gets the Services account this user is signed into.
|
@NonNull Optional<String> |
getAwayMessage()
Gets, if one is set and known, the away message for the user.
|
@NonNull Set<String> |
getChannels()
Gets the user's channels.
|
@NonNull String |
getHost()
Gets the user's host.
|
@NonNull String |
getMessagingName()
Gets the name used when sending messages.
|
@NonNull String |
getNick()
Gets the user's nick.
|
@NonNull Optional<String> |
getOperatorInformation()
Gets a user's operator information, if they have any privileges, noting
that this information may not imply actual IRC Operator status but some
other IRC network status as well.
|
@NonNull Optional<String> |
getRealName()
Gets the user's real name
|
@NonNull Optional<String> |
getServer()
Gets the name of the server the user is on.
|
@NonNull String |
getUserString()
Gets the user's user string.
|
int |
hashCode() |
boolean |
isAway()
Gets if the user is away.
|
@NonNull String |
toString() |
isStale
getClient, getCreationTime, getName
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
getLowerCaseMessagingName, sendCtcpMessage, sendMessage, sendMultiLineMessage, sendMultiLineMessage, sendMultiLineNotice, sendMultiLineNotice, sendNotice
getLowerCaseName, getName
getCreationTime
getClient
public DefaultUser(Client.WithManagement client, @NonNull String name, @Nullable String account, @Nullable String awayMessage, @NonNull String nick, @NonNull String user, @NonNull String host, boolean isAway, @Nullable String operString, @Nullable String realName, @Nullable String server, @NonNull Set<String> channels)
client
- client from which this camename
- full mask nameaccount
- account, if knownawayMessage
- away message, if knownnick
- nickuser
- user string (ident)host
- hostisAway
- true if awayoperString
- oper info, if knownrealName
- real name, if knownserver
- server info, if knownchannels
- channels they are inpublic @NonNull Optional<String> getAccount()
User
getAccount
in interface User
CapabilityManager.getCapabilities()
,
ServerInfo.hasWhoXSupport()
public @NonNull Optional<String> getAwayMessage()
User
getAwayMessage
in interface User
public @NonNull Set<String> getChannels()
User
getChannels
in interface User
public @NonNull String getHost()
User
public @NonNull String getMessagingName()
MessageReceiver
getMessagingName
in interface MessageReceiver
public @NonNull String getNick()
User
public @NonNull Optional<String> getOperatorInformation()
User
Example: "is an Operator".
getOperatorInformation
in interface User
public @NonNull Optional<String> getRealName()
User
getRealName
in interface User
public @NonNull Optional<String> getServer()
User
public @NonNull String getUserString()
User
getUserString
in interface User
public boolean isAway()
User
public @NonNull String toString()
toString
in class DefaultActor
Copyright © 2013–2021 Kitteh. All rights reserved.