code: @PUT
      @Path("/{androidID}")
      @Consumes(MediaType.APPLICATION_JSON)
      @Produces(MediaType.APPLICATION_JSON)
      public Response updateAndroidVariant(
              @PathParam("pushAppID") String id,
              @PathParam("androidID") String androidID,
              AndroidVariant updatedAndroidApplication) {
  
          AndroidVariant androidVariant = (AndroidVariant) variantService.findByVariantID(androidID);
          if (androidVariant != null) {
  
              // some validation
              try {
                  validateModelClass(updatedAndroidApplication);
              } catch (ConstraintViolationException cve) {
                  logger.info("Unable to update Android Variant '{}'", androidVariant.getVariantID());
                  logger.debug("Details: {}", cve);
  
                  // Build and return the 400 (Bad Request) response
                  ResponseBuilder builder = createBadRequestResponse(cve.getConstraintViolations());
  
                  return builder.build();
              }
  
              // apply updated data:
              androidVariant.setGoogleKey(updatedAndroidApplication.getGoogleKey());
              androidVariant.setProjectNumber(updatedAndroidApplication.getProjectNumber());
              androidVariant.setName(updatedAndroidApplication.getName());
              androidVariant.setDescription(updatedAndroidApplication.getDescription());
              logger.trace("Updating Android Variant '{}'", androidID);
              variantService.updateVariant(androidVariant);
              return Response.ok(androidVariant).build();
          }
  
          return Response.status(Status.NOT_FOUND).entity("Could not find requested Variant").build();
      }
docs: Update Android Variant
  
  @param id                        id of {@link PushApplication}
  @param androidID                 id of {@link AndroidVariant}
  @param updatedAndroidApplication new info of {@link AndroidVariant}
  
  @return                  updated {@link AndroidVariant}
  
  @statuscode 200 The Android Variant updated successfully
  @statuscode 400 The format of the client request was incorrect
  @statuscode 404 The requested Android Variant resource does not exist