/// <summary>
 /// Registers the view model with the model, so that the model can fire change notifications
 /// </summary>
 /// <param name="vm"></param>
 public void Register(BEGattVMBase <GattObjectType> vm)
 {
     lock (_viewModelInstances)
     {
         if (vm == null)
         {
             throw new ArgumentNullException("Tried to register a null-valued view-model to a model.");
         }
         _viewModelInstances.Add(vm);
     }
 }
 /// <summary>
 /// Unregisters the view model from the model
 /// </summary>
 /// <param name="vm"></param>
 public void UnregisterVMFromModel(BEGattVMBase <GattObjectType> vm)
 {
     lock (_viewModelInstances)
     {
         if (vm == null)
         {
             throw new ArgumentNullException("Tried to remove a null-valued view-model from a model");
         }
         if (_viewModelInstances.Contains(vm))
         {
             _viewModelInstances.Remove(vm);
         }
     }
 }