当前位置: 首页>>代码示例>>TypeScript>>正文


TypeScript lang.normalizeBlank函数代码示例

本文整理汇总了TypeScript中angular2/src/facade/lang.normalizeBlank函数的典型用法代码示例。如果您正苦于以下问题:TypeScript normalizeBlank函数的具体用法?TypeScript normalizeBlank怎么用?TypeScript normalizeBlank使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了normalizeBlank函数的9个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的TypeScript代码示例。

示例1: initCallbacks

 initCallbacks({onTurnStart,
   onTurnDone,
   onScheduleMicrotask,
   onErrorHandler} = {}) {
   this._onTurnStart = normalizeBlank(onTurnStart);
   this._onTurnDone = normalizeBlank(onTurnDone);
   this._onErrorHandler = normalizeBlank(onErrorHandler);
 }
开发者ID:gdi2290,项目名称:sample-Angular2,代码行数:8,代码来源:vm_turn_zone.ts

示例2: generate

 generate(params: StringMap<string, string>): string {
   if (!StringMapWrapper.contains(params, this.name)) {
     throw new BaseException(
         `Route generator for '${this.name}' was not included in parameters passed.`)
   }
   return normalizeBlank(StringMapWrapper.get(params, this.name));
 }
开发者ID:AsherBarak,项目名称:angular,代码行数:7,代码来源:path_recognizer.ts

示例3: value

 set value(value) {
   this._emptyAllActiveViewContainers();
   this._useDefault = false;
   var containers = MapWrapper.get(this._valueViewContainers, value);
   if (isBlank(containers)) {
     this._useDefault = true;
     containers = normalizeBlank(MapWrapper.get(this._valueViewContainers, _whenDefault));
   }
   this._activateViewContainers(containers);
   this._switchValue = value;
 }
开发者ID:gdi2290,项目名称:sample-Angular2,代码行数:11,代码来源:switch.ts

示例4: _onError

 _onError(zone, e) {
   if (isPresent(this._onErrorHandler)) {
     var trace = [normalizeBlank(e.stack)];
     while (zone && zone.constructedAtException) {
       trace.push(zone.constructedAtException.get());
       zone = zone.parent;
     }
     this._onErrorHandler(e, trace);
   } else {
     throw e;
   }
 }
开发者ID:gdi2290,项目名称:sample-Angular2,代码行数:12,代码来源:vm_turn_zone.ts

示例5: _processRequest

 _processRequest(request) {
   var url = request.url;
   if (this._expectations.length > 0) {
     var expectation = this._expectations[0];
     if (expectation.url == url) {
       ListWrapper.remove(this._expectations, expectation);
       request.complete(expectation.response);
       return ;
     }
   }
   if (MapWrapper.contains(this._definitions, url)) {
     var response = MapWrapper.get(this._definitions, url);
     request.complete(normalizeBlank(response));
     return ;
   }
   throw new BaseException(`Unexpected request ${url}`);
 }
开发者ID:gdi2290,项目名称:sample-Angular2,代码行数:17,代码来源:xhr_mock.ts

示例6: getAttribute

 /**
  * Gets an attribute from the underlying DOM element.
  * (DEPRECATED way of accessing the DOM, replacement coming)
  */
 // TODO(tbosch): Here we expose the real DOM element.
 // We need a more general way to read/write to the DOM element
 // via a proper abstraction in the render layer
 getAttribute(name: string): string {
   return normalizeBlank(DOM.getAttribute(this.domElement, name));
 }
开发者ID:AsherBarak,项目名称:angular,代码行数:10,代码来源:element_ref.ts

示例7: get

 get(param: string): string { return normalizeBlank(StringMapWrapper.get(this.params, param)); }
开发者ID:Mariem-07,项目名称:angular,代码行数:1,代码来源:instruction.ts

示例8: overrideOnEventDone

 overrideOnEventDone(onEventDoneFn: Function, waitForAsync: boolean = false): void {
   this._onEventDone = normalizeBlank(onEventDoneFn);
 }
开发者ID:goderbauer,项目名称:angular,代码行数:3,代码来源:testability_spec.ts

示例9: overrideOnTurnStart

 overrideOnTurnStart(onTurnStartFn: Function): void {
   this._onTurnStart = normalizeBlank(onTurnStartFn);
 }
开发者ID:goderbauer,项目名称:angular,代码行数:3,代码来源:testability_spec.ts


注:本文中的angular2/src/facade/lang.normalizeBlank函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。