Class InCellLists.MultiLevelListItem

  • Enclosing class:
    InCellLists

    public static final class InCellLists.MultiLevelListItem
    extends Object
    An instance of this inner class models an item or element in a multi-level list. Each multi-level list item consists of the text for the high level items and an ArrayList containing the text for each of the associated lower level items. When written into a cell, each multi-level list item will have this general appearance. Item One Sub Item One. Sub Item Two. Item Two Sub Item One. Sub Item Two. etc. It would be quite possible to modify this class to model much more complex list structures descending through two, three or even more levels.
    • Constructor Detail

      • MultiLevelListItem

        public MultiLevelListItem​(String itemText,
                                  List<String> lowerLevelItems)
        Create a new instance of the MultiLevelListItem class using the following parameters.
        Parameters:
        itemText - A String that encapsulates the text for the high level list item.
        lowerLevelItems - An ArrayList whose elements encapsulate the text for the associated lower level list items.
    • Method Detail

      • getItemText

        public String getItemText()
        Get the text for the high level list item.
        Returns:
        A String that encapsulates the text for the high level list item.
      • getLowerLevelItems

        public List<String> getLowerLevelItems()
        Get the text for the associated lower level list items.
        Returns:
        An ArrayList whose elements each encapsulate the text for a single associated lower level list item.