Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
 package org.uberfire.workbench.model.menu;

 
 public class TestMenuSyntax {
 
     public static Object mainfinal String... args ) {
         return MenuFactory
                .newContributedMenu"x" )
                    .contributeTo"xx" )
                    .withRole"" )
                    .submenu"xx" )
                        .menu"cc" )
                            .respondsWithnull )
                        .endMenu()
                    .endMenus()
                .endMenu().
                newTopLevelMenu"")
                    .withRole"xxx" )
                        .submenu("")
                            .menu("xx")
                                .withRole"xxx" )
                                .respondsWithnull )
                            .endMenu()
                            .menu("x")
                                .submenu("xxx")
                                    .menu("xx")
                                        .respondsWithnull )
                                    .endMenu()
                                .endMenus()
                                .submenu("xxx")
                                    .menu("xx")
                                        .respondsWithnull )
                                    .endMenu()
                                .endMenus()
                            .endMenu()
                        .endMenus()
                .endMenu()
                .newTopLevelMenu("x")
                    .withRole"" )
                    .respondsWithnull )
                .endMenu()
                .newTopLevelMenu("x")
                    .submenu("x")
                        .menu("x")
                            .respondsWithnull )
                        .endMenu()
                    .endMenus()
                .endMenu()
                .newTopLevelMenu("xx")
                    .respondsWithnull )
                .endMenu()
                .newTopLevelMenu"xx" )
                    .withItemsnull )
                .endMenu()
                .newContributedMenu"x" )
                    .contributeTo"xx" )
                    .withRole"" )
                    .submenu"xx" )
                        .menu"cc" )
                            .respondsWithnull )
                        .endMenu()
                    .endMenus()
                .endMenu()
            .build();
    }
New to GrepCode? Check out our FAQ X