HttpDownloader.h 667 Bytes
Newer Older
Kai Westerkamp committed
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30
// Fill out your copyright notice in the Description page of Project Settings.

#pragma once

#include "UObject/NoExportTypes.h"
#include "Runtime/Online/HTTP/Public/Http.h"
#include "HttpDownloader.generated.h"

/**
 * 
 */
UCLASS()
class MASTERTESTPROJECT_API UHttpDownloader : public UObject
{
	GENERATED_BODY()

public:
	UFUNCTION()
	FString ResolveRealativeURL(const FString &BaseUrl, const FString &RelativeUrl);


	UFUNCTION()
	void DownloadFile(const FString &URL);

	/*Assign this function to call when the GET request processes sucessfully*/
	virtual void OnResponseReceived(FHttpRequestPtr Request, FHttpResponsePtr Response, bool bWasSuccessful);

	
	
};