auphong2707/dl4se-code-review-dataset huggingface dataset:
Source:
public final void updateAAD ( java.nio.ByteBuffer input ) { if ( ( ( mode ) != ( javax.crypto.Cipher.ENCRYPT_MODE ) ) && ( ( mode ) != ( javax.crypto.Cipher.DECRYPT_MODE ) ) ) { throw new java.lang.IllegalStateException ( "Cipher is not initialized" ) ; } if ( input == null ) { throw new java.lang.IllegalArgumentException ( "input == null" ) ; } spiImpl.engineUpdateAAD ( input ) ; }

Target:
public final void updateAAD ( java.nio.ByteBuffer input ) { if ( ( ( mode ) != ( javax.crypto.Cipher.ENCRYPT_MODE ) ) && ( ( mode ) != ( javax.crypto.Cipher.DECRYPT_MODE ) ) ) { throw new java.lang.IllegalStateException ( "Cipher is not initialized" ) ; } if ( input == null ) { throw new java.lang.IllegalArgumentException ( "input == null" ) ; } getSpi ( ) . engineUpdateAAD ( input ) ; }
Source:
static boolean containsValueImpl ( java.util.Map < ? , ? > map , @ javax.annotation.Nullable java.lang.Object value ) { for ( java.util.Map.Entry < ? , ? > entry : map.entrySet ( ) ) { if ( com.google.common.base.Objects.equal ( entry.getValue ( ) , value ) ) { return true ; } } return false ; }

Target:
static boolean containsValueImpl ( java.util.Map < ? , ? > map , @ javax.annotation.Nullable java.lang.Object value ) { return com.google.common.collect.Iterators.contains ( com.google.common.collect.Maps.valueIterator ( map.entrySet ( ) . iterator ( ) ) , value ) ; }
Source:
public boolean hasIccCardUsingSlotId ( int slotId ) { int [ ] subId = mSubscriptionController.getSubIdUsingSlotId ( slotId ) ; final com.android.internal.telephony.Phone phone = getPhone ( subId [ 0 ] ) ; if ( ( subId != null ) && ( phone != null ) ) { return phone.getIccCard ( ) . hasIccCard ( ) ; } else { return false ; } }

Target:
public boolean hasIccCard ( ) { return hasIccCardUsingSlotIndex ( mSubscriptionController.getSlotIndex ( getDefaultSubscription ( ) ) ) ; }
Source:
private void processExisting ( int permissions ) throws com.android.sched.util.file.NoSuchFileException , com.android.sched.util.file.NotFileOrDirectoryException , com.android.sched.util.file.WrongPermissionException { assert ( file ) != null ; if ( ! ( file.exists ( ) ) ) { throw new com.android.sched.util.file.NoSuchFileException ( ( ( com.android.sched.util.location.FileOrDirLocation ) ( location ) ) ) ; } if ( ! ( file.isFile ( ) ) ) { throw new com.android.sched.util.file.NotFileOrDirectoryException ( ( ( com.android.sched.util.location.FileOrDirLocation ) ( location ) ) ) ; } checkPermissions ( file , permissions ) ; }

Target:
private void processExisting ( int permissions ) throws com.android.sched.util.file.NoSuchFileException , com.android.sched.util.file.NotFileException , com.android.sched.util.file.WrongPermissionException { assert ( file ) != null ; if ( ! ( file.exists ( ) ) ) { throw new com.android.sched.util.file.NoSuchFileException ( ( ( com.android.sched.util.location.FileOrDirLocation ) ( location ) ) ) ; } if ( ! ( file.isFile ( ) ) ) { throw new com.android.sched.util.file.NotFileException ( ( ( com.android.sched.util.location.FileLocation ) ( location ) ) ) ; } checkPermissions ( file , permissions ) ; }
Source:
private void addWifiChangeHandler ( com.android.server.wifi.scanner.WifiScanningServiceImpl.ClientInfo ci , int handler ) { mActiveWifiChangeHandlers.add ( android.util.Pair.create ( ci , handler ) ) ; if ( ( mInternalClientInfo ) == null ) { mInternalClientInfo = new com.android.server.wifi.scanner.WifiScanningServiceImpl.InternalClientInfo ( ci.getUid ( ) , new android.os.Messenger ( this . getHandler ( ) ) ) ; mInternalClientInfo.register ( ) ; } }

Target:
private boolean addWifiChangeHandler ( com.android.server.wifi.scanner.WifiScanningServiceImpl.ClientInfo ci , int handler ) { if ( ci == null ) { android.util.Log.d ( com.android.server.wifi.scanner.WifiScanningServiceImpl.TAG , ( "Failing wifi change request ClientInfo not found " + handler ) ) ; return false ; } mActiveWifiChangeHandlers.add ( android.util.Pair.create ( ci , handler ) ) ; if ( ( mInternalClientInfo ) == null ) { mInternalClientInfo = new com.android.server.wifi.scanner.WifiScanningServiceImpl.InternalClientInfo ( ci.getUid ( ) , new android.os.Messenger ( this . getHandler ( ) ) ) ; mInternalClientInfo.register ( ) ; } return true ; }
Source:
public android.net.wifi.WifiConfiguration getSavedNetworkForScanDetailAndCache ( com.android.server.wifi.ScanDetail scanDetail ) { android.net.wifi.WifiConfiguration network = getSavedNetworkForScanDetail ( scanDetail ) ; if ( network == null ) { return null ; } saveToScanDetailCacheForNetwork ( network , scanDetail ) ; if ( ( ( scanDetail.getNetworkDetail ( ) ) != null ) && ( ( scanDetail.getNetworkDetail ( ) . getDtimInterval ( ) ) > 0 ) ) { network.dtimInterval = scanDetail.getNetworkDetail ( ) . getDtimInterval ( ) ; } return createExternalWifiConfiguration ( network , true ) ; }

Target:
public android.net.wifi.WifiConfiguration getConfiguredNetworkForScanDetailAndCache ( com.android.server.wifi.ScanDetail scanDetail ) { android.net.wifi.WifiConfiguration network = getConfiguredNetworkForScanDetail ( scanDetail ) ; if ( network == null ) { return null ; } saveToScanDetailCacheForNetwork ( network , scanDetail ) ; if ( ( ( scanDetail.getNetworkDetail ( ) ) != null ) && ( ( scanDetail.getNetworkDetail ( ) . getDtimInterval ( ) ) > 0 ) ) { network.dtimInterval = scanDetail.getNetworkDetail ( ) . getDtimInterval ( ) ; } return createExternalWifiConfiguration ( network , true ) ; }
Source:
protected void engineInit ( int opmode , java.security.Key key , java.security.AlgorithmParameters params , java.security.SecureRandom random ) throws java.security.InvalidAlgorithmParameterException , java.security.InvalidKeyException { if ( params != null ) { throw new java.security.InvalidAlgorithmParameterException ( ( "unknown param type: " + ( params.getClass ( ) . getName ( ) ) ) ) ; } engineInitInternal ( opmode , key ) ; }

Target:
protected void engineInit ( int opmode , java.security.Key key , java.security.spec.AlgorithmParameterSpec params , java.security.SecureRandom random ) throws java.security.InvalidAlgorithmParameterException , java.security.InvalidKeyException { if ( params != null ) { throw new java.security.InvalidAlgorithmParameterException ( ( "unknown param type: " + ( params.getClass ( ) . getName ( ) ) ) ) ; } engineInitInternal ( opmode , key , params ) ; }
Source:
public com.android.ims.internal.IImsServiceController getImsServiceControllerAndListen ( int slotId , @ android.telephony.TelephonyManager.Feature int feature , com.android.ims.internal.IImsServiceFeatureListener callback ) { try { com.android.internal.telephony.ITelephony telephony = getITelephony ( ) ; if ( telephony != null ) { return telephony.getImsServiceControllerAndListen ( slotId , feature , callback ) ; } } catch ( android.os.RemoteException e ) { android.telephony.Rlog.e ( android.telephony.TelephonyManager.TAG , ( "getImsServiceControllerAndListen, RemoteException: " + ( e.getMessage ( ) ) ) ) ; } return null ; }

Target:
public com.android.ims.internal.IImsServiceController getImsServiceControllerAndListen ( int slotIndex , @ android.telephony.TelephonyManager.Feature int feature , com.android.ims.internal.IImsServiceFeatureListener callback ) { try { com.android.internal.telephony.ITelephony telephony = getITelephony ( ) ; if ( telephony != null ) { return telephony.getImsServiceControllerAndListen ( slotIndex , feature , callback ) ; } } catch ( android.os.RemoteException e ) { android.telephony.Rlog.e ( android.telephony.TelephonyManager.TAG , ( "getImsServiceControllerAndListen, RemoteException: " + ( e.getMessage ( ) ) ) ) ; } return null ; }
Source:
boolean checkDisplayNameParams ( int field , int style , int minStyle , int maxStyle , java.util.Locale locale , int fieldMask ) { if ( ( ( ( field < 0 ) || ( field >= ( fields.length ) ) ) || ( style < minStyle ) ) || ( style > maxStyle ) ) { throw new java.lang.IllegalArgumentException ( ) ; } if ( locale == null ) { throw new java.lang.NullPointerException ( ) ; } return java.util.Calendar.isFieldSet ( fieldMask , field ) ; }

Target:
boolean checkDisplayNameParams ( int field , int style , int minStyle , int maxStyle , java.util.Locale locale , int fieldMask ) { int baseStyle = getBaseStyle ( style ) ; if ( ( ( ( field < 0 ) || ( field >= ( fields.length ) ) ) || ( baseStyle < minStyle ) ) || ( baseStyle > maxStyle ) ) { throw new java.lang.IllegalArgumentException ( ) ; } if ( locale == null ) { throw new java.lang.NullPointerException ( ) ; } return java.util.Calendar.isFieldSet ( fieldMask , field ) ; }
Source:
public java.util.Collection < com.android.build.FilterData > getFilters ( ) { com.google.common.collect.ImmutableList.Builder < com.android.build.FilterData > filters = com.google.common.collect.ImmutableList.builder ( ) ; if ( ( densityFilter ) != null ) { filters.add ( FilterData.Builder.build ( OutputFile.DENSITY , densityFilter ) ) ; } if ( ( abiFilter ) != null ) { filters.add ( FilterData.Builder.build ( OutputFile.ABI , abiFilter ) ) ; } return filters.build ( ) ; }

Target:
public java.util.Collection < com.android.build.FilterData > getFilters ( ) { com.google.common.collect.ImmutableList.Builder < com.android.build.FilterData > filters = com.google.common.collect.ImmutableList.builder ( ) ; if ( ( densityFilter ) != null ) { filters.add ( com.android.ide.common.build.SplitOutputMatcherTest.FakeFilterData.Builder.build ( OutputFile.DENSITY , densityFilter ) ) ; } if ( ( abiFilter ) != null ) { filters.add ( com.android.ide.common.build.SplitOutputMatcherTest.FakeFilterData.Builder.build ( OutputFile.ABI , abiFilter ) ) ; } return filters.build ( ) ; }
Source:
public void testMissingDataDirDistroVersionFile ( ) throws java.lang.Exception { createSystemTzDataFileOnHost ( com.android.cts.tzdata.TzDataCheckTest.VALID_RULES_VERSION ) ; com.android.cts.tzdata.TzDataCheckTest.PathPair dataCurrentDir = mDataDir.createSubPath ( com.android.cts.tzdata.TzDataCheckTest.CURRENT_DIR_NAME ) ; com.android.timezone.distro.TimeZoneDistro distroWithoutAVersionFile = com.android.cts.tzdata.TzDataCheckTest.createValidDistroBuilder ( ) . clearVersionForTests ( ) . buildUnvalidated ( ) ; com.android.cts.tzdata.TzDataCheckTest.unpackOnHost ( dataCurrentDir , distroWithoutAVersionFile ) ; pushHostTestDirToDevice ( ) ; assertEquals ( 3 , runTzDataCheckOnDevice ( ) ) ; assertDevicePathDoesNotExist ( dataCurrentDir ) ; }

Target:
public void testMissingDataDirDistroVersionFile ( ) throws java.lang.Exception { createSystemTzDataFileOnHost ( com.android.cts.tzdata.TzDataCheckTest.VALID_RULES_VERSION ) ; com.android.cts.tzdata.TzDataCheckTest.PathPair dataCurrentDir = mDataDir.createSubPath ( com.android.cts.tzdata.TzDataCheckTest.CURRENT_DIR_NAME ) ; byte [ ] distroWithoutAVersionFileBytes = com.android.cts.tzdata.TzDataCheckTest.createValidDistroBuilder ( ) . clearVersionForTests ( ) . buildUnvalidatedBytes ( ) ; com.android.cts.tzdata.TzDataCheckTest.unpackOnHost ( dataCurrentDir , distroWithoutAVersionFileBytes ) ; pushHostTestDirToDevice ( ) ; assertEquals ( 3 , runTzDataCheckOnDevice ( ) ) ; assertDevicePathDoesNotExist ( dataCurrentDir ) ; }
Source:
public com.android.dx.io.ClassData.Field [ ] allFields ( ) { com.android.dx.io.ClassData.Field [ ] result = new com.android.dx.io.ClassData.Field [ ( staticFields.length ) + ( instanceFields.length ) ] ; java.lang.System.arraycopy ( staticFields , 0 , result , 0 , staticFields.length ) ; java.lang.System.arraycopy ( instanceFields , 0 , result , staticFields.length , instanceFields.length ) ; return result ; }

Target:
public com.android.dex.ClassData.Field [ ] allFields ( ) { com.android.dex.ClassData.Field [ ] result = new com.android.dex.ClassData.Field [ ( staticFields.length ) + ( instanceFields.length ) ] ; java.lang.System.arraycopy ( staticFields , 0 , result , 0 , staticFields.length ) ; java.lang.System.arraycopy ( instanceFields , 0 , result , staticFields.length , instanceFields.length ) ; return result ; }
Source:
public static java.lang.String formatDateRange ( long startMs , long endMs , int flags , java.lang.String olsonId ) { if ( ( flags & ( libcore.icu.DateIntervalFormat.FORMAT_UTC ) ) != 0 ) { olsonId = "UTC" ; } java.util.TimeZone tz = ( olsonId != null ) ? java.util.TimeZone.getTimeZone ( olsonId ) : java.util.TimeZone.getDefault ( ) ; return libcore.icu.DateIntervalFormat.formatDateRange ( java.util.Locale.getDefault ( ) , tz , startMs , endMs , flags ) ; }

Target:
public static java.lang.String formatDateRange ( long startMs , long endMs , int flags , java.lang.String olsonId ) { if ( ( flags & ( libcore.icu.DateIntervalFormat.FORMAT_UTC ) ) != 0 ) { olsonId = "UTC" ; } java.util.TimeZone tz = ( olsonId != null ) ? java.util.TimeZone.getTimeZone ( olsonId ) : java.util.TimeZone.getDefault ( ) ; java.util.TimeZone icuTimeZone = libcore.icu.DateIntervalFormat.icuTimeZone ( tz ) ; com.ibm.icu.util.ULocale icuLocale = com.ibm.icu.util.ULocale.getDefault ( ) ; return libcore.icu.DateIntervalFormat.formatDateRange ( icuLocale , icuTimeZone , startMs , endMs , flags ) ; }
Source:
public void uint8 ( short v ) throws java.io.IOException { mBuffer [ 0 ] = ( ( byte ) ( v & 255 ) ) ; write ( 1 ) ; }

Target:
public void object ( @ org.jetbrains.annotations.Nullable com.android.tools.rpclib.binary.BinaryObject obj ) throws java.io.IOException { if ( obj == null ) { uint32 ( BinaryObject.NULL_ID ) ; return ; } if ( mEncodedMap.containsKey ( obj ) ) { int key = mEncodedMap.get ( obj ) ; uint16 ( key ) ; return ; } int key = ( mEncodedMap.size ( ) ) + 1 ; mEncodedMap.put ( obj , key ) ; uint32 ( key ) ; obj.type ( ) . encode ( this ) ; obj.encode ( this ) ; }
Source:
private static com.android.sdklib.util.Pair < com.android.ide.eclipse.adt.internal.resources.ResourceType , java.lang.String > parseResource ( java.lang.String url ) { if ( ! ( url.startsWith ( "@" ) ) ) { return null ; } int typeEnd = url.indexOf ( '/' , 1 ) ; if ( typeEnd == ( - 1 ) ) { return null ; } int nameBegin = typeEnd + 1 ; int typeBegin = ( url.startsWith ( "@+" ) ) ? 2 : 1 ; int colon = url.lastIndexOf ( ':' , typeEnd ) ; if ( colon != ( - 1 ) ) { typeBegin = colon + 1 ; } java.lang.String typeName = url.substring ( typeBegin , typeEnd ) ; com.android.ide.eclipse.adt.internal.resources.ResourceType type = com.android.ide.eclipse.adt.internal.resources.ResourceType.getEnum ( typeName ) ; if ( type == null ) { return null ; } java.lang.String name = url.substring ( nameBegin ) ; return com.android.sdklib.util.Pair.of ( type , name ) ; }

Target:
private static com.android.util.Pair < com.android.resources.ResourceType , java.lang.String > parseResource ( java.lang.String url ) { if ( ! ( url.startsWith ( "@" ) ) ) { return null ; } int typeEnd = url.indexOf ( '/' , 1 ) ; if ( typeEnd == ( - 1 ) ) { return null ; } int nameBegin = typeEnd + 1 ; int typeBegin = ( url.startsWith ( "@+" ) ) ? 2 : 1 ; int colon = url.lastIndexOf ( ':' , typeEnd ) ; if ( colon != ( - 1 ) ) { typeBegin = colon + 1 ; } java.lang.String typeName = url.substring ( typeBegin , typeEnd ) ; com.android.resources.ResourceType type = com.android.resources.ResourceType.getEnum ( typeName ) ; if ( type == null ) { return null ; } java.lang.String name = url.substring ( nameBegin ) ; return com.android.util.Pair.of ( type , name ) ; }
Source:
public void afterCheckFile ( @ com.android.annotations.NonNull com.android.tools.lint.detector.api.Context context ) { com.android.tools.lint.detector.api.XmlContext xmlContext = ( ( com.android.tools.lint.detector.api.XmlContext ) ( context ) ) ; org.w3c.dom.Element element = xmlContext.document.getDocumentElement ( ) ; if ( element != null ) { checkDocumentElement ( xmlContext , element ) ; } if ( ( ( mSeenUsesSdk ) == 0 ) && ( context.isEnabled ( com.android.tools.lint.checks.ManifestDetector.USES_SDK ) ) ) { context.report ( com.android.tools.lint.checks.ManifestDetector.USES_SDK , com.android.tools.lint.detector.api.Location.create ( context.file ) , ( "Manifest should specify a minimum API level with " + ( "<uses-sdk android:minSdkVersion=\"?\" />; if it really supports " + "all versions of Android set it to 1." ) ) , null ) ; } }

Target:
public void afterCheckFile ( @ com.android.annotations.NonNull com.android.tools.lint.detector.api.Context context ) { com.android.tools.lint.detector.api.XmlContext xmlContext = ( ( com.android.tools.lint.detector.api.XmlContext ) ( context ) ) ; org.w3c.dom.Element element = xmlContext.document.getDocumentElement ( ) ; if ( element != null ) { com.android.tools.lint.checks.ManifestDetector.checkDocumentElement ( xmlContext , element ) ; } if ( ( ( mSeenUsesSdk ) == 0 ) && ( context.isEnabled ( com.android.tools.lint.checks.ManifestDetector.USES_SDK ) ) ) { context.report ( com.android.tools.lint.checks.ManifestDetector.USES_SDK , com.android.tools.lint.detector.api.Location.create ( context.file ) , ( "Manifest should specify a minimum API level with " + ( "<uses-sdk android:minSdkVersion=\"?\" />; if it really supports " + "all versions of Android set it to 1." ) ) , null ) ; } }
Source:
public void removeJavascriptInterface ( final java.lang.String interfaceName ) { if ( checkNeedsPost ( ) ) { mRunQueue.addTask ( new java.lang.Runnable ( ) { @ java.lang.Override public void run ( ) { removeJavascriptInterface ( interfaceName ) ; } } ) ; return ; } mAwContents.removeJavascriptInterface ( interfaceName ) ; }

Target:
public void flingScroll ( final int vx , final int vy ) { if ( checkNeedsPost ( ) ) { mRunQueue.addTask ( new java.lang.Runnable ( ) { @ java.lang.Override public void run ( ) { flingScroll ( vx , vy ) ; } } ) ; return ; } mAwContents.flingScroll ( vx , vy ) ; }
Source:
public void testProvidedModuleDependency ( ) throws java.io.IOException { com.intellij.openapi.module.Module moduleA = createModule ( "a.iml" , StdModuleTypes.JAVA ) ; addDependentModule ( moduleA , DependencyScope.PROVIDED ) ; com.intellij.openapi.vfs.VirtualFile [ ] runtimeClasspath = com.intellij.roots.ModuleScopesTest.getRuntimeClasspath ( moduleA ) ; assertEmpty ( runtimeClasspath ) ; final com.intellij.openapi.vfs.VirtualFile [ ] compilationClasspath = com.intellij.roots.ModuleScopesTest.getCompilationClasspath ( moduleA ) ; assertEquals ( 1 , compilationClasspath.length ) ; }

Target:
public void testRuntimeModuleDependency ( ) throws java.io.IOException { com.intellij.openapi.module.Module moduleA = createModule ( "a.iml" , StdModuleTypes.JAVA ) ; addDependentModule ( moduleA , DependencyScope.RUNTIME ) ; final com.intellij.openapi.vfs.VirtualFile [ ] runtimeClasspath = com.intellij.roots.ModuleScopesTest.getRuntimeClasspath ( moduleA ) ; assertEquals ( 1 , runtimeClasspath.length ) ; final com.intellij.openapi.vfs.VirtualFile [ ] compilationClasspath = com.intellij.roots.ModuleScopesTest.getCompilationClasspath ( moduleA ) ; assertEquals ( 1 , compilationClasspath.length ) ; com.intellij.openapi.vfs.VirtualFile [ ] production = com.intellij.roots.ModuleScopesTest.getProductionCompileClasspath ( moduleA ) ; assertEmpty ( production ) ; }
Source:
public static void computeClamp ( android.renderscript.cts.TestClamp.ArgumentsUshortUshortUshortUshort args ) { args.ulf = 0 ; args.ulfRelaxed = 0 ; args.out = ( ( short ) ( java.lang.StrictMath.min ( ( ( args.inMaxValue ) & 65535 ) , java.lang.StrictMath.max ( ( ( args.inValue ) & 65535 ) , ( ( args.inMinValue ) & 65535 ) ) ) ) ) ; }

Target:
public static void computeClamp ( android.renderscript.cts.TestClamp.ArgumentsUintUintUintUint args ) { args.out = android.renderscript.cts.CoreMathVerifier.minU32 ( args.inMaxValue , android.renderscript.cts.CoreMathVerifier.maxU32 ( args.inValue , args.inMinValue ) ) ; }
Source:
public static int $opt$noinline$foo ( Main o ) { if ( Main.doThrow ) { throw new java.lang.Error ( ) ; } if ( ( ( o.getClass ( ) ) == ( Main.class ) ) || ( ( o.getClass ( ) ) != ( SubMain.class ) ) ) { return o.foo ( ) ; } else { return o.bar ( ) ; } }

Target:
public static int $noinline$runSmaliTest ( java.lang.String name , Main input ) { try { java.lang.Class < ? > c = java.lang.Class.forName ( "SmaliTests" ) ; java.lang.reflect.Method m = c.getMethod ( name , Main.class ) ; return ( ( java.lang.Integer ) ( m.invoke ( null , input ) ) ) ; } catch ( java.lang.Exception ex ) { throw new java.lang.Error ( ex ) ; } }
Source:
private void checkInOptionBase ( javax.lang.model.element.VariableElement optionField ) throws com.google.devtools.common.options.processor.OptionProcessor.OptionProcessorException { if ( ( optionField.getEnclosingElement ( ) . getKind ( ) ) != ( javax.lang.model.element.ElementKind.CLASS ) ) { throw new com.google.devtools.common.options.processor.OptionProcessor.OptionProcessorException ( optionField , "The field should belong to a class." ) ; } javax.lang.model.type.TypeMirror thisOptionClass = optionField.getEnclosingElement ( ) . asType ( ) ; javax.lang.model.type.TypeMirror optionsBase = elementUtils.getTypeElement ( "com.google.devtools.common.options.OptionsBase" ) . asType ( ) ; if ( ! ( typeUtils.isAssignable ( thisOptionClass , optionsBase ) ) ) { throw new com.google.devtools.common.options.processor.OptionProcessor.OptionProcessorException ( optionField , "@Option annotated fields can only be in classes that inherit from OptionsBase." ) ; } }

Target:
private void checkInOptionBase ( javax.lang.model.element.VariableElement optionField ) throws com.google.devtools.common.options.processor.OptionProcessorException { if ( ( optionField.getEnclosingElement ( ) . getKind ( ) ) != ( javax.lang.model.element.ElementKind.CLASS ) ) { throw new com.google.devtools.common.options.processor.OptionProcessorException ( optionField , "The field should belong to a class." ) ; } javax.lang.model.type.TypeMirror thisOptionClass = optionField.getEnclosingElement ( ) . asType ( ) ; javax.lang.model.type.TypeMirror optionsBase = elementUtils.getTypeElement ( "com.google.devtools.common.options.OptionsBase" ) . asType ( ) ; if ( ! ( typeUtils.isAssignable ( thisOptionClass , optionsBase ) ) ) { throw new com.google.devtools.common.options.processor.OptionProcessorException ( optionField , "@Option annotated fields can only be in classes that inherit from OptionsBase." ) ; } }
Source:
public void testGetExampleShortNumber ( ) { assertEquals ( "8711" , shortInfo.getExampleShortNumber ( RegionCode.AM ) ) ; assertEquals ( "1010" , shortInfo.getExampleShortNumber ( RegionCode.FR ) ) ; assertEquals ( "" , shortInfo.getExampleShortNumber ( RegionCode.UN001 ) ) ; assertEquals ( "" , shortInfo.getExampleShortNumber ( null ) ) ; }

Target:
public void testGetExampleShortNumber ( ) { assertEquals ( "8711" , com.android.i18n.phonenumbers.ShortNumberInfoTest.shortInfo.getExampleShortNumber ( RegionCode.AM ) ) ; assertEquals ( "1010" , com.android.i18n.phonenumbers.ShortNumberInfoTest.shortInfo.getExampleShortNumber ( RegionCode.FR ) ) ; assertEquals ( "" , com.android.i18n.phonenumbers.ShortNumberInfoTest.shortInfo.getExampleShortNumber ( RegionCode.UN001 ) ) ; assertEquals ( "" , com.android.i18n.phonenumbers.ShortNumberInfoTest.shortInfo.getExampleShortNumber ( null ) ) ; }
Source:
public void setUp ( ) throws java.lang.Exception { mMockDevice = org.easymock.EasyMock.createNiceMock ( com.android.tradefed.device.ITestDevice.class ) ; mMockBuildInfo = org.easymock.EasyMock.createNiceMock ( com.android.tradefed.build.IBuildInfo.class ) ; mMockHelper = new com.android.compatibility.common.tradefed.build.VtsCompatibilityInvocationHelper ( ) ; mPreparer = new com.android.tradefed.targetprep.VtsTraceCollectPreparer ( ) { @ java.lang.Override com.android.compatibility.common.tradefed.build.VtsCompatibilityInvocationHelper createVtsHelper ( ) { return mMockHelper ; } } ; com.android.tradefed.config.OptionSetter setter = new com.android.tradefed.config.OptionSetter ( mPreparer ) ; setter.setOptionValue ( "local-trace-dir" , com.android.tradefed.targetprep.VtsTraceCollectPreparerTest.TEST_TRACE_DIR ) ; }

Target:
public void setUp ( ) throws java.lang.Exception { mMockDevice = org.easymock.EasyMock.createNiceMock ( com.android.tradefed.device.ITestDevice.class ) ; mMockBuildInfo = org.easymock.EasyMock.createNiceMock ( com.android.tradefed.build.IBuildInfo.class ) ; mTestDir = com.android.tradefed.util.FileUtil.createTempDir ( "vts-trace-collect-unit-tests" ) ; mMockHelper = new com.android.compatibility.common.tradefed.build.CompatibilityBuildHelper ( mMockBuildInfo ) { @ java.lang.Override public java.io.File getTestsDir ( ) throws java.io.FileNotFoundException { return mTestDir ; } public java.io.File getResultDir ( ) throws java.io.FileNotFoundException { return mTestDir ; } } ; mPreparer = new com.android.tradefed.targetprep.VtsTraceCollectPreparer ( ) { @ java.lang.Override com.android.compatibility.common.tradefed.build.CompatibilityBuildHelper createBuildHelper ( com.android.tradefed.build.IBuildInfo buildInfo ) { return mMockHelper ; } } ; }
Source:
private void startForegroundCompat ( android.app.Notification notification ) { if ( ( mStartForeground ) != null ) { mStartForegroundArgs [ 0 ] = java.lang.Integer.valueOf ( mNotificationId ) ; mStartForegroundArgs [ 1 ] = notification ; try { mStartForeground.invoke ( this , mStartForegroundArgs ) ; } catch ( java.lang.Exception e ) { com.googlecode.android_scripting.Log.e ( e ) ; } return ; } setForeground ( true ) ; if ( notification != null ) { mNotificationManager.notify ( mNotificationId , notification ) ; } }

Target:
protected android.app.NotificationManager getNotificationManager ( ) { if ( ( mNotificationManager ) == null ) { mNotificationManager = ( ( android.app.NotificationManager ) ( getSystemService ( com.googlecode.android_scripting.NOTIFICATION_SERVICE ) ) ) ; } return mNotificationManager ; }
Source:
public void close ( ) throws com.android.jack.library.LibraryIOException { try { com.android.sched.vfs.OutputVFile libraryPropertiesOut = vfs.getRootDir ( ) . createOutputVFile ( com.android.jack.library.v0000.LIBRARY_PROPERTIES_VPATH ) ; libraryProperties.store ( libraryPropertiesOut.openWrite ( ) , "Library properties" ) ; } catch ( com.android.sched.util.file.CannotCreateFileException e ) { throw new com.android.jack.library.LibraryIOException ( getLocation ( ) , e ) ; } catch ( java.io.IOException e ) { throw new com.android.jack.library.LibraryIOException ( getLocation ( ) , e ) ; } }

Target:
public void close ( ) throws com.android.jack.library.LibraryIOException { try { com.android.sched.vfs.OutputVFile libraryPropertiesOut = vfs.getRootInputOutputVDir ( ) . createOutputVFile ( com.android.jack.library.v0000.LIBRARY_PROPERTIES_VPATH ) ; libraryProperties.store ( libraryPropertiesOut.openWrite ( ) , "Library properties" ) ; } catch ( com.android.sched.util.file.CannotCreateFileException e ) { throw new com.android.jack.library.LibraryIOException ( getLocation ( ) , e ) ; } catch ( java.io.IOException e ) { throw new com.android.jack.library.LibraryIOException ( getLocation ( ) , e ) ; } }
Source:
protected byte [ ] getIllegalByteArray ( ) { return new byte [ ] { 0 } ; }

Target:
protected byte [ ] getIllegalByteArray ( ) { return new byte [ ] { ( ( byte ) ( 216 ) ) , ( ( byte ) ( 0 ) ) , ( ( byte ) ( 219 ) ) , ( ( byte ) ( 0 ) ) } ; }
Source:
com.android.jack.ir.InternalCompilerException translateException ( org.eclipse.jdt.internal.compiler.ast.TypeDeclaration typeDeclaration , java.lang.Throwable e , com.android.jack.ir.sourceinfo.SourceInfo info ) { com.android.jack.ir.InternalCompilerException ice = translateException ( e ) ; if ( typeDeclaration != null ) { java.lang.StringBuffer sb = new java.lang.StringBuffer ( ) ; typeDeclaration.printHeader ( 0 , sb ) ; ice.addNode ( typeDeclaration.getClass ( ) . getName ( ) , sb.toString ( ) , info ) ; } return ice ; }

Target:
com.android.jack.ir.JNodeInternalError translateException ( org.eclipse.jdt.internal.compiler.ast.TypeDeclaration typeDeclaration , java.lang.Throwable e , com.android.jack.ir.sourceinfo.SourceInfo info ) { com.android.jack.ir.JNodeInternalError ice = translateException ( e ) ; if ( typeDeclaration != null ) { java.lang.StringBuffer sb = new java.lang.StringBuffer ( ) ; typeDeclaration.printHeader ( 0 , sb ) ; ice.addNode ( typeDeclaration.getClass ( ) . getName ( ) , sb.toString ( ) , info ) ; } return ice ; }
Source:
public void onServiceDisconnected ( android.content.ComponentName name ) { mService.set ( null ) ; }

Target:
public void dispose ( ) { try { android.telephony.mbms.vendor.IMbmsStreamingService streamingService = mService.get ( ) ; if ( streamingService == null ) { return ; } streamingService.dispose ( mSubscriptionId ) ; } catch ( android.os.RemoteException e ) { } finally { mService.set ( null ) ; android.telephony.MbmsStreamingManager.sIsInitialized.set ( false ) ; } }
Source:
public void handle ( @ javax.annotation.Nonnull org.simpleframework.http.Request request , @ javax.annotation.Nonnull org.simpleframework.http.Response response ) { com.android.jack.server.JackSimpleServer.logger.log ( java.util.logging.Level.WARNING , "Jack version not available, try to shutdown server (jack-admin stop-server)" ) ; super . handle ( request , response ) ; }

Target:
public void handle ( @ javax.annotation.Nonnull org.simpleframework.http.Request request , @ javax.annotation.Nonnull org.simpleframework.http.Response response ) { java.lang.String normalizedPath = request.getPath ( ) . getPath ( ) ; com.android.jack.server.JackSimpleServer.logger.log ( java.util.logging.Level.INFO , ( ( "Route request from '" + normalizedPath ) + "'" ) ) ; org.simpleframework.http.core.Container container = registry.get ( normalizedPath ) ; if ( container != null ) { container.handle ( request , response ) ; } else { primary.handle ( request , response ) ; } }
Source:
public int computeVerticalScrollRange ( ) { mFactory.startYourEngines ( false ) ; if ( checkNeedsPost ( ) ) { int ret = runOnUiThreadBlocking ( new java.util.concurrent.Callable < java.lang.Integer > ( ) { @ java.lang.Override public java.lang.Integer call ( ) { return computeVerticalScrollRange ( ) ; } } ) ; return ret ; } return mAwContents.computeVerticalScrollRange ( ) ; }

Target:
public int computeVerticalScrollOffset ( ) { mFactory.startYourEngines ( false ) ; if ( checkNeedsPost ( ) ) { int ret = runOnUiThreadBlocking ( new java.util.concurrent.Callable < java.lang.Integer > ( ) { @ java.lang.Override public java.lang.Integer call ( ) { return computeVerticalScrollOffset ( ) ; } } ) ; return ret ; } return mAwContents.computeVerticalScrollOffset ( ) ; }
Source:
public com.android.ims.internal.IImsRcsFeature getRcsFeature ( int slotId ) { synchronized ( mLock ) { com.android.internal.telephony.ims.ImsServiceController.ImsFeatureContainer f = getImsFeatureContainer ( slotId , ImsFeature.RCS ) ; if ( f == null ) { android.util.Log.w ( com.android.internal.telephony.ims.ImsServiceController.LOG_TAG , ( "Requested null RcsFeature on slot " + slotId ) ) ; return null ; } return f.resolve ( com.android.ims.internal.IImsRcsFeature.class ) ; } }

Target:
public android.telephony.ims.aidl.IImsRcsFeature getRcsFeature ( int slotId ) { synchronized ( mLock ) { com.android.internal.telephony.ims.ImsServiceController.ImsFeatureContainer f = getImsFeatureContainer ( slotId , ImsFeature.FEATURE_RCS ) ; if ( f == null ) { android.util.Log.w ( com.android.internal.telephony.ims.ImsServiceController.LOG_TAG , ( "Requested null RcsFeature on slot " + slotId ) ) ; return null ; } return f.resolve ( android.telephony.ims.aidl.IImsRcsFeature.class ) ; } }
Source:
protected void doBuildPatchFile ( java.io.File olderFile , java.io.File newerFile , java.util.zip.ZipOutputStream patchOutput ) throws java.io.IOException { patchOutput.putNextEntry ( new java.util.zip.ZipEntry ( myPath ) ) ; writeExecutableFlag ( patchOutput , newerFile ) ; writeDiff ( olderFile , newerFile , patchOutput ) ; patchOutput.closeEntry ( ) ; }

Target:
protected void doBuildPatchFile ( java.io.File toFile , com.intellij.updater.MultiZipFile.OutputStream patchOutput ) throws java.io.IOException { if ( ! ( myIsMove ) ) { java.io.File source = getSource ( myOlderDir ) ; patchOutput.putNextEntry ( myPath ) ; writeExecutableFlag ( patchOutput , toFile ) ; writeDiff ( source , toFile , patchOutput ) ; patchOutput.closeEntry ( ) ; } }
Source:
public void addI32 ( android.support.v8.renderscript.Int2 v ) { if ( android.support.v8.renderscript.RenderScript.shouldThunk ( ) ) { mN.addI32 ( new android.support.v8.renderscript.Int2 ( v.x , v.y ) ) ; return ; } addI32 ( v.x ) ; addI32 ( v.y ) ; }

Target:
public void addU16 ( android.support.v8.renderscript.Int2 v ) { if ( android.support.v8.renderscript.RenderScript.shouldThunk ( ) ) { mN.addU16 ( v ) ; return ; } addU16 ( v.x ) ; addU16 ( v.y ) ; }
Source:
private void reportConnectionAttemptStart ( android.net.wifi.WifiConfiguration config , java.lang.String targetBSSID , int roamType ) { mWifiMetrics.startConnectionEvent ( config , targetBSSID , roamType ) ; mWifiDiagnostics.reportConnectionEvent ( ( - 1 ) , WifiDiagnostics.CONNECTION_EVENT_STARTED ) ; }

Target:
private void reportConnectionAttemptStart ( android.net.wifi.WifiConfiguration config , java.lang.String targetBSSID , int roamType ) { mWifiMetrics.startConnectionEvent ( config , targetBSSID , roamType ) ; mDiagsConnectionStartMillis = mClock.getElapsedSinceBootMillis ( ) ; mWifiDiagnostics.reportConnectionEvent ( mDiagsConnectionStartMillis , WifiDiagnostics.CONNECTION_EVENT_STARTED ) ; sendMessageDelayed ( com.android.server.wifi.WifiStateMachine.CMD_DIAGS_CONNECT_TIMEOUT , mDiagsConnectionStartMillis , com.android.server.wifi.WifiStateMachine.DIAGS_CONNECT_TIMEOUT_MILLIS ) ; }
Source:
public boolean matches ( java.lang.Object o ) { for ( org.hamcrest.Matcher < ? extends T > matcher : matchers ) { if ( ! ( matcher.matches ( o ) ) ) { return false ; } } return true ; }

Target:
public boolean matches ( java.lang.Object o , org.hamcrest.Description mismatch ) { for ( org.hamcrest.Matcher < ? super T > matcher : matchers ) { if ( ! ( matcher.matches ( o ) ) ) { mismatch.appendDescriptionOf ( matcher ) . appendText ( " " ) ; matcher.describeMismatch ( o , mismatch ) ; return false ; } } return true ; }
Source:
public org.eclipse.core.runtime.jobs.Job delegateRunLint ( ) { org.eclipse.core.runtime.jobs.Job job = super . delegateRunLint ( ) ; if ( job != null ) { job.addJobChangeListener ( new org.eclipse.core.runtime.jobs.JobChangeAdapter ( ) { @ java.lang.Override public void done ( org.eclipse.core.runtime.jobs.IJobChangeEvent event ) { com.android.ide.eclipse.adt.internal.editors.layout.gle2.GraphicalEditorPart graphicalEditor = getGraphicalEditor ( ) ; if ( graphicalEditor != null ) { com.android.ide.eclipse.adt.internal.editors.layout.gle2.LayoutActionBar bar = graphicalEditor.getLayoutActionBar ( ) ; if ( ! ( bar.isDisposed ( ) ) ) { bar.updateErrorIndicator ( ) ; } } } } ) ; } return job ; }

Target:
public org.eclipse.core.resources.IMarker getIssueForNode ( @ com.android.annotations.Nullable com.android.ide.eclipse.adt.internal.editors.layout.uimodel.UiViewElementNode node ) { if ( node == null ) { return null ; } if ( ( mClient ) != null ) { return mClient.getIssueForNode ( node ) ; } return null ; }
Source:
private void newDefaultNetwork ( long timeMs , com.android.server.connectivity.NetworkAgentInfo newNai ) { android.net.metrics.DefaultNetworkEvent ev = new android.net.metrics.DefaultNetworkEvent ( timeMs ) ; ev.durationMs = timeMs ; if ( newNai != null ) { com.android.server.connectivity.DefaultNetworkMetrics.fillLinkInfo ( ev , newNai ) ; ev.initialScore = newNai.getCurrentScore ( ) ; if ( newNai.lastValidated ) { mIsCurrentlyValid = true ; mLastValidationTimeMs = timeMs ; } } mCurrentDefaultNetwork = ev ; }

Target:
private void newDefaultNetwork ( long timeMs , com.android.server.connectivity.NetworkAgentInfo newNai ) { android.net.metrics.DefaultNetworkEvent ev = new android.net.metrics.DefaultNetworkEvent ( timeMs ) ; ev.durationMs = timeMs ; if ( newNai != null ) { com.android.server.connectivity.DefaultNetworkMetrics.fillLinkInfo ( ev , newNai ) ; ev.initialScore = newNai.getCurrentScore ( ) ; if ( newNai.lastValidated ) { logDefaultNetworkValidity ( timeMs , true ) ; } } else { mIsCurrentlyValid = false ; } mCurrentDefaultNetwork = ev ; }
Source:
public com.android.timezone.distro.TimeZoneDistro build ( ) throws com.android.timezone.distro.DistroException { if ( ( distroVersion ) == null ) { throw new java.lang.IllegalStateException ( "Missing distroVersion" ) ; } if ( ( icuData ) == null ) { throw new java.lang.IllegalStateException ( "Missing icuData" ) ; } if ( ( tzData ) == null ) { throw new java.lang.IllegalStateException ( "Missing tzData" ) ; } return buildUnvalidated ( ) ; }

Target:
public byte [ ] buildBytes ( ) throws com.android.timezone.distro.DistroException { if ( ( distroVersion ) == null ) { throw new java.lang.IllegalStateException ( "Missing distroVersion" ) ; } if ( ( icuData ) == null ) { throw new java.lang.IllegalStateException ( "Missing icuData" ) ; } if ( ( tzData ) == null ) { throw new java.lang.IllegalStateException ( "Missing tzData" ) ; } return buildUnvalidatedBytes ( ) ; }
Source:
private static void print ( @ javax.annotation.Nonnull java.lang.StringBuilder sb , @ javax.annotation.Nonnull java.lang.String header , @ javax.annotation.Nonnull java.util.List < java.lang.String > items ) { if ( ( items.size ( ) ) > 0 ) { sb.append ( " - " ) . append ( header ) . append ( ":\n" ) ; java.util.Collections.sort ( items ) ; for ( java.lang.String item : items ) { sb.append ( " " ) . append ( item ) . append ( '\n' ) ; } } }

Target:
private static void print ( @ javax.annotation.Nonnull java.lang.StringBuilder sb , @ javax.annotation.Nonnull java.lang.String header , @ javax.annotation.Nonnull java.util.List < java.lang.String > items , boolean ordered ) { if ( ( items.size ( ) ) > 0 ) { sb.append ( " - " ) . append ( header ) . append ( ":\n" ) ; if ( ordered ) { java.util.Collections.sort ( items ) ; } for ( java.lang.String item : items ) { sb.append ( " " ) . append ( item ) . append ( '\n' ) ; } } }
Source:
public java.io.File getOutput ( ) { assert ( output ) != null ; return output ; }

Target:
public java.io.File getOutput ( ) { assert ( output ) != null ; if ( ( ( workingDir ) != null ) && ( ! ( output.isAbsolute ( ) ) ) ) { return new java.io.File ( workingDir , output.getPath ( ) ) ; } else { return output ; } }
Source:
public static com.android.dialer.searchfragment.nearbyplaces.NearbyPlacesCursor newInstnace ( android.content.Context context , android.database.Cursor nearbyPlacesCursor ) { android.database.MatrixCursor headerCursor = new android.database.MatrixCursor ( HEADER_PROJECTION ) ; headerCursor.addRow ( new java.lang.String [ ] { context.getString ( R.string.nearby_places ) } ) ; return new com.android.dialer.searchfragment.nearbyplaces.NearbyPlacesCursor ( new android.database.Cursor [ ] { headerCursor , nearbyPlacesCursor } ) ; }

Target:
static com.android.dialer.searchfragment.nearbyplaces.NearbyPlacesCursor newInstance ( android.content.Context context , android.database.Cursor nearbyPlacesCursor , long directoryId ) { android.database.MatrixCursor headerCursor = new android.database.MatrixCursor ( HEADER_PROJECTION ) ; headerCursor.addRow ( new java.lang.String [ ] { context.getString ( R.string.nearby_places ) } ) ; return new com.android.dialer.searchfragment.nearbyplaces.NearbyPlacesCursor ( new android.database.Cursor [ ] { headerCursor , nearbyPlacesCursor } , directoryId ) ; }
Source:
public static void setUp ( ) throws java.lang.Exception { com.android.jack.Options options = new com.android.jack.Options ( ) ; com.android.jack.optimizations.ExpressionSimplifierTest.hooks = new com.android.sched.util.RunnableHooks ( ) ; options.checkValidity ( com.android.jack.optimizations.ExpressionSimplifierTest.hooks ) ; com.android.sched.util.config.GatherConfigBuilder configBuilder = options.getConfigBuilder ( com.android.jack.optimizations.ExpressionSimplifierTest.hooks ) ; configBuilder.setDebug ( ) ; configBuilder.set ( Optimizations.ENABLE_NULL_INSTANCEOF.getName ( ) , java.lang.Boolean.TRUE ) ; com.android.sched.util.config.ThreadConfig.setConfig ( configBuilder.build ( ) ) ; }

Target:
public static void setUp ( ) throws java.lang.Exception { com.android.jack.Options options = new com.android.jack.Options ( ) ; com.android.jack.optimizations.ExpressionSimplifierTest.hooks = new com.android.sched.util.RunnableHooks ( ) ; options.checkValidity ( com.android.jack.optimizations.ExpressionSimplifierTest.hooks ) ; com.android.sched.util.config.GatherConfigBuilder configBuilder = options.getConfigBuilder ( com.android.jack.optimizations.ExpressionSimplifierTest.hooks ) ; configBuilder.getCodecContext ( ) . setDebug ( ) ; configBuilder.set ( Optimizations.ENABLE_NULL_INSTANCEOF.getName ( ) , java.lang.Boolean.TRUE ) ; com.android.sched.util.config.ThreadConfig.setConfig ( configBuilder.build ( ) ) ; }
Source:
public com.android.server.net.NetworkStatsService.NetworkStatsSettings.Config getDevConfig ( ) { return new com.android.server.net.NetworkStatsService.NetworkStatsSettings.Config ( getSecureLong ( android.provider.Settings.Secure.NETSTATS_DEV_BUCKET_DURATION , android.text.format.DateUtils.HOUR_IN_MILLIS ) , getSecureLong ( android.provider.Settings.Secure.NETSTATS_DEV_ROTATE_AGE , ( 15 * ( android.text.format.DateUtils.DAY_IN_MILLIS ) ) ) , getSecureLong ( android.provider.Settings.Secure.NETSTATS_DEV_DELETE_AGE , ( 90 * ( android.text.format.DateUtils.DAY_IN_MILLIS ) ) ) ) ; }

Target:
public com.android.server.net.NetworkStatsService.NetworkStatsSettings.Config getUidTagConfig ( ) { return new com.android.server.net.NetworkStatsService.NetworkStatsSettings.Config ( getGlobalLong ( android.provider.Settings.Global.NETSTATS_UID_TAG_BUCKET_DURATION , ( 2 * ( android.text.format.DateUtils.HOUR_IN_MILLIS ) ) ) , getGlobalLong ( android.provider.Settings.Global.NETSTATS_UID_TAG_ROTATE_AGE , ( 5 * ( android.text.format.DateUtils.DAY_IN_MILLIS ) ) ) , getGlobalLong ( android.provider.Settings.Global.NETSTATS_UID_TAG_DELETE_AGE , ( 15 * ( android.text.format.DateUtils.DAY_IN_MILLIS ) ) ) ) ; }
Source:
public void canRemoveNetworkConfigWhenWifiDisabed ( ) { boolean result ; when ( mWifiConfigManager.removeNetwork ( eq ( 0 ) , anyInt ( ) ) ) . thenReturn ( true ) ; mLooper.startAutoDispatch ( ) ; result = mWsm.syncRemoveNetwork ( mWsmAsyncChannel , 0 ) ; mLooper.stopAutoDispatch ( ) ; org.junit.Assert.assertTrue ( result ) ; verify ( mWifiConfigManager ) . removeNetwork ( anyInt ( ) , anyInt ( ) ) ; }

Target:
public void canRemoveNetworkConfigWhenWifiDisabled ( ) { boolean result ; when ( mWifiConfigManager.removeNetwork ( eq ( 0 ) , anyInt ( ) ) ) . thenReturn ( true ) ; mLooper.startAutoDispatch ( ) ; result = mWsm.syncRemoveNetwork ( mWsmAsyncChannel , 0 ) ; mLooper.stopAutoDispatch ( ) ; org.junit.Assert.assertTrue ( result ) ; verify ( mWifiConfigManager ) . removeNetwork ( anyInt ( ) , anyInt ( ) ) ; }
Source:
public static java.lang.String calledPartyBCDFragmentToString ( byte [ ] bytes , int offset , int length ) { java.lang.StringBuilder ret = new java.lang.StringBuilder ( ( length * 2 ) ) ; android.telephony.PhoneNumberUtils.internalCalledPartyBCDFragmentToString ( ret , bytes , offset , length ) ; return ret.toString ( ) ; }

Target:
public static java.lang.String calledPartyBCDFragmentToString ( byte [ ] bytes , int offset , int length , int bcdExtType ) { java.lang.StringBuilder ret = new java.lang.StringBuilder ( ( length * 2 ) ) ; android.telephony.PhoneNumberUtils.internalCalledPartyBCDFragmentToString ( ret , bytes , offset , length , bcdExtType ) ; return ret.toString ( ) ; }
Source:
protected void onDraw ( android.graphics.Canvas canvas ) { super . onDraw ( canvas ) ; android.graphics.Rect r = canvas.getClipBounds ( ) ; mRect.set ( r ) ; mRect.top += mBorder ; mRect.bottom -= mBorder ; mRect.left += mBorder ; mRect.right -= mBorder ; canvas.drawBitmap ( mBitmap , null , mRect , mPaint1 ) ; if ( ( mDotX ) != ( java.lang.Float.NaN ) ) { canvas.drawCircle ( mDotX , mDotY , mDotRadus , mDotPaint ) ; } }

Target:
protected void onDraw ( android.graphics.Canvas canvas ) { super . onDraw ( canvas ) ; android.graphics.Rect r = canvas.getClipBounds ( ) ; mRect.set ( r ) ; mRect.top += mBorder ; mRect.bottom -= mBorder ; mRect.left += mBorder ; mRect.right -= mBorder ; canvas.drawBitmap ( mBitmap , null , mRect , mPaint1 ) ; if ( ! ( java.lang.Float.isNaN ( mDotX ) ) ) { canvas.drawCircle ( mDotX , mDotY , mDotRadus , mDotPaint ) ; } }
Source:
public void test_JarFile_Modified_SF_EntryAttributes ( ) throws java.io.IOException { java.lang.String modifiedJarName = "Modified_SF_EntryAttributes.jar" ; tests.support.resource.Support_Resources.copyFile ( resources , null , modifiedJarName ) ; java.util.jar.JarFile jarFile = new java.util.jar.JarFile ( new java.io.File ( resources , modifiedJarName ) , true ) ; java.util.Enumeration < java.util.jar.JarEntry > entries = jarFile.entries ( ) ; while ( entries.hasMoreElements ( ) ) { java.util.zip.ZipEntry zipEntry = entries.nextElement ( ) ; try { jarFile.getInputStream ( zipEntry ) ; fail ( "should throw Security Exception" ) ; } catch ( java.lang.SecurityException e ) { } } }

Target:
public void test_close ( ) throws java.io.IOException { java.lang.String modifiedJarName = "Modified_SF_EntryAttributes.jar" ; java.io.File file = tests.support.resource.Support_Resources.copyFile ( resources , null , modifiedJarName ) ; java.util.jar.JarFile jarFile = new java.util.jar.JarFile ( file , true ) ; java.util.Enumeration < java.util.jar.JarEntry > entries = jarFile.entries ( ) ; jarFile.close ( ) ; jarFile.close ( ) ; }
Source:
protected void onEnabled ( int track , long positionUs , boolean joining ) { com.google.android.exoplayer.util.Assertions.checkArgument ( ( ( track >= 0 ) && ( track < ( mTracksIndex.size ( ) ) ) ) ) ; mTrackIndex = mTracksIndex.get ( track ) ; mSource.enable ( mTrackIndex , positionUs ) ; seekToInternal ( positionUs ) ; }

Target:
protected com.google.android.exoplayer.MediaFormat getFormat ( int track ) { com.google.android.exoplayer.util.Assertions.checkArgument ( ( ( track >= 0 ) && ( track < ( mTracksIndex.size ( ) ) ) ) ) ; return mSource.getFormat ( mTracksIndex.get ( track ) ) ; }
Source:
private long updateMatchScoresBasedOnDataMatches ( android.database.sqlite.SQLiteDatabase db , long rawContactId , com.android.providers.contacts.ContactAggregator.MatchCandidateList candidates , com.android.providers.contacts.ContactMatcher matcher ) { updateMatchScoresBasedOnNameMatches ( db , rawContactId , matcher ) ; long bestMatch = matcher.pickBestMatch ( ContactMatcher.SCORE_THRESHOLD_PRIMARY , false ) ; if ( bestMatch != ( - 1 ) ) { return bestMatch ; } updateMatchScoresBasedOnEmailMatches ( db , rawContactId , matcher ) ; updateMatchScoresBasedOnPhoneMatches ( db , rawContactId , matcher ) ; return - 1 ; }

Target:
private long updateMatchScoresBasedOnDataMatches ( android.database.sqlite.SQLiteDatabase db , long rawContactId , com.android.providers.contacts.ContactMatcher matcher ) { updateMatchScoresBasedOnIdentityMatch ( db , rawContactId , matcher ) ; updateMatchScoresBasedOnNameMatches ( db , rawContactId , matcher ) ; long bestMatch = matcher.pickBestMatch ( ContactMatcher.SCORE_THRESHOLD_PRIMARY , false ) ; if ( bestMatch != ( - 1 ) ) { return bestMatch ; } updateMatchScoresBasedOnEmailMatches ( db , rawContactId , matcher ) ; updateMatchScoresBasedOnPhoneMatches ( db , rawContactId , matcher ) ; return - 1 ; }
Source:
public static long copy ( java.io.InputStream from , com.google.common.io.OutputSupplier < ? extends java.io.OutputStream > to ) throws java.io.IOException { boolean threw = true ; java.io.OutputStream out = to.getOutput ( ) ; try { long count = com.google.common.io.ByteStreams.copy ( from , out ) ; threw = false ; return count ; } finally { com.google.common.io.Closeables.close ( out , threw ) ; } }

Target:
public static com.google.common.io.ByteArrayDataOutput newDataOutput ( java.io.ByteArrayOutputStream byteArrayOutputSteam ) { return new com.google.common.io.ByteStreams.ByteArrayDataOutputStream ( com.google.common.base.Preconditions.checkNotNull ( byteArrayOutputSteam ) ) ; }