Class NewsLetterTemplateHome
- java.lang.Object
-
- fr.paris.lutece.plugins.newsletter.business.NewsLetterTemplateHome
-
public final class NewsLetterTemplateHome extends java.lang.ObjectThis class provides instances management methods (create, find, ...) for NewsLetterTemplate objects
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static NewsLetterTemplatecreate(NewsLetterTemplate newsletterTemplate, fr.paris.lutece.portal.service.plugin.Plugin plugin)Creation of an instance of a newsletter templatestatic NewsLetterTemplatefindByPrimaryKey(int nKey, fr.paris.lutece.portal.service.plugin.Plugin plugin)Returns an object NewsLetter's template from its identifierstatic fr.paris.lutece.util.ReferenceListgetTemplateListByRef(fr.paris.lutece.portal.service.plugin.Plugin plugin)Fetches a template liststatic java.util.List<NewsLetterTemplate>getTemplatesCollectionByType(java.lang.String strTopicType, fr.paris.lutece.portal.service.plugin.Plugin plugin)Returns a list of templates depending on the given topic typestatic java.util.Collection<NewsLetterTemplate>getTemplatesList(fr.paris.lutece.portal.service.plugin.Plugin plugin)Returns the list of every templatesstatic fr.paris.lutece.util.ReferenceListgetTemplatesListByType(java.lang.String strTopicType, fr.paris.lutece.portal.service.plugin.Plugin plugin)Returns a list of templates depending on the given typestatic java.util.Collection<NewsLetterTemplate>getTemplatesListByWorkgoup(java.lang.String strWorkgroupKey, fr.paris.lutece.portal.service.plugin.Plugin plugin)Returns the list of templates associated with a given workgroupstatic voidremove(int nNewsLetterTemplateId, fr.paris.lutece.portal.service.plugin.Plugin plugin)Remove the record from the template identifierstatic NewsLetterTemplateupdate(NewsLetterTemplate newsletterTemplate, fr.paris.lutece.portal.service.plugin.Plugin plugin)Update of an instance of a newsletter template
-
-
-
Method Detail
-
getTemplatesList
public static java.util.Collection<NewsLetterTemplate> getTemplatesList(fr.paris.lutece.portal.service.plugin.Plugin plugin)
Returns the list of every templates- Parameters:
plugin- The Plugin- Returns:
- a collection object
-
getTemplatesListByType
public static fr.paris.lutece.util.ReferenceList getTemplatesListByType(java.lang.String strTopicType, fr.paris.lutece.portal.service.plugin.Plugin plugin)Returns a list of templates depending on the given type- Parameters:
strTopicType- the topic type of templates to retrieveplugin- The Plugin- Returns:
- a Referencelist object
-
getTemplatesCollectionByType
public static java.util.List<NewsLetterTemplate> getTemplatesCollectionByType(java.lang.String strTopicType, fr.paris.lutece.portal.service.plugin.Plugin plugin)
Returns a list of templates depending on the given topic type- Parameters:
strTopicType- the topic type of templates to retrieveplugin- The Plugin- Returns:
- a Collection object
-
create
public static NewsLetterTemplate create(NewsLetterTemplate newsletterTemplate, fr.paris.lutece.portal.service.plugin.Plugin plugin)
Creation of an instance of a newsletter template- Parameters:
newsletterTemplate- template An instance of a newsletter template which contains the informations to storeplugin- The Plugin- Returns:
- The instance of a newsletter template which has been created with its primary key.
-
findByPrimaryKey
public static NewsLetterTemplate findByPrimaryKey(int nKey, fr.paris.lutece.portal.service.plugin.Plugin plugin)
Returns an object NewsLetter's template from its identifier- Parameters:
nKey- the primary key of the newsletter's templateplugin- The Plugin- Returns:
- an instance of the class
-
update
public static NewsLetterTemplate update(NewsLetterTemplate newsletterTemplate, fr.paris.lutece.portal.service.plugin.Plugin plugin)
Update of an instance of a newsletter template- Parameters:
newsletterTemplate- template An instance of a newsletter template which contains the informations to storeplugin- The Plugin- Returns:
- The instance of a newsletter template which has been updated with its primary key.
-
remove
public static void remove(int nNewsLetterTemplateId, fr.paris.lutece.portal.service.plugin.Plugin plugin)Remove the record from the template identifier- Parameters:
nNewsLetterTemplateId- the template identifierplugin- the Plugin
-
getTemplateListByRef
public static fr.paris.lutece.util.ReferenceList getTemplateListByRef(fr.paris.lutece.portal.service.plugin.Plugin plugin)
Fetches a template list- Parameters:
plugin- The plugin- Returns:
- A reference list
-
getTemplatesListByWorkgoup
public static java.util.Collection<NewsLetterTemplate> getTemplatesListByWorkgoup(java.lang.String strWorkgroupKey, fr.paris.lutece.portal.service.plugin.Plugin plugin)
Returns the list of templates associated with a given workgroup- Parameters:
strWorkgroupKey- The workgoup keyplugin- The Plugin- Returns:
- a collection object
-
-