auphong2707/dl4se-code-review-dataset huggingface dataset:
Source:
void remove ( java.util.UUID uuid ) { synchronized ( mApps ) { java.util.Iterator < com.android.bluetooth.gatt.ContextMap < T > . App > i = mApps.iterator ( ) ; while ( i.hasNext ( ) ) { com.android.bluetooth.gatt.ContextMap < T > . App entry = i.next ( ) ; if ( entry.uuid.equals ( uuid ) ) { entry.unlinkToDeath ( ) ; i.remove ( ) ; break ; } } } }

Target:
void remove ( int id ) { synchronized ( mApps ) { java.util.Iterator < com.android.bluetooth.gatt.ContextMap < T > . App > i = mApps.iterator ( ) ; while ( i.hasNext ( ) ) { com.android.bluetooth.gatt.ContextMap < T > . App entry = i.next ( ) ; if ( ( entry.id ) == id ) { entry.unlinkToDeath ( ) ; mScanStats.get ( entry.name ) . isRegistered = false ; i.remove ( ) ; break ; } } } }
Source:
void remove ( int id ) { synchronized ( mApps ) { java.util.Iterator < com.android.bluetooth.gatt.ContextMap < T > . App > i = mApps.iterator ( ) ; while ( i.hasNext ( ) ) { com.android.bluetooth.gatt.ContextMap < T > . App entry = i.next ( ) ; if ( ( entry.id ) == id ) { entry.unlinkToDeath ( ) ; i.remove ( ) ; break ; } } } }

Target:
void remove ( java.util.UUID uuid ) { synchronized ( mApps ) { java.util.Iterator < com.android.bluetooth.gatt.ContextMap < T > . App > i = mApps.iterator ( ) ; while ( i.hasNext ( ) ) { com.android.bluetooth.gatt.ContextMap < T > . App entry = i.next ( ) ; if ( entry.uuid.equals ( uuid ) ) { entry.unlinkToDeath ( ) ; mScanStats.get ( entry.name ) . isRegistered = false ; i.remove ( ) ; break ; } } } }
Source:
public long getNextScheduledStartTimeAfter ( long startTime ) { java.util.List < com.android.tv.dvr.ScheduledRecording > temp = getNonStartedScheduledRecordings ( ) ; java.util.Collections.sort ( temp , ScheduledRecording.START_TIME_COMPARATOR ) ; for ( com.android.tv.dvr.ScheduledRecording r : temp ) { if ( ( r.getStartTimeMs ( ) ) > startTime ) { return r.getStartTimeMs ( ) ; } } return DvrDataManager.NEXT_START_TIME_NOT_FOUND ; }

Target:
public long getNextScheduledStartTimeAfter ( long startTime ) { java.util.List < com.android.tv.dvr.data.ScheduledRecording > temp = getNonStartedScheduledRecordings ( ) ; java.util.Collections.sort ( temp , ScheduledRecording.START_TIME_COMPARATOR ) ; for ( com.android.tv.dvr.data.ScheduledRecording r : temp ) { if ( ( r.getStartTimeMs ( ) ) > startTime ) { return r.getStartTimeMs ( ) ; } } return DvrDataManager.NEXT_START_TIME_NOT_FOUND ; }
Source:
public void onError ( int code , java.lang.String message ) { if ( code == ( android.accounts.AccountManager.ERROR_CODE_CANCELED ) ) { cancel ( true ) ; return ; } setException ( convertErrorToException ( code , message ) ) ; }

Target:
public void onError ( int code , java.lang.String message ) { if ( ( ( code == ( android.accounts.AccountManager.ERROR_CODE_CANCELED ) ) || ( code == ( android.accounts.AccountManager.ERROR_CODE_USER_RESTRICTED ) ) ) || ( code == ( android.accounts.AccountManager.ERROR_CODE_MANAGEMENT_DISABLED_FOR_ACCOUNT_TYPE ) ) ) { cancel ( true ) ; return ; } setException ( convertErrorToException ( code , message ) ) ; }
Source:
public void onMessageSendFailed ( int messageId ) { android.os.Bundle mResults = new android.os.Bundle ( ) ; mResults.putInt ( "discoverySessionId" , mDiscoverySessionId ) ; mResults.putInt ( "messageId" , messageId ) ; synchronized ( mLock ) { java.lang.Long startTime = mMessageStartTime.get ( messageId ) ; if ( startTime != null ) { mResults.putLong ( "latencyMs" , ( ( java.lang.System.currentTimeMillis ( ) ) - ( startTime.longValue ( ) ) ) ) ; mMessageStartTime.remove ( messageId ) ; } } mEventFacade.postEvent ( "WifiNanSessionOnMessageSendFailed" , mResults ) ; }

Target:
public void onMessageSendFailed ( int messageId ) { android.os.Bundle mResults = new android.os.Bundle ( ) ; mResults.putInt ( "discoverySessionId" , mDiscoverySessionId ) ; mResults.putInt ( "messageId" , messageId ) ; synchronized ( mLock ) { java.lang.Long startTime = mMessageStartTime.get ( messageId ) ; if ( startTime != null ) { mResults.putLong ( "latencyMs" , ( ( java.lang.System.currentTimeMillis ( ) ) - ( startTime.longValue ( ) ) ) ) ; mMessageStartTime.remove ( messageId ) ; } } mEventFacade.postEvent ( "WifiAwareSessionOnMessageSendFailed" , mResults ) ; }
Source:
public void run ( ) { pair.execute ( new java.lang.Runnable ( ) { @ java.lang.Override public void run ( ) { pair.listener.terminated ( from ) ; } } ) ; }

Target:
private void terminated ( final com.google.common.util.concurrent.Service.State from ) { switch ( from ) { case NEW : com.google.common.util.concurrent.AbstractService.TERMINATED_FROM_NEW_CALLBACK.enqueueOn ( listeners ) ; break ; case RUNNING : com.google.common.util.concurrent.AbstractService.TERMINATED_FROM_RUNNING_CALLBACK.enqueueOn ( listeners ) ; break ; case STOPPING : com.google.common.util.concurrent.AbstractService.TERMINATED_FROM_STOPPING_CALLBACK.enqueueOn ( listeners ) ; break ; case STARTING : case TERMINATED : case FAILED : default : throw new java.lang.AssertionError ( ) ; } }
Source:
public void testConnectOverProxy_explicit_http_uses_direct_connection ( ) throws java.lang.Exception { byte [ ] fileContents = "abcdef 1234567890" . getBytes ( java.nio.charset.StandardCharsets.UTF_8 ) ; java.net.URL fileUrl = addFileEntry ( libcore.java.net.FtpURLConnectionTest.FILE_PATH , fileContents ) ; libcore.java.net.FtpURLConnectionTest.CountingProxy countingProxy = libcore.java.net.FtpURLConnectionTest.CountingProxy.start ( ) ; final int numConnections ; try { java.net.Proxy proxy = countingProxy.asProxy ( ) ; java.net.URLConnection connection = fileUrl.openConnection ( proxy ) ; libcore.java.net.FtpURLConnectionTest.assertContents ( fileContents , connection.getInputStream ( ) ) ; } finally { numConnections = countingProxy.shutdownAndGetConnectionCount ( ) ; } assertEquals ( 0 , numConnections ) ; }

Target:
public void testConnectOverProxy_explicit_http_uses_direct_connection ( ) throws java.lang.Exception { byte [ ] fileContents = "abcdef 1234567890" . getBytes ( java.nio.charset.StandardCharsets.UTF_8 ) ; java.net.URL fileUrl = addFileEntry ( libcore.java.net.FtpURLConnectionTest.FILE_PATH , fileContents ) ; libcore.java.net.FtpURLConnectionTest.CountingProxy countingProxy = libcore.java.net.FtpURLConnectionTest.CountingProxy.start ( ) ; try { java.net.Proxy proxy = countingProxy.asProxy ( ) ; java.net.URLConnection connection = fileUrl.openConnection ( proxy ) ; libcore.java.net.FtpURLConnectionTest.assertContents ( fileContents , connection.getInputStream ( ) ) ; countingProxy.waitAndAssertConnectionCount ( 0 ) ; } finally { countingProxy.shutdown ( ) ; } }
Source:
public boolean isSubTypeOf ( @ javax.annotation.Nonnull com.android.jack.ir.ast.JReferenceType jclass ) { if ( jclass instanceof com.android.jack.ir.ast.JClass ) { com.android.jack.ir.ast.JClass currentClass = this ; do { currentClass = ( ( com.android.jack.ir.ast.JDefinedClass ) ( currentClass ) ) . getSuperClass ( ) ; if ( jclass.equals ( currentClass ) ) { return true ; } } while ( currentClass instanceof com.android.jack.ir.ast.JDefinedClass ) ; } return false ; }

Target:
public boolean isSubTypeOf ( @ javax.annotation.Nonnull com.android.jack.ir.ast.JReferenceType jclass ) { if ( jclass instanceof com.android.jack.ir.ast.JClass ) { com.android.jack.ir.ast.JClass currentClass = this ; do { currentClass = ( ( com.android.jack.ir.ast.JDefinedClass ) ( currentClass ) ) . getSuperClass ( ) ; if ( ( currentClass != null ) && ( jclass.isSameType ( currentClass ) ) ) { return true ; } } while ( currentClass instanceof com.android.jack.ir.ast.JDefinedClass ) ; } return false ; }
Source:
public void testSecurityPatchFound ( ) { if ( mSkipTests ) { android.util.Log.w ( android.os.cts.SecurityPatchTest.TAG , "Skipping M+ Test." ) ; return ; } java.lang.String buildSecurityPatch = android.os.SystemProperties.get ( "ro.build.version.security_patch" , "" ) ; java.lang.String error = java.lang.String.format ( android.os.cts.SecurityPatchTest.SECURITY_PATCH_ERROR , buildSecurityPatch ) ; assertTrue ( error , ( ! ( buildSecurityPatch.isEmpty ( ) ) ) ) ; }

Target:
public void testSecurityPatchFound ( ) { if ( mSkipTests ) { android.util.Log.w ( android.os.cts.SecurityPatchTest.TAG , "Skipping M+ Test." ) ; return ; } java.lang.String buildSecurityPatch = Build.VERSION.SECURITY_PATCH ; java.lang.String error = java.lang.String.format ( android.os.cts.SecurityPatchTest.SECURITY_PATCH_ERROR , buildSecurityPatch ) ; assertTrue ( error , ( ! ( buildSecurityPatch.isEmpty ( ) ) ) ) ; }
Source:
private void verifyNorm ( ) throws java.lang.Throwable { float expectedMagneticFieldEarth = ( ( android.hardware.SensorManager.MAGNETIC_FIELD_EARTH_MAX ) + ( android.hardware.SensorManager.MAGNETIC_FIELD_EARTH_MIN ) ) / 2 ; float magneticFieldEarthThreshold = expectedMagneticFieldEarth - ( android.hardware.SensorManager.MAGNETIC_FIELD_EARTH_MIN ) ; android.hardware.cts.helpers.sensorTestOperations.VerifyMagnitudeOperation verifyNorm = new android.hardware.cts.helpers.sensorTestOperations.VerifyMagnitudeOperation ( this . getApplicationContext ( ) , android.hardware.Sensor.TYPE_MAGNETIC_FIELD , android.hardware.SensorManager.SENSOR_DELAY_FASTEST , expectedMagneticFieldEarth , magneticFieldEarthThreshold ) ; verifyNorm.execute ( ) ; logSuccess ( ) ; }

Target:
private void verifyNorm ( ) throws java.lang.Throwable { float expectedMagneticFieldEarth = ( ( android.hardware.SensorManager.MAGNETIC_FIELD_EARTH_MAX ) + ( android.hardware.SensorManager.MAGNETIC_FIELD_EARTH_MIN ) ) / 2 ; float magneticFieldEarthThreshold = expectedMagneticFieldEarth - ( android.hardware.SensorManager.MAGNETIC_FIELD_EARTH_MIN ) ; android.hardware.cts.helpers.sensorTestOperations.VerifySensorOperation verifyNorm = new android.hardware.cts.helpers.sensorTestOperations.VerifySensorOperation ( this . getApplicationContext ( ) , android.hardware.Sensor.TYPE_MAGNETIC_FIELD , android.hardware.SensorManager.SENSOR_DELAY_FASTEST , 0 , 100 ) ; verifyNorm.verifyMagnitude ( expectedMagneticFieldEarth , magneticFieldEarthThreshold ) ; verifyNorm.execute ( ) ; logSuccess ( ) ; }
Source:
public com.android.sdklib.devices.Screen deepCopy ( ) { com.android.sdklib.devices.Screen s = new com.android.sdklib.devices.Screen ( ) ; s.mScreenSize = mScreenSize ; s.mDiagonalLength = mDiagonalLength ; s.mPixelDensity = mPixelDensity ; s.mScreenRatio = mScreenRatio ; s.mXDimension = mXDimension ; s.mYDimension = mYDimension ; s.mXdpi = mXdpi ; s.mYdpi = mYdpi ; s.mMultitouch = mMultitouch ; s.mMechanism = mMechanism ; s.mScreenType = mScreenType ; return s ; }

Target:
public com.android.sdklib.devices.Screen deepCopy ( ) { com.android.sdklib.devices.Screen s = new com.android.sdklib.devices.Screen ( ) ; s.mScreenSize = mScreenSize ; s.mDiagonalLength = mDiagonalLength ; s.mPixelDensity = mPixelDensity ; s.mScreenRatio = mScreenRatio ; s.mXDimension = mXDimension ; s.mYDimension = mYDimension ; s.mXdpi = mXdpi ; s.mYdpi = mYdpi ; s.mMultitouch = mMultitouch ; s.mMechanism = mMechanism ; s.mScreenType = mScreenType ; s.mScreenRound = mScreenRound ; return s ; }
Source:
protected void setUp ( ) throws java.lang.Exception { super . setUp ( ) ; com.android.compatibility.common.tradefed.build.CompatibilityBuildHelper buildHelper = new com.android.compatibility.common.tradefed.build.CompatibilityBuildHelper ( mBuild ) ; sepolicyAnalyze = buildHelper.getTestFile ( "sepolicy-analyze" ) ; sepolicyAnalyze.setExecutable ( true ) ; devicePolicyFile = java.io.File.createTempFile ( "sepolicy" , ".tmp" ) ; devicePolicyFile.deleteOnExit ( ) ; mDevice.pullFile ( "/sys/fs/selinux/policy" , devicePolicyFile ) ; }

Target:
protected void setUp ( ) throws java.lang.Exception { super . setUp ( ) ; com.android.compatibility.common.tradefed.build.CompatibilityBuildHelper buildHelper = new com.android.compatibility.common.tradefed.build.CompatibilityBuildHelper ( mBuild ) ; sepolicyAnalyze = buildHelper.getTestFile ( "sepolicy-analyze" ) ; sepolicyAnalyze.setExecutable ( true ) ; devicePolicyFile = android.security.cts.SELinuxHostTest.getDevicePolicyFile ( mDevice ) ; }
Source:
private void setMood ( int moodId , int textId , boolean showTicker ) { java.lang.CharSequence text = getText ( textId ) ; java.lang.String tickerText = ( showTicker ) ? getString ( textId ) : null ; android.app.Notification notification = new android.app.Notification ( moodId , tickerText , java.lang.System.currentTimeMillis ( ) ) ; notification.setLatestEventInfo ( this , getText ( R.string.status_bar_notifications_mood_title ) , text , makeMoodIntent ( moodId ) ) ; mNotificationManager.notify ( R.layout.status_bar_notifications , notification ) ; }

Target:
private void setMood ( int moodId , int textId , boolean showTicker ) { java.lang.CharSequence text = getText ( textId ) ; java.lang.String tickerText = ( showTicker ) ? getString ( textId ) : null ; android.app.Notification notification = new android.app.Notification ( moodId , tickerText , java.lang.System.currentTimeMillis ( ) ) ; notification.setLatestEventInfo ( this , getText ( R.string.status_bar_notifications_mood_title ) , text , makeMoodIntent ( moodId ) ) ; mNotificationManager.notify ( com.example.android.apis.app.StatusBarNotifications.MOOD_NOTIFICATIONS , notification ) ; }
Source:
private void printBlockCommon ( @ javax.annotation.Nonnull com.android.jack.ir.ast.cfg.JRegularBasicBlock block ) { if ( block.hasPrimarySuccessor ( ) ) { print ( "; primary: " ) ; if ( ( ( cfgBlocks ) != null ) && ( cfgBlocks.containsKey ( block ) ) ) { print ( cfgBlocks.get ( block.getPrimarySuccessor ( ) ) ) ; } else { print ( "???" ) ; } } printBlockCommon ( ( ( com.android.jack.ir.ast.cfg.JBasicBlock ) ( block ) ) ) ; }

Target:
private void printBlockIds ( @ javax.annotation.Nonnull java.lang.Iterable < com.android.jack.ir.ast.cfg.JBasicBlock > blocks , @ javax.annotation.CheckForNull com.android.jack.ir.ast.cfg.JBasicBlock primary ) { print ( "{" ) ; java.lang.String sep = " " ; for ( com.android.jack.ir.ast.cfg.JBasicBlock block : blocks ) { print ( sep ) ; if ( ( ( cfgBlocks ) != null ) && ( cfgBlocks.containsKey ( block ) ) ) { print ( cfgBlocks.get ( block ) ) ; } else { print ( "???" ) ; } if ( block == primary ) { print ( "**" ) ; } sep = ", " ; } print ( " }" ) ; }
Source:
private void acceptConnections ( ) throws java.lang.Exception { while ( true ) { java.net.Socket socket ; try { socket = serverSocket.accept ( ) ; } catch ( java.net.SocketException e ) { return ; } final com.google.mockwebserver.SocketPolicy socketPolicy = dispatcher.peekSocketPolicy ( ) ; if ( socketPolicy == ( com.google.mockwebserver.SocketPolicy.DISCONNECT_AT_START ) ) { dispatchBookkeepingRequest ( 0 , socket ) ; socket.close ( ) ; } else { openClientSockets.put ( socket , true ) ; serveConnection ( socket ) ; } } }

Target:
private void acceptConnections ( ) throws java.lang.Exception { while ( true ) { java.net.Socket socket ; try { socket = serverSocket.accept ( ) ; } catch ( java.net.SocketException e ) { return ; } com.google.mockwebserver.SocketPolicy socketPolicy = dispatcher.peek ( ) . getSocketPolicy ( ) ; if ( socketPolicy == ( com.google.mockwebserver.SocketPolicy.DISCONNECT_AT_START ) ) { dispatchBookkeepingRequest ( 0 , socket ) ; socket.close ( ) ; } else { openClientSockets.put ( socket , true ) ; serveConnection ( socket ) ; } } }
Source:
static < OutputT > com.android.dialer.common.concurrent.UiListener < OutputT > create ( android.app.FragmentManager fragmentManager , java.lang.String taskId ) { @ java.lang.SuppressWarnings ( value = "unchecked" ) com.android.dialer.common.concurrent.UiListener < OutputT > uiListener = ( ( com.android.dialer.common.concurrent.UiListener < OutputT > ) ( fragmentManager.findFragmentByTag ( taskId ) ) ) ; if ( uiListener == null ) { com.android.dialer.common.LogUtil.i ( "UiListener.create" , ( "creating new UiListener for " + taskId ) ) ; uiListener = new com.android.dialer.common.concurrent.UiListener < > ( ) ; fragmentManager.beginTransaction ( ) . add ( uiListener , taskId ) . commit ( ) ; } return uiListener ; }

Target:
static < OutputT > com.android.dialer.common.concurrent.UiListener < OutputT > create ( android.app.FragmentManager fragmentManager , java.lang.String taskId ) { @ java.lang.SuppressWarnings ( value = "unchecked" ) com.android.dialer.common.concurrent.UiListener < OutputT > uiListener = ( ( com.android.dialer.common.concurrent.UiListener < OutputT > ) ( fragmentManager.findFragmentByTag ( taskId ) ) ) ; if ( uiListener == null ) { com.android.dialer.common.LogUtil.i ( "UiListener.create" , ( "creating new UiListener for " + taskId ) ) ; uiListener = new com.android.dialer.common.concurrent.UiListener < > ( ) ; fragmentManager.beginTransaction ( ) . add ( uiListener , taskId ) . commitAllowingStateLoss ( ) ; } return uiListener ; }
Source:
public static void connect ( java.io.FileDescriptor fd , java.net.InetAddress inetAddress , int port , int timeoutMs ) throws java.net.SocketException , java.net.SocketTimeoutException { try { libcore.io.IoBridge.connectErrno ( fd , inetAddress , port , timeoutMs ) ; } catch ( libcore.io.ErrnoException errnoException ) { throw new java.net.ConnectException ( libcore.io.IoBridge.connectDetail ( inetAddress , port , timeoutMs , errnoException ) , errnoException ) ; } catch ( java.net.SocketException ex ) { throw ex ; } catch ( java.net.SocketTimeoutException ex ) { throw ex ; } catch ( java.io.IOException ex ) { throw new java.net.SocketException ( ex ) ; } }

Target:
public static void connect ( java.io.FileDescriptor fd , java.net.InetAddress inetAddress , int port , int timeoutMs ) throws java.net.SocketException , java.net.SocketTimeoutException { try { libcore.io.IoBridge.connectErrno ( fd , inetAddress , port , timeoutMs ) ; } catch ( android.system.ErrnoException errnoException ) { throw new java.net.ConnectException ( libcore.io.IoBridge.connectDetail ( inetAddress , port , timeoutMs , errnoException ) , errnoException ) ; } catch ( java.net.SocketException ex ) { throw ex ; } catch ( java.net.SocketTimeoutException ex ) { throw ex ; } catch ( java.io.IOException ex ) { throw new java.net.SocketException ( ex ) ; } }
Source:
public java.nio.charset.CoderResult call ( com.ibm.icu.charset.CharsetEncoderICU encoder , java.lang.Object context , java.nio.CharBuffer source , java.nio.ByteBuffer target , java.nio.IntBuffer offsets , char [ ] buffer , int length , int cp , java.nio.charset.CoderResult cr ) { if ( context == null ) { return java.nio.charset.CoderResult.UNDERFLOW ; } else if ( ( ( java.lang.String ) ( context ) ) . equals ( com.ibm.icu.charset.CharsetCallback.SUB_STOP_ON_ILLEGAL ) ) { if ( ! ( cr.isUnmappable ( ) ) ) { return cr ; } else { return java.nio.charset.CoderResult.UNDERFLOW ; } } return cr ; }

Target:
public java.nio.charset.CoderResult call ( com.ibm.icu.charset.CharsetDecoderICU decoder , java.lang.Object context , java.nio.ByteBuffer source , java.nio.CharBuffer target , java.nio.IntBuffer offsets , char [ ] buffer , int length , java.nio.charset.CoderResult cr ) { if ( context == null ) { return java.nio.charset.CoderResult.UNDERFLOW ; } else if ( ( ( java.lang.String ) ( context ) ) . equals ( com.ibm.icu.charset.CharsetCallback.SUB_STOP_ON_ILLEGAL ) ) { if ( ! ( cr.isUnmappable ( ) ) ) { return cr ; } else { return java.nio.charset.CoderResult.UNDERFLOW ; } } return cr ; }
Source:
private int getParameterSize ( @ javax.annotation.Nonnull com.android.jack.ir.ast.JMethod method ) { int paramSize = 0 ; if ( ! ( method.isStatic ( ) ) ) { paramSize += 1 ; } for ( com.android.jack.ir.ast.JParameter param : method.getParams ( ) ) { if ( ( ( param.getType ( ) ) == ( JPrimitiveTypeEnum.LONG.getType ( ) ) ) || ( ( param.getType ( ) ) == ( JPrimitiveTypeEnum.DOUBLE.getType ( ) ) ) ) { paramSize += 2 ; } else { paramSize += 1 ; } } return paramSize ; }

Target:
private int getParameterWordCount ( @ javax.annotation.Nonnull com.android.jack.ir.ast.JMethod method ) { int wordCount = ( method.isStatic ( ) ) ? 0 : Type.OBJECT.getWordCount ( ) ; for ( com.android.jack.ir.ast.JParameter param : method.getParams ( ) ) { wordCount += com.android.jack.backend.dex.rop.RopHelper.convertTypeToDx ( param.getType ( ) ) . getWordCount ( ) ; } return wordCount ; }
Source:
public void testGet1_IndexOutOfBoundsException ( ) { try { java.util.concurrent.CopyOnWriteArrayList c = new java.util.concurrent.CopyOnWriteArrayList ( ) ; c.get ( ( - 1 ) ) ; shouldThrow ( ) ; } catch ( java.lang.IndexOutOfBoundsException success ) { } }

Target:
public void testSubList3_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.subList ( ( ( list.size ( ) ) - 1 ) , 1 ) ; shouldThrow ( ) ; } catch ( java.lang.IndexOutOfBoundsException success ) { } } }
Source:
public void simRefresh ( int var1 , android.hardware.radio.V1_0.SimRefreshResult var2 ) { }

Target:
public void simRefresh ( int indicationType , android.hardware.radio.V1_0.SimRefreshResult refreshResult ) { mRil.processIndication ( indicationType ) ; com.android.internal.telephony.uicc.IccRefreshResponse response = new com.android.internal.telephony.uicc.IccRefreshResponse ( ) ; response.refreshResult = refreshResult.type ; response.efId = refreshResult.efId ; response.aid = refreshResult.aid ; if ( RIL.RILJ_LOGD ) mRil.unsljLogRet ( com.android.internal.telephony.RILConstants.RIL_UNSOL_SIM_REFRESH , response ) ; if ( ( mRil.mIccRefreshRegistrants ) != null ) { mRil.mIccRefreshRegistrants.notifyRegistrants ( new android.os.AsyncResult ( null , response , null ) ) ; } }
Source:
public java.nio.IntBuffer put ( java.nio.IntBuffer src ) { if ( src == ( this ) ) { throw new java.lang.IllegalArgumentException ( ) ; } if ( ( src.remaining ( ) ) > ( remaining ( ) ) ) { throw new java.nio.BufferOverflowException ( ) ; } int [ ] contents = new int [ src.remaining ( ) ] ; src.get ( contents ) ; put ( contents ) ; return this ; }

Target:
public java.nio.IntBuffer put ( java.nio.IntBuffer src ) { if ( src == ( this ) ) { throw new java.lang.IllegalArgumentException ( "src == this" ) ; } if ( ( src.remaining ( ) ) > ( remaining ( ) ) ) { throw new java.nio.BufferOverflowException ( ) ; } int [ ] contents = new int [ src.remaining ( ) ] ; src.get ( contents ) ; put ( contents ) ; return this ; }
Source:
public void testVariantLevelAbiFilter ( ) { com.android.build.VariantOutput match ; java.util.List < com.android.build.VariantOutput > list = com.google.common.collect.Lists.newArrayList ( ) ; list.add ( ( match = com.android.ide.common.build.SplitOutputMatcherTest.getUniversalOutput ( 1 ) ) ) ; java.util.List < java.io.File > result = com.android.ide.common.build.SplitOutputMatcherTest.computeBestOutput ( list , com.google.common.collect.Sets.newHashSet ( "bar" , "foo" ) , 160 , "foo" , "zzz" ) ; assertEquals ( 1 , result.size ( ) ) ; assertEquals ( match.getMainOutputFile ( ) . getOutputFile ( ) , result.get ( 0 ) ) ; }

Target:
public void testVariantLevelAbiFilter ( ) { com.android.build.VariantOutput match ; java.util.List < com.android.build.VariantOutput > list = com.google.common.collect.Lists.newArrayList ( ) ; list.add ( ( match = com.android.ide.common.build.SplitOutputMatcherTest.getUniversalOutput ( 1 ) ) ) ; java.util.List < com.android.build.OutputFile > result = com.android.ide.common.build.SplitOutputMatcherTest.computeBestOutput ( list , com.google.common.collect.Sets.newHashSet ( "bar" , "foo" ) , 160 , "foo" , "zzz" ) ; assertEquals ( 1 , result.size ( ) ) ; assertEquals ( match.getMainOutputFile ( ) , result.get ( 0 ) ) ; }
Source:
public void onServiceConnected ( android.content.ComponentName className , android.bluetooth.IBinder service ) { if ( android.bluetooth.BluetoothMap.DBG ) android.bluetooth.BluetoothMap.log ( "Proxy object connected" ) ; mService = IBluetoothMap.Stub.asInterface ( service ) ; if ( ( mServiceListener ) != null ) { mServiceListener.onServiceConnected ( BluetoothProfile.MAP , this ) ; } }

Target:
public void onServiceConnected ( android.content.ComponentName className , android.os.IBinder service ) { if ( android.bluetooth.BluetoothMap.DBG ) android.bluetooth.BluetoothMap.log ( "Proxy object connected" ) ; mService = IBluetoothMap.Stub.asInterface ( android.os.Binder.allowBlocking ( service ) ) ; if ( ( mServiceListener ) != null ) { mServiceListener.onServiceConnected ( BluetoothProfile.MAP , this ) ; } }
Source:
private void setPhonesDialConnection ( com.android.internal.telephony.Phone phone , com.android.internal.telephony.Connection c ) { try { org.mockito.Mockito.when ( phone.dial ( org.mockito.ArgumentMatchers.anyString ( ) , org.mockito.ArgumentMatchers.anyInt ( ) ) ) . thenReturn ( c ) ; } catch ( com.android.internal.telephony.CallStateException e ) { junit.framework.Assert.fail ( ) ; } }

Target:
private void setPhonesDialConnection ( com.android.internal.telephony.Phone phone , com.android.internal.telephony.Connection c ) { try { org.mockito.Mockito.when ( phone.dial ( org.mockito.ArgumentMatchers.anyString ( ) , org.mockito.ArgumentMatchers.any ( ) ) ) . thenReturn ( c ) ; } catch ( com.android.internal.telephony.CallStateException e ) { junit.framework.Assert.fail ( ) ; } }
Source:
public void testMergedResourcesByName ( ) throws java.lang.Exception { com.android.ide.common.res2.ResourceMerger merger = com.android.ide.common.res2.ResourceMergerTest.getResourceMerger ( ) ; verifyResourceExists ( merger , "drawable/icon" , "drawable-ldpi/icon" , "drawable/icon2" , "drawable/patch" , "raw/foo" , "layout/main" , "layout/layout_ref" , "layout/alias_replaced_by_file" , "layout/file_replaced_by_alias" , "drawable/color_drawable" , "drawable/drawable_ref" , "color/color" , "string/basic_string" , "string/xliff_string" , "string/styled_string" , "style/style" , "array/string_array" , "attr/dimen_attr" , "attr/string_attr" , "attr/enum_attr" , "attr/flag_attr" , "attr/blah" , "attr/blah2" , "attr/flagAttr" , "declare-styleable/declare_styleable" , "dimen/dimen" , "id/item_id" , "integer/integer" ) ; }

Target:
public void testMergedResourcesByName ( ) throws java.lang.Exception { com.android.ide.common.res2.ResourceMerger merger = com.android.ide.common.res2.ResourceMergerTest.getResourceMerger ( ) ; verifyResourceExists ( merger , "drawable/icon" , "drawable-ldpi/icon" , "drawable/icon2" , "drawable/patch" , "raw/foo" , "layout/main" , "layout/layout_ref" , "layout/alias_replaced_by_file" , "layout/file_replaced_by_alias" , "drawable/color_drawable" , "drawable/drawable_ref" , "color/color" , "string/basic_string" , "string/xliff_string" , "string/xliff_with_carriage_return" , "string/styled_string" , "style/style" , "array/string_array" , "attr/dimen_attr" , "attr/string_attr" , "attr/enum_attr" , "attr/flag_attr" , "attr/blah" , "attr/blah2" , "attr/flagAttr" , "declare-styleable/declare_styleable" , "dimen/dimen" , "id/item_id" , "integer/integer" ) ; }
Source:
public void adjustLocalOrRemoteStreamVolume ( int streamType , int direction , java.lang.String callingPackage ) { if ( android.media.AudioService.DEBUG_VOL ) android.util.Log.d ( android.media.AudioService.TAG , ( ( "adjustLocalOrRemoteStreamVolume(dir=" + direction ) + ")" ) ) ; if ( android.media.AudioSystem.isStreamActive ( AudioSystem.STREAM_MUSIC , 0 ) ) { adjustStreamVolume ( AudioSystem.STREAM_MUSIC , direction , 0 , callingPackage ) ; } else if ( mMediaFocusControl.checkUpdateRemoteStateIfActive ( AudioSystem.STREAM_MUSIC ) ) { mMediaFocusControl.adjustRemoteVolume ( AudioSystem.STREAM_MUSIC , direction , 0 ) ; } }

Target:
public void adjustStreamVolume ( int streamType , int direction , int flags , java.lang.String callingPackage ) { adjustStreamVolume ( streamType , direction , flags , callingPackage , android.os.Binder.getCallingUid ( ) ) ; }
Source:
private void verifyRaLifetime ( android.net.apf.ApfTest.TestApfFilter apfFilter , android.net.apf.ApfTest.MockIpManagerCallback ipManagerCallback , java.nio.ByteBuffer packet , int lifetime ) throws android.system.ErrnoException , java.io.IOException { ipManagerCallback.resetApfProgramWait ( ) ; apfFilter.pretendPacketReceived ( packet.array ( ) ) ; byte [ ] program = ipManagerCallback.getApfProgram ( ) ; verifyRaLifetime ( program , packet , lifetime ) ; }

Target:
private void verifyRaLifetime ( android.net.apf.ApfTest.TestApfFilter apfFilter , android.net.apf.ApfTest.MockIpClientCallback ipClientCallback , java.nio.ByteBuffer packet , int lifetime ) throws android.system.ErrnoException , java.io.IOException { ipClientCallback.resetApfProgramWait ( ) ; apfFilter.pretendPacketReceived ( packet.array ( ) ) ; byte [ ] program = ipClientCallback.getApfProgram ( ) ; verifyRaLifetime ( program , packet , lifetime ) ; }
Source:
private boolean writePackageStatusWithOptimisticLockCheck ( int optimisticLockId , int newOptimisticLockId , java.lang.Integer status , com.android.server.timezone.PackageVersions packageVersions ) throws java.io.IOException { int currentOptimisticLockId ; try { currentOptimisticLockId = getCurrentOptimisticLockId ( ) ; if ( currentOptimisticLockId != optimisticLockId ) { return false ; } } catch ( java.text.ParseException e ) { recoverFromBadData ( e ) ; return false ; } writePackageStatusInternal ( status , newOptimisticLockId , packageVersions ) ; return true ; }

Target:
private boolean writePackageStatusWithOptimisticLockCheck ( int optimisticLockId , int newOptimisticLockId , java.lang.Integer status , com.android.server.timezone.PackageVersions packageVersions ) throws java.io.IOException { int currentOptimisticLockId ; try { currentOptimisticLockId = getCurrentOptimisticLockId ( ) ; if ( currentOptimisticLockId != optimisticLockId ) { return false ; } } catch ( java.text.ParseException e ) { recoverFromBadData ( e ) ; return false ; } writePackageStatusLocked ( status , newOptimisticLockId , packageVersions ) ; return true ; }
Source:
public org.chromium.mojo.system.impl.WaitResult wait ( org.chromium.mojo.system.Handle handle , org.chromium.mojo.system.impl.HandleSignals signals , long deadline ) { java.nio.ByteBuffer buffer = allocateDirectBuffer ( 8 ) ; org.chromium.mojo.system.impl.WaitResult result = new org.chromium.mojo.system.impl.WaitResult ( ) ; result.setMojoResult ( org.chromium.mojo.system.impl.CoreImpl.filterMojoResultForWait ( nativeWait ( buffer , getMojoHandle ( handle ) , signals.getFlags ( ) , deadline ) ) ) ; org.chromium.mojo.system.impl.HandleSignalsState signalsState = new org.chromium.mojo.system.impl.HandleSignalsState ( new org.chromium.mojo.system.impl.HandleSignals ( buffer.getInt ( 0 ) ) , new org.chromium.mojo.system.impl.HandleSignals ( buffer.getInt ( 4 ) ) ) ; result.setHandleSignalsState ( signalsState ) ; return result ; }

Target:
org.chromium.mojo.system.Core.HandleSignalsState queryHandleSignalsState ( int mojoHandle ) { java.nio.ByteBuffer buffer = allocateDirectBuffer ( 8 ) ; int result = nativeQueryHandleSignalsState ( mojoHandle , buffer ) ; if ( result != ( org.chromium.mojo.system.MojoResult.OK ) ) throw new org.chromium.mojo.system.MojoException ( result ) ; return new org.chromium.mojo.system.Core.HandleSignalsState ( new org.chromium.mojo.system.impl.HandleSignals ( buffer.getInt ( 0 ) ) , new org.chromium.mojo.system.impl.HandleSignals ( buffer.getInt ( 4 ) ) ) ; }
Source:
public void testCipherInputStream_TruncatedInput_Failure ( ) throws java.lang.Exception { javax.crypto.Cipher cipher = javax.crypto.Cipher.getInstance ( "AES/CBC/PKCS5Padding" ) ; cipher.init ( javax.crypto.Cipher.DECRYPT_MODE , new javax.crypto.spec.SecretKeySpec ( new byte [ 16 ] , "AES" ) , new javax.crypto.spec.IvParameterSpec ( new byte [ 16 ] ) ) ; java.io.InputStream is = new javax.crypto.CipherInputStream ( new java.io.ByteArrayInputStream ( new byte [ 31 ] ) , cipher ) ; is.read ( new byte [ 4 ] ) ; is.close ( ) ; }

Target:
public void testSkip ( ) throws java.lang.Exception { javax.crypto.Cipher cipher = javax.crypto.Cipher.getInstance ( "AES/CBC/PKCS5Padding" ) ; cipher.init ( javax.crypto.Cipher.DECRYPT_MODE , key , iv ) ; java.io.InputStream in = new javax.crypto.CipherInputStream ( new java.io.ByteArrayInputStream ( aesCipherText ) , cipher ) ; assertTrue ( ( ( in.skip ( 5 ) ) >= 0 ) ) ; }
Source:
protected boolean start ( ) { mPanDevices = new java.util.HashMap < android.bluetooth.BluetoothDevice , com.android.bluetooth.pan.PanService.BluetoothPanDevice > ( ) ; mBluetoothIfaceAddresses = new java.util.ArrayList < java.lang.String > ( ) ; try { mMaxPanDevices = getResources ( ) . getInteger ( com.android.internal.R.integer.config_max_pan_devices ) ; } catch ( android.content.res.Resources.NotFoundException e ) { mMaxPanDevices = com.android.bluetooth.pan.PanService.BLUETOOTH_MAX_PAN_CONNECTIONS ; } initializeNative ( ) ; mNativeAvailable = true ; mNetworkFactory = new com.android.bluetooth.pan.BluetoothTetheringNetworkFactory ( getBaseContext ( ) , getMainLooper ( ) , this ) ; return true ; }

Target:
protected boolean start ( ) { mPanDevices = new java.util.HashMap < android.bluetooth.BluetoothDevice , com.android.bluetooth.pan.PanService.BluetoothPanDevice > ( ) ; mBluetoothIfaceAddresses = new java.util.ArrayList < java.lang.String > ( ) ; try { mMaxPanDevices = getResources ( ) . getInteger ( com.android.internal.R.integer.config_max_pan_devices ) ; } catch ( android.content.res.Resources.NotFoundException e ) { mMaxPanDevices = com.android.bluetooth.pan.PanService.BLUETOOTH_MAX_PAN_CONNECTIONS ; } initializeNative ( ) ; mNativeAvailable = true ; mNetworkFactory = new com.android.bluetooth.pan.BluetoothTetheringNetworkFactory ( getBaseContext ( ) , getMainLooper ( ) , this ) ; com.android.bluetooth.pan.PanService.setPanService ( this ) ; return true ; }
Source:
public void onConfigurationChanged ( android.content.res.Configuration newConfig ) { synchronized ( mPackages ) { if ( applyConfigurationToResourcesLocked ( newConfig , null ) ) { if ( ( ( mPendingConfiguration ) == null ) || ( mPendingConfiguration.isOtherSeqNewer ( newConfig ) ) ) { mPendingConfiguration = newConfig ; queueOrSendMessage ( android.app.ActivityThread.H.CONFIGURATION_CHANGED , newConfig ) ; } } } }

Target:
public void onConfigurationChanged ( android.content.res.Configuration newConfig ) { synchronized ( mResourcesManager ) { if ( mResourcesManager.applyConfigurationToResourcesLocked ( newConfig , null ) ) { if ( ( ( mPendingConfiguration ) == null ) || ( mPendingConfiguration.isOtherSeqNewer ( newConfig ) ) ) { mPendingConfiguration = newConfig ; sendMessage ( android.app.ActivityThread.H.CONFIGURATION_CHANGED , newConfig ) ; } } } }
Source:
public void onReceivedError ( int errorCode , java.lang.String description , java.lang.String failingUrl ) { if ( ( description == null ) || ( description.isEmpty ( ) ) ) { description = android.net.http.ErrorStrings.getString ( errorCode , mWebView.getContext ( ) ) ; } org.chromium.content.common.TraceEvent.begin ( ) ; if ( com.android.webview.chromium.WebViewContentsClientAdapter.TRACE ) android.util.Log.d ( com.android.webview.chromium.WebViewContentsClientAdapter.TAG , ( "onReceivedError=" + failingUrl ) ) ; mWebViewClient.onReceivedError ( mWebView , errorCode , description , failingUrl ) ; org.chromium.content.common.TraceEvent.end ( ) ; }

Target:
public void onReceivedError ( int errorCode , java.lang.String description , java.lang.String failingUrl ) { if ( ( description == null ) || ( description.isEmpty ( ) ) ) { description = android.net.http.ErrorStrings.getString ( errorCode , mWebView.getContext ( ) ) ; } org.chromium.base.TraceEvent.begin ( ) ; if ( com.android.webview.chromium.WebViewContentsClientAdapter.TRACE ) android.util.Log.d ( com.android.webview.chromium.WebViewContentsClientAdapter.TAG , ( "onReceivedError=" + failingUrl ) ) ; mWebViewClient.onReceivedError ( mWebView , errorCode , description , failingUrl ) ; org.chromium.base.TraceEvent.end ( ) ; }
Source:
public java.util.Iterator < com.android.sched.vfs.InputVFile > iterator ( @ javax.annotation.Nonnull com.android.jack.library.FileType fileType ) { if ( ! ( containsFileType ( fileType ) ) ) { return com.google.common.collect.Iterators.emptyIterator ( ) ; } if ( fileType == ( com.android.jack.library.FileType.RSC ) ) { return resources.iterator ( ) ; } java.util.List < com.android.sched.vfs.InputVFile > inputVFiles = new java.util.ArrayList < com.android.sched.vfs.InputVFile > ( ) ; fillFiles ( inputVFS.getRootInputVDir ( ) , fileType , inputVFiles ) ; return inputVFiles.iterator ( ) ; }

Target:
public java.util.Iterator < com.android.sched.vfs.InputVFile > iterator ( @ javax.annotation.Nonnull com.android.jack.library.FileType fileType ) { if ( ! ( containsFileType ( fileType ) ) ) { return com.google.common.collect.ImmutableSet.< com.android.sched.vfs.InputVFile > of ( ) . iterator ( ) ; } if ( fileType == ( com.android.jack.library.FileType.RSC ) ) { return resources.iterator ( ) ; } java.util.List < com.android.sched.vfs.InputVFile > inputVFiles = new java.util.ArrayList < com.android.sched.vfs.InputVFile > ( ) ; fillFiles ( inputVFS.getRootInputVDir ( ) , fileType , inputVFiles ) ; return inputVFiles.iterator ( ) ; }
Source:
private com.android.jack.ir.ast.JDefinedClass checkAndInitializeSyntheticClass ( java.lang.String syntheticClassFullName ) { com.android.jack.ir.ast.JDefinedClass syntheticClass ; try { syntheticClass = supportUtil.getLookup ( ) . getClass ( syntheticClassFullName ) ; throw new java.lang.AssertionError ( ( "Duplicated initialize synthetic switch map class: " + syntheticClass ) ) ; } catch ( com.android.jack.ir.ast.JPackageLookupException e ) { syntheticClass = initializeSyntheticClass ( syntheticClassFullName ) ; } catch ( com.android.jack.ir.ast.JTypeLookupException e ) { syntheticClass = initializeSyntheticClass ( syntheticClassFullName ) ; } return syntheticClass ; }

Target:
private com.android.jack.ir.ast.JDefinedClass checkAndInitializeSyntheticClass ( @ javax.annotation.Nonnull com.android.jack.ir.ast.JPackage enclosingPackage , @ javax.annotation.Nonnull java.lang.String syntheticClassShortName ) { com.android.jack.ir.ast.JDefinedClass syntheticClass = null ; boolean needSyntheticClass = false ; try { syntheticClass = ( ( com.android.jack.ir.ast.JDefinedClass ) ( enclosingPackage.getType ( syntheticClassShortName ) ) ) ; if ( ( syntheticClass.getLocation ( ) ) instanceof com.android.jack.library.TypeInInputLibraryLocation ) { needSyntheticClass = true ; } } catch ( com.android.jack.ir.ast.JTypeLookupException e ) { needSyntheticClass = true ; } if ( needSyntheticClass ) { syntheticClass = initializeSyntheticClass ( enclosingPackage , syntheticClassShortName ) ; } assert syntheticClass != null ; return syntheticClass ; }
Source:
public void onSeparate ( android.telecom.Connection connection ) { com.android.dialer.common.LogUtil.i ( "SimulatorConference.onSeparate" , ( "connection: " + connection ) ) ; onEvent ( new com.android.dialer.simulator.Simulator.Event ( com.android.dialer.simulator.Simulator.Event.SEPARATE , com.android.dialer.simulator.impl.SimulatorSimCallManager.getConnectionTag ( connection ) , null ) ) ; }

Target:
public void onSeparate ( android.telecom.Connection connection ) { com.android.dialer.common.LogUtil.i ( "SimulatorConference.onSeparate" , ( "connection: " + connection ) ) ; onEvent ( new com.android.dialer.simulator.Simulator.Event ( com.android.dialer.simulator.Simulator.Event.SEPARATE , com.android.dialer.simulator.impl.SimulatorSimCallManager.getConnectionTag ( connection ) , null ) ) ; if ( ( ( conferenceType ) == ( com.android.dialer.simulator.Simulator.CONFERENCE_TYPE_GSM ) ) && ( ( getConnections ( ) . size ( ) ) == 1 ) ) { removeConnection ( getConnections ( ) . get ( 0 ) ) ; destroy ( ) ; } }
Source:
public java.util.List < java.io.File > getJavaSourceFolders ( ) { if ( ( mJavaSourceFolders ) == null ) { if ( com.android.tools.lint.detector.api.Project.isAospFrameworksProject ( mDir ) ) { return java.util.Collections.singletonList ( new java.io.File ( mDir , "java" ) ) ; } if ( com.android.tools.lint.detector.api.Project.isAospBuildEnvironment ( ) ) { java.lang.String top = com.android.tools.lint.detector.api.Project.getAospTop ( ) ; if ( mDir.getAbsolutePath ( ) . startsWith ( top ) ) { mJavaSourceFolders = getAospJavaSourcePath ( ) ; return mJavaSourceFolders ; } } mJavaSourceFolders = mClient.getJavaSourceFolders ( this ) ; } return mJavaSourceFolders ; }

Target:
public java.util.List < java.io.File > getJavaSourceFolders ( ) { if ( ( mJavaSourceFolders ) == null ) { if ( com.android.tools.lint.detector.api.Project.isAospFrameworksRelatedProject ( mDir ) ) { return java.util.Collections.singletonList ( new java.io.File ( mDir , "java" ) ) ; } if ( com.android.tools.lint.detector.api.Project.isAospBuildEnvironment ( ) ) { java.lang.String top = com.android.tools.lint.detector.api.Project.getAospTop ( ) ; if ( mDir.getAbsolutePath ( ) . startsWith ( top ) ) { mJavaSourceFolders = getAospJavaSourcePath ( ) ; return mJavaSourceFolders ; } } mJavaSourceFolders = mClient.getJavaSourceFolders ( this ) ; } return mJavaSourceFolders ; }
Source:
public void TestFormatUseAppendToAsPlaceholder ( ) { com.ibm.icu.impl.SimplePatternFormatter fmt = com.ibm.icu.impl.SimplePatternFormatter.compile ( "Placeholders {0} and {1}" ) ; java.lang.StringBuilder appendTo = new java.lang.StringBuilder ( "previous:" ) ; try { fmt.formatAndAppend ( appendTo , null , appendTo , "frog" ) ; fail ( "IllegalArgumentException expected." ) ; } catch ( java.lang.IllegalArgumentException e ) { } }

Target:
public void TestFormatUseAppendToAsArgument ( ) { com.ibm.icu.text.SimpleFormatter fmt = com.ibm.icu.text.SimpleFormatter.compile ( "Arguments {0} and {1}" ) ; java.lang.StringBuilder appendTo = new java.lang.StringBuilder ( "previous:" ) ; try { fmt.formatAndAppend ( appendTo , null , appendTo , "frog" ) ; fail ( "IllegalArgumentException expected." ) ; } catch ( java.lang.IllegalArgumentException e ) { } }
Source:
public void onMessageWaitingIndicatorChanged ( boolean visible ) { if ( com.android.phone.CallNotifier.VDBG ) log ( ( ( ( "onMessageWaitingIndicatorChanged(): " + ( this . mSubId ) ) + " " ) + visible ) ) ; mApplication.notificationMgr.updateMwi ( this . mSubId , visible ) ; }

Target:
public void onCallForwardingIndicatorChanged ( boolean visible ) { android.util.Log.i ( com.android.phone.CallNotifier.LOG_TAG , ( ( ( "onCallForwardingIndicatorChanged(): subId=" + ( this . mSubId ) ) + ", visible=" ) + ( visible ? "Y" : "N" ) ) ) ; mCFIStatus.put ( this . mSubId , visible ) ; updatePhoneStateListeners ( false ) ; }
Source:
public void registerMediaButtonIntent ( android.app.PendingIntent pi , android.content.ComponentName eventReceiver ) { if ( pi == null ) { android.util.Log.e ( android.media.AudioManager.TAG , "Cannot call registerMediaButtonIntent() with a null parameter" ) ; return ; } android.media.session.MediaSessionLegacyHelper helper = android.media.session.MediaSessionLegacyHelper.getHelper ( mApplicationContext ) ; helper.addMediaButtonListener ( pi , eventReceiver , mApplicationContext ) ; }

Target:
public void registerMediaButtonIntent ( android.app.PendingIntent pi , android.content.ComponentName eventReceiver ) { if ( pi == null ) { android.util.Log.e ( android.media.AudioManager.TAG , "Cannot call registerMediaButtonIntent() with a null parameter" ) ; return ; } android.media.session.MediaSessionLegacyHelper helper = android.media.session.MediaSessionLegacyHelper.getHelper ( getContext ( ) ) ; helper.addMediaButtonListener ( pi , eventReceiver , getContext ( ) ) ; }
Source:
protected boolean stop ( ) { return true ; }

Target:
protected boolean stop ( ) { if ( ( mHandler ) != null ) { mHandler.removeCallbacksAndMessages ( null ) ; android.os.Looper looper = mHandler.getLooper ( ) ; if ( looper != null ) { looper.quit ( ) ; } } resetRemoteData ( ) ; return true ; }
Source:
static boolean deleteAllTypesForAlias ( android.security.KeyStore keystore , java.lang.String alias ) { return ( keystore.delKey ( ( ( android.security.Credentials.USER_PRIVATE_KEY ) + alias ) ) ) | ( android.security.Credentials.deleteCertificateTypesForAlias ( keystore , alias ) ) ; }

Target:
static boolean deleteAllTypesForAlias ( android.security.KeyStore keystore , java.lang.String alias ) { return ( ( keystore.delete ( ( ( android.security.Credentials.USER_PRIVATE_KEY ) + alias ) ) ) | ( keystore.delete ( ( ( android.security.Credentials.USER_SECRET_KEY ) + alias ) ) ) ) | ( android.security.Credentials.deleteCertificateTypesForAlias ( keystore , alias ) ) ; }
Source:
public java.lang.String getVisualVoicemailPackageName ( java.lang.String callingPackage , int subId ) { mAppOps.checkPackage ( android.os.Binder.getCallingUid ( ) , callingPackage ) ; if ( ! ( canReadPhoneState ( callingPackage , "getVisualVoicemailPackageName" ) ) ) { return null ; } return com.android.phone.vvm.RemoteVvmTaskManager.getRemotePackage ( mPhone.getContext ( ) , subId ) . getPackageName ( ) ; }

Target:
public java.lang.String getCdmaEriTextForSubscriber ( int subId , java.lang.String callingPackage ) { if ( ! ( com.android.internal.telephony.TelephonyPermissions.checkCallingOrSelfReadPhoneState ( mApp , callingPackage , "getCdmaEriIconTextForSubscriber" ) ) ) { return null ; } final com.android.internal.telephony.Phone phone = getPhone ( subId ) ; if ( phone != null ) { return phone.getCdmaEriText ( ) ; } else { return null ; } }
Source:
private static android.content.ContentValues createCarrierInfoInternal ( ) { android.content.ContentValues contentValues = new android.content.ContentValues ( ) ; contentValues.put ( CarrierIdProvider.MCCMNC , com.android.providers.telephony.CarrierIdProviderTest.dummy_mccmnc ) ; contentValues.put ( CarrierIdProvider.GID1 , com.android.providers.telephony.CarrierIdProviderTest.dummy_gid1 ) ; contentValues.put ( CarrierIdProvider.GID2 , com.android.providers.telephony.CarrierIdProviderTest.dummy_gid2 ) ; contentValues.put ( CarrierIdProvider.PLMN , com.android.providers.telephony.CarrierIdProviderTest.dummy_plmn ) ; contentValues.put ( CarrierIdProvider.IMSI_PREFIX , com.android.providers.telephony.CarrierIdProviderTest.dummy_imsi_prefix ) ; contentValues.put ( CarrierIdProvider.SPN , com.android.providers.telephony.CarrierIdProviderTest.dummy_spn ) ; contentValues.put ( CarrierIdProvider.APN , com.android.providers.telephony.CarrierIdProviderTest.dummy_apn ) ; contentValues.put ( CarrierIdProvider.NAME , com.android.providers.telephony.CarrierIdProviderTest.dummy_name ) ; contentValues.put ( CarrierIdProvider.CID , com.android.providers.telephony.CarrierIdProviderTest.dummy_cid ) ; return contentValues ; }

Target:
private static android.content.ContentValues createCarrierInfoInternal ( ) { android.content.ContentValues contentValues = new android.content.ContentValues ( ) ; contentValues.put ( CarrierIdentification.MCCMNC , com.android.providers.telephony.CarrierIdProviderTest.dummy_mccmnc ) ; contentValues.put ( CarrierIdentification.GID1 , com.android.providers.telephony.CarrierIdProviderTest.dummy_gid1 ) ; contentValues.put ( CarrierIdentification.GID2 , com.android.providers.telephony.CarrierIdProviderTest.dummy_gid2 ) ; contentValues.put ( CarrierIdentification.PLMN , com.android.providers.telephony.CarrierIdProviderTest.dummy_plmn ) ; contentValues.put ( CarrierIdentification.IMSI_PREFIX_XPATTERN , com.android.providers.telephony.CarrierIdProviderTest.dummy_imsi_prefix ) ; contentValues.put ( CarrierIdentification.SPN , com.android.providers.telephony.CarrierIdProviderTest.dummy_spn ) ; contentValues.put ( CarrierIdentification.APN , com.android.providers.telephony.CarrierIdProviderTest.dummy_apn ) ; contentValues.put ( CarrierIdentification.NAME , com.android.providers.telephony.CarrierIdProviderTest.dummy_name ) ; contentValues.put ( CarrierIdentification.CID , com.android.providers.telephony.CarrierIdProviderTest.dummy_cid ) ; return contentValues ; }