Send Integers From Ardunio to Java Program Using Serial Port

Do you know if there is an Arduino function that posts integers or doubles to the serial port? Or can the Arduino only post strings to the serial port?

It takes some effort to send integers and doubles to the serial port as a collection of bytes, rather than strings. The easiest way is to define a union of a double or int and an array of bytes of the same size. Create an instance of the union, set the integer or double, and Serial.write() the matching byte array.