C# 클래스 Catel.MVVM.Views.ViewToViewModelMappingHelper

Helper class to fix ViewToViewModelMapping for IView.
파일 보기 프로젝트 열기: Catel/Catel

Private Properties

프로퍼티 타입 설명
InitializeViewModel void
OnViewModelChanged void
OnViewModelContainerPropertyChanged void
OnViewModelPropertyChanged void
TransferValue void
UninitializeViewModel void
UninitializeViewToViewModelMappings void

공개 메소드들

메소드 설명
InitializeViewToViewModelMappings ( IViewModelContainer viewModelContainer ) : void

Initializes the ViewToViewModelMapping for the specified IViewModelContainer.

UninitializeViewToViewModelMappings ( IViewModelContainer viewModelContainer ) : void

Uninitializes the ViewToViewModelMapping for the specified IViewModelContainer.

ViewToViewModelMappingHelper ( IViewModelContainer viewModelContainer ) : System

Initializes a new instance of the ViewToViewModelMappingHelper class.

보호된 메소드들

메소드 설명
TransferValueFromViewModelToView ( IViewModel viewModel, string viewPropertyName, string viewModelPropertyName ) : void

Transfers the value from a view model property to the view property. This method does nothing when viewModel is null.

This method does not check the type of the properties. If the types are incorrect, an exception will be thrown by the .NET Framework.

TransferValueFromViewToViewModel ( IViewModel viewModel, string viewPropertyName, string viewModelPropertyName ) : void

Transfers the value from a view property to the view model property. This method does nothing when viewModel is null.

This method does not check the type of the properties. If the types are incorrect, an exception will be thrown by the .NET Framework.

비공개 메소드들

메소드 설명
InitializeViewModel ( IViewModel viewModel ) : void

Initializes the specified view model.

OnViewModelChanged ( object sender, EventArgs e ) : void

Called when the view model on the view model container has changed.

OnViewModelContainerPropertyChanged ( object sender, PropertyChangedEventArgs e ) : void

Called when a property on the view model container has changed.

OnViewModelPropertyChanged ( object sender, PropertyChangedEventArgs e ) : void

Called when a property on the view model has changed.

TransferValue ( object source, string sourcePropertyName, object target, string targetPropertyName ) : void

Transfers a value from the source property to the target property.

This method does not check the type of the properties. If the types are incorrect, an exception will be thrown by the .NET Framework.

UninitializeViewModel ( IViewModel viewModel ) : void

Uninitializes the specified view model.

UninitializeViewToViewModelMappings ( ) : void

Uninitializes the ViewToViewModelMapping for the registered IViewModelContainer.

메소드 상세

InitializeViewToViewModelMappings() 공개 정적인 메소드

Initializes the ViewToViewModelMapping for the specified IViewModelContainer.
The is null.
public static InitializeViewToViewModelMappings ( IViewModelContainer viewModelContainer ) : void
viewModelContainer IViewModelContainer The view model container to initialize the mappings for.
리턴 void

TransferValueFromViewModelToView() 보호된 메소드

Transfers the value from a view model property to the view property. This method does nothing when viewModel is null.
This method does not check the type of the properties. If the types are incorrect, an exception will be thrown by the .NET Framework.
The is null or whitespace. The is null or whitespace.
protected TransferValueFromViewModelToView ( IViewModel viewModel, string viewPropertyName, string viewModelPropertyName ) : void
viewModel IViewModel The view model.
viewPropertyName string Name of the view property.
viewModelPropertyName string Name of the view model property.
리턴 void

TransferValueFromViewToViewModel() 보호된 메소드

Transfers the value from a view property to the view model property. This method does nothing when viewModel is null.
This method does not check the type of the properties. If the types are incorrect, an exception will be thrown by the .NET Framework.
The is null or whitespace. The is null or whitespace.
protected TransferValueFromViewToViewModel ( IViewModel viewModel, string viewPropertyName, string viewModelPropertyName ) : void
viewModel IViewModel The view model.
viewPropertyName string Name of the view property.
viewModelPropertyName string Name of the view model property.
리턴 void

UninitializeViewToViewModelMappings() 공개 정적인 메소드

Uninitializes the ViewToViewModelMapping for the specified IViewModelContainer.
The is null.
public static UninitializeViewToViewModelMappings ( IViewModelContainer viewModelContainer ) : void
viewModelContainer IViewModelContainer The view model container the uninitialize the mappings for.
리턴 void

ViewToViewModelMappingHelper() 공개 메소드

Initializes a new instance of the ViewToViewModelMappingHelper class.
The is null.
public ViewToViewModelMappingHelper ( IViewModelContainer viewModelContainer ) : System
viewModelContainer IViewModelContainer The view model container.
리턴 System