Package com.opentok
Class CaptionProperties.Builder
- java.lang.Object
-
- com.opentok.CaptionProperties.Builder
-
- Enclosing class:
- CaptionProperties
public static class CaptionProperties.Builder extends java.lang.Object
Used to create a CaptionProperties object.- See Also:
CaptionProperties
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description CaptionProperties
build()
Builds the CaptionProperties object.CaptionProperties.Builder
languageCode(java.lang.String languageCode)
The BCP-47 code for a spoken language used on this call.CaptionProperties.Builder
maxDuration(int maxDuration)
The maximum duration for the audio captioning, in seconds.CaptionProperties.Builder
partialCaptions(boolean partialCaptions)
Whether to enable this to faster captioning at the cost of some degree of inaccuracies.CaptionProperties.Builder
statusCallbackUrl(java.lang.String statusCallbackUrl)
A publicly reachable URL controlled by the customer and capable of generating the content to be rendered without user intervention.
-
-
-
Method Detail
-
languageCode
public CaptionProperties.Builder languageCode(java.lang.String languageCode)
The BCP-47 code for a spoken language used on this call. The default value is "en-US". The following language codes are supported: "en-AU" (English, Australia), "en-GB" (Englsh, UK), "es-US" (English, US), "zh-CN" (Chinese, Simplified), "fr-FR" (French), "fr-CA" (French, Canadian), "de-DE" (German), "hi-IN" (Hindi, Indian), "it-IT" (Italian), "ja-JP" (Japanese), "ko-KR" (Korean), "pt-BR" (Portuguese, Brazilian), "th-TH" (Thai).- Parameters:
languageCode
- The BCP-47 language code as a string.- Returns:
- This Builder with the languageCode property setting.
-
statusCallbackUrl
public CaptionProperties.Builder statusCallbackUrl(java.lang.String statusCallbackUrl)
A publicly reachable URL controlled by the customer and capable of generating the content to be rendered without user intervention. The minimum length of the URL is 15 characters and the maximum length is 2048 characters. For more information, see Live Caption status updates.- Parameters:
statusCallbackUrl
- The status callback URL as a string.- Returns:
- This Builder with the statusCallbackUrl property setting.
-
maxDuration
public CaptionProperties.Builder maxDuration(int maxDuration)
The maximum duration for the audio captioning, in seconds. The default value is 14,400 seconds (4 hours), the maximum duration allowed.- Parameters:
maxDuration
- The maximum captions duration in seconds.- Returns:
- This Builder with the maxDuration property setting.
-
partialCaptions
public CaptionProperties.Builder partialCaptions(boolean partialCaptions)
Whether to enable this to faster captioning at the cost of some degree of inaccuracies. The default value istrue
.- Parameters:
partialCaptions
- Whether to enable faster captions.- Returns:
- This Builder with the partialCaptions property setting.
-
build
public CaptionProperties build()
Builds the CaptionProperties object.- Returns:
- The CaptionProperties object with this builder's settings.
-
-