本文整理汇总了TypeScript中angular2-logger/core.Logger类的典型用法代码示例。如果您正苦于以下问题:TypeScript Logger类的具体用法?TypeScript Logger怎么用?TypeScript Logger使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
在下文中一共展示了Logger类的10个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的TypeScript代码示例。
示例1: constructor
constructor(private _logger: Logger
) {
this._logger.log('CasseTete Component Mounted Successfully');
}
开发者ID:larryaubstore,项目名称:casse-tete-angular,代码行数:4,代码来源:casse-tete.component.ts
示例2: logMsgs
logMsgs(){
this._logger.error('This is a priority level 1 error message...');
this._logger.warn('This is a priority level 2 warning message...');
this._logger.info('This is a priority level 3 info message...');
this._logger.debug('This is a priority level 4 debug message...');
this._logger.log('This is a priority level 5 log message...');
}
开发者ID:VQComms,项目名称:angular2-logger,代码行数:7,代码来源:hello-world.component.ts
示例3:
this.socket.on('dashboard', (msg) => {
let message:any = msg.content;
if (message.type) {
this.ngRedux.dispatch(message);
} else {
this.logger.warn('Unknown message type', msg);
}
});
开发者ID:dimapod,项目名称:xc-dashboard,代码行数:8,代码来源:socket.service.ts
示例4: resolve
(data) => {
this.logger.info(eicformatlog(LoginService.name, data, true));
const context: UserContext = {profileId: data.profile, securityToken: data.access_token};
this.contextStorage.saveUser(context).then(
() => {
this.contextService.setUser(context);
resolve(context);
},
(error) => reject("Error almacenando la información en el dispositvo movil.")
);
},
开发者ID:davsuapas,项目名称:Angular2Ionic2ReusableApplications,代码行数:11,代码来源:login.service.ts
示例5: Promise
return new Promise((resolve, reject) => {
this.logger.info(eicformatlog(EicOauth2AuthorizeService.name, "Config: " + this.config, true));
const uri = this.config.authorizeUrl +
"?client_id=" + this.config.params.clientId +
"&redirect_uri=http://localhost/callback&response_type=token";
const browserRef = this.appBrowser.create(uri,
"_blank", "location=no,clearsessioncache=yes,clearcache=yes");
this.logger.debug(eicformatlog(EicOauth2AuthorizeService.name, "URI: " + uri));
browserRef.on("loadstart").subscribe(event => {
if ((event.url).indexOf("http://localhost/callback") === 0) {
browserRef.on("exit").subscribe(event => {});
browserRef.close();
this.logger.debug(eicformatlog(EicOauth2AuthorizeService.name, "URL callback: " + event.url));
const responseParameters = ((event.url).split("#")[1]).split("&");
const parsedResponse = {};
for (const responseParameter of responseParameters) {
parsedResponse[responseParameter.split("=")[0]] = responseParameter.split("=")[1];
}
if (parsedResponse["access_token"] !== undefined) {
resolve(parsedResponse);
} else {
reject();
}
}
});
browserRef.on("exit").subscribe( event => {
reject();
});
});
开发者ID:davsuapas,项目名称:Angular2Ionic2ReusableApplications,代码行数:41,代码来源:oauth2-authorize.service.ts
示例6: keygen
keygen(id:number) {
// jQuery("#regen_ssh_key").click(function () {
// layer.alert('申请已提交,请等待,请勿重复提交');
// jQuery.get(
// jQuery(this).attr('value'),
// {},
// function (data) {
// layer.alert(data)
// }
// )
// })
this._logger.debug(id)
}
开发者ID:jumpserver,项目名称:web,代码行数:13,代码来源:changinfo.ts
示例7: ngOnInit
ngOnInit() {
this.data = {'users': 10, 'hosts': 10, 'online': 19, 'hostonline': 9};
this._appService.getMyinfo();
this._logger.log('dashboard.ts:Dashboard,ngOnInit');
// this._appService.getMyinfoFromServer().subscribe(response => {
// this.user = response;
// this._logger.log('dashboard.ts:Dashboard,ngOnInit')
// this._logger.debug(response)
// this._appService.setMyinfo(this.user);
// });
}
开发者ID:jumpserver,项目名称:web,代码行数:13,代码来源:changinfo.ts
示例8: resolve
browserRef.on("loadstart").subscribe(event => {
if ((event.url).indexOf("http://localhost/callback") === 0) {
browserRef.on("exit").subscribe(event => {});
browserRef.close();
this.logger.debug(eicformatlog(EicOauth2AuthorizeService.name, "URL callback: " + event.url));
const responseParameters = ((event.url).split("#")[1]).split("&");
const parsedResponse = {};
for (const responseParameter of responseParameters) {
parsedResponse[responseParameter.split("=")[0]] = responseParameter.split("=")[1];
}
if (parsedResponse["access_token"] !== undefined) {
resolve(parsedResponse);
} else {
reject();
}
}
});
开发者ID:davsuapas,项目名称:Angular2Ionic2ReusableApplications,代码行数:23,代码来源:oauth2-authorize.service.ts
示例9: ngOnInit
ngOnInit() {
this._logger.log('dashboard.ts:Dashboard,ngOnInit');
this._appService.getMyinfo();
this.data = {'users': 10, 'hosts': 10, 'online': 19, 'hostonline': 9};
// this._appService.getMyinfoFromServer().subscribe(response => {
// this.user = response;
// this._logger.log('dashboard.ts:Dashboard,ngOnInit')
// this._logger.debug(response)
// this._appService.setMyinfo(this.user);
// });
// this.top10Chart = echarts.init(document.getElementById('top10'));
// var option = {
// title: {
// text: '月数据总览',
// subtext: '一个月内历史汇总',
// x: 'center'
// },
// tooltip: {
// trigger: 'axis'
// },
// backgroundColor: '#fff',
// legend: {
// data: ['登陆次数', '活跃用户', '活跃资产'],
// y: 'bottom'
// },
// toolbox: {
// show: false,
// feature: {
//
//
// magicType: {show: true, type: ['line', 'bar']}
// }
// },
// calculable: true,
// xAxis: [
// {
// type: 'category',
// boundaryGap: false,
// data: ['03-08', '03-09', '03-10', '03-11', '03-12', '03-13', '03-14', '03-15', '03-16', '03-17', '03-18', '03-19', '03-20', '03-21', '03-22', '03-23', '03-24', '03-25', '03-26', '03-27', '03-28', '03-29', '03-30', '03-31', '04-01', '04-02', '04-03', '04-04', '04-05', '04-06']
// }
// ],
// yAxis: [
// {
// type: 'value'
// }
// ],
// series: [
// {
// name: '登陆次数',
// type: 'line',
// smooth: true,
// itemStyle: {normal: {areaStyle: {type: 'default'}}},
// data: [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 2, 13, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0]
// },
// {
// name: '活跃用户',
// type: 'line',
// smooth: true,
// itemStyle: {normal: {areaStyle: {type: 'default'}}},
// data: [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0]
// },
// {
// name: '活跃资产',
// type: 'line',
// smooth: true,
// itemStyle: {normal: {areaStyle: {type: 'default'}}},
// data: [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0]
// }
//
// ]
// };
// this.top10Chart.setOption(option, true);
// while(jQuery('#top10').width()==0)
// this.top10Chart.setOption(option,true);
}
开发者ID:monalisir,项目名称:web,代码行数:77,代码来源:dashboard.ts
示例10: ngOnInit
ngOnInit() {
this._logger.log('index.tx:AppComponent,ngOnInit');
this._appService.checklogin(this._router.lastNavigationAttempt);
this._appService.getMyinfo();
}
开发者ID:monalisir,项目名称:web,代码行数:6,代码来源:index.ts
注:本文中的angular2-logger/core.Logger类示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论