Package org.javacord.api.entity.channel
Class ServerThreadChannelUpdater
- java.lang.Object
-
- org.javacord.api.entity.channel.ServerChannelUpdater<ServerThreadChannelUpdater>
-
- org.javacord.api.entity.channel.ServerThreadChannelUpdater
-
public class ServerThreadChannelUpdater extends ServerChannelUpdater<ServerThreadChannelUpdater>
This class can be used to update server thread channels.
-
-
Constructor Summary
Constructors Constructor Description ServerThreadChannelUpdater(ServerThreadChannel thread)Creates a new server thread channel updater.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ServerThreadChannelUpdatersetArchivedFlag(boolean archived)Queues the archived flag to be updated.ServerThreadChannelUpdatersetAutoArchiveDuration(AutoArchiveDuration autoArchiveDuration)Queues the auto archive duration to be updated.ServerThreadChannelUpdatersetInvitableFlag(boolean invitable)Queues the invitable flag to be updated.ServerThreadChannelUpdatersetLockedFlag(boolean locked)Queues the locked flag to be updated.ServerThreadChannelUpdatersetSlowmodeDelayInSeconds(int delay)Queues slowmode delay to be updated.java.util.concurrent.CompletableFuture<java.lang.Void>update()Performs the queued updates.-
Methods inherited from class org.javacord.api.entity.channel.ServerChannelUpdater
setAuditLogReason, setName
-
-
-
-
Constructor Detail
-
ServerThreadChannelUpdater
public ServerThreadChannelUpdater(ServerThreadChannel thread)
Creates a new server thread channel updater.- Parameters:
thread- The thread to update.
-
-
Method Detail
-
setArchivedFlag
public ServerThreadChannelUpdater setArchivedFlag(boolean archived)
Queues the archived flag to be updated.- Parameters:
archived- The new archived flag of the thread.- Returns:
- The current instance in order to chain call methods.
-
setAutoArchiveDuration
public ServerThreadChannelUpdater setAutoArchiveDuration(AutoArchiveDuration autoArchiveDuration)
Queues the auto archive duration to be updated.- Parameters:
autoArchiveDuration- The new auto archive duration of the thread.- Returns:
- The current instance in order to chain call methods.
-
setLockedFlag
public ServerThreadChannelUpdater setLockedFlag(boolean locked)
Queues the locked flag to be updated.- Parameters:
locked- The new locked flag of the thread.- Returns:
- The current instance in order to chain call methods.
-
setInvitableFlag
public ServerThreadChannelUpdater setInvitableFlag(boolean invitable)
Queues the invitable flag to be updated. Only available for private threads.- Parameters:
invitable- The new invitable flag of the thread.- Returns:
- The current instance in order to chain call methods.
-
setSlowmodeDelayInSeconds
public ServerThreadChannelUpdater setSlowmodeDelayInSeconds(int delay)
Queues slowmode delay to be updated.- Parameters:
delay- The delay in seconds.- Returns:
- The current instance in order to chain call methods.
-
update
public java.util.concurrent.CompletableFuture<java.lang.Void> update()
Performs the queued updates.- Overrides:
updatein classServerChannelUpdater<ServerThreadChannelUpdater>- Returns:
- A future to check if the update was successful.
-
-