SlideShare ist ein Scribd-Unternehmen logo
1 von 18
MVVM with Kendo UI
BRUNO PESSANHA
MVVM
BRUNO PESSANHA – MVVM WITH KENDO UI
MVVM
BRUNO PESSANHA – MVVM WITH KENDO UI
Advantages Disadvantages
Facilitates easier parallel development of a UI and
the building blocks that power it
For simpler UIs, MVVM can be overkill.
Abstracts the View and thus reduces the quantity of
business logic (or glue) required in the code behind
it.
Whilst data-bindings can be declarative and nice to
work with, they can be harder to debug than
imperative code where we simply set breakpoints.
The ViewModel can be easier to unit test than
event-driven code.
Data-bindings in non-trivial applications can create
a lot of book-keeping. You also don’t want to end
up in a situation where bindings are heavier than
the objects being bound to.
The ViewModel (being more Model than View) can
be tested without concerns of UI automation and
interaction.
In larger applications, it can be more difficult to
design the ViewModel up front to get the necessary
amount of generalisation.
Kendo MVVM – Model
BRUNO PESSANHA – MVVM WITH KENDO UI
Data;
UI Independent;
State;
Written in code;
Represented by pure data.
Kendo MVVM – View
BRUNO PESSANHA – MVVM WITH KENDO UI
Kendo MVVM – View-Model
BRUNO PESSANHA – MVVM WITH KENDO UI
Kendo MVVM – Binding View to View-Model
BRUNO PESSANHA – MVVM WITH KENDO UI
Kendo MVVM – Binding View to View-Model
BRUNO PESSANHA – MVVM WITH KENDO UI
Kendo MVVM – Observable Array
BRUNO PESSANHA – MVVM WITH KENDO UI
Kendo MVVM – Getting a field value
BRUNO PESSANHA – MVVM WITH KENDO UI
Kendo MVVM – Getting a field value
BRUNO PESSANHA – MVVM WITH KENDO UI
Kendo MVVM – Setting a field value
BRUNO PESSANHA – MVVM WITH KENDO UI
Kendo MVVM – Calculated field
BRUNO PESSANHA – MVVM WITH KENDO UI
Kendo MVVM – Bindings
Attr Checked
Click Custom
Disabled Enabled
Events HTML
Invisible Source
Style Text
Value Visible
BRUNO PESSANHA – MVVM WITH KENDO UI
Kendo MVVM – Bindings – Attr
BRUNO PESSANHA – MVVM WITH KENDO UI
Kendo MVVM – Bindings – Source
BRUNO PESSANHA – MVVM WITH KENDO UI
Kendo MVVM – Bindings – Custom
BRUNO PESSANHA – MVVM WITH KENDO UI
References
 http://blogs.msdn.com/b/johngossman/archive/2005/10/08/478683.aspx
 http://msdn.microsoft.com/en-us/magazine/dd419663.aspx
 http://docs.telerik.com/kendo-ui/getting-started/framework/mvvm/overview
 http://demos.telerik.com/kendo-ui/mvvm/index
 http://en.wikipedia.org/wiki/Model_View_ViewModel
 http://blogs.msdn.com/b/johngossman/archive/2006/03/04/543695.aspx
BRUNO PESSANHA – MVVM WITH KENDO UI

Weitere ähnliche Inhalte

Ähnlich wie MVVM with Kendo UI

How I Accidentally Discovered MVVM
How I Accidentally Discovered MVVMHow I Accidentally Discovered MVVM
How I Accidentally Discovered MVVMBradford Dillon
 
Tales of Two Brothers
Tales of Two BrothersTales of Two Brothers
Tales of Two BrothersFiyaz Hasan
 
Cassandra Summit 2014: Apache Cassandra on Pivotal CloudFoundry
Cassandra Summit 2014: Apache Cassandra on Pivotal CloudFoundryCassandra Summit 2014: Apache Cassandra on Pivotal CloudFoundry
Cassandra Summit 2014: Apache Cassandra on Pivotal CloudFoundryDataStax Academy
 
SAP WEBDYNPRO ABAP TRAINING
SAP WEBDYNPRO ABAP TRAININGSAP WEBDYNPRO ABAP TRAINING
SAP WEBDYNPRO ABAP TRAININGSanthosh Sap
 
Model View Madness
Model View MadnessModel View Madness
Model View MadnessMike Wilcox
 
RESPONSIVE DESIGN AND THE MODERN WEB APPLICATION
RESPONSIVE DESIGN AND THE MODERN WEB APPLICATIONRESPONSIVE DESIGN AND THE MODERN WEB APPLICATION
RESPONSIVE DESIGN AND THE MODERN WEB APPLICATIONMorten Pedersen
 
Introduction to .NET MAUI
Introduction to .NET MAUIIntroduction to .NET MAUI
Introduction to .NET MAUIMoaid Hathot
 
Mvvw patterns
Mvvw patternsMvvw patterns
Mvvw patternseleksdev
 
Magnolia blossom-webinar
Magnolia blossom-webinarMagnolia blossom-webinar
Magnolia blossom-webinarbkraft
 
Tanzu Developer Connect Workshop - 06022022.pdf
Tanzu Developer Connect Workshop - 06022022.pdfTanzu Developer Connect Workshop - 06022022.pdf
Tanzu Developer Connect Workshop - 06022022.pdfGabrielaRodriguez182401
 
Vue.js Getting Started
Vue.js Getting StartedVue.js Getting Started
Vue.js Getting StartedMurat Doğan
 
Building an enterprise app in silverlight 4 and NHibernate
Building an enterprise app in silverlight 4 and NHibernateBuilding an enterprise app in silverlight 4 and NHibernate
Building an enterprise app in silverlight 4 and NHibernatebwullems
 
Architectural Design Pattern: Android
Architectural Design Pattern: AndroidArchitectural Design Pattern: Android
Architectural Design Pattern: AndroidJitendra Kumar
 
MVC From Beginner to Advance in Indian Style by - Indiandotnet
MVC From Beginner to Advance in Indian Style by - IndiandotnetMVC From Beginner to Advance in Indian Style by - Indiandotnet
MVC From Beginner to Advance in Indian Style by - IndiandotnetIndiandotnet
 
apidays Helsinki & North 2023 - Interface Contracts in Event-driven Microfron...
apidays Helsinki & North 2023 - Interface Contracts in Event-driven Microfron...apidays Helsinki & North 2023 - Interface Contracts in Event-driven Microfron...
apidays Helsinki & North 2023 - Interface Contracts in Event-driven Microfron...apidays
 
WordPress Mobile development - slides from WordCamp UK 2012
WordPress Mobile development - slides from WordCamp UK 2012WordPress Mobile development - slides from WordCamp UK 2012
WordPress Mobile development - slides from WordCamp UK 2012rachel_mccollin
 

Ähnlich wie MVVM with Kendo UI (20)

MVVM-C vs MVP
MVVM-C vs MVPMVVM-C vs MVP
MVVM-C vs MVP
 
How I Accidentally Discovered MVVM
How I Accidentally Discovered MVVMHow I Accidentally Discovered MVVM
How I Accidentally Discovered MVVM
 
Tales of Two Brothers
Tales of Two BrothersTales of Two Brothers
Tales of Two Brothers
 
Cassandra Summit 2014: Apache Cassandra on Pivotal CloudFoundry
Cassandra Summit 2014: Apache Cassandra on Pivotal CloudFoundryCassandra Summit 2014: Apache Cassandra on Pivotal CloudFoundry
Cassandra Summit 2014: Apache Cassandra on Pivotal CloudFoundry
 
Sap webdynpro abap training
Sap webdynpro abap trainingSap webdynpro abap training
Sap webdynpro abap training
 
SAP WEBDYNPRO ABAP TRAINING
SAP WEBDYNPRO ABAP TRAININGSAP WEBDYNPRO ABAP TRAINING
SAP WEBDYNPRO ABAP TRAINING
 
Model View Madness
Model View MadnessModel View Madness
Model View Madness
 
RESPONSIVE DESIGN AND THE MODERN WEB APPLICATION
RESPONSIVE DESIGN AND THE MODERN WEB APPLICATIONRESPONSIVE DESIGN AND THE MODERN WEB APPLICATION
RESPONSIVE DESIGN AND THE MODERN WEB APPLICATION
 
Android MVVM
Android MVVMAndroid MVVM
Android MVVM
 
Introduction to .NET MAUI
Introduction to .NET MAUIIntroduction to .NET MAUI
Introduction to .NET MAUI
 
Mvvw patterns
Mvvw patternsMvvw patterns
Mvvw patterns
 
Magnolia blossom-webinar
Magnolia blossom-webinarMagnolia blossom-webinar
Magnolia blossom-webinar
 
Tanzu Developer Connect Workshop - 06022022.pdf
Tanzu Developer Connect Workshop - 06022022.pdfTanzu Developer Connect Workshop - 06022022.pdf
Tanzu Developer Connect Workshop - 06022022.pdf
 
Vue.js Getting Started
Vue.js Getting StartedVue.js Getting Started
Vue.js Getting Started
 
Building an enterprise app in silverlight 4 and NHibernate
Building an enterprise app in silverlight 4 and NHibernateBuilding an enterprise app in silverlight 4 and NHibernate
Building an enterprise app in silverlight 4 and NHibernate
 
Architectural Design Pattern: Android
Architectural Design Pattern: AndroidArchitectural Design Pattern: Android
Architectural Design Pattern: Android
 
MVC From Beginner to Advance in Indian Style by - Indiandotnet
MVC From Beginner to Advance in Indian Style by - IndiandotnetMVC From Beginner to Advance in Indian Style by - Indiandotnet
MVC From Beginner to Advance in Indian Style by - Indiandotnet
 
Weavy CocoaHeads
Weavy CocoaHeadsWeavy CocoaHeads
Weavy CocoaHeads
 
apidays Helsinki & North 2023 - Interface Contracts in Event-driven Microfron...
apidays Helsinki & North 2023 - Interface Contracts in Event-driven Microfron...apidays Helsinki & North 2023 - Interface Contracts in Event-driven Microfron...
apidays Helsinki & North 2023 - Interface Contracts in Event-driven Microfron...
 
WordPress Mobile development - slides from WordCamp UK 2012
WordPress Mobile development - slides from WordCamp UK 2012WordPress Mobile development - slides from WordCamp UK 2012
WordPress Mobile development - slides from WordCamp UK 2012
 

Kürzlich hochgeladen

Chinsurah Escorts ☎️8617697112 Starting From 5K to 15K High Profile Escorts ...
Chinsurah Escorts ☎️8617697112  Starting From 5K to 15K High Profile Escorts ...Chinsurah Escorts ☎️8617697112  Starting From 5K to 15K High Profile Escorts ...
Chinsurah Escorts ☎️8617697112 Starting From 5K to 15K High Profile Escorts ...Nitya salvi
 
Define the academic and professional writing..pdf
Define the academic and professional writing..pdfDefine the academic and professional writing..pdf
Define the academic and professional writing..pdfPearlKirahMaeRagusta1
 
10 Trends Likely to Shape Enterprise Technology in 2024
10 Trends Likely to Shape Enterprise Technology in 202410 Trends Likely to Shape Enterprise Technology in 2024
10 Trends Likely to Shape Enterprise Technology in 2024Mind IT Systems
 
%in Stilfontein+277-882-255-28 abortion pills for sale in Stilfontein
%in Stilfontein+277-882-255-28 abortion pills for sale in Stilfontein%in Stilfontein+277-882-255-28 abortion pills for sale in Stilfontein
%in Stilfontein+277-882-255-28 abortion pills for sale in Stilfonteinmasabamasaba
 
8257 interfacing 2 in microprocessor for btech students
8257 interfacing 2 in microprocessor for btech students8257 interfacing 2 in microprocessor for btech students
8257 interfacing 2 in microprocessor for btech studentsHimanshiGarg82
 
%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...
%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...
%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...masabamasaba
 
Unlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language ModelsUnlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language Modelsaagamshah0812
 
Introducing Microsoft’s new Enterprise Work Management (EWM) Solution
Introducing Microsoft’s new Enterprise Work Management (EWM) SolutionIntroducing Microsoft’s new Enterprise Work Management (EWM) Solution
Introducing Microsoft’s new Enterprise Work Management (EWM) SolutionOnePlan Solutions
 
Payment Gateway Testing Simplified_ A Step-by-Step Guide for Beginners.pdf
Payment Gateway Testing Simplified_ A Step-by-Step Guide for Beginners.pdfPayment Gateway Testing Simplified_ A Step-by-Step Guide for Beginners.pdf
Payment Gateway Testing Simplified_ A Step-by-Step Guide for Beginners.pdfkalichargn70th171
 
Generic or specific? Making sensible software design decisions
Generic or specific? Making sensible software design decisionsGeneric or specific? Making sensible software design decisions
Generic or specific? Making sensible software design decisionsBert Jan Schrijver
 
Crypto Cloud Review - How To Earn Up To $500 Per DAY Of Bitcoin 100% On AutoP...
Crypto Cloud Review - How To Earn Up To $500 Per DAY Of Bitcoin 100% On AutoP...Crypto Cloud Review - How To Earn Up To $500 Per DAY Of Bitcoin 100% On AutoP...
Crypto Cloud Review - How To Earn Up To $500 Per DAY Of Bitcoin 100% On AutoP...SelfMade bd
 
%in ivory park+277-882-255-28 abortion pills for sale in ivory park
%in ivory park+277-882-255-28 abortion pills for sale in ivory park %in ivory park+277-882-255-28 abortion pills for sale in ivory park
%in ivory park+277-882-255-28 abortion pills for sale in ivory park masabamasaba
 
%in Durban+277-882-255-28 abortion pills for sale in Durban
%in Durban+277-882-255-28 abortion pills for sale in Durban%in Durban+277-882-255-28 abortion pills for sale in Durban
%in Durban+277-882-255-28 abortion pills for sale in Durbanmasabamasaba
 
%in tembisa+277-882-255-28 abortion pills for sale in tembisa
%in tembisa+277-882-255-28 abortion pills for sale in tembisa%in tembisa+277-882-255-28 abortion pills for sale in tembisa
%in tembisa+277-882-255-28 abortion pills for sale in tembisamasabamasaba
 
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...harshavardhanraghave
 
%in tembisa+277-882-255-28 abortion pills for sale in tembisa
%in tembisa+277-882-255-28 abortion pills for sale in tembisa%in tembisa+277-882-255-28 abortion pills for sale in tembisa
%in tembisa+277-882-255-28 abortion pills for sale in tembisamasabamasaba
 
Software Quality Assurance Interview Questions
Software Quality Assurance Interview QuestionsSoftware Quality Assurance Interview Questions
Software Quality Assurance Interview QuestionsArshad QA
 
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...Health
 
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdf
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdfintroduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdf
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdfVishalKumarJha10
 
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...Shane Coughlan
 

Kürzlich hochgeladen (20)

Chinsurah Escorts ☎️8617697112 Starting From 5K to 15K High Profile Escorts ...
Chinsurah Escorts ☎️8617697112  Starting From 5K to 15K High Profile Escorts ...Chinsurah Escorts ☎️8617697112  Starting From 5K to 15K High Profile Escorts ...
Chinsurah Escorts ☎️8617697112 Starting From 5K to 15K High Profile Escorts ...
 
Define the academic and professional writing..pdf
Define the academic and professional writing..pdfDefine the academic and professional writing..pdf
Define the academic and professional writing..pdf
 
10 Trends Likely to Shape Enterprise Technology in 2024
10 Trends Likely to Shape Enterprise Technology in 202410 Trends Likely to Shape Enterprise Technology in 2024
10 Trends Likely to Shape Enterprise Technology in 2024
 
%in Stilfontein+277-882-255-28 abortion pills for sale in Stilfontein
%in Stilfontein+277-882-255-28 abortion pills for sale in Stilfontein%in Stilfontein+277-882-255-28 abortion pills for sale in Stilfontein
%in Stilfontein+277-882-255-28 abortion pills for sale in Stilfontein
 
8257 interfacing 2 in microprocessor for btech students
8257 interfacing 2 in microprocessor for btech students8257 interfacing 2 in microprocessor for btech students
8257 interfacing 2 in microprocessor for btech students
 
%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...
%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...
%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...
 
Unlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language ModelsUnlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language Models
 
Introducing Microsoft’s new Enterprise Work Management (EWM) Solution
Introducing Microsoft’s new Enterprise Work Management (EWM) SolutionIntroducing Microsoft’s new Enterprise Work Management (EWM) Solution
Introducing Microsoft’s new Enterprise Work Management (EWM) Solution
 
Payment Gateway Testing Simplified_ A Step-by-Step Guide for Beginners.pdf
Payment Gateway Testing Simplified_ A Step-by-Step Guide for Beginners.pdfPayment Gateway Testing Simplified_ A Step-by-Step Guide for Beginners.pdf
Payment Gateway Testing Simplified_ A Step-by-Step Guide for Beginners.pdf
 
Generic or specific? Making sensible software design decisions
Generic or specific? Making sensible software design decisionsGeneric or specific? Making sensible software design decisions
Generic or specific? Making sensible software design decisions
 
Crypto Cloud Review - How To Earn Up To $500 Per DAY Of Bitcoin 100% On AutoP...
Crypto Cloud Review - How To Earn Up To $500 Per DAY Of Bitcoin 100% On AutoP...Crypto Cloud Review - How To Earn Up To $500 Per DAY Of Bitcoin 100% On AutoP...
Crypto Cloud Review - How To Earn Up To $500 Per DAY Of Bitcoin 100% On AutoP...
 
%in ivory park+277-882-255-28 abortion pills for sale in ivory park
%in ivory park+277-882-255-28 abortion pills for sale in ivory park %in ivory park+277-882-255-28 abortion pills for sale in ivory park
%in ivory park+277-882-255-28 abortion pills for sale in ivory park
 
%in Durban+277-882-255-28 abortion pills for sale in Durban
%in Durban+277-882-255-28 abortion pills for sale in Durban%in Durban+277-882-255-28 abortion pills for sale in Durban
%in Durban+277-882-255-28 abortion pills for sale in Durban
 
%in tembisa+277-882-255-28 abortion pills for sale in tembisa
%in tembisa+277-882-255-28 abortion pills for sale in tembisa%in tembisa+277-882-255-28 abortion pills for sale in tembisa
%in tembisa+277-882-255-28 abortion pills for sale in tembisa
 
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
 
%in tembisa+277-882-255-28 abortion pills for sale in tembisa
%in tembisa+277-882-255-28 abortion pills for sale in tembisa%in tembisa+277-882-255-28 abortion pills for sale in tembisa
%in tembisa+277-882-255-28 abortion pills for sale in tembisa
 
Software Quality Assurance Interview Questions
Software Quality Assurance Interview QuestionsSoftware Quality Assurance Interview Questions
Software Quality Assurance Interview Questions
 
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
 
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdf
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdfintroduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdf
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdf
 
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...
 

MVVM with Kendo UI

  • 1. MVVM with Kendo UI BRUNO PESSANHA
  • 2. MVVM BRUNO PESSANHA – MVVM WITH KENDO UI
  • 3. MVVM BRUNO PESSANHA – MVVM WITH KENDO UI Advantages Disadvantages Facilitates easier parallel development of a UI and the building blocks that power it For simpler UIs, MVVM can be overkill. Abstracts the View and thus reduces the quantity of business logic (or glue) required in the code behind it. Whilst data-bindings can be declarative and nice to work with, they can be harder to debug than imperative code where we simply set breakpoints. The ViewModel can be easier to unit test than event-driven code. Data-bindings in non-trivial applications can create a lot of book-keeping. You also don’t want to end up in a situation where bindings are heavier than the objects being bound to. The ViewModel (being more Model than View) can be tested without concerns of UI automation and interaction. In larger applications, it can be more difficult to design the ViewModel up front to get the necessary amount of generalisation.
  • 4. Kendo MVVM – Model BRUNO PESSANHA – MVVM WITH KENDO UI Data; UI Independent; State; Written in code; Represented by pure data.
  • 5. Kendo MVVM – View BRUNO PESSANHA – MVVM WITH KENDO UI
  • 6. Kendo MVVM – View-Model BRUNO PESSANHA – MVVM WITH KENDO UI
  • 7. Kendo MVVM – Binding View to View-Model BRUNO PESSANHA – MVVM WITH KENDO UI
  • 8. Kendo MVVM – Binding View to View-Model BRUNO PESSANHA – MVVM WITH KENDO UI
  • 9. Kendo MVVM – Observable Array BRUNO PESSANHA – MVVM WITH KENDO UI
  • 10. Kendo MVVM – Getting a field value BRUNO PESSANHA – MVVM WITH KENDO UI
  • 11. Kendo MVVM – Getting a field value BRUNO PESSANHA – MVVM WITH KENDO UI
  • 12. Kendo MVVM – Setting a field value BRUNO PESSANHA – MVVM WITH KENDO UI
  • 13. Kendo MVVM – Calculated field BRUNO PESSANHA – MVVM WITH KENDO UI
  • 14. Kendo MVVM – Bindings Attr Checked Click Custom Disabled Enabled Events HTML Invisible Source Style Text Value Visible BRUNO PESSANHA – MVVM WITH KENDO UI
  • 15. Kendo MVVM – Bindings – Attr BRUNO PESSANHA – MVVM WITH KENDO UI
  • 16. Kendo MVVM – Bindings – Source BRUNO PESSANHA – MVVM WITH KENDO UI
  • 17. Kendo MVVM – Bindings – Custom BRUNO PESSANHA – MVVM WITH KENDO UI
  • 18. References  http://blogs.msdn.com/b/johngossman/archive/2005/10/08/478683.aspx  http://msdn.microsoft.com/en-us/magazine/dd419663.aspx  http://docs.telerik.com/kendo-ui/getting-started/framework/mvvm/overview  http://demos.telerik.com/kendo-ui/mvvm/index  http://en.wikipedia.org/wiki/Model_View_ViewModel  http://blogs.msdn.com/b/johngossman/archive/2006/03/04/543695.aspx BRUNO PESSANHA – MVVM WITH KENDO UI

Hinweis der Redaktion

  1. The Model View ViewModel (MVVM) is an architectural pattern used in software engineering that originated from Microsoft as a specialization of the Presentation Model design pattern introduced by Martin Fowler. MVVM facilitates a clear separation of the development of the graphical user interface (either as markup language or GUI code) from the development of the business logic or back end logic known as the model (also known as the data model to distinguish it from the view model). The view model of MVVM is a value converter[6] meaning that the view model is responsible for exposing the data objects from the model in such a way that those objects are easily managed and consumed. In this respect, the view model is more model than view, and handles most if not all of the view’s display logic (though the demarcation between what functions are handled by which layer is a subject of ongoing discussion[6] and exploration). The view model may also implement a mediator pattern organising access to the backend logic around the set of use cases supported by the view.
  2. Kendo MVVM is an implementation of the MVVM pattern which seamlessly integrates with the rest of the Kendo framework (widgets and DataSource). The Model is defined as in MVC; it is the data or business logic, completely UI independent, that stores the state and does the processing of the problem domain.  The Model is written in code or is represented by pure data encoded in relational tables or XML.  The View is almost always defined declaratively, very often with a tool.  By the nature of these tools and declarative languages some view state that MVC encodes in its View classes is not easy to represent.  For example, the UI may have multiple modes of interaction such as "view mode" and "edit mode" that change the behavior of the controls or the look of the visuals.
  3. The View in Model/View/ViewModel consists of the visual elements, the buttons, windows, graphics and more complex controls of a GUI. 
  4. The ObservableArray wraps an existing Array object with change tracking capabilities.
  5. The attr binding populates DOM element attributes from View-Model fields or methods. This is useful in many cases - setting the href and titleof a hyperlink, setting the src attribute of an image etc. If the View-Model field(s) change the attributes would be updated. The attr binding is set like this: attr: { attribute1: field1, attribute2: field2 } where attribute1 and attribute2 are the names of the attributes that would be set and field1 and field2 are the names of the View-Model fields to which those attributes would be bound. 
  6. The source binding sets the HTML content of the target element by rendering a Kendo template with a View-Model value. If the View-Model value changes the HTML content of the target element will be updated. The template is specified by the data-template attribute of the element. The value of that attribute should be the value of the id of an existing script element which defines the Kendo template. If a template is not specified a default template will be used depending on element tag name.
  7. The refresh handler is responsible for updating the HTML element. It will be executed each time when the value of the bound MVVM field changes. The bound DOM element and attached MVVM bindings could be retrieved through the context of the function. The change handler is responsible for updating the View-Model. It listens for the change event of the bound HTML input element. The View-Model is updated through the set(value) method of the binding.