mirror of
https://github.com/RGBCube/serenity
synced 2025-07-26 23:47:45 +00:00
AK+Everywhere: Rename String to DeprecatedString
We have a new, improved string type coming up in AK (OOM aware, no null state), and while it's going to use UTF-8, the name UTF8String is a mouthful - so let's free up the String name by renaming the existing class. Making the old one have an annoying name will hopefully also help with quick adoption :^)
This commit is contained in:
parent
f74251606d
commit
6e19ab2bbc
2006 changed files with 11635 additions and 11636 deletions
|
@ -22,37 +22,37 @@ public:
|
|||
|
||||
virtual ~TimeZone() override = default;
|
||||
|
||||
[[nodiscard]] String const& identifier() const { return m_identifier; }
|
||||
[[nodiscard]] DeprecatedString const& identifier() const { return m_identifier; }
|
||||
[[nodiscard]] Optional<OffsetType> const& offset_nanoseconds() const { return m_offset_nanoseconds; }
|
||||
|
||||
void set_identifier(String identifier) { m_identifier = move(identifier); };
|
||||
void set_identifier(DeprecatedString identifier) { m_identifier = move(identifier); };
|
||||
void set_offset_nanoseconds(OffsetType offset_nanoseconds) { m_offset_nanoseconds = offset_nanoseconds; };
|
||||
|
||||
private:
|
||||
explicit TimeZone(Object& prototype);
|
||||
|
||||
// 11.5 Properties of Temporal.TimeZone Instances, https://tc39.es/proposal-temporal/#sec-properties-of-temporal-timezone-instances
|
||||
String m_identifier; // [[Identifier]]
|
||||
DeprecatedString m_identifier; // [[Identifier]]
|
||||
Optional<OffsetType> m_offset_nanoseconds; // [[OffsetNanoseconds]]
|
||||
};
|
||||
|
||||
bool is_available_time_zone_name(StringView time_zone);
|
||||
String canonicalize_time_zone_name(String const& time_zone);
|
||||
ThrowCompletionOr<TimeZone*> create_temporal_time_zone(VM&, String const& identifier, FunctionObject const* new_target = nullptr);
|
||||
DeprecatedString canonicalize_time_zone_name(DeprecatedString const& time_zone);
|
||||
ThrowCompletionOr<TimeZone*> create_temporal_time_zone(VM&, DeprecatedString const& identifier, FunctionObject const* new_target = nullptr);
|
||||
ISODateTime get_iso_parts_from_epoch(VM&, Crypto::SignedBigInteger const& epoch_nanoseconds);
|
||||
BigInt* get_named_time_zone_next_transition(VM&, StringView time_zone_identifier, BigInt const& epoch_nanoseconds);
|
||||
BigInt* get_named_time_zone_previous_transition(VM&, StringView time_zone_identifier, BigInt const& epoch_nanoseconds);
|
||||
String format_time_zone_offset_string(double offset_nanoseconds);
|
||||
String format_iso_time_zone_offset_string(double offset_nanoseconds);
|
||||
DeprecatedString format_time_zone_offset_string(double offset_nanoseconds);
|
||||
DeprecatedString format_iso_time_zone_offset_string(double offset_nanoseconds);
|
||||
ThrowCompletionOr<Object*> to_temporal_time_zone(VM&, Value temporal_time_zone_like);
|
||||
ThrowCompletionOr<double> get_offset_nanoseconds_for(VM&, Value time_zone, Instant&);
|
||||
ThrowCompletionOr<String> builtin_time_zone_get_offset_string_for(VM&, Value time_zone, Instant&);
|
||||
ThrowCompletionOr<DeprecatedString> builtin_time_zone_get_offset_string_for(VM&, Value time_zone, Instant&);
|
||||
ThrowCompletionOr<PlainDateTime*> builtin_time_zone_get_plain_date_time_for(VM&, Value time_zone, Instant&, Object& calendar);
|
||||
ThrowCompletionOr<Instant*> builtin_time_zone_get_instant_for(VM&, Value time_zone, PlainDateTime&, StringView disambiguation);
|
||||
ThrowCompletionOr<Instant*> disambiguate_possible_instants(VM&, MarkedVector<Instant*> const& possible_instants, Value time_zone, PlainDateTime&, StringView disambiguation);
|
||||
ThrowCompletionOr<MarkedVector<Instant*>> get_possible_instants_for(VM&, Value time_zone, PlainDateTime&);
|
||||
ThrowCompletionOr<bool> time_zone_equals(VM&, Object& one, Object& two);
|
||||
|
||||
bool is_valid_time_zone_numeric_utc_offset_syntax(String const&);
|
||||
bool is_valid_time_zone_numeric_utc_offset_syntax(DeprecatedString const&);
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue