Class LoginRequest
- java.lang.Object
-
- io.github.ma1uta.matrix.client.model.auth.LoginRequest
-
public class LoginRequest extends Object
Authenticates the user, and issues an access token they can use to authorize themself in subsequent requests.
-
-
Field Summary
Fields Modifier and Type Field Description private StringaddressDeprecated.in favour ofidentifier.private StringdeviceIdID of the client device.private IdentifieridentifierIdentification information for the user.private StringinitialDeviceDisplayNameA display name to assign to the newly-created device.private StringmediumDeprecated.in favour ofidentifier.private char[]passwordRequired when type is m.login.password.private StringtokenRequired when type is m.login.token.private StringtypeRequired.private StringuserDeprecated.in favour ofidentifier.
-
Constructor Summary
Constructors Constructor Description LoginRequest()
-
Method Summary
Modifier and Type Method Description StringgetAddress()StringgetDeviceId()IdentifiergetIdentifier()StringgetInitialDeviceDisplayName()StringgetMedium()char[]getPassword()StringgetToken()StringgetType()StringgetUser()voidsetAddress(String address)voidsetDeviceId(String deviceId)voidsetIdentifier(Identifier identifier)voidsetInitialDeviceDisplayName(String initialDeviceDisplayName)voidsetMedium(String medium)voidsetPassword(char[] password)voidsetToken(String token)voidsetType(String type)voidsetUser(String user)
-
-
-
Field Detail
-
type
private String type
Required. The login type being used. One of: ["m.login.password", "m.login.token"].
-
identifier
private Identifier identifier
Identification information for the user.
-
user
@Deprecated private String user
Deprecated.in favour ofidentifier.The fully qualified user ID or just local part of the user ID, to log in.
-
medium
@Deprecated private String medium
Deprecated.in favour ofidentifier.When logging in using a third party identifier, the medium of the identifier. Must be 'email'.
-
address
@Deprecated private String address
Deprecated.in favour ofidentifier.Third party identifier for the user.
-
password
private char[] password
Required when type is m.login.password. The user's password.
-
token
private String token
Required when type is m.login.token. The login token.
-
deviceId
private String deviceId
ID of the client device. If this does not correspond to a known client device, a new device will be created. The server will auto-generate a device_id if this is not specified.
-
initialDeviceDisplayName
private String initialDeviceDisplayName
A display name to assign to the newly-created device. Ignored if device_id corresponds to a known device.
-
-
Method Detail
-
getType
public String getType()
-
setType
public void setType(String type)
-
getIdentifier
public Identifier getIdentifier()
-
setIdentifier
public void setIdentifier(Identifier identifier)
-
getUser
public String getUser()
-
setUser
public void setUser(String user)
-
getMedium
public String getMedium()
-
setMedium
public void setMedium(String medium)
-
getAddress
public String getAddress()
-
setAddress
public void setAddress(String address)
-
getPassword
public char[] getPassword()
-
setPassword
public void setPassword(char[] password)
-
getToken
public String getToken()
-
setToken
public void setToken(String token)
-
getDeviceId
public String getDeviceId()
-
setDeviceId
public void setDeviceId(String deviceId)
-
getInitialDeviceDisplayName
public String getInitialDeviceDisplayName()
-
setInitialDeviceDisplayName
public void setInitialDeviceDisplayName(String initialDeviceDisplayName)
-
-