Get Parents

How can i to get all the Parents Ids from a Specific Node on a Tree?

By using
    tree.getParentID
you can get direct parent of item , with little effor it possible to receive full list of parents

function getAllParents(id){
    var ar=[id];
       while (id=tree.getParentId(id))
          ar.push(id)
    return ar;
}