Karşılaştırma başlıkları yazılım dünyasında kalıp halinde kullanıldıklarından İngilizce olarak yazılmıştır.

Java C#
Geliştirici Sun Microsystem Microsoft
Geliştirilme Yılı 1995 2000
Veri Tipi Gelişmiş Az Gelişmiş
Struct Concept Desteği Yok Desteği var
Switch Case String in Switch Not Allowed String in Switch Allowed
Delegates Absent Supported
Referans Tipleri Java C#
Garbage collection Var Var
Weak references Var Var
Reference queue Var Var
Soft and Phantom references Var Yok
Proxy support Var; proxy generation Var; object contexts




Diziler ve Kolleksiyonlar Java C#
Abstract data types Var Var
One-dimensional, zero-based index arrays Var Var
Multidimensional arrays, rectangular (single array) Yok Var
Multidimensional arrays, jagged (arrays of arrays) Var Var
Non-zero based arrays Yok Some
Unified arrays and collections Yok Var
Maps/dictionaries Var Var
Sorted dictionaries Var Var[25]
Sets Var Var
Sorted sets Var Var[26]
Lists/vectors Var Var
Queues/stacks Var Var
Priority queue Var Yok
Bags/multisets Yok Var
Concurrency optimized collections Var Var[27]

 

Java C#
 // Is valid, as numbers is an object of type short[]

short[] numbers = new short[100];

// Is valid, but it isn’t clear that values

// is an object of type double[]

double values[] = new double[100];

 // Is valid, as numbers is an object of type short[]

short[] numbers = new short[100];

double values[] = new double[100]; // Won’t compile!

İfadeler ve Operatörler Java C#
Aritmetik Operatörler Var Var
Mantıksal Operatörler Var Var
Bitwise logic operators Var Var
Şart Operatörler Var Var
String Birleştirme Var Var
Casts(Atama) Var Var
Boxing Var; implicit Var; implicit
Unboxing Var; implicit Var; explicit
Lifted operators Yok Var
Overflow control Yok Var
Strict floating point evaluation Var; opt-in/out Yok
Verbatim (here-)strings Yok Var[31]
Nesne Yönelimi Java C#
Classes mandatory mandatory
Interfaces Var Var
Abstract classes Var Var
Member accessibility levels Var; public, package, protected, private Var; public, internal, protected, private, protected internal
Class-level inner classes Var;static inner classes are class level Var; all inner classes are class level
Instance-level inner classes Var Yok
Statement-level (local) anonymous classes Var Var; Without methods
Partial classes Yok; but see AspectJ[36] Var
Implicit (inferred) anonymous classes Yok Var[37]
Deprecation/obsolescence Var Var
Overload versioning Some Var
Enums can implement interfaces Var Yok
Properties Yok, but see JavaBeans spec Var
Events Provided by standard libraries Built-in language feature
Operator overloading Yok Var
Indexers Yok Var
Implicit conversions Yok Var
Explicit conversions Yok Var
Fields and initialization Java C#
Fields Var Var
Constants Var Var; but no support for constant passed parameters[41]
Static (class) constructors Var Var
Instance constructors Var Var
Finalizers/destructors Var Var
Instance initializers Var Yok; can be simulated with instance constructor
Object initialization Bottom-up
(fields and constructors)
Top-down (fields); bottom-up (constructors)
Object initializers Yok Var
Collection initializers Yok; can be modelled Var
Array initializers Var Var
Methot ve Özellikler Java C#
Static imports Var Var[42]
Virtual methods Virtual by default Yokn-virtual by default
Abstract Var Var
Sealing Var Var
Explicit interface implementation Default methods in Java 8 Var[43]
Value (input) parameters Var Var
Reference (input/output) parameters Yok Var
Output (output) parameters Yok Var
Constant (immutable) parameters Var;final parameters Yok
Variadic methods Var Var
Optional arguments Yok[44] Var
Named arguments Yok Var
Generator methods Yok Var
Extension / default methods Var Var
Conditional methods Yok Var
Partial methods Yok Var

 

Exceptions Java C#
Checked exceptions Var Yok
Try-catch-finally Var Var
Generics Java C#
Implementation Type erasure Reification
Runtime realization Yok Var
Covariance Var Var
Contravariance Var Var
Reference type constraint Var; implicit Var
Value/primitive type constraint Yok Var
Constructor constraint Yok Var
Relation constraint Var Var
Primitive/value type support Yok Var
Migration compatibility Var Yok
Metadata Java C#
Metadata annotations/attributes Interface based; user-defined annotations can be created[68] Class based
Positional arguments Yok; unless a single argument Var
Named arguments Var Var
Default values At definition Through initialization
Nested types Var Var
Specialization Yok Var
Conditional metadata Yok Var
PreprocessingCompilation and Packaging Java C#
Namespaces Packages Namespaces
File contents Restricted Free
Packaging Package Assembly
Classes/assembly search path ClassPath Both compile-time and runtime[69][70]
Conditional compilation Var Var
Custom errors/warnings Var; AnnotationProcessor Var
Explicit regions Yok Var
Threading and Synchronization Java C#
Threads Var Var
Thread pool Var Var
Task-based parallelism Partial[71] Var[72]
Semaphores Var Var
Monitors Var Var
Thread-local variables Var Var; ThreadStaticAttribute
Native interoperability Java C#
Cross-language interoperability Var (with NashornCORBAJNI orJNA)[78] Var; C# was designed for it[78]
External/native methods Var Var
Marshalling External glue code required Var; metadata controlled
Pointers and arithmetics Yok; but references exist Var
Native types Var[79] Var
Fixed-size buffers Yok Var
Explicit stack allocation Yok Var
Address-of Yok Var
Object pinning (fix variable to address) Yok Var
Platform support Java C#
Linux Var via Mono
Mac OS X Var via Mono
Solaris Var via Mono
FreeBSD Var via Mono
AIX Var Partial?
iOS via RoboVM or Codename One via Xamarin MonoTouch
Windows Var Var
Windows Mobile Var Var
Windows Phone via Codename One[80] Var
Windows 8 Modern Var Var
Android via DalvikART via Xamarin MonoDroid
Feature phones Var Yok
Symbian Var Deprecated
Blackberry Var via cross-compiler[81]

Kaynak : wikipedia.org

 


Bir cevap yazın

E-posta hesabınız yayımlanmayacak.