there are many different possible ways, the 3 below are most used ones:
1) using USB port
2) using bluetooth
3) using SMS, MMS and other wireless messaging
the first two are used when mobile and PC are near each other
if you decided to use USB and take a look at JSR 80: Java USB API (http://jcp.org/en/jsr/detail?id=80)
if you decided to use Bluetooth take a look at JSR 82: JavaTM APIs for Bluetooth (http://jcp.org/en/jsr/detail?id=82)
if you decided to use wireless messaging then you should take a look at following JSRs:
JSR 120: Wireless Messaging API (http://jcp.org/en/jsr/detail?id=120)
JSR 212: Server API for Mobile Services: Messaging - SAMS: Messaging (http://jcp.org/en/jsr/detail?id=212)
JSR 205: Wireless Messaging API 2.0 (http://jcp.org/en/jsr/detail?id=205)
if decided to enter J2ME world assuming you are not already familiar with it, you may need lots of other things to learn first.
at least learning the J2ME spec and reading list of available JSR's for J2ME will be useful.