auphong2707/dl4se-code-review-dataset huggingface dataset:
Source:
private java.net.URLConnection openGifURLConnection ( ) throws java.io.IOException { java.lang.String cts = java.lang.System.getProperty ( "java.io.tmpdir" ) ; java.io.File tmpDir = new java.io.File ( cts ) ; tests.support.resource.Support_Resources.copyFile ( tmpDir , null , "Harmony.GIF" ) ; java.net.URL fUrl1 = new java.net.URL ( ( ( "file:/" + ( tmpDir.getPath ( ) ) ) + "/Harmony.GIF" ) ) ; java.net.URLConnection con1 = fUrl1.openConnection ( ) ; return con1 ; }

Target:
private java.net.URLConnection openGifURLConnection ( ) throws java.io.IOException { java.lang.String cts = java.lang.System.getProperty ( "java.io.tmpdir" ) ; java.io.File tmpDir = new java.io.File ( cts ) ; tests.support.resource.Support_Resources.copyFile ( tmpDir , null , "Harmony.GIF" ) ; java.net.URL fUrl1 = new java.net.URL ( ( ( "file://" + ( tmpDir.getPath ( ) ) ) + "/Harmony.GIF" ) ) ; java.net.URLConnection con1 = fUrl1.openConnection ( ) ; return con1 ; }
Source:
public com.android.server.wifi.WifiNative.RingBufferStatus [ ] getRingBufferStatus ( ) { try { if ( ( mWifiVendorHal ) != null ) { return mWifiVendorHal.getRingBufferStatus ( ) ; } } catch ( java.lang.UnsupportedOperationException e ) { } legacyHalWarning ( ) ; synchronized ( com.android.server.wifi.WifiNative.sLock ) { if ( isHalStarted ( ) ) { return com.android.server.wifi.WifiNative.getRingBufferStatusNative ( com.android.server.wifi.WifiNative.sWlan0Index ) ; } else { return null ; } } }

Target:
public com.android.server.wifi.WifiNative.RingBufferStatus [ ] getRingBufferStatus ( ) { synchronized ( com.android.server.wifi.WifiNative.sLock ) { if ( isHalStarted ( ) ) { return com.android.server.wifi.WifiNative.getRingBufferStatusNative ( com.android.server.wifi.WifiNative.sWlan0Index ) ; } else { return null ; } } }
Source:
public com.android.ide.common.resources.ResourceRepository loadFrameworkResources ( com.android.sdklib.IAndroidTarget androidTarget ) { java.lang.String osResourcesPath = androidTarget.getPath ( IAndroidTarget.RESOURCES ) ; com.android.io.FolderWrapper frameworkRes = new com.android.io.FolderWrapper ( osResourcesPath ) ; if ( frameworkRes.exists ( ) ) { com.android.ide.common.resources.FrameworkResources resources = new com.android.ide.common.resources.FrameworkResources ( ) ; try { loadResources ( resources , frameworkRes ) ; resources.loadPublicResources ( frameworkRes , com.android.ide.eclipse.adt.AdtPlugin.getDefault ( ) ) ; return resources ; } catch ( java.io.IOException e ) { } } return null ; }

Target:
public com.android.ide.common.resources.ResourceRepository loadFrameworkResources ( com.android.sdklib.IAndroidTarget androidTarget ) { java.lang.String osResourcesPath = androidTarget.getPath ( IAndroidTarget.RESOURCES ) ; com.android.io.FolderWrapper frameworkRes = new com.android.io.FolderWrapper ( osResourcesPath ) ; if ( frameworkRes.exists ( ) ) { com.android.ide.common.resources.FrameworkResources resources = new com.android.ide.common.resources.FrameworkResources ( ) ; try { resources.loadResources ( frameworkRes ) ; resources.loadPublicResources ( frameworkRes , com.android.ide.eclipse.adt.AdtPlugin.getDefault ( ) ) ; return resources ; } catch ( java.io.IOException e ) { } } return null ; }
Source:
private void responseLceData ( android.hardware.radio.V1_0.RadioResponseInfo responseInfo , android.hardware.radio.V1_0.LceDataInfo lceInfo ) { com.android.internal.telephony.RILRequest rr = mRil.processResponse ( responseInfo ) ; if ( rr != null ) { java.util.ArrayList < java.lang.Integer > ret = null ; if ( ( responseInfo.error ) == ( android.hardware.radio.V1_0.RadioError.NONE ) ) { ret = com.android.internal.telephony.RIL.convertHalLceData ( lceInfo , mRil ) ; com.android.internal.telephony.RadioResponse.sendMessageResponse ( rr.mResult , ret ) ; } mRil.processResponseDone ( rr , responseInfo , ret ) ; } }

Target:
private void responseLceData ( android.hardware.radio.V1_0.RadioResponseInfo responseInfo , android.hardware.radio.V1_0.LceDataInfo lceInfo ) { com.android.internal.telephony.RILRequest rr = mRil.processResponse ( responseInfo ) ; if ( rr != null ) { java.util.ArrayList < java.lang.Integer > ret = com.android.internal.telephony.RIL.convertHalLceData ( lceInfo , mRil ) ; if ( ( responseInfo.error ) == ( android.hardware.radio.V1_0.RadioError.NONE ) ) { com.android.internal.telephony.RadioResponse.sendMessageResponse ( rr.mResult , ret ) ; } mRil.processResponseDone ( rr , responseInfo , ret ) ; } }
Source:
public void test_RAND_bytes_Success ( ) throws java.lang.Exception { byte [ ] output = new byte [ 128 ] ; org.apache.harmony.xnet.provider.jsse.NativeCrypto.RAND_bytes ( output ) ; boolean isZero = true ; for ( int i = 0 ; i < ( output.length ) ; i ++ ) { isZero &= ( output [ i ] ) == 0 ; } assertFalse ( ( "Random output was zero. This is a very low probability event (1 in 2^128) " + "and probably indicates an error." ) , isZero ) ; org.apache.harmony.xnet.provider.jsse.NativeCryptoTest.assertNoErrors ( ) ; }

Target:
public void test_RAND_bytes_Success ( ) throws java.lang.Exception { byte [ ] output = new byte [ 128 ] ; org.apache.harmony.xnet.provider.jsse.NativeCrypto.RAND_bytes ( output ) ; boolean isZero = true ; for ( int i = 0 ; i < ( output.length ) ; i ++ ) { isZero &= ( output [ i ] ) == 0 ; } assertFalse ( ( "Random output was zero. This is a very low probability event (1 in 2^128) " + "and probably indicates an error." ) , isZero ) ; }
Source:
static void getString ( java.lang.invoke.MethodHandle m , Main.ValueHolder v , java.lang.String value , boolean expectFailure ) throws java.lang.Throwable { boolean exceptionThrown = false ; try { final java.lang.String got = ( v == null ) ? ( ( java.lang.String ) ( m.invokeExact ( ) ) ) : ( ( java.lang.String ) ( m.invokeExact ( v ) ) ) ; Main.Tester.assertTrue ( got.equals ( value ) ) ; } catch ( java.lang.invoke.WrongMethodTypeException e ) { exceptionThrown = true ; } Main.Tester.assertEquals ( exceptionThrown , expectFailure ) ; }

Target:
static void getString ( java.lang.invoke.MethodHandle m , Main.ValueHolder v , java.lang.String value , boolean expectFailure ) throws java.lang.Throwable { boolean exceptionThrown = false ; try { final java.lang.String got = ( v == null ) ? ( ( java.lang.String ) ( m.invokeExact ( ) ) ) : ( ( java.lang.String ) ( m.invokeExact ( v ) ) ) ; Main.Tester.assertTrue ( got.equals ( value ) ) ; } catch ( java.lang.invoke.WrongMethodTypeException e ) { exceptionThrown = true ; } Main.Tester.assertEquals ( expectFailure , exceptionThrown ) ; }
Source:
public boolean generate ( java.lang.String key ) { try { return ( mBinder.generate ( key , ( - 1 ) ) ) == ( android.security.KeyStore.NO_ERROR ) ; } catch ( android.os.RemoteException e ) { android.util.Log.w ( android.security.KeyStore.TAG , "Cannot connect to keystore" , e ) ; return false ; } }

Target:
public boolean generate ( java.lang.String key , int uid ) { try { return ( mBinder.generate ( key , uid ) ) == ( android.security.KeyStore.NO_ERROR ) ; } catch ( android.os.RemoteException e ) { android.util.Log.w ( android.security.KeyStore.TAG , "Cannot connect to keystore" , e ) ; return false ; } }
Source:
public static com.android.jack.dx.rop.code.Rop opReturn ( com.android.jack.dx.rop.type.TypeBearer type ) { switch ( type.getBasicFrameType ( ) ) { case com.android.jack.dx.rop.type.Type.BT_INT : return com.android.jack.dx.rop.code.Rops.RETURN_INT ; case com.android.jack.dx.rop.type.Type.BT_CLOSURE : case com.android.jack.dx.rop.type.Type.BT_LONG : return com.android.jack.dx.rop.code.Rops.RETURN_LONG ; case com.android.jack.dx.rop.type.Type.BT_FLOAT : return com.android.jack.dx.rop.code.Rops.RETURN_FLOAT ; case com.android.jack.dx.rop.type.Type.BT_DOUBLE : return com.android.jack.dx.rop.code.Rops.RETURN_DOUBLE ; case com.android.jack.dx.rop.type.Type.BT_OBJECT : return com.android.jack.dx.rop.code.Rops.RETURN_OBJECT ; case com.android.jack.dx.rop.type.Type.BT_VOID : return com.android.jack.dx.rop.code.Rops.RETURN_VOID ; } return com.android.jack.dx.rop.code.Rops.throwBadType ( type ) ; }

Target:
public static com.android.jack.dx.rop.code.Rop opReturn ( com.android.jack.dx.rop.type.TypeBearer type ) { switch ( type.getBasicFrameType ( ) ) { case com.android.jack.dx.rop.type.Type.BT_INT : return com.android.jack.dx.rop.code.Rops.RETURN_INT ; case com.android.jack.dx.rop.type.Type.BT_LONG : return com.android.jack.dx.rop.code.Rops.RETURN_LONG ; case com.android.jack.dx.rop.type.Type.BT_FLOAT : return com.android.jack.dx.rop.code.Rops.RETURN_FLOAT ; case com.android.jack.dx.rop.type.Type.BT_DOUBLE : return com.android.jack.dx.rop.code.Rops.RETURN_DOUBLE ; case com.android.jack.dx.rop.type.Type.BT_OBJECT : return com.android.jack.dx.rop.code.Rops.RETURN_OBJECT ; case com.android.jack.dx.rop.type.Type.BT_VOID : return com.android.jack.dx.rop.code.Rops.RETURN_VOID ; } return com.android.jack.dx.rop.code.Rops.throwBadType ( type ) ; }
Source:
public static < K , V > org.hamcrest.Matcher < java.util.Map < K , V > > hasEntry ( K key , V value ) { return org.hamcrest.collection.IsMapContaining.hasEntry ( org.hamcrest.collection.IsMapContaining.equalTo ( key ) , org.hamcrest.collection.IsMapContaining.equalTo ( value ) ) ; }

Target:
public static < K , V > org.hamcrest.Matcher < java.util.Map < ? extends K , ? extends V > > hasEntry ( K key , V value ) { return new org.hamcrest.collection.IsMapContaining < K , V > ( org.hamcrest.collection.IsMapContaining.equalTo ( key ) , org.hamcrest.collection.IsMapContaining.equalTo ( value ) ) ; }
Source:
private boolean hasAllApns ( java.lang.String [ ] apnTypes ) { if ( com.android.internal.util.ArrayUtils.isEmpty ( apnTypes ) ) { return false ; } java.util.List apnList = java.util.Arrays.asList ( apnTypes ) ; if ( apnList.contains ( PhoneConstants.APN_TYPE_ALL ) ) { android.util.Log.d ( com.android.settings.ApnEditor.TAG , "hasAllApns: true because apnList.contains(PhoneConstants.APN_TYPE_ALL)" ) ; return true ; } for ( java.lang.String apn : com.android.internal.telephony.PhoneConstants.APN_TYPES ) { if ( ! ( apnList.contains ( apn ) ) ) { return false ; } } android.util.Log.d ( com.android.settings.ApnEditor.TAG , "hasAllApns: true" ) ; return true ; }

Target:
static boolean hasAllApns ( java.lang.String [ ] apnTypes ) { if ( com.android.internal.util.ArrayUtils.isEmpty ( apnTypes ) ) { return false ; } java.util.List apnList = java.util.Arrays.asList ( apnTypes ) ; if ( apnList.contains ( PhoneConstants.APN_TYPE_ALL ) ) { android.util.Log.d ( com.android.settings.ApnEditor.TAG , "hasAllApns: true because apnList.contains(PhoneConstants.APN_TYPE_ALL)" ) ; return true ; } for ( java.lang.String apn : com.android.internal.telephony.PhoneConstants.APN_TYPES ) { if ( ! ( apnList.contains ( apn ) ) ) { return false ; } } android.util.Log.d ( com.android.settings.ApnEditor.TAG , "hasAllApns: true" ) ; return true ; }
Source:
public void testFloat16Sub ( ) { setupTest ( ) ; android.renderscript.cts.ScriptC_float16_arithmetic script = new android.renderscript.cts.ScriptC_float16_arithmetic ( mRS ) ; script.set_gInput ( mInput ) ; script.forEach_sub ( mF16Matrix ) ; script.forEach_bitcast ( mF16Matrix , mU16Matrix ) ; mU16Matrix.copyTo ( output ) ; for ( int x = 0 ; x < ( numInputs ) ; x ++ ) { for ( int y = 0 ; y < ( numInputs ) ; y ++ ) { checkFloat16Sub ( x , y ) ; } } }

Target:
public void testFloat16Sub ( ) { script.set_gInput ( mInput ) ; script.forEach_sub ( mF16Matrix ) ; script.forEach_bitcast ( mF16Matrix , mU16Matrix ) ; mU16Matrix.copyTo ( output ) ; for ( int x = 0 ; x < ( numInputs ) ; x ++ ) { for ( int y = 0 ; y < ( numInputs ) ; y ++ ) { checkFloat16Sub ( x , y ) ; } } }
Source:
public void copy1DRangeFromUnchecked ( int off , int count , float [ ] d ) { int dataSize = ( mType.mElement.getBytesSize ( ) ) * count ; data1DChecks ( off , count , ( ( d.length ) * 4 ) , dataSize ) ; mRS.nAllocationData1D ( getIDSafe ( ) , off , mSelectedLOD , count , d , dataSize ) ; }

Target:
public void copy1DRangeFromUnchecked ( int off , int count , int [ ] d ) { int dataSize = ( mType.mElement.getBytesSize ( ) ) * count ; data1DChecks ( off , count , ( ( d.length ) * 4 ) , dataSize ) ; mRS.nAllocationData1D ( getIDSafe ( ) , off , mSelectedLOD , count , d , dataSize ) ; }
Source:
private static int getDefaultKeySizeForType ( int keyType ) { if ( keyType == ( com.android.org.conscrypt.NativeCrypto.EVP_PKEY_DSA ) ) { return android.security.KeyPairGeneratorSpec.DSA_DEFAULT_KEY_SIZE ; } else if ( keyType == ( com.android.org.conscrypt.NativeCrypto.EVP_PKEY_EC ) ) { return android.security.KeyPairGeneratorSpec.EC_DEFAULT_KEY_SIZE ; } else if ( keyType == ( com.android.org.conscrypt.NativeCrypto.EVP_PKEY_RSA ) ) { return android.security.KeyPairGeneratorSpec.RSA_DEFAULT_KEY_SIZE ; } throw new java.lang.IllegalArgumentException ( ( "Invalid key type " + keyType ) ) ; }

Target:
private static int getDefaultKeySizeForType ( int keyType ) { if ( keyType == ( com.android.org.conscrypt.NativeCrypto.EVP_PKEY_EC ) ) { return android.security.KeyPairGeneratorSpec.EC_DEFAULT_KEY_SIZE ; } else if ( keyType == ( com.android.org.conscrypt.NativeCrypto.EVP_PKEY_RSA ) ) { return android.security.KeyPairGeneratorSpec.RSA_DEFAULT_KEY_SIZE ; } throw new java.lang.IllegalArgumentException ( ( "Invalid key type " + keyType ) ) ; }
Source:
private static java.io.File getWrittenResources ( ) throws MergeConsumer.ConsumerException , com.android.ide.common.res2.DuplicateDataException , java.io.IOException { com.android.ide.common.res2.AssetMerger assetMerger = com.android.ide.common.res2.AssetMergerTest.getAssetMerger ( ) ; java.io.File folder = com.google.common.io.Files.createTempDir ( ) ; com.android.ide.common.res2.MergedAssetWriter writer = new com.android.ide.common.res2.MergedAssetWriter ( folder ) ; assetMerger.mergeData ( writer ) ; return folder ; }

Target:
private static java.io.File getWrittenResources ( ) throws MergeConsumer.ConsumerException , com.android.ide.common.res2.DuplicateDataException , java.io.IOException { com.android.ide.common.res2.AssetMerger assetMerger = com.android.ide.common.res2.AssetMergerTest.getAssetMerger ( ) ; java.io.File folder = com.google.common.io.Files.createTempDir ( ) ; com.android.ide.common.res2.MergedAssetWriter writer = new com.android.ide.common.res2.MergedAssetWriter ( folder ) ; assetMerger.mergeData ( writer , false ) ; return folder ; }
Source:
private void parseProfileButtons ( com.android.cts.verifier.audio.peripheralprofile.ProfileButtonAttributes buttonAttributes , java.lang.String elementName , org.xml.sax.Attributes xmlAtts ) { buttonAttributes.mHasBtnA = ( java.lang.Integer.parseInt ( xmlAtts.getValue ( com.android.cts.verifier.audio.peripheralprofile.PeripheralProfile.kAttr_HasBtnA ) ) ) == 1 ; buttonAttributes.mHasBtnB = ( java.lang.Integer.parseInt ( xmlAtts.getValue ( com.android.cts.verifier.audio.peripheralprofile.PeripheralProfile.kAttr_HasBtnB ) ) ) == 1 ; buttonAttributes.mHasBtnC = ( java.lang.Integer.parseInt ( xmlAtts.getValue ( com.android.cts.verifier.audio.peripheralprofile.PeripheralProfile.kAttr_HasBtnC ) ) ) == 1 ; buttonAttributes.mHasBtnD = ( java.lang.Integer.parseInt ( xmlAtts.getValue ( com.android.cts.verifier.audio.peripheralprofile.PeripheralProfile.kAttr_HasBtnD ) ) ) == 1 ; }

Target:
private void parseProfileButtons ( com.android.cts.verifier.audio.peripheralprofile.ProfileButtonAttributes buttonAttributes , java.lang.String elementName , org.xml.sax.Attributes xmlAtts ) { buttonAttributes.mHasBtnA = ( java.lang.Integer.parseInt ( xmlAtts.getValue ( com.android.cts.verifier.audio.peripheralprofile.PeripheralProfile.kAttr_HasBtnA ) ) ) == 1 ; buttonAttributes.mHasBtnB = ( java.lang.Integer.parseInt ( xmlAtts.getValue ( com.android.cts.verifier.audio.peripheralprofile.PeripheralProfile.kAttr_HasBtnB ) ) ) == 1 ; buttonAttributes.mHasBtnC = ( java.lang.Integer.parseInt ( xmlAtts.getValue ( com.android.cts.verifier.audio.peripheralprofile.PeripheralProfile.kAttr_HasBtnC ) ) ) == 1 ; }
Source:
public void setWifiLinkLayerStats ( java.lang.String iface , int enable ) { if ( com.android.server.wifi.WifiNative.HIDL_VENDOR_ENABLE ) { } else { if ( iface == null ) return ; synchronized ( com.android.server.wifi.WifiNative.sLock ) { if ( isHalStarted ( ) ) { com.android.server.wifi.WifiNative.setWifiLinkLayerStatsNative ( com.android.server.wifi.WifiNative.sWlan0Index , enable ) ; } } } }

Target:
public void setWifiLinkLayerStats ( java.lang.String iface , int enable ) { }
Source:
final android.content.res.XmlBlock openXmlBlockAsset ( int cookie , java.lang.String fileName ) throws java.io.IOException { synchronized ( this ) { if ( ! ( mOpen ) ) { throw new java.lang.RuntimeException ( "Assetmanager has been closed" ) ; } int xmlBlock = openXmlAssetNative ( cookie , fileName ) ; if ( xmlBlock != 0 ) { android.content.res.XmlBlock res = new android.content.res.XmlBlock ( this , xmlBlock ) ; incRefsLocked ( res.hashCode ( ) ) ; return res ; } } throw new java.io.FileNotFoundException ( ( "Asset XML file: " + fileName ) ) ; }

Target:
final android.content.res.XmlBlock openXmlBlockAsset ( int cookie , java.lang.String fileName ) throws java.io.IOException { synchronized ( this ) { if ( ! ( mOpen ) ) { throw new java.lang.RuntimeException ( "Assetmanager has been closed" ) ; } long xmlBlock = openXmlAssetNative ( cookie , fileName ) ; if ( xmlBlock != 0 ) { android.content.res.XmlBlock res = new android.content.res.XmlBlock ( this , xmlBlock ) ; incRefsLocked ( res.hashCode ( ) ) ; return res ; } } throw new java.io.FileNotFoundException ( ( "Asset XML file: " + fileName ) ) ; }
Source:
public synchronized void tearDown ( com.android.tradefed.invoker.IInvocationContext context , java.lang.Throwable e ) throws com.android.tradefed.device.DeviceNotAvailableException { -- ( mNumOfInstances ) ; if ( ( mNumOfInstances ) > 0 ) { return ; } if ( ( ( mVenvDir ) != null ) && ( mIsDirCreator ) ) { try { com.android.tradefed.targetprep.VtsPythonVirtualenvPreparer.recursiveDelete ( mVenvDir.toPath ( ) ) ; com.android.tradefed.log.LogUtil.CLog.i ( "Deleted the virtual env's temp working dir, %s." , mVenvDir ) ; } catch ( java.io.IOException exception ) { com.android.tradefed.log.LogUtil.CLog.e ( "Failed to delete %s: %s" , mVenvDir , exception ) ; } mVenvDir = null ; } }

Target:
public synchronized void tearDown ( com.android.tradefed.invoker.IInvocationContext context , java.lang.Throwable e ) throws com.android.tradefed.device.DeviceNotAvailableException { -- ( mNumOfInstances ) ; if ( ( mNumOfInstances ) > 0 ) { return ; } if ( ( ( mVenvDir ) != null ) && ( mIsDirCreator ) ) { try { com.android.tradefed.targetprep.VtsPythonVirtualenvPreparer.recursiveDelete ( mVenvDir.toPath ( ) ) ; com.android.tradefed.log.LogUtil.CLog.d ( "Deleted the virtual env's temp working dir, %s." , mVenvDir ) ; } catch ( java.io.IOException exception ) { com.android.tradefed.log.LogUtil.CLog.e ( "Failed to delete %s: %s" , mVenvDir , exception ) ; } mVenvDir = null ; } }
Source:
public void setWifiLinkLayerStats ( java.lang.String iface , int enable ) { try { if ( ( mWifiVendorHal ) != null ) { mWifiVendorHal.setWifiLinkLayerStats ( iface , enable ) ; return ; } } catch ( java.lang.UnsupportedOperationException e ) { } legacyHalWarning ( ) ; if ( iface == null ) return ; synchronized ( com.android.server.wifi.WifiNative.sLock ) { if ( isHalStarted ( ) ) { com.android.server.wifi.WifiNative.setWifiLinkLayerStatsNative ( com.android.server.wifi.WifiNative.sWlan0Index , enable ) ; } } }

Target:
public void setWifiLinkLayerStats ( java.lang.String iface , int enable ) { if ( iface == null ) return ; synchronized ( com.android.server.wifi.WifiNative.sLock ) { if ( isHalStarted ( ) ) { com.android.server.wifi.WifiNative.setWifiLinkLayerStatsNative ( com.android.server.wifi.WifiNative.sWlan0Index , enable ) ; } } }
Source:
public void test_useDelimiter_String ( ) { s = new java.util.Scanner ( "test" ) ; try { s.useDelimiter ( ( ( java.lang.String ) ( null ) ) ) ; fail ( "Should throw NullPointerException" ) ; } catch ( java.lang.NullPointerException e ) { } s = new java.util.Scanner ( "test" ) ; s.useDelimiter ( "\\w+" ) ; assertEquals ( "\\w+" , s.delimiter ( ) . toString ( ) ) ; }

Target:
public void test_useDelimiter_String ( ) { s = new java.util.Scanner ( "test" ) ; try { s.useDelimiter ( ( ( java.lang.String ) ( null ) ) ) ; fail ( ) ; } catch ( java.lang.NullPointerException expected ) { } s = new java.util.Scanner ( "test" ) ; s.useDelimiter ( "\\w+" ) ; assertEquals ( "\\w+" , s.delimiter ( ) . toString ( ) ) ; }
Source:
public boolean hasNextLong ( int radix ) { java.util.regex.Pattern integerPattern = getIntegerPattern ( radix ) ; boolean isLongValue = false ; if ( hasNext ( integerPattern ) ) { java.lang.String intString = matcher.group ( ) ; intString = removeLocaleInfo ( intString , java.util.Scanner.DataType.INT ) ; try { cachedNextValue = java.lang.Long.valueOf ( intString , radix ) ; isLongValue = true ; } catch ( java.lang.NumberFormatException e ) { matchSuccessful = false ; } } return isLongValue ; }

Target:
public boolean hasNextLong ( int radix ) { java.util.regex.Pattern integerPattern = getIntegerPattern ( radix ) ; boolean isLongValue = false ; if ( hasNext ( integerPattern ) ) { java.lang.String intString = matcher.group ( ) ; intString = removeLocaleInfo ( intString , int . class ) ; try { cachedNextValue = java.lang.Long.valueOf ( intString , radix ) ; isLongValue = true ; } catch ( java.lang.NumberFormatException e ) { matchSuccessful = false ; } } return isLongValue ; }
Source:
private void putAllImpl ( java.util.Map map ) { java.util.Iterator iter = map.entrySet ( ) . iterator ( ) ; while ( iter.hasNext ( ) ) { java.util.Map.Entry entry = ( ( java.util.Map.Entry ) ( iter.next ( ) ) ) ; putImpl ( ( ( K ) ( entry.getKey ( ) ) ) , ( ( V ) ( entry.getValue ( ) ) ) ) ; } }

Target:
private void putAllImpl ( java.util.Map < ? extends K , ? extends V > map ) { for ( java.util.Map.Entry < ? extends K , ? extends V > entry : map.entrySet ( ) ) { putImpl ( entry.getKey ( ) , entry.getValue ( ) ) ; } }
Source:
private com.android.build.gradle.internal.test.report.PackageTestResults addPackage ( java.lang.String packageName , java.lang.String device , java.lang.String project , java.lang.String flavor ) { java.lang.String key = ( ( ( ( ( device + "/" ) + project ) + "/" ) + flavor ) + "/" ) + packageName ; com.android.build.gradle.internal.test.report.PackageTestResults packageResults = packages.get ( key ) ; if ( packageResults == null ) { packageResults = new com.android.build.gradle.internal.test.report.PackageTestResults ( packageName , this , device , project , flavor ) ; packages.put ( key , packageResults ) ; } return packageResults ; }

Target:
private com.android.build.gradle.internal.test.report.PackageTestResults addPackage ( java.lang.String packageName ) { com.android.build.gradle.internal.test.report.PackageTestResults packageResults = packages.get ( packageName ) ; if ( packageResults == null ) { packageResults = new com.android.build.gradle.internal.test.report.PackageTestResults ( packageName , this ) ; packages.put ( packageName , packageResults ) ; } return packageResults ; }
Source:
void registerClient ( java.util.UUID uuid , android.bluetooth.IBluetoothGattCallback callback ) { enforceCallingOrSelfPermission ( com.android.bluetooth.gatt.BLUETOOTH_PERM , "Need BLUETOOTH permission" ) ; if ( com.android.bluetooth.gatt.GattService.DBG ) android.util.Log.d ( com.android.bluetooth.gatt.GattService.TAG , ( "registerClient() - UUID=" + uuid ) ) ; mClientMap.add ( uuid , callback ) ; gattClientRegisterAppNative ( uuid.getLeastSignificantBits ( ) , uuid.getMostSignificantBits ( ) ) ; }

Target:
void registerClient ( java.util.UUID uuid , android.bluetooth.IBluetoothGattCallback callback ) { enforceCallingOrSelfPermission ( com.android.bluetooth.gatt.BLUETOOTH_PERM , "Need BLUETOOTH permission" ) ; if ( com.android.bluetooth.gatt.GattService.DBG ) android.util.Log.d ( com.android.bluetooth.gatt.GattService.TAG , ( "registerClient() - UUID=" + uuid ) ) ; mClientMap.add ( uuid , callback , this ) ; gattClientRegisterAppNative ( uuid.getLeastSignificantBits ( ) , uuid.getMostSignificantBits ( ) ) ; }
Source:
public void testNewConstructors_Success ( ) throws java.lang.Exception { java.security.SecureRandom sr1 = new java.security.SecureRandom ( ) ; assertEquals ( libcore.java.security.SecureRandomTest.EXPECTED_PROVIDER , sr1.getProvider ( ) . getClass ( ) . getName ( ) ) ; test_SecureRandom ( sr1 ) ; java.security.SecureRandom sr2 = new java.security.SecureRandom ( libcore.java.security.SecureRandomTest.STATIC_SEED_BYTES ) ; assertEquals ( libcore.java.security.SecureRandomTest.EXPECTED_PROVIDER , sr2.getProvider ( ) . getClass ( ) . getName ( ) ) ; test_SecureRandom ( sr2 ) ; }

Target:
public void testNewConstructors_Success ( ) throws java.lang.Exception { java.security.SecureRandom sr1 = new java.security.SecureRandom ( ) ; assertNotNull ( sr1 ) ; assertNotNull ( sr1.getProvider ( ) ) ; assertEquals ( libcore.java.security.SecureRandomTest.EXPECTED_PROVIDER , sr1.getProvider ( ) . getClass ( ) . getName ( ) ) ; test_SecureRandom ( sr1 ) ; java.security.SecureRandom sr2 = new java.security.SecureRandom ( libcore.java.security.SecureRandomTest.STATIC_SEED_BYTES ) ; assertEquals ( libcore.java.security.SecureRandomTest.EXPECTED_PROVIDER , sr2.getProvider ( ) . getClass ( ) . getName ( ) ) ; test_SecureRandom ( sr2 ) ; }
Source:
private static java.lang.String normalizeInterfaceMethodName ( java.lang.String name , boolean isLambda , boolean isStatic ) { java.lang.String suffix ; if ( isLambda ) { suffix = DependencyCollector.INTERFACE_COMPANION_SUFFIX ; } else if ( isStatic ) { suffix = com.google.devtools.build.android.desugar.InterfaceDesugaring.INTERFACE_STATIC_COMPANION_METHOD_SUFFIX ; } else { return name ; } return name + suffix ; }

Target:
private static java.lang.String normalizeInterfaceMethodName ( java.lang.String name , boolean isLambda , boolean isStatic ) { if ( isLambda ) { return name + ( DependencyCollector.INTERFACE_COMPANION_SUFFIX ) ; } else if ( isStatic ) { return name + ( com.google.devtools.build.android.desugar.InterfaceDesugaring.INTERFACE_STATIC_COMPANION_METHOD_SUFFIX ) ; } else { return name ; } }
Source:
public E next ( ) { if ( ( cursor ) == ( fence ) ) throw new java.util.NoSuchElementException ( ) ; E result = elements [ cursor ] ; if ( ( ( tail ) != ( fence ) ) || ( result == null ) ) throw new java.util.ConcurrentModificationException ( ) ; lastRet = cursor ; cursor = ( ( cursor ) + 1 ) & ( ( elements.length ) - 1 ) ; return result ; }

Target:
public E next ( ) { if ( ( cursor ) == ( fence ) ) throw new java.util.NoSuchElementException ( ) ; @ java.lang.SuppressWarnings ( value = "unchecked" ) E result = ( ( E ) ( elements [ cursor ] ) ) ; if ( ( ( tail ) != ( fence ) ) || ( result == null ) ) throw new java.util.ConcurrentModificationException ( ) ; lastRet = cursor ; cursor = ( ( cursor ) + 1 ) & ( ( elements.length ) - 1 ) ; return result ; }
Source:
public int getProfileConnectionState ( int profile ) { if ( ! ( com.android.bluetooth.Utils.checkCallerAllowManagedProfiles ( mService ) ) ) { android.util.Log.w ( com.android.bluetooth.btservice.AdapterService.TAG , "getProfileConnectionState- Not allowed for non-active user" ) ; return android.bluetooth.BluetoothProfile.STATE_DISCONNECTED ; } com.android.bluetooth.btservice.AdapterService service = getService ( ) ; if ( service == null ) return android.bluetooth.BluetoothProfile.STATE_DISCONNECTED ; return service.getProfileConnectionState ( profile ) ; }

Target:
public int getProfileConnectionState ( int profile ) { if ( ! ( com.android.bluetooth.Utils.checkCallerAllowManagedProfiles ( mService ) ) ) { android.util.Log.w ( com.android.bluetooth.btservice.AdapterService.TAG , "getProfileConnectionState- Not allowed for non-active user" ) ; return android.bluetooth.BluetoothProfile.STATE_DISCONNECTED ; } com.android.bluetooth.btservice.AdapterService service = getService ( ) ; if ( service == null ) { return android.bluetooth.BluetoothProfile.STATE_DISCONNECTED ; } return service.getProfileConnectionState ( profile ) ; }
Source:
public boolean isRingingForSubscriber ( int subId , java.lang.String callingPackage ) { if ( ! ( com.android.internal.telephony.TelephonyPermissions.checkCallingOrSelfReadPhoneState ( mApp , callingPackage , "isRingingForSubscriber" ) ) ) { return false ; } final com.android.internal.telephony.Phone phone = getPhone ( subId ) ; if ( phone != null ) { return ( phone.getState ( ) ) == ( PhoneConstants.State.RINGING ) ; } else { return false ; } }

Target:
public boolean isRingingForSubscriber ( int subId , java.lang.String callingPackage ) { if ( ! ( com.android.internal.telephony.TelephonyPermissions.checkCallingOrSelfReadPhoneState ( mApp , subId , callingPackage , "isRingingForSubscriber" ) ) ) { return false ; } final com.android.internal.telephony.Phone phone = getPhone ( subId ) ; if ( phone != null ) { return ( phone.getState ( ) ) == ( PhoneConstants.State.RINGING ) ; } else { return false ; } }
Source:
public void runTest ( ) { mConvolve.setInput ( mInPixelsAllocation ) ; if ( mUseNative ) { mGroup.setOutput ( mMatrix.getKernelID ( ) , mOutPixelsAllocation ) ; mGroup.execute ( ) ; } else { mConvolve.forEach ( mScratchPixelsAllocation1 ) ; mMatrix.forEach ( mScratchPixelsAllocation1 , mOutPixelsAllocation ) ; } }

Target:
public void runTest ( ) { mConvolve.setInput ( mInPixelsAllocation ) ; if ( mUseNative ) { mOutPixelsAllocation = ( ( android.renderscript.Allocation ) ( mGroup.execute ( mInPixelsAllocation ) [ 0 ] ) ) ; } else { mConvolve.forEach ( mScratchPixelsAllocation1 ) ; mMatrix.forEach ( mScratchPixelsAllocation1 , mOutPixelsAllocation ) ; } }
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 { org.apache.harmony.xnet.provider.jsse.NativeCryptoTest.assertEqualSessions ( clientSession [ 0 ] , session ) ; super . afterHandshake ( org.apache.harmony.xnet.provider.jsse.NativeCryptoTest.NULL , s , org.apache.harmony.xnet.provider.jsse.NativeCryptoTest.NULL , sock , fd , callback ) ; }

Target:
public void afterHandshake ( long session , long s , long c , java.net.Socket sock , java.io.FileDescriptor fd , org.apache.harmony.xnet.provider.jsse.NativeCrypto.SSLHandshakeCallbacks callback ) throws java.lang.Exception { org.apache.harmony.xnet.provider.jsse.NativeCryptoTest.assertEqualSessions ( clientSession [ 0 ] , session ) ; super . afterHandshake ( org.apache.harmony.xnet.provider.jsse.NativeCryptoTest.NULL , s , org.apache.harmony.xnet.provider.jsse.NativeCryptoTest.NULL , sock , fd , callback ) ; }
Source:
private static com.android.sched.scheduler.TagOrMarkerOrComponentSet getJackFormatInitialTagSet ( ) { com.android.sched.scheduler.Scheduler scheduler = com.android.sched.scheduler.Scheduler.getScheduler ( ) ; com.android.sched.scheduler.TagOrMarkerOrComponentSet set = scheduler.createTagOrMarkerOrComponentSet ( ) ; set.add ( com.android.jack.ir.JackFormatIr.class ) ; set.add ( com.android.jack.shrob.obfuscation.OriginalNames.class ) ; set.add ( com.android.jack.ir.sourceinfo.SourceInfoCreation.class ) ; return set ; }

Target:
public static com.android.sched.scheduler.TagOrMarkerOrComponentSet getJackFormatInitialTagSet ( @ javax.annotation.Nonnull com.android.sched.scheduler.Scheduler scheduler ) { com.android.sched.scheduler.TagOrMarkerOrComponentSet set = scheduler.createTagOrMarkerOrComponentSet ( ) ; set.add ( com.android.jack.ir.JackFormatIr.class ) ; set.add ( com.android.jack.shrob.obfuscation.OriginalNames.class ) ; set.add ( com.android.jack.ir.sourceinfo.SourceInfoCreation.class ) ; return set ; }
Source:
public void shutdown ( ) { if ( ( mStopped ) == false ) { mStopped = true ; try { mServerSocket.close ( ) ; } catch ( java.io.IOException e ) { if ( com.android.bluetooth.ObexServerSockets.D ) android.util.Log.d ( TAG , "Exception while thread shutdown:" , e ) ; } } if ( ! ( java.lang.Thread.currentThread ( ) . equals ( this ) ) ) { if ( com.android.bluetooth.ObexServerSockets.D ) android.util.Log.d ( TAG , "shutdown called from another thread - interrupt()." ) ; interrupt ( ) ; } }

Target:
public void shutdown ( ) { if ( ! ( mStopped ) ) { mStopped = true ; try { mServerSocket.close ( ) ; } catch ( java.io.IOException e ) { if ( com.android.bluetooth.ObexServerSockets.D ) android.util.Log.d ( TAG , "Exception while thread shutdown:" , e ) ; } } if ( ! ( java.lang.Thread.currentThread ( ) . equals ( this ) ) ) { if ( com.android.bluetooth.ObexServerSockets.D ) android.util.Log.d ( TAG , "shutdown called from another thread - interrupt()." ) ; interrupt ( ) ; } }
Source:
public boolean setRemoteAlias ( android.bluetooth.BluetoothDevice device , java.lang.String name ) { if ( ! ( com.android.bluetooth.Utils.checkCaller ( ) ) ) { android.util.Log.w ( com.android.bluetooth.btservice.AdapterService.TAG , "setRemoteAlias() - Not allowed for non-active user" ) ; return false ; } com.android.bluetooth.btservice.AdapterService service = getService ( ) ; if ( service == null ) return false ; return service.setRemoteAlias ( device , name ) ; }

Target:
public boolean setRemoteAlias ( android.bluetooth.BluetoothDevice device , java.lang.String name ) { if ( ! ( com.android.bluetooth.Utils.checkCaller ( ) ) ) { android.util.Log.w ( com.android.bluetooth.btservice.AdapterService.TAG , "setRemoteAlias() - Not allowed for non-active user" ) ; return false ; } com.android.bluetooth.btservice.AdapterService service = getService ( ) ; if ( service == null ) { return false ; } return service.setRemoteAlias ( device , name ) ; }
Source:
public void test_EVP_SignInit ( ) throws java.lang.Exception { final int ctx = org.apache.harmony.xnet.provider.jsse.NativeCrypto.EVP_SignInit ( "RSA-SHA256" ) ; assertTrue ( ( ctx != ( org.apache.harmony.xnet.provider.jsse.NativeCryptoTest.NULL ) ) ) ; org.apache.harmony.xnet.provider.jsse.NativeCrypto.EVP_MD_CTX_destroy ( ctx ) ; try { org.apache.harmony.xnet.provider.jsse.NativeCrypto.EVP_SignInit ( "foobar" ) ; fail ( ) ; } catch ( java.lang.RuntimeException expected ) { } }

Target:
public void test_EVP_SignInit ( ) throws java.lang.Exception { final long ctx = org.apache.harmony.xnet.provider.jsse.NativeCrypto.EVP_SignInit ( "RSA-SHA256" ) ; assertTrue ( ( ctx != ( org.apache.harmony.xnet.provider.jsse.NativeCryptoTest.NULL ) ) ) ; org.apache.harmony.xnet.provider.jsse.NativeCrypto.EVP_MD_CTX_destroy ( ctx ) ; try { org.apache.harmony.xnet.provider.jsse.NativeCrypto.EVP_SignInit ( "foobar" ) ; fail ( ) ; } catch ( java.lang.RuntimeException expected ) { } }
Source:
static byte [ ] toBytes ( java.lang.Object object ) { java.io.ByteArrayOutputStream baos = new java.io.ByteArrayOutputStream ( ) ; try { java.io.ObjectOutputStream os = new java.io.ObjectOutputStream ( baos ) ; os.writeObject ( object ) ; os.close ( ) ; } catch ( java.lang.Exception e ) { android.util.Log.w ( com.android.certinstaller.Util.TAG , ( ( ( "toBytes(): " + e ) + ": " ) + object ) ) ; } finally { return baos.toByteArray ( ) ; } }

Target:
static byte [ ] toBytes ( java.lang.Object object ) { java.io.ByteArrayOutputStream baos = new java.io.ByteArrayOutputStream ( ) ; try { java.io.ObjectOutputStream os = new java.io.ObjectOutputStream ( baos ) ; os.writeObject ( object ) ; os.close ( ) ; } catch ( java.lang.Exception e ) { android.util.Log.w ( com.android.certinstaller.Util.TAG , ( ( ( "toBytes(): " + e ) + ": " ) + object ) ) ; } return baos.toByteArray ( ) ; }
Source:
private void generateTestManifest ( java.lang.String testPackageName , int minSdkVersion , int targetSdkVersion , java.lang.String testedPackageName , java.lang.String instrumentationRunner , java.lang.Boolean handleProfiling , java.lang.Boolean functionalTest , java.lang.String outManifestLocation ) { com.android.builder.internal.TestManifestGenerator generator = new com.android.builder.internal.TestManifestGenerator ( outManifestLocation , testPackageName , minSdkVersion , targetSdkVersion , testedPackageName , instrumentationRunner , handleProfiling , functionalTest ) ; try { generator.generate ( ) ; } catch ( java.io.IOException e ) { throw new java.lang.RuntimeException ( e ) ; } }

Target:
private static void generateTestManifest ( java.lang.String testPackageName , java.lang.String minSdkVersion , int targetSdkVersion , java.lang.String testedPackageName , java.lang.String instrumentationRunner , java.lang.Boolean handleProfiling , java.lang.Boolean functionalTest , java.lang.String outManifestLocation ) { com.android.builder.internal.TestManifestGenerator generator = new com.android.builder.internal.TestManifestGenerator ( outManifestLocation , testPackageName , minSdkVersion , targetSdkVersion , testedPackageName , instrumentationRunner , handleProfiling , functionalTest ) ; try { generator.generate ( ) ; } catch ( java.io.IOException e ) { throw new java.lang.RuntimeException ( e ) ; } }
Source:
public boolean canThrow ( ) { return ( ( ( ( getType ( ) . isSameType ( JPrimitiveTypeEnum.BYTE.getType ( ) ) ) || ( getType ( ) . isSameType ( JPrimitiveTypeEnum.CHAR.getType ( ) ) ) ) || ( getType ( ) . isSameType ( JPrimitiveTypeEnum.SHORT.getType ( ) ) ) ) || ( getType ( ) . isSameType ( JPrimitiveTypeEnum.INT.getType ( ) ) ) ) || ( getType ( ) . isSameType ( JPrimitiveTypeEnum.LONG.getType ( ) ) ) ; }

Target:
public boolean canThrow ( ) { return ( ( ( ( ( getType ( ) ) == ( JPrimitiveTypeEnum.BYTE.getType ( ) ) ) || ( ( getType ( ) ) == ( JPrimitiveTypeEnum.CHAR.getType ( ) ) ) ) || ( ( getType ( ) ) == ( JPrimitiveTypeEnum.SHORT.getType ( ) ) ) ) || ( ( getType ( ) ) == ( JPrimitiveTypeEnum.INT.getType ( ) ) ) ) || ( ( getType ( ) ) == ( JPrimitiveTypeEnum.LONG.getType ( ) ) ) ; }
Source:
private static java.util.ResourceBundle.Control getDefaultControl ( java.lang.String baseName ) { if ( ( java.util.ResourceBundle.providers ) != null ) { for ( java.util.spi.ResourceBundleControlProvider provider : java.util.ResourceBundle.providers ) { java.util.ResourceBundle.Control control = provider.getControl ( baseName ) ; if ( control != null ) { return control ; } } } return java.util.ResourceBundle.Control.INSTANCE ; }

Target:
private static java.util.ResourceBundle.Control getDefaultControl ( java.lang.String baseName ) { return java.util.ResourceBundle.Control.INSTANCE ; }
Source:
public void run ( ) { com.android.rs.test_compat.RenderScript pRS = com.android.rs.test_compat.RenderScript.create ( mCtx ) ; com.android.rs.test_compat.ScriptC_bug_char s = new com.android.rs.test_compat.ScriptC_bug_char ( pRS , mRes , R.raw.bug_char ) ; pRS.setMessageHandler ( mRsMessage ) ; initializeValues ( s ) ; s.invoke_bug_char_test ( ) ; pRS.finish ( ) ; waitForMessage ( ) ; pRS.destroy ( ) ; }

Target:
public void run ( ) { com.android.rs.test_compat.RenderScript pRS = com.android.rs.test_compat.RenderScript.create ( mCtx ) ; com.android.rs.test_compat.ScriptC_bug_char s = new com.android.rs.test_compat.ScriptC_bug_char ( pRS ) ; pRS.setMessageHandler ( mRsMessage ) ; initializeValues ( s ) ; s.invoke_bug_char_test ( ) ; pRS.finish ( ) ; waitForMessage ( ) ; pRS.destroy ( ) ; }
Source:
void onAdvertiserStarted ( int status , int advertiserId ) throws android.os.RemoteException { if ( com.android.bluetooth.gatt.GattService.DBG ) android.util.Log.d ( com.android.bluetooth.gatt.GattService.TAG , ( ( ( "onAdvertiserStarted() - advertiserId=" + advertiserId ) + ", status=" ) + status ) ) ; mAdvertiseManager.callbackDone ( advertiserId , status ) ; com.android.bluetooth.gatt.AdvertiserMap.App app = mAdvertiserMap.getById ( advertiserId ) ; if ( app != null ) { if ( status == 0 ) { app.callback.onMultiAdvertiseCallback ( AdvertiseCallback.ADVERTISE_SUCCESS , true , null ) ; } else { app.callback.onMultiAdvertiseCallback ( AdvertiseCallback.ADVERTISE_FAILED_INTERNAL_ERROR , true , null ) ; } } }

Target:
void onAdvertiserStarted ( int status , int advertiserId ) throws android.os.RemoteException { if ( com.android.bluetooth.gatt.GattService.DBG ) android.util.Log.d ( com.android.bluetooth.gatt.GattService.TAG , ( ( ( "onAdvertiserStarted() - advertiserId=" + advertiserId ) + ", status=" ) + status ) ) ; com.android.bluetooth.gatt.AdvertiserMap.App app = mAdvertiserMap.getById ( advertiserId ) ; if ( app != null ) { if ( status == 0 ) { app.callback.onMultiAdvertiseCallback ( AdvertiseCallback.ADVERTISE_SUCCESS , true , null ) ; } else { app.callback.onMultiAdvertiseCallback ( AdvertiseCallback.ADVERTISE_FAILED_INTERNAL_ERROR , true , null ) ; } } }
Source:
public void test_removeHandshakeCompletedListener ( ) throws java.io.IOException { javax.net.ssl.SSLSocket ssl = getSSLSocket ( ) ; javax.net.ssl.HandshakeCompletedListener ls = new org.apache.harmony.tests.javax.net.ssl.SSLSocketTest.HandshakeCL ( ) ; try { ssl.removeHandshakeCompletedListener ( null ) ; fail ( ) ; } catch ( java.lang.IllegalArgumentException expected ) { } try { ssl.removeHandshakeCompletedListener ( ls ) ; } catch ( java.lang.IllegalArgumentException expected ) { } ssl.addHandshakeCompletedListener ( ls ) ; ssl.removeHandshakeCompletedListener ( ls ) ; ssl.close ( ) ; }

Target:
public void test_removeHandshakeCompletedListener ( ) throws java.io.IOException { javax.net.ssl.SSLSocket ssl = getSSLSocket ( ) ; javax.net.ssl.HandshakeCompletedListener ls = new org.apache.harmony.tests.javax.net.ssl.SSLSocketTest.HandshakeCL ( ) ; try { ssl.removeHandshakeCompletedListener ( null ) ; fail ( ) ; } catch ( java.lang.IllegalArgumentException expected ) { } try { ssl.removeHandshakeCompletedListener ( ls ) ; fail ( ) ; } catch ( java.lang.IllegalArgumentException expected ) { } ssl.addHandshakeCompletedListener ( ls ) ; ssl.removeHandshakeCompletedListener ( ls ) ; ssl.close ( ) ; }
Source:
public void onPageFinished ( android.webkit.WebView view , java.lang.String url ) { if ( ! ( mInPageLoad ) ) { return ; } if ( ! ( isPrivateBrowsingEnabled ( ) ) ) { com.android.browser.LogTag.logPageFinishedLoading ( url , ( ( android.os.SystemClock.uptimeMillis ( ) ) - ( mLoadStartTime ) ) ) ; } syncCurrentState ( view , url ) ; mWebViewController.onPageFinished ( this ) ; }

Target:
public void onPageFinished ( android.webkit.WebView view , java.lang.String url ) { if ( ! ( isPrivateBrowsingEnabled ( ) ) ) { com.android.browser.LogTag.logPageFinishedLoading ( url , ( ( android.os.SystemClock.uptimeMillis ( ) ) - ( mLoadStartTime ) ) ) ; } syncCurrentState ( view , url ) ; mWebViewController.onPageFinished ( this ) ; }
Source:
public int getProfileConnectionState ( com.android.settingslib.bluetooth.LocalBluetoothProfile profile ) { if ( ( ( mProfileConnectionState ) == null ) || ( ( mProfileConnectionState.get ( profile ) ) == null ) ) { int state = profile.getConnectionStatus ( mDevice ) ; mProfileConnectionState.put ( profile , state ) ; } return mProfileConnectionState.get ( profile ) ; }

Target:
public int getProfileConnectionState ( com.android.settingslib.bluetooth.LocalBluetoothProfile profile ) { if ( ( mProfileConnectionState.get ( profile ) ) == null ) { int state = profile.getConnectionStatus ( mDevice ) ; mProfileConnectionState.put ( profile , state ) ; } return mProfileConnectionState.get ( profile ) ; }
Source:
com.android.ide.eclipse.adt.internal.editors.layout.ProjectCallback getProjectCallback ( boolean reset , com.android.ide.common.rendering.LayoutLibrary layoutLibrary ) { if ( ( mProjectCallback ) == null ) { com.android.ide.eclipse.adt.internal.resources.manager.ResourceManager resManager = com.android.ide.eclipse.adt.internal.resources.manager.ResourceManager.getInstance ( ) ; org.eclipse.core.resources.IProject project = getProject ( ) ; com.android.ide.eclipse.adt.internal.resources.manager.ProjectResources projectRes = resManager.getProjectResources ( project ) ; mProjectCallback = new com.android.ide.eclipse.adt.internal.editors.layout.ProjectCallback ( layoutLibrary , projectRes , project , mCredential ) ; } else if ( reset ) { mProjectCallback.getMissingClasses ( ) . clear ( ) ; mProjectCallback.getUninstantiatableClasses ( ) . clear ( ) ; } return mProjectCallback ; }

Target:
com.android.ide.eclipse.adt.internal.editors.layout.ProjectCallback getProjectCallback ( boolean reset , com.android.ide.common.rendering.LayoutLibrary layoutLibrary ) { if ( ( mProjectCallback ) == null ) { com.android.ide.eclipse.adt.internal.resources.manager.ResourceManager resManager = com.android.ide.eclipse.adt.internal.resources.manager.ResourceManager.getInstance ( ) ; org.eclipse.core.resources.IProject project = getProject ( ) ; com.android.ide.eclipse.adt.internal.resources.manager.ProjectResources projectRes = resManager.getProjectResources ( project ) ; mProjectCallback = new com.android.ide.eclipse.adt.internal.editors.layout.ProjectCallback ( layoutLibrary , projectRes , project , mCredential , this ) ; } else if ( reset ) { mProjectCallback.getMissingClasses ( ) . clear ( ) ; mProjectCallback.getUninstantiatableClasses ( ) . clear ( ) ; } return mProjectCallback ; }
Source:
public void run ( ) { android.renderscript.RenderScript pRS = android.renderscript.RenderScript.create ( mCtx ) ; com.android.rs.test.ScriptC_copy_test s = new com.android.rs.test.ScriptC_copy_test ( pRS ) ; pRS.setMessageHandler ( mRsMessage ) ; testFloat2 ( pRS , s ) ; testFloat3 ( pRS , s ) ; testFloat4 ( pRS , s ) ; s.invoke_sendResult ( true ) ; pRS.finish ( ) ; waitForMessage ( ) ; pRS.destroy ( ) ; }

Target:
public void run ( ) { android.renderscript.RenderScript pRS = android.renderscript.RenderScript.create ( mCtx ) ; com.android.rs.test.ScriptC_copy_test s = new com.android.rs.test.ScriptC_copy_test ( pRS ) ; pRS.setMessageHandler ( mRsMessage ) ; testFloat2 ( pRS , s ) ; testFloat3 ( pRS , s ) ; testFloat4 ( pRS , s ) ; s.invoke_sendResult ( true ) ; pRS.finish ( ) ; waitForMessage ( ) ; s.destroy ( ) ; pRS.destroy ( ) ; }
Source:
private boolean scanFile ( android.database.Cursor cursor , int arrayPos ) { com.android.bluetooth.opp.BluetoothOppShareInfo info = mShares.get ( arrayPos ) ; synchronized ( this ) { if ( com.android.bluetooth.opp.BluetoothOppService.D ) { android.util.Log.d ( com.android.bluetooth.opp.BluetoothOppService.TAG , ( "Scanning file " + ( info.mFilename ) ) ) ; } if ( ! ( mMediaScanInProgress ) ) { mMediaScanInProgress = true ; new com.android.bluetooth.opp.BluetoothOppService.MediaScannerNotifier ( this , info , mHandler ) ; return true ; } else { return false ; } } }

Target:
private boolean scanFile ( int arrayPos ) { com.android.bluetooth.opp.BluetoothOppShareInfo info = mShares.get ( arrayPos ) ; synchronized ( this ) { if ( com.android.bluetooth.opp.BluetoothOppService.D ) { android.util.Log.d ( com.android.bluetooth.opp.BluetoothOppService.TAG , ( "Scanning file " + ( info.mFilename ) ) ) ; } if ( ! ( mMediaScanInProgress ) ) { mMediaScanInProgress = true ; new com.android.bluetooth.opp.BluetoothOppService.MediaScannerNotifier ( this , info , mHandler ) ; return true ; } else { return false ; } } }
Source:
static void nativeSetDrawFilter ( int nativeCanvas , int nativeFilter ) { android.graphics.Canvas_Delegate canvasDelegate = android.graphics.Canvas_Delegate.sManager.getDelegate ( nativeCanvas ) ; if ( canvasDelegate == null ) { return ; } canvasDelegate.mDrawFilter = android.graphics.DrawFilter_Delegate.getDelegate ( nativeFilter ) ; if ( ( ( canvasDelegate.mDrawFilter ) != null ) && ( ( canvasDelegate.mDrawFilter.isSupported ( ) ) == false ) ) { com.android.layoutlib.bridge.Bridge.getLog ( ) . fidelityWarning ( LayoutLog.TAG_DRAWFILTER , canvasDelegate.mDrawFilter.getSupportMessage ( ) , null , null ) ; } }

Target:
static void nativeSetDrawFilter ( long nativeCanvas , long nativeFilter ) { android.graphics.Canvas_Delegate canvasDelegate = android.graphics.Canvas_Delegate.sManager.getDelegate ( nativeCanvas ) ; if ( canvasDelegate == null ) { return ; } canvasDelegate.mDrawFilter = android.graphics.DrawFilter_Delegate.getDelegate ( nativeFilter ) ; if ( ( ( canvasDelegate.mDrawFilter ) != null ) && ( ( canvasDelegate.mDrawFilter.isSupported ( ) ) == false ) ) { com.android.layoutlib.bridge.Bridge.getLog ( ) . fidelityWarning ( LayoutLog.TAG_DRAWFILTER , canvasDelegate.mDrawFilter.getSupportMessage ( ) , null , null ) ; } }