Table of Contents

Class ViewModelDefinitionAttribute<TViewModel>

Namespace
Blazing.Mvvm.ComponentModel
Assembly
Blazing.Mvvm.Base.dll

Specifies metadata for a generic ViewModel to control its registration in the dependency injection container. Supports configuration of service lifetime, optional keyed registration, and DI registration for a specific service type.

[AttributeUsage(AttributeTargets.Class, AllowMultiple = true)]
public sealed class ViewModelDefinitionAttribute<TViewModel> : ViewModelDefinitionAttribute, IViewModelGenericAttributeDefinition where TViewModel : IViewModelBase

Type Parameters

TViewModel

The type the ViewModel implements that should be used for DI registration. Must implement IViewModelBase.

Inheritance

Implements

Inherited Members

Properties

ViewModelType

Gets the service type used for DI registration. This is the type specified by TViewModel.

public Type ViewModelType { get; }

Property Value

Type