001
014
015 package com.liferay.portal.util;
016
017 import aQute.bnd.annotation.ProviderType;
018
019 import com.liferay.portal.kernel.dao.db.DB;
020 import com.liferay.portal.kernel.dao.db.DBFactoryUtil;
021 import com.liferay.portal.kernel.exception.PortalException;
022 import com.liferay.portal.kernel.portlet.LiferayPortletRequest;
023 import com.liferay.portal.kernel.portlet.LiferayPortletResponse;
024 import com.liferay.portal.kernel.security.pacl.permission.PortalRuntimePermission;
025 import com.liferay.portal.kernel.servlet.taglib.ui.BreadcrumbEntry;
026 import com.liferay.portal.kernel.upload.UploadPortletRequest;
027 import com.liferay.portal.kernel.upload.UploadServletRequest;
028 import com.liferay.portal.model.BaseModel;
029 import com.liferay.portal.model.Company;
030 import com.liferay.portal.model.Group;
031 import com.liferay.portal.model.Layout;
032 import com.liferay.portal.model.LayoutFriendlyURLComposite;
033 import com.liferay.portal.model.LayoutQueryStringComposite;
034 import com.liferay.portal.model.LayoutSet;
035 import com.liferay.portal.model.Portlet;
036 import com.liferay.portal.model.ResourcePermission;
037 import com.liferay.portal.model.User;
038 import com.liferay.portal.service.PortletLocalServiceUtil;
039 import com.liferay.portal.theme.ThemeDisplay;
040 import com.liferay.portlet.InvokerPortlet;
041 import com.liferay.portlet.PortletInstanceFactoryUtil;
042 import com.liferay.portlet.expando.model.ExpandoBridge;
043
044 import java.io.IOException;
045 import java.io.Serializable;
046
047 import java.net.InetAddress;
048
049 import java.sql.SQLException;
050
051 import java.util.Date;
052 import java.util.List;
053 import java.util.Locale;
054 import java.util.Map;
055 import java.util.Properties;
056 import java.util.ResourceBundle;
057 import java.util.Set;
058 import java.util.TimeZone;
059
060 import javax.portlet.ActionRequest;
061 import javax.portlet.ActionResponse;
062 import javax.portlet.PortletConfig;
063 import javax.portlet.PortletException;
064 import javax.portlet.PortletMode;
065 import javax.portlet.PortletPreferences;
066 import javax.portlet.PortletRequest;
067 import javax.portlet.PortletResponse;
068 import javax.portlet.PortletURL;
069 import javax.portlet.PreferencesValidator;
070 import javax.portlet.RenderRequest;
071 import javax.portlet.ValidatorException;
072 import javax.portlet.WindowState;
073
074 import javax.servlet.ServletContext;
075 import javax.servlet.ServletException;
076 import javax.servlet.http.HttpServletRequest;
077 import javax.servlet.http.HttpServletResponse;
078 import javax.servlet.http.HttpSession;
079
080
085 @ProviderType
086 public class PortalUtil {
087
088
096 public static void addPageDescription(
097 String description, HttpServletRequest request) {
098
099 getPortal().addPageDescription(description, request);
100 }
101
102
110 public static void addPageKeywords(
111 String keywords, HttpServletRequest request) {
112
113 getPortal().addPageKeywords(keywords, request);
114 }
115
116
122 public static void addPageSubtitle(
123 String subtitle, HttpServletRequest request) {
124
125 getPortal().addPageSubtitle(subtitle, request);
126 }
127
128
134 public static void addPageTitle(String title, HttpServletRequest request) {
135 getPortal().addPageTitle(title, request);
136 }
137
138 public static boolean addPortalInetSocketAddressEventListener(
139 PortalInetSocketAddressEventListener
140 portalInetSocketAddressEventListener) {
141
142 return getPortal().addPortalInetSocketAddressEventListener(
143 portalInetSocketAddressEventListener);
144 }
145
146
155 @Deprecated
156 public static void addPortalPortEventListener(
157 PortalPortEventListener portalPortEventListener) {
158
159 getPortal().addPortalPortEventListener(portalPortEventListener);
160 }
161
162
169 public static void addPortletBreadcrumbEntry(
170 HttpServletRequest request, String title, String url) {
171
172 getPortal().addPortletBreadcrumbEntry(request, title, url);
173 }
174
175
183 public static void addPortletBreadcrumbEntry(
184 HttpServletRequest request, String title, String url,
185 Map<String, Object> data) {
186
187 getPortal().addPortletBreadcrumbEntry(request, title, url, data);
188 }
189
190
198 public static void addPortletDefaultResource(
199 HttpServletRequest request, Portlet portlet)
200 throws PortalException {
201
202 getPortal().addPortletDefaultResource(request, portlet);
203 }
204
205 public static void addPortletDefaultResource(
206 long companyId, Layout layout, Portlet portlet)
207 throws PortalException {
208
209 getPortal().addPortletDefaultResource(companyId, layout, portlet);
210 }
211
212
229 public static String addPreservedParameters(
230 ThemeDisplay themeDisplay, Layout layout, String url,
231 boolean doAsUser) {
232
233 return getPortal().addPreservedParameters(
234 themeDisplay, layout, url, doAsUser);
235 }
236
237
245 public static String addPreservedParameters(
246 ThemeDisplay themeDisplay, String url) {
247
248 return getPortal().addPreservedParameters(themeDisplay, url);
249 }
250
251 public static void addUserLocaleOptionsMessage(HttpServletRequest request) {
252 getPortal().addUserLocaleOptionsMessage(request);
253 }
254
255
261 public static void clearRequestParameters(RenderRequest renderRequest) {
262 getPortal().clearRequestParameters(renderRequest);
263 }
264
265
272 public static void copyRequestParameters(
273 ActionRequest actionRequest, ActionResponse actionResponse) {
274
275 getPortal().copyRequestParameters(actionRequest, actionResponse);
276 }
277
278
286 public static String escapeRedirect(String url) {
287 return getPortal().escapeRedirect(url);
288 }
289
290
297 public static String generateRandomKey(
298 HttpServletRequest request, String input) {
299
300 return getPortal().generateRandomKey(request, input);
301 }
302
303 public static String getAbsoluteURL(
304 HttpServletRequest request, String url) {
305
306 return getPortal().getAbsoluteURL(request, url);
307 }
308
309 public static LayoutQueryStringComposite
310 getActualLayoutQueryStringComposite(
311 long groupId, boolean privateLayout, String friendlyURL,
312 Map<String, String[]> params, Map<String, Object> requestContext)
313 throws PortalException {
314
315 return getPortal().getActualLayoutQueryStringComposite(
316 groupId, privateLayout, friendlyURL, params, requestContext);
317 }
318
319 public static String getActualURL(
320 long groupId, boolean privateLayout, String mainPath,
321 String friendlyURL, Map<String, String[]> params,
322 Map<String, Object> requestContext)
323 throws PortalException {
324
325 return getPortal().getActualURL(
326 groupId, privateLayout, mainPath, friendlyURL, params,
327 requestContext);
328 }
329
330
334 @Deprecated
335 public static Locale[] getAlternateLocales(HttpServletRequest request)
336 throws PortalException {
337
338 return getPortal().getAlternateLocales(request);
339 }
340
341
360 public static String getAlternateURL(
361 String canonicalURL, ThemeDisplay themeDisplay, Locale locale,
362 Layout layout)
363 throws PortalException {
364
365 return getPortal().getAlternateURL(
366 canonicalURL, themeDisplay, locale, layout);
367 }
368
369 public static long[] getAncestorSiteGroupIds(long groupId)
370 throws PortalException {
371
372 return getPortal().getAncestorSiteGroupIds(groupId);
373 }
374
375
379 @Deprecated
380 public static Set<String> getAuthTokenIgnoreActions() {
381 return getPortal().getAuthTokenIgnoreActions();
382 }
383
384
388 @Deprecated
389 public static Set<String> getAuthTokenIgnorePortlets() {
390 return getPortal().getAuthTokenIgnorePortlets();
391 }
392
393
403 public static BaseModel<?> getBaseModel(
404 ResourcePermission resourcePermission)
405 throws PortalException {
406
407 return getPortal().getBaseModel(resourcePermission);
408 }
409
410
420 public static BaseModel<?> getBaseModel(String modelName, String primKey)
421 throws PortalException {
422
423 return getPortal().getBaseModel(modelName, primKey);
424 }
425
426
436 public static long getBasicAuthUserId(HttpServletRequest request)
437 throws PortalException {
438
439 return getPortal().getBasicAuthUserId(request);
440 }
441
442
453 public static long getBasicAuthUserId(
454 HttpServletRequest request, long companyId)
455 throws PortalException {
456
457 return getPortal().getBasicAuthUserId(request, companyId);
458 }
459
460 public static List<Group> getBrowsableScopeGroups(
461 long userId, long companyId, long groupId, String portletId)
462 throws PortalException {
463
464 return getPortal().getBrowsableScopeGroups(
465 userId, companyId, groupId, portletId);
466 }
467
468
491 public static String getCanonicalURL(
492 String completeURL, ThemeDisplay themeDisplay, Layout layout)
493 throws PortalException {
494
495 return getPortal().getCanonicalURL(completeURL, themeDisplay, layout);
496 }
497
498
524 public static String getCanonicalURL(
525 String completeURL, ThemeDisplay themeDisplay, Layout layout,
526 boolean forceLayoutFriendlyURL)
527 throws PortalException {
528
529 return getPortal().getCanonicalURL(
530 completeURL, themeDisplay, layout, forceLayoutFriendlyURL);
531 }
532
533
536 @Deprecated
537 public static String getCDNHost() {
538 return getPortal().getCDNHost();
539 }
540
541
548 public static String getCDNHost(boolean secure) {
549 return getPortal().getCDNHost(secure);
550 }
551
552 public static String getCDNHost(HttpServletRequest request)
553 throws PortalException {
554
555 return getPortal().getCDNHost(request);
556 }
557
558
565 public static String getCDNHostHttp(long companyId) {
566 return getPortal().getCDNHostHttp(companyId);
567 }
568
569
576 public static String getCDNHostHttps(long companyId) {
577 return getPortal().getCDNHostHttps(companyId);
578 }
579
580
586 public static String getClassName(long classNameId) {
587 return getPortal().getClassName(classNameId);
588 }
589
590
596 public static long getClassNameId(Class<?> clazz) {
597 return getPortal().getClassNameId(clazz);
598 }
599
600
606 public static long getClassNameId(String value) {
607 return getPortal().getClassNameId(value);
608 }
609
610
620 public static String getClassNamePortletId(String className) {
621 return getPortal().getClassNamePortletId(className);
622 }
623
624 public static Company getCompany(HttpServletRequest request)
625 throws PortalException {
626
627 return getPortal().getCompany(request);
628 }
629
630 public static Company getCompany(PortletRequest portletRequest)
631 throws PortalException {
632
633 return getPortal().getCompany(portletRequest);
634 }
635
636 public static long getCompanyId(HttpServletRequest request) {
637 return getPortal().getCompanyId(request);
638 }
639
640 public static long getCompanyId(PortletRequest portletRequest) {
641 return getPortal().getCompanyId(portletRequest);
642 }
643
644 public static long[] getCompanyIds() {
645 return getPortal().getCompanyIds();
646 }
647
648 public static String getComputerAddress() {
649 return getPortal().getComputerAddress();
650 }
651
652 public static String getComputerName() {
653 return getPortal().getComputerName();
654 }
655
656 public static Map<String, List<Portlet>> getControlPanelCategoriesMap(
657 HttpServletRequest request) {
658
659 return getPortal().getControlPanelCategoriesMap(request);
660 }
661
662 public static String getControlPanelCategory(
663 String portletId, ThemeDisplay themeDisplay) {
664
665 return getPortal().getControlPanelCategory(portletId, themeDisplay);
666 }
667
668 public static String getControlPanelFullURL(
669 long scopeGroupId, String ppid, Map<String, String[]> params)
670 throws PortalException {
671
672 return getPortal().getControlPanelFullURL(scopeGroupId, ppid, params);
673 }
674
675 public static long getControlPanelPlid(long companyId)
676 throws PortalException {
677
678 return getPortal().getControlPanelPlid(companyId);
679 }
680
681 public static long getControlPanelPlid(PortletRequest portletRequest)
682 throws PortalException {
683
684 return getPortal().getControlPanelPlid(portletRequest);
685 }
686
687 public static Set<Portlet> getControlPanelPortlets(
688 long companyId, String category) {
689
690 return getPortal().getControlPanelPortlets(companyId, category);
691 }
692
693 public static List<Portlet> getControlPanelPortlets(
694 String category, ThemeDisplay themeDisplay) {
695
696 return getPortal().getControlPanelPortlets(category, themeDisplay);
697 }
698
699 public static PortletURL getControlPanelPortletURL(
700 HttpServletRequest request, String portletId, long referrerPlid,
701 String lifecycle) {
702
703 return getPortal().getControlPanelPortletURL(
704 request, portletId, referrerPlid, lifecycle);
705 }
706
707 public static PortletURL getControlPanelPortletURL(
708 PortletRequest portletRequest, String portletId, long referrerPlid,
709 String lifecycle) {
710
711 return getPortal().getControlPanelPortletURL(
712 portletRequest, portletId, referrerPlid, lifecycle);
713 }
714
715 public static String getCreateAccountURL(
716 HttpServletRequest request, ThemeDisplay themeDisplay)
717 throws Exception {
718
719 return getPortal().getCreateAccountURL(request, themeDisplay);
720 }
721
722 public static long[] getCurrentAndAncestorSiteGroupIds(long groupId)
723 throws PortalException {
724
725 return getPortal().getCurrentAndAncestorSiteGroupIds(groupId);
726 }
727
728 public static List<Group> getCurrentAndAncestorSiteGroups(long groupId)
729 throws PortalException {
730
731 return getPortal().getCurrentAndAncestorSiteGroups(groupId);
732 }
733
734 public static String getCurrentCompleteURL(HttpServletRequest request) {
735 return getPortal().getCurrentCompleteURL(request);
736 }
737
738 public static String getCurrentURL(HttpServletRequest request) {
739 return getPortal().getCurrentURL(request);
740 }
741
742 public static String getCurrentURL(PortletRequest portletRequest) {
743 return getPortal().getCurrentURL(portletRequest);
744 }
745
746 public static String getCustomSQLFunctionIsNotNull() {
747 return getPortal().getCustomSQLFunctionIsNotNull();
748 }
749
750 public static String getCustomSQLFunctionIsNull() {
751 return getPortal().getCustomSQLFunctionIsNull();
752 }
753
754
763 public static Date getDate(int month, int day, int year) {
764 return getPortal().getDate(month, day, year);
765 }
766
767
782 public static Date getDate(
783 int month, int day, int year,
784 Class<? extends PortalException> clazz)
785 throws PortalException {
786
787 return getPortal().getDate(month, day, year, clazz);
788 }
789
790
807 public static Date getDate(
808 int month, int day, int year, int hour, int min,
809 Class<? extends PortalException> clazz)
810 throws PortalException {
811
812 return getPortal().getDate(month, day, year, hour, min, clazz);
813 }
814
815
833 public static Date getDate(
834 int month, int day, int year, int hour, int min, TimeZone timeZone,
835 Class<? extends PortalException> clazz)
836 throws PortalException {
837
838 return getPortal().getDate(
839 month, day, year, hour, min, timeZone, clazz);
840 }
841
842
858 public static Date getDate(
859 int month, int day, int year, TimeZone timeZone,
860 Class<? extends PortalException> clazz)
861 throws PortalException {
862
863 return getPortal().getDate(month, day, year, timeZone, clazz);
864 }
865
866
869 @Deprecated
870 public static DB getDB() {
871 return DBFactoryUtil.getDB();
872 }
873
874 public static long getDefaultCompanyId() {
875 return getPortal().getDefaultCompanyId();
876 }
877
878 public static long getDigestAuthUserId(HttpServletRequest request)
879 throws PortalException {
880
881 return getPortal().getDigestAuthUserId(request);
882 }
883
884 public static String getEmailFromAddress(
885 PortletPreferences preferences, long companyId, String defaultValue) {
886
887 return getPortal().getEmailFromAddress(
888 preferences, companyId, defaultValue);
889 }
890
891 public static String getEmailFromName(
892 PortletPreferences preferences, long companyId, String defaultValue) {
893
894 return getPortal().getEmailFromName(
895 preferences, companyId, defaultValue);
896 }
897
898 public static Map<String, Serializable> getExpandoBridgeAttributes(
899 ExpandoBridge expandoBridge, PortletRequest portletRequest)
900 throws PortalException {
901
902 return getPortal().getExpandoBridgeAttributes(
903 expandoBridge, portletRequest);
904 }
905
906 public static Map<String, Serializable> getExpandoBridgeAttributes(
907 ExpandoBridge expandoBridge,
908 UploadPortletRequest uploadPortletRequest)
909 throws PortalException {
910
911 return getPortal().getExpandoBridgeAttributes(
912 expandoBridge, uploadPortletRequest);
913 }
914
915 public static Serializable getExpandoValue(
916 PortletRequest portletRequest, String name, int type,
917 String displayType)
918 throws PortalException {
919
920 return getPortal().getExpandoValue(
921 portletRequest, name, type, displayType);
922 }
923
924 public static Serializable getExpandoValue(
925 UploadPortletRequest uploadPortletRequest, String name, int type,
926 String displayType)
927 throws PortalException {
928
929 return getPortal().getExpandoValue(
930 uploadPortletRequest, name, type, displayType);
931 }
932
933 public static String getFacebookURL(
934 Portlet portlet, String facebookCanvasPageURL,
935 ThemeDisplay themeDisplay)
936 throws PortalException {
937
938 return getPortal().getFacebookURL(
939 portlet, facebookCanvasPageURL, themeDisplay);
940 }
941
942 public static Portlet getFirstMyAccountPortlet(ThemeDisplay themeDisplay) {
943 return getPortal().getFirstMyAccountPortlet(themeDisplay);
944 }
945
946 public static String getFirstPageLayoutTypes(HttpServletRequest request) {
947 return getPortal().getFirstPageLayoutTypes(request);
948 }
949
950 public static Portlet getFirstSiteAdministrationPortlet(
951 ThemeDisplay themeDisplay) {
952
953 return getPortal().getFirstSiteAdministrationPortlet(themeDisplay);
954 }
955
956 public static String getFullName(
957 String firstName, String middleName, String lastName) {
958
959 return getPortal().getFullName(firstName, middleName, lastName);
960 }
961
962 public static String getGlobalLibDir() {
963 return getPortal().getGlobalLibDir();
964 }
965
966 public static String getGoogleGadgetURL(
967 Portlet portlet, ThemeDisplay themeDisplay)
968 throws PortalException {
969
970 return getPortal().getGoogleGadgetURL(portlet, themeDisplay);
971 }
972
973 public static String getGroupFriendlyURL(
974 Group group, boolean privateLayoutSet, ThemeDisplay themeDisplay)
975 throws PortalException {
976
977 return getPortal().getGroupFriendlyURL(
978 group, privateLayoutSet, themeDisplay);
979 }
980
981 public static String getGroupFriendlyURL(
982 Group group, boolean privateLayoutSet, ThemeDisplay themeDisplay,
983 Locale locale)
984 throws PortalException {
985
986 return getPortal().getGroupFriendlyURL(
987 group, privateLayoutSet, themeDisplay, locale);
988 }
989
990 public static int[] getGroupFriendlyURLIndex(String requestURI) {
991 return getPortal().getGroupFriendlyURLIndex(requestURI);
992 }
993
994 public static String[] getGroupPermissions(HttpServletRequest request) {
995 return getPortal().getGroupPermissions(request);
996 }
997
998 public static String[] getGroupPermissions(
999 HttpServletRequest request, String className) {
1000
1001 return getPortal().getGroupPermissions(request, className);
1002 }
1003
1004 public static String[] getGroupPermissions(PortletRequest portletRequest) {
1005 return getPortal().getGroupPermissions(portletRequest);
1006 }
1007
1008 public static String[] getGroupPermissions(
1009 PortletRequest portletRequest, String className) {
1010
1011 return getPortal().getGroupPermissions(portletRequest, className);
1012 }
1013
1014 public static String[] getGuestPermissions(HttpServletRequest request) {
1015 return getPortal().getGuestPermissions(request);
1016 }
1017
1018 public static String[] getGuestPermissions(
1019 HttpServletRequest request, String className) {
1020
1021 return getPortal().getGuestPermissions(request, className);
1022 }
1023
1024 public static String[] getGuestPermissions(PortletRequest portletRequest) {
1025 return getPortal().getGuestPermissions(portletRequest);
1026 }
1027
1028 public static String[] getGuestPermissions(
1029 PortletRequest portletRequest, String className) {
1030
1031 return getPortal().getGuestPermissions(portletRequest, className);
1032 }
1033
1034 public static String getHomeURL(HttpServletRequest request)
1035 throws PortalException {
1036
1037 return getPortal().getHomeURL(request);
1038 }
1039
1040 public static String getHost(HttpServletRequest request) {
1041 return getPortal().getHost(request);
1042 }
1043
1044 public static String getHost(PortletRequest portletRequest) {
1045 return getPortal().getHost(portletRequest);
1046 }
1047
1048 public static HttpServletRequest getHttpServletRequest(
1049 PortletRequest portletRequest) {
1050
1051 return getPortal().getHttpServletRequest(portletRequest);
1052 }
1053
1054 public static HttpServletResponse getHttpServletResponse(
1055 PortletResponse portletResponse) {
1056
1057 return getPortal().getHttpServletResponse(portletResponse);
1058 }
1059
1060 public static String getI18nPathLanguageId(
1061 Locale locale, String defaultI18nPathLanguageId) {
1062
1063 return getPortal().getI18nPathLanguageId(
1064 locale, defaultI18nPathLanguageId);
1065 }
1066
1067 public static String getJournalArticleActualURL(
1068 long groupId, boolean privateLayout, String mainPath,
1069 String friendlyURL, Map<String, String[]> params,
1070 Map<String, Object> requestContext)
1071 throws PortalException {
1072
1073 return getPortal().getJournalArticleActualURL(
1074 groupId, privateLayout, mainPath, friendlyURL, params,
1075 requestContext);
1076 }
1077
1078 public static Layout getJournalArticleLayout(
1079 long groupId, boolean privateLayout, String friendlyURL)
1080 throws PortalException {
1081
1082 return getPortal().getJournalArticleLayout(
1083 groupId, privateLayout, friendlyURL);
1084 }
1085
1086 public static String getJsSafePortletId(String portletId) {
1087 return getPortal().getJsSafePortletId(portletId);
1088 }
1089
1090 public static String getLayoutActualURL(Layout layout) {
1091 return getPortal().getLayoutActualURL(layout);
1092 }
1093
1094 public static String getLayoutActualURL(Layout layout, String mainPath) {
1095 return getPortal().getLayoutActualURL(layout, mainPath);
1096 }
1097
1098 public static String getLayoutActualURL(
1099 long groupId, boolean privateLayout, String mainPath,
1100 String friendlyURL)
1101 throws PortalException {
1102
1103 return getPortal().getLayoutActualURL(
1104 groupId, privateLayout, mainPath, friendlyURL);
1105 }
1106
1107 public static String getLayoutActualURL(
1108 long groupId, boolean privateLayout, String mainPath,
1109 String friendlyURL, Map<String, String[]> params,
1110 Map<String, Object> requestContext)
1111 throws PortalException {
1112
1113 return getPortal().getLayoutActualURL(
1114 groupId, privateLayout, mainPath, friendlyURL, params,
1115 requestContext);
1116 }
1117
1118 public static String getLayoutFriendlyURL(
1119 Layout layout, ThemeDisplay themeDisplay)
1120 throws PortalException {
1121
1122 return getPortal().getLayoutFriendlyURL(layout, themeDisplay);
1123 }
1124
1125 public static String getLayoutFriendlyURL(
1126 Layout layout, ThemeDisplay themeDisplay, Locale locale)
1127 throws PortalException {
1128
1129 return getPortal().getLayoutFriendlyURL(layout, themeDisplay, locale);
1130 }
1131
1132 public static LayoutFriendlyURLComposite getLayoutFriendlyURLComposite(
1133 long groupId, boolean privateLayout, String friendlyURL,
1134 Map<String, String[]> params, Map<String, Object> requestContext)
1135 throws PortalException {
1136
1137 return getPortal().getLayoutFriendlyURLComposite(
1138 groupId, privateLayout, friendlyURL, params, requestContext);
1139 }
1140
1141 public static String getLayoutFullURL(
1142 Layout layout, ThemeDisplay themeDisplay)
1143 throws PortalException {
1144
1145 return getPortal().getLayoutFullURL(layout, themeDisplay);
1146 }
1147
1148 public static String getLayoutFullURL(
1149 Layout layout, ThemeDisplay themeDisplay, boolean doAsUser)
1150 throws PortalException {
1151
1152 return getPortal().getLayoutFullURL(layout, themeDisplay, doAsUser);
1153 }
1154
1155 public static String getLayoutFullURL(long groupId, String portletId)
1156 throws PortalException {
1157
1158 return getPortal().getLayoutFullURL(groupId, portletId);
1159 }
1160
1161 public static String getLayoutFullURL(
1162 long groupId, String portletId, boolean secure)
1163 throws PortalException {
1164
1165 return getPortal().getLayoutFullURL(groupId, portletId, secure);
1166 }
1167
1168 public static String getLayoutFullURL(ThemeDisplay themeDisplay)
1169 throws PortalException {
1170
1171 return getPortal().getLayoutFullURL(themeDisplay);
1172 }
1173
1174 public static String getLayoutRelativeURL(
1175 Layout layout, ThemeDisplay themeDisplay)
1176 throws PortalException {
1177
1178 return getPortal().getLayoutRelativeURL(layout, themeDisplay);
1179 }
1180
1181 public static String getLayoutRelativeURL(
1182 Layout layout, ThemeDisplay themeDisplay, boolean doAsUser)
1183 throws PortalException {
1184
1185 return getPortal().getLayoutRelativeURL(layout, themeDisplay, doAsUser);
1186 }
1187
1188 public static String getLayoutSetFriendlyURL(
1189 LayoutSet layoutSet, ThemeDisplay themeDisplay)
1190 throws PortalException {
1191
1192 return getPortal().getLayoutSetFriendlyURL(layoutSet, themeDisplay);
1193 }
1194
1195 public static String getLayoutTarget(Layout layout) {
1196 return getPortal().getLayoutTarget(layout);
1197 }
1198
1199 public static String getLayoutURL(Layout layout, ThemeDisplay themeDisplay)
1200 throws PortalException {
1201
1202 return getPortal().getLayoutURL(layout, themeDisplay);
1203 }
1204
1205 public static String getLayoutURL(
1206 Layout layout, ThemeDisplay themeDisplay, boolean doAsUser)
1207 throws PortalException {
1208
1209 return getPortal().getLayoutURL(layout, themeDisplay, doAsUser);
1210 }
1211
1212 public static String getLayoutURL(
1213 Layout layout, ThemeDisplay themeDisplay, Locale locale)
1214 throws PortalException {
1215
1216 return getPortal().getLayoutURL(layout, themeDisplay, locale);
1217 }
1218
1219 public static String getLayoutURL(ThemeDisplay themeDisplay)
1220 throws PortalException {
1221
1222 return getPortal().getLayoutURL(themeDisplay);
1223 }
1224
1225 public static LiferayPortletRequest getLiferayPortletRequest(
1226 PortletRequest portletRequest) {
1227
1228 return getPortal().getLiferayPortletRequest(portletRequest);
1229 }
1230
1231 public static LiferayPortletResponse getLiferayPortletResponse(
1232 PortletResponse portletResponse) {
1233
1234 return getPortal().getLiferayPortletResponse(portletResponse);
1235 }
1236
1237 public static Locale getLocale(HttpServletRequest request) {
1238 return getPortal().getLocale(request);
1239 }
1240
1241 public static Locale getLocale(
1242 HttpServletRequest request, HttpServletResponse response,
1243 boolean initialize) {
1244
1245 return getPortal().getLocale(request, response, initialize);
1246 }
1247
1248 public static Locale getLocale(PortletRequest portletRequest) {
1249 return getPortal().getLocale(portletRequest);
1250 }
1251
1252 public static String getLocalizedFriendlyURL(
1253 HttpServletRequest request, Layout layout, Locale locale,
1254 Locale originalLocale)
1255 throws Exception {
1256
1257 return getPortal().getLocalizedFriendlyURL(
1258 request, layout, locale, originalLocale);
1259 }
1260
1261 public static String getMailId(
1262 String mx, String popPortletPrefix, Object... ids) {
1263
1264 return getPortal().getMailId(mx, popPortletPrefix, ids);
1265 }
1266
1267
1271 @Deprecated
1272 public static BaseModel<?> getModel(ResourcePermission resourcePermission)
1273 throws PortalException {
1274
1275 return getPortal().getBaseModel(resourcePermission);
1276 }
1277
1278
1282 @Deprecated
1283 public static BaseModel<?> getModel(String modelName, String primKey)
1284 throws PortalException {
1285
1286 return getPortal().getBaseModel(modelName, primKey);
1287 }
1288
1289 public static String getNetvibesURL(
1290 Portlet portlet, ThemeDisplay themeDisplay)
1291 throws PortalException {
1292
1293 return getPortal().getNetvibesURL(portlet, themeDisplay);
1294 }
1295
1296 public static String getNewPortletTitle(
1297 String portletTitle, String oldScopeName, String newScopeName) {
1298
1299 return getPortal().getNewPortletTitle(
1300 portletTitle, oldScopeName, newScopeName);
1301 }
1302
1303 public static HttpServletRequest getOriginalServletRequest(
1304 HttpServletRequest request) {
1305
1306 return getPortal().getOriginalServletRequest(request);
1307 }
1308
1309
1312 @Deprecated
1313 public static long getParentGroupId(long scopeGroupId)
1314 throws PortalException {
1315
1316 return getPortal().getParentGroupId(scopeGroupId);
1317 }
1318
1319 public static String getPathContext() {
1320 return getPortal().getPathContext();
1321 }
1322
1323 public static String getPathContext(HttpServletRequest request) {
1324 return getPortal().getPathContext(request);
1325 }
1326
1327 public static String getPathContext(PortletRequest portletRequest) {
1328 return getPortal().getPathContext(portletRequest);
1329 }
1330
1331 public static String getPathContext(String contextPath) {
1332 return getPortal().getPathContext(contextPath);
1333 }
1334
1335 public static String getPathFriendlyURLPrivateGroup() {
1336 return getPortal().getPathFriendlyURLPrivateGroup();
1337 }
1338
1339 public static String getPathFriendlyURLPrivateUser() {
1340 return getPortal().getPathFriendlyURLPrivateUser();
1341 }
1342
1343 public static String getPathFriendlyURLPublic() {
1344 return getPortal().getPathFriendlyURLPublic();
1345 }
1346
1347 public static String getPathImage() {
1348 return getPortal().getPathImage();
1349 }
1350
1351 public static String getPathMain() {
1352 return getPortal().getPathMain();
1353 }
1354
1355 public static String getPathModule() {
1356 return getPortal().getPathModule();
1357 }
1358
1359 public static String getPathProxy() {
1360 return getPortal().getPathProxy();
1361 }
1362
1363 public static long getPlidFromFriendlyURL(
1364 long companyId, String friendlyURL) {
1365
1366 return getPortal().getPlidFromFriendlyURL(companyId, friendlyURL);
1367 }
1368
1369 public static long getPlidFromPortletId(
1370 long groupId, boolean privateLayout, String portletId)
1371 throws PortalException {
1372
1373 return getPortal().getPlidFromPortletId(
1374 groupId, privateLayout, portletId);
1375 }
1376
1377 public static long getPlidFromPortletId(long groupId, String portletId)
1378 throws PortalException {
1379
1380 return getPortal().getPlidFromPortletId(groupId, portletId);
1381 }
1382
1383 public static Portal getPortal() {
1384 PortalRuntimePermission.checkGetBeanProperty(PortalUtil.class);
1385
1386 return _portal;
1387 }
1388
1389 public static PortalInetSocketAddressEventListener[]
1390 getPortalInetSocketAddressEventListeners() {
1391
1392 return getPortal().getPortalInetSocketAddressEventListeners();
1393 }
1394
1395 public static String getPortalLibDir() {
1396 return getPortal().getPortalLibDir();
1397 }
1398
1399 public static InetAddress getPortalLocalInetAddress(boolean secure) {
1400 return getPortal().getPortalLocalInetAddress(secure);
1401 }
1402
1403 public static int getPortalLocalPort(boolean secure) {
1404 return getPortal().getPortalLocalPort(secure);
1405 }
1406
1407
1410 @Deprecated
1411 public static int getPortalPort() {
1412 return getPortal().getPortalPort();
1413 }
1414
1415
1419 @Deprecated
1420 public static int getPortalPort(boolean secure) {
1421 return getPortal().getPortalPort(secure);
1422 }
1423
1424 public static Properties getPortalProperties() {
1425 return getPortal().getPortalProperties();
1426 }
1427
1428 public static InetAddress getPortalServerInetAddress(boolean secure) {
1429 return getPortal().getPortalServerInetAddress(secure);
1430 }
1431
1432 public static int getPortalServerPort(boolean secure) {
1433 return getPortal().getPortalServerPort(secure);
1434 }
1435
1436 public static String getPortalURL(HttpServletRequest request) {
1437 return getPortal().getPortalURL(request);
1438 }
1439
1440 public static String getPortalURL(
1441 HttpServletRequest request, boolean secure) {
1442
1443 return getPortal().getPortalURL(request, secure);
1444 }
1445
1446 public static String getPortalURL(Layout layout, ThemeDisplay themeDisplay)
1447 throws PortalException {
1448
1449 return getPortal().getPortalURL(layout, themeDisplay);
1450 }
1451
1452 public static String getPortalURL(PortletRequest portletRequest) {
1453 return getPortal().getPortalURL(portletRequest);
1454 }
1455
1456 public static String getPortalURL(
1457 PortletRequest portletRequest, boolean secure) {
1458
1459 return getPortal().getPortalURL(portletRequest, secure);
1460 }
1461
1462 public static String getPortalURL(
1463 String serverName, int serverPort, boolean secure) {
1464
1465 return getPortal().getPortalURL(serverName, serverPort, secure);
1466 }
1467
1468 public static String getPortalURL(ThemeDisplay themeDisplay)
1469 throws PortalException {
1470
1471 return getPortal().getPortalURL(themeDisplay);
1472 }
1473
1474 public static String getPortalWebDir() {
1475 return getPortal().getPortalWebDir();
1476 }
1477
1478
1482 @Deprecated
1483 public static Set<String> getPortletAddDefaultResourceCheckWhitelist() {
1484 return getPortal().getPortletAddDefaultResourceCheckWhitelist();
1485 }
1486
1487
1491 @Deprecated
1492 public static Set<String>
1493 getPortletAddDefaultResourceCheckWhitelistActions() {
1494
1495 return getPortal().getPortletAddDefaultResourceCheckWhitelistActions();
1496 }
1497
1498
1502 @Deprecated
1503 public static List<BreadcrumbEntry> getPortletBreadcrumbList(
1504 HttpServletRequest request) {
1505
1506 return getPortal().getPortletBreadcrumbList(request);
1507 }
1508
1509
1514 @Deprecated
1515 public static List<BreadcrumbEntry> getPortletBreadcrumbs(
1516 HttpServletRequest request) {
1517
1518 return getPortal().getPortletBreadcrumbs(request);
1519 }
1520
1521 public static PortletConfig getPortletConfig(
1522 long companyId, String portletId, ServletContext servletContext)
1523 throws PortletException {
1524
1525 Portlet portlet = PortletLocalServiceUtil.getPortletById(
1526 companyId, portletId);
1527
1528 InvokerPortlet invokerPortlet = PortletInstanceFactoryUtil.create(
1529 portlet, servletContext);
1530
1531 return invokerPortlet.getPortletConfig();
1532 }
1533
1534 public static String getPortletDescription(
1535 Portlet portlet, ServletContext servletContext, Locale locale) {
1536
1537 return getPortal().getPortletDescription(
1538 portlet, servletContext, locale);
1539 }
1540
1541 public static String getPortletDescription(Portlet portlet, User user) {
1542 return getPortal().getPortletDescription(portlet, user);
1543 }
1544
1545 public static String getPortletDescription(
1546 String portletId, Locale locale) {
1547
1548 return getPortal().getPortletDescription(portletId, locale);
1549 }
1550
1551 public static String getPortletDescription(
1552 String portletId, String languageId) {
1553
1554 return getPortal().getPortletDescription(portletId, languageId);
1555 }
1556
1557 public static String getPortletDescription(String portletId, User user) {
1558 return getPortal().getPortletDescription(portletId, user);
1559 }
1560
1561 public static String getPortletId(HttpServletRequest request) {
1562 return getPortal().getPortletId(request);
1563 }
1564
1565 public static String getPortletId(PortletRequest portletRequest) {
1566 return getPortal().getPortletId(portletRequest);
1567 }
1568
1569 public static String getPortletLongTitle(Portlet portlet, Locale locale) {
1570 return getPortal().getPortletLongTitle(portlet, locale);
1571 }
1572
1573 public static String getPortletLongTitle(
1574 Portlet portlet, ServletContext servletContext, Locale locale) {
1575
1576 return getPortal().getPortletLongTitle(portlet, servletContext, locale);
1577 }
1578
1579 public static String getPortletLongTitle(
1580 Portlet portlet, String languageId) {
1581
1582 return getPortal().getPortletLongTitle(portlet, languageId);
1583 }
1584
1585 public static String getPortletLongTitle(Portlet portlet, User user) {
1586 return getPortal().getPortletLongTitle(portlet, user);
1587 }
1588
1589 public static String getPortletLongTitle(String portletId, Locale locale) {
1590 return getPortal().getPortletLongTitle(portletId, locale);
1591 }
1592
1593 public static String getPortletLongTitle(
1594 String portletId, String languageId) {
1595
1596 return getPortal().getPortletLongTitle(portletId, languageId);
1597 }
1598
1599 public static String getPortletLongTitle(String portletId, User user) {
1600 return getPortal().getPortletLongTitle(portletId, user);
1601 }
1602
1603 public static String getPortletNamespace(String portletId) {
1604 return getPortal().getPortletNamespace(portletId);
1605 }
1606
1607 public static String getPortletTitle(Portlet portlet, Locale locale) {
1608 return getPortal().getPortletTitle(portlet, locale);
1609 }
1610
1611 public static String getPortletTitle(
1612 Portlet portlet, ServletContext servletContext, Locale locale) {
1613
1614 return getPortal().getPortletTitle(portlet, servletContext, locale);
1615 }
1616
1617 public static String getPortletTitle(Portlet portlet, String languageId) {
1618 return getPortal().getPortletTitle(portlet, languageId);
1619 }
1620
1621 public static String getPortletTitle(Portlet portlet, User user) {
1622 return getPortal().getPortletTitle(portlet, user);
1623 }
1624
1625 public static String getPortletTitle(PortletRequest portletRequest) {
1626 return getPortal().getPortletTitle(portletRequest);
1627 }
1628
1629 public static String getPortletTitle(PortletResponse portletResponse) {
1630 return getPortal().getPortletTitle(portletResponse);
1631 }
1632
1633 public static String getPortletTitle(String portletId, Locale locale) {
1634 return getPortal().getPortletTitle(portletId, locale);
1635 }
1636
1637 public static String getPortletTitle(String portletId, String languageId) {
1638 return getPortal().getPortletTitle(portletId, languageId);
1639 }
1640
1641 public static String getPortletTitle(String portletId, User user) {
1642 return getPortal().getPortletTitle(portletId, user);
1643 }
1644
1645 public static String getPortletXmlFileName() {
1646 return getPortal().getPortletXmlFileName();
1647 }
1648
1649 public static PortletPreferences getPreferences(
1650 HttpServletRequest request) {
1651
1652 return getPortal().getPreferences(request);
1653 }
1654
1655 public static PreferencesValidator getPreferencesValidator(
1656 Portlet portlet) {
1657
1658 return getPortal().getPreferencesValidator(portlet);
1659 }
1660
1661 public static String getRelativeHomeURL(HttpServletRequest request)
1662 throws PortalException {
1663
1664 return getPortal().getRelativeHomeURL(request);
1665 }
1666
1667 public static ResourceBundle getResourceBundle(Locale locale) {
1668 return getPortal().getResourceBundle(locale);
1669 }
1670
1671 public static long getScopeGroupId(HttpServletRequest request)
1672 throws PortalException {
1673
1674 return getPortal().getScopeGroupId(request);
1675 }
1676
1677 public static long getScopeGroupId(
1678 HttpServletRequest request, String portletId)
1679 throws PortalException {
1680
1681 return getPortal().getScopeGroupId(request, portletId);
1682 }
1683
1684 public static long getScopeGroupId(
1685 HttpServletRequest request, String portletId,
1686 boolean checkStagingGroup)
1687 throws PortalException {
1688
1689 return getPortal().getScopeGroupId(
1690 request, portletId, checkStagingGroup);
1691 }
1692
1693 public static long getScopeGroupId(Layout layout) {
1694 return getPortal().getScopeGroupId(layout);
1695 }
1696
1697 public static long getScopeGroupId(Layout layout, String portletId) {
1698 return getPortal().getScopeGroupId(layout, portletId);
1699 }
1700
1701 public static long getScopeGroupId(long plid) {
1702 return getPortal().getScopeGroupId(plid);
1703 }
1704
1705 public static long getScopeGroupId(PortletRequest portletRequest)
1706 throws PortalException {
1707
1708 return getPortal().getScopeGroupId(portletRequest);
1709 }
1710
1711 public static User getSelectedUser(HttpServletRequest request)
1712 throws PortalException {
1713
1714 return getPortal().getSelectedUser(request);
1715 }
1716
1717 public static User getSelectedUser(
1718 HttpServletRequest request, boolean checkPermission)
1719 throws PortalException {
1720
1721 return getPortal().getSelectedUser(request, checkPermission);
1722 }
1723
1724 public static User getSelectedUser(PortletRequest portletRequest)
1725 throws PortalException {
1726
1727 return getPortal().getSelectedUser(portletRequest);
1728 }
1729
1730 public static User getSelectedUser(
1731 PortletRequest portletRequest, boolean checkPermission)
1732 throws PortalException {
1733
1734 return getPortal().getSelectedUser(portletRequest, checkPermission);
1735 }
1736
1737 public static String getServletContextName() {
1738 return getPortal().getServletContextName();
1739 }
1740
1741 public static long[] getSharedContentSiteGroupIds(
1742 long companyId, long groupId, long userId)
1743 throws PortalException {
1744
1745 return getPortal().getSharedContentSiteGroupIds(
1746 companyId, groupId, userId);
1747 }
1748
1749 public static Map<String, List<Portlet>> getSiteAdministrationCategoriesMap(
1750 HttpServletRequest request) {
1751
1752 return getPortal().getSiteAdministrationCategoriesMap(request);
1753 }
1754
1755 public static PortletURL getSiteAdministrationURL(
1756 HttpServletRequest request, ThemeDisplay themeDisplay) {
1757
1758 return getPortal().getSiteAdministrationURL(request, themeDisplay);
1759 }
1760
1761 public static PortletURL getSiteAdministrationURL(
1762 HttpServletRequest request, ThemeDisplay themeDisplay,
1763 String portletName) {
1764
1765 return getPortal().getSiteAdministrationURL(
1766 request, themeDisplay, portletName);
1767 }
1768
1769 public static PortletURL getSiteAdministrationURL(
1770 PortletResponse portletResponse, ThemeDisplay themeDisplay) {
1771
1772 return getPortal().getSiteAdministrationURL(
1773 portletResponse, themeDisplay);
1774 }
1775
1776 public static PortletURL getSiteAdministrationURL(
1777 PortletResponse portletResponse, ThemeDisplay themeDisplay,
1778 String portletName) {
1779
1780 return getPortal().getSiteAdministrationURL(
1781 portletResponse, themeDisplay, portletName);
1782 }
1783
1784
1788 @Deprecated
1789 public static long[] getSiteAndCompanyGroupIds(long groupId)
1790 throws PortalException {
1791
1792 return getPortal().getSiteAndCompanyGroupIds(groupId);
1793 }
1794
1795
1799 @Deprecated
1800 public static long[] getSiteAndCompanyGroupIds(ThemeDisplay themeDisplay)
1801 throws PortalException {
1802
1803 return getPortal().getSiteAndCompanyGroupIds(themeDisplay);
1804 }
1805
1806 public static Locale getSiteDefaultLocale(long groupId)
1807 throws PortalException {
1808
1809 return getPortal().getSiteDefaultLocale(groupId);
1810 }
1811
1812 public static long getSiteGroupId(long scopeGroupId)
1813 throws PortalException {
1814
1815 return getPortal().getSiteGroupId(scopeGroupId);
1816 }
1817
1818 public static String getSiteLoginURL(ThemeDisplay themeDisplay)
1819 throws PortalException {
1820
1821 return getPortal().getSiteLoginURL(themeDisplay);
1822 }
1823
1824 public static String getStaticResourceURL(
1825 HttpServletRequest request, String uri) {
1826
1827 return getPortal().getStaticResourceURL(request, uri);
1828 }
1829
1830 public static String getStaticResourceURL(
1831 HttpServletRequest request, String uri, long timestamp) {
1832
1833 return getPortal().getStaticResourceURL(request, uri, timestamp);
1834 }
1835
1836 public static String getStaticResourceURL(
1837 HttpServletRequest request, String uri, String queryString) {
1838
1839 return getPortal().getStaticResourceURL(request, uri, queryString);
1840 }
1841
1842 public static String getStaticResourceURL(
1843 HttpServletRequest request, String uri, String queryString,
1844 long timestamp) {
1845
1846 return getPortal().getStaticResourceURL(
1847 request, uri, queryString, timestamp);
1848 }
1849
1850 public static String getStrutsAction(HttpServletRequest request) {
1851 return getPortal().getStrutsAction(request);
1852 }
1853
1854 public static String[] getSystemGroups() {
1855 return getPortal().getSystemGroups();
1856 }
1857
1858 public static String[] getSystemOrganizationRoles() {
1859 return getPortal().getSystemOrganizationRoles();
1860 }
1861
1862 public static String[] getSystemRoles() {
1863 return getPortal().getSystemRoles();
1864 }
1865
1866 public static String[] getSystemSiteRoles() {
1867 return getPortal().getSystemSiteRoles();
1868 }
1869
1870 public static String getUniqueElementId(
1871 HttpServletRequest request, String namespace, String id) {
1872
1873 return getPortal().getUniqueElementId(request, namespace, id);
1874 }
1875
1876 public static String getUniqueElementId(
1877 PortletRequest request, String namespace, String id) {
1878
1879 return getPortal().getUniqueElementId(request, namespace, id);
1880 }
1881
1882 public static UploadPortletRequest getUploadPortletRequest(
1883 PortletRequest portletRequest) {
1884
1885 return getPortal().getUploadPortletRequest(portletRequest);
1886 }
1887
1888 public static UploadServletRequest getUploadServletRequest(
1889 HttpServletRequest request) {
1890
1891 return getPortal().getUploadServletRequest(request);
1892 }
1893
1894 public static Date getUptime() {
1895 return getPortal().getUptime();
1896 }
1897
1898 public static String getURLWithSessionId(String url, String sessionId) {
1899 return getPortal().getURLWithSessionId(url, sessionId);
1900 }
1901
1902 public static User getUser(HttpServletRequest request)
1903 throws PortalException {
1904
1905 return getPortal().getUser(request);
1906 }
1907
1908 public static User getUser(PortletRequest portletRequest)
1909 throws PortalException {
1910
1911 return getPortal().getUser(portletRequest);
1912 }
1913
1914 public static String getUserEmailAddress(long userId) {
1915 return getPortal().getUserEmailAddress(userId);
1916 }
1917
1918 public static long getUserId(HttpServletRequest request) {
1919 return getPortal().getUserId(request);
1920 }
1921
1922 public static long getUserId(PortletRequest portletRequest) {
1923 return getPortal().getUserId(portletRequest);
1924 }
1925
1926 public static String getUserName(BaseModel<?> baseModel) {
1927 return getPortal().getUserName(baseModel);
1928 }
1929
1930 public static String getUserName(long userId, String defaultUserName) {
1931 return getPortal().getUserName(userId, defaultUserName);
1932 }
1933
1934 public static String getUserName(
1935 long userId, String defaultUserName, HttpServletRequest request) {
1936
1937 return getPortal().getUserName(userId, defaultUserName, request);
1938 }
1939
1940 public static String getUserName(
1941 long userId, String defaultUserName, String userAttribute) {
1942
1943 return getPortal().getUserName(userId, defaultUserName, userAttribute);
1944 }
1945
1946 public static String getUserName(
1947 long userId, String defaultUserName, String userAttribute,
1948 HttpServletRequest request) {
1949
1950 return getPortal().getUserName(
1951 userId, defaultUserName, userAttribute, request);
1952 }
1953
1954 public static String getUserPassword(HttpServletRequest request) {
1955 return getPortal().getUserPassword(request);
1956 }
1957
1958 public static String getUserPassword(HttpSession session) {
1959 return getPortal().getUserPassword(session);
1960 }
1961
1962 public static String getUserPassword(PortletRequest portletRequest) {
1963 return getPortal().getUserPassword(portletRequest);
1964 }
1965
1966
1969 @Deprecated
1970 public static String getUserValue(
1971 long userId, String param, String defaultValue) {
1972
1973 return getPortal().getUserValue(userId, param, defaultValue);
1974 }
1975
1976 public static String getValidPortalDomain(long companyId, String domain) {
1977 return getPortal().getValidPortalDomain(companyId, domain);
1978 }
1979
1980 public static long getValidUserId(long companyId, long userId)
1981 throws PortalException {
1982
1983 return getPortal().getValidUserId(companyId, userId);
1984 }
1985
1986 public static String getVirtualHostname(LayoutSet layoutSet) {
1987 return getPortal().getVirtualHostname(layoutSet);
1988 }
1989
1990 public static String getVirtualLayoutActualURL(
1991 long groupId, boolean privateLayout, String mainPath,
1992 String friendlyURL, Map<String, String[]> params,
1993 Map<String, Object> requestContext)
1994 throws PortalException {
1995
1996 return getPortal().getVirtualLayoutActualURL(
1997 groupId, privateLayout, mainPath, friendlyURL, params,
1998 requestContext);
1999 }
2000
2001 public static LayoutFriendlyURLComposite
2002 getVirtualLayoutFriendlyURLComposite(
2003 boolean privateLayout, String friendlyURL,
2004 Map<String, String[]> params, Map<String, Object> requestContext)
2005 throws PortalException {
2006
2007 return getPortal().getVirtualLayoutFriendlyURLComposite(
2008 privateLayout, friendlyURL, params, requestContext);
2009 }
2010
2011 public static String getWidgetURL(
2012 Portlet portlet, ThemeDisplay themeDisplay)
2013 throws PortalException {
2014
2015 return getPortal().getWidgetURL(portlet, themeDisplay);
2016 }
2017
2018 public static void initCustomSQL() {
2019 getPortal().initCustomSQL();
2020 }
2021
2022 public static User initUser(HttpServletRequest request) throws Exception {
2023 return getPortal().initUser(request);
2024 }
2025
2026 public static void invokeTaglibDiscussion(
2027 PortletConfig portletConfig, ActionRequest actionRequest,
2028 ActionResponse actionResponse)
2029 throws Exception {
2030
2031 getPortal().invokeTaglibDiscussion(
2032 portletConfig, actionRequest, actionResponse);
2033 }
2034
2035
2038 @Deprecated
2039 public static boolean isAllowAddPortletDefaultResource(
2040 HttpServletRequest request, Portlet portlet)
2041 throws PortalException {
2042
2043 return getPortal().isAllowAddPortletDefaultResource(request, portlet);
2044 }
2045
2046 public static boolean isCDNDynamicResourcesEnabled(
2047 HttpServletRequest request)
2048 throws PortalException {
2049
2050 return getPortal().isCDNDynamicResourcesEnabled(request);
2051 }
2052
2053 public static boolean isCDNDynamicResourcesEnabled(long companyId) {
2054 return getPortal().isCDNDynamicResourcesEnabled(companyId);
2055 }
2056
2057
2060 @Deprecated
2061 public static boolean isCommunityAdmin(User user, long groupId)
2062 throws Exception {
2063
2064 return getPortal().isCommunityAdmin(user, groupId);
2065 }
2066
2067
2070 @Deprecated
2071 public static boolean isCommunityOwner(User user, long groupId)
2072 throws Exception {
2073
2074 return getPortal().isCommunityOwner(user, groupId);
2075 }
2076
2077 public static boolean isCompanyAdmin(User user) throws Exception {
2078 return getPortal().isCompanyAdmin(user);
2079 }
2080
2081 public static boolean isCompanyControlPanelPortlet(
2082 String portletId, String category, ThemeDisplay themeDisplay)
2083 throws PortalException {
2084
2085 return getPortal().isCompanyControlPanelPortlet(
2086 portletId, category, themeDisplay);
2087 }
2088
2089 public static boolean isCompanyControlPanelPortlet(
2090 String portletId, ThemeDisplay themeDisplay)
2091 throws PortalException {
2092
2093 return getPortal().isCompanyControlPanelPortlet(
2094 portletId, themeDisplay);
2095 }
2096
2097 public static boolean isCompanyControlPanelVisible(
2098 ThemeDisplay themeDisplay)
2099 throws PortalException {
2100
2101 return getPortal().isCompanyControlPanelVisible(themeDisplay);
2102 }
2103
2104 public static boolean isControlPanelPortlet(
2105 String portletId, String category, ThemeDisplay themeDisplay) {
2106
2107 return getPortal().isControlPanelPortlet(
2108 portletId, category, themeDisplay);
2109 }
2110
2111 public static boolean isControlPanelPortlet(
2112 String portletId, ThemeDisplay themeDisplay) {
2113
2114 return getPortal().isControlPanelPortlet(portletId, themeDisplay);
2115 }
2116
2117 public static boolean isGroupAdmin(User user, long groupId)
2118 throws Exception {
2119
2120 return getPortal().isGroupAdmin(user, groupId);
2121 }
2122
2123 public static boolean isGroupFriendlyURL(
2124 String fullURL, String groupFriendlyURL, String layoutFriendlyURL) {
2125
2126 return getPortal().isGroupFriendlyURL(
2127 fullURL, groupFriendlyURL, layoutFriendlyURL);
2128 }
2129
2130 public static boolean isGroupOwner(User user, long groupId)
2131 throws Exception {
2132
2133 return getPortal().isGroupOwner(user, groupId);
2134 }
2135
2136 public static boolean isLayoutDescendant(Layout layout, long layoutId)
2137 throws PortalException {
2138
2139 return getPortal().isLayoutDescendant(layout, layoutId);
2140 }
2141
2142 public static boolean isLayoutSitemapable(Layout layout) {
2143 return getPortal().isLayoutSitemapable(layout);
2144 }
2145
2146 public static boolean isLoginRedirectRequired(HttpServletRequest request) {
2147 return getPortal().isLoginRedirectRequired(request);
2148 }
2149
2150 public static boolean isMethodGet(PortletRequest portletRequest) {
2151 return getPortal().isMethodGet(portletRequest);
2152 }
2153
2154 public static boolean isMethodPost(PortletRequest portletRequest) {
2155 return getPortal().isMethodPost(portletRequest);
2156 }
2157
2158 public static boolean isMultipartRequest(HttpServletRequest request) {
2159 return getPortal().isMultipartRequest(request);
2160 }
2161
2162 public static boolean isOmniadmin(long userId) {
2163 return getPortal().isOmniadmin(userId);
2164 }
2165
2166 public static boolean isOmniadmin(User user) {
2167 return getPortal().isOmniadmin(user);
2168 }
2169
2170 public static boolean isReservedParameter(String name) {
2171 return getPortal().isReservedParameter(name);
2172 }
2173
2174 public static boolean isRightToLeft(HttpServletRequest request) {
2175 return getPortal().isRightToLeft(request);
2176 }
2177
2178 public static boolean isRSSFeedsEnabled() {
2179 return getPortal().isRSSFeedsEnabled();
2180 }
2181
2182 public static boolean isSecure(HttpServletRequest request) {
2183 return getPortal().isSecure(request);
2184 }
2185
2186 public static boolean isSystemGroup(String groupName) {
2187 return getPortal().isSystemGroup(groupName);
2188 }
2189
2190 public static boolean isSystemRole(String roleName) {
2191 return getPortal().isSystemRole(roleName);
2192 }
2193
2194 public static boolean isUpdateAvailable() {
2195 return getPortal().isUpdateAvailable();
2196 }
2197
2198 public static boolean isValidResourceId(String resourceId) {
2199 return getPortal().isValidResourceId(resourceId);
2200 }
2201
2202 public static boolean removePortalEventListener(
2203 PortalInetSocketAddressEventListener
2204 portalInetSocketAddressEventListener) {
2205
2206 return getPortal().removePortalInetSocketAddressEventListener(
2207 portalInetSocketAddressEventListener);
2208 }
2209
2210 public static void resetCDNHosts() {
2211 getPortal().resetCDNHosts();
2212 }
2213
2214
2218 @Deprecated
2219 public static Set<String> resetPortletAddDefaultResourceCheckWhitelist() {
2220 return getPortal().resetPortletAddDefaultResourceCheckWhitelist();
2221 }
2222
2223
2227 @Deprecated
2228 public static Set<String>
2229 resetPortletAddDefaultResourceCheckWhitelistActions() {
2230
2231 return getPortal().
2232 resetPortletAddDefaultResourceCheckWhitelistActions();
2233 }
2234
2235 public static String resetPortletParameters(String url, String portletId) {
2236 return getPortal().resetPortletParameters(url, portletId);
2237 }
2238
2239
2242 @Deprecated
2243 public static void runSQL(String sql) throws IOException, SQLException {
2244 DBFactoryUtil.getDB().runSQL(sql);
2245 }
2246
2247 public static void sendError(
2248 Exception e, ActionRequest actionRequest,
2249 ActionResponse actionResponse)
2250 throws IOException {
2251
2252 getPortal().sendError(e, actionRequest, actionResponse);
2253 }
2254
2255 public static void sendError(
2256 Exception e, HttpServletRequest request,
2257 HttpServletResponse response)
2258 throws IOException, ServletException {
2259
2260 getPortal().sendError(e, request, response);
2261 }
2262
2263 public static void sendError(
2264 int status, Exception e, ActionRequest actionRequest,
2265 ActionResponse actionResponse)
2266 throws IOException {
2267
2268 getPortal().sendError(status, e, actionRequest, actionResponse);
2269 }
2270
2271 public static void sendError(
2272 int status, Exception e, HttpServletRequest request,
2273 HttpServletResponse response)
2274 throws IOException, ServletException {
2275
2276 getPortal().sendError(status, e, request, response);
2277 }
2278
2279 public static void sendRSSFeedsDisabledError(
2280 HttpServletRequest request, HttpServletResponse response)
2281 throws IOException, ServletException {
2282
2283 getPortal().sendRSSFeedsDisabledError(request, response);
2284 }
2285
2286 public static void sendRSSFeedsDisabledError(
2287 PortletRequest portletRequest, PortletResponse portletResponse)
2288 throws IOException, ServletException {
2289
2290 getPortal().sendRSSFeedsDisabledError(portletRequest, portletResponse);
2291 }
2292
2293
2297 public static void setPageDescription(
2298 String description, HttpServletRequest request) {
2299
2300 getPortal().setPageDescription(description, request);
2301 }
2302
2303
2306 public static void setPageKeywords(
2307 String keywords, HttpServletRequest request) {
2308
2309 getPortal().setPageKeywords(keywords, request);
2310 }
2311
2312
2315 public static void setPageSubtitle(
2316 String subtitle, HttpServletRequest request) {
2317
2318 getPortal().setPageSubtitle(subtitle, request);
2319 }
2320
2321
2325 public static void setPageTitle(String title, HttpServletRequest request) {
2326 getPortal().setPageTitle(title, request);
2327 }
2328
2329 public static void setPortalInetSocketAddresses(
2330 HttpServletRequest request) {
2331
2332 getPortal().setPortalInetSocketAddresses(request);
2333 }
2334
2335
2341 @Deprecated
2342 public static void setPortalPort(HttpServletRequest request) {
2343 getPortal().setPortalPort(request);
2344 }
2345
2346 public static void storePreferences(PortletPreferences portletPreferences)
2347 throws IOException, ValidatorException {
2348
2349 getPortal().storePreferences(portletPreferences);
2350 }
2351
2352 public static String[] stripURLAnchor(String url, String separator) {
2353 return getPortal().stripURLAnchor(url, separator);
2354 }
2355
2356 public static String transformCustomSQL(String sql) {
2357 return getPortal().transformCustomSQL(sql);
2358 }
2359
2360 public static String transformSQL(String sql) {
2361 return getPortal().transformSQL(sql);
2362 }
2363
2364 public static void updateImageId(
2365 BaseModel<?> baseModel, boolean image, byte[] bytes,
2366 String fieldName, long maxSize, int maxHeight, int maxWidth)
2367 throws PortalException {
2368
2369 getPortal().updateImageId(
2370 baseModel, image, bytes, fieldName, maxSize, maxHeight, maxWidth);
2371 }
2372
2373 public static PortletMode updatePortletMode(
2374 String portletId, User user, Layout layout, PortletMode portletMode,
2375 HttpServletRequest request) {
2376
2377 return getPortal().updatePortletMode(
2378 portletId, user, layout, portletMode, request);
2379 }
2380
2381 public static String updateRedirect(
2382 String redirect, String oldPath, String newPath) {
2383
2384 return getPortal().updateRedirect(redirect, oldPath, newPath);
2385 }
2386
2387 public static WindowState updateWindowState(
2388 String portletId, User user, Layout layout, WindowState windowState,
2389 HttpServletRequest request) {
2390
2391 return getPortal().updateWindowState(
2392 portletId, user, layout, windowState, request);
2393 }
2394
2395
2400 @Deprecated
2401 public void removePortalPortEventListener(
2402 PortalPortEventListener portalPortEventListener) {
2403
2404 getPortal().removePortalPortEventListener(portalPortEventListener);
2405 }
2406
2407 public void setPortal(Portal portal) {
2408 PortalRuntimePermission.checkSetBeanProperty(getClass());
2409
2410 _portal = portal;
2411 }
2412
2413 private static Portal _portal;
2414
2415 }