# GoogleMobileAds.Api.ApplicationPreferences

Interface for accessing and modifying application preference data (SharedPreferences on Android and NSUserDefaults on iOS).

## Summary

Values saved by this interface are saved in an application scope, and are shared by SDKs included in this application.

| ### Public static functions ||
|---|---|
| `https://developers.google.com/admob/unity/reference/class/google-mobile-ads/api/application-preferences#class_google_mobile_ads_1_1_api_1_1_application_preferences_1a45142ada039ff4f929c4833f8716c013(string key)` | `int` Read an int value from the application preferences. |
| `https://developers.google.com/admob/unity/reference/class/google-mobile-ads/api/application-preferences#class_google_mobile_ads_1_1_api_1_1_application_preferences_1a4d3bb991eb41c245be0a69d07a61a283(string key)` | `string` Read a string value from the application preferences. |
| `https://developers.google.com/admob/unity/reference/class/google-mobile-ads/api/application-preferences#class_google_mobile_ads_1_1_api_1_1_application_preferences_1af44cbd83d5b0197fa4cb5aade13b866e(string key, int value)` | `void` Set an int value in the application preferences. |
| `https://developers.google.com/admob/unity/reference/class/google-mobile-ads/api/application-preferences#class_google_mobile_ads_1_1_api_1_1_application_preferences_1a66402a11446d4af5eec8ca2821c45baf(string key, string value)` | `void` Set a string value in the application preferences. |

## Public static functions

### GetInt

```c#
int GetInt(
  string key
)
```
Read an int value from the application preferences.

<br />

Details Parameters `key` The key with which to retrieve the value.

### GetString

```c#
string GetString(
  string key
)
```
Read a string value from the application preferences.

<br />

Details Parameters `key` The key with which to retrieve the value.

### SetInt

```c#
void SetInt(
  string key,
  int value
)
```
Set an int value in the application preferences.

<br />

Details Parameters `key` The key with which to associate the value. `value` The value that needs to be associated to the key.

### SetString

```c#
void SetString(
  string key,
  string value
)
```
Set a string value in the application preferences.

<br />

Details Parameters `key` The key with which to associate the value. `value` The value that needs to be associated to the key.