Class ResourceListingUtils

java.lang.Object
org.jboss.as.test.shared.ResourceListingUtils

public class ResourceListingUtils extends Object
  • Constructor Details

    • ResourceListingUtils

      public ResourceListingUtils()
  • Method Details

    • listResources

      public static List<String> listResources(org.jboss.modules.ModuleClassLoader classLoader, String rootDir, boolean recursive)
      Lists resources in deployment using provided API for iterating resources
      Parameters:
      classLoader - the deployment class loader
      rootDir - directory which should be considered as root
      recursive - if true also a recursive resources are taken into account, otherwise only resources in rootDir are considered
      Returns:
      list of resources returned by the API for iterating over deployment resources
    • classToPath

      public static String classToPath(Class clazz)
      translates path to class in package notation to standard path notation with addition of .class suffix
      Parameters:
      clazz - class in package notation
      Returns:
      path representation of class
    • filterResources

      public static void filterResources(Collection<String> resources, String rootDir, boolean removeRecursive)
      Filters resources in collection using specified parameters
      Parameters:
      resources - collection to be filtered
      rootDir - what is the root directory of resources which should be taken into account
      removeRecursive - if recursive resources should be removed or not (true means recursive resources are removed, false means that they are preserved)