Liferay 6.0.5

com.liferay.portlet.journal.service
Class JournalTemplateLocalServiceUtil

java.lang.Object
  extended by com.liferay.portlet.journal.service.JournalTemplateLocalServiceUtil

public class JournalTemplateLocalServiceUtil
extends Object

The utility for the journal template local service. This utility wraps JournalTemplateLocalServiceImpl and is the primary access point for service operations in application layer code running on the local server.

Never modify this class directly. Add custom service methods to JournalTemplateLocalServiceImpl and rerun ServiceBuilder to regenerate this class.

This is a local service. Methods of this service will not have security checks based on the propagated JAAS credentials because this service can only be accessed from within the same VM.

See Also:
JournalTemplateLocalService, JournalTemplateLocalServiceBaseImpl, JournalTemplateLocalServiceImpl
ServiceBuilder generated this class. Modifications in this class will be overwritten the next time is generated.

Constructor Summary
JournalTemplateLocalServiceUtil()
           
 
Method Summary
static JournalTemplate addJournalTemplate(JournalTemplate journalTemplate)
          Adds the journal template to the database.
static JournalTemplate addTemplate(long userId, long groupId, String templateId, boolean autoTemplateId, String structureId, String name, String description, String xsl, boolean formatXsl, String langType, boolean cacheable, boolean smallImage, String smallImageURL, File smallFile, ServiceContext serviceContext)
           
static void addTemplateResources(JournalTemplate template, boolean addCommunityPermissions, boolean addGuestPermissions)
           
static void addTemplateResources(JournalTemplate template, String[] communityPermissions, String[] guestPermissions)
           
static void addTemplateResources(long groupId, String templateId, boolean addCommunityPermissions, boolean addGuestPermissions)
           
static void addTemplateResources(long groupId, String templateId, String[] communityPermissions, String[] guestPermissions)
           
static void checkNewLine(long groupId, String templateId)
           
static JournalTemplate copyTemplate(long userId, long groupId, String oldTemplateId, String newTemplateId, boolean autoTemplateId)
           
static JournalTemplate createJournalTemplate(long id)
          Creates a new journal template with the primary key.
static void deleteJournalTemplate(JournalTemplate journalTemplate)
          Deletes the journal template from the database.
static void deleteJournalTemplate(long id)
          Deletes the journal template with the primary key from the database.
static void deleteTemplate(JournalTemplate template)
           
static void deleteTemplate(long groupId, String templateId)
           
static void deleteTemplates(long groupId)
           
static List dynamicQuery(DynamicQuery dynamicQuery)
          Performs a dynamic query on the database and returns the matching rows.
static List dynamicQuery(DynamicQuery dynamicQuery, int start, int end)
          Performs a dynamic query on the database and returns a range of the matching rows.
static List dynamicQuery(DynamicQuery dynamicQuery, int start, int end, OrderByComparator orderByComparator)
          Performs a dynamic query on the database and returns an ordered range of the matching rows.
static long dynamicQueryCount(DynamicQuery dynamicQuery)
          Counts the number of rows that match the dynamic query.
static JournalTemplate getJournalTemplate(long id)
          Gets the journal template with the primary key.
static JournalTemplate getJournalTemplateByUuidAndGroupId(String uuid, long groupId)
          Gets the journal template with the UUID and group id.
static List<JournalTemplate> getJournalTemplates(int start, int end)
          Gets a range of all the journal templates.
static int getJournalTemplatesCount()
          Gets the number of journal templates.
static JournalTemplateLocalService getService()
           
static List<JournalTemplate> getStructureTemplates(long groupId, String structureId)
           
static List<JournalTemplate> getStructureTemplates(long groupId, String structureId, int start, int end)
           
static int getStructureTemplatesCount(long groupId, String structureId)
           
static JournalTemplate getTemplate(long id)
           
static JournalTemplate getTemplate(long groupId, String templateId)
           
static JournalTemplate getTemplateBySmallImageId(long smallImageId)
           
static List<JournalTemplate> getTemplates()
           
static List<JournalTemplate> getTemplates(long groupId)
           
static List<JournalTemplate> getTemplates(long groupId, int start, int end)
           
static int getTemplatesCount(long groupId)
           
static boolean hasTemplate(long groupId, String templateId)
           
static List<JournalTemplate> search(long companyId, long groupId, String keywords, String structureId, String structureIdComparator, int start, int end, OrderByComparator obc)
           
static List<JournalTemplate> search(long companyId, long groupId, String templateId, String structureId, String structureIdComparator, String name, String description, boolean andOperator, int start, int end, OrderByComparator obc)
           
static int searchCount(long companyId, long groupId, String keywords, String structureId, String structureIdComparator)
           
static int searchCount(long companyId, long groupId, String templateId, String structureId, String structureIdComparator, String name, String description, boolean andOperator)
           
 void setService(JournalTemplateLocalService service)
           
static JournalTemplate updateJournalTemplate(JournalTemplate journalTemplate)
          Updates the journal template in the database.
static JournalTemplate updateJournalTemplate(JournalTemplate journalTemplate, boolean merge)
          Updates the journal template in the database.
static JournalTemplate updateTemplate(long groupId, String templateId, String structureId, String name, String description, String xsl, boolean formatXsl, String langType, boolean cacheable, boolean smallImage, String smallImageURL, File smallFile, ServiceContext serviceContext)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JournalTemplateLocalServiceUtil

public JournalTemplateLocalServiceUtil()
Method Detail

addJournalTemplate

public static JournalTemplate addJournalTemplate(JournalTemplate journalTemplate)
                                          throws SystemException
Adds the journal template to the database. Also notifies the appropriate model listeners.

Parameters:
journalTemplate - the journal template to add
Returns:
the journal template that was added
Throws:
SystemException - if a system exception occurred

createJournalTemplate

public static JournalTemplate createJournalTemplate(long id)
Creates a new journal template with the primary key. Does not add the journal template to the database.

Parameters:
id - the primary key for the new journal template
Returns:
the new journal template

deleteJournalTemplate

public static void deleteJournalTemplate(long id)
                                  throws PortalException,
                                         SystemException
Deletes the journal template with the primary key from the database. Also notifies the appropriate model listeners.

Parameters:
id - the primary key of the journal template to delete
Throws:
PortalException - if a journal template with the primary key could not be found
SystemException - if a system exception occurred

deleteJournalTemplate

public static void deleteJournalTemplate(JournalTemplate journalTemplate)
                                  throws SystemException
Deletes the journal template from the database. Also notifies the appropriate model listeners.

Parameters:
journalTemplate - the journal template to delete
Throws:
SystemException - if a system exception occurred

dynamicQuery

public static List dynamicQuery(DynamicQuery dynamicQuery)
                         throws SystemException
Performs a dynamic query on the database and returns the matching rows.

Parameters:
dynamicQuery - the dynamic query to search with
Returns:
the matching rows
Throws:
SystemException - if a system exception occurred

dynamicQuery

public static List dynamicQuery(DynamicQuery dynamicQuery,
                                int start,
                                int end)
                         throws SystemException
Performs a dynamic query on the database and returns a range of the matching rows.

Useful when paginating results. Returns a maximum of end - start instances. start and end are not primary keys, they are indexes in the result set. Thus, 0 refers to the first result in the set. Setting both start and end to QueryUtil.ALL_POS will return the full result set.

Parameters:
dynamicQuery - the dynamic query to search with
start - the lower bound of the range of model instances to return
end - the upper bound of the range of model instances to return (not inclusive)
Returns:
the range of matching rows
Throws:
SystemException - if a system exception occurred

dynamicQuery

public static List dynamicQuery(DynamicQuery dynamicQuery,
                                int start,
                                int end,
                                OrderByComparator orderByComparator)
                         throws SystemException
Performs a dynamic query on the database and returns an ordered range of the matching rows.

Useful when paginating results. Returns a maximum of end - start instances. start and end are not primary keys, they are indexes in the result set. Thus, 0 refers to the first result in the set. Setting both start and end to QueryUtil.ALL_POS will return the full result set.

Parameters:
dynamicQuery - the dynamic query to search with
start - the lower bound of the range of model instances to return
end - the upper bound of the range of model instances to return (not inclusive)
orderByComparator - the comparator to order the results by
Returns:
the ordered range of matching rows
Throws:
SystemException - if a system exception occurred

dynamicQueryCount

public static long dynamicQueryCount(DynamicQuery dynamicQuery)
                              throws SystemException
Counts the number of rows that match the dynamic query.

Parameters:
dynamicQuery - the dynamic query to search with
Returns:
the number of rows that match the dynamic query
Throws:
SystemException - if a system exception occurred

getJournalTemplate

public static JournalTemplate getJournalTemplate(long id)
                                          throws PortalException,
                                                 SystemException
Gets the journal template with the primary key.

Parameters:
id - the primary key of the journal template to get
Returns:
the journal template
Throws:
PortalException - if a journal template with the primary key could not be found
SystemException - if a system exception occurred

getJournalTemplateByUuidAndGroupId

public static JournalTemplate getJournalTemplateByUuidAndGroupId(String uuid,
                                                                 long groupId)
                                                          throws PortalException,
                                                                 SystemException
Gets the journal template with the UUID and group id.

Parameters:
uuid - the UUID of journal template to get
groupId - the group id of the journal template to get
Returns:
the journal template
Throws:
PortalException - if a journal template with the UUID and group id could not be found
SystemException - if a system exception occurred

getJournalTemplates

public static List<JournalTemplate> getJournalTemplates(int start,
                                                        int end)
                                                 throws SystemException
Gets a range of all the journal templates.

Useful when paginating results. Returns a maximum of end - start instances. start and end are not primary keys, they are indexes in the result set. Thus, 0 refers to the first result in the set. Setting both start and end to QueryUtil.ALL_POS will return the full result set.

Parameters:
start - the lower bound of the range of journal templates to return
end - the upper bound of the range of journal templates to return (not inclusive)
Returns:
the range of journal templates
Throws:
SystemException - if a system exception occurred

getJournalTemplatesCount

public static int getJournalTemplatesCount()
                                    throws SystemException
Gets the number of journal templates.

Returns:
the number of journal templates
Throws:
SystemException - if a system exception occurred

updateJournalTemplate

public static JournalTemplate updateJournalTemplate(JournalTemplate journalTemplate)
                                             throws SystemException
Updates the journal template in the database. Also notifies the appropriate model listeners.

Parameters:
journalTemplate - the journal template to update
Returns:
the journal template that was updated
Throws:
SystemException - if a system exception occurred

updateJournalTemplate

public static JournalTemplate updateJournalTemplate(JournalTemplate journalTemplate,
                                                    boolean merge)
                                             throws SystemException
Updates the journal template in the database. Also notifies the appropriate model listeners.

Parameters:
journalTemplate - the journal template to update
merge - whether to merge the journal template with the current session. See BatchSession.update(com.liferay.portal.kernel.dao.orm.Session, com.liferay.portal.model.BaseModel, boolean) for an explanation.
Returns:
the journal template that was updated
Throws:
SystemException - if a system exception occurred

addTemplate

public static JournalTemplate addTemplate(long userId,
                                          long groupId,
                                          String templateId,
                                          boolean autoTemplateId,
                                          String structureId,
                                          String name,
                                          String description,
                                          String xsl,
                                          boolean formatXsl,
                                          String langType,
                                          boolean cacheable,
                                          boolean smallImage,
                                          String smallImageURL,
                                          File smallFile,
                                          ServiceContext serviceContext)
                                   throws PortalException,
                                          SystemException
Throws:
PortalException
SystemException

addTemplateResources

public static void addTemplateResources(long groupId,
                                        String templateId,
                                        boolean addCommunityPermissions,
                                        boolean addGuestPermissions)
                                 throws PortalException,
                                        SystemException
Throws:
PortalException
SystemException

addTemplateResources

public static void addTemplateResources(JournalTemplate template,
                                        boolean addCommunityPermissions,
                                        boolean addGuestPermissions)
                                 throws PortalException,
                                        SystemException
Throws:
PortalException
SystemException

addTemplateResources

public static void addTemplateResources(long groupId,
                                        String templateId,
                                        String[] communityPermissions,
                                        String[] guestPermissions)
                                 throws PortalException,
                                        SystemException
Throws:
PortalException
SystemException

addTemplateResources

public static void addTemplateResources(JournalTemplate template,
                                        String[] communityPermissions,
                                        String[] guestPermissions)
                                 throws PortalException,
                                        SystemException
Throws:
PortalException
SystemException

checkNewLine

public static void checkNewLine(long groupId,
                                String templateId)
                         throws PortalException,
                                SystemException
Throws:
PortalException
SystemException

copyTemplate

public static JournalTemplate copyTemplate(long userId,
                                           long groupId,
                                           String oldTemplateId,
                                           String newTemplateId,
                                           boolean autoTemplateId)
                                    throws PortalException,
                                           SystemException
Throws:
PortalException
SystemException

deleteTemplate

public static void deleteTemplate(long groupId,
                                  String templateId)
                           throws PortalException,
                                  SystemException
Throws:
PortalException
SystemException

deleteTemplate

public static void deleteTemplate(JournalTemplate template)
                           throws PortalException,
                                  SystemException
Throws:
PortalException
SystemException

deleteTemplates

public static void deleteTemplates(long groupId)
                            throws PortalException,
                                   SystemException
Throws:
PortalException
SystemException

getStructureTemplates

public static List<JournalTemplate> getStructureTemplates(long groupId,
                                                          String structureId)
                                                   throws SystemException
Throws:
SystemException

getStructureTemplates

public static List<JournalTemplate> getStructureTemplates(long groupId,
                                                          String structureId,
                                                          int start,
                                                          int end)
                                                   throws SystemException
Throws:
SystemException

getStructureTemplatesCount

public static int getStructureTemplatesCount(long groupId,
                                             String structureId)
                                      throws SystemException
Throws:
SystemException

getTemplate

public static JournalTemplate getTemplate(long id)
                                   throws PortalException,
                                          SystemException
Throws:
PortalException
SystemException

getTemplate

public static JournalTemplate getTemplate(long groupId,
                                          String templateId)
                                   throws PortalException,
                                          SystemException
Throws:
PortalException
SystemException

getTemplateBySmallImageId

public static JournalTemplate getTemplateBySmallImageId(long smallImageId)
                                                 throws PortalException,
                                                        SystemException
Throws:
PortalException
SystemException

getTemplates

public static List<JournalTemplate> getTemplates()
                                          throws SystemException
Throws:
SystemException

getTemplates

public static List<JournalTemplate> getTemplates(long groupId)
                                          throws SystemException
Throws:
SystemException

getTemplates

public static List<JournalTemplate> getTemplates(long groupId,
                                                 int start,
                                                 int end)
                                          throws SystemException
Throws:
SystemException

getTemplatesCount

public static int getTemplatesCount(long groupId)
                             throws SystemException
Throws:
SystemException

hasTemplate

public static boolean hasTemplate(long groupId,
                                  String templateId)
                           throws SystemException
Throws:
SystemException

search

public static List<JournalTemplate> search(long companyId,
                                           long groupId,
                                           String keywords,
                                           String structureId,
                                           String structureIdComparator,
                                           int start,
                                           int end,
                                           OrderByComparator obc)
                                    throws SystemException
Throws:
SystemException

search

public static List<JournalTemplate> search(long companyId,
                                           long groupId,
                                           String templateId,
                                           String structureId,
                                           String structureIdComparator,
                                           String name,
                                           String description,
                                           boolean andOperator,
                                           int start,
                                           int end,
                                           OrderByComparator obc)
                                    throws SystemException
Throws:
SystemException

searchCount

public static int searchCount(long companyId,
                              long groupId,
                              String keywords,
                              String structureId,
                              String structureIdComparator)
                       throws SystemException
Throws:
SystemException

searchCount

public static int searchCount(long companyId,
                              long groupId,
                              String templateId,
                              String structureId,
                              String structureIdComparator,
                              String name,
                              String description,
                              boolean andOperator)
                       throws SystemException
Throws:
SystemException

updateTemplate

public static JournalTemplate updateTemplate(long groupId,
                                             String templateId,
                                             String structureId,
                                             String name,
                                             String description,
                                             String xsl,
                                             boolean formatXsl,
                                             String langType,
                                             boolean cacheable,
                                             boolean smallImage,
                                             String smallImageURL,
                                             File smallFile,
                                             ServiceContext serviceContext)
                                      throws PortalException,
                                             SystemException
Throws:
PortalException
SystemException

getService

public static JournalTemplateLocalService getService()

setService

public void setService(JournalTemplateLocalService service)

Liferay 6.0.5