private String assembleStartCommandLine ( ) throws MojoExecutionException { String emulatorPath ; if ( ! "SdkTools" . equals ( parsedEmulatorLocation ) ) { emulatorPath = new File ( parsedEmulatorLocation , parsedExecutable ) . getAbsolutePath ( ) ; } else { emulatorPath = new File ( getAndroidSdk ( ) . getToolsPath ( ) , parsedExecutable ) . getAbsolutePath ( ) ; } StringBuilder startCommandline = new StringBuilder ( "\"\"" ) . append ( emulatorPath ) . append ( "\"\"" ) . append ( " -avd " ) . append ( parsedAvd ) . append ( " " ) ; if ( ! StringUtils . isEmpty ( parsedOptions ) ) { startCommandline . append ( parsedOptions ) ; } getLog ( ) . info ( "Android emulator command: " + startCommandline ) ; return startCommandline . toString ( ) ; }
Assemble the command line for starting the emulator based on the parameters supplied in the pom file and on the command line . It should not be that painful to do work with command line and pom supplied values but evidently it is .