createCooldown

open fun createCooldown(@Nullable tablePrefix: @Nullable String, @NotNull cooldownType: @NotNull String, @NotNull cooldownOwner: @NotNull String, @NotNull cooldownExpiry: @NotNull Timestamp)(source)

Creates a new cooldown with a random UUID in the database.

Parameters

tablePrefix

the prefix to be used for the table name, if any

cooldownType

the type of the cooldown

cooldownOwner

the owner of the cooldown as a UUID

cooldownExpiry

the time when the cooldown will expire in milliseconds since the epoch

Throws

if there is an error creating the cooldown


abstract fun createCooldown(@Nullable tablePrefix: @Nullable String, @NotNull id: @NotNull String, @NotNull cooldownType: @NotNull String, @NotNull cooldownOwner: @NotNull String, @NotNull cooldownExpiry: @NotNull Timestamp)(source)

Creates a new cooldown with the given UUID in the database.

Parameters

tablePrefix

the prefix to be used for the table name, if any

id

the UUID for the cooldown

cooldownType

the type of the cooldown

cooldownOwner

the owner of the cooldown as a UUID

cooldownExpiry

the time when the cooldown will expire in milliseconds since the epoch

Throws

if there is an error creating the cooldown