001    /**
002     * Copyright (c) 2000-present Liferay, Inc. All rights reserved.
003     *
004     * This library is free software; you can redistribute it and/or modify it under
005     * the terms of the GNU Lesser General Public License as published by the Free
006     * Software Foundation; either version 2.1 of the License, or (at your option)
007     * any later version.
008     *
009     * This library is distributed in the hope that it will be useful, but WITHOUT
010     * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
011     * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
012     * details.
013     */
014    
015    package com.liferay.portlet.exportimport.staging;
016    
017    import aQute.bnd.annotation.ProviderType;
018    
019    import com.liferay.portal.kernel.exception.PortalException;
020    import com.liferay.portal.kernel.json.JSONArray;
021    import com.liferay.portal.kernel.json.JSONObject;
022    import com.liferay.portal.kernel.util.ProxyFactory;
023    import com.liferay.portal.kernel.util.UnicodeProperties;
024    import com.liferay.portal.kernel.workflow.WorkflowTask;
025    import com.liferay.portal.kernel.xml.Element;
026    import com.liferay.portal.model.Group;
027    import com.liferay.portal.model.Layout;
028    import com.liferay.portal.model.LayoutRevision;
029    import com.liferay.portal.model.Portlet;
030    import com.liferay.portal.model.User;
031    import com.liferay.portal.service.ServiceContext;
032    import com.liferay.portlet.exportimport.lar.MissingReference;
033    import com.liferay.portlet.exportimport.lar.PortletDataContext;
034    import com.liferay.portlet.exportimport.model.ExportImportConfiguration;
035    
036    import java.io.Serializable;
037    
038    import java.util.Date;
039    import java.util.List;
040    import java.util.Locale;
041    import java.util.Map;
042    
043    import javax.portlet.PortletPreferences;
044    import javax.portlet.PortletRequest;
045    
046    import javax.servlet.http.HttpServletRequest;
047    
048    /**
049     * @author Raymond Augé
050     */
051    @ProviderType
052    public class StagingUtil {
053    
054            public static String buildRemoteURL(
055                    String remoteAddress, int remotePort, String remotePathContext,
056                    boolean secureConnection) {
057    
058                    return _staging.buildRemoteURL(
059                            remoteAddress, remotePort, remotePathContext, secureConnection);
060            }
061    
062            /**
063             * @deprecated As of 7.0.0, replaced by {@link #getRemoteSiteURL(Group,
064             *             boolean)}
065             */
066            @Deprecated
067            public static String buildRemoteURL(
068                    String remoteAddress, int remotePort, String remotePathContext,
069                    boolean secureConnection, long remoteGroupId, boolean privateLayout) {
070    
071                    return _staging.buildRemoteURL(
072                            remoteAddress, remotePort, remotePathContext, secureConnection,
073                            remoteGroupId, privateLayout);
074            }
075    
076            public static String buildRemoteURL(
077                    UnicodeProperties typeSettingsProperties) {
078    
079                    return _staging.buildRemoteURL(typeSettingsProperties);
080            }
081    
082            /**
083             * @deprecated As of 7.0.0, replaced by {@link
084             *             com.liferay.portlet.exportimport.service.StagingLocalServiceUtil#
085             *             checkDefaultLayoutSetBranches(long, Group, boolean, boolean,
086             *             boolean, ServiceContext)}
087             */
088            @Deprecated
089            public static void checkDefaultLayoutSetBranches(
090                            long userId, Group liveGroup, boolean branchingPublic,
091                            boolean branchingPrivate, boolean remote,
092                            ServiceContext serviceContext)
093                    throws PortalException {
094    
095                    _staging.checkDefaultLayoutSetBranches(
096                            userId, liveGroup, branchingPublic, branchingPrivate, remote,
097                            serviceContext);
098            }
099    
100            public static void copyFromLive(PortletRequest PortletRequest)
101                    throws PortalException {
102    
103                    _staging.copyFromLive(PortletRequest);
104            }
105    
106            public static void copyFromLive(
107                            PortletRequest PortletRequest, Portlet portlet)
108                    throws PortalException {
109    
110                    _staging.copyFromLive(PortletRequest, portlet);
111            }
112    
113            /**
114             * @deprecated As of 7.0.0, replaced by {@link #publishPortlet(long, long,
115             *             long, long, long, String, Map)}
116             */
117            @Deprecated
118            public static void copyPortlet(
119                            PortletRequest PortletRequest, long sourceGroupId,
120                            long targetGroupId, long sourcePlid, long targetPlid,
121                            String portletId)
122                    throws PortalException {
123    
124                    _staging.copyPortlet(
125                            PortletRequest, sourceGroupId, targetGroupId, sourcePlid,
126                            targetPlid, portletId);
127            }
128    
129            public static void copyRemoteLayouts(
130                            ExportImportConfiguration exportImportConfiguration)
131                    throws PortalException {
132    
133                    _staging.copyRemoteLayouts(exportImportConfiguration);
134            }
135    
136            public static void copyRemoteLayouts(long exportImportConfigurationId)
137                    throws PortalException {
138    
139                    _staging.copyRemoteLayouts(exportImportConfigurationId);
140            }
141    
142            public static void copyRemoteLayouts(
143                            long sourceGroupId, boolean privateLayout,
144                            Map<Long, Boolean> layoutIdMap, Map<String, String[]> parameterMap,
145                            String remoteAddress, int remotePort, String remotePathContext,
146                            boolean secureConnection, long remoteGroupId,
147                            boolean remotePrivateLayout)
148                    throws PortalException {
149    
150                    _staging.copyRemoteLayouts(
151                            sourceGroupId, privateLayout, layoutIdMap, parameterMap,
152                            remoteAddress, remotePort, remotePathContext, secureConnection,
153                            remoteGroupId, remotePrivateLayout);
154            }
155    
156            /**
157             * @deprecated As of 7.0.0, replaced by {@link #copyRemoteLayouts(long,
158             *             boolean, Map, Map, String, int, String, boolean, long,
159             *             boolean)}
160             */
161            @Deprecated
162            public static void copyRemoteLayouts(
163                            long sourceGroupId, boolean privateLayout,
164                            Map<Long, Boolean> layoutIdMap, Map<String, String[]> parameterMap,
165                            String remoteAddress, int remotePort, String remotePathContext,
166                            boolean secureConnection, long remoteGroupId,
167                            boolean remotePrivateLayout, Date startDate, Date endDate)
168                    throws PortalException {
169    
170                    _staging.copyRemoteLayouts(
171                            sourceGroupId, privateLayout, layoutIdMap, parameterMap,
172                            remoteAddress, remotePort, remotePathContext, secureConnection,
173                            remoteGroupId, remotePrivateLayout, startDate, endDate);
174            }
175    
176            public static void copyRemoteLayouts(
177                            long sourceGroupId, boolean privateLayout,
178                            Map<Long, Boolean> layoutIdMap, String name,
179                            Map<String, String[]> parameterMap, String remoteAddress,
180                            int remotePort, String remotePathContext, boolean secureConnection,
181                            long remoteGroupId, boolean remotePrivateLayout)
182                    throws PortalException {
183    
184                    _staging.copyRemoteLayouts(
185                            sourceGroupId, privateLayout, layoutIdMap, name, parameterMap,
186                            remoteAddress, remotePort, remotePathContext, secureConnection,
187                            remoteGroupId, remotePrivateLayout);
188            }
189    
190            public static void deleteLastImportSettings(
191                            Group liveGroup, boolean privateLayout)
192                    throws PortalException {
193    
194                    _staging.deleteLastImportSettings(liveGroup, privateLayout);
195            }
196    
197            public static void deleteRecentLayoutRevisionId(
198                    HttpServletRequest request, long layoutSetBranchId, long plid) {
199    
200                    _staging.deleteRecentLayoutRevisionId(request, layoutSetBranchId, plid);
201            }
202    
203            public static void deleteRecentLayoutRevisionId(
204                    long userId, long layoutSetBranchId, long plid) {
205    
206                    _staging.deleteRecentLayoutRevisionId(userId, layoutSetBranchId, plid);
207            }
208    
209            /**
210             * @deprecated As of 7.0.0, replaced by {@link
211             *             #deleteRecentLayoutRevisionId(long, long, long)}
212             */
213            @Deprecated
214            public static void deleteRecentLayoutRevisionId(
215                    User user, long layoutSetBranchId, long plid) {
216    
217                    _staging.deleteRecentLayoutRevisionId(user, layoutSetBranchId, plid);
218            }
219    
220            public static JSONArray getErrorMessagesJSONArray(
221                    Locale locale, Map<String, MissingReference> missingReferences) {
222    
223                    return _staging.getErrorMessagesJSONArray(locale, missingReferences);
224            }
225    
226            /**
227             * @deprecated As of 7.0.0, replaced by {@link
228             *             #getErrorMessagesJSONArray(Locale, Map<String,
229             *             MissingReference>)}
230             */
231            @Deprecated
232            public static JSONArray getErrorMessagesJSONArray(
233                    Locale locale, Map<String, MissingReference> missingReferences,
234                    Map<String, Serializable> contextMap) {
235    
236                    return _staging.getErrorMessagesJSONArray(
237                            locale, missingReferences, contextMap);
238            }
239    
240            public static JSONObject getExceptionMessagesJSONObject(
241                    Locale locale, Exception e,
242                    ExportImportConfiguration exportImportConfiguration) {
243    
244                    return _staging.getExceptionMessagesJSONObject(
245                            locale, e, exportImportConfiguration);
246            }
247    
248            /**
249             * @deprecated As of 7.0.0, replaced by {@link
250             *             #getExceptionMessagesJSONObject(Locale, Exception,
251             *             ExportImportConfiguration)}
252             */
253            @Deprecated
254            public static JSONObject getExceptionMessagesJSONObject(
255                    Locale locale, Exception e, Map<String, Serializable> contextMap) {
256    
257                    return _staging.getExceptionMessagesJSONObject(locale, e, contextMap);
258            }
259    
260            public static Group getLiveGroup(long groupId) {
261                    return _staging.getLiveGroup(groupId);
262            }
263    
264            public static long getLiveGroupId(long groupId) {
265                    return _staging.getLiveGroupId(groupId);
266            }
267    
268            /**
269             * @deprecated As of 7.0.0, moved to {@link
270             *             com.liferay.portlet.exportimport.lar.ExportImportHelperUtil#getMissingParentLayouts(
271             *             Layout, long)}
272             */
273            @Deprecated
274            public static List<Layout> getMissingParentLayouts(
275                            Layout layout, long liveGroupId)
276                    throws Exception {
277    
278                    return _staging.getMissingParentLayouts(layout, liveGroupId);
279            }
280    
281            public static long getRecentLayoutRevisionId(
282                            HttpServletRequest request, long layoutSetBranchId, long plid)
283                    throws PortalException {
284    
285                    return _staging.getRecentLayoutRevisionId(
286                            request, layoutSetBranchId, plid);
287            }
288    
289            public static long getRecentLayoutRevisionId(
290                            User user, long layoutSetBranchId, long plid)
291                    throws PortalException {
292    
293                    return _staging.getRecentLayoutRevisionId(
294                            user, layoutSetBranchId, plid);
295            }
296    
297            public static long getRecentLayoutSetBranchId(
298                    HttpServletRequest request, long layoutSetId) {
299    
300                    return _staging.getRecentLayoutSetBranchId(request, layoutSetId);
301            }
302    
303            public static long getRecentLayoutSetBranchId(User user, long layoutSetId) {
304                    return _staging.getRecentLayoutSetBranchId(user, layoutSetId);
305            }
306    
307            public static String getRemoteSiteURL(
308                            Group stagingGroup, boolean privateLayout)
309                    throws PortalException {
310    
311                    return _staging.getRemoteSiteURL(stagingGroup, privateLayout);
312            }
313    
314            public static String getSchedulerGroupName(
315                    String destinationName, long groupId) {
316    
317                    return _staging.getSchedulerGroupName(destinationName, groupId);
318            }
319    
320            public static String getStagedPortletId(String portletId) {
321                    return _staging.getStagedPortletId(portletId);
322            }
323    
324            public static long[] getStagingAndLiveGroupIds(long groupId)
325                    throws PortalException {
326    
327                    return _staging.getStagingAndLiveGroupIds(groupId);
328            }
329    
330            public static Group getStagingGroup(long groupId) {
331                    return _staging.getStagingGroup(groupId);
332            }
333    
334            /**
335             * @deprecated As of 7.0.0, replaced by {@link
336             *             com.liferay.portlet.exportimport.configuration.ExportImportConfigurationParameterMapFactory#buildParameterMap(
337             *             )}
338             */
339            @Deprecated
340            public static Map<String, String[]> getStagingParameters() {
341                    return _staging.getStagingParameters();
342            }
343    
344            /**
345             * @deprecated As of 7.0.0, replaced by {@link
346             *             com.liferay.portlet.exportimport.configuration.ExportImportConfigurationParameterMapFactory#buildParameterMap(
347             *             PortletRequest)}
348             */
349            @Deprecated
350            public static Map<String, String[]> getStagingParameters(
351                    PortletRequest PortletRequest) {
352    
353                    return _staging.getStagingParameters(PortletRequest);
354            }
355    
356            public static JSONArray getWarningMessagesJSONArray(
357                    Locale locale, Map<String, MissingReference> missingReferences) {
358    
359                    return _staging.getWarningMessagesJSONArray(locale, missingReferences);
360            }
361    
362            /**
363             * @deprecated As of 7.0.0, replaced by {@link
364             *             #getWarningMessagesJSONArray(Locale, Map<String,
365             *             MissingReference>)}
366             */
367            @Deprecated
368            public static JSONArray getWarningMessagesJSONArray(
369                    Locale locale, Map<String, MissingReference> missingReferences,
370                    Map<String, Serializable> contextMap) {
371    
372                    return _staging.getWarningMessagesJSONArray(
373                            locale, missingReferences, contextMap);
374            }
375    
376            public static WorkflowTask getWorkflowTask(
377                            long userId, LayoutRevision layoutRevision)
378                    throws PortalException {
379    
380                    return _staging.getWorkflowTask(userId, layoutRevision);
381            }
382    
383            public static boolean hasWorkflowTask(
384                            long userId, LayoutRevision layoutRevision)
385                    throws PortalException {
386    
387                    return _staging.hasWorkflowTask(userId, layoutRevision);
388            }
389    
390            public static boolean isGroupAccessible(Group group, Group fromGroup) {
391                    return _staging.isGroupAccessible(group, fromGroup);
392            }
393    
394            public static boolean isGroupAccessible(long groupId, long fromGroupId)
395                    throws PortalException {
396    
397                    return _staging.isGroupAccessible(groupId, fromGroupId);
398            }
399    
400            public static boolean isIncomplete(Layout layout, long layoutSetBranchId) {
401                    return _staging.isIncomplete(layout, layoutSetBranchId);
402            }
403    
404            /**
405             * @deprecated As of 7.0.0, see {@link
406             *             com.liferay.portal.kernel.backgroundtask.BackgroundTaskExecutor#getIsolationLevel(
407             *             )}
408             */
409            @Deprecated
410            public static void lockGroup(long userId, long groupId)
411                    throws PortalException {
412    
413                    _staging.lockGroup(userId, groupId);
414            }
415    
416            public static void publishLayout(
417                            long userId, long plid, long liveGroupId, boolean includeChildren)
418                    throws PortalException {
419    
420                    _staging.publishLayout(userId, plid, liveGroupId, includeChildren);
421            }
422    
423            public static void publishLayouts(
424                            long userId, ExportImportConfiguration exportImportConfiguration)
425                    throws PortalException {
426    
427                    _staging.publishLayouts(userId, exportImportConfiguration);
428            }
429    
430            public static void publishLayouts(
431                            long userId, long exportImportConfigurationId)
432                    throws PortalException {
433    
434                    _staging.publishLayouts(userId, exportImportConfigurationId);
435            }
436    
437            public static void publishLayouts(
438                            long userId, long sourceGroupId, long targetGroupId,
439                            boolean privateLayout, long[] layoutIds,
440                            Map<String, String[]> parameterMap)
441                    throws PortalException {
442    
443                    _staging.publishLayouts(
444                            userId, sourceGroupId, targetGroupId, privateLayout, layoutIds,
445                            parameterMap);
446            }
447    
448            /**
449             * @deprecated As of 7.0.0, replaced by {@link #publishLayouts(long, long,
450             *             long, boolean, long[], Map)}
451             */
452            @Deprecated
453            public static void publishLayouts(
454                            long userId, long sourceGroupId, long targetGroupId,
455                            boolean privateLayout, long[] layoutIds,
456                            Map<String, String[]> parameterMap, Date startDate, Date endDate)
457                    throws PortalException {
458    
459                    _staging.publishLayouts(
460                            userId, sourceGroupId, targetGroupId, privateLayout, layoutIds,
461                            parameterMap, startDate, endDate);
462            }
463    
464            public static void publishLayouts(
465                            long userId, long sourceGroupId, long targetGroupId,
466                            boolean privateLayout, long[] layoutIds, String name,
467                            Map<String, String[]> parameterMap)
468                    throws PortalException {
469    
470                    _staging.publishLayouts(
471                            userId, sourceGroupId, targetGroupId, privateLayout, layoutIds,
472                            name, parameterMap);
473            }
474    
475            /**
476             * @deprecated As of 7.0.0, replaced by {@link #publishLayouts(long, long,
477             *             long, boolean, long[], Map)}
478             */
479            @Deprecated
480            public static void publishLayouts(
481                            long userId, long sourceGroupId, long targetGroupId,
482                            boolean privateLayout, Map<Long, Boolean> layoutIdMap,
483                            Map<String, String[]> parameterMap, Date startDate, Date endDate)
484                    throws PortalException {
485    
486                    _staging.publishLayouts(
487                            userId, sourceGroupId, targetGroupId, privateLayout, layoutIdMap,
488                            parameterMap, startDate, endDate);
489            }
490    
491            public static void publishLayouts(
492                            long userId, long sourceGroupId, long targetGroupId,
493                            boolean privateLayout, Map<String, String[]> parameterMap)
494                    throws PortalException {
495    
496                    _staging.publishLayouts(
497                            userId, sourceGroupId, targetGroupId, privateLayout, parameterMap);
498            }
499    
500            /**
501             * @deprecated As of 7.0.0, replaced by {@link #publishLayouts(long, long,
502             *             long, boolean, Map)}
503             */
504            @Deprecated
505            public static void publishLayouts(
506                            long userId, long sourceGroupId, long targetGroupId,
507                            boolean privateLayout, Map<String, String[]> parameterMap,
508                            Date startDate, Date endDate)
509                    throws PortalException {
510    
511                    _staging.publishLayouts(
512                            userId, sourceGroupId, targetGroupId, privateLayout, parameterMap,
513                            startDate, endDate);
514            }
515    
516            public static void publishPortlet(
517                            long userId, ExportImportConfiguration exportImportConfiguration)
518                    throws PortalException {
519    
520                    _staging.publishPortlet(userId, exportImportConfiguration);
521            }
522    
523            public static void publishPortlet(
524                            long userId, long exportImportConfigurationId)
525                    throws PortalException {
526    
527                    _staging.publishPortlet(userId, exportImportConfigurationId);
528            }
529    
530            public static void publishPortlet(
531                            long userId, long sourceGroupId, long targetGroupId,
532                            long sourcePlid, long targetPlid, String portletId,
533                            Map<String, String[]> parameterMap)
534                    throws PortalException {
535    
536                    _staging.publishPortlet(
537                            userId, sourceGroupId, targetGroupId, sourcePlid, targetPlid,
538                            portletId, parameterMap);
539            }
540    
541            public static void publishToLive(PortletRequest PortletRequest)
542                    throws PortalException {
543    
544                    _staging.publishToLive(PortletRequest);
545            }
546    
547            public static void publishToLive(
548                            PortletRequest PortletRequest, Portlet portlet)
549                    throws PortalException {
550    
551                    _staging.publishToLive(PortletRequest, portlet);
552            }
553    
554            public static void publishToRemote(PortletRequest PortletRequest)
555                    throws PortalException {
556    
557                    _staging.publishToRemote(PortletRequest);
558            }
559    
560            public static void scheduleCopyFromLive(PortletRequest PortletRequest)
561                    throws PortalException {
562    
563                    _staging.scheduleCopyFromLive(PortletRequest);
564            }
565    
566            public static void schedulePublishToLive(PortletRequest PortletRequest)
567                    throws PortalException {
568    
569                    _staging.schedulePublishToLive(PortletRequest);
570            }
571    
572            public static void schedulePublishToRemote(PortletRequest PortletRequest)
573                    throws PortalException {
574    
575                    _staging.schedulePublishToRemote(PortletRequest);
576            }
577    
578            public static void setRecentLayoutBranchId(
579                            HttpServletRequest request, long layoutSetBranchId, long plid,
580                            long layoutBranchId)
581                    throws PortalException {
582    
583                    _staging.setRecentLayoutBranchId(
584                            request, layoutSetBranchId, plid, layoutBranchId);
585            }
586    
587            public static void setRecentLayoutBranchId(
588                            User user, long layoutSetBranchId, long plid, long layoutBranchId)
589                    throws PortalException {
590    
591                    _staging.setRecentLayoutBranchId(
592                            user, layoutSetBranchId, plid, layoutBranchId);
593            }
594    
595            public static void setRecentLayoutRevisionId(
596                            HttpServletRequest request, long layoutSetBranchId, long plid,
597                            long layoutRevisionId)
598                    throws PortalException {
599    
600                    _staging.setRecentLayoutRevisionId(
601                            request, layoutSetBranchId, plid, layoutRevisionId);
602            }
603    
604            public static void setRecentLayoutRevisionId(
605                            User user, long layoutSetBranchId, long plid, long layoutRevisionId)
606                    throws PortalException {
607    
608                    _staging.setRecentLayoutRevisionId(
609                            user, layoutSetBranchId, plid, layoutRevisionId);
610            }
611    
612            public static void setRecentLayoutSetBranchId(
613                            HttpServletRequest request, long layoutSetId,
614                            long layoutSetBranchId)
615                    throws PortalException {
616    
617                    _staging.setRecentLayoutSetBranchId(
618                            request, layoutSetId, layoutSetBranchId);
619            }
620    
621            public static void setRecentLayoutSetBranchId(
622                            User user, long layoutSetId, long layoutSetBranchId)
623                    throws PortalException {
624    
625                    _staging.setRecentLayoutSetBranchId(
626                            user, layoutSetId, layoutSetBranchId);
627            }
628    
629            public static String stripProtocolFromRemoteAddress(String remoteAddress) {
630                    return _staging.stripProtocolFromRemoteAddress(remoteAddress);
631            }
632    
633            /**
634             * @deprecated As of 7.0.0, see {@link
635             *             com.liferay.portal.kernel.backgroundtask.BackgroundTaskExecutor#getIsolationLevel(
636             *             )}
637             */
638            @Deprecated
639            public static void unlockGroup(long groupId) {
640                    _staging.unlockGroup(groupId);
641            }
642    
643            public static void unscheduleCopyFromLive(PortletRequest PortletRequest)
644                    throws PortalException {
645    
646                    _staging.unscheduleCopyFromLive(PortletRequest);
647            }
648    
649            public static void unschedulePublishToLive(PortletRequest PortletRequest)
650                    throws PortalException {
651    
652                    _staging.unschedulePublishToLive(PortletRequest);
653            }
654    
655            public static void unschedulePublishToRemote(PortletRequest PortletRequest)
656                    throws PortalException {
657    
658                    _staging.unschedulePublishToRemote(PortletRequest);
659            }
660    
661            public static void updateLastImportSettings(
662                            Element layoutElement, Layout layout,
663                            PortletDataContext portletDataContext)
664                    throws PortalException {
665    
666                    _staging.updateLastImportSettings(
667                            layoutElement, layout, portletDataContext);
668            }
669    
670            /**
671             * @deprecated As of 7.0.0, replaced by {@link
672             *             com.liferay.portlet.exportimport.lar.ExportImportDateUtil#updateLastPublishDate(
673             *             long, boolean, com.liferay.portal.kernel.util.DateRange,
674             *             Date)}
675             */
676            @Deprecated
677            public static void updateLastPublishDate(
678                            long sourceGroupId, boolean privateLayout, Date lastPublishDate)
679                    throws PortalException {
680    
681                    _staging.updateLastPublishDate(
682                            sourceGroupId, privateLayout, lastPublishDate);
683            }
684    
685            /**
686             * @deprecated As of 7.0.0, replaced by {@link
687             *             com.liferay.portlet.exportimport.lar.ExportImportDateUtil#updateLastPublishDate(
688             *             String, PortletPreferences,
689             *             com.liferay.portal.kernel.util.DateRange, Date)}
690             */
691            @Deprecated
692            public static void updateLastPublishDate(
693                            String portletId, PortletPreferences portletPreferences,
694                            Date lastPublishDate)
695                    throws PortalException {
696    
697                    _staging.updateLastPublishDate(
698                            portletId, portletPreferences, lastPublishDate);
699            }
700    
701            public static void updateStaging(
702                            PortletRequest PortletRequest, Group liveGroup)
703                    throws PortalException {
704    
705                    _staging.updateStaging(PortletRequest, liveGroup);
706            }
707    
708            public static void validateRemote(
709                            long groupId, String remoteAddress, int remotePort,
710                            String remotePathContext, boolean secureConnection,
711                            long remoteGroupId)
712                    throws PortalException {
713    
714                    _staging.validateRemote(
715                            groupId, remoteAddress, remotePort, remotePathContext,
716                            secureConnection, remoteGroupId);
717            }
718    
719            /**
720             * @deprecated As of 7.0.0, replaced by {@link #validateRemote(long, String,
721             *             int, String, boolean, long)}
722             */
723            @Deprecated
724            public static void validateRemote(
725                            String remoteAddress, int remotePort, String remotePathContext,
726                            boolean secureConnection, long remoteGroupId)
727                    throws PortalException {
728    
729                    _staging.validateRemote(
730                            remoteAddress, remotePort, remotePathContext, secureConnection,
731                            remoteGroupId);
732            }
733    
734            private static final Staging _staging =
735                    ProxyFactory.newServiceTrackedInstance(Staging.class);
736    
737    }