* @throws DotRuntimeException
* @throws PortalException
*/
public List<Map<String, Object>> getAllAvailablePortletInfoList() throws SystemException, LanguageException, DotRuntimeException, PortalException {
PortletAPI portletAPI = APILocator.getPortletAPI();
UserWebAPI uWebAPI = WebAPILocator.getUserWebAPI();
WebContext ctx = WebContextFactory.get();
HttpServletRequest request = ctx.getHttpServletRequest();
List<Map<String, Object>> listOfPortletsInfo = new ArrayList<Map<String,Object>>();
List<Portlet> portlets = portletAPI.findAllPortlets();
for(Portlet p: portlets) {
if(portletAPI.canAddPortletToLayout(p)) {
Map<String, Object> portletMap = new HashMap<String, Object>();
String portletTitle = LanguageUtil.get(uWebAPI.getLoggedInUser(request),"com.dotcms.repackage.javax.portlet.title." + p.getPortletId());
portletMap.put("title", portletTitle);
portletMap.put("id", p.getPortletId());
listOfPortletsInfo.add(portletMap);