CRIWARE Unity Plugin Manual  Last Updated: 2024-07-12
CriFsInstaller Class Reference

A module for installing files. More...

Inherits CriDisposable.

Public Types

enum  Status { Stop, Busy, Complete, Error }
 A value indicating the installer status. More...
 

Public Member Functions

override void Dispose ()
 Discards the installer. More...
 
void Copy (CriFsBinder binder, string srcPath, string dstPath, int installBufferSize)
 Copies the file. More...
 
void Stop ()
 Stops the installation process. More...
 
Status GetStatus ()
 Gets the status of the installer. More...
 
float GetProgress ()
 Gets the progress of the installation process. More...
 

Static Public Member Functions

static void ExecuteMain ()
 Periodic execution function More...
 

Detailed Description

A module for installing files.

Description:
A module for installing files.
Used to install content on the server to the local storage.
Note:
If the network connection times out, CriFsInstaller retries infinitely. However, an error occurs and it doesn't retry in the following cases.
  • Network connection timed out while checking the existence of the installation source file
  • The installation source file did not exist This class does not determine when to abort the infinite retry.
Note:
It is up to the application implementation to decide when to stop infinite retry.
For example, interruption by the following steps is possible.
  1. Get the installation progress using the CriWare.CriFsInstaller::GetProgress function.
  2. After a certain period of time, get the installation progress again.
  3. If the values obtained in step 1. and step 2. are the same, stop the installation using the CriWare.CriFsInstaller::Stop function.

Member Enumeration Documentation

enum Status
strong

A value indicating the installer status.

See also
CriFsInstaller::GetStatus
Enumerator
Stop 

Stopped

Busy 

Installation in progress

Complete 

Installation complete

Error 

Error occurred

Member Function Documentation

override void Dispose ( )
inline

Discards the installer.

Note:
If you discard the installer during the installation process, the process may be blocked in this function for a long time.
void Copy ( CriFsBinder  binder,
string  srcPath,
string  dstPath,
int  installBufferSize 
)
inline

Copies the file.

Parameters
binderBinder
srcPathCopy source file path name
dstPathCopy destination file path name
installBufferSizeInstall buffer size
Description:
Starts copying files.

This function returns immediately.
To get the copy completion status, use the CriWare.CriFsInstaller::GetStatus function.
See also
CriFsInstaller::GetStatus
void Stop ( )
inline

Stops the installation process.

Description:
Stops the processing.

This function returns immediately.
Use the CriWare.CriFsInstaller::GetStatus function to get the stop completion status.
See also
CriFsInstaller::GetStatus
Status GetStatus ( )
inline

Gets the status of the installer.

Returns
Status
See also
CriFsInstaller::Status
float GetProgress ( )
inline

Gets the progress of the installation process.

Returns
Progress status
Description:
Gets the progress of the process.
It is a 32-bit floating point number in the range from 0.0 to 1.0.
static void ExecuteMain ( )
inlinestatic

Periodic execution function

Description:
Proceed with the installation process. It should be run regularly.

The documentation for this class was generated from the following file: