Add method findNodesByType.