Explore the UiPath Community and ways you can benefit on your journey to auto...
Migrating JavaME Apps to Android
1. hello “ Here’s some great tips for migrating your Java ME apps to Android” Eric Hildum, Motorola Martin Wrigley, Orange
2. Transitioning to Android Android for Java ME developers Eric Hildum Senior Product Manager Motorola
3.
4.
5.
6.
7. ANDROID MANIFEST <?xml version="1.0" encoding="utf-8"?> <!-- Copyright (C) 2007 The Android Open Source Project Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. Copyright (C) 2009 Motorola, Inc. --> <!-- Declare the contents of this Android application. The namespace attribute brings in the Android platform namespace, and the package supplies a unique name for the application. When writing your own application, the package name must be changed from "com.example.*" to come from a domain that you own or have control over. --> <manifest xmlns:android="http://schemas.android.com/apk/res/android" package="com.example.android.helloactivity"> <!-- The application tag supplies the name as presented to the end user. Note that this name is specified by a resource id. This allows you to localize the name in the appropriate strings.xml file. --> <application android:label="@string/application_name"> <!-- The application contains an activity named HelloActivity --> <activity android:name="HelloActivity"> <intent-filter> <!-- MAIN indicates that this activity is the one that should be started when the application is started --> <action android:name="android.intent.action.MAIN"/> <!-- LAUNCHER indicates that this is the activity that should be shown in the application Launcher --> <category android:name="android.intent.category.LAUNCHER"/> </intent-filter> </activity> </application> </manifest>
16. HELLO WORLD JAVA /* * Copyright (C) 2007 The Android Open Source Project * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. * * Copyright (C) 2009 Motorola, Inc. */ package com.example.android.helloactivity; import android.app.Activity; import android.os.Bundle; /** * A minimal "Hello, World!" application. */ public class HelloActivity extends Activity { public HelloActivity() { } /** * onCreate is called when the activity is first created. */ @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); // Set the layout for this activity. You can find it // in res/layout/hello_activity.xml by default, or in a localized // version in the res/layout_* directories. // Notice that the view is referenced by id. This allows the correct // layout to be selected based on local, geometry, and orientation. // Many sample applications in tutorials will show the layout being // specified by a string - a reference to a specific file. // DO NOT do this! Always use an id instead. setContentView(R.layout.hello_activity); } }
22. BOTTOM LINE Bottom line: many concepts are directly transferable, but the application model, UI framework, display characteristics, and data persistence are different enough that most applications will need to be significantly rewritten for Android
23.
24. Legal Copyright (2009), Motorola, Inc. All rights reserved except as otherwise explicitly indicated. The information offered in this presentation is offered on an "AS IS" basis, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. In addition, Motorola disclaims all liability from the use or inability to use the information provided. The entire risk as to the quality and performance of the information in this presentation is with you. The presentation may contain certain sample source code in the form of example applications and code fragments. Motorola grants you a limited personal, non-exclusive, and revocable license to: (i) use the sample source code internally to develop, test, evaluate and demonstrate software applications for use solely with or on Motorola wireless handset products, and (ii) incorporate the sample source code into the applications and distribute the applications in binary form only, provided that you include any copyright notice that appears in the sample source code.
25. Legal Copyright (C) 2007 The Android Open Source Project Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
28. how to submit newly developed apps www.orangepartner.com
29. #adevinar please address your questions to the ‘host’ using the ‘chat’ to the right of your screen. OR use Twitter and send us your comments or questions using the following hash tag #adevinar questions?
30. #adevinar thank you tell us what you thought #adevinar @OrangePartner @Motodev www.orangepartner.com developer.motorola.com
Editor's Notes
Hello, Welcome to the second Orange and Motorola Webinar “'Here’s some great tips for migrating your Java ME apps to Android'”. I am the Director of Developer Services for Orange and I’ll be hosting today’s webinar. We know that many of you joined us two weeks ago to learn how to develop Android apps using the MOTODEV studio. So welcome back. We hope you’ve already started using this intuitive tool. For those who didn’t join us, but wanted to, then we’ll follow up with you after the webinar to show you where you can access the slides and the STUDIO. Before I hand over to Eric of Motorola, I’d like begin by saying that making sure your apps work seamlessly is really important to both Orange and Motorola. We want to help you to develop apps with the least effort possible, and we are looking at the ways in which we can help you. These webinars are a start and there is a wealth of resource out there from both MOTODEV and Orange Partner. I’ll explain how you can access this resource a little bit later in the webinar, plus I’ll update you on a testing initiative that Motorola and Orange are involved in for Android apps. But as I said, more about that later. But for now, I’ll hand you over to Eric Hildum, Senior Product Manager at Motorola to talk you what you need to know when migrating your Java ME app to Android. And one last thing, we’d really encourage you to ask us questions. At the end of the webinar we’ll have dedicated time for questions and answers, so please, don’t hold back. Ask away or send us your comments for discussion. If there is anything you want to know specifically about Eric’s session or generally about developing with Orange or Motorola at all then please send them via the chat and we’ll address them at the end of the webinar. There is also a twitter feed to send us your thoughts. Do so using the hash tag “ adevinar ”. Over to you Eric….
Android hardware requirements from early Google site describing the Platform Development Kit dated 9-June-2008. Compare Android device requirements with Pismo Powerbook introduced in 2000.
Conclusion: Motorola and Orange: working together to help you Motorola is working closely with Orange to ensure that you: the MOTODEV and Orange developer community has the information and resources they need to successfully develop, test, and distribute Android applications. We want to help you. These webinars are a start, we have ongoing support through both our developer programmes: As Eric just touched on, there is a world of a lot of resource through MOTODEV - the Motorola developer network that’s dedicated to opening up the potential of Android to every developer. Just go to the website, to access, tools and documentation, community support. ( developer.motorola.com – we’ll provide the links at the end of the webinar). On the Orange side, all you need to do is go to the Orange Partner website to see what help we can offer you in developing your apps. Testing your apps on the Orange network and devices is really important to us. This is why we have world wide Orange Developer centres. There are also virtual developer centres. You can find device specs and many other tools for testing. (Martin to expand here on the apps support we provide) You’ll see we place a lot of emphasis to help you to test, test, and test again. I wanted to let you know that we're working with Motorola and others to produce - initially - some guidelines / test cases against which developers can test Android apps. We're all aware of the need for this within the industry, and both Orange and Motorola are at the forefront in helping to do something about it. And whatever we do, we're going to do it quickly. But we need your help. We need to know what you feel the problematic areas are: the areas that cause the errors in testing? Let us know and send us your thoughts.
AND FOR YOUR DEVELOPED ANDROID APPS, HERE IS THE ORANGE APP SHOP: One click access to apps from the Orange device home screen A small selection of suitable apps, regularly updated Availability on major devices platforms / OS (Blackberry, Java, Android, WM,.. ) Easy discovery and content selection, through an animated store front One-stop experience billed to their Orange bill: no registration required Automatic download & installation of application on devices One click to launch downloaded applications And that’s exactly what we’ve delivered with the Orange App Shop. It’s a straightforward, honest, dynamic, refreshing and friendly shop front housing a comprehensive catalogue of Orange-branded and 3rd party games, applications, wallpapers and ringtones. You can see the latest apps available, search for apps within the catalogue, view the best-sellers, and store your downloaded apps in your ‘my stuff’ folder. It’ll be available across multiple platforms and on numerous devices. And we’re particularly pleased with the ‘my stuff’ folder, and you’ll see why in a minute ... Let’s take a look at the App Shop client, but before we do, it’s important to stress that the other distribution points for apps are still available in the countries. People can still download apps from Orange World in the UK, France, Spain and Belgium. It’s available on all java devices and most Symbian, Android, WM devices. So, the new App Shop client won’t necessarily replace the existing routes-to-market for applications, it’ll complement them.