public static void updatePreferences(
     com.liferay.portal.ejb.PortletPreferencesPK pk,
     com.liferay.portlet.PortletPreferencesImpl prefs)
     throws com.liferay.portal.PortalException, com.liferay.portal.SystemException {
   try {
     PortletPreferencesManager portletPreferencesManager =
         PortletPreferencesManagerFactory.getManager();
     portletPreferencesManager.updatePreferences(pk, prefs);
   } catch (com.liferay.portal.PortalException pe) {
     throw pe;
   } catch (com.liferay.portal.SystemException se) {
     throw se;
   } catch (Exception e) {
     throw new com.liferay.portal.SystemException(e);
   }
 }
  public static com.dotcms.repackage.portlet.javax.portlet.PortletPreferences getPreferences(
      java.lang.String companyId, com.liferay.portal.ejb.PortletPreferencesPK pk)
      throws com.liferay.portal.PortalException, com.liferay.portal.SystemException {
    try {
      PortletPreferencesManager portletPreferencesManager =
          PortletPreferencesManagerFactory.getManager();

      return portletPreferencesManager.getPreferences(companyId, pk);
    } catch (com.liferay.portal.PortalException pe) {
      throw pe;
    } catch (com.liferay.portal.SystemException se) {
      throw se;
    } catch (Exception e) {
      throw new com.liferay.portal.SystemException(e);
    }
  }