http://www.altdevblogaday.com/2013/12/20/roll-your-own-vector/