Class DirectRead

  • All Implemented Interfaces:
    Function<String,​Response>, AssetsRead

    public class DirectRead
    extends Object
    Author:
    Denis Danilin | me@loslobos.ru 04.03.2023 13:30 fair-http-server ☭ sweat and blood
    • Field Detail

      • autoDirList

        protected final boolean autoDirList
      • gotIndex

        protected final boolean gotIndex
      • indexFile

        protected final Set<String> indexFile
      • cache

        protected final boolean cache
      • maxCacheSize

        protected final long maxCacheSize
      • maxCacheLife

        protected final long maxCacheLife
      • namedRef

        protected final String namedRef
    • Constructor Detail

      • DirectRead

        public DirectRead​(com.typesafe.config.Config staticsCfg,
                          String root)
    • Method Detail

      • fileResponse

        public static Response fileResponse​(Path p,
                                            String mimeType,
                                            long size)
      • canProcess

        public boolean canProcess​(String webpath)
      • dirList

        protected byte[] dirList​(String dirName,
                                 Collection<org.logdoc.fairhttp.service.http.statics.StaticRead.FRes> content)
      • rememberMime

        protected void rememberMime​(String id,
                                    String mime)