For a beginner's introduction to ball vs line physics I can recommend Tony Pa's old vector tutorial:
http://www.tonypa.pri.ee/vectors/tut07.htmlOnce you've mastered the basic vector math he's outlined in it, then you can move on to more advanced physics engines. It's very easy to understand and is a great primer on vector math.
It's a tutorial I keep coming back to and one grew my geometry objects out of (although you would barely recognise the connection nowadays).
After you've tackled that, you'll want to learn "separating axis theorem". That will set you up for polygon collisions.
And if you want to do billiard ball collision, I posted a thread on an old forum here:
http://processing.org/discourse/yabb2/YaBB.pl?num=1201461240It's a fairly basic version of billiard ball collision, but it does work.
For simply testing a collision between a circle and a line, then you can use the proximity() method in my Line object here:
http://github.com/st33d/red-rogue/blob/master/src/com/robotacid/geom/Line.asResolving the collision is something you'll have to figure out yourself - but as I said, work through the Tony Pa tutorial and you'll have a good foundation to grow from.