Compartilhar via


RequestChecker.ReportViolation Method (String, String, HttpStatusCode)

 

Reports a violation by throwing a System.ServiceModel.Web.WebFaultException.

Namespace:   Microsoft.WindowsServerSolutions.WebApi.Framework
Assembly:  Wssg.WebApi.Framework (in Wssg.WebApi.Framework.dll)

Syntax

public static void ReportViolation(
    string paramName,
    string errorMsg,
    HttpStatusCode statusCode
)
public:
static void ReportViolation(
    String^ paramName,
    String^ errorMsg,
    HttpStatusCode statusCode
)
Public Shared Sub ReportViolation (
    paramName As String,
    errorMsg As String,
    statusCode As HttpStatusCode
)

Parameters

  • paramName
    Type: System.String

    The name of the parameter to check.

  • errorMsg
    Type: System.String

    The error message to add to the web fault exception.

See Also

RequestChecker Class
Microsoft.WindowsServerSolutions.WebApi.Framework Namespace

Return to top