@@ -8,6 +8,7 @@ import { getPidFromiOSSimulatorLogs } from "../common/helpers";
8
8
const inspectorAppName = "NativeScript Inspector.app" ;
9
9
const inspectorNpmPackageName = "tns-ios-inspector" ;
10
10
const inspectorUiDir = "WebInspectorUI/" ;
11
+ import { performanceLog } from "../common/decorators" ;
11
12
12
13
export class IOSDeviceDebugService extends DebugServiceBase implements IDeviceDebugService {
13
14
private _lldbProcess : ChildProcess ;
@@ -38,6 +39,7 @@ export class IOSDeviceDebugService extends DebugServiceBase implements IDeviceDe
38
39
return "ios" ;
39
40
}
40
41
42
+ @performanceLog ( )
41
43
public async debug ( debugData : IDebugData , debugOptions : IDebugOptions ) : Promise < string > {
42
44
this . validateOptions ( debugOptions ) ;
43
45
@@ -75,6 +77,7 @@ export class IOSDeviceDebugService extends DebugServiceBase implements IDeviceDe
75
77
}
76
78
}
77
79
80
+ @performanceLog ( )
78
81
private async startDeviceLogProcess ( debugData : IDebugData , debugOptions : IDebugOptions ) : Promise < void > {
79
82
if ( debugOptions . justlaunch ) {
80
83
// No logs should be printed on console when `--justlaunch` option is passed.
@@ -95,6 +98,7 @@ export class IOSDeviceDebugService extends DebugServiceBase implements IDeviceDe
95
98
await this . device . openDeviceLogStream ( { predicate : IOS_LOG_PREDICATE } ) ;
96
99
}
97
100
101
+ @performanceLog ( )
98
102
private async startAppOnSimulator ( debugData : IDebugData , debugOptions : IDebugOptions ) : Promise < void > {
99
103
const args = debugOptions . debugBrk ? "--nativescript-debug-brk" : "--nativescript-debug-start" ;
100
104
const launchResult = await this . $iOSEmulatorServices . runApplicationOnEmulator ( debugData . pathToAppPackage , {
@@ -112,6 +116,7 @@ export class IOSDeviceDebugService extends DebugServiceBase implements IDeviceDe
112
116
this . startAppDebuggerOnSimulator ( pid ) ;
113
117
}
114
118
119
+ @performanceLog ( )
115
120
private async startAppOnDevice ( debugData : IDebugData , debugOptions : IDebugOptions ) : Promise < void > {
116
121
const runOptions : IRunPlatformOptions = {
117
122
device : this . deviceIdentifier ,
@@ -148,6 +153,7 @@ export class IOSDeviceDebugService extends DebugServiceBase implements IDeviceDe
148
153
}
149
154
}
150
155
156
+ @performanceLog ( )
151
157
private async wireDebuggerClient ( debugData : IDebugData , debugOptions : IDebugOptions ) : Promise < string > {
152
158
if ( ( debugOptions . inspector || ! debugOptions . client ) && this . $hostInfo . isDarwin ) {
153
159
return await this . setupTcpAppDebugProxy ( debugData , debugOptions ) ;
@@ -181,6 +187,7 @@ export class IOSDeviceDebugService extends DebugServiceBase implements IDeviceDe
181
187
return null ;
182
188
}
183
189
190
+ @performanceLog ( )
184
191
private async openAppInspector ( fileDescriptor : string , debugData : IDebugData , debugOptions : IDebugOptions ) : Promise < ChildProcess > {
185
192
if ( debugOptions . client ) {
186
193
const inspectorPath = await this . $packageInstallationManager . getInspectorFromCache ( inspectorNpmPackageName , debugData . projectDir ) ;
0 commit comments