Class DontBindAttribute
you can prevent one or more binding sources from supplying values for a dto property decorated with this attribute.
Inheritance
DontBindAttribute
Inherited Members
Namespace: FastEndpoints
Assembly: FastEndpoints.Attributes.dll
Syntax
[AttributeUsage(AttributeTargets.Property)]
public class DontBindAttribute : Attribute
Constructors
DontBindAttribute(Source)
specify a bitwise combination of binding sources to disable for the property.
Declaration
public DontBindAttribute(Source sources)
Parameters
Type | Name | Description |
---|---|---|
Source | sources |
Properties
BindingSources
gets the disabled binding sources.
Declaration
public Source BindingSources { get; set; }
Property Value
Type | Description |
---|---|
Source |
IsRequired
set to true if a validation error should be thrown when the request doesn't have a value for this property.
Declaration
public bool IsRequired { get; set; }
Property Value
Type | Description |
---|---|
bool |