Class GatewayUtils

java.lang.Object
services.moleculer.web.common.GatewayUtils
All Implemented Interfaces:
HttpConstants

public final class GatewayUtils extends Object implements HttpConstants
  • Field Details

    • urlCache

      protected static final io.datatree.dom.Cache<String,URL> urlCache
    • jarTimestamp

      protected static final long jarTimestamp
  • Constructor Details

    • GatewayUtils

      public GatewayUtils()
  • Method Details

    • sendError

      public static final void sendError(WebResponse rsp, Throwable cause)
    • getService

      public static final <T extends services.moleculer.service.Service> T getService(services.moleculer.ServiceBroker broker, Class<T> type)
    • getCookieValue

      public static final String getCookieValue(WebRequest req, WebResponse rsp, String name)
    • getCookie

      public static final HttpCookie getCookie(WebRequest req, WebResponse rsp, String name)
    • setCookie

      public static final void setCookie(WebResponse rsp, HttpCookie cookie)
    • isReadable

      public static final boolean isReadable(String path)
    • getFileSize

      public static final long getFileSize(String path)
    • getLastModifiedTime

      public static final long getLastModifiedTime(String path)
    • readAllBytes

      public static final byte[] readAllBytes(String path)
    • getFileURL

      public static final URL getFileURL(String path)