|
Liferay 6.1.2-ce-ga3 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.liferay.portal.service.http.LayoutServiceSoap
public class LayoutServiceSoap
This class provides a SOAP utility for the
LayoutServiceUtil
service utility. The
static methods of this class calls the same methods of the service utility.
However, the signatures are different because it is difficult for SOAP to
support certain types.
ServiceBuilder follows certain rules in translating the methods. For example,
if the method in the service utility returns a List
, that
is translated to an array of LayoutSoap
.
If the method in the service utility returns a
Layout
, that is translated to a
LayoutSoap
. Methods that SOAP cannot
safely wire are skipped.
The benefits of using the SOAP utility is that it is cross platform compatible. SOAP allows different languages like Java, .NET, C++, PHP, and even Perl, to call the generated services. One drawback of SOAP is that it is slow because it needs to serialize all calls into a text format (XML).
You can see a list of services at http://localhost:8080/api/secure/axis. Set the property axis.servlet.hosts.allowed in portal.properties to configure security.
The SOAP utility is only generated for remote services.
LayoutServiceHttp
,
LayoutSoap
,
LayoutServiceUtil
Constructor Summary | |
---|---|
LayoutServiceSoap()
|
Method Summary | |
---|---|
static LayoutSoap |
addLayout(long groupId,
boolean privateLayout,
long parentLayoutId,
String[] localeNamesMapLanguageIds,
String[] localeNamesMapValues,
String[] localeTitlesMapLanguageIds,
String[] localeTitlesMapValues,
String[] descriptionMapLanguageIds,
String[] descriptionMapValues,
String[] keywordsMapLanguageIds,
String[] keywordsMapValues,
String[] robotsMapLanguageIds,
String[] robotsMapValues,
String type,
boolean hidden,
String friendlyURL,
ServiceContext serviceContext)
Adds a layout with additional parameters. |
static LayoutSoap |
addLayout(long groupId,
boolean privateLayout,
long parentLayoutId,
String name,
String title,
String description,
String type,
boolean hidden,
String friendlyURL,
ServiceContext serviceContext)
This method handles the creation of the layout including its resources, metadata, and internal data structures. |
static void |
deleteLayout(long groupId,
boolean privateLayout,
long layoutId,
ServiceContext serviceContext)
Deletes the layout with the primary key, also deleting the layout's child layouts, and associated resources. |
static void |
deleteLayout(long plid,
ServiceContext serviceContext)
Deletes the layout with the plid, also deleting the layout's child layouts, and associated resources. |
static LayoutSoap[] |
getAncestorLayouts(long plid)
Returns all the ancestor layouts of the layout. |
static long |
getDefaultPlid(long groupId,
long scopeGroupId,
boolean privateLayout,
String portletId)
Returns the primary key of the default layout for the group. |
static long |
getDefaultPlid(long groupId,
long scopeGroupId,
String portletId)
|
static LayoutSoap |
getLayoutByUuidAndGroupId(String uuid,
long groupId,
boolean privateLayout)
|
static String |
getLayoutName(long groupId,
boolean privateLayout,
long layoutId,
String languageId)
Returns the name of the layout. |
static LayoutReference[] |
getLayoutReferences(long companyId,
String portletId,
String preferencesKey,
String preferencesValue)
Returns the layout references for all the layouts that belong to the company and belong to the portlet that matches the preferences. |
static LayoutSoap[] |
getLayouts(long groupId,
boolean privateLayout)
|
static LayoutSoap[] |
getLayouts(long groupId,
boolean privateLayout,
long parentLayoutId)
|
static LayoutSoap[] |
getLayouts(long groupId,
boolean privateLayout,
long parentLayoutId,
boolean incomplete,
int start,
int end)
|
static void |
setLayouts(long groupId,
boolean privateLayout,
long parentLayoutId,
long[] layoutIds,
ServiceContext serviceContext)
Sets the layouts for the group, replacing and prioritizing all layouts of the parent layout. |
static void |
unschedulePublishToLive(long groupId,
String jobName,
String groupName)
Deletes the job from the scheduler's queue. |
static void |
unschedulePublishToRemote(long groupId,
String jobName,
String groupName)
Deletes the job from the scheduler's persistent queue. |
static LayoutSoap |
updateLayout(long groupId,
boolean privateLayout,
long layoutId,
long parentLayoutId,
String[] localeNamesMapLanguageIds,
String[] localeNamesMapValues,
String[] localeTitlesMapLanguageIds,
String[] localeTitlesMapValues,
String[] descriptionMapLanguageIds,
String[] descriptionMapValues,
String[] keywordsMapLanguageIds,
String[] keywordsMapValues,
String[] robotsMapLanguageIds,
String[] robotsMapValues,
String type,
boolean hidden,
String friendlyURL,
Boolean iconImage,
byte[] iconBytes,
ServiceContext serviceContext)
Updates the layout. |
static LayoutSoap |
updateLayout(long groupId,
boolean privateLayout,
long layoutId,
String typeSettings)
Updates the layout replacing its type settings. |
static LayoutSoap |
updateLookAndFeel(long groupId,
boolean privateLayout,
long layoutId,
String themeId,
String colorSchemeId,
String css,
boolean wapTheme)
Updates the look and feel of the layout. |
static LayoutSoap |
updateName(long groupId,
boolean privateLayout,
long layoutId,
String name,
String languageId)
Updates the name of the layout matching the group, layout ID, and privacy. |
static LayoutSoap |
updateName(long plid,
String name,
String languageId)
Updates the name of the layout matching the primary key. |
static LayoutSoap |
updateParentLayoutId(long groupId,
boolean privateLayout,
long layoutId,
long parentLayoutId)
Updates the parent layout ID of the layout matching the group, layout ID, and privacy. |
static LayoutSoap |
updateParentLayoutId(long plid,
long parentPlid)
Updates the parent layout ID of the layout matching the primary key. |
static LayoutSoap |
updatePriority(long groupId,
boolean privateLayout,
long layoutId,
int priority)
Updates the priority of the layout matching the group, layout ID, and privacy. |
static LayoutSoap |
updatePriority(long plid,
int priority)
Updates the priority of the layout matching the primary key. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public LayoutServiceSoap()
Method Detail |
---|
public static LayoutSoap addLayout(long groupId, boolean privateLayout, long parentLayoutId, String[] localeNamesMapLanguageIds, String[] localeNamesMapValues, String[] localeTitlesMapLanguageIds, String[] localeTitlesMapValues, String[] descriptionMapLanguageIds, String[] descriptionMapValues, String[] keywordsMapLanguageIds, String[] keywordsMapValues, String[] robotsMapLanguageIds, String[] robotsMapValues, String type, boolean hidden, String friendlyURL, ServiceContext serviceContext) throws RemoteException
This method handles the creation of the layout including its resources, metadata, and internal data structures. It is not necessary to make subsequent calls to any methods to setup default groups, resources, ... etc.
groupId
- the primary key of the groupprivateLayout
- whether the layout is private to the groupparentLayoutId
- the primary key of the parent layout (optionally
LayoutConstants.DEFAULT_PARENT_LAYOUT_ID
)localeNamesMap
- the layout's locales and localized nameslocaleTitlesMap
- the layout's locales and localized titlesdescriptionMap
- the layout's locales and localized descriptionskeywordsMap
- the layout's locales and localized keywordsrobotsMap
- the layout's locales and localized robotstype
- the layout's type (optionally LayoutConstants.TYPE_PORTLET
). The
possible types can be found in LayoutConstants
.hidden
- whether the layout is hiddenfriendlyURL
- the layout's friendly URL (optionally PropsValues.DEFAULT_USER_PRIVATE_LAYOUT_FRIENDLY_URL
or PropsValues.DEFAULT_USER_PUBLIC_LAYOUT_FRIENDLY_URL
).
The default values can be overridden in
portal-ext.properties
by specifying new values for
the corresponding properties defined in PropsValues
. To see how the URL is
normalized when accessed see FriendlyURLNormalizerUtil.normalize(
String)
.serviceContext
- the service context. Must set the universally
unique identifier (UUID) for the layout. Can set the creation
date, modification date and the expando bridge attributes for the
layout. For layouts that belong to a layout set prototype, an
attribute named 'layoutUpdateable' can be used to specify whether
site administrators can modify this page within their site.
PortalException
- if a group with the primary key could not be
found, if the group did not have permission to manage the layouts
involved, or if layout values were invalid
SystemException
- if a system exception occurred
RemoteException
public static LayoutSoap addLayout(long groupId, boolean privateLayout, long parentLayoutId, String name, String title, String description, String type, boolean hidden, String friendlyURL, ServiceContext serviceContext) throws RemoteException
This method handles the creation of the layout including its resources, metadata, and internal data structures. It is not necessary to make subsequent calls to any methods to setup default groups, resources, ... etc.
groupId
- the primary key of the groupprivateLayout
- whether the layout is private to the groupparentLayoutId
- the primary key of the parent layout (optionally
LayoutConstants.DEFAULT_PARENT_LAYOUT_ID
)name
- Map the layout's locales and localized namestitle
- Map the layout's locales and localized titlesdescription
- Map the layout's locales and localized descriptionstype
- the layout's type (optionally LayoutConstants.TYPE_PORTLET
). The
possible types can be found in LayoutConstants
.hidden
- whether the layout is hiddenfriendlyURL
- the layout's friendly URL (optionally PropsValues.DEFAULT_USER_PRIVATE_LAYOUT_FRIENDLY_URL
or PropsValues.DEFAULT_USER_PUBLIC_LAYOUT_FRIENDLY_URL
).
The default values can be overridden in
portal-ext.properties
by specifying new values for
the corresponding properties defined in PropsValues
. To see how the URL is
normalized when accessed see FriendlyURLNormalizerUtil.normalize(
String)
.serviceContext
- the service context. Must set the universally
unique identifier (UUID) for the layout. Can specify the creation
date, modification date and the expando bridge attributes for the
layout. For layouts that belong to a layout set prototype, an
attribute named 'layoutUpdateable' can be used to specify whether
site administrators can modify this page within their site.
PortalException
- if a group with the primary key could not be
found, if the group did not have permission to manage the layouts
involved, or if layout values were invalid
SystemException
- if a system exception occurred
RemoteException
public static void deleteLayout(long groupId, boolean privateLayout, long layoutId, ServiceContext serviceContext) throws RemoteException
groupId
- the primary key of the groupprivateLayout
- whether the layout is private to the grouplayoutId
- the primary key of the layoutserviceContext
- the service context
PortalException
- if the user did not have permission to delete the
layout, if a matching layout could not be found , or if some
other portal exception occurred
SystemException
- if a system exception occurred
RemoteException
public static void deleteLayout(long plid, ServiceContext serviceContext) throws RemoteException
plid
- the primary key of the layoutserviceContext
- the service context
PortalException
- if the user did not have permission to delete the
layout, if a layout with the primary key could not be found , or
if some other portal exception occurred
SystemException
- if a system exception occurred
RemoteException
public static LayoutSoap[] getAncestorLayouts(long plid) throws RemoteException
plid
- the primary key of the layout
PortalException
- if a matching layout could not be found or if a
portal exception occurred
SystemException
- if a system exception occurred
RemoteException
public static long getDefaultPlid(long groupId, long scopeGroupId, boolean privateLayout, String portletId) throws RemoteException
groupId
- the primary key of the groupscopeGroupId
- the primary key of the scope group. See ServiceContext#getScopeGroupId()
.privateLayout
- whether the layout is private to the groupportletId
- the primary key of the portlet
LayoutConstants.DEFAULT_PLID
otherwise
PortalException
- if a group, layout, or portlet with the primary
key could not be found
SystemException
- if a system exception occurred
RemoteException
public static long getDefaultPlid(long groupId, long scopeGroupId, String portletId) throws RemoteException
RemoteException
public static LayoutSoap getLayoutByUuidAndGroupId(String uuid, long groupId, boolean privateLayout) throws RemoteException
RemoteException
public static String getLayoutName(long groupId, boolean privateLayout, long layoutId, String languageId) throws RemoteException
groupId
- the primary key of the groupprivateLayout
- whether the layout is private to the grouplayoutId
- the primary key of the layoutlanguageId
- the primary key of the language. For more information
See Locale
.
PortalException
- if a matching layout could not be found
SystemException
- if a system exception occurred
RemoteException
public static LayoutReference[] getLayoutReferences(long companyId, String portletId, String preferencesKey, String preferencesValue) throws RemoteException
companyId
- the primary key of the companyportletId
- the primary key of the portletpreferencesKey
- the portlet's preference keypreferencesValue
- the portlet's preference value
SystemException
- if a system exception occurred
RemoteException
public static LayoutSoap[] getLayouts(long groupId, boolean privateLayout) throws RemoteException
RemoteException
public static LayoutSoap[] getLayouts(long groupId, boolean privateLayout, long parentLayoutId) throws RemoteException
RemoteException
public static LayoutSoap[] getLayouts(long groupId, boolean privateLayout, long parentLayoutId, boolean incomplete, int start, int end) throws RemoteException
RemoteException
public static void setLayouts(long groupId, boolean privateLayout, long parentLayoutId, long[] layoutIds, ServiceContext serviceContext) throws RemoteException
groupId
- the primary key of the groupprivateLayout
- whether the layout is private to the groupparentLayoutId
- the primary key of the parent layoutlayoutIds
- the primary keys of the layoutsserviceContext
- the service context
PortalException
- if a group or layout with the primary key could
not be found, if the group did not have permission to manage the
layouts, if no layouts were specified, if the first layout was
not page-able, if the first layout was hidden, or if some other
portal exception occurred
SystemException
- if a system exception occurred
RemoteException
public static void unschedulePublishToLive(long groupId, String jobName, String groupName) throws RemoteException
groupId
- the primary key of the groupjobName
- the job namegroupName
- the group name (optionally DestinationNames.LAYOUTS_LOCAL_PUBLISHER
).
See DestinationNames
.
PortalException
- if the group did not permission to manage staging
and publish
SystemException
- if a system exception occurred
RemoteException
public static void unschedulePublishToRemote(long groupId, String jobName, String groupName) throws RemoteException
groupId
- the primary key of the groupjobName
- the job namegroupName
- the group name (optionally DestinationNames.LAYOUTS_LOCAL_PUBLISHER
).
See DestinationNames
.
PortalException
- if a group with the primary key could not be
found or if the group did not have permission to publish
SystemException
- if a system exception occurred
RemoteException
public static LayoutSoap updateLayout(long groupId, boolean privateLayout, long layoutId, long parentLayoutId, String[] localeNamesMapLanguageIds, String[] localeNamesMapValues, String[] localeTitlesMapLanguageIds, String[] localeTitlesMapValues, String[] descriptionMapLanguageIds, String[] descriptionMapValues, String[] keywordsMapLanguageIds, String[] keywordsMapValues, String[] robotsMapLanguageIds, String[] robotsMapValues, String type, boolean hidden, String friendlyURL, Boolean iconImage, byte[] iconBytes, ServiceContext serviceContext) throws RemoteException
groupId
- the primary key of the groupprivateLayout
- whether the layout is private to the grouplayoutId
- the primary key of the layoutparentLayoutId
- the primary key of the layout's new parent layoutlocaleNamesMap
- the layout's locales and localized nameslocaleTitlesMap
- the layout's locales and localized titlesdescriptionMap
- the locales and localized descriptions to merge
(optionally null
)keywordsMap
- the locales and localized keywords to merge
(optionally null
)robotsMap
- the locales and localized robots to merge (optionally
null
)type
- the layout's new type (optionally LayoutConstants.TYPE_PORTLET
)hidden
- whether the layout is hiddenfriendlyURL
- the layout's new friendly URL (optionally PropsValues.DEFAULT_USER_PRIVATE_LAYOUT_FRIENDLY_URL
or PropsValues.DEFAULT_USER_PRIVATE_LAYOUT_FRIENDLY_URL
).
The default values can be overridden in
portal-ext.properties
by specifying new values for
the corresponding properties defined in PropsValues
. To see how the URL is
normalized when accessed see FriendlyURLNormalizerUtil.normalize(
String)
.iconImage
- whether the icon image will be updatediconBytes
- the byte array of the layout's new icon imageserviceContext
- the service context. Can set the modification date
and expando bridge attributes for the layout.
PortalException
- if a group or layout with the primary key could
not be found, if the user did not have permission to update the
layout, if a unique friendly URL could not be generated, if a
valid parent layout ID to use could not be found, or if the
layout parameters were invalid
SystemException
- if a system exception occurred
RemoteException
public static LayoutSoap updateLayout(long groupId, boolean privateLayout, long layoutId, String typeSettings) throws RemoteException
groupId
- the primary key of the groupprivateLayout
- whether the layout is private to the grouplayoutId
- the primary key of the layouttypeSettings
- the settings to load the unicode properties object.
See #fastLoad(String)
.
PortalException
- if a matching layout could not be found or if the
user did not have permission to update the layout
SystemException
- if a system exception occurred
RemoteException
public static LayoutSoap updateLookAndFeel(long groupId, boolean privateLayout, long layoutId, String themeId, String colorSchemeId, String css, boolean wapTheme) throws RemoteException
groupId
- the primary key of the groupprivateLayout
- whether the layout is private to the grouplayoutId
- the primary key of the layoutthemeId
- the primary key of the layout's new themecolorSchemeId
- the primary key of the layout's new color schemecss
- the layout's new CSSwapTheme
- whether the theme is for WAP browsers
PortalException
- if a matching layout could not be found, or if
the user did not have permission to update the layout and
permission to apply the theme
SystemException
- if a system exception occurred
RemoteException
public static LayoutSoap updateName(long groupId, boolean privateLayout, long layoutId, String name, String languageId) throws RemoteException
groupId
- the primary key of the groupprivateLayout
- whether the layout is private to the grouplayoutId
- the primary key of the layoutname
- the layout's new namelanguageId
- the primary key of the language. For more information
see Locale
.
PortalException
- if a matching layout could not be found, if the
user did not have permission to update the layout, or if the new
name was null
SystemException
- if a system exception occurred
RemoteException
public static LayoutSoap updateName(long plid, String name, String languageId) throws RemoteException
plid
- the primary key of the layoutname
- the name to be assignedlanguageId
- the primary key of the language. For more information
see Locale
.
PortalException
- if a layout with the primary key could not be
found, or if the user did not have permission to update the
layout, or if the name was null
SystemException
- if a system exception occurred
RemoteException
public static LayoutSoap updateParentLayoutId(long groupId, boolean privateLayout, long layoutId, long parentLayoutId) throws RemoteException
groupId
- the primary key of the groupprivateLayout
- whether the layout is private to the grouplayoutId
- the primary key of the layoutparentLayoutId
- the primary key to be assigned to the parent
layout
PortalException
- if a valid parent layout ID to use could not be
found, if a matching layout could not be found, or if the user
did not have permission to update the layout
SystemException
- if a system exception occurred
RemoteException
public static LayoutSoap updateParentLayoutId(long plid, long parentPlid) throws RemoteException
LayoutConstants.DEFAULT_PARENT_LAYOUT_ID
is
assigned.
plid
- the primary key of the layoutparentPlid
- the primary key of the parent layout
PortalException
- if a layout with the primary key could not be
found, if the user did not have permission to update the layout,
or if a valid parent layout ID to use could not be found
SystemException
- if a system exception occurred
RemoteException
public static LayoutSoap updatePriority(long groupId, boolean privateLayout, long layoutId, int priority) throws RemoteException
groupId
- the primary key of the groupprivateLayout
- whether the layout is private to the grouplayoutId
- the primary key of the layoutpriority
- the layout's new priority
PortalException
- if a matching layout could not be found or if the
user did not have permission to update the layout
SystemException
- if a system exception occurred
RemoteException
public static LayoutSoap updatePriority(long plid, int priority) throws RemoteException
plid
- the primary key of the layoutpriority
- the layout's new priority
PortalException
- if a layout with the primary key could not be
found
SystemException
- if a system exception occurred
RemoteException
|
Liferay 6.1.2-ce-ga3 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |