Imports System.ComponentModel

Public Class Alumno
  Implements INotifyPropertyChanged
  Private _idAlumno As Integer
  Public Property IdAlumno() As Integer
    Get
      Return _idAlumno
    End Get
    Set(value As Integer)
      _idAlumno = value
      OnPropertyChanged(New PropertyChangedEventArgs("IdAlumno"))
    End Set
  End Property

  Private _listaAsignaturas As List(Of Asignatura)
  Public Property ListaAsignaturas() As List(Of Asignatura)
    Get
      Return _listaAsignaturas
    End Get
    Set(value As List(Of Asignatura))
      _listaAsignaturas = value
      OnPropertyChanged(New PropertyChangedEventArgs("ListaAsignaturas"))
    End Set
  End Property

  Public Event PropertyChanged As PropertyChangedEventHandler _
    Implements INotifyPropertyChanged.PropertyChanged

  Public Sub OnPropertyChanged(e As PropertyChangedEventArgs)
    RaiseEvent PropertyChanged(Me, e)
    ' generar evento
  End Sub

  Public Sub New()
    IdAlumno = 0
    ListaAsignaturas = New List(Of Asignatura)()
  End Sub

  Public Sub New(id As Integer, lista As List(Of Asignatura))
    IdAlumno = id
    ListaAsignaturas = lista
  End Sub
End Class
