Package org.jahia.params

Examples of org.jahia.params.ParamBean


        String op = request.getParameter("do");
        if (op == null)
            op = "";
        final String operation = op;

        ParamBean jParams = initAdminJahiaData(request, response, session);
        final JahiaUser user = jParams.getUser();
        final JahiaSite site = jParams.getSite();

        try {
                Boolean accessGranted = (Boolean) session.getAttribute(CLASS_NAME + "accessGranted");
                if (accessGranted == null) {
                    accessGranted = Boolean.FALSE;
View Full Code Here


    public static void initMenu(HttpServletRequest request, JahiaUser user) {
        JahiaData jData = (JahiaData) request
                .getAttribute("org.jahia.data.JahiaData");
        if (jData != null) {
            ParamBean ctx = (ParamBean) jData.getProcessingContext();

            AdministrationModulesRegistry administrationModulesRegistry = (AdministrationModulesRegistry) SpringContextSingleton
                    .getInstance().getContext().getBean(
                            "administrationModulesRegistry");
            ctx.setAttribute("administrationServerModules", getMenuItems(
                    administrationModulesRegistry.getServerModules(), ctx, user));
            ctx.setAttribute("administrationSiteModules", getMenuItems(
                    administrationModulesRegistry.getSiteModules(), ctx, user));
        }
    }
View Full Code Here

            public String execute(String previousOut, RenderContext renderContext, Resource resource, RenderChain chain)
                    throws Exception {
                return s;
            }
        });
        ParamBean ctx = (ParamBean) Jahia.getThreadParamBean();
        RenderContext renderCtx = new RenderContext(ctx.getRequest(), ctx.getResponse(), ctx.getUser());       
       
        String result = chain.doFilter(renderCtx, null);

        assertFalse("Email found in result : "+result, mailPattern.matcher(result).find());
    }
View Full Code Here

    @BeforeClass
    public static void oneTimeSetUp() throws Exception {
        JahiaSite site = TestHelper.createSite(TESTSITE_NAME, Sets.newHashSet("en", "fr"), null, false);

        ParamBean paramBean = (ParamBean) Jahia.getThreadParamBean();

        paramBean.getSession(true).setAttribute(ParamBean.SESSION_SITE, site);

        JahiaData jData = new JahiaData(paramBean, false);
        paramBean.setAttribute(JahiaData.JAHIA_DATA, jData);

        JCRSessionWrapper session = JCRSessionFactory.getInstance()
                .getCurrentUserSession(null, Locale.ENGLISH);
        JCRNodeWrapper siteNode = session.getNode(SITECONTENT_ROOT_NODE);
View Full Code Here

//    }

    private List<String> getBaseUrls(String workspace, String sitePath) {
        List<String> urls = new ArrayList<String>();
        try {
            ParamBean ctx = (ParamBean) Jahia.getThreadParamBean();
            JCRSessionWrapper session = JCRSessionFactory.getInstance().getCurrentUserSession(workspace,
                    LanguageCodeConverters.languageCodeToLocale(DEFAULT_LANGUAGE));

            // generate seedlist
            RenderContext renderCtx = new RenderContext(ctx.getRequest(), ctx.getResponse(), ctx.getUser());
                       
            JCRNodeWrapper homeNode = null;
            try {
                homeNode = session.getRootNode().getNode(sitePath + "/home");
            } catch (PathNotFoundException e) {
View Full Code Here

TOP

Related Classes of org.jahia.params.ParamBean

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.