There are descriptions for each function. You want to have it constantly checking whenever you need to do pathfinding.