Skip to content

liuact1986/MvvmLib

Repository files navigation

MvvmLib

Mvvm Library for .NET projects.

Documentation

Documentation

Support

If you enjoy what I build, please help support this project.

paypal

MvvmLib.Core [netstandard 2.0, net 4.5]

  • BindableBase, Editable, Validatable and ModelWrapper base classes for Models and ViewModels
  • DelegateCommand, AsyncCommand and CompositeCommand
  • EventAggregator : allows to subscribe, publish and filter messages
  • ChangeTracker: allows to track object changes.
  • Singleton
  • SyncUtils Allows to sync lists and collections

MvvmLib.IoC (Dependency Injection) [netstandard 2.0, net 4.5]

  • Allows to register and resolve Type, Singleton, Instance, factory, values
  • Auto discover types and types for interfaces not registered
  • Inject properties and manage circular references
  • Attributes: PreferredConstructor, PreferredImplementation (for interfaces), Dependency (for properties)

MvvmLib.Wpf (Navigation) [net 4.5]

  • NavigationSource: source for ContentControls
  • SharedSource: source for ItemsControls, Selectors (ListBox, TabControl, etc.)
  • NavigationManager: allows to manage NavigationSources and SharedSources
  • ListCollectionViewEx: allows to browse, filter, sort, group, add, edit with lists and collections.
  • PagedSource: paging for DataGrid, etc.
  • Command providers: NavigationSourceCommands, NavigationSourceContainerCommands, SharedSourceCommands, ListCollectionViewCommands, PagedSourceCommands
  • INavigationAware: allows view models to be notified on navigate
  • ICanActivate, ICanDeactivate: allow to cancel navigation
  • IIsSelected, ISelectable, SelectionSyncBehavior: allow to select a view
  • AnimatingContentControl, TransitioningContentControl, TransitioningItemsControl: allow to animate content
  • Triggers, TriggerActions and Behaviors: EventTrigger, DataTrigger, CallMethodeAction, SelectionSyncBehavior, EventToCommandBehavior,EventToMethodBehavior, etc.
  • PropertyFilter and CompositeFilter: allow to generate predicates.
  • ViewModelLocator: allows to resolve ViewModel for views
  • IIsLoaded: allows to notify view model that the view is loaded for a view that use resolve view model attached property
  • BootstrapperBase: base class for Bootstrapper
  • ModuleManager: allows to manage modules/assemblies loaded "on demand"

MvvmLib.Windows (Navigation) [uwp]

  • NavigationManager: allows to create and manage navigation services
  • FrameNavigationService: allows to navigate, go back, go forward, cancel navigation and notify viewmodel
  • ViewModelLocator: allows to resolve ViewModel for views
  • INavigatable: allows the view models to be notified on navigate
  • IDeactivatable: allows to cancel navigation
  • ILoadedEventListener: allows to be notified from view model when the view is loaded
  • BackRequestManager: allows to show the back button in title bar
  • BootstrapperBase: bootstrapper base class

MvvmLib.XF (Navigation) [Xamarin]

  • NavigationManager: allows to create and manage navigation services
  • PageNavigationService: allows to push, push modal, pop, pop modal, pop to root, handle system go back, cancel navigation and notify viewmodel
  • ViewModelLocator: allows to resolve ViewModel for views
  • INavigatable: allows the view models to be notified on navigate
  • IActivatable, IDeactivatable: allow to cancel navigation
  • INavigationParameterKnowledge: allows to store navigation parameter in the view model for system go back
  • IPageKnowledge: allows to receive in view model the page
  • DialogService: allows to display alerts and action sheets
  • BootstrapperBase: bootstrapper base class
  • EventToCommandBehavior and BehaviorBase

MvvmLib.Adaptive.Wpf [net 4.5]

  • BreakpointBinder: allows to bind controls and make the page "responsive"
  • BreakpointListener: allows to define a list of breakpoints and be notified on current breakpoint changed

MvvmLib.Adaptive.Windows [uwp]

  • BreakpointBinder: allows to bind controls and make the page "responsive"
  • BreakpointListener: allows to define a list of breakpoints and be notified on current breakpoint changed
  • ResponsiveGridView and ResponsiveVariableSizedGridView
  • BusyIndicator

Installation

Wpf

Package Required Description NuGet
MvvmLib.Core Yes BindableBase, Validation, commands, Messenger Nuget
MvvmLib.Wpf Yes Navigation with view model, view composition Nuget
MvvmLib.IoC No IoC Container or use Unity, Autofac, etc. Nuget
MvvmLib.Adaptive.Wpf No Make the view "responsive" Nuget
PM> Install-Package MvvmLib.Core
PM> Install-Package MvvmLib.Wpf
PM> Install-Package MvvmLib.IoC
PM> Install-Package MvvmLib.Adaptive.Wpf

Uwp

Package Required Description NuGet
MvvmLib.Core Yes BindableBase, Validation, commands, Messenger Nuget
MvvmLib.Windows Yes Navigation with view model Nuget
MvvmLib.IoC No IoC Container or use Unity, Autofac, etc. Nuget
MvvmLib.Adaptive.Windows No Make the page "responsive" Nuget
PM> Install-Package MvvmLib.Core
PM> Install-Package MvvmLib.Windows
PM> Install-Package MvvmLib.IoC
PM> Install-Package MvvmLib.Adaptive.Windows

Xamarin

Package Required Description NuGet
MvvmLib.Core No BindableBase, Validation, commands, Messenger Nuget
MvvmLib.XF Yes Navigation with view model Nuget
MvvmLib.IoC No IoC Container or use Unity, Autofac, etc. Nuget
PM> Install-Package MvvmLib.Core
PM> Install-Package MvvmLib.XF
PM> Install-Package MvvmLib.IoC