Class PrettyPrint

java.lang.Object
org.ddolib.util.PrettyPrint

public class PrettyPrint extends Object
Collection of utility functions for formatting data for display.
  • Constructor Details

    • PrettyPrint

      public PrettyPrint()
  • Method Details

    • formatMs

      public static String formatMs(long durationMs)
      Formats a duration in milliseconds into a human-readable string. The format includes hours, minutes, seconds, and milliseconds as needed (e.g., " 1 h 12 min 30 sec 500 ms").
      Parameters:
      durationMs - the duration in milliseconds to format
      Returns:
      a formatted string representing the duration