99 lines
		
	
	
		
			1.6 KiB
		
	
	
	
		
			Plaintext
		
	
	
	
	
	
		
		
			
		
	
	
			99 lines
		
	
	
		
			1.6 KiB
		
	
	
	
		
			Plaintext
		
	
	
	
	
	
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								p.location-badge.
							 | 
						||
| 
								 | 
							
								  exported from <a href='../router'>angular2/router</a>
							 | 
						||
| 
								 | 
							
								  defined in <a href="https://github.com/angular/angular/tree/master/modules/angular2/src/router/route_registry.js#L6-L154">angular2/src/router/route_registry.js (line 6)</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 Members
							 | 
						||
| 
								 | 
							
								  .l-sub-section
							 | 
						||
| 
								 | 
							
								    h3 constructor
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								    
							 | 
						||
| 
								 | 
							
								    pre.prettyprint
							 | 
						||
| 
								 | 
							
								      code.
							 | 
						||
| 
								 | 
							
								        constructor()
							 | 
						||
| 
								 | 
							
								    
							 | 
						||
| 
								 | 
							
								    :markdown
							 | 
						||
| 
								 | 
							
								      
							 | 
						||
| 
								 | 
							
								      
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								  .l-sub-section
							 | 
						||
| 
								 | 
							
								    h3 config
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								    
							 | 
						||
| 
								 | 
							
								    pre.prettyprint
							 | 
						||
| 
								 | 
							
								      code.
							 | 
						||
| 
								 | 
							
								        config(parentComponent, config:StringMap<string, any>)
							 | 
						||
| 
								 | 
							
								    
							 | 
						||
| 
								 | 
							
								    :markdown
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								      Given a component and a configuration object, add the route to this registry
							 | 
						||
| 
								 | 
							
								      
							 | 
						||
| 
								 | 
							
								      
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								  .l-sub-section
							 | 
						||
| 
								 | 
							
								    h3 configFromComponent
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								    
							 | 
						||
| 
								 | 
							
								    pre.prettyprint
							 | 
						||
| 
								 | 
							
								      code.
							 | 
						||
| 
								 | 
							
								        configFromComponent(component)
							 | 
						||
| 
								 | 
							
								    
							 | 
						||
| 
								 | 
							
								    :markdown
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								      Reads the annotations of a component and configures the registry based on them
							 | 
						||
| 
								 | 
							
								      
							 | 
						||
| 
								 | 
							
								      
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								  .l-sub-section
							 | 
						||
| 
								 | 
							
								    h3 generate
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								    
							 | 
						||
| 
								 | 
							
								    pre.prettyprint
							 | 
						||
| 
								 | 
							
								      code.
							 | 
						||
| 
								 | 
							
								        generate(name:string, params:StringMap<string, string>, hostComponent)
							 | 
						||
| 
								 | 
							
								    
							 | 
						||
| 
								 | 
							
								    :markdown
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								      
							 | 
						||
| 
								 | 
							
								      
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								  .l-sub-section
							 | 
						||
| 
								 | 
							
								    h3 recognize
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								    
							 | 
						||
| 
								 | 
							
								    pre.prettyprint
							 | 
						||
| 
								 | 
							
								      code.
							 | 
						||
| 
								 | 
							
								        recognize(url:string, parentComponent)
							 | 
						||
| 
								 | 
							
								    
							 | 
						||
| 
								 | 
							
								    :markdown
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								      Given a URL and a parent component, return the most specific instruction for navigating
							 | 
						||
| 
								 | 
							
								      the application into the state specified by the
							 | 
						||
| 
								 | 
							
								      
							 | 
						||
| 
								 | 
							
								      
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								
							 |