'List all nodes.
:param location: Filter the groups by location (optional)
:type  location: a :class:`NodeLocation` instance.
:return:  List of node objects
:rtype: ``list`` of :class:`Node`'

def list_nodes(self, location=None):

    nodes = []
    for group in self.ex_list_groups(location):
        nodes.extend(group.nodes)
    return nodes
