X-Git-Url: https://code.wpia.club/?p=gigi.git;a=blobdiff_plain;f=lib%2Fjetty%2Forg%2Feclipse%2Fjetty%2Futil%2Fresource%2FResource.java;h=7c9c8ecd46cc8228027abdcdc288743ea16b0984;hp=b36a935582366c10b84c8430b4a973a2f5cdc55d;hb=ba4f228fa9f72d50991a2218cfd83987ef5d385e;hpb=875b5e9651498a0cd8e0001c0742ba843e47cad0 diff --git a/lib/jetty/org/eclipse/jetty/util/resource/Resource.java b/lib/jetty/org/eclipse/jetty/util/resource/Resource.java index b36a9355..7c9c8ecd 100644 --- a/lib/jetty/org/eclipse/jetty/util/resource/Resource.java +++ b/lib/jetty/org/eclipse/jetty/util/resource/Resource.java @@ -1,6 +1,6 @@ // // ======================================================================== -// Copyright (c) 1995-2014 Mort Bay Consulting Pty. Ltd. +// Copyright (c) 1995-2016 Mort Bay Consulting Pty. Ltd. // ------------------------------------------------------------------------ // All rights reserved. This program and the accompanying materials // are made available under the terms of the Eclipse Public License v1.0 @@ -193,7 +193,7 @@ public abstract class Resource implements ResourceFactory, Closeable } } - return newResource(url); + return newResource(url, useCaches); } /* ------------------------------------------------------------ */ @@ -352,6 +352,7 @@ public abstract class Resource implements ResourceFactory, Closeable /** * Returns an URL representing the given resource */ + // TODO: should deprecate this one and only use getURI() public abstract URL getURL(); /* ------------------------------------------------------------ */ @@ -405,6 +406,7 @@ public abstract class Resource implements ResourceFactory, Closeable /** * Deletes the given resource */ + // TODO: can throw IOException public abstract boolean delete() throws SecurityException; @@ -412,6 +414,7 @@ public abstract class Resource implements ResourceFactory, Closeable /** * Rename the given resource */ + // TODO: can throw IOException public abstract boolean renameTo( Resource dest) throws SecurityException; @@ -420,6 +423,7 @@ public abstract class Resource implements ResourceFactory, Closeable * Returns a list of resource names contained in the given resource * The resource names are not URL encoded. */ + // TODO: can throw IOException public abstract String[] list(); /* ------------------------------------------------------------ */ @@ -545,7 +549,7 @@ public abstract class Resource implements ResourceFactory, Closeable buf.append(""); } buf.append("\n"); - buf.append("\n"); + buf.append("\n"); return buf.toString(); } @@ -609,7 +613,7 @@ public abstract class Resource implements ResourceFactory, Closeable private static String deTag(String raw) { - return StringUtil.replace( StringUtil.replace(raw,"<","<"), ">", ">"); + return StringUtil.sanitizeXmlString(raw); } /* ------------------------------------------------------------ */