I have a 30 line Java Android app which uses WebView to connect to our website. The website was the real development and it does all the work for scaling and adjusting. The app simply makes a WebView browser connection to it, plus it catches connectivity errors and uses Toast for some messaging. All is about 30 lines of Java, using Eclipse. The app is done, fully tested, signed and is being deployed to play store.
I want to have the same app supported on iphone and ipad. My question is this:
Is xcode and rewriting the app in Objective C the fastest and best path to port the app from Java/android to ios? Is there a shortcut? Is there a translation or transformation utility available?
Phonegap/Cordova doesn't seem to be applicable here (or is it?) as the app is not a js/html/Css app. I also understand that there are no plugins for ios in Eclipse. There are tutorials on how to do this in xcode (e.g., http://conecode.com/news/2011/05/ios-tutorial-creating-a-web-view-uiwebview/) but was wondering if there is a better path.
I remember a university project a few years back that was trying to build the translator from java to objective C plus all the needed ios libraries. Not sure if it became a product at any time.
Any pointers is appreciated.
The best path is using Objective-C or Swift in XCode, since WebViews are available in iOS too, and your app will be of a length comparable to the Android version.
Related
I've been working hard to finish making my Android app, and now it's time to make an IOS version too.
I've noticed that Mac computer is needed to start with IOS apps, so I came into few questions since I don't have any Mac device in my home:
1) What is the most affordable developement enviroment for IOS developement?
2) Is there any tool or guide for Android --> IOS?
3) What is Xamarin? Does it allow to build apps for android & IOS together? and how effective it will be since I already made my Android app via Android Studio?
Looking for answers,
Thanks in advance.
I did not find answer to this questions in the web. what I found is 5 years old aged irrelevant answers.
congratulations for your new app.
1) You can have a look for OS X servers http://www.macincloud.com but in the long term I think it would be time and money saving to just buy a second hand Mac computer or a Mac Mini for 500 dollars or so.
2) They use different syntax and different APIs, so you won't be able to reuse most of your knowledge, I'd recommend you to have a look to the iTunes University Stanford videos.
3) Xamarin is a mobile cross platform framework, the main advantage is that your code is converted into native one, so the final touch uses real native components. In that case you have to use C# for the development and, of course, redo the whole project.
I have one simple question, that is can I convert my android .apk app into ios using any software? If yes, then please give me the name of that software. If any alternative method for that please guide me.
Google has a tool to convert the back-end, nothing for front-end though
http://www.xda-developers.com/google-tool-helps-developers-port-android-apps-to-ios/
There is a new startup that clains to convert the APK to IOS.
It's called MechDome.
The goal is very simple and attractable:
Reduce time to market by eliminating cross-platform development. Automatically convert your existing Android apps to high-fidelity, native iOS apps.
There is nothing out there that would convert apk into ios app. To my knowledge there is also nothing out there that could translate android code to IOS. The operation is simply too complex for a simple tool to manage.
However, there are tools you could use to make your apps (developed by you) work across multiple platforms. I'm sure there are more, but here are 2 of them I found in minutes (look into them if you are interested): Apportable, Phonegap (discontinued as of 2020/03. It was made obsolete by ProgressiveWebApps - PWA).
In past decade or so WebApps have been picking up for anything that is not too graphically demanding as they can run on anything that has a Web Browser. With this style devs pretty much open their website in a platform-specific executable and it looks like an app.
As for your existing app depending on complexity of your software you have to rewrite from a little to a lot of code to adapt to IOS APIs.
In short: No. Unless your app is build on multiplatform framework, converting means manual adaptation.
There is no known way to convert an android app to iOS. MechDome which is a Developer Tool that Automatically Converts Android Apps into iOS Apps seems to have stopped as of 30/03/2021. link
However if it is your plan to launch android and iOS app from one coding project, use Flutter which allows you to launch on both platforms simultaneously.
Flutter is Google’s mobile UI framework that provides a fast and expressive way for developers to build native apps on both iOS & Android, using a single codebase.
Get started here link
I have been researching PhoneGap and I'm now at an impasse and need some advice. I know that PhoneGap essentially 'converts' html5,css,JS sites to 'apps' for distribution, which leads me to my question:
Why wouldn't one simply utilize a webview within an activity to do the same thing and keep the app native?
The advantage of PhoneGap is that it provides APIs that enable your HTML/javascript to interact with the phone (e.g. camera, accelerometer, media etc.)
These APIs are standard across multiple devices (iOS, Android, WinPhone, Blackberry etc.). So you can write one set of HTML/javascript and deploy to multiple platforms.
If you just created a WebView you would not have the PhoneGap APIs and you would need to build containers on each platform you were interested in.
Good question I have searched me too, because we went in Phonegap solution and I think it is a wrong way for us.
The long story:
That is very true if you write once a UI with web developer skills than not needed to know native language and it compile, and ready for testing.
Web developers are more so higher the demand => developer price even cheaper.
When the client want a Milestone 1 for his great idea it will ask a few company, freelancers about development price and time. If is a very basic application version with Phonegap you will have the less development cost( off if your web dev skills are the same laver as platform dev skills) with webView at second place and last one the native.
The client is satisfied with app result buit with Phonegap and want to get more investors so it will make a presentation, where they are asking more features.
At Milestone 2 you will add a few features. Some are easy command line install and you get it, some aren't. Maybe you will be unlucky as you want a combination of 2 existing plugin with a few extras. The conclusion will be: you have to develop a plugin. At this point is already a very big sign of interrogation which is cheaper: the Phonegap + Phonegap plugin or a WebView. If you need 5 existing plugin and your has a little modification, than still Phonegap. But if you need only 1 plugin, only yours, than the web view is the proper way. There are also cases which makes the Phonegap stucture useless. Also there is a problem with version control system under Phonegap if you develop web files, and native code too: some are regenerating at each build time some not. Still is expensiver the native platform. Now the required features are developed. The client will make a demo for investors, where will be visible execution speed with this new features. Or here they will require optimisation, runtime speed-up or after publish to market they will see some are running with low end phones and not the ultimate, which ws used at demos and they will decide to go to Milestone 3 : speed up.
At optimisation, speed up (Milestone 3) you will decide as you need native GUI. After all GUI developed with web now you will need to throw out at fence and implement the side, maybe some parts need even NDK to speed up. No way to be good here with Phonegap. But you have hired web developers, or contracted that company. Now go back to that company , developers which can make native code. They will not start from 0, so they need to analyse the code, refactor and your development price will go up at least with 50% as you would start it from 0 with native.
Good Question, you still could use webview for that but you won't be able to access native functions like ringtone, camera, and all that, however, the app done that way will be regarded as a native app.
I was talking with someone about iPhone and Android apps and they said there was something around called "Titanium" that could convert an iPhone app to an Android app and vice versa; being that they are written in different languages (amongst other nuances) I found this a little hard to believe.
I'm assuming he meant this
From what I can understand, you can't "convert" an existing app from one to the other, but if you build an iPhone app based off of this API THEN it can be converted to the other?
Am I right in my thinking?
You're almost right. In Titanium you build your app using JavaScript (and HTML/CSS for webviews - sort of webpages) and it converts it to native code for both platforms - Obj C for iOS and Java for Android. However you still need to write a significant amount of platform specific code because not everything will work right out of the box on both platforms. And yes - you can not convert existing apps using Titanium to anything.
The word "convert" is inaccurate in describing what Titanium Mobile does. You don't "build an iPhone app based off of this API", you write your app using the Ti API (which is based in Javascript/HTML/CSS), and when you compile that app you end up with both a native iOS app package and a native Android app package.
I have to develop an app for the Ipad. It has to be non-browser based. That's a requirement and I can't change it.
I think it likely that the app would be useful on other tablet PC types and have a good chance of a second app which requires IPad and Android at a minimum; Windows and Linux would also be useful.
If it makes any differences these are "desktop" apps for tablet PCs and it is not envisaged that there will be any handphone development.
Is there a “Grand Unifying Theory” of cross-platform desktop app development? Is there a good IDE, preferably FOSS? I'd rather code C++ or Java and am less keen on Ruby or Python (through lack of experience) but would accept if there is no alternative.
I need a GUI builder, something like Borland Delphi or MSVC or the Eclipse Android plugin and I need a way of executing different code on different platforms (#ifdef Android … etc)
Any ideas, or should I just go ahead and code the current project for Ipad only and stick to browser based HTML5 + CSS3 with Jquery/Ajax for cross platform apps (the problem being that some will need to execute native system calls, like en/de-crypting a file and at least one app has to work in “local mode” if there is so internet access, so I guess I would have to bundle a web server (Apache) if I go browser based (in order to serve the web pages), which would not be necessary with a “desktop app”.
Any recommended IDEs, Web sites? Books? Thanks
The "grand unifying theory" is that core business logic should reside in the cloud; that allows your iOS and Android implementations to be just a thin GUI on top of this shared logic. Unfortunately, there isn't really a way to reuse the GUI, and even if you did, it would go against the intuition of users on one or both platforms, since you wouldn't be using the paradigms of those specific platforms.
Google App Engine provides a way for implementing your core business logic in Java on top of Google's cloud computing infrastructure at reasonable costs (development is free, cost is proportionate to usage, and one can put caps on how much one is willing to pay). There is an Eclipse plugin for developing App Engine applications. When developing for Android, you will similarly want to use Eclipse (there is a plugin specifically for Android development), although the Android SDK can be used just from the commandline (which is good for setting up a continuous build and test system).
For iOS, you will want to use the standard Xcode and the iOS SDK. Xcode is an IDE, but it is possible to build Xcode projects directly from the commandline using the xcodebuild command (also good for continuous building). The standard language for iOS applications is Objective-C.
You should take a look at jQuery Mobile. I used it to cross develop between Android and Playbook. I know that it also does iOS.
Maybe for you the downside is that you have to program in JavaScript.