SlideShare uma empresa Scribd logo
1 de 15
AnuradhaMalalasena
What is ?
 JS library aimed to manage data in rich client applications
- It’s client side LINQ to SQL
- Mirror server-side model to client side dynamically (eg :- Entity Framework Objects)
- No need of creating client side Models for every server side entity.
 Implements the Open Data Protocol (OData) query standard
- If a query can be expressed in OData syntax, it can be expressed in Breeze
- http://www.example.com/api/Northwind/Customers?$filter=startswith(CompanyName,'C') eq true&$orderby=CompanyName
 Ships with adapters for the ASP.NET WebAPI for Odata
Communication
DAL
UI
BL (MV*)
Offline Storage
Entities
Module Module Module
Server
Why ?
 It’s free
 Simplify data query tasks (LINQ style)
 Manage client side data caching
 Support batch operations (saveChanges())
 Support all modern browsers on desktop and mobile devices (ECMAScript 5)
 Out-of-box support for Knockout, Angular, and Backbone
 Well documented
 Intellisense support
Key features of
 Query like LINQ
/* Query like LINQ */
// Define query for customers
// starting with 'A', sorted by name,
var query = breeze.EntityQuery
.from("Customers")
.where("CompanyName", "startsWith", "A")
.orderBy("CompanyName");
//... execute it later ...
Key features of
 Query like LINQ
 Async with Promises /* Async query with promises */
// Execute query asynchronously on remote server
// returns a promise ... with success/fail callbacks
var promise = manager.executeQuery(query)
.then(querySucceeded)
.fail(queryFailed);
/* Async save with promises */
// Batch asynchronous save of all entities w/ pending
changes
// returns a promise ... with success/fail callbacks
var promise = manager.saveChanges()
.then(saveSucceeded)
.fail(saveFailed);
Key features of
 Query like LINQ
 Async with Promises
 Change tracking
/* Change tracking */
// save all changes (if there are any)
if (manager.hasChanges()) {
manager.saveChanges()
.then(saveSucceeded)
.fail(saveFailed);
}
// listen for any change to a customer
customer.entityAspect.propertyChanged
.subscribe(somethingHappened);
// listen for validation errors
customer.entityAspect.validationErrorsChanged
.subscribe(updateValidationUI);
Key features of
 Query like LINQ
 Async with Promises
 Change tracking
 Knockout/Angular data binding
<!-- Knockout template -->
<ul data-bind="foreach: results">
<li>
<span data-bind="text:FirstName"></span>
<span data-bind="text:LastName"></span>
</li>
</ul>
// bound to employees from query
manager.executeQuery(breeze.EntityQuery
.from("Employees"))
.then(function(data){
ko.applyBindings(data);
});
Key features of
 Query like LINQ
 Async with Promises
 Change tracking
 Knockout/Angular data binding
 Query with related entities
/* Query with related entities using expand */
// query for orders of customers whose name begins
"Alfreds"
// include their customers & child details & their
detail products
breeze.EntityQuery.from("Orders")
.where("Customer.CompanyName", "startsWith", "Alfre
ds")
.expand("Customer, OrderDetails.Product")
.using(manager)
.execute().then(querySucceeded).fail(queryFailed);
Key features of
 Query like LINQ
 Async with Promises
 Change tracking
 Knockout/Angular data binding
 Query with related entities
 Navigate to related entities
/* Navigate to related entities in cache */
// Query success callback
function querySucceeded (data) {
var order1 = data.results[0];
// Parent customer of the order
var customer = order1.Customer();
// Product of the first OrderDetail of the order
var product1 = order1.OrderDetails()[0].Product();
}
Key features of
 Query like LINQ
 Async with Promises
 Change tracking
 Knockout/Angular data binding
 Query with related entities
 Navigate to related entities
 Flatten entity graphs
/* Flatten entity graphs */
// Projection query: "select" flattens the Orders to 4
fields.
// Order id, ship date, & customer name of Orders w/
freight > $500
breeze.EntityQuery.from("Orders")
.where("Freight", ">", 500)
.select("OrderId, Customer.CompanyName,
ShippedDate")
.orderBy("Customer.CompanyName, ShippedDate");
Key features of
 Query like LINQ
 Async with Promises
 Change tracking
 Knockout/Angular data binding
 Query with related entities
 Navigate to related entities
 Flatten entity graphs
 Query server or cache
/* Query the server, cache, or both */
var query = breeze.EntityQuery("Customers");
// execute query asynchronously on the server
manager.executeQuery(query).then(querySuccess).fail(qu
eryFail);
// execute query synchronously on local cache
var customers = manager.executeQueryLocally(query)
// fetch customer by id from cache (if found) or
remotely
var checkCacheFirst = true;
manager.fetchEntityByKey("CompanyName", 42,
checkCacheFirst)
.then(fetchSuccess).fail(fetchFail);
Key features of
 Query like LINQ
 Async with Promises
 Change tracking
 Knockout/Angular data binding
 Query with related entities
 Navigate to related entities
 Flatten entity graphs
 Query server or cache
 Save changes offline
/* Save changes offline; restore later */
var changes = manager.getChanges();
var exportData = manager.exportEntities(changes);
window.localStorage.setItem("changes", exportData);
// ... later ...
var importData =
window.localStorage.getItem("changes");
manager.importEntities(importData);
Demo
ThankYOU

Mais conteúdo relacionado

Mais procurados

SenchaCon 2016: Enterprise Applications, Role Based Access Controls (RBAC) an...
SenchaCon 2016: Enterprise Applications, Role Based Access Controls (RBAC) an...SenchaCon 2016: Enterprise Applications, Role Based Access Controls (RBAC) an...
SenchaCon 2016: Enterprise Applications, Role Based Access Controls (RBAC) an...Sencha
 
Building better SQL Server Databases
Building better SQL Server DatabasesBuilding better SQL Server Databases
Building better SQL Server DatabasesColdFusionConference
 
Going Serverless with Azure Functions in .NET
Going Serverless with Azure Functions in .NETGoing Serverless with Azure Functions in .NET
Going Serverless with Azure Functions in .NETJeremy Likness
 
Galen Framework - Responsive Design Automation
Galen Framework - Responsive Design AutomationGalen Framework - Responsive Design Automation
Galen Framework - Responsive Design AutomationVenkat Ramana Reddy Parine
 
Spicing up SharePoint web parts
Spicing up SharePoint web partsSpicing up SharePoint web parts
Spicing up SharePoint web partsRandy Williams
 
Code First with Serverless Azure Functions
Code First with Serverless Azure FunctionsCode First with Serverless Azure Functions
Code First with Serverless Azure FunctionsJeremy Likness
 
ADO.NET Data Services
ADO.NET Data ServicesADO.NET Data Services
ADO.NET Data Servicesukdpe
 
Lyudmila Zharova: Developing Solutions for SharePoint 2010 Using the Client O...
Lyudmila Zharova: Developing Solutions for SharePoint 2010 Using the Client O...Lyudmila Zharova: Developing Solutions for SharePoint 2010 Using the Client O...
Lyudmila Zharova: Developing Solutions for SharePoint 2010 Using the Client O...SharePoint Saturday NY
 
Deploying your static web app to the Cloud
Deploying your static web app to the CloudDeploying your static web app to the Cloud
Deploying your static web app to the CloudChristoffer Noring
 
MVC 6 - Tag Helpers and View Components
MVC 6 - Tag Helpers and View ComponentsMVC 6 - Tag Helpers and View Components
MVC 6 - Tag Helpers and View ComponentsDavid Paquette
 
Customizations in Enterprise Applications using Oracle ADF
Customizations in Enterprise Applications using Oracle ADFCustomizations in Enterprise Applications using Oracle ADF
Customizations in Enterprise Applications using Oracle ADFRohan Walia
 
Tokyo Azure Meetup #14 - Azure Functions Proxies
Tokyo Azure Meetup #14  -  Azure Functions ProxiesTokyo Azure Meetup #14  -  Azure Functions Proxies
Tokyo Azure Meetup #14 - Azure Functions ProxiesTokyo Azure Meetup
 
MSDN Sessions 032817 - Azure Functions
MSDN Sessions 032817 - Azure FunctionsMSDN Sessions 032817 - Azure Functions
MSDN Sessions 032817 - Azure FunctionsMarc Obaldo
 
Dotnet- An overview of ASP.NET & ADO.NET- Mazenet solution
Dotnet- An overview of ASP.NET & ADO.NET- Mazenet solutionDotnet- An overview of ASP.NET & ADO.NET- Mazenet solution
Dotnet- An overview of ASP.NET & ADO.NET- Mazenet solutionMazenetsolution
 
oracle oa framework training | oracle oa framework training courses | oa fram...
oracle oa framework training | oracle oa framework training courses | oa fram...oracle oa framework training | oracle oa framework training courses | oa fram...
oracle oa framework training | oracle oa framework training courses | oa fram...Nancy Thomas
 
Building Your Own Development Tools With the Force.com Tooling API
Building Your Own Development Tools With the Force.com Tooling APIBuilding Your Own Development Tools With the Force.com Tooling API
Building Your Own Development Tools With the Force.com Tooling APISalesforce Developers
 

Mais procurados (20)

SenchaCon 2016: Enterprise Applications, Role Based Access Controls (RBAC) an...
SenchaCon 2016: Enterprise Applications, Role Based Access Controls (RBAC) an...SenchaCon 2016: Enterprise Applications, Role Based Access Controls (RBAC) an...
SenchaCon 2016: Enterprise Applications, Role Based Access Controls (RBAC) an...
 
Building better SQL Server Databases
Building better SQL Server DatabasesBuilding better SQL Server Databases
Building better SQL Server Databases
 
Going Serverless with Azure Functions in .NET
Going Serverless with Azure Functions in .NETGoing Serverless with Azure Functions in .NET
Going Serverless with Azure Functions in .NET
 
Galen Framework - Responsive Design Automation
Galen Framework - Responsive Design AutomationGalen Framework - Responsive Design Automation
Galen Framework - Responsive Design Automation
 
Spicing up SharePoint web parts
Spicing up SharePoint web partsSpicing up SharePoint web parts
Spicing up SharePoint web parts
 
Oracle ADF Case Study
Oracle ADF Case StudyOracle ADF Case Study
Oracle ADF Case Study
 
RESTful API - Best Practices
RESTful API - Best PracticesRESTful API - Best Practices
RESTful API - Best Practices
 
Code First with Serverless Azure Functions
Code First with Serverless Azure FunctionsCode First with Serverless Azure Functions
Code First with Serverless Azure Functions
 
Angularjs & REST
Angularjs & RESTAngularjs & REST
Angularjs & REST
 
ADO.NET Data Services
ADO.NET Data ServicesADO.NET Data Services
ADO.NET Data Services
 
Lyudmila Zharova: Developing Solutions for SharePoint 2010 Using the Client O...
Lyudmila Zharova: Developing Solutions for SharePoint 2010 Using the Client O...Lyudmila Zharova: Developing Solutions for SharePoint 2010 Using the Client O...
Lyudmila Zharova: Developing Solutions for SharePoint 2010 Using the Client O...
 
Deploying your static web app to the Cloud
Deploying your static web app to the CloudDeploying your static web app to the Cloud
Deploying your static web app to the Cloud
 
MVC 6 - Tag Helpers and View Components
MVC 6 - Tag Helpers and View ComponentsMVC 6 - Tag Helpers and View Components
MVC 6 - Tag Helpers and View Components
 
Customizations in Enterprise Applications using Oracle ADF
Customizations in Enterprise Applications using Oracle ADFCustomizations in Enterprise Applications using Oracle ADF
Customizations in Enterprise Applications using Oracle ADF
 
Tokyo Azure Meetup #14 - Azure Functions Proxies
Tokyo Azure Meetup #14  -  Azure Functions ProxiesTokyo Azure Meetup #14  -  Azure Functions Proxies
Tokyo Azure Meetup #14 - Azure Functions Proxies
 
MSDN Sessions 032817 - Azure Functions
MSDN Sessions 032817 - Azure FunctionsMSDN Sessions 032817 - Azure Functions
MSDN Sessions 032817 - Azure Functions
 
Dotnet- An overview of ASP.NET & ADO.NET- Mazenet solution
Dotnet- An overview of ASP.NET & ADO.NET- Mazenet solutionDotnet- An overview of ASP.NET & ADO.NET- Mazenet solution
Dotnet- An overview of ASP.NET & ADO.NET- Mazenet solution
 
oracle oa framework training | oracle oa framework training courses | oa fram...
oracle oa framework training | oracle oa framework training courses | oa fram...oracle oa framework training | oracle oa framework training courses | oa fram...
oracle oa framework training | oracle oa framework training courses | oa fram...
 
Oracle application framework (oaf) online training
Oracle application framework (oaf) online trainingOracle application framework (oaf) online training
Oracle application framework (oaf) online training
 
Building Your Own Development Tools With the Force.com Tooling API
Building Your Own Development Tools With the Force.com Tooling APIBuilding Your Own Development Tools With the Force.com Tooling API
Building Your Own Development Tools With the Force.com Tooling API
 

Semelhante a Introduction to BreezeJs

SharePoint Client Object Model (CSOM)
SharePoint Client Object Model (CSOM)SharePoint Client Object Model (CSOM)
SharePoint Client Object Model (CSOM)Kashif Imran
 
Stephane Lapointe, Frank Boucher & Alexandre Brisebois: Les micro-services et...
Stephane Lapointe, Frank Boucher & Alexandre Brisebois: Les micro-services et...Stephane Lapointe, Frank Boucher & Alexandre Brisebois: Les micro-services et...
Stephane Lapointe, Frank Boucher & Alexandre Brisebois: Les micro-services et...MSDEVMTL
 
SoCal Code Camp 2011 - ASP.NET MVC 4
SoCal Code Camp 2011 - ASP.NET MVC 4SoCal Code Camp 2011 - ASP.NET MVC 4
SoCal Code Camp 2011 - ASP.NET MVC 4Jon Galloway
 
Building workflow solution with Microsoft Azure and Cloud | Integration Monday
Building workflow solution with Microsoft Azure and Cloud | Integration MondayBuilding workflow solution with Microsoft Azure and Cloud | Integration Monday
Building workflow solution with Microsoft Azure and Cloud | Integration MondayBizTalk360
 
Practical AngularJS
Practical AngularJSPractical AngularJS
Practical AngularJSWei Ru
 
Windows Azure and a little SQL Data Services
Windows Azure and a little SQL Data ServicesWindows Azure and a little SQL Data Services
Windows Azure and a little SQL Data Servicesukdpe
 
Introduction to ASP.NET
Introduction to ASP.NETIntroduction to ASP.NET
Introduction to ASP.NETPeter Gfader
 
JavaOne 2014 - Supporting Multi-tenancy Applications with Java EE
JavaOne 2014 - Supporting Multi-tenancy Applications with Java EEJavaOne 2014 - Supporting Multi-tenancy Applications with Java EE
JavaOne 2014 - Supporting Multi-tenancy Applications with Java EERodrigo Cândido da Silva
 
Introduction to the Client OM in SharePoint 2010
Introduction to the Client OM in SharePoint 2010Introduction to the Client OM in SharePoint 2010
Introduction to the Client OM in SharePoint 2010Ben Robb
 
Azure Durable Functions (2019-04-27)
Azure Durable Functions (2019-04-27)Azure Durable Functions (2019-04-27)
Azure Durable Functions (2019-04-27)Paco de la Cruz
 
Microservice Websites – Micro CPH
Microservice Websites – Micro CPHMicroservice Websites – Micro CPH
Microservice Websites – Micro CPHGustaf Nilsson Kotte
 
Wcf data services
Wcf data servicesWcf data services
Wcf data servicesEyal Vardi
 
Intoduction to Play Framework
Intoduction to Play FrameworkIntoduction to Play Framework
Intoduction to Play FrameworkKnoldus Inc.
 
Couchbase@live person meetup july 22nd
Couchbase@live person meetup   july 22ndCouchbase@live person meetup   july 22nd
Couchbase@live person meetup july 22ndIdo Shilon
 
[Hands-on] CQRS(Command Query Responsibility Segregation) 와 Event Sourcing 패턴 실습
[Hands-on] CQRS(Command Query Responsibility Segregation) 와 Event Sourcing 패턴 실습[Hands-on] CQRS(Command Query Responsibility Segregation) 와 Event Sourcing 패턴 실습
[Hands-on] CQRS(Command Query Responsibility Segregation) 와 Event Sourcing 패턴 실습Oracle Korea
 
CQRS and Event Sourcing
CQRS and Event Sourcing CQRS and Event Sourcing
CQRS and Event Sourcing Inho Kang
 

Semelhante a Introduction to BreezeJs (20)

SharePoint Client Object Model (CSOM)
SharePoint Client Object Model (CSOM)SharePoint Client Object Model (CSOM)
SharePoint Client Object Model (CSOM)
 
Stephane Lapointe, Frank Boucher & Alexandre Brisebois: Les micro-services et...
Stephane Lapointe, Frank Boucher & Alexandre Brisebois: Les micro-services et...Stephane Lapointe, Frank Boucher & Alexandre Brisebois: Les micro-services et...
Stephane Lapointe, Frank Boucher & Alexandre Brisebois: Les micro-services et...
 
SoCal Code Camp 2011 - ASP.NET MVC 4
SoCal Code Camp 2011 - ASP.NET MVC 4SoCal Code Camp 2011 - ASP.NET MVC 4
SoCal Code Camp 2011 - ASP.NET MVC 4
 
Building workflow solution with Microsoft Azure and Cloud | Integration Monday
Building workflow solution with Microsoft Azure and Cloud | Integration MondayBuilding workflow solution with Microsoft Azure and Cloud | Integration Monday
Building workflow solution with Microsoft Azure and Cloud | Integration Monday
 
Jsf presentation
Jsf presentationJsf presentation
Jsf presentation
 
ASP.NET Lecture 2
ASP.NET Lecture 2ASP.NET Lecture 2
ASP.NET Lecture 2
 
Practical AngularJS
Practical AngularJSPractical AngularJS
Practical AngularJS
 
App fabric introduction
App fabric introductionApp fabric introduction
App fabric introduction
 
Windows Azure and a little SQL Data Services
Windows Azure and a little SQL Data ServicesWindows Azure and a little SQL Data Services
Windows Azure and a little SQL Data Services
 
Introduction to ASP.NET
Introduction to ASP.NETIntroduction to ASP.NET
Introduction to ASP.NET
 
JavaOne 2014 - Supporting Multi-tenancy Applications with Java EE
JavaOne 2014 - Supporting Multi-tenancy Applications with Java EEJavaOne 2014 - Supporting Multi-tenancy Applications with Java EE
JavaOne 2014 - Supporting Multi-tenancy Applications with Java EE
 
Introduction to the Client OM in SharePoint 2010
Introduction to the Client OM in SharePoint 2010Introduction to the Client OM in SharePoint 2010
Introduction to the Client OM in SharePoint 2010
 
Azure Durable Functions (2019-04-27)
Azure Durable Functions (2019-04-27)Azure Durable Functions (2019-04-27)
Azure Durable Functions (2019-04-27)
 
Microservice Websites – Micro CPH
Microservice Websites – Micro CPHMicroservice Websites – Micro CPH
Microservice Websites – Micro CPH
 
Wcf data services
Wcf data servicesWcf data services
Wcf data services
 
Intoduction to Play Framework
Intoduction to Play FrameworkIntoduction to Play Framework
Intoduction to Play Framework
 
State management
State managementState management
State management
 
Couchbase@live person meetup july 22nd
Couchbase@live person meetup   july 22ndCouchbase@live person meetup   july 22nd
Couchbase@live person meetup july 22nd
 
[Hands-on] CQRS(Command Query Responsibility Segregation) 와 Event Sourcing 패턴 실습
[Hands-on] CQRS(Command Query Responsibility Segregation) 와 Event Sourcing 패턴 실습[Hands-on] CQRS(Command Query Responsibility Segregation) 와 Event Sourcing 패턴 실습
[Hands-on] CQRS(Command Query Responsibility Segregation) 와 Event Sourcing 패턴 실습
 
CQRS and Event Sourcing
CQRS and Event Sourcing CQRS and Event Sourcing
CQRS and Event Sourcing
 

Último

CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Servicegiselly40
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonAnna Loughnan Colquhoun
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsEnterprise Knowledge
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024The Digital Insurer
 
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...gurkirankumar98700
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesSinan KOZAK
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationMichael W. Hawkins
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Paola De la Torre
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024Results
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountPuma Security, LLC
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsMaria Levchenko
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024The Digital Insurer
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...apidays
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processorsdebabhi2
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreternaman860154
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Enterprise Knowledge
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024The Digital Insurer
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking MenDelhi Call girls
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc
 

Último (20)

CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Service
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024
 
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen Frames
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 

Introduction to BreezeJs

  • 2. What is ?  JS library aimed to manage data in rich client applications - It’s client side LINQ to SQL - Mirror server-side model to client side dynamically (eg :- Entity Framework Objects) - No need of creating client side Models for every server side entity.  Implements the Open Data Protocol (OData) query standard - If a query can be expressed in OData syntax, it can be expressed in Breeze - http://www.example.com/api/Northwind/Customers?$filter=startswith(CompanyName,'C') eq true&$orderby=CompanyName  Ships with adapters for the ASP.NET WebAPI for Odata
  • 4. Why ?  It’s free  Simplify data query tasks (LINQ style)  Manage client side data caching  Support batch operations (saveChanges())  Support all modern browsers on desktop and mobile devices (ECMAScript 5)  Out-of-box support for Knockout, Angular, and Backbone  Well documented  Intellisense support
  • 5. Key features of  Query like LINQ /* Query like LINQ */ // Define query for customers // starting with 'A', sorted by name, var query = breeze.EntityQuery .from("Customers") .where("CompanyName", "startsWith", "A") .orderBy("CompanyName"); //... execute it later ...
  • 6. Key features of  Query like LINQ  Async with Promises /* Async query with promises */ // Execute query asynchronously on remote server // returns a promise ... with success/fail callbacks var promise = manager.executeQuery(query) .then(querySucceeded) .fail(queryFailed); /* Async save with promises */ // Batch asynchronous save of all entities w/ pending changes // returns a promise ... with success/fail callbacks var promise = manager.saveChanges() .then(saveSucceeded) .fail(saveFailed);
  • 7. Key features of  Query like LINQ  Async with Promises  Change tracking /* Change tracking */ // save all changes (if there are any) if (manager.hasChanges()) { manager.saveChanges() .then(saveSucceeded) .fail(saveFailed); } // listen for any change to a customer customer.entityAspect.propertyChanged .subscribe(somethingHappened); // listen for validation errors customer.entityAspect.validationErrorsChanged .subscribe(updateValidationUI);
  • 8. Key features of  Query like LINQ  Async with Promises  Change tracking  Knockout/Angular data binding <!-- Knockout template --> <ul data-bind="foreach: results"> <li> <span data-bind="text:FirstName"></span> <span data-bind="text:LastName"></span> </li> </ul> // bound to employees from query manager.executeQuery(breeze.EntityQuery .from("Employees")) .then(function(data){ ko.applyBindings(data); });
  • 9. Key features of  Query like LINQ  Async with Promises  Change tracking  Knockout/Angular data binding  Query with related entities /* Query with related entities using expand */ // query for orders of customers whose name begins "Alfreds" // include their customers & child details & their detail products breeze.EntityQuery.from("Orders") .where("Customer.CompanyName", "startsWith", "Alfre ds") .expand("Customer, OrderDetails.Product") .using(manager) .execute().then(querySucceeded).fail(queryFailed);
  • 10. Key features of  Query like LINQ  Async with Promises  Change tracking  Knockout/Angular data binding  Query with related entities  Navigate to related entities /* Navigate to related entities in cache */ // Query success callback function querySucceeded (data) { var order1 = data.results[0]; // Parent customer of the order var customer = order1.Customer(); // Product of the first OrderDetail of the order var product1 = order1.OrderDetails()[0].Product(); }
  • 11. Key features of  Query like LINQ  Async with Promises  Change tracking  Knockout/Angular data binding  Query with related entities  Navigate to related entities  Flatten entity graphs /* Flatten entity graphs */ // Projection query: "select" flattens the Orders to 4 fields. // Order id, ship date, & customer name of Orders w/ freight > $500 breeze.EntityQuery.from("Orders") .where("Freight", ">", 500) .select("OrderId, Customer.CompanyName, ShippedDate") .orderBy("Customer.CompanyName, ShippedDate");
  • 12. Key features of  Query like LINQ  Async with Promises  Change tracking  Knockout/Angular data binding  Query with related entities  Navigate to related entities  Flatten entity graphs  Query server or cache /* Query the server, cache, or both */ var query = breeze.EntityQuery("Customers"); // execute query asynchronously on the server manager.executeQuery(query).then(querySuccess).fail(qu eryFail); // execute query synchronously on local cache var customers = manager.executeQueryLocally(query) // fetch customer by id from cache (if found) or remotely var checkCacheFirst = true; manager.fetchEntityByKey("CompanyName", 42, checkCacheFirst) .then(fetchSuccess).fail(fetchFail);
  • 13. Key features of  Query like LINQ  Async with Promises  Change tracking  Knockout/Angular data binding  Query with related entities  Navigate to related entities  Flatten entity graphs  Query server or cache  Save changes offline /* Save changes offline; restore later */ var changes = manager.getChanges(); var exportData = manager.exportEntities(changes); window.localStorage.setItem("changes", exportData); // ... later ... var importData = window.localStorage.getItem("changes"); manager.importEntities(importData);
  • 14. Demo