Uses of Class
com.thecoderscorner.menu.domain.MenuItem
-
-
Uses of MenuItem in com.thecoderscorner.menu.domain
Subclasses of MenuItem in com.thecoderscorner.menu.domain Modifier and Type Class Description classActionMenuItemActionMenuItem represents a menu item that is a one shot action, in that when triggered it just runs the callback on the embedded side.classAnalogMenuItemRepresents an analog (numeric) menu item, it is always a zero based integer when retrieved from storage, but it can have an offset and divisor, so therefore is able to represent decimal values.classBooleanMenuItemA menu item that can only hold boolean values (true or false).classEditableTextMenuItemAn implementation of menu item that can store text strings.classEnumMenuItemA menu item implementation that represents one of a known set of choices, the choices are stored as an integer value, but each choice has a string representation as well.classFloatMenuItemFloatMenuItem represents a menu item that uses a floating point value.classRuntimeListMenuItemclassSubMenuItemSubMenuItem represents a menu item that has children.Methods in com.thecoderscorner.menu.domain with parameters of type MenuItem Modifier and Type Method Description protected voidMenuItemBuilder. baseFromExisting(MenuItem item) -
Uses of MenuItem in com.thecoderscorner.menu.domain.state
Methods in com.thecoderscorner.menu.domain.state that return MenuItem Modifier and Type Method Description MenuItem<T>MenuState. getItem()Gets the menu item associated with this state.Methods in com.thecoderscorner.menu.domain.state that return types with arguments of type MenuItem Modifier and Type Method Description java.util.Collection<MenuItem>MenuTree. getAllMenuItems()Gets every menu item held in this menu tree, will be uniquejava.util.Set<MenuItem>MenuTree. getAllSubMenus()Returns all the submenus that are currently storedjava.util.Optional<MenuItem>MenuTree. getMenuById(int id)Gets the menu item with the specified ID, finding the submenu if needed.java.util.List<MenuItem>MenuTree. getMenuItems(MenuItem item)Get a list of all menu items for a given submenuMethods in com.thecoderscorner.menu.domain.state with parameters of type MenuItem Modifier and Type Method Description voidMenuTree. addMenuItem(SubMenuItem parent, MenuItem item)add a new menu item to a sub menu, for the top level menu use ROOT.voidMenuTree. addOrUpdateItem(int parentId, MenuItem item)This will either add or update an existing item, depending if the ID is already present.<T> voidMenuTree. changeItem(MenuItem<T> item, MenuState<T> menuState)Change the value that's associated with a menu item.SubMenuItemMenuTree. findParent(MenuItem toFind)Finds the submenu that the provided object belongs to.java.util.List<MenuItem>MenuTree. getMenuItems(MenuItem item)Get a list of all menu items for a given submenu<T> MenuState<T>MenuTree. getMenuState(MenuItem<T> item)Gets the menu state that's associated with a given menu item.voidMenuTree. moveItem(SubMenuItem parent, MenuItem newItem, MenuTree.MoveType moveType)Moves the item either up or down in the list for that submenuvoidMenuTree. removeMenuItem(MenuItem toRemove)Remove the menu item using this menu item as a prototype (Uses the ID for comparison)voidMenuTree. removeMenuItem(SubMenuItem parent, MenuItem item)Remove the menu item for the provided menu item in the provided sub menu.voidMenuTree. replaceMenuById(MenuItem toReplace)Replace a menu item with the given ID.voidMenuTree. replaceMenuById(SubMenuItem subMenu, MenuItem toReplace)Replace the menu item that has a given parent with the one provided.Constructors in com.thecoderscorner.menu.domain.state with parameters of type MenuItem Constructor Description BooleanMenuState(MenuItem<java.lang.Boolean> item, boolean changed, boolean active, boolean value)FloatMenuState(MenuItem<java.lang.Float> item, boolean changed, boolean active, java.lang.Float value)IntegerMenuState(MenuItem<java.lang.Integer> item, boolean changed, boolean active, java.lang.Integer value)MenuState(MenuItem<T> item, boolean changed, boolean active, T value)normally these states are created from the menu item, instead of directlyStringListMenuState(MenuItem<java.util.List<java.lang.String>> item, boolean changed, boolean active, java.lang.String... value)StringListMenuState(MenuItem<java.util.List<java.lang.String>> item, boolean changed, boolean active, java.util.List<java.lang.String> value)StringMenuState(MenuItem<java.lang.String> item, boolean changed, boolean active, java.lang.String value) -
Uses of MenuItem in com.thecoderscorner.menu.domain.util
Methods in com.thecoderscorner.menu.domain.util that return MenuItem Modifier and Type Method Description static MenuItemMenuItemHelper. createFromExistingWithId(MenuItem selected, int newId)creates a copy of the menu item chosen, with the ID changed to newIdMethods in com.thecoderscorner.menu.domain.util with parameters of type MenuItem Modifier and Type Method Description voidAbstractMenuItemVisitor. anyItem(MenuItem item)Whenever a visit method is not implemented, then anyItem is called instead.static SubMenuItemMenuItemHelper. asSubMenu(MenuItem item)Returns the menu item as a sub menu or nullstatic MenuItemMenuItemHelper. createFromExistingWithId(MenuItem selected, int newId)creates a copy of the menu item chosen, with the ID changed to newIdstatic intMenuItemHelper. eepromSizeForItem(MenuItem item)Gets the size of the eeprom storage for a given element typestatic booleanMenuItemHelper. isRuntimeStructureNeeded(MenuItem item)Check if the item is based on a runtime itemstatic <T> java.util.Optional<T>MenuItemHelper. visitWithResult(MenuItem item, AbstractMenuItemVisitor<T> visitor)Visits a menu item calling the appropriate function for the type and collects the result that is set by calling your visitor's `setResult` method. -
Uses of MenuItem in com.thecoderscorner.menu.remote
Methods in com.thecoderscorner.menu.remote with parameters of type MenuItem Modifier and Type Method Description voidRemoteControllerListener. ackReceived(CorrelationId key, MenuItem item, AckStatus status)voidRemoteControllerListener. menuItemChanged(MenuItem item, boolean valueOnly)Called when a menu item has either been added or changed, the valueOnly indicates if the change is just in the latest value, or also in the MenuItem structure too.CorrelationIdRemoteMenuController. sendAbsoluteUpdate(MenuItem item, java.lang.Object newValue)Send an asbolute change for the given itemCorrelationIdRemoteMenuController. sendDeltaUpdate(MenuItem item, int deltaChange)Send a delta change for the given menuitem -
Uses of MenuItem in com.thecoderscorner.menu.remote.commands
Classes in com.thecoderscorner.menu.remote.commands with type parameters of type MenuItem Modifier and Type Class Description classBootItemMenuCommand<T extends MenuItem,V>Methods in com.thecoderscorner.menu.remote.commands with parameters of type MenuItem Modifier and Type Method Description static MenuChangeCommandCommandFactory. newAbsoluteMenuChangeCommand(CorrelationId correlation, MenuItem item, java.lang.Object value)Creates a new absolute change command given the menu item and the absolute change in value.static MenuChangeCommandCommandFactory. newDeltaChangeCommand(CorrelationId correlation, MenuItem item, int value)Creates a new delta change command given the menu item and the delta change in value.
-