OK, I just felt like trying this out for myself; really there is something very satisfying at watching a ball swing back and forth on a string. So here: http://pastebin.java-gaming.org/d0bb2981a0e14
(I don't know how to embed JGO pastebins). I made it using LWJGL so if you don't use LWJGL, then you won't have the libraries and natives to run it and you probably won't understand the rendering parts of it. But the simulation bits should still help.
Now as soon as I had it, I realized that the thing just kept swinging infinitely so I had to add in a little (very) simplistic friction. That is the " - ( av * FRICTION_COEFFICIENT / mass )"
term in the SwingingBody.update() method. That friction bit is the only reason the mass of the body affects the motion.
One last thing - it is very crude in places. I was trying to do it quickly, and shortly whilst making it self-contained. Sorry.