definition of getLinks()