Example #1
0
    /// <summary>
    ///     Match based one of the given method names
    /// </summary>
    /// <param name="value">The first name</param>
    /// <param name="values">Any additional names</param>
    /// <returns></returns>
    public RestfulApiMethodBuilder MatchName(string value, params string[] values)
    {
        _names             = new[] { value }.Concat(values).ToArray();
        _nameMatchBehavior = ApiConventionNameMatchBehavior.Exact;

        return(this);
    }
 public RestfulApiParameterMatcher(
     Index parameterIndex,
     ApiConventionNameMatchBehavior nameMatch,
     string[] names,
     ApiConventionTypeMatchBehavior typeMatch,
     INamedTypeSymbol?type
     )
 {
     ParameterIndex = parameterIndex;
     NameMatch      = nameMatch;
     Names          = names;
     TypeMatch      = typeMatch;
     Type           = type;
 }
Example #3
0
 /// <summary>
 /// Initializes a new instance of <see cref="ApiConventionNameMatchAttribute"/>.
 /// </summary>
 /// <param name="matchBehavior">The <see cref="ApiConventionNameMatchBehavior"/>.</param>
 public ApiConventionNameMatchAttribute(ApiConventionNameMatchBehavior matchBehavior)
 {
     MatchBehavior = matchBehavior;
 }