ParenthesizePropertyNameAttribute 类

定义

指示关联属性的名称在“属性”窗口中显示时是否带有括号。 此类不能被继承。

public ref class ParenthesizePropertyNameAttribute sealed : Attribute
[System.AttributeUsage(System.AttributeTargets.All)]
public sealed class ParenthesizePropertyNameAttribute : Attribute
public sealed class ParenthesizePropertyNameAttribute : Attribute
[<System.AttributeUsage(System.AttributeTargets.All)>]
type ParenthesizePropertyNameAttribute = class
    inherit Attribute
type ParenthesizePropertyNameAttribute = class
    inherit Attribute
Public NotInheritable Class ParenthesizePropertyNameAttribute
Inherits Attribute
继承
ParenthesizePropertyNameAttribute
属性

注解

ParenthesizePropertyNameAttributeNeedParenthesis值为 的 true 向属性窗口指示关联的属性应在其名称周围用括号显示。 属性窗口在字母顺序模式下,在列表顶部附近显示一个属性,其名称周围带有括号;如果属性窗口处于分类模式,则显示在其类别顶部附近。

构造函数

ParenthesizePropertyNameAttribute()

初始化 ParenthesizePropertyNameAttribute 类的新实例,该实例指示关联属性显示时不应带括号。

ParenthesizePropertyNameAttribute(Boolean)

通过使用指定值来指示该特性显示时是否带有括号,初始化 ParenthesizePropertyNameAttribute 类的新实例。

字段

Default

用默认值(该值指示关联的属性显示时不应带有括号)初始化 ParenthesizePropertyNameAttribute 类的新实例。 此字段为只读。

属性

NeedParenthesis

获取一个值,该值指示在“属性”窗口中显示属性的名称时是否带有括号。

TypeId

在派生类中实现时,获取此 Attribute 的唯一标识符。

(继承自 Attribute)

方法

Equals(Object)

将指定的对象与此对象进行比较并测试是否相等。

GetHashCode()

获取此对象的哈希代码。

GetType()

获取当前实例的 Type

(继承自 Object)
IsDefaultAttribute()

获取一个值,该值指示该特性的当前值是否为该特性的默认值。

IsDefaultAttribute()

在派生类中重写时,指示此实例的值是否是派生类的默认值。

(继承自 Attribute)
Match(Object)

当在派生类中重写时,返回一个指示此实例是否等于指定对象的值。

(继承自 Attribute)
MemberwiseClone()

创建当前 Object 的浅表副本。

(继承自 Object)
ToString()

返回表示当前对象的字符串。

(继承自 Object)

显式接口实现

_Attribute.GetIDsOfNames(Guid, IntPtr, UInt32, UInt32, IntPtr)

将一组名称映射为对应的一组调度标识符。

(继承自 Attribute)
_Attribute.GetTypeInfo(UInt32, UInt32, IntPtr)

检索对象的类型信息,然后可以使用该信息获取接口的类型信息。

(继承自 Attribute)
_Attribute.GetTypeInfoCount(UInt32)

检索对象提供的类型信息接口的数量(0 或 1)。

(继承自 Attribute)
_Attribute.Invoke(UInt32, Guid, UInt32, Int16, IntPtr, IntPtr, IntPtr, IntPtr)

提供对某一对象公开的属性和方法的访问。

(继承自 Attribute)

适用于