Class LegacyUserEditSpec

java.lang.Object
discord4j.core.spec.legacy.LegacyUserEditSpec
All Implemented Interfaces:
LegacySpec<discord4j.discordjson.json.UserModifyRequest>

public class LegacyUserEditSpec extends Object implements LegacySpec<discord4j.discordjson.json.UserModifyRequest>
LegacySpec used to modify the current user.
See Also:
  • Constructor Details

    • LegacyUserEditSpec

      public LegacyUserEditSpec()
  • Method Details

    • setUsername

      public LegacyUserEditSpec setUsername(String username)
      Sets the user's username. May cause the discriminator to be randomized.
      Parameters:
      username - The user's username.
      Returns:
      This spec.
    • setAvatar

      public LegacyUserEditSpec setAvatar(@Nullable Image avatar)
      Sets the user's avatar.
      Parameters:
      avatar - The user's avatar.
      Returns:
      This spec.
    • asRequest

      public discord4j.discordjson.json.UserModifyRequest asRequest()
      Specified by:
      asRequest in interface LegacySpec<discord4j.discordjson.json.UserModifyRequest>