Reputation: 1907
Is there a way (and if so how?) to access plugged-in resources on my computer with java? Like the microphone, the speakers and the computer monitor? I'm not talking about mainboard, cpu, etc. this is reserved for C.
Upvotes: 0
Views: 1968
Reputation: 53880
No. The idea of microphone, speaker, and monitor are all abstracted in Java. You can draw things, which will generally show up on the monitor. You can get audio input, which generally comes from the microphone, and you can output sound, which generally comes through the speakers. However, Java doesn't concern itself with how the platform implements these specific features, and Java is unaware of anything beyond the abstract layer.
However, you can extend Java by writing native libraries (JNI) to do platform specific things if you need further information or control.
Upvotes: 3