private String getCommandParam ( String paramName , String defaultValue ) throws CommandLineParsingException { for ( String param : commandParams ) { if ( ! param . contains ( "=" ) ) { continue ; } String [ ] splitArg = splitArg ( param ) ; String attributeName = splitArg [ 0 ] ; String value = splitArg [ 1 ] ; if ( attributeName . equalsIgnoreCase ( paramName ) ) { return value ; } } return defaultValue ; }
Returns the value for a command line parameter of the form parameterName = value or defaultValue if that parameter has not been specified by the user .