auphong2707/dl4se-code-review-dataset huggingface dataset:
Source:
static <C extends Condition, CPS extends AbstractConditionParserState<C>> C parseCondition( ObjectParser<CPS, QueryParseContext> condParser, XContentParser parser, QueryParseContext parseContext ) throws IOException { CPS state = condParser.parse(parser, parseContext); String error = state.checkValid(); if (error != null) { throw new ParsingException(parser.getTokenLocation(), error); } return state.condition(); }

Target:
static <C extends Condition, CPS extends AbstractConditionParserState<C>> C parseCondition( ObjectParser<CPS, QueryParseContext> condParser, XContentParser parser, QueryParseContext parseContext ) throws IOException { CPS state = condParser.parse(parser, parseContext); state.checkValid(); return state.condition(); }
Source:
protected void configure() { bind(SitePaths.class); bind(InitFlags.class); bind(Libraries.class); bind(LibraryDownloader.class); factory(Section.Factory.class); step().to(UpgradeFrom2_0_x.class); step().to(InitGitManager.class); if (initDb) { step().to(InitDatabase.class); } step().to(InitIndex.class); step().to(InitAuth.class); step().to(InitLabels.class); step().to(InitSendEmail.class); if (standalone) { step().to(InitContainer.class); } step().to(InitSshd.class); step().to(InitHttpd.class); step().to(InitCache.class); step().to(InitAdminUser.class); step().to(InitPlugins.class); }

Target:
protected void configure() { bind(SitePaths.class); bind(InitFlags.class); bind(Libraries.class); bind(LibraryDownloader.class); factory(Section.Factory.class); step().to(UpgradeFrom2_0_x.class); step().to(InitGitManager.class); if (initDb) { step().to(InitDatabase.class); } step().to(InitIndex.class); step().to(InitAuth.class); step().to(InitAdminUser.class); step().to(InitLabels.class); step().to(InitSendEmail.class); if (standalone) { step().to(InitContainer.class); } step().to(InitSshd.class); step().to(InitHttpd.class); step().to(InitCache.class); step().to(InitPlugins.class); }
Source:
public static FileOutputStream createFile(final Context context, final String filename) throws IOException { final String filepath = getSDPath(); final File path = new File(filepath); final boolean hasSD = MainActivity.hasSD(); if (hasSD) { path.mkdirs(); final String openString = filepath + filename; MainActivity.info("openString: " + openString); final File file = new File(openString); if (!file.exists()) { if (!file.createNewFile()) { throw new IOException("Could not create file: " + openString); } } return new FileOutputStream(file); } if (Build.VERSION.SDK_INT >= 23) { return context.openFileOutput(filename, Context.MODE_PRIVATE); } else { return context.openFileOutput(filename, Context.MODE_WORLD_READABLE); } }

Target:
public static FileOutputStream createFile(final Context context, final String filename) throws IOException { final String filepath = getSDPath(); final File path = new File(filepath); final boolean hasSD = MainActivity.hasSD(); if (hasSD) { path.mkdirs(); final String openString = filepath + filename; MainActivity.info("openString: " + openString); final File file = new File(openString); if (!file.exists()) { if (!file.createNewFile()) { throw new IOException("Could not create file: " + openString); } } return new FileOutputStream(file); } return context.openFileOutput(filename, Context.MODE_PRIVATE); }
Source:
protected void executeQueryCommand() { clusterId = getParameters().getClusterId(); Guid volumeId = getParameters().getVolumeId(); if (volumeId != null) { volume = getGlusterVolumeDao().getById(volumeId); if (volume == null) { throw new RuntimeException(String.format("Invalid volume id %s", volumeId)); } asyncTask = volume.getAsyncTask(); if(asyncTask == null) { getQueryReturnValue().setReturnValue(null); return; } getQueryReturnValue().setReturnValue(fetchTaskStatusDetails()); } }

Target:
protected void executeQueryCommand() { clusterId = getParameters().getClusterId(); if (clusterId == null) { clusterId = volume.getClusterId(); } Guid volumeId = getParameters().getVolumeId(); if (volumeId != null) { volume = getGlusterVolumeDao().getById(volumeId); if (volume == null) { throw new RuntimeException(VdcBllMessages.ACTION_TYPE_FAILED_GLUSTER_VOLUME_INVALID.toString()); } asyncTask = volume.getAsyncTask(); if (asyncTask == null) { getQueryReturnValue().setReturnValue(null); return; } getQueryReturnValue().setReturnValue(fetchTaskStatusDetails()); } }
Source:
public String queryGC100(String getDevices, String sourceAddress) throws IOException { List<String> deviceList = new ArrayList<String>(); Socket socket = new Socket(sourceAddress, GC100IRControlPoint.CONNECT_PORT); SocketAddress socketAddress = socket.getRemoteSocketAddress(); if (socket.isConnected()) { logger.info("Connected Successfully to " + socketAddress); } DataOutputStream outToServer = new DataOutputStream(socket.getOutputStream()); BufferedReader inFromServer = new BufferedReader(new InputStreamReader(socket.getInputStream())); byte[] commandInBytes = getDevices.getBytes(); outToServer.write(commandInBytes); int c; StringBuilder response = new StringBuilder(); while ((c = inFromServer.read()) != '\0') { response.append((char) c); if (c == 13) { deviceList.add(response.toString()); response = new StringBuilder(); } if (response.toString().equals(END_LIST_DEVICES)) { break; } } StringBuilder temp = new StringBuilder(); for (String deviceStr : deviceList) { temp.append(deviceStr); } try { socket.close(); } catch (SocketException e) { logger.warn("Socket Exception occurred", e); } return temp.toString(); }

Target:
public String queryGC100(String getDevices, String sourceAddress) throws IOException { List<String> deviceList = new ArrayList<String>(); Socket socket = new Socket(sourceAddress, GC100IRControlPoint.CONNECT_PORT); SocketAddress socketAddress = socket.getRemoteSocketAddress(); if (socket.isConnected()) { logger.info("Connected Successfully to {}", socketAddress); } DataOutputStream outToServer = new DataOutputStream(socket.getOutputStream()); BufferedReader inFromServer = new BufferedReader(new InputStreamReader(socket.getInputStream())); byte[] commandInBytes = getDevices.getBytes(); outToServer.write(commandInBytes); int c; StringBuilder response = new StringBuilder(); while ((c = inFromServer.read()) != '\0') { response.append((char) c); if (c == 13) { deviceList.add(response.toString()); response = new StringBuilder(); } if (response.toString().equals(END_LIST_DEVICES)) { break; } } StringBuilder temp = new StringBuilder(); for (String deviceStr : deviceList) { temp.append(deviceStr); } try { socket.close(); } catch (SocketException e) { logger.warn("Socket Exception occurred", e); } return temp.toString(); }
Source:
private static void addExtensionLink(LinkMenuBar m, TopMenuItem item) { Anchor atag; if (item.getUrl() != null && isAbsolute(item.getUrl())) { atag = anchor(item.getName(), item.getUrl()); } else { atag = anchor(item.getName(), selfRedirect(item.getUrl())); } atag.setTarget(item.getTarget()); if (item.getId() != null) { atag.getElement().setAttribute("id", item.getId()); } m.add(atag); }

Target:
private static void addExtensionLink(LinkMenuBar m, TopMenuItem item) { Anchor atag = anchor(item.getName(), isAbsolute(item.getUrl()) ? item.getUrl() : selfRedirect(item.getUrl())); atag.setTarget(item.getTarget()); if (item.getId() != null) { atag.getElement().setAttribute("id", item.getId()); } m.add(atag); }
Source:
private static List<Storage> buildMountsList(Context context, Collection<String> mounts) { List<Storage> list = new ArrayList<Storage>(mounts.size()); int externalSdcardsCount = 0; if (mounts.size() > 0) { String firstItem = mounts.iterator().next(); if (!Environment.isExternalStorageRemovable() || Environment.isExternalStorageEmulated()) { list.add(new Storage(context.getString(R.string.prefs_sdcard_internal), firstItem)); } else { externalSdcardsCount = 1; list.add(new Storage(context.getString(R.string.prefs_sdcard_external, externalSdcardsCount), firstItem)); } if (mounts.size() > 1) { Iterator<String> iter = mounts.iterator(); iter.next(); externalSdcardsCount++; while (iter.hasNext()) { String mount = iter.next(); list.add(new Storage(context.getString(R.string.prefs_sdcard_external, externalSdcardsCount++), mount)); } } } Log.d(TAG, "final storage list is: " + list); return list; }

Target:
private static List<Storage> buildMountsList(Context context, Collection<String> mounts) { List<Storage> list = new ArrayList<>(mounts.size()); int externalSdcardsCount = 0; if (mounts.size() > 0) { String firstItem = mounts.iterator().next(); if (!Environment.isExternalStorageRemovable() || Environment.isExternalStorageEmulated()) { list.add(new Storage(context.getString(R.string.prefs_sdcard_internal), firstItem)); } else { externalSdcardsCount = 1; list.add(new Storage(context.getString(R.string.prefs_sdcard_external, externalSdcardsCount), firstItem)); } if (mounts.size() > 1) { Iterator<String> iter = mounts.iterator(); iter.next(); externalSdcardsCount++; while (iter.hasNext()) { String mount = iter.next(); list.add(new Storage(context.getString(R.string.prefs_sdcard_external, externalSdcardsCount++), mount)); } } } Log.d(TAG, "final storage list is: " + list); return list; }
Source:
public void registerSynchronization(Synchronization synchronization) { if (transactionSynchronizationRegistry == null) { throw JpaLogger.JPA_LOGGER.nullTransactionSynchronizationRegistry(); } transactionSynchronizationRegistry.registerInterposedSynchronization(synchronization); }

Target:
public void registerSynchronization(Synchronization synchronization) { locateTransactionSynchronizationRegistry(). registerInterposedSynchronization(synchronization); }
Source:
protected void testExecute_withCourseIdAndSectionNameAndSessionName_shouldUpdatePrivilegesInSessionLevel() { InstructorAttributes instructor1OfCourse1 = typicalBundle.instructors.get("instructor1OfCourse1"); String[] submissionParams = new String[] { Const.ParamsNames.INSTRUCTOR_ID, instructor1OfCourse1.getGoogleId(), Const.ParamsNames.COURSE_ID, instructor1OfCourse1.courseId, }; InstructorPrivilegeUpdateRequest reqBody = new InstructorPrivilegeUpdateRequest(); reqBody.setCanSubmitSessionInSections(true); reqBody.setSectionName("Tutorial1"); reqBody.setFeedbackSessionName("Session1"); UpdateInstructorPrivilegeAction action = getAction(reqBody, submissionParams); JsonResult result = getJsonResult(action); assertEquals(HttpStatus.SC_OK, result.getStatusCode()); InstructorPrivilegeData response = (InstructorPrivilegeData) result.getOutput(); assertTrue(response.isCanModifyCourse()); assertTrue(response.isCanModifySession()); assertTrue(response.isCanModifyStudent()); assertTrue(response.isCanModifyInstructor()); assertTrue(response.isCanViewStudentInSections()); assertTrue(response.isCanSubmitSessionInSections()); assertFalse(response.isCanViewSessionInSections()); assertFalse(response.isCanModifySessionCommentsInSections()); }

Target:
protected void testExecute_withCourseIdAndSectionNameAndSessionName_shouldUpdatePrivilegesInSessionLevel() { InstructorAttributes helper1OfCourse1 = typicalBundle.instructors.get("helperOfCourse1"); assertFalse(helper1OfCourse1.privileges.isAllowedForPrivilege("Tutorial1", "Session1", Const.ParamsNames.INSTRUCTOR_PERMISSION_SUBMIT_SESSION_IN_SECTIONS)); assertFalse(helper1OfCourse1.privileges.isAllowedForPrivilege("Tutorial1", "Session1", Const.ParamsNames.INSTRUCTOR_PERMISSION_VIEW_SESSION_IN_SECTIONS)); assertFalse(helper1OfCourse1.privileges.isAllowedForPrivilege("Tutorial1", "Session1", Const.ParamsNames.INSTRUCTOR_PERMISSION_MODIFY_SESSION_COMMENT_IN_SECTIONS)); String[] submissionParams = new String[] { Const.ParamsNames.INSTRUCTOR_EMAIL, helper1OfCourse1.getEmail(), Const.ParamsNames.COURSE_ID, helper1OfCourse1.courseId, }; InstructorPrivilegeUpdateRequest reqBody = new InstructorPrivilegeUpdateRequest(); reqBody.setCanSubmitSessionInSections(true); reqBody.setCanViewSessionInSections(true); reqBody.setCanModifySessionCommentsInSections(true); reqBody.setSectionName("Tutorial1"); reqBody.setFeedbackSessionName("Session1"); UpdateInstructorPrivilegeAction action = getAction(reqBody, submissionParams); JsonResult result = getJsonResult(action); assertEquals(HttpStatus.SC_OK, result.getStatusCode()); InstructorPrivilegeData response = (InstructorPrivilegeData) result.getOutput(); assertFalse(response.isCanModifyCourse()); assertFalse(response.isCanModifySession()); assertFalse(response.isCanModifyStudent()); assertFalse(response.isCanModifyInstructor()); assertFalse(response.isCanViewStudentInSections()); assertTrue(response.isCanSubmitSessionInSections()); assertTrue(response.isCanViewSessionInSections()); assertTrue(response.isCanModifySessionCommentsInSections()); }
Source:
public IRichBolt getConsumer() { Preconditions.checkArgument(!props.isEmpty(), "Writable MongoDB must contain collection config"); String serField; if (props.contains("ser.field")) { serField = props.getProperty("ser.field"); } else if (props.contains("trident.ser.field")) { serField = props.getProperty("trident.ser.field"); } else { serField = "tridentSerField"; } MongoMapper mapper = new SqlMongoMapper(serField, serializer); return new MongoInsertBolt(url, props.getProperty("collection.name"), mapper); }

Target:
public IRichBolt getConsumer() { Preconditions.checkArgument(!props.isEmpty(), "Writable MongoDB must contain collection config"); String serField; if (props.contains(VALUE_SERIALIZED_FIELD)) { serField = props.getProperty(VALUE_SERIALIZED_FIELD); } else if (props.contains(TRIDENT_VALUE_SERIALIZED_FIELD)) { serField = props.getProperty(TRIDENT_VALUE_SERIALIZED_FIELD); } else { serField = DEFAULT_VALUE_SERIALIZED_FIELD; } MongoMapper mapper = new SqlMongoMapper(serField, serializer); return new MongoInsertBolt(url, props.getProperty(COLLECTION_NAME), mapper); }
Source:
private static boolean parseOptions(String arg, SelectedOptions options) { final boolean isOption = isOption(arg); if (isOption) { final String[] argParts = arg.substring(2).split("="); final Options option = Options.valueOf(argParts[0].toUpperCase()); option.accept(options, argParts.length > 1 ? argParts[1] : null); } return isOption; }

Target:
private static boolean parseOptions(String arg, SelectedOptions options) { final boolean isOption = isOption(arg); if (isOption) { final String[] argParts = arg.substring(2).split("="); final Options option = Options.valueOf(argParts[0].toUpperCase()); switch (option) { case PATH: options.getPaths().setBasePath(new File(argParts[1])); break; case ENVPATH: options.getPaths().setEnvPath(new File(argParts[1])); break; case SCRIPTPATH: options.getPaths().setScriptPath(new File(argParts[1])); break; case DRIVERPATH: options.getPaths().setDriverPath(new File(argParts[1])); break; case HOOKPATH: options.getPaths().setHookPath(new File(argParts[1])); break; case ENV: options.setEnvironment(argParts[1]); break; case FORCE: options.setForce(true); break; case TRACE: options.setTrace(true); break; case HELP: options.setHelp(true); break; case TEMPLATE: options.setTemplate(argParts[1]); break; case IDPATTERN: options.setIdPattern(argParts[1]); break; case QUIET: options.setQuiet(true); break; } } return isOption; }
Source:
private boolean hasOnlyPseudoConflicts(List<Diff> differences) { for (Diff difference : differences) { if (difference.getConflict().getKind() == ConflictKind.REAL) { return false; } } return true; }

Target:
private boolean hasOnlyPseudoConflicts(List<Diff> differences) { return Iterators.all(differences.iterator(), EMFComparePredicates.hasConflict(ConflictKind.PSEUDO)); }
Source:
public void shutDown() { closeQuitely(m_outStream); m_outStream = null; if (null != m_readerThread) { m_readerThread.interrupt(); } closeQuitely(m_inReader); m_inReader = null; closeQuitely(m_clientSocket); m_clientSocket = null; }

Target:
public void shutDown() { closeQuietly(m_outStream); m_outStream = null; if (null != m_readerThread) { m_readerThread.interrupt(); } closeQuietly(m_inReader); m_inReader = null; closeQuietly(m_clientSocket); m_clientSocket = null; }
Source:
private Watch eventWatch(KubernetesClient client, String podName, String namespace, TaskListener runListener) { try { return client.events().inNamespace(namespace).withField("involvedObject.name", podName).watch(new TaskListenerEventWatcher(podName, runListener)); } catch (KubernetesClientException e) { LOGGER.log(Level.FINE, e, () -> "Cannot watch events on " + namespace + "/" +podName); } return () -> {}; }

Target:
private Watch eventWatch(KubernetesClient client, String podName, String namespace, TaskListener runListener) { try { return client.events().inNamespace(namespace).withField("involvedObject.name", podName).watch(new TaskListenerEventWatcher(podName, runListener)); } catch (KubernetesClientException e) { LOGGER.log(Level.INFO, e, () -> "Cannot watch events on " + namespace + "/" +podName); } return () -> {}; }
Source:
public void write(PacketBuffer buffer) { this.getBlocks().write(buffer); this.getItems().write(buffer); this.getFluids().write(buffer); writeForgeTags(buffer); }

Target:
public void write(PacketBuffer buffer) { this.getBlocks().write(buffer); this.getItems().write(buffer); this.getFluids().write(buffer); }
Source:
public DlmsDevice findDlmsDevice(final DlmsDeviceMessageMetadata messageMetadata) throws FunctionalException, SessionProviderException, InterruptedException { final String deviceIdentification = messageMetadata.getDeviceIdentification(); final DlmsDevice dlmsDevice = this.dlmsDeviceRepository.findByDeviceIdentification(deviceIdentification); if (dlmsDevice == null) { throw new FunctionalException(FunctionalExceptionType.UNKNOWN_DEVICE, COMPONENT_TYPE, new ProtocolAdapterException("Unable to communicate with unknown device: " + deviceIdentification)); } dlmsDevice.setIpAddress(this.getDeviceIpAddress(dlmsDevice, messageMetadata.getIpAddress())); return dlmsDevice; }

Target:
public DlmsDevice findDlmsDevice(final DlmsDeviceMessageMetadata messageMetadata) throws FunctionalException, SessionProviderException { final String deviceIdentification = messageMetadata.getDeviceIdentification(); final DlmsDevice dlmsDevice = this.dlmsDeviceRepository.findByDeviceIdentification(deviceIdentification); if (dlmsDevice == null) { throw new FunctionalException(FunctionalExceptionType.UNKNOWN_DEVICE, COMPONENT_TYPE, new ProtocolAdapterException("Unable to communicate with unknown device: " + deviceIdentification)); } dlmsDevice.setIpAddress(this.getDeviceIpAddress(dlmsDevice, messageMetadata.getIpAddress())); return dlmsDevice; }
Source:
private void handlerError(String clientEndpoint, final String ticket, final Exception exception) { excutorService.submit(new Runnable() { @Override public void run() { try { sendError(ticket, exception.getMessage()); } catch (Throwable t) { LOG.error("Unable to send error message.", t); } } }); }

Target:
private void handlerError(String clientEndpoint, final String ticket, final Exception exception) { executorService.submit(new Runnable() { @Override public void run() { try { sendError(ticket, exception.getMessage()); } catch (RuntimeException t) { LOG.error("Unable to send error message.", t); } } }); }
Source:
public MessageHeader extractHeader(IndexedRecord message) { assert message != null : "Message should not be null"; final Schema messageSchema = message.getSchema(); final Schema firstFieldSchema = messageSchema.getFields().get(EXPECTED_HEADER_POSITION).schema(); if (firstFieldSchema.getType() != Schema.Type.RECORD) { throw new IllegalArgumentException( "Provided message's first field is not a record but " + firstFieldSchema.getType()); } if (!firstFieldSchema.getFullName().equals(messageHeaderSchema.getFullName())) { throw new IllegalArgumentException( "Provided message's first field is not a header but " + firstFieldSchema.getFullName()); } final Object firstFieldValue = message.get(EXPECTED_HEADER_POSITION); if (firstFieldValue instanceof MessageHeader) { return MessageHeader.class.cast(firstFieldValue); } else { return (MessageHeader) SpecificData.get().deepCopy(messageHeaderSchema, firstFieldValue); } }

Target:
public MessageHeader extractHeader(IndexedRecord message) { assert message != null : MESSAGE_SHOULD_NOT_BE_NULL_LABEL; final Schema messageSchema = message.getSchema(); final Schema firstFieldSchema = messageSchema.getFields().get(EXPECTED_HEADER_POSITION).schema(); if (firstFieldSchema.getType() != Schema.Type.RECORD) { throw new IllegalArgumentException(PROVIDED_FIRST_FIELD_RECORD_LABEL + firstFieldSchema.getType()); } if (!firstFieldSchema.getFullName().equals(messageHeaderSchema.getFullName())) { throw new IllegalArgumentException(PROVIDED_FIRST_FIELD_HEADER_LABEL + firstFieldSchema.getFullName()); } final Object firstFieldValue = message.get(EXPECTED_HEADER_POSITION); if (firstFieldValue instanceof MessageHeader) { return MessageHeader.class.cast(firstFieldValue); } else { return (MessageHeader) SpecificData.get().deepCopy(messageHeaderSchema, firstFieldValue); } }
Source:
private void start() { if (isStarted.compareAndSet(false, true)) { executor.execute(() -> { try (BufferedReader br2 = br) { SseEventBuilder builder = new SseEventBuilder(providers); String line = br.readLine(); while (line != null && !subscriptions.isEmpty()) { if (line.startsWith("data: ")) { builder.data(line.substring(6)); } else if (line.startsWith("id: ")) { builder.id(line.substring(4)); } else if (line.startsWith("event: ")) { builder.name(line.substring(7)); } else if (line.startsWith(": ")) { builder.comment(line.substring(2)); } else if ("".equals(line)) { InboundSseEvent event = builder.build(); for (SseSubscription subscription : subscriptions) { subscription.fireEvent(event); } builder = new SseEventBuilder(providers); } line = br.readLine(); } for (SseSubscription subscription : subscriptions) { subscription.fireComplete(); } } catch (IOException ex) { for (SseSubscription subscription : subscriptions) { subscription.fireError(ex); } } }); } }

Target:
private void start() { if (isStarted.compareAndSet(false, true)) { executor.execute(() -> { try (BufferedReader br2 = br) { SseEventBuilder builder = new SseEventBuilder(providers); String line = br.readLine(); while (line != null && !subscriptions.isEmpty()) { if (line.startsWith("data:")) { builder.data(removeSpace(line.substring(5))); } else if (line.startsWith("id:")) { builder.id(removeSpace(line.substring(3))); } else if (line.startsWith("event:")) { builder.name(removeSpace(line.substring(6))); } else if (line.startsWith(":")) { builder.comment(removeSpace(line.substring(1))); } else if ("".equals(line)) { InboundSseEvent event = builder.build(); for (SseSubscription subscription : subscriptions) { subscription.fireEvent(event); } builder = new SseEventBuilder(providers); } line = br.readLine(); } for (SseSubscription subscription : subscriptions) { subscription.complete(); } } catch (IOException ex) { for (SseSubscription subscription : subscriptions) { subscription.fireError(ex); } } }); } }
Source:
public synchronized long getMaxSize() { return maxSize; }

Target:
public long getMaxSize() { return maxSize; }
Source:
public void testManualMetadataBasedRule() throws InterruptedException { RetentionRule testRule = createManualMetadataBasedRuleMillis("dc:expired", 1000L); Calendar haldSecond = Calendar.getInstance(); haldSecond.add(Calendar.MILLISECOND, 500); file.setPropertyValue("dc:expired", haldSecond); file = session.saveDocument(file); file = service.attachRule(file, testRule, session); assertTrue(file.isRecord()); assertTrue(session.isUnderRetentionOrLegalHold(file.getRef())); awaitRetentionExpiration(1000L); Record record = file.getAdapter(Record.class); assertFalse(record.isRetainUntilInderterminate()); assertFalse(record.isRetentionExpired()); assertTrue(session.isUnderRetentionOrLegalHold(file.getRef())); awaitRetentionExpiration(1000L); file = session.getDocument(file.getRef()); record = file.getAdapter(Record.class); assertFalse(session.isUnderRetentionOrLegalHold(file.getRef())); assertTrue(record.isRetentionExpired()); }

Target:
public void testManualMetadataBasedRule() throws InterruptedException { RetentionRule testRule = createManualMetadataBasedRuleMillis("dc:expired", 1000); Calendar halfSecond = Calendar.getInstance(); halfSecond.add(Calendar.MILLISECOND, 500); file.setPropertyValue("dc:expired", halfSecond); file = session.saveDocument(file); file = service.attachRule(file, testRule, session); assertTrue(file.isRecord()); assertTrue(session.isUnderRetentionOrLegalHold(file.getRef())); awaitRetentionExpiration(1000); Record record = file.getAdapter(Record.class); assertFalse(record.isRetentionIndeterminate()); assertFalse(record.isRetentionExpired()); assertTrue(session.isUnderRetentionOrLegalHold(file.getRef())); awaitRetentionExpiration(1000); file = session.getDocument(file.getRef()); record = file.getAdapter(Record.class); assertFalse(session.isUnderRetentionOrLegalHold(file.getRef())); assertTrue(record.isRetentionExpired()); }
Source:
public Set<String> toShardIdentifiers(Set<String> routingKeys) { Set<String> shardIds = new LinkedHashSet<>(); for ( String routingKey : routingKeys ) { shardIds.add( toShardIdentifier( routingKey ) ); } return shardIds; }

Target:
public Set<String> toShardIdentifiers(Set<String> routingKeys) { for ( String routingKey : routingKeys ) { checkShardIdentifier( routingKey ); } return routingKeys; }
Source:
private void applyAsHasher(final Hasher hasher, final IntConsumer action) { verifyHasher(hasher); toSet(hasher).forEach(i -> action.accept(i)); }

Target:
private void applyAsHasher(final Hasher hasher, final IntConsumer action) { verifyHasher(hasher); IndexFilters.distinctIndexes(hasher, getShape(), action); }
Source:
public void testRequestShouldNotFollowRedirects() throws IOException { final AtomicInteger requestsAttempted = new AtomicInteger(0); HttpRequestExecutor requestExecutor = new HttpRequestExecutor() { @Override public HttpResponse execute(HttpRequest request, HttpClientConnection conn, HttpContext context) throws IOException, HttpException { HttpResponse resp = new BasicHttpResponse(HttpVersion.HTTP_1_1, 302, null); resp.addHeader("location", "<LINK_0>/path"); requestsAttempted.incrementAndGet(); return resp; } }; HttpClient client = HttpClients.custom().setRequestExecutor(requestExecutor).build(); ApacheHttpTransport transport = new ApacheHttpTransport(client); ApacheHttpRequest request = transport.buildRequest("GET", "<LINK_0>"); LowLevelHttpResponse response = request.execute(); assertEquals(1, requestsAttempted.get()); assertEquals(302, response.getStatusCode()); }

Target:
public void testRequestShouldNotFollowRedirects() throws IOException { final AtomicInteger requestsAttempted = new AtomicInteger(0); HttpRequestExecutor requestExecutor = new HttpRequestExecutor() { @Override public HttpResponse execute(HttpRequest request, HttpClientConnection connection, HttpContext context) throws IOException, HttpException { HttpResponse response = new BasicHttpResponse(HttpVersion.HTTP_1_1, 302, null); response.addHeader("location", "<LINK_0>/path"); requestsAttempted.incrementAndGet(); return response; } }; HttpClient client = HttpClients.custom().setRequestExecutor(requestExecutor).build(); ApacheHttpTransport transport = new ApacheHttpTransport(client); ApacheHttpRequest request = transport.buildRequest("GET", "<LINK_0>"); LowLevelHttpResponse response = request.execute(); assertEquals(1, requestsAttempted.get()); assertEquals(302, response.getStatusCode()); }
Source:
public void testIsFiltered() { Variant variant = Variant.newBuilder() .setId("Var1") .addFilter("PASS") .setReferenceBases("A") .addAlternateBases("G") .addAlternateBases("C") .addAlternateBases("T") .build(); assertFalse(VariantUtils.IS_FILTERED.apply(variant)); variant = Variant.newBuilder() .setId("Var2") .addFilter(".") .setReferenceBases("A") .addAlternateBases("G") .addAlternateBases("C") .addAlternateBases("T") .build(); assertFalse(VariantUtils.IS_FILTERED.apply(variant)); variant = Variant.newBuilder() .setId("Var3") .addFilter("BAD_SB_SCORE") .setReferenceBases("A") .addAlternateBases("G") .addAlternateBases("C") .addAlternateBases("T") .build(); assertTrue(VariantUtils.IS_FILTERED.apply(variant)); variant = Variant.newBuilder() .setId("Var4") .addFilter("LowQual") .addFilter("!ReallyBadHaplotype_score") .setReferenceBases("A") .addAlternateBases("G") .addAlternateBases("C") .addAlternateBases("T") .build(); assertTrue(VariantUtils.IS_FILTERED.apply(variant)); variant = Variant.newBuilder().setReferenceBases("A").addAlternateBases("G").build(); assertFalse(VariantUtils.IS_FILTERED.apply(variant)); }

Target:
public void testIsFiltered() { Variant variant = Variant.newBuilder() .setId("Var1") .addFilter(VariantUtils.PASSES_FILTERS) .setReferenceBases("A") .addAlternateBases("G") .addAlternateBases("C") .addAlternateBases("T") .build(); assertFalse(VariantUtils.IS_FILTERED.apply(variant)); variant = Variant.newBuilder() .setId("Var2") .addFilter(VariantUtils.MISSING_VALUE) .setReferenceBases("A") .addAlternateBases("G") .addAlternateBases("C") .addAlternateBases("T") .build(); assertFalse(VariantUtils.IS_FILTERED.apply(variant)); variant = Variant.newBuilder() .setId("Var3") .addFilter("BAD_SB_SCORE") .setReferenceBases("A") .addAlternateBases("G") .addAlternateBases("C") .addAlternateBases("T") .build(); assertTrue(VariantUtils.IS_FILTERED.apply(variant)); variant = Variant.newBuilder() .setId("Var4") .addFilter("LowQual") .addFilter("!ReallyBadHaplotype_score") .setReferenceBases("A") .addAlternateBases("G") .addAlternateBases("C") .addAlternateBases("T") .build(); assertTrue(VariantUtils.IS_FILTERED.apply(variant)); variant = Variant.newBuilder().setReferenceBases("A").addAlternateBases("G").build(); assertFalse(VariantUtils.IS_FILTERED.apply(variant)); }
Source:
public ResilienceStrategyProvider create(ServiceCreationConfiguration<ResilienceStrategyProvider> configuration) { if (configuration != null) { throw new IllegalArgumentException("Expected a null configuration but got " + configuration .getClass() .getSimpleName()); } return new DefaultResilienceStrategyProvider(); }

Target:
public ResilienceStrategyProvider create(ServiceCreationConfiguration<ResilienceStrategyProvider> configuration) { if (configuration == null) { return new DefaultResilienceStrategyProvider(); } else if (configuration instanceof DefaultResilienceStrategyProviderConfiguration) { return new DefaultResilienceStrategyProvider((DefaultResilienceStrategyProviderConfiguration) configuration); } else { throw new IllegalArgumentException("Expected a configuration of type DefaultResilienceStrategyProviderConfiguration (or none) but got " + configuration .getClass() .getName()); } }
Source:
protected Map<String, TraceTypeHelper> getTraceTypeMap() { Map<String, TraceTypeHelper> traceTypeMap = new TreeMap<>(); for (TraceTypeHelper helper : TmfTraceType.getTraceTypeHelpers()) { String text = helper.getCategoryName() + SEP + helper.getName(); traceTypeMap.put(text, helper); } return traceTypeMap; }

Target:
protected Map<String, TraceTypeHelper> getTraceTypeMap() { Map<String, TraceTypeHelper> traceTypeMap = new TreeMap<>(); for (TraceTypeHelper helper : TmfTraceType.getTraceTypeHelpers()) { if (!helper.isExperimentType()) { String text = helper.getCategoryName() + SEP + helper.getName(); traceTypeMap.put(text, helper); } } return traceTypeMap; }
Source:
public WebSocketCloseStatus(int statusCode, String reasonText) { if (!isValidStatusCode(statusCode)) { throw new IllegalArgumentException( "WebSocket close status code does NOT comply with RFC-6455: " + statusCode); } if (reasonText == null) { throw new NullPointerException("Reason text cannot be null"); } this.statusCode = statusCode; this.reasonText = reasonText; }

Target:
public WebSocketCloseStatus(int statusCode, String reasonText) { if (!isValidStatusCode(statusCode)) { throw new IllegalArgumentException( "WebSocket close status code does NOT comply with RFC-6455: " + statusCode); } this.statusCode = statusCode; this.reasonText = checkNotNull(reasonText, "reasonText"); }
Source:
public Set<ITmfEventType> getContainedEventTypes() { TmfEventTypeManager instance = TmfEventTypeManager.getInstance(); return instance.getTypes(CtfTmfEventType.computeContextName(this)); }

Target:
public Set<ITmfEventType> getContainedEventTypes() { TmfEventTypeManager instance = TmfEventTypeManager.getInstance(); Set<ITmfEventType> eventTypes = instance.getTypes(CtfTmfEventType.computeContextName(this)); return ImmutableSet.copyOf(eventTypes); }
Source:
public void execute() { String inviterId = getRequestParamValue(ParamsNames.INVITER_ID); Assumption.assertNotNull(inviterId); String courseId = getRequestParamValue(ParamsNames.COURSE_ID); Assumption.assertNotNull(courseId); String inviteReceiverEmail = getRequestParamValue(ParamsNames.INVITE_RECEIVER_EMAIL); Assumption.assertNotNull(inviteReceiverEmail); AccountAttributes inviter = logic.getAccount(inviterId); Assumption.assertNotNull(inviter); CourseAttributes course = logic.getCourse(courseId); Assumption.assertNotNull(course); InstructorAttributes inviteReceiver = logic.getInstructorForEmail(courseId, inviteReceiverEmail); Assumption.assertNotNull(inviteReceiver); EmailWrapper email = new EmailGenerator() .generateInstructorCourseJoinEmail(inviter, inviteReceiver, course); try { emailSender.sendEmail(email); } catch (Exception e) { throw new RuntimeException("Unexpected error while sending email", e); } }

Target:
public void execute() { String inviterId = getRequestParamValue(ParamsNames.INVITER_ID); Assumption.assertNotNull(inviterId); String courseId = getRequestParamValue(ParamsNames.COURSE_ID); Assumption.assertNotNull(courseId); String instructorEmail = getRequestParamValue(ParamsNames.INSTRUCTOR_EMAIL); Assumption.assertNotNull(instructorEmail); AccountAttributes inviter = logic.getAccount(inviterId); Assumption.assertNotNull(inviter); CourseAttributes course = logic.getCourse(courseId); Assumption.assertNotNull(course); InstructorAttributes instructor = logic.getInstructorForEmail(courseId, instructorEmail); Assumption.assertNotNull(instructor); EmailWrapper email = new EmailGenerator() .generateInstructorCourseJoinEmail(inviter, instructor, course); try { emailSender.sendEmail(email); } catch (Exception e) { throw new RuntimeException("Unexpected error while sending email", e); } }
Source:
public Set<IndexFieldDTO> getIndexedFields(boolean update) throws Exception { Set<IndexFieldDTO> result = indexFields; if(result == null || update) { synchronized(solrIndexVersionLock) { result = indexFields; if(result == null || update) { result = getIndexFieldDetails(null); Map<String, IndexFieldDTO> resultMap = new HashMap<String, IndexFieldDTO>(); for(IndexFieldDTO field: result) { resultMap.put(field.getName(), field); } indexFields = result; indexFieldMap = resultMap; } } } return result; }

Target:
public Set<IndexFieldDTO> getIndexedFields(boolean update) throws Exception { Set<IndexFieldDTO> result = indexFields; if(result == null || update) { synchronized(solrIndexVersionLock) { result = indexFields; if(result == null || update) { result = indexFields = getIndexFieldDetails(null); Map<String, IndexFieldDTO> resultMap = new HashMap<String, IndexFieldDTO>(); for(IndexFieldDTO field: result) { resultMap.put(field.getName(), field); } indexFieldMap = resultMap; } } } return result; }
Source:
public CoLocationConstraintDesc(final AbstractID coLocationGroupId, final int constraintIndex) { this.coLocationGroupId = checkNotNull(coLocationGroupId); this.constraintIndex = constraintIndex; }

Target:
CoLocationConstraintDesc(final AbstractID coLocationGroupId, final int constraintIndex) { this.coLocationGroupId = checkNotNull(coLocationGroupId); this.constraintIndex = constraintIndex; }
Source:
public List<File> getContextScreenshots() { List<File> screenshots = currentContextScreenshots.get(); return Collections.unmodifiableList(screenshots == null ? Collections.emptyList() : screenshots); }

Target:
public List<File> getContextScreenshots() { List<File> screenshots = currentContextScreenshots.get(); return screenshots == null ? Collections.emptyList() : Collections.unmodifiableList(screenshots); }
Source:
public HazmatArmorPiece(Category category, SlimefunItemStack item, RecipeType recipeType, ItemStack[] recipe, PotionEffect[] effects) { super(category, item, recipeType, recipe, effects, new NamespacedKey(SlimefunPlugin.instance, "hazmat_suit")); types = new ProtectionType[] {ProtectionType.BEES, ProtectionType.RADIATION}; }

Target:
public HazmatArmorPiece(Category category, SlimefunItemStack item, RecipeType recipeType, ItemStack[] recipe, PotionEffect[] effects) { super(category, item, recipeType, recipe, effects); types = new ProtectionType[] {ProtectionType.BEES, ProtectionType.RADIATION}; setId = new NamespacedKey(SlimefunPlugin.instance, "hazmat_suit"); }
Source:
private String formatVolClusterName(String volClusterName) { if (volClusterName == null) { return null; } String[] names = volClusterName.split("\\|"); return names.length == 2 ? names[0] + " (" + names[1] + ")" : names[0]; }

Target:
private String[] formatVolClusterName(String volClusterName) { if (volClusterName == null) { return null; } String[] names = volClusterName.split("\\|"); return names; }
Source:
private void assertIsDefaultValues(StudentProfileAttributes profileAttributes) { assertEquals("OTHER", profileAttributes.gender.name()); assertEquals("", profileAttributes.googleId); assertEquals("", profileAttributes.shortName); assertEquals("", profileAttributes.email); assertEquals("", profileAttributes.institute); assertEquals("", profileAttributes.nationality); assertEquals("", profileAttributes.moreInfo); assertEquals("", profileAttributes.pictureKey); }

Target:
private void assertIsDefaultValues(StudentProfileAttributes profileAttributes) { assertEquals(Gender.OTHER, profileAttributes.gender); assertEquals(VALID_GOOGLE_ID, profileAttributes.googleId); assertEquals("", profileAttributes.shortName); assertEquals("", profileAttributes.email); assertEquals("", profileAttributes.institute); assertEquals("", profileAttributes.nationality); assertEquals("", profileAttributes.moreInfo); assertEquals("", profileAttributes.pictureKey); }
Source:
protected boolean formatStorage(StorageDomain dom, VDS vds) { try { return getVdsBroker() .RunVdsCommand(VDSCommandType.FormatStorageDomain, new FormatStorageDomainVDSCommandParameters(vds.getId(), dom.getId())).getSucceeded(); } catch (VdcBLLException e) { if (e.getVdsError().getCode() != VdcBllErrors.StorageDomainDoesNotExist) { throw e; } log.warnFormat("Storage Domain {0} which was about to be formatted was not exists in VDS id {1}", vds.getId(), dom.getId()); return true; } }

Target:
protected boolean formatStorage(StorageDomain dom, VDS vds) { try { return getVdsBroker() .RunVdsCommand(VDSCommandType.FormatStorageDomain, new FormatStorageDomainVDSCommandParameters(vds.getId(), dom.getId())).getSucceeded(); } catch (VdcBLLException e) { if (e.getErrorCode() != VdcBllErrors.StorageDomainDoesNotExist) { throw e; } log.warnFormat("Storage Domain {0} which was about to be formatted does not exist in VDS {1}", dom.getName(), vds.getName()); return true; } }
Source:
protected boolean canDoAction() { VdsValidator validator = new VdsValidator(getVds()); return validate(validator.isUp()); }

Target:
protected boolean canDoAction() { VDSGroup cluster = getDbFacade().getVdsGroupDao().get(getVds().getVdsGroupId()); if (!cluster.supportsGlusterService() || !GlusterFeatureSupported.glusterDiskProvisioning(cluster.getCompatibilityVersion())) { return failCanDoAction(VdcBllMessages.ACTION_TYPE_FAILED_STORAGE_PROVISIONING_NOT_SUPPORTED_BY_CLUSTER); } VdsValidator validator = new VdsValidator(getVds()); return validate(validator.isUp()); }
Source:
public void close() throws InterruptedException { if (m_blessedThreadIds.contains(Thread.currentThread().getId())) { throw new RuntimeException("Can't invoke backpressureBarrier from within the client callback thread " + " without deadlocking the client library"); } m_isShutdown = true; synchronized (m_backpressureLock) { m_backpressureLock.notifyAll(); } if (m_reconnectStatusListener != null) { m_distributer.removeClientStatusListener(m_reconnectStatusListener); m_reconnectStatusListener.close(); } m_distributer.shutdown(); m_ex.shutdown(); m_ex.awaitTermination(365, TimeUnit.DAYS); ClientFactory.decreaseClientNum(); }

Target:
public void close() throws InterruptedException { if (m_blessedThreadIds.contains(Thread.currentThread().getId())) { throw new RuntimeException("Can't invoke backpressureBarrier from within the client callback thread " + " without deadlocking the client library"); } m_isShutdown = true; synchronized (m_backpressureLock) { m_backpressureLock.notifyAll(); } if (m_reconnectStatusListener != null) { m_distributer.removeClientStatusListener(m_reconnectStatusListener); m_reconnectStatusListener.close(); } if (m_ex != null) { m_ex.shutdown(); m_ex.awaitTermination(1, TimeUnit.SECONDS); } m_distributer.shutdown(); ClientFactory.decreaseClientNum(); }
Source:
protected CompiledPlan compileAdHocCalcitePlan(String sql, boolean inferPartitioning, boolean forcedSP, DeterminismMode detMode) { CompiledPlan cp = null; try { cp = m_aide.compileAdHocPlan(PlannerType.CALCITE, sql, inferPartitioning, forcedSP, detMode); assertNotNull(cp); } catch (Exception ex) { fail(ex.getMessage()); } return cp; }

Target:
protected CompiledPlan compileAdHocCalcitePlan(String sql, boolean inferPartitioning, boolean forcedSP, DeterminismMode detMode) { CompiledPlan cp = m_aide.compileAdHocPlan(PlannerType.CALCITE, sql, inferPartitioning, forcedSP, detMode); assertNotNull(cp); return cp; }
Source:
public void interrupt( @Nonnull Thread thread, @Nullable String template, @Nullable Object... args) { String message = String.format(String.valueOf(template), args); mInterruptMessage.put(thread, message); }

Target:
public void interrupt( @Nonnull Thread thread, @Nullable String template, @Nullable Object... args) { String message = String.format(String.valueOf(template), args); mInterruptMessage.put(thread, message); if (isInterruptible(thread)) { thread.interrupt(); } }
Source:
protected void scheduleInputEventBasedRule(RetentionRule rule) { if (!rule.isEnabled() || !rule.isEventBased()) { throw new IllegalArgumentException("Rule is disabled or not event-based"); } BulkService bulkService = Framework.getService(BulkService.class); RepositoryService repositoryService = Framework.getService(RepositoryService.class); StringBuilder query = new StringBuilder(RetentionConstants.RULE_RECORD_DOCUMENT_QUERY); query.append(" AND ") .append(RetentionConstants.RECORD_RULE_IDS_PROP) .append(" = '" + rule.getDocument().getId() + "'"); for (String repositoryName : repositoryService.getRepositoryNames()) { BulkCommand command = new BulkCommand.Builder(EvalInputEventBasedRuleAction.ACTION_NAME, query.toString()).user(SecurityConstants.SYSTEM_USERNAME).repository(repositoryName).build(); bulkService.submit(command); } }

Target:
protected void scheduleInputEventBasedRule(RetentionRule rule) { if (!rule.isEnabled() || !rule.isEventBased()) { throw new IllegalArgumentException("Rule is disabled or not event-based"); } BulkService bulkService = Framework.getService(BulkService.class); RepositoryService repositoryService = Framework.getService(RepositoryService.class); StringBuilder query = new StringBuilder(RetentionConstants.RULE_RECORD_DOCUMENT_QUERY); query.append(" AND ") .append(RetentionConstants.RECORD_RULE_IDS_PROP) .append(" = '" + rule.getDocument().getId() + "'"); for (String repositoryName : repositoryService.getRepositoryNames()) { BulkCommand command = new BulkCommand.Builder(EvalInputEventBasedRuleAction.ACTION_NAME, query.toString(), SecurityConstants.SYSTEM_USERNAME).repository(repositoryName).build(); bulkService.submit(command); } }
Source:
protected void formatBranch() throws EmailException { switch (this.type) { case CREATE: appendText(velocifyFile("NewBranch.vm")); break; case UPDATE: appendText(velocifyFile("ModifyBranch.vm")); break; case DELETE: appendText(velocifyFile("DeleteBranch.vm")); break; } }

Target:
protected void formatBranch() throws EmailException { switch (this.type) { case CREATE: appendText(velocifyFile("NewBranch.vm")); break; case UPDATE: case UPDATE_NONFASTFORWARD: appendText(velocifyFile("ModifyBranch.vm")); break; case DELETE: appendText(velocifyFile("DeleteBranch.vm")); break; } }
Source:
protected boolean mustBeRemoved(@Nonnull JDefinedClassOrInterface type) { if (type == stringDef || type == intDef) { return true; } if (type instanceof JDefinedAnnotationType) { if ((!type.getAnnotations(stringDef).isEmpty()) || !type.getAnnotations(intDef).isEmpty()) { JDefinedAnnotationType typeDef = (JDefinedAnnotationType) type; if (typeDef.getRetentionPolicy() != JRetentionPolicy.SOURCE) { JSession session = type.getParent(JSession.class); session.getReporter().report(Severity.NON_FATAL, new InvalidRetentionForTypeDef(typeDef)); } return true; } } return false; }

Target:
protected boolean mustBeRemoved(@Nonnull JDefinedClassOrInterface type) { if (type == stringDef || type == intDef) { return true; } if (type instanceof JDefinedAnnotationType) { if ((!type.getAnnotations(stringDef).isEmpty()) || !type.getAnnotations(intDef).isEmpty()) { JDefinedAnnotationType typeDef = (JDefinedAnnotationType) type; if (typeDef.getRetentionPolicy() != JRetentionPolicy.SOURCE) { type.getSession().getReporter().report(Severity.NON_FATAL, new InvalidRetentionForTypeDef(typeDef)); } return true; } } return false; }
Source:
private void handleSyncUpdate(final SyncState sync, Callback successCallback, Callback errorCallback) { try { switch (sync.getStatus()) { case NEW: break; case RUNNING: break; case DONE: ReactBridgeHelper.invokeSuccess(successCallback, sync.asJSON()); break; case FAILED: ReactBridgeHelper.invokeSuccess(errorCallback, sync.asJSON()); break; } } catch (Exception e) { SalesforceReactLogger.e(TAG, "handleSyncUpdate call failed", e); } }

Target:
private void handleSyncUpdate(final SyncState sync, Callback successCallback, Callback errorCallback) { try { switch (sync.getStatus()) { case NEW: break; case RUNNING: break; case DONE: ReactBridgeHelper.invoke(successCallback, sync.asJSON()); break; case FAILED: ReactBridgeHelper.invoke(errorCallback, sync.asJSON()); break; } } catch (Exception e) { SalesforceReactLogger.e(TAG, "handleSyncUpdate call failed", e); } }
Source:
public void MercurySignupTest_006_japaneseUserSignup() { SignupPageObject mobileSignup = new SignupPageObject(driver); mobileSignup.openMobileSignupPage(wikiURL); String userName = "品質管理" + mobileSignup.getTimeStamp(); String password = "品質管理管理" + mobileSignup.getTimeStamp(); String email = "qaart001+" + mobileSignup.getTimeStamp() + "@gmail.com"; mobileSignup.typeEmailAddress(email).typeUsername(userName).typePassword(password) .typeBirthdate("12", "12", "1952").register(); mobileSignup.verifyAvatarAfterSignup(); }

Target:
public void MercurySignupTest_006_japaneseUserSignup() { SignupPageObject mobileSignup = new SignupPageObject(driver); mobileSignup.openMobileSignupPage(wikiURL); String userName = "ユーザー" + mobileSignup.getTimeStamp(); String password = "パス" + mobileSignup.getTimeStamp(); String email = "qaart001+" + mobileSignup.getTimeStamp() + "@gmail.com"; mobileSignup.typeEmailAddress(email).typeUsername(userName).typePassword(password) .typeBirthdate("12", "12", "1952").register(); mobileSignup.verifyAvatarAfterSignup(); }
Source:
public static DrtConfigGroup get(Config config) { return ConfigUtils.addOrGetModule( config, DrtConfigGroup.class ) ; }

Target:
public static DrtConfigGroup get(Config config) { return (DrtConfigGroup) config.getModule(GROUP_NAME); }
Source:
boolean isRunning() { return running; }

Target:
private boolean isRunning() { return running; }
Source:
public int hashCode() { int result = 17; result += 37 * Arrays.hashCode(mElements); result += 37 * mRepeat; return result; }

Target:
public int hashCode() { int result = 17; result += 37 * 37 * Arrays.hashCode(mElements); result += 37 * mRepeat; return result; }