@staticmethod
def get_clique(node, join_tree):
    """
        Gets the parent clique associated with the specified BBN node.

        :param node: BBN node.
        :param join_tree: Join tree.
        :return: Parent clique.
        """
    if 'parent.clique' not in node.metadata:
        cliques = sorted(join_tree.find_cliques_with_node_and_parents(node.
            id), key=lambda x: x.id)
        clique = cliques[0]
        node.add_metadata('parent.clique', clique)
        return clique
    else:
        return node.metadata['parent.clique']
