Rename to IHasDuration

This commit is contained in:
Dean Herbert
2020-05-27 12:38:39 +09:00
parent b8e0a6f127
commit cbd563e80b
27 changed files with 60 additions and 48 deletions

View File

@ -175,10 +175,10 @@ namespace osu.Game.Rulesets.Objects
/// Returns the end time of this object.
/// </summary>
/// <remarks>
/// This returns the <see cref="IHasEndTime.EndTime"/> where available, falling back to <see cref="HitObject.StartTime"/> otherwise.
/// This returns the <see cref="IHasDuration.EndTime"/> where available, falling back to <see cref="HitObject.StartTime"/> otherwise.
/// </remarks>
/// <param name="hitObject">The object.</param>
/// <returns>The end time of this object.</returns>
public static double GetEndTime(this HitObject hitObject) => (hitObject as IHasEndTime)?.EndTime ?? hitObject.StartTime;
public static double GetEndTime(this HitObject hitObject) => (hitObject as IHasDuration)?.EndTime ?? hitObject.StartTime;
}
}