FBufferReaderWithSHA

Similar to [FBufferReader](API\Runtime\Core\Serialization\FBufferReader), but will verify the contents of the buffer on close (on close to that we know we don't need the data anymore)

Choose your operating system:

Windows

macOS

Linux

Inheritance Hierarchy

References

Module

Core

Header

/Engine/Source/Runtime/Core/Public/Misc/SecureHash.h

Include

#include "Misc/SecureHash.h"

Syntax

class FBufferReaderWithSHA : public FBufferReaderBase

Remarks

Similar to FBufferReader, but will verify the contents of the buffer on close (on close to that we know we don't need the data anymore)

Variables

Name Description

Protected variable

bool

 

bIsUnfoundHashAnError

True if failing to lookup the hash should trigger an error

Protected variable

FString

 

SourcePathname

Path to the file to use to lookup the SHA hash value

Constructors

Name Description

Public function

FBufferReaderWithSHA

(
    void* Data,
    int64 Size,
    bool bInFreeOnClose,
    const TCHAR* SHASourcePathname,
    bool bIsPersistent,
    bool bInIsUnfoundHashAnError
)

We force the base class to NOT free buffer on close, as we will let the SHA task do it if needed

Destructors

Name Description

Public function

~FBufferReaderWithSHA()

Overridden from FArchive

Name Description

Public function Virtual

bool

 

Close()

Attempts to close and finalize any handles used for backing data storage, returns true if it succeeded.

Overridden from FArchiveState

Name Description

Public function Virtual Const

FString

 

GetArchiveName()

Returns the name of the Archive.