I’m trying to use HybridMenu in my V10 app but I can’t work out how to create one. The code sample shows the use of HybridMenuBuilder but I have looked in the Java doc for 3.0.15.vaadin10 and I can’t see it there. I have looked in pretty much all the other classes and I can’t see any method that returns a HybridMenu. Sorry for being so dim. Can anyone give me a clue as to how I would create a HybridMenu using Vaadin 10.
Thank you for the pointers. I have now had a chance to make some progress. I need to make the menus based on entries in a DB table. I’m wondering how to pass that (the repository class references?) to the init() method. I did create a constructor with no parameters (as an experiment) and that does get called before init() but the base class (HybridMenu) no parameter constructor is called first and that calls init(). Perhaps I need to pass them via the init parameters (VaadinSession vaadinSession, UI ui), or maybe there is a better pattern …
Ah just made some more progress. I returned false from init() and then added a readMenus() method passing the repositories to build the menus, calling build() at the end. The menus now appear (there are bugs to fix).