
p.location-badge.
  exported from <a href='../router'>angular2/router</a>
  defined in <a href="https://github.com/angular/angular/tree/2.0.0-alpha.37/modules/angular2/src/router/route_registry.ts#L37-L293">angular2/src/router/route_registry.ts (line 37)</a>

:markdown
  The RouteRegistry holds route configurations for each component in an Angular app.
  It is responsible for creating Instructions from URLs, and generating URLs based on route and
  parameters.
  
  

.l-main-section
  h2 Annotations
  .l-sub-section
    h3.annotation Injectable
    pre.prettyprint
      code.
        @Injectable()


.l-main-section
  h2 Members
  .l-sub-section
    h3#config config

    
    pre.prettyprint
      code.
        config(parentComponent: any, config: RouteDefinition)
    
    :markdown
      Given a component and a configuration object, add the route to this registry
      
      





  .l-sub-section
    h3#configFromComponent configFromComponent

    
    pre.prettyprint
      code.
        configFromComponent(component: any)
    
    :markdown
      Reads the annotations of a component and configures the registry based on them
      
      





  .l-sub-section
    h3#recognize recognize

    
    pre.prettyprint
      code.
        recognize(url: string, parentComponent: any)
    
    :markdown
      Given a URL and a parent component, return the most specific instruction for navigating
      the application into the state specified by the url
      
      





  .l-sub-section
    h3#generate generate

    
    pre.prettyprint
      code.
        generate(linkParams: any[], parentComponent: any)
    
    :markdown
      Given a normalized list with component names and params like: `['user', {id: 3 }]`
      generates a url with a leading slash relative to the provided `parentComponent`.
      
      




