[oozie] Refactor getWidgetSuccessor and getWidgetPredecessor