Added documentation and refactored capturer. Changed testgen to reflect changes in capturer