'Generates a items string according to the configuration.
:param is_debug: If True returns a string with all items.
:type is_debug: boolean
:return: A string containing items and their count, ready to be displayed.
:rtype: string'

def get_inventory_line(self, is_debug=False):

    available_items = {'pokemon_bag': 'Pokemon:    {:,}/{:,}'.format(inventory.Pokemons.get_space_used(), inventory.get_pokemon_inventory_size()), 'space_info': 'Items:    {:,}/{:,}'.format(self.inventory.get_space_used(), (self.inventory.get_space_used() + self.inventory.get_space_left())), 'pokeballs': 'Pokeballs:    {:,}'.format(self.inventory.get(1).count), 'greatballs': 'GreatBalls:    {:,}'.format(self.inventory.get(2).count), 'ultraballs': 'UltraBalls:    {:,}'.format(self.inventory.get(3).count), 'masterballs': 'MasterBalls:    {:,}'.format(self.inventory.get(4).count), 'razzberries': 'RazzBerries:    {:,}'.format(self.inventory.get(701).count), 'blukberries': 'BlukBerries:    {:,}'.format(self.inventory.get(702).count), 'nanabberries': 'NanabBerries:    {:,}'.format(self.inventory.get(703).count), 'wepabberries': 'WeparBerries:    {:,}'.format(self.inventory.get(704).count), 'pinapberries': 'PinapBerries:    {:,}'.format(self.inventory.get(705).count), 'luckyegg': 'LuckyEgg:    {:,}'.format(self.inventory.get(301).count), 'incubator': 'Incubator:    {:,}'.format(self.inventory.get(902).count), 'troydisk': 'TroyDisk:    {:,}'.format(self.inventory.get(501).count), 'potion': 'Potion:    {:,}'.format(self.inventory.get(101).count), 'superpotion': 'SuperPotion:    {:,}'.format(self.inventory.get(102).count), 'hyperpotion': 'HyperPotion:    {:,}'.format(self.inventory.get(103).count), 'maxpotion': 'MaxPotion:    {:,}'.format(self.inventory.get(104).count), 'incense': 'Incense:    {:,}'.format(self.inventory.get(401).count), 'incensespicy': 'IncenseSpicy:    {:,}'.format(self.inventory.get(402).count), 'incensecool': 'IncenseCool:    {:,}'.format(self.inventory.get(403).count), 'revive': 'Revive:    {:,}'.format(self.inventory.get(201).count), 'maxrevive': 'MaxRevive:    {:,}'.format(self.inventory.get(202).count), 'sunstone': 'SunStone:    {:,}'.format(self.inventory.get(1101).count), 'kingsrock': 'KingsRock:    {:,}'.format(self.inventory.get(1102).count), 'metalcoat': 'MetalCoat:    {:,}'.format(self.inventory.get(1103).count), 'dragonscale': 'DragonScale:    {:,}'.format(self.inventory.get(1104).count), 'upgrade': 'Upgrade:    {:,}'.format(self.inventory.get(1105).count)}
    def get_item(item):
        "\n                                                Fetches    a    item    string    from    the    available    items    dictionary.\n                                                :param    item:    The    item    name.\n                                                :type    item:    string\n                                                :return:    The    generated    item    string.\n                                                :rtype:    string\n                                                :raise:    ConfigException:    When    the    provided    item    string    isn't    in    the    available    items\n                                                dictionary.\n                                                "
        if (item not in available_items):
            raise ConfigException("item    '{}'    isn't    available    for    displaying".format(item))
        return available_items[item]
    if is_debug:
        temp = []
        for (key, value) in available_items.iteritems():
            temp.append(value)
        return '    |    '.join(temp)
    line = '    |    '.join(map(get_item, self.displayed_items))
    return line
