SlideShare une entreprise Scribd logo
1  sur  15
Télécharger pour lire hors ligne
Desarrollo de Aplicaciones Cross-
Platform para Dispositivos Moviles
Building Cross-Platform Mobile Applications
M.S.C. Raquel Vásquez Ramírez
M.S.C. Cristian A. Rodríguez Enríquez
Contenido	
  
•  Manejo	
  de	
  Base	
  de	
  Datos	
  (Client	
  Side)	
  
•  Almacenamiento	
  Local	
  
– Permanente	
  
– Sesión	
  
– Usando	
  Base	
  de	
  Datos	
  
•  Conclusiones	
  
Building Cross-Plaftform Mobile Applications – jQuery Mobile
Slide 02 of 15
HTML 5: Data Storage
Building Cross-Plaftform Mobile Applications – jQuery Mobile
Slide 03 of 15
HTML5 offers two types of data storage on the client:
•  Storage via a database containing the tables
described in SQL
•  Storage through localStorage and sessionStorage
objects, to store information made up of strings.
Permanent Storage and Session Storage
Building Cross-Plaftform Mobile Applications – jQuery Mobile
Slide 04 of 15
Para habilitar el “Storage” se utilizan dos objetos de
JavaScript:
•  localStorage: Permite el almacenamiento permanente
•  sessionStorage: Permite el almacenamiento en la sesión
Permanent Storage
Building Cross-Plaftform Mobile Applications – jQuery Mobile
Slide 05 of 15
localStorage.lname = “Sarrion”;
localStorage.fname = “Eric”;
Building Cross-Plaftform Mobile Applications – jQuery Mobile
Slide 06 of 15
Session Storage
sessionStorage.lname = “Sarrion”;
sessionStorage.fname = “Eric”;
Building Cross-Plaftform Mobile Applications – jQuery Mobile
Slide 07 of 15
Usando una Base de Datos
Como se puede observar el almacenamiento temporal y
permanente no provee las facilidades de las bases de datos
SQL.
Gracias a HTML 5 es posible usar bases de SQL de forma local.
Building Cross-Plaftform Mobile Applications – jQuery Mobile
Slide 08 of 15
Creando la Base de Datos
var	
  db	
  =	
  openDatabase	
  (“Test”,	
  “1.0”,	
  “Test”,	
  65535);	
  
Building Cross-Plaftform Mobile Applications – jQuery Mobile
Slide 09 of 15
Transaction
db.transacKon	
  (funcKon	
  (transacKon)	
  	
  
{	
  
	
  	
  	
  	
  var	
  sql	
  =	
  SQL	
  query;	
  
	
  	
  	
  	
  transacKon.executeSql	
  (sql,	
  [parameters]	
  /	
  undefined,	
  	
  
	
  	
  	
  	
  funcKon	
  ()	
  
	
  	
  	
  	
  {	
  	
  
	
  	
  	
  	
  	
  	
  	
  	
  //	
  JavaScript	
  code	
  to	
  execute	
  if	
  the	
  query	
  was	
  successful	
  
	
  	
  	
  	
  },	
  	
  
	
  	
  	
  	
  funcKon	
  ()	
  
	
  	
  	
  	
  {	
  	
  
	
  	
  	
  	
  	
  	
  	
  	
  //	
  JavaScript	
  code	
  to	
  execute	
  if	
  the	
  query	
  failed	
  
	
  	
  	
  	
  }	
  );	
  
});	
  
Building Cross-Plaftform Mobile Applications – jQuery Mobile
Slide 10 of 15
Usando la Base de Datos
•  Crear Base de Datos
•  Insertar
•  Listar (SELECT)
•  Eliminar Tabla
Building Cross-Plaftform Mobile Applications – jQuery Mobile
Slide 11 of 15
CREATE TABLE
db.transacKon	
  (funcKon	
  (transacKon)	
  	
  
	
  	
  {	
  
	
  	
  	
  	
  var	
  sql	
  =	
  "CREATE	
  TABLE	
  customers	
  "	
  +	
  
	
  	
  	
  	
  	
  	
  	
  	
  "	
  (id	
  INTEGER	
  NOT	
  NULL	
  PRIMARY	
  KEY	
  AUTOINCREMENT,	
  "	
  +	
  
	
  	
  	
  	
  	
  	
  	
  	
  "lname	
  VARCHAR(100)	
  NOT	
  NULL,	
  "	
  +	
  	
  
	
  	
  	
  	
  	
  	
  	
  	
  "fname	
  VARCHAR(100)	
  NOT	
  NULL)"	
  
	
  	
  	
  	
  transacKon.executeSql	
  (sql,	
  undefined,	
  funcKon	
  ()	
  
	
  	
  	
  	
  {	
  	
  
	
  	
  	
  	
  	
  	
  alert	
  ("Table	
  created");	
  
	
  	
  	
  	
  },	
  error);	
  
	
  	
  });	
  
Building Cross-Plaftform Mobile Applications – jQuery Mobile
Slide 12 of 15
DROP TABLE
db.transacKon	
  (funcKon	
  (transacKon)	
  	
  
	
  	
  {	
  
	
  	
  	
  	
  var	
  sql	
  =	
  "DROP	
  TABLE	
  customers";	
  
	
  	
  	
  	
  transacKon.executeSql	
  (sql,	
  undefined,	
  ok,	
  error);	
  
	
  	
  }	
  
Building Cross-Plaftform Mobile Applications – jQuery Mobile
Slide 13 of 15
INSERT INTO
db.transacKon	
  (funcKon	
  (transacKon)	
  	
  
	
  	
  {	
  
	
  	
  	
  	
  var	
  sql	
  =	
  "INSERT	
  INTO	
  customers	
  (lname,	
  fname)	
  VALUES	
  (?,	
  ?)";	
  
	
  	
  	
  	
  transacKon.executeSql	
  (sql,	
  [lname,	
  fname],	
  funcKon	
  ()	
  
	
  	
  	
  	
  {	
  	
  
	
  	
  	
  	
  	
  	
  alert	
  ("Customer	
  inserted");	
  
	
  	
  	
  	
  },	
  error);	
  
	
  	
  }	
  
Building Cross-Plaftform Mobile Applications – jQuery Mobile
Slide 14 of 15
Base de Datos Server Side (Elementos)
var	
  sql	
  =	
  "SELECT	
  *	
  FROM	
  customers";	
  
transacKon.executeSql	
  (sql,	
  undefined,…	
  	
  
Conclusiones	
  
•  jQuery provee los elementos necesarios para
desarrollar aplicaciones para dispositivos móviles
•  Desarrollo Ágil
•  Si se desea sincronizar datos con un servidor, se
requiere usar una base de datos local y sincronizar
cuando se disponga de conexión mediante una
consulta constante del estado de la conexión (Push?)
•  Optimización de Aplicaciones Web
Building Cross-Plaftform Mobile Applications – jQuery Mobile
Slide 15 of 15

Contenu connexe

Similaire à 05 Building cross-platform mobile applications with jQuery Mobile / Desarrollo de Aplicaciones Cross-Platform para Dispositivos Moviles

Couchbase@live person meetup july 22nd
Couchbase@live person meetup   july 22ndCouchbase@live person meetup   july 22nd
Couchbase@live person meetup july 22ndIdo Shilon
 
From Web App Model Design to Production with Wakanda
From Web App Model Design to Production with WakandaFrom Web App Model Design to Production with Wakanda
From Web App Model Design to Production with WakandaAlexandre Morgaut
 
03 Building cross platform mobile applications with PhoneGap / Desarrollo de ...
03 Building cross platform mobile applications with PhoneGap / Desarrollo de ...03 Building cross platform mobile applications with PhoneGap / Desarrollo de ...
03 Building cross platform mobile applications with PhoneGap / Desarrollo de ...Cristian Rodríguez Enríquez
 
Full Stack Development With Node.Js And NoSQL (Nic Raboy & Arun Gupta)
Full Stack Development With Node.Js And NoSQL (Nic Raboy & Arun Gupta)Full Stack Development With Node.Js And NoSQL (Nic Raboy & Arun Gupta)
Full Stack Development With Node.Js And NoSQL (Nic Raboy & Arun Gupta)Red Hat Developers
 
Silverlight 2 for Developers - TechEd New Zealand 2008
Silverlight 2 for Developers - TechEd New Zealand 2008Silverlight 2 for Developers - TechEd New Zealand 2008
Silverlight 2 for Developers - TechEd New Zealand 2008Jonas Follesø
 
What 100M downloads taught us about iOS architectures
What 100M downloads taught us about iOS architecturesWhat 100M downloads taught us about iOS architectures
What 100M downloads taught us about iOS architecturesFrancesco Di Lorenzo
 
[Codecamp 2016] Going functional with flyd and react
[Codecamp 2016] Going functional with flyd and react [Codecamp 2016] Going functional with flyd and react
[Codecamp 2016] Going functional with flyd and react gcazaciuc
 
Liferay Devcon presentation on Workflow & Dynamic Forms
Liferay Devcon presentation on Workflow & Dynamic FormsLiferay Devcon presentation on Workflow & Dynamic Forms
Liferay Devcon presentation on Workflow & Dynamic FormsWillem Vermeer
 
Liferay Devcon Presentation on Dynamic Forms with Liferay Workflow
Liferay Devcon Presentation on Dynamic Forms with Liferay WorkflowLiferay Devcon Presentation on Dynamic Forms with Liferay Workflow
Liferay Devcon Presentation on Dynamic Forms with Liferay WorkflowWillem Vermeer
 
Sanjeev_Kumar_Paul- Resume-Latest
Sanjeev_Kumar_Paul- Resume-LatestSanjeev_Kumar_Paul- Resume-Latest
Sanjeev_Kumar_Paul- Resume-LatestSanjeev Kumar Paul
 
Rapid prototyping of eclipse rcp applications - Eclipsecon Europe 2017
Rapid prototyping of eclipse rcp applications - Eclipsecon Europe 2017Rapid prototyping of eclipse rcp applications - Eclipsecon Europe 2017
Rapid prototyping of eclipse rcp applications - Eclipsecon Europe 2017Patrik Suzzi
 
Mobile for SharePoint with Windows Phone
Mobile for SharePoint with Windows PhoneMobile for SharePoint with Windows Phone
Mobile for SharePoint with Windows PhoneEdgewater
 
React JS and Redux
React JS and ReduxReact JS and Redux
React JS and ReduxGlib Kechyn
 
20150812 4시간만에 따라해보는 windows 10 앱 개발
20150812  4시간만에 따라해보는 windows 10 앱 개발20150812  4시간만에 따라해보는 windows 10 앱 개발
20150812 4시간만에 따라해보는 windows 10 앱 개발영욱 김
 
Resume_Sandip_Mohod_Java_9_plus_years_exp
Resume_Sandip_Mohod_Java_9_plus_years_expResume_Sandip_Mohod_Java_9_plus_years_exp
Resume_Sandip_Mohod_Java_9_plus_years_expSandip Mohod
 
Rits Brown Bag - Salesforce Lightning
Rits Brown Bag - Salesforce LightningRits Brown Bag - Salesforce Lightning
Rits Brown Bag - Salesforce LightningRight IT Services
 
Dropwizard Introduction
Dropwizard IntroductionDropwizard Introduction
Dropwizard IntroductionAnthony Chen
 

Similaire à 05 Building cross-platform mobile applications with jQuery Mobile / Desarrollo de Aplicaciones Cross-Platform para Dispositivos Moviles (20)

handout-05b
handout-05bhandout-05b
handout-05b
 
Couchbase@live person meetup july 22nd
Couchbase@live person meetup   july 22ndCouchbase@live person meetup   july 22nd
Couchbase@live person meetup july 22nd
 
From Web App Model Design to Production with Wakanda
From Web App Model Design to Production with WakandaFrom Web App Model Design to Production with Wakanda
From Web App Model Design to Production with Wakanda
 
03 Building cross platform mobile applications with PhoneGap / Desarrollo de ...
03 Building cross platform mobile applications with PhoneGap / Desarrollo de ...03 Building cross platform mobile applications with PhoneGap / Desarrollo de ...
03 Building cross platform mobile applications with PhoneGap / Desarrollo de ...
 
Full Stack Development With Node.Js And NoSQL (Nic Raboy & Arun Gupta)
Full Stack Development With Node.Js And NoSQL (Nic Raboy & Arun Gupta)Full Stack Development With Node.Js And NoSQL (Nic Raboy & Arun Gupta)
Full Stack Development With Node.Js And NoSQL (Nic Raboy & Arun Gupta)
 
Silverlight 2 for Developers - TechEd New Zealand 2008
Silverlight 2 for Developers - TechEd New Zealand 2008Silverlight 2 for Developers - TechEd New Zealand 2008
Silverlight 2 for Developers - TechEd New Zealand 2008
 
Jsf intro
Jsf introJsf intro
Jsf intro
 
What 100M downloads taught us about iOS architectures
What 100M downloads taught us about iOS architecturesWhat 100M downloads taught us about iOS architectures
What 100M downloads taught us about iOS architectures
 
[Codecamp 2016] Going functional with flyd and react
[Codecamp 2016] Going functional with flyd and react [Codecamp 2016] Going functional with flyd and react
[Codecamp 2016] Going functional with flyd and react
 
Liferay Devcon presentation on Workflow & Dynamic Forms
Liferay Devcon presentation on Workflow & Dynamic FormsLiferay Devcon presentation on Workflow & Dynamic Forms
Liferay Devcon presentation on Workflow & Dynamic Forms
 
Liferay Devcon Presentation on Dynamic Forms with Liferay Workflow
Liferay Devcon Presentation on Dynamic Forms with Liferay WorkflowLiferay Devcon Presentation on Dynamic Forms with Liferay Workflow
Liferay Devcon Presentation on Dynamic Forms with Liferay Workflow
 
Sanjeev_Kumar_Paul- Resume-Latest
Sanjeev_Kumar_Paul- Resume-LatestSanjeev_Kumar_Paul- Resume-Latest
Sanjeev_Kumar_Paul- Resume-Latest
 
Rapid prototyping of eclipse rcp applications - Eclipsecon Europe 2017
Rapid prototyping of eclipse rcp applications - Eclipsecon Europe 2017Rapid prototyping of eclipse rcp applications - Eclipsecon Europe 2017
Rapid prototyping of eclipse rcp applications - Eclipsecon Europe 2017
 
Js in quick books
Js in quick booksJs in quick books
Js in quick books
 
Mobile for SharePoint with Windows Phone
Mobile for SharePoint with Windows PhoneMobile for SharePoint with Windows Phone
Mobile for SharePoint with Windows Phone
 
React JS and Redux
React JS and ReduxReact JS and Redux
React JS and Redux
 
20150812 4시간만에 따라해보는 windows 10 앱 개발
20150812  4시간만에 따라해보는 windows 10 앱 개발20150812  4시간만에 따라해보는 windows 10 앱 개발
20150812 4시간만에 따라해보는 windows 10 앱 개발
 
Resume_Sandip_Mohod_Java_9_plus_years_exp
Resume_Sandip_Mohod_Java_9_plus_years_expResume_Sandip_Mohod_Java_9_plus_years_exp
Resume_Sandip_Mohod_Java_9_plus_years_exp
 
Rits Brown Bag - Salesforce Lightning
Rits Brown Bag - Salesforce LightningRits Brown Bag - Salesforce Lightning
Rits Brown Bag - Salesforce Lightning
 
Dropwizard Introduction
Dropwizard IntroductionDropwizard Introduction
Dropwizard Introduction
 

Plus de Cristian Rodríguez Enríquez

LiDIA: An integration architecture to query Linked Open Data from multiple da...
LiDIA: An integration architecture to query Linked Open Data from multiple da...LiDIA: An integration architecture to query Linked Open Data from multiple da...
LiDIA: An integration architecture to query Linked Open Data from multiple da...Cristian Rodríguez Enríquez
 
02 Building cross platform mobile applications with PhoneGap / Desarrollo de ...
02 Building cross platform mobile applications with PhoneGap / Desarrollo de ...02 Building cross platform mobile applications with PhoneGap / Desarrollo de ...
02 Building cross platform mobile applications with PhoneGap / Desarrollo de ...Cristian Rodríguez Enríquez
 
01 Building cross platform mobile applications with PhoneGap / Desarrollo de ...
01 Building cross platform mobile applications with PhoneGap / Desarrollo de ...01 Building cross platform mobile applications with PhoneGap / Desarrollo de ...
01 Building cross platform mobile applications with PhoneGap / Desarrollo de ...Cristian Rodríguez Enríquez
 
04 Building cross-platform mobile applications with jQuery Mobile / Desarroll...
04 Building cross-platform mobile applications with jQuery Mobile / Desarroll...04 Building cross-platform mobile applications with jQuery Mobile / Desarroll...
04 Building cross-platform mobile applications with jQuery Mobile / Desarroll...Cristian Rodríguez Enríquez
 
03 Building cross-platform mobile applications with jQuery Mobile / Desarroll...
03 Building cross-platform mobile applications with jQuery Mobile / Desarroll...03 Building cross-platform mobile applications with jQuery Mobile / Desarroll...
03 Building cross-platform mobile applications with jQuery Mobile / Desarroll...Cristian Rodríguez Enríquez
 
01 Building cross-platform mobile applications with jQuery Mobile
01 Building cross-platform mobile applications with jQuery Mobile01 Building cross-platform mobile applications with jQuery Mobile
01 Building cross-platform mobile applications with jQuery MobileCristian Rodríguez Enríquez
 
Propuesta de integración para el consumo de múltiples datasets de linked data
Propuesta de integración para el consumo de múltiples datasets de linked dataPropuesta de integración para el consumo de múltiples datasets de linked data
Propuesta de integración para el consumo de múltiples datasets de linked dataCristian Rodríguez Enríquez
 

Plus de Cristian Rodríguez Enríquez (7)

LiDIA: An integration architecture to query Linked Open Data from multiple da...
LiDIA: An integration architecture to query Linked Open Data from multiple da...LiDIA: An integration architecture to query Linked Open Data from multiple da...
LiDIA: An integration architecture to query Linked Open Data from multiple da...
 
02 Building cross platform mobile applications with PhoneGap / Desarrollo de ...
02 Building cross platform mobile applications with PhoneGap / Desarrollo de ...02 Building cross platform mobile applications with PhoneGap / Desarrollo de ...
02 Building cross platform mobile applications with PhoneGap / Desarrollo de ...
 
01 Building cross platform mobile applications with PhoneGap / Desarrollo de ...
01 Building cross platform mobile applications with PhoneGap / Desarrollo de ...01 Building cross platform mobile applications with PhoneGap / Desarrollo de ...
01 Building cross platform mobile applications with PhoneGap / Desarrollo de ...
 
04 Building cross-platform mobile applications with jQuery Mobile / Desarroll...
04 Building cross-platform mobile applications with jQuery Mobile / Desarroll...04 Building cross-platform mobile applications with jQuery Mobile / Desarroll...
04 Building cross-platform mobile applications with jQuery Mobile / Desarroll...
 
03 Building cross-platform mobile applications with jQuery Mobile / Desarroll...
03 Building cross-platform mobile applications with jQuery Mobile / Desarroll...03 Building cross-platform mobile applications with jQuery Mobile / Desarroll...
03 Building cross-platform mobile applications with jQuery Mobile / Desarroll...
 
01 Building cross-platform mobile applications with jQuery Mobile
01 Building cross-platform mobile applications with jQuery Mobile01 Building cross-platform mobile applications with jQuery Mobile
01 Building cross-platform mobile applications with jQuery Mobile
 
Propuesta de integración para el consumo de múltiples datasets de linked data
Propuesta de integración para el consumo de múltiples datasets de linked dataPropuesta de integración para el consumo de múltiples datasets de linked data
Propuesta de integración para el consumo de múltiples datasets de linked data
 

Dernier

GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdflior mazor
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Scriptwesley chun
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityPrincipled Technologies
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Drew Madelung
 
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
 
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
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptxHampshireHUG
 
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
 
Evaluating the top large language models.pdf
Evaluating the top large language models.pdfEvaluating the top large language models.pdf
Evaluating the top large language models.pdfChristopherTHyatt
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024Rafal Los
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - 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
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfsudhanshuwaghmare1
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdfhans926745
 
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
 
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
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsJoaquim Jorge
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)Gabriella Davis
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking MenDelhi Call girls
 
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
 

Dernier (20)

GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdf
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
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
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
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
 
Evaluating the top large language models.pdf
Evaluating the top large language models.pdfEvaluating the top large language models.pdf
Evaluating the top large language models.pdf
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - 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...
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
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
 
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
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 

05 Building cross-platform mobile applications with jQuery Mobile / Desarrollo de Aplicaciones Cross-Platform para Dispositivos Moviles

  • 1. Desarrollo de Aplicaciones Cross- Platform para Dispositivos Moviles Building Cross-Platform Mobile Applications M.S.C. Raquel Vásquez Ramírez M.S.C. Cristian A. Rodríguez Enríquez
  • 2. Contenido   •  Manejo  de  Base  de  Datos  (Client  Side)   •  Almacenamiento  Local   – Permanente   – Sesión   – Usando  Base  de  Datos   •  Conclusiones   Building Cross-Plaftform Mobile Applications – jQuery Mobile Slide 02 of 15
  • 3. HTML 5: Data Storage Building Cross-Plaftform Mobile Applications – jQuery Mobile Slide 03 of 15 HTML5 offers two types of data storage on the client: •  Storage via a database containing the tables described in SQL •  Storage through localStorage and sessionStorage objects, to store information made up of strings.
  • 4. Permanent Storage and Session Storage Building Cross-Plaftform Mobile Applications – jQuery Mobile Slide 04 of 15 Para habilitar el “Storage” se utilizan dos objetos de JavaScript: •  localStorage: Permite el almacenamiento permanente •  sessionStorage: Permite el almacenamiento en la sesión
  • 5. Permanent Storage Building Cross-Plaftform Mobile Applications – jQuery Mobile Slide 05 of 15 localStorage.lname = “Sarrion”; localStorage.fname = “Eric”;
  • 6. Building Cross-Plaftform Mobile Applications – jQuery Mobile Slide 06 of 15 Session Storage sessionStorage.lname = “Sarrion”; sessionStorage.fname = “Eric”;
  • 7. Building Cross-Plaftform Mobile Applications – jQuery Mobile Slide 07 of 15 Usando una Base de Datos Como se puede observar el almacenamiento temporal y permanente no provee las facilidades de las bases de datos SQL. Gracias a HTML 5 es posible usar bases de SQL de forma local.
  • 8. Building Cross-Plaftform Mobile Applications – jQuery Mobile Slide 08 of 15 Creando la Base de Datos var  db  =  openDatabase  (“Test”,  “1.0”,  “Test”,  65535);  
  • 9. Building Cross-Plaftform Mobile Applications – jQuery Mobile Slide 09 of 15 Transaction db.transacKon  (funcKon  (transacKon)     {          var  sql  =  SQL  query;          transacKon.executeSql  (sql,  [parameters]  /  undefined,            funcKon  ()          {                    //  JavaScript  code  to  execute  if  the  query  was  successful          },            funcKon  ()          {                    //  JavaScript  code  to  execute  if  the  query  failed          }  );   });  
  • 10. Building Cross-Plaftform Mobile Applications – jQuery Mobile Slide 10 of 15 Usando la Base de Datos •  Crear Base de Datos •  Insertar •  Listar (SELECT) •  Eliminar Tabla
  • 11. Building Cross-Plaftform Mobile Applications – jQuery Mobile Slide 11 of 15 CREATE TABLE db.transacKon  (funcKon  (transacKon)        {          var  sql  =  "CREATE  TABLE  customers  "  +                  "  (id  INTEGER  NOT  NULL  PRIMARY  KEY  AUTOINCREMENT,  "  +                  "lname  VARCHAR(100)  NOT  NULL,  "  +                    "fname  VARCHAR(100)  NOT  NULL)"          transacKon.executeSql  (sql,  undefined,  funcKon  ()          {                alert  ("Table  created");          },  error);      });  
  • 12. Building Cross-Plaftform Mobile Applications – jQuery Mobile Slide 12 of 15 DROP TABLE db.transacKon  (funcKon  (transacKon)        {          var  sql  =  "DROP  TABLE  customers";          transacKon.executeSql  (sql,  undefined,  ok,  error);      }  
  • 13. Building Cross-Plaftform Mobile Applications – jQuery Mobile Slide 13 of 15 INSERT INTO db.transacKon  (funcKon  (transacKon)        {          var  sql  =  "INSERT  INTO  customers  (lname,  fname)  VALUES  (?,  ?)";          transacKon.executeSql  (sql,  [lname,  fname],  funcKon  ()          {                alert  ("Customer  inserted");          },  error);      }  
  • 14. Building Cross-Plaftform Mobile Applications – jQuery Mobile Slide 14 of 15 Base de Datos Server Side (Elementos) var  sql  =  "SELECT  *  FROM  customers";   transacKon.executeSql  (sql,  undefined,…    
  • 15. Conclusiones   •  jQuery provee los elementos necesarios para desarrollar aplicaciones para dispositivos móviles •  Desarrollo Ágil •  Si se desea sincronizar datos con un servidor, se requiere usar una base de datos local y sincronizar cuando se disponga de conexión mediante una consulta constante del estado de la conexión (Push?) •  Optimización de Aplicaciones Web Building Cross-Plaftform Mobile Applications – jQuery Mobile Slide 15 of 15