added support for oneway=1 and oneway=-1

fixes #1400