Codestrong 2012 breakout session how to develop your own modules

  • Published on
    09-May-2015

  • View
    1.023

  • Download
    5

Embed Size (px)

Transcript

<ul><li>1.Introduction to Module Development Aaron K. SaundersFounder/CTO Clearly Innovative Inc@aaronksaundersaaron@clearlyinnovative.com</li></ul> <p>2. About Me Founder &amp; CTO Clearly Innovative Inc. Full stack development for mobile and web integrations w/javascript &amp; nodejs Appcelerator Platform Evangelist; Titan IOS and Android Module Development 2yrs of Appcelerator blogging Working on book with ACS and Alloy Integration 3. What thispresentation is about 4. Android Topics Introduction to module development, not advanced Basic integration of third party library and intent based library Understand the Titanium Studio Menu commands for scripts Understanding Ant build script on Android 5. IOS Topics Introduction to module development, not advanced Basic integration of third party library Understand the Titanium Studio Menu commands for scripts Understanding command line scripts 6. What thispresentation is notabout 7. Out of Scope Advanced view integration in modules Additional information on NDK integration on Android Addressing complex third party library conflicts on IOS 8. Android first becauseit needs some love 9. Your Environment Instructions on the wiki are your beststarting point Use the commands provided inTitanium Studio Be sure you have followed instructionsfor setting up Titanium Studio Installing Java Development Tools 10. Android ModuleQuickly 11. Create AndroidModule Select New Titanium Mobile Module Project from Menu Fill out all of the fields presented Save the project Edit the build.properties to point to the ANDROID_NDK path Run project 12. Run through script ondevice 13. Add somefunctionality 14. Skyhook SDK 15. Integration Steps Import 3rd party library Pass authentication credentials intomodule Setup callbacks in module Pass results back from module Render results 16. Edit app.js Instantiate the module object Create a proxy object Provide credentials to module Setup success and error callback Execute API method on proxy object 17. Edit app.js 18. Edit module file Remove the template method calls generated by script Create property for the username Create property for realm 19. Edit module file 20. Edit proxy file Get properties for username andrealm; framework does most of theheavy lifting for you Get the callback functions from thepassed in parameters 21. Edit proxy file 22. Edit proxy file 23. Edit proxy file So now we have all the data in Weneed to get the data out Create hashMap, add the objects andcall our callback 24. Code for completedmodule 25. IOS module 26. Your Environment Instructions on the wiki are your beststarting point Use the commands provided inTitanium Studio Be sure you have followed instructionsfor setting up Titanium Studio Installing IOS &amp; XcodeDevelopment Tools 27. Card.io SDK 28. Integration Steps Import 3rd party library Pass application key into module Setup callbacks in module Pass results back from module Render results 29. Libraries &amp;Headers 30. Edit app.js Instantiate the module object Provide application key to module Setup success and error callback Execute API method on module 31. Edit app.js 32. Edit header file Set the interface for the card.io delegate Set up private variable for the function callback with success or error information 33. Edit header file 34. Edit module file Remove the template method calls generated by script Make sure we de-allocate any memory that we have allocated Get the parameters from the javascript passed into objective-c Make card.io API call to display card capture information 35. Edit module file 36. Edit module file Handle the response from the UI after it is rendered Handle the two delegates from API for user cancel or data entered Pass a new hashmap containing results back to the javascript app 37. Edit module file 38. Edit module file 39. OVERLOAD!! Blog posting next two weeks All code provided on github Additional Intent based module included 40. Aaron K. Saunders @aaronksaundersaaron@clearlyinnovative.com blog.clearlyinnovative.com </p>

Recommended

View more >