Class Upload3Resource

java.lang.Object
org.ctan.site.resources.upload.Upload3Resource

@Path("/3.0/upload") @Produces("application/json") public class Upload3Resource extends Object
The class Upload3Resource contains the controller for the upload resource.
  • Constructor Details

    • Upload3Resource

      public Upload3Resource(@NonNull @NonNull UploadService service)
      This is the constructor for the class TexArchive3Resource.
      Parameters:
      service - the underlying service
  • Method Details

    • getAddendum

      @GET @Path("/addendum") public Map<String,String> getAddendum()
      The method getAddendum provides means to retrieve the upload addendum file.
      Returns:
      the addendum
    • getList

      @GET @Path("/list") public UploadService.IncomingTo getList(@QueryParam("page") Long page, @QueryParam("size") Long size)
      The method getList provides means to retrieve the list of unprocessed uploads.
      Parameters:
      page - the current page
      size - the page size
      Returns:
      the list of upload items
    • getStatistics

      @GET @Path("/statistics") @PermitAll @UnitOfWork("siteDb") public Map<String,Integer> getStatistics()
      The method getStatistics provides means to retrieve the cached upload statistics. The upload statistics contains the number of uploads per month.

      The statistics are cached and updated every 30 minutes.

      Returns:
      the statistics
    • getVersion

      @GET @Path("/version") public Map<String,String> getVersion()
      The method getVersion provides means to retrieve the version number of the API.
      Returns:
      a Map with a single attribute version containing the version number as String.