Skip to content

Commit fd52119

Browse files
committed
LibWeb: Add getters and setters for Fetch::Header's members
1 parent dc6fb43 commit fd52119

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

Userland/Libraries/LibWeb/Fetch/Headers.h

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,14 @@ class Headers final : public Bindings::PlatformObject {
3535

3636
virtual ~Headers() override;
3737

38+
[[nodiscard]] Infrastructure::HeaderList& header_list() { return m_header_list; }
39+
[[nodiscard]] Infrastructure::HeaderList const& header_list() const { return m_header_list; }
40+
void set_header_list(Infrastructure::HeaderList header_list) { m_header_list = move(header_list); }
41+
42+
[[nodiscard]] Guard guard() const { return m_guard; }
43+
void set_guard(Guard guard) { m_guard = guard; }
44+
45+
// JS API functions
3846
WebIDL::ExceptionOr<void> append(Infrastructure::Header);
3947
WebIDL::ExceptionOr<void> append(String const& name, String const& value);
4048
WebIDL::ExceptionOr<void> delete_(String const& name);

0 commit comments

Comments
 (0)