# InstallReferrerStateListener

# InstallReferrerStateListener

`
public


interface
InstallReferrerStateListener
`  
`


`

|--------------------------------------------------------------|
| com.android.installreferrer.api.InstallReferrerStateListener |

<br />

*** ** * ** ***

Callback for setup process. This listener's[onInstallReferrerSetupFinished(int)](https://developer.android.com/reference/com/android/installreferrer/api/InstallReferrerStateListener#onInstallReferrerSetupFinished(int))method is called when the setup process is complete.

## Summary

|                                                                                                                                  ### Public methods                                                                                                                                  ||
|------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| ` abstract void` | ` `[onInstallReferrerServiceDisconnected](https://developer.android.com/reference/com/android/installreferrer/api/InstallReferrerStateListener#onInstallReferrerServiceDisconnected())`() ` Called to notify that connection to install referrer service was lost. |
| ` abstract void` | ` `[onInstallReferrerSetupFinished](https://developer.android.com/reference/com/android/installreferrer/api/InstallReferrerStateListener#onInstallReferrerSetupFinished(int))`(int responseCode) ` Called to notify that setup is complete.                        |

## Public methods

### onInstallReferrerServiceDisconnected

```
void onInstallReferrerServiceDisconnected ()
```

Called to notify that connection to install referrer service was lost.

Note: This does not remove install referrer service connection itself - this binding to the service will remain active, and you will receive a call to[onInstallReferrerSetupFinished(int)](https://developer.android.com/reference/com/android/installreferrer/api/InstallReferrerStateListener#onInstallReferrerSetupFinished(int))when install referrer service is next running and setup is complete.

<br />

### onInstallReferrerSetupFinished

```
void onInstallReferrerSetupFinished (int responseCode)
```

Called to notify that setup is complete.

<br />

|                                                                                                                                Parameters                                                                                                                                ||
|----------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| `responseCode` | `int`: The response code from[InstallReferrerClient.InstallReferrerResponse](https://developer.android.com/reference/com/android/installreferrer/api/InstallReferrerClient.InstallReferrerResponse)which returns the status of the setup process. <br /> |

-

  ## Annotations

  - [InstallReferrerClient.InstallReferrerResponse](https://developer.android.com/reference/com/android/installreferrer/api/InstallReferrerClient.InstallReferrerResponse)
-

  ## Interfaces

  - [InstallReferrerStateListener](https://developer.android.com/reference/com/android/installreferrer/api/InstallReferrerStateListener)
-

  ## Classes

  - [InstallReferrerClient](https://developer.android.com/reference/com/android/installreferrer/api/InstallReferrerClient)
  - [InstallReferrerClient.Builder](https://developer.android.com/reference/com/android/installreferrer/api/InstallReferrerClient.Builder)
  - [ReferrerDetails](https://developer.android.com/reference/com/android/installreferrer/api/ReferrerDetails)