# UAppUpdateOptions Class Reference

# UAppUpdateOptions

`#include <AppUpdateOptions.h>`

This class represents the options for the app update.

## Summary

To create an instance of this class, use the CreateAppUpdateOptions function, which initializes the object based on the given update type.

### Inheritance

Inherits from: UObject

|                                                                                                                                                                                                                                                                                                                                ### Public static functions                                                                                                                                                                                                                                                                                                                                 ||
|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| [CreateAppUpdateOptions](https://developer.android.com/reference/unreal-engine/play/core/class/u-app-update-options#class_u_app_update_options_1a7902d9454e6d23b4693d0afa3e624111)`(`[EAppUpdateType](https://developer.android.com/reference/unreal-engine/play/core/group/play-in-app-updates#group___play_in_app_updates_1ga5d9c61ac39de4c62f8f7606d2956e5a0)` UpdateType)` | [UAppUpdateOptions](https://developer.android.com/reference/unreal-engine/play/core/class/u-app-update-options#class_u_app_update_options)` *` Creates an[UAppUpdateOptions](https://developer.android.com/reference/unreal-engine/play/core/class/u-app-update-options#class_u_app_update_options)object. |

|                                                                                                                                                                                                           ### Public functions                                                                                                                                                                                                            ||
|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| [BeginDestroy](https://developer.android.com/reference/unreal-engine/play/core/class/u-app-update-options#class_u_app_update_options_1ada1328abf456d6b9e65e0761fd5a6420)`() override`                  | `virtual void` Part of UObject interface.                                                                                                                                                                                         |
| [ClearAppUpdateOptions](https://developer.android.com/reference/unreal-engine/play/core/class/u-app-update-options#class_u_app_update_options_1af0f678f74e00bcf00a9813be4b9d0600)`()`                  | `void` Clears the native app update options object.                                                                                                                                                                               |
| [GetAppUpdateType](https://developer.android.com/reference/unreal-engine/play/core/class/u-app-update-options#class_u_app_update_options_1ad74cb1dd8db470feeddd4c7093cbcfdb)`()`                       | [EAppUpdateType](https://developer.android.com/reference/unreal-engine/play/core/group/play-in-app-updates#group___play_in_app_updates_1ga5d9c61ac39de4c62f8f7606d2956e5a0) Returns the type of update.                           |
| [IsAssetPackDeletionAllowed](https://developer.android.com/reference/unreal-engine/play/core/class/u-app-update-options#class_u_app_update_options_1a6192dffd22b2f40065093f05d2c3b858)`()`             | `bool` Returns whether the asset pack deletion is allowed.                                                                                                                                                                        |
| [SetAssetPackDeletionAllowed](https://developer.android.com/reference/unreal-engine/play/core/class/u-app-update-options#class_u_app_update_options_1a6e1a493ef23087e2d0e49743a288a4fe)`(bool bAllow)` | [EAppUpdateErrorCode](https://developer.android.com/reference/unreal-engine/play/core/group/play-in-app-updates#group___play_in_app_updates_1ga55d0c575f82f8fab56d7129e5c8399e5) Sets whether the asset pack deletion is allowed. |

## Public static functions

### CreateAppUpdateOptions

```scdoc
UAppUpdateOptions * CreateAppUpdateOptions(
  EAppUpdateType UpdateType
)
```  
Creates an[UAppUpdateOptions](https://developer.android.com/reference/unreal-engine/play/core/class/u-app-update-options#class_u_app_update_options)object.

<br />

|                                                                              Details                                                                              ||
|-------------|------------------------------------------------------------------------------------------------------------------------------------------------------|
| Parameters  | |--------------|---------------------| | `UpdateType` | The type of update. |                                                                        |
| **Returns** | The[UAppUpdateOptions](https://developer.android.com/reference/unreal-engine/play/core/class/u-app-update-options#class_u_app_update_options)object. |

## Public functions

### BeginDestroy

```text
virtual void BeginDestroy() override
```  
Part of UObject interface.

Called when the object is marked for deletion by MarkPendingKill.  

### ClearAppUpdateOptions

```text
void ClearAppUpdateOptions()
```  
Clears the native app update options object.  

### GetAppUpdateType

```text
EAppUpdateType GetAppUpdateType()
```  
Returns the type of update.  

### IsAssetPackDeletionAllowed

```text
bool IsAssetPackDeletionAllowed()
```  
Returns whether the asset pack deletion is allowed.  

### SetAssetPackDeletionAllowed

```text
EAppUpdateErrorCode SetAssetPackDeletionAllowed(
  bool bAllow
)
```  
Sets whether the asset pack deletion is allowed.

<br />

|                                                              Details                                                               ||
|-------------|-----------------------------------------------------------------------------------------------------------------------|
| Parameters  | |----------|---------------------------------------------| | `bAllow` | Whether the asset pack deletion is allowed. | |
| **Returns** | The error code of the operation.                                                                                      |