Your SlideShare is downloading. ×
0
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
iPhonical and model-driven software development for the iPhone
Upcoming SlideShare
Loading in...5
×

Thanks for flagging this SlideShare!

Oops! An error has occurred.

×
Saving this for later? Get the SlideShare app to save on your phone or tablet. Read anywhere, anytime – even offline.
Text the download link to your phone
Standard text messaging rates apply

iPhonical and model-driven software development for the iPhone

1,954

Published on

These are the slides of my talk "iPhonical and model-driven software development on the iPhone" at the German iPhone Developer Conference 2009 in Cologne. Unfortunately, this version does not include …

These are the slides of my talk "iPhonical and model-driven software development on the iPhone" at the German iPhone Developer Conference 2009 in Cologne. Unfortunately, this version does not include the 25+ minutes demos I presented during the talk.

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

No Downloads
Views
Total Views
1,954
On Slideshare
0
From Embeds
0
Number of Embeds
0
Actions
Shares
0
Downloads
82
Comments
0
Likes
7
Embeds 0
No embeds

Report content
Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
No notes for slide

Transcript

  • 1. iPhonicalSoftware Development and Model-Driven Heiko Behrens (itemis) backchannel via #iphonical #iphonedevcon09
  • 2. / soft·ware de·vel·op·ment / n. the set of activities that results in software products. ~ may include research, new development, modification, reuse, maintenance, or any other activities that result in software products.
  • 3. Sketching some Typical Situations in Software Development #iphonical #iphonedevcon09
  • 4. Boring code
  • 5. Accidental complexity
  • 6. Wrong level of abstraction
  • 7. Anatomy of Modern Software Software artifact
  • 8. Anatomy of Modern Software manually written code Frameworks Libraries
  • 9. Anatomy of Modern Software manually written code Frameworks schematic code (manually written) Libraries
  • 10. (rote) coding doesn’t cut it!
  • 11. Our Problems Can we solve them with code generation?
  • 12. Yes, we can!
  • 13. Talking about Common Approaches to Advoid Redundancy #iphonical #iphonedevcon09
  • 14. Wizards
  • 15. Wizards in Practice Ruby on Rails AppLoop Xcode Project Templates
  • 16. This wizard whips up a complete and running legacy application with just a single click.
  • 17. Designers
  • 18. Designers in Practice Graphical Designers Interface Core Builder Data
  • 19. Interface Builder is no abstraction but another approach to object construction. Handwritten code is still needed.
  • 20. Core Data produces code a developer can work with but overwrites handcrafted value.
  • 21. Introducing Model-Driven Software Development #mdsd #iphonical #iphonedevcon09
  • 22. Raise the level of abstraction where possible and generate code wisely.
  • 23. One cannot abstract away everything. Manual code is great for all the special cases and details.
  • 24. Use the best of both worlds at the same time.
  • 25. Isn’t Core Data #mdsd? #iphonical #iphonedevcon09
  • 26. Models Data Schema
  • 27. Sophisticated Runtime
  • 28. Demo
  • 29. So, what’s # iPhonical about? #iphonedevcon09
  • 30. View DSL View / GUI NIB Entity DSL ViewController ViewController Remote DSL Service DSL Transfomer ServiceFacades Mapper ORM / DAO RemoteClient Entities Messages Sqlite JSON HTTP Any ServerFacade RestService Server Server Entities Messages JBoss / RestEasy
  • 31. Thoughts of an iPhone developer
  • 32. View DSL View / GUI NIB Entity DSL Better Manually ViewController ViewController Remote DSL Service DSL What’s this? Transfomer ServiceFacades Mapper Core Data ORM / DAO Entities Framework Messages RemoteClient Sqlite JSON HTTP Any ServerFacade RestService Most likely Server Entities Server Messages legacy JBoss / RestEasy
  • 33. Will now present Objective Resource or “iPhone on Rails” #iphonical #iphonedevcon09
  • 34. Demo
  • 35. Entities with Objective Resource #import "ObjectiveResource.h" #import "ObjectiveResource.h" #import "Dog.h" #import "Person.h" @interface Person : NSObject { @implementation Person ! NSString *personId; @synthesize personId; ! NSDate *updatedAt; @synthesize updatedAt; ! NSDate *createdAt; @synthesize createdAt; ! NSString *name; @synthesize name; } // handle pluralization @property (nonatomic, retain) NSString *personId; + (NSString *) getRemoteCollectionName { @property (nonatomic, retain) NSDate *updatedAt; ! return @"people"; @property (nonatomic, retain) NSDate *createdAt; } @property (nonatomic, retain) NSString *name; - (NSArray *) findAllDogs { // returns dogs ! return [Dog findRemote:[NSString stringWithFormat: - (NSArray *) findAllDogs; @"%@/dogs", personId, nil]]; - (NSArray *) findAllDogsWithResponse: (NSError * *) aError; } @end - (NSArray *) findAllDogsWithResponse: (NSError * *) aError { ! return [Dog findRemote:[NSString stringWithFormat: @"%@/dogs", personId, nil] withResponse: aError]; } - (void) dealloc { ! [personId release]; ! [updatedAt release]; ! [createdAt release]; ! [name release]; ! [super dealloc]; } @end
  • 36. Real Information Content #import "ObjectiveResource.h" #import "ObjectiveResource.h" #import "Dog.h" #import "Person.h" @interface Person : NSObject { @implementation Person ! NSString *personId; @synthesize personId; ! NSDate *updatedAt; @synthesize updatedAt; ! NSDate *createdAt; @synthesize createdAt; ! NSString *name; @synthesize name; } // handle pluralization @property (nonatomic, retain) NSString *personId; + (NSString *) getRemoteCollectionName { @property (nonatomic, retain) NSDate *updatedAt; ! return @"people"; @property (nonatomic, retain) NSDate *createdAt; } @property (nonatomic, retain) NSString *name; - (NSArray *) findAllDogs { // returns dogs ! return [Dog findRemote:[NSString stringWithFormat: - (NSArray *) findAllDogs; @"%@/dogs", personId, nil]]; - (NSArray *) findAllDogsWithResponse: (NSError * *) aError; } @end - (NSArray *) findAllDogsWithResponse: (NSError * *) aError { ! return [Dog findRemote:[NSString stringWithFormat: @"%@/dogs", personId, nil] withResponse: aError]; } - (void) dealloc { ! [personId release]; ! [updatedAt release]; ! [createdAt release]; ! [name release]; ! [super dealloc]; } @end
  • 37. Objective-C #ftl ? #iphonical #iphonedevcon09
  • 38. Objective-C
  • 39. Suppose...
  • 40. You’d want to core an apple...
  • 41. ... for your kids.
  • 42. ? Right tool for the job
  • 43. Your trusty swiss army knife!
  • 44. Suppose...
  • 45. You’d want to core a few more apples...
  • 46. ... for an apple cake.
  • 47. Still the best tool for the job?
  • 48. Better use this one
  • 49. ...and this one
  • 50. ... a DSL is ...
  • 51. A specific tool for a specific job
  • 52. A specific tool for a specific job
  • 53. Idea behind #iphonical : Use DSLs to describe the world #iphonedevcon09
  • 54. ! ! entity Car { ! ! ! ! ! ! String name; ! ! ! ! ! ! String number; ! ! ! ! ! ! Integer km; ! ! ! ! ! ! JourneyEntry * journeys; ! ! }; ! ! ! ! ! ! ! ! entity JourneyEntry { ! ! ! ! Location startLocation; Entities ! ! ! ! ! ! Location endLocation; ! ! ! ! ! ! String comment; ! ! ! ! ! ! Integer startKm; ! ! ! ! ! ! Integer endKm; ! ! ! ! ! ! Car car; ! ! ! ! ! ! Driver driver; ! ! ! ! ! ! Reason reason; ! ! }; ! ! entity CarDataResponse { ! ! ! ! ! ! String creationDate; ! ! ! ! ! ! ! ! ! ! Car car; ! ! ! ! Location location; ! ! ! ! JourneyEntry journey; Services / Messages ! ! ! ! ! ! Driver driver; ! ! }; ! ! restService iDriveLogService "/idrivelogservice" { ! ! ! ! ! ! baseUrl "http://localhost:8080/iDriveLogRESTWebServices"; ! ! ! ! ! ! get data "/data" response:CarDataResponse; ! ! }; ! ! viewController Root { UI ! ! ! ! ! ! ui Label myLabel; ! ! ! ! ! ! ui Textfield myTextfield; ! ! ! ! ! ! action myAction; ! ! };
  • 55. Leverage Entity DSL for Objective Resource
  • 56. View / GUI Entity DSL ViewController Objective Resource Entities and Mapping JSON / HTTP Rails Application
  • 57. Demo
  • 58. Wait... #iPhonical works with any framework ? #iphonedevcon09
  • 59. Demo of custom templates
  • 60. #iPhonical: Where to get and its future #iphonedevcon09
  • 61. Open source Apache License 2.0 code code.google.com/p/iphonical/ Currently 8 participants
  • 62. What’s comming up? ! Publications in upcoming Eclipse Magazin ! ShowCase about Conferences ! Tighter integration with Xcode
  • 63. twitter @HBehrens blog http://HeikoBehrens.net mail Heiko.Behrens@itemis.de xing http://www.xing.com/profile/Heiko_Behrens linkedin http://www.linkedin.com/in/HeikoBehrens code.google.com/p/iphonical

×