TurbineRunDataInternal rundata = (TurbineRunDataInternal) getTurbineRunData(request);
String target = assertNotNull(rundata.getTarget(), "Target was not specified");
// ����ض����־��������ض�������Ҫ��ҳ�������
if (!rundata.isRedirected()) {
Context context = rundata.getContext();
renderTemplate(getScreenTemplate(target), context, rundata);
// layout�ɱ����á�
if (rundata.isLayoutEnabled()) {
String layoutTemplateOverride = rundata.getLayoutTemplateOverride();
if (layoutTemplateOverride != null) {
target = layoutTemplateOverride;
}
String layoutTemplate = getLayoutTemplate(target);
if (templateService.exists(layoutTemplate)) {
String screenContent = defaultIfNull(bufferedRequestContext.popCharBuffer(), EMPTY_STRING);
context.put(SCREEN_PLACEHOLDER_KEY, screenContent);
renderTemplate(layoutTemplate, context, rundata);
}
}
}