auphong2707/dl4se-code-review-dataset huggingface dataset:
Source:
<code>public void testLayerSwitchTriggeredColorChange() { EmbroideryWorkSpace workSpace = Mockito.mock(DSTWorkSpace.class); <START> ArrayList<StitchPoint> pointList = Mockito.spy(new ArrayList<>()); Mockito.when(pointList.isEmpty()).thenReturn(false); <END> Mockito.when(stream.getPointList()).thenReturn(pointList); StitchCommand previousCommand = new DSTStitchCommand(1, 1, layer - 1, Mockito.mock(Sprite.class)); StitchCommand command = new DSTStitchCommand(xCoord, yCoord, layer, Mockito.mock(Sprite.class)); command.act(workSpace, stream, previousCommand); Mockito.verify(stream, Mockito.times(1)).addColorChange(); Mockito.verify(stream, Mockito.times(1)).addJump(); Mockito.verify(stream, Mockito.times(3)).addStitchPoint(Mockito.eq(1.0f), Mockito.eq(1.0f)); Mockito.verify(stream, Mockito.times(1)).addStitchPoint(Mockito.eq(xCoord), Mockito.eq(yCoord)); }</code><technical_language>Please add element instead of a spy</technical_language>

Target:
public void testLayerSwitchTriggeredColorChange() { ArrayList<StitchPoint> pointList = new ArrayList<>(); pointList.add(mock(StitchPoint.class)); when(stream.getPointList()).thenReturn(pointList); StitchCommand previousCommand = new DSTStitchCommand(1, 1, layer - 1, mock(Sprite.class)); StitchCommand command = new DSTStitchCommand(xCoord, yCoord, layer, mock(Sprite.class)); command.act(workSpace, stream, previousCommand); InOrder inOrder = inOrder(stream); inOrder.verify(stream, times(1)).addColorChange(); inOrder.verify(stream, times(1)).addStitchPoint(eq(1.0f), eq(1.0f)); inOrder.verify(stream, times(1)).addJump(); inOrder.verify(stream, times(2)).addStitchPoint(eq(1.0f), eq(1.0f)); inOrder.verify(stream, times(1)).addStitchPoint(eq(xCoord), eq(yCoord)); }
Source:
<code>public void setup() { context.turnOffAuthorisationSystem(); <START> parentCommunity = CommunityBuilder.createCommunity(context).withName("test").build(); <END> }</code><technical_language>Please do *not* leave authorization turned test methods. This result in unexpected behavior. temporarily turned create (or delete) test content</technical_language>

Target:
public void setup() { context.turnOffAuthorisationSystem(); parentCommunity = CommunityBuilder.createCommunity(context).withName("test").build(); context.restoreAuthSystemState(); }
Source:
<code>protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_sink_to_swim_tutorials); tutorialView = (ImageView) findViewById(R.id.tut); startButton = (ImageView) findViewById(R.id.start_button); startButton.setEnabled(false); curTutorialImage = 1; tutorialView.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View v) { if(curTutorialImage == PowerUpUtils.SWIM_TUTS.length){ } else if (curTutorialImage == PowerUpUtils.SWIM_TUTS.length-1){ tutorialView.setImageDrawable(getResources().getDrawable(PowerUpUtils.SWIM_TUTS[curTutorialImage])); curTutorialImage++; startButton.setVisibility(View.VISIBLE); startButton.setEnabled(true); } else { tutorialView.setImageDrawable(getResources().getDrawable(PowerUpUtils.SWIM_TUTS[curTutorialImage])); curTutorialImage++; } } }); startButton.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View v) { if (startButton.isEnabled()){ Intent intent = new Intent(SinkToSwimTutorials.this,SinkToSwimGame.class); finish(); startActivity(intent); } } }); public void goToMap(){ new GameActivity().gameActivityInstance.finish(); Intent intent = new Intent(this, MapActivity.class); intent.setFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP); startActivity(intent); finish(); } @Override public void onBackPressed() { super.onBackPressed(); <START> goToMap() <END> } }</code><technical_language>Missing ;(semi colon). Syntax Error</technical_language>

Target:
protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_sink_to_swim_tutorials); tutorialView = (ImageView) findViewById(R.id.tut); startButton = (ImageView) findViewById(R.id.start_button); startButton.setEnabled(false); curTutorialImage = 1; tutorialView.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View v) { if(curTutorialImage == PowerUpUtils.SWIM_TUTS.length){ } else if (curTutorialImage == PowerUpUtils.SWIM_TUTS.length-1){ tutorialView.setImageDrawable(getResources().getDrawable(PowerUpUtils.SWIM_TUTS[curTutorialImage])); curTutorialImage++; startButton.setVisibility(View.VISIBLE); startButton.setEnabled(true); } else { tutorialView.setImageDrawable(getResources().getDrawable(PowerUpUtils.SWIM_TUTS[curTutorialImage])); curTutorialImage++; } } }); startButton.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View v) { if (startButton.isEnabled()){ Intent intent = new Intent(SinkToSwimTutorials.this,SinkToSwimGame.class); finish(); startActivity(intent); } } }); }
Source:
<code>public void defaultConfiguration() { <START> loadConfig(DefaultLdapConfig.class); <END> LdapAuthenticationProvider provider = ldapProvider(); LdapAuthoritiesPopulator authoritiesPopulator = getAuthoritiesPopulator(provider); assertThat(authoritiesPopulator).hasFieldOrPropertyWithValue("groupRoleAttribute", "cn"); assertThat(authoritiesPopulator).hasFieldOrPropertyWithValue("groupSearchBase", ""); assertThat(authoritiesPopulator).hasFieldOrPropertyWithValue("groupSearchFilter", "(uniqueMember={0})"); assertThat(ReflectionTestUtils.getField(getAuthoritiesMapper(provider), "prefix")).isEqualTo("ROLE_"); }</code><technical_language>Please SpringTestRule instead of loadConfig. helpful commit 87a216a</technical_language>

Target:
public void defaultConfiguration() { this.spring.register(DefaultLdapConfig.class).autowire(); LdapAuthenticationProvider provider = ldapProvider(); LdapAuthoritiesPopulator authoritiesPopulator = getAuthoritiesPopulator(provider); assertThat(authoritiesPopulator).hasFieldOrPropertyWithValue("groupRoleAttribute", "cn"); assertThat(authoritiesPopulator).hasFieldOrPropertyWithValue("groupSearchBase", ""); assertThat(authoritiesPopulator).hasFieldOrPropertyWithValue("groupSearchFilter", "(uniqueMember={0})"); assertThat(ReflectionTestUtils.getField(getAuthoritiesMapper(provider), "prefix")).isEqualTo("ROLE_"); }
Source:
<code><START> public Status getJobStatus(String jobId) throws IOException { <END> Preconditions.checkArgument(isConnectionOpen(), "Connection must be opened first"); String jobInfoString = SshExecUtils.readCommandOutput( SshExecUtils.sshExec(sshClient, buildOozieJobCommand(jobId, "info"))); return oozieCmdLineParser.readStatusFromJobInfo(jobInfoString); }</code><technical_language>I if change IOException a runtime here</technical_language>

Target:
public Status getJobStatus(String jobId) { SshSimpleConnection sshConnection = sshConnectionManager.getConnection(); Command execResults = sshConnection.execute(buildOozieJobCommand(jobId, "info")); String jobInfoString = SshExecUtils.readCommandOutput(execResults); return oozieCmdLineParser.readStatusFromJobInfo(jobInfoString); }
Source:
<code>public View getView(int position, View convertView, ViewGroup parent) { ThemeViewHolder holder; if (convertView == null || convertView.getTag() == null) { convertView = mInflater.inflate(R.layout.theme_grid_item, parent, false); holder = new ThemeViewHolder(convertView); convertView.setTag(holder); } else { holder = (ThemeViewHolder) convertView.getTag(); } configureThemeImageSize(parent); ThemeModel theme = mThemes.get(position); String screenshotURL = theme.getScreenshotUrl(); String themeId = theme.getThemeId(); boolean isPremium = !theme.isFree(); boolean isCurrent = theme.getActive(); holder.nameView.setText(theme.getName()); if (isPremium) { holder.priceView.setText(theme.getPriceText()); holder.priceView.setVisibility(View.VISIBLE); } else { holder.priceView.setVisibility(View.GONE); } if (!screenshotURL.startsWith(ThemeWebActivity.THEME_HTTP_PREFIX)) { if (screenshotURL.startsWith(" screenshotURL = screenshotURL.substring(2); } screenshotURL = ThemeWebActivity.THEME_HTTPS_PROTOCOL + screenshotURL; } configureImageView(holder, screenshotURL, themeId, isCurrent); configureImageButton(holder, themeId, isPremium, isCurrent); configureCardView(holder, isCurrent); ThemeSectionHeader header = mHeaders.get(position); if (header != null) { holder.headerView.setVisibility(View.VISIBLE); holder.headerText.setText(header.text); <START> holder.headerCount.setText(Integer.toString(header.count)); <END> } else { holder.headerView.setVisibility(View.GONE); } return convertView; }</code><technical_language>String.valueOf(header.count) get rid of localization warning here</technical_language>

Target:
public View getView(int position, View convertView, ViewGroup parent) { ThemeViewHolder holder; if (convertView == null || convertView.getTag() == null) { convertView = mInflater.inflate(R.layout.theme_grid_item, parent, false); holder = new ThemeViewHolder(convertView); convertView.setTag(holder); } else { holder = (ThemeViewHolder) convertView.getTag(); } configureThemeImageSize(parent); ThemeModel theme = mThemes.get(position); String screenshotURL = theme.getScreenshotUrl(); String themeId = theme.getThemeId(); boolean isPremium = !theme.isFree(); boolean isCurrent = theme.getActive(); holder.nameView.setText(theme.getName()); if (isPremium) { holder.priceView.setText(theme.getPriceText()); holder.priceView.setVisibility(View.VISIBLE); } else { holder.priceView.setVisibility(View.GONE); } if (!screenshotURL.startsWith(ThemeWebActivity.THEME_HTTP_PREFIX)) { if (screenshotURL.startsWith(" screenshotURL = screenshotURL.substring(2); } screenshotURL = ThemeWebActivity.THEME_HTTPS_PROTOCOL + screenshotURL; } configureImageView(holder, screenshotURL, themeId, isCurrent); configureImageButton(holder, themeId, isPremium, isCurrent); configureCardView(holder, isCurrent); ThemeSectionHeader header = mHeaders.get(position); if (header != null) { holder.headerView.setVisibility(View.VISIBLE); holder.headerText.setText(header.text); holder.headerCount.setText(String.valueOf(header.count)); } else { holder.headerView.setVisibility(View.GONE); } return convertView; }
Source:
<code>public TJobExecutionStatus forStatus(String status) { try { TezStatus tezStatus = TezStatus.valueOf(status); switch (tezStatus) { case SUBMITTED: case INITING: case RUNNING: return TJobExecutionStatus.IN_PROGRESS; default: return TJobExecutionStatus.COMPLETE; } } catch (IllegalArgumentException ex) { <START> LOG.debug("Could not understand the status from tez execution engine : " + status); <END> return TJobExecutionStatus.NOT_AVAILABLE; } }</code><technical_language>I LOG.warn more suited for this message. expect this happen</technical_language>

Target:
public TJobExecutionStatus forStatus(String status) { if (StringUtils.isEmpty(status)) { return TJobExecutionStatus.NOT_AVAILABLE; } TezStatus tezStatus = TezStatus.valueOf(status); switch (tezStatus) { case SUBMITTED: case INITING: case RUNNING: return TJobExecutionStatus.IN_PROGRESS; default: return TJobExecutionStatus.COMPLETE; } }
Source:
<code>private List<ExternalDiscoveredHost> runDiscoveredHostListMethod(HttpMethod httpMethod) { try{ runHttpMethod(httpClient, httpMethod); ForemanDiscoveredHostWrapper fdw = objectMapper.readValue(httpMethod.getResponseBody(), ForemanDiscoveredHostWrapper.class); return mapDiscoveredHosts(Arrays.asList(fdw.getResults())); <START> } catch (JsonParseException e) { <END> handleException(e); } catch (JsonMappingException e) { handleException(e); } catch (IOException e) { handleException(e); } return null; }</code><technical_language>I is catch (IOException e) { handleException(e); } other IOExceptions handle same. please apply other blocks</technical_language>

Target:
private List<ExternalDiscoveredHost> runDiscoveredHostListMethod(HttpMethod httpMethod) { try{ runHttpMethod(httpClient, httpMethod); ForemanDiscoveredHostWrapper fdw = objectMapper.readValue(httpMethod.getResponseBody(), ForemanDiscoveredHostWrapper.class); return mapDiscoveredHosts(Arrays.asList(fdw.getResults())); } catch (IOException e) { handleException(e); } return null; }
Source:
<code>protected void innerMap( InputRow inputRow, Context context ) throws IOException { final List<Object> groupKey = Rows.toGroupKey( rollupGranularity.bucketStart(inputRow.getTimestamp()).getMillis(), inputRow ); Interval interval; if (determineIntervals) { interval = config.getGranularitySpec() .getSegmentGranularity() .bucket(DateTimes.utc(inputRow.getTimestampFromEpoch())); <START> hyperLogLogs.putIfAbsent(interval, HyperLogLogCollector.makeLatestCollector()); <END> } else { final Optional<Interval> maybeInterval = config.getGranularitySpec() .bucketInterval(DateTimes.utc(inputRow.getTimestampFromEpoch())); if (!maybeInterval.isPresent()) { throw new ISE("WTF?! No bucket found for timestamp: %s", inputRow.getTimestampFromEpoch()); } interval = maybeInterval.get(); } hyperLogLogs .get(interval) .add(hashFunction.hashBytes(HadoopDruidIndexerConfig.JSON_MAPPER.writeValueAsBytes(groupKey)).asBytes()); context.getCounter(HadoopDruidIndexerConfig.IndexJobCounters.ROWS_PROCESSED_COUNTER).increment(1); }</code><technical_language>This is a good candidate for computeIfAbsent</technical_language>

Target:
protected void innerMap( InputRow inputRow, Context context ) throws IOException { final List<Object> groupKey = Rows.toGroupKey( rollupGranularity.bucketStart(inputRow.getTimestamp()).getMillis(), inputRow ); Interval interval; if (determineIntervals) { interval = config.getGranularitySpec() .getSegmentGranularity() .bucket(DateTimes.utc(inputRow.getTimestampFromEpoch())); hyperLogLogs.computeIfAbsent(interval, intv -> HyperLogLogCollector.makeLatestCollector()); } else { final Optional<Interval> maybeInterval = config.getGranularitySpec() .bucketInterval(DateTimes.utc(inputRow.getTimestampFromEpoch())); if (!maybeInterval.isPresent()) { throw new ISE("WTF?! No bucket found for timestamp: %s", inputRow.getTimestampFromEpoch()); } interval = maybeInterval.get(); } hyperLogLogs .get(interval) .add(hashFunction.hashBytes(HadoopDruidIndexerConfig.JSON_MAPPER.writeValueAsBytes(groupKey)).asBytes()); context.getCounter(HadoopDruidIndexerConfig.IndexJobCounters.ROWS_PROCESSED_COUNTER).increment(1); }
Source:
<code>void display(PrintWriter writer) throws UnloggedFailure, OrmException { AccountGroup group = groupCache.get(new AccountGroup.NameKey(name)); String errorText = "Group not found or not visible\n"; if (group == null) { writer.write(errorText); writer.flush(); return; } try { List<AccountInfo> members = apply(group.getGroupUUID()); ColumnFormatter formatter = new ColumnFormatter(writer, '\t'); <START> formatter.addColumn("userid"); <END> formatter.addColumn("name"); formatter.addColumn("email"); formatter.nextLine(); for (AccountInfo member : members) { if (member == null) { continue; } AccountState account = accounts.get(member._id); formatter.addColumn(Objects.firstNonNull( account != null ? account.getUserName() : null, "n/a")); formatter.addColumn(Objects.firstNonNull( Strings.emptyToNull(member.name), "n/a")); formatter.addColumn(Objects.firstNonNull(member.email, "n/a")); formatter.nextLine(); } formatter.finish(); } catch (MethodNotAllowedException e) { writer.write(errorText); writer.flush(); } }</code><technical_language>s/userid/username A user account ID a username, calling username 'userid' is confusing me. introduce a new term for it. Do need show username? If yes, REST API return it</technical_language>

Target:
void display(PrintWriter writer) throws UnloggedFailure, OrmException { AccountGroup group = groupCache.get(new AccountGroup.NameKey(name)); String errorText = "Group not found or not visible\n"; if (group == null) { writer.write(errorText); writer.flush(); return; } try { List<AccountInfo> members = apply(group.getGroupUUID()); ColumnFormatter formatter = new ColumnFormatter(writer, '\t'); formatter.addColumn("id"); formatter.addColumn("username"); formatter.addColumn("full name"); formatter.addColumn("email"); formatter.nextLine(); for (AccountInfo member : members) { if (member == null) { continue; } formatter.addColumn(member._id.toString()); formatter.addColumn(Objects.firstNonNull(member.username, "n/a")); formatter.addColumn(Objects.firstNonNull( Strings.emptyToNull(member.name), "n/a")); formatter.addColumn(Objects.firstNonNull(member.email, "n/a")); formatter.nextLine(); } formatter.finish(); } catch (MethodNotAllowedException e) { writer.write(errorText); writer.flush(); } }
Source:
<code>public DocumentModel getOrCreateDocument(DocumentModel docModel) { <START> return getOrCreateDocument(docModel, null); <END> }</code><technical_language>Function.identity() here, need test nullity after</technical_language>

Target:
public DocumentModel getOrCreateDocument(DocumentModel docModel) { return getOrCreateDocument(docModel, Function.identity()); }
Source:
<code>protected Map<Guid, Guid> addAllTemplateDisks() { processIllegalDisks(); Map<Guid, Guid> <START> idMap = <END> super.addAllTemplateDisks(); if (!idMap.isEmpty()) { lockSnapshot(); } return idMap; }</code><technical_language>please rename reflect ids contained in this map</technical_language>

Target:
protected Map<Guid, Guid> addAllTemplateDisks() { processIllegalDisks(); Map<Guid, Guid> srcDeviceIdToTargetDeviceIdMapping = super.addAllTemplateDisks(); if (!srcDeviceIdToTargetDeviceIdMapping.isEmpty()) { lockSnapshot(); } return srcDeviceIdToTargetDeviceIdMapping; }
Source:
<code>public static void setJobIdOffset(int jobIdOffset) { <START> if (jobIdOffset > JobIds.RESERVED_JOB_ID_RANGE_START - 500) { <END> throw new IllegalArgumentException("offset is too close to Integer.MAX_VALUE"); } JobConfig.jobIdOffset = jobIdOffset; }</code><technical_language>I need update unit tests. Some failing now</technical_language>

Target:
public static void setJobIdOffset(int jobIdOffset) { JobPreconditions.checkArgumentNonnegative(jobIdOffset, "offset can't be negative"); if (jobIdOffset > JobIdsInternal.RESERVED_JOB_ID_RANGE_START - 500) { throw new IllegalArgumentException("offset is too close to Integer.MAX_VALUE"); } JobConfig.jobIdOffset = jobIdOffset; }
Source:
<code>void testFindGetterIdentifier() { AggregateModel<SomeGetterIdAnnotatedHandlers> inspector = AnnotatedAggregateMetaModelFactory.inspectAggregate(SomeGetterIdAnnotatedHandlers.class); assertEquals("SomeGetterIdAnnotatedHandlers", inspector.type()); assertEquals("id", inspector.getIdentifier(new SomeGetterIdAnnotatedHandlers())); <START> assertEquals("getId", inspector.routingKey()); <END> }</code><technical_language>matching models' routing key routing key in @CommandHandler, is expected identical property name in command. So, method name, is validated here. such, remove get prepending routing key if a method</technical_language>

Target:
void testFindGetterIdentifier() { AggregateModel<SomeGetterIdAnnotatedHandlers> inspector = AnnotatedAggregateMetaModelFactory.inspectAggregate(SomeGetterIdAnnotatedHandlers.class); assertEquals("SomeGetterIdAnnotatedHandlers", inspector.type()); assertEquals("id", inspector.getIdentifier(new SomeGetterIdAnnotatedHandlers())); assertEquals("id", inspector.routingKey()); }
Source:
<code>private void shuffleAndPopulate(Map<String, Integer> availableReplicaCountPerDatacenter) { for (String dataCenter : replicaListPerDatacenter.keySet()) { List<ReplicaId> replicaList = shuffleReplicaListForDataCenter(dataCenter, availableReplicaCountPerDatacenter); <START> replicaListPerDatacenter.put(dataCenter, replicaList); <END> replicasInFlightPerDatacenter.put(dataCenter, new ArrayList<ReplicaId>()); } }</code><technical_language>do this line shuffleReplicaListForDataCenter</technical_language>

Target:
private void shuffleAndPopulate(Map<String, Integer> availableReplicaCountPerDatacenter) { for (String dataCenter : replicaListPerDatacenter.keySet()) { shuffleReplicasForDataCenter(dataCenter, availableReplicaCountPerDatacenter); replicasInFlightPerDatacenter.put(dataCenter, new ArrayList<ReplicaId>()); } }
Source:
<code>public static void main(String... args) { EngineConfigCLIParser parser = null; try { parser = new EngineConfigCLIParser(); parser.parse(args); EngineConfigMap argsMap = parser.getEngineConfigMap(); <START> if (argsMap.getLogFile() != null) { <END> JavaLoggingUtils.addFileHandler(argsMap.getLogFile(), argsMap.getLogLevel()); } } catch (Throwable t) { System.out.println(t.getMessage()); System.exit(1); } try { EngineConfig.getInstance().setUpAndExecute(parser); } catch (Throwable t) { LoggerFactory.getLogger(EngineConfigExecutor.class).debug("Exiting with error: ", t); System.out.println(t.getMessage()); System.exit(1); } }</code><technical_language>same... separate parameters, for file for level, detached</technical_language>

Target:
public static void main(String... args) { EngineConfigCLIParser parser = null; try { parser = new EngineConfigCLIParser(); parser.parse(args); EngineConfigMap argsMap = parser.getEngineConfigMap(); if (argsMap.getLogFile() != null) { JavaLoggingUtils.addFileHandler(argsMap.getLogFile()); } if (argsMap.getLogLevel() != null) { JavaLoggingUtils.setLogLevel(argsMap.getLogLevel()); } } catch (Throwable t) { System.out.println(t.getMessage()); System.exit(1); } try { EngineConfig.getInstance().setUpAndExecute(parser); } catch (Throwable t) { LoggerFactory.getLogger(EngineConfigExecutor.class).debug("Exiting with error: ", t); System.out.println(t.getMessage()); System.exit(1); } }
Source:
<code>private Class<?> getImplementationClass() throws NoSuchAlgorithmException { Reference<Class<?>> implementationClassRef = this.implementationClassRef; Class<?> implementationClass = implementationClassRef != null ? implementationClassRef.get() : null; if (implementationClass == null) { ClassLoader classLoader = WildFlyElytronProvider.class.getClassLoader(); try { <START> implementationClass = Class.forName(getClassName(), true, classLoader); <END> } catch (ClassNotFoundException e) { throw log.noSuchAlgorithmCreateService(getType(), getAlgorithm(), e); } this.implementationClassRef = new WeakReference<>(implementationClass); } return implementationClass; }</code><technical_language>parameter set false avoid excess startup overhead</technical_language>

Target:
private Class<?> getImplementationClass() throws NoSuchAlgorithmException { Reference<Class<?>> implementationClassRef = this.implementationClassRef; Class<?> implementationClass = implementationClassRef != null ? implementationClassRef.get() : null; if (implementationClass == null) { ClassLoader classLoader = WildFlyElytronProvider.class.getClassLoader(); try { implementationClass = Class.forName(getClassName(), false, classLoader); } catch (ClassNotFoundException e) { throw log.noSuchAlgorithmCreateService(getType(), getAlgorithm(), e); } this.implementationClassRef = new WeakReference<>(implementationClass); } return implementationClass; }
Source:
<code>public final CloseableStreamBuildListener createBuildListener() throws IOException, InterruptedException { OutputStream logger = createOutputStream(); if (!(loggable instanceof Run<?,?>)) { throw new IOException("Loggable is not a Run instance: " + loggable.getClass()); } Run<?,?> build = (Run<?, ?>)loggable; for (ConsoleLogFilter filter : ConsoleLogFilter.all()) { logger = filter.decorateLogger(build, logger); } final Job<?, ?> project = build.getParent(); <START> if (project instanceof BuildableItemWithBuildWrappers && build instanceof AbstractBuild) { <END> BuildableItemWithBuildWrappers biwbw = (BuildableItemWithBuildWrappers) project; for (BuildWrapper bw : biwbw.getBuildWrappersList()) { logger = bw.decorateLogger((AbstractBuild) build, logger); } } final ConsoleLogFilter f = getExtraConsoleLogFilter(); if (f != null) { LOGGER.log(Level.INFO, "Decorated run {0} by a custom log filter {1}", new Object[]{this, f}); logger = f.decorateLogger(build, logger); } return new CloseableStreamBuildListener(logger, getOwner().getCharset()); }</code><technical_language>This a failure of abstraction</technical_language>

Target:
public final StreamBuildListener createBuildListener() throws IOException, InterruptedException { OutputStream logger = createOutputStream(); if (!(loggable instanceof Run<?,?>)) { throw new IOException("Loggable is not a Run instance: " + loggable.getClass()); } Run<?,?> build = (Run<?, ?>)loggable; for (ConsoleLogFilter filter : ConsoleLogFilter.all()) { logger = filter.decorateLogger(build, logger); } final Job<?, ?> project = build.getParent(); if (project instanceof BuildableItemWithBuildWrappers && build instanceof AbstractBuild) { BuildableItemWithBuildWrappers biwbw = (BuildableItemWithBuildWrappers) project; for (BuildWrapper bw : biwbw.getBuildWrappersList()) { logger = bw.decorateLogger((AbstractBuild) build, logger); } } final ConsoleLogFilter f = getExtraConsoleLogFilter(); if (f != null) { LOGGER.log(Level.INFO, "Decorated run {0} by a custom log filter {1}", new Object[]{this, f}); logger = f.decorateLogger(build, logger); } return new StreamBuildListener(logger, getOwner().getCharset()); }
Source:
<code>public void renameAndAddIndexedField() { final int oldTestVal = 7; final Long testVal = Long.valueOf(293); RealmMigration migration = new RealmMigration() { @Override public void migrate(DynamicRealm realm, long oldVersion, long newVersion) { realm.schema.get("MigrationIndexedFieldRenamed") .renameField("testField", "oldTestField") .addField("testField", Long.class); } }; RealmConfiguration config = configFactory.createConfigurationBuilder() .schema(MigrationIndexedFieldRenamed.class) .schemaVersion(2) .migration(migration) .assetFile("rename-and-add-indexed.realm") .build(); realm = Realm.getInstance(config); realm.beginTransaction(); MigrationIndexedFieldRenamed obj = realm.createObject(MigrationIndexedFieldRenamed.class, 2); obj.oldTestField = oldTestVal; obj.testField = testVal; realm.commitTransaction(); assertTrue(realm.getSchema().get("MigrationIndexedFieldRenamed").hasField("testField")); <START> assertTrue(realm.getSchema().get("MigrationIndexedFieldRenamed").hasField("oldTestField")); <END> RealmResults<MigrationIndexedFieldRenamed> result = realm.where(MigrationIndexedFieldRenamed.class).equalTo("id", 2).findAll(); assertEquals("There should be an object with PK=2", 1, result.size()); assertEquals("Unexpected oldTestField value", oldTestVal, result.first().oldTestField); assertEquals("Unexpected testField value", testVal, result.first().testField); realm.close(); }</code><technical_language>check if index is preserved. original issue is wrong number of columns, worth check too</technical_language>

Target:
public void renameAndAddIndexedField() { final Class<MigrationIndexedFieldRenamed> schemaClass = MigrationIndexedFieldRenamed.class; final int oldTestVal = 7; final Long testVal = Long.valueOf(293); RealmMigration migration = new RealmMigration() { @Override public void migrate(DynamicRealm realm, long oldVersion, long newVersion) { realm.getSchema().get(schemaClass.getSimpleName()) .renameField("testField", "oldTestField") .addField("testField", Long.class); } }; RealmConfiguration config = configFactory.createConfigurationBuilder() .schema(schemaClass) .schemaVersion(2) .migration(migration) .assetFile("rename-and-add-indexed.realm") .build(); realm = Realm.getInstance(config); realm.beginTransaction(); MigrationIndexedFieldRenamed obj = realm.createObject(schemaClass, 2); obj.oldTestField = oldTestVal; obj.testField = testVal; realm.commitTransaction(); RealmObjectSchema schema = realm.getSchema().get(schemaClass.getSimpleName()); assertTrue(schema.hasField("testField")); assertTrue(schema.hasField("oldTestField")); assertTrue(schema.hasIndex("oldTestField")); RealmResults<MigrationIndexedFieldRenamed> result = realm.where(schemaClass).equalTo("id", 2).findAll(); assertEquals("There should be an object with PK=2", 1, result.size()); assertEquals("Unexpected oldTestField value", oldTestVal, result.first().oldTestField); assertEquals("Unexpected testField value", testVal, result.first().testField); realm.close(); }
Source:
<code>public void close() { logger.debug("Closing connection to broker '{}'", name); try { if (started) { client.disconnect(); } } catch (MqttException e) { <START> logger.error(String.format("Error closing connection to broker '{}'", name), e); <END> } started = false; }</code><technical_language>in logger.error String.format called implicitly</technical_language>

Target:
public void close() { logger.debug("Closing connection to broker '{}'", name); try { if (started) { client.disconnect(); } } catch (MqttException e) { logger.error("Error closing connection to broker", e); } started = false; }
Source:
<code>public Object convert(Object value) { <START> Object convertedValue; if (isInstanceOfMultiValue(value)) { convertedValue = convertMultiValue(value); } else if (isInstanceOfMap(value)) { convertedValue = convertMap(value); } else if (isInstanceOfRecord(value)) { convertedValue = convertRecord(value); } else { convertedValue = convertSingleValue(value); } return convertedValue; <END> }</code><technical_language>Suggest renaming some methods: suggestion if (isMultiValue(value)) { return convertMultiValue(value); } else if (isMap(value)) { return convertMap(value); } else if (isRecord(value)) { return convertRecord(value); } else { return convertSingleValue(value); }</technical_language>

Target:
public Object convert(Object value) { Object convertedValue; if (isMultiValue(value)) { convertedValue = convertMultiValue(value); } else if (isMap(value)) { convertedValue = convertMap(value); } else if (isRecord(value)) { convertedValue = convertRecord(value); } else { convertedValue = convertSingleValue(value); } return convertedValue; }
Source:
<code>public PlanningErrorException(Throwable e) { <START> super(e.getCause()); <END> }</code><technical_language>setting of this exception of e? e next constructor</technical_language>

Target:
public PlanningErrorException(Throwable e) { super(e); }
Source:
<code>public boolean verifyOrder(String[] testNames) throws IllegalArgumentException { int testIndex = 0; int testLength = testNames.length; if (testLength == 0) return true; <START> for (int nX = 0; nX < methodList.size(); nX++) { <END> String methodName = methodList.get(nX); String testName = testNames[testIndex]; testMethodName(testName); if (testName.equals(methodName)) ++testIndex; if (testIndex >= testLength) return true; } return false; }</code><technical_language>replace this fashioned for loop foreach loop like: for(String methodName : methodList){ .... }</technical_language>

Target:
public boolean verifyOrder(String[] testNames) throws IllegalArgumentException { int testIndex = 0; int testLength = testNames.length; if (testLength == 0) return true; for (String methodName : methodList) { String testName = testNames[testIndex]; testMethodName(testName); if (testName.equals(methodName)) ++testIndex; if (testIndex >= testLength) return true; } return false; }
Source:
<code>public FileStatus getFileStatus(Path path) throws IOException { if (files.containsKey(path)) { return generateURIStatus(path, files.get(path).length); <START> } <END> else { throw new FileNotFoundException(path.toString()); } }</code><technical_language>remove else</technical_language>

Target:
public FileStatus getFileStatus(Path path) { if (files.containsKey(path)) { return generateURIStatus(path, files.get(path).length); } return null; }
Source:
<code><START> public void testSwapRefAlt(final VariantContext swapMe, final VariantContext expected) throws Exception { <END> VcfTestUtils.assertEquals(LiftoverUtils.swapRefAlt(swapMe, annotationsToSwap, annotationsToDrop), expected); }</code><technical_language>Test throw exception</technical_language>

Target:
public void testSwapRefAlt(final VariantContext swapMe, final VariantContext expected) { VcfTestUtils.assertEquals(LiftoverUtils.swapRefAlt(swapMe, annotationsToSwap, annotationsToDrop), expected); }
Source:
<code>public boolean isValid(String type, ConstraintValidatorContext context) { boolean isValid = catalog.isSupported(type); if (!isValid) { <START> context.buildConstraintViolationWithTemplate("unsupported operation"); <END> } return isValid; }</code><technical_language>pass message in annotation</technical_language>

Target:
public boolean isValid(String type, ConstraintValidatorContext context) { boolean isValid = catalog.isSupported(type); if (!isValid) { String message = context.getDefaultConstraintMessageTemplate(); context.buildConstraintViolationWithTemplate(message); } return isValid; }
Source:
<code>private void updateOverlayCoverageLayer(int zoomLevel) { final List<Overlay> overlays = mMap.getOverlays(); <START> if (mCoverageTilesOverlayLowZoom == null || mCoverageTilesOverlayHighZoom == null <END> || zoomLevel < CoverageOverlay.LOW_ZOOM_LEVEL) { if (mCoverageTilesOverlayDefaultZoom != null && !overlays.contains(mCoverageTilesOverlayDefaultZoom)) { overlays.remove(mCoverageTilesOverlayLowZoom); overlays.remove(mCoverageTilesOverlayHighZoom); overlays.add(0, mCoverageTilesOverlayDefaultZoom); mMap.invalidate(); } return; } final Overlay overlayRemoved = (!isHighZoom(zoomLevel)) ? mCoverageTilesOverlayHighZoom : mCoverageTilesOverlayLowZoom; final Overlay overlayAdded = (isHighZoom(zoomLevel)) ? mCoverageTilesOverlayHighZoom : mCoverageTilesOverlayLowZoom; overlays.remove(overlayRemoved); overlays.remove(mCoverageTilesOverlayDefaultZoom); if (!overlays.contains(overlayAdded)) { boolean hasMapOverlay = overlays.contains(mLowResMapOverlayHighZoom) || overlays.contains(mLowResMapOverlayLowZoom); int idx = hasMapOverlay ? 1 : 0; overlays.add(idx, overlayAdded); mMap.invalidate(); } }</code><technical_language>precondition of this function line: if (!isCoverageTilesInitialized()) { return; }</technical_language>

Target:
private void updateOverlayCoverageLayer(int zoomLevel) { if (mCoverageTilesOverlayLowZoom == null || mCoverageTilesOverlayHighZoom == null || mCoverageTilesOverlayOriginalZoom == null) { return; } final List<Overlay> overlays = mMap.getOverlays(); if (zoomLevel < CoverageOverlay.LOW_ZOOM_LEVEL) { if (!overlays.contains(mCoverageTilesOverlayOriginalZoom)) { overlays.remove(mCoverageTilesOverlayLowZoom); overlays.remove(mCoverageTilesOverlayHighZoom); overlays.add(0, mCoverageTilesOverlayOriginalZoom); mMap.invalidate(); } return; } final Overlay overlayRemoved = (!isHighZoom(zoomLevel)) ? mCoverageTilesOverlayHighZoom : mCoverageTilesOverlayLowZoom; final Overlay overlayAdded = (isHighZoom(zoomLevel)) ? mCoverageTilesOverlayHighZoom : mCoverageTilesOverlayLowZoom; overlays.remove(overlayRemoved); overlays.remove(mCoverageTilesOverlayOriginalZoom); if (!overlays.contains(overlayAdded)) { boolean hasMapOverlay = overlays.contains(mLowResMapOverlayHighZoom) || overlays.contains(mLowResMapOverlayLowZoom); int idx = hasMapOverlay ? 1 : 0; overlays.add(idx, overlayAdded); mMap.invalidate(); } }
Source:
<code>public void changeProjectFeatureFlag() throws Exception { boolean value = false; final FeatureFlagService featureFlagService = gd.getFeatureFlagService(); ProjectFeatureFlag featureFlag = featureFlagService.getProjectFeatureFlag(project, PROJECT_FEATURE_FLAG); featureFlag.setEnabled(value); featureFlagService.updateProjectFeatureFlag(featureFlag); int count = 0; <START> while (count++ < 20) { <END> featureFlag = featureFlagService.getProjectFeatureFlag(project, PROJECT_FEATURE_FLAG); checkProjectFeatureFlag(featureFlag, PROJECT_FEATURE_FLAG, value); value = !value; featureFlag.setEnabled(value); featureFlagService.updateProjectFeatureFlag(featureFlag); } }</code><technical_language>discussion, this cycle redudndant single check enough</technical_language>

Target:
public void changeProjectFeatureFlag() throws Exception { final FeatureFlagService featureFlagService = gd.getFeatureFlagService(); ProjectFeatureFlag featureFlag = featureFlagService.getProjectFeatureFlag(project, PROJECT_FEATURE_FLAG); boolean value = !featureFlag.isEnabled(); featureFlag.setEnabled(value); featureFlagService.updateProjectFeatureFlag(featureFlag); checkProjectFeatureFlag(featureFlag, PROJECT_FEATURE_FLAG, value); }
Source:
<code>public void process() { PerformanceMonitor.startActivity("rendering/backdrop"); FBO sceneOpaqueFbo = displayResolutionDependentFBOs.get(new ResourceUrn("engine:sceneOpaque")); <START> sceneOpaqueFbo.bind(); END> sceneOpaqueFbo.setRenderBufferMask(true, false, false); glCallList(skySphere); sceneOpaqueFbo.setRenderBufferMask(true, true, true); PerformanceMonitor.endActivity(); }</code><technical_language>above, instantiate FBO process try BindFBO in initialize() instead of this bind() line</technical_language>

Target:
public void process() { PerformanceMonitor.startActivity("rendering/backdrop"); sceneOpaqueFbo.bind(); sceneOpaqueFbo.setRenderBufferMask(true, false, false); glCallList(skySphere); sceneOpaqueFbo.setRenderBufferMask(true, true, true); PerformanceMonitor.endActivity(); }
Source:
<code>private void fetchNextIfNeeded() { if (!isNextFetched) { isNextFetched = true; <START> if (next == null) { <END> next = isAscending ? range.getFrom() : range.getTo(); } else { next = isAscending ? increment(next) : decrement(next); } } }</code><technical_language>a check next = null good enough. if null is bound? I avoid this leading endless lopps</technical_language>

Target:
private void fetchNextIfNeeded() { if (!isNextFetched) { isNextFetched = true; if (next == null) { next = isAscending ? range.getFrom() : range.getTo(); } else { next = isAscending ? increment(next, step) : decrement(next, step); } } }
Source:
<code>public void process(Exchange exchange) { String issueKey = exchange.getIn().getHeader(ISSUE_KEY, String.class); if (issueKey == null) { throw new IllegalArgumentException("Missing exchange input header named " + ISSUE_KEY); } JiraRestClient client = ((JiraEndpoint) getEndpoint()).getClient(); IssueRestClient issueClient = client.getIssueClient(); Issue issue = issueClient.getIssue(issueKey).claim(); if (exchange.getPattern().isOutCapable()) { <START> exchange.getOut().copyFrom(exchange.getIn()); <END> exchange.getOut().setBody(issue); } else { exchange.getIn().setBody(issue); } }</code><technical_language>If mistaken, exchange().getOut() [deprecated](<LINK_0> in favour of exchange().getMessage()</technical_language>

Target:
public void process(Exchange exchange) { String issueKey = exchange.getIn().getHeader(ISSUE_KEY, String.class); if (issueKey == null) { throw new IllegalArgumentException("Missing exchange input header named " + ISSUE_KEY); } JiraRestClient client = ((JiraEndpoint) getEndpoint()).getClient(); IssueRestClient issueClient = client.getIssueClient(); Issue issue = issueClient.getIssue(issueKey).claim(); exchange.getMessage().setBody(issue); }
Source:
<code>public ResponseEntity<List<DownloadBundleDTO>> getDownloadHistory(Principal principal) throws PermissionDeniedException { final AthenaUser user = userService.getUser(principal); <START> return ResponseEntity.ok(vocabularyService.getDownloadHistory(user.getId())); <END> }</code><technical_language>entity</technical_language>

Target:
public List<DownloadBundleDTO> getDownloadHistory(Principal principal) throws PermissionDeniedException { final AthenaUser user = userService.getUser(principal); return vocabularyService.getDownloadHistory(user.getId()); }
Source:
<code><START> public void rm(String key) throws IOException { <END> key = key.replace(" ", ""); zkState.delete(key); }</code><technical_language>this method deserves a description</technical_language>

Target:
public void rm(String key) throws IOException { zkState.delete(key); }
Source:
<code><START> private void updateQuerySource(BrokerRequest brokerRequest) { <END> String tableName = brokerRequest.getQuerySource().getTableName(); String[] querySourceSplits = tableName.split("\\.", 2); if (querySourceSplits.length != 2) { return; } if (_enableCaseInsensitive && _tableCache.existTableName(querySourceSplits[1]) && !_tableCache .existTableName(tableName)) { brokerRequest.getQuerySource().setTableName(querySourceSplits[1]); return; } TableType tableType = TableNameBuilder.getTableTypeFromTableName(tableName); if (tableType != null && _routingManager.routingExists(querySourceSplits[1]) && !_routingManager .routingExists(tableName)) { brokerRequest.getQuerySource().setTableName(querySourceSplits[1]); return; } if (_routingManager.routingExists(TableNameBuilder.REALTIME.tableNameWithType(querySourceSplits[1])) && !_routingManager.routingExists(TableNameBuilder.REALTIME.tableNameWithType(tableName))) { brokerRequest.getQuerySource().setTableName(querySourceSplits[1]); return; } if (_routingManager.routingExists(TableNameBuilder.OFFLINE.tableNameWithType(querySourceSplits[1])) && !_routingManager.routingExists(TableNameBuilder.OFFLINE.tableNameWithType(tableName))) { brokerRequest.getQuerySource().setTableName(querySourceSplits[1]); } }</code><technical_language>this done in PinotQuery2BrokerRequestConverter</technical_language>

Target:
private void updateQuerySource(BrokerRequest brokerRequest) { String tableName = brokerRequest.getQuerySource().getTableName(); String[] tableNameSplits = StringUtils.split(tableName, '.'); if (tableNameSplits.length != 2) { return; } if (_enableCaseInsensitive) { if (_tableCache.containsTable(tableNameSplits[1]) && !_tableCache.containsTable(tableName)) { brokerRequest.getQuerySource().setTableName(tableNameSplits[1]); } return; } if (TableNameBuilder.isTableResource(tableName)) { if (_routingManager.routingExists(tableNameSplits[1]) && !_routingManager.routingExists(tableName)) { brokerRequest.getQuerySource().setTableName(tableNameSplits[1]); } return; } if (_routingManager.routingExists(TableNameBuilder.REALTIME.tableNameWithType(tableNameSplits[1])) && !_routingManager.routingExists(TableNameBuilder.REALTIME.tableNameWithType(tableName))) { brokerRequest.getQuerySource().setTableName(tableNameSplits[1]); return; } if (_routingManager.routingExists(TableNameBuilder.OFFLINE.tableNameWithType(tableNameSplits[1])) && !_routingManager.routingExists(TableNameBuilder.OFFLINE.tableNameWithType(tableName))) { brokerRequest.getQuerySource().setTableName(tableNameSplits[1]); } }
Source:
<code>public void visitNode(AstNode node) { if (CheckUtils.isMethodDefinition(node) && !alreadyStaticMethod(node) && hasValuableCode(node)){ String self = getFirstArgument(node); <START> if (self != null && !isUsed(node, self) &&!isDocStringsAndNotImplementedError(node)){ <END> getContext().createLineViolation(this, MESSAGE, node.getFirstChild(PythonGrammar.FUNCNAME)); } } }</code><technical_language>@ivandalbosco super minor: space !isDocStringsAndNotImplementedError(node)</technical_language>

Target:
public void visitNode(AstNode node) { if (CheckUtils.isMethodDefinition(node) && !alreadyStaticMethod(node) && hasValuableCode(node)){ String self = getFirstArgument(node); if (self != null && !isUsed(node, self) && !onlyRaisesNotImplementedError(node)){ getContext().createLineViolation(this, MESSAGE, node.getFirstChild(PythonGrammar.FUNCNAME)); } } }
Source:
<code>public ExecutionResult execute(final TaskConfig config, final TaskExecutionContext taskExecutionContext) { return pluginRequestHelper.submitRequest(pluginId, JsonBasedTaskExtension.EXECUTION_REQUEST, new PluginInteractionCallback<ExecutionResult>() { @Override public String requestBody(String resolvedExtensionVersion) { return handlerMap.get(resolvedExtensionVersion).getTaskExecutionBody(config, taskExecutionContext); } @Override public Map<String, Object> requestParams(String resolvedExtensionVersion) { final LinkedHashMap params = new LinkedHashMap(); <START> params.put("console", new ConsoleWrapper(taskExecutionContext)); <END> return params; } @Override public ExecutionResult onSuccess(String responseBody, String resolvedExtensionVersion) { return handlerMap.get(resolvedExtensionVersion).toExecutionResult(responseBody); } }); }</code><technical_language>This is part in this PR concerned about. Rethink this change <String, String> <String, Object>. Talk @pshivana. @Load mechanism instead provide a get this, GoApplicationAccessor. I changes job, job runs in agent a time. issue I changing Object is this is longer serializable. If want move plugins out a process, cannot. Ideally, this wrapper object (as spoken). a message based API well, plugin use. But, I this is done (for convenience of plugin developer) I agree. But, I this passed in request params</technical_language>

Target:
public ExecutionResult execute(final TaskConfig config, final TaskExecutionContext taskExecutionContext) { return pluginRequestHelper.submitRequest(pluginId, JsonBasedTaskExtension.EXECUTION_REQUEST, new PluginInteractionCallback<ExecutionResult>() { @Override public String requestBody(String resolvedExtensionVersion) { return handlerMap.get(resolvedExtensionVersion).getTaskExecutionBody(config, taskExecutionContext); } @Override public Map<String, String> requestParams(String resolvedExtensionVersion) { return null; } @Override public ExecutionResult onSuccess(String responseBody, String resolvedExtensionVersion) { return handlerMap.get(resolvedExtensionVersion).toExecutionResult(responseBody); } }); }
Source:
<code>public static IndexWriterConfig population() { IndexWriterConfig writerConfig = standard(); writerConfig.setMaxBufferedDocs( POPULATION_MAX_BUFFERED_DOCS ); writerConfig.setRAMBufferSizeMB( POPULATION_RAM_BUFFER_SIZE_MB ); return writerConfig; <START> } <END></code><technical_language>if need another population configuration delegate of work default instead of copy pasting</technical_language>

Target:
public static IndexWriterConfig population() { Analyzer analyzer = LuceneDataSource.KEYWORD_ANALYZER; return population( analyzer ); }
Source:
<code>private void addBootstrap3And4Style( <START> String bootstrap3FileName, InputStream bootstrap3Data, Resource bootstrap4resource) { <END> try (InputStream bootstrap4Data = bootstrap4resource.getInputStream()) { String bootstrap4FileName = bootstrap4resource.getFilename(); LOG.debug("Adding matching bootstrap 4 theme with name {}", bootstrap4FileName); styleService.addStyle( bootstrap3FileName, bootstrap3FileName, bootstrap3Data, bootstrap4FileName, bootstrap4Data); } catch (IOException e) { LOG.error("error adding new bootstrap 4 theme", e); } }</code><technical_language>Is a bit surprising InputStream Resource</technical_language>

Target:
private void addBootstrap3And4Style( String bootstrap3FileName, InputStream bootstrap3Data, Resource bootstrap4resource) { try (InputStream bootstrap4Data = bootstrap4resource.getInputStream()) { String bootstrap4FileName = bootstrap4resource.getFilename(); LOG.debug("Adding matching bootstrap 4 theme with name {}", bootstrap4FileName); styleService.addStyle( bootstrap3FileName, bootstrap3FileName, bootstrap3Data, bootstrap4FileName, bootstrap4Data); } catch (Exception e) { LOG.error("error adding new bootstrap 4 theme", e); } }
Source:
<code>public ProvisionAdviceHolder(Binding<T> binding, AdviceElementImpl element) { Method member = (Method)element.injectionPoint.getMember(); <START> this.order = Optional.ofNullable(member.getAnnotation(Order.class)).map(order -> order.value()).orElse(1000); <END> this.binding = binding; }</code><technical_language>1000</technical_language>

Target:
public ProvisionAdviceHolder(Binding<T> binding, AdviceElementImpl element) { this.order = ((Advises)(element.getQualifier())).order(); this.binding = binding; }
Source:
<code>private void verifyNotEmpty(String name, String value) throws ConfigurationException { <START> if (org.apache.commons.lang.StringUtils.isEmpty(value)) { <END> throw new ConfigurationException("Unable to find " + name); } }</code><technical_language>import org.apache.commons.lang package avoid some clutter</technical_language>

Target:
private void verifyNotEmpty(String name, String value) throws ConfigurationException { if (StringUtils.isEmpty(value)) { throw new ConfigurationException("Unable to find " + name); } }