code: function setState(state) {
          return function (job, arg0, arg1) {
              job._setState(state, arg0, arg1);
          };
      }
docs: Helper which yields a function that transitions to the specified state