我有一个Class ABC
. 我想为它写两个属性。我已经在代码中提到了一个。另一个将是single dimensional array
.
Public Class ABC
Private m_Type As String
Private SomeArray........need to write a property for array which will be of type `int`
Public Property Type() As String
Get
Return m_Type
End Get
Set(ByVal value As String)
m_Type = value
End Set
End Property
End Class
我不确定如何为数组定义一个可以在List(Of ABC)
. 数组的属性可以是只读数组,就像我一样
硬编码它的数据。
所以基本上当我这样做时,
Dim SomeList As New List(Of ABC)
在for循环中我需要这样的东西,
SomeList.Item(index).SomeArray......this will give me all the items inside the array