コード例 #1
0
ファイル: Chart.php プロジェクト: chippyash/simple-accounts
 /**
  * Find an account node using its id
  *
  * @param Nominal $nId
  * @return node|null
  */
 protected function findNode(Nominal $nId)
 {
     return $this->tree->accept(new NodeFinder($nId));
 }
コード例 #2
0
 public function testTheYieldOfALeafNodeIsTheNodeItself()
 {
     $node = new Node('node');
     $visitor = new YieldVisitor();
     $this->assertSame([$node], $node->accept($visitor));
 }