Replace yield method to match php 5.5

Since PHP 5.5 there was a clash between yield method and built in
keyword
Add comments

Add doc block comments to each method
Add output buffering

Adding output buffering to the framework