@@ -6,7 +6,7 @@ import { CONNECTED_STATUS } from "../common/constants";
66import { DebugTools , TrackActionNames } from "../constants" ;
77
88export class DebugService extends EventEmitter implements IDebugService {
9- private _platformDebugServices : IDictionary < IPlatformDebugService > ;
9+ private _platformDebugServices : IDictionary < IDeviceDebugService > ;
1010 constructor ( private $devicesService : Mobile . IDevicesService ,
1111 private $errors : IErrors ,
1212 private $injector : IInjector ,
@@ -51,7 +51,7 @@ export class DebugService extends EventEmitter implements IDebugService {
5151 this . $errors . failWithoutHelp ( `Unsupported device OS: ${ device . deviceInfo . platform } . You can debug your applications only on iOS or Android.` ) ;
5252 }
5353
54- // TODO: Consider to move this code to ios-debug-service
54+ // TODO: Consider to move this code to ios-device- debug-service
5555 if ( this . $mobileHelper . isiOSPlatform ( device . deviceInfo . platform ) ) {
5656 if ( device . isEmulator && ! debugData . pathToAppPackage && debugOptions . debugBrk ) {
5757 this . $errors . failWithoutHelp ( "To debug on iOS simulator you need to provide path to the app package." ) ;
@@ -72,13 +72,13 @@ export class DebugService extends EventEmitter implements IDebugService {
7272 return debugService . debugStop ( ) ;
7373 }
7474
75- protected getDebugService ( device : Mobile . IDevice ) : IPlatformDebugService {
75+ protected getDebugService ( device : Mobile . IDevice ) : IDeviceDebugService {
7676 if ( ! this . _platformDebugServices [ device . deviceInfo . identifier ] ) {
7777 const platform = device . deviceInfo . platform ;
7878 if ( this . $mobileHelper . isiOSPlatform ( platform ) ) {
79- this . _platformDebugServices [ device . deviceInfo . identifier ] = this . $injector . resolve ( "iOSDebugService " , { device } ) ;
79+ this . _platformDebugServices [ device . deviceInfo . identifier ] = this . $injector . resolve ( "iOSDeviceDebugService " , { device } ) ;
8080 } else if ( this . $mobileHelper . isAndroidPlatform ( platform ) ) {
81- this . _platformDebugServices [ device . deviceInfo . identifier ] = this . $injector . resolve ( "androidDebugService " , { device } ) ;
81+ this . _platformDebugServices [ device . deviceInfo . identifier ] = this . $injector . resolve ( "androidDeviceDebugService " , { device } ) ;
8282 } else {
8383 this . $errors . failWithoutHelp ( DebugCommandErrors . UNSUPPORTED_DEVICE_OS_FOR_DEBUGGING ) ;
8484 }
@@ -89,12 +89,12 @@ export class DebugService extends EventEmitter implements IDebugService {
8989 return this . _platformDebugServices [ device . deviceInfo . identifier ] ;
9090 }
9191
92- private getDebugServiceByIdentifier ( deviceIdentifier : string ) : IPlatformDebugService {
92+ private getDebugServiceByIdentifier ( deviceIdentifier : string ) : IDeviceDebugService {
9393 const device = this . $devicesService . getDeviceByIdentifier ( deviceIdentifier ) ;
9494 return this . getDebugService ( device ) ;
9595 }
9696
97- private attachConnectionErrorHandlers ( platformDebugService : IPlatformDebugService ) {
97+ private attachConnectionErrorHandlers ( platformDebugService : IDeviceDebugService ) {
9898 let connectionErrorHandler = ( e : Error ) => this . emit ( CONNECTION_ERROR_EVENT_NAME , e ) ;
9999 connectionErrorHandler = connectionErrorHandler . bind ( this ) ;
100100 platformDebugService . on ( CONNECTION_ERROR_EVENT_NAME , connectionErrorHandler ) ;
0 commit comments