EOS_PlayerDataStorage_WriteFile

EOS API reference page for EOS_PlayerDataStorage_WriteFile

Choose your implementation method:

C

C#

This function is part of the PlayerDataStorage Interface.

Remarks

Write new data to a specific file, potentially overwriting any existing file by the same name, to the cloud. This request will occur asynchronously, potentially over multiple frames. All callbacks for this function will come from the same thread that the SDK is ticked from. If specified, the FileTransferProgressCallback will always be called at least once if the request is started successfully.

Return Value

A valid Player Data Storage File Request handle if successful, or NULL otherwise. Data contained in the completion callback will have more detailed information about issues with the request in failure cases. This handle must be released when it is no longer needed

See Also

EOS_PlayerDataStorageFileTransferRequest_Release

Parameters

EOS_PlayerDataStorage_WriteFile

Parameter Type And Name

Usage Information

EOS_HPlayerDataStorage Handle

const EOS_PlayerDataStorage_WriteFileOptions* WriteOptions

Object containing properties related to which user is writing the file, what the file's name is, and related mechanisms for writing the data

void* ClientData

Optional pointer to help clients track this request, that is returned in associated callbacks

const EOS_PlayerDataStorage_OnWriteFileCompleteCallback CompletionCallback

This function is called when the write operation completes

This function is asynchronous; the EOS SDK guarantees that your callback (the CompletionCallback parameter) will run when the operation completes, regardless of whether it succeeds or fails. Use the void* parameter to pass any contextual information the callback may need in order to react properly. Relevant information can be copied from the EOS SDK's cache while the callback function is running. You do not need to remove the callback function.

Callback Function Information

Because this function is asynchronous, it employs a callback of type EOS_PlayerDataStorage_OnWriteFileCompleteCallback to report the results of its operation.

Callback Remarks

Callback for when EOS_PlayerDataStorage_WriteFile completes

Callback Parameters

EOS_PlayerDataStorage_OnWriteFileCompleteCallback

Parameter Type And Name

Usage Information

const EOS_PlayerDataStorage_WriteFileCallbackInfo* Data

Related API Members

This function is part of the PlayerDataStorage Interface.

Remarks

Write new data to a specific file, potentially overwriting any existing file by the same name, to the cloud. This request will occur asynchronously, potentially over multiple frames. All callbacks for this function will come from the same thread that the SDK is ticked from. If specified, the FileTransferProgressCallback will always be called at least once if the request is started successfully.

Return Value

A valid Player Data Storage File Request handle if successful, or NULL otherwise. Data contained in the completion callback will have more detailed information about issues with the request in failure cases. This handle must be released when it is no longer needed

See Also

{PlayerDataStorageFileTransferRequest.Release}

Parameters

PlayerDataStorage.PlayerDataStorageInterface.WriteFile

Parameter Type And Name

Usage Information

WriteFileOptions writeOptions

Object containing properties related to which user is writing the file, what the file's name is, and related mechanisms for writing the data

object clientData

Optional pointer to help clients track this request, that is returned in associated callbacks

OnWriteFileCompleteCallback completionCallback

This function is called when the write operation completes

This function is asynchronous; the EOS SDK guarantees that your callback (the CompletionCallback parameter) will run when the operation completes, regardless of whether it succeeds or fails. Use the object parameter to pass any contextual information the callback may need in order to react properly. Relevant information can be copied from the EOS SDK's cache while the callback function is running. You do not need to remove the callback function.

Callback Function Information

Because this function is asynchronous, it employs a callback of type PlayerDataStorage.OnWriteFileCompleteCallback to report the results of its operation.

Callback Remarks

Callback for when {PlayerDataStorageInterface.WriteFile} completes

Callback Parameters

PlayerDataStorage.OnWriteFileCompleteCallback

Parameter Type And Name

Usage Information

WriteFileCallbackInfo data

Related API Members