This question already has answers here:
How do I move from Java to C#?
(9 answers)
Closed 5 years ago.
I am going to start work with a company that works on a .NET framework and i am a professional java developer and i think i should switch to .NET because i cant see any bright future with java anymore.
My questions:
Now i have decided to move to .NET, what things i should learn as a total beginner. Should i learn C# or i should understand basics of .NET first?? as i know only that .Net is a framework and c# is one of language run on it. I am only interested in C# as it like java not in VB or any other.
please tell me what i am suppose to learn and please refer to me some books.
thanks
You are correct in your understanding that .Net is the underlying portable framework which is supported via multiple languages such as C#,VB etc. If you are looking for a Java equivalent in terms of programming language then C# is exactly what you want to be working with.
One of the best books for C# out there is C# via CLR that teaches you C# with an understanding of the underlying CLR. It is more of an intermediate-advanced proficiency book but the basics should be easy to latch on to given your Java background.
Related
This question already has answers here:
Closed 11 years ago.
Possible Duplicates:
What are the most important functional differences between C# and VB.NET?
C#'s edge over VB
I'm programming in VB.net because I'd former experience in VB 6.0 and I've familiar with its syntax. I know that C# is preferred by the biggest part of .net programmers. I know that C performance had superior performance against many other languages, but there is a good advantage in the same .net framework? There is a quite good reason for advicing me if should I migrate right now from VB to C#? Thanks!
Wikipedia has a good comparison of the two.
Personally, I chose to learn C# because I find the VB syntax too verbose, and the wages were higher. I think there's sometimes an (unjustified?) stigma attached to VB.NET that it's a 'lesser' language, and that can sometimes be reflected in the attitudes of employers and subsequently the remuneration on offer.
At the end of the day though, the output you get from either language is the same.
I'd advise you to program in the language you are comfortable with. There are minor differences in the languages (C# has some syntactic features that vb.net doesn't and vice versa), but eventually, they compile to the same ILCode and thus perform the same.
This question already has answers here:
Closed 12 years ago.
Possible Duplicate:
is there an effective tool to convert c# to java?
I'm not very experienced with Java and have a lot of C# that I would like to translate into Java syntax so it would become compilable.
Reason: Android and Google Cloud
I know the API/Platforms have different structures, but lets say we dont need a 100% compability, but just to get "core functionalitet" translated. The GUI itself is one story of its own, as I've learned. But instead of rewriting every SWITCH-CASE, rebuild every Class etc. it would be nice to "map" the objects to Java equals and then do a recompile on the Android/Google platform.
I am sure there would be something that cant be translated as its a "C# only thing" - but just like every language is possible to generate .NET/MONO I thought there might be a Java -> .Net available too and therefore also a decompiler kinda thing?
So are there any easy ways to overcome this translation by Frameworks, SDK or other similar methods that will take 80-95% of the task automatically?
Have a look here: JSC.
But beside, there are some c# concepts which don't easyli translate into java.
.NET and Mono are compatible because both are VMs that run C# code. Grasshopper claims to allow you to run .NET classes on the JVM, but I haven't used it. It won't work at all for Android because Android isn't the JVM, but rather Dalvik.
The differences between C# and Java are more than "structural" as you put it, and translating from one language to another is more complicated than I think you understand.
I know Microsoft has a tool that's supposed to help convert Java to C#, but considering that a great many java applications reference libraries outside of the main system (apache being the most prominent example) this type of tool would be a monumental task.
C# also has data types that aren't supported at all in Java, such as unsigned types and stack-allocated objects. Writing translations from CLR to Java bytecode would be difficult indeed. And if you're using lambda functions in your code, kiss this idea goodbye.
Then there's the fact that not all language features in Java are available to the Davlik JVM.
I'm not a microsoft fanboy, but here's a comparison of the two languages that will give you an idea why I doubt this tool exists.
http://en.wikipedia.org/wiki/Comparison_of_C_Sharp_and_Java
This question already has answers here:
What are major differences between C# and Java?
(7 answers)
Closed 8 years ago.
For complicated reasons (not C#'s fault I love that language very much) I have to learn Java. I hate learning new langages and i dont wanna have to learn what I already know from C#.
What are some resources that teach whats different without learning it all?
I realize this isn't a very specific answer, but the best advice I can give you is to not go into it with the "I hate learning new languages" mindset. If you're familiar with C#, Java will be a piece of cake. Depending on what you're working on, most of your questions can easily be answered by a quick look at the API documentation. I don't think you have to worry about "learning it all".
The problem won't be the syntax but the framework. Since I'm not a Java developer either, I'm not sure where to look. But I suggest looking into the frameworks you'll be working with instead of syntax.
Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 7 years ago.
Improve this question
What is the quickest/easiest way to learn Java for a seasoned .NET/C# (more than 7 years) and C++ (5years) developer.
When I say to learn Java - I mean being able to write applications in a "Java way" using base classes library + where needed using a popular Java libraries (it is great that so many of them are open source).
I know that Java development comes in a lot of flavors - enterprise applicatons (Java EE), mobile devices (Java ME), objects hosted in application servers (to my knowledge Java has a buch of these) - however at the moment I am interested in a general Java development - may be with a some emphasis on a integration projects/enterprise development.
So basically - I am a strong, passionate about technology, proud to be a senior C#/C++ developer with a dozen years of experience who wants to dedicate a month-worth (may be more) of evenings to learn to effectively program in Java environment.
Having said that I don't mean I am switching from .NET/C++ to Java - but I would probably have to spend 30%-50% of my development time developing/supporting/whateverstageintheSDLC in Java.
Thank you.
I suggest starting with The Java Language Specification. I don't think there is any quicker or more comprehensive way of gaining an understanding of the language for a seasoned programmer.
Followed by Java Collections Tutorial.
Followed by java.lang.* and java.util.* classes, interfaces and packages.
This will give a good basis for learning and understanding any other branch of Java as it becomes necessary.
I would take a completely different approach to reading books upfront. Simply download an IDE and get coding. The netbeans tutorials tend to get you up and running with a variety to technologies very quickly.
If you can code C# then you should have no problem getting something up and running.
Once you have some code up and running that is when you would then dig out the likes of effective Java.
Karl
Effective Java should be in every Java developer's bookshelf. It focuses not so much on performance as one might think from the title, but rather on how to program Java idiomatically, which becomes subtly different from following the idioms of C#.
Perhaps one of the best ways would be to get a copy of Bruce Eckel's Thinking in Java.
Much more than simply covering the syntax of the language, this book goes into the background - as the title says, "How to think in Java" so you can write pure Java code, not C# (or C++) code using Java Syntax.
I m only speaking for java web app development: i think its going to be quite similar to how you might've done it in C# using ASP.NET, except you don't get the visual drag and drop GUI creation using visual studio. The basic concepts are pretty much the same.
As for libraries, there are a million and one in java, and only time will help with those. But it'll help knowing the common ones, such as apache commons, google collections, spring, hibernate. It might help you get started if you start with something like Appfuse, which is a full java RAD web app framework that munges together all the above common frameworks.
On the build tools side, there are ant and maven as the major players. I prefer ant over maven personally.
Ordered list:
Thinking in Java;
Core Java, Volume II;
Spring reference;
This question already has answers here:
Closed 11 years ago.
Possible Duplicate:
Best way to really grok Java for a C# guy
I worked on C# for a few years now move to Java. Is there a good Java tutorial for C# developers?
thanks!
Here is a helpful article to compare the language syntax and some differences between the two.
as far as i know java has a similar syntax ;
anyway have a look here this article compare c# and java keywords
This book isn't geared specifically towards people coming from a C# background, but I still recommend it highly. You'll draw the comparisons with C# on your own as you read. And it is free in electronic form. Bruce Eckel's "Thinking In Java"