CommonLibSSE NG
Loading...
Searching...
No Matches
LooseFileStream.h
Go to the documentation of this file.
1#pragma once
2
5#include "RE/S/Stream.h"
6
7namespace RE
8{
9 namespace BSResource
10 {
11 class Location;
12
14 public LooseFileStreamBase, // 10
15 public Stream // 00
16 {
17 public:
18 inline static constexpr auto RTTI = RTTI_BSResource____LooseFileStream;
19
20 ~LooseFileStream() override; // 00
21
22 // override (Stream)
23 ErrorCode DoOpen() override; // 01
24 void DoClose() override; // 02
25 ErrorCode DoGetInfo(Info& a_info) override; // 04
26 void DoClone(BSTSmartPointer<Stream>& a_out) const override; // 05
27 ErrorCode DoRead(void* a_buffer, std::uint64_t a_toRead, std::uint64_t& a_read) const override; // 06
28 ErrorCode DoWrite(const void* a_buffer, std::uint64_t a_toWrite, std::uint64_t& a_written) const override; // 07
29 ErrorCode DoSeek(std::uint64_t a_toSeek, SeekMode a_mode, std::uint64_t& a_sought) const override; // 08
30 ErrorCode DoSetEndOfStream() override; // 09
31 bool DoGetName(BSFixedString& a_dst) const override; // 0A
32 ErrorCode DoCreateAsync(BSTSmartPointer<AsyncStream>& a_streamOut) const override; // 0B
33#ifndef ENABLE_SKYRIM_AE
34 static LooseFileStream* Create(BSFixedString a_prefix, BSFixedString a_dirName, BSFixedString a_fileName, std::uint32_t a_fileSize, bool a_readOnly, Location* a_location);
35#endif
36
37 // members
39 std::uint64_t filePos; // 40
40 void* buffer; // 48
41
42 private:
43#ifndef ENABLE_SKYRIM_AE
44 LooseFileStream* Ctor(const BSFixedString& a_prefix, const BSFixedString& a_dirName, const BSFixedString& a_fileName, std::uint32_t a_fileSize, bool a_readOnly, Location* a_location);
45#endif
46 };
47 static_assert(sizeof(LooseFileStream) == 0x50);
48 }
49}
Definition Location.h:17
Definition LooseFileStream.h:16
void DoClone(BSTSmartPointer< Stream > &a_out) const override
ErrorCode DoCreateAsync(BSTSmartPointer< AsyncStream > &a_streamOut) const override
ErrorCode DoSetEndOfStream() override
static constexpr auto RTTI
Definition LooseFileStream.h:18
ErrorCode DoRead(void *a_buffer, std::uint64_t a_toRead, std::uint64_t &a_read) const override
ErrorCode DoGetInfo(Info &a_info) override
ErrorCode DoOpen() override
void * buffer
Definition LooseFileStream.h:40
Location * location
Definition LooseFileStream.h:38
bool DoGetName(BSFixedString &a_dst) const override
ErrorCode DoWrite(const void *a_buffer, std::uint64_t a_toWrite, std::uint64_t &a_written) const override
static LooseFileStream * Create(BSFixedString a_prefix, BSFixedString a_dirName, BSFixedString a_fileName, std::uint32_t a_fileSize, bool a_readOnly, Location *a_location)
ErrorCode DoSeek(std::uint64_t a_toSeek, SeekMode a_mode, std::uint64_t &a_sought) const override
std::uint64_t filePos
Definition LooseFileStream.h:39
Definition Stream.h:21
Definition BSTSmartPointer.h:36
ErrorCode
Definition ErrorCodes.h:8
SeekMode
Definition Stream.h:14
Definition AbsorbEffect.h:6
constexpr REL::VariantID RTTI_BSResource____LooseFileStream(690383, 398238, 0x1f61208)
Definition Info.h:8
Definition LooseFileStreamBase.h:11