Class PathNormalizer


  • public class PathNormalizer
    extends java.lang.Object
    Utility class for normalizing file paths across different operating systems. Ensures consistent path format and handles platform-specific path separators.
    • Constructor Summary

      Constructors 
      Constructor Description
      PathNormalizer()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.String normalizePath​(java.lang.String path)
      Normalizes file path for cross-platform compatibility.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • PathNormalizer

        public PathNormalizer()
    • Method Detail

      • normalizePath

        public java.lang.String normalizePath​(java.lang.String path)
        Normalizes file path for cross-platform compatibility. Converts path separators and handles platform-specific formatting.
        Parameters:
        path - the path to normalize
        Returns:
        normalized path with forward slashes, or the original path if null/empty