genericmethod5.vb

来自「大名鼎鼎的mono是.NET平台的跨平台(支持linux」· VB 代码 · 共 33 行

VB
33
字号
Imports SystemImports System.CollectionsImports System.ReflectionNamespace GenericMethod5    Interface BaseObject    End Interface    Class Statement        Implements BaseObject    End Class    Class ForEachStatement        Inherits Statement    End Class    Class ForStatement        Inherits Statement    End Class    Class T        Function FindFirstParent(Of T1, T2)() As BaseObject        End Function        Sub Test()            Dim m_ContainingStatement As Statement            m_ContainingStatement = CType(Me.FindFirstParent(Of ForEachStatement, ForStatement)(), Statement)        End Sub    End Class    Class Test        Shared Function Main() As Integer        End Function    End ClassEnd Namespace

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?