From f5adf51f59628c210d6bc8838df99d9b64002ee5 Mon Sep 17 00:00:00 2001 From: ulrich Date: Fri, 25 Jun 2021 09:55:05 +0000 Subject: [PATCH] Logik in den Actor ausgelagert --- src/de/uhilger/httpserver/adoc/AdocHandler.java | 9 ++++----- 1 files changed, 4 insertions(+), 5 deletions(-) diff --git a/src/de/uhilger/httpserver/adoc/AdocHandler.java b/src/de/uhilger/httpserver/adoc/AdocHandler.java index 2c4a63f..6edfb7a 100644 --- a/src/de/uhilger/httpserver/adoc/AdocHandler.java +++ b/src/de/uhilger/httpserver/adoc/AdocHandler.java @@ -18,9 +18,7 @@ package de.uhilger.httpserver.adoc; import com.sun.net.httpserver.HttpExchange; -import de.uhilger.httpserver.base.HttpResponder; import de.uhilger.httpserver.base.handler.FileHandler; -import java.io.File; import java.io.IOException; import java.net.URI; import java.util.logging.Logger; @@ -53,6 +51,9 @@ String requestPathStr = uri.getPath(); //logger.fine("filter: " + requestUriStr); if(requestPathStr.toLowerCase().endsWith(AdocFilter.ADOC)) { + AdocActor actor = new AdocActor(); + actor.handle(e, fileBase, getFileName(e)); + /* File adocfile = new File(fileBase, getFileName(e)); logger.fine("adocfile: " + adocfile.getAbsolutePath()); AdocActor actor = new AdocActor(); @@ -60,14 +61,12 @@ logger.fine("outfile: " + outfile.getAbsolutePath()); HttpResponder fs = new HttpResponder(); fs.serveFile(e, outfile); + */ } else { super.handle(e); // andere Inhalte zu FileHandler delegieren } } - public String getFileBase() { - return this.fileBase; - } } -- Gitblit v1.9.3