Browse Source

Apply suggestions from code review

Co-authored-by: Armano den Boef <68127614+Rozen4334@users.noreply.github.com>
pull/2136/head
Cenk Ergen GitHub 3 years ago
parent
commit
45ec61e0de
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 12 additions and 6 deletions
  1. +6
    -3
      src/Discord.Net.Core/Interactions/IRouteMatchContainer.cs
  2. +5
    -2
      src/Discord.Net.Core/Interactions/IRouteSegmentMatch.cs
  3. +1
    -1
      src/Discord.Net.Core/Interactions/RouteSegmentMatch.cs

+ 6
- 3
src/Discord.Net.Core/Interactions/IRouteMatchContainer.cs View File

@@ -3,17 +3,20 @@ using System.Collections.Generic;
namespace Discord
{
/// <summary>
/// Represents a container for temporarily storing CustomId wild card matches of a command name.
/// Represents a container for temporarily storing CustomId wild card matches of a component.
/// </summary>
public interface IRouteMatchContainer
{
/// <summary>
/// Gets the collection of the captured route segments.
/// Gets the collection of captured route segments in this container.
/// </summary>
/// <returns>
/// A collection of captured route segments.
///</returns>
IEnumerable<IRouteSegmentMatch> SegmentMatches { get; }

/// <summary>
/// Sets the <see cref="SegmentMatches"/> propert
/// Sets the <see cref="SegmentMatches"/> property of this container.
/// </summary>
/// <param name="segmentMatches">The collection of captured route segments.</param>
void SetSegmentMatches(IEnumerable<IRouteSegmentMatch> segmentMatches);


+ 5
- 2
src/Discord.Net.Core/Interactions/IRouteSegmentMatch.cs View File

@@ -1,13 +1,16 @@
namespace Discord
{
/// <summary>
/// Represents an object for storing CustomId a wild card match.
/// Represents an object for storing a CustomId wild card match.
/// </summary>
public interface IRouteSegmentMatch
{
/// <summary>
/// Gets the captured value.
/// Gets the captured value of this wild card match.
/// </summary>
/// <returns>
/// The value of this wild card.
/// </returns>
string Value { get; }
}
}

+ 1
- 1
src/Discord.Net.Core/Interactions/RouteSegmentMatch.cs View File

@@ -1,7 +1,7 @@
namespace Discord
{
/// <summary>
/// Represents an object for storing CustomId wild card matches.
/// Represents an object for storing a CustomId wild card match.
/// </summary>
internal record RouteSegmentMatch : IRouteSegmentMatch
{


Loading…
Cancel
Save