auphong2707/dl4se-code-review-dataset huggingface dataset:
Source:
public void copyFrom ( float [ ] d ) { mRS.validate ( ) ; if ( ( mCurrentDimZ ) > 0 ) { copy3DRangeFrom ( 0 , 0 , 0 , mCurrentDimX , mCurrentDimY , mCurrentDimZ , d ) ; } else if ( ( mCurrentDimY ) > 0 ) { copy2DRangeFrom ( 0 , 0 , mCurrentDimX , mCurrentDimY , d ) ; } else { copy1DRangeFrom ( 0 , mCurrentCount , d ) ; } }

Target:
private void validateIsFloat64 ( ) { if ( ( mType.mElement.mType ) == ( Element.DataType.FLOAT_64 ) ) { return ; } throw new android.support.v8.renderscript.RSIllegalArgumentException ( ( "64 bit float source does not match allocation type " + ( mType.mElement.mType ) ) ) ; }
Source:
public void test_plus_TemporalAmount_negativeMinutes ( ) { java.time.temporal.TemporalAmount period = tck.java.time.MockSimplePeriod.of ( ( - 25 ) , java.time.temporal.ChronoUnit.MINUTES ) ; java.time.LocalTime t = TEST_12_30_40_987654321.plus ( period ) ; org.testng.Assert.assertEquals ( t , java.time.LocalTime.of ( 12 , 5 , 40 , 987654321 ) ) ; }

Target:
public void test_plus_TemporalAmount_negativeMinutes ( ) { java.time.temporal.TemporalAmount period = tck.java.time.MockSimplePeriod.of ( ( - 25 ) , java.time.temporal.ChronoUnit.MINUTES ) ; java.time.LocalTime t = tck.java.time.TCKLocalTime.TEST_12_30_40_987654321.plus ( period ) ; org.testng.Assert.assertEquals ( t , java.time.LocalTime.of ( 12 , 5 , 40 , 987654321 ) ) ; }
Source:
private static native int nativeForkAndSpecialize ( int uid , int gid , int [ ] gids , int debugFlags , int [ ] [ ] rlimits , int mountExternal , java.lang.String seInfo , java.lang.String niceName , int [ ] fdsToClose , java.lang.String instructionSet , java.lang.String appDataDir ) ;

Target:
private static native int nativeForkAndSpecialize ( int uid , int gid , int [ ] gids , int debugFlags , int [ ] [ ] rlimits , int mountExternal , java.lang.String seInfo , java.lang.String niceName , int [ ] fdsToClose , int [ ] fdsToIgnore , java.lang.String instructionSet , java.lang.String appDataDir ) ;
Source:
public void testInstallWithBadlyFormedRulesVersion ( ) throws java.lang.Exception { final java.lang.String invalidRulesVersion = "203Bc" ; byte [ ] versionBytes = libcore.tzdata.update2.BundleVersion.getBytes ( BundleVersion.FULL_BUNDLE_FORMAT_VERSION , invalidRulesVersion , "001" ) ; libcore.tzdata.update2.TimeZoneBundle bundle = libcore.tzdata.update2.TzDataBundleInstallerTest.createTimeZoneBundleWithVersionBytes ( versionBytes ) ; assertFalse ( installer.install ( bundle.getBytes ( ) ) ) ; assertNoContentInstalled ( ) ; }

Target:
public void testInstallWithBadlyFormedRulesVersion ( ) throws java.lang.Exception { final java.lang.String invalidRulesVersion = "203Bc" ; byte [ ] versionBytes = libcore.tzdata.update2.BundleVersion.getBytes ( BundleVersion.FULL_BUNDLE_FORMAT_VERSION , invalidRulesVersion , "001" ) ; libcore.tzdata.update2.TimeZoneBundle bundle = libcore.tzdata.update2.TimeZoneBundleInstallerTest.createTimeZoneBundleWithVersionBytes ( versionBytes ) ; assertFalse ( installer.install ( bundle.getBytes ( ) ) ) ; assertNoContentInstalled ( ) ; }
Source:
public boolean visit ( @ javax.annotation.Nonnull com.android.jack.ir.ast.JMethod jmethod ) { com.android.jack.ir.ast.marker.ThrownExceptionMarker marker = jmethod.getMarker ( com.android.jack.ir.ast.marker.ThrownExceptionMarker.class ) ; if ( marker != null ) { for ( com.android.jack.ir.ast.JClass exception : marker.getThrownExceptions ( ) ) { addCodeUsage ( exception ) ; } } return super . visit ( jmethod ) ; }

Target:
public boolean visit ( @ javax.annotation.Nonnull com.android.jack.ir.ast.JMethodBody x ) { inBody = true ; return super . visit ( x ) ; }
Source:
public void generatePushValue ( final org.jetbrains.asm4.commons.GeneratorAdapter generator , final java.lang.Object value ) { final java.awt.Rectangle rc = ( ( java.awt.Rectangle ) ( value ) ) ; generator.newInstance ( com.intellij.uiDesigner.compiler.RectanglePropertyCodeGenerator.myRectangleType ) ; generator.dup ( ) ; generator.push ( rc.x ) ; generator.push ( rc.y ) ; generator.push ( rc.width ) ; generator.push ( rc.height ) ; generator.invokeConstructor ( com.intellij.uiDesigner.compiler.RectanglePropertyCodeGenerator.myRectangleType , com.intellij.uiDesigner.compiler.RectanglePropertyCodeGenerator.myInitMethod ) ; }

Target:
public void generatePushValue ( final org.jetbrains.org.objectweb.asm.commons.GeneratorAdapter generator , final java.lang.Object value ) { final java.awt.Rectangle rc = ( ( java.awt.Rectangle ) ( value ) ) ; generator.newInstance ( com.intellij.uiDesigner.compiler.RectanglePropertyCodeGenerator.myRectangleType ) ; generator.dup ( ) ; generator.push ( rc.x ) ; generator.push ( rc.y ) ; generator.push ( rc.width ) ; generator.push ( rc.height ) ; generator.invokeConstructor ( com.intellij.uiDesigner.compiler.RectanglePropertyCodeGenerator.myRectangleType , com.intellij.uiDesigner.compiler.RectanglePropertyCodeGenerator.myInitMethod ) ; }
Source:
private static void expectEqualsNaN64 ( long expected , long result ) { if ( ( expected != result ) && ( ( expected | ( Main.DPQUIET ) ) != result ) ) { throw new java.lang.Error ( ( ( ( "Expected: 0x" + ( java.lang.Long.toHexString ( expected ) ) ) + ", found: 0x" ) + ( java.lang.Long.toHexString ( result ) ) ) ) ; } }

Target:
private static void expectEqualsNaN64 ( long expected , long result ) { if ( ( expected != result ) && ( ( expected | ( Main.DPQUIET ) ) != result ) ) { if ( ! ( Main.isDalvik ) ) { if ( expected == ( result & ( java.lang.Long.MAX_VALUE ) ) ) { return ; } } throw new java.lang.Error ( ( ( ( "Expected: 0x" + ( java.lang.Long.toHexString ( expected ) ) ) + ", found: 0x" ) + ( java.lang.Long.toHexString ( result ) ) ) ) ; } }
Source:
public void testSelectedDescendantsMatch_SelectedDescendantsMatchAndDoNotMatch ( ) { android.view.View grany = setUpViewHierarchy ( ) ; try { android.support.test.espresso.assertion.ViewAssertions.selectedDescendantsMatch ( android.support.test.espresso.matcher.ViewMatchers.isAssignableFrom ( android.widget.TextView.class ) , android.support.test.espresso.matcher.ViewMatchers.hasContentDescription ( ) ) . check ( grany , absentException ) ; } catch ( junit.framework.AssertionFailedError expected ) { return ; } fail ( "should fail because not all descendants match." ) ; }

Target:
private android.view.View setUpViewHierarchy ( ) { android.widget.TextView v1 = new android.widget.TextView ( mTargetContext ) ; v1.setText ( "no content description" ) ; android.widget.TextView v2 = new android.widget.TextView ( mTargetContext ) ; v2.setText ( "has content description" ) ; v2.setContentDescription ( "content description" ) ; android.view.ViewGroup parent = new android.widget.RelativeLayout ( mTargetContext ) ; android.view.View grany = new android.widget.ScrollView ( mTargetContext ) ; ( ( android.view.ViewGroup ) ( grany ) ) . addView ( parent ) ; parent.addView ( v1 ) ; parent.addView ( v2 ) ; return grany ; }
Source:
private void mergeClassDefs ( ) { com.android.dx.merge.SortableType [ ] types = getSortedTypes ( ) ; contentsOut.classDefs.off = idsDefsOut.getPosition ( ) ; contentsOut.classDefs.size = types.length ; for ( com.android.dx.merge.SortableType type : types ) { com.android.dx.io.DexBuffer in = type.getBuffer ( ) ; com.android.dx.merge.IndexMap indexMap = ( in == ( dexA ) ) ? aIndexMap : bIndexMap ; transformClassDef ( in , type.getClassDef ( ) , indexMap ) ; } }

Target:
private void mergeClassDefs ( ) { com.android.dx.merge.SortableType [ ] types = getSortedTypes ( ) ; contentsOut.classDefs.off = idsDefsOut.getPosition ( ) ; contentsOut.classDefs.size = types.length ; for ( com.android.dx.merge.SortableType type : types ) { com.android.dex.Dex in = type.getDex ( ) ; com.android.dx.merge.IndexMap indexMap = ( in == ( dexA ) ) ? aIndexMap : bIndexMap ; transformClassDef ( in , type.getClassDef ( ) , indexMap ) ; } }
Source:
public boolean hasIccCard ( ) { synchronized ( mLock ) { if ( ( ( mUiccCard ) != null ) && ( ( mUiccCard.getCardState ( ) ) != ( com.android.internal.telephony.uicc.IccCardStatus.CardState.CARDSTATE_ABSENT ) ) ) { return true ; } return false ; } }

Target:
public boolean hasIccCard ( ) { synchronized ( mLock ) { if ( ( ( mUiccCard ) != null ) && ( ( mUiccCard.getCardState ( ) ) != ( com.android.internal.telephony.uicc.IccCardStatus.CardState.CARDSTATE_ABSENT ) ) ) { return true ; } loge ( ( "hasIccCard: UiccProfile is not null but UiccCard is null or card state is " + "ABSENT" ) ) ; return false ; } }
Source:
private void enforceModifyPermissionOrCarrierPrivilege ( int subId ) { int permission = mApp.checkCallingOrSelfPermission ( android.Manifest.permission.MODIFY_PHONE_STATE ) ; if ( permission == ( android.content.pm.PackageManager.PERMISSION_GRANTED ) ) { return ; } com.android.phone.PhoneInterfaceManager.log ( "No modify permission, check carrier privilege next." ) ; enforceCarrierPrivilege ( subId ) ; }

Target:
public java.lang.String getDeviceSoftwareVersionForSlot ( int slotIndex , java.lang.String callingPackage ) { if ( ! ( com.android.internal.telephony.TelephonyPermissions.checkCallingOrSelfReadPhoneState ( mApp , callingPackage , "getDeviceSoftwareVersionForSlot" ) ) ) { return null ; } com.android.internal.telephony.Phone phone = com.android.internal.telephony.PhoneFactory.getPhone ( slotIndex ) ; return phone == null ? null : phone.getDeviceSvn ( ) ; }
Source:
private android.net.wifi.WifiConfiguration getDefaultApConfiguration ( ) { android.net.wifi.WifiConfiguration config = new android.net.wifi.WifiConfiguration ( ) ; config.SSID = mContext.getResources ( ) . getString ( R.string.wifi_tether_configure_ssid_default ) ; config.allowedKeyManagement.set ( KeyMgmt.WPA2_PSK ) ; java.lang.String randomUUID = java.util.UUID.randomUUID ( ) . toString ( ) ; config.preSharedKey = ( randomUUID.substring ( 0 , 8 ) ) + ( randomUUID.substring ( 9 , 13 ) ) ; return config ; }

Target:
private android.net.wifi.WifiConfiguration getDefaultApConfiguration ( ) { android.net.wifi.WifiConfiguration config = new android.net.wifi.WifiConfiguration ( ) ; config.SSID = ( ( mContext.getResources ( ) . getString ( R.string.wifi_tether_configure_ssid_default ) ) + "_" ) + ( getRandomIntForDefaultSsid ( ) ) ; config.allowedKeyManagement.set ( KeyMgmt.WPA2_PSK ) ; java.lang.String randomUUID = java.util.UUID.randomUUID ( ) . toString ( ) ; config.preSharedKey = ( randomUUID.substring ( 0 , 8 ) ) + ( randomUUID.substring ( 9 , 13 ) ) ; return config ; }
Source:
public boolean visit ( @ javax.annotation.Nonnull com.android.jack.ir.ast.JAnnotation annotation ) { com.android.jack.dx.rop.annotation.Annotation ropAnnotation = new com.android.jack.dx.rop.annotation.Annotation ( com.android.jack.backend.dex.rop.RopHelper.getCstType ( annotation.getType ( ) ) , com.android.jack.dx.rop.annotation.AnnotationVisibility.EMBEDDED ) ; createAnnotationPairs ( annotation , ropAnnotation ) ; ropAnnotation.setImmutable ( ) ; com.android.jack.dx.rop.cst.CstAnnotation cstAnnotation = new com.android.jack.dx.rop.cst.CstAnnotation ( ropAnnotation ) ; result = cstAnnotation ; return false ; }

Target:
public boolean visit ( @ javax.annotation.Nonnull com.android.jack.ir.ast.JAnnotation annotation ) { com.android.jack.dx.rop.annotation.Annotation ropAnnotation = new com.android.jack.dx.rop.annotation.Annotation ( com.android.jack.backend.dex.rop.RopHelper.convertTypeToDx ( annotation.getType ( ) ) , com.android.jack.dx.rop.annotation.AnnotationVisibility.EMBEDDED ) ; createAnnotationPairs ( annotation , ropAnnotation ) ; ropAnnotation.setImmutable ( ) ; com.android.jack.dx.rop.cst.CstAnnotation cstAnnotation = new com.android.jack.dx.rop.cst.CstAnnotation ( ropAnnotation ) ; result = cstAnnotation ; return false ; }
Source:
public static java.lang.String [ ] getAvailableCurrencyCodes ( android.icu.util.ULocale loc , java.util.Date d ) { android.icu.text.CurrencyMetaInfo.CurrencyFilter filter = android.icu.text.CurrencyMetaInfo.CurrencyFilter.onDate ( d ) . withRegion ( loc.getCountry ( ) ) ; java.util.List < java.lang.String > list = android.icu.util.Currency.getTenderCurrencies ( filter ) ; if ( list.isEmpty ( ) ) { return null ; } return list.toArray ( new java.lang.String [ list.size ( ) ] ) ; }

Target:
public static java.lang.String [ ] getAvailableCurrencyCodes ( android.icu.util.ULocale loc , java.util.Date d ) { java.lang.String region = android.icu.util.ULocale.getRegionForSupplementalData ( loc , false ) ; android.icu.text.CurrencyMetaInfo.CurrencyFilter filter = android.icu.text.CurrencyMetaInfo.CurrencyFilter.onDate ( d ) . withRegion ( region ) ; java.util.List < java.lang.String > list = android.icu.util.Currency.getTenderCurrencies ( filter ) ; if ( list.isEmpty ( ) ) { return null ; } return list.toArray ( new java.lang.String [ list.size ( ) ] ) ; }
Source:
public void notifyFailed ( ) { ( mRetryCounter ) ++ ; long temp = java.lang.Math.min ( mMaximumDelayMs , ( ( long ) ( ( mStartDelayMs ) * ( java.lang.Math.pow ( mMultiplier , mRetryCounter ) ) ) ) ) ; mCurrentDelayMs = ( ( long ) ( ( ( 1 + ( java.lang.Math.random ( ) ) ) / 2 ) * temp ) ) ; mHandler.removeCallbacks ( mRunnable ) ; mHandler.postDelayed ( mRunnable , mCurrentDelayMs ) ; }

Target:
public void notifyFailed ( ) { ( mRetryCounter ) ++ ; long temp = java.lang.Math.min ( mMaximumDelayMs , ( ( long ) ( ( mStartDelayMs ) * ( java.lang.Math.pow ( mMultiplier , mRetryCounter ) ) ) ) ) ; mCurrentDelayMs = ( ( long ) ( ( ( 1 + ( java.lang.Math.random ( ) ) ) / 2 ) * temp ) ) ; mHandlerAdapter.removeCallbacks ( mRunnable ) ; mHandlerAdapter.postDelayed ( mRunnable , mCurrentDelayMs ) ; }
Source:
public boolean p2pReinvoke ( int netId , java.lang.String deviceAddress ) { if ( ( android.text.TextUtils.isEmpty ( deviceAddress ) ) || ( netId < 0 ) ) return false ; if ( ( com.android.server.wifi.WifiNative.HIDL_ENABLE ) && ( ( mSupplicantP2pIfaceHal ) != null ) ) { return mSupplicantP2pIfaceHal.reinvoke ( netId , deviceAddress ) ; } else { return doBooleanCommand ( ( ( ( "P2P_INVITE persistent=" + netId ) + " peer=" ) + deviceAddress ) ) ; } }

Target:
public boolean p2pReinvoke ( int netId , java.lang.String deviceAddress ) { if ( ( android.text.TextUtils.isEmpty ( deviceAddress ) ) || ( netId < 0 ) ) return false ; if ( ( com.android.server.wifi.WifiNative.HIDL_P2P_ENABLE ) && ( ( mSupplicantP2pIfaceHal ) != null ) ) { return mSupplicantP2pIfaceHal.reinvoke ( netId , deviceAddress ) ; } else { return doBooleanCommand ( ( ( ( "P2P_INVITE persistent=" + netId ) + " peer=" ) + deviceAddress ) ) ; } }
Source:
public java.lang.String getTestPackage ( com.android.builder.VariantConfiguration testedVariant ) { java.lang.String testPackage = mMergedFlavor.getTestPackageName ( ) ; if ( testPackage == null ) { java.lang.String testedPackage = testedVariant.getPackageName ( null ) ; testPackage = testedPackage + ".test" ; } return testPackage ; }

Target:
public java.lang.String getPackageName ( ) { java.lang.String packageName ; if ( ( mType ) == ( com.android.builder.VariantConfiguration.Type.TEST ) ) { packageName = mMergedFlavor.getTestPackageName ( ) ; if ( packageName == null ) { java.lang.String testedPackage = mTestedConfig.getPackageName ( ) ; packageName = testedPackage + ".test" ; } } else { packageName = getPackageOverride ( ) ; if ( packageName == null ) { packageName = getPackageFromManifest ( ) ; } } return packageName ; }
Source:
public void testListIterator1_IndexOutOfBoundsException ( ) { try { java.util.concurrent.CopyOnWriteArrayList c = new java.util.concurrent.CopyOnWriteArrayList ( ) ; c.listIterator ( ( - 1 ) ) ; shouldThrow ( ) ; } catch ( java.lang.IndexOutOfBoundsException success ) { } }

Target:
public void testListIterator1_IndexOutOfBoundsException ( ) { java.util.concurrent.CopyOnWriteArrayList c = jsr166.CopyOnWriteArrayListTest.populatedArray ( 5 ) ; java.util.List [ ] lists = new java.util.List [ ] { c , c.subList ( 1 , ( ( c.size ( ) ) - 1 ) ) } ; for ( java.util.List list : lists ) { try { list.listIterator ( ( - 1 ) ) ; shouldThrow ( ) ; } catch ( java.lang.IndexOutOfBoundsException success ) { } } }
Source:
public void test_ConstructorLjava_lang_String ( ) throws java.io.IOException { java.lang.System.setProperty ( "user.dir" , java.lang.System.getProperty ( "java.io.tmpdir" ) ) ; zfile.close ( ) ; java.util.zip.ZipFile zip = new java.util.zip.ZipFile ( tempFileName ) ; zip.close ( ) ; java.io.File file = java.io.File.createTempFile ( "zip" , "tmp" ) ; try { zip = new java.util.zip.ZipFile ( file.getName ( ) ) ; fail ( "ZipException expected" ) ; } catch ( java.util.zip.ZipException ee ) { } file.delete ( ) ; }

Target:
public void test_ConstructorLjava_lang_String ( ) throws java.io.IOException { zfile.close ( ) ; java.util.zip.ZipFile zip = new java.util.zip.ZipFile ( tempFileName ) ; zip.close ( ) ; java.io.File file = java.io.File.createTempFile ( "zip" , "tmp" ) ; try { zip = new java.util.zip.ZipFile ( file.getAbsolutePath ( ) ) ; fail ( "ZipException expected" ) ; } catch ( java.util.zip.ZipException ee ) { } file.delete ( ) ; }
Source:
public void test_socket_accept_Nonblocking_NotBound ( ) throws java.io.IOException { java.net.ServerSocket gotSocket = serverChannel.socket ( ) ; serverChannel.configureBlocking ( false ) ; try { gotSocket.accept ( ) ; fail ( "Should throw an IllegalBlockingModeException" ) ; } catch ( java.nio.channels.IllegalBlockingModeException e ) { } serverChannel.close ( ) ; try { gotSocket.accept ( ) ; fail ( "Should throw an IllegalBlockingModeException" ) ; } catch ( java.nio.channels.IllegalBlockingModeException e ) { } }

Target:
public void test_socket_accept_Blocking_NotBound ( ) throws java.io.IOException { java.net.ServerSocket gotSocket = serverChannel.socket ( ) ; serverChannel.configureBlocking ( true ) ; try { gotSocket.accept ( ) ; fail ( "Should throw an IllegalBlockingModeException" ) ; } catch ( java.nio.channels.IllegalBlockingModeException expected ) { } serverChannel.close ( ) ; try { gotSocket.accept ( ) ; fail ( "Should throw an IllegalBlockingModeException" ) ; } catch ( java.nio.channels.IllegalBlockingModeException expected ) { } }
Source:
java.lang.String getResourcePathFromCodePath ( ) { java.lang.String codePath = getCodePath ( ) ; if ( ( ( flags ) & ( android.content.pm.PackageManager.INSTALL_FORWARD_LOCK ) ) != 0 ) { java.lang.String apkNameOnly = com.android.server.pm.PackageManagerService.getApkName ( codePath ) ; return ( ( ( mAppInstallDir.getPath ( ) ) + "/" ) + apkNameOnly ) + ".zip" ; } else { return codePath ; } }

Target:
void createCopyFile ( ) { installDir = ( isFwdLocked ( ) ) ? mDrmAppPrivateInstallDir : mAppInstallDir ; codeFileName = createTempPackageFile ( installDir ) . getPath ( ) ; resourceFileName = getResourcePathFromCodePath ( ) ; created = true ; }
Source:
public boolean isBetterMatchThan ( com.android.ide.eclipse.adt.internal.resources.configurations.ResourceQualifier compareTo , com.android.ide.eclipse.adt.internal.resources.configurations.ResourceQualifier reference ) { if ( compareTo == null ) { return true ; } com.android.ide.eclipse.adt.internal.resources.configurations.KeyboardStateQualifier compareQualifier = ( ( com.android.ide.eclipse.adt.internal.resources.configurations.KeyboardStateQualifier ) ( compareTo ) ) ; com.android.ide.eclipse.adt.internal.resources.configurations.KeyboardStateQualifier referenceQualifier = ( ( com.android.ide.eclipse.adt.internal.resources.configurations.KeyboardStateQualifier ) ( reference ) ) ; if ( ( referenceQualifier.mValue ) == ( com.android.ide.eclipse.adt.internal.resources.configurations.KeyboardStateQualifier.KeyboardState.SOFT ) ) { if ( ( ( compareQualifier.mValue ) == ( com.android.ide.eclipse.adt.internal.resources.configurations.KeyboardStateQualifier.KeyboardState.EXPOSED ) ) && ( ( mValue ) == ( com.android.ide.eclipse.adt.internal.resources.configurations.KeyboardStateQualifier.KeyboardState.SOFT ) ) ) { return true ; } } return false ; }

Target:
public java.lang.String getFolderSegment ( com.android.sdklib.IAndroidTarget target ) { if ( ( mValue ) != null ) { return mValue.getValue ( ) ; } return "" ; }
Source:
public void viewportChanged ( ) { org.eclipse.swt.widgets.Display.getDefault ( ) . syncExec ( new java.lang.Runnable ( ) { public void run ( ) { synchronized ( this ) { viewport = model.getViewport ( ) ; setBounds ( ) ; setTransform ( ) ; } } } ) ; doRedraw ( ) ; }

Target:
public void treeChanged ( ) { org.eclipse.swt.widgets.Display.getDefault ( ) . syncExec ( new java.lang.Runnable ( ) { public void run ( ) { synchronized ( this ) { tree = model.getTree ( ) ; selectedNode = model.getSelection ( ) ; viewport = model.getViewport ( ) ; setBounds ( ) ; setTransform ( ) ; } } } ) ; doRedraw ( ) ; }
Source:
public void getSmscAddress ( android.os.Message result ) { com.android.internal.telephony.RILRequest rr = com.android.internal.telephony.RILRequest.obtain ( com.android.internal.telephony.RIL_REQUEST_GET_SMSC_ADDRESS , result ) ; if ( com.android.internal.telephony.RIL.RILJ_LOGD ) riljLog ( ( ( ( rr.serialString ( ) ) + "> " ) + ( com.android.internal.telephony.RIL.requestToString ( rr.mRequest ) ) ) ) ; send ( rr ) ; }

Target:
public void queryAvailableBandMode ( android.os.Message response ) { com.android.internal.telephony.RILRequest rr = com.android.internal.telephony.RILRequest.obtain ( com.android.internal.telephony.RIL_REQUEST_QUERY_AVAILABLE_BAND_MODE , response , mRILDefaultWorkSource ) ; if ( com.android.internal.telephony.RIL.RILJ_LOGD ) riljLog ( ( ( ( rr.serialString ( ) ) + "> " ) + ( com.android.internal.telephony.RIL.requestToString ( rr.mRequest ) ) ) ) ; send ( rr ) ; }
Source:
public void onCreate ( ) { java.lang.System.loadLibrary ( "perfettocts_jni" ) ; new java.lang.Thread ( new java.lang.Runnable ( ) { @ java.lang.Override public void run ( ) { try { android.perfetto.producer.ProducerIsolatedService.setupProducer ( ) ; } catch ( java.lang.Exception ex ) { ex.printStackTrace ( ) ; } } } ) . start ( ) ; }

Target:
public void onCreate ( ) { android.app.Notification.Builder builder = new android.app.Notification.Builder ( this , "isolated_service" ) ; builder.setContentTitle ( "Perfetto isolated service" ) . setContentText ( "Perfetto isolated service" ) . setSmallIcon ( R.mipmap.ic_launcher ) ; startForeground ( android.perfetto.producer.ProducerIsolatedService.NOTIFICATION_ID , builder.build ( ) ) ; java.lang.System.loadLibrary ( "perfettocts_jni" ) ; new java.lang.Thread ( new java.lang.Runnable ( ) { @ java.lang.Override public void run ( ) { try { android.perfetto.producer.ProducerIsolatedService.setupProducer ( ) ; } catch ( java.lang.Exception ex ) { ex.printStackTrace ( ) ; } } } ) . start ( ) ; }
Source:
private com.android.jack.dx.dex.code.Dop findOpcodeForInsn ( com.android.jack.dx.dex.code.DalvInsn insn , com.android.jack.dx.dex.code.Dop guess ) { while ( guess != null ) { if ( guess.getFormat ( ) . isCompatible ( insn ) ) { if ( ( ! ( dexOptions.forceJumbo ) ) || ( ( guess.getOpcode ( ) ) != ( com.android.jack.dx.io.Opcodes.CONST_STRING ) ) ) { break ; } } guess = com.android.jack.dx.dex.code.Dops.getNextOrNull ( guess , dexOptions ) ; } return guess ; }

Target:
private com.android.jack.dx.dex.code.Dop findOpcodeForInsn ( com.android.jack.dx.dex.code.DalvInsn insn , com.android.jack.dx.dex.code.Dop guess ) { while ( guess != null ) { if ( guess.getFormat ( ) . isCompatible ( insn ) ) { if ( ( ! ( dexOptions.isForceJumbo ( ) ) ) || ( ( guess.getOpcode ( ) ) != ( com.android.jack.dx.io.Opcodes.CONST_STRING ) ) ) { break ; } } guess = com.android.jack.dx.dex.code.Dops.getNextOrNull ( guess , dexOptions ) ; } return guess ; }
Source:
public byte [ ] transmit ( byte [ ] command ) throws android.os.RemoteException { this . setCallingPid ( android.os.Binder.getCallingPid ( ) ) ; return this . transmit ( command ) ; }

Target:
public byte [ ] transmit ( byte [ ] command ) throws android.os.RemoteException { this . setCallingPid ( android.os.Binder.getCallingPid ( ) ) ; try { return this . transmit ( command ) ; } catch ( java.io.IOException e ) { throw new android.os.ServiceSpecificException ( android.se.omapi.SEService.IO_ERROR , e.getMessage ( ) ) ; } }
Source:
void finishInputLocked ( ) { mNextServedView = null ; if ( ( mServedView ) != null ) { if ( android.view.inputmethod.InputMethodManager.DEBUG ) android.util.Log.v ( android.view.inputmethod.InputMethodManager.TAG , ( "FINISH INPUT: " + ( mServedView ) ) ) ; if ( ( mCurrentTextBoxAttribute ) != null ) { try { mService.finishInput ( mClient ) ; } catch ( android.os.RemoteException e ) { } } notifyInputConnectionFinished ( ) ; mServedView = null ; mCompletions = null ; mServedConnecting = false ; clearConnectionLocked ( ) ; } }

Target:
void finishInputLocked ( ) { mNextServedView = null ; if ( ( mServedView ) != null ) { if ( android.view.inputmethod.InputMethodManager.DEBUG ) android.util.Log.v ( android.view.inputmethod.InputMethodManager.TAG , ( "FINISH INPUT: mServedView=" + ( android.view.inputmethod.InputMethodManager.dumpViewInfo ( mServedView ) ) ) ) ; if ( ( mCurrentTextBoxAttribute ) != null ) { try { mService.finishInput ( mClient ) ; } catch ( android.os.RemoteException e ) { throw e.rethrowFromSystemServer ( ) ; } } mServedView = null ; mCompletions = null ; mServedConnecting = false ; clearConnectionLocked ( ) ; } }
Source:
public static com.android.cts.verifier.TestListAdapter.TestListItem newTest ( android.content.Context context , int titleResId , java.lang.String testName , android.content.Intent intent ) { return com.android.cts.verifier.TestListAdapter.TestListItem.newTest ( context.getString ( titleResId ) , testName , intent ) ; }

Target:
public static com.android.cts.verifier.TestListAdapter.TestListItem newTest ( android.content.Context context , int titleResId , java.lang.String testName , android.content.Intent intent , java.lang.String [ ] requiredFeatures , java.lang.String [ ] excludedFeatures , java.lang.String [ ] applicableFeatures ) { return com.android.cts.verifier.TestListAdapter.TestListItem.newTest ( context.getString ( titleResId ) , testName , intent , requiredFeatures , excludedFeatures , applicableFeatures ) ; }
Source:
public void getPreferredVoicePrivacy ( android.os.Message result ) { com.android.internal.telephony.RILRequest rr = com.android.internal.telephony.RILRequest.obtain ( com.android.internal.telephony.RIL_REQUEST_CDMA_QUERY_PREFERRED_VOICE_PRIVACY_MODE , result ) ; send ( rr ) ; }

Target:
public void getMute ( android.os.Message response ) { com.android.internal.telephony.RILRequest rr = com.android.internal.telephony.RILRequest.obtain ( com.android.internal.telephony.RIL_REQUEST_GET_MUTE , response , mRILDefaultWorkSource ) ; if ( com.android.internal.telephony.RIL.RILJ_LOGD ) riljLog ( ( ( ( rr.serialString ( ) ) + "> " ) + ( com.android.internal.telephony.RIL.requestToString ( rr.mRequest ) ) ) ) ; send ( rr ) ; }
Source:
void resolve ( ) { if ( ( formalVar ) != null ) { return ; } java.lang.reflect.GenericDeclaration curLayer = declOfVarUser ; java.lang.reflect.TypeVariable var ; while ( ( var = org.apache.harmony.luni.lang.reflect.ImplForVariable.findFormalVar ( curLayer , name ) ) == null ) { curLayer = org.apache.harmony.luni.lang.reflect.ImplForVariable.nextLayer ( curLayer ) ; if ( curLayer == null ) { throw new java.lang.AssertionError ( "illegal type variable reference" ) ; } } formalVar = ( ( org.apache.harmony.luni.lang.reflect.ImplForVariable < D > ) ( var ) ) ; this . genericDeclaration = formalVar.genericDeclaration ; this . bounds = formalVar.bounds ; }

Target:
void resolve ( ) { if ( ( formalVar ) != null ) { return ; } java.lang.reflect.GenericDeclaration curLayer = declOfVarUser ; java.lang.reflect.TypeVariable var ; while ( ( var = libcore.reflect.TypeVariableImpl.findFormalVar ( curLayer , name ) ) == null ) { curLayer = libcore.reflect.TypeVariableImpl.nextLayer ( curLayer ) ; if ( curLayer == null ) { throw new java.lang.AssertionError ( "illegal type variable reference" ) ; } } formalVar = ( ( libcore.reflect.TypeVariableImpl < D > ) ( var ) ) ; this . genericDeclaration = formalVar.genericDeclaration ; this . bounds = formalVar.bounds ; }
Source:
public java.lang.String createNetworkSpecifier ( @ android.net.wifi.aware.WifiAwareManager.DataPathRole int role , @ android.annotation.Nullable java.lang.Object peerHandle , @ android.annotation.Nullable byte [ ] token ) { if ( mTerminated ) { android.util.Log.w ( android.net.wifi.aware.WifiAwareDiscoveryBaseSession.TAG , "createNetworkSpecifier: called on terminated session" ) ; return null ; } else { android.net.wifi.aware.WifiAwareManager mgr = mMgr.get ( ) ; if ( mgr == null ) { android.util.Log.w ( android.net.wifi.aware.WifiAwareDiscoveryBaseSession.TAG , "createNetworkSpecifier: called post GC on WifiAwareManager" ) ; return null ; } return mgr.createNetworkSpecifier ( mClientId , role , mSessionId , peerHandle , token ) ; } }

Target:
public java.lang.String createNetworkSpecifier ( @ android.net.wifi.aware.WifiAwareManager.DataPathRole int role , @ android.annotation.Nullable android.net.wifi.aware.WifiAwareManager.PeerHandle peerHandle , @ android.annotation.Nullable byte [ ] token ) { if ( mTerminated ) { android.util.Log.w ( android.net.wifi.aware.WifiAwareDiscoveryBaseSession.TAG , "createNetworkSpecifier: called on terminated session" ) ; return null ; } else { android.net.wifi.aware.WifiAwareManager mgr = mMgr.get ( ) ; if ( mgr == null ) { android.util.Log.w ( android.net.wifi.aware.WifiAwareDiscoveryBaseSession.TAG , "createNetworkSpecifier: called post GC on WifiAwareManager" ) ; return null ; } return mgr.createNetworkSpecifier ( mClientId , role , mSessionId , peerHandle , token ) ; } }
Source:
public static < T > T find ( java.util.Iterator < ? extends T > iterator , com.google.common.base.Predicate < ? super T > predicate , @ javax.annotation.Nullable T defaultValue ) { com.google.common.collect.UnmodifiableIterator < ? extends T > filteredIterator = com.google.common.collect.Iterators.filter ( iterator , predicate ) ; return filteredIterator.hasNext ( ) ? filteredIterator.next ( ) : defaultValue ; }

Target:
public static < T > T find ( java.util.Iterator < ? extends T > iterator , com.google.common.base.Predicate < ? super T > predicate , @ javax.annotation.Nullable T defaultValue ) { return com.google.common.collect.Iterators.getNext ( com.google.common.collect.Iterators.filter ( iterator , predicate ) , defaultValue ) ; }
Source:
private com.android.jack.ir.ast.JMethodIdWithReturnType getJMethodIdWithReturnType ( @ javax.annotation.Nonnull org.eclipse.jdt.internal.compiler.lookup.MethodBinding mb ) { com.android.jack.ir.ast.JMethodId methodId = new com.android.jack.ir.ast.JMethodId ( com.android.jack.ir.impl.ReferenceMapper.intern ( mb.selector ) , com.android.jack.ir.ast.MethodKind.INSTANCE_VIRTUAL ) ; for ( org.eclipse.jdt.internal.compiler.lookup.TypeBinding parameterType : mb.parameters ) { methodId.addParam ( getTypeMap ( ) . get ( parameterType ) ) ; } return new com.android.jack.ir.ast.JMethodIdWithReturnType ( methodId , getTypeMap ( ) . get ( mb.returnType ) ) ; }

Target:
private com.android.jack.ir.ast.JMethodId getJMethodId ( @ javax.annotation.Nonnull org.eclipse.jdt.internal.compiler.lookup.MethodBinding mb ) { com.android.jack.ir.ast.JMethodIdWide methodIdWide = new com.android.jack.ir.ast.JMethodIdWide ( com.android.jack.ir.impl.ReferenceMapper.intern ( mb.selector ) , com.android.jack.ir.ast.MethodKind.INSTANCE_VIRTUAL ) ; for ( org.eclipse.jdt.internal.compiler.lookup.TypeBinding parameterType : mb.parameters ) { methodIdWide.addParam ( getTypeMap ( ) . get ( parameterType ) ) ; } return new com.android.jack.ir.ast.JMethodId ( methodIdWide , getTypeMap ( ) . get ( mb.returnType ) ) ; }
Source:
public boolean isNonTtyOrTtyOnVolteEnabledForSlot ( ) { if ( getBooleanCarrierConfigForSlot ( CarrierConfigManager.KEY_CARRIER_VOLTE_TTY_SUPPORTED_BOOL ) ) { return true ; } return ( Settings.Secure.getInt ( mContext.getContentResolver ( ) , Settings.Secure.PREFERRED_TTY_MODE , TelecomManager.TTY_MODE_OFF ) ) == ( android.telecom.TelecomManager.TTY_MODE_OFF ) ; }

Target:
public static boolean isNonTtyOrTtyOnVolteEnabled ( android.content.Context context ) { if ( com.android.ims.ImsManager.getBooleanCarrierConfig ( context , CarrierConfigManager.KEY_CARRIER_VOLTE_TTY_SUPPORTED_BOOL ) ) { return true ; } android.telecom.TelecomManager tm = ( ( android.telecom.TelecomManager ) ( context.getSystemService ( Context.TELECOM_SERVICE ) ) ) ; if ( tm == null ) { android.util.Log.w ( com.android.ims.ImsManager.TAG , "isNonTtyOrTtyOnVolteEnabled: telecom not available" ) ; return true ; } return ( tm.getCurrentTtyMode ( ) ) == ( android.telecom.TelecomManager.TTY_MODE_OFF ) ; }
Source:
public void testStageUninstall_existingStagedDataDistro ( ) throws java.lang.Exception { byte [ ] installedDistroBytes = com.android.timezone.distro.installer.TimeZoneDistroInstallerTest.createValidTimeZoneDistroBytes ( com.android.timezone.distro.installer.TimeZoneDistroInstallerTest.NEW_RULES_VERSION , 1 ) ; simulateInstalledDistro ( installedDistroBytes ) ; java.io.File stagedDataDir = installer.getStagedTzDataDir ( ) ; assertTrue ( stagedDataDir.mkdir ( ) ) ; assertTrue ( installer.stageUninstall ( ) ) ; assertDistroUninstallStaged ( ) ; assertInstalledDistro ( installedDistroBytes ) ; }

Target:
public void testStageUninstall_existingInstalledDataDistro ( ) throws java.lang.Exception { byte [ ] installedDistroBytes = com.android.timezone.distro.installer.TimeZoneDistroInstallerTest.createValidTimeZoneDistroBytes ( com.android.timezone.distro.installer.TimeZoneDistroInstallerTest.NEW_RULES_VERSION , 1 ) ; simulateInstalledDistro ( installedDistroBytes ) ; java.io.File stagedDataDir = installer.getStagedTzDataDir ( ) ; assertTrue ( stagedDataDir.mkdir ( ) ) ; assertEquals ( TimeZoneDistroInstaller.UNINSTALL_SUCCESS , installer.stageUninstall ( ) ) ; assertDistroUninstallStaged ( ) ; assertInstalledDistro ( installedDistroBytes ) ; }
Source:
public void testInternalState ( ) { java.nio.CharBuffer in = java.nio.CharBuffer.wrap ( "A" ) ; java.nio.ByteBuffer out = java.nio.ByteBuffer.allocate ( 16 ) ; org.apache.harmony.tests.java.nio.charset.ASCIICharsetEncoderTest.encoder.reset ( ) ; org.apache.harmony.tests.java.nio.charset.ASCIICharsetEncoderTest.encoder.encode ( in , out , false ) ; in = java.nio.CharBuffer.wrap ( "B" ) ; org.apache.harmony.tests.java.nio.charset.ASCIICharsetEncoderTest.encoder.encode ( in , out , true ) ; org.apache.harmony.tests.java.nio.charset.ASCIICharsetEncoderTest.encoder.flush ( out ) ; }

Target:
public void testInternalState ( ) { java.nio.CharBuffer in = java.nio.CharBuffer.wrap ( "A" ) ; java.nio.ByteBuffer out = java.nio.ByteBuffer.allocate ( 16 ) ; encoder.reset ( ) ; encoder.encode ( in , out , false ) ; in = java.nio.CharBuffer.wrap ( "B" ) ; encoder.encode ( in , out , true ) ; encoder.flush ( out ) ; }
Source:
private static void assertScanResultsMessage ( int listenerId , android.net.wifi.WifiScanner [ ] expected , android.os.Message scanResultMessage ) { assertEquals ( "what" , WifiScanner.CMD_SCAN_RESULT , scanResultMessage.what ) ; assertEquals ( "listenerId" , listenerId , scanResultMessage.arg2 ) ; assertScanDatasEquals ( expected , ( ( android.net.wifi.WifiScanner.ParcelableScanData ) ( scanResultMessage.obj ) ) . getResults ( ) ) ; }

Target:
private static void assertScanResultsMessage ( int listenerId , android.net.wifi.WifiScanner [ ] expected , android.os.Message scanResultMessage ) { org.junit.Assert.assertEquals ( "what" , WifiScanner.CMD_SCAN_RESULT , scanResultMessage.what ) ; org.junit.Assert.assertEquals ( "listenerId" , listenerId , scanResultMessage.arg2 ) ; com.android.server.wifi.ScanTestUtil.assertScanDatasEquals ( expected , ( ( android.net.wifi.WifiScanner.ParcelableScanData ) ( scanResultMessage.obj ) ) . getResults ( ) ) ; }
Source:
public void showInputMethodAndSubtypeEnabler ( java.lang.String imiId ) { synchronized ( mH ) { try { mService.showInputMethodAndSubtypeEnablerFromClient ( mClient , imiId ) ; } catch ( android.os.RemoteException e ) { android.util.Log.w ( android.view.inputmethod.InputMethodManager.TAG , ( "IME died: " + ( mCurId ) ) , e ) ; } } }

Target:
public android.view.inputmethod.InputMethodSubtype getCurrentInputMethodSubtype ( ) { try { return mService.getCurrentInputMethodSubtype ( ) ; } catch ( android.os.RemoteException e ) { throw e.rethrowFromSystemServer ( ) ; } }
Source:
public void testMakeTimeZone_All ( ) throws java.lang.Exception { libcore.util.ZoneInfoDB.TzData instance = libcore.util.ZoneInfoDB.getInstance ( ) ; java.lang.String [ ] availableIDs = instance.getAvailableIDs ( ) ; java.util.Arrays.sort ( availableIDs ) ; for ( java.lang.String id : availableIDs ) { libcore.io.BufferIterator bufferIterator = instance.getBufferIterator ( id ) ; libcore.util.ZoneInfo zoneInfo = libcore.util.ZoneInfo.makeTimeZone ( id , bufferIterator , java.lang.Long.MIN_VALUE ) ; assertNotNull ( ( ( "TimeZone " + id ) + " was not created" ) , zoneInfo ) ; assertEquals ( id , zoneInfo.getID ( ) ) ; } }

Target:
public void testReadTimeZone_All ( ) throws java.lang.Exception { libcore.util.ZoneInfoDB.TzData instance = libcore.util.ZoneInfoDB.getInstance ( ) ; java.lang.String [ ] availableIDs = instance.getAvailableIDs ( ) ; java.util.Arrays.sort ( availableIDs ) ; for ( java.lang.String id : availableIDs ) { libcore.io.BufferIterator bufferIterator = instance.getBufferIterator ( id ) ; libcore.util.ZoneInfo zoneInfo = libcore.util.ZoneInfo.readTimeZone ( id , bufferIterator , java.lang.Long.MIN_VALUE ) ; assertNotNull ( ( ( "TimeZone " + id ) + " was not created" ) , zoneInfo ) ; assertEquals ( id , zoneInfo.getID ( ) ) ; } }
Source:
public static java.util.List < java.lang.String > appendLines ( java.util.List < java.lang.String > result , java.lang.String file , java.lang.String encoding ) throws java.io.IOException { return com.ibm.icu.impl.UnicodeRegex.appendLines ( result , new java.io.FileInputStream ( file ) , encoding ) ; }

Target:
public static java.util.List < java.lang.String > appendLines ( java.util.List < java.lang.String > result , java.lang.String file , java.lang.String encoding ) throws java.io.IOException { java.io.InputStream is = new java.io.FileInputStream ( file ) ; try { return com.ibm.icu.impl.UnicodeRegex.appendLines ( result , is , encoding ) ; } finally { is.close ( ) ; } }
Source:
protected void setUp ( ) throws java.lang.Exception { super . setUp ( ) ; m = new com.android.sdklib.internal.repository.packages.BrokenPackage ( null , "short description" , "long description" , 12 , 13 , "os/path" ) ; }

Target:
protected void setUp ( ) throws java.lang.Exception { super . setUp ( ) ; m = new com.android.sdklib.internal.repository.packages.BrokenPackage ( null , "short description" , "long description" , 12 , 13 , "os/path" , com.android.sdklib.repository.descriptors.PkgDesc.newTool ( new com.android.sdklib.repository.FullRevision ( 1 , 2 , 3 , 4 ) , FullRevision.NOT_SPECIFIED ) ) ; }
Source:
private boolean callsSuper ( lombok.ast.MethodDeclaration node , final java.lang.String methodName ) { final java.util.concurrent.atomic.AtomicBoolean result = new java.util.concurrent.atomic.AtomicBoolean ( ) ; node.accept ( new lombok.ast.ForwardingAstVisitor ( ) { @ java.lang.Override public boolean visitMethodInvocation ( lombok.ast.MethodInvocation node ) { if ( ( node.astName ( ) . astValue ( ) . equals ( methodName ) ) && ( ( node.astOperand ( ) ) instanceof lombok.ast.Super ) ) { result.set ( true ) ; } return super . visitMethodInvocation ( node ) ; } } ) ; return result.get ( ) ; }

Target:
public lombok.ast.AstVisitor createJavaVisitor ( @ com.android.annotations.NonNull final com.android.tools.lint.detector.api.JavaContext context ) { return new lombok.ast.ForwardingAstVisitor ( ) { @ java.lang.Override public boolean visitMethodDeclaration ( lombok.ast.MethodDeclaration node ) { com.android.tools.lint.client.api.JavaParser.ResolvedNode resolved = context.resolve ( node ) ; if ( resolved instanceof com.android.tools.lint.client.api.JavaParser.ResolvedMethod ) { com.android.tools.lint.client.api.JavaParser.ResolvedMethod method = ( ( com.android.tools.lint.client.api.JavaParser.ResolvedMethod ) ( resolved ) ) ; com.android.tools.lint.checks.CallSuperDetector.checkCallSuper ( context , node , method ) ; } return false ; } } ; }
Source:
public java.nio.channels.FileChannel getChannel ( ) { synchronized ( this ) { if ( ( channel ) == null ) { channel = sun.nio.ch.FileChannelImpl.open ( fd , path , false , true , append , this ) ; fd.incrementAndGetUseCount ( ) ; } return channel ; } }

Target:
protected void finalize ( ) throws java.io.IOException { if ( ( guard ) != null ) { guard.warnIfOpen ( ) ; } if ( ( fd ) != null ) { if ( ( ( fd ) == ( java.io.FileDescriptor.out ) ) || ( ( fd ) == ( java.io.FileDescriptor.err ) ) ) { flush ( ) ; } else { close ( ) ; } } }
Source:
public java.nio.ByteBuffer putShort ( int index , short value ) { if ( isReadOnly ) { throw new java.nio.ReadOnlyBufferException ( ) ; } checkIndex ( index , SizeOf.SHORT ) ; this . block.pokeShort ( ( ( offset ) + index ) , value , order ) ; return this ; }

Target:
public final short getShort ( int index ) { checkNotFreed ( ) ; checkIndex ( index , SizeOf.SHORT ) ; return this . block.peekShort ( ( ( offset ) + index ) , order ) ; }
Source:
public void testGetActivities ( ) { assertEquals ( 1 , mManifestTestApp.getActivities ( ) . length ) ; com.android.sdklib.xml.AndroidManifestParser.Activity activity = mManifestTestApp.getActivities ( ) [ 0 ] ; assertEquals ( com.android.ide.eclipse.adt.internal.project.AndroidManifestParserTest.ACTIVITY_NAME , activity.getName ( ) ) ; assertTrue ( activity.hasAction ( ) ) ; assertTrue ( activity.isHomeActivity ( ) ) ; assertTrue ( activity.hasAction ( ) ) ; assertEquals ( activity , mManifestTestApp.getActivities ( ) [ 0 ] ) ; }

Target:
public void testGetVersionCode ( ) { assertEquals ( com.android.ide.eclipse.adt.internal.project.AndroidManifestParserTest.VERSION_CODE , mManifestTestApp.getVersionCode ( ) ) ; assertEquals ( null , mManifestInstrumentation.getVersionCode ( ) ) ; }
Source:
private static void initFormatStrings ( ) { synchronized ( android.text.format.DateUtils.sLock ) { android.content.res.Resources r = android.content.res.Resources.getSystem ( ) ; android.content.res.Configuration cfg = r.getConfiguration ( ) ; if ( ( ( android.text.format.DateUtils.sLastConfig ) == null ) || ( ! ( android.text.format.DateUtils.sLastConfig.equals ( cfg ) ) ) ) { android.text.format.DateUtils.sLastConfig = cfg ; android.text.format.DateUtils.sStatusTimeFormat = java.text.DateFormat.getTimeInstance ( java.text.DateFormat.SHORT ) ; android.text.format.DateUtils.sElapsedFormatMMSS = r.getString ( com.android.internal.R.string.elapsed_time_short_format_mm_ss ) ; android.text.format.DateUtils.sElapsedFormatHMMSS = r.getString ( com.android.internal.R.string.elapsed_time_short_format_h_mm_ss ) ; } } }

Target:
private static void initFormatStringsLocked ( ) { android.content.res.Resources r = android.content.res.Resources.getSystem ( ) ; android.content.res.Configuration cfg = r.getConfiguration ( ) ; if ( ( ( android.text.format.DateUtils.sLastConfig ) == null ) || ( ! ( android.text.format.DateUtils.sLastConfig.equals ( cfg ) ) ) ) { android.text.format.DateUtils.sLastConfig = cfg ; android.text.format.DateUtils.sStatusTimeFormat = java.text.DateFormat.getTimeInstance ( java.text.DateFormat.SHORT ) ; android.text.format.DateUtils.sElapsedFormatMMSS = r.getString ( com.android.internal.R.string.elapsed_time_short_format_mm_ss ) ; android.text.format.DateUtils.sElapsedFormatHMMSS = r.getString ( com.android.internal.R.string.elapsed_time_short_format_h_mm_ss ) ; } }
Source:
public void setComment ( java.lang.String comment ) { if ( ( comment != null ) && ( ( comment.length ( ) ) > 65535 ) ) { throw new java.lang.IllegalArgumentException ( ( "Comment too long: " + ( comment.length ( ) ) ) ) ; } this . comment = comment ; }

Target:
public void setComment ( java.lang.String comment ) { if ( comment == null ) { this . comment = null ; return ; } byte [ ] commentBytes = comment.getBytes ( Charsets.UTF_8 ) ; if ( ( commentBytes.length ) > 65535 ) { throw new java.lang.IllegalArgumentException ( ( "Comment too long: " + ( commentBytes.length ) ) ) ; } this . comment = comment ; }
Source:
private static byte [ ] getBytes ( java.lang.String string ) { return string.getBytes ( Charsets.UTF_8 ) ; }

Target:
private static byte [ ] getKeyBytes ( java.lang.String string ) { try { int utfCount = ( ( int ) ( java.nio.charset.ModifiedUtf8.countBytes ( string , false ) ) ) ; byte [ ] result = new byte [ utfCount ] ; java.nio.charset.ModifiedUtf8.encode ( result , 0 , string ) ; return result ; } catch ( java.io.UTFDataFormatException e ) { throw new java.lang.RuntimeException ( e ) ; } }
Source:
private void addRemoteSysImg ( com.android.sdklib.AndroidVersion version , com.android.sdklib.repository.MajorRevision revision , java.lang.String abi ) { com.android.sdklib.repository.descriptors.IPkgDesc d = com.android.sdklib.repository.descriptors.PkgDesc.newSysImg ( version , abi , revision ) ; com.android.sdklib.repository.remote.RemotePkgInfo r = new com.android.sdklib.repository.remote.RemotePkgInfo ( d , mSource ) ; mRemotePkgs.put ( d.getType ( ) , r ) ; }

Target:
private void addRemoteSysImg ( com.android.sdklib.AndroidVersion version , com.android.sdklib.repository.MajorRevision revision , com.android.sdklib.repository.descriptors.IdDisplay tag , java.lang.String abi ) { com.android.sdklib.repository.descriptors.IPkgDesc d = com.android.sdklib.repository.descriptors.PkgDesc.newSysImg ( version , tag , abi , revision ) ; com.android.sdklib.repository.remote.RemotePkgInfo r = new com.android.sdklib.repository.remote.RemotePkgInfo ( d , mSource ) ; mRemotePkgs.put ( d.getType ( ) , r ) ; }
Source:
private java.util.List < com.android.sdkuilib.internal.repository.ArchiveInfo > getRemoteArchives_NoGUI ( boolean includeObsoletes ) { refreshSources ( true ) ; loadRemoteAddonsList ( ) ; com.android.sdkuilib.internal.repository.UpdaterLogic ul = new com.android.sdkuilib.internal.repository.UpdaterLogic ( this ) ; java.util.List < com.android.sdkuilib.internal.repository.ArchiveInfo > archives = ul.computeUpdates ( null , getSources ( ) , getLocalSdkParser ( ) . getPackages ( ) , includeObsoletes ) ; ul.addNewPlatforms ( archives , getSources ( ) , getLocalSdkParser ( ) . getPackages ( ) , includeObsoletes ) ; java.util.Collections.sort ( archives ) ; return archives ; }

Target:
private java.util.List < com.android.sdkuilib.internal.repository.ArchiveInfo > getRemoteArchives_NoGUI ( boolean includeObsoletes ) { refreshSources ( true ) ; loadRemoteAddonsList ( ) ; com.android.sdkuilib.internal.repository.SdkUpdaterLogic ul = new com.android.sdkuilib.internal.repository.SdkUpdaterLogic ( this ) ; java.util.List < com.android.sdkuilib.internal.repository.ArchiveInfo > archives = ul.computeUpdates ( null , getSources ( ) , getLocalSdkParser ( ) . getPackages ( ) , includeObsoletes ) ; ul.addNewPlatforms ( archives , getSources ( ) , getLocalSdkParser ( ) . getPackages ( ) , includeObsoletes ) ; java.util.Collections.sort ( archives ) ; return archives ; }
Source:
public java.util.Iterator < android.net.wifi.nan.LvBufferUtils.LvElement > iterator ( ) { return new java.util.Iterator < android.net.wifi.nan.LvBufferUtils.LvElement > ( ) { private java.util.Iterator < android.net.wifi.nan.TlvBufferUtils.TlvElement > mTlvIterator = mTlvIterable.iterator ( ) ; @ java.lang.Override public boolean hasNext ( ) { return mTlvIterator.hasNext ( ) ; } @ java.lang.Override public android.net.wifi.nan.LvBufferUtils.LvElement next ( ) { android.net.wifi.nan.TlvBufferUtils.TlvElement tlvE = mTlvIterator.next ( ) ; return new android.net.wifi.nan.LvBufferUtils.LvElement ( tlvE.length , tlvE.refArray , tlvE.offset ) ; } @ java.lang.Override public void remove ( ) { throw new java.lang.UnsupportedOperationException ( ) ; } } ; }

Target:
public java.util.Iterator < android.net.wifi.aware.LvBufferUtils.LvElement > iterator ( ) { return new java.util.Iterator < android.net.wifi.aware.LvBufferUtils.LvElement > ( ) { private java.util.Iterator < android.net.wifi.aware.TlvBufferUtils.TlvElement > mTlvIterator = mTlvIterable.iterator ( ) ; @ java.lang.Override public boolean hasNext ( ) { return mTlvIterator.hasNext ( ) ; } @ java.lang.Override public android.net.wifi.aware.LvBufferUtils.LvElement next ( ) { android.net.wifi.aware.TlvBufferUtils.TlvElement tlvE = mTlvIterator.next ( ) ; return new android.net.wifi.aware.LvBufferUtils.LvElement ( tlvE.length , tlvE.refArray , tlvE.offset ) ; } @ java.lang.Override public void remove ( ) { throw new java.lang.UnsupportedOperationException ( ) ; } } ; }