Package org.apache.jetspeed.search

Examples of org.apache.jetspeed.search.SearchEngine


       
    }
   
    protected void updateSearchEngine(boolean remove, PortletApplication pa)
    {
        SearchEngine searchEngine = (SearchEngine) Jetspeed.getComponentManager().getComponent("org.apache.jetspeed.search.SearchEngine");
        if (searchEngine != null)
        {
            if (remove)
            {
                searchEngine.remove(pa);
                searchEngine.remove(pa.getPortlets());
            }
            else
            {
                searchEngine.add(pa);
                searchEngine.add(pa.getPortlets());
            }
        }
    }
View Full Code Here


            {
                FeedbackPanel feed = (FeedbackPanel) getPage().get("feedback");
               
                try
                {
                    SearchEngine searchEngine = ((AbstractAdminWebApplication) getApplication()).getServiceLocator().getSearchEngine();
                    PortletRegistry registry = ((AbstractAdminWebApplication) getApplication()).getServiceLocator().getPortletRegistry();
                   
                    PortletApplication app = registry.getPortletApplication(paNodeBean.getApplicationName());
                    List<PortletDefinition> portletDefList = app.getPortlets();
                   
                    List<Object> list = new ArrayList<Object>();
                    list.addAll(portletDefList);
                    list.add(app);
                   
                    searchEngine.remove(list);
                   
                    list.clear();
                    list.add(app);
                    list.addAll(portletDefList);
                   
                    searchEngine.add(list);
                }
                catch (Exception e)
                {
                    logger.error("Failed to refresh the search index of application.", e);
                    StringResourceModel resModel = new StringResourceModel("pam.details.action.status.search.index.refreshFailure", this, null, new Object [] { paNodeBean.getApplicationName(), e.getMessage() } );
View Full Code Here

TOP

Related Classes of org.apache.jetspeed.search.SearchEngine

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.