public class SelfInfoImpl extends UserImpl implements SelfInfo
api, avatarId, bot, discriminator, fake, id, name, privateChannel
Constructor and Description |
---|
SelfInfoImpl(java.lang.String id,
JDAImpl api) |
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getEmail()
Used to get the email of the currently logged in account.
NOTE: this is a AccountType.CLIENT method only! |
boolean |
isMfaEnabled()
If true, this account is protected by Multi-Factor authorizaiton.
If this is a Client account, then this describes the MFA status of the Client account. If this is a Bot account, then this describes the MFA status of the Client account that owns this Bot. |
boolean |
isVerified()
The status of this account's verification.
(Have you accepted the verification email) |
SelfInfoImpl |
setEmail(java.lang.String email) |
SelfInfoImpl |
setMfaEnabled(boolean enabled) |
SelfInfoImpl |
setVerified(boolean verified) |
equals, getAsMention, getAvatarId, getAvatarUrl, getDefaultAvatarId, getDefaultAvatarUrl, getDiscriminator, getId, getJDA, getName, getPrivateChannel, hashCode, hasPrivateChannel, isBot, isFake, setAvatarId, setBot, setDiscriminator, setFake, setName, setPrivateChannel, toString
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
getAvatarId, getAvatarUrl, getDefaultAvatarId, getDefaultAvatarUrl, getDiscriminator, getJDA, getName, getPrivateChannel, hasPrivateChannel, isBot
getCreationTime, getId
getAsMention
public SelfInfoImpl(java.lang.String id, JDAImpl api)
public boolean isVerified()
SelfInfo
isVerified
in interface SelfInfo
public boolean isMfaEnabled()
SelfInfo
isMfaEnabled
in interface SelfInfo
public java.lang.String getEmail() throws AccountTypeException
SelfInfo
AccountType.CLIENT
method only!getEmail
in interface SelfInfo
AccountTypeException
- If this method is called when JDA#getAccountType()
does not return
AccountType.CLIENT
. E.g: If the logged in account isn't a Client account!public SelfInfoImpl setVerified(boolean verified)
public SelfInfoImpl setMfaEnabled(boolean enabled)
public SelfInfoImpl setEmail(java.lang.String email)