|
@@ -21,7 +21,7 @@ public:
|
|
|
virtual ~MimeData() = default;
|
|
|
|
|
|
ByteBuffer data(StringView mime_type) const { return m_data.get(mime_type).value_or({}); }
|
|
|
- void set_data(DeprecatedString const& mime_type, ByteBuffer&& data) { m_data.set(mime_type, move(data)); }
|
|
|
+ void set_data(String const& mime_type, ByteBuffer&& data) { m_data.set(mime_type, move(data)); }
|
|
|
|
|
|
bool has_format(StringView mime_type) const { return m_data.contains(mime_type); }
|
|
|
Vector<DeprecatedString> formats() const;
|
|
@@ -36,16 +36,16 @@ public:
|
|
|
Vector<URL> urls() const;
|
|
|
ErrorOr<void> set_urls(Vector<URL> const&);
|
|
|
|
|
|
- HashMap<DeprecatedString, ByteBuffer> const& all_data() const { return m_data; }
|
|
|
+ HashMap<String, ByteBuffer> const& all_data() const { return m_data; }
|
|
|
|
|
|
private:
|
|
|
MimeData() = default;
|
|
|
- explicit MimeData(HashMap<DeprecatedString, ByteBuffer> const& data)
|
|
|
+ explicit MimeData(HashMap<String, ByteBuffer> const& data)
|
|
|
: m_data(data.clone().release_value_but_fixme_should_propagate_errors())
|
|
|
{
|
|
|
}
|
|
|
|
|
|
- HashMap<DeprecatedString, ByteBuffer> m_data;
|
|
|
+ HashMap<String, ByteBuffer> m_data;
|
|
|
};
|
|
|
|
|
|
StringView guess_mime_type_based_on_filename(StringView);
|