FastMoq
Search Results for

    Show / Hide Table of Contents

    Class FastArg

    Provider-neutral argument matcher helpers for FastMoq expression-based setup and verification flows.

    Inheritance
    object
    FastArg
    Inherited Members
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: FastMoq.Providers
    Assembly: FastMoq.Abstractions.dll
    Syntax
    public static class FastArg

    Methods

    AnyExpression<T>()

    Matches any expression argument of type Expression<Func<T, bool>>.

    Declaration
    public static Expression<Func<T, bool>> AnyExpression<T>()
    Returns
    Type Description
    Expression<Func<T, bool>>
    Type Parameters
    Name Description
    T
    Remarks

    This is the provider-neutral replacement for older wildcard expression helpers such as Mocker.BuildExpression<T>() in new code.

    Any<T>()

    Matches any argument of type T.

    Declaration
    public static T Any<T>()
    Returns
    Type Description
    T
    Type Parameters
    Name Description
    T
    Remarks

    Use this only inside FastMoq-supported expression-based setup or verification APIs.

    IsNotNull<T>()

    Matches a non-null argument.

    Declaration
    public static T IsNotNull<T>()
    Returns
    Type Description
    T
    Type Parameters
    Name Description
    T

    IsNull<T>()

    Matches a null argument.

    Declaration
    public static T IsNull<T>()
    Returns
    Type Description
    T
    Type Parameters
    Name Description
    T

    Is<T>(Expression<Func<T, bool>>)

    Matches an argument when the supplied predicate returns true.

    Declaration
    public static T Is<T>(Expression<Func<T, bool>> predicate)
    Parameters
    Type Name Description
    Expression<Func<T, bool>> predicate

    The predicate used to evaluate the runtime argument.

    Returns
    Type Description
    T
    Type Parameters
    Name Description
    T
    In this article
    Back to top
    Generated 2026-04-29 03:53 UTC