📄 attributes.vb
字号:
Imports System<AttributeUsage(AttributeTargets.All, AllowMultiple:=True)> _Public Class AuthorAttribute Inherits Attribute Public Name As String Public No As Integer Public Sub New(ByVal Name As String) Me.Name = Name End Sub Public Sub New(ByVal Name As Integer) Me.Name = Name.toString() End SubEnd Class<AttributeUsage(AttributeTargets.All)> _Public Class PublicationAttribute Inherits Attribute Public Name As Object Public Sub New(ByVal Name As String) Me.Name = Name End SubEnd Class<Publication("Tata McGraw"), AuthorAttribute("Robin Cook", _ No:=47), Author(10)> _Public Class C1 <Author("John"), Publication("Tata McGraw")> _ Public Function S1() As Object End FunctionEnd ClassModule Test Function Main() As Integer End FunctionEnd Module
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -