Package org.zeroexchange.web.navigation.menu.model

Examples of org.zeroexchange.web.navigation.menu.model.Submenu


    @Override
    public List<MenuItem> getSubmenu(String key) {
        List<MenuItem> topMenu = getTopItems();
        for(MenuItem topMenuItem : topMenu) {
            if(topMenuItem instanceof Submenu) {
                Submenu submenu = (Submenu) topMenuItem;
                List<MenuItem> leftMenuCandidate = submenu.getMenuItems();
                if(getKey(topMenuItem).equals(key) || findItemByKey(leftMenuCandidate, key) != null) {
                    return leftMenuCandidate;
                }
            }
        }
View Full Code Here


     */
    protected boolean isMenuItemAllowed(MenuItem menuItem) {
        if(menuItem instanceof Leaf) {
            return targetFilter.isAllowed(((Leaf) menuItem).getPageClass());
        } else if(menuItem instanceof Submenu){
            Submenu submenu = (Submenu) menuItem;
            for(MenuItem item : submenu.getMenuItems()) {
                if(isMenuItemAllowed(item)) {
                    return true;
                }
            }
        }
View Full Code Here

TOP

Related Classes of org.zeroexchange.web.navigation.menu.model.Submenu

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.