Imports System.Collections.ObjectModel
Imports System.ComponentModel

Public Class Asignaturas
  Implements INotifyPropertyChanged
  Private _tipo As String
  ' Obligatoria, Optativa
  Public Property Tipo() As String
    Get
      Return _tipo
    End Get
    Set(value As String)
      _tipo = value
      OnPropertyChanged(New PropertyChangedEventArgs("Tipo"))
    End Set
  End Property

  Private _listaAsignaturas As ObservableCollection(Of Asignatura)
  Public Property ListaAsignaturas() As ObservableCollection(Of Asignatura)
    Get
      Return _listaAsignaturas
    End Get
    Set(value As ObservableCollection(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()
    Tipo = ""
    ListaAsignaturas = New ObservableCollection(Of Asignatura)()
  End Sub

  Public Sub New(tipo__1 As String, lista As ObservableCollection(Of Asignatura))
    Tipo = tipo__1
    ListaAsignaturas = lista
  End Sub
End Class
