Class AbstractAdminResource

    • Constructor Detail

      • AbstractAdminResource

        public AbstractAdminResource()
    • Method Detail

      • loadSpace

        protected SpaceInstLight loadSpace​(String spaceId)
        Loading data centralization of a space
        Parameters:
        spaceId - the space identifier
        Returns:
        the space instance light representation
      • loadSpaces

        protected Collection<SpaceInstLight> loadSpaces​(String... spaceIds)
        Loading data centralization of spaces
        Parameters:
        spaceIds - the space identifiers
        Returns:
        never null collection of spaces
      • loadComponent

        protected ComponentInstLight loadComponent​(String componentId)
        Loading data centralization of a space
        Parameters:
        componentId - the component instance identifier
        Returns:
      • loadComponents

        protected Collection<ComponentInstLight> loadComponents​(String... componentIds)
        Loading data centralization of components
        Parameters:
        componentIds - the component instance identifiers
        Returns:
        never null collection of components
      • asWebEntities

        protected <T,​E extends AbstractTypeEntityCollection<E> asWebEntities​(Class<E> entityClass,
                                                                                     Collection<T> data)
        Converts the given list of data into their corresponding web entities.
        Parameters:
        entityClass - the entity class returned.
        data - data to convert.
        Returns:
        an array with the corresponding web entities.
      • asWebEntities

        protected <T,​E extends AbstractTypeEntityCollection<E> asWebEntities​(Class<E> entityClass,
                                                                                     Collection<T> data,
                                                                                     boolean forceGettingFavorite)
        Converts the given list of data into their corresponding web entities.
        Parameters:
        entityClass - the entity class returned.
        data - data to convert.
        forceGettingFavorite - forcing the user favorite space search even if the favorite feature is disabled
        Returns:
        an array with the corresponding web entities.
      • asWebPersonalEntities

        protected <T,​E extends AbstractTypeEntityCollection<E> asWebPersonalEntities​(Collection<T> data)
        Converts the given list of data into their corresponding web entities.
        Parameters:
        data - data to convert.
        Returns:
        an array with the corresponding web entities.
      • asWebEntity

        protected SpaceEntity asWebEntity​(SpaceInstLight space,
                                          boolean forceGettingFavorite)
        Converts the space into its corresponding web entity.
        Parameters:
        space - the space to convert.
        forceGettingFavorite - forcing the user favorite space search even if the favorite
        Returns:
        the corresponding space entity.
      • asWebEntity

        protected SpaceAppearanceEntity asWebEntity​(SpaceInstLight space,
                                                    String look,
                                                    String wallpaper,
                                                    String css)
        Converts the space appearance into its corresponding web entity.
        Parameters:
        space - the aimed space appearance to convert.
        look - the look associated to the given space.
        wallpaper - the wallpaper associated to the given space.
        Returns:
        the corresponding space appearance entity.
      • asWebEntity

        protected ComponentEntity asWebEntity​(ComponentInstLight component)
        Converts the component into its corresponding web entity.
        Parameters:
        component - the component to convert.
        Returns:
        the corresponding component entity.
      • asWebPersonalEntity

        protected PersonalComponentEntity asWebPersonalEntity​(SilverpeasComponent component)
        Converts the personal component into its corresponding web entity.
        Parameters:
        component - the personal component to convert.
        Returns:
        the corresponding personal component entity.
      • asWebPersonalEntity

        protected PersonalComponentEntity asWebPersonalEntity​(SilverpeasComponentInstance component)
        Converts the personal component into its corresponding web entity.
        Parameters:
        component - the personal component to convert.
        Returns:
        the corresponding personal component entity.
      • asWebPersonalEntity

        protected PersonalToolEntity asWebPersonalEntity​(AbstractTool tool)
        Converts the tool into its corresponding web entity.
        Parameters:
        tool - the tool to convert.
        Returns:
        the corresponding tool entity.
      • asWebEntity

        protected AbstractTypeEntity asWebEntity​(Object object)
        Converts the component into its corresponding web entity.
        Parameters:
        object - any object instance.
        Returns:
        the corresponding component entity.
      • getAdminServices

        protected AdminWebService getAdminServices()
        Returns:
        the common admin services
      • getAdminPersonalDelegate

        protected AdminPersonalWebDelegate getAdminPersonalDelegate()
        Returns:
        the commin admin personal services
      • verifyUserAuthorizedToAccessSpace

        protected void verifyUserAuthorizedToAccessSpace​(String spaceId)
        Verifies the requester user is authorized to access the given space
        Parameters:
        spaceId - the space identifier
      • verifyUserAuthorizedToAccessLookContext

        protected void verifyUserAuthorizedToAccessLookContext()
        Verifies the requester user is authorized to access the given space
      • isUserAuthorizedToAccessLookContext

        protected boolean isUserAuthorizedToAccessLookContext()
        Indicates if the requester user is authorized to access the given space
      • getLookDelegate

        protected LookWebDelegate getLookDelegate()
        Returns:
        the common look services for Web Services