private void replaceWithLanguageModel(ConstantValue constantValue){
  assert (constantValue.getValue() instanceof String);
  String oldString=(String)constantValue.getValue();
  StringLMOptimizer slmo=new StringLMOptimizer(constantValue,objective);
  String newString=slmo.optimize();
  constantValue.setValue(newString);
  if (!objective.isNotWorse()) {
    constantValue.setValue(oldString);
  }
}

private void replaceWithLanguageModel ( ConstantValue constantValue ) { assert ( constantValue . getValue ( ) instanceof String ) ; String oldString = ( String ) constantValue . getValue ( ) ; StringLMOptimizer slmo = new StringLMOptimizer ( constantValue , objective ) ; String newString = slmo . optimize ( ) ; constantValue . setValue ( newString ) ; if ( ! objective . isNotWorse ( ) ) { constantValue . setValue ( oldString ) ; } }
attempt to use the language model to improve the string constant . if a better string is found that doesn ' t negatively impact the fitness value , statement will be overwritten to use the new improved value .
