What advantages should I take when using Java + Swing over C # + WinForms / WPF?

There is a group here using Java, server and client side, with Swing for client UIs. I am planning to assume that they are changing the frontend to C # and WinForms or WPF, but I want to prepare with:

  • List of benefits that can arise when migrating to Winforms / WPF from Swing.
  • List of Swing benefits that can be thrown back at me using WinForms / WPF (the only thing I can think of is being able to share more code between server and client due to the fact that they are the same language - given the fact that the server side will remain Java).
+1


a source to share


8 answers


1) The stench stinks. (Almost just kidding, but actually, in my opinion, this is pretty awful.) Even if you are going to develop in Java, use SWT or some other decent toolkit look / feel. Moving to Windows Forms or WPF (potentially) will give you much more powerful UI options on Windows, but only on Windows.



2) You bind to Windows and lose the cross-platform nature of Java + Swing. You potentially lose some of the potential for shared code. You have to reschedule in non-java, which could mean a lack of experience / training / knowledge from other developers on your team.

+2


a source


I'll provide this by saying that I am a .net developer, so the following might be heretical.

It looks like your company already has a significant investment in Java. People, software licenses and code base.

If my company (or group) was primarily java, and we have been successful in meeting business requirements, then, to be honest, I would have turned his way .



The only way that I could switch tech stacks is if the stack we were on was really dead. Bearing in mind that it was very difficult to find programmers, it no longer met the needs of the business, we had a large number of unsuccessful projects and / or the language itself did not develop anymore.

Switching over just because someone prefers one language over another is not a starter and ultimately won't make any business sense. The very act of such a change will mean that the company will lose those people who are still committed to the old stack. Replacing people is extremely expensive only in terms of lost knowledge.

It's another matter if you don't know yet what tough reasons for switching platforms, then you shouldn't even encourage it. Take the accountants' point of view, what does this actually provide?

+3


a source


  • Lead time and start time. You just can't compare Swing to Winforms / WPF in terms of runtime / runtime.

  • I really don't know ... if you have a highly skilled Java team that doesn't know the .Net API stick with Swing, otherwise don't think twice ... Use Winforms. About "the ability to share a lot of code between server and client because it is the same language", don't worry ... there are many ways to make two different applications from different languages ​​to each other.

+2


a source


The GUI performance should be faster with a winform.NET application compared to a Swing application running on Windows. At the moment this is not a huge difference for most applications, but computers can run Java quickly these days.

You will still be talking to Java code anyway. Depending on what they did, you might be better off just sticking to the front end of the Swing.

If that's an option, you should consider a web interface. If it can be done in XHTML / Javascript / CSS, you will retain the cross-platform advantages that the Java GUI gives you.

But you really need to think about why you want to switch to Winforms instead of Java. Is there something about an existing Java application that you don't like, would be better and worth the cost of reworking in another language? Is this something that can be fixed without a complete rewrite?

0


a source


Do you have any custom components that might suffer from the move from Swing to .net? Do you have staff who are experts in custom Swing component development (Java2D experience, familiarity with the Swings input subsystem, etc.) who know little about custom WinForm development?

If the answer to these questions is yes, then you should probably stick with Swing.

0


a source


1) It's easier to make the Winforms app look like a Windows app. Java applications usually feel "funny" if you're not careful.

2) Everything you program uses Java. Having a single non-Java component means the project is more difficult to work with. General service will also be more annoying. Currently, each of your project teams needs to know Java just to be able to work with anyone else on your project team. In terms of recruiting and service, it is convenient. Personally, I am against switching the GUI unless you get some other benefit from it.

You have not provided any reasons why you plan to make your offer.

0


a source


If using Windows.net it is the best choice because you have: 1. A good designer in Visual Studio, good documentation and examples 2. Better startup, CPU and memory usage at runtime: see http: //www.codeproject. com / KB / dotnet / RuntimePerformance.aspx

If you are using Linux you have Mono versus Java, but it is more difficult to make a comparison there due to the large number of distributions.

0


a source


The big advantage is the free libraries that you can use in java. Most nosql systems are written in java, Neo4j is best (only java will give you the ability to run these bundled products). This is something that dot net cannot do, and it will give your applications the winforms capability wpf can have.

0


a source







All Articles