auphong2707/dl4se-code-review-dataset huggingface dataset:
Source:
public void test2_0SetEnabledGetEnabled ( ) throws java.lang.Exception { if ( ! ( isBassBoostAvailable ( ) ) ) { return ; } getBassBoost ( 0 ) ; try { mBassBoost.setEnabled ( true ) ; assertTrue ( "invalid state from getEnabled" , mBassBoost.getEnabled ( ) ) ; mBassBoost.setEnabled ( false ) ; assertFalse ( "invalid state to getEnabled" , mBassBoost.getEnabled ( ) ) ; } catch ( java.lang.IllegalStateException e ) { fail ( "setEnabled() in wrong state" ) ; } finally { releaseBassBoost ( ) ; } }

Target:
public void test2_0SetEnabledGetEnabled ( ) throws java.lang.Exception { if ( ! ( isBassBoostAvailable ( ) ) ) { return ; } getBassBoost ( getSessionId ( ) ) ; try { mBassBoost.setEnabled ( true ) ; assertTrue ( "invalid state from getEnabled" , mBassBoost.getEnabled ( ) ) ; mBassBoost.setEnabled ( false ) ; assertFalse ( "invalid state to getEnabled" , mBassBoost.getEnabled ( ) ) ; } catch ( java.lang.IllegalStateException e ) { fail ( "setEnabled() in wrong state" ) ; } finally { releaseBassBoost ( ) ; } }
Source:
private boolean introducesUnwantedFields ( proguard.optimize.peephole.ProgramClass programClass , proguard.optimize.peephole.ProgramClass targetClass ) { if ( ( ! ( proguard.optimize.peephole.InstantiationClassMarker.isInstantiated ( targetClass ) ) ) && ( ( ( targetClass.subClasses ) == null ) || ( isOnlySubClass ( programClass , targetClass ) ) ) ) { return false ; } proguard.optimize.peephole.MemberCounter counter = new proguard.optimize.peephole.MemberCounter ( ) ; programClass.fieldsAccept ( new proguard.optimize.peephole.MemberAccessFilter ( 0 , ClassConstants.INTERNAL_ACC_STATIC , counter ) ) ; return ( counter.getCount ( ) ) > 0 ; }

Target:
private boolean introducesUnwantedFields ( proguard.optimize.peephole.ProgramClass programClass , proguard.optimize.peephole.ProgramClass targetClass ) { if ( ( ! ( proguard.optimize.peephole.InstantiationClassMarker.isInstantiated ( targetClass ) ) ) && ( ( ( targetClass.subClasses ) == null ) || ( isOnlySubClass ( programClass , targetClass ) ) ) ) { return false ; } proguard.optimize.peephole.MemberCounter counter = new proguard.optimize.peephole.MemberCounter ( ) ; programClass.fieldsAccept ( new proguard.optimize.peephole.MemberAccessFilter ( 0 , ClassConstants.ACC_STATIC , counter ) ) ; return ( counter.getCount ( ) ) > 0 ; }
Source:
public void testInstall_withWorkingDir ( ) throws java.lang.Exception { java.io.File workingDir = installer.getWorkingDir ( ) ; assertTrue ( workingDir.mkdir ( ) ) ; libcore.tzdata.update2.TimeZoneBundleInstallerTest.createFile ( new java.io.File ( workingDir , "myFile" ) , new byte [ ] { 'a' } ) ; libcore.tzdata.update2.TimeZoneBundle bundle = libcore.tzdata.update2.TimeZoneBundleInstallerTest.createValidTimeZoneBundle ( libcore.tzdata.update2.TimeZoneBundleInstallerTest.NEW_RULES_VERSION , 1 ) ; assertEquals ( TimeZoneBundleInstaller.INSTALL_SUCCESS , installer.installWithErrorCode ( bundle.getBytes ( ) ) ) ; assertBundleInstalled ( bundle ) ; }

Target:
public void testInstall_withWorkingDir ( ) throws java.lang.Exception { java.io.File workingDir = installer.getWorkingDir ( ) ; assertTrue ( workingDir.mkdir ( ) ) ; libcore.tzdata.update2.TimeZoneBundleInstallerTest.createFile ( new java.io.File ( workingDir , "myFile" ) , new byte [ ] { 'a' } ) ; libcore.tzdata.update2.TimeZoneDistro distro = libcore.tzdata.update2.TimeZoneBundleInstallerTest.createValidTimeZoneDistro ( libcore.tzdata.update2.TimeZoneBundleInstallerTest.NEW_RULES_VERSION , 1 ) ; assertEquals ( TimeZoneBundleInstaller.INSTALL_SUCCESS , installer.installWithErrorCode ( distro.getBytes ( ) ) ) ; assertDistroInstalled ( distro ) ; }
Source:
private void showError ( final java.lang.String msg , final java.lang.Throwable t , org.eclipse.core.runtime.IProgressMonitor monitor ) { monitor.done ( ) ; mViewer.getShell ( ) . getDisplay ( ) . syncExec ( new java.lang.Runnable ( ) { @ java.lang.Override public void run ( ) { org.eclipse.core.runtime.Status s = new org.eclipse.core.runtime.Status ( org.eclipse.core.runtime.IStatus.ERROR , "Screenshot" , msg , t ) ; org.eclipse.jface.dialogs.ErrorDialog.openError ( mViewer.getShell ( ) , "Error" , "Error obtaining UI hierarchy" , s ) ; } } ) ; }

Target:
public void run ( org.eclipse.core.runtime.IProgressMonitor monitor ) throws java.lang.InterruptedException , java.lang.reflect.InvocationTargetException { com.android.uiautomator.UiAutomatorHelper.UiAutomatorResult result = null ; try { result = com.android.uiautomator.UiAutomatorHelper.takeSnapshot ( device , monitor ) ; } catch ( com.android.uiautomator.UiAutomatorHelper.UiAutomatorException e ) { monitor.done ( ) ; showError ( e.getMessage ( ) , e ) ; return ; } mViewer.setModel ( result.model , result.uiHierarchy , result.screenshot ) ; monitor.done ( ) ; }
Source:
public void onClientPlaybackStateUpdate ( int state , long stateChangeTimeMs , long currentPosMs , float speed ) { android.os.Handler handler = mLocalHandler.get ( ) ; if ( handler != null ) { handler.obtainMessage ( com.android.bluetooth.avrcp.Avrcp.MSG_UPDATE_STATE , 0 , state , new java.lang.Long ( currentPosMs ) ) . sendToTarget ( ) ; } }

Target:
public void onClientPlaybackStateUpdate ( int state , long stateChangeTimeMs , long currentPosMs , float speed ) { if ( com.android.bluetooth.avrcp.Avrcp.DEBUG ) android.util.Log.v ( com.android.bluetooth.avrcp.Avrcp.TAG , ( ( ( "RemoteControlDisplayer: Update playbackState state=" + state ) + " position=" ) + currentPosMs ) ) ; android.os.Handler handler = mLocalHandler.get ( ) ; if ( handler != null ) { handler.obtainMessage ( com.android.bluetooth.avrcp.Avrcp.MSG_UPDATE_STATE , 0 , state , new java.lang.Long ( currentPosMs ) ) . sendToTarget ( ) ; } }
Source:
public void onResume ( ) { super . onResume ( ) ; if ( ( mWifiEnabler ) != null ) { mWifiEnabler.resume ( ) ; } getActivity ( ) . registerReceiver ( mReceiver , mFilter ) ; if ( ( ( mKeyStoreNetworkId ) != ( android.net.wifi.WifiConfiguration.INVALID_NETWORK_ID ) ) && ( ( android.security.KeyStore.getInstance ( ) . state ( ) ) == ( KeyStore.State.UNLOCKED ) ) ) { mWifiManager.connect ( mKeyStoreNetworkId , mConnectListener ) ; } mKeyStoreNetworkId = android.net.wifi.WifiConfiguration.INVALID_NETWORK_ID ; updateAccessPoints ( ) ; }

Target:
public void onResume ( ) { super . onResume ( ) ; if ( ( mWifiEnabler ) != null ) { mWifiEnabler.resume ( ) ; } getActivity ( ) . registerReceiver ( mReceiver , mFilter ) ; if ( ( ( mKeyStoreNetworkId ) != ( android.net.wifi.WifiConfiguration.INVALID_NETWORK_ID ) ) && ( android.security.KeyStore.getInstance ( ) . isUnlocked ( ) ) ) { mWifiManager.connect ( mKeyStoreNetworkId , mConnectListener ) ; } mKeyStoreNetworkId = android.net.wifi.WifiConfiguration.INVALID_NETWORK_ID ; updateAccessPoints ( ) ; }
Source:
private void sendNanStateChangedBroadcast ( boolean enabled ) { if ( com.android.server.wifi.nan.WifiNanStateManager.VDBG ) { android.util.Log.v ( com.android.server.wifi.nan.WifiNanStateManager.TAG , ( "sendNanStateChangedBroadcast: enabled=" + enabled ) ) ; } final android.content.Intent intent = new android.content.Intent ( android.net.wifi.nan.WifiNanManager.ACTION_WIFI_NAN_STATE_CHANGED ) ; intent.addFlags ( Intent.FLAG_RECEIVER_REGISTERED_ONLY ) ; mContext.sendBroadcastAsUser ( intent , UserHandle.ALL ) ; }

Target:
private void sendAwareStateChangedBroadcast ( boolean enabled ) { if ( com.android.server.wifi.aware.WifiAwareStateManager.VDBG ) { android.util.Log.v ( com.android.server.wifi.aware.WifiAwareStateManager.TAG , ( "sendAwareStateChangedBroadcast: enabled=" + enabled ) ) ; } final android.content.Intent intent = new android.content.Intent ( android.net.wifi.aware.WifiAwareManager.ACTION_WIFI_AWARE_STATE_CHANGED ) ; intent.addFlags ( Intent.FLAG_RECEIVER_REGISTERED_ONLY ) ; mContext.sendBroadcastAsUser ( intent , UserHandle.ALL ) ; }
Source:
public void run ( ) { setMinSize ( width , height ) ; }

Target:
private void loadImage ( ) { image = model.getImage ( ) ; if ( ( image ) != null ) { width = image.getBounds ( ) . width ; height = image.getBounds ( ) . height ; } else { width = 0 ; height = 0 ; } setMinSize ( width , height ) ; }
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.hasMinToolsRev ( ) ) ; assertFalse ( p.hasMinPlatformToolsRev ( ) ) ; }

Target:
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.hasVendorId ( ) ) ; assertFalse ( p.hasMinToolsRev ( ) ) ; assertFalse ( p.hasMinPlatformToolsRev ( ) ) ; }
Source:
private static < K , V > java.util.Map.Entry < K , java.util.Collection < V > > unmodifiableAsMapEntry ( final java.util.Map.Entry < K , java.util.Collection < V > > entry ) { com.google.common.base.Preconditions.checkNotNull ( entry ) ; return new com.google.common.collect.AbstractMapEntry < K , java.util.Collection < V > > ( ) { @ java.lang.Override public K getKey ( ) { return entry.getKey ( ) ; } @ java.lang.Override public java.util.Collection < V > getValue ( ) { return com.google.common.collect.Multimaps.unmodifiableValueCollection ( entry.getValue ( ) ) ; } } ; }

Target:
public static < K , V > java.util.Map < K , java.util.Set < V > > asMap ( com.google.common.collect.SetMultimap < K , V > multimap ) { return ( ( java.util.Map < K , java.util.Set < V > > ) ( ( java.util.Map < K , ? > ) ( multimap.asMap ( ) ) ) ) ; }
Source:
public java.util.Iterator < com.android.jack.ir.ast.JMethodId > iterator ( ) { return virtualMethods.iterator ( ) ; }

Target:
public java.util.Iterator < com.android.jack.ir.ast.JMethodId > iterator ( ) { return new java.util.Iterator < com.android.jack.ir.ast.JMethodId > ( ) { @ javax.annotation.Nonnull private final java.util.Iterator < com.android.jack.frontend.VirtualMethodsMarker.ComparableMethodId > iterator = virtualMethods.values ( ) . iterator ( ) ; @ java.lang.Override public boolean hasNext ( ) { return iterator.hasNext ( ) ; } @ javax.annotation.Nonnull @ java.lang.Override public com.android.jack.ir.ast.JMethodId next ( ) { return iterator.next ( ) . methodId ; } @ java.lang.Override public void remove ( ) { throw new java.lang.UnsupportedOperationException ( ) ; } } ; }
Source:
public boolean accept ( com.android.ide.eclipse.adt.internal.resources.configurations.ResourceQualifier qualifier ) { if ( ( ( ( ( qualifier instanceof com.android.ide.eclipse.adt.internal.resources.configurations.LanguageQualifier ) || ( qualifier instanceof com.android.ide.eclipse.adt.internal.resources.configurations.RegionQualifier ) ) || ( qualifier instanceof com.android.ide.eclipse.adt.internal.resources.configurations.DockModeQualifier ) ) || ( qualifier instanceof com.android.ide.eclipse.adt.internal.resources.configurations.NightModeQualifier ) ) || ( qualifier instanceof com.android.ide.eclipse.adt.internal.resources.configurations.VersionQualifier ) ) { return false ; } return true ; }

Target:
public boolean accept ( com.android.ide.common.resources.configuration.ResourceQualifier qualifier ) { if ( ( ( ( ( qualifier instanceof com.android.ide.common.resources.configuration.LanguageQualifier ) || ( qualifier instanceof com.android.ide.common.resources.configuration.RegionQualifier ) ) || ( qualifier instanceof com.android.ide.common.resources.configuration.DockModeQualifier ) ) || ( qualifier instanceof com.android.ide.common.resources.configuration.NightModeQualifier ) ) || ( qualifier instanceof com.android.ide.common.resources.configuration.VersionQualifier ) ) { return false ; } return true ; }
Source:
void startBluetoothDisable ( ) { mAdapterStateMachine.sendMessage ( AdapterState.BEGIN_DISABLE ) ; }

Target:
void stopProfileServices ( ) { mAdapterProperties.onBluetoothDisable ( ) ; java.lang.Class [ ] supportedProfileServices = com.android.bluetooth.btservice.Config.getSupportedProfiles ( ) ; if ( ( ( mRunningProfiles.size ( ) ) < 1 ) || ( ( ( mRunningProfiles.size ( ) ) == 1 ) && ( com.android.bluetooth.gatt.GattService.class . getSimpleName ( ) . equals ( mRunningProfiles.get ( 0 ) . getName ( ) ) ) ) ) { debugLog ( "stopProfileServices() - No profiles services to stop or already stopped." ) ; mAdapterStateMachine.sendMessage ( AdapterState.BREDR_STOPPED ) ; } setAllProfileServiceStates ( supportedProfileServices , BluetoothAdapter.STATE_OFF ) ; }
Source:
boolean startSingleAdvertising ( com.android.bluetooth.gatt.AdvertiseClient client ) { logd ( "starting single advertising" ) ; resetCountDownLatch ( ) ; enableAdvertising ( client , true ) ; if ( ! ( waitForCallback ( ) ) ) { return false ; } setAdvertisingData ( client , client.advertiseData , false ) ; return true ; }

Target:
boolean startSingleAdvertising ( com.android.bluetooth.gatt.AdvertiseClient client ) { logd ( "starting single advertising" ) ; resetCountDownLatch ( ) ; enableAdvertising ( client , true ) ; if ( ! ( waitForCallback ( ) ) ) { return false ; } setAdvertisingData ( client , client.advertiseData , false ) ; if ( ( client.scanResponse ) != null ) { setAdvertisingData ( client , client.scanResponse , true ) ; } return true ; }
Source:
public void testSetSecurityManager ( ) throws java.lang.Exception { com.android.ide.common.rendering.RenderSecurityManager manager = new com.android.ide.common.rendering.RenderSecurityManager ( null , null ) ; try { manager.setActive ( true ) ; java.lang.System.setSecurityManager ( null ) ; fail ( "Should have thrown security exception" ) ; } catch ( java.lang.SecurityException exception ) { assertEquals ( "Security access not allowed during rendering" , exception.toString ( ) ) ; } finally { manager.dispose ( ) ; } }

Target:
public void testSetSecurityManager ( ) throws java.lang.Exception { com.android.ide.common.rendering.RenderSecurityManager manager = new com.android.ide.common.rendering.RenderSecurityManager ( null , null ) ; try { manager.setActive ( true , myCredential ) ; java.lang.System.setSecurityManager ( null ) ; fail ( "Should have thrown security exception" ) ; } catch ( java.lang.SecurityException exception ) { assertEquals ( "Security access not allowed during rendering" , exception.toString ( ) ) ; } finally { manager.dispose ( myCredential ) ; } }
Source:
protected void initializeScriptAndBuffers ( android.graphics.Bitmap inputImage , com.android.rs.test.LayerInfo focalLayer ) { scriptC = new com.android.rs.test.renderscript.ScriptC_layered_filter_fast_d1new ( renderScript ) ; com.android.rs.test.KernelDataForRenderScript.setUseNewRS ( true ) ; int margin = ( com.android.rs.test.KernelDataForRenderScript.getMaxKernelRadius ( ) ) + 1 ; buffers = new com.android.rs.test.d1new.ImageBuffersForRenderScriptd1new ( inputImage , margin , renderScript , scriptC ) ; buffers.initializeRenderScript ( focalLayer , scriptC ) ; }

Target:
protected void initializeScriptAndBuffers ( android.graphics.Bitmap inputImage , com.android.rs.refocus.LayerInfo focalLayer ) { scriptC = new com.android.rs.refocus.renderscript.ScriptC_layered_filter_fast_d1new ( renderScript ) ; com.android.rs.refocus.KernelDataForRenderScript.setUseNewRS ( true ) ; int margin = ( com.android.rs.refocus.KernelDataForRenderScript.getMaxKernelRadius ( ) ) + 1 ; buffers = new com.android.rs.refocus.d1new.ImageBuffersForRenderScriptd1new ( inputImage , margin , renderScript , scriptC ) ; buffers.initializeRenderScript ( focalLayer , scriptC ) ; }
Source:
public android.net.IpConfiguration readIpAndProxyConfigurations ( ) { android.util.SparseArray < android.net.IpConfiguration > networks = readIpAndProxyConfigurations ( com.android.server.ethernet.EthernetConfigStore.ipConfigFile ) ; if ( ( networks.size ( ) ) == 0 ) { android.util.Log.w ( com.android.server.ethernet.EthernetConfigStore.TAG , "No Ethernet configuration found. Using default." ) ; return new android.net.IpConfiguration ( android.net.IpConfiguration.IpAssignment.DHCP , android.net.IpConfiguration.ProxySettings.NONE , null , null ) ; } if ( ( networks.size ( ) ) > 1 ) { android.util.Log.w ( com.android.server.ethernet.EthernetConfigStore.TAG , "Multiple Ethernet configurations detected. Only reading first one." ) ; } return networks.valueAt ( 0 ) ; }

Target:
public void read ( ) { synchronized ( mSync ) { android.util.ArrayMap < java.lang.String , android.net.IpConfiguration > configs = com.android.server.net.IpConfigStore.readIpConfigurations ( com.android.server.ethernet.EthernetConfigStore.ipConfigFile ) ; if ( configs.containsKey ( "0" ) ) { mIpConfigurationForDefaultInterface = configs.remove ( "0" ) ; } mIpConfigurations = configs ; } }
Source:
private static android.view.MotionEvent newTouchUpEvent ( long downTime , int x , int y ) { long eventTime = android.os.SystemClock.uptimeMillis ( ) ; android.view.MotionEvent event = android.view.MotionEvent.obtain ( downTime , eventTime , MotionEvent.ACTION_UP , x , y , 1 ) ; event.setSource ( InputDevice.SOURCE_TOUCHSCREEN ) ; return event ; }

Target:
private static android.view.MotionEvent newTouchMoveEvent ( long downTime , int x , int y ) { long eventTime = android.os.SystemClock.uptimeMillis ( ) ; android.view.MotionEvent event = android.view.MotionEvent.obtain ( downTime , eventTime , MotionEvent.ACTION_MOVE , x , y , 1 ) ; if ( ( Build.VERSION.SDK_INT ) >= ( Build.VERSION_CODES.HONEYCOMB_MR1 ) ) { event.setSource ( InputDevice.SOURCE_TOUCHSCREEN ) ; } return event ; }
Source:
public void test_checkedMapSerializationCompatability ( ) throws java.lang.Exception { java.util.Map < java.lang.String , java.lang.String > c = new java.util.HashMap < java.lang.String , java.lang.String > ( ) ; assertFalse ( ( c instanceof java.util.SortedMap ) ) ; c = java.util.Collections.checkedMap ( c , java.lang.String.class , java.lang.String.class ) ; tests.util.SerializationTester.assertCompabilityEquals ( c , "serialization/java/util/Collections_CheckedMap.golden.ser" ) ; }

Target:
public void test_checkedMapSerializationCompatability ( ) throws java.lang.Exception { java.util.Map < java.lang.String , java.lang.String > c = new java.util.HashMap < java.lang.String , java.lang.String > ( ) ; assertFalse ( ( c instanceof java.util.SortedMap ) ) ; c = java.util.Collections.checkedMap ( c , java.lang.String.class , java.lang.String.class ) ; tests.util.SerializationTester.assertCompabilityEquals ( c , "serialization/tests/api/java/util/Collections_CheckedMap.golden.ser" ) ; }
Source:
public abstract com.google.common.collect.ImmutableMap < R , V > column ( C columnKey ) ;

Target:
public com.google.common.collect.ImmutableMap < R , V > column ( C columnKey ) { com.google.common.base.Preconditions.checkNotNull ( columnKey ) ; return com.google.common.base.MoreObjects.firstNonNull ( ( ( com.google.common.collect.ImmutableMap < R , V > ) ( columnMap ( ) . get ( columnKey ) ) ) , com.google.common.collect.ImmutableMap.< R , V > of ( ) ) ; }
Source:
void silence ( ) { if ( ( mConnectionService ) == null ) { com.android.server.telecom.Log.w ( this , "silence() request on a call without a connection service." ) ; } else { com.android.server.telecom.Log.i ( this , "Send silence to connection service for call %s" , this ) ; com.android.server.telecom.Log.event ( this , Log.Events.SILENCE ) ; mConnectionService.silence ( this ) ; } }

Target:
void stopDtmfTone ( ) { if ( ( mConnectionService ) == null ) { android.telecom.Log.w ( this , "stopDtmfTone() request on a call without a connection service." ) ; } else { android.telecom.Log.i ( this , "Send stopDtmfTone to connection service for call %s" , this ) ; android.telecom.Log.addEvent ( this , LogUtils.Events.STOP_DTMF ) ; mConnectionService.stopDtmfTone ( this ) ; } }
Source:
public void testAesCbcHmacSha256Tcp4 ( ) throws java.lang.Exception { android.net.IpSecAlgorithm crypt = new android.net.IpSecAlgorithm ( android.net.IpSecAlgorithm.CRYPT_AES_CBC , android.net.cts.IpSecManagerTest.CRYPT_KEY ) ; android.net.IpSecAlgorithm auth = new android.net.IpSecAlgorithm ( android.net.IpSecAlgorithm.AUTH_HMAC_SHA256 , getAuthKey ( 256 ) , 128 ) ; checkTransform ( android.system.OsConstants.IPPROTO_TCP , android.net.cts.IpSecManagerTest.IPV4_LOOPBACK , crypt , auth , false , 1 , false ) ; checkTransform ( android.system.OsConstants.IPPROTO_TCP , android.net.cts.IpSecManagerTest.IPV4_LOOPBACK , crypt , auth , false , 1 , true ) ; }

Target:
public void testAesCbcHmacSha1Udp4 ( ) throws java.lang.Exception { android.net.IpSecAlgorithm crypt = new android.net.IpSecAlgorithm ( android.net.IpSecAlgorithm.CRYPT_AES_CBC , android.net.cts.IpSecManagerTest.CRYPT_KEY ) ; android.net.IpSecAlgorithm auth = new android.net.IpSecAlgorithm ( android.net.IpSecAlgorithm.AUTH_HMAC_SHA1 , android.net.cts.IpSecManagerTest.getKey ( 160 ) , 96 ) ; checkTransform ( android.system.OsConstants.IPPROTO_UDP , android.net.cts.IpSecManagerTest.IPV4_LOOPBACK , crypt , auth , null , false , 1 , false ) ; checkTransform ( android.system.OsConstants.IPPROTO_UDP , android.net.cts.IpSecManagerTest.IPV4_LOOPBACK , crypt , auth , null , false , 1 , true ) ; }
Source:
private java.lang.Object responseDataCallList ( android.os.Parcel p ) { java.util.ArrayList < com.android.internal.telephony.dataconnection.DataCallResponse > response ; int ver = p.readInt ( ) ; int num = p.readInt ( ) ; riljLog ( ( ( ( "responseDataCallList ver=" + ver ) + " num=" ) + num ) ) ; response = new java.util.ArrayList < com.android.internal.telephony.dataconnection.DataCallResponse > ( num ) ; for ( int i = 0 ; i < num ; i ++ ) { response.add ( getDataCallResponse ( p , ver ) ) ; } return response ; }

Target:
static com.android.internal.telephony.dataconnection.DataCallResponse convertDataCallResult ( android.hardware.radio.V1_0.SetupDataCallResult dcResult ) { return new com.android.internal.telephony.dataconnection.DataCallResponse ( dcResult.status , dcResult.suggestedRetryTime , dcResult.cid , dcResult.active , dcResult.type , dcResult.ifname , dcResult.addresses , dcResult.dnses , dcResult.gateways , dcResult.pcscf , dcResult.mtu ) ; }
Source:
public void testApplyingWithoutCriticalFiles ( ) throws java.lang.Exception { com.intellij.updater.PatchFileCreator.create ( myOlderDir , myNewerDir , myFile , java.util.Collections.< java.lang.String > emptyList ( ) , java.util.Collections.< java.lang.String > emptyList ( ) , java.util.Collections.< java.lang.String > emptyList ( ) , com.intellij.updater.TEST_UI ) ; com.intellij.updater.PatchFileCreator.PreparationResult preparationResult = com.intellij.updater.PatchFileCreator.prepareAndValidate ( myFile , myOlderDir , com.intellij.updater.TEST_UI ) ; assertTrue ( com.intellij.updater.PatchFileCreator.apply ( preparationResult , new java.util.HashMap < java.lang.String , com.intellij.updater.ValidationResult.Option > ( ) , com.intellij.updater.TEST_UI ) ) ; }

Target:
public void testApplyingWithCriticalFiles ( ) throws java.lang.Exception { myPatchSpec.setCriticalFiles ( java.util.Arrays.asList ( "lib/annotations.jar" ) ) ; com.intellij.updater.PatchFileCreator.create ( myPatchSpec , myFile , com.intellij.updater.TEST_UI ) ; com.intellij.updater.PatchFileCreator.PreparationResult preparationResult = com.intellij.updater.PatchFileCreator.prepareAndValidate ( myFile , myOlderDir , com.intellij.updater.TEST_UI ) ; assertTrue ( com.intellij.updater.PatchFileCreator.apply ( preparationResult , new java.util.HashMap < java.lang.String , com.intellij.updater.ValidationResult.Option > ( ) , com.intellij.updater.TEST_UI ) ) ; assertAppliedCorrectly ( ) ; }
Source:
public static boolean matchByAddress ( int workaround_id , java.lang.String address ) { if ( ( address == null ) || ( address.isEmpty ( ) ) ) return false ; com.android.bluetooth.util.Interop.lazyInitInteropDatabase ( ) ; for ( com.android.bluetooth.util.Interop.Entry entry : com.android.bluetooth.util.Interop.entries ) { if ( ( ( entry.workaround_id ) == workaround_id ) && ( entry.address.startsWith ( address.toLowerCase ( ) ) ) ) { return true ; } } return false ; }

Target:
public static boolean matchByAddress ( int workaroundId , java.lang.String address ) { if ( ( address == null ) || ( address.isEmpty ( ) ) ) return false ; com.android.bluetooth.util.Interop.lazyInitInteropDatabase ( ) ; for ( com.android.bluetooth.util.Interop.Entry entry : com.android.bluetooth.util.Interop.entries ) { if ( ( ( entry.workaround_id ) == workaroundId ) && ( entry.address.startsWith ( address.toLowerCase ( ) ) ) ) { return true ; } } return false ; }
Source:
public boolean disable ( ) { try { return mManagerService.disable ( true ) ; } catch ( android.os.RemoteException e ) { android.util.Log.e ( android.bluetooth.BluetoothAdapter.TAG , "" , e ) ; } return false ; }

Target:
public android.bluetooth.BluetoothActivityEnergyInfo getControllerActivityEnergyInfo ( int updateType ) { android.os.SynchronousResultReceiver receiver = new android.os.SynchronousResultReceiver ( ) ; requestControllerActivityEnergyInfo ( receiver ) ; try { android.os.SynchronousResultReceiver.Result result = receiver.awaitResult ( 1000 ) ; if ( ( result.bundle ) != null ) { return result.bundle.getParcelable ( BatteryStats.RESULT_RECEIVER_CONTROLLER_KEY ) ; } } catch ( java.util.concurrent.TimeoutException e ) { android.util.Log.e ( android.bluetooth.BluetoothAdapter.TAG , "getControllerActivityEnergyInfo timed out" ) ; } return null ; }
Source:
public void postInvalidateDelayed ( long delayMilliseconds , int left , int top , int right , int bottom ) { if ( ( mAttachInfo ) != null ) { final android.view.View.AttachInfo.InvalidateInfo info = android.view.View.AttachInfo.InvalidateInfo.acquire ( ) ; info.target = this ; info.left = left ; info.top = top ; info.right = right ; info.bottom = bottom ; final android.os.Message msg = android.os.Message.obtain ( ) ; msg.what = android.view.View.AttachInfo.INVALIDATE_RECT_MSG ; msg.obj = info ; mAttachInfo.mHandler.sendMessageDelayed ( msg , delayMilliseconds ) ; } }

Target:
protected void onDetachedFromWindow ( ) { mPrivateFlags &= ~ ( android.view.View.CANCEL_NEXT_UP_EVENT ) ; removeUnsetPressCallback ( ) ; removeLongPressCallback ( ) ; removePerformClickCallback ( ) ; removeSendViewScrolledAccessibilityEventCallback ( ) ; destroyDrawingCache ( ) ; destroyLayer ( ) ; if ( ( mDisplayList ) != null ) { mDisplayList.invalidate ( ) ; } if ( ( mAttachInfo ) != null ) { mAttachInfo.mHandler.removeMessages ( android.view.View.AttachInfo.INVALIDATE_MSG , this ) ; } mCurrentAnimation = null ; resetResolvedLayoutDirection ( ) ; resetResolvedTextDirection ( ) ; }
Source:
public void onSdkChange ( ) { com.android.sdklib.IAndroidTarget target = getRenderingTarget ( ) ; if ( target != null ) { mConfigComposite.onSdkLoaded ( target ) ; mConfigListener.onConfigurationChange ( ) ; } }

Target:
public void onSdkLoaded ( ) { com.android.sdklib.IAndroidTarget oldTarget = getRenderingTarget ( ) ; preRenderingTargetChangeCleanUp ( oldTarget ) ; com.android.ide.eclipse.adt.internal.sdk.Sdk currentSdk = com.android.ide.eclipse.adt.internal.sdk.Sdk.getCurrent ( ) ; if ( currentSdk != null ) { com.android.sdklib.IAndroidTarget target = currentSdk.getTarget ( mEditedFile.getProject ( ) ) ; if ( target != null ) { mConfigComposite.onSdkLoaded ( target ) ; mConfigListener.onConfigurationChange ( ) ; } } }
Source:
public void run ( ) { try { barrier.await ( 60 , java.util.concurrent.TimeUnit.SECONDS ) ; } catch ( java.lang.Exception e ) { throw new java.lang.AssertionError ( e ) ; } try { java.lang.Thread.sleep ( waitMillis ) ; } catch ( java.lang.InterruptedException ex ) { throw new java.lang.RuntimeException ( "shouldn't happen" , ex ) ; } tests.api.org.apache.harmony.kernel.dalvik.ThreadsTest.UNSAFE.unpark ( thread ) ; }

Target:
public void run ( ) { try { barrier.await ( 60 , java.util.concurrent.TimeUnit.SECONDS ) ; } catch ( java.lang.Exception e ) { throw new java.lang.AssertionError ( e ) ; } try { java.lang.Thread.sleep ( waitMillis ) ; } catch ( java.lang.InterruptedException ex ) { throw new java.lang.RuntimeException ( "shouldn't happen" , ex ) ; } org.apache.harmony.tests.org.apache.harmony.kernel.dalvik.ThreadsTest.UNSAFE.unpark ( thread ) ; }
Source:
public java.lang.String toString ( ) { return ( ( ( ( ( ( ( ( "JarDependency{" + "mJarFile=" ) + ( mJarFile ) ) + ", mCompiled=" ) + ( mCompiled ) ) + ", mPackaged=" ) + ( mPackaged ) ) + ", mProguarded=" ) + ( mProguarded ) ) + '}' ; }

Target:
public java.lang.String toString ( ) { return ( ( ( ( ( ( ( ( ( ( "JarDependency{" + "mJarFile=" ) + ( mJarFile ) ) + ", mCompiled=" ) + ( mCompiled ) ) + ", mPackaged=" ) + ( mPackaged ) ) + ", mProguarded=" ) + ( mProguarded ) ) + ", mResolvedCoordinates=" ) + ( mResolvedCoordinates ) ) + '}' ; }
Source:
public void afterHandshake ( int session , int s , int c , java.net.Socket sock , java.io.FileDescriptor fd , org.apache.harmony.xnet.provider.jsse.NativeCrypto.SSLHandshakeCallbacks callback ) throws java.lang.Exception { assertEquals ( "NULL" , org.apache.harmony.xnet.provider.jsse.NativeCrypto.SSL_SESSION_compress_meth ( c , session ) ) ; super . afterHandshake ( session , s , c , sock , fd , callback ) ; }

Target:
public void afterHandshake ( int session , int s , int c , java.net.Socket sock , java.io.FileDescriptor fd , org.apache.harmony.xnet.provider.jsse.NativeCrypto.SSLHandshakeCallbacks callback ) throws java.lang.Exception { byte [ ] b = org.apache.harmony.xnet.provider.jsse.NativeCrypto.i2d_SSL_SESSION ( session ) ; assertNotNull ( b ) ; int session2 = org.apache.harmony.xnet.provider.jsse.NativeCrypto.d2i_SSL_SESSION ( b ) ; assertTrue ( ( session2 != ( org.apache.harmony.xnet.provider.jsse.NativeCryptoTest.NULL ) ) ) ; org.apache.harmony.xnet.provider.jsse.NativeCrypto.SSL_SESSION_free ( session2 ) ; super . afterHandshake ( session , s , c , sock , fd , callback ) ; }
Source:
public boolean reportError ( byte error ) { android.util.Log.v ( android.bluetooth.BluetoothInputHost.TAG , ( "reportError(): error = " + error ) ) ; boolean result = false ; if ( ( mService ) != null ) { try { result = mService.reportError ( error ) ; } catch ( android.os.RemoteException e ) { android.util.Log.e ( android.bluetooth.BluetoothInputHost.TAG , e.toString ( ) ) ; } } else { android.util.Log.w ( android.bluetooth.BluetoothInputHost.TAG , "Proxy not attached to service" ) ; } return result ; }

Target:
public boolean sendReport ( android.bluetooth.BluetoothDevice device , int id , byte [ ] data ) { boolean result = false ; if ( ( mService ) != null ) { try { result = mService.sendReport ( device , id , data ) ; } catch ( android.os.RemoteException e ) { android.util.Log.e ( android.bluetooth.BluetoothInputHost.TAG , e.toString ( ) ) ; } } else { android.util.Log.w ( android.bluetooth.BluetoothInputHost.TAG , "Proxy not attached to service" ) ; } return result ; }
Source:
public static void recordPercentageHistogram ( java.lang.String name , int sample ) { if ( ( org.chromium.base.metrics.RecordHistogram.sDisabledBy ) != null ) return ; long key = org.chromium.base.metrics.RecordHistogram.getCachedHistogramKey ( name ) ; long result = org.chromium.base.metrics.RecordHistogram.nativeRecordEnumeratedHistogram ( name , key , sample , 101 ) ; if ( result != key ) org.chromium.base.metrics.RecordHistogram.sCache.put ( name , result ) ; }

Target:
public static void recordSparseSlowlyHistogram ( java.lang.String name , int sample ) { if ( org.chromium.base.metrics.RecordHistogram.sIsDisabledForTests ) return ; long key = org.chromium.base.metrics.RecordHistogram.getCachedHistogramKey ( name ) ; long result = org.chromium.base.metrics.RecordHistogram.nativeRecordSparseHistogram ( name , key , sample ) ; if ( result != key ) org.chromium.base.metrics.RecordHistogram.sCache.put ( name , result ) ; }
Source:
public void annotate ( com.android.dx.util.ExceptionWithContext ex ) { ex.addContext ( "(locals array set; primary)" ) ; primary.annotate ( ex ) ; int sz = secondaries.size ( ) ; for ( int label = 0 ; label < sz ; label ++ ) { com.android.dx.cf.code.LocalsArray la = secondaries.get ( label ) ; if ( la != null ) { ex.addContext ( ( ( "(locals array set: primary for caller " + ( com.android.dx.util.Hex.u2 ( label ) ) ) + ')' ) ) ; la.getPrimary ( ) . annotate ( ex ) ; } } }

Target:
public void annotate ( com.android.dex.util.ExceptionWithContext ex ) { ex.addContext ( "(locals array set; primary)" ) ; primary.annotate ( ex ) ; int sz = secondaries.size ( ) ; for ( int label = 0 ; label < sz ; label ++ ) { com.android.dx.cf.code.LocalsArray la = secondaries.get ( label ) ; if ( la != null ) { ex.addContext ( ( ( "(locals array set: primary for caller " + ( com.android.dx.util.Hex.u2 ( label ) ) ) + ')' ) ) ; la.getPrimary ( ) . annotate ( ex ) ; } } }
Source:
public void testOutgoingCallSelectPhoneAccountNoVideo ( ) throws java.lang.Exception { startOutgoingPhoneCallPendingCreateConnection ( "650-555-1212" , null , mConnectionServiceFixtureA , java.lang.Process.myUserHandle ( ) , VideoProfile.STATE_BIDIRECTIONAL ) ; android.telecom.com.android.server.telecom.Call call = mTelecomSystem.getCallsManager ( ) . getCalls ( ) . iterator ( ) . next ( ) ; assert call.isVideoCallingSupported ( ) ; assertEquals ( VideoProfile.STATE_BIDIRECTIONAL , call.getVideoState ( ) ) ; call.setTargetPhoneAccount ( mPhoneAccountA2.getAccountHandle ( ) ) ; assert ! ( call.isVideoCallingSupported ( ) ) ; assertEquals ( VideoProfile.STATE_AUDIO_ONLY , call.getVideoState ( ) ) ; }

Target:
public void testOutgoingCallSelectPhoneAccountVideo ( ) throws java.lang.Exception { startOutgoingPhoneCallPendingCreateConnection ( "650-555-1212" , null , mConnectionServiceFixtureA , java.lang.Process.myUserHandle ( ) , VideoProfile.STATE_BIDIRECTIONAL ) ; android.telecom.com.android.server.telecom.Call call = mTelecomSystem.getCallsManager ( ) . getCalls ( ) . iterator ( ) . next ( ) ; assert call.isVideoCallingSupported ( ) ; org.junit.Assert.assertEquals ( VideoProfile.STATE_BIDIRECTIONAL , call.getVideoState ( ) ) ; call.setTargetPhoneAccount ( mPhoneAccountA1.getAccountHandle ( ) ) ; assert call.isVideoCallingSupported ( ) ; org.junit.Assert.assertEquals ( VideoProfile.STATE_BIDIRECTIONAL , call.getVideoState ( ) ) ; }
Source:
public void testDropCdmaEnhancedPrivacyVoiceCall ( ) throws java.lang.Exception { mConnectionServiceFixtureA.mConnectionServiceDelegate.mProperties = android.telecom.Connection.PROPERTY_HAS_CDMA_VOICE_PRIVACY ; com.android.server.telecom.tests.IdPair ids = startAndMakeActiveOutgoingCall ( "650-555-1212" , mPhoneAccountA0.getAccountHandle ( ) , mConnectionServiceFixtureA ) ; assertEquals ( Call.STATE_ACTIVE , mInCallServiceFixtureX.getCall ( ids.mCallId ) . getState ( ) ) ; mConnectionServiceFixtureA.mLatestConnection.setConnectionProperties ( 0 ) ; assertFalse ( Call.Details.hasProperty ( mInCallServiceFixtureX.getCall ( ids.mCallId ) . getProperties ( ) , Call.Details.PROPERTY_HAS_CDMA_VOICE_PRIVACY ) ) ; }

Target:
public void testPullExternalCall ( ) throws java.lang.Exception { mConnectionServiceFixtureA.mConnectionServiceDelegate.mCapabilities = android.telecom.Connection.CAPABILITY_CAN_PULL_CALL ; mConnectionServiceFixtureA.mConnectionServiceDelegate.mProperties = android.telecom.Connection.PROPERTY_IS_EXTERNAL_CALL ; com.android.server.telecom.tests.IdPair ids = startAndMakeActiveIncomingCall ( "650-555-1212" , mPhoneAccountA0.getAccountHandle ( ) , mConnectionServiceFixtureA ) ; org.junit.Assert.assertEquals ( Call.STATE_ACTIVE , mInCallServiceFixtureX.getCall ( ids.mCallId ) . getState ( ) ) ; mInCallServiceFixtureX.mInCallAdapter.pullExternalCall ( ids.mCallId ) ; org.mockito.Mockito.verify ( mConnectionServiceFixtureA.getTestDouble ( ) , org.mockito.Mockito.timeout ( com.android.server.telecom.tests.TEST_TIMEOUT ) ) . pullExternalCall ( org.mockito.Matchers.eq ( ids.mConnectionId ) , org.mockito.Matchers.any ( ) ) ; }
Source:
public static android.telephony.MbmsStreamingManager create ( android.content.Context context , android.telephony.mbms.IMbmsStreamingManagerCallback listener , java.lang.String streamingAppName ) throws android.telephony.mbms.MbmsInitializationException { int subId = android.telephony.SubscriptionManager.INVALID_SUBSCRIPTION_ID ; android.telephony.MbmsStreamingManager manager = new android.telephony.MbmsStreamingManager ( context , listener , streamingAppName , subId ) ; manager.bindAndInitialize ( ) ; return manager ; }

Target:
public static android.telephony.MbmsStreamingManager create ( android.content.Context context , android.telephony.mbms.IMbmsStreamingManagerCallback listener , java.lang.String streamingAppName ) throws android.telephony.mbms.MbmsException { int subId = android.telephony.SubscriptionManager.getDefaultSubscriptionId ( ) ; android.telephony.MbmsStreamingManager manager = new android.telephony.MbmsStreamingManager ( context , listener , streamingAppName , subId ) ; manager.bindAndInitialize ( ) ; return manager ; }
Source:
public android.bluetooth.BluetoothCodecStatus getCodecStatus ( android.bluetooth.BluetoothDevice device ) { enforceCallingOrSelfPermission ( com.android.bluetooth.hearingaid.BLUETOOTH_PERM , "Need BLUETOOTH permission" ) ; if ( com.android.bluetooth.hearingaid.HearingAidService.DBG ) { android.util.Log.d ( com.android.bluetooth.hearingaid.HearingAidService.TAG , ( ( "getCodecStatus(" + device ) + ")" ) ) ; } throw new java.lang.IllegalStateException ( "Implement me" ) ; }

Target:
private void removeStateMachine ( android.bluetooth.BluetoothDevice device ) { synchronized ( mStateMachines ) { com.android.bluetooth.hearingaid.HearingAidStateMachine sm = mStateMachines.get ( device ) ; if ( sm == null ) { android.util.Log.w ( com.android.bluetooth.hearingaid.HearingAidService.TAG , ( ( "removeStateMachine: device " + device ) + " does not have a state machine" ) ) ; return ; } android.util.Log.i ( com.android.bluetooth.hearingaid.HearingAidService.TAG , ( "removeStateMachine: removing state machine for device: " + device ) ) ; sm.doQuit ( ) ; sm.cleanup ( ) ; mStateMachines.remove ( device ) ; } }
Source:
public boolean remove ( java.lang.Object o ) { if ( o instanceof java.util.Map.Entry ) { java.util.Map.Entry < ? , ? > entry = ( ( java.util.Map.Entry < ? , ? > ) ( o ) ) ; java.util.Collection < V2 > values = get ( ( ( K ) ( entry.getKey ( ) ) ) ) ; return values.remove ( entry.getValue ( ) ) ; } return false ; }

Target:
public java.util.Collection < V > get ( java.lang.Object key ) { return containsKey ( key ) ? multimap.get ( ( ( K ) ( key ) ) ) : null ; }
Source:
public static void main ( java.lang.String [ ] args ) { int [ ] a = new int [ 5 ] ; a = Main.bar ( a ) ; if ( ( a.length ) != 0 ) { throw new java.lang.Error ( ( "Expected 0, got " + ( a.length ) ) ) ; } }

Target:
public static int [ ] foo ( int [ ] a ) { a [ 0 ] = 0 ; a [ 1 ] = 0 ; a [ 2 ] = 0 ; return new int [ ( a.length ) - 1 ] ; }
Source:
void expandCapacity ( int minimumCapacity ) { int newCapacity = ( ( value.length ) * 2 ) + 2 ; if ( ( newCapacity - minimumCapacity ) < 0 ) newCapacity = minimumCapacity ; if ( newCapacity < 0 ) { if ( minimumCapacity < 0 ) throw new java.lang.OutOfMemoryError ( ) ; newCapacity = java.lang.Integer.MAX_VALUE ; } value = java.util.Arrays.copyOf ( value , newCapacity ) ; }

Target:
private int newCapacity ( int minCapacity ) { int newCapacity = ( ( value.length ) << 1 ) + 2 ; if ( ( newCapacity - minCapacity ) < 0 ) { newCapacity = minCapacity ; } return ( newCapacity <= 0 ) || ( ( ( java.lang.AbstractStringBuilder.MAX_ARRAY_SIZE ) - newCapacity ) < 0 ) ? hugeCapacity ( minCapacity ) : newCapacity ; }
Source:
public void testFileToUrl ( ) throws java.lang.Exception { if ( ( com.android.SdkConstants.CURRENT_PLATFORM ) == ( com.android.SdkConstants.PLATFORM_WINDOWS ) ) { assertEquals ( "file:/D:/tmp/foo/bar" , com.android.utils.SdkUtils.fileToUrlString ( new java.io.File ( "D:\\tmp\\foo\\bar" ) ) ) ; assertEquals ( "file:/C:/tmp/foo/bar" , com.android.utils.SdkUtils.fileToUrlString ( new java.io.File ( "/tmp/foo/bar" ) ) ) ; assertEquals ( "file:/C:/tmp/$&+,:;=%3F@/foo%20bar%25" , com.android.utils.SdkUtils.fileToUrlString ( new java.io.File ( "/tmp/$&+,:;=?@/foo bar%" ) ) ) ; } else { assertEquals ( "file:/tmp/foo/bar" , com.android.utils.SdkUtils.fileToUrlString ( new java.io.File ( "/tmp/foo/bar" ) ) ) ; assertEquals ( "file:/tmp/$&+,:;=%3F@/foo%20bar%25" , com.android.utils.SdkUtils.fileToUrlString ( new java.io.File ( "/tmp/$&+,:;=?@/foo bar%" ) ) ) ; } }

Target:
public void testFileToUrl ( ) throws java.lang.Exception { java.lang.String pDrive = ( ( com.android.SdkConstants.CURRENT_PLATFORM ) == ( com.android.SdkConstants.PLATFORM_WINDOWS ) ) ? "C:" : "" ; java.lang.String uDrive = ( ( com.android.SdkConstants.CURRENT_PLATFORM ) == ( com.android.SdkConstants.PLATFORM_WINDOWS ) ) ? "/C:" : "" ; assertEquals ( ( ( "file:" + uDrive ) + "/tmp/foo/bar" ) , com.android.utils.SdkUtils.fileToUrlString ( new java.io.File ( ( pDrive + "/tmp/foo/bar" ) ) ) ) ; assertEquals ( ( ( "file:" + uDrive ) + "/tmp/$&+,:;=%3F@/foo%20bar%25" ) , com.android.utils.SdkUtils.fileToUrlString ( new java.io.File ( ( pDrive + "/tmp/$&+,:;=?@/foo bar%" ) ) ) ) ; }
Source:
public void setDeviceTimeZone ( java.lang.String zoneId ) { android.app.AlarmManager alarm = ( ( android.app.AlarmManager ) ( mContext.getSystemService ( Context.ALARM_SERVICE ) ) ) ; alarm.setTimeZone ( zoneId ) ; android.content.Intent intent = new android.content.Intent ( TelephonyIntents.ACTION_NETWORK_SET_TIMEZONE ) ; intent.addFlags ( Intent.FLAG_RECEIVER_REPLACE_PENDING ) ; intent.putExtra ( "time-zone" , zoneId ) ; mContext.sendStickyBroadcastAsUser ( intent , UserHandle.ALL ) ; }

Target:
public void setDeviceTimeZone ( java.lang.String zoneId ) { com.android.internal.telephony.TimeServiceHelper.setDeviceTimeZoneStatic ( mContext , zoneId ) ; }
Source:
public void testWrongVariantLevelAbiFilter ( ) { java.util.List < com.android.build.VariantOutput > list = com.google.common.collect.Lists.newArrayList ( ) ; list.add ( com.android.ide.common.build.SplitOutputMatcherTest.getUniversalOutput ( 1 ) ) ; java.util.List < com.android.build.OutputFile > result = com.android.ide.common.build.SplitOutputMatcherTest.computeBestOutput ( list , com.google.common.collect.Sets.newHashSet ( "bar" , "foo" ) , 160 , "zzz" ) ; assertEquals ( 0 , result.size ( ) ) ; }

Target:
public void testWrongVariantLevelAbiFilter ( ) throws com.android.ide.common.process.ProcessException { java.util.List < com.android.build.VariantOutput > list = com.google.common.collect.Lists.newArrayList ( ) ; list.add ( com.android.ide.common.build.SplitOutputMatcherTest.getUniversalOutput ( 1 ) ) ; java.util.List < java.io.File > result = com.android.ide.common.build.SplitOutputMatcherTest.computeBestOutput ( list , com.google.common.collect.Sets.newHashSet ( "bar" , "foo" ) , 160 , "zzz" ) ; assertEquals ( 0 , result.size ( ) ) ; }
Source:
public static void parse ( java.lang.String proguardFileName , java.lang.String baseDir , @ javax.annotation.Nonnull com.android.jack.shrob.spec.Flags flags ) throws org.antlr.runtime.RecognitionException { assert proguardFileName != null ; assert baseDir != null ; java.io.File proguardFile = com.android.jack.shrob.proguard.GrammarActions.getFileFromBaseDir ( baseDir , proguardFileName ) ; com.android.jack.shrob.proguard.ProguardParser parser = com.android.jack.shrob.proguard.GrammarActions.createParserFromFile ( proguardFile ) ; if ( parser != null ) { try { parser.prog ( flags , proguardFile.getParentFile ( ) . getAbsolutePath ( ) ) ; } catch ( com.android.jack.shrob.proguard.RecoverableRecognitionException e ) { throw e.getCause ( ) ; } } }

Target:
public static void parse ( java.lang.String proguardFileName , java.lang.String baseDir , @ javax.annotation.Nonnull com.android.jack.shrob.spec.Flags flags ) throws org.antlr.runtime.RecognitionException { assert proguardFileName != null ; assert baseDir != null ; java.io.File proguardFile = com.android.jack.shrob.proguard.GrammarActions.getFileFromBaseDir ( baseDir , proguardFileName ) ; com.android.jack.shrob.proguard.ProguardParser parser = com.android.jack.shrob.proguard.GrammarActions.createParserFromFile ( proguardFile ) ; if ( parser != null ) { try { parser.prog ( flags , proguardFile.getParentFile ( ) . getPath ( ) ) ; } catch ( com.android.jack.shrob.proguard.RecoverableRecognitionException e ) { throw e.getCause ( ) ; } } }
Source:
public boolean equals ( java.lang.Object o ) { if ( ( this ) == o ) return true ; if ( ( o == null ) || ( ( getClass ( ) ) != ( o.getClass ( ) ) ) ) return false ; com.google.gct.testing.dimension.GoogleCloudTestingType googleCloudTestingType = ( ( com.google.gct.testing.dimension.GoogleCloudTestingType ) ( o ) ) ; return googleCloudTestingType.getId ( ) . equals ( this . getId ( ) ) ; }

Target:
public boolean equals ( java.lang.Object o ) { if ( ( this ) == o ) return true ; if ( ( o == null ) || ( ( getClass ( ) ) != ( o.getClass ( ) ) ) ) return false ; com.google.gct.testing.dimension.CloudTestingType cloudTestingType = ( ( com.google.gct.testing.dimension.CloudTestingType ) ( o ) ) ; return cloudTestingType.getId ( ) . equals ( this . getId ( ) ) ; }
Source:
public org.eclipse.swt.graphics.Font getFont ( java.lang.Object element , int columnIndex ) { if ( element instanceof com.android.sdkuilib.internal.repository.core.PkgItem ) { if ( ( ( ( com.android.sdkuilib.internal.repository.core.PkgItem ) ( element ) ) . getState ( ) ) == ( com.android.sdkuilib.internal.repository.core.PkgItem.PkgState.NEW ) ) { return mTreeFontItalic ; } } else if ( element instanceof java.lang.Package ) { return mTreeFontItalic ; } return super . getFont ( element ) ; }

Target:
protected org.eclipse.swt.graphics.Font getTreeFontItalic ( ) { return mTreeFontItalic ; }
Source:
private void sendShutdownMessage ( ) { if ( mRemoveTimeoutMsg ) { android.content.Intent timeoutIntent = new android.content.Intent ( com.android.bluetooth.sap.SapService.USER_CONFIRM_TIMEOUT_ACTION ) ; sendBroadcast ( timeoutIntent , com.android.bluetooth.sap.BLUETOOTH_PERM ) ; mIsWaitingAuthorization = false ; cancelUserTimeoutAlarm ( ) ; } mSessionStatusHandler.removeCallbacksAndMessages ( null ) ; mSessionStatusHandler.obtainMessage ( com.android.bluetooth.sap.SapService.SHUTDOWN ) . sendToTarget ( ) ; }

Target:
private void sendShutdownMessage ( ) { if ( mRemoveTimeoutMsg ) { android.content.Intent timeoutIntent = new android.content.Intent ( com.android.bluetooth.sap.SapService.USER_CONFIRM_TIMEOUT_ACTION ) ; sendBroadcast ( timeoutIntent , com.android.bluetooth.sap.BLUETOOTH_PERM ) ; mIsWaitingAuthorization = false ; cancelUserTimeoutAlarm ( ) ; } removeSdpRecord ( ) ; mSessionStatusHandler.removeCallbacksAndMessages ( null ) ; mSessionStatusHandler.obtainMessage ( com.android.bluetooth.sap.SapService.SHUTDOWN ) . sendToTarget ( ) ; }
Source:
public void testDisableSupplicant ( ) { com.android.server.wifi.WificondControl wificondControl = org.mockito.Mockito.mock ( com.android.server.wifi.WificondControl.class ) ; android.net.wifi.IWificond wificond = org.mockito.Mockito.mock ( android.net.wifi.IWificond.class ) ; mWifiNative.setWificondControl ( wificondControl ) ; mWifiNative.disableSupplicant ( ) ; org.mockito.Mockito.verify ( wificondControl ) . disableSupplicant ( ) ; }

Target:
public void testDisableSupplicant ( ) { org.mockito.Mockito.when ( mWificondControl.disableSupplicant ( ) ) . thenReturn ( true ) ; mWifiNative.disableSupplicant ( ) ; org.mockito.Mockito.verify ( mWificondControl ) . disableSupplicant ( ) ; }
Source:
public java.util.List < com.intellij.openapi.vfs.VirtualFile > getModuleClasspathEntries ( @ org.jetbrains.annotations.NotNull java.lang.String externalModulePath ) { java.util.List < com.intellij.openapi.vfs.VirtualFile > virtualFiles = myClasspathMap.get ( ) . get ( externalModulePath ) ; return virtualFiles == null ? java.util.Collections.< com.intellij.openapi.vfs.VirtualFile > emptyList ( ) : virtualFiles ; }

Target:
public java.util.List < com.intellij.openapi.vfs.VirtualFile > getModuleClasspathEntries ( @ org.jetbrains.annotations.NotNull java.lang.String externalModulePath ) { checkRootsValidity ( myClasspathMap.get ( ) . get ( externalModulePath ) ) ; java.util.List < com.intellij.openapi.vfs.VirtualFile > virtualFiles = myClasspathMap.get ( ) . get ( externalModulePath ) ; return virtualFiles == null ? java.util.Collections.< com.intellij.openapi.vfs.VirtualFile > emptyList ( ) : virtualFiles ; }