17#include "CoreMinimal.h"
18#include "UObject/NoExportTypes.h"
19#include "PPF_Platform.h"
20#include "OnlineSubsystemPicoNames.h"
21#include "OnlineSubsystemPico.h"
22#include "Pico_AssetFile.generated.h"
29DECLARE_LOG_CATEGORY_EXTERN(PicoAssetFile, Log, All);
31DECLARE_DYNAMIC_DELEGATE_ThreeParams(FAssetFileDeleteResult,
bool, bIsError,
const FString&, ErrorMessage, UPico_AssetFileDeleteResult*, DeleteResult);
32DECLARE_DYNAMIC_DELEGATE_ThreeParams(FAssetFileDownloadResult,
bool, bIsError,
const FString&, ErrorMessage, UPico_AssetFileDownloadResult*, DownloadResult);
33DECLARE_DYNAMIC_DELEGATE_ThreeParams(FAssetFileDownloadCancelResult,
bool, bIsError,
const FString&, ErrorMessage, UPico_AssetFileDownloadCancelResult*, DownloadCancelResult);
34DECLARE_DYNAMIC_DELEGATE_ThreeParams(FGetAssetFileStatus,
bool, bIsError,
const FString&, ErrorMessage, UPico_AssetStatus*, AssetFileStatus);
35DECLARE_DYNAMIC_DELEGATE_ThreeParams(FGetAssetFileList,
bool, bIsError,
const FString&, ErrorMessage, UPico_AssetDetailsArray*, AssetDetailsArray);
37DECLARE_MULTICAST_DELEGATE_OneParam(FAssetFileDownloadUpdateNotify, UPico_AssetFileDownloadUpdate* );
38DECLARE_MULTICAST_DELEGATE_OneParam(FAssetFileDeleteForSafetyNotify, UPico_AssetFileDeleteForSafety* );
57 FOnlineSubsystemPico& PicoSubsystem;
63 FAssetFileDeleteResult DeleteByIDDelegate;
64 FAssetFileDeleteResult DeleteByNameDelegate;
65 FAssetFileDownloadResult DownloadByIdDelegate;
66 FAssetFileDownloadResult DownloadByNameDelegate;
67 FAssetFileDownloadCancelResult DownloadCancelByIdDelegate;
68 FAssetFileDownloadCancelResult DownloadCancelNameIdDelegate;
69 FGetAssetFileStatus GetAssetFileStatusByIdDelegate;
70 FGetAssetFileStatus GetAssetFileStatusByNameDelegate;
71 FGetAssetFileList GetAssetFileListDelegate;
72 FGetAssetFileList GetNextAssetDetailsArrayPageDelegate;
99 bool DeleteByID(FString AssetFileID, FAssetFileDeleteResult InDeleteByIDDelegate);
113 bool DeleteByName(FString AssetFileName, FAssetFileDeleteResult InDeleteByNameDelegate);
126 bool DownloadById(FString AssetFileID, FAssetFileDownloadResult InDownloadByIDDelegate);
139 bool DownloadByName(FString AssetFileName, FAssetFileDownloadResult InDownloadByNameDelegate);
152 bool DownloadCancelById(FString AssetFileID, FAssetFileDownloadCancelResult InDownloadCancelByIDDelegate);
165 bool DownloadCancelByName(FString AssetFileName, FAssetFileDownloadCancelResult InDownloadCancelByNameDelegate);
218 FDelegateHandle AssetFileDownloadUpdateHandle;
219 void OnAssetFileDownloadUpdate(ppfMessageHandle Message,
bool bIsError);
221 FDelegateHandle AssetFileDeleteForSafetyHandle;
222 void OnAssetFileDeleteForSafety(ppfMessageHandle Message,
bool bIsError);
261 UFUNCTION(BlueprintCallable, meta = (WorldContext =
"WorldContextObject"), Category =
"OnlinePico|AssetFile")
262 static
bool DeleteByID(UObject* WorldContextObject, FString AssetFileID, FAssetFileDeleteResult InDeleteByIDDelegate);
277 UFUNCTION(BlueprintCallable, meta = (WorldContext = "WorldContextObject"), Category = "OnlinePico|AssetFile")
278 static
bool DeleteByName(UObject* WorldContextObject, FString AssetFileName, FAssetFileDeleteResult InDeleteByNameDelegate);
292 UFUNCTION(BlueprintCallable, meta = (WorldContext = "WorldContextObject"), Category = "OnlinePico|AssetFile")
293 static
bool DownloadById(UObject* WorldContextObject, FString AssetFileID, FAssetFileDownloadResult InDownloadByIDDelegate);
307 UFUNCTION(BlueprintCallable, meta = (WorldContext = "WorldContextObject"), Category = "OnlinePico|AssetFile")
308 static
bool DownloadByName(UObject* WorldContextObject, FString AssetFileName, FAssetFileDownloadResult InDownloadByNameDelegate);
322 UFUNCTION(BlueprintCallable, meta = (WorldContext = "WorldContextObject"), Category = "OnlinePico|AssetFile")
323 static
bool DownloadCancelById(UObject* WorldContextObject, FString AssetFileID, FAssetFileDownloadCancelResult InDownloadCancelByIDDelegate);
337 UFUNCTION(BlueprintCallable, meta = (WorldContext = "WorldContextObject"), Category = "OnlinePico|AssetFile")
338 static
bool DownloadCancelByName(UObject* WorldContextObject, FString AssetFileName, FAssetFileDownloadCancelResult InDownloadCancelByNameDelegate);
351 UFUNCTION(BlueprintCallable, meta = (WorldContext = "WorldContextObject"), Category = "OnlinePico|AssetFile")
352 static
bool GetAssetFileList(UObject* WorldContextObject, FGetAssetFileList InGetAssetFileListDelegate);
366 UFUNCTION(BlueprintCallable, meta = (WorldContext = "WorldContextObject"), Category = "OnlinePico|AssetFile")
367 static
bool GetNextAssetDetailsArrayPage(UObject* WorldContextObject, UPico_AssetDetailsArray* InAssetDetailsArray, FGetAssetFileList InGetNextAssetDetailsArrayPageDelegate);
381 UFUNCTION(BlueprintCallable, meta = (WorldContext = "WorldContextObject"), Category = "OnlinePico|AssetFile")
382 static
bool GetAssetFileStatusById(UObject* WorldContextObject, FString AssetFileID, FGetAssetFileStatus InGetAssetFileStatusByIdDelegate);
396 UFUNCTION(BlueprintCallable, meta = (WorldContext = "WorldContextObject"), Category = "OnlinePico|AssetFile")
397 static
bool GetAssetFileStatusByName(UObject* WorldContextObject, FString AssetFileName, FGetAssetFileStatus InGetAssetFileStatusByNameDelegate);
405class ONLINESUBSYSTEMPICO_API UPico_AssetFileDeleteResult : public UObject
411 void InitParams(ppfAssetFileDeleteResult* InppfAssetFileDeleteResultHandle);
414 FString AssetId = FString();
415 FString FilePath = FString();
416 bool bIsSuccessed =
false;
417 ppfID ppfAssetId = 0;
421 UFUNCTION(BlueprintPure, Category =
"Pico Platform|AssetFile|Delete Result")
422 FString GetAssetId();
424 UFUNCTION(BlueprintPure, Category =
"Pico Platform|AssetFile|Delete Result")
425 FString GetFilePath();
427 UFUNCTION(BlueprintPure, Category =
"Pico Platform|AssetFile|Delete Result")
430 ppfID GetppfAssetId();
435class ONLINESUBSYSTEMPICO_API UPico_AssetDetails :
public UObject
441 void InitParams(ppfAssetDetails* InppfAssetDetailsHandle);
444 FString AssetId = FString();
445 FString AssetType = FString();
446 FString DownloadStatus = FString();
447 FString FilePath = FString();
448 FString IapStatus = FString();
449 FString Metadata = FString();
450 FString Filename = FString();
452 FString IapSku = FString();
453 FString IapName = FString();
454 FString IapPrice = FString();
455 FString IapCurrency = FString();
456 FString IapDescription = FString();
457 FString IapIconUrl = FString();
458 ppfID ppfAssetId = 0;
461 UFUNCTION(BlueprintPure, Category = "Pico Platform|AssetFile|Asset Details")
462 FString GetAssetId();
464 UFUNCTION(BlueprintPure, Category = "Pico Platform|AssetFile|Asset Details")
465 FString GetFilePath();
467 UFUNCTION(BlueprintPure, Category = "Pico Platform|AssetFile|Asset Details")
468 FString GetAssetType();
470 UFUNCTION(BlueprintPure, Category = "Pico Platform|AssetFile|Asset Details")
471 FString GetDownloadStatus();
473 UFUNCTION(BlueprintPure, Category = "Pico Platform|AssetFile|Asset Details")
474 FString GetIapStatus();
476 UFUNCTION(BlueprintPure, Category = "Pico Platform|AssetFile|Asset Details")
477 FString GetMetadata();
479 UFUNCTION(BlueprintPure, Category = "Pico Platform|AssetFile|Asset Details")
480 FString GetFilename();
482 UFUNCTION(BlueprintPure, Category = "Pico Platform|AssetFile|Asset Details")
485 UFUNCTION(BlueprintPure, Category = "Pico Platform|AssetFile|Asset Details")
488 UFUNCTION(BlueprintPure, Category = "Pico Platform|AssetFile|Asset Details")
489 FString GetIapName();
491 UFUNCTION(BlueprintPure, Category = "Pico Platform|AssetFile|Asset Details")
492 FString GetIapPrice();
494 UFUNCTION(BlueprintPure, Category = "Pico Platform|AssetFile|Asset Details")
495 FString GetIapCurrency();
497 UFUNCTION(BlueprintPure, Category = "Pico Platform|AssetFile|Asset Details")
498 FString GetIapDescription();
500 UFUNCTION(BlueprintPure, Category = "Pico Platform|AssetFile|Asset Details")
501 FString GetIapIconUrl();
503 ppfID GetppfAssetId();
507class ONLINESUBSYSTEMPICO_API UPico_AssetDetailsArray : public UObject
513 void InitParams(ppfAssetDetailsArray* InppfAssetDetailsArrayHandle);
517 TArray<UPico_AssetDetails*> AssetDetailsArray;
520 bool bHasNextPage = false;
521 FString NextPageParam = FString();
525 UFUNCTION(BlueprintPure, Category = "Pico Platform|AssetFile|Asset Details Array")
526 UPico_AssetDetails* GetElement(int32 Index);
528 UFUNCTION(BlueprintPure, Category = "Pico Platform|AssetFile|Asset Details Array")
531 UFUNCTION(BlueprintPure, Category = "Pico Platform|AssetFile|Asset Details Array")
532 bool GetHasNextPage();
534 UFUNCTION(BlueprintPure, Category = "Pico Platform|AssetFile|Asset Details Array")
535 FString GetNextPageParam();
539class ONLINESUBSYSTEMPICO_API UPico_AssetFileDownloadCancelResult : public UObject
545 void InitParams(ppfAssetFileDownloadCancelResult* InppfAssetFileDownloadCancelResultHandle);
548 FString AssetId = FString();
549 FString FilePath = FString();
550 bool bIsSuccessed = false;
551 ppfID ppfAssetId = 0;
554 UFUNCTION(BlueprintPure, Category = "Pico Platform|AssetFile|Download Cancel Result")
555 FString GetAssetId();
557 UFUNCTION(BlueprintPure, Category = "Pico Platform|AssetFile|Download Cancel Result")
558 FString GetFilePath();
560 UFUNCTION(BlueprintPure, Category = "Pico Platform|AssetFile|Download Cancel Result")
563 ppfID GetppfAssetId();
567class ONLINESUBSYSTEMPICO_API UPico_AssetFileDownloadUpdate : public UObject
573 void InitParams(ppfAssetFileDownloadUpdate* InppfAssetFileDownloadUpdateHandle);
576 FString AssetId = FString();
577 int64 BytesTotal = 0;
578 int64 BytesTransferred = 0;
580 ppfID ppfAssetId = 0;
584 UFUNCTION(BlueprintPure, Category = "Pico Platform|AssetFile|Download Update")
585 FString GetAssetId();
587 UFUNCTION(BlueprintPure, Category = "Pico Platform|AssetFile|Download Update")
588 int64 GetBytesTotal();
590 UFUNCTION(BlueprintPure, Category = "Pico Platform|AssetFile|Download Update")
591 int64 GetBytesTransferred();
593 UFUNCTION(BlueprintPure, Category = "Pico Platform|AssetFile|Download Update")
596 ppfID GetppfAssetId();
600class ONLINESUBSYSTEMPICO_API UPico_AssetFileDownloadResult : public UObject
606 void InitParams(ppfAssetFileDownloadResult* InppfAssetFileDownloadResultHandle);
609 FString AssetId = FString();
610 FString FilePath = FString();
611 ppfID ppfAssetId = 0;
615 UFUNCTION(BlueprintPure, Category = "Pico Platform|AssetFile|Download Result")
616 FString GetAssetId();
618 UFUNCTION(BlueprintPure, Category = "Pico Platform|AssetFile|Download Result")
619 FString GetFilePath();
621 ppfID GetppfAssetId();
625class ONLINESUBSYSTEMPICO_API UPico_AssetStatus : public UObject
631 void InitParams(ppfAssetStatus* InppfAssetStatusHandle);
634 FString AssetId = FString();
635 FString FilePath = FString();
636 FString FileName = FString();
637 FString DownloadStatus = FString();
638 ppfID ppfAssetId = 0;
642 UFUNCTION(BlueprintPure, Category = "Pico Platform|AssetFile|Asset Status")
643 FString GetAssetId();
645 UFUNCTION(BlueprintPure, Category = "Pico Platform|AssetFile|Asset Status")
646 FString GetFilePath();
648 UFUNCTION(BlueprintPure, Category = "Pico Platform|AssetFile|Asset Status")
649 FString GetFileName();
652 UFUNCTION(BlueprintPure, Category = "Pico Platform|AssetFile|Asset Status")
653 FString GetDownloadStatus();
655 ppfID GetppfAssetId();
659class ONLINESUBSYSTEMPICO_API UPico_AssetFileDeleteForSafety : public UObject
665 void InitParams(ppfAssetFileDeleteForSafety* InppfAssetFileDeleteForSafetyHandle);
668 FString AssetId = FString();
669 FString Reason = FString();
670 ppfID ppfAssetId = 0;
674 UFUNCTION(BlueprintPure, Category = "Pico Platform|AssetFile|Delete For Safety")
675 FString GetAssetId();
677 UFUNCTION(BlueprintPure, Category = "Pico Platform|AssetFile|Delete For Safety")
680 ppfID GetppfAssetId();
PicoAssetFileInterface class.
Definition: Pico_AssetFile.h:54
bool DownloadCancelByName(FString AssetFileName, FAssetFileDownloadCancelResult InDownloadCancelByNameDelegate)
Cancels the download of an asset file by asset file name.
bool DownloadCancelById(FString AssetFileID, FAssetFileDownloadCancelResult InDownloadCancelByIDDelegate)
Cancels the download of an asset file by asset file ID.
FAssetFileDeleteForSafetyNotify AssetFileDeleteForSafetyCallback
Sets the callback to automatically delete a downloaded asset file if it is different from the origina...
Definition: Pico_AssetFile.h:85
bool DownloadById(FString AssetFileID, FAssetFileDownloadResult InDownloadByIDDelegate)
Downloads an asset file by asset file ID.
bool DeleteByName(FString AssetFileName, FAssetFileDeleteResult InDeleteByNameDelegate)
Deletes an installed asset file by asset file name. The corresponding asset file will be removed from...
bool GetAssetFileStatusById(FString AssetFileID, FGetAssetFileStatus InGetAssetFileStatusByIdDelegate)
Gets the download status of an asset file by asset file ID.
bool DeleteByID(FString AssetFileID, FAssetFileDeleteResult InDeleteByIDDelegate)
Deletes an installed asset file by asset file ID. The corresponding asset file will be removed from t...
FAssetFileDownloadUpdateNotify AssetFileDownloadUpdateCallback
Sets the callback to track the download progress of asset file. The Transferred field indicates the n...
Definition: Pico_AssetFile.h:79
bool GetNextAssetDetailsArrayPage(UPico_AssetDetailsArray *InAssetDetailsArray, FGetAssetFileList InGetNextAssetDetailsArrayPageDelegate)
Gets the next page of the asset file list.
bool DownloadByName(FString AssetFileName, FAssetFileDownloadResult InDownloadByNameDelegate)
Downloads an asset file by asset file name.
bool GetAssetFileStatusByName(FString AssetFileName, FGetAssetFileStatus InGetAssetFileStatusByNameDelegate)
Gets the download status of an asset file by asset file name.
bool GetAssetFileList(FGetAssetFileList InGetAssetFileListDelegate)
Gets the asset file list.
OnlinePicoAssetFile Blueprint Function class.
Definition: Pico_AssetFile.h:242
EAssetFileDownloadCompleteStatus
The status of the file in the file download process.
Definition: OnlineSubsystemPicoNames.h:591