130 likes | 310 Views
Adobe Presentation. Brijesh Patel | Working with AIR Native Extensions. What are Native Extensions?. Third party, native-code backed Actionscript API additions to AIR applications. Flash Builder. Android SDK & NDK. XCode. Adobe AIR. Visual Studio. Why Native Extensions ??.
E N D
Adobe Presentation Brijesh Patel | Working with AIR Native Extensions
What are Native Extensions? • Third party, native-code backed Actionscript API additions to AIR applications Flash Builder Android SDK & NDK XCode Adobe AIR Visual Studio
Why Native Extensions ?? • AIR is AWESOME !!! • Allows you to create cross platform applications • Rapid multiscreen development • A large feature set • But … • No access to device specific capabilities (Contacts, Notifications, Bluetooth,etc) • Waits for a native feature to mature before providing access to it • Porting existing applications to AIR might be a pain
Bridging the gap !!! • Provide access to device specific features • Native developers can reuse existing code • Actionscript API set can be extended • Same interface can be used on different platforms
Anatomy of an extension • A set of Actionscript classes • Associated native code for one or more target devices • A descriptor that contains deployment information • A signature to ensure secure delivery </desc>
Utilizing an extension • Step 1: Add ANE • Project Creation Wizard - Build Path • Project Properties – Flex Build Path • Extension Information • Extension ID • Minimum AIR Runtime Version • Signed • Targets • Google Android (Android – ARM) • iOS • Windows • Mac
Utilizing an extension • Step 2: Use ANE in code • Code hinting • Extension ID in App descriptor file
Debugging • On device makes sense! • Debugging info from native code depends on ANE
Package Settings • Where is it? • Project Properties • Flex Build Packaging • Flash Builder does for you: • Auto adjust package • ANE Validations • Extension ID • Native Library • Initializer • Finalizer • Developer can do: • Change package settings
Simulation • Run on desktop • To run/debug mobile app on desktop, ANE needs to target the desktop OS !
ANE for desktops • What you can do? • Computer intensive tasks • Hardware interfacing
Demo • Mobile ANE usage • Android • iOS • Desktop ANE usuage • Windows • Mac