Add LineBuffer function