-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathBug.vb
More file actions
58 lines (44 loc) · 1.32 KB
/
Bug.vb
File metadata and controls
58 lines (44 loc) · 1.32 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
Imports System.Collections.Generic
Namespace Solution
Public Class Bug
Private idField As Integer
Public Property Id As Integer
Get
Return idField
End Get
Set(ByVal value As Integer)
idField = value
End Set
End Property
Private nameField As String
Public Property Name As String
Get
Return nameField
End Get
Set(ByVal value As String)
nameField = value
End Set
End Property
Private statusField As Integer
Public Property Status As Integer
Get
Return statusField
End Get
Set(ByVal value As Integer)
statusField = value
End Set
End Property
Const count As Integer = 10
Public Shared Function GetBugList() As List(Of Bug)
Dim result As List(Of Bug) = New List(Of Bug)(count)
For i As Integer = 0 To count - 1
Dim st As Bug = New Bug()
st.Name = "Bug" & i.ToString()
st.idField = i
st.Status = i Mod 3
result.Add(st)
Next
Return result
End Function
End Class
End Namespace