Class LayoutFriendlyURLLocalServiceUtil

Object
com.liferay.portal.kernel.service.LayoutFriendlyURLLocalServiceUtil

public class LayoutFriendlyURLLocalServiceUtil extends Object
Provides the local service utility for LayoutFriendlyURL. This utility wraps com.liferay.portal.service.impl.LayoutFriendlyURLLocalServiceImpl and is an access point for service operations in application layer code running on the local server. 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.
Author:
Brian Wing Shun Chan
See Also:
{$generated.description}
  • Constructor Details

    • LayoutFriendlyURLLocalServiceUtil

      public LayoutFriendlyURLLocalServiceUtil()
  • Method Details

    • addLayoutFriendlyURL

      public static LayoutFriendlyURL addLayoutFriendlyURL(LayoutFriendlyURL layoutFriendlyURL)
      Adds the layout friendly url to the database. Also notifies the appropriate model listeners.

      Important: Inspect LayoutFriendlyURLLocalServiceImpl for overloaded versions of the method. If provided, use these entry points to the API, as the implementation logic may require the additional parameters defined there.

      Parameters:
      layoutFriendlyURL - the layout friendly url
      Returns:
      the layout friendly url that was added
    • addLayoutFriendlyURL

      public static LayoutFriendlyURL addLayoutFriendlyURL(long userId, long companyId, long groupId, long plid, boolean privateLayout, String friendlyURL, String languageId, ServiceContext serviceContext) throws PortalException
      Throws:
      PortalException
    • addLayoutFriendlyURLs

      public static List<LayoutFriendlyURL> addLayoutFriendlyURLs(long userId, long companyId, long groupId, long plid, boolean privateLayout, Map<Locale,String> friendlyURLMap, ServiceContext serviceContext) throws PortalException
      Throws:
      PortalException
    • createLayoutFriendlyURL

      public static LayoutFriendlyURL createLayoutFriendlyURL(long layoutFriendlyURLId)
      Creates a new layout friendly url with the primary key. Does not add the layout friendly url to the database.
      Parameters:
      layoutFriendlyURLId - the primary key for the new layout friendly url
      Returns:
      the new layout friendly url
    • createPersistedModel

      public static PersistedModel createPersistedModel(Serializable primaryKeyObj) throws PortalException
      Throws:
      PortalException
    • deleteLayoutFriendlyURL

      public static LayoutFriendlyURL deleteLayoutFriendlyURL(LayoutFriendlyURL layoutFriendlyURL)
      Deletes the layout friendly url from the database. Also notifies the appropriate model listeners.

      Important: Inspect LayoutFriendlyURLLocalServiceImpl for overloaded versions of the method. If provided, use these entry points to the API, as the implementation logic may require the additional parameters defined there.

      Parameters:
      layoutFriendlyURL - the layout friendly url
      Returns:
      the layout friendly url that was removed
    • deleteLayoutFriendlyURL

      public static LayoutFriendlyURL deleteLayoutFriendlyURL(long layoutFriendlyURLId) throws PortalException
      Deletes the layout friendly url with the primary key from the database. Also notifies the appropriate model listeners.

      Important: Inspect LayoutFriendlyURLLocalServiceImpl for overloaded versions of the method. If provided, use these entry points to the API, as the implementation logic may require the additional parameters defined there.

      Parameters:
      layoutFriendlyURLId - the primary key of the layout friendly url
      Returns:
      the layout friendly url that was removed
      Throws:
      PortalException - if a layout friendly url with the primary key could not be found
    • deleteLayoutFriendlyURL

      public static void deleteLayoutFriendlyURL(long plid, String languageId)
    • deleteLayoutFriendlyURLs

      public static void deleteLayoutFriendlyURLs(long plid)
    • deletePersistedModel

      public static PersistedModel deletePersistedModel(PersistedModel persistedModel) throws PortalException
      Throws:
      PortalException
    • dslQuery

      public static <T> T dslQuery(com.liferay.petra.sql.dsl.query.DSLQuery dslQuery)
    • dslQueryCount

      public static int dslQueryCount(com.liferay.petra.sql.dsl.query.DSLQuery dslQuery)
    • dynamicQuery

      public static DynamicQuery dynamicQuery()
    • dynamicQuery

      public static <T> List<T> dynamicQuery(DynamicQuery dynamicQuery)
      Performs a dynamic query on the database and returns the matching rows.
      Parameters:
      dynamicQuery - the dynamic query
      Returns:
      the matching rows
    • dynamicQuery

      public static <T> List<T> dynamicQuery(DynamicQuery dynamicQuery, int start, int end)
      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 com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS will return the full result set. If orderByComparator is specified, then the query will include the given ORDER BY logic. If orderByComparator is absent, then the query will include the default ORDER BY logic from com.liferay.portal.model.impl.LayoutFriendlyURLModelImpl.

      Parameters:
      dynamicQuery - the dynamic query
      start - the lower bound of the range of model instances
      end - the upper bound of the range of model instances (not inclusive)
      Returns:
      the range of matching rows
    • dynamicQuery

      public static <T> List<T> dynamicQuery(DynamicQuery dynamicQuery, int start, int end, OrderByComparator<T> orderByComparator)
      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 com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS will return the full result set. If orderByComparator is specified, then the query will include the given ORDER BY logic. If orderByComparator is absent, then the query will include the default ORDER BY logic from com.liferay.portal.model.impl.LayoutFriendlyURLModelImpl.

      Parameters:
      dynamicQuery - the dynamic query
      start - the lower bound of the range of model instances
      end - the upper bound of the range of model instances (not inclusive)
      orderByComparator - the comparator to order the results by (optionally null)
      Returns:
      the ordered range of matching rows
    • dynamicQueryCount

      public static long dynamicQueryCount(DynamicQuery dynamicQuery)
      Returns the number of rows matching the dynamic query.
      Parameters:
      dynamicQuery - the dynamic query
      Returns:
      the number of rows matching the dynamic query
    • dynamicQueryCount

      public static long dynamicQueryCount(DynamicQuery dynamicQuery, Projection projection)
      Returns the number of rows matching the dynamic query.
      Parameters:
      dynamicQuery - the dynamic query
      projection - the projection to apply to the query
      Returns:
      the number of rows matching the dynamic query
    • fetchFirstLayoutFriendlyURL

      public static LayoutFriendlyURL fetchFirstLayoutFriendlyURL(long groupId, boolean privateLayout, String friendlyURL)
    • fetchLayoutFriendlyURL

      public static LayoutFriendlyURL fetchLayoutFriendlyURL(long layoutFriendlyURLId)
    • fetchLayoutFriendlyURL

      public static LayoutFriendlyURL fetchLayoutFriendlyURL(long groupId, boolean privateLayout, String friendlyURL, String languageId)
    • fetchLayoutFriendlyURL

      public static LayoutFriendlyURL fetchLayoutFriendlyURL(long plid, String languageId)
    • fetchLayoutFriendlyURL

      public static LayoutFriendlyURL fetchLayoutFriendlyURL(long plid, String languageId, boolean useDefault)
    • fetchLayoutFriendlyURLByUuidAndGroupId

      public static LayoutFriendlyURL fetchLayoutFriendlyURLByUuidAndGroupId(String uuid, long groupId)
      Returns the layout friendly url matching the UUID and group.
      Parameters:
      uuid - the layout friendly url's UUID
      groupId - the primary key of the group
      Returns:
      the matching layout friendly url, or null if a matching layout friendly url could not be found
    • getActionableDynamicQuery

      public static ActionableDynamicQuery getActionableDynamicQuery()
    • getExportActionableDynamicQuery

      public static ExportActionableDynamicQuery getExportActionableDynamicQuery(PortletDataContext portletDataContext)
    • getIndexableActionableDynamicQuery

      public static IndexableActionableDynamicQuery getIndexableActionableDynamicQuery()
    • getLayoutFriendlyURL

      public static LayoutFriendlyURL getLayoutFriendlyURL(long layoutFriendlyURLId) throws PortalException
      Returns the layout friendly url with the primary key.
      Parameters:
      layoutFriendlyURLId - the primary key of the layout friendly url
      Returns:
      the layout friendly url
      Throws:
      PortalException - if a layout friendly url with the primary key could not be found
    • getLayoutFriendlyURL

      public static LayoutFriendlyURL getLayoutFriendlyURL(long groupId, boolean privateLayout, String friendlyURL, String languageId) throws NoSuchLayoutFriendlyURLException
      Throws:
      NoSuchLayoutFriendlyURLException
    • getLayoutFriendlyURL

      public static LayoutFriendlyURL getLayoutFriendlyURL(long plid, String languageId) throws PortalException
      Throws:
      PortalException
    • getLayoutFriendlyURL

      public static LayoutFriendlyURL getLayoutFriendlyURL(long plid, String languageId, boolean useDefault) throws PortalException
      Throws:
      PortalException
    • getLayoutFriendlyURLByUuidAndGroupId

      public static LayoutFriendlyURL getLayoutFriendlyURLByUuidAndGroupId(String uuid, long groupId) throws PortalException
      Returns the layout friendly url matching the UUID and group.
      Parameters:
      uuid - the layout friendly url's UUID
      groupId - the primary key of the group
      Returns:
      the matching layout friendly url
      Throws:
      PortalException - if a matching layout friendly url could not be found
    • getLayoutFriendlyURLs

      public static Map<Long,String> getLayoutFriendlyURLs(Group siteGroup, List<Layout> layouts, String languageId)
    • getLayoutFriendlyURLs

      public static List<LayoutFriendlyURL> getLayoutFriendlyURLs(int start, int end)
      Returns a range of all the layout friendly urls.

      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 com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS will return the full result set. If orderByComparator is specified, then the query will include the given ORDER BY logic. If orderByComparator is absent, then the query will include the default ORDER BY logic from com.liferay.portal.model.impl.LayoutFriendlyURLModelImpl.

      Parameters:
      start - the lower bound of the range of layout friendly urls
      end - the upper bound of the range of layout friendly urls (not inclusive)
      Returns:
      the range of layout friendly urls
    • getLayoutFriendlyURLs

      public static List<LayoutFriendlyURL> getLayoutFriendlyURLs(long plid)
    • getLayoutFriendlyURLs

      public static List<LayoutFriendlyURL> getLayoutFriendlyURLs(long plid, String friendlyURL, int start, int end)
    • getLayoutFriendlyURLsByUuidAndCompanyId

      public static List<LayoutFriendlyURL> getLayoutFriendlyURLsByUuidAndCompanyId(String uuid, long companyId)
      Returns all the layout friendly urls matching the UUID and company.
      Parameters:
      uuid - the UUID of the layout friendly urls
      companyId - the primary key of the company
      Returns:
      the matching layout friendly urls, or an empty list if no matches were found
    • getLayoutFriendlyURLsByUuidAndCompanyId

      public static List<LayoutFriendlyURL> getLayoutFriendlyURLsByUuidAndCompanyId(String uuid, long companyId, int start, int end, OrderByComparator<LayoutFriendlyURL> orderByComparator)
      Returns a range of layout friendly urls matching the UUID and company.
      Parameters:
      uuid - the UUID of the layout friendly urls
      companyId - the primary key of the company
      start - the lower bound of the range of layout friendly urls
      end - the upper bound of the range of layout friendly urls (not inclusive)
      orderByComparator - the comparator to order the results by (optionally null)
      Returns:
      the range of matching layout friendly urls, or an empty list if no matches were found
    • getLayoutFriendlyURLsCount

      public static int getLayoutFriendlyURLsCount()
      Returns the number of layout friendly urls.
      Returns:
      the number of layout friendly urls
    • getLayoutFriendlyURLsCount

      public static int getLayoutFriendlyURLsCount(long companyId, String friendlyURL)
    • getOSGiServiceIdentifier

      public static String getOSGiServiceIdentifier()
      Returns the OSGi service identifier.
      Returns:
      the OSGi service identifier
    • getPersistedModel

      public static PersistedModel getPersistedModel(Serializable primaryKeyObj) throws PortalException
      Throws:
      PortalException
    • updateLayoutFriendlyURL

      public static LayoutFriendlyURL updateLayoutFriendlyURL(LayoutFriendlyURL layoutFriendlyURL)
      Updates the layout friendly url in the database or adds it if it does not yet exist. Also notifies the appropriate model listeners.

      Important: Inspect LayoutFriendlyURLLocalServiceImpl for overloaded versions of the method. If provided, use these entry points to the API, as the implementation logic may require the additional parameters defined there.

      Parameters:
      layoutFriendlyURL - the layout friendly url
      Returns:
      the layout friendly url that was updated
    • updateLayoutFriendlyURL

      public static LayoutFriendlyURL updateLayoutFriendlyURL(long userId, long companyId, long groupId, long plid, boolean privateLayout, String friendlyURL, String languageId, ServiceContext serviceContext) throws PortalException
      Throws:
      PortalException
    • updateLayoutFriendlyURLs

      public static List<LayoutFriendlyURL> updateLayoutFriendlyURLs(long userId, long companyId, long groupId, long plid, boolean privateLayout, Map<Locale,String> friendlyURLMap, ServiceContext serviceContext) throws PortalException
      Throws:
      PortalException
    • getService

      public static LayoutFriendlyURLLocalService getService()
    • setService

      public static void setService(LayoutFriendlyURLLocalService service)