auphong2707/dl4se-code-review-dataset huggingface dataset:
Source:
public void setUp ( com.android.tradefed.device.ITestDevice device , com.android.tradefed.build.IBuildInfo buildInfo ) throws com.android.tradefed.device.DeviceNotAvailableException , com.android.tradefed.targetprep.BuildError , com.android.tradefed.targetprep.TargetSetupError { for ( java.util.Map.Entry < java.lang.String , java.lang.String > entry : com.android.compatibility.common.tradefed.targetprep.DeviceInfoCollector.BUILD_KEYS.entrySet ( ) ) { buildInfo.addBuildAttribute ( entry.getKey ( ) , com.android.tradefed.util.ArrayUtil.join ( "," , device.getProperty ( entry.getValue ( ) ) ) ) ; } if ( mSkipDeviceInfo ) { return ; } createTempHostDir ( ) ; createResultDir ( buildInfo ) ; run ( device , buildInfo ) ; getDeviceInfoFiles ( device ) ; }

Target:
public void setUp ( com.android.tradefed.device.ITestDevice device , com.android.tradefed.build.IBuildInfo buildInfo ) throws com.android.tradefed.device.DeviceNotAvailableException , com.android.tradefed.targetprep.BuildError , com.android.tradefed.targetprep.TargetSetupError { for ( java.util.Map.Entry < java.lang.String , java.lang.String > entry : com.android.compatibility.common.tradefed.targetprep.DeviceInfoCollector.BUILD_KEYS.entrySet ( ) ) { buildInfo.addBuildAttribute ( entry.getKey ( ) , com.android.compatibility.common.tradefed.targetprep.DeviceInfoCollector.nullToEmpty ( device.getProperty ( entry.getValue ( ) ) ) ) ; } if ( mSkipDeviceInfo ) { return ; } createTempHostDir ( ) ; createResultDir ( buildInfo ) ; run ( device , buildInfo ) ; getDeviceInfoFiles ( device ) ; }
Source:
public com.android.builder.model.ApiVersion getTargetSdkVersion ( ) { if ( ( mTestedConfig ) != null ) { return mTestedConfig.getTargetSdkVersion ( ) ; } com.android.builder.model.ApiVersion targetSdkVersion = mMergedFlavor.getTargetSdkVersion ( ) ; if ( targetSdkVersion == null ) { java.io.File manifestLocation = mDefaultSourceProvider.getManifestFile ( ) ; targetSdkVersion = com.android.builder.core.DefaultApiVersion.create ( sManifestParser.getTargetSdkVersion ( manifestLocation ) ) ; } return targetSdkVersion ; }

Target:
public com.android.builder.model.ApiVersion getMinSdkVersion ( ) { if ( ( mTestedConfig ) != null ) { return mTestedConfig.getMinSdkVersion ( ) ; } com.android.builder.model.ApiVersion minSdkVersion = mMergedFlavor.getMinSdkVersion ( ) ; if ( minSdkVersion == null ) { java.io.File manifestLocation = mDefaultSourceProvider.getManifestFile ( ) ; minSdkVersion = com.android.builder.core.DefaultApiVersion.create ( sManifestParser.getMinSdkVersion ( manifestLocation ) ) ; } return minSdkVersion ; }
Source:
private final void resetContext ( ) { org.conscrypt.NativeRef.EVP_MD_CTX ctxLocal = new org.conscrypt.NativeRef.EVP_MD_CTX ( org.conscrypt.NativeCrypto.EVP_MD_CTX_create ( ) ) ; org.conscrypt.NativeCrypto.EVP_MD_CTX_init ( ctxLocal ) ; final org.conscrypt.OpenSSLKey macKey = this . macKey ; if ( macKey != null ) { org.conscrypt.NativeCrypto.EVP_DigestSignInit ( ctxLocal , evp_md , macKey.getPkeyContext ( ) ) ; } this . ctx = ctxLocal ; }

Target:
private final void resetContext ( ) { org.conscrypt.NativeRef.EVP_MD_CTX ctxLocal = new org.conscrypt.NativeRef.EVP_MD_CTX ( org.conscrypt.NativeCrypto.EVP_MD_CTX_create ( ) ) ; org.conscrypt.NativeCrypto.EVP_MD_CTX_init ( ctxLocal ) ; final org.conscrypt.OpenSSLKey macKey = this . macKey ; if ( macKey != null ) { org.conscrypt.NativeCrypto.EVP_DigestSignInit ( ctxLocal , evp_md , macKey.getNativeRef ( ) ) ; } this . ctx = ctxLocal ; }
Source:
private static android.net.wifi.hotspot2.pps.Credential createCredentialWithUserCredential ( ) { android.net.wifi.hotspot2.pps.Credential.UserCredential userCred = new android.net.wifi.hotspot2.pps.Credential.UserCredential ( ) ; userCred.username = "username" ; userCred.password = "password" ; userCred.eapType = android.net.wifi.EAPConstants.EAP_TTLS ; userCred.nonEapInnerMethod = "MS-CHAP" ; return android.net.wifi.hotspot2.pps.CredentialTest.createCredential ( userCred , null , null , FakeKeys.CA_CERT0 , new java.security.cert.X509Certificate [ ] { android.net.wifi.FakeKeys.CLIENT_CERT } , FakeKeys.RSA_KEY1 ) ; }

Target:
private static android.net.wifi.hotspot2.pps.Credential createCredentialWithUserCredential ( ) { android.net.wifi.hotspot2.pps.Credential.UserCredential userCred = new android.net.wifi.hotspot2.pps.Credential.UserCredential ( ) ; userCred.username = "username" ; userCred.password = "password" ; userCred.machineManaged = true ; userCred.ableToShare = true ; userCred.softTokenApp = "TestApp" ; userCred.eapType = android.net.wifi.EAPConstants.EAP_TTLS ; userCred.nonEapInnerMethod = "MS-CHAP" ; return android.net.wifi.hotspot2.pps.CredentialTest.createCredential ( userCred , null , null , FakeKeys.CA_CERT0 , new java.security.cert.X509Certificate [ ] { android.net.wifi.FakeKeys.CLIENT_CERT } , FakeKeys.RSA_KEY1 ) ; }
Source:
public void test_getAllByName_localhost ( ) throws java.lang.Exception { java.net.InetAddress [ ] inetAddresses = java.net.InetAddress.getAllByName ( "localhost" ) ; libcore.java.net.InetAddressTest.assertEquals ( 1 , inetAddresses.length ) ; java.net.InetAddress inetAddress = inetAddresses [ 0 ] ; libcore.java.net.InetAddressTest.assertEquals ( libcore.java.net.InetAddressTest.LOOPBACK4_BYTES , "localhost" , inetAddress ) ; assertTrue ( inetAddress.isLoopbackAddress ( ) ) ; }

Target:
public void test_getByName_loopbackIpv4 ( ) throws java.lang.Exception { java.net.InetAddress inetAddress = java.net.InetAddress.getByName ( "127.0.0.1" ) ; libcore.java.net.InetAddressTest.checkInetAddress ( libcore.java.net.InetAddressTest.LOOPBACK4_BYTES , "localhost" , inetAddress ) ; org.junit.Assert.assertTrue ( inetAddress.isLoopbackAddress ( ) ) ; }
Source:
private void makeA2dpDeviceUnavailableNow ( java.lang.String address ) { synchronized ( mA2dpAvrcpLock ) { mAvrcpAbsVolSupported = false ; } android.media.AudioSystem.setDeviceConnectionState ( AudioSystem.DEVICE_OUT_BLUETOOTH_A2DP , AudioSystem.DEVICE_STATE_UNAVAILABLE , address ) ; mConnectedDevices.remove ( AudioSystem.DEVICE_OUT_BLUETOOTH_A2DP ) ; }

Target:
private void makeA2dpDeviceUnavailableNow ( java.lang.String address ) { synchronized ( mA2dpAvrcpLock ) { mAvrcpAbsVolSupported = false ; } android.media.AudioSystem.setDeviceConnectionState ( AudioSystem.DEVICE_OUT_BLUETOOTH_A2DP , AudioSystem.DEVICE_STATE_UNAVAILABLE , address ) ; mConnectedDevices.remove ( AudioSystem.DEVICE_OUT_BLUETOOTH_A2DP ) ; synchronized ( mCurAudioRoutes ) { if ( ( mCurAudioRoutes.mBluetoothName ) != null ) { mCurAudioRoutes.mBluetoothName = null ; android.media.AudioService.sendMsg ( mAudioHandler , android.media.AudioService.MSG_REPORT_NEW_ROUTES , android.media.AudioService.SENDMSG_NOOP , 0 , 0 , null , 0 ) ; } } }
Source:
public void test_listenUsingRfcommWithServiceRecord ( ) throws java.io.IOException { android.bluetooth.BluetoothAdapter adapter = android.bluetooth.BluetoothAdapter.getDefaultAdapter ( ) ; enable ( adapter ) ; android.bluetooth.BluetoothServerSocket socket = adapter.listenUsingRfcommWithServiceRecord ( "test" , java.util.UUID.randomUUID ( ) ) ; assertNotNull ( socket ) ; socket.close ( ) ; }

Target:
public void test_listenUsingRfcommWithServiceRecord ( ) throws java.io.IOException { if ( ! ( mHasBluetooth ) ) { return ; } android.bluetooth.BluetoothAdapter adapter = android.bluetooth.BluetoothAdapter.getDefaultAdapter ( ) ; enable ( adapter ) ; android.bluetooth.BluetoothServerSocket socket = adapter.listenUsingRfcommWithServiceRecord ( "test" , java.util.UUID.randomUUID ( ) ) ; assertNotNull ( socket ) ; socket.close ( ) ; }
Source:
public static void main ( java.lang.String [ ] args ) { if ( Main.triggerArrayOOM ( ) ) { java.lang.System.out.println ( "NEW_ARRAY correctly threw OOME" ) ; } if ( Main.triggerInstanceOOM ( ) ) { java.lang.System.out.println ( "NEW_INSTANCE correctly threw OOME" ) ; } }

Target:
public static void main ( java.lang.String [ ] args ) { if ( Main.triggerReflectionOOM ( ) ) { java.lang.System.out.println ( "Test reflection correctly threw" ) ; } if ( Main.triggerArrayOOM ( ) ) { java.lang.System.out.println ( "NEW_ARRAY correctly threw OOME" ) ; } if ( Main.triggerInstanceOOM ( ) ) { java.lang.System.out.println ( "NEW_INSTANCE correctly threw OOME" ) ; } }
Source:
private boolean isIPv6ULA ( ) { if ( ( address ) instanceof java.net.Inet6Address ) { byte [ ] bytes = address.getAddress ( ) ; return ( ( bytes [ 0 ] ) & ( ( byte ) ( 254 ) ) ) == ( ( byte ) ( 252 ) ) ; } return false ; }

Target:
private boolean isIPv6ULA ( ) { if ( isIPv6 ( ) ) { byte [ ] bytes = address.getAddress ( ) ; return ( ( bytes [ 0 ] ) & ( ( byte ) ( 254 ) ) ) == ( ( byte ) ( 252 ) ) ; } return false ; }
Source:
private static java.lang.String createDesription ( int minApiLevel , int exactApiLevel ) { java.lang.String s = "Broken package" ; s += ( exactApiLevel == ( com.android.sdklib.internal.repository.packages.BrokenPackage.API_LEVEL_INVALID ) ) ? " (No API level)" : java.lang.String.format ( " for API %d" , exactApiLevel ) ; s += ( minApiLevel == ( com.android.sdklib.internal.repository.packages.BrokenPackage.MIN_API_LEVEL_NOT_SPECIFIED ) ) ? "" : java.lang.String.format ( ", min API %d" , minApiLevel ) ; return s ; }

Target:
private static java.lang.String createDesription ( int minApiLevel , int exactApiLevel ) { java.lang.String s = "Broken package" ; s += ( exactApiLevel == ( BrokenPackage.API_LEVEL_INVALID ) ) ? " (No API level)" : java.lang.String.format ( " for API %d" , exactApiLevel ) ; s += ( minApiLevel == ( BrokenPackage.MIN_API_LEVEL_NOT_SPECIFIED ) ) ? "" : java.lang.String.format ( ", min API %d" , minApiLevel ) ; return s ; }
Source:
public java.lang.String describeFirstNonRequestableCapability ( ) { if ( hasCapability ( android.net.NetworkCapabilities.NET_CAPABILITY_VALIDATED ) ) return "NET_CAPABILITY_VALIDATED" ; if ( hasCapability ( android.net.NetworkCapabilities.NET_CAPABILITY_CAPTIVE_PORTAL ) ) return "NET_CAPABILITY_CAPTIVE_PORTAL" ; if ( hasCapability ( android.net.NetworkCapabilities.NET_CAPABILITY_FOREGROUND ) ) return "NET_CAPABILITY_FOREGROUND" ; if ( ( ( mNetworkCapabilities ) & ( android.net.NetworkCapabilities.NON_REQUESTABLE_CAPABILITIES ) ) != 0 ) { return "unknown non-requestable capabilities " + ( java.lang.Long.toHexString ( mNetworkCapabilities ) ) ; } if ( ( ( mLinkUpBandwidthKbps ) != 0 ) || ( ( mLinkDownBandwidthKbps ) != 0 ) ) return "link bandwidth" ; if ( hasSignalStrength ( ) ) return "signalStrength" ; return null ; }

Target:
public void clearAll ( ) { mNetworkCapabilities = mTransportTypes = 0 ; mLinkUpBandwidthKbps = mLinkDownBandwidthKbps = android.net.NetworkCapabilities.LINK_BANDWIDTH_UNSPECIFIED ; mNetworkSpecifier = null ; mSignalStrength = android.net.NetworkCapabilities.SIGNAL_STRENGTH_UNSPECIFIED ; mUids = null ; }
Source:
public void visit ( int version , int access , java.lang.String name , java.lang.String signature , java.lang.String superName , java.lang.String [ ] interfaces ) { companion = null ; internalName = name ; bytecodeVersion = version ; accessFlags = access ; super . visit ( version , access , name , signature , superName , interfaces ) ; }

Target:
public void visit ( int version , int access , java.lang.String name , java.lang.String signature , java.lang.String superName , java.lang.String [ ] interfaces ) { companion = null ; numberOfDefaultMethods = 0 ; internalName = name ; bytecodeVersion = version ; accessFlags = access ; if ( isInterface ( ) ) { depsCollector.recordExtendedInterfaces ( name , interfaces ) ; } super . visit ( version , access , name , signature , superName , interfaces ) ; }
Source:
public void afterHandshake ( long session , long s , long c , java.net.Socket sock , java.io.FileDescriptor fd , org.conscrypt.NativeCrypto.SSLHandshakeCallbacks callback ) throws java.lang.Exception { byte [ ] id = org.conscrypt.NativeCrypto.SSL_SESSION_session_id ( session ) ; assertNotNull ( id ) ; assertEquals ( 32 , id.length ) ; super . afterHandshake ( session , s , c , sock , fd , callback ) ; }

Target:
public void run ( long sslSession ) throws java.lang.Exception { try { org.conscrypt.NativeCrypto.SSL_shutdown ( sslSession , org.conscrypt.NativeCryptoTest.INVALID_FD , null ) ; fail ( ) ; } catch ( java.lang.NullPointerException expected ) { } }
Source:
public android.telephony.ims.ImsCallProfile createCallProfile ( int callSessionType , int callType ) { try { return mCompatFeature.createCallProfile ( mSessionId , callSessionType , callType ) ; } catch ( android.os.RemoteException e ) { throw new java.lang.RuntimeException ( e.getMessage ( ) ) ; } }

Target:
public void onFeatureRemoved ( ) { mContext.unregisterReceiver ( mReceiver ) ; try { mCompatFeature.endSession ( mSessionId ) ; mCompatFeature.removeRegistrationListener ( mListener ) ; if ( ( mRegCompatAdapter ) != null ) { mCompatFeature.removeRegistrationListener ( mRegCompatAdapter.getRegistrationListener ( ) ) ; } } catch ( android.os.RemoteException e ) { android.util.Log.w ( com.android.internal.telephony.ims.MmTelFeatureCompatAdapter.TAG , ( "onFeatureRemoved: Couldn't end session: " + ( e.getMessage ( ) ) ) ) ; } }
Source:
private boolean readNotifyBufferMessage ( ) { try { org.chromium.mojo.system.ResultAnd < org.chromium.mojo.system.MessagePipeHandle.ReadMessageResult > readMessageResult = mReadHandle.readMessage ( org.chromium.mojo.bindings.ExecutorFactory.NOTIFY_BUFFER , 0 , MessagePipeHandle.ReadFlags.NONE ) ; if ( ( readMessageResult.getMojoResult ( ) ) == ( org.chromium.mojo.system.MojoResult.OK ) ) { asyncWait ( ) ; return true ; } } catch ( org.chromium.mojo.system.MojoException e ) { } return false ; }

Target:
private void close ( ) { synchronized ( mLock ) { mWriteHandle.close ( ) ; mPendingActions.clear ( ) ; } mWatcher.cancel ( ) ; mWatcher.destroy ( ) ; mReadHandle.close ( ) ; }
Source:
static com.google.i18n.phonenumbers.Phonemetadata.PhoneMetadata getShortNumberMetadataForRegion ( java.lang.String regionCode ) { if ( ! ( com.google.i18n.phonenumbers.MetadataManager.regionCodeSet.contains ( regionCode ) ) ) { return null ; } synchronized ( com.google.i18n.phonenumbers.MetadataManager.regionCodeToShortNumberMetadataMap ) { if ( ! ( com.google.i18n.phonenumbers.MetadataManager.regionCodeToShortNumberMetadataMap.containsKey ( regionCode ) ) ) { com.google.i18n.phonenumbers.MetadataManager.loadShortNumberMetadataFromFile ( regionCode ) ; } } return com.google.i18n.phonenumbers.MetadataManager.regionCodeToShortNumberMetadataMap.get ( regionCode ) ; }

Target:
com.google.i18n.phonenumbers.Phonemetadata.PhoneMetadata get ( java.lang.String regionCode ) { return regionCodeToMetadata.get ( regionCode ) ; }
Source:
, @ dalvik.annotation.TestTargetNew ( level = dalvik.annotation.TestLevel.COMPLETE , method = "prepare" , args = { } ) , @ dalvik.annotation.TestTargetNew ( level = dalvik.annotation.TestLevel.COMPLETE , method = "setAudioEncoder" , args = { int . class } ) , @ dalvik.annotation.TestTargetNew ( level = dalvik.annotation.TestLevel.COMPLETE , method = "setAudioSource" , args = { int . class } ) , @ dalvik.annotation.TestTargetNew ( level = dalvik.annotation.TestLevel.COMPLETE , method = "setOutputFormat" , args = { int . class } ) , @ dalvik.annotation.TestTargetNew ( level = dalvik.annotation.TestLevel.COMPLETE , method = "start" , args = { } ) , @ dalvik.annotation.TestTargetNew ( level = dalvik.annotation.TestLevel.COMPLETE , method = "stop" , args = { } ) , @ dalvik.annotation.TestTargetNew ( level = dalvik.annotation.TestLevel.COMPLETE , method = "setOnErrorListener" , args = { android.media.MediaRecorder.OnErrorListener.class } ) , @ dalvik.annotation.TestTargetNew ( level = dalvik.annotation.TestLevel.COMPLETE , method = "setMaxFileSize" , args = { long . class } ) } ) public void testOnErrorListener ( ) throws java.lang.Exception { mMediaRecorder.setAudioSource ( MediaRecorder.AudioSource.DEFAULT ) ; mMediaRecorder.setOutputFormat ( MediaRecorder.OutputFormat.THREE_GPP ) ; mMediaRecorder.setAudioEncoder ( MediaRecorder.AudioEncoder.AMR_NB ) ; recordMedia ( android.media.cts.MediaRecorderTest.MAX_FILE_SIZE ) ; assertFalse ( mOnErrorCalled ) ; }

Target:
private void recordMedia ( long maxFileSize , java.io.File outFile ) throws java.lang.Exception { mMediaRecorder.setMaxFileSize ( maxFileSize ) ; mMediaRecorder.prepare ( ) ; mMediaRecorder.start ( ) ; java.lang.Thread.sleep ( android.media.cts.MediaRecorderTest.RECORD_TIME ) ; mMediaRecorder.stop ( ) ; assertTrue ( outFile.exists ( ) ) ; assertTrue ( ( ( outFile.length ( ) ) < ( 1.1 * maxFileSize ) ) ) ; assertTrue ( ( ( outFile.length ( ) ) > 0 ) ) ; }
Source:
public boolean isPaused ( ) { mFactory.startYourEngines ( true ) ; if ( checkNeedsPost ( ) ) { java.lang.Boolean ret = runOnUiThreadBlocking ( new java.util.concurrent.Callable < java.lang.Boolean > ( ) { @ java.lang.Override public java.lang.Boolean call ( ) { return isPaused ( ) ; } } ) ; return ret ; } return mAwContents.isPaused ( ) ; }

Target:
public void clearCache ( final boolean includeDiskFiles ) { if ( checkNeedsPost ( ) ) { mRunQueue.addTask ( new java.lang.Runnable ( ) { @ java.lang.Override public void run ( ) { clearCache ( includeDiskFiles ) ; } } ) ; return ; } mAwContents.clearCache ( includeDiskFiles ) ; }
Source:
public android.content.Intent expectStartActivityIntent ( int timeoutMs ) { android.content.Intent intent = null ; try { intent = mStartedActivities.poll ( timeoutMs , java.util.concurrent.TimeUnit.MILLISECONDS ) ; } catch ( java.lang.InterruptedException e ) { } assertNotNull ( ( ( "Did not receive sign-in intent after " + timeoutMs ) + "ms" ) , intent ) ; return intent ; }

Target:
public android.content.Intent expectStartActivityIntent ( int timeoutMs ) { android.content.Intent intent = null ; try { intent = mStartedActivities.poll ( timeoutMs , java.util.concurrent.TimeUnit.MILLISECONDS ) ; } catch ( java.lang.InterruptedException e ) { } org.junit.Assert.assertNotNull ( ( ( "Did not receive sign-in intent after " + timeoutMs ) + "ms" ) , intent ) ; return intent ; }
Source:
private int getSelectedSavedFilterIndex ( ) { return mFiltersTableViewer.getTable ( ) . getSelectionIndex ( ) ; }

Target:
private void filterSelectionChanged ( ) { int idx = mFiltersTableViewer.getTable ( ) . getSelectionIndex ( ) ; if ( idx == ( - 1 ) ) { idx = 0 ; mFiltersTableViewer.getTable ( ) . setSelection ( idx ) ; } mCurrentSelectedFilterIndex = idx ; resetUnreadCountForSelectedFilter ( ) ; updateFiltersToolBar ( ) ; updateAppliedFilters ( ) ; }
Source:
private static boolean isRootStorageDir ( java.lang.String artPath ) { for ( int i = 0 ; i < ( com.android.providers.media.MediaProvider.mExternalStoragePaths.length ) ; i ++ ) { if ( ( ( com.android.providers.media.MediaProvider.mExternalStoragePaths [ i ] ) != null ) && ( artPath.equalsIgnoreCase ( com.android.providers.media.MediaProvider.mExternalStoragePaths [ i ] ) ) ) return true ; } return false ; }

Target:
private static boolean isRootStorageDir ( java.lang.String [ ] rootPaths , java.lang.String testPath ) { for ( java.lang.String rootPath : rootPaths ) { if ( ( rootPath != null ) && ( rootPath.equalsIgnoreCase ( testPath ) ) ) { return true ; } } return false ; }
Source:
public boolean countryUsesUtc ( java.lang.String isoCountryCode , long whenMillis ) { if ( android.text.TextUtils.isEmpty ( isoCountryCode ) ) { return false ; } libcore.util.CountryTimeZones countryTimeZones = libcore.util.TimeZoneFinder.getInstance ( ) . lookupCountryTimeZones ( isoCountryCode ) ; return ( countryTimeZones != null ) && ( countryTimeZones.hasUtcZone ( whenMillis ) ) ; }

Target:
private libcore.util.CountryTimeZones getCountryTimeZones ( java.lang.String isoCountryCode ) { synchronized ( this ) { if ( ( mLastCountryTimeZones ) != null ) { if ( mLastCountryTimeZones.isForCountryCode ( isoCountryCode ) ) { return mLastCountryTimeZones ; } } libcore.util.CountryTimeZones countryTimeZones = libcore.util.TimeZoneFinder.getInstance ( ) . lookupCountryTimeZones ( isoCountryCode ) ; if ( countryTimeZones != null ) { mLastCountryTimeZones = countryTimeZones ; } return countryTimeZones ; } }
Source:
private final void resetContext ( ) { org.conscrypt.OpenSSLDigestContext ctxLocal = new org.conscrypt.OpenSSLDigestContext ( org.conscrypt.NativeCrypto.EVP_MD_CTX_create ( ) ) ; org.conscrypt.NativeCrypto.EVP_MD_CTX_init ( ctxLocal ) ; if ( signing ) { enableDSASignatureNonceHardeningIfApplicable ( ) ; org.conscrypt.NativeCrypto.EVP_SignInit ( ctxLocal , evpAlgorithm ) ; } else { org.conscrypt.NativeCrypto.EVP_VerifyInit ( ctxLocal , evpAlgorithm ) ; } this . ctx = ctxLocal ; }

Target:
private final void resetContext ( ) { org.conscrypt.NativeRef.EVP_MD_CTX ctxLocal = new org.conscrypt.NativeRef.EVP_MD_CTX ( org.conscrypt.NativeCrypto.EVP_MD_CTX_create ( ) ) ; org.conscrypt.NativeCrypto.EVP_MD_CTX_init ( ctxLocal ) ; if ( signing ) { enableDSASignatureNonceHardeningIfApplicable ( ) ; org.conscrypt.NativeCrypto.EVP_SignInit ( ctxLocal , evpAlgorithm ) ; } else { org.conscrypt.NativeCrypto.EVP_VerifyInit ( ctxLocal , evpAlgorithm ) ; } this . ctx = ctxLocal ; }
Source:
public void statusIndication ( int token , int status ) { android.util.Log.d ( com.android.bluetooth.sap.SapRilReceiver.TAG , ( ( ( "statusIndication: token " + token ) + " status " ) + status ) ) ; com.android.bluetooth.sap.SapMessage sapMessage = new com.android.bluetooth.sap.SapMessage ( SapMessage.ID_STATUS_IND ) ; sapMessage.setStatusChange ( status ) ; sendSapMessage ( sapMessage ) ; }

Target:
public void statusIndication ( int token , int status ) { android.util.Log.d ( com.android.bluetooth.sap.SapRilReceiver.TAG , ( ( ( "statusIndication: token " + token ) + " status " ) + status ) ) ; com.android.bluetooth.sap.SapService.notifyUpdateWakeLock ( mSapServiceHandler ) ; com.android.bluetooth.sap.SapMessage sapMessage = new com.android.bluetooth.sap.SapMessage ( SapMessage.ID_STATUS_IND ) ; sapMessage.setStatusChange ( status ) ; sendSapMessage ( sapMessage ) ; }
Source:
public final void testHasHardwarePropHashChanged_Oem ( ) { final com.android.sdklib.devices.Device d2 = dm.getDevice ( "Nexus One" , "Google" ) ; assertEquals ( "MD5:d886364fc30320c0518f51002d0ef22d" , com.android.sdklib.devices.DeviceManager.hasHardwarePropHashChanged ( d2 , "invalid" ) ) ; assertEquals ( null , com.android.sdklib.devices.DeviceManager.hasHardwarePropHashChanged ( d2 , "MD5:d886364fc30320c0518f51002d0ef22d" ) ) ; d2.getDefaultHardware ( ) . setKeyboard ( Keyboard.QWERTY ) ; assertEquals ( "MD5:db682e0a58e74a8614e43e6e15c05176" , com.android.sdklib.devices.DeviceManager.hasHardwarePropHashChanged ( d2 , "MD5:d886364fc30320c0518f51002d0ef22d" ) ) ; d2.getDefaultHardware ( ) . setKeyboard ( Keyboard.NOKEY ) ; assertEquals ( null , com.android.sdklib.devices.DeviceManager.hasHardwarePropHashChanged ( d2 , "MD5:d886364fc30320c0518f51002d0ef22d" ) ) ; }

Target:
public final void testHasHardwarePropHashChanged_Oem ( ) { final com.android.sdklib.devices.Device d2 = dm.getDevice ( "Nexus One" , "Google" ) ; assertEquals ( "MD5:36362a51e6c830c2ab515a312c9ecbff" , com.android.sdklib.devices.DeviceManager.hasHardwarePropHashChanged ( d2 , "invalid" ) ) ; assertEquals ( null , com.android.sdklib.devices.DeviceManager.hasHardwarePropHashChanged ( d2 , "MD5:36362a51e6c830c2ab515a312c9ecbff" ) ) ; d2.getDefaultHardware ( ) . setKeyboard ( Keyboard.QWERTY ) ; assertEquals ( "MD5:f8f4b390755f2f58dfeb7d3020cd87db" , com.android.sdklib.devices.DeviceManager.hasHardwarePropHashChanged ( d2 , "MD5:36362a51e6c830c2ab515a312c9ecbff" ) ) ; d2.getDefaultHardware ( ) . setKeyboard ( Keyboard.NOKEY ) ; assertEquals ( null , com.android.sdklib.devices.DeviceManager.hasHardwarePropHashChanged ( d2 , "MD5:36362a51e6c830c2ab515a312c9ecbff" ) ) ; }
Source:
public void setUp ( ) throws java.lang.Exception { super . setUp ( ) ; server = new tests.support.Support_TestWebServer ( ) ; org.apache.harmony.luni.tests.java.net.URLConnectionTest.port = server.initServer ( ) ; url = new java.net.URL ( ( ( "http://localhost:" + ( org.apache.harmony.luni.tests.java.net.URLConnectionTest.port ) ) + "/test1" ) ) ; uc = url.openConnection ( ) ; url2 = new java.net.URL ( ( ( "http://localhost:" + ( org.apache.harmony.luni.tests.java.net.URLConnectionTest.port ) ) + "/test2" ) ) ; uc2 = url2.openConnection ( ) ; url3 = new java.net.URL ( ( ( "http://localhost:" + ( org.apache.harmony.luni.tests.java.net.URLConnectionTest.port ) ) + "/test3" ) ) ; uc3 = url3.openConnection ( ) ; fileURL = createTempHelloWorldFile ( ) ; fileURLCon = fileURL.openConnection ( ) ; jarURLCon = openJarURLConnection ( ) ; }

Target:
public void setUp ( ) throws java.lang.Exception { super . setUp ( ) ; server = new tests.support.Support_TestWebServer ( ) ; server.setDelay ( 10 ) ; org.apache.harmony.luni.tests.java.net.URLConnectionTest.port = server.initServer ( ) ; url = new java.net.URL ( ( ( "http://localhost:" + ( org.apache.harmony.luni.tests.java.net.URLConnectionTest.port ) ) + "/test1" ) ) ; uc = url.openConnection ( ) ; url2 = new java.net.URL ( ( ( "http://localhost:" + ( org.apache.harmony.luni.tests.java.net.URLConnectionTest.port ) ) + "/test2" ) ) ; uc2 = url2.openConnection ( ) ; url3 = new java.net.URL ( ( ( "http://localhost:" + ( org.apache.harmony.luni.tests.java.net.URLConnectionTest.port ) ) + "/test3" ) ) ; uc3 = url3.openConnection ( ) ; fileURL = createTempHelloWorldFile ( ) ; fileURLCon = fileURL.openConnection ( ) ; jarURLCon = openJarURLConnection ( ) ; }
Source:
public static void checkVersionNumbers ( int classVersion ) throws java.lang.UnsupportedOperationException { if ( ( classVersion < ( proguard.classfile.ClassConstants.INTERNAL_CLASS_VERSION_1_0 ) ) || ( classVersion > ( proguard.classfile.ClassConstants.INTERNAL_CLASS_VERSION_1_7 ) ) ) { throw new java.lang.UnsupportedOperationException ( ( ( ( ( ( ( ( ( ( ( "Unsupported class version number [" + ( proguard.classfile.util.ClassUtil.internalMajorClassVersion ( classVersion ) ) ) + "." ) + ( proguard.classfile.util.ClassUtil.internalMinorClassVersion ( classVersion ) ) ) + "] (maximum " ) + ( proguard.classfile.ClassConstants.INTERNAL_CLASS_VERSION_1_7_MAJOR ) ) + "." ) + ( proguard.classfile.ClassConstants.INTERNAL_CLASS_VERSION_1_7_MINOR ) ) + ", Java " ) + ( proguard.classfile.ClassConstants.EXTERNAL_CLASS_VERSION_1_7 ) ) + ")" ) ) ; } }

Target:
public static void checkVersionNumbers ( int classVersion ) throws java.lang.UnsupportedOperationException { if ( ( classVersion < ( ClassConstants.CLASS_VERSION_1_0 ) ) || ( classVersion > ( ClassConstants.CLASS_VERSION_1_8 ) ) ) { throw new java.lang.UnsupportedOperationException ( ( ( ( ( ( ( ( ( ( ( "Unsupported class version number [" + ( proguard.classfile.util.ClassUtil.internalMajorClassVersion ( classVersion ) ) ) + "." ) + ( proguard.classfile.util.ClassUtil.internalMinorClassVersion ( classVersion ) ) ) + "] (maximum " ) + ( ClassConstants.CLASS_VERSION_1_8_MAJOR ) ) + "." ) + ( ClassConstants.CLASS_VERSION_1_8_MINOR ) ) + ", Java " ) + ( JavaConstants.CLASS_VERSION_1_8 ) ) + ")" ) ) ; } }
Source:
public void testEtwsMessageCancel ( ) { android.telephony.SmsCbMessage msg = com.android.internal.telephony.gsm.GsmSmsCbTest.createFromPdu ( com.android.internal.telephony.gsm.GsmSmsCbTest.etwsMessageCancel ) ; android.util.Log.d ( com.android.internal.telephony.gsm.GsmSmsCbTest.TAG , msg.toString ( ) ) ; assertEquals ( "GS mismatch" , 0 , msg.getGeographicalScope ( ) ) ; assertEquals ( "serial number mismatch" , 0 , msg.getSerialNumber ( ) ) ; assertEquals ( "message ID mismatch" , 4352 , msg.getServiceCategory ( ) ) ; assertEquals ( "warning type mismatch" , SmsCbEtwsInfo.ETWS_WARNING_TYPE_EARTHQUAKE , msg.getEtwsWarningInfo ( ) . getWarningType ( ) ) ; }

Target:
public void testEtwsMessageCancel ( ) { android.telephony.SmsCbMessage msg = com.android.internal.telephony.gsm.GsmSmsCbTest.createFromPdu ( com.android.internal.telephony.gsm.GsmSmsCbTest.etwsMessageCancel ) ; android.telephony.Rlog.d ( com.android.internal.telephony.gsm.GsmSmsCbTest.TAG , msg.toString ( ) ) ; assertEquals ( "GS mismatch" , 0 , msg.getGeographicalScope ( ) ) ; assertEquals ( "serial number mismatch" , 0 , msg.getSerialNumber ( ) ) ; assertEquals ( "message ID mismatch" , 4352 , msg.getServiceCategory ( ) ) ; assertEquals ( "warning type mismatch" , SmsCbEtwsInfo.ETWS_WARNING_TYPE_EARTHQUAKE , msg.getEtwsWarningInfo ( ) . getWarningType ( ) ) ; }
Source:
public void test ( ) throws java.lang.Exception { assertEquals ( ( "src/test/pkg/WrongColor.java:9: Error: Should pass resolved color instead of resource id here: getResources().getColor(R.color.blue) [ResourceAsColor]\n" + ( ( ( ( ( ( ( ( ( " paint2.setColor(R.color.blue);\n" + " ~~~~~~~~~~~~\n" ) + "src/test/pkg/WrongColor.java:11: Error: Should pass resolved color instead of resource id here: getResources().getColor(R.color.red) [ResourceAsColor]\n" ) + " textView.setTextColor(R.color.red);\n" ) + " ~~~~~~~~~~~\n" ) + "src/test/pkg/WrongColor.java:12: Error: Should pass resolved color instead of resource id here: getResources().getColor(android.R.color.red) [ResourceAsColor]\n" ) + " textView.setTextColor(android.R.color.red);\n" ) + " ~~~~~~~~~~~~~~~~~~~\n" ) + "3 errors, 0 warnings\n" ) + "" ) ) , lintProject ( "src/test/pkg/WrongColor.java.txt=>src/test/pkg/WrongColor.java" ) ) ; }

Target:
public void test ( ) throws java.lang.Exception { assertEquals ( ( "src/test/pkg/WrongColor.java:9: Error: Should pass resolved color instead of resource id here: getResources().getColor(R.color.blue) [ResourceAsColor]\n" + ( ( ( ( ( ( ( ( ( ( ( ( ( ( " paint2.setColor(R.color.blue);\n" + " ~~~~~~~~~~~~\n" ) + "src/test/pkg/WrongColor.java:11: Error: Should pass resolved color instead of resource id here: getResources().getColor(R.color.red) [ResourceAsColor]\n" ) + " textView.setTextColor(R.color.red);\n" ) + " ~~~~~~~~~~~\n" ) + "src/test/pkg/WrongColor.java:12: Error: Should pass resolved color instead of resource id here: getResources().getColor(android.R.color.red) [ResourceAsColor]\n" ) + " textView.setTextColor(android.R.color.red);\n" ) + " ~~~~~~~~~~~~~~~~~~~\n" ) + "src/test/pkg/WrongColor.java:13: Error: Should pass resolved color instead of resource id here: getResources().getColor(R.color.blue) [ResourceAsColor]\n" ) + " textView.setTextColor(foo > 0 ? R.color.green : R.color.blue);\n" ) + " ~~~~~~~~~~~~\n" ) + "src/test/pkg/WrongColor.java:13: Error: Should pass resolved color instead of resource id here: getResources().getColor(R.color.green) [ResourceAsColor]\n" ) + " textView.setTextColor(foo > 0 ? R.color.green : R.color.blue);\n" ) + " ~~~~~~~~~~~~~\n" ) + "5 errors, 0 warnings\n" ) ) , lintProject ( "src/test/pkg/WrongColor.java.txt=>src/test/pkg/WrongColor.java" ) ) ; }
Source:
public void actionPerformed ( com.intellij.openapi.actionSystem.AnActionEvent e ) { com.intellij.openapi.project.Project project = PlatformDataKeys.PROJECT.getData ( e.getDataContext ( ) ) ; if ( project == null ) { project = com.intellij.openapi.project.ProjectManager.getInstance ( ) . getDefaultProject ( ) ; } if ( com.intellij.ide.actions.ShowStructureSettingsAction.isGradleProject ( project ) ) { com.intellij.openapi.ui.Messages.showInfoMessage ( ( "We will provide a UI to configure project settings later. " + "Until then, please manually edit your build.gradle file(s.)" ) , "Project Structure" ) ; return ; } com.intellij.openapi.options.ShowSettingsUtil.getInstance ( ) . editConfigurable ( project , OptionsEditorDialog.DIMENSION_KEY , com.intellij.openapi.roots.ui.configuration.ProjectStructureConfigurable.getInstance ( project ) ) ; }

Target:
public void actionPerformed ( com.intellij.openapi.actionSystem.AnActionEvent e ) { com.intellij.openapi.project.Project project = PlatformDataKeys.PROJECT.getData ( e.getDataContext ( ) ) ; if ( project == null ) { project = com.intellij.openapi.project.ProjectManager.getInstance ( ) . getDefaultProject ( ) ; } if ( com.intellij.ide.actions.ShowStructureSettingsAction.isGradleProject ( project ) ) { com.intellij.ide.actions.ShowStructureSettingsAction.showDisabledProjectStructureDialogMessage ( ) ; return ; } com.intellij.openapi.options.ShowSettingsUtil.getInstance ( ) . editConfigurable ( project , OptionsEditorDialog.DIMENSION_KEY , com.intellij.openapi.roots.ui.configuration.ProjectStructureConfigurable.getInstance ( project ) ) ; }
Source:
public void widgetDefaultSelected ( org.eclipse.swt.events.SelectionEvent arg0 ) { java.util.List < com.android.ddmuilib.logcat.LogCatMessage > selectedMessages = getSelectedLogCatMessages ( ) ; if ( ( selectedMessages.size ( ) ) == 0 ) { return ; } for ( com.android.ddmuilib.logcat.ILogCatMessageSelectionListener l : mMessageSelectionListeners ) { l.messageDoubleClicked ( selectedMessages.get ( 0 ) ) ; } }

Target:
public void copy ( org.eclipse.swt.dnd.Clipboard clipboard ) { copySelectionToClipboard ( clipboard ) ; }
Source:
public void setUp ( ) throws java.lang.Exception { mResultsDir = com.android.tradefed.util.FileUtil.createTempDir ( "results" ) ; mResultDir = com.android.tradefed.util.FileUtil.createTempDir ( "12345" , mResultsDir ) ; mSubPlansDir = com.android.tradefed.util.FileUtil.createTempDir ( "subplans" ) ; mBuildHelper = new com.android.compatibility.common.tradefed.result.SubPlanCreatorTest.SpctMockCompatibilityBuildHelper ( new com.android.tradefed.build.BuildInfo ( "0" , "" , "" ) ) ; populateResults ( ) ; mSubPlanCreator = new com.android.compatibility.common.tradefed.result.SubPlanCreator ( ) ; com.android.tradefed.config.ArgsOptionParser optionParser = new com.android.tradefed.config.ArgsOptionParser ( mSubPlanCreator ) ; optionParser.parse ( java.util.Arrays.asList ( "-n" , com.android.compatibility.common.tradefed.result.SubPlanCreatorTest.SP_NAME , "--session" , com.android.compatibility.common.tradefed.result.SubPlanCreatorTest.SP_SESSION , "-r" , com.android.compatibility.common.tradefed.result.SubPlanCreatorTest.SP_RESULT_TYPE_FAILED , "-r" , com.android.compatibility.common.tradefed.result.SubPlanCreatorTest.SP_RESULT_TYPE_NOT_EXECUTED ) ) ; }

Target:
public void setUp ( ) throws java.lang.Exception { mResultsDir = com.android.tradefed.util.FileUtil.createTempDir ( "results" ) ; mResultDir = com.android.tradefed.util.FileUtil.createTempDir ( "12345" , mResultsDir ) ; mSubPlansDir = com.android.tradefed.util.FileUtil.createTempDir ( "subplans" ) ; mBuildHelper = new com.android.compatibility.common.tradefed.result.SubPlanCreatorTest.SpctMockCompatibilityBuildHelper ( new com.android.tradefed.build.BuildInfo ( "0" , "" , "" ) ) ; populateResults ( ) ; mSubPlanCreator = new com.android.compatibility.common.tradefed.result.SubPlanCreator ( ) ; com.android.tradefed.config.ArgsOptionParser optionParser = new com.android.tradefed.config.ArgsOptionParser ( mSubPlanCreator ) ; optionParser.parse ( java.util.Arrays.asList ( "-n" , com.android.compatibility.common.tradefed.result.SubPlanCreatorTest.SP_NAME , "--session" , com.android.compatibility.common.tradefed.result.SubPlanCreatorTest.SP_SESSION , "--result-type" , com.android.compatibility.common.tradefed.result.SubPlanCreatorTest.SP_RESULT_TYPE_FAILED , "--result-type" , com.android.compatibility.common.tradefed.result.SubPlanCreatorTest.SP_RESULT_TYPE_NOT_EXECUTED ) ) ; }
Source:
private static void waitToDie ( java.lang.Thread thread ) { try { thread.join ( 5000 ) ; } catch ( java.lang.InterruptedException ignored ) { } if ( thread.isAlive ( ) ) { fail ( ( ( "Thread \"" + ( thread.getName ( ) ) ) + "\" did not exit." ) ) ; } }

Target:
private static void waitToDie ( java.lang.Thread thread ) { assertFalse ( java.lang.Thread.currentThread ( ) . isInterrupted ( ) ) ; try { thread.join ( 5000 ) ; } catch ( java.lang.InterruptedException ignored ) { ignored.printStackTrace ( ) ; } if ( thread.isAlive ( ) ) { fail ( ( ( "Thread \"" + ( thread.getName ( ) ) ) + "\" did not exit." ) ) ; } }
Source:
private boolean areAllApplicationsReady ( ) { for ( com.android.internal.telephony.uicc.UiccCardApplication app : mUiccApplications ) { if ( ( ( app != null ) && ( isSupportedApplication ( app ) ) ) && ( ! ( app.isReady ( ) ) ) ) { return false ; } } return ( mUiccApplications [ 0 ] ) != null ; }

Target:
private boolean areAllApplicationsReady ( ) { for ( com.android.internal.telephony.uicc.UiccCardApplication app : mUiccApplications ) { if ( ( ( app != null ) && ( isSupportedApplication ( app ) ) ) && ( ! ( app.isReady ( ) ) ) ) { if ( com.android.internal.telephony.uicc.UiccProfile.VDBG ) log ( "areAllApplicationsReady: return false" ) ; return false ; } } if ( com.android.internal.telephony.uicc.UiccProfile.VDBG ) { log ( ( "areAllApplicationsReady: outside loop, return " + ( ( mUiccApplications [ 0 ] ) != null ) ) ) ; } return ( mUiccApplications [ 0 ] ) != null ; }
Source:
private boolean shadowsAnyFields ( proguard.optimize.peephole.Clazz clazz , proguard.optimize.peephole.Clazz targetClass ) { proguard.optimize.peephole.MemberCounter counter = new proguard.optimize.peephole.MemberCounter ( ) ; clazz.hierarchyAccept ( true , false , false , true , new proguard.optimize.peephole.AllFieldVisitor ( new proguard.optimize.peephole.SimilarMemberVisitor ( targetClass , true , true , true , false , new proguard.optimize.peephole.MemberAccessFilter ( 0 , ClassConstants.INTERNAL_ACC_PRIVATE , counter ) ) ) ) ; return ( counter.getCount ( ) ) > 0 ; }

Target:
private boolean shadowsAnyFields ( proguard.optimize.peephole.Clazz clazz , proguard.optimize.peephole.Clazz targetClass ) { proguard.optimize.peephole.MemberCounter counter = new proguard.optimize.peephole.MemberCounter ( ) ; clazz.hierarchyAccept ( true , false , false , true , new proguard.optimize.peephole.AllFieldVisitor ( new proguard.optimize.peephole.SimilarMemberVisitor ( targetClass , true , true , true , false , new proguard.optimize.peephole.MemberAccessFilter ( 0 , ClassConstants.ACC_PRIVATE , counter ) ) ) ) ; return ( counter.getCount ( ) ) > 0 ; }
Source:
public void close ( ) throws com.android.sched.util.file.CannotCloseException { vfs.close ( ) ; try { if ( dir.exists ( ) ) { com.android.sched.util.file.FileUtils.deleteDir ( dir ) ; } } catch ( java.io.IOException e ) { throw new com.android.sched.util.file.CannotCloseException ( new com.android.sched.util.location.DirectoryLocation ( dir ) , e ) ; } }

Target:
public synchronized void close ( ) throws com.android.sched.util.file.CannotCloseException { if ( ! ( closed ) ) { vfs.close ( ) ; try { if ( dir.exists ( ) ) { com.android.sched.util.file.FileUtils.deleteDir ( dir ) ; } } catch ( java.io.IOException e ) { throw new com.android.sched.util.file.CannotCloseException ( new com.android.sched.util.location.DirectoryLocation ( dir ) , e ) ; } closed = true ; } }
Source:
public boolean postExecutionCheck ( com.android.tradefed.device.ITestDevice device ) throws com.android.tradefed.device.DeviceNotAvailableException { if ( ! ( com.android.compatibility.common.util.MonitoringUtils.checkDeviceConnectivity ( device ) ) ) { setFailureMessage ( "failed network connectivity check" ) ; return false ; } return true ; }

Target:
public boolean postExecutionCheck ( com.android.tradefed.device.ITestDevice device ) throws com.android.tradefed.device.DeviceNotAvailableException { if ( ! ( com.android.compatibility.common.util.MonitoringUtils.checkDeviceConnectivity ( device ) ) ) { if ( mIsFailed ) { com.android.tradefed.log.LogUtil.CLog.w ( "NetworkConnectivityChecker is still failing." ) ; return true ; } mIsFailed = true ; return false ; } mIsFailed = false ; return true ; }
Source:
public void logrb ( java.util.logging.Level level , java.lang.String sourceClass , java.lang.String sourceMethod , java.lang.String bundleName , java.lang.String msg , java.lang.Throwable thrown ) { if ( ( ( level.intValue ( ) ) < ( levelValue ) ) || ( ( levelValue ) == ( java.util.logging.Logger.offValue ) ) ) { return ; } java.util.logging.LogRecord lr = new java.util.logging.LogRecord ( level , msg ) ; lr.setSourceClassName ( sourceClass ) ; lr.setSourceMethodName ( sourceMethod ) ; lr.setThrown ( thrown ) ; doLog ( lr , bundleName ) ; }

Target:
public void logp ( java.util.logging.Level level , java.lang.String sourceClass , java.lang.String sourceMethod , java.lang.Throwable thrown , java.util.function.Supplier < java.lang.String > msgSupplier ) { if ( ! ( isLoggable ( level ) ) ) { return ; } java.util.logging.LogRecord lr = new java.util.logging.LogRecord ( level , msgSupplier.get ( ) ) ; lr.setSourceClassName ( sourceClass ) ; lr.setSourceMethodName ( sourceMethod ) ; lr.setThrown ( thrown ) ; doLog ( lr ) ; }
Source:
public void run ( ) { while ( isRunning ( ) ) { java.lang.Object object = waitForObject ( ) ; if ( object == null ) { continue ; } boolean finalized = waitForFinalization ( object ) ; if ( ( ! finalized ) && ( ! ( dalvik.system.VMRuntime.getRuntime ( ) . isDebuggerActive ( ) ) ) ) { java.lang.Daemons.FinalizerWatchdogDaemon.finalizerTimedOut ( object ) ; break ; } } }

Target:
public void run ( ) { while ( isRunning ( ) ) { boolean waitSuccessful = waitForObject ( ) ; if ( waitSuccessful == false ) { continue ; } boolean finalized = waitForFinalization ( ) ; if ( ( ! finalized ) && ( ! ( dalvik.system.VMRuntime.getRuntime ( ) . isDebuggerActive ( ) ) ) ) { java.lang.Object finalizedObject = java.lang.Daemons.FinalizerDaemon.INSTANCE.finalizingObject ; if ( finalizedObject != null ) { java.lang.Daemons.FinalizerWatchdogDaemon.finalizerTimedOut ( finalizedObject ) ; break ; } } } }
Source:
private void setup ( ) { android.content.pm.LauncherApps launcherApps = ( ( android.content.pm.LauncherApps ) ( getSystemService ( Context.LAUNCHER_APPS_SERVICE ) ) ) ; synchronized ( com.android.cts.launchertests.support.LauncherCallbackTestsService.mPackagesLock ) { com.android.cts.launchertests.support.LauncherCallbackTestsService.mPackagesAdded.clear ( ) ; com.android.cts.launchertests.support.LauncherCallbackTestsService.mPackagesRemoved.clear ( ) ; com.android.cts.launchertests.support.LauncherCallbackTestsService.mPackagesChanged.clear ( ) ; if ( ( mCallback ) != null ) { launcherApps.unregisterCallback ( mCallback ) ; } mCallback = new com.android.cts.launchertests.support.LauncherCallbackTestsService.TestCallback ( ) ; launcherApps.registerCallback ( mCallback ) ; } }

Target:
private void setup ( ) { android.content.pm.LauncherApps launcherApps = ( ( android.content.pm.LauncherApps ) ( getSystemService ( Context.LAUNCHER_APPS_SERVICE ) ) ) ; synchronized ( mCallbackLock ) { if ( ( mCallback ) != null ) { launcherApps.unregisterCallback ( mCallback ) ; } com.android.cts.launchertests.support.LauncherCallbackTestsService.mPackagesAdded.clear ( ) ; com.android.cts.launchertests.support.LauncherCallbackTestsService.mPackagesRemoved.clear ( ) ; com.android.cts.launchertests.support.LauncherCallbackTestsService.mPackagesChanged.clear ( ) ; mCallback = new com.android.cts.launchertests.support.LauncherCallbackTestsService.TestCallback ( ) ; launcherApps.registerCallback ( mCallback , new android.os.Handler ( mCallbackThread.getLooper ( ) ) ) ; android.util.Log.i ( com.android.cts.launchertests.support.LauncherCallbackTestsService.TAG , "started listening for events" ) ; } }
Source:
public void testProxyingPackagePrivateMethods_AreIntercepted ( ) throws java.lang.Throwable { assertEquals ( "fake result" , proxyFor ( com.google.dexmaker.stock.ProxyBuilderTest.HasPackagePrivateMethod.class ) . build ( ) . result ( ) ) ; }

Target:
public void testProxying_ClassHierarchy ( ) throws java.lang.Throwable { assertEquals ( "package" , proxyFor ( com.google.dexmaker.stock.ProxyBuilderTest.MyParentClass.class ) . build ( ) . someMethod ( ) ) ; assertEquals ( "fake result" , proxyFor ( com.google.dexmaker.stock.ProxyBuilderTest.MyChildClassWithProtectedMethod.class ) . build ( ) . someMethod ( ) ) ; assertEquals ( "fake result" , proxyFor ( com.google.dexmaker.stock.ProxyBuilderTest.MyChildClassWithPublicMethod.class ) . build ( ) . someMethod ( ) ) ; }
Source:
public static void main ( java.lang.String [ ] args ) { UnresolvedClass c = new UnresolvedClass ( ) ; Main.callInvokeUnresolvedStatic ( ) ; Main.callInvokeUnresolvedVirtual ( c ) ; Main.callInvokeUnresolvedInterface ( c ) ; Main.callInvokeUnresolvedSuper ( new Main ( ) ) ; }

Target:
public static void main ( java.lang.String [ ] args ) { UnresolvedClass c = new UnresolvedClass ( ) ; Main.callInvokeUnresolvedStatic ( ) ; Main.callInvokeUnresolvedVirtual ( c ) ; Main.callInvokeUnresolvedInterface ( c ) ; Main.callInvokeUnresolvedSuper ( new Main ( ) ) ; Main.callUnresolvedStaticFieldAccess ( ) ; Main.callUnresolvedInstanceFieldAccess ( c ) ; }
Source:
private static boolean hasFirstArgument ( lombok.ast.Expression argument , java.util.List < lombok.ast.MethodInvocation > list ) { for ( lombok.ast.MethodInvocation method : list ) { lombok.ast.Expression argument1 = method.astArguments ( ) . first ( ) ; if ( argument.toString ( ) . equals ( argument1.toString ( ) ) ) { return true ; } } return false ; }

Target:
private static boolean hasFirstArgument ( com.intellij.psi.PsiExpression argument , java.util.List < com.intellij.psi.PsiMethodCallExpression > list ) { for ( com.intellij.psi.PsiMethodCallExpression call : list ) { com.intellij.psi.PsiExpression [ ] expressions = call.getArgumentList ( ) . getExpressions ( ) ; if ( ( expressions.length ) > 0 ) { com.intellij.psi.PsiExpression argument2 = expressions [ 0 ] ; if ( argument.getText ( ) . equals ( argument2.getText ( ) ) ) { return true ; } } } return false ; }
Source:
public void testE3 ( ) { dot.junit.opcodes.aput_wide.d.T_aput_wide_1 t = new dot.junit.opcodes.aput_wide.d.T_aput_wide_1 ( ) ; long [ ] arr = new long [ 2 ] ; try { t.run ( arr , ( - 1 ) , 100000000000L ) ; fail ( "expected ArrayIndexOutOfBoundsException" ) ; } catch ( java.lang.ArrayIndexOutOfBoundsException aie ) { } }

Target:
public void testVFE4 ( ) { load ( "dot.junit.opcodes.aput_wide.d.T_aput_wide_9" , java.lang.VerifyError.class ) ; }
Source:
public long getAppDataInode ( java.lang.String uuid , java.lang.String pkgname , int userid , int flags ) throws com.android.internal.os.InstallerConnection.InstallerException { final java.lang.String [ ] res = mInstaller.execute ( "get_app_data_inode" , uuid , pkgname , userid , flags ) ; try { return java.lang.Long.parseLong ( res [ 1 ] ) ; } catch ( java.lang.ArrayIndexOutOfBoundsException | java.lang.NumberFormatException e ) { throw new com.android.internal.os.InstallerConnection.InstallerException ( ( "Invalid inode result: " + ( java.util.Arrays.toString ( res ) ) ) ) ; } }

Target:
public long getAppDataInode ( java.lang.String uuid , java.lang.String packageName , int userId , int flags ) throws com.android.internal.os.InstallerConnection.InstallerException { checkLock ( ) ; try { return mInstalld.getAppDataInode ( uuid , packageName , userId , flags ) ; } catch ( android.os.RemoteException | android.os.ServiceSpecificException e ) { throw new com.android.internal.os.InstallerConnection.InstallerException ( e.getMessage ( ) ) ; } }
Source:
public boolean select ( android.icu.text.PluralRules.FixedDecimal sample , java.lang.String keyword ) { for ( android.icu.text.PluralRules.Rule rule : rules ) { if ( ( rule.getKeyword ( ) . equals ( keyword ) ) && ( rule.appliesTo ( sample ) ) ) { return true ; } } return false ; }

Target:
public boolean select ( android.icu.text.PluralRules.IFixedDecimal sample , java.lang.String keyword ) { for ( android.icu.text.PluralRules.Rule rule : rules ) { if ( ( rule.getKeyword ( ) . equals ( keyword ) ) && ( rule.appliesTo ( sample ) ) ) { return true ; } } return false ; }
Source:
private boolean addint1D ( com.android.rs.test.RenderScript RS , com.android.rs.test.ScriptC_reduce s ) { final int [ ] input = createInputArrayInt ( 100000 , 0 , ( 1 << 13 ) ) ; final int javaRslt = addint ( input ) ; final int rsRslt = s.reduce_addint ( input ) . get ( ) ; return result ( "addint1D" , javaRslt , rsRslt ) ; }

Target:
private boolean addint1D_array ( com.android.rs.test.RenderScript RS , com.android.rs.test.ScriptC_reduce s , int seed , int [ ] size ) { final int [ ] input = createInputArrayInt ( size [ 0 ] , seed , ( ( java.lang.Integer.MAX_VALUE ) / ( size [ 0 ] ) ) ) ; final int javaRslt = addint ( input ) ; final int rsRslt = s.reduce_addint ( input ) . get ( ) ; return result ( "addint1D_array" , new com.android.rs.test.UT_reduce.timing ( size [ 0 ] ) , javaRslt , rsRslt ) ; }