1
0
mirror of https://github.com/ppy/osu.git synced 2024-11-14 15:57:24 +08:00
osu-lazer/osu.Game/Online/API/APIMessagesRequest.cs
2022-06-17 16:37:17 +09:00

31 lines
774 B
C#

// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
// See the LICENCE file in the repository root for full licence text.
#nullable disable
using System.Collections.Generic;
using osu.Framework.IO.Network;
using osu.Game.Online.Chat;
namespace osu.Game.Online.API
{
public abstract class APIMessagesRequest : APIRequest<List<Message>>
{
private readonly long? sinceId;
protected APIMessagesRequest(long? sinceId)
{
this.sinceId = sinceId;
}
protected override WebRequest CreateWebRequest()
{
var req = base.CreateWebRequest();
if (sinceId.HasValue) req.AddParameter(@"since", sinceId.Value.ToString());
return req;
}
}
}