summaryrefslogtreecommitdiff
path: root/Userland/Libraries/LibWeb/HTML/Scripting/Script.h
blob: 10a189ccba8f3bb9a3ec293c5415b09a7b3ff0be (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
/*
 * Copyright (c) 2021, Andreas Kling <kling@serenityos.org>
 *
 * SPDX-License-Identifier: BSD-2-Clause
 */

#pragma once

#include <AK/RefCounted.h>
#include <AK/URL.h>

namespace Web::HTML {

// https://html.spec.whatwg.org/multipage/webappapis.html#concept-script
class Script : public RefCounted<Script> {
public:
    virtual ~Script();

    URL const& base_url() const { return m_base_url; }
    String const& filename() const { return m_filename; }

protected:
    Script(URL base_url, String filename);

private:
    URL m_base_url;
    String m_filename;
};

}