boolean showInfoBar = attrs.getValue(MappedAttributes.SHOW_INFO_BAR, false);
boolean showMode = attrs.getValue(MappedAttributes.SHOW_MODE, false);
boolean showWindowState = attrs.getValue(MappedAttributes.SHOW_WINDOW_STATE, false);
String theme = attrs.getValue(MappedAttributes.THEME, null);
Described described = srcContainer.adapt(Described.class);
String id = attrs.getValue(MappedAttributes.ID, null);
String icon = attrs.getValue(MappedAttributes.ICON, null);
String width = attrs.getValue(MappedAttributes.WIDTH, null);
String height = attrs.getValue(MappedAttributes.HEIGHT, null);
//
List<String> a = Collections.singletonList(UserACL.EVERYONE);
if (srcContainer.isAdapted(ProtectedResource.class)) {
ProtectedResource pr = srcContainer.adapt(ProtectedResource.class);
a = pr.getAccessPermissions();
}
//
mo = new ApplicationData<Portlet>(srcContainer.getObjectId(), component.getName(), ApplicationType.PORTLET,
state, id, described.getName(), icon, described.getDescription(), showInfoBar, showWindowState,
showMode, theme, width, height, Collections.<String, String> emptyMap(), a);
} else {
List<ComponentData> dstChildren = loadChildren(srcContainer);
mo = load(srcContainer, dstChildren);
}