MaxLengthAttribute 建構函式

定義

初始化 MaxLengthAttribute 類別的新執行個體。

多載

名稱 Description
MaxLengthAttribute()

初始化 MaxLengthAttribute 類別的新執行個體。

MaxLengthAttribute(Int32)

根據參數MaxLengthAttribute初始化類別length的新實例。

MaxLengthAttribute()

來源:
MaxLengthAttribute.cs
來源:
MaxLengthAttribute.cs
來源:
MaxLengthAttribute.cs
來源:
MaxLengthAttribute.cs
來源:
MaxLengthAttribute.cs

初始化 MaxLengthAttribute 類別的新執行個體。

public:
 MaxLengthAttribute();
public MaxLengthAttribute();
[System.Diagnostics.CodeAnalysis.RequiresUnreferencedCode("Uses reflection to get the 'Count' property on types that don't implement ICollection. This 'Count' property may be trimmed. Ensure it is preserved.")]
public MaxLengthAttribute();
Public Sub New ()
屬性

備註

將使用資料庫所支援的最大允許長度。

適用於

MaxLengthAttribute(Int32)

來源:
MaxLengthAttribute.cs
來源:
MaxLengthAttribute.cs
來源:
MaxLengthAttribute.cs
來源:
MaxLengthAttribute.cs
來源:
MaxLengthAttribute.cs

根據參數MaxLengthAttribute初始化類別length的新實例。

public:
 MaxLengthAttribute(int length);
public MaxLengthAttribute(int length);
[System.Diagnostics.CodeAnalysis.RequiresUnreferencedCode("Uses reflection to get the 'Count' property on types that don't implement ICollection. This 'Count' property may be trimmed. Ensure it is preserved.")]
public MaxLengthAttribute(int length);
new System.ComponentModel.DataAnnotations.MaxLengthAttribute : int -> System.ComponentModel.DataAnnotations.MaxLengthAttribute
[<System.Diagnostics.CodeAnalysis.RequiresUnreferencedCode("Uses reflection to get the 'Count' property on types that don't implement ICollection. This 'Count' property may be trimmed. Ensure it is preserved.")>]
new System.ComponentModel.DataAnnotations.MaxLengthAttribute : int -> System.ComponentModel.DataAnnotations.MaxLengthAttribute
Public Sub New (length As Integer)

參數

length
Int32

陣列或字串資料的最大允許長度。

屬性

適用於