Class NaruUtils

java.lang.Object
net.thevpc.naru.impl.util.NaruUtils

public class NaruUtils extends Object
  • Constructor Details

    • NaruUtils

      public NaruUtils()
  • Method Details

    • formatDirective

      public static net.thevpc.nuts.text.NMsg formatDirective(String name)
    • checkValidRoutineName

      public static void checkValidRoutineName(String text)
    • isValidRoutineName

      public static boolean isValidRoutineName(String text)
    • stripAnsi

      public static String stripAnsi(String text)
    • parseEnv

      public static Map<String,net.thevpc.nuts.elem.NElement> parseEnv(String msg)
    • parseEnv

      public static Map<String,net.thevpc.nuts.elem.NElement> parseEnv(net.thevpc.nuts.elem.NElement aa)
    • abbreviate

      public static String abbreviate(String s, int max)
    • logWebRequest

      public static void logWebRequest(net.thevpc.nuts.net.NWebRequest request, net.thevpc.nuts.text.NMsg text, Object input)
    • logWebResponse

      public static void logWebResponse(net.thevpc.nuts.net.NWebRequest request, net.thevpc.nuts.text.NMsg text, Object input, Object output, net.thevpc.nuts.time.NChronometer chronometer)
    • showItems

      public static void showItems(List<net.thevpc.nuts.text.NText> items, Set<Integer> toShow, NaruTask task)
    • isPath

      public static boolean isPath(String command)
    • snippet

      public static String snippet(String content)
    • resolveIndexes

      public static Set<Integer> resolveIndexes(NaruUtils.LineRange[] ranges, int count)
    • parseRanges

      public static List<NaruUtils.LineRange> parseRanges(net.thevpc.nuts.cmdline.NCmdLine cmdLine)
    • formattedTokensSize

      public static net.thevpc.nuts.text.NText formattedTokensSize(long cl)
    • showItemsWithFormat

      public static void showItemsWithFormat(String context2, String format, List<NaruUtils.LineRange> ranges, NaruTask task)
    • timeAgo

      public static String timeAgo(Instant instant)