Native Apps and Web Apps - JBoss...Native Apps and Web Apps iOS Native App Native App Native App...

Preview:

Citation preview

Native Apps and Web Apps

iOS

NativeApp

NativeApp

NativeApp

NativeApp

NativeApp

NativeApp

NativeApp

NativeApp

WebAppWebApp

WebAppWebApp

Desktop OSs

Desktop Browsers

Mobile Browsers

Android Blackberry

One Tool, One Language, One Codebase

Any Platform

Flex Application

AIR Flash Player

Goal of the Flash Platform

iOS Desktop OSs

Desktop Browsers

Mobile Browsers

Android Blackberry

Flash Platform - A complete system for web innovation

MXML and ActionScript

XML/HTTPREST

SOAP Web Services

How Flex WorksBrowser

J2EE Application Server

BlazeDS orLC Data Services

Flash Player

Web Server

Existing Applications and Infrastructure

Flex Builder IDE

Flex SDKMXML ActionScriptFlex Class Library

.swf

Compile

.swf

HTTP/S AMF/S RTMP/SSOAP

Adobe AIR

Deploying AIR Mobile Applications

App.apk

App.air

Android Market Android Device

App.ipk iTunes App Store iOS Device

App.bar BlackBerry App World RIM Device

Mobile Applications in "Hero"s:TabbedApplication s:ViewNavigatorApplications:Application

1

ViewNavigatorApplication and TabbedApplication

• View stack metaphor– View– ViewNavigator / TabbedViewNavigator

• Built-in mobile navigation experience– Action bar– Back button– Transitions– APIs

ViewNavigator API

• navigator.pushView();• navigator.popView();• navigator.popToFirstView()

• navigator.activeView;

2

ActionBar

<s:View xmlns:fx=http://ns.adobe.com/mxml/2009 …title=”Expenses">

<s:navigationContent><s:Button icon="@Embed('assets/home.png')"/>

</s:navigationContent>

<s:actionContent><s:Button label=”+"/>

</s:actionContent>

</s:View>3

navigationContent titleContent actionContent

View Lifecycle

• Alternative option: destructionPolicy=“none”

View becomes activeView

Created

Another view becomes active

View Destroyed User

navigates back to view View

Recreated

data

3B

Mobile ItemRenderers• ItemRenderer• IconItemRenderer

<s:IconItemRendererlabelField="lastName" messageField="title"iconField="picture"decoratorClass=”phoneIcon">

4

Flex with Java via Text-based Serialization

Web Service

Client

App Server

XML, JSON, etc

(RESTful / SOAP)

Remoting Performance Example

Flex with Java via Binary Serialization

BlazeDS

Spring Bean

Client

App Server

POJO

EJB

Other

Endpoint

AMF

Flex with Java via Messaging

MessageService

BlazeDS

Adapter Y

Adapter X

MessagingSystem Y

MessagingSystem X

Endpoint JMSProviderJMS Adapter

PublisherSubscriber

AMF

App Server

Recommended