auphong2707/dl4se-code-review-dataset huggingface dataset:
Source:
private void sendScreenState ( boolean on ) { com.android.internal.telephony.RILRequest rr = com.android.internal.telephony.RILRequest.obtain ( com.android.internal.telephony.RIL_REQUEST_SCREEN_STATE , null ) ; rr.mParcel.writeInt ( 1 ) ; rr.mParcel.writeInt ( ( on ? 1 : 0 ) ) ; if ( com.android.internal.telephony.RIL.RILJ_LOGD ) riljLog ( ( ( ( ( ( rr.serialString ( ) ) + "> " ) + ( com.android.internal.telephony.RIL.requestToString ( rr.mRequest ) ) ) + ": " ) + on ) ) ; send ( rr ) ; }

Target:
private void sendScreenState ( boolean on ) { com.android.internal.telephony.RILRequest rr = com.android.internal.telephony.RILRequest.obtain ( com.android.internal.telephony.RIL_REQUEST_SCREEN_STATE , null , mRILDefaultWorkSource ) ; rr.mParcel.writeInt ( 1 ) ; rr.mParcel.writeInt ( ( on ? 1 : 0 ) ) ; if ( com.android.internal.telephony.RIL.RILJ_LOGD ) riljLog ( ( ( ( ( ( rr.serialString ( ) ) + "> " ) + ( com.android.internal.telephony.RIL.requestToString ( rr.mRequest ) ) ) + ": " ) + on ) ) ; send ( rr ) ; }
Source:
private int shrinkArray ( proguard.shrink.VisitorAccepter [ ] array , int length ) { int counter = 0 ; for ( int index = 0 ; index < length ; index ++ ) { if ( usageMarker.isUsed ( array [ index ] ) ) { array [ ( counter ++ ) ] = array [ index ] ; } } if ( counter < length ) { java.util.Arrays.fill ( array , counter , length , null ) ; } return counter ; }

Target:
private boolean [ ] shrinkFlags ( proguard.shrink.Constant [ ] constantPool , int [ ] array , int length ) { boolean [ ] unused = new boolean [ length ] ; for ( int index = 0 ; index < length ; index ++ ) { if ( ! ( usageMarker.isUsed ( constantPool [ array [ index ] ] ) ) ) { unused [ index ] = true ; } } return unused ; }
Source:
public void run ( ) { synchronized ( this ) { if ( com.android.internal.policy.impl.PhoneWindowManager.localLOGV ) android.util.Log.v ( com.android.internal.policy.impl.PhoneWindowManager.TAG , "mScreenLockTimeout activating keyguard" ) ; if ( ( mKeyguardMediator ) != null ) { mKeyguardMediator.doKeyguardTimeout ( ) ; } mLockScreenTimerActive = false ; } }

Target:
public void systemReady ( ) { if ( ( mKeyguardMediator ) != null ) { mKeyguardMediator.onSystemReady ( ) ; } synchronized ( mLock ) { updateOrientationListenerLp ( ) ; mSystemReady = true ; mHandler.post ( new java.lang.Runnable ( ) { public void run ( ) { updateSettings ( ) ; } } ) ; } }
Source:
public void onSelected ( boolean showTitle ) { super . onSelected ( showTitle ) ; updateControls ( ) ; postHideRippleAnimation ( ) ; }

Target:
private void initializeTimeline ( ) { com.android.tv.data.Program program = mTimeShiftManager.getProgramAt ( mTimeShiftManager.getCurrentPositionMs ( ) ) ; mProgramStartTimeMs = program.getStartTimeUtcMillis ( ) ; mProgramEndTimeMs = program.getEndTimeUtcMillis ( ) ; mProgress.setMax ( ( ( mProgramEndTimeMs ) - ( mProgramStartTimeMs ) ) ) ; updateRecTimeText ( ) ; com.android.tv.common.SoftPreconditions.checkArgument ( ( ( mProgramStartTimeMs ) <= ( mProgramEndTimeMs ) ) ) ; }
Source:
public void dispose ( ) throws android.telephony.mbms.MbmsException { try { mService.disposeStream ( mAppName , mSubscriptionId , mServiceInfo.getServiceId ( ) ) ; } catch ( android.os.RemoteException e ) { android.util.Log.w ( android.telephony.mbms.StreamingService.LOG_TAG , ( "Caught remote exception calling disposeStream: " + e ) ) ; throw new android.telephony.mbms.MbmsException ( MbmsException.ERROR_UNKNOWN_REMOTE_EXCEPTION ) ; } }

Target:
public void stopStreaming ( ) throws android.telephony.mbms.MbmsException { if ( ( mService ) == null ) { throw new java.lang.IllegalStateException ( "No streaming service attached" ) ; } try { mService.stopStreaming ( mAppName , mSubscriptionId , mServiceInfo.getServiceId ( ) ) ; } catch ( android.os.DeadObjectException e ) { android.util.Log.w ( android.telephony.mbms.StreamingService.LOG_TAG , "Remote process died" ) ; mService = null ; throw new android.telephony.mbms.MbmsException ( MbmsException.ERROR_SERVICE_LOST ) ; } catch ( android.os.RemoteException e ) { android.util.Log.w ( android.telephony.mbms.StreamingService.LOG_TAG , ( "Caught remote exception calling stopStreaming: " + e ) ) ; throw new android.telephony.mbms.MbmsException ( MbmsException.ERROR_UNKNOWN_REMOTE_EXCEPTION ) ; } }
Source:
public static void getSSLParameters ( javax.net.ssl.SSLParameters params , org.conscrypt.SSLParametersImpl impl , org.conscrypt.OpenSSLSocketImpl socket ) { params.setEndpointIdentificationAlgorithm ( impl.getEndpointIdentificationAlgorithm ( ) ) ; if ( ( impl.getUseSni ( ) ) && ( org.conscrypt.AddressUtils.isValidSniHostname ( socket.getHostname ( ) ) ) ) { params.setServerNames ( java.util.Collections.< javax.net.ssl.SNIServerName > singletonList ( new javax.net.ssl.SNIHostName ( socket.getHostname ( ) ) ) ) ; } }

Target:
public static void getSSLParameters ( javax.net.ssl.SSLParameters params , org.conscrypt.SSLParametersImpl impl , org.conscrypt.OpenSSLSocketImpl socket ) { params.setEndpointIdentificationAlgorithm ( impl.getEndpointIdentificationAlgorithm ( ) ) ; params.setUseCipherSuitesOrder ( impl.getUseCipherSuitesOrder ( ) ) ; if ( ( impl.getUseSni ( ) ) && ( org.conscrypt.AddressUtils.isValidSniHostname ( socket.getHostname ( ) ) ) ) { params.setServerNames ( java.util.Collections.< javax.net.ssl.SNIServerName > singletonList ( new javax.net.ssl.SNIHostName ( socket.getHostname ( ) ) ) ) ; } }
Source:
public com.android.server.net.NetworkStatsService.NetworkStatsSettings.Config getUidTagConfig ( ) { return new com.android.server.net.NetworkStatsService.NetworkStatsSettings.Config ( getSecureLong ( android.provider.Settings.Secure.NETSTATS_UID_TAG_BUCKET_DURATION , ( 2 * ( android.text.format.DateUtils.HOUR_IN_MILLIS ) ) ) , getSecureLong ( android.provider.Settings.Secure.NETSTATS_UID_TAG_ROTATE_AGE , ( 5 * ( android.text.format.DateUtils.DAY_IN_MILLIS ) ) ) , getSecureLong ( android.provider.Settings.Secure.NETSTATS_UID_TAG_DELETE_AGE , ( 15 * ( android.text.format.DateUtils.DAY_IN_MILLIS ) ) ) ) ; }

Target:
public com.android.server.net.NetworkStatsService.NetworkStatsSettings.Config getUidTagConfig ( ) { return new com.android.server.net.NetworkStatsService.NetworkStatsSettings.Config ( getGlobalLong ( android.provider.Settings.Global.NETSTATS_UID_TAG_BUCKET_DURATION , ( 2 * ( android.text.format.DateUtils.HOUR_IN_MILLIS ) ) ) , getGlobalLong ( android.provider.Settings.Global.NETSTATS_UID_TAG_ROTATE_AGE , ( 5 * ( android.text.format.DateUtils.DAY_IN_MILLIS ) ) ) , getGlobalLong ( android.provider.Settings.Global.NETSTATS_UID_TAG_DELETE_AGE , ( 15 * ( android.text.format.DateUtils.DAY_IN_MILLIS ) ) ) ) ; }
Source:
public boolean canImport ( javax.swing.JComponent component , java.awt.datatransfer.DataFlavor [ ] dataFlavors ) { for ( java.awt.datatransfer.DataFlavor flavor : dataFlavors ) { if ( ( flavor.isFlavorJavaFileListType ( ) ) || ( flavor.isFlavorTextType ( ) ) ) { return true ; } } return false ; }

Target:
public boolean canImport ( javax.swing.TransferHandler.TransferSupport support ) { boolean isCopySupported = ( ( javax.swing.TransferHandler.COPY ) & ( support.getSourceDropActions ( ) ) ) == ( javax.swing.TransferHandler.COPY ) ; if ( ! isCopySupported ) { return false ; } for ( java.awt.datatransfer.DataFlavor flavor : support.getDataFlavors ( ) ) { if ( ( flavor.isFlavorJavaFileListType ( ) ) || ( flavor.isFlavorTextType ( ) ) ) { support.setDropAction ( javax.swing.TransferHandler.COPY ) ; return true ; } } return false ; }
Source:
void doDockedTest ( java.lang.String testCase , android.server.cts.ParentChildTestBase.ParentChildTest t ) throws java.lang.Exception { com.android.tradefed.log.LogUtil.CLog.logAndDisplay ( LogLevel.INFO , "Running test docked" ) ; startTestCaseDocked ( testCase ) ; doSingleTest ( t ) ; stopTestCase ( ) ; }

Target:
void doDockedTest ( java.lang.String testCase , android.server.cts.ParentChildTestBase.ParentChildTest t ) throws java.lang.Exception { com.android.tradefed.log.LogUtil.CLog.logAndDisplay ( LogLevel.INFO , "Running test docked" ) ; if ( ! ( supportsSplitScreenMultiWindow ( ) ) ) { com.android.tradefed.log.LogUtil.CLog.logAndDisplay ( LogLevel.INFO , "Skipping test: no split multi-window support" ) ; return ; } startTestCaseDocked ( testCase ) ; doSingleTest ( t ) ; stopTestCase ( ) ; }
Source:
public sun.misc.Resource getResource ( java.lang.String name , boolean check ) { if ( sun.misc.URLClassPath.DEBUG ) { java.lang.System.err.println ( ( ( "URLClassPath.getResource(\"" + name ) + "\")" ) ) ; } sun.misc.URLClassPath.Loader loader ; for ( int i = 0 ; ( loader = getLoader ( i ) ) != null ; i ++ ) { sun.misc.Resource res = loader.getResource ( name , check ) ; if ( res != null ) { return res ; } } return null ; }

Target:
public synchronized void addURL ( java.net.URL url ) { if ( closed ) return ; synchronized ( urls ) { if ( ( url == null ) || ( path.contains ( url ) ) ) return ; urls.add ( 0 , url ) ; path.add ( url ) ; if ( ( lookupCacheURLs ) != null ) { sun.misc.URLClassPath.disableAllLookupCaches ( ) ; } } }
Source:
public static void main ( java.lang.String [ ] args ) { IsDefaultTest.test ( ) ; AnnotationTest.testAnnotationsByType ( ) ; AnnotationTest.testDeclaredAnnotation ( ) ; AnnotationTest.testDeclaredAnnotationsByType ( ) ; AnnotationTest.testMethodAnnotationsByType ( ) ; AnnotationTest.testMethodDeclaredAnnotations ( ) ; AnnotationTest.testMethodDeclaredAnnotationsByType ( ) ; }

Target:
public static void main ( java.lang.String [ ] args ) { Main.printIsDefault ( Main.DefaultInterface.class ) ; Main.printIsDefault ( Main.RegularInterface.class ) ; Main.printIsDefault ( Main.ImplementsWithDefault.class ) ; Main.printIsDefault ( Main.ImplementsWithRegular.class ) ; }
Source:
private void runInBatchModeImpl ( java.lang.String javaPkgName ) throws com.android.cts.DeviceDisconnectedException { mDevice.runInBatchMode ( this , javaPkgName ) ; synchronized ( mTimeOutTimer ) { if ( ! ( mTestStop ) ) { try { mTimeOutTimer.waitOn ( ) ; } catch ( java.lang.InterruptedException e ) { com.android.cts.Log.d ( "time out object interrupted" ) ; } } mProgressObserver.stop ( ) ; if ( mTimeOutTimer.isTimeOut ( ) ) { return ; } else { mTimeOutTimer.cancel ( false ) ; } } }

Target:
private void runInBatchModeImpl ( java.lang.String javaPkgName , android.annotation.cts.Profile profile ) throws com.android.cts.DeviceDisconnectedException { mDevice.runInBatchMode ( this , javaPkgName , profile ) ; synchronized ( mTimeOutTimer ) { if ( ! ( mTestStop ) ) { try { mTimeOutTimer.waitOn ( ) ; } catch ( java.lang.InterruptedException e ) { com.android.cts.Log.d ( "time out object interrupted" ) ; } } mProgressObserver.stop ( ) ; if ( mTimeOutTimer.isTimeOut ( ) ) { return ; } else { mTimeOutTimer.cancel ( false ) ; } } }
Source:
private void activate ( ) { java.io.File binDir = new java.io.File ( mVenvDir , ( com.android.tradefed.targetprep.VtsPythonVirtualenvPreparer.isOnWindows ( ) ? "Scripts" : "bin" ) ) ; mRunUtil.setWorkingDir ( binDir ) ; java.lang.String path = java.lang.System.getenv ( com.android.tradefed.targetprep.VtsPythonVirtualenvPreparer.PATH ) ; mRunUtil.setEnvVariable ( com.android.tradefed.targetprep.VtsPythonVirtualenvPreparer.PATH , ( ( binDir + ( java.io.File.pathSeparator ) ) + path ) ) ; java.io.File pipFile = new java.io.File ( binDir , com.android.tradefed.targetprep.VtsPythonVirtualenvPreparer.PIP ) ; pipFile.setExecutable ( true ) ; mPip = pipFile.getAbsolutePath ( ) ; }

Target:
com.android.tradefed.util.IRunUtil getRunUtil ( ) { if ( ( mRunUtil ) == null ) { mRunUtil = new com.android.tradefed.util.RunUtil ( ) ; } return mRunUtil ; }
Source:
public void onReceive ( android.content.Context context , android.content.Intent intent ) { synchronized ( this ) { mPendingAlarm = null ; alarmFiredNative ( ) ; } }

Target:
public void handleMessage ( android.os.Message msg ) { debugLog ( ( "handleMessage() - Message: " + ( msg.what ) ) ) ; switch ( msg.what ) { case com.android.bluetooth.btservice.AdapterService.MESSAGE_PROFILE_SERVICE_STATE_CHANGED : { debugLog ( "handleMessage() - MESSAGE_PROFILE_SERVICE_STATE_CHANGED" ) ; processProfileServiceStateChanged ( ( ( java.lang.String ) ( msg.obj ) ) , msg.arg1 ) ; } break ; } }
Source:
private void updateDataSet ( final java.util.List < com.android.ddmuilib.SysinfoPanel.BugReportParser.DataValue > data , final java.lang.String label ) { org.eclipse.swt.widgets.Display.getDefault ( ) . syncExec ( new java.lang.Runnable ( ) { @ java.lang.Override public void run ( ) { mLabel.setText ( label ) ; for ( com.android.ddmuilib.SysinfoPanel.BugReportParser.DataValue d : data ) { mDataset.setValue ( d.name , d.value ) ; } } } ) ; }

Target:
private void updatePieDataSet ( final java.util.List < com.android.ddmuilib.SysinfoPanel.BugReportParser.DataValue > data , final java.lang.String label ) { org.eclipse.swt.widgets.Display.getDefault ( ) . syncExec ( new java.lang.Runnable ( ) { @ java.lang.Override public void run ( ) { mLabel.setText ( label ) ; mStackLayout.topControl = mPieChartComposite ; mChartComposite.layout ( ) ; for ( com.android.ddmuilib.SysinfoPanel.BugReportParser.DataValue d : data ) { mDataset.setValue ( d.name , d.value ) ; } } } ) ; }
Source:
static com.android.jack.shrob.spec.ClassSpecification classSpec ( java.lang.String name , boolean hasNameNegator , @ javax.annotation.Nonnull com.android.jack.shrob.spec.ClassTypeSpecification classType , com.android.jack.shrob.spec.AnnotationSpecification annotation , @ javax.annotation.Nonnull com.android.jack.shrob.spec.ModifierSpecification modifier ) { com.android.jack.shrob.spec.NameSpecification nameSpec ; if ( name.equals ( "*" ) ) { nameSpec = com.android.jack.shrob.proguard.GrammarActions.name ( "**" , com.android.jack.shrob.proguard.GrammarActions.FilterSeparator.CLASS ) ; } else { nameSpec = com.android.jack.shrob.proguard.GrammarActions.name ( name , com.android.jack.shrob.proguard.GrammarActions.FilterSeparator.CLASS ) ; } nameSpec.setNegator ( hasNameNegator ) ; com.android.jack.shrob.spec.ClassSpecification classSpec = new com.android.jack.shrob.spec.ClassSpecification ( nameSpec , classType , annotation ) ; classSpec.setModifier ( modifier ) ; return classSpec ; }

Target:
static com.android.jack.shrob.spec.ClassSpecification classSpec ( java.util.List < com.android.jack.shrob.spec.NameSpecification > classNames , @ javax.annotation.Nonnull com.android.jack.shrob.spec.ClassTypeSpecification classType , com.android.jack.shrob.spec.AnnotationSpecification annotation , @ javax.annotation.Nonnull com.android.jack.shrob.spec.ModifierSpecification modifier ) { com.android.jack.shrob.spec.ClassSpecification classSpec = new com.android.jack.shrob.spec.ClassSpecification ( classNames , classType , annotation ) ; classSpec.setModifier ( modifier ) ; return classSpec ; }
Source:
private static void readZoneTab ( libcore.io.BufferIterator it , int zoneTabOffset ) { byte [ ] bytes = new byte [ ( ( int ) ( libcore.util.ZoneInfoDB.TZDATA.size ( ) ) ) - zoneTabOffset ] ; it.seek ( zoneTabOffset ) ; it.readByteArray ( bytes , 0 , bytes.length ) ; libcore.util.ZoneInfoDB.zoneTab = new java.lang.String ( bytes , 0 , bytes.length , java.nio.charset.Charsets.US_ASCII ) ; }

Target:
private void readZoneTab ( libcore.io.BufferIterator it , int zoneTabOffset , int zoneTabSize ) { byte [ ] bytes = new byte [ zoneTabSize ] ; it.seek ( zoneTabOffset ) ; it.readByteArray ( bytes , 0 , bytes.length ) ; zoneTab = new java.lang.String ( bytes , 0 , bytes.length , java.nio.charset.Charsets.US_ASCII ) ; }
Source:
public int getState ( ) { if ( com.android.bluetooth.pbap.BluetoothPbapService.DEBUG ) android.util.Log.d ( com.android.bluetooth.pbap.BluetoothPbapService.TAG , ( "getState " + ( mState ) ) ) ; if ( ! ( com.android.bluetooth.Utils.checkCaller ( ) ) ) { android.util.Log.w ( com.android.bluetooth.pbap.BluetoothPbapService.TAG , "getState(): not allowed for non-active user" ) ; return android.bluetooth.BluetoothPbap.STATE_DISCONNECTED ; } enforceCallingOrSelfPermission ( com.android.bluetooth.pbap.BluetoothPbapService.BLUETOOTH_PERM , "Need BLUETOOTH permission" ) ; return mState ; }

Target:
protected boolean stop ( ) { android.util.Log.v ( com.android.bluetooth.pbap.BluetoothPbapService.TAG , "stop()" ) ; if ( ! ( mIsRegistered ) ) { android.util.Log.i ( com.android.bluetooth.pbap.BluetoothPbapService.TAG , "Avoid unregister when receiver it is not registered" ) ; return true ; } try { mIsRegistered = false ; unregisterReceiver ( mPbapReceiver ) ; } catch ( java.lang.Exception e ) { android.util.Log.w ( com.android.bluetooth.pbap.BluetoothPbapService.TAG , "Unable to unregister pbap receiver" , e ) ; } setState ( BluetoothPbap.STATE_DISCONNECTED , BluetoothPbap.RESULT_CANCELED ) ; closeService ( ) ; if ( ( mSessionStatusHandler ) != null ) { mSessionStatusHandler.removeCallbacksAndMessages ( null ) ; } return true ; }
Source:
boolean waitForCallback ( int callback ) { synchronized ( mLocalLock ) { java.util.Iterator < java.lang.Integer > it = mCallbackQueue.iterator ( ) ; while ( it.hasNext ( ) ) { if ( ( it.next ( ) ) == callback ) { it.remove ( ) ; return true ; } } mCurrentWaitForCallback = callback ; mBlocker = new java.util.concurrent.CountDownLatch ( 1 ) ; } try { return mBlocker.await ( android.net.wifi.aware.cts.SingleDeviceTest.WAIT_FOR_AWARE_CHANGE , java.util.concurrent.TimeUnit.SECONDS ) ; } catch ( java.lang.InterruptedException e ) { return false ; } }

Target:
boolean waitForCallback ( int callback ) { synchronized ( mLocalLock ) { boolean found = mCallbackQueue.remove ( callback ) ; if ( found ) { return true ; } mCurrentWaitForCallback = callback ; mBlocker = new java.util.concurrent.CountDownLatch ( 1 ) ; } try { return mBlocker.await ( android.net.wifi.aware.cts.SingleDeviceTest.WAIT_FOR_AWARE_CHANGE_SECS , java.util.concurrent.TimeUnit.SECONDS ) ; } catch ( java.lang.InterruptedException e ) { return false ; } }
Source:
void findTaskToMoveToFrontLocked ( com.android.server.am.TaskRecord task , int flags , android.os.Bundle options ) { if ( ( flags & ( android.app.ActivityManager.MOVE_TASK_NO_USER_ACTION ) ) == 0 ) { mUserLeaving = true ; } if ( ( flags & ( android.app.ActivityManager.MOVE_TASK_WITH_HOME ) ) != 0 ) { task.setTaskToReturnTo ( com.android.server.am.ActivityRecord.HOME_ACTIVITY_TYPE ) ; } task.stack.moveTaskToFrontLocked ( task , null , options ) ; if ( com.android.server.am.ActivityManagerService.DEBUG_STACK ) android.util.Slog.d ( com.android.server.am.ActivityManagerService.TAG , ( "findTaskToMoveToFront: moved to front of stack=" + ( task.stack ) ) ) ; }

Target:
void findTaskToMoveToFrontLocked ( com.android.server.am.TaskRecord task , int flags , android.os.Bundle options , java.lang.String reason ) { if ( ( flags & ( android.app.ActivityManager.MOVE_TASK_NO_USER_ACTION ) ) == 0 ) { mUserLeaving = true ; } if ( ( flags & ( android.app.ActivityManager.MOVE_TASK_WITH_HOME ) ) != 0 ) { task.setTaskToReturnTo ( com.android.server.am.ActivityRecord.HOME_ACTIVITY_TYPE ) ; } task.stack.moveTaskToFrontLocked ( task , null , options , reason ) ; if ( com.android.server.am.ActivityManagerService.DEBUG_STACK ) android.util.Slog.d ( com.android.server.am.ActivityManagerService.TAG , ( "findTaskToMoveToFront: moved to front of stack=" + ( task.stack ) ) ) ; }
Source:
public void setVoiceMessageWaiting ( int line , int countWaiting ) { if ( line != 1 ) { return ; } if ( countWaiting < 0 ) { countWaiting = - 1 ; } else if ( countWaiting > 255 ) { countWaiting = 255 ; } countVoiceMessages = countWaiting ; mRecordsEventsRegistrants.notifyResult ( com.android.internal.telephony.uicc.EVENT_MWI ) ; }

Target:
public void setVoiceMessageWaiting ( int line , int countWaiting ) { if ( line != 1 ) { return ; } if ( countWaiting < 0 ) { countWaiting = - 1 ; } else if ( countWaiting > 255 ) { countWaiting = 255 ; } mCountVoiceMessages = countWaiting ; mRecordsEventsRegistrants.notifyResult ( com.android.internal.telephony.uicc.EVENT_MWI ) ; }
Source:
public void recommendation_noScans_returnsCurrentConfig ( ) throws java.lang.Exception { android.net.wifi.ScanResult [ ] scanResults = new android.net.wifi.ScanResult [ 0 ] ; android.net.wifi.WifiConfiguration expectedConfig = new android.net.wifi.WifiConfiguration ( ) ; android.net.RecommendationRequest request = new android.net.RecommendationRequest.Builder ( ) . setScanResults ( scanResults ) . setNetworkCapabilities ( new android.net.NetworkCapabilities ( ) . removeCapability ( NetworkCapabilities.NET_CAPABILITY_TRUSTED ) ) . setCurrentRecommendedWifiConfig ( expectedConfig ) . build ( ) ; android.net.RecommendationResult result = verifyAndCaptureResult ( request ) ; org.junit.Assert.assertEquals ( request.getCurrentSelectedConfig ( ) , result.getWifiConfiguration ( ) ) ; }

Target:
public void recommendation_noScans_returnsCurrentConfig ( ) throws java.lang.Exception { android.net.wifi.ScanResult [ ] scanResults = new android.net.wifi.ScanResult [ 0 ] ; android.net.wifi.WifiConfiguration expectedConfig = new android.net.wifi.WifiConfiguration ( ) ; expectedConfig.SSID = "ssid" ; expectedConfig.BSSID = "bssid" ; android.net.RecommendationRequest request = new android.net.RecommendationRequest.Builder ( ) . setScanResults ( scanResults ) . setNetworkCapabilities ( new android.net.NetworkCapabilities ( ) . removeCapability ( NetworkCapabilities.NET_CAPABILITY_TRUSTED ) ) . setCurrentRecommendedWifiConfig ( expectedConfig ) . build ( ) ; android.net.RecommendationResult result = verifyAndCaptureResult ( request ) ; org.junit.Assert.assertEquals ( expectedConfig , result.getWifiConfiguration ( ) ) ; }
Source:
void stopProfileServices ( ) { java.lang.Class [ ] supportedProfileServices = com.android.bluetooth.btservice.Config.getSupportedProfiles ( ) ; if ( ( mRunningProfiles.size ( ) ) == 0 ) { debugLog ( "stopProfileServices() - No profiles services to stop or already stopped." ) ; return ; } setAllProfileServiceStates ( supportedProfileServices , BluetoothAdapter.STATE_OFF ) ; }

Target:
void stateChangeCallback ( int status ) { if ( status == ( AbstractionLayer.BT_STATE_OFF ) ) { debugLog ( "stateChangeCallback: disableNative() completed" ) ; } else if ( status == ( AbstractionLayer.BT_STATE_ON ) ) { mAdapterStateMachine.sendMessage ( AdapterState.BLE_STARTED ) ; } else { android.util.Log.e ( com.android.bluetooth.btservice.AdapterService.TAG , ( ( "Incorrect status " + status ) + " in stateChangeCallback" ) ) ; } }
Source:
public java.lang.String getDensityFilter ( ) { return densityFilter ; }

Target:
public java.lang.String getFilter ( java.lang.String filterType ) { if ( ( ( densityFilter ) != null ) && ( filterType.equals ( OutputFile.DENSITY ) ) ) { return densityFilter ; } else if ( ( ( abiFilter ) != null ) && ( filterType.equals ( OutputFile.ABI ) ) ) { return abiFilter ; } return null ; }
Source:
public void testNewSms ( ) { transitionFromStartupToIdle ( ) ; mGsmInboundSmsHandler.sendMessage ( InboundSmsHandler.EVENT_NEW_SMS , new android.os.AsyncResult ( null , mSmsMessage , null ) ) ; com.android.internal.telephony.TelephonyTestUtils.waitForMs ( 100 ) ; verifySmsIntentBroadcasts ( 0 ) ; mGsmInboundSmsHandler.sendMessage ( InboundSmsHandler.EVENT_NEW_SMS , new android.os.AsyncResult ( null , mSmsMessage , null ) ) ; com.android.internal.telephony.TelephonyTestUtils.waitForMs ( 100 ) ; verify ( mContext , times ( 2 ) ) . sendBroadcast ( any ( android.content.Intent.class ) ) ; assertEquals ( "IdleState" , getCurrentState ( ) . getName ( ) ) ; }

Target:
public void testNewSmsFromBlockedNumber_noBroadcastsSent ( ) { java.lang.String blockedNumber = "1234567890" ; org.mockito.Mockito.doReturn ( blockedNumber ) . when ( mInboundSmsTracker ) . getDisplayAddress ( ) ; mFakeBlockedNumberContentProvider.mBlockedNumbers.add ( blockedNumber ) ; transitionFromStartupToIdle ( ) ; mGsmInboundSmsHandler.sendMessage ( InboundSmsHandler.EVENT_NEW_SMS , new android.os.AsyncResult ( null , mSmsMessage , null ) ) ; com.android.internal.telephony.TelephonyTestUtils.waitForMs ( 100 ) ; org.mockito.Mockito.verify ( mContext , org.mockito.Mockito.never ( ) ) . sendBroadcast ( org.mockito.Matchers.any ( android.content.Intent.class ) ) ; org.junit.Assert.assertEquals ( "IdleState" , getCurrentState ( ) . getName ( ) ) ; }
Source:
synchronized void nAllocationRead ( long id , byte [ ] d ) { validate ( ) ; rsnAllocationRead ( mContext , id , d ) ; }

Target:
synchronized void nScriptInvokeV ( long id , int slot , byte [ ] params , boolean mUseInc ) { validate ( ) ; long curCon = mContext ; if ( mUseInc ) { curCon = mIncCon ; } rsnScriptInvokeV ( curCon , id , slot , params , mUseInc ) ; }
Source:
public void setHorizontalScrollbarOverlay ( final boolean overlay ) { if ( checkNeedsPost ( ) ) { mRunQueue.addTask ( new java.lang.Runnable ( ) { @ java.lang.Override public void run ( ) { setHorizontalScrollbarOverlay ( overlay ) ; } } ) ; return ; } mAwContents.setHorizontalScrollbarOverlay ( overlay ) ; }

Target:
public void setVerticalScrollbarOverlay ( final boolean overlay ) { if ( checkNeedsPost ( ) ) { mRunQueue.addTask ( new java.lang.Runnable ( ) { @ java.lang.Override public void run ( ) { setVerticalScrollbarOverlay ( overlay ) ; } } ) ; return ; } mAwContents.setVerticalScrollbarOverlay ( overlay ) ; }
Source:
public void binderDied ( ) { if ( com.android.server.LocationManagerService.LOCAL_LOGV ) { android.util.Slog.v ( com.android.server.LocationManagerService.TAG , "Location listener died" ) ; } synchronized ( mLock ) { removeUpdatesLocked ( this ) ; } synchronized ( this ) { if ( ( mPendingBroadcasts ) > 0 ) { this . decrementPendingBroadcasts ( ) ; mPendingBroadcasts = 0 ; } } }

Target:
public void binderDied ( ) { if ( com.android.server.LocationManagerService.D ) android.util.Log.d ( com.android.server.LocationManagerService.TAG , "Location listener died" ) ; synchronized ( mLock ) { removeUpdatesLocked ( this ) ; } synchronized ( this ) { if ( ( mPendingBroadcasts ) > 0 ) { this . decrementPendingBroadcasts ( ) ; mPendingBroadcasts = 0 ; } } }
Source:
void onDocumentsReady ( java.util.List < com.android.documentsui.model.DocumentInfo > docs ) { mClipper.clipDocuments ( docs ) ; android.app.Activity activity = getActivity ( ) ; com.android.documentsui.Snackbars.makeSnackbar ( activity , activity.getResources ( ) . getQuantityString ( R.plurals.clipboard_files_clipped , docs.size ( ) , docs.size ( ) ) , Snackbar.LENGTH_SHORT ) . show ( ) ; }

Target:
protected void onPostExecute ( java.util.List < com.android.documentsui.model.DocumentInfo > docs ) { copyDocuments ( docs , destination ) ; }
Source:
private boolean updateSelectAllState ( ) { for ( android.support.v17.leanback.widget.GuidedAction guidedAction : getActions ( ) ) { if ( ( guidedAction.getCheckSetId ( ) ) == ( android.support.v17.leanback.widget.GuidedAction.CHECKBOX_CHECK_SET_ID ) ) { if ( ! ( guidedAction.isChecked ( ) ) ) { if ( mAllSelected ) { updateSelectAllState ( findActionById ( com.android.tv.dvr.ui.SeriesDeletionFragment.ACTION_ID_SELECT_ALL ) , false ) ; } return false ; } } } if ( ! ( mAllSelected ) ) { updateSelectAllState ( findActionById ( com.android.tv.dvr.ui.SeriesDeletionFragment.ACTION_ID_SELECT_ALL ) , true ) ; } return true ; }

Target:
private boolean updateSelectAllState ( ) { for ( android.support.v17.leanback.widget.GuidedAction guidedAction : getActions ( ) ) { if ( ( guidedAction.getCheckSetId ( ) ) == ( android.support.v17.leanback.widget.GuidedAction.CHECKBOX_CHECK_SET_ID ) ) { if ( ! ( guidedAction.isChecked ( ) ) ) { if ( mAllSelected ) { updateSelectAllState ( findActionById ( com.android.tv.dvr.ui.DvrSeriesDeletionFragment.ACTION_ID_SELECT_ALL ) , false ) ; } return false ; } } } if ( ! ( mAllSelected ) ) { updateSelectAllState ( findActionById ( com.android.tv.dvr.ui.DvrSeriesDeletionFragment.ACTION_ID_SELECT_ALL ) , true ) ; } return true ; }
Source:
private void setWifiStatus ( ) { android.net.wifi.WifiInfo wifiInfo = mWifiManager.getConnectionInfo ( ) ; java.lang.String macAddress = ( wifiInfo == null ) ? null : wifiInfo.getMacAddress ( ) ; mWifiMacAddress.setSummary ( ( ! ( android.text.TextUtils.isEmpty ( macAddress ) ) ? macAddress : mUnavailable ) ) ; }

Target:
private void setWifiStatus ( ) { android.net.wifi.WifiInfo wifiInfo = mWifiManager.getConnectionInfo ( ) ; boolean hasMacAddress = ( wifiInfo != null ) && ( wifiInfo.hasRealMacAddress ( ) ) ; java.lang.String macAddress = ( hasMacAddress ) ? wifiInfo.getMacAddress ( ) : null ; mWifiMacAddress.setSummary ( ( ! ( android.text.TextUtils.isEmpty ( macAddress ) ) ? macAddress : mUnavailable ) ) ; }
Source:
public final void testPkgTypeSource ( ) throws java.lang.Exception { com.android.sdklib.repository.descriptors.IPkgCapabilities p = PkgType.PKG_SOURCES ; assertTrue ( p.hasMajorRevision ( ) ) ; assertFalse ( p.hasFullRevision ( ) ) ; assertTrue ( p.hasAndroidVersion ( ) ) ; assertFalse ( p.hasPath ( ) ) ; assertFalse ( p.hasTag ( ) ) ; assertFalse ( p.hasVendor ( ) ) ; assertFalse ( p.hasMinToolsRev ( ) ) ; assertFalse ( p.hasMinPlatformToolsRev ( ) ) ; }

Target:
public final void testPkgTypeSource ( ) throws java.lang.Exception { com.android.sdklib.repository.descriptors.IPkgCapabilities p = PkgType.PKG_SOURCE ; assertTrue ( p.hasMajorRevision ( ) ) ; assertFalse ( p.hasFullRevision ( ) ) ; assertTrue ( p.hasAndroidVersion ( ) ) ; assertFalse ( p.hasPath ( ) ) ; assertFalse ( p.hasTag ( ) ) ; assertFalse ( p.hasVendor ( ) ) ; assertFalse ( p.hasMinToolsRev ( ) ) ; assertFalse ( p.hasMinPlatformToolsRev ( ) ) ; }
Source:
public void copy1DRangeFromUnchecked ( int off , int count , byte [ ] d ) { android.os.Trace.traceBegin ( RenderScript.TRACE_TAG , "copy1DRangeFromUnchecked" ) ; int dataSize = ( mType.mElement.getBytesSize ( ) ) * count ; data1DChecks ( off , count , d.length , dataSize ) ; mRS.nAllocationData1D ( getIDSafe ( ) , off , mSelectedLOD , count , d , dataSize , Element.DataType.SIGNED_8 ) ; android.os.Trace.traceEnd ( RenderScript.TRACE_TAG ) ; }

Target:
public void copyFrom ( float [ ] d ) { validateIsFloat32 ( ) ; copyFromUnchecked ( d , Element.DataType.FLOAT_32 , d.length ) ; }
Source:
public com.android.jack.dx.io.instructions.DecodedInstruction withIndex ( int newIndex ) { return new com.android.jack.dx.io.instructions.OneRegisterDecodedInstruction ( getFormat ( ) , getOpcode ( ) , newIndex , getIndexType ( ) , getTarget ( ) , getLiteral ( ) , a ) ; }

Target:
public com.android.jack.dx.io.instructions.DecodedInstruction withIndex ( int newFirstIndex , int newSecondIndex ) { assert ( getSecondIndexType ( ) ) == ( com.android.jack.dx.io.IndexType.NONE ) ; return new com.android.jack.dx.io.instructions.OneRegisterDecodedInstruction ( getFormat ( ) , getOpcode ( ) , newFirstIndex , getFirstIndexType ( ) , getTarget ( ) , getLiteral ( ) , a ) ; }
Source:
public static void doTest ( ) throws java.lang.Exception { Main.testMethod ( "java.lang.Object" , "toString" ) ; Main.testMethod ( "java.lang.String" , "charAt" , int . class ) ; Main.testMethod ( "java.lang.Math" , "sqrt" , double . class ) ; Main.testMethod ( "java.util.List" , "add" , java.lang.Object.class ) ; }

Target:
public static void doTest ( ) throws java.lang.Exception { Main.testMethod ( "java.lang.Object" , "toString" ) ; Main.testMethod ( "java.lang.String" , "charAt" , int . class ) ; Main.testMethod ( "java.lang.Math" , "sqrt" , double . class ) ; Main.testMethod ( "java.util.List" , "add" , java.lang.Object.class ) ; Main.testMethod ( Main.getProxyClass ( ) , "run" ) ; }
Source:
public void onClick ( android.view.View v ) { if ( ! ( mDpm.isAdminActive ( com.android.cts.verifier.managedprovisioning.DeviceAdminTestReceiver.getReceiverComponentName ( ) ) ) ) { android.widget.Toast.makeText ( this , R.string.provisioning_byod_keyguard_disabled_features_not_admin , Toast.LENGTH_SHORT ) . show ( ) ; return ; } mDpm.resetPassword ( "testpassword" , 0 ) ; setKeyguardDisabledFeatures ( ( ( ( android.app.admin.DevicePolicyManager.KEYGUARD_DISABLE_TRUST_AGENTS ) | ( android.app.admin.DevicePolicyManager.KEYGUARD_DISABLE_FINGERPRINT ) ) | ( android.app.admin.DevicePolicyManager.KEYGUARD_DISABLE_UNREDACTED_NOTIFICATIONS ) ) ) ; }

Target:
public void onClick ( android.view.View v ) { if ( ! ( mDpm.isAdminActive ( getAdminComponent ( ) ) ) ) { android.widget.Toast.makeText ( this , R.string.provisioning_byod_keyguard_disabled_features_not_admin , Toast.LENGTH_SHORT ) . show ( ) ; return ; } setKeyguardDisabledFeatures ( ) ; mDpm.resetPassword ( "testpassword" , 0 ) ; }
Source:
synchronized int getAudioState ( ) { com.android.internal.util.IState state = getCurrentState ( ) ; if ( state == ( mAudioConnecting ) ) { return android.bluetooth.BluetoothHeadset.STATE_AUDIO_CONNECTING ; } else if ( ( state == ( mAudioDisconnecting ) ) || ( state == ( mAudioOn ) ) ) { return android.bluetooth.BluetoothHeadset.STATE_AUDIO_CONNECTED ; } else { return android.bluetooth.BluetoothHeadset.STATE_AUDIO_DISCONNECTED ; } }

Target:
synchronized int getConnectionState ( android.bluetooth.BluetoothDevice device ) { if ( ( mCurrentDevice ) == null ) { return android.bluetooth.BluetoothProfile.STATE_DISCONNECTED ; } if ( ! ( mCurrentDevice.equals ( device ) ) ) { return android.bluetooth.BluetoothProfile.STATE_DISCONNECTED ; } return ( ( com.android.bluetooth.hfp.HeadsetStateMachine.HeadsetStateBase ) ( getCurrentState ( ) ) ) . getConnectionStateInt ( ) ; }
Source:
public void updateConnectStatus ( ) { getPassButton ( ) . setEnabled ( ( ( mOutputDevInfo ) != null ) ) ; }

Target:
public void updateConnectStatus ( ) { mPlayBtn.setEnabled ( ( ( mIsPeripheralAttached ) && ( ( mSelectedProfile ) != null ) ) ) ; getPassButton ( ) . setEnabled ( ( ( ( mSelectedProfile ) != null ) && ( ( mOutputDevInfo ) != null ) ) ) ; }
Source:
public void setTaskResizeable ( int taskId , boolean resizeable ) { synchronized ( this ) { com.android.server.am.TaskRecord task = mStackSupervisor.anyTaskForIdLocked ( taskId , false ) ; if ( task == null ) { android.util.Slog.w ( com.android.server.am.ActivityManagerService.TAG , ( ( "setTaskResizeable: taskId=" + taskId ) + " not found" ) ) ; return ; } if ( ( task.mResizeable ) != resizeable ) { task.mResizeable = resizeable ; mStackSupervisor.ensureActivitiesVisibleLocked ( null , 0 ) ; mStackSupervisor.resumeTopActivitiesLocked ( ) ; } } }

Target:
private boolean removeTaskByIdLocked ( int taskId , boolean killProcess , boolean removeFromRecents ) { final com.android.server.am.TaskRecord tr = mStackSupervisor.anyTaskForIdLocked ( taskId , ( ! ( com.android.server.am.ActivityStackSupervisor.RESTORE_FROM_RECENTS ) ) , StackId.INVALID_STACK_ID ) ; if ( tr != null ) { tr.removeTaskActivitiesLocked ( ) ; cleanUpRemovedTaskLocked ( tr , killProcess , removeFromRecents ) ; if ( tr.isPersistable ) { notifyTaskPersisterLocked ( null , true ) ; } return true ; } android.util.Slog.w ( com.android.server.am.ActivityManagerService.TAG , ( "Request to remove task ignored for non-existent task " + taskId ) ) ; return false ; }
Source:
public static byte [ ] [ ] encodeCertificates ( org.conscrypt.Certificate [ ] certificates ) throws java.security.cert.CertificateEncodingException { byte [ ] [ ] certificateBytes = new byte [ certificates.length ] [ ] ; for ( int i = 0 ; i < ( certificates.length ) ; i ++ ) { certificateBytes [ i ] = certificates [ i ] . getEncoded ( ) ; } return certificateBytes ; }

Target:
public static byte [ ] [ ] encodeCertificates ( java.security.cert.Certificate [ ] certificates ) throws java.security.cert.CertificateEncodingException { byte [ ] [ ] certificateBytes = new byte [ certificates.length ] [ ] ; for ( int i = 0 ; i < ( certificates.length ) ; i ++ ) { certificateBytes [ i ] = certificates [ i ] . getEncoded ( ) ; } return certificateBytes ; }
Source:
protected int tryAcquireShared ( int ignore ) { return innerIsDone ( ) ? 1 : - 1 ; }

Target:
public V get ( long timeout , java.util.concurrent.TimeUnit unit ) throws java.lang.InterruptedException , java.util.concurrent.ExecutionException , java.util.concurrent.TimeoutException { if ( unit == null ) throw new java.lang.NullPointerException ( ) ; int s = state ; if ( ( s <= ( java.util.concurrent.FutureTask.COMPLETING ) ) && ( ( s = awaitDone ( true , unit.toNanos ( timeout ) ) ) <= ( java.util.concurrent.FutureTask.COMPLETING ) ) ) throw new java.util.concurrent.TimeoutException ( ) ; return report ( s ) ; }
Source:
public void deleteOdex ( java.lang.String apkPath , java.lang.String instructionSet , java.lang.String outputPath ) throws com.android.internal.os.InstallerConnection.InstallerException { if ( ! ( checkBeforeRemote ( ) ) ) return ; try { mInstalld.deleteOdex ( apkPath , instructionSet , outputPath ) ; } catch ( android.os.RemoteException | android.os.ServiceSpecificException e ) { throw new com.android.internal.os.InstallerConnection.InstallerException ( e.getMessage ( ) ) ; } }

Target:
public boolean mergeProfiles ( int uid , java.lang.String packageName ) throws com.android.server.pm.Installer.InstallerException { if ( ! ( checkBeforeRemote ( ) ) ) return false ; try { return mInstalld.mergeProfiles ( uid , packageName ) ; } catch ( android.os.RemoteException | android.os.ServiceSpecificException e ) { throw com.android.server.pm.Installer.InstallerException.from ( e ) ; } }
Source:
public void TestGetSetAllowedChars ( ) { android.icu.text.SpoofChecker sc = new android.icu.text.SpoofChecker.Builder ( ) . build ( ) ; android.icu.text.UnicodeSet us ; android.icu.text.UnicodeSet uset ; uset = sc.getAllowedChars ( ) ; assertTrue ( "" , uset.isFrozen ( ) ) ; us = new android.icu.text.UnicodeSet ( ( ( int ) ( 65 ) ) , ( ( int ) ( 90 ) ) ) ; sc = new android.icu.text.SpoofChecker.Builder ( ) . setAllowedChars ( us ) . build ( ) ; assertEquals ( "" , us , sc.getAllowedChars ( ) ) ; }

Target:
public void TestGetSetAllowedChars ( ) { android.icu.text.SpoofChecker sc = new android.icu.text.SpoofChecker.Builder ( ) . setChecks ( SpoofChecker.CHAR_LIMIT ) . build ( ) ; android.icu.text.UnicodeSet us ; android.icu.text.UnicodeSet uset ; uset = sc.getAllowedChars ( ) ; assertTrue ( "" , uset.isFrozen ( ) ) ; us = new android.icu.text.UnicodeSet ( 65 , 90 ) ; sc = new android.icu.text.SpoofChecker.Builder ( ) . setChecks ( SpoofChecker.CHAR_LIMIT ) . setAllowedChars ( us ) . build ( ) ; assertEquals ( "" , us , sc.getAllowedChars ( ) ) ; }
Source:
public void test2_1SetEnabledAfterRelease ( ) throws java.lang.Exception { if ( ! ( isVirtualizerAvailable ( ) ) ) { return ; } getVirtualizer ( 0 ) ; mVirtualizer.release ( ) ; try { mVirtualizer.setEnabled ( true ) ; } catch ( java.lang.IllegalStateException e ) { } finally { releaseVirtualizer ( ) ; } }

Target:
public void test2_1SetEnabledAfterRelease ( ) throws java.lang.Exception { if ( ! ( isVirtualizerAvailable ( ) ) ) { return ; } getVirtualizer ( getSessionId ( ) ) ; mVirtualizer.release ( ) ; try { mVirtualizer.setEnabled ( true ) ; } catch ( java.lang.IllegalStateException e ) { } finally { releaseVirtualizer ( ) ; } }
Source:
public void writeToParcel ( android.os.Parcel destination , int flags ) { destination.writeParcelable ( mAccountHandle , 0 ) ; destination.writeParcelable ( mAddress , 0 ) ; destination.writeParcelable ( mExtras , 0 ) ; destination.writeInt ( mVideoState ) ; destination.writeString ( mTelecomCallId ) ; }

Target:
public void writeToParcel ( android.os.Parcel destination , int flags ) { destination.writeParcelable ( mAccountHandle , 0 ) ; destination.writeParcelable ( mAddress , 0 ) ; destination.writeParcelable ( mExtras , 0 ) ; destination.writeInt ( mVideoState ) ; destination.writeString ( mTelecomCallId ) ; destination.writeInt ( ( mShouldShowIncomingCallUi ? 1 : 0 ) ) ; }
Source:
public void run ( ) { for ( com.android.ide.eclipse.adt.internal.editors.layout.gle2.CanvasSelection cs : selection ) { com.android.ide.eclipse.adt.internal.editors.layout.gle2.CanvasViewInfo vi = cs.getViewInfo ( ) ; if ( ( vi != null ) && ( ! ( vi.isRoot ( ) ) ) ) { com.android.ide.eclipse.adt.internal.editors.layout.uimodel.UiViewElementNode ui = vi.getUiViewKey ( ) ; if ( ui != null ) { ui.deleteXmlNode ( ) ; } } } }

Target:
public void run ( ) { for ( com.android.ide.eclipse.adt.internal.editors.layout.gle2.CanvasSelection cs : selection ) { com.android.ide.eclipse.adt.internal.editors.layout.gle2.CanvasViewInfo vi = cs.getViewInfo ( ) ; if ( ( vi != null ) && ( ! ( vi.isRoot ( ) ) ) ) { com.android.ide.eclipse.adt.internal.editors.layout.uimodel.UiViewElementNode ui = vi.getUiViewNode ( ) ; if ( ui != null ) { ui.deleteXmlNode ( ) ; } } } }
Source:
private com.android.internal.util.Predicate < android.test.suitebuilder.TestMethod > getSizePredicateFromArg ( java.lang.String sizeArg ) { if ( android.test.InstrumentationTestRunner.SMALL_SUITE.equals ( sizeArg ) ) { return android.test.suitebuilder.TestPredicates.SELECT_SMALL ; } else if ( android.test.InstrumentationTestRunner.MEDIUM_SUITE.equals ( sizeArg ) ) { return android.test.suitebuilder.TestPredicates.SELECT_MEDIUM ; } else if ( android.test.InstrumentationTestRunner.LARGE_SUITE.equals ( sizeArg ) ) { return android.test.suitebuilder.TestPredicates.SELECT_LARGE ; } else { return null ; } }

Target:
private com.android.internal.util.Predicate < android.test.suitebuilder.TestMethod > getSizePredicateFromArg ( java.lang.String sizeArg ) { if ( android.test.InstrumentationTestRunner.SMALL_SUITE.equals ( sizeArg ) ) { return android.test.InstrumentationTestRunner.SELECT_SMALL ; } else if ( android.test.InstrumentationTestRunner.MEDIUM_SUITE.equals ( sizeArg ) ) { return android.test.InstrumentationTestRunner.SELECT_MEDIUM ; } else if ( android.test.InstrumentationTestRunner.LARGE_SUITE.equals ( sizeArg ) ) { return android.test.InstrumentationTestRunner.SELECT_LARGE ; } else { return null ; } }
Source:
private java.util.Collection < com.android.jack.preprocessor.Rule > parseRules ( @ javax.annotation.Nonnull com.android.jack.ir.ast.JSession session , @ javax.annotation.Nonnull java.io.Reader reader , @ javax.annotation.Nonnull com.android.sched.util.location.Location location ) throws java.io.IOException , org.antlr.runtime.RecognitionException { org.antlr.runtime.ANTLRReaderStream in = new org.antlr.runtime.ANTLRReaderStream ( reader ) ; com.android.jack.preprocessor.PreProcessorLexer lexer = new com.android.jack.preprocessor.PreProcessorLexer ( in ) ; org.antlr.runtime.CommonTokenStream tokens = new org.antlr.runtime.CommonTokenStream ( lexer ) ; com.android.jack.preprocessor.PreProcessorParser parser = new com.android.jack.preprocessor.PreProcessorParser ( tokens ) ; return parser.rules ( session , location ) ; }

Target:
private java.util.Collection < com.android.jack.preprocessor.Rule > parseRules ( @ javax.annotation.Nonnull com.android.jack.ir.ast.JSession session , @ javax.annotation.Nonnull java.io.Reader reader , @ javax.annotation.Nonnull com.android.sched.util.location.Location location ) throws com.android.sched.util.file.CannotReadException , org.antlr.runtime.RecognitionException { org.antlr.runtime.ANTLRReaderStream in ; try { in = new org.antlr.runtime.ANTLRReaderStream ( reader ) ; } catch ( java.io.IOException e ) { throw new com.android.sched.util.file.CannotReadException ( location , e ) ; } com.android.jack.preprocessor.PreProcessorLexer lexer = new com.android.jack.preprocessor.PreProcessorLexer ( in ) ; org.antlr.runtime.CommonTokenStream tokens = new org.antlr.runtime.CommonTokenStream ( lexer ) ; com.android.jack.preprocessor.PreProcessorParser parser = new com.android.jack.preprocessor.PreProcessorParser ( tokens ) ; return parser.rules ( session , location ) ; }
Source:
public static java.lang.String getSyntheticSwitchMapInitializerName ( com.android.jack.ir.ast.JDefinedEnum enumType ) { java.lang.String enumName = com.android.jack.Jack.getLookupFormatter ( ) . getName ( enumType ) ; enumName = enumName.substring ( 1 , ( ( enumName.length ( ) ) - 1 ) ) . replace ( '/' , '_' ) ; return ( ( com.android.jack.transformations.enums.OptimizationUtil.LongerPrefix ) + enumName ) + ( com.android.jack.transformations.enums.OptimizationUtil.Suffix ) ; }

Target:
public static java.lang.String getSyntheticSwitchMapInitializerName ( @ javax.annotation.Nonnull com.android.jack.ir.ast.JDefinedEnum enumType ) { java.lang.String enumName = com.android.jack.util.NamingTools.getValidName ( com.android.jack.ir.formatter.BinaryQualifiedNameFormatter.getFormatter ( ) . getName ( enumType ) ) ; java.lang.String methodName = com.android.jack.util.NamingTools.getNonSourceConflictingName ( ( ( "get" + enumName ) + ( com.android.jack.transformations.enums.OptimizationUtil.Suffix ) ) ) ; return methodName ; }
Source:
void assertCallDisplayName ( final android.telecom.Call call , final java.lang.String name ) { waitUntilConditionIsTrueOrTimeout ( new android.telecom.cts.BaseTelecomTestWithMockServices.Condition ( ) { @ java.lang.Override public java.lang.Object expected ( ) { return name ; } @ java.lang.Override public java.lang.Object actual ( ) { return call.getDetails ( ) . getCallerDisplayName ( ) ; } } , android.telecom.cts.WAIT_FOR_STATE_CHANGE_TIMEOUT_MS , ( "Call should have display name: " + name ) ) ; }

Target:
void assertCallDisplayName ( final android.telecom.Call call , final java.lang.String name ) { waitUntilConditionIsTrueOrTimeout ( new android.telecom.cts.BaseTelecomTestWithMockServices.Condition ( ) { @ java.lang.Override public java.lang.Object expected ( ) { return name ; } @ java.lang.Override public java.lang.Object actual ( ) { return call.getDetails ( ) . getCallerDisplayName ( ) ; } } , android.telecom.cts.TestUtils.WAIT_FOR_STATE_CHANGE_TIMEOUT_MS , ( "Call should have display name: " + name ) ) ; }
Source:
static void writeStringStringMap ( java.util.Map < java.lang.String , java.lang.String > map , java.io.OutputStream os ) throws java.io.IOException { if ( map != null ) { com.android.volley.toolbox.DiskBasedCache.writeInt ( os , map.size ( ) ) ; for ( java.util.Map.Entry < java.lang.String , java.lang.String > entry : map.entrySet ( ) ) { com.android.volley.toolbox.DiskBasedCache.writeString ( os , entry.getKey ( ) ) ; com.android.volley.toolbox.DiskBasedCache.writeString ( os , entry.getValue ( ) ) ; } } else { com.android.volley.toolbox.DiskBasedCache.writeInt ( os , 0 ) ; } }

Target:
static void writeHeaderList ( java.util.List < com.android.volley.Header > headers , java.io.OutputStream os ) throws java.io.IOException { if ( headers != null ) { com.android.volley.toolbox.DiskBasedCache.writeInt ( os , headers.size ( ) ) ; for ( com.android.volley.Header header : headers ) { com.android.volley.toolbox.DiskBasedCache.writeString ( os , header.getName ( ) ) ; com.android.volley.toolbox.DiskBasedCache.writeString ( os , header.getValue ( ) ) ; } } else { com.android.volley.toolbox.DiskBasedCache.writeInt ( os , 0 ) ; } }
Source:
protected java.lang.Void doInBackground ( java.lang.Void ... voids ) { testIdleConstraintFails_notIdle ( ) ; if ( ! ( sendBroadcastAndBlockForResult ( new android.content.Intent ( com.android.cts.verifier.jobscheduler.IdleConstraintTestActivity.ACTION_EXPEDITE_IDLE_MODE ) ) ) ) { runOnUiThread ( new com.android.cts.verifier.jobscheduler.IdleConstraintTestActivity.IdleTestResultRunner ( com.android.cts.verifier.jobscheduler.IdleConstraintTestActivity.IDLE_ON_JOB_ID , false ) ) ; } testIdleConstraintExecutes_onIdle ( ) ; notifyTestCompleted ( ) ; return null ; }

Target:
protected java.lang.Void doInBackground ( android.os.PowerManager ... wakeLocks ) { mPartialWakeLock = wakeLocks [ 0 ] ; if ( ! ( sendBroadcastAndBlockForResult ( new android.content.Intent ( com.android.cts.verifier.jobscheduler.IdleConstraintTestActivity.ACTION_EXPEDITE_IDLE_MODE ) ) ) ) { runOnUiThread ( new com.android.cts.verifier.jobscheduler.IdleConstraintTestActivity.IdleTestResultRunner ( com.android.cts.verifier.jobscheduler.IdleConstraintTestActivity.IDLE_ON_JOB_ID , false ) ) ; } else { testIdleConstraintExecutes_onIdle ( ) ; } notifyTestCompleted ( ) ; return null ; }