Class OkHttpRequestTask

  • All Implemented Interfaces:
    java.lang.Comparable<Task>, org.gradle.api.internal.DynamicObjectAware, org.gradle.api.internal.TaskInternal, Named, ExtensionAware, Task, Configurable<Task>
    Direct Known Subclasses:
    HttpGet, HttpPut

    public abstract class OkHttpRequestTask
    extends OkHttpTask
    Base class for tasks which execute exactly one HTTP Request.
    • Constructor Detail

      • OkHttpRequestTask

        public OkHttpRequestTask()
    • Method Detail

      • getProgressLoggerFactory

        @Inject
        protected abstract org.gradle.internal.logging.progress.ProgressLoggerFactory getProgressLoggerFactory()
      • getHeaders

        @Input
        public abstract MapProperty<java.lang.String,​java.lang.String> getHeaders()
      • executeRequest

        public void executeRequest()
                            throws java.io.IOException
        Throws:
        java.io.IOException
      • buildRequest

        public okhttp3.Request.Builder buildRequest​(okhttp3.Request.Builder builder)
      • handleResponse

        public void handleResponse​(okhttp3.Response response)
                            throws java.io.IOException
        Throws:
        java.io.IOException