
The title is too long!
"Unlike the Raspberry Pi, the Arduino is less a general purpose computer designed as a programming tutorial foundation, more a controller unit for electronics projects, though the Pi can be used in such a role too. Arduino is operated using a Java API."
The Arduino and PI are aimed at the same market yes, but different purposes.
The PI is a basic PC, provided to allow easier access to programming environments without the risk of breaking an expensive PC.
The Arduino is aimed at real-time control and embedded electronics.
The Arduino is not accessed using a Java API, it's programmed in C/C++ (although other languages can be used with an appropriate tool chain), the Processing based IDE is written in Java.
The PI can do basic electronic control, but it's not suited to realtime operation.