Cross-Platform, Native Mobile Development                                       with Eclipse       @peterfriese | http://p...
cell phone usage is ubiquitous
cell phone usage is ubiquitous
s t                 e c             o pn e            h s           p a          r y         u r        o ve      se e ves...
People are !fferent
... so #ey have !fferent ta$es!
countless devices
diversity of platforms
Javapublic class SpeakersList extends GenericListActivity<Speaker> {	   List<Speaker> speakers;	   @Override	   public voi...
C#public partial class SpeakerDetailsDetailsView : PhoneApplicationPage{    public SpeakerDetailsDetailsView()    {       ...
Objective-C@implementation SpeakersListViewController- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection...
HTML{% extends "generated/application.html" %}{% block title%}Speakers{% endblock %}{% block content_class %}table list{% ...
server-side web                           Web Server                        executes application                          ...
client-side web     Web Browser      JavaScriptexecutes application logic  Files         Database          Device         ...
hybrid appNative App         Interpreter    Request   Interceptor         JavaScript Bridge          Browser     executes ...
interpreted appNative App         interpreter                  Database  Application    Script                       Files...
generated app    Generator Generator Input       Native App                               Logic     Logic      Modeldescri...
App Anatomy 101
Views
Views   Cells
Views Cells   Navigation
EntitiesViews                 SessionCells        title             roomNavigation
Views                 SessionCells        title             roomNavigationEntities                   ContentProviders
Views                 SessionCells        title             roomNavigationEntities                   ContentProviders
DSL for mobileViewsCellsNavigationEntitiesContentProviders
NavigationtabbarApplication itemisApp {	   button {	   	 title="News"	   	 icon="calendar.png"	   	 view=NewsList( Current...
Viewstableview SessionsList(Session[] sessions) {	 title= "Sessions"	 section {	   	   }	   }}
Cellstableview SessionsList(Session[] sessions) {	 title= "Sessions"	 section {	 	 cell Subtitle foreach items as item {	 ...
Entitiesentity Session {	 String title	 String id	 String room	 Date startTime	 Date endTime}
ContentProviders   contentprovider Sessions(String day) returns Session[]   	 fetches XML   	 from ("http://eclipsecon.org...
Demo :)
«Xpand»
Toolsmith’s point of view                            «Xpand»                  Parser                               Templat...
Extending Applause1. Create a new generator bundle         2. Provide build strategy           <extension point="org.appla...
twitter @peterfrieseblog    http://peterfriese.decompany http://www.zuehlke.com
Cross-Platform Native Mobile Development with Eclipse
Cross-Platform Native Mobile Development with Eclipse
Upcoming SlideShare
Loading in...5
×

Cross-Platform Native Mobile Development with Eclipse

2,642

Published on

Developing great apps for mobile platforms like Android, iOS or mobile web is a challenging task. Not only do you have to take into consideration the limited resources your app has at it's disposal, you also have to follow the established UI idioms - which may differ on the respective platforms.

In this session, I will demonstrate how you can build mobile apps with tools from the Eclipse ecosystem. Based on real-world examples I will present a domain-specific language we used to mobilize enterprise systems or to create the official Eclipse Summit Europe conference app (http://bit.ly/ese_app_de). What's more, I will show you how to overcome the tedium of having to manually port your application from one platform to other platform technologies such as Objective-C or Django/Python. Finally, I will show how to integrate Eclipse tooling with external tools such as Apple's Xcode and Google App Engine.

See http://lanyrd.com/2011/eclipsecon-europe/shhmy/

Published in: Technology
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total Views
2,642
On Slideshare
0
From Embeds
0
Number of Embeds
2
Actions
Shares
0
Downloads
116
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

Cross-Platform Native Mobile Development with Eclipse

  1. 1. Cross-Platform, Native Mobile Development with Eclipse @peterfriese | http://peterfriese.de http://www.zuehlke.com
  2. 2. cell phone usage is ubiquitous
  3. 3. cell phone usage is ubiquitous
  4. 4. s t e c o pn e h s p a r y u r o ve se e ves u ge e a w an our li m ofto
  5. 5. People are !fferent
  6. 6. ... so #ey have !fferent ta$es!
  7. 7. countless devices
  8. 8. diversity of platforms
  9. 9. Javapublic class SpeakersList extends GenericListActivity<Speaker> { List<Speaker> speakers; @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setTitle("Speakers"); speakers = getItemsFromProvider(); ArrayList<AbstractRowAdapter> rowAdapters = new ArrayList<AbstractRowAdapter>(); Iterable<Speaker> items1 = speakers; for (Speaker i : items1) rowAdapters.add(new Cell1(i)); setListAdapter(new GenericItemAdapter(this, rowAdapters)); finishCreation(); }
  10. 10. C#public partial class SpeakerDetailsDetailsView : PhoneApplicationPage{ public SpeakerDetailsDetailsView() { InitializeComponent(); } protected override void OnNavigatedTo(NavigationEventArgs e) { string selectedIndex = ""; if (NavigationContext.QueryString.TryGetValue("itemByIndex", out selectedIndex)) { int index = int.Parse(selectedIndex); DataContext = App.RootViewModelProvider.BlogpostsModelProvider().BlogItems[index]; } }}
  11. 11. Objective-C@implementation SpeakersListViewController- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section { if(section == 0) { return [[[contentProvider valueForKeyPath:@"content"] asArray] count]; } else return 0;}- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath { id item = [self.items objectAtIndex: indexPath.row]; IPContentProvider *provider = [(itemisAppProviders*)contentProvider.providers providerForSpeakerByName: [item valueForKeyPath:@"name"]]; SpeakerDetailsViewController *controller = [[SpeakerDetailsViewController alloc] init]; controller.contentProvider = provider; [self.navigationController pushViewController: controller animated: TRUE]; [controller release];}
  12. 12. HTML{% extends "generated/application.html" %}{% block title%}Speakers{% endblock %}{% block content_class %}table list{% endblock %}{% block content %}<ul>{% for s in data|to_list %} <li> {% url views.SpeakerDetailsBySpeakerByName s.name|urlencode as url %} <a href="{{ url }}"> <div class="cell_text">{{s.name|safe}}</div> </a> </li>{% endfor %}</ul>{% endblock %}
  13. 13. server-side web Web Server executes application logicWeb Browser Files Database Device Backend
  14. 14. client-side web Web Browser JavaScriptexecutes application logic Files Database Device Backend
  15. 15. hybrid appNative App Interpreter Request Interceptor JavaScript Bridge Browser executes JavaScript Device Backend
  16. 16. interpreted appNative App interpreter Database Application Script Files Device Backend
  17. 17. generated app Generator Generator Input Native App Logic Logic Modeldescribes logic and Database Database complete system Files FilesFiles Database Device Backend
  18. 18. App Anatomy 101
  19. 19. Views
  20. 20. Views Cells
  21. 21. Views Cells Navigation
  22. 22. EntitiesViews SessionCells title roomNavigation
  23. 23. Views SessionCells title roomNavigationEntities ContentProviders
  24. 24. Views SessionCells title roomNavigationEntities ContentProviders
  25. 25. DSL for mobileViewsCellsNavigationEntitiesContentProviders
  26. 26. NavigationtabbarApplication itemisApp { button { title="News" icon="calendar.png" view=NewsList( CurrentTimeline() ) } button { title= "Tue" icon= "calendar.png" view= SessionsList( Sessions("2011-11-03 ") ) } button { title= "Speakers" icon= "person" view= SpeakersList( AllSpeakers() ) }}
  27. 27. Viewstableview SessionsList(Session[] sessions) { title= "Sessions" section { } }}
  28. 28. Cellstableview SessionsList(Session[] sessions) { title= "Sessions" section { cell Subtitle foreach items as item { details= item.title action=NewsItemDetailView(item) } }}
  29. 29. Entitiesentity Session { String title String id String room Date startTime Date endTime}
  30. 30. ContentProviders contentprovider Sessions(String day) returns Session[] fetches XML from ("http://eclipsecon.org/ece2011?" day) selects "sessions.session"
  31. 31. Demo :)
  32. 32. «Xpand»
  33. 33. Toolsmith’s point of view «Xpand» Parser Templates Templates iPhone Android Grammar Editor describes DSL EMF MM
  34. 34. Extending Applause1. Create a new generator bundle 2. Provide build strategy <extension point="org.applause.lang.ui.buildstrate gy"> <buildstrategy class="org.applause.lang.generator.wp7.builder.W P7BuildStrategy"> </buildstrategy> </extension> 3. Provide template project orm"> <extension point="org.applause.lang.ui.mobileplatf <mobileplatform name="Windows Phone 7" projectNameSuffix="WP7" templateProject="templateproject/project.zip"> </mobileplatform> </extension>
  35. 35. twitter @peterfrieseblog http://peterfriese.decompany http://www.zuehlke.com
  1. A particular slide catching your eye?

    Clipping is a handy way to collect important slides you want to go back to later.

×