This commit is contained in:
Looly 2024-11-18 09:43:56 +08:00
parent e3a60ad93f
commit 53e36eff3e
4 changed files with 5 additions and 5 deletions

View File

@ -188,7 +188,7 @@ public class SimpleServer {
* @return this
*/
public SimpleServer setRoot(final File root) {
this.engine.setHandler(new RootHandler(root));
addAction("/", new RootHandler(root));
return this;
}

View File

@ -27,7 +27,7 @@ import java.io.Closeable;
* @author looly
* @since 5.2.6
*/
public class SunServerBase implements Closeable {
public class SunServerExchangeBase implements Closeable {
protected final HttpExchange httpExchange;
@ -36,7 +36,7 @@ public class SunServerBase implements Closeable {
*
* @param httpExchange {@link HttpExchange}
*/
public SunServerBase(final HttpExchange httpExchange) {
public SunServerExchangeBase(final HttpExchange httpExchange) {
this.httpExchange = httpExchange;
}

View File

@ -47,7 +47,7 @@ import java.util.Map;
*
* @author Looly
*/
public class SunServerRequest extends SunServerBase implements ServerRequest {
public class SunServerRequest extends SunServerExchangeBase implements ServerRequest {
private Map<String, HttpCookie> cookieCache;
private ListValueMap<String, String> paramsCache;

View File

@ -37,7 +37,7 @@ import java.util.Map;
* @author looly
* @since 6.0.0
*/
public class SunServerResponse extends SunServerBase implements ServerResponse {
public class SunServerResponse extends SunServerExchangeBase implements ServerResponse {
private Charset charset;
/**