Class LayoutSetLocalServiceUtil
com.liferay.portal.service.impl.LayoutSetLocalServiceImpl 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 Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic LayoutSetaddLayoutSet(long groupId, boolean privateLayout) static LayoutSetaddLayoutSet(LayoutSet layoutSet) Adds the layout set to the database.static LayoutSetcreateLayoutSet(long layoutSetId) Creates a new layout set with the primary key.static PersistedModelcreatePersistedModel(Serializable primaryKeyObj) static LayoutSetdeleteLayoutSet(long layoutSetId) Deletes the layout set with the primary key from the database.static voiddeleteLayoutSet(long groupId, boolean privateLayout, ServiceContext serviceContext) static LayoutSetdeleteLayoutSet(LayoutSet layoutSet) Deletes the layout set from the database.static PersistedModeldeletePersistedModel(PersistedModel persistedModel) static <T> TdslQuery(com.liferay.petra.sql.dsl.query.DSLQuery dslQuery) static intdslQueryCount(com.liferay.petra.sql.dsl.query.DSLQuery dslQuery) static DynamicQuerystatic <T> List<T>dynamicQuery(DynamicQuery dynamicQuery) Performs a dynamic query on the database and returns the matching rows.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.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.static longdynamicQueryCount(DynamicQuery dynamicQuery) Returns the number of rows matching the dynamic query.static longdynamicQueryCount(DynamicQuery dynamicQuery, Projection projection) Returns the number of rows matching the dynamic query.static LayoutSetfetchLayoutSet(long layoutSetId) static LayoutSetfetchLayoutSet(long groupId, boolean privateLayout) static LayoutSetfetchLayoutSet(String virtualHostname) static LayoutSetfetchLayoutSetByLogoId(boolean privateLayout, long logoId) static ActionableDynamicQuerystatic LayoutSetgetLayoutSet(long layoutSetId) Returns the layout set with the primary key.static LayoutSetgetLayoutSet(long groupId, boolean privateLayout) static LayoutSetgetLayoutSet(String virtualHostname) getLayoutSets(int start, int end) Returns a range of all the layout sets.getLayoutSetsByLayoutSetPrototypeUuid(String layoutSetPrototypeUuid) static intReturns the number of layout sets.static StringReturns the OSGi service identifier.static intgetPageCount(long groupId, boolean privateLayout) static PersistedModelgetPersistedModel(Serializable primaryKeyObj) static LayoutSetLocalServicestatic voidsetService(LayoutSetLocalService service) static LayoutSetupdateFaviconFileEntryId(long groupId, boolean privateLayout, long faviconFileEntryId) static LayoutSetupdateLayoutSet(LayoutSet layoutSet) Updates the layout set in the database or adds it if it does not yet exist.static voidupdateLayoutSetPrototypeLinkEnabled(long groupId, boolean privateLayout, boolean layoutSetPrototypeLinkEnabled, String layoutSetPrototypeUuid) Updates the state of the layout set prototype link.static LayoutSetupdateLogo(long groupId, boolean privateLayout, boolean hasLogo, byte[] bytes) static LayoutSetupdateLogo(long groupId, boolean privateLayout, boolean hasLogo, File file) static LayoutSetupdateLogo(long groupId, boolean privateLayout, boolean hasLogo, InputStream inputStream) static LayoutSetupdateLogo(long groupId, boolean privateLayout, boolean hasLogo, InputStream inputStream, boolean cleanUpStream) static LayoutSetupdateLookAndFeel(long groupId, boolean privateLayout, String themeId, String colorSchemeId, String css) static voidupdateLookAndFeel(long groupId, String themeId, String colorSchemeId, String css) static LayoutSetupdateSettings(long groupId, boolean privateLayout, String settings) static LayoutSetupdateVirtualHosts(long groupId, boolean privateLayout, TreeMap<String, String> virtualHostnames)
-
Constructor Details
-
LayoutSetLocalServiceUtil
public LayoutSetLocalServiceUtil()
-
-
Method Details
-
addLayoutSet
Adds the layout set to the database. Also notifies the appropriate model listeners.Important: Inspect LayoutSetLocalServiceImpl 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:
layoutSet- the layout set- Returns:
- the layout set that was added
-
addLayoutSet
- Throws:
PortalException
-
createLayoutSet
Creates a new layout set with the primary key. Does not add the layout set to the database.- Parameters:
layoutSetId- the primary key for the new layout set- Returns:
- the new layout set
-
createPersistedModel
public static PersistedModel createPersistedModel(Serializable primaryKeyObj) throws PortalException - Throws:
PortalException
-
deleteLayoutSet
Deletes the layout set from the database. Also notifies the appropriate model listeners.Important: Inspect LayoutSetLocalServiceImpl 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:
layoutSet- the layout set- Returns:
- the layout set that was removed
-
deleteLayoutSet
Deletes the layout set with the primary key from the database. Also notifies the appropriate model listeners.Important: Inspect LayoutSetLocalServiceImpl 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:
layoutSetId- the primary key of the layout set- Returns:
- the layout set that was removed
- Throws:
PortalException- if a layout set with the primary key could not be found
-
deleteLayoutSet
public static void deleteLayoutSet(long groupId, boolean privateLayout, ServiceContext serviceContext) throws PortalException - Throws:
PortalException
-
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
-
dynamicQuery
Performs a dynamic query on the database and returns the matching rows.- Parameters:
dynamicQuery- the dynamic query- Returns:
- the matching rows
-
dynamicQuery
Performs a dynamic query on the database and returns a range of the matching rows.Useful when paginating results. Returns a maximum of
end - startinstances.startandendare not primary keys, they are indexes in the result set. Thus,0refers to the first result in the set. Setting bothstartandendtocom.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POSwill return the full result set. IforderByComparatoris specified, then the query will include the given ORDER BY logic. IforderByComparatoris absent, then the query will include the default ORDER BY logic fromcom.liferay.portal.model.impl.LayoutSetModelImpl.- Parameters:
dynamicQuery- the dynamic querystart- the lower bound of the range of model instancesend- 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 - startinstances.startandendare not primary keys, they are indexes in the result set. Thus,0refers to the first result in the set. Setting bothstartandendtocom.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POSwill return the full result set. IforderByComparatoris specified, then the query will include the given ORDER BY logic. IforderByComparatoris absent, then the query will include the default ORDER BY logic fromcom.liferay.portal.model.impl.LayoutSetModelImpl.- Parameters:
dynamicQuery- the dynamic querystart- the lower bound of the range of model instancesend- the upper bound of the range of model instances (not inclusive)orderByComparator- the comparator to order the results by (optionallynull)- Returns:
- the ordered range of matching rows
-
dynamicQueryCount
Returns the number of rows matching the dynamic query.- Parameters:
dynamicQuery- the dynamic query- Returns:
- the number of rows matching the dynamic query
-
dynamicQueryCount
Returns the number of rows matching the dynamic query.- Parameters:
dynamicQuery- the dynamic queryprojection- the projection to apply to the query- Returns:
- the number of rows matching the dynamic query
-
fetchLayoutSet
-
fetchLayoutSet
-
fetchLayoutSet
-
fetchLayoutSetByLogoId
public static LayoutSet fetchLayoutSetByLogoId(boolean privateLayout, long logoId) throws PortalException - Throws:
PortalException
-
getActionableDynamicQuery
-
getIndexableActionableDynamicQuery
-
getLayoutSet
Returns the layout set with the primary key.- Parameters:
layoutSetId- the primary key of the layout set- Returns:
- the layout set
- Throws:
PortalException- if a layout set with the primary key could not be found
-
getLayoutSet
- Throws:
PortalException
-
getLayoutSet
- Throws:
PortalException
-
getLayoutSets
Returns a range of all the layout sets.Useful when paginating results. Returns a maximum of
end - startinstances.startandendare not primary keys, they are indexes in the result set. Thus,0refers to the first result in the set. Setting bothstartandendtocom.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POSwill return the full result set. IforderByComparatoris specified, then the query will include the given ORDER BY logic. IforderByComparatoris absent, then the query will include the default ORDER BY logic fromcom.liferay.portal.model.impl.LayoutSetModelImpl.- Parameters:
start- the lower bound of the range of layout setsend- the upper bound of the range of layout sets (not inclusive)- Returns:
- the range of layout sets
-
getLayoutSetsByLayoutSetPrototypeUuid
-
getLayoutSetsCount
public static int getLayoutSetsCount()Returns the number of layout sets.- Returns:
- the number of layout sets
-
getOSGiServiceIdentifier
Returns the OSGi service identifier.- Returns:
- the OSGi service identifier
-
getPageCount
public static int getPageCount(long groupId, boolean privateLayout) -
getPersistedModel
- Throws:
PortalException
-
updateFaviconFileEntryId
public static LayoutSet updateFaviconFileEntryId(long groupId, boolean privateLayout, long faviconFileEntryId) throws PortalException - Throws:
PortalException
-
updateLayoutSet
Updates the layout set in the database or adds it if it does not yet exist. Also notifies the appropriate model listeners.Important: Inspect LayoutSetLocalServiceImpl 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:
layoutSet- the layout set- Returns:
- the layout set that was updated
-
updateLayoutSetPrototypeLinkEnabled
public static void updateLayoutSetPrototypeLinkEnabled(long groupId, boolean privateLayout, boolean layoutSetPrototypeLinkEnabled, String layoutSetPrototypeUuid) throws PortalException Updates the state of the layout set prototype link.- Parameters:
groupId- the primary key of the groupprivateLayout- whether the layout set is private to the grouplayoutSetPrototypeLinkEnabled- whether the layout set prototype is link enabledlayoutSetPrototypeUuid- the uuid of the layout set prototype to link with- Throws:
PortalException
-
updateLogo
public static LayoutSet updateLogo(long groupId, boolean privateLayout, boolean hasLogo, byte[] bytes) throws PortalException - Throws:
PortalException
-
updateLogo
public static LayoutSet updateLogo(long groupId, boolean privateLayout, boolean hasLogo, File file) throws PortalException - Throws:
PortalException
-
updateLogo
public static LayoutSet updateLogo(long groupId, boolean privateLayout, boolean hasLogo, InputStream inputStream) throws PortalException - Throws:
PortalException
-
updateLogo
public static LayoutSet updateLogo(long groupId, boolean privateLayout, boolean hasLogo, InputStream inputStream, boolean cleanUpStream) throws PortalException - Throws:
PortalException
-
updateLookAndFeel
public static LayoutSet updateLookAndFeel(long groupId, boolean privateLayout, String themeId, String colorSchemeId, String css) throws PortalException - Throws:
PortalException
-
updateLookAndFeel
public static void updateLookAndFeel(long groupId, String themeId, String colorSchemeId, String css) throws PortalException - Throws:
PortalException
-
updateSettings
public static LayoutSet updateSettings(long groupId, boolean privateLayout, String settings) throws PortalException - Throws:
PortalException
-
updateVirtualHosts
public static LayoutSet updateVirtualHosts(long groupId, boolean privateLayout, TreeMap<String, String> virtualHostnames) throws PortalException- Throws:
PortalException
-
getService
-
setService
-