Class CategoryServiceImpl

java.lang.Object
io.meeds.social.category.service.CategoryServiceImpl
All Implemented Interfaces:
io.meeds.social.category.service.CategoryService

@Service public class CategoryServiceImpl extends Object implements io.meeds.social.category.service.CategoryService
  • Field Details

  • Constructor Details

    • CategoryServiceImpl

      public CategoryServiceImpl()
  • Method Details

    • getCategoryTree

      public io.meeds.social.category.model.CategoryTree getCategoryTree(io.meeds.social.category.model.CategoryFilter filter, String username, Locale locale)
      Specified by:
      getCategoryTree in interface io.meeds.social.category.service.CategoryService
    • findCategories

      public List<io.meeds.social.category.model.CategorySearchResult> findCategories(io.meeds.social.category.model.CategorySearchFilter filter, String username, Locale locale)
      Specified by:
      findCategories in interface io.meeds.social.category.service.CategoryService
    • getAncestorIds

      public List<Long> getAncestorIds(long categoryId, String username) throws org.exoplatform.commons.exception.ObjectNotFoundException, IllegalAccessException
      Specified by:
      getAncestorIds in interface io.meeds.social.category.service.CategoryService
      Throws:
      org.exoplatform.commons.exception.ObjectNotFoundException
      IllegalAccessException
    • getAncestorIds

      public List<Long> getAncestorIds(long categoryId)
      Specified by:
      getAncestorIds in interface io.meeds.social.category.service.CategoryService
    • getSubcategoryIds

      public List<Long> getSubcategoryIds(String username, long categoryId, long offset, long limit, long depth)
      Specified by:
      getSubcategoryIds in interface io.meeds.social.category.service.CategoryService
    • getSubcategoryIds

      public List<Long> getSubcategoryIds(long categoryId, long offset, long limit, long depth)
      Specified by:
      getSubcategoryIds in interface io.meeds.social.category.service.CategoryService
    • getCategory

      public io.meeds.social.category.model.CategoryWithName getCategory(long categoryId, String username, Locale locale) throws org.exoplatform.commons.exception.ObjectNotFoundException, IllegalAccessException
      Specified by:
      getCategory in interface io.meeds.social.category.service.CategoryService
      Throws:
      org.exoplatform.commons.exception.ObjectNotFoundException
      IllegalAccessException
    • getCategory

      public io.meeds.social.category.model.Category getCategory(long categoryId)
      Specified by:
      getCategory in interface io.meeds.social.category.service.CategoryService
    • getRootCategory

      public io.meeds.social.category.model.Category getRootCategory(long ownerId)
      Specified by:
      getRootCategory in interface io.meeds.social.category.service.CategoryService
    • getDefaultCategoryId

      public long getDefaultCategoryId(String nameId)
      Reads the id CategoryImportService stored for the descriptor's nameId, through its public settings scope and context, so that no bean depends on the importer.
      Specified by:
      getDefaultCategoryId in interface io.meeds.social.category.service.CategoryService
    • createCategory

      public io.meeds.social.category.model.Category createCategory(io.meeds.social.category.model.Category category, String username) throws org.exoplatform.commons.ObjectAlreadyExistsException, org.exoplatform.commons.exception.ObjectNotFoundException, IllegalAccessException
      Specified by:
      createCategory in interface io.meeds.social.category.service.CategoryService
      Throws:
      org.exoplatform.commons.ObjectAlreadyExistsException
      org.exoplatform.commons.exception.ObjectNotFoundException
      IllegalAccessException
    • updateCategory

      public io.meeds.social.category.model.Category updateCategory(io.meeds.social.category.model.Category category, String username) throws org.exoplatform.commons.exception.ObjectNotFoundException, IllegalAccessException
      Specified by:
      updateCategory in interface io.meeds.social.category.service.CategoryService
      Throws:
      org.exoplatform.commons.exception.ObjectNotFoundException
      IllegalAccessException
    • deleteCategory

      public io.meeds.social.category.model.Category deleteCategory(long categoryId, String username) throws org.exoplatform.commons.exception.ObjectNotFoundException, IllegalAccessException
      Specified by:
      deleteCategory in interface io.meeds.social.category.service.CategoryService
      Throws:
      org.exoplatform.commons.exception.ObjectNotFoundException
      IllegalAccessException
    • canEdit

      public boolean canEdit(long categoryId, String username)
      Specified by:
      canEdit in interface io.meeds.social.category.service.CategoryService
    • canEdit

      public boolean canEdit(io.meeds.social.category.model.Category category, String username)
      Specified by:
      canEdit in interface io.meeds.social.category.service.CategoryService
    • canManageLink

      public boolean canManageLink(long categoryId, String username)
      Specified by:
      canManageLink in interface io.meeds.social.category.service.CategoryService
    • canManageLink

      public boolean canManageLink(io.meeds.social.category.model.Category category, String username)
      Specified by:
      canManageLink in interface io.meeds.social.category.service.CategoryService
    • getCategoryEntries

      public io.meeds.social.category.model.CategoryEntryList getCategoryEntries(long categoryId, List<String> objectTypes, String username, long offset, long limit)
      Specified by:
      getCategoryEntries in interface io.meeds.social.category.service.CategoryService