Q:

How to get Liferay site name from inside Portlet class?

I can get the current Liferay site name from JSP:
<%= themeDisplay.getLayout().getGroup().getName() %>

It gives for instance "Guest".  
QUESTION: How to get the same from the Java Portlet class?
The closest I have found are the PortalUtil.getLayoutURL methods but I don't want an URL as the site name from the URL is all lowercase and potentially different from the real site name.

A:

Or simply:
ThemeDisplay themeDisplay = (ThemeDisplay) renderRequest
            .getAttribute(WebKeys.THEME_DISPLAY);
themeDisplay.getScopeGroup().getName();

