public function getValues($recursive = TRUE) {
    $values = new NodeCollection();
    foreach ($this->elements->getItems() as $element) {
      if ($element instanceof ArrayPairNode) {
        $value = $element->getValue();
        if ($recursive && $value instanceof ArrayNode) {
          $values->add($value->getValues($recursive));
        }
        else {
          $values->add($value);
        }
      }
      else {
        $values->add($element);
      }
    }
    return $values;
  }
public function getValues($recursive = TRUE) {
    $values = new NodeCollection();
    foreach ($this->elements->getItems() as $element) {
      if ($element instanceof ArrayPairNode) {
        $value = $element->getValue();
        if ($recursive && $value instanceof ArrayNode) {
          $values->add($value->getValues($recursive));
        }
        else {
          $values->add($value);
        }
      }
      else {
        $values->add($element);
      }
    }
    return $values;
  }
public function getValues ( $ recursive = TRUE ) { $ values = new NodeCollection ( ) ; foreach ( $ this -> elements -> getItems ( ) as $ element ) { if ( $ element instanceof ArrayPairNode ) { $ value = $ element -> getValue ( ) ; if ( $ recursive && $ value instanceof ArrayNode ) { $ values -> add ( $ value -> getValues ( $ recursive ) ) ; } else { $ values -> add ( $ value ) ; } } else { $ values -> add ( $ element ) ; } } return $ values ; }
Get the values of the array.

@param boolean $recursive
(optional) TRUE to get values of array elements that are also arrays.

@return NodeCollection
Get the values of the array .