title: Search for Object in Generic List
body: <p>Is it possible to search for an object by one of its properties in a Generic List?</p>
  
  <pre><code>Public Class Customer
  
      Private _id As Integer
  
      Private _name As String
  
      Public Property ID() As Integer
          Get
              Return _id
          End Get
          Set
              _id = value
          End Set
      End Property
  
      Public Property Name() As String
          Get
              Return _name
          End Get
          Set
              _name = value
          End Set
      End Property
  
      Public Sub New(id As Integer, name As String)
          _id = id
          _name = name
      End Sub
  
  End Class
  </code></pre>
  
  <p>Then loading and searching</p>
  
  <pre><code>Dim list as new list(Of Customer)
  
  list.Add(New Customer(1,"A")
  
  list.Add(New Customer(2,"B")
  </code></pre>
  
  <p>How can I return customer object with id =1? Does this have to do with the "Predicate" in Generics?</p>
  
  <p>Note: I am doing this in VB.NET.</p>