public static CategoryTree create(final List<Category> allCategoriesAsFlatListWithoutChildrenSettings) { final List<Category> categoryTreeList = categoriesOrganizedAsTree(allCategoriesAsFlatListWithoutChildrenSettings); final List<Category> allAsFlatList = getAllRecursive(categoryTreeList); final Map<LocaleSlugPair, Category> categoriesByLocaleAndSlug = buildBySlugMap(allAsFlatList); final Map<String, Category> categoriesById = buildByIdMap(allAsFlatList); return new CategoryTreeImpl(categoryTreeList, allAsFlatList, categoriesByLocaleAndSlug, categoriesById); }
public static CategoryTree create(final List<Category> allCategoriesAsFlatListWithoutChildrenSettings) { final List<Category> categoryTreeList = categoriesOrganizedAsTree(allCategoriesAsFlatListWithoutChildrenSettings); final List<Category> allAsFlatList = getAllRecursive(categoryTreeList); final Map<LocaleSlugPair, Category> categoriesByLocaleAndSlug = buildBySlugMap(allAsFlatList); final Map<String, Category> categoriesById = buildByIdMap(allAsFlatList); return new CategoryTreeImpl(categoryTreeList, allAsFlatList, categoriesByLocaleAndSlug, categoriesById); }
public static CategoryTree create(final List<Category> allCategoriesAsFlatListWithoutChildrenSettings) { final List<Category> categoryTreeList = categoriesOrganizedAsTree(allCategoriesAsFlatListWithoutChildrenSettings); final List<Category> allAsFlatList = getAllRecursive(categoryTreeList); final Map<LocaleSlugPair, Category> categoriesByLocaleAndSlug = buildBySlugMap(allAsFlatList); final Map<String, Category> categoriesById = buildByIdMap(allAsFlatList); return new CategoryTreeImpl(categoryTreeList, allAsFlatList, categoriesByLocaleAndSlug, categoriesById); }