Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8536231
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T10:36:54+00:00 2026-06-11T10:36:54+00:00

I’m trying to do an HTTP Patch request from an Android application and haven’t

  • 0

I’m trying to do an HTTP Patch request from an Android application and haven’t been able to figure it out. It looks like PATCH isn’t supported by HTTPUrlConnection. HttpPatch doesn’t seem to be in the libraries included on Android (link). Any ideas?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-11T10:36:55+00:00Added an answer on June 11, 2026 at 10:36 am

    If the Patch method is absolutely necessary you will have to import the Apache HttpClient as a jar dependency. This will increase the size of your app somewhat but it should not be a huge problem.

    As a workaround you could try to just include this java code in your app:

    /*
     * ====================================================================
     * Licensed to the Apache Software Foundation (ASF) under one
     * or more contributor license agreements.  See the NOTICE file
     * distributed with this work for additional information
     * regarding copyright ownership.  The ASF licenses this file
     * to you under the Apache License, Version 2.0 (the
     * "License"); you may not use this file except in compliance
     * with the License.  You may obtain a copy of the License at
     *
     *   http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing,
     * software distributed under the License is distributed on an
     * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
     * KIND, either express or implied.  See the License for the
     * specific language governing permissions and limitations
     * under the License.
     * ====================================================================
     *
     * This software consists of voluntary contributions made by many
     * individuals on behalf of the Apache Software Foundation.  For more
     * information on the Apache Software Foundation, please see
     * <http://www.apache.org/>.
     *
     */
    
    package org.apache.http.client.methods;
    
    import java.net.URI;
    
    import org.apache.http.annotation.NotThreadSafe;
    
    /**
     * HTTP PATCH method.
     * <p>
     * The HTTP PATCH method is defined in <a
     * href="http://tools.ietf.org/html/rfc5789">RF5789</a>: <blockquote> The PATCH
     * method requests that a set of changes described in the request entity be
     * applied to the resource identified by the Request- URI. Differs from the PUT
     * method in the way the server processes the enclosed entity to modify the
     * resource identified by the Request-URI. In a PUT request, the enclosed entity
     * origin server, and the client is requesting that the stored version be
     * replaced. With PATCH, however, the enclosed entity contains a set of
     * instructions describing how a resource currently residing on the origin
     * server should be modified to produce a new version. </blockquote>
     * </p>
     *
     * @since 4.2
     */
    @NotThreadSafe
    public class HttpPatch extends HttpEntityEnclosingRequestBase {
    
        public final static String METHOD_NAME = "PATCH";
    
        public HttpPatch() {
            super();
        }
    
        public HttpPatch(final URI uri) {
            super();
            setURI(uri);
        }
    
        public HttpPatch(final String uri) {
            super();
            setURI(URI.create(uri));
        }
    
        @Override
        public String getMethod() {
            return METHOD_NAME;
        }
    
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm trying to decode HTML entries from here NYTimes.com and I cannot figure out
For some reason, after submitting a string like this Jack’s Spindle from a text
I have a string like this: La Torre Eiffel paragonata all&#8217;Everest What PHP function
I am trying to render a haml file in a javascript response like so:
I would like to run a str_replace or preg_replace which looks for certain words
I have a view passing on information from a database: def serve_article(request, id): served_article
I would like my Web page http://www.gmarks.org/math_in_e-mail.txt on my Apache 2.2.14 server to display
I have a .ini file as follows: [playlist] numberofentries=2 File1=http://87.230.82.17:80 Title1=(#1 - 365/1400) Example
I am trying to understand how to use SyndicationItem to display feed which is
Basically, what I'm trying to create is a page of div tags, each has

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.