public static function wrap(
        Service $service,
        callable $bytesGenerator = null
    ) {
        return function (callable $handler) use ($service, $bytesGenerator) {
            return new self($handler, $service, $bytesGenerator);
        };
    }