Class UResourceImpl

java.lang.Object
ushiosan.jvm.internal.validators.UResourceValidator
ushiosan.jvm.internal.filesystem.UResourceImpl
Direct Known Subclasses:
UResource

public abstract class UResourceImpl extends UResourceValidator
  • Constructor Details

    • UResourceImpl

      public UResourceImpl()
  • Method Details

    • regexPathOf

      @NotNull public static <T extends Path> @NotNull Predicate<T> regexPathOf(@NotNull @RegExp @NotNull String pattern, boolean fullPath, boolean inverted, @MagicConstant(flagsFromClass=java.util.regex.Pattern.class) int @NotNull ... flags)
      Generates a filter to capture the elements that meet said restriction
      Type Parameters:
      T - generic member type
      Parameters:
      pattern - regular expression to apply
      fullPath - property used to parse the full path or just the file name for matches
      inverted - option to perform the action inverted
      flags - regular expression configuration flags
      Returns:
      the filter instance with the desired behavior
      See Also:
    • regexPathOf

      @NotNull public static <T extends Path> @NotNull Predicate<T> regexPathOf(@NotNull @RegExp @NotNull String pattern, boolean fullPath, @MagicConstant(flagsFromClass=java.util.regex.Pattern.class) int @NotNull ... flags)
      Generates a filter to capture the elements that meet said restriction
      Type Parameters:
      T - generic member type
      Parameters:
      pattern - regular expression to apply
      fullPath - property used to parse the full path or just the file name for matches
      flags - regular expression configuration flags
      Returns:
      the filter instance with the desired behavior
      See Also:
    • regexPathOf

      @NotNull public static <T extends Path> @NotNull Predicate<T> regexPathOf(@NotNull @NotNull Pattern pattern, boolean fullPath, boolean inverted)
      Generates a filter to capture the elements that meet said restriction
      Type Parameters:
      T - generic member type
      Parameters:
      pattern - regular expression to apply
      fullPath - property used to parse the full path or just the file name for matches
      inverted - option to perform the action inverted
      Returns:
      the filter instance with the desired behavior
      See Also:
    • namedPathOf

      @NotNull public static <T extends Path> @NotNull Predicate<T> namedPathOf(boolean inverted, String @NotNull ... names)
      Generates a filter to capture the elements that meet said restriction
      Type Parameters:
      T - generic member type
      Parameters:
      names - the resource possible names
      inverted - option to perform the action inverted
      Returns:
      the filter instance with the desired behavior
    • extensionsPathOf

      @NotNull public static <T extends Path> @NotNull Predicate<T> extensionsPathOf(boolean inverted, String @NotNull ... extensions)
      Generates a filter to capture the elements that meet said restriction
      Type Parameters:
      T - generic member type
      Parameters:
      extensions - the resource possible extensions
      inverted - option to perform the action inverted
      Returns:
      the filter instance with the desired behavior
    • regexFileOf

      @NotNull public static <T extends File> @NotNull Predicate<T> regexFileOf(@NotNull @RegExp @NotNull String pattern, boolean fullPath, boolean inverted, @MagicConstant(flagsFromClass=java.util.regex.Pattern.class) int @NotNull ... flags)
      Generates a filter to capture the elements that meet said restriction
      Type Parameters:
      T - generic member type
      Parameters:
      pattern - regular expression to apply
      fullPath - property used to parse the full path or just the file name for matches
      inverted - option to perform the action inverted
      flags - regular expression configuration flags
      Returns:
      the filter instance with the desired behavior
      See Also:
    • regexFileOf

      @NotNull public static <T extends File> @NotNull Predicate<T> regexFileOf(@NotNull @RegExp @NotNull String pattern, boolean fullPath, @MagicConstant(flagsFromClass=java.util.regex.Pattern.class) int @NotNull ... flags)
      Generates a filter to capture the elements that meet said restriction
      Type Parameters:
      T - generic member type
      Parameters:
      pattern - regular expression to apply
      fullPath - property used to parse the full path or just the file name for matches
      flags - regular expression configuration flags
      Returns:
      the filter instance with the desired behavior
      See Also:
    • regexFileOf

      @NotNull public static <T extends File> @NotNull Predicate<T> regexFileOf(@NotNull @NotNull Pattern pattern, boolean fullPath, boolean inverted)
      Generates a filter to capture the elements that meet said restriction
      Type Parameters:
      T - generic member type
      Parameters:
      pattern - regular expression to apply
      fullPath - property used to parse the full path or just the file name for matches
      inverted - option to perform the action inverted
      Returns:
      the filter instance with the desired behavior
      See Also:
    • namedFileOf

      @NotNull public static <T extends File> @NotNull Predicate<T> namedFileOf(boolean inverted, String @NotNull ... names)
      Generates a filter to capture the elements that meet said restriction
      Type Parameters:
      T - generic member type
      Parameters:
      names - the resource possible names
      inverted - option to perform the action inverted
      Returns:
      the filter instance with the desired behavior
    • extensionsFileOf

      @NotNull public static <T extends File> @NotNull Predicate<T> extensionsFileOf(boolean inverted, String @NotNull ... extensions)
      Generates a filter to capture the elements that meet said restriction
      Type Parameters:
      T - generic member type
      Parameters:
      extensions - the resource possible extensions
      inverted - option to perform the action inverted
      Returns:
      the filter instance with the desired behavior
    • regexEntryOf

      @NotNull public static <T extends ZipEntry> @NotNull Predicate<T> regexEntryOf(@NotNull @RegExp @NotNull String pattern, boolean fullPath, boolean inverted, @MagicConstant(flagsFromClass=java.util.regex.Pattern.class) int @NotNull ... flags)
      Generates a filter to capture the elements that meet said restriction
      Type Parameters:
      T - generic member type
      Parameters:
      pattern - regular expression to apply
      fullPath - property used to parse the full path or just the file name for matches
      inverted - option to perform the action inverted
      flags - regular expression configuration flags
      Returns:
      the filter instance with the desired behavior
      See Also:
    • regexEntryOf

      @NotNull public static <T extends ZipEntry> @NotNull Predicate<T> regexEntryOf(@NotNull @RegExp @NotNull String pattern, boolean fullPath, @MagicConstant(flagsFromClass=java.util.regex.Pattern.class) int @NotNull ... flags)
      Generates a filter to capture the elements that meet said restriction
      Type Parameters:
      T - generic member type
      Parameters:
      pattern - regular expression to apply
      fullPath - property used to parse the full path or just the file name for matches
      flags - regular expression configuration flags
      Returns:
      the filter instance with the desired behavior
      See Also:
    • regexEntryOf

      @NotNull public static <T extends ZipEntry> @NotNull Predicate<T> regexEntryOf(@NotNull @NotNull Pattern pattern, boolean fullPath, boolean inverted)
      Generates a filter to capture the elements that meet said restriction
      Type Parameters:
      T - generic member type
      Parameters:
      pattern - regular expression to apply
      fullPath - property used to parse the full path or just the file name for matches
      inverted - option to perform the action inverted
      Returns:
      the filter instance with the desired behavior
      See Also:
    • namedEntryOf

      @NotNull public static <T extends ZipEntry> @NotNull Predicate<T> namedEntryOf(boolean inverted, String @NotNull ... names)
      Generates a filter to capture the elements that meet said restriction
      Type Parameters:
      T - generic member type
      Parameters:
      names - the resource possible names
      inverted - option to perform the action inverted
      Returns:
      the filter instance with the desired behavior
    • extensionsEntryOf

      @NotNull public static <T extends ZipEntry> @NotNull Predicate<T> extensionsEntryOf(boolean inverted, String @NotNull ... extensions)
      Generates a filter to capture the elements that meet said restriction
      Type Parameters:
      T - generic member type
      Parameters:
      extensions - the resource possible extensions
      inverted - option to perform the action inverted
      Returns:
      the filter instance with the desired behavior