SlideShare une entreprise Scribd logo
1  sur  12
Télécharger pour lire hors ligne
Promise Object
Presenter: Nirmal Hota, Mindfire Solutions
Date: 21/02/2014
About Me
MCTS : .NET Framework 4, Web Applications
MCTS : MS Dynamics CRM 2011 Customization and Configuration
MCTS : Microsoft Dynamics CRM 2011 Applications
TCAD : Titanium Certified Application Developer
MS Dynamics CRM, Commerce Server, .Net, WinJS, PhoneGap, Titanium,
Xamarin
My Key Skills
Connect me in :
Facebook : http://www.facebook.com/nirmal.hota.14
Twitter : http://twitter.com/nirmalhota
LinkedIn : http://in.linkedin.com/in/nirmalhota
Google+ : https://plus.google.com/104872959343373237226
Blog : http://nirmalhota.blogspot.in/
Skype : mfsi_nirmal
Contact me in :
Email : nirmalh@mindfiresolutions.com | nirmalhota@gmail.com
Agenda
>> What is a promise
>> How it works
>> Advantages of promise
>> Real life implementation (Demo)
>> Q & A
>> Some frequently used methods
What is a promise
>> Schedule work for future
>> Asynchronous programming approach
>> Runs in background thread
>> Foreground works without blocking
>> Methods exposed by convention ends with “Async”
How it works
Application
Give me stuffs (via XHR call)
MoveNext
Promisestogetback
Search
I will manipulate
the stuff if I get it
HereisyourStuff
Got it :)
Let's manipulate
Some frequently used Methods
>> then : Allows to define tasks to be done after
promise fulfilled.
>> done : Allows to define tasks to be done after
promise fulfilled.
>> any : Allows to define tasks to be done after any of
the task performed among a set of promises.
>> join : Allows to define tasks to be done after all of
the tasks performed among a set of promises.
>> cancel : Allows to cancel an in progress promise
then vs done
>> Both of them are used after the completion of
promised task
>> Both the methods takes the same kind of
parameters completed, error and in progress handlers
>> “then” returns a promise object where as “done”
returns an undefined
>> In case any exception occurred in the promised
block, “then” puts the error in the promise object and
return it to outside. But “done” throws the same to
outside as a normal exception. So better place for
“done” is at the end of the promise chain
Advantages of promise
>> No blocking of main thread for long running XHR
calls. This can be handled in the background
>> Ability to define the tasks after a long running XHR
is over
>> Can chain multiple calls
>> Tasks can be defined to be done after the
completion of multiple parallel processes or any
process out the set processes
Real life implementation
Demo
Question and
Answer
Thank you
www.mindfiresolutions.com
https://www.facebook.com/MindfireSolutions
http://www.linkedin.com/company/mindfire-solutions
http://twitter.com/mindfires

Contenu connexe

En vedette

Jasper reports in 3 easy steps
Jasper reports in 3 easy stepsJasper reports in 3 easy steps
Jasper reports in 3 easy stepsIvaylo Zashev
 
"Analytics inside your Java application", Part 2, jDays 2015 Speaker: "Veaces...
"Analytics inside your Java application", Part 2, jDays 2015 Speaker: "Veaces..."Analytics inside your Java application", Part 2, jDays 2015 Speaker: "Veaces...
"Analytics inside your Java application", Part 2, jDays 2015 Speaker: "Veaces...hamidsamadi
 
Mobile Web Development from Scratch
Mobile Web Development from ScratchMobile Web Development from Scratch
Mobile Web Development from ScratchNokiaAppForum
 
Jaspersoft Studioチュートリアル1 - レポートの作成
Jaspersoft Studioチュートリアル1 - レポートの作成Jaspersoft Studioチュートリアル1 - レポートの作成
Jaspersoft Studioチュートリアル1 - レポートの作成htshozawa
 
Jasper Reports
Jasper ReportsJasper Reports
Jasper ReportsEnkitec
 
Introduction to java Jasper Report with Server & iReport
Introduction to java Jasper Report with Server & iReportIntroduction to java Jasper Report with Server & iReport
Introduction to java Jasper Report with Server & iReportArif Hosain
 
Embedding Jaspersoft into your PHP application
Embedding Jaspersoft into your PHP applicationEmbedding Jaspersoft into your PHP application
Embedding Jaspersoft into your PHP applicationMariano Luna
 
BatchJobService
BatchJobServiceBatchJobService
BatchJobServicesupergigas
 
A Short Intorduction to JasperReports
A Short Intorduction to JasperReportsA Short Intorduction to JasperReports
A Short Intorduction to JasperReportsGuo Albert
 
Open Source Reporting Tool Comparison
Open Source Reporting Tool ComparisonOpen Source Reporting Tool Comparison
Open Source Reporting Tool ComparisonRogue Wave Software
 
Introduction to Jasper Reports
Introduction to Jasper ReportsIntroduction to Jasper Reports
Introduction to Jasper ReportsMindfire Solutions
 

En vedette (14)

Jasper reports in 3 easy steps
Jasper reports in 3 easy stepsJasper reports in 3 easy steps
Jasper reports in 3 easy steps
 
"Analytics inside your Java application", Part 2, jDays 2015 Speaker: "Veaces...
"Analytics inside your Java application", Part 2, jDays 2015 Speaker: "Veaces..."Analytics inside your Java application", Part 2, jDays 2015 Speaker: "Veaces...
"Analytics inside your Java application", Part 2, jDays 2015 Speaker: "Veaces...
 
Mobile Web Development from Scratch
Mobile Web Development from ScratchMobile Web Development from Scratch
Mobile Web Development from Scratch
 
Jaspersoft Studioチュートリアル1 - レポートの作成
Jaspersoft Studioチュートリアル1 - レポートの作成Jaspersoft Studioチュートリアル1 - レポートの作成
Jaspersoft Studioチュートリアル1 - レポートの作成
 
Jasper Reports
Jasper ReportsJasper Reports
Jasper Reports
 
Introduction to java Jasper Report with Server & iReport
Introduction to java Jasper Report with Server & iReportIntroduction to java Jasper Report with Server & iReport
Introduction to java Jasper Report with Server & iReport
 
Advanced Jasper Reports
Advanced Jasper ReportsAdvanced Jasper Reports
Advanced Jasper Reports
 
Embedding Jaspersoft into your PHP application
Embedding Jaspersoft into your PHP applicationEmbedding Jaspersoft into your PHP application
Embedding Jaspersoft into your PHP application
 
BatchJobService
BatchJobServiceBatchJobService
BatchJobService
 
A Short Intorduction to JasperReports
A Short Intorduction to JasperReportsA Short Intorduction to JasperReports
A Short Intorduction to JasperReports
 
Open Source Reporting Tool Comparison
Open Source Reporting Tool ComparisonOpen Source Reporting Tool Comparison
Open Source Reporting Tool Comparison
 
Introduction to Jasper Reports
Introduction to Jasper ReportsIntroduction to Jasper Reports
Introduction to Jasper Reports
 
Japer Reports
Japer ReportsJaper Reports
Japer Reports
 
Captcha ppt
Captcha pptCaptcha ppt
Captcha ppt
 

Similaire à Promise Object in Windows Store App

MuleSoft Meetup | Reading Meetup Group | Hosted by Integral Zone
MuleSoft Meetup | Reading Meetup Group | Hosted by Integral ZoneMuleSoft Meetup | Reading Meetup Group | Hosted by Integral Zone
MuleSoft Meetup | Reading Meetup Group | Hosted by Integral ZoneIntegralZone
 
Building configurable applications for the web
Building configurable applications for the webBuilding configurable applications for the web
Building configurable applications for the websupertom
 
BITS 2016 How DevOps Ends the War Between Developers and Sysadmins
BITS 2016   How DevOps Ends the War Between Developers and SysadminsBITS 2016   How DevOps Ends the War Between Developers and Sysadmins
BITS 2016 How DevOps Ends the War Between Developers and SysadminsAhmed Musaad
 
Agile Delivery Methods And Leadership
Agile Delivery Methods And LeadershipAgile Delivery Methods And Leadership
Agile Delivery Methods And LeadershipRanjith Varghese
 
Development frameworks and methods
Development frameworks and methodsDevelopment frameworks and methods
Development frameworks and methodsMin Phone Nyunt Win
 
Student Answer and Work Form Unit 3 Ver. CStudent Name ________.docx
Student Answer and Work Form Unit 3 Ver. CStudent Name ________.docxStudent Answer and Work Form Unit 3 Ver. CStudent Name ________.docx
Student Answer and Work Form Unit 3 Ver. CStudent Name ________.docxjohniemcm5zt
 
Remotetestingfeaturev1 160109071942
Remotetestingfeaturev1 160109071942Remotetestingfeaturev1 160109071942
Remotetestingfeaturev1 160109071942Arunkumar H
 
Remotetestingfeature v1.1
Remotetestingfeature v1.1Remotetestingfeature v1.1
Remotetestingfeature v1.1Arunkumar H
 
Progressive Web Apps by Millicent Convento
Progressive Web Apps by Millicent ConventoProgressive Web Apps by Millicent Convento
Progressive Web Apps by Millicent ConventoDEVCON
 
How to explain DevOps to your mom
How to explain DevOps to your momHow to explain DevOps to your mom
How to explain DevOps to your momAndreas Grabner
 
Malware Cleanup Project
Malware Cleanup ProjectMalware Cleanup Project
Malware Cleanup ProjectSubarno Saha
 
Interview Questions For Microsoft Dynamics CRM
Interview Questions For Microsoft Dynamics CRMInterview Questions For Microsoft Dynamics CRM
Interview Questions For Microsoft Dynamics CRMKumari Warsha Goel
 
Becoming the Docker Champion: Bringing Docker Back to Work
Becoming the Docker Champion: Bringing Docker Back to WorkBecoming the Docker Champion: Bringing Docker Back to Work
Becoming the Docker Champion: Bringing Docker Back to WorkDocker, Inc.
 
What is Drools, Guvnor and Planner? 2012 02-17 Brno Dev Conference
What is Drools, Guvnor and Planner? 2012 02-17 Brno Dev ConferenceWhat is Drools, Guvnor and Planner? 2012 02-17 Brno Dev Conference
What is Drools, Guvnor and Planner? 2012 02-17 Brno Dev ConferenceGeoffrey De Smet
 
Rails Operations - Lessons Learned
Rails Operations -  Lessons LearnedRails Operations -  Lessons Learned
Rails Operations - Lessons LearnedJosh Nichols
 
How to use Salesforce composite request connector in Mule
How to use Salesforce composite request connector in MuleHow to use Salesforce composite request connector in Mule
How to use Salesforce composite request connector in MuleAlexandra N. Martinez
 
Salesforce Apex Hours:-Mitigate with Mono-Purpose Microservices
Salesforce Apex Hours:-Mitigate with Mono-Purpose MicroservicesSalesforce Apex Hours:-Mitigate with Mono-Purpose Microservices
Salesforce Apex Hours:-Mitigate with Mono-Purpose MicroservicesAmit Chaudhary
 

Similaire à Promise Object in Windows Store App (20)

MuleSoft Meetup | Reading Meetup Group | Hosted by Integral Zone
MuleSoft Meetup | Reading Meetup Group | Hosted by Integral ZoneMuleSoft Meetup | Reading Meetup Group | Hosted by Integral Zone
MuleSoft Meetup | Reading Meetup Group | Hosted by Integral Zone
 
Building configurable applications for the web
Building configurable applications for the webBuilding configurable applications for the web
Building configurable applications for the web
 
BITS 2016 How DevOps Ends the War Between Developers and Sysadmins
BITS 2016   How DevOps Ends the War Between Developers and SysadminsBITS 2016   How DevOps Ends the War Between Developers and Sysadmins
BITS 2016 How DevOps Ends the War Between Developers and Sysadmins
 
Agile Delivery Methods And Leadership
Agile Delivery Methods And LeadershipAgile Delivery Methods And Leadership
Agile Delivery Methods And Leadership
 
Development frameworks and methods
Development frameworks and methodsDevelopment frameworks and methods
Development frameworks and methods
 
Student Answer and Work Form Unit 3 Ver. CStudent Name ________.docx
Student Answer and Work Form Unit 3 Ver. CStudent Name ________.docxStudent Answer and Work Form Unit 3 Ver. CStudent Name ________.docx
Student Answer and Work Form Unit 3 Ver. CStudent Name ________.docx
 
Remotetestingfeaturev1 160109071942
Remotetestingfeaturev1 160109071942Remotetestingfeaturev1 160109071942
Remotetestingfeaturev1 160109071942
 
Remotetestingfeature v1.1
Remotetestingfeature v1.1Remotetestingfeature v1.1
Remotetestingfeature v1.1
 
Progressive Web Apps by Millicent Convento
Progressive Web Apps by Millicent ConventoProgressive Web Apps by Millicent Convento
Progressive Web Apps by Millicent Convento
 
How to explain DevOps to your mom
How to explain DevOps to your momHow to explain DevOps to your mom
How to explain DevOps to your mom
 
Malware Cleanup Project
Malware Cleanup ProjectMalware Cleanup Project
Malware Cleanup Project
 
Interview Questions For Microsoft Dynamics CRM
Interview Questions For Microsoft Dynamics CRMInterview Questions For Microsoft Dynamics CRM
Interview Questions For Microsoft Dynamics CRM
 
Becoming the Docker Champion: Bringing Docker Back to Work
Becoming the Docker Champion: Bringing Docker Back to WorkBecoming the Docker Champion: Bringing Docker Back to Work
Becoming the Docker Champion: Bringing Docker Back to Work
 
What is Drools, Guvnor and Planner? 2012 02-17 Brno Dev Conference
What is Drools, Guvnor and Planner? 2012 02-17 Brno Dev ConferenceWhat is Drools, Guvnor and Planner? 2012 02-17 Brno Dev Conference
What is Drools, Guvnor and Planner? 2012 02-17 Brno Dev Conference
 
Rails Operations - Lessons Learned
Rails Operations -  Lessons LearnedRails Operations -  Lessons Learned
Rails Operations - Lessons Learned
 
Role of dev ops in it consulting
Role of dev ops in it consultingRole of dev ops in it consulting
Role of dev ops in it consulting
 
How to use Salesforce composite request connector in Mule
How to use Salesforce composite request connector in MuleHow to use Salesforce composite request connector in Mule
How to use Salesforce composite request connector in Mule
 
Salesforce Apex Hours:-Mitigate with Mono-Purpose Microservices
Salesforce Apex Hours:-Mitigate with Mono-Purpose MicroservicesSalesforce Apex Hours:-Mitigate with Mono-Purpose Microservices
Salesforce Apex Hours:-Mitigate with Mono-Purpose Microservices
 
What's new in Microsoft Teams
What's new in Microsoft Teams What's new in Microsoft Teams
What's new in Microsoft Teams
 
CV28022015
CV28022015CV28022015
CV28022015
 

Plus de Mindfire Solutions (20)

Physician Search and Review
Physician Search and ReviewPhysician Search and Review
Physician Search and Review
 
diet management app
diet management appdiet management app
diet management app
 
Business Technology Solution
Business Technology SolutionBusiness Technology Solution
Business Technology Solution
 
Remote Health Monitoring
Remote Health MonitoringRemote Health Monitoring
Remote Health Monitoring
 
Influencer Marketing Solution
Influencer Marketing SolutionInfluencer Marketing Solution
Influencer Marketing Solution
 
ELMAH
ELMAHELMAH
ELMAH
 
High Availability of Azure Applications
High Availability of Azure ApplicationsHigh Availability of Azure Applications
High Availability of Azure Applications
 
IOT Hands On
IOT Hands OnIOT Hands On
IOT Hands On
 
Glimpse of Loops Vs Set
Glimpse of Loops Vs SetGlimpse of Loops Vs Set
Glimpse of Loops Vs Set
 
Oracle Sql Developer-Getting Started
Oracle Sql Developer-Getting StartedOracle Sql Developer-Getting Started
Oracle Sql Developer-Getting Started
 
Adaptive Layout In iOS 8
Adaptive Layout In iOS 8Adaptive Layout In iOS 8
Adaptive Layout In iOS 8
 
Introduction to Auto-layout : iOS/Mac
Introduction to Auto-layout : iOS/MacIntroduction to Auto-layout : iOS/Mac
Introduction to Auto-layout : iOS/Mac
 
LINQPad - utility Tool
LINQPad - utility ToolLINQPad - utility Tool
LINQPad - utility Tool
 
Get started with watch kit development
Get started with watch kit developmentGet started with watch kit development
Get started with watch kit development
 
Swift vs Objective-C
Swift vs Objective-CSwift vs Objective-C
Swift vs Objective-C
 
Material Design in Android
Material Design in AndroidMaterial Design in Android
Material Design in Android
 
Introduction to OData
Introduction to ODataIntroduction to OData
Introduction to OData
 
Ext js Part 2- MVC
Ext js Part 2- MVCExt js Part 2- MVC
Ext js Part 2- MVC
 
ExtJs Basic Part-1
ExtJs Basic Part-1ExtJs Basic Part-1
ExtJs Basic Part-1
 
Spring Security Introduction
Spring Security IntroductionSpring Security Introduction
Spring Security Introduction
 

Dernier

Amazon Bedrock in Action - presentation of the Bedrock's capabilities
Amazon Bedrock in Action - presentation of the Bedrock's capabilitiesAmazon Bedrock in Action - presentation of the Bedrock's capabilities
Amazon Bedrock in Action - presentation of the Bedrock's capabilitiesKrzysztofKkol1
 
Post Quantum Cryptography – The Impact on Identity
Post Quantum Cryptography – The Impact on IdentityPost Quantum Cryptography – The Impact on Identity
Post Quantum Cryptography – The Impact on Identityteam-WIBU
 
JavaLand 2024 - Going serverless with Quarkus GraalVM native images and AWS L...
JavaLand 2024 - Going serverless with Quarkus GraalVM native images and AWS L...JavaLand 2024 - Going serverless with Quarkus GraalVM native images and AWS L...
JavaLand 2024 - Going serverless with Quarkus GraalVM native images and AWS L...Bert Jan Schrijver
 
Comparing Linux OS Image Update Models - EOSS 2024.pdf
Comparing Linux OS Image Update Models - EOSS 2024.pdfComparing Linux OS Image Update Models - EOSS 2024.pdf
Comparing Linux OS Image Update Models - EOSS 2024.pdfDrew Moseley
 
Introduction to Firebase Workshop Slides
Introduction to Firebase Workshop SlidesIntroduction to Firebase Workshop Slides
Introduction to Firebase Workshop Slidesvaideheekore1
 
Ronisha Informatics Private Limited Catalogue
Ronisha Informatics Private Limited CatalogueRonisha Informatics Private Limited Catalogue
Ronisha Informatics Private Limited Catalogueitservices996
 
VictoriaMetrics Q1 Meet Up '24 - Community & News Update
VictoriaMetrics Q1 Meet Up '24 - Community & News UpdateVictoriaMetrics Q1 Meet Up '24 - Community & News Update
VictoriaMetrics Q1 Meet Up '24 - Community & News UpdateVictoriaMetrics
 
Real-time Tracking and Monitoring with Cargo Cloud Solutions.pptx
Real-time Tracking and Monitoring with Cargo Cloud Solutions.pptxReal-time Tracking and Monitoring with Cargo Cloud Solutions.pptx
Real-time Tracking and Monitoring with Cargo Cloud Solutions.pptxRTS corp
 
Osi security architecture in network.pptx
Osi security architecture in network.pptxOsi security architecture in network.pptx
Osi security architecture in network.pptxVinzoCenzo
 
Strategies for using alternative queries to mitigate zero results
Strategies for using alternative queries to mitigate zero resultsStrategies for using alternative queries to mitigate zero results
Strategies for using alternative queries to mitigate zero resultsJean Silva
 
Powering Real-Time Decisions with Continuous Data Streams
Powering Real-Time Decisions with Continuous Data StreamsPowering Real-Time Decisions with Continuous Data Streams
Powering Real-Time Decisions with Continuous Data StreamsSafe Software
 
Leveraging AI for Mobile App Testing on Real Devices | Applitools + Kobiton
Leveraging AI for Mobile App Testing on Real Devices | Applitools + KobitonLeveraging AI for Mobile App Testing on Real Devices | Applitools + Kobiton
Leveraging AI for Mobile App Testing on Real Devices | Applitools + KobitonApplitools
 
Patterns for automating API delivery. API conference
Patterns for automating API delivery. API conferencePatterns for automating API delivery. API conference
Patterns for automating API delivery. API conferencessuser9e7c64
 
The Role of IoT and Sensor Technology in Cargo Cloud Solutions.pptx
The Role of IoT and Sensor Technology in Cargo Cloud Solutions.pptxThe Role of IoT and Sensor Technology in Cargo Cloud Solutions.pptx
The Role of IoT and Sensor Technology in Cargo Cloud Solutions.pptxRTS corp
 
UI5ers live - Custom Controls wrapping 3rd-party libs.pptx
UI5ers live - Custom Controls wrapping 3rd-party libs.pptxUI5ers live - Custom Controls wrapping 3rd-party libs.pptx
UI5ers live - Custom Controls wrapping 3rd-party libs.pptxAndreas Kunz
 
Machine Learning Software Engineering Patterns and Their Engineering
Machine Learning Software Engineering Patterns and Their EngineeringMachine Learning Software Engineering Patterns and Their Engineering
Machine Learning Software Engineering Patterns and Their EngineeringHironori Washizaki
 
Understanding Flamingo - DeepMind's VLM Architecture
Understanding Flamingo - DeepMind's VLM ArchitectureUnderstanding Flamingo - DeepMind's VLM Architecture
Understanding Flamingo - DeepMind's VLM Architecturerahul_net
 
SensoDat: Simulation-based Sensor Dataset of Self-driving Cars
SensoDat: Simulation-based Sensor Dataset of Self-driving CarsSensoDat: Simulation-based Sensor Dataset of Self-driving Cars
SensoDat: Simulation-based Sensor Dataset of Self-driving CarsChristian Birchler
 
SAM Training Session - How to use EXCEL ?
SAM Training Session - How to use EXCEL ?SAM Training Session - How to use EXCEL ?
SAM Training Session - How to use EXCEL ?Alexandre Beguel
 
OpenChain Education Work Group Monthly Meeting - 2024-04-10 - Full Recording
OpenChain Education Work Group Monthly Meeting - 2024-04-10 - Full RecordingOpenChain Education Work Group Monthly Meeting - 2024-04-10 - Full Recording
OpenChain Education Work Group Monthly Meeting - 2024-04-10 - Full RecordingShane Coughlan
 

Dernier (20)

Amazon Bedrock in Action - presentation of the Bedrock's capabilities
Amazon Bedrock in Action - presentation of the Bedrock's capabilitiesAmazon Bedrock in Action - presentation of the Bedrock's capabilities
Amazon Bedrock in Action - presentation of the Bedrock's capabilities
 
Post Quantum Cryptography – The Impact on Identity
Post Quantum Cryptography – The Impact on IdentityPost Quantum Cryptography – The Impact on Identity
Post Quantum Cryptography – The Impact on Identity
 
JavaLand 2024 - Going serverless with Quarkus GraalVM native images and AWS L...
JavaLand 2024 - Going serverless with Quarkus GraalVM native images and AWS L...JavaLand 2024 - Going serverless with Quarkus GraalVM native images and AWS L...
JavaLand 2024 - Going serverless with Quarkus GraalVM native images and AWS L...
 
Comparing Linux OS Image Update Models - EOSS 2024.pdf
Comparing Linux OS Image Update Models - EOSS 2024.pdfComparing Linux OS Image Update Models - EOSS 2024.pdf
Comparing Linux OS Image Update Models - EOSS 2024.pdf
 
Introduction to Firebase Workshop Slides
Introduction to Firebase Workshop SlidesIntroduction to Firebase Workshop Slides
Introduction to Firebase Workshop Slides
 
Ronisha Informatics Private Limited Catalogue
Ronisha Informatics Private Limited CatalogueRonisha Informatics Private Limited Catalogue
Ronisha Informatics Private Limited Catalogue
 
VictoriaMetrics Q1 Meet Up '24 - Community & News Update
VictoriaMetrics Q1 Meet Up '24 - Community & News UpdateVictoriaMetrics Q1 Meet Up '24 - Community & News Update
VictoriaMetrics Q1 Meet Up '24 - Community & News Update
 
Real-time Tracking and Monitoring with Cargo Cloud Solutions.pptx
Real-time Tracking and Monitoring with Cargo Cloud Solutions.pptxReal-time Tracking and Monitoring with Cargo Cloud Solutions.pptx
Real-time Tracking and Monitoring with Cargo Cloud Solutions.pptx
 
Osi security architecture in network.pptx
Osi security architecture in network.pptxOsi security architecture in network.pptx
Osi security architecture in network.pptx
 
Strategies for using alternative queries to mitigate zero results
Strategies for using alternative queries to mitigate zero resultsStrategies for using alternative queries to mitigate zero results
Strategies for using alternative queries to mitigate zero results
 
Powering Real-Time Decisions with Continuous Data Streams
Powering Real-Time Decisions with Continuous Data StreamsPowering Real-Time Decisions with Continuous Data Streams
Powering Real-Time Decisions with Continuous Data Streams
 
Leveraging AI for Mobile App Testing on Real Devices | Applitools + Kobiton
Leveraging AI for Mobile App Testing on Real Devices | Applitools + KobitonLeveraging AI for Mobile App Testing on Real Devices | Applitools + Kobiton
Leveraging AI for Mobile App Testing on Real Devices | Applitools + Kobiton
 
Patterns for automating API delivery. API conference
Patterns for automating API delivery. API conferencePatterns for automating API delivery. API conference
Patterns for automating API delivery. API conference
 
The Role of IoT and Sensor Technology in Cargo Cloud Solutions.pptx
The Role of IoT and Sensor Technology in Cargo Cloud Solutions.pptxThe Role of IoT and Sensor Technology in Cargo Cloud Solutions.pptx
The Role of IoT and Sensor Technology in Cargo Cloud Solutions.pptx
 
UI5ers live - Custom Controls wrapping 3rd-party libs.pptx
UI5ers live - Custom Controls wrapping 3rd-party libs.pptxUI5ers live - Custom Controls wrapping 3rd-party libs.pptx
UI5ers live - Custom Controls wrapping 3rd-party libs.pptx
 
Machine Learning Software Engineering Patterns and Their Engineering
Machine Learning Software Engineering Patterns and Their EngineeringMachine Learning Software Engineering Patterns and Their Engineering
Machine Learning Software Engineering Patterns and Their Engineering
 
Understanding Flamingo - DeepMind's VLM Architecture
Understanding Flamingo - DeepMind's VLM ArchitectureUnderstanding Flamingo - DeepMind's VLM Architecture
Understanding Flamingo - DeepMind's VLM Architecture
 
SensoDat: Simulation-based Sensor Dataset of Self-driving Cars
SensoDat: Simulation-based Sensor Dataset of Self-driving CarsSensoDat: Simulation-based Sensor Dataset of Self-driving Cars
SensoDat: Simulation-based Sensor Dataset of Self-driving Cars
 
SAM Training Session - How to use EXCEL ?
SAM Training Session - How to use EXCEL ?SAM Training Session - How to use EXCEL ?
SAM Training Session - How to use EXCEL ?
 
OpenChain Education Work Group Monthly Meeting - 2024-04-10 - Full Recording
OpenChain Education Work Group Monthly Meeting - 2024-04-10 - Full RecordingOpenChain Education Work Group Monthly Meeting - 2024-04-10 - Full Recording
OpenChain Education Work Group Monthly Meeting - 2024-04-10 - Full Recording
 

Promise Object in Windows Store App

  • 1. Promise Object Presenter: Nirmal Hota, Mindfire Solutions Date: 21/02/2014
  • 2. About Me MCTS : .NET Framework 4, Web Applications MCTS : MS Dynamics CRM 2011 Customization and Configuration MCTS : Microsoft Dynamics CRM 2011 Applications TCAD : Titanium Certified Application Developer MS Dynamics CRM, Commerce Server, .Net, WinJS, PhoneGap, Titanium, Xamarin My Key Skills Connect me in : Facebook : http://www.facebook.com/nirmal.hota.14 Twitter : http://twitter.com/nirmalhota LinkedIn : http://in.linkedin.com/in/nirmalhota Google+ : https://plus.google.com/104872959343373237226 Blog : http://nirmalhota.blogspot.in/ Skype : mfsi_nirmal Contact me in : Email : nirmalh@mindfiresolutions.com | nirmalhota@gmail.com
  • 3. Agenda >> What is a promise >> How it works >> Advantages of promise >> Real life implementation (Demo) >> Q & A >> Some frequently used methods
  • 4. What is a promise >> Schedule work for future >> Asynchronous programming approach >> Runs in background thread >> Foreground works without blocking >> Methods exposed by convention ends with “Async”
  • 5. How it works Application Give me stuffs (via XHR call) MoveNext Promisestogetback Search I will manipulate the stuff if I get it HereisyourStuff Got it :) Let's manipulate
  • 6. Some frequently used Methods >> then : Allows to define tasks to be done after promise fulfilled. >> done : Allows to define tasks to be done after promise fulfilled. >> any : Allows to define tasks to be done after any of the task performed among a set of promises. >> join : Allows to define tasks to be done after all of the tasks performed among a set of promises. >> cancel : Allows to cancel an in progress promise
  • 7. then vs done >> Both of them are used after the completion of promised task >> Both the methods takes the same kind of parameters completed, error and in progress handlers >> “then” returns a promise object where as “done” returns an undefined >> In case any exception occurred in the promised block, “then” puts the error in the promise object and return it to outside. But “done” throws the same to outside as a normal exception. So better place for “done” is at the end of the promise chain
  • 8. Advantages of promise >> No blocking of main thread for long running XHR calls. This can be handled in the background >> Ability to define the tasks after a long running XHR is over >> Can chain multiple calls >> Tasks can be defined to be done after the completion of multiple parallel processes or any process out the set processes