TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
Â
Android Services Skill Sprint
1. embt.co/sprint-android-servicesBlog Notes:
Android Services
for Background Execution
Developer Skill Sprint
Tips, Tricks and Techniques
The Ultimate Application Development platform for
Widows 10, Mac, Mobile and IoT
Jim McKeeth
Developer Evangelist / Engineer
Embarcadero Technologies
Jim.McKeeth@Embarcadero.com
Nov 10th, 2015
@JimMcKeeth
2. embt.co/sprint-android-servicesBlog Notes:
This Skill Sprint Works with . . .
⢠Windows
⢠OS X
⢠Android
⢠iOS
⢠RAD Studio
⢠Appmethod
⢠Object Pascal
⢠C++
⢠RAD Studio 10 Seattle DocWiki
â http://docwiki.embarcadero.com/RADStudio/Seattle/en/
⢠Appmethod Summer 2015 Release DocWiki
â http://docwiki.appmethod.com/appmethod/1.17/topics/en/
⢠Appmethod supports the FireMonkey
framework on all four platforms while RAD
Studio, Delphi and C++Builder also support
VCL on Windows. Contact sales with any
questions!
5. embt.co/sprint-android-servicesBlog Notes:
Android Services vs. Threads
Android Services
⢠Cannot access the UI
⢠Runs in main thread of
host app process
⢠Can contain multiple
threads
⢠Used for long running
processes
Threads
⢠Cannot access the UI
⢠Not accessible to other
apps
⢠Terminated with app
⢠Used to improve
responsiveness
6. embt.co/sprint-android-servicesBlog Notes:
Android Service Type Variations
⢠IntentService
â Handle asynchronous requests (onHandleIntent(Intent) event)
â Otherwise are syncronous (onStartCommand(Intent) event)
â Both are Bindable (onBind event)
⢠Local vs. Remote
â Local only accessible by host (exported = false in manifest)
â Remote cross app access (exported = true in manifest)
7. embt.co/sprint-android-servicesBlog Notes:
Android Service Wizard
⢠Local Service
â Synchronous local access
⢠Intent Local Service
â Asynchronous local access
⢠Remote Service
â Synchronous local & remote access
⢠Intent Remote Service
â Asynchronous local & remote access
10. embt.co/sprint-android-servicesBlog Notes:
Service Workarounds
⢠Use RTL or low-level calls instead of FMX
components. If the service fails when started, use a
lower level call.
⢠Manually edit manifest to make remote services
published.
⢠Manually edit Java Templates for Intent and
Remote Services (See http://delphi.org/?p=2084)
11. embt.co/sprint-android-servicesBlog Notes:
Learning Resources
⢠DocWiki
â http://docwiki.embarcadero.com/RADStudio/Seattle/en/Android_Service
â http://docwiki.embarcadero.com/RADStudio/Seattle/en/Creating_Android_Services
⢠CodeRage X â Android Services on YouTube
â http://embt.co/crx-android-services
⢠Blog Posts
â http://delphi.org/tag/android-services/
â http://community.embarcadero.com/blogs/entry/download-an-image-in-background-
with-android-services
Download a free trial!
embt.co/trialdownloads
12. embt.co/sprint-android-servicesBlog Notes:
Next Time . . .
GPU Computing with OpenCL
See the full schedule and replays at embt.co/Sprints15
⢠Tuesday, the 17th of November, 2014
â 6AM San Francisco / 9AM New York / 2PM London / 3PM Milan
â 11AM San Francisco / 2PM New York / 7PM London / 8PM Milan
â 5PM San Francisco / Wed 10AM Tokyo / Wed 12PM Sydney
(Based on San Francisco time. Verify your local time are correct: http://embt.co/nov17thtimes)
Download a free trial!
embt.co/trialdownloads
14. embt.co/sprint-android-servicesBlog Notes:
Q&A
Developer Skill Sprint
Tips, Tricks and Techniques
The Ultimate Application Development platform for
Widows 10, Mac, Mobile and IoT
Jim McKeeth
Developer Evangelist / Engineer
Embarcadero Technologies
Jim.McKeeth@Embarcadero.com
November 10th, 2015
@JimMcKeeth
Thank-You!
Download a free trial!
embt.co/trialdownloads