Class MockBodyHandler

  • All Implemented Interfaces:
    io.vertx.core.Handler<io.vertx.ext.web.RoutingContext>, io.vertx.ext.web.handler.BodyHandler

    public class MockBodyHandler
    extends Object
    implements io.vertx.ext.web.handler.BodyHandler
    Copy of Vertx BodyHandlerImpl. Had to do this because I want to get raw bytes of everything and if it was a form or multipart it would not set the body buffer.
    • Constructor Detail

      • MockBodyHandler

        public MockBodyHandler()
    • Method Detail

      • handle

        public void handle​(io.vertx.ext.web.RoutingContext context)
        Specified by:
        handle in interface io.vertx.core.Handler<io.vertx.ext.web.RoutingContext>
      • setHandleFileUploads

        public io.vertx.ext.web.handler.BodyHandler setHandleFileUploads​(boolean handleFileUploads)
        Specified by:
        setHandleFileUploads in interface io.vertx.ext.web.handler.BodyHandler
      • setBodyLimit

        public io.vertx.ext.web.handler.BodyHandler setBodyLimit​(long bodyLimit)
        Specified by:
        setBodyLimit in interface io.vertx.ext.web.handler.BodyHandler
      • setUploadsDirectory

        public io.vertx.ext.web.handler.BodyHandler setUploadsDirectory​(String uploadsDirectory)
        Specified by:
        setUploadsDirectory in interface io.vertx.ext.web.handler.BodyHandler
      • setMergeFormAttributes

        public io.vertx.ext.web.handler.BodyHandler setMergeFormAttributes​(boolean mergeFormAttributes)
        Specified by:
        setMergeFormAttributes in interface io.vertx.ext.web.handler.BodyHandler
      • setDeleteUploadedFilesOnEnd

        public io.vertx.ext.web.handler.BodyHandler setDeleteUploadedFilesOnEnd​(boolean deleteUploadedFilesOnEnd)
        Specified by:
        setDeleteUploadedFilesOnEnd in interface io.vertx.ext.web.handler.BodyHandler
      • setPreallocateBodyBuffer

        public io.vertx.ext.web.handler.BodyHandler setPreallocateBodyBuffer​(boolean isPreallocateBodyBuffer)
        Specified by:
        setPreallocateBodyBuffer in interface io.vertx.ext.web.handler.BodyHandler