@ CheckReturnValue public ChannelAction setBitrate ( Integer bitrate ) { if ( type != ChannelType . VOICE ) throw new UnsupportedOperationException ( "Can only set the bitrate for a VoiceChannel!" ) ; if ( bitrate != null ) { int maxBitrate = guild . getFeatures ( ) . contains ( "VIP_REGIONS" ) ? 128000 : 96000 ; if ( bitrate < 8000 ) throw new IllegalArgumentException ( "Bitrate must be greater than 8000." ) ; else if ( bitrate > maxBitrate ) throw new IllegalArgumentException ( "Bitrate must be less than " + maxBitrate ) ; } this . bitrate = bitrate ; return this ; }
Sets the bitrate for the new VoiceChannel