original_string: public function blueprints($type)
      {
          if ($this->blueprints === null) {
              $this->blueprints = new Blueprints(self::getTypes());
          }
  
          try {
              $blueprint = $this->blueprints->get($type);
          } catch (\RuntimeException $e) {
              $blueprint = $this->blueprints->get('default');
          }
  
          if (empty($blueprint->initialized)) {
              $this->grav->fireEvent('onBlueprintCreated', new Event(['blueprint' => $blueprint, 'type' => $type]));
              $blueprint->initialized = true;
          }
  
          return $blueprint;
      }
code: public function blueprints($type)
      {
          if ($this->blueprints === null) {
              $this->blueprints = new Blueprints(self::getTypes());
          }
  
          try {
              $blueprint = $this->blueprints->get($type);
          } catch (\RuntimeException $e) {
              $blueprint = $this->blueprints->get('default');
          }
  
          if (empty($blueprint->initialized)) {
              $this->grav->fireEvent('onBlueprintCreated', new Event(['blueprint' => $blueprint, 'type' => $type]));
              $blueprint->initialized = true;
          }
  
          return $blueprint;
      }
code_tokens: public function blueprints ( $ type ) { if ( $ this -> blueprints === null ) { $ this -> blueprints = new Blueprints ( self :: getTypes ( ) ) ; } try { $ blueprint = $ this -> blueprints -> get ( $ type ) ; } catch ( \ RuntimeException $ e ) { $ blueprint = $ this -> blueprints -> get ( 'default' ) ; } if ( empty ( $ blueprint -> initialized ) ) { $ this -> grav -> fireEvent ( 'onBlueprintCreated' , new Event ( [ 'blueprint' => $ blueprint , 'type' => $ type ] ) ) ; $ blueprint -> initialized = true ; } return $ blueprint ; }
docstring: Get a blueprint for a page type.
  
  @param  string $type
  
  @return Blueprint
docstring_tokens: Get a blueprint for a page type .