Password

@Serializable
data class Password(val id: String, val creationDate: Long, val tail: String, _password: String, _scopes: String, val type: PasswordType, _events: List<PasswordEvent>)

The Password data class represents the password data

Author

N7ghtm4r3 - Tecknobit

Constructors

Link copied to clipboard
constructor(id: String, creationDate: Long, tail: String, _password: String, _scopes: String, type: PasswordType, _events: List<PasswordEvent>)

Properties

Link copied to clipboard
@SerialName(value = "creation_date" )
val creationDate: Long

When the password has been created

Link copied to clipboard

events the events of the password

Link copied to clipboard
val id: String

The identifier of the password

Link copied to clipboard
@Transient
val password: MutableState<String>

password state container of the password value

Link copied to clipboard
@Transient
val scopes: Set<String>

scopes the scopes of the password

Link copied to clipboard
val tail: String

The tail of the password

Link copied to clipboard
val type: PasswordType

The type of the password

Functions

Link copied to clipboard

Method used to locally append the PasswordEventType.COPIED event

Link copied to clipboard

Method used to locally append the PasswordEventType.REFRESHED event

Link copied to clipboard

Method used to check whether the password has any scopes attached

Link copied to clipboard
fun refreshPassword(refreshedPassword: String)

Method used to locally refresh the password value