private void ExtractVariables() { _variables.Clear(); MatchCollection matches = Regex.Matches(Source, FLASH_VAR_PATTERN, RegexOptions.Multiline); foreach (Match match in matches) { string value = match.Groups["value"].Value; string variable = match.Groups["variable"].Value; if (value.Contains("\\/")) { value = value.Replace("\\/", "/"); } _variables[variable] = value; } Hotel = HotelEndPoint.GetHotel(InfoHost); }
public static Task <HProfile> GetProfileAsync(string uniqueId) => ReadContentAsync <HProfile>(HotelEndPoint.GetHotel(uniqueId).ToUri(), $"/api/public/users/{uniqueId}/profile");
public static async Task <HProfile> GetProfileAsync(string uniqueId) => HProfile.Create(await ReadContentAsync <string>(HotelEndPoint.GetHotel(uniqueId).ToUri(), $"/api/public/users/{uniqueId}/profile"));
public override HHotel Read(ref Utf8JsonReader reader, Type typeToConvert, JsonSerializerOptions options) { return(reader.TokenType == JsonTokenType.String ? HotelEndPoint.GetHotel(reader.GetString()) : HHotel.Unknown); }