로딩
요청 처리 중입니다...

[WPF_DevExpress] ViewModel 01.BindableBase 클래스

 [WPF_DevExpress] ViewModel 01.BindableBase 클래스

해당 글은 DevExpress 18.2 버전을 기준으로 작성되었습니다. BindableBase 클래스는 INotifyPropertyChanged 인터페이스를 구현하여 최소한의 코딩으로 바인딩 가능한 속성을 선언하는 API를 제공한다.

바인딩 가능한 속성 바인딩 가능한 속성을 선언하려면 다음을 수행한다. DevExpress.Mvvm을 using한다.

ViewModel에서 BindableBase 클래스를 상속한다. 바인딩하려는 속성의 getter 및 setter에서 GetValue 및 SetValue 메소드를 사용한다. using DevExpress.Mvvm; namespace ViewModelStudy { class ViewModel : BindableBase { public string FirstName { get { return GetValue(nameof(FirstName)); } set { SetValue(value, nameof(FirstName)); } } }...

# BindableBase # DevExpress # GetValue # MVVM프레임워크 # SetValue # ViewModel # WPF # 데브익스프레스