added basic next method for output
Merge branch 'dev'