original_string: public function get($id)
      {
          foreach ($this->instructions as $instruction) {
              if (!$instruction instanceof Node && !$instruction instanceof Subgraph) {
                  continue;
              }
  
              if ($instruction->getId() == $id) {
                  return $instruction;
              }
          }
  
          throw new \InvalidArgumentException(sprintf('Found no node or graph with id "%s" in "%s".', $id, $this->id));
      }
code: public function get($id)
      {
          foreach ($this->instructions as $instruction) {
              if (!$instruction instanceof Node && !$instruction instanceof Subgraph) {
                  continue;
              }
  
              if ($instruction->getId() == $id) {
                  return $instruction;
              }
          }
  
          throw new \InvalidArgumentException(sprintf('Found no node or graph with id "%s" in "%s".', $id, $this->id));
      }
code_tokens: public function get ( $ id ) { foreach ( $ this -> instructions as $ instruction ) { if ( ! $ instruction instanceof Node && ! $ instruction instanceof Subgraph ) { continue ; } if ( $ instruction -> getId ( ) == $ id ) { return $ instruction ; } } throw new \ InvalidArgumentException ( sprintf ( 'Found no node or graph with id "%s" in "%s".' , $ id , $ this -> id ) ) ; }
docstring: Returns a node or a subgraph, given his id.
  
  @param string $id the identifier of the node/graph to fetch
  
  @return Node|Graph
  
  @throws InvalidArgumentException node or graph not found
docstring_tokens: Returns a node or a subgraph given his id .