Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.

30-To-Launch #3 - Data and Networking

1,385 views

Published on

Published in: Technology
  • Be the first to comment

30-To-Launch #3 - Data and Networking

  1. 1. WIRELESS: softlayer - techwildData andNetworkingChris Koenigchris.koenig@microsoft.com214-385-5616@chriskoenig |http://chriskoenig.net
  2. 2. 30-to-Launch Program Overview Session 1 Session 2 Session 3 Session 4• Overview of • Exploring Windows • Working with Data • Windows Phone Windows Phone Phone Capabilities • App Resources Marketplace • Metro Design • Live Tiles • Isolated Storage • Application • Tour: Expression • Sensors & • Database submittal process Blend Camera • Networking Stack • How to handle • Tour: Visual Studio • Launchers • Social Integration rejection • Building, Running • Choosers • Promoting your and Debugging • Search Integration application Your First App • Advertisements • Help submitting • Online Resources your app to the• Signup for Marketplace Marketplace 2 Windows Phone
  3. 3. Today’s Agenda Proxomo Isolated Storage Databases on Windows Phone Networking Stack Social Sharing 3 Windows Phone
  4. 4. Proxomo
  5. 5. Isolated Storage
  6. 6. Isolated Storage Windows Phone
  7. 7. Using Isolated Storage inWindows PhoneDemohttp://github.com/chriskoenig/isolatedstorage
  8. 8. Databases
  9. 9. SQL Server on Windows Phone Based on SQL Server Compact Edition 3.5 Runtime is distributed with the operating system Interaction managed through LINQ to SQL’s code-first model  Create classes that represent tables  Annotate classes and fields/properties with [Table] and [Column] attributes  Create a custom DataContext object to manage interactions Automatic conversion of data types  Properties are available Encrypt the database using a password on 9 Windows Phone the connection string
  10. 10. Local Data Storage: OverviewApps store private data in Isolated Storage Settings and properties in the app dictionary App Root Folder Unstructured data in Isolated Storage files Structured data in database files Install Creates root folder Package sandboxed to App Database Manager file (r/o) App Data Folder Creates/manages App files and settings WP7 Isolated Storage APIs Application Application Settings file files Database file10 Windows Phone
  11. 11. Inserts/Updates/Deletes Actions made on the objects and collections Your app code  Create new objects  Add objects to collections Name Yellow Tail Name Little Managed by the DataContext Penguin Varietal Pinot Noir Varietal Pinot Noir  Changes made against AtHome True AtHome True False the DataContext first  Changes persisted by calling SubmitChanges() SubmitChanges  LINQ to SQL determines change set and submits to DB11 Windows Phone
  12. 12. Using SQL CE for WindowsPhoneDemohttp://github.com/chriskoenig/databaseformango
  13. 13. Networking Stack
  14. 14. Networking Stack WebClient HttpWebRequest / HttpWebResponse XML JSON Custom14 Windows Phone
  15. 15. WebClient Simple API  DownloadStringComplete  DownloadStringAsync GET verb Anonymous authentcation Runs on the UI Thread15 Windows Phone
  16. 16. HttpWebRequest More complex api Access to the request stream and response stream Support all HTTP verbs Support basic authentication Runs on the background thread Windows Phone
  17. 17. XML Located in System.Xml.Linq namespace XDocument LINQ to XML Windows Phone
  18. 18. JSON No built-in support for JSON (ish) Recommended to use JSON.NET  JsonConvert.Deserialize<T>  JsonConvert.Serialize() Windows Phone
  19. 19. Networking with XML and JSONDemohttp://github.com/chriskoenig/NetworkingXmlAndJson
  20. 20. Social Integration
  21. 21. Sharing with… Defined Social Networks (i.e. Twitter, Facebook) Share from your app  ShareLinkTask  ShareStatusTask Integrate into Windows Phone  Photos_Extra_Hub  Photos_Extra_Share Windows Phone
  22. 22. Social Sharing with WindowsPhoneDemohttp://github.com/chriskoenig/socialsharing
  23. 23. Homework Start wrapping up your project Test on the device Start generating the required images Ping me for help with roadblocks23 Windows Phone
  24. 24. http://bemyappdallas.eventbrite.co m/ BeMyApp Feb 24-26, Dallas 2012
  25. 25. http://mobileappdfw2.eventbrite.com AT&T Mobile App Hackathon! Come build your mobile app with us. We will have 5+ senior mobile application developers that will be directly assisting you with your mobile application development efforts. Come to network. Come to learn. Come to hang out! Where? AT&T Foundry - 2900 West Plano Parkway, Plano, TX 75075 When? Friday Feb 17th at 6PM and all day Saturday!
  26. 26. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.© 2011 Microsoft Corporation.All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries.

×