Remember meForgot password?
    Log in with Twitter

article imageGoogle may adopt Apple's programming language as Android default

By James Walker     Apr 8, 2016 in Technology
Google could be planning to adopt Apple's open-source Swift programming language for use in building Android apps. Doing so would be a huge task requiring the rewrite of many existing code libraries but would free Google from its ongoing issues with Java.
Android currently uses Java as its first-class programming language, the language that most app developers use to build new Android apps. Much of Android is built on top of Java including the code libraries provided by Google that developers build their apps on top of.
Java isn't an open-source language though. Creator Oracle has sued Google for as much as $1 billion over alleged copyright infringement and use of Java in Android without paying royalties. Google has allegedly copied much of Oracle's work by building customised Java libraries for use in Android.
In January this year, Google made the surprise announcement that it will rip the offending code out of Android and move the OS to use Oracle's open-source packages. This should lessen the damages paid by Google as Android now uses code authorised by Oracle.
According to a report from The Next Web, Google is considering changing Android's first-class language though, potentially freeing it from its issues with Java. The current primary contender is Swift, an open-source language originally developed by Apple for use in building iOS apps.
Swift has quickly become popular with developers. It is easy to write but also powerful and feature-rich, capable of creating high-quality apps without the complexities of older languages such as Java.
A move wouldn't be as simple as allowing Android to run Swift code though, itself a big challenge. All of the existing Android standard library would have to be reworked to run in Swift, potentially requiring complete rewrites of current APIs if they are incompatible with the language.
The Android standard library is the pool of code provided by Google that developers use to interact with Android. The standard library lets developers send notifications, access networking and location details, communicate with the user and, at a low level, draw on the screen and talk to a device's hardware. Without it, apps wouldn't work.
To get Swift apps running as well as Java ones do today, Google would have to revisit virtually all of its existing code, patching in missing features as required and updating older libraries to work with the modern language. It would be a monumental effort and any work isn't likely to be seen soon.
Google isn't said to have plans to drop Java anytime soon. Even if the project with Swift does happen, the new language will be promoted as an alternative to Java for the foreseeable future. Other languages are also being considered, including newcomer Kotlin, but Swift is thought to be the favourite due to its active developer community.
Using Swift on Android could be beneficial to developers who also write for iOS. Using the same programming language on both platforms would make it simpler to port apps between platforms, letting developers write code once and then modify it as required to add details specific to iOS and Android.
More about Google, Android, Ios, Apple, Oracle
Latest News
Top News