Table of Contents

ValidateParamsAttribute Class

Enables the validation of the parameters of service operations.

Remarks

Validation attributes, like Required or MaxLength, applied to the parameters, and to the members of class parameters, are only checked when this attribute is present. Apply it to a method to validate the parameters of that operation, or to the service contract interface to validate the parameters of all its operations. When validation fails, the request is answered with status code 400 and a detailed error message.

Syntax

Unit: XData.Service.Common

ValidateParamsAttribute = class(TCustomAttribute);

Constructors

Name Description
Create Creates the attribute.

Properties

Name Description
Enabled Indicates whether parameter validation is enabled.