LeviLamina
Loading...
Searching...
No Matches
ResponseResourceRange.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5namespace Gameface {
6
8public:
9 // ResponseResourceRange inner types declare
10 // clang-format off
11 struct RangeInBytes;
12 // clang-format on
13
14 // ResponseResourceRange inner types define
15 enum class Status : ushort {
16 Ok = 200,
17 PartialContent = 206,
18 RangeNotSatisfiable = 416,
19 };
20
21 struct RangeInBytes {
22 public:
23 // member variables
24 // NOLINTBEGIN
25 ::ll::TypedStorage<8, 8, uint64> start;
26 ::ll::TypedStorage<8, 8, uint64> end;
27 // NOLINTEND
28 };
29
30public:
31 // member variables
32 // NOLINTBEGIN
33 ::ll::TypedStorage<2, 2, ::Gameface::ResponseResourceRange::Status> mStatus;
34 ::ll::TypedStorage<8, 24, ::std::optional<::Gameface::ResponseResourceRange::RangeInBytes>> mRangeInBytes;
35 ::ll::TypedStorage<8, 8, uint64> mSize;
36 // NOLINTEND
37
38public:
39 // member functions
40 // NOLINTBEGIN
41 MCFOLD ::std::optional<::Gameface::ResponseResourceRange::RangeInBytes> const& getRangeInBytes() const;
42
43 MCFOLD uint64 getSize() const;
44
45 MCFOLD ::Gameface::ResponseResourceRange::Status getStatus() const;
46 // NOLINTEND
47
48public:
49 // static functions
50 // NOLINTBEGIN
51 MCAPI static ::Gameface::ResponseResourceRange makeOkResponseRange(uint64 start, uint64 end, uint64 size);
52
53 MCAPI static ::Gameface::ResponseResourceRange
54 makePartialContentResponseRange(uint64 start, uint64 end, uint64 size);
55
56 MCAPI static ::Gameface::ResponseResourceRange makeRangeNotSatisfiableResponse(uint64 size);
57 // NOLINTEND
58};
59
60} // namespace Gameface
Definition ResponseResourceRange.h:7
Definition ResponseResourceRange.h:17