export declare class ActivatedRoute {
    /** An observable of the URL segments matched by this route. */
    url: Observable<UrlSegment[]>; //当前路由的path 以及跳转参数
    // value对象{
    //     parameters: //跳转参数 如果为queryParameter则不会出现在这
    //     path:'' //当前路由的path
    // }
    /** An observable of the matrix parameters scoped to this route. */
    /** 一个表示当前路由范围内的矩阵参数 在路由中;隔开 */
    params: Observable<Params>;
    /** An observable of the query parameters shared by all the routes. */
    /** 一个表示所有路由共享的查询参数的observable 在路由中?隔开 */
    queryParams: Observable<Params>;
    /** An observable of the URL fragment shared by all the routes. */
    /** 一个表示所有路由共享url片段的observable */
    fragment: Observable<string | null>;
    /** An observable of the static and resolved data of this route. */
    /** 一个表示该路由静态数据和解析数据的observable */
    /** 在定义路由时的data */
    data: Observable<Data>;
    /** The outlet name of the route, a constant. */
    outlet: string;
    /** The component of the route, a constant. */
    /** 本路由中对应的组件 是个常量 */
    component: Type<any> | string | null;
    /** The current snapshot of this route */
    /** 本路由此刻的快照,拥有该类的所有属性,在不订阅的情况下获取想到的路由数据 */
    snapshot: ActivatedRouteSnapshot;
    /** The configuration used to match this route. */
    get routeConfig(): Route | null;
    /** The root of the router state. */
    get root(): ActivatedRoute;
    /** The parent of this route in the router state tree. */
    get parent(): ActivatedRoute | null;
    /** The first child of this route in the router state tree. */
    get firstChild(): ActivatedRoute | null;
    /** The children of this route in the router state tree. */
    get children(): ActivatedRoute[];
    /** The path from the root of the router state tree to this route. */
    get pathFromRoot(): ActivatedRoute[];
    /**
     * An Observable that contains a map of the required and optional parameters
     * specific to the route.
     * The map supports retrieving single and multiple values from the same parameter.
     */
    get paramMap(): Observable<ParamMap>;
    /**
     * An Observable that contains a map of the query parameters available to all routes.
     * The map supports retrieving single and multiple values from the query parameter.
     */
    get queryParamMap(): Observable<ParamMap>;
    toString(): string;
}
Logo

华为开发者空间,是为全球开发者打造的专属开发空间,汇聚了华为优质开发资源及工具,致力于让每一位开发者拥有一台云主机,基于华为根生态开发、创新。

更多推荐