Connect 2014 JMP 104 Mats Jansson and Fredrik Paulsson
-
Upload
mats-jansson -
Category
Documents
-
view
127 -
download
4
Transcript of Connect 2014 JMP 104 Mats Jansson and Fredrik Paulsson
© 2014 IBM Corporation
JMP 104: Demystifying the Roadmap From IBM Domino Applications to the Mobile App Stores
Mats Jansson, Donova ABFredrik Paulsson, Donova AB
1
Speaker bio
Mats [email protected]
Consulting in Lotus since first Symphony (1975) CEO, Technical and Sales lead of Donova Or at least tries to be some of it.. Member of board, Donova AB PCLP since v4.0 Instructor iOS and Android developer in Xcode and Eclipse Over 15 apps in both technologies Lotusphere friends map for IOS
Fredrik [email protected]
Developer with 15 Yrs experience. PCLP since R5 IBM Certified Advanced Instructor XPages Member of board, Donova AB
Donova AB
12 Years of focused work in IBM Collaboration IBM Premier Business Partner 11 consultants with edge competence Active worldwide Located in Sweden

Agenda
Welcome
Why bother building native apps.
Demystifying the the appstores.
Basic mobile webpage
Put it in a native app
Using Java in ADT
And Objective-C in Xcode
Build the data stream with XAgent
Consume it in the app
Its a wrap!
Q&A

Related sessions
AD304 : The Power of Collaborating IBM Domino, IBM Connections and IBM WorklightMon, 27/Jan 03:45 PM - 04:45 PM
AD504 : Build and Optimize Mobile Experiences with IBM WebSphere Portal and IBM Web Content ManagerTue, 28/Jan 11:15 AM - 12:15 PM
AD501 : IBM Worklight for IBM Domino DevelopersTue, 28/Jan 04:15 PM - 05:15 PM
AD502 : The Mobile Distruption: Why XPages Development is Targeting Mobile FirstThu, 30/Jan 08:30 AM - 09:30 AM
AD503 : XPages Mobile Development in IBM Domino 9.0.1 and BeyondThu, 30/Jan 10:00 AM - 11:00 AM
BP201 : Creating a Mobile Application Framework with XpagesTue, 28/Jan 03:00 PM - 04:00 PM
BP209 : IBM Worklight: Going From XPages Mobile to Native Mobile ApplicationsThu, 30/Jan 11:15 AM - 12:15 PM
© Copyright IBM Corporation 2014. All rights reserved.
U.S. Government Users Restricted Rights - Use, duplication or disclosure restricted by GSA ADP Schedule Contract with IBM Corp.
IBM, the IBM logo, ibm.com,, and IBM Domino are trademarks or registered trademarks of International Business Machines Corporation in the United States, other countries, or both. If these and other IBM trademarked terms are marked on their first occurrence in this information with a trademark symbol (® or ™), these symbols indicate U.S. registered or common law trademarks owned by IBM at the time this information was published. Such trademarks may also be registered or common law trademarks in other countries. A current list of IBM trademarks is available on the Web at “Copyright and trademark information” at www.ibm.com/legal/copytrade.shtml
The "Android" name, the logo, and other trademarks are property of Google Inc.
RIM is the owner of the ubiquitous BlackBerry® family of trademarks.
Xcode, ios and Cocoa is a trademark of Apple inc.
Other company, product, or service names may be trademarks or service marks of others.
Availability. References in this presentation to IBM products, programs, or services do not imply that they will be available in all countries in which IBM operates.
The workshops, sessions and materials have been prepared by IBM or the session speakers and reflect their own views. They are provided for informational purposes only, and are neither intended to, nor shall have the effect of being, legal or other guidance or advice to any participant. While efforts were made to verify the completeness and accuracy of the information contained in this presentation, it is provided AS-IS without warranty of any kind, express or implied. IBM shall not be responsible for any damages arising out of the use of, or otherwise related to, this presentation or any other materials. Nothing contained in this presentation is intended to, nor shall have the effect of, creating any warranties or representations from IBM or its suppliers or licensors, or altering the terms and conditions of the applicable license agreement governing the use of IBM software.
All customer examples described are presented as illustrations of how those customers have used IBM products and the results they may have achieved. Actual environmental costs and performance characteristics may vary by customer. Nothing contained in these materials is intended to, nor shall have the effect of, stating or implying that any activities undertaken by you will result in any specific sales, revenue growth or other results.
Acknowledgements and Disclaimers

6
Why bother developing native apps

7
Mobile web apps
You and the audience know each other
Marketing the app is not and issue
Quick access to common information
No time for searching and digging for a solution
No need for hardware resources
Gyro, Camera, GPS, local storage …
No need for payment of the solution itself.
8
Native apps
You need a marketing channel
App stores have a very good marketing impact
Payment made easy
You do not need to use a web shop like PayPal or other.
Access all hardware features
Native api's with good performance
9
Hybrid apps
Bring the two together
Native navigation
Web based presentation
Native shell around the web app
Most common app types
List or Table
WebView Map Game or openGL

12
Demystifying the app stores

The App Stores

Windows Store
Not covered any more in this session!
Uses Visual Studio
Develop in C#, C++, Visual Basic or Java Script.
No support for OpenGL , uses DirectX instead
Two account types - Single user account – Company account
$19 or $99 annually
Will be certified by humans
120000 apps

Blackberry World
Also not covered in this session
Use Adobe Air, HTML5, Javascript, C++, Java and more
Use Eclipse, Visual Studio, Cascade or Core to develop
Sign Your own apps and publish on Blackberry World
Approval process made by humans at Blackberry.
No annual fee
120000 apps

Android – Google Play
Register for a Google Play publisher account and pay $25
If you want to sell apps, set up a Google Wallet Merchant Account
Explore the Google Play Developer Console and learn about the tools for publishing
Write Your code in Eclipse and the plugin ADT using Java
Apps are certified by You
1 million apps

Example Google play user UI

Google Play Console

Google Play Console

iTunes Appstore
Convince Your boss to buy You a Mac and the handheld device!
Download Xcode from Appstore – It is free!
Register as a developer on apple.com and pay an annual fee of $99
Your apps will be deeply reviewed by humans
Follow the guidelines and respect not less than a week timeframe.
A huge community with examples and support
1 million apps

iTunes appstore rewiew guidelines
We have lots of kids downloading lots of apps, and parental controls don't work unless the parents set them up (many don't). So know that we're keeping an eye out for the kids.
We have over one million apps in the App Store. We don't need any more Fart apps. If your app doesn't do something useful or provide some form of lasting entertainment, it may not be accepted.
If your App looks like it was cobbled together in a few days, or you're trying to get your first practice App into the store to impress your friends, please brace yourself for rejection. We have lots of serious developers who don't want their quality Apps to be surrounded by amateur hour.
We will reject Apps for any content or behavior that we believe is over the line. What line, you ask? Well, as a Supreme Court Justice once said, "I'll know it when I see it". And we think that you will also know it when you cross it.

Itunes appstore rewiew guidelines (cont.)
If your app is rejected, we have a Review Board that you can appeal to. If you run to the press and trash us, it never helps.
If you attempt to cheat the system (for example, by trying to trick the review process, steal data from users, copy another developer's work, or manipulate the ratings) your apps will be removed from the store and you will be expelled from the developer program.
This is a living document, and new apps presenting new questions may result in new rules at any time. Perhaps your app will trigger this.
Lastly, we love this stuff too, and honor what you do. We're really trying our best to create the best platform in the world for you to express your talents and make a living too. If it sounds like we're control freaks, well, maybe it's because we're so committed to our users and making sure they have a quality experience with our products. Just like almost all of you are too.

Itunes connect

Itunes connect sales trends

What about private (corporate) apps?
IOS alt 1
IOS Developer Enterprise Program
Internal apps
$299 / year
IOS alt 2
Apple Volume Purchase Program
Develop a custom B2B apps
Android
Google Play private channel
Requires a domain on Google Apps , Education or Government
$25 / year

26
Basic mobile webpage and ExtLib
Basic mobile webpage
Pros and cons of mobile web apps.
ConsThe mobile needs to be online.UI/UX not feel exactly like other native apps.If Domino is down, nothing works.If you have a bad connection, it´s behaves slowly and user will probably complain.
ProsEasy to administer.Easy to develop.Easy to update. You do not need to upload the app after modification.You do not need to use the Apple App store, Google Play for Android or other app store.
Basic mobile webpage
viewportRight window/image is an XPage with a view included and without viewport while the left uses the viewport.
<meta name = "viewport" content = "width = 320, initial-scale = 1.0, maximum-scale = 1.0, user-scalable = no">
Basic mobile webpage
All parameters for viewport
There are six different set up to get a mobile interface if you insert the following (viewport).Also works on native web pages/Xpages.
widthThe width of the viewport in pixels. The default is 980. The range is from 200 to 10,000.heightThe height of the viewport in pixels.initial-scaleThe initial scale of the viewport as a multiplier. You can set only the initial scale of the viewport—the scale of the viewport the first time the webpage is displayed. Thereafter, the user can zoom in and out unless you set user-scalable to no. Zooming by the user is also limited by the minimum-scale and maximum-scale properties.
minimum-scaleSpecifies the minimum scale value of the viewport. The default is 0.25. The range is from >0 to 10.0.maximum-scaleSpecifies the maximum scale value of the viewport. The default is 5.0. The range is from >0 to 10.0.user-scalableDetermines whether or not the user can zoom in and out—whether or not the user can change the scale of the viewport. Set to yes to allow scaling and no to disallow scaling. The default is yes.Setting user-scalable to no also prevents a webpage from scrolling when entering text in an input field.
Basic mobile webpage
For example, to set the viewport width to the width of the device, add this to your HTML file:<meta name="viewport" content="width=device-width">
To set the initial scale to 1.0, add this to your HTML file:<meta name="viewport" content="initial-scale=1.0">
To set the initial scale and to turn off user scaling, add this to your HTML file:<meta name="viewport" content="initial-scale=2.3, user-scalable=no">
Basic mobile webpage
A few other properties for mobile (Supported Meta Tags)
Set fullscreen to web app.Set the following meta tag to enable fullscreen mode when the user saved the URL of your app
to his home screen (then your app looks like it is a standalone app):<meta name="apple-mobile-web-app-capable" content="yes">
You can control the color of the topmost status bar with this meta tag:<meta name="apple-mobile-web-app-status-bar-style" content="black">Note: This meta tag has no effect unless you first specify full-screen mode as described in “apple-mobile-web-app-capable.”
You can set an icon used for the device's home screen:<link rel="apple-touch-icon" href="/apple-touch-icon.png">(Size 57x57 pixels, format PNG.)Note: It is recommended to name the icon 'apple-touch-icon.png'.
You can set a 'splash screen', that means an image that is displayed while the app (web page) is loaded:
<link rel="apple-touch-startup-image" href="/startup.png">In the above example, replace startup.png with your startup screen filename. On iPhone and
iPod touch, the image must be 320 x 480 pixels and in portrait orientation.
Demo
Include viewport in an XPage and see the difference for an XPage without viewport.
Basic mobile webpage and ExtLib - Settings to use ExtLib Mobile
Useful setting for working with ExtLib Set the Mobile Page Prefix in the XPages Application Properties for the XPages
Mobile Theme. Enabling it for the XPages Extension Library.
Basic mobile webpage and ExtLib - Settings to use ExtLib Mobile
Basic mobile webpage and ExtLib - Settings to use ExtLib Mobile
Demo
See the same view as used in Xpage before but with ExtLib Mobile.
37
29
Use in a native app
Android Development Tool
Plugin for the Eclipse IDE Android is developed by Google Inc. Java (preferred)

Android Development Tool

Demo
We are going to build a native app.
Use a built in browser
Automatically open the website in there and have it remain there.
Hybrid app


Xcode
The RAD tool from Apple
Used to develop apps with for example Objective-C Includes editor, compiler , simulator and more.

Cocoa Touch Frameworks
Built on Objective-C UI Kit
Graphics and AnimationCore AnimationOpenGL ESQuartz 2D
User ApplicationsAddress BookCore LocationMap KitStore Kit
Data ManagementCore DataSQLite
Networking and InternetBonjourWebKitBSD Sockets
Audio and VideoCore AudioOpenALMedia LibraryAV Foundation

Objective -C
Objective-C
is a general-purpose, object-oriented programming language that adds Smalltalk-style messaging to the C programming language.
It is the main programming language used by Apple for the OS X and iOS operating systems and their respective APIs, Cocoa and Cocoa Touch.
An IOS App Is Built from a Network of Objects
When building apps for iOS, you’ll spend most of your time working with objects. Those objects are instances of Objective-C classes, some of which are provided for you by Cocoa or Cocoa Touch and some of which you’ll write yourself.

Xcode – the flow

The UI of Xcode

Demo
We are going to build a native app.
Use a built in browser
Automatically open the website in there and have it remain there.
Hybrid app


49
Make it even more Native

Our App Scenario
Get some data out to the device
Get it fast and get it asyncronous
Keep it simple and slim
Use xagent to provide the stream
Present the data in a fashionable manner with native navigation
When the user wants more detail load it from the web
Use xpage as the presenter

51
Build the stream: XAgent
Build the stream using XAgent
For insperation and code samples that showed me the way to XAgents. More about XAgents go to Stephan H Wissel excellent website. (http://www.wissel.net)
XAgent
With a XAgent you have no limitations on the number of scanned documents. It's also much faster to use JavaWriter/XML in an XAgent than using XML against (<viewName>? ReadViewEntries).
ReadViewEntriesReadViewEntries is slow and limited to 999 documents in a lookup if you use (<viewName>? ReadViewEntries).
Build the stream using XAgent
For insperation and code samples that showed me the way to XAgents. More about XAgents go to Stephan H Wissel excellent website. ()
First, XAgent is no agent in the sense you think normally about when you work with Notes.
XAgent could contain eg Java, sessionScope, JavaScript @Formula() and so on and is built in a standard Xpage.
The XPage needs to be set to “render=false”.
The XAgent can not schedule in the way you can do in Notes with an agent.
54
Consume the stream

And use it in a native app
Table apps contains a good way of presenting domino view data
Map view and other presentations can be used the same way
You can speed up the app furthermore by preloading data in a database
SQLite is included
Arrays is commonly used for short lived data

To get the app accepted
Use Reachability methods
Never use private frameworks
Provide Apple with login details (if Your app contains user logins)
Explain the app purpose in details in reviewer textfield.
Keep the UI simple and strait forward

Demo
Add a login page
Add the “View” - Table to the app
Connect the table to a detail page.


Demo
This is the app we built Our data on:
Based on over 10000 places all stored in IBM Domino 9.0.1

60
Wrap It Up!

What we have shown
When and what to use as a best practice
What You should learn do get up and running
How appstore distribution works
Some programming details.

Related sessions
AD304 : The Power of Collaborating IBM Domino, IBM Connections and IBM WorklightMon, 27/Jan 03:45 PM - 04:45 PM
AD504 : Build and Optimize Mobile Experiences with IBM WebSphere Portal and IBM Web Content ManagerTue, 28/Jan 11:15 AM - 12:15 PM
AD501 : IBM Worklight for IBM Domino DevelopersTue, 28/Jan 04:15 PM - 05:15 PM
AD502 : The Mobile Distruption: Why XPages Development is Targeting Mobile FirstThu, 30/Jan 08:30 AM - 09:30 AM
AD503 : XPages Mobile Development in IBM Domino 9.0.1 and BeyondThu, 30/Jan 10:00 AM - 11:00 AM
BP201 : Creating a Mobile Application Framework with XpagesTue, 28/Jan 03:00 PM - 04:00 PM
BP209 : IBM Worklight: Going From XPages Mobile to Native Mobile ApplicationsThu, 30/Jan 11:15 AM - 12:15 PM

63
Questions ????

Access Connect Online to complete your session surveys using any:– Web or mobile browser – Connect Online kiosk onsite
Downloads available at http://www.donova.se/connect-2014
64
© Copyright IBM Corporation 2014. All rights reserved.
U.S. Government Users Restricted Rights - Use, duplication or disclosure restricted by GSA ADP Schedule Contract with IBM Corp.
IBM, the IBM logo, ibm.com,, and IBM Domino are trademarks or registered trademarks of International Business Machines Corporation in the United States, other countries, or both. If these and other IBM trademarked terms are marked on their first occurrence in this information with a trademark symbol (® or ™), these symbols indicate U.S. registered or common law trademarks owned by IBM at the time this information was published. Such trademarks may also be registered or common law trademarks in other countries. A current list of IBM trademarks is available on the Web at “Copyright and trademark information” at www.ibm.com/legal/copytrade.shtml
The "Android" name, the logo, and other trademarks are property of Google Inc.
RIM is the owner of the ubiquitous BlackBerry® family of trademarks.
Xcode, ios and Cocoa is a trademark of Apple inc.
Other company, product, or service names may be trademarks or service marks of others.
Availability. References in this presentation to IBM products, programs, or services do not imply that they will be available in all countries in which IBM operates.
The workshops, sessions and materials have been prepared by IBM or the session speakers and reflect their own views. They are provided for informational purposes only, and are neither intended to, nor shall have the effect of being, legal or other guidance or advice to any participant. While efforts were made to verify the completeness and accuracy of the information contained in this presentation, it is provided AS-IS without warranty of any kind, express or implied. IBM shall not be responsible for any damages arising out of the use of, or otherwise related to, this presentation or any other materials. Nothing contained in this presentation is intended to, nor shall have the effect of, creating any warranties or representations from IBM or its suppliers or licensors, or altering the terms and conditions of the applicable license agreement governing the use of IBM software.
All customer examples described are presented as illustrations of how those customers have used IBM products and the results they may have achieved. Actual environmental costs and performance characteristics may vary by customer. Nothing contained in these materials is intended to, nor shall have the effect of, stating or implying that any activities undertaken by you will result in any specific sales, revenue growth or other results.
Acknowledgements and Disclaimers