Class ResourceUtils

java.lang.Object
io.smallrye.common.resource.ResourceUtils

public final class ResourceUtils extends Object
Miscellaneous resource-related utilities.
  • Method Details

    • canonicalizeRelativePath

      public static String canonicalizeRelativePath(String path)
      An efficient relative path string canonicalizer which avoids copying and allocation to the maximum possible extent. The canonical path has no . or .. segments, does not contain consecutive /, and does not begin or end with a /.
      Parameters:
      path - the path name (must not be null)
      Returns:
      the canonical equivalent path (not null)