CommonLibSSE (powerof3)
Loading...
Searching...
No Matches
ArchiveStream.h
Go to the documentation of this file.
1#pragma once
2
3#include "RE/S/Stream.h"
4
5namespace RE
6{
7 namespace BSResource
8 {
9 class ArchiveStream : public Stream
10 {
11 public:
12 inline static constexpr auto RTTI = RTTI_BSResource__ArchiveStream;
13 inline static constexpr auto VTABLE = VTABLE_BSResource__ArchiveStream;
14
15 ~ArchiveStream() override; // 00
16
17 // override (Stream)
18 ErrorCode DoOpen() override; // 01
19 void DoClose() override; // 02
20 [[nodiscard]] std::uint64_t DoGetKey() const override; // 03
21 void DoClone(BSTSmartPointer<Stream>& a_out) const override; // 05
22 ErrorCode DoRead(void* a_buffer, std::uint64_t a_toRead, std::uint64_t& a_read) const override; // 06
23 ErrorCode DoWrite(const void* a_buffer, std::uint64_t a_toWrite, std::uint64_t& a_written) const override; // 07
24 ErrorCode DoSeek(std::uint64_t a_toSeek, SeekMode a_mode, std::uint64_t& a_sought) const override; // 08
25 bool DoGetName(BSFixedString& a_dst) const override; // 0A
26 ErrorCode DoCreateAsync(BSTSmartPointer<AsyncStream>& a_streamOut) const override; // 0B
27
28 // add
29 virtual std::uint32_t DoGetSize() const; // 0C
30
31 // members
32 void* source; // 10
33 std::uint32_t startOffset; // 18
34 std::uint32_t currentOffset; // 1C
36 };
37#ifdef SKYRIM_SUPPORT_AE
38 static_assert(sizeof(ArchiveStream) == 0x30);
39#else
40 static_assert(sizeof(ArchiveStream) == 0x28);
41#endif
42 }
43}
Definition ArchiveStream.h:10
ErrorCode DoOpen() override
ErrorCode DoCreateAsync(BSTSmartPointer< AsyncStream > &a_streamOut) const override
ErrorCode DoRead(void *a_buffer, std::uint64_t a_toRead, std::uint64_t &a_read) const override
bool DoGetName(BSFixedString &a_dst) const override
std::uint32_t startOffset
Definition ArchiveStream.h:33
std::uint32_t currentOffset
Definition ArchiveStream.h:34
ErrorCode DoSeek(std::uint64_t a_toSeek, SeekMode a_mode, std::uint64_t &a_sought) const override
static constexpr auto RTTI
Definition ArchiveStream.h:12
ErrorCode DoWrite(const void *a_buffer, std::uint64_t a_toWrite, std::uint64_t &a_written) const override
static constexpr auto VTABLE
Definition ArchiveStream.h:13
BSFixedString name
Definition ArchiveStream.h:35
std::uint64_t DoGetKey() const override
virtual std::uint32_t DoGetSize() const
void * source
Definition ArchiveStream.h:32
void DoClone(BSTSmartPointer< Stream > &a_out) const override
Definition Stream.h:21
Definition BSTSmartPointer.h:37
ErrorCode
Definition ErrorCodes.h:8
SeekMode
Definition Stream.h:14
Definition AbsorbEffect.h:6
constexpr std::array< REL::ID, 1 > VTABLE_BSResource__ArchiveStream
Definition Offsets_VTABLE.h:9381
constexpr REL::ID RTTI_BSResource__ArchiveStream(static_cast< std::uint64_t >(690346))