Class FontResourceServlet

java.lang.Object
javax.servlet.GenericServlet
javax.servlet.http.HttpServlet
com.levigo.jadice.web.server.FontDownloadServlet
com.levigo.jadice.web.server.FontResourceServlet
All Implemented Interfaces:
Serializable, javax.servlet.Servlet, javax.servlet.ServletConfig

@WebServlet(description="Servlet providing font-related resources", displayName="jadice web toolkit font resources download", name="jwtFontResourceServlet", urlPatterns="/jwt/fontresources/*") public class FontResourceServlet extends FontDownloadServlet
A servlet providing static font-related resources. Currently only webfontloader.js (formerly: webfonts.js) and the JWT-icon-font is served.
See Also:
  • Constructor Details

    • FontResourceServlet

      public FontResourceServlet()
  • Method Details

    • doGet

      protected void doGet(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response) throws javax.servlet.ServletException, IOException
      Overrides:
      doGet in class FontDownloadServlet
      Throws:
      javax.servlet.ServletException
      IOException
    • addContentTypeHeaders

      protected void addContentTypeHeaders(javax.servlet.http.HttpServletResponse response, String fileName)
      Sets the content-type for a requested resource. This logic is very simple as not many different file-types are served
      Parameters:
      response - the servlet-response
      fileName - the name of the resource