|
| virtual async Task | SaveAsync (object sender, ExecuteEventArgs e) |
| | Saves the Model, first committing changes if ManagedObjectLifetime is true.
|
| virtual void | Cancel (object sender, ExecuteEventArgs e) |
| | Cancels changes made to the model if ManagedObjectLifetime is true.
|
| virtual void | AddNew (object sender, ExecuteEventArgs e) |
| | Adds a new item to the Model (if it is a collection).
|
| virtual void | Remove (object sender, ExecuteEventArgs e) |
| | Removes an item from the Model (if it is a collection).
|
| virtual void | Delete (object sender, ExecuteEventArgs e) |
| | Marks the Model for deletion (if it is an editable root object).
|
| virtual async Task< T?> | RefreshAsync< F > (Func< Task< T?> > factory) |
| | Creates or retrieves a new instance of the Model by invoking an action.
|
| virtual async Task< T?> | SaveAsync () |
| | Saves the Model, first committing changes if ManagedObjectLifetime is true.
|
|
| static readonly DependencyProperty | ModelProperty |
| | Gets or sets the Model object.
|
| static readonly DependencyProperty | ManageObjectLifetimeProperty |
| | Gets or sets a value indicating whether the ViewModel should automatically managed the lifetime of the Model.
|
| virtual async Task< T?> | DoSaveAsync (ISavable? cloned) |
| | Override to provide custom Model save behavior.
|
| virtual void | DoCancel () |
| | Cancels changes made to the model if ManagedObjectLifetime is true.
|
| virtual object | DoAddNew () |
| | Adds a new item to the Model (if it is a collection).
|
| virtual void | DoRemove (object? item) |
| | Removes an item from the Model (if it is a collection).
|
| virtual void | DoDelete () |
| | Marks the Model for deletion (if it is an editable root object).
|
| virtual void | OnModelChanged (T? oldValue, T? newValue) |
| | Invoked when the Model changes, allowing event handlers to be unhooked from the old object and hooked on the new object.
|
| void | UnhookChangedEvents (T? model) |
| | Unhooks changed event handlers from the model.
|
| virtual void | OnSetProperties () |
| | Override this method to hook into to logic of setting properties when model is changed or edited.
|
| virtual void | OnPropertyChanged (string propertyName) |
| | Raise the PropertyChanged event.
|
| T? | Model [get, set] |
| | Gets or sets the Model object.
|
| bool | ManageObjectLifetime [get, set] |
| | Gets or sets a value indicating whether the ViewManageObjectLifetime should automatically managed the lifetime of the ManageObjectLifetime.
|
| bool | IsBusy [get, protected set] |
| | Gets a value indicating whether this object is executing an asynchronous process.
|
| virtual bool | IsDirty [get, protected set] |
| | Gets a value indicating whether the Model has been changed.
|
| virtual bool | IsValid [get, protected set] |
| | Gets a value indicating whether the Model is currently valid (has no broken rules).
|
| virtual bool | CanSave [get, protected set] |
| | Gets a value indicating whether the Model can currently be saved.
|
| virtual bool | CanCancel [get, protected set] |
| | Gets a value indicating whether the Model can currently be canceled.
|
| virtual bool | CanCreate [get, protected set] |
| | Gets a value indicating whether an instance of the Model can currently be created.
|
| virtual bool | CanDelete [get, protected set] |
| | Gets a value indicating whether the Model can currently be deleted.
|
| virtual bool | CanFetch [get, protected set] |
| | Gets a value indicating whether an instance of the Model can currently be retrieved.
|
| virtual bool | CanRemove [get, protected set] |
| | Gets a value indicating whether the Model can currently be removed.
|
| virtual bool | CanAddNew [get, protected set] |
| | Gets a value indicating whether the Model can currently be added.
|
| virtual bool | CanCreateObject [get, protected set] |
| | Gets a value indicating whether the current user is authorized to create a Model.
|
| virtual bool | CanGetObject [get, protected set] |
| | Gets a value indicating whether the current user is authorized to retrieve a Model.
|
| virtual bool | CanEditObject [get, protected set] |
| | Gets a value indicating whether the current user is authorized to save (insert or update a Model.
|
| virtual bool | CanDeleteObject [get, protected set] |
| | Gets a value indicating whether the current user is authorized to delete a Model.
|
| PropertyChangedEventHandler? | ModelPropertyChanged |
| | Event raised when a property on the Model changes.
|
| Action< object, ChildChangedEventArgs >? | ModelChildChanged |
| | Event raised when a child of the Model changes.
|
| Action< object, NotifyCollectionChangedEventArgs >? | ModelCollectionChanged |
| | Event raised the Model changes and is a collection.
|
| PropertyChangedEventHandler? | PropertyChanged |
| | Event raised when a property changes.
|
Base class used to create ViewModel objects, with pre-existing verbs for use by InvokeMethod or Invoke.
- Template Parameters
-
| T | Type of the Model object. |