Interface INewsletterTopicService

  • All Known Implementing Classes:
    FreeHtmlTopicService

    public interface INewsletterTopicService
    Interface of services that provide topics for newsletters
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      void copyNewsletterTopic​(int oldTopicId, NewsletterTopic newsletterTopic, fr.paris.lutece.portal.business.user.AdminUser user, java.util.Locale locale)
      Copy a topic for a newsletter.
      void createNewsletterTopic​(NewsletterTopic newsletterTopic, fr.paris.lutece.portal.business.user.AdminUser user, java.util.Locale locale)
      Creates a new topic for a newsletter
      java.lang.String getConfigurationPage​(NewsletterTopic newsletterTopic, java.lang.String strBaseUrl, fr.paris.lutece.portal.business.user.AdminUser user, java.util.Locale locale)
      Get the configuration page of the content type.
      java.lang.String getHtmlContent​(NewsletterTopic newsletterTopic, fr.paris.lutece.portal.business.user.AdminUser user, java.util.Locale locale)
      Get the html content of a topic.
      java.lang.String getNewsletterTopicTypeCode()
      Get the unique code of the topic type associated with this service.
      java.lang.String getNewsletterTopicTypeName​(java.util.Locale locale)
      Get the localized name of the topic type associated with this service.
      boolean hasConfiguration()
      Check if topics of this topic type need a configuration or not.
      void removeNewsletterTopic​(int nNewsletterTopicId)
      Remove a newsletter topic from its id.
      void saveConfiguration​(java.util.Map<java.lang.String,​java.lang.String[]> mapParameters, NewsletterTopic newsletterTopic, fr.paris.lutece.portal.business.user.AdminUser user, java.util.Locale locale)  
    • Method Detail

      • getNewsletterTopicTypeCode

        java.lang.String getNewsletterTopicTypeCode()
        Get the unique code of the topic type associated with this service.
        Returns:
        The unique code of the topic type associated with this service.
      • getNewsletterTopicTypeName

        java.lang.String getNewsletterTopicTypeName​(java.util.Locale locale)
        Get the localized name of the topic type associated with this service.
        Parameters:
        locale - The locale to use
        Returns:
        The name of the topic type associated with this service in the given locale.
      • hasConfiguration

        boolean hasConfiguration()
        Check if topics of this topic type need a configuration or not.
        Returns:
        True if topics of this topic type has a configuration page or not.
      • getConfigurationPage

        java.lang.String getConfigurationPage​(NewsletterTopic newsletterTopic,
                                              java.lang.String strBaseUrl,
                                              fr.paris.lutece.portal.business.user.AdminUser user,
                                              java.util.Locale locale)
        Get the configuration page of the content type.
        Parameters:
        newsletterTopic - The newsletter topic to get the configuration of.
        strBaseUrl - The base url
        user - The current user
        locale - The locale
        Returns:
        The HTML code of the configuration page
      • saveConfiguration

        void saveConfiguration​(java.util.Map<java.lang.String,​java.lang.String[]> mapParameters,
                               NewsletterTopic newsletterTopic,
                               fr.paris.lutece.portal.business.user.AdminUser user,
                               java.util.Locale locale)
        Parameters:
        mapParameters - The collection of parameters of the configuration. Those parameters are request parameters in request contexts.
        newsletterTopic - The newsletter topic to get the configuration of.
        user - The current user
        locale - The locale
      • createNewsletterTopic

        void createNewsletterTopic​(NewsletterTopic newsletterTopic,
                                   fr.paris.lutece.portal.business.user.AdminUser user,
                                   java.util.Locale locale)
        Creates a new topic for a newsletter
        Parameters:
        newsletterTopic - The details of the topic to create
        user - The current user
        locale - The locale
      • removeNewsletterTopic

        void removeNewsletterTopic​(int nNewsletterTopicId)
        Remove a newsletter topic from its id.
        Parameters:
        nNewsletterTopicId - The id of the topic to remove.
      • getHtmlContent

        java.lang.String getHtmlContent​(NewsletterTopic newsletterTopic,
                                        fr.paris.lutece.portal.business.user.AdminUser user,
                                        java.util.Locale locale)
        Get the html content of a topic.
        Parameters:
        newsletterTopic - The topic to get the html of.
        user - The current user
        locale - The locale
        Returns:
        The html content describing the topic to add to the newsletter.
      • copyNewsletterTopic

        void copyNewsletterTopic​(int oldTopicId,
                                 NewsletterTopic newsletterTopic,
                                 fr.paris.lutece.portal.business.user.AdminUser user,
                                 java.util.Locale locale)
        Copy a topic for a newsletter.
        Parameters:
        id - of the old newsletterTopic
        newsletterTopic - The details of the topic to create
        user - The current user
        locale - The locale