1
0
mirror of https://github.com/ppy/osu.git synced 2024-11-15 21:57:25 +08:00
osu-lazer/osu.Game/Beatmaps/IOnlineBeatmapMetadataSource.cs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

33 lines
1.3 KiB
C#
Raw Normal View History

// 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.
using System;
namespace osu.Game.Beatmaps
{
/// <summary>
2023-05-08 01:18:59 +08:00
/// Unifying interface for sources of <see cref="OnlineBeatmapMetadata"/>.
/// </summary>
public interface IOnlineBeatmapMetadataSource : IDisposable
{
/// <summary>
/// Whether this source can currently service lookups.
/// </summary>
bool Available { get; }
/// <summary>
/// Looks up the online metadata for the supplied <paramref name="beatmapInfo"/>.
/// </summary>
2023-05-07 23:49:31 +08:00
/// <param name="beatmapInfo">The <see cref="BeatmapInfo"/> to look up.</param>
/// <param name="onlineMetadata">
/// An <see cref="OnlineBeatmapMetadata"/> instance if the lookup is successful.
/// <see langword="null"/> if a mismatch between the local instance and the looked-up data was detected.
/// The returned value is only valid if the return value of the method is <see langword="true"/>.
/// </param>
/// <returns>
2023-05-07 23:49:31 +08:00
/// Whether the lookup was performed.
/// </returns>
2023-05-07 23:49:31 +08:00
bool TryLookup(BeatmapInfo beatmapInfo, out OnlineBeatmapMetadata? onlineMetadata);
}
}