Generics sample

Imports System.Collections.Generic
Public Class mySession

Private _sessionGUID As String
Public Property sessionGUID() As String
Get
Return _sessionGUID
End Get
Set(ByVal value As String)
_sessionGUID = value
End Set
End Property
Private _sdate As String
Public Property sdate() As DateTime
Get
Return _sdate
End Get
Set(ByVal value As DateTime)
_sdate = value
End Set
End Property
End Class
									
Public Class mySessions
Private m_col As List(Of mySession)

Public Sub New()
m_col = New List(Of mySession)
End Sub
Protected Overrides Sub Finalize()
MyBase.Finalize()
End Sub

Public Sub AddSession(ByVal var As mySession)
m_col.Add(var)
End Sub
Public Function Item(ByVal Index As Integer) As mySession
Return CType(m_col.Item(Index), mySession)
End Function
Public Function Count() As Integer
Return m_col.Count
End Function

End Class