Agora Server Gateway SDK Java API Reference
Loading...
Searching...
No Matches
io.agora.rtc.AgoraServiceConfig Class Reference

Public Member Functions

 AgoraServiceConfig ()
 
 AgoraServiceConfig (int enableAudioProcessor, int enableAudioDevice, int enableVideo, Object context, java.lang.String appId, int areaCode, int channelProfile, int audioScenario, int useStringUid, String logFilePath, int logFileSize, int logFilters, int domainLimit)
 
int getEnableAudioProcessor ()
 
void setEnableAudioProcessor (int enableAudioProcessor)
 
int getEnableAudioDevice ()
 
void setEnableAudioDevice (int enableAudioDevice)
 
int getEnableVideo ()
 
void setEnableVideo (int enableVideo)
 
Object getContext ()
 
void setContext (Object context)
 
String getAppId ()
 
void setAppId (String appId)
 
int getAreaCode ()
 
void setAreaCode (int areaCode)
 
int getChannelProfile ()
 
void setChannelProfile (int channelProfile)
 
int getAudioScenario ()
 
void setAudioScenario (int audioScenario)
 
int getUseStringUid ()
 
void setUseStringUid (int useStringUid)
 
String getLogFilePath ()
 
void setLogFilePath (String logFilePath)
 
int getLogFileSize ()
 
void setLogFileSize (int logFileSize)
 
int getLogFilters ()
 
void setLogFilters (int logFilters)
 
int getDomainLimit ()
 
void setDomainLimit (int domainLimit)
 
String toString ()
 

Private Attributes

int enableAudioProcessor = 1
 
int enableAudioDevice = 0
 
int enableVideo = 0
 
Object context
 
String appId
 
int areaCode = Constants.AREA_CODE_GLOB
 
int channelProfile = Constants.CHANNEL_PROFILE_LIVE_BROADCASTING
 
int audioScenario = Constants.AUDIO_SCENARIO_CHORUS
 
int useStringUid
 
String logFilePath
 
int logFileSize = 2048
 
int logFilters = Constants.LOG_FILTER_INFO
 
int domainLimit
 

Detailed Description

The global configurations for AgoraService.

Set these configurations when calling initialize.

Constructor & Destructor Documentation

◆ AgoraServiceConfig() [1/2]

io.agora.rtc.AgoraServiceConfig.AgoraServiceConfig ( )

◆ AgoraServiceConfig() [2/2]

io.agora.rtc.AgoraServiceConfig.AgoraServiceConfig ( int enableAudioProcessor,
int enableAudioDevice,
int enableVideo,
Object context,
java.lang.String appId,
int areaCode,
int channelProfile,
int audioScenario,
int useStringUid,
String logFilePath,
int logFileSize,
int logFilters,
int domainLimit )

Member Function Documentation

◆ getAppId()

String io.agora.rtc.AgoraServiceConfig.getAppId ( )

◆ getAreaCode()

int io.agora.rtc.AgoraServiceConfig.getAreaCode ( )

◆ getAudioScenario()

int io.agora.rtc.AgoraServiceConfig.getAudioScenario ( )

◆ getChannelProfile()

int io.agora.rtc.AgoraServiceConfig.getChannelProfile ( )

◆ getContext()

Object io.agora.rtc.AgoraServiceConfig.getContext ( )

◆ getDomainLimit()

int io.agora.rtc.AgoraServiceConfig.getDomainLimit ( )

◆ getEnableAudioDevice()

int io.agora.rtc.AgoraServiceConfig.getEnableAudioDevice ( )

◆ getEnableAudioProcessor()

int io.agora.rtc.AgoraServiceConfig.getEnableAudioProcessor ( )

◆ getEnableVideo()

int io.agora.rtc.AgoraServiceConfig.getEnableVideo ( )

◆ getLogFilePath()

String io.agora.rtc.AgoraServiceConfig.getLogFilePath ( )

◆ getLogFileSize()

int io.agora.rtc.AgoraServiceConfig.getLogFileSize ( )

◆ getLogFilters()

int io.agora.rtc.AgoraServiceConfig.getLogFilters ( )

◆ getUseStringUid()

int io.agora.rtc.AgoraServiceConfig.getUseStringUid ( )

◆ setAppId()

void io.agora.rtc.AgoraServiceConfig.setAppId ( String appId)

◆ setAreaCode()

void io.agora.rtc.AgoraServiceConfig.setAreaCode ( int areaCode)

◆ setAudioScenario()

void io.agora.rtc.AgoraServiceConfig.setAudioScenario ( int audioScenario)

◆ setChannelProfile()

void io.agora.rtc.AgoraServiceConfig.setChannelProfile ( int channelProfile)

◆ setContext()

void io.agora.rtc.AgoraServiceConfig.setContext ( Object context)

◆ setDomainLimit()

void io.agora.rtc.AgoraServiceConfig.setDomainLimit ( int domainLimit)

◆ setEnableAudioDevice()

void io.agora.rtc.AgoraServiceConfig.setEnableAudioDevice ( int enableAudioDevice)

◆ setEnableAudioProcessor()

void io.agora.rtc.AgoraServiceConfig.setEnableAudioProcessor ( int enableAudioProcessor)

◆ setEnableVideo()

void io.agora.rtc.AgoraServiceConfig.setEnableVideo ( int enableVideo)

◆ setLogFilePath()

void io.agora.rtc.AgoraServiceConfig.setLogFilePath ( String logFilePath)

◆ setLogFileSize()

void io.agora.rtc.AgoraServiceConfig.setLogFileSize ( int logFileSize)

◆ setLogFilters()

void io.agora.rtc.AgoraServiceConfig.setLogFilters ( int logFilters)

◆ setUseStringUid()

void io.agora.rtc.AgoraServiceConfig.setUseStringUid ( int useStringUid)

◆ toString()

String io.agora.rtc.AgoraServiceConfig.toString ( )

Member Data Documentation

◆ appId

String io.agora.rtc.AgoraServiceConfig.appId
private

The App ID of your project.

◆ areaCode

int io.agora.rtc.AgoraServiceConfig.areaCode = Constants.AREA_CODE_GLOB
private

The region for connection. This is an advanced feature and applies to scenarios that have regional restrictions. After specifying the region, the app integrated with the Agora SDK connects to the Agora servers within that region.

  • 0x00000001: Mainland China.
  • 0x00000002: North America.
  • 0x00000004: Europe.
  • 0x00000008: Asia, excluding Mainland China.
  • 0x00000010: Japan.
  • 0x00000020: India.
  • 0xFFFFFFFF: Global.

◆ audioScenario

int io.agora.rtc.AgoraServiceConfig.audioScenario = Constants.AUDIO_SCENARIO_CHORUS
private

The audio scenario.

  • 0: (Recommended) The default audio scenario.
  • 3: (Recommended) The live gaming scenario, which needs to enable gaming audio effects in the speaker. Choose this scenario to achieve high-fidelity music playback.
  • 5: The chatroom scenario, which needs to keep recording when setClientRole to audience.
  • 6: (Recommended) The scenario requiring high-quality audio.
  • 7: (Default) The chorus scenario.

◆ channelProfile

int io.agora.rtc.AgoraServiceConfig.channelProfile = Constants.CHANNEL_PROFILE_LIVE_BROADCASTING
private

The channel profile.

  • 0: Communication. This profile prioritizes smoothness and applies to the one-to-one scenario.
  • 1: (Default) Live Broadcast. Set to this profile if there are more than 2 people in the channel.

◆ context

Object io.agora.rtc.AgoraServiceConfig.context
private

The user context.

  • For Windows, it is the handle of the window that loads the video. Specify this value to support plugging or unplugging the video devices while the host is powered on.
  • For Android, it is the context of activity.

◆ domainLimit

int io.agora.rtc.AgoraServiceConfig.domainLimit
private

Determines whether to enable domain limit.

  • 1: only connect to servers that are already parsed by DNS.
  • 0: (Default) connect to servers with no limit.

◆ enableAudioDevice

int io.agora.rtc.AgoraServiceConfig.enableAudioDevice = 0
private

Whether to enable the audio device module. The function of the audio device module is to manage audio devices, such as recording and playing audio. If you set enableAudioDevice as false and set enableAudioProcessor as true, you cannot use audio devices, but you can push PCM audio data.

  • true: Enable the audio device module. Audio recording and playback is available.
  • false: (Default) Disable the audio device module. Audio recording and playback is unavailable.

◆ enableAudioProcessor

int io.agora.rtc.AgoraServiceConfig.enableAudioProcessor = 1
private

Whether to enable the audio processing module.

  • true: (Default) Enable the audio processing module.
  • false: Disable the audio processing module. If you disable the audio processing module, you cannot create audio tracks.

◆ enableVideo

int io.agora.rtc.AgoraServiceConfig.enableVideo = 0
private

Whether to enable video.

  • true: Enable video.
  • false: (Default) Disable video.

◆ logFilePath

String io.agora.rtc.AgoraServiceConfig.logFilePath
private

The log file path. The default value is NULL, which stands for the default log path.

◆ logFileSize

int io.agora.rtc.AgoraServiceConfig.logFileSize = 2048
private

The log file size (KB). The default value is 2048.

◆ logFilters

int io.agora.rtc.AgoraServiceConfig.logFilters = Constants.LOG_FILTER_INFO
private

The log level:

  • 0: Do not output any log.
  • 0x80f: Output all the API logs.
  • 0x0f: (Default) Output logs of the CRITICAL, ERROR, WARNING, and INFO level.
  • 0x0e: Output logs of the CRITICAL, ERROR, and WARNING level.
  • 0x0c: Output logs of the CRITICAL and ERROR level.
  • 0x08: Output logs of the CRITICAL level.

◆ useStringUid

int io.agora.rtc.AgoraServiceConfig.useStringUid
private

Whether to enable string uid.

  • true: Enables string uid.
  • false: (Default) Disables string uid.

The documentation for this class was generated from the following file: