Class TikaMimeTypes


  • @Path("/mime-types")
    public class TikaMimeTypes
    extends Object

    Provides details of all the mimetypes known to Apache Tika, similar to --list-supported-types with the Tika CLI.

    Can also provide full details on a single known type.

    • Constructor Detail

      • TikaMimeTypes

        public TikaMimeTypes()
    • Method Detail

      • getMimeTypesHTML

        @GET
        @Produces("text/html")
        public String getMimeTypesHTML()
      • getMimeTypeDetailsHTML

        @GET
        @Path("/{type}/{subtype}")
        @Produces("text/html")
        public String getMimeTypeDetailsHTML​(@PathParam("type")
                                             String typePart,
                                             @PathParam("subtype")
                                             String subtype)
      • getMimeTypeDetailsJSON

        @GET
        @Path("/{type}/{subtype}")
        @Produces("application/json")
        public String getMimeTypeDetailsJSON​(@PathParam("type")
                                             String typePart,
                                             @PathParam("subtype")
                                             String subtype)
                                      throws IOException
        Throws:
        IOException
      • getMimeTypesPlain

        @GET
        @Produces("text/plain")
        public String getMimeTypesPlain()
      • getMediaType

        protected org.apache.tika.server.core.resource.TikaMimeTypes.MediaTypeDetails getMediaType​(String type,
                                                                                                   String subtype)
                                                                                            throws javax.ws.rs.NotFoundException
        Throws:
        javax.ws.rs.NotFoundException
      • getMediaTypes

        protected List<org.apache.tika.server.core.resource.TikaMimeTypes.MediaTypeDetails> getMediaTypes()