Lacks of Xamarin.Android is obvious.
Java (Android SDK) is free and has a large community. Xamarin.Android costs a money and has a very little community.
And what are the merits?
P.S. I write in C# and Java both, but I see that best language is mainstream and official language.
Java/C++ is tool for Android and cross-platform development, C#/C++ for Windows development, not vice versa.
Actually I have to disagree with you on that point. I have done Android Development with Java and with C# using Xamarin. The biggest benefit of Xamarin is the ability to build apps cross platform. The problem with using straight java is that how often do you want to build an app in Android only. Most of us want to build apps that work cross platform, and if you go strictly native this becomes a very time consuming practice where you are duplicating business functionality in different languages. Xamarin leverages the same API's, and works close enough to prevent issues with working in a different API, something .net specific.
The article is intended to give an overview of Xamarin.Android, not to be a discussion point on the pros and cons of using Xamarin vs native. So the article assumes that the decision to use Xamarin has already been made.
That said, there are several reasons why Xamarin would be selected over Java. If your team consists of .NET developers and you want to build apps that target the Android platform, then surely leveraging your existing investment is a common-sense and viable option. Otherwise you'll need to re-skill them in Java. Yes, they are similar enough to learn, but there are also differences between the two ecosystem as to make the decision a far from straight forward one (especially if you have build tools, deployment tools, continuous integration, unit testing tools etc etc).
Also, if you architect your solutions from the outset then you are able to build cross-platform apps from the same codebase. Writing native apps on single platforms can be a costly and time consuming option.
> If your team consists of .NET developers and you want to build apps that target the Android platform
Xamarin.Android != Mono != Microsoft.NET.
They are very different.
Syntax is nothing compared to APIs and available third-party sources and libs.
> if you architect your solutions from the outset
Yes, in this case, Xamarin can actually be useful.
> Writing native apps on single platforms can be a costly and time consuming option.
Android device ($100) + iOS device ($1000) + Android SDK ($0) + Mac device for X-Code ($1500) = $2600.
Android device ($100) + iOS device ($1000) + Xamarin ($999-1899 EVERY YEAR!!! see https://store.xamarin.com/) = infinity $.
I agree with Dominic, this article is about how to use Xamarin, all technologies have their time and place, and their are pros and cons to everything. You can't outright disprove something for all situations, cause every situation is unique.
I can see some of your points, but Xamarin was largely built by the same people who built the Mono Framework with regard to .net, and leverages many of the same libraries. You can implement Mono libraries within Xamarin, and leverage them to support your development, your statement of Mono != .NET is a relatively simplistic view.
Also what your cost model above does not include is development time. While the tools may match your costing the development time to duplicate effort for multiple platforms is where you will lose a lot of money. If you figure your application is going to take roughly lets say 80 hrs (a 2 week sprint) to build on each platform (normally there might be one platform a little less, one a little more, but for this example lets say they equal out), and let's say a bill rate of $150 / hour.
This is assuming your are duplicating and building the exact same app in both iOS and Android, as most enterprise solutions will be, because companies have embraced the build your own device. Also if I'm building an app I would like it to have as broad a reach as possible.
For Xamarin, we leverage PCLs and Shared Code Projects, and the fact that C# is used for everything, and on average in my experience you can expect 80% code share (if you aren't using Xamarin Forms) for the separate platforms. So it would look like what is shown below. The common libraries would require 80% of the development effort, and each platform would be 20% of the development effort each.
Normal native development involves: $24,000
Xamarin Development involves: $14,400
Which means Xamarin offers a cost saving in development time of $9,600, over an application for a 2 week project. So we could drag that out over the course of several projects and it more than offsets the cost of Xamarin licensing.
Also, your licensing left out an option, the indie platform which allows for $25/month for Xamarin, which comes to $300 a year. If you went with this option than your looking at that two week project saving you 32 times that amount in development cost.
I'm not saying Xamarin should replace all native development, but I am saying it is a viable option and to discount it on licensing costs is very short sighted.
C#-developer still have to be retrained to write in Xamarin.Android or Xamarin.iOS.
Where are soo few familiar third-party .NET assemblies runs on Android or iOS.
Also, as I know, you cannot use *.jar libraries for Xamarin.Android (if can, it must nullify Xamarin "cross-platformity").
I haven't had any Xamarin or Android training. There will always be a learning curve when you are learning a new system, and this is no different.
The developer is able to write in the language they are already familiar with (C#) using the IDE they are familiar with (Visual Studio). So this lessens the learning curve when compared to having to be retrained in Java / Eclipse.
Again I have to agree with the others, the retraining is just no difference than learning a third party API which is a standard operating procedure for any developer, and your statement still does address the benefits of the shared code.
Last Visit: 31-Dec-99 19:00 Last Update: 20-Feb-24 18:42