auphong2707/dl4se-code-review-dataset huggingface dataset:
Source:
<code>private static void checkParameterTypes(String methodName, Class[] parameterTypes, String methodAnnotation, String[] parameterNames) { int totalLength = parameterTypes.length; Set<Class> injectedTypes = new HashSet<Class>() { private static final long serialVersionUID = -5324894581793435812L; { add(ITestContext.class); add(ITestResult.class); add(XmlTest.class); add(Method.class); add(Object[].class); }}; for (Class parameterType : parameterTypes) { if (injectedTypes.contains(parameterType)) { totalLength--; } } if (parameterNames.length != totalLength) { <START> throw new TestNGException( <END> "Cannot inject " + methodAnnotation + " annotated Method [" + methodName + "] with " + Arrays.toString(parameterTypes) + ".\nFor more information on native dependency injection please refer to " + "<LINK_0>" ); } }</code><technical_language>this exception is related "if (parameterNames.length != totalLength)". I more context somewhere</technical_language>

Target:
private static void checkParameterTypes(String methodName, Class[] parameterTypes, String methodAnnotation, String[] parameterNames) { int totalLength = parameterTypes.length; Set<Class> injectedTypes = new HashSet<Class>() { private static final long serialVersionUID = -5324894581793435812L; { add(ITestContext.class); add(ITestResult.class); add(XmlTest.class); add(Method.class); add(Object[].class); }}; for (Class parameterType : parameterTypes) { if (injectedTypes.contains(parameterType)) { totalLength--; } } if ( (parameterNames.length ==0) && (totalLength != 0) ) { String errPrefix = "Cannot inject " + methodAnnotation + " annotated Method [" + methodName + "] with " + Arrays.toString(parameterTypes); if (mapping.containsKey(methodAnnotation)) { errPrefix = "Can inject only one of " + prettyFormat(mapping.get(methodAnnotation)) + " into a " + methodAnnotation + " annotated " + methodName; } throw new TestNGException( errPrefix + ".\nFor more information on native dependency injection please refer to " + "<LINK_0>" ); } if (parameterNames.length != totalLength) { throw new TestNGException( "Method " + methodName + " requires " + parameterTypes.length + " parameters but " + parameterNames.length + " were supplied in the " + methodAnnotation + " annotation."); } }
Source:
<code>public List<SourceControl.SourceControlBean> getSourceControlList() { <START> List<SourceControl.SourceControlBean> sourceControlList = new ArrayList<>(); <END> for (SourceControl sourceControl : SourceControl.values()) { sourceControlList.add(new SourceControl.SourceControlBean(sourceControl)); } return sourceControlList; }</code><technical_language>trivial lambdas, a high priority</technical_language>

Target:
public List<SourceControl.SourceControlBean> getSourceControlList() { List<SourceControl.SourceControlBean> sourceControlList = new ArrayList<>(); Arrays.asList(SourceControl.values()).forEach(sourceControl -> sourceControlList.add(new SourceControl.SourceControlBean(sourceControl))); return sourceControlList; }
Source:
<code><START> private void changeToolbarVisibilityInFullscreenMode(Object arg) { <END> String notificationName = OoyalaNotification.getNameOrUnknown(arg); if (notificationName.equals(OoyalaSkinLayoutController.FULLSCREEN_CHANGED_NOTIFICATION_NAME)) { if (((OoyalaNotification) arg).getData().equals(Boolean.TRUE)) { toolbar.setVisibility(View.GONE); } else { toolbar.setVisibility(View.VISIBLE); toolbar.bringToFront(); } } }</code><technical_language>Is this problem for sample app? need move skin</technical_language>

Target:
private void changeToolbarVisibilityInFullscreenMode(Object arg) { String notificationName = OoyalaNotification.getNameOrUnknown(arg); if (notificationName.equals(OoyalaSkinLayoutController.FULLSCREEN_CHANGED_NOTIFICATION_NAME) && toolbar != null) { if (((OoyalaNotification) arg).getData().equals(Boolean.TRUE)) { toolbar.setVisibility(View.GONE); } else { toolbar.setVisibility(View.VISIBLE); toolbar.bringToFront(); } } }
Source:
<code>public void start() { URI configFileUri = null; try { if (service.configFile != null) { URL configFile = JCacheLifecycle.class.getClassLoader().getResource(service.configFile); if (configFile == null) { throw new IllegalArgumentException(String.format("Unable to locate specified configuration file %s.", service.configFile)); } configFileUri = configFile.toURI(); } } catch (URISyntaxException e) { log.errorf(String.format("Exception while accessing configuration file %s.", service.configFile), e); throw new IllegalStateException(e); } Properties configProperties = null; if (service.propertiesFile != null) { configProperties = new Properties(); try { Utils.loadProperties(configProperties, JCacheLifecycle.class.getClassLoader().getResourceAsStream(service.propertiesFile)); } catch (IOException e) { log.error(String.format("Exception while loading configuration properties file %s.", service.propertiesFile)); throw new IllegalStateException(e); } } <START> cacheManager = Caching.getCachingProvider().getCacheManager(configFileUri, JCacheLifecycle.class.getClassLoader(), configProperties); <END> service.cache = service.createCache ? cacheManager.createCache(service.cacheName, new MutableConfiguration()) : cacheManager.getCache(service.cacheName); }</code><technical_language>Infinispan versions bring JCacheProvider for embedded remote, (and should!) of classpath, add property for selection of provider</technical_language>

Target:
public void start() { URI cacheManagerUri = null; try { if (service.configFile != null) { URL cacheManagerUrl = JCacheLifecycle.class.getClassLoader().getResource(service.configFile); if (cacheManagerUrl == null) { throw new IllegalArgumentException(String.format("Unable to locate specified configuration file %s.", service.configFile)); } cacheManagerUri = cacheManagerUrl.toURI(); } } catch (URISyntaxException e) { log.errorf(String.format("Exception while accessing configuration file %s.", service.configFile), e); throw new IllegalStateException(e); } Properties configProperties = null; if (service.propertiesFile != null) { configProperties = new Properties(); try (InputStream propertiesStream = JCacheLifecycle.class.getClassLoader().getResourceAsStream(service.propertiesFile)) { Utils.loadProperties(configProperties, propertiesStream); } catch (IOException e) { log.error(String.format("Exception while loading configuration properties file %s.", service.propertiesFile)); throw new IllegalStateException(e); } } CachingProvider cachingProvider = service.cachingProviderClass == null ? Caching.getCachingProvider() : Caching.getCachingProvider(service.cachingProviderClass); service.cacheManager = cachingProvider.getCacheManager(cacheManagerUri, JCacheLifecycle.class.getClassLoader(), configProperties); }
Source:
<code>public void testIncompleteZKHostInfo() throws Exception { <START> assumeTrue(dcStr.equalsIgnoreCase("all") || dcStr.replaceAll("\\p{Space}", "").split(",").length == dcs.length); <END> if (testHardwareLayout.getDatacenterCount() > 1) { JSONObject partialZkJson = constructZkLayoutJSON(Collections.singleton(dcsToZkInfo.entrySet().iterator().next().getValue())); Utils.writeJsonObjectToFile(partialZkJson, zkLayoutPath); Utils.writeJsonObjectToFile(testHardwareLayout.getHardwareLayout().toJSONObject(), hardwareLayoutPath); Utils.writeJsonObjectToFile(testPartitionLayout.getPartitionLayout().toJSONObject(), partitionLayoutPath); try { HelixBootstrapUpgradeUtil.bootstrapOrUpgrade(hardwareLayoutPath, partitionLayoutPath, zkLayoutPath, CLUSTER_NAME_PREFIX, dcStr, DEFAULT_MAX_PARTITIONS_PER_RESOURCE, false, false, new HelixAdminFactory()); fail("Should have thrown IllegalArgumentException as a zk host is missing for one of the dcs"); } catch (IllegalArgumentException e) { } } }</code><technical_language>I assumeTrue is unnecessary. test is supposed performed DCs specified</technical_language>

Target:
public void testIncompleteZKHostInfo() throws Exception { assumeTrue(dcStr.equalsIgnoreCase("all")); if (testHardwareLayout.getDatacenterCount() > 1) { JSONObject partialZkJson = constructZkLayoutJSON(Collections.singleton(dcsToZkInfo.entrySet().iterator().next().getValue())); Utils.writeJsonObjectToFile(partialZkJson, zkLayoutPath); Utils.writeJsonObjectToFile(testHardwareLayout.getHardwareLayout().toJSONObject(), hardwareLayoutPath); Utils.writeJsonObjectToFile(testPartitionLayout.getPartitionLayout().toJSONObject(), partitionLayoutPath); try { HelixBootstrapUpgradeUtil.bootstrapOrUpgrade(hardwareLayoutPath, partitionLayoutPath, zkLayoutPath, CLUSTER_NAME_PREFIX, dcStr, DEFAULT_MAX_PARTITIONS_PER_RESOURCE, false, false, new HelixAdminFactory()); fail("Should have thrown IllegalArgumentException as a zk host is missing for one of the dcs"); } catch (IllegalArgumentException e) { } } }
Source:
<code><START> private void testUpdateInsertionFeature(String insertion) throws Exception { <END> String url = "/ats/program/" + getSawProgram().getArtId() + "/insertion/1234567800/feature"; JsonArray array = putAndCheck(url, Entity.entity(insertion, MediaType.APPLICATION_JSON_TYPE)); Assert.assertEquals(1, array.size()); JsonObject obj = getObjectNamed("Renamed Insertion Feature", array); Assert.assertNotNull("Did not find value Renamed Insertion Feature", obj); }</code><technical_language>getUuid instead of getArtId,</technical_language>

Target:
private void testUpdateInsertionFeature(String insertion) throws Exception { String url = "/ats/program/" + getSawProgram().getUuid() + "/insertion/1234567800/feature"; JsonArray array = putAndCheck(url, Entity.entity(insertion, MediaType.APPLICATION_JSON_TYPE)); Assert.assertEquals(1, array.size()); JsonObject obj = getObjectNamed("Renamed Insertion Feature", array); Assert.assertNotNull("Did not find value Renamed Insertion Feature", obj); }
Source:
<code>private boolean upgradeTwentyFourTwentyFive(SQLiteDatabase db) { db.beginTransaction(); try { boolean strandedRecordObserved = false; SqlStorage<FormRecord> formRecordStorage = UserDbUpgradeUtils.getFormRecordStorage(c, db, FormRecord.class); SqlStorage<SessionStateDescriptor> ssdStorage = new SqlStorage<>( SessionStateDescriptor.STORAGE_KEY, SessionStateDescriptor.class, new ConcreteAndroidDbHelper(c, db)); for (SessionStateDescriptor ssd : ssdStorage) { try { FormRecord formRecord = formRecordStorage.read(ssd.getFormRecordId()); if (formRecord.getStatus().contentEquals(FormRecord.STATUS_UNSTARTED)) { strandedRecordObserved = true; break; } } catch (NoSuchElementException e) { strandedRecordObserved = true; break; } } if (strandedRecordObserved) { SqlStorage.wipeTable(db, SessionStateDescriptor.STORAGE_KEY); for (FormRecord formRecord : formRecordStorage) { if (formRecord.getStatus().contentEquals(FormRecord.STATUS_INCOMPLETE)) { <START> formRecordStorage.remove(formRecord); <END> } } } db.setTransactionSuccessful(); return true; } finally { db.endTransaction(); } }</code><technical_language>I generally of deleting in-place this (while iterator) a dangerous operation, assume need a "todelete" list apply deletions afterwards. I incorrect WRT iterators</technical_language>

Target:
private boolean upgradeTwentyFourTwentyFive(SQLiteDatabase db) { db.beginTransaction(); try { boolean strandedRecordObserved = false; SqlStorage<FormRecord> formRecordStorage = UserDbUpgradeUtils.getFormRecordStorage(c, db, FormRecord.class); SqlStorage<SessionStateDescriptor> ssdStorage = new SqlStorage<>( SessionStateDescriptor.STORAGE_KEY, SessionStateDescriptor.class, new ConcreteAndroidDbHelper(c, db)); for (SessionStateDescriptor ssd : ssdStorage) { try { FormRecord formRecord = formRecordStorage.read(ssd.getFormRecordId()); if (formRecord.getStatus().contentEquals(FormRecord.STATUS_UNSTARTED)) { strandedRecordObserved = true; break; } } catch (NoSuchElementException e) { strandedRecordObserved = true; break; } } if (strandedRecordObserved) { SqlStorage.wipeTable(db, SessionStateDescriptor.STORAGE_KEY); Vector<FormRecord> incompleteRecords = formRecordStorage.getRecordsForValue(FormRecord.META_STATUS, FormRecord.STATUS_INCOMPLETE); for (FormRecord incompleteRecord : incompleteRecords) { formRecordStorage.remove(incompleteRecord); } } db.setTransactionSuccessful(); return true; } finally { db.endTransaction(); } }
Source:
<code>private KerberosManager() { String engineEtc = System.getenv("ENGINE_ETC"); if (engineEtc == null) { engineEtc = "/etc/ovirt-engine"; } File krb5File = new File(engineEtc, "krb5.conf"); if (!krb5File.exists()) { String msg = String.format("Failed loading kerberos settings from File %1$s.", krb5File.getAbsolutePath()); log.error(msg); throw new RuntimeException(msg); <START> } else { <END> System.setProperty("java.security.krb5.conf", krb5File.getAbsolutePath()); } System.setProperty("sun.security.krb5.msinterop.kstring", "true"); }</code><technical_language>need for else positive flow</technical_language>

Target:
private KerberosManager() { String engineEtc = System.getenv("ENGINE_ETC"); if (engineEtc == null) { engineEtc = "/etc/ovirt-engine"; } File krb5File = new File(engineEtc, "krb5.conf"); if (!krb5File.exists()) { String msg = String.format("Failed loading kerberos settings from File %1$s.", krb5File.getAbsolutePath()); log.error(msg); throw new RuntimeException(msg); } System.setProperty("java.security.krb5.conf", krb5File.getAbsolutePath()); System.setProperty("sun.security.krb5.msinterop.kstring", "true"); }
Source:
<code>public final void parseVersion( String version ) { comparable = new ComparableVersion( version ); int index = version.indexOf( '-' ); String part1; String part2 = null; if ( index < 0 ) { part1 = version; } else { part1 = version.substring( 0, index ); part2 = version.substring( index + 1 ); } if ( part2 != null ) { if ( part2.length() == 1 || !part2.startsWith( "0" ) ) { buildNumber = tryParseInt( part2 ); if ( buildNumber == null ) { qualifier = part2; } } else { qualifier = part2; } } if ( ( !part1.contains( "." ) ) && !part1.startsWith( "0" ) ) { majorVersion = tryParseInt( part1 ); if ( majorVersion == null ) { qualifier = version; buildNumber = null; } } else { boolean fallback = false; StringTokenizer tok = new StringTokenizer( part1, "." ); if ( tok.hasMoreTokens() ) { majorVersion = getNextIntegerToken( tok ); if ( majorVersion == null ) { fallback = true; } } else { fallback = true; } if ( tok.hasMoreTokens() ) { minorVersion = getNextIntegerToken( tok ); if ( minorVersion == null ) { fallback = true; } } if ( tok.hasMoreTokens() ) { incrementalVersion = getNextIntegerToken( tok ); if ( incrementalVersion == null ) { fallback = true; } } if ( tok.hasMoreTokens() ) { qualifier = tok.nextToken(); <START> fallback = Pattern.compile( "\\d+" ).matcher( qualifier ).matches(); <END> } if ( part1.contains( ".." ) || part1.startsWith( "." ) || part1.endsWith( "." ) ) { fallback = true; } if ( fallback ) { qualifier = version; majorVersion = null; minorVersion = null; incrementalVersion = null; buildNumber = null; } } }</code><technical_language>char array approach before</technical_language>

Target:
public final void parseVersion( String version ) { comparable = new ComparableVersion( version ); int index = version.indexOf( '-' ); String part1; String part2 = null; if ( index < 0 ) { part1 = version; } else { part1 = version.substring( 0, index ); part2 = version.substring( index + 1 ); } if ( part2 != null ) { if ( part2.length() == 1 || !part2.startsWith( "0" ) ) { buildNumber = tryParseInt( part2 ); if ( buildNumber == null ) { qualifier = part2; } } else { qualifier = part2; } } if ( ( !part1.contains( "." ) ) && !part1.startsWith( "0" ) ) { majorVersion = tryParseInt( part1 ); if ( majorVersion == null ) { qualifier = version; buildNumber = null; } } else { boolean fallback = false; StringTokenizer tok = new StringTokenizer( part1, "." ); if ( tok.hasMoreTokens() ) { majorVersion = getNextIntegerToken( tok ); if ( majorVersion == null ) { fallback = true; } } else { fallback = true; } if ( tok.hasMoreTokens() ) { minorVersion = getNextIntegerToken( tok ); if ( minorVersion == null ) { fallback = true; } } if ( tok.hasMoreTokens() ) { incrementalVersion = getNextIntegerToken( tok ); if ( incrementalVersion == null ) { fallback = true; } } if ( tok.hasMoreTokens() ) { qualifier = tok.nextToken(); fallback = isDigits( qualifier ); } if ( part1.contains( ".." ) || part1.startsWith( "." ) || part1.endsWith( "." ) ) { fallback = true; } if ( fallback ) { qualifier = version; majorVersion = null; minorVersion = null; incrementalVersion = null; buildNumber = null; } } }
Source:
<code>public Message(String nodeName, Id nodeID, User sender, Content content) throws MessageException, NodeException <START> { <END> super(nodeName, nodeID); if (sender == null){ throw new MessageException("Error, null sender in Message constructor"); } else if (content == null){ throw new MessageException("Error, null content in Message constructor"); } else { this.mSender = sender; this.mContent = content; this.mDate = new java.util.Date(); } }</code><technical_language>do checked exceptions here</technical_language>

Target:
public Message(String nodeName, Id nodeID, User sender, Content content) { super(nodeName, nodeID); this.mSender = Objects.requireNonNull(sender); this.mContent = Objects.requireNonNull(content); this.mDate = new java.util.Date(); }
Source:
<code>public void start() { mSuccess = false; try { mProjectsFolder = File.createTempFile("targettranslation", "." + Translator.ARCHIVE_EXTENSION); FileUtils.copyInputStreamToFile(resolver.openInputStream(mContentUri), mProjectsFolder); ArchiveDetails details = ArchiveDetails.newInstance(mProjectsFolder, Locale.getDefault().getLanguage(), AppContext.getLibrary()); mProjectsFound = ""; mAlreadyPresent = false; for (ArchiveDetails.TargetTranslationDetails td : details.targetTranslationDetails) { mProjectsFound += td.projectName + " - " + td.targetLanguageName + ", "; String targetTranslationId = td.targetTranslationSlug; <START> File localDir = new File(AppContext.getTranslator().getPath(), targetTranslationId); <END> TargetTranslation localTargetTranslation = TargetTranslation.open(localDir); if ((localTargetTranslation != null)) { mAlreadyPresent = true; } } mProjectsFound = mProjectsFound.replaceAll(", $", ""); mSuccess = true; } catch (Exception e) { Logger.e(TAG,"Error processing input file: " + mContentUri.toString()); } }</code><technical_language>correct a target translation is id. building path manually. e.g. AppContext.getTranslator().getTargetTranslation(targetTranslationId)</technical_language>

Target:
public void start() { mSuccess = false; try { mProjectsFolder = File.createTempFile("targettranslation", "." + Translator.ARCHIVE_EXTENSION); FileUtils.copyInputStreamToFile(resolver.openInputStream(mContentUri), mProjectsFolder); ArchiveDetails details = ArchiveDetails.newInstance(mProjectsFolder, Locale.getDefault().getLanguage(), AppContext.getLibrary()); mProjectsFound = ""; mAlreadyPresent = false; for (ArchiveDetails.TargetTranslationDetails td : details.targetTranslationDetails) { mProjectsFound += td.projectName + " - " + td.targetLanguageName + ", "; String targetTranslationId = td.targetTranslationSlug; TargetTranslation localTargetTranslation = AppContext.getTranslator().getTargetTranslation(targetTranslationId); if ((localTargetTranslation != null)) { mAlreadyPresent = true; } } mProjectsFound = mProjectsFound.replaceAll(", $", ""); mSuccess = true; } catch (Exception e) { Logger.e(TAG,"Error processing input file: " + mContentUri.toString()); } }
Source:
<code>public boolean deployAllAPIsAtGatewayStartup (Set<String> assignedGatewayLabels) throws ArtifactSynchronizerException { if (gatewayArtifactSynchronizerProperties.isRetrieveFromStorageEnabled()) { if (artifactRetriever != null) { try { Iterator<String> it = assignedGatewayLabels.iterator(); APIGatewayAdminClient apiGatewayAdminClient = new APIGatewayAdminClient(); while (it.hasNext()) { String label = it.next(); List<String> gatewayRuntimeArtifacts = ServiceReferenceHolder .getInstance().getArtifactRetriever().retrieveAllArtifacts(label); for (String APIruntimeArtifact :gatewayRuntimeArtifacts){ GatewayAPIDTO gatewayAPIDTO = null; try { <START> if (!StringUtils.isEmpty(APIruntimeArtifact)) { <END> gatewayAPIDTO = new Gson().fromJson(APIruntimeArtifact, GatewayAPIDTO.class); log.info("Deploying synapse artifacts of " + gatewayAPIDTO.getName()); apiGatewayAdminClient.deployAPI(gatewayAPIDTO); } } catch (AxisFault axisFault) { log.error("Error in deploying" + gatewayAPIDTO.getName()+ " to the Gateway "); continue; } } if (debugEnabled) { log.debug("APIs deployed in gateway with the label of " + label); } } return true; } catch (ArtifactSynchronizerException | IOException e ) { String msg = "Error deploying APIs to the Gateway "; log.error(msg, e); throw new ArtifactSynchronizerException(msg, e); } } else { String msg = "Artifact retriever not found"; log.error(msg); throw new ArtifactSynchronizerException(msg); } } return false; }</code><technical_language>fix variable naming</technical_language>

Target:
public boolean deployAllAPIsAtGatewayStartup (Set<String> assignedGatewayLabels) throws ArtifactSynchronizerException { if (gatewayArtifactSynchronizerProperties.isRetrieveFromStorageEnabled()) { if (artifactRetriever != null) { try { Iterator<String> it = assignedGatewayLabels.iterator(); APIGatewayAdminClient apiGatewayAdminClient = new APIGatewayAdminClient(); while (it.hasNext()) { String label = it.next(); List<String> gatewayRuntimeArtifacts = ServiceReferenceHolder .getInstance().getArtifactRetriever().retrieveAllArtifacts(label); for (String runtimeArtifact :gatewayRuntimeArtifacts){ GatewayAPIDTO gatewayAPIDTO = null; try { if (StringUtils.isNotEmpty(runtimeArtifact)) { gatewayAPIDTO = new Gson().fromJson(runtimeArtifact, GatewayAPIDTO.class); log.info("Deploying synapse artifacts of " + gatewayAPIDTO.getName()); apiGatewayAdminClient.deployAPI(gatewayAPIDTO); } } catch (AxisFault axisFault) { log.error("Error in deploying" + gatewayAPIDTO.getName()+ " to the Gateway "); continue; } } if (debugEnabled) { log.debug("APIs deployed in gateway with the label of " + label); } } return true; } catch (ArtifactSynchronizerException | IOException e ) { String msg = "Error deploying APIs to the Gateway "; log.error(msg, e); throw new ArtifactSynchronizerException(msg, e); } } else { String msg = "Artifact retriever not found"; log.error(msg); throw new ArtifactSynchronizerException(msg); } } return false; }
Source:
<code>private boolean isWorkplaceJoined() { @SuppressWarnings("unchecked") Class<IDeviceCertificate> certClass = (Class<IDeviceCertificate>)AuthenticationSettings.INSTANCE.getDeviceCertificateProxy(); <START> return (certClass != null); <END> }</code><technical_language>remove bracket</technical_language>

Target:
private boolean isWorkplaceJoined() { @SuppressWarnings("unchecked") Class<IDeviceCertificate> certClass = (Class<IDeviceCertificate>)AuthenticationSettings.INSTANCE.getDeviceCertificateProxy(); return certClass != null; }
Source:
<code>private void insertIntoInv(List<ItemStack> stacks) { stacks.forEach(stack -> { for (int i = 0; i < 6; i++) { <START> if (insertIntoInv(i, stack).isEmpty()) { <END> break; } } }); }</code><technical_language>worth making work if free space in inv. this void items full I think</technical_language>

Target:
private boolean insertIntoInv(List<ItemStack> stacks) { boolean result = false; for (ItemStack stack : stacks) { for (int i = 0; i < 6; i++) { if (insertIntoInv(i, stack)) result = true; if (stack.isEmpty()) break; } } return result; }
Source:
<code>protected void init() throws Exception { if (aggregateMissingLicensesFile!=null&& !aggregateMissingLicensesFile.equals(missingFile)) { getLog().warn(""); getLog().warn("You should use *missingFile* parameter instead of deprecated *aggregateMissingLicensesFile*."); getLog().warn(""); missingFile = aggregateMissingLicensesFile; } if (aggregateMissingLicensesFileArtifact!=null && !aggregateMissingLicensesFileArtifact.equals(missingLicensesFileArtifact)) { getLog().warn(""); getLog().warn("You should use *missingLicensesFileArtifact* parameter instead of deprecated *aggregateMissingLicensesFileArtifact*."); getLog().warn(""); missingLicensesFileArtifact = aggregateMissingLicensesFileArtifact; } isAggregatorBuild = true; reactorProjectDependencies = new TreeMap<>(); for (MavenProject reactorProject : this.reactorProjects) { <START> reactorProjectDependencies.put(String.format("%s:%s", reactorProject.getGroupId(), reactorProject.getArtifactId()), reactorProject.getDependencies()); <END> } super.init(); }</code><technical_language>Code style</technical_language>

Target:
protected void init() throws Exception { if ( aggregateMissingLicensesFile != null && !aggregateMissingLicensesFile.equals( missingFile ) ) { getLog().warn( "" ); getLog().warn( "You should use *missingFile* parameter instead of deprecated *aggregateMissingLicensesFile*." ); getLog().warn( "" ); missingFile = aggregateMissingLicensesFile; } if ( aggregateMissingLicensesFileArtifact != null && !aggregateMissingLicensesFileArtifact.equals( missingLicensesFileArtifact ) ) { getLog().warn( "" ); getLog().warn( "You should use *missingLicensesFileArtifact* parameter instead of deprecated *aggregateMissingLicensesFileArtifact*." ); getLog().warn( "" ); missingLicensesFileArtifact = aggregateMissingLicensesFileArtifact; } super.init(); }
Source:
<code>@Override public <T> Future<T> execute(HttpAsyncRequestProducer requestProducer, HttpAsyncResponseConsumer<T> responseConsumer, HttpContext context, FutureCallback<T> callback) { context.setAttribute(TraceContext.class.getName(), currentTraceContext.get()); return delegate.execute( new TracingAsyncRequestProducer(requestProducer, context), new TracingAsyncResponseConsumer<>(responseConsumer, context), context, <START> new FutureCallbackWithCurrentSpan(tracer.currentSpan(), callback) <END> ); }</code><technical_language>tracecontext in currentSpan set in context.setAttribute right? some cost fetching it, I remember reuse context value</technical_language>

Target:
@Override public <T> Future<T> execute(HttpAsyncRequestProducer requestProducer, HttpAsyncResponseConsumer<T> responseConsumer, HttpContext context, FutureCallback<T> callback) { TraceContext traceCtx = currentTraceContext.get(); context.setAttribute(TraceContext.class.getName(), traceCtx); return delegate.execute( new TracingAsyncRequestProducer(requestProducer, context), new TracingAsyncResponseConsumer<>(responseConsumer, context), context, callback == null ? null : new TraceContextAwareFutureCallback(currentTraceContext, traceCtx, callback) ); }
Source:
<code>private void populateDirectoryList() { setContentView(R.layout.uploader_layout); ListView mListView = (ListView) findViewById(android.R.id.list); ActionBar actionBar = getSupportActionBar(); String current_dir = mParents.peek(); if (current_dir.equals("")) { actionBar.setTitle(getString(R.string.uploader_top_message)); } else { actionBar.setTitle(current_dir); } boolean notRoot = (mParents.size() > 1); actionBar.setDisplayHomeAsUpEnabled(notRoot); actionBar.setHomeButtonEnabled(notRoot); String full_path = generatePath(mParents); Log_OC.d(TAG, "Populating view with content of : " + full_path); mFile = getStorageManager().getFileByPath(full_path); if (mFile != null) { Vector<OCFile> files = getStorageManager().getFolderContent(mFile ); files = sortFileList(files); List<HashMap<String, Object>> data = new LinkedList<>(); for (OCFile f : files) { <START> if (f.isFolder()) { <END> HashMap<String, Object> h = new HashMap<>(); h.put("dirname", f); data.add(h); } } UploaderAdapter sa = new UploaderAdapter(this, data, R.layout.uploader_list_item_layout, new String[] {"dirname"}, new int[] {R.id.filename}, getStorageManager(), getAccount()); mListView.setAdapter(sa); Button btnChooseFolder = (Button) findViewById(R.id.uploader_choose_folder); btnChooseFolder.setOnClickListener(this); Button btnNewFolder = (Button) findViewById(R.id.uploader_cancel); btnNewFolder.setOnClickListener(this); mListView.setOnItemClickListener(this); } }</code><technical_language>This leads a regression. In master app is showing files, folders. if sentence removed</technical_language>

Target:
private void populateDirectoryList() { setContentView(R.layout.uploader_layout); ListView mListView = (ListView) findViewById(android.R.id.list); ActionBar actionBar = getSupportActionBar(); String current_dir = mParents.peek(); if (current_dir.equals("")) { actionBar.setTitle(getString(R.string.uploader_top_message)); } else { actionBar.setTitle(current_dir); } boolean notRoot = (mParents.size() > 1); actionBar.setDisplayHomeAsUpEnabled(notRoot); actionBar.setHomeButtonEnabled(notRoot); String full_path = generatePath(mParents); Log_OC.d(TAG, "Populating view with content of : " + full_path); mFile = getStorageManager().getFileByPath(full_path); if (mFile != null) { Vector<OCFile> files = getStorageManager().getFolderContent(mFile ); files = sortFileList(files); List<HashMap<String, Object>> data = new LinkedList<>(); for (OCFile f : files) { HashMap<String, Object> h = new HashMap<>(); h.put("dirname", f); data.add(h); } UploaderAdapter sa = new UploaderAdapter(this, data, R.layout.uploader_list_item_layout, new String[] {"dirname"}, new int[] {R.id.filename}, getStorageManager(), getAccount()); mListView.setAdapter(sa); Button btnChooseFolder = (Button) findViewById(R.id.uploader_choose_folder); btnChooseFolder.setOnClickListener(this); Button btnNewFolder = (Button) findViewById(R.id.uploader_cancel); btnNewFolder.setOnClickListener(this); mListView.setOnItemClickListener(this); } }
Source:
<code>public <T> Mono<DecryptionResult<T>> getDecryptionResult(final Class<T> classType) { ObjectNode decryptableContentAsObjectNode = Utils.as(this.decryptableContent, ObjectNode.class); if (decryptableContentAsObjectNode == null) { return Mono.just(new DecryptionResult<>(Utils.getSimpleObjectMapper().convertValue(this.decryptableContent, classType), null)); } Mono<Pair<ObjectNode, DecryptionContext>> decryptedItemAndContextPairMono = EncryptionProcessor.decrypt(decryptableContentAsObjectNode, this.encryptor); <START> <END> return decryptedItemAndContextPairMono.map( decryptedItemAndContextPair -> { T ii = this.cosmosSerializer.convert(classType, decryptedItemAndContextPair.getLeft()); return new DecryptionResult<>(ii, decryptedItemAndContextPair.getRight()); } ).onErrorResume( t -> { Exception exception = Utils.as(t, Exception.class); if (exception == null) { return Mono.error(t); } assert exception != null; JsonNode encryptedInfo = decryptableContentAsObjectNode.get(Constants.ENCRYPTION_INFO); ObjectNode encryptedInfoObject = Utils.as(encryptedInfo, ObjectNode.class); String dataEncryptionKeyId = (encryptedInfoObject != null) ? encryptedInfoObject.get(Constants.DATA_ENCRYPTION_KEY_ID).asText() : null; exception = new EncryptionException( dataEncryptionKeyId, this.decryptableContent.toString(), exception); return Mono.error(exception); } ); }</code><technical_language>remove line</technical_language>

Target:
public <T> Mono<DecryptionResult<T>> getDecryptionResult(final Class<T> classType) { ObjectNode decryptableContentAsObjectNode = Utils.as(this.decryptableContent, ObjectNode.class); if (decryptableContentAsObjectNode == null) { return Mono.just(new DecryptionResult<>(Utils.getSimpleObjectMapper().convertValue(this.decryptableContent, classType), null)); } Mono<Pair<ObjectNode, DecryptionContext>> decryptedItemAndContextPairMono = EncryptionProcessor.decrypt(decryptableContentAsObjectNode, this.encryptor); return decryptedItemAndContextPairMono.map( decryptedItemAndContextPair -> { T ii = this.cosmosSerializer.convert(classType, decryptedItemAndContextPair.getLeft()); return new DecryptionResult<>(ii, decryptedItemAndContextPair.getRight()); } ).onErrorResume( t -> { Exception exception = Utils.as(t, Exception.class); if (exception == null) { return Mono.error(t); } JsonNode encryptedInfo = decryptableContentAsObjectNode.get(Constants.ENCRYPTION_INFO); ObjectNode encryptedInfoObject = Utils.as(encryptedInfo, ObjectNode.class); String dataEncryptionKeyId = (encryptedInfoObject != null) ? encryptedInfoObject.get(Constants.DATA_ENCRYPTION_KEY_ID).asText() : null; exception = new EncryptionException( dataEncryptionKeyId, this.decryptableContent.toString(), exception); return Mono.error(exception); } ); }
Source:
<code>public SnapshotStatus[] getSnapshotListing(String snapshotRoot) throws IOException { SnapshotStatus[] status = null; checkOperation(OperationCategory.READ); boolean success = false; readLock(); try { checkOperation(OperationCategory.READ); status = FSDirSnapshotOp.getSnapshotListing(dir, snapshotManager, snapshotRoot); success = true; } catch (AccessControlException ace) { <START> logAuditEvent(success, "listSnapshots", null, null, null); <END> throw ace; } finally { readUnlock(); } logAuditEvent(success, "listSnapshots", null, null, null); return status; }</code><technical_language>put path in audit log logAuditEvent(success, "listSnapshots", snapshotRoot);</technical_language>

Target:
public SnapshotStatus[] getSnapshotListing(String snapshotRoot) throws IOException { final String operationName = "listSnapshotDirectory"; SnapshotStatus[] status; checkOperation(OperationCategory.READ); boolean success = false; final FSPermissionChecker pc = getPermissionChecker(); FSPermissionChecker.setOperationType(operationName); try { readLock(); try { checkOperation(OperationCategory.READ); status = FSDirSnapshotOp.getSnapshotListing(dir, pc, snapshotManager, snapshotRoot); success = true; } finally { readUnlock(operationName, getLockReportInfoSupplier(null)); } } catch (AccessControlException ace) { logAuditEvent(success, "listSnapshots", snapshotRoot); throw ace; } logAuditEvent(success, "listSnapshots", snapshotRoot); return status; }
Source:
<code>public boolean isNoexcept(boolean inCalledContext) { ICPPFunction overload = getOverload(); if (overload != null) { ICPPASTFunctionDeclarator decl = FunctionHelpers.findDeclarator(overload); <START> if (decl.getNoexceptExpression() == null) <END> return false; } return fArg1.isNoexcept(inCalledContext) && fArg2.isNoexcept(inCalledContext); }</code><technical_language>If is a noexcept-expression, needs evaluated. In current AST formulation, done ValueFactory.create(IASTExpression), start evaluations ICPPEvaluation.getValue(). This applies other places in this patch currently check if noexcept-expression is null</technical_language>

Target:
public boolean isNoexcept(boolean inCalledContext) { ICPPFunction overload = getOverload(); if (overload != null) { return EvalUtil.evaluateNoexceptSpecifier(overload.getType().getNoexceptSpecifier()); } return fArg1.isNoexcept(inCalledContext) && fArg2.isNoexcept(inCalledContext); }
Source:
<code>public Mono<MsalToken> authenticateWithUsernamePassword(TokenRequestContext request, String username, String password) { return Mono.fromFuture(() -> getPublicClientApplication(false).acquireToken( UserNamePasswordParameters.builder(new HashSet<>(request.getScopes()), username, password.toCharArray()) .build())) <START> .onErrorResume(t -> Mono.error(new ClientAuthenticationException("Failed to acquire token with username " <END> + "and password", null, t))).map(ar -> new MsalToken(ar, options)); }</code><technical_language>this onErrorMap? This logic more of error mapping alternate resume exception this propagate error</technical_language>

Target:
public Mono<MsalToken> authenticateWithUsernamePassword(TokenRequestContext request, String username, String password) { return Mono.fromFuture(() -> getPublicClientApplication(false).acquireToken( UserNamePasswordParameters.builder(new HashSet<>(request.getScopes()), username, password.toCharArray()) .build())) .onErrorMap(t -> new ClientAuthenticationException("Failed to acquire token with username and password", null, t)).map(ar -> new MsalToken(ar, options)); }
Source:
<code>protected static PromoDialogAdvanced newInstance(Builder builder) { PromoDialogAdvanced fragment = new PromoDialogAdvanced(); Bundle args = new Bundle(); <START> args.putInt("drawableId", builder.drawableId); <END> args.putInt("titleId", builder.titleId); args.putInt("descriptionId", builder.descriptionId); args.putInt("linkId", builder.linkId); args.putInt("buttonNegativeId", builder.buttonNegativeId); args.putInt("buttonPositiveId", builder.buttonPositiveId); fragment.setArguments(args); return fragment; }</code><technical_language>move "drawableId", "titleId", strings private static final String...</technical_language>

Target:
protected static PromoDialogAdvanced newInstance(Builder builder) { PromoDialogAdvanced fragment = new PromoDialogAdvanced(); Bundle args = new Bundle(); args.putInt(KEY_DRAWABLE_RES_ID, builder.drawableResId); args.putInt(KEY_TITLE_RES_ID, builder.titleResId); args.putInt(KEY_DESCRIPTION_RES_ID, builder.descriptionResId); args.putInt(KEY_LINK_RES_ID, builder.linkResId); args.putInt(KEY_BUTTON_NEGATIVE_RES_ID, builder.buttonNegativeResId); args.putInt(KEY_BUTTON_POSITIVE_RES_ID, builder.buttonPositiveResId); fragment.setArguments(args); return fragment; }
Source:
<code>public ResourceProcessor<Resource<CorsSite>> corsSiteResourceProcessor() { return new ResourceProcessor<Resource<CorsSite>>() { @Override public Resource<CorsSite> process(Resource<CorsSite> resource) { LinkBuilder link = configuration.entityLinks().linkForSingleResource( CorsSite.class, resource.getContent().getId() ) .slash("addToNetwork"); resource.add(link.withRel("addToNetwork")); <START> LinkBuilder link2 = configuration.entityLinks().linkForSingleResource( <END> CorsSite.class, resource.getContent().getId() ) .slash("removeFromNetwork"); resource.add(link2.withRel("removeFromNetwork")); return resource; } }; }</code><technical_language>naming, removeFromNetworkLink (and addToNetworkLink)</technical_language>

Target:
public ResourceProcessor<Resource<CorsSite>> corsSiteResourceProcessor() { return new ResourceProcessor<Resource<CorsSite>>() { @Override public Resource<CorsSite> process(Resource<CorsSite> resource) { LinkBuilder addToNetworkLink = configuration.entityLinks().linkForSingleResource( CorsSite.class, resource.getContent().getId() ) .slash("addToNetwork"); resource.add(addToNetworkLink.withRel("addToNetwork")); LinkBuilder removeFromNetworkLink = configuration.entityLinks().linkForSingleResource( CorsSite.class, resource.getContent().getId() ) .slash("removeFromNetwork"); resource.add(removeFromNetworkLink.withRel("removeFromNetwork")); return resource; } }; }
Source:
<code>protected boolean canDoAction() { <START> Disk disk = getDiskDao().get(getParameters().getImageGroupID()); <END> if (disk.getDiskStorageType() == DiskStorageType.LUN) { return failCanDoAction(EngineMessage.ACTION_TYPE_FAILED_LUN_DISK); } return true; }</code><technical_language>change patch-set 3</technical_language>

Target:
protected boolean canDoAction() { return !isDiskLun(); }
Source:
<code>private Optional<PublicKey> readPublicKeyFromLocation(String publicKeyLocation, String keyID) throws Exception { URL publicKeyURL = currentThread().getContextClassLoader().getResource(publicKeyLocation); if (publicKeyURL == null) { try { publicKeyURL = new URL(publicKeyLocation); } catch (MalformedURLException ex) { publicKeyURL = null; } } if (publicKeyURL == null) { return Optional.empty(); } try (InputStream inputStream = publicKeyURL.openStream(); <START> BufferedReader reader = new BufferedReader(new InputStreamReader(inputStream))){ <END> String keyContents = reader.lines().collect(Collectors.joining(System.lineSeparator())); return createPublicKey(keyContents, keyID); } }</code><technical_language>explicitly a CharSet read stream (using InputStreamReader ctor CharSet) instead of system default CharSet? able determine correct encoding getContentEncoding() reading content</technical_language>

Target:
private Optional<PublicKey> readPublicKeyFromLocation(String publicKeyLocation, String keyID) throws Exception { URL publicKeyURL = currentThread().getContextClassLoader().getResource(publicKeyLocation); if (publicKeyURL == null) { try { publicKeyURL = new URL(publicKeyLocation); } catch (MalformedURLException ex) { publicKeyURL = null; } } if (publicKeyURL == null) { return Optional.empty(); } URLConnection urlConnection = publicKeyURL.openConnection(); Charset charset = Charset.defaultCharset(); ContentType contentType = ContentType.newContentType(urlConnection.getContentType()); if(contentType != null) { String charEncoding = contentType.getCharacterEncoding(); if(charEncoding != null) { try { if (!Charset.isSupported(charEncoding)) { LOGGER.warning("Charset " + charEncoding + " for remote public key not supported, using default charset instead"); } else { charset = Charset.forName(contentType.getCharacterEncoding()); } }catch (IllegalCharsetNameException ex){ LOGGER.severe("Charset " + ex.getCharsetName() + " for remote public key not support, Cause: " + ex.getMessage()); } } } try (InputStream inputStream = urlConnection.getInputStream(); BufferedReader reader = new BufferedReader(new InputStreamReader(inputStream, charset))){ String keyContents = reader.lines().collect(Collectors.joining(System.lineSeparator())); return createPublicKey(keyContents, keyID); } }
Source:
<code>private static boolean setApiTokenVersion2(final SharedPreferences prefs, final String apiToken) throws KeyStoreException, IOException, NoSuchAlgorithmException, CertificateException, NoSuchPaddingException, InvalidKeyException, UnrecoverableEntryException, IllegalBlockSizeException, BadPaddingException { final KeyStore keyStore = getKeyStore(); final SecretKey key = (SecretKey) keyStore.getKey(KEYSTORE_WIGLE_CREDS_KEY_V2, null); Cipher encrypt = Cipher.getInstance(AES_CIPHER); encrypt.init(Cipher.ENCRYPT_MODE, key); <START> final byte[] input = apiToken.getBytes(); <END> final byte[] cypherToken = encrypt.doFinal(input); if (cypherToken == null) { MainActivity.error("[TOKEN] ERROR: unreachable condition, cypherToken NULL. APIv" + Build.VERSION.SDK_INT); return false; } final byte[] iv = encrypt.getIV(); final int tagLength = (cypherToken.length - input.length) * 8; final SharedPreferences.Editor editor = prefs.edit(); editor.putString(ListFragment.PREF_TOKEN, Base64.encodeToString(cypherToken, Base64.DEFAULT)); editor.putString(ListFragment.PREF_TOKEN_IV, Base64.encodeToString(iv, Base64.DEFAULT)); editor.putInt(ListFragment.PREF_TOKEN_TAG_LENGTH, tagLength); editor.apply(); MainActivity.info("[TOKEN] setApiTokenVersion2 set token length: " + apiToken.length()); return true; }</code><technical_language>apiToken need a null check someplace this</technical_language>

Target:
private static boolean setApiTokenVersion2(final SharedPreferences prefs, final String apiToken) throws KeyStoreException, IOException, NoSuchAlgorithmException, CertificateException, NoSuchPaddingException, InvalidKeyException, UnrecoverableEntryException, IllegalBlockSizeException, BadPaddingException { if (apiToken == null) { MainActivity.error("[TOKEN] ERROR: unreachable condition, apiToken NULL. APIv" + Build.VERSION.SDK_INT); return false; } final KeyStore keyStore = getKeyStore(); final SecretKey key = (SecretKey) keyStore.getKey(KEYSTORE_WIGLE_CREDS_KEY_V2, null); Cipher encrypt = Cipher.getInstance(AES_CIPHER); encrypt.init(Cipher.ENCRYPT_MODE, key); final byte[] input = apiToken.getBytes(); final byte[] cypherToken = encrypt.doFinal(input); if (cypherToken == null) { MainActivity.error("[TOKEN] ERROR: unreachable condition, cypherToken NULL. APIv" + Build.VERSION.SDK_INT); return false; } final byte[] iv = encrypt.getIV(); final int tagLength = (cypherToken.length - input.length) * 8; final SharedPreferences.Editor editor = prefs.edit(); editor.putString(ListFragment.PREF_TOKEN, Base64.encodeToString(cypherToken, Base64.DEFAULT)); editor.putString(ListFragment.PREF_TOKEN_IV, Base64.encodeToString(iv, Base64.DEFAULT)); editor.putInt(ListFragment.PREF_TOKEN_TAG_LENGTH, tagLength); editor.apply(); MainActivity.info("[TOKEN] setApiTokenVersion2 set token length: " + apiToken.length()); return true; }
Source:
<code>private <T extends Trade> ValueWithFailures<List<T>> parseFile(CsvIterator csv, Class<T> tradeType) { List<T> trades = new ArrayList<>(); List<FailureItem> failures = new ArrayList<>(); int line = 2; for (CsvRow row : (Iterable<CsvRow>) () -> csv) { try { String typeRaw = row.getField(TYPE_FIELD); String type = typeRaw.toUpperCase(Locale.ENGLISH); TradeInfo info = parseTradeInfo(row); switch (type.toUpperCase(Locale.ENGLISH)) { case "FRA": if (tradeType == FraTrade.class || tradeType == Trade.class) { trades.add(tradeType.cast(FraTradeCsvLoader.parse(row, info, refData))); } break; case "SWAP": if (tradeType == SwapTrade.class || tradeType == Trade.class) { trades.add(tradeType.cast(SwapTradeCsvLoader.parse(row, info, refData))); } break; case "TERMDEPOSIT": case "TERM DEPOSIT": if (tradeType == TermDepositTrade.class || tradeType == Trade.class) { trades.add(tradeType.cast(TermDepositTradeCsvLoader.parse(row, info, refData))); } break; default: failures.add( FailureItem.of(FailureReason.PARSING, "CSV file trade type '{}' is not known at line {}", typeRaw, line)); break; } line++; } catch (RuntimeException ex) { failures.add( FailureItem.of(FailureReason.PARSING, ex, "CSV file trade could not be parsed at line {}: " + ex.getMessage(), line)); } <START> } <END> return ValueWithFailures.of(trades, failures); }</code><technical_language>Line count incremented if exception is thrown</technical_language>

Target:
private <T extends Trade> ValueWithFailures<List<T>> parseFile(CsvIterator csv, Class<T> tradeType) { List<T> trades = new ArrayList<>(); List<FailureItem> failures = new ArrayList<>(); int line = 2; for (CsvRow row : (Iterable<CsvRow>) () -> csv) { try { String typeRaw = row.getField(TYPE_FIELD); String type = typeRaw.toUpperCase(Locale.ENGLISH); TradeInfo info = parseTradeInfo(row); switch (type.toUpperCase(Locale.ENGLISH)) { case "FRA": if (tradeType == FraTrade.class || tradeType == Trade.class) { trades.add(tradeType.cast(FraTradeCsvLoader.parse(row, info, refData))); } break; case "SWAP": if (tradeType == SwapTrade.class || tradeType == Trade.class) { trades.add(tradeType.cast(SwapTradeCsvLoader.parse(row, info, refData))); } break; case "TERMDEPOSIT": case "TERM DEPOSIT": if (tradeType == TermDepositTrade.class || tradeType == Trade.class) { trades.add(tradeType.cast(TermDepositTradeCsvLoader.parse(row, info, refData))); } break; default: failures.add( FailureItem.of(FailureReason.PARSING, "CSV file trade type '{}' is not known at line {}", typeRaw, line)); break; } } catch (RuntimeException ex) { failures.add( FailureItem.of(FailureReason.PARSING, ex, "CSV file trade could not be parsed at line {}: " + ex.getMessage(), line)); } line++; } return ValueWithFailures.of(trades, failures); }
Source:
<code>public void setVmNetwork(Boolean vmNetwork) { if (!ObjectUtils.objectsEqual(this.vmNetwork, vmNetwork)) { this.vmNetwork = vmNetwork; <START> onPropertyChanged(new PropertyChangedEventArgs("Vm Network")); END> } }</code><technical_language>need this, listening "Role" property changed event. ObjectUtils.objectsEqual() check necessary either, set member. (the case if this item in form, constructors of FormItem)</technical_language>

Target:
public void setVmNetwork(Boolean vmNetwork) { this.vmNetwork = vmNetwork; }
Source:
<code>public OsmAndProtocolDecoder(OsmAndProtocol protocol) { super(protocol); <START> speedUnits = Context.getConfig().getString("osmand.speedUnits", "kn"); <END> }</code><technical_language>Please consistent other places: <LINK_0> Possibly updating TK103 decoder better</technical_language>

Target:
public OsmAndProtocolDecoder(OsmAndProtocol protocol) { super(protocol); }