[WIP^2] upload handler interface

refs https://github.com/owncloud/core/issues/12052#issuecomment-63972509
looping here is quite stupid