# MbmsGroupCallSessionCallback

Added in[API level 29](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)  

# MbmsGroupCallSessionCallback

*** ** * ** ***

[Kotlin](https://developer.android.com/reference/kotlin/android/telephony/mbms/MbmsGroupCallSessionCallback "View this page in Kotlin")\|Java

`
public


interface
MbmsGroupCallSessionCallback
`  
`


`

|-----------------------------------------------------|
| android.telephony.mbms.MbmsGroupCallSessionCallback |

<br />

*** ** * ** ***

A callback class that is used to receive information from the middleware on MBMS group-call services. An instance of this object should be passed into[MbmsGroupCallSession.create(Context, int, Executor, MbmsGroupCallSessionCallback)](https://developer.android.com/reference/android/telephony/MbmsGroupCallSession#create(android.content.Context,%20int,%20java.util.concurrent.Executor,%20android.telephony.mbms.MbmsGroupCallSessionCallback)).

## Summary

|                                                                                                                                                                                                                                                                                                                                                ### Public methods                                                                                                                                                                                                                                                                                                                                                 ||
|-----------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| ` default void` | ` `[onAvailableSaisUpdated](https://developer.android.com/reference/android/telephony/mbms/MbmsGroupCallSessionCallback#onAvailableSaisUpdated(java.util.List<java.lang.Integer>,%20java.util.List<java.util.List<java.lang.Integer>>))`(`[List](https://developer.android.com/reference/java/util/List)`<`[Integer](https://developer.android.com/reference/java/lang/Integer)`> currentSais, `[List](https://developer.android.com/reference/java/util/List)`<`[List](https://developer.android.com/reference/java/util/List)`<`[Integer](https://developer.android.com/reference/java/lang/Integer)`>> availableSais) ` Indicates that the list of currently available SAIs has been updated. |
| ` default void` | ` `[onError](https://developer.android.com/reference/android/telephony/mbms/MbmsGroupCallSessionCallback#onError(int,%20java.lang.String))`(int errorCode, `[String](https://developer.android.com/reference/java/lang/String)` message) ` Called by the middleware when it has detected an error condition.                                                                                                                                                                                                                                                                                                                                                                                     |
| ` default void` | ` `[onMiddlewareReady](https://developer.android.com/reference/android/telephony/mbms/MbmsGroupCallSessionCallback#onMiddlewareReady())`() ` Called to indicate that the middleware has been initialized and is ready.                                                                                                                                                                                                                                                                                                                                                                                                                                                                           |
| ` default void` | ` `[onServiceInterfaceAvailable](https://developer.android.com/reference/android/telephony/mbms/MbmsGroupCallSessionCallback#onServiceInterfaceAvailable(java.lang.String,%20int))`(`[String](https://developer.android.com/reference/java/lang/String)` interfaceName, int index) ` Called soon after the app calls[MbmsGroupCallSession.create](https://developer.android.com/reference/android/telephony/MbmsGroupCallSession#create(android.content.Context,%20int,%20java.util.concurrent.Executor,%20android.telephony.mbms.MbmsGroupCallSessionCallback)).                                                                                                                                |

## Public methods

### onAvailableSaisUpdated

Added in[API level 29](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)  

```
public void onAvailableSaisUpdated (List<Integer> currentSais, 
                List<List<Integer>> availableSais)
```

Indicates that the list of currently available SAIs has been updated. The app may use this information to filter the list of group calls when displaying available group calls to the user by matching the SAIs with a list of group calls separately negotiated with the carrier. The app may also report the aggregate list of SAIs to the group call application server so that a network entity can determine when, and where to activate the broadcast of particular group calls.

<br />

|                                                                                       Parameters                                                                                       ||
|-----------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| `currentSais`   | `List`: The available SAIs on the current cell. This value cannot be`null`. <br />                                                                                    |
| `availableSais` | `List`: A list of lists of available SAIS in neighboring cells, where each list contains the available SAIs in an individual cell. This value cannot be`null`. <br /> |

### onError

Added in[API level 29](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)  

```
public void onError (int errorCode, 
                String message)
```

Called by the middleware when it has detected an error condition. The possible error codes are listed in[MbmsErrors](https://developer.android.com/reference/android/telephony/mbms/MbmsErrors).

<br />

|                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   Parameters                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    ||
|-------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| `errorCode` | `int`: The error code. Value is[MbmsErrors.ERROR_NO_UNIQUE_MIDDLEWARE](https://developer.android.com/reference/android/telephony/mbms/MbmsErrors#ERROR_NO_UNIQUE_MIDDLEWARE),[MbmsErrors.ERROR_MIDDLEWARE_LOST](https://developer.android.com/reference/android/telephony/mbms/MbmsErrors#ERROR_MIDDLEWARE_LOST),[MbmsErrors.ERROR_MIDDLEWARE_NOT_BOUND](https://developer.android.com/reference/android/telephony/mbms/MbmsErrors#ERROR_MIDDLEWARE_NOT_BOUND),[MbmsErrors.InitializationErrors.ERROR_APP_PERMISSIONS_NOT_GRANTED](https://developer.android.com/reference/android/telephony/mbms/MbmsErrors.InitializationErrors#ERROR_APP_PERMISSIONS_NOT_GRANTED),[MbmsErrors.InitializationErrors.ERROR_DUPLICATE_INITIALIZE](https://developer.android.com/reference/android/telephony/mbms/MbmsErrors.InitializationErrors#ERROR_DUPLICATE_INITIALIZE),[MbmsErrors.InitializationErrors.ERROR_UNABLE_TO_INITIALIZE](https://developer.android.com/reference/android/telephony/mbms/MbmsErrors.InitializationErrors#ERROR_UNABLE_TO_INITIALIZE),[MbmsErrors.GeneralErrors.ERROR_MIDDLEWARE_NOT_YET_READY](https://developer.android.com/reference/android/telephony/mbms/MbmsErrors.GeneralErrors#ERROR_MIDDLEWARE_NOT_YET_READY),[MbmsErrors.GeneralErrors.ERROR_OUT_OF_MEMORY](https://developer.android.com/reference/android/telephony/mbms/MbmsErrors.GeneralErrors#ERROR_OUT_OF_MEMORY),[MbmsErrors.GeneralErrors.ERROR_MIDDLEWARE_TEMPORARILY_UNAVAILABLE](https://developer.android.com/reference/android/telephony/mbms/MbmsErrors.GeneralErrors#ERROR_MIDDLEWARE_TEMPORARILY_UNAVAILABLE),[MbmsErrors.GeneralErrors.ERROR_IN_E911](https://developer.android.com/reference/android/telephony/mbms/MbmsErrors.GeneralErrors#ERROR_IN_E911),[MbmsErrors.GeneralErrors.ERROR_NOT_CONNECTED_TO_HOME_CARRIER_LTE](https://developer.android.com/reference/android/telephony/mbms/MbmsErrors.GeneralErrors#ERROR_NOT_CONNECTED_TO_HOME_CARRIER_LTE),[MbmsErrors.GeneralErrors.ERROR_UNABLE_TO_READ_SIM](https://developer.android.com/reference/android/telephony/mbms/MbmsErrors.GeneralErrors#ERROR_UNABLE_TO_READ_SIM), or[MbmsErrors.GeneralErrors.ERROR_CARRIER_CHANGE_NOT_ALLOWED](https://developer.android.com/reference/android/telephony/mbms/MbmsErrors.GeneralErrors#ERROR_CARRIER_CHANGE_NOT_ALLOWED) <br /> |
| `message`   | `String`: A human-readable message generated by the middleware for debugging purposes. This value may be`null`. <br />                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             |

### onMiddlewareReady

Added in[API level 29](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)  

```
public void onMiddlewareReady ()
```

Called to indicate that the middleware has been initialized and is ready. Before this method is called, calling any method on an instance of[MbmsGroupCallSession](https://developer.android.com/reference/android/telephony/MbmsGroupCallSession)will result in an[IllegalStateException](https://developer.android.com/reference/java/lang/IllegalStateException)or an error delivered via[onError(int, java.lang.String)](https://developer.android.com/reference/android/telephony/mbms/MbmsGroupCallSessionCallback#onError(int,%20java.lang.String))with error code[MbmsErrors.GeneralErrors.ERROR_MIDDLEWARE_NOT_YET_READY](https://developer.android.com/reference/android/telephony/mbms/MbmsErrors.GeneralErrors#ERROR_MIDDLEWARE_NOT_YET_READY).

<br />

### onServiceInterfaceAvailable

Added in[API level 29](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)  

```
public void onServiceInterfaceAvailable (String interfaceName, 
                int index)
```

Called soon after the app calls[MbmsGroupCallSession.create](https://developer.android.com/reference/android/telephony/MbmsGroupCallSession#create(android.content.Context,%20int,%20java.util.concurrent.Executor,%20android.telephony.mbms.MbmsGroupCallSessionCallback)). The information supplied via this callback may be used to establish a data-link interface with the modem. In order to establish the data-link interface, the multicast IP and port must be obtained out-of-band from the carrier. A[MulticastSocket](https://developer.android.com/reference/java/net/MulticastSocket)may then be constructed using a[NetworkInterface](https://developer.android.com/reference/java/net/NetworkInterface)with the name and interface supplied by this callback.

<br />

|                                             Parameters                                              ||
|-----------------|------------------------------------------------------------------------------------|
| `interfaceName` | `String`: The interface name for the data link. This value cannot be`null`. <br /> |
| `index`         | `int`: The index for the data link. <br />                                         |