auphong2707/dl4se-code-review-dataset huggingface dataset:
Source:
public void startLockTaskModeOnCurrent ( ) throws android.os.RemoteException { enforceCallingPermission ( android.Manifest.permission.MANAGE_ACTIVITY_STACKS , "startLockTaskModeOnCurrent" ) ; long ident = android.os.Binder.clearCallingIdentity ( ) ; try { synchronized ( this ) { com.android.server.am.ActivityRecord r = mStackSupervisor.topRunningActivityLocked ( ) ; if ( r != null ) { startLockTaskModeLocked ( r.task ) ; } } } finally { android.os.Binder.restoreCallingIdentity ( ident ) ; } }

Target:
public ActivityManager.TaskThumbnail getTaskThumbnail ( int id ) { synchronized ( this ) { enforceCallingPermission ( android.Manifest.permission.READ_FRAME_BUFFER , "getTaskThumbnail()" ) ; final com.android.server.am.TaskRecord tr = mStackSupervisor.anyTaskForIdLocked ( id , ( ! ( com.android.server.am.ActivityStackSupervisor.RESTORE_FROM_RECENTS ) ) , StackId.INVALID_STACK_ID ) ; if ( tr != null ) { return tr.getTaskThumbnailLocked ( ) ; } } return null ; }
Source:
public android.net.wifi.hotspot2.pps.Policy.RoamingPartner createFromParcel ( android.os.Parcel in ) { android.net.wifi.hotspot2.pps.Policy.RoamingPartner roamingPartner = new android.net.wifi.hotspot2.pps.Policy.RoamingPartner ( ) ; roamingPartner.fqdn = in.readString ( ) ; roamingPartner.fqdnExactMatch = ( in.readInt ( ) ) != 0 ; roamingPartner.priority = in.readInt ( ) ; roamingPartner.countries = in.readString ( ) ; return roamingPartner ; }

Target:
public android.net.wifi.hotspot2.pps.Policy.RoamingPartner createFromParcel ( android.os.Parcel in ) { android.net.wifi.hotspot2.pps.Policy.RoamingPartner roamingPartner = new android.net.wifi.hotspot2.pps.Policy.RoamingPartner ( ) ; roamingPartner.setFqdn ( in.readString ( ) ) ; roamingPartner.setFqdnExactMatch ( ( ( in.readInt ( ) ) != 0 ) ) ; roamingPartner.setPriority ( in.readInt ( ) ) ; roamingPartner.setCountries ( in.readString ( ) ) ; return roamingPartner ; }
Source:
public boolean requestScores ( android.net.NetworkKey [ ] networks ) { mContext.enforceCallingOrSelfPermission ( permission.BROADCAST_NETWORK_PRIVILEGED , com.android.server.NetworkScoreService.TAG ) ; final long token = android.os.Binder.clearCallingIdentity ( ) ; try { final android.net.INetworkRecommendationProvider provider = getRecommendationProvider ( ) ; if ( provider != null ) { try { provider.requestScores ( networks ) ; return true ; } catch ( android.os.RemoteException e ) { android.util.Log.w ( com.android.server.NetworkScoreService.TAG , "Failed to request scores." , e ) ; } } return false ; } finally { android.os.Binder.restoreCallingIdentity ( token ) ; } }

Target:
public boolean requestScores ( android.net.NetworkKey [ ] networks ) { mContext.enforceCallingOrSelfPermission ( permission.REQUEST_NETWORK_SCORES , com.android.server.NetworkScoreService.TAG ) ; final long token = android.os.Binder.clearCallingIdentity ( ) ; try { final android.net.INetworkRecommendationProvider provider = getRecommendationProvider ( ) ; if ( provider != null ) { try { provider.requestScores ( networks ) ; return true ; } catch ( android.os.RemoteException e ) { android.util.Log.w ( com.android.server.NetworkScoreService.TAG , "Failed to request scores." , e ) ; } } return false ; } finally { android.os.Binder.restoreCallingIdentity ( token ) ; } }
Source:
protected boolean removeEldestEntry ( java.util.Map.Entry < org.apache.harmony.xnet.provider.jsse.ByteArray , javax.net.ssl.SSLSession > eldest ) { return ( ( maximumSize ) > 0 ) && ( ( size ( ) ) > ( maximumSize ) ) ; }

Target:
protected boolean removeEldestEntry ( java.util.Map.Entry < org.apache.harmony.xnet.provider.jsse.ByteArray , javax.net.ssl.SSLSession > eldest ) { boolean remove = ( ( maximumSize ) > 0 ) && ( ( size ( ) ) > ( maximumSize ) ) ; if ( remove ) { remove ( eldest.getKey ( ) ) ; sessionRemoved ( eldest.getValue ( ) ) ; } return false ; }
Source:
synchronized void dropClient ( com.android.ddmlib.Client client , boolean notify ) { if ( ( com.android.ddmlib.MonitorThread.mInstance ) == null ) { return ; } synchronized ( mClientList ) { if ( ( mClientList.remove ( client ) ) == false ) { return ; } } client.close ( notify ) ; broadcast ( com.android.ddmlib.MonitorThread.CLIENT_DISCONNECTED , client ) ; wakeup ( ) ; }

Target:
synchronized void dropClient ( com.android.ddmlib.Client client , boolean notify ) { if ( ( com.android.ddmlib.MonitorThread.sInstance ) == null ) { return ; } synchronized ( mClientList ) { if ( ( mClientList.remove ( client ) ) == false ) { return ; } } client.close ( notify ) ; broadcast ( com.android.ddmlib.MonitorThread.CLIENT_DISCONNECTED , client ) ; wakeup ( ) ; }
Source:
private void loadUrl ( java.lang.String url ) { mWebView.loadUrl ( url ) ; mWebView.requestFocus ( ) ; }

Target:
private void loadUrl ( java.lang.String url ) { if ( ( ( ( Build.VERSION.SDK_INT ) >= ( Build.VERSION_CODES.M ) ) && ( "file" . equals ( android.net.Uri.parse ( url ) . getScheme ( ) ) ) ) && ( ( android.content.pm.PackageManager.PERMISSION_DENIED ) == ( checkSelfPermission ( Manifest.permission.READ_EXTERNAL_STORAGE ) ) ) ) { requestPermissionsForPage ( new org.chromium.webview_shell.WebViewBrowserActivity.FilePermissionRequest ( url ) ) ; } mWebView.loadUrl ( url ) ; mWebView.requestFocus ( ) ; }
Source:
public int setAllowedCarriers ( int slotIndex , java.util.List < android.service.carrier.CarrierIdentifier > carriers ) { enforceModifyPermission ( ) ; int subId = android.telephony.SubscriptionManager.getSubId ( slotIndex ) [ 0 ] ; int [ ] retVal = ( ( int [ ] ) ( sendRequest ( com.android.phone.PhoneInterfaceManager.CMD_SET_ALLOWED_CARRIERS , carriers , subId ) ) ) ; return retVal [ 0 ] ; }

Target:
public int setAllowedCarriers ( int slotIndex , java.util.List < android.service.carrier.CarrierIdentifier > carriers ) { enforceModifyPermission ( ) ; if ( carriers == null ) { throw new java.lang.NullPointerException ( "carriers cannot be null" ) ; } int subId = android.telephony.SubscriptionManager.getSubId ( slotIndex ) [ 0 ] ; int [ ] retVal = ( ( int [ ] ) ( sendRequest ( com.android.phone.PhoneInterfaceManager.CMD_SET_ALLOWED_CARRIERS , carriers , subId ) ) ) ; return retVal [ 0 ] ; }
Source:
public void setSoWriteTimeout ( int writeTimeoutMilliseconds ) throws java.net.SocketException { this . writeTimeoutMilliseconds = writeTimeoutMilliseconds ; libcore.io.StructTimeval tv = libcore.io.StructTimeval.fromMillis ( writeTimeoutMilliseconds ) ; try { Libcore.os.setsockoptTimeval ( getFileDescriptor$ ( ) , libcore.io.OsConstants.SOL_SOCKET , libcore.io.OsConstants.SO_SNDTIMEO , tv ) ; } catch ( libcore.io.ErrnoException errnoException ) { throw errnoException.rethrowAsSocketException ( ) ; } }

Target:
public void setSoWriteTimeout ( int writeTimeoutMilliseconds ) throws java.net.SocketException { this . writeTimeoutMilliseconds = writeTimeoutMilliseconds ; android.system.StructTimeval tv = android.system.StructTimeval.fromMillis ( writeTimeoutMilliseconds ) ; try { Libcore.os.setsockoptTimeval ( getFileDescriptor$ ( ) , android.system.OsConstants.SOL_SOCKET , android.system.OsConstants.SO_SNDTIMEO , tv ) ; } catch ( android.system.ErrnoException errnoException ) { throw errnoException.rethrowAsSocketException ( ) ; } }
Source:
public void handleMessage ( android.os.Message msg ) { switch ( msg.what ) { case android.widget.TextView.Marquee.MESSAGE_START : mStatus = android.widget.TextView.Marquee.MARQUEE_RUNNING ; tick ( ) ; break ; case android.widget.TextView.Marquee.MESSAGE_TICK : tick ( ) ; break ; case android.widget.TextView.Marquee.MESSAGE_RESTART : if ( ( mStatus ) == ( android.widget.TextView.Marquee.MARQUEE_RUNNING ) ) { if ( ( mRepeatLimit ) >= 0 ) { ( mRepeatLimit ) -- ; } start ( mRepeatLimit ) ; } break ; } }

Target:
public void doFrame ( long frameTimeNanos ) { if ( ( mStatus ) == ( android.widget.TextView.Marquee.MARQUEE_RUNNING ) ) { if ( ( mRepeatLimit ) >= 0 ) { ( mRepeatLimit ) -- ; } start ( mRepeatLimit ) ; } }
Source:
private com.android.jack.optimizations.valuepropagation.CompilationProperties defaultProperties ( ) { return CompilationProperties.EMPTY.excludeJillToolchain ( ) . withPreserveJls ( false ) . withPreserveReflections ( false ) . with ( Optimizations.FieldValuePropagation.ENSURE_TYPE_INITIALIZERS.getName ( ) , java.lang.Boolean.FALSE ) . with ( Optimizations.FieldValuePropagation.REMOVE_NULL_CHECKS.getName ( ) , java.lang.Boolean.TRUE ) . with ( Optimizations.FieldValuePropagation.ENABLE.getName ( ) , java.lang.Boolean.TRUE ) . with ( Optimizations.ArgumentValuePropagation.ENABLE.getName ( ) , java.lang.Boolean.TRUE ) ; }

Target:
private com.android.jack.optimizations.valuepropagation.CompilationProperties defaultProperties ( ) { return CompilationProperties.EMPTY.excludeJillToolchain ( ) . with ( Optimizations.FieldValuePropagation.ENSURE_TYPE_INITIALIZERS.getName ( ) , java.lang.Boolean.FALSE ) . with ( Optimizations.FieldValuePropagation.PRESERVE_NULL_CHECKS.getName ( ) , java.lang.Boolean.FALSE ) . with ( Optimizations.FieldValuePropagation.ENABLE.getName ( ) , java.lang.Boolean.TRUE ) . with ( Optimizations.ArgumentValuePropagation.ENABLE.getName ( ) , java.lang.Boolean.TRUE ) ; }
Source:
public boolean disableDataConnectivity ( ) { enforceModifyPermission ( ) ; int subId = mSubscriptionController.getDefaultDataSubId ( ) ; final com.android.internal.telephony.Phone phone = getPhone ( subId ) ; if ( phone != null ) { phone.setDataEnabled ( false ) ; return true ; } else { return false ; } }

Target:
public boolean disableDataConnectivity ( ) { enforceModifyPermission ( ) ; int subId = mSubscriptionController.getDefaultDataSubId ( ) ; final com.android.internal.telephony.Phone phone = getPhone ( subId ) ; if ( phone != null ) { phone.setUserDataEnabled ( false ) ; return true ; } else { return false ; } }
Source:
public boolean retainAll ( java.util.Collection < ? > c ) { boolean modified = false ; java.util.Iterator < E > it = iterator ( ) ; while ( it.hasNext ( ) ) { if ( ! ( c.contains ( it.next ( ) ) ) ) { it.remove ( ) ; modified = true ; } } return modified ; }

Target:
public boolean retainAll ( java.util.Collection < ? > c ) { java.util.Objects.requireNonNull ( c ) ; boolean modified = false ; java.util.Iterator < E > it = iterator ( ) ; while ( it.hasNext ( ) ) { if ( ! ( c.contains ( it.next ( ) ) ) ) { it.remove ( ) ; modified = true ; } } return modified ; }
Source:
public final void testPkgTypePlatformTool ( ) { com.android.sdklib.repository.descriptors.IPkgCapabilities p = PkgType.PKG_PLATFORM_TOOLS ; assertFalse ( p.hasMajorRevision ( ) ) ; assertTrue ( p.hasFullRevision ( ) ) ; assertFalse ( p.hasAndroidVersion ( ) ) ; assertFalse ( p.hasPath ( ) ) ; assertFalse ( p.hasMinToolsRev ( ) ) ; assertFalse ( p.hasMinPlatformToolsRev ( ) ) ; }

Target:
public final void testPkgTypePlatformTool ( ) { com.android.sdklib.repository.descriptors.IPkgCapabilities p = PkgType.PKG_PLATFORM_TOOLS ; assertFalse ( p.hasMajorRevision ( ) ) ; assertTrue ( p.hasFullRevision ( ) ) ; assertFalse ( p.hasAndroidVersion ( ) ) ; assertFalse ( p.hasPath ( ) ) ; assertFalse ( p.hasVendorId ( ) ) ; assertFalse ( p.hasMinToolsRev ( ) ) ; assertFalse ( p.hasMinPlatformToolsRev ( ) ) ; }
Source:
private com.android.dialer.simulator.portal.SimulatorPortalEntryGroup buildSimulatorNotificationsPortal ( ) { return com.android.dialer.simulator.portal.SimulatorPortalEntryGroup.builder ( ) . setMethods ( com.google.common.collect.ImmutableMap.< java.lang.String , java.lang.Runnable > builder ( ) . put ( "Missed calls" , ( ) -> new com.android.dialer.simulator.impl.SimulatorMissedCallCreator ( context ) . start ( SimulatorUtils.NOTIFICATION_COUNT ) ) . put ( "Missed calls (few)" , ( ) -> new com.android.dialer.simulator.impl.SimulatorMissedCallCreator ( context ) . start ( SimulatorUtils.NOTIFICATION_COUNT_FEW ) ) . put ( "Voicemails" , ( ) -> com.android.dialer.simulator.impl.SimulatorUtils.addVoicemailNotifications ( context , SimulatorUtils.NOTIFICATION_COUNT ) ) . build ( ) ) . build ( ) ; }

Target:
private com.android.dialer.simulator.impl.SimulatorPortalEntryGroup buildSimulatorNotificationsPortal ( ) { return com.android.dialer.simulator.impl.SimulatorPortalEntryGroup.builder ( ) . setMethods ( com.google.common.collect.ImmutableMap.< java.lang.String , java.lang.Runnable > builder ( ) . put ( "Missed calls" , ( ) -> new com.android.dialer.simulator.impl.SimulatorMissedCallCreator ( context ) . start ( SimulatorUtils.NOTIFICATION_COUNT ) ) . put ( "Missed calls (few)" , ( ) -> new com.android.dialer.simulator.impl.SimulatorMissedCallCreator ( context ) . start ( SimulatorUtils.NOTIFICATION_COUNT_FEW ) ) . put ( "Voicemails" , ( ) -> com.android.dialer.simulator.impl.SimulatorUtils.addVoicemailNotifications ( context , SimulatorUtils.NOTIFICATION_COUNT ) ) . build ( ) ) . build ( ) ; }
Source:
private com.android.server.wifi.NetworkUpdateResult verifyAddEphemeralNetworkToWifiConfigManager ( android.net.wifi.WifiConfiguration configuration ) { com.android.server.wifi.NetworkUpdateResult result = addNetworkToWifiConfigManager ( configuration ) ; assertTrue ( ( ( result.getNetworkId ( ) ) != ( android.net.wifi.WifiConfiguration.INVALID_NETWORK_ID ) ) ) ; assertTrue ( result.isNewNetwork ( ) ) ; assertTrue ( result.hasIpChanged ( ) ) ; assertTrue ( result.hasProxyChanged ( ) ) ; verifyNetworkAddBroadcast ( configuration ) ; verifyNetworkNotInConfigStoreData ( configuration ) ; return result ; }

Target:
private boolean isNetworkInConfigStoreData ( android.net.wifi.WifiConfiguration configuration ) { com.android.server.wifi.WifiConfigStoreData storeData = captureWriteStoreData ( ) ; if ( storeData == null ) { return false ; } return isNetworkInConfigStoreData ( configuration , storeData ) ; }
Source:
private void addAuthParam ( com.android.server.wifi.hotspot2.anqp.eap.AuthParam param ) { java.util.Set < com.android.server.wifi.hotspot2.anqp.eap.AuthParam > authParams = mAuthParams.get ( param.getAuthInfoID ( ) ) ; if ( authParams == null ) { authParams = new java.util.HashSet < > ( ) ; mAuthParams.put ( param.getAuthInfoID ( ) , authParams ) ; } authParams.add ( param ) ; }

Target:
private static void addAuthParam ( java.util.Map < java.lang.Integer , java.util.Set < com.android.server.wifi.hotspot2.anqp.eap.AuthParam > > paramsMap , com.android.server.wifi.hotspot2.anqp.eap.AuthParam authParam ) { java.util.Set < com.android.server.wifi.hotspot2.anqp.eap.AuthParam > authParams = paramsMap.get ( authParam.getAuthTypeID ( ) ) ; if ( authParams == null ) { authParams = new java.util.HashSet < > ( ) ; paramsMap.put ( authParam.getAuthTypeID ( ) , authParams ) ; } authParams.add ( authParam ) ; }
Source:
public boolean offer ( E e ) { java.util.concurrent.ArrayBlockingQueue.checkNotNull ( e ) ; final java.util.concurrent.locks.ReentrantLock lock = this . lock ; lock.lock ( ) ; try { if ( ( count ) == ( items.length ) ) return false ; else { insert ( e ) ; return true ; } } finally { lock.unlock ( ) ; } }

Target:
public boolean offer ( E e ) { java.util.concurrent.ArrayBlockingQueue.checkNotNull ( e ) ; final java.util.concurrent.locks.ReentrantLock lock = this . lock ; lock.lock ( ) ; try { if ( ( count ) == ( items.length ) ) return false ; else { enqueue ( e ) ; return true ; } } finally { lock.unlock ( ) ; } }
Source:
protected static com.android.jack.ir.InternalCompilerException translateException ( @ javax.annotation.Nonnull com.android.jack.ir.ast.JNode node , @ javax.annotation.Nonnull java.lang.Throwable e ) { if ( e instanceof java.lang.VirtualMachineError ) { throw ( ( java.lang.VirtualMachineError ) ( e ) ) ; } com.android.jack.ir.InternalCompilerException ice ; if ( e instanceof com.android.jack.ir.InternalCompilerException ) { ice = ( ( com.android.jack.ir.InternalCompilerException ) ( e ) ) ; } else { ice = new com.android.jack.ir.InternalCompilerException ( "Unexpected error during visit." , e ) ; } ice.addNode ( node ) ; return ice ; }

Target:
protected static com.android.jack.ir.JNodeInternalError translateException ( @ javax.annotation.Nonnull com.android.jack.ir.ast.JNode node , @ javax.annotation.Nonnull java.lang.Throwable e ) { if ( e instanceof java.lang.VirtualMachineError ) { throw ( ( java.lang.VirtualMachineError ) ( e ) ) ; } com.android.jack.ir.JNodeInternalError ice ; if ( e instanceof com.android.jack.ir.JNodeInternalError ) { ice = ( ( com.android.jack.ir.JNodeInternalError ) ( e ) ) ; } else { ice = new com.android.jack.ir.JNodeInternalError ( "Unexpected error during visit." , e ) ; } ice.addNode ( node ) ; return ice ; }
Source:
public void testIsLanguageAvailable ( ) { com.android.speech.tts.MockableTextToSpeechService.IDelegate delegate = com.google.testing.littlemock.LittleMock.mock ( com.android.speech.tts.MockableTextToSpeechService.IDelegate.class ) ; com.android.speech.tts.MockableTextToSpeechService.setMocker ( delegate ) ; com.google.testing.littlemock.LittleMock.doReturn ( TextToSpeech.LANG_COUNTRY_AVAILABLE ) . when ( delegate ) . onIsLanguageAvailable ( "eng" , "USA" , "" ) ; assertEquals ( TextToSpeech.LANG_COUNTRY_AVAILABLE , mTts.isLanguageAvailable ( java.util.Locale.US ) ) ; com.google.testing.littlemock.LittleMock.verify ( delegate , com.google.testing.littlemock.LittleMock.times ( 1 ) ) . onIsLanguageAvailable ( "eng" , "USA" , "" ) ; }

Target:
public void testIsLanguageAvailable ( ) { com.android.speech.tts.MockableTextToSpeechService.IDelegate delegate = org.mockito.Mockito.mock ( com.android.speech.tts.MockableTextToSpeechService.IDelegate.class ) ; com.android.speech.tts.MockableTextToSpeechService.setMocker ( delegate ) ; org.mockito.Mockito.doReturn ( TextToSpeech.LANG_COUNTRY_AVAILABLE ) . when ( delegate ) . onIsLanguageAvailable ( "eng" , "USA" , "" ) ; assertEquals ( TextToSpeech.LANG_COUNTRY_AVAILABLE , mTts.isLanguageAvailable ( java.util.Locale.US ) ) ; org.mockito.Mockito.verify ( delegate , org.mockito.Mockito.times ( 1 ) ) . onIsLanguageAvailable ( "eng" , "USA" , "" ) ; }
Source:
private void createContextMenu ( ) { mMenuManager = new org.eclipse.jface.action.MenuManager ( ) { @ java.lang.Override public boolean isDynamic ( ) { return true ; } } ; setupStaticMenuActions ( mMenuManager ) ; new com.android.ide.eclipse.adt.internal.editors.layout.gle2.DynamicContextMenu ( mLayoutEditor , this , mMenuManager ) ; org.eclipse.swt.widgets.Menu menu = mMenuManager.createContextMenu ( this ) ; setMenu ( menu ) ; }

Target:
public void menuDetected ( org.eclipse.swt.events.MenuDetectEvent e ) { mSelectionManager.menuClick ( e ) ; }
Source:
static android.telephony.SignalStrength convertHalSignalStrength ( com.android.internal.telephony.V1_0.SignalStrength signalStrength ) { return new android.telephony.SignalStrength ( signalStrength.gw.signalStrength , signalStrength.gw.bitErrorRate , signalStrength.cdma.dbm , signalStrength.cdma.ecio , signalStrength.evdo.dbm , signalStrength.evdo.ecio , signalStrength.evdo.signalNoiseRatio , signalStrength.lte.signalStrength , signalStrength.lte.rsrp , signalStrength.lte.rsrq , signalStrength.lte.rssnr , signalStrength.lte.cqi , signalStrength.tdScdma.rscp ) ; }

Target:
static android.telephony.SignalStrength convertHalSignalStrength ( com.android.internal.telephony.V1_0.SignalStrength signalStrength ) { int tdscdmaRscp_1_2 = 255 ; if ( ( ( signalStrength.tdScdma.rscp ) >= 25 ) && ( ( signalStrength.tdScdma.rscp ) <= 120 ) ) { int rscpDbm = - ( signalStrength.tdScdma.rscp ) ; tdscdmaRscp_1_2 = rscpDbm + 120 ; } return new android.telephony.SignalStrength ( signalStrength.gw.signalStrength , signalStrength.gw.bitErrorRate , signalStrength.cdma.dbm , signalStrength.cdma.ecio , signalStrength.evdo.dbm , signalStrength.evdo.ecio , signalStrength.evdo.signalNoiseRatio , signalStrength.lte.signalStrength , signalStrength.lte.rsrp , signalStrength.lte.rsrq , signalStrength.lte.rssnr , signalStrength.lte.cqi , tdscdmaRscp_1_2 ) ; }
Source:
public java.io.File getJackLibraryOutputZip ( ) { return libraryOutZip ; }

Target:
public java.util.List < java.lang.String > getEcjArguments ( ) { if ( ( inputSources ) == null ) { return ecjExtraArguments ; } java.util.ArrayList < java.lang.String > list = new java.util.ArrayList < java.lang.String > ( ecjExtraArguments ) ; for ( java.io.File input : inputSources ) { list.add ( input.getPath ( ) ) ; } return list ; }
Source:
private void broadcastConnectionState ( android.bluetooth.BluetoothDevice device , int newState , int prevState ) { int delay = mAudioManager.setBluetoothA2dpDeviceConnectionState ( device , newState , BluetoothProfile.A2DP ) ; mWakeLock.acquire ( ) ; mIntentBroadcastHandler.sendMessageDelayed ( mIntentBroadcastHandler.obtainMessage ( com.android.bluetooth.a2dp.A2dpStateMachine.MSG_CONNECTION_STATE_CHANGED , prevState , newState , device ) , delay ) ; }

Target:
private void broadcastConnectionState ( android.bluetooth.BluetoothDevice device , int newState , int prevState ) { mAudioManager.setBluetoothA2dpDeviceConnectionState ( device , newState , BluetoothProfile.A2DP ) ; mWakeLock.acquire ( ) ; mIntentBroadcastHandler.sendMessage ( mIntentBroadcastHandler.obtainMessage ( com.android.bluetooth.a2dp.A2dpStateMachine.MSG_CONNECTION_STATE_CHANGED , prevState , newState , device ) ) ; }
Source:
public java.lang.String getDisplayVariant ( java.util.Locale locale ) { if ( ( variantCode.length ( ) ) == 0 ) { return variantCode ; } java.lang.String result = libcore.icu.ICU.getDisplayVariantNative ( getIcuLocaleId ( ) , locale.getIcuLocaleId ( ) ) ; if ( result == null ) { result = libcore.icu.ICU.getDisplayVariantNative ( getIcuLocaleId ( ) , java.util.Locale.getDefault ( ) . getIcuLocaleId ( ) ) ; } return result ; }

Target:
public java.lang.String getDisplayVariant ( java.util.Locale locale ) { if ( variantCode.isEmpty ( ) ) { return "" ; } try { java.util.Locale.Builder.normalizeAndValidateVariant ( variantCode ) ; } catch ( java.util.IllformedLocaleException ilfe ) { return variantCode ; } java.lang.String result = libcore.icu.ICU.getDisplayVariant ( this , locale ) ; if ( result == null ) { result = libcore.icu.ICU.getDisplayVariant ( this , java.util.Locale.getDefault ( ) ) ; } if ( result.isEmpty ( ) ) { return variantCode ; } return result ; }
Source:
public boolean onPreferenceTreeClick ( android.preference.PreferenceScreen preferenceScreen , android.preference.Preference preference ) { if ( preference.getKey ( ) . equals ( com.android.phone.CdmaOptions.BUTTON_CDMA_ROAMING_KEY ) ) { return true ; } return false ; }

Target:
public boolean preferenceTreeClick ( android.preference.Preference preference ) { if ( preference.getKey ( ) . equals ( com.android.phone.CdmaOptions.BUTTON_CDMA_SYSTEM_SELECT_KEY ) ) { log ( "preferenceTreeClick: return BUTTON_CDMA_ROAMING_KEY true" ) ; return true ; } if ( preference.getKey ( ) . equals ( com.android.phone.CdmaOptions.BUTTON_CDMA_SUBSCRIPTION_KEY ) ) { log ( "preferenceTreeClick: return CDMA_SUBSCRIPTION_KEY true" ) ; return true ; } return false ; }
Source:
public int getState ( ) { if ( android.bluetooth.BluetoothPbap.VDBG ) android.bluetooth.BluetoothPbap.log ( "getState()" ) ; final android.bluetooth.IBluetoothPbap service = mService ; if ( service != null ) { try { return service.getState ( ) ; } catch ( android.os.RemoteException e ) { android.util.Log.e ( android.bluetooth.BluetoothPbap.TAG , e.toString ( ) ) ; } } else { android.util.Log.w ( android.bluetooth.BluetoothPbap.TAG , "Proxy not attached to service" ) ; if ( android.bluetooth.BluetoothPbap.DBG ) android.bluetooth.BluetoothPbap.log ( android.util.Log.getStackTraceString ( new java.lang.Throwable ( ) ) ) ; } return BluetoothProfile.STATE_DISCONNECTED ; }

Target:
public java.util.List < android.bluetooth.BluetoothDevice > getConnectedDevices ( ) { android.bluetooth.BluetoothPbap.log ( "getConnectedDevices()" ) ; final android.bluetooth.IBluetoothPbap service = mService ; if ( service == null ) { android.util.Log.w ( android.bluetooth.BluetoothPbap.TAG , "Proxy not attached to service" ) ; return new java.util.ArrayList < android.bluetooth.BluetoothDevice > ( ) ; } try { return service.getConnectedDevices ( ) ; } catch ( android.os.RemoteException e ) { android.util.Log.e ( android.bluetooth.BluetoothPbap.TAG , e.toString ( ) ) ; } return new java.util.ArrayList < android.bluetooth.BluetoothDevice > ( ) ; }
Source:
private int getSubId ( ) { if ( ( mSubId ) == ( SubscriptionManager.DEFAULT_SUBSCRIPTION_ID ) ) { return android.telephony.TelephonyManager.getDefaultSubscription ( ) ; } return mSubId ; }

Target:
public int getVoiceActivationState ( int subId ) { try { com.android.internal.telephony.ITelephony telephony = getITelephony ( ) ; if ( telephony != null ) return telephony.getVoiceActivationState ( subId , getOpPackageName ( ) ) ; } catch ( android.os.RemoteException ex ) { } catch ( java.lang.NullPointerException ex ) { } return android.telephony.TelephonyManager.SIM_ACTIVATION_STATE_UNKNOWN ; }
Source:
public void onCreateButtonActions ( java.util.List < android.support.v17.leanback.widget.GuidedAction > actions , android.os.Bundle savedInstanceState ) { actions.add ( new android.support.v17.leanback.widget.GuidedAction.Builder ( getActivity ( ) ) . clickAction ( GuidedAction.ACTION_ID_OK ) . build ( ) ) ; actions.add ( new android.support.v17.leanback.widget.GuidedAction.Builder ( getActivity ( ) ) . clickAction ( GuidedAction.ACTION_ID_CANCEL ) . build ( ) ) ; }

Target:
public void onCreateActions ( java.util.List < android.support.v17.leanback.widget.GuidedAction > actions , android.os.Bundle savedInstanceState ) { mPriorityGuidedAction = new android.support.v17.leanback.widget.GuidedAction.Builder ( getActivity ( ) ) . id ( com.android.tv.dvr.ui.DvrSeriesSettingsFragment.ACTION_ID_PRIORITY ) . title ( mProrityActionTitle ) . build ( ) ; actions.add ( mPriorityGuidedAction ) ; mChannelsGuidedAction = new android.support.v17.leanback.widget.GuidedAction.Builder ( getActivity ( ) ) . id ( com.android.tv.dvr.ui.DvrSeriesSettingsFragment.ACTION_ID_CHANNEL ) . title ( mChannelsActionTitle ) . subActions ( buildChannelSubAction ( ) ) . build ( ) ; actions.add ( mChannelsGuidedAction ) ; updateChannelsGuidedAction ( false ) ; }
Source:
public void fillPresentationAttributes ( java.lang.String name , java.lang.String value ) { com.android.assetstudiolib.vectordrawable.SvgLeafNode.logger.log ( java.util.logging.Level.FINE , ( ( ( ">>>> PROP " + name ) + " = " ) + value ) ) ; mVdAttributesMap.put ( name , value ) ; }

Target:
public void fillPresentationAttributes ( java.lang.String name , java.lang.String value ) { com.android.assetstudiolib.vectordrawable.SvgLeafNode.logger.log ( java.util.logging.Level.FINE , ( ( ( ">>>> PROP " + name ) + " = " ) + value ) ) ; if ( value.startsWith ( "url(" ) ) { getTree ( ) . logErrorLine ( ( "Unsupported URL value: " + value ) , getDocumentNode ( ) , SvgTree.SvgLogLevel.ERROR ) ; return ; } mVdAttributesMap.put ( name , value ) ; }
Source:
public java.lang.String getMeidForSlot ( int slotIndex , java.lang.String callingPackage ) { if ( ! ( com.android.internal.telephony.TelephonyPermissions.checkCallingOrSelfReadPhoneState ( mApp , callingPackage , "getMeidForSlot" ) ) ) { return null ; } com.android.internal.telephony.Phone phone = com.android.internal.telephony.PhoneFactory.getPhone ( slotIndex ) ; return phone == null ? null : phone.getMeid ( ) ; }

Target:
public void setRadioIndicationUpdateMode ( int subId , int filters , int mode ) { enforceModifyPermission ( ) ; final com.android.internal.telephony.Phone phone = getPhone ( subId ) ; if ( phone == null ) { com.android.phone.PhoneInterfaceManager.loge ( ( "setRadioIndicationUpdateMode fails with invalid subId: " + subId ) ) ; return ; } phone.setRadioIndicationUpdateMode ( filters , mode ) ; }
Source:
public void setSupplicantLogLevel ( java.lang.String level ) { doStringCommand ( ( "LOG_LEVEL " + level ) ) ; }

Target:
void enableVerboseLogging ( int verbose ) { if ( verbose > 0 ) { com.android.server.wifi.WifiNative.DBG = true ; } else { com.android.server.wifi.WifiNative.DBG = false ; } if ( ( mWificondControl ) != null ) { mWificondControl.enableVerboseLogging ( ( verbose > 0 ? true : false ) ) ; } if ( ( mSupplicantStaIfaceHal ) != null ) { mSupplicantStaIfaceHal.enableVerboseLogging ( ( verbose > 0 ) ) ; } if ( ( mWifiVendorHal ) != null ) { mWifiVendorHal.enableVerboseLogging ( ( verbose > 0 ) ) ; } }
Source:
protected native void disconnect0 ( int family ) ;

Target:
protected void disconnect0 ( int family ) { if ( isClosed ( ) ) { return ; } java.net.InetAddress inetAddressUnspec = new java.net.InetAddress ( ) ; inetAddressUnspec.holder ( ) . family = android.system.OsConstants.AF_UNSPEC ; try { libcore.io.IoBridge.connect ( fd , inetAddressUnspec , 0 ) ; } catch ( java.net.SocketException ignored ) { } }
Source:
private static void addBodyIfExists ( java.net.HttpURLConnection connection , com.android.volley.Request < ? > request ) throws com.android.volley.AuthFailureError , java.io.IOException { byte [ ] body = request.getBody ( ) ; if ( body != null ) { connection.setDoOutput ( true ) ; connection.addRequestProperty ( com.android.volley.toolbox.HurlStack.HEADER_CONTENT_TYPE , request.getBodyContentType ( ) ) ; java.io.DataOutputStream out = new java.io.DataOutputStream ( connection.getOutputStream ( ) ) ; out.write ( body ) ; out.close ( ) ; } }

Target:
private static void addBodyIfExists ( java.net.HttpURLConnection connection , com.android.volley.Request < ? > request ) throws com.android.volley.AuthFailureError , java.io.IOException { byte [ ] body = request.getBody ( ) ; if ( body != null ) { com.android.volley.toolbox.HurlStack.addBody ( connection , request , body ) ; } }
Source:
public int hashCode ( ) { int hash = 17 ; hash = ( 31 * hash ) + ( mLocation.hashCode ( ) ) ; hash = ( 31 * hash ) + ( mAutofocus ? 1 : 0 ) ; hash = ( 31 * hash ) + ( mFlash ? 1 : 0 ) ; return hash ; }

Target:
public int hashCode ( ) { int hash = 17 ; hash = ( 31 * hash ) + ( mLocation.ordinal ( ) ) ; hash = ( 31 * hash ) + ( mAutofocus ? 1 : 0 ) ; hash = ( 31 * hash ) + ( mFlash ? 1 : 0 ) ; return hash ; }
Source:
private byte [ ] getResourceContents ( java.lang.String resourceName ) throws java.io.IOException { try ( java.io.InputStream in = getClass ( ) . getResourceAsStream ( resourceName ) ) { if ( in == null ) { throw new java.lang.IllegalArgumentException ( ( "Resource not found: " + resourceName ) ) ; } return com.android.apksig.ApkVerifierTest.toByteArray ( in ) ; } }

Target:
private void assertVerified ( java.lang.String apkFilenameInResources , java.lang.Integer minSdkVersionOverride , java.lang.Integer maxSdkVersionOverride ) throws java.lang.Exception { com.android.apksig.ApkVerifierTest.assertVerified ( verify ( apkFilenameInResources , minSdkVersionOverride , maxSdkVersionOverride ) ) ; }
Source:
private void loadFrom ( java.io.InputStream in ) throws java.io.IOException { java.io.ByteArrayOutputStream bytesOut = new java.io.ByteArrayOutputStream ( ) ; byte [ ] buffer = new byte [ 8192 ] ; int count ; while ( ( count = in.read ( buffer ) ) != ( - 1 ) ) { bytesOut.write ( buffer , 0 , count ) ; } in.close ( ) ; this . data = bytesOut.toByteArray ( ) ; this . length = data.length ; this . tableOfContents.readFrom ( this ) ; }

Target:
public com.android.dex.Dex.Section open ( int position ) { if ( ( position < 0 ) || ( position >= ( data.capacity ( ) ) ) ) { throw new java.lang.IllegalArgumentException ( ( ( ( "position=" + position ) + " length=" ) + ( data.capacity ( ) ) ) ) ; } java.nio.ByteBuffer sectionData = data.duplicate ( ) ; sectionData.order ( java.nio.ByteOrder.LITTLE_ENDIAN ) ; sectionData.position ( position ) ; sectionData.limit ( data.capacity ( ) ) ; return new com.android.dex.Dex.Section ( "section" , sectionData ) ; }
Source:
public android.net.NetworkStats combineValues ( android.net.NetworkStats.Entry entry ) { final int i = findIndex ( entry.iface , entry.uid , entry.set , entry.tag , entry.roaming ) ; if ( i == ( - 1 ) ) { addValues ( entry ) ; } else { rxBytes [ i ] += entry.rxBytes ; rxPackets [ i ] += entry.rxPackets ; txBytes [ i ] += entry.txBytes ; txPackets [ i ] += entry.txPackets ; operations [ i ] += entry.operations ; } return this ; }

Target:
public android.net.NetworkStats combineValues ( android.net.NetworkStats.Entry entry ) { final int i = findIndex ( entry.iface , entry.uid , entry.set , entry.tag , entry.metered , entry.roaming ) ; if ( i == ( - 1 ) ) { addValues ( entry ) ; } else { rxBytes [ i ] += entry.rxBytes ; rxPackets [ i ] += entry.rxPackets ; txBytes [ i ] += entry.txBytes ; txPackets [ i ] += entry.txPackets ; operations [ i ] += entry.operations ; } return this ; }
Source:
private void unregisterForSimRecordEvents ( ) { com.android.internal.telephony.IccRecords r = mIccRecords.get ( ) ; if ( r == null ) { return ; } r.unregisterForNetworkSelectionModeAutomatic ( this ) ; r.unregisterForNewSms ( this ) ; r.unregisterForRecordsEvents ( this ) ; r.unregisterForRecordsLoaded ( this ) ; }

Target:
private void registerForSimRecordEvents ( ) { com.android.internal.telephony.uicc.IccRecords r = mIccRecords.get ( ) ; if ( r == null ) { return ; } r.registerForNetworkSelectionModeAutomatic ( this , com.android.internal.telephony.gsm.EVENT_SET_NETWORK_AUTOMATIC , null ) ; r.registerForNewSms ( this , com.android.internal.telephony.gsm.EVENT_NEW_ICC_SMS , null ) ; r.registerForRecordsEvents ( this , com.android.internal.telephony.gsm.EVENT_ICC_RECORD_EVENTS , null ) ; r.registerForRecordsLoaded ( this , com.android.internal.telephony.gsm.EVENT_SIM_RECORDS_LOADED , null ) ; }
Source:
com.android.server.ConnectivityServiceTest.CallbackInfo expectCallbackLike ( java.util.function.Predicate < com.android.server.ConnectivityServiceTest.CallbackInfo > fn , int timeoutMs ) { int timeLeft = timeoutMs ; while ( timeLeft > 0 ) { long start = android.os.SystemClock.elapsedRealtime ( ) ; com.android.server.ConnectivityServiceTest.CallbackInfo info = nextCallback ( timeLeft ) ; if ( fn.test ( info ) ) { return info ; } timeLeft -= ( android.os.SystemClock.elapsedRealtime ( ) ) - start ; } fail ( ( ( "Did not receive expected callback after " + timeoutMs ) + "ms" ) ) ; return null ; }

Target:
com.android.server.ConnectivityServiceTest.CallbackInfo expectCallbackLike ( java.util.function.Predicate < com.android.server.ConnectivityServiceTest.CallbackInfo > fn , int timeoutMs ) { int timeLeft = timeoutMs ; while ( timeLeft > 0 ) { long start = android.os.SystemClock.elapsedRealtime ( ) ; com.android.server.ConnectivityServiceTest.CallbackInfo info = nextCallback ( timeLeft ) ; if ( fn.test ( info ) ) { return info ; } timeLeft -= ( android.os.SystemClock.elapsedRealtime ( ) ) - start ; } org.junit.Assert.fail ( ( ( "Did not receive expected callback after " + timeoutMs ) + "ms" ) ) ; return null ; }
Source:
public float setTargetHeapUtilization ( float newTarget ) { if ( ( newTarget <= 0.0 ) || ( newTarget >= 1.0 ) ) { throw new java.lang.IllegalArgumentException ( ( newTarget + " out of range (0,1)" ) ) ; } synchronized ( this ) { float oldTarget = getTargetHeapUtilization ( ) ; nativeSetTargetHeapUtilization ( newTarget ) ; return oldTarget ; } }

Target:
public float setTargetHeapUtilization ( float newTarget ) { if ( ( newTarget <= 0.0F ) || ( newTarget >= 1.0F ) ) { throw new java.lang.IllegalArgumentException ( ( newTarget + " out of range (0,1)" ) ) ; } synchronized ( this ) { float oldTarget = getTargetHeapUtilization ( ) ; nativeSetTargetHeapUtilization ( newTarget ) ; return oldTarget ; } }
Source:
public void testDisconnectEvent ( ) throws java.lang.Exception { testConnectEvent ( ) ; mDc.sendMessage ( DataConnection.EVENT_DISCONNECT , mDcp ) ; com.android.internal.telephony.TelephonyTestUtils.waitForMs ( 100 ) ; org.mockito.Mockito.verify ( mSimulatedCommandsVerifier , org.mockito.Mockito.times ( 1 ) ) . deactivateDataCall ( org.mockito.ArgumentMatchers.eq ( 1 ) , org.mockito.ArgumentMatchers.eq ( RILConstants.DEACTIVATE_REASON_NONE ) , org.mockito.ArgumentMatchers.any ( android.os.Message.class ) ) ; org.junit.Assert.assertEquals ( "DcInactiveState" , getCurrentState ( ) . getName ( ) ) ; }

Target:
public void testDisconnectEvent ( ) throws java.lang.Exception { testConnectEvent ( ) ; mDc.sendMessage ( DataConnection.EVENT_DISCONNECT , mDcp ) ; com.android.internal.telephony.TelephonyTestUtils.waitForMs ( 100 ) ; org.mockito.Mockito.verify ( mSimulatedCommandsVerifier , org.mockito.Mockito.times ( 1 ) ) . deactivateDataCall ( org.mockito.ArgumentMatchers.eq ( 1 ) , org.mockito.ArgumentMatchers.eq ( DataService.REQUEST_REASON_NORMAL ) , org.mockito.ArgumentMatchers.any ( android.os.Message.class ) ) ; org.junit.Assert.assertEquals ( "DcInactiveState" , getCurrentState ( ) . getName ( ) ) ; }
Source:
private com.android.internal.telephony.gsm.stk.ComprehensionTlv searchForNextTag ( com.android.internal.telephony.gsm.stk.ComprehensionTlvTag tag , java.util.Iterator < com.android.internal.telephony.gsm.stk.ComprehensionTlv > iter ) { int tagValue = tag.value ( ) ; while ( iter.hasNext ( ) ) { com.android.internal.telephony.gsm.stk.ComprehensionTlv ctlv = iter.next ( ) ; if ( ( ctlv.getTag ( ) ) == tagValue ) { return ctlv ; } } return null ; }

Target:
private com.android.internal.telephony.cat.ComprehensionTlv searchForNextTag ( com.android.internal.telephony.cat.ComprehensionTlvTag tag , java.util.Iterator < com.android.internal.telephony.cat.ComprehensionTlv > iter ) { int tagValue = tag.value ( ) ; while ( iter.hasNext ( ) ) { com.android.internal.telephony.cat.ComprehensionTlv ctlv = iter.next ( ) ; if ( ( ctlv.getTag ( ) ) == tagValue ) { return ctlv ; } } return null ; }
Source:
protected void renderBreadcrumbs ( org.w3c.dom.Element parent ) { org.w3c.dom.Element div = append ( parent , "div" ) ; div.setAttribute ( "class" , "breadcrumbs" ) ; appendLink ( div , "index.html" , "all" ) ; appendText ( div , java.lang.String.format ( " > %s" , getResults ( ) . getName ( ) ) ) ; }

Target:
protected void renderBreadcrumbs ( org.gradle.api.internal.html.SimpleHtmlWriter htmlWriter ) throws java.io.IOException { htmlWriter.startElement ( "div" ) . attribute ( "class" , "breadcrumbs" ) ; htmlWriter.startElement ( "a" ) . attribute ( "href" , "index.html" ) . characters ( "all" ) . endElement ( ) ; htmlWriter.characters ( java.lang.String.format ( " > %s" , getResults ( ) . getName ( ) ) ) ; htmlWriter.endElement ( ) ; }
Source:
public java.lang.String getDeviceSoftwareVersion ( int slotId ) { int [ ] subId = android.telephony.SubscriptionManager.getSubId ( slotId ) ; if ( ( subId == null ) || ( ( subId.length ) == 0 ) ) { return null ; } try { com.android.internal.telephony.IPhoneSubInfo info = getSubscriberInfo ( ) ; if ( info == null ) return null ; return info.getDeviceSvnUsingSubId ( subId [ 0 ] , mContext.getOpPackageName ( ) ) ; } catch ( android.os.RemoteException ex ) { return null ; } catch ( java.lang.NullPointerException ex ) { return null ; } }

Target:
public void setCarrierInfoForImsiEncryption ( android.telephony.ImsiEncryptionInfo imsiEncryptionInfo ) { try { com.android.internal.telephony.IPhoneSubInfo info = getSubscriberInfo ( ) ; if ( info == null ) return ; info.setCarrierInfoForImsiEncryption ( mSubId , mContext.getOpPackageName ( ) , imsiEncryptionInfo ) ; } catch ( java.lang.NullPointerException ex ) { return ; } catch ( android.os.RemoteException ex ) { android.telephony.Rlog.e ( android.telephony.TelephonyManager.TAG , "setCarrierInfoForImsiEncryption RemoteException" , ex ) ; return ; } }
Source:
void disposeLocked ( ) { java.util.ArrayList < com.android.server.LocationManagerService.UpdateRecord > records = mRecordsByProvider.get ( this . mProvider ) ; if ( records != null ) { records.remove ( this ) ; } }

Target:
void disposeLocked ( boolean removeReceiver ) { java.util.ArrayList < com.android.server.LocationManagerService.UpdateRecord > globalRecords = mRecordsByProvider.get ( this . mProvider ) ; if ( globalRecords != null ) { globalRecords.remove ( this ) ; } if ( ! removeReceiver ) return ; java.util.HashMap < java.lang.String , com.android.server.LocationManagerService.UpdateRecord > receiverRecords = mReceiver.mUpdateRecords ; if ( receiverRecords != null ) { receiverRecords.remove ( this . mProvider ) ; if ( removeReceiver && ( ( receiverRecords.size ( ) ) == 0 ) ) { removeUpdatesLocked ( mReceiver ) ; } } }
Source:
public void testSet2 ( ) { try { java.util.concurrent.CopyOnWriteArrayList c = new java.util.concurrent.CopyOnWriteArrayList ( ) ; c.add ( "asdasd" ) ; c.add ( "asdad" ) ; c.set ( 100 , "qwerty" ) ; shouldThrow ( ) ; } catch ( java.lang.IndexOutOfBoundsException success ) { } }

Target:
public void testGet1_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.get ( ( - 1 ) ) ; shouldThrow ( ) ; } catch ( java.lang.IndexOutOfBoundsException success ) { } } }
Source:
public void disableIms ( int slotId ) { try { mIImsServiceController.disableIms ( slotId ) ; } catch ( android.os.RemoteException e ) { android.util.Log.w ( com.android.internal.telephony.ims.ImsServiceController.LOG_TAG , ( "Couldn't disable IMS: " + ( e.getMessage ( ) ) ) ) ; } }

Target:
public void disableIms ( int slotId ) { try { synchronized ( mLock ) { if ( isServiceControllerAvailable ( ) ) { mIImsServiceController.disableIms ( slotId ) ; } } } catch ( android.os.RemoteException e ) { android.util.Log.w ( com.android.internal.telephony.ims.ImsServiceController.LOG_TAG , ( "Couldn't disable IMS: " + ( e.getMessage ( ) ) ) ) ; } }
Source:
public void eventFollowupReceived ( android.hardware.wifi.V1_0.NanFollowupReceivedInd event ) { if ( com.android.server.wifi.aware.WifiAwareNativeCallback.VDBG ) { android.util.Log.v ( com.android.server.wifi.aware.WifiAwareNativeCallback.TAG , ( ( ( ( ( "eventFollowupReceived: discoverySessionId=" + ( event.discoverySessionId ) ) + ", peerId=" ) + ( event.peerId ) ) + ", addr=" ) + ( java.lang.String.valueOf ( libcore.util.HexEncoding.encode ( event.addr ) ) ) ) ) ; } mWifiAwareStateManager.onMessageReceivedNotification ( event.discoverySessionId , event.peerId , event.addr , convertUcByteToLcByteArray ( event.serviceSpecificInfo ) ) ; }

Target:
public void eventFollowupReceived ( android.hardware.wifi.V1_0.NanFollowupReceivedInd event ) { if ( com.android.server.wifi.aware.WifiAwareNativeCallback.VDBG ) { android.util.Log.v ( com.android.server.wifi.aware.WifiAwareNativeCallback.TAG , ( ( ( ( ( "eventFollowupReceived: discoverySessionId=" + ( event.discoverySessionId ) ) + ", peerId=" ) + ( event.peerId ) ) + ", addr=" ) + ( java.lang.String.valueOf ( libcore.util.HexEncoding.encode ( event.addr ) ) ) ) ) ; } mWifiAwareStateManager.onMessageReceivedNotification ( event.discoverySessionId , event.peerId , event.addr , convertArrayListToNativeByteArray ( event.serviceSpecificInfo ) ) ; }
Source:
public void bind ( java.net.SocketAddress localAddr ) throws java.io.IOException { if ( channel.isConnected ( ) ) { throw new java.nio.channels.AlreadyConnectedException ( ) ; } if ( ( java.nio.SocketChannelImpl.SOCKET_STATUS_PENDING ) == ( channel.status ) ) { throw new java.nio.channels.ConnectionPendingException ( ) ; } super . bind ( localAddr ) ; channel.initLocalAddressAndPort ( ) ; channel.isBound = true ; }

Target:
public void connect ( java.net.SocketAddress remoteAddr , int timeout ) throws java.io.IOException { if ( ! ( channel.isBlocking ( ) ) ) { throw new java.nio.channels.IllegalBlockingModeException ( ) ; } if ( isConnected ( ) ) { throw new java.nio.channels.AlreadyConnectedException ( ) ; } super . connect ( remoteAddr , timeout ) ; channel.onBind ( false ) ; if ( super . isConnected ( ) ) { java.net.InetSocketAddress remoteInetAddress = ( ( java.net.InetSocketAddress ) ( remoteAddr ) ) ; channel.onConnectStatusChanged ( remoteInetAddress , java.nio.SocketChannelImpl.SOCKET_STATUS_CONNECTED , false ) ; } }
Source:
private void renderChildren ( java.util.List < com.android.builder.dependency.LibraryDependency > libraries ) { renderer.startChildren ( ) ; for ( int i = 0 ; i < ( libraries.size ( ) ) ; i ++ ) { com.android.builder.dependency.LibraryDependency lib = libraries.get ( i ) ; render ( lib , ( i == ( ( libraries.size ( ) ) - 1 ) ) ) ; } renderer.completeChildren ( ) ; }

Target:
private void render ( final com.android.builder.dependency.JarDependency jar , boolean lastChild ) { renderer.visit ( new org.gradle.api.Action < org.gradle.logging.StyledTextOutput > ( ) { @ java.lang.Override public void execute ( org.gradle.logging.StyledTextOutput styledTextOutput ) { getTextOutput ( ) . text ( ( "LOCAL: " + ( jar.getJarFile ( ) . getName ( ) ) ) ) ; } } , lastChild ) ; }
Source:
private static void onTransmitFollowupEvent ( short transactionId , int reason ) { if ( com.android.server.wifi.aware.WifiAwareNative.VDBG ) { android.util.Log.v ( com.android.server.wifi.aware.WifiAwareNative.TAG , ( ( ( "onTransmitFollowupEvent: transactionId=" + transactionId ) + ", reason=" ) + reason ) ) ; } if ( reason == ( com.android.server.wifi.aware.WifiAwareNative.AWARE_STATUS_SUCCESS ) ) { com.android.server.wifi.aware.WifiAwareStateManager.getInstance ( ) . onMessageSendSuccessNotification ( transactionId ) ; } else { com.android.server.wifi.aware.WifiAwareStateManager.getInstance ( ) . onMessageSendFailNotification ( transactionId , reason ) ; } }

Target:
private static void onTransmitFollowupEvent ( short transactionId , int reason ) { if ( com.android.server.wifi.aware.WifiAwareNative.VDBG ) { android.util.Log.v ( com.android.server.wifi.aware.WifiAwareNative.TAG , ( ( ( "onTransmitFollowupEvent: transactionId=" + transactionId ) + ", reason=" ) + reason ) ) ; } if ( reason == ( com.android.server.wifi.aware.WifiAwareNative.AWARE_STATUS_SUCCESS ) ) { com.android.server.wifi.aware.WifiAwareNative.sWifiAwareStateManager.onMessageSendSuccessNotification ( transactionId ) ; } else { com.android.server.wifi.aware.WifiAwareNative.sWifiAwareStateManager.onMessageSendFailNotification ( transactionId , reason ) ; } }
Source:
private int parseHistoricalBytes ( byte [ ] atrBytes , int index ) { if ( ( ( mHistoricalBytes.length ) + index ) > ( atrBytes.length ) ) { com.android.internal.telephony.uicc.AnswerToReset.loge ( "Failed to read the historical bytes." ) ; return - 1 ; } if ( ( mHistoricalBytes.length ) > 0 ) { java.lang.System.arraycopy ( atrBytes , index , mHistoricalBytes , 0 , mHistoricalBytes.length ) ; } return index + ( mHistoricalBytes.length ) ; }

Target:
private int parseHistoricalBytes ( byte [ ] atrBytes , int index ) { int length = ( mFormatByte ) & ( com.android.internal.telephony.uicc.AnswerToReset.T_MASK ) ; if ( ( length + index ) > ( atrBytes.length ) ) { com.android.internal.telephony.uicc.AnswerToReset.loge ( "Failed to read the historical bytes." ) ; return - 1 ; } if ( length > 0 ) { mHistoricalBytes = com.android.internal.telephony.uicc.AnswerToReset.HistoricalBytes.parseHistoricalBytes ( atrBytes , index , length ) ; } return index + length ; }
Source:
public java.util.Collection < V > get ( java.lang.Object key ) { java.util.Collection < V > collection = unmodifiableMap.get ( key ) ; return collection == null ? null : com.google.common.collect.Multimaps.unmodifiableValueCollection ( collection ) ; }

Target:
public java.util.Map < K , java.util.Collection < V > > asMap ( ) { java.util.Map < K , java.util.Collection < V > > result = map ; if ( result == null ) { result = map = java.util.Collections.unmodifiableMap ( com.google.common.collect.Maps.transformValues ( delegate.asMap ( ) , new com.google.common.base.Function < java.util.Collection < V > , java.util.Collection < V > > ( ) { @ java.lang.Override public java.util.Collection < V > apply ( java.util.Collection < V > collection ) { return com.google.common.collect.Multimaps.unmodifiableValueCollection ( collection ) ; } } ) ) ; } return result ; }