public static void withPageFiltered(String page, ScriptSessionFilter filter, Runnable task)
{
ServerContext serverContext = ServerContextFactory.get();
ScriptSessionFilter pageFilter = new PageScriptSessionFilter(serverContext, page);
ScriptSessionFilter realFilter = new AndScriptSessionFilter(pageFilter, filter);
TaskDispatcher taskDispatcher = TaskDispatcherFactory.get(serverContext);
taskDispatcher.dispatchTask(realFilter, task);
}