java compilation
i am not a java developer so is it possible for me to develop java code on windows and then deploy the windows开发者_StackOverflow社区 compiled .class files to a solaris server...would it run..
Yes, it should.
However, watch out for the most common pitfalls like:
- version incompatibility (e.g. class file version, runtime environment)
- system dependent resource descriptors (e.g. file paths)
Yes, that is specifically the premise behind Java's Write Once Run Anywhere motto
Yes, java byte code (class files) is platform independent.
Yes, 99.9% of the time this is the case. There are some hiccups with non-Sun (read, IBM) JVMs that aren't perfectly cross-platform compatible.
as the others already said, it will most likely work. Id suggest you read some info on the Java Virtual Machine as this wonderful virtual device allows running java byte code on (nearly) any machine...
In general, It should. Mind it that class file don't run by themselves, you need to have java installed on the machine. It should also be compatible version.
精彩评论