auphong2707/dl4se-code-review-dataset huggingface dataset:
Source:
private static void initFormatStrings ( ) { synchronized ( android.text.format.DateUtils.sLock ) { android.content.res.Resources r = android.content.res.Resources.getSystem ( ) ; android.content.res.Configuration cfg = r.getConfiguration ( ) ; if ( ( ( android.text.format.DateUtils.sLastConfig ) == null ) || ( ! ( android.text.format.DateUtils.sLastConfig.equals ( cfg ) ) ) ) { android.text.format.DateUtils.sLastConfig = cfg ; android.text.format.DateUtils.sStatusTimeFormat = java.text.DateFormat.getTimeInstance ( java.text.DateFormat.SHORT ) ; android.text.format.DateUtils.sElapsedFormatMMSS = r.getString ( com.android.internal.R.string.elapsed_time_short_format_mm_ss ) ; android.text.format.DateUtils.sElapsedFormatHMMSS = r.getString ( com.android.internal.R.string.elapsed_time_short_format_h_mm_ss ) ; } } }

Target:
private static void initFormatStrings ( ) { synchronized ( android.text.format.DateUtils.sLock ) { android.text.format.DateUtils.initFormatStringsLocked ( ) ; } }
Source:
public void nonExpiredCacheHit ( ) throws java.lang.Exception { com.android.volley.Cache.Entry entry = com.android.volley.utils.CacheTestUtils.makeRandomCacheEntry ( null , false , false ) ; mCache.setEntryToReturn ( entry ) ; mCacheQueue.add ( mRequest ) ; mCacheQueue.waitUntilEmpty ( com.android.volley.CacheDispatcherTest.TIMEOUT_MILLIS ) ; assertTrue ( mDelivery.postResponse_called ) ; assertFalse ( mDelivery.postError_called ) ; }

Target:
public void cacheMiss ( ) throws java.lang.Exception { mDispatcher.processRequest ( mRequest ) ; com.android.volley.CacheDispatcherTest.verifyNoResponse ( mDelivery ) ; org.mockito.Mockito.verify ( mNetworkQueue ) . put ( mRequest ) ; org.junit.Assert.assertNull ( mRequest.getCacheEntry ( ) ) ; }
Source:
public java.lang.Object getMinSdkVersion ( @ com.android.annotations.NonNull java.io.File manifestFile ) { try { return com.android.xml.AndroidManifest.getMinSdkVersion ( new com.android.io.FileWrapper ( manifestFile ) ) ; } catch ( javax.xml.xpath.XPathExpressionException e ) { } catch ( com.android.io.StreamException e ) { throw new java.lang.RuntimeException ( e ) ; } return 1 ; }

Target:
public java.lang.Object getTargetSdkVersion ( @ com.android.annotations.NonNull java.io.File manifestFile ) { if ( ( mTargetSdkVersion ) == null ) { try { mTargetSdkVersion = com.google.common.base.Optional.fromNullable ( com.android.xml.AndroidManifest.getTargetSdkVersion ( new com.android.io.FileWrapper ( manifestFile ) ) ) ; } catch ( javax.xml.xpath.XPathExpressionException e ) { return new java.lang.RuntimeException ( e ) ; } catch ( com.android.io.StreamException e ) { throw new java.lang.RuntimeException ( e ) ; } } return mTargetSdkVersion.or ( ( - 1 ) ) ; }
Source:
public void onActivityCreated ( android.os.Bundle savedInstanceState ) { super . onActivityCreated ( savedInstanceState ) ; mWifiManager = ( ( android.net.wifi.WifiManager ) ( getSystemService ( Context.WIFI_SERVICE ) ) ) ; }

Target:
public void onActivityCreated ( android.os.Bundle savedInstanceState ) { super . onActivityCreated ( savedInstanceState ) ; mWifiManager = ( ( android.net.wifi.WifiManager ) ( getSystemService ( Context.WIFI_SERVICE ) ) ) ; mFilter = new android.content.IntentFilter ( ) ; mFilter.addAction ( WifiManager.LINK_CONFIGURATION_CHANGED_ACTION ) ; mFilter.addAction ( WifiManager.NETWORK_STATE_CHANGED_ACTION ) ; }
Source:
private com.android.jack.ir.ast.JDefinedClass initializeSyntheticClass ( @ javax.annotation.Nonnull com.android.jack.ir.ast.JPackage enclosingPackage , @ javax.annotation.Nonnull java.lang.String syntheticClassShortName ) { com.android.jack.ir.ast.JDefinedClass syntheticSwitchmapClass = new com.android.jack.ir.ast.JDefinedClass ( com.android.jack.ir.sourceinfo.SourceInfo.UNKNOWN , syntheticClassShortName , ( ( ( com.android.jack.ir.ast.JModifier.PUBLIC ) | ( com.android.jack.ir.ast.JModifier.FINAL ) ) | ( com.android.jack.ir.ast.JModifier.SYNTHETIC ) ) , enclosingPackage , com.android.jack.load.NopClassOrInterfaceLoader.INSTANCE ) ; syntheticSwitchmapClass.setSuperClass ( session.getLookup ( ) . getClass ( "Ljava/lang/Object;" ) ) ; syntheticSwitchmapClass.setExternal ( false ) ; session.addTypeToEmit ( syntheticSwitchmapClass ) ; return syntheticSwitchmapClass ; }

Target:
private com.android.jack.ir.ast.JDefinedClass initializeSyntheticClass ( @ javax.annotation.Nonnull com.android.jack.ir.ast.JPackage enclosingPackage , @ javax.annotation.Nonnull java.lang.String syntheticClassShortName ) { com.android.jack.ir.ast.JDefinedClass syntheticSwitchmapClass = new com.android.jack.ir.ast.JDefinedClass ( com.android.jack.ir.sourceinfo.SourceInfo.UNKNOWN , syntheticClassShortName , ( ( ( com.android.jack.ir.ast.JModifier.PUBLIC ) | ( com.android.jack.ir.ast.JModifier.FINAL ) ) | ( com.android.jack.ir.ast.JModifier.SYNTHETIC ) ) , enclosingPackage , com.android.jack.load.NopClassOrInterfaceLoader.INSTANCE ) ; syntheticSwitchmapClass.setSuperClass ( session.getLookup ( ) . getClass ( CommonTypes.JAVA_LANG_OBJECT ) ) ; syntheticSwitchmapClass.setExternal ( false ) ; session.addTypeToEmit ( syntheticSwitchmapClass ) ; return syntheticSwitchmapClass ; }
Source:
public void testAppNameKeyword ( ) { com.android.ddmuilib.logcat.LogCatMessage msg = new com.android.ddmuilib.logcat.LogCatMessage ( com.android.ddmlib.Log.LogLevel.VERBOSE , "" , "" , "dalvik" , "" , "" , "sample message" ) ; assertEquals ( false , search ( "dalv.*" , msg ) ) ; assertEquals ( true , search ( "app:dal.*k" , msg ) ) ; }

Target:
public void testAppNameKeyword ( ) { com.android.ddmlib.logcat.LogCatMessage msg = new com.android.ddmlib.logcat.LogCatMessage ( com.android.ddmlib.Log.LogLevel.VERBOSE , "" , "" , "dalvik" , "" , "" , "sample message" ) ; assertEquals ( false , search ( "dalv.*" , msg ) ) ; assertEquals ( true , search ( "app:dal.*k" , msg ) ) ; }
Source:
private android.telephony.ims.feature.ImsFeature makeImsFeature ( int slotId , int feature ) { switch ( feature ) { case android.telephony.ims.feature.ImsFeature.EMERGENCY_MMTEL : { return onCreateEmergencyMMTelImsFeature ( slotId ) ; } case android.telephony.ims.feature.ImsFeature.MMTEL : { return onCreateMMTelImsFeature ( slotId ) ; } case android.telephony.ims.feature.ImsFeature.RCS : { return onCreateRcsFeature ( slotId ) ; } } return null ; }

Target:
private com.android.ims.internal.IImsMMTelFeature createMMTelFeatureInternal ( int slotId , com.android.ims.internal.IImsFeatureStatusCallback c ) { android.telephony.ims.feature.MMTelFeature f = onCreateMMTelImsFeature ( slotId ) ; if ( f != null ) { setupFeature ( f , slotId , ImsFeature.MMTEL , c ) ; return f.getBinder ( ) ; } else { return null ; } }
Source:
public static boolean testSntp ( ) { final android.net.SntpClient client = new android.net.SntpClient ( ) ; if ( client.requestTime ( "0.pool.ntp.org" , 10000 ) ) { return true ; } return false ; }

Target:
public static boolean testSntp ( android.content.Context context ) { final android.net.SntpClient client = new android.net.SntpClient ( ) ; final android.net.ConnectivityManager mCM = context.getSystemService ( android.net.ConnectivityManager.class ) ; final android.net.Network network = mCM.getActiveNetwork ( ) ; if ( client.requestTime ( "0.pool.ntp.org" , 10000 , network ) ) { return true ; } return false ; }
Source:
protected static java.io.File getMergedBlobFolder ( java.io.File folder ) throws java.io.IOException { java.io.File originalMerger = new java.io.File ( folder , AssetMerger.FN_MERGER_XML ) ; java.lang.String content = com.google.common.io.Files.toString ( originalMerger , com.google.common.base.Charsets.UTF_8 ) ; content = content.replaceAll ( "\\$TOP\\$" , java.util.regex.Matcher.quoteReplacement ( folder.getAbsolutePath ( ) ) ) . replaceAll ( "\\$SEP\\$" , java.util.regex.Matcher.quoteReplacement ( java.io.File.separator ) ) ; java.io.File tempFolder = com.google.common.io.Files.createTempDir ( ) ; com.google.common.io.Files.write ( content , new java.io.File ( tempFolder , AssetMerger.FN_MERGER_XML ) , com.google.common.base.Charsets.UTF_8 ) ; return tempFolder ; }

Target:
protected static java.io.File getMergedBlobFolder ( java.io.File folder ) throws java.io.IOException { java.io.File originalMerger = new java.io.File ( folder , DataMerger.FN_MERGER_XML ) ; java.lang.String content = com.google.common.io.Files.toString ( originalMerger , com.google.common.base.Charsets.UTF_8 ) ; content = content.replaceAll ( "\\$TOP\\$" , java.util.regex.Matcher.quoteReplacement ( folder.getAbsolutePath ( ) ) ) . replaceAll ( "\\$SEP\\$" , java.util.regex.Matcher.quoteReplacement ( java.io.File.separator ) ) ; java.io.File tempFolder = com.google.common.io.Files.createTempDir ( ) ; com.google.common.io.Files.write ( content , new java.io.File ( tempFolder , DataMerger.FN_MERGER_XML ) , com.google.common.base.Charsets.UTF_8 ) ; return tempFolder ; }
Source:
public void testUpdateBatteryLevel_errorTooLargeValue ( ) { com.android.bluetooth.btservice.RemoteDevices remoteDevices = new com.android.bluetooth.btservice.RemoteDevices ( mAdapterService ) ; int batteryLevel = 101 ; org.junit.Assert.assertNull ( remoteDevices.getDeviceProperties ( mDevice1 ) ) ; remoteDevices.updateBatteryLevel ( mDevice1 , batteryLevel ) ; org.mockito.Mockito.verify ( mAdapterService , org.mockito.Mockito.never ( ) ) . sendBroadcast ( org.mockito.Mockito.any ( ) , org.mockito.Mockito.anyString ( ) ) ; org.junit.Assert.assertNull ( remoteDevices.getDeviceProperties ( mDevice1 ) ) ; org.mockito.Mockito.verifyNoMoreInteractions ( mAdapterService ) ; }

Target:
public void testUpdateBatteryLevel_errorNegativeValue ( ) { int batteryLevel = android.bluetooth.BluetoothDevice.BATTERY_LEVEL_UNKNOWN ; org.junit.Assert.assertNull ( mRemoteDevices.getDeviceProperties ( mDevice1 ) ) ; mRemoteDevices.updateBatteryLevel ( mDevice1 , batteryLevel ) ; org.mockito.Mockito.verify ( mAdapterService , org.mockito.Mockito.never ( ) ) . sendBroadcast ( org.mockito.Mockito.any ( ) , org.mockito.Mockito.anyString ( ) ) ; org.junit.Assert.assertNull ( mRemoteDevices.getDeviceProperties ( mDevice1 ) ) ; org.mockito.Mockito.verifyNoMoreInteractions ( mAdapterService ) ; }
Source:
public void addOutput ( byte [ ] data , int offset , int length ) { if ( ! ( isCancelled ( ) ) ) { java.lang.String s ; try { s = new java.lang.String ( data , offset , length , "UTF-8" ) ; } catch ( java.io.UnsupportedEncodingException e ) { s = new java.lang.String ( data , offset , length ) ; } mOutputBuffer.append ( s ) ; } }

Target:
public void addOutput ( byte [ ] data , int offset , int length ) { if ( ! ( isCancelled ( ) ) ) { java.lang.String s ; s = new java.lang.String ( data , offset , length , com.google.common.base.Charsets.UTF_8 ) ; mOutputBuffer.append ( s ) ; } }
Source:
public static < B > java.util.Set < java.util.List < B > > cartesianProduct ( java.util.List < ? extends java.util.Set < ? extends B > > sets ) { for ( java.util.Set < ? extends B > set : sets ) { if ( set.isEmpty ( ) ) { return com.google.common.collect.ImmutableSet.of ( ) ; } } com.google.common.collect.Sets.CartesianSet < B > cartesianSet = new com.google.common.collect.Sets.CartesianSet < B > ( sets ) ; return cartesianSet ; }

Target:
public static < B > java.util.Set < java.util.List < B > > cartesianProduct ( java.util.List < ? extends java.util.Set < ? extends B > > sets ) { return com.google.common.collect.Sets.CartesianSet.create ( sets ) ; }
Source:
public void testGetNetworkCountryIso ( ) { android.content.pm.PackageManager packageManager = getContext ( ) . getPackageManager ( ) ; java.lang.String countryCode = mTelephonyManager.getNetworkCountryIso ( ) ; if ( packageManager.hasSystemFeature ( PackageManager.FEATURE_TELEPHONY ) ) { assertTrue ( ( ( ( "Country code '" + countryCode ) + "' did not match " ) + ( android.telephony.cts.TelephonyManagerTest.ISO_COUNTRY_CODE_PATTERN ) ) , java.util.regex.Pattern.matches ( android.telephony.cts.TelephonyManagerTest.ISO_COUNTRY_CODE_PATTERN , countryCode ) ) ; } else { } }

Target:
public void testGetNetworkCountryIso ( ) { android.content.pm.PackageManager packageManager = android.telephony.cts.TelephonyManagerTest.getContext ( ) . getPackageManager ( ) ; java.lang.String countryCode = mTelephonyManager.getNetworkCountryIso ( ) ; if ( packageManager.hasSystemFeature ( PackageManager.FEATURE_TELEPHONY ) ) { org.junit.Assert.assertTrue ( ( ( ( "Country code '" + countryCode ) + "' did not match " ) + ( android.telephony.cts.TelephonyManagerTest.ISO_COUNTRY_CODE_PATTERN ) ) , java.util.regex.Pattern.matches ( android.telephony.cts.TelephonyManagerTest.ISO_COUNTRY_CODE_PATTERN , countryCode ) ) ; } else { } }
Source:
public void testFlagIExistingI ( ) { int iFlags = PackageManager.INSTALL_INTERNAL ; int rFlags = ( PackageManager.INSTALL_INTERNAL ) | ( PackageManager.INSTALL_REPLACE_EXISTING ) ; installFromRawResource ( "install.apk" , R.raw.install , iFlags , false , false , ( - 1 ) , ( - 1 ) ) ; installFromRawResource ( "install.apk" , R.raw.install , rFlags , true , false , ( - 1 ) , ( - 1 ) ) ; }

Target:
public void testFlagFExistingE ( ) { if ( android.os.Environment.isExternalStorageEmulated ( ) ) { return ; } int iFlags = android.content.pm.PackageManager.INSTALL_EXTERNAL ; int rFlags = ( android.content.pm.PackageManager.INSTALL_FORWARD_LOCK ) | ( android.content.pm.PackageManager.INSTALL_REPLACE_EXISTING ) ; installFromRawResource ( "install.apk" , R.raw.install , iFlags , false , false , ( - 1 ) , ( - 1 ) ) ; installFromRawResource ( "install.apk" , R.raw.install , rFlags , true , false , ( - 1 ) , ( - 1 ) ) ; }
Source:
public static java.lang.String getXmlString ( com.android.resources.ResourceType type , com.android.ide.eclipse.adt.internal.resources.ResourceItem resourceItem , boolean system ) { if ( ( type == ( com.android.resources.ResourceType.ID ) ) && ( resourceItem instanceof com.android.ide.eclipse.adt.internal.resources.IIdResourceItem ) ) { com.android.ide.eclipse.adt.internal.resources.IIdResourceItem idResource = ( ( com.android.ide.eclipse.adt.internal.resources.IIdResourceItem ) ( resourceItem ) ) ; if ( idResource.isDeclaredInline ( ) ) { return ( ( ( system ? "@android:" : "@+" ) + ( type.getName ( ) ) ) + "/" ) + ( resourceItem.getName ( ) ) ; } } return ( ( ( system ? "@android:" : "@" ) + ( type.getName ( ) ) ) + "/" ) + ( resourceItem.getName ( ) ) ; }

Target:
public static java.lang.String getXmlString ( com.android.resources.ResourceType type , com.android.ide.eclipse.adt.internal.resources.manager.ResourceItem resourceItem , boolean system ) { if ( ( type == ( com.android.resources.ResourceType.ID ) ) && ( resourceItem.isDeclaredInline ( ) ) ) { return ( ( ( system ? "@android:" : "@+" ) + ( type.getName ( ) ) ) + "/" ) + ( resourceItem.getName ( ) ) ; } return ( ( ( system ? "@android:" : "@" ) + ( type.getName ( ) ) ) + "/" ) + ( resourceItem.getName ( ) ) ; }
Source:
private void createDeviceTab ( org.eclipse.swt.widgets.TabFolder tabFolder , org.eclipse.swt.widgets.TabItem devTabItem ) { org.eclipse.swt.widgets.Composite root = new org.eclipse.swt.widgets.Composite ( tabFolder , org.eclipse.swt.SWT.NONE ) ; devTabItem.setControl ( root ) ; com.android.sdkuilib.ui.GridLayoutBuilder.create ( root ) . columns ( 1 ) ; com.android.sdkuilib.internal.repository.ui.DeviceManagerPage container = new com.android.sdkuilib.internal.repository.ui.DeviceManagerPage ( root , org.eclipse.swt.SWT.NONE , mUpdaterData , mDeviceManager ) ; com.android.sdkuilib.ui.GridDataBuilder.create ( container ) . fill ( ) . grab ( ) ; }

Target:
public void onAvdCreated ( com.android.sdklib.internal.avd.AvdInfo avdInfo ) { if ( avdInfo != null ) { mTabFolder.setSelection ( 0 ) ; mAvdPage.selectAvd ( avdInfo , true ) ; } }
Source:
public static void setUpClass ( ) { com.android.jack.compile.androidtree.bouncycastle.BouncycastleCompilationTest.class . getClassLoader ( ) . setDefaultAssertionStatus ( true ) ; com.android.jack.compile.androidtree.bouncycastle.BouncycastleCompilationTest.BOOTCLASSPATH = new java.io.File [ ] { com.android.jack.TestTools.getFromAndroidTree ( "out/target/common/obj/JAVA_LIBRARIES/core_intermediates/classes.jar" ) } ; com.android.jack.compile.androidtree.bouncycastle.BouncycastleCompilationTest.SOURCELIST = com.android.jack.TestTools.getTargetLibSourcelist ( "bouncycastle" ) ; com.android.jack.compile.androidtree.bouncycastle.BouncycastleCompilationTest.JARJAR_RULES = new com.android.jack.JarJarRules ( com.android.jack.TestTools.getFromAndroidTree ( "external/bouncycastle/jarjar-rules.txt" ) ) ; }

Target:
public static void setUpClass ( ) { com.android.jack.compile.androidtree.bouncycastle.BouncycastleCompilationTest.class . getClassLoader ( ) . setDefaultAssertionStatus ( true ) ; com.android.jack.compile.androidtree.bouncycastle.BouncycastleCompilationTest.BOOTCLASSPATH = new java.io.File [ ] { com.android.jack.TestTools.getFromAndroidTree ( "out/target/common/obj/JAVA_LIBRARIES/core-libart_intermediates/classes.zip" ) } ; com.android.jack.compile.androidtree.bouncycastle.BouncycastleCompilationTest.REF_BOOTCLASSPATH = new java.io.File [ ] { com.android.jack.TestTools.getFromAndroidTree ( "out/target/common/obj/JAVA_LIBRARIES/core-libart_intermediates/classes.jar" ) } ; com.android.jack.compile.androidtree.bouncycastle.BouncycastleCompilationTest.SOURCELIST = com.android.jack.TestTools.getTargetLibSourcelist ( "bouncycastle" ) ; com.android.jack.compile.androidtree.bouncycastle.BouncycastleCompilationTest.JARJAR_RULES = new com.android.jack.JarJarRules ( com.android.jack.TestTools.getFromAndroidTree ( "external/bouncycastle/jarjar-rules.txt" ) ) ; }
Source:
public java.util.Locale.Builder setLanguage ( java.lang.String language ) { if ( ( language == null ) || ( language.isEmpty ( ) ) ) { this . language = "" ; return this ; } final java.lang.String lowercaseLanguage = language.toLowerCase ( java.util.Locale.ROOT ) ; if ( ! ( java.util.Locale.isValidBcp47Alpha ( lowercaseLanguage , 2 , 3 ) ) ) { throw new java.util.IllformedLocaleException ( ( "Invalid language: " + language ) ) ; } this . language = lowercaseLanguage ; return this ; }

Target:
public java.util.Locale.Builder setLanguage ( java.lang.String language ) { this . language = java.util.Locale.Builder.normalizeAndValidateLanguage ( language ) ; return this ; }
Source:
public void delete ( @ javax.annotation.Nonnull com.android.jack.library.FileType fileType , @ javax.annotation.Nonnull com.android.sched.vfs.VPath typePath ) throws com.android.jack.library.FileTypeDoesNotExistException , com.android.sched.util.file.CannotDeleteFileException { try { com.android.sched.vfs.InputVFS currentSectionVFS = getSectionVFS ( fileType ) ; currentSectionVFS.getRootInputVDir ( ) . delete ( buildFileVPath ( fileType , typePath ) ) ; } catch ( com.android.sched.util.file.NotFileOrDirectoryException e ) { throw new com.android.jack.library.FileTypeDoesNotExistException ( getLocation ( ) , typePath , fileType ) ; } catch ( com.android.sched.util.file.NoSuchFileException e ) { throw new com.android.jack.library.FileTypeDoesNotExistException ( getLocation ( ) , typePath , fileType ) ; } }

Target:
public void delete ( @ javax.annotation.Nonnull com.android.jack.library.FileType fileType , @ javax.annotation.Nonnull com.android.sched.vfs.VPath typePath ) throws com.android.jack.library.FileTypeDoesNotExistException , com.android.sched.util.file.CannotDeleteFileException { try { com.android.sched.vfs.InputVFS currentSectionVFS = getSectionVFS ( fileType ) ; currentSectionVFS.getRootInputVDir ( ) . getInputVFile ( buildFileVPath ( fileType , typePath ) ) . delete ( ) ; } catch ( com.android.sched.util.file.NotFileOrDirectoryException e ) { throw new com.android.jack.library.FileTypeDoesNotExistException ( getLocation ( ) , typePath , fileType ) ; } catch ( com.android.sched.util.file.NoSuchFileException e ) { throw new com.android.jack.library.FileTypeDoesNotExistException ( getLocation ( ) , typePath , fileType ) ; } }
Source:
public void getRadioCapability ( android.os.Message response ) { com.android.internal.telephony.RILRequest rr = com.android.internal.telephony.RILRequest.obtain ( com.android.internal.telephony.RIL_REQUEST_GET_RADIO_CAPABILITY , response , mRILDefaultWorkSource ) ; if ( com.android.internal.telephony.RIL.RILJ_LOGD ) riljLog ( ( ( ( rr.serialString ( ) ) + "> " ) + ( com.android.internal.telephony.RIL.requestToString ( rr.mRequest ) ) ) ) ; send ( rr ) ; }

Target:
public void pullLceData ( android.os.Message response ) { android.hardware.radio.V1_0.IRadio radioProxy = getRadioProxy ( response ) ; if ( radioProxy != null ) { com.android.internal.telephony.RILRequest rr = obtainRequest ( com.android.internal.telephony.RIL_REQUEST_PULL_LCEDATA , response , mRILDefaultWorkSource ) ; if ( com.android.internal.telephony.RIL.RILJ_LOGD ) { riljLog ( ( ( ( rr.serialString ( ) ) + "> " ) + ( com.android.internal.telephony.RIL.requestToString ( rr.mRequest ) ) ) ) ; } try { radioProxy.pullLceData ( rr.mSerial ) ; } catch ( android.os.RemoteException | java.lang.RuntimeException e ) { handleRadioProxyExceptionForRR ( rr , "pullLceData" , e ) ; } } }
Source:
public void socketpair ( int domain , int type , int protocol , java.io.FileDescriptor fd1 , java.io.FileDescriptor fd2 ) throws android.system.ErrnoException { os.socketpair ( domain , type , protocol , fd1 , fd2 ) ; if ( ( domain != ( AF_UNIX ) ) && ( domain != ( AF_NETLINK ) ) ) { tagSocket ( fd1 ) ; tagSocket ( fd2 ) ; } }

Target:
public void socketpair ( int domain , int type , int protocol , java.io.FileDescriptor fd1 , java.io.FileDescriptor fd2 ) throws android.system.ErrnoException { os.socketpair ( domain , type , protocol , fd1 , fd2 ) ; if ( libcore.io.BlockGuardOs.isInetDomain ( domain ) ) { tagSocket ( fd1 ) ; tagSocket ( fd2 ) ; } }
Source:
private int deleteCodeCacheDirsLI ( java.lang.String volumeUuid , java.lang.String packageName ) { int [ ] users = com.android.server.pm.PackageManagerService.sUserManager.getUserIds ( ) ; int res = 0 ; for ( int user : users ) { int resInner = mInstaller.deleteCodeCacheFiles ( volumeUuid , packageName , user ) ; if ( resInner < 0 ) { res = resInner ; } } return res ; }

Target:
private int [ ] resolveUserIds ( int userId ) { return userId == ( android.os.UserHandle.USER_ALL ) ? com.android.server.pm.PackageManagerService.sUserManager.getUserIds ( ) : new int [ ] { userId } ; }
Source:
private void logTestFailure ( java.io.PrintStream logStream , java.lang.String provider , libcore.javax.crypto.CipherTest.CipherTestParam params , java.lang.Exception e ) { logStream.append ( ( ( ( ( ( ( "Error encountered checking " + ( params.transformation ) ) + ", keySize=" ) + ( ( params.key.getEncoded ( ) . length ) * 8 ) ) + " with provider " ) + provider ) + "\n" ) ) ; e.printStackTrace ( logStream ) ; }

Target:
private void logTestFailure ( java.io.PrintStream logStream , java.lang.String provider , libcore.javax.crypto.CipherTest.CipherTestParam params , java.lang.Exception e ) { logStream.append ( ( ( ( ( ( ( "Error encountered checking " + ( params.transformation ) ) + ", keySize=" ) + ( ( params.encryptKey.getEncoded ( ) . length ) * 8 ) ) + " with provider " ) + provider ) + "\n" ) ) ; e.printStackTrace ( logStream ) ; }
Source:
public void setTestClassName ( java.lang.String testClassName , java.lang.String testMethodName ) { java.lang.Class testClass = loadTestClass ( testClassName ) ; if ( shouldRunSingleTestMethod ( testMethodName , testClass ) ) { junit.framework.TestCase testCase = buildSingleTestMethod ( testClass , testMethodName ) ; mTestCases = com.google.android.collect.Lists.newArrayList ( testCase ) ; mTestClassName = testClass.getSimpleName ( ) ; } else { setTest ( getTest ( testClass ) , testClass ) ; } }

Target:
public void setTestClassName ( java.lang.String testClassName , java.lang.String testMethodName ) { java.lang.Class testClass = loadTestClass ( testClassName ) ; if ( shouldRunSingleTestMethod ( testMethodName , testClass ) ) { junit.framework.TestCase testCase = buildSingleTestMethod ( testClass , testMethodName ) ; mTestCases = new java.util.ArrayList < > ( ) ; mTestCases.add ( testCase ) ; mTestClassName = testClass.getSimpleName ( ) ; } else { setTest ( getTest ( testClass ) , testClass ) ; } }
Source:
private void processIntentScoVolume ( android.content.Intent intent , android.bluetooth.BluetoothDevice device ) { int volumeValue = intent.getIntExtra ( AudioManager.EXTRA_VOLUME_STREAM_VALUE , 0 ) ; if ( ( mPhoneState.getSpeakerVolume ( ) ) != volumeValue ) { mPhoneState.setSpeakerVolume ( volumeValue ) ; setVolumeNative ( HeadsetHalConstants.VOLUME_TYPE_SPK , volumeValue , getByteAddress ( device ) ) ; } }

Target:
private void processIntentScoVolume ( android.content.Intent intent , android.bluetooth.BluetoothDevice device ) { int volumeValue = intent.getIntExtra ( AudioManager.EXTRA_VOLUME_STREAM_VALUE , 0 ) ; if ( ( mPhoneState.getSpeakerVolume ( ) ) != volumeValue ) { mPhoneState.setSpeakerVolume ( volumeValue ) ; mNativeInterface.setVolume ( device , HeadsetHalConstants.VOLUME_TYPE_SPK , volumeValue ) ; } }
Source:
public void onReceive ( android.content.Context context , android.content.Intent intent ) { if ( AudioManager.ACTION_HEADSET_PLUG.equals ( intent.getAction ( ) ) ) { boolean isPluggedIn = ( intent.getIntExtra ( "state" , 0 ) ) == 1 ; android.util.Log.v ( com.android.dialer.app.voicemail.WiredHeadsetManager.TAG , ( "ACTION_HEADSET_PLUG event, plugged in: " + isPluggedIn ) ) ; onHeadsetPluggedInChanged ( isPluggedIn ) ; } }

Target:
public void onReceive ( android.content.Context context , android.content.Intent intent ) { if ( AudioManager.ACTION_HEADSET_PLUG.equals ( intent.getAction ( ) ) ) { boolean isPluggedIn = ( intent.getIntExtra ( "state" , 0 ) ) == 1 ; com.android.dialer.common.LogUtil.v ( com.android.dialer.app.voicemail.WiredHeadsetManager.TAG , ( "ACTION_HEADSET_PLUG event, plugged in: " + isPluggedIn ) ) ; onHeadsetPluggedInChanged ( isPluggedIn ) ; } }
Source:
private com.android.jack.ir.ast.JExpressionStatement makeResetCall ( com.android.jack.ir.sourceinfo.SourceInfo info ) { assert ( ( lockClass ) != null ) && ( ( resetMethodId ) != null ) ; return new com.android.jack.ir.ast.JExpressionStatement ( info , new com.android.jack.ir.ast.JMethodCall ( info , null , resetClass , resetMethodId , JPrimitiveTypeEnum.VOID.getType ( ) , false ) ) ; }

Target:
private com.android.jack.ir.ast.JExpressionStatement makeRequestCall ( com.android.jack.ir.sourceinfo.SourceInfo info ) { assert ( ( ( lockClass ) != null ) && ( ( requestClass ) != null ) ) && ( ( requestMethodId ) != null ) ; return new com.android.jack.ir.ast.JExpressionStatement ( info , new com.android.jack.ir.ast.JMethodCall ( info , null , requestClass , requestMethodId , JPrimitiveTypeEnum.VOID.getType ( ) , false ) ) ; }
Source:
private void expireRequest ( android.net.NetworkCapabilities netCap , int sequenceNum ) { int ourSeqNum = - 1 ; synchronized ( android.net.ConnectivityManager.sLegacyRequests ) { android.net.ConnectivityManager.LegacyRequest l = android.net.ConnectivityManager.sLegacyRequests.get ( netCap ) ; if ( l == null ) return ; ourSeqNum = l.expireSequenceNumber ; if ( ( l.expireSequenceNumber ) == sequenceNum ) { unregisterNetworkCallback ( l.networkCallback ) ; android.net.ConnectivityManager.sLegacyRequests.remove ( netCap ) ; } } android.util.Log.d ( android.net.ConnectivityManager.TAG , ( ( ( "expireRequest with " + ourSeqNum ) + ", " ) + sequenceNum ) ) ; }

Target:
private void expireRequest ( android.net.NetworkCapabilities netCap , int sequenceNum ) { int ourSeqNum = - 1 ; synchronized ( android.net.ConnectivityManager.sLegacyRequests ) { android.net.ConnectivityManager.LegacyRequest l = android.net.ConnectivityManager.sLegacyRequests.get ( netCap ) ; if ( l == null ) return ; ourSeqNum = l.expireSequenceNumber ; if ( ( l.expireSequenceNumber ) == sequenceNum ) removeRequestForFeature ( netCap ) ; } android.util.Log.d ( android.net.ConnectivityManager.TAG , ( ( ( "expireRequest with " + ourSeqNum ) + ", " ) + sequenceNum ) ) ; }
Source:
public void testCompile2 ( ) throws java.lang.Exception { com.android.jack.test.toolchain.IToolchain toolchain = com.android.jack.test.toolchain.AbstractTestTools.getCandidateToolchain ( ) ; toolchain.setSourceLevel ( SourceLevel.JAVA_7 ) . addToClasspath ( toolchain.getDefaultBootClasspath ( ) ) . srcToExe ( com.android.jack.test.toolchain.AbstractTestTools.createTempDir ( ) , false , com.android.jack.test.toolchain.AbstractTestTools.getTestRootDir ( "com.android.jack.java7.trywithresources.test002.jack" ) ) ; }

Target:
public void testCompile2 ( ) throws java.lang.Exception { new com.android.jack.test.helper.RuntimeTestHelper ( TEST002 ) . setSourceLevel ( SourceLevel.JAVA_7 ) . compileAndRunTest ( ) ; }
Source:
public void testEmptyRootXml ( ) throws java.lang.Exception { java.lang.String document = ( "<?xml version=\"1.0\"?>" + ( com.android.sdklib.repository.SdkRepositoryTest.OPEN_TAG ) ) + ( com.android.sdklib.repository.SdkRepositoryTest.CLOSE_TAG ) ; javax.xml.transform.Source source = new javax.xml.transform.stream.StreamSource ( new java.io.StringReader ( document ) ) ; com.android.sdklib.repository.SdkRepositoryTest.CaptureErrorHandler handler = new com.android.sdklib.repository.SdkRepositoryTest.CaptureErrorHandler ( ) ; javax.xml.validation.Validator validator = getValidator ( SdkRepository.NS_LATEST_VERSION , handler ) ; validator.validate ( source ) ; handler.verify ( ) ; }

Target:
public void testEmptyRootXml ( ) throws java.lang.Exception { java.lang.String document = ( "<?xml version=\"1.0\"?>" + ( com.android.sdklib.repository.SdkRepositoryTest.OPEN_TAG ) ) + ( com.android.sdklib.repository.SdkRepositoryTest.CLOSE_TAG ) ; javax.xml.transform.Source source = new javax.xml.transform.stream.StreamSource ( new java.io.StringReader ( document ) ) ; com.android.sdklib.repository.SdkRepositoryTest.CaptureErrorHandler handler = new com.android.sdklib.repository.SdkRepositoryTest.CaptureErrorHandler ( ) ; javax.xml.validation.Validator validator = getValidator ( SdkRepoConstants.NS_LATEST_VERSION , handler ) ; validator.validate ( source ) ; handler.verify ( ) ; }
Source:
public void widgetSelected ( org.eclipse.swt.events.SelectionEvent e ) { super . widgetSelected ( e ) ; if ( ( mResourceType ) == ( com.android.resources.ResourceType.STRING ) ) { createNewString ( ) ; } }

Target:
public void widgetSelected ( org.eclipse.swt.events.SelectionEvent e ) { super . widgetSelected ( e ) ; if ( ( mResourceType ) == ( com.android.resources.ResourceType.STRING ) ) { createNewString ( ) ; } else { assert com.android.ide.eclipse.adt.internal.editors.xml.Hyperlinks.isValueResource ( mResourceType ) ; java.lang.String newName = createNewValue ( mResourceType ) ; if ( newName != null ) { setupResourceList ( ) ; selectItemName ( newName ) ; } } }
Source:
public void testNewInstanceString_CharArrayIntIntConstructor ( ) { runTestNewInstanceString ( "([CII)V" , new org.apache.harmony.jpda.tests.jdwp.ClassType.NewInstanceStringTest.ConstructorArgumentsProvider ( ) { @ java.lang.Override public void provideConstructorArguments ( java.util.List < org.apache.harmony.jpda.tests.framework.jdwp.Value > constructorArguments ) { long debuggeeClassId = getClassIDBySignature ( getDebuggeeClassSignature ( ) ) ; org.apache.harmony.jpda.tests.framework.jdwp.Value charArrayValue = getStaticFieldValue ( debuggeeClassId , "CHAR_ARRAY" ) ; constructorArguments.add ( charArrayValue ) ; constructorArguments.add ( new org.apache.harmony.jpda.tests.framework.jdwp.Value ( 0 ) ) ; constructorArguments.add ( new org.apache.harmony.jpda.tests.framework.jdwp.Value ( 1 ) ) ; } } ) ; }

Target:
public void testNewInstanceString_CharArrayConstructor ( ) { runTestNewInstanceString ( "([C)V" , new org.apache.harmony.jpda.tests.jdwp.ClassType.ConstructorArgumentsProvider ( ) { @ java.lang.Override public void provideConstructorArguments ( java.util.List < org.apache.harmony.jpda.tests.framework.jdwp.Value > constructorArguments ) { long debuggeeClassId = getClassIDBySignature ( getDebuggeeClassSignature ( ) ) ; org.apache.harmony.jpda.tests.framework.jdwp.Value charArrayValue = getStaticFieldValue ( debuggeeClassId , "CHAR_ARRAY" ) ; constructorArguments.add ( charArrayValue ) ; } } ) ; }
Source:
public void testAssistantStackLaunchNewTaskWithDockedStack ( ) throws java.lang.Exception { if ( ( ! ( supportsSplitScreenMultiWindow ( ) ) ) || ( ! ( assistantRunsOnPrimaryDisplay ( ) ) ) ) return ; launchActivity ( android.server.cts.ActivityManagerAssistantStackTests.TEST_ACTIVITY ) ; launchActivityInDockStack ( android.server.cts.ActivityManagerAssistantStackTests.DOCKED_ACTIVITY ) ; mAmWmState.assertContainsStack ( "Must contain fullscreen stack." , android.server.cts.FULLSCREEN_WORKSPACE_STACK_ID ) ; mAmWmState.assertContainsStack ( "Must contain docked stack." , android.server.cts.DOCKED_STACK_ID ) ; enableAssistant ( ) ; assertAssistantStackCanLaunchAndReturnFromNewTask ( ) ; disableAssistant ( ) ; }

Target:
public void testAssistantStackLaunchNewTaskWithDockedStack ( ) throws java.lang.Exception { if ( ( ! ( supportsSplitScreenMultiWindow ( ) ) ) || ( ! ( assistantRunsOnPrimaryDisplay ( ) ) ) ) return ; launchActivity ( android.server.cts.ActivityManagerAssistantStackTests.TEST_ACTIVITY ) ; launchActivityInDockStack ( android.server.cts.ActivityManagerAssistantStackTests.DOCKED_ACTIVITY ) ; mAmWmState.assertHasFullscreenTypeStackOnDisplay ( "Must contain fullscreen stack." , android.server.cts.ActivityManagerAssistantStackTests.mAssistantDisplayId ) ; mAmWmState.assertContainsStack ( "Must contain docked stack." , android.server.cts.DOCKED_STACK_ID ) ; enableAssistant ( ) ; assertAssistantStackCanLaunchAndReturnFromNewTask ( ) ; disableAssistant ( ) ; }
Source:
public java.lang.String getDexCacheString ( com.android.dex.Dex dex , int dexStringIndex ) { java.lang.String s = dexCacheStrings [ dexStringIndex ] ; if ( s == null ) { s = dex.strings ( ) . get ( dexStringIndex ) . intern ( ) ; dexCacheStrings [ dexStringIndex ] = s ; } return s ; }

Target:
public java.lang.String getDexCacheString ( com.android.dex.Dex dex , int dexStringIndex ) { java.lang.String s = dexCache.getResolvedString ( dexStringIndex ) ; if ( s == null ) { s = dex.strings ( ) . get ( dexStringIndex ) . intern ( ) ; dexCache.setResolvedString ( dexStringIndex , s ) ; } return s ; }
Source:
private void check ( java.lang.String [ ] [ ] tests , java.util.Set < java.lang.String > keys , com.ibm.icu.impl.ValidIdentifiers.Datasubtype ... datasubtypes ) { int count = 0 ; com.ibm.icu.impl.locale.LocaleValidityChecker localeValidityChecker = new com.ibm.icu.impl.locale.LocaleValidityChecker ( datasubtypes ) ; for ( java.lang.String [ ] test : tests ) { check ( ( ++ count ) , localeValidityChecker , test [ 0 ] , test [ 1 ] , keys ) ; } }

Target:
private void check ( java.lang.String [ ] [ ] tests , java.util.Set < java.lang.String > keys , com.ibm.icu.impl.ValidIdentifiers.Datasubtype ... datasubtypes ) { int count = 0 ; com.ibm.icu.impl.locale.LocaleValidityChecker localeValidityChecker = new com.ibm.icu.impl.locale.LocaleValidityChecker ( datasubtypes ) ; for ( java.lang.String [ ] test : tests ) { if ( ( test [ 1 ] . endsWith ( "-va-posix" ) ) && ( logKnownIssue ( "12615" , "Validity check wrong for -va-posix?" ) ) ) continue ; check ( ( ++ count ) , localeValidityChecker , test [ 0 ] , test [ 1 ] , keys ) ; } }
Source:
public java.lang.Class < ? > getTestClass ( ) { java.lang.String name = getClassName ( ) ; if ( name == null ) return null ; try { return java.lang.Class.forName ( name ) ; } catch ( java.lang.ClassNotFoundException e ) { return null ; } }

Target:
public java.lang.Class < ? > getTestClass ( ) { if ( ( fTestClass ) != null ) { return fTestClass ; } java.lang.String name = getClassName ( ) ; if ( name == null ) { return null ; } try { fTestClass = java.lang.Class.forName ( name , false , getClass ( ) . getClassLoader ( ) ) ; return fTestClass ; } catch ( java.lang.ClassNotFoundException e ) { return null ; } }
Source:
private com.android.jack.dx.rop.annotation.Annotation createAnnotation ( @ javax.annotation.Nonnull com.android.jack.ir.ast.JAnnotation annotation ) throws com.android.jack.backend.dex.AnnotationBuilder.BuildAnnotationException , com.android.jack.backend.dex.AnnotationBuilder.SourceAnnotationException { com.android.jack.dx.rop.annotation.Annotation ropAnnotation = new com.android.jack.dx.rop.annotation.Annotation ( com.android.jack.backend.dex.rop.RopHelper.getCstType ( annotation.getType ( ) ) , getVisibility ( annotation.getRetentionPolicy ( ) ) ) ; constantBuilder.createAnnotationPairs ( annotation , ropAnnotation ) ; ropAnnotation.setImmutable ( ) ; return ropAnnotation ; }

Target:
private com.android.jack.dx.rop.annotation.Annotation createAnnotation ( @ javax.annotation.Nonnull com.android.jack.ir.ast.JAnnotation annotation ) throws com.android.jack.backend.dex.AnnotationBuilder.BuildAnnotationException , com.android.jack.backend.dex.AnnotationBuilder.SourceAnnotationException { com.android.jack.dx.rop.annotation.Annotation ropAnnotation = new com.android.jack.dx.rop.annotation.Annotation ( com.android.jack.backend.dex.rop.RopHelper.convertTypeToDx ( annotation.getType ( ) ) , getVisibility ( annotation.getRetentionPolicy ( ) ) ) ; constantBuilder.createAnnotationPairs ( annotation , ropAnnotation ) ; ropAnnotation.setImmutable ( ) ; return ropAnnotation ; }
Source:
public static java.io.FileDescriptor socket ( boolean stream ) throws java.net.SocketException { java.io.FileDescriptor fd ; try { fd = Libcore.os.socket ( libcore.io.AF_INET6 , ( stream ? SOCK_STREAM : SOCK_DGRAM ) , 0 ) ; if ( ! stream ) { Libcore.os.setsockoptInt ( fd , libcore.io.IPPROTO_IPV6 , libcore.io.IPV6_MULTICAST_HOPS , 1 ) ; } return fd ; } catch ( libcore.io.ErrnoException errnoException ) { throw errnoException.rethrowAsSocketException ( ) ; } }

Target:
public static java.io.FileDescriptor socket ( boolean stream ) throws java.net.SocketException { java.io.FileDescriptor fd ; try { fd = Libcore.os.socket ( libcore.io.AF_INET6 , ( stream ? SOCK_STREAM : SOCK_DGRAM ) , 0 ) ; if ( ! stream ) { Libcore.os.setsockoptInt ( fd , libcore.io.IPPROTO_IPV6 , libcore.io.IPV6_MULTICAST_HOPS , 1 ) ; } return fd ; } catch ( android.system.ErrnoException errnoException ) { throw errnoException.rethrowAsSocketException ( ) ; } }
Source:
public com.android.apksigner.core.internal.util.ByteBufferDataSource slice ( long offset , long size ) { if ( ( offset == 0 ) && ( size == ( mSize ) ) ) { return this ; } checkChunkValid ( offset , size ) ; int chunkPosition = ( ( int ) ( offset ) ) ; int chunkLimit = ( ( int ) ( chunkPosition + size ) ) ; synchronized ( mBuffer ) { mBuffer.position ( 0 ) ; mBuffer.limit ( chunkLimit ) ; mBuffer.position ( chunkPosition ) ; return new com.android.apksigner.core.internal.util.ByteBufferDataSource ( mBuffer ) ; } }

Target:
public void copyTo ( long offset , int size , java.nio.ByteBuffer dest ) { dest.put ( getByteBuffer ( offset , size ) ) ; }
Source:
public void createConnectionFailed ( java.lang.String callId , android.telecom.ConnectionRequest request , boolean isIncoming , android.telecom.Logging.Session.Info sessionInfo ) { android.telecom.Log.startSession ( sessionInfo , android.telecom.ConnectionService.SESSION_CREATE_CONN_FAILED ) ; try { com.android.internal.os.SomeArgs args = com.android.internal.os.SomeArgs.obtain ( ) ; args.arg1 = callId ; args.arg2 = request ; args.arg3 = android.telecom.Log.createSubsession ( ) ; args.argi1 = ( isIncoming ) ? 1 : 0 ; mHandler.obtainMessage ( android.telecom.ConnectionService.MSG_CREATE_CONNECTION_FAILED , args ) . sendToTarget ( ) ; } finally { android.telecom.Log.endSession ( ) ; } }

Target:
public void createConnectionFailed ( android.telecom.PhoneAccountHandle connectionManagerPhoneAccount , java.lang.String callId , android.telecom.ConnectionRequest request , boolean isIncoming , android.telecom.Logging.Session.Info sessionInfo ) { android.telecom.Log.startSession ( sessionInfo , android.telecom.ConnectionService.SESSION_CREATE_CONN_FAILED ) ; try { com.android.internal.os.SomeArgs args = com.android.internal.os.SomeArgs.obtain ( ) ; args.arg1 = callId ; args.arg2 = request ; args.arg3 = android.telecom.Log.createSubsession ( ) ; args.arg4 = connectionManagerPhoneAccount ; args.argi1 = ( isIncoming ) ? 1 : 0 ; mHandler.obtainMessage ( android.telecom.ConnectionService.MSG_CREATE_CONNECTION_FAILED , args ) . sendToTarget ( ) ; } finally { android.telecom.Log.endSession ( ) ; } }
Source:
private boolean getAutoTime ( ) { try { return ( Settings.Global.getInt ( mCr , Settings.Global.AUTO_TIME ) ) > 0 ; } catch ( android.provider.Settings snfe ) { return true ; } }

Target:
public boolean isConcurrentVoiceAndDataAllowed ( ) { if ( ( mSS.getCssIndicator ( ) ) == 1 ) { return true ; } else if ( mPhone.isPhoneTypeGsm ( ) ) { return ( mSS.getRilDataRadioTechnology ( ) ) >= ( android.telephony.ServiceState.RIL_RADIO_TECHNOLOGY_UMTS ) ; } else { return false ; } }
Source:
void onLocalDisconnect ( ) { if ( ! ( disconnected ) ) { doDisconnect ( ) ; if ( false ) android.util.Log.d ( com.android.internal.telephony.cdma.CdmaConnection.LOG_TAG , "[CDMAConn] onLoalDisconnect" ) ; if ( ( parent ) != null ) { parent.detach ( this ) ; } } releaseWakeLock ( ) ; }

Target:
void onLocalDisconnect ( ) { if ( ! ( disconnected ) ) { doDisconnect ( ) ; if ( false ) android.telephony.Rlog.d ( com.android.internal.telephony.cdma.CdmaConnection.LOG_TAG , "[CDMAConn] onLoalDisconnect" ) ; if ( ( parent ) != null ) { parent.detach ( this ) ; } } releaseWakeLock ( ) ; }
Source:
protected java.lang.Void doInBackground ( java.lang.Void ... arg0 ) { android.media.MediaMetadata.Builder builder = new android.media.MediaMetadata.Builder ( ) ; builder.putString ( MediaMetadata.METADATA_KEY_TITLE , title ) ; android.graphics.Bitmap posterArt = android.graphics.BitmapFactory.decodeResource ( getResources ( ) , imageResId ) ; if ( posterArt != null ) { builder.putBitmap ( MediaMetadata.METADATA_KEY_ART , posterArt ) ; } mMediaSession.setMetadata ( builder.build ( ) ) ; return null ; }

Target:
public void done ( boolean success ) { if ( success ) { blockOrUnblockScreen ( mTvView , false ) ; mIsCurrentChannelUnblockedByUser = true ; } }
Source:
public static java.util.Date getDate ( android.security.keymaster.KeyCharacteristics keyCharacteristics , int tag ) { java.util.Date result = keyCharacteristics.hwEnforced.getDate ( tag , null ) ; if ( result == null ) { result = keyCharacteristics.swEnforced.getDate ( tag , null ) ; } return result ; }

Target:
public static java.lang.String [ ] getJcaBlockModesFromKeymasterBlockModes ( java.util.Collection < java.lang.Integer > keymasterBlockModes ) { if ( ( keymasterBlockModes == null ) || ( keymasterBlockModes.isEmpty ( ) ) ) { return libcore.util.EmptyArray.STRING ; } java.lang.String [ ] result = new java.lang.String [ keymasterBlockModes.size ( ) ] ; int offset = 0 ; for ( int keymasterBlockMode : keymasterBlockModes ) { result [ offset ] = android.security.KeymasterUtils.getJcaBlockModeFromKeymasterBlockMode ( keymasterBlockMode ) ; offset ++ ; } return result ; }
Source:
public void traverse ( @ javax.annotation.Nonnull com.android.jack.ir.ast.JVisitor visitor ) { if ( visitor.visit ( this ) ) { if ( visitor.needLoading ( ) ) { loadSubPackages ( ) ; loadClassesAndInterfaces ( ) ; } visitor.accept ( subPackages ) ; visitor.accept ( declaredTypes ) ; } visitor.endVisit ( this ) ; }

Target:
public void traverse ( @ javax.annotation.Nonnull com.android.jack.ir.ast.JVisitor visitor ) { assert ( ( enclosingPackage ) == null ) || ( ! ( enclosingPackage.deletedItems.contains ( getName ( ) ) ) ) ; if ( visitor.visit ( this ) ) { if ( visitor.needLoading ( ) ) { loadSubPackages ( ) ; loadClassesAndInterfaces ( ) ; } visitor.accept ( subPackages ) ; visitor.accept ( declaredTypes ) ; } visitor.endVisit ( this ) ; }
Source:
private boolean isDexFilledNewArrayCompatible ( @ javax.annotation.Nonnull com.android.jack.ir.ast.JNewArray newArray ) { com.android.jack.ir.ast.JType elementType = newArray.getArrayType ( ) . getElementType ( ) ; java.util.List < com.android.jack.ir.ast.JExpression > initializers = newArray.getInitializers ( ) ; if ( ( ( ( ! ( initializers.isEmpty ( ) ) ) && ( ( initializers.size ( ) ) <= 5 ) ) && ( ( newArray.getDims ( ) . size ( ) ) == 1 ) ) && ( elementType.equals ( JPrimitiveTypeEnum.INT.getType ( ) ) ) ) { return true ; } return false ; }

Target:
private boolean isDexFilledNewArrayCompatible ( @ javax.annotation.Nonnull com.android.jack.ir.ast.JNewArray newArray ) { com.android.jack.ir.ast.JType elementType = newArray.getArrayType ( ) . getElementType ( ) ; java.util.List < com.android.jack.ir.ast.JExpression > initializers = newArray.getInitializers ( ) ; if ( ( ( ( ! ( initializers.isEmpty ( ) ) ) && ( ( initializers.size ( ) ) <= 5 ) ) && ( ( newArray.getDims ( ) . size ( ) ) == 1 ) ) && ( elementType.isSameType ( JPrimitiveTypeEnum.INT.getType ( ) ) ) ) { return true ; } return false ; }
Source:
public void testDismissKeyguardActivity_method_notTop ( ) throws java.lang.Exception { if ( ! ( isHandheld ( ) ) ) { return ; } final java.lang.String logSeparator = clearLogcat ( ) ; gotoKeyguard ( ) ; mAmWmState.computeState ( mDevice , null ) ; assertTrue ( mAmWmState.getAmState ( ) . getKeyguardControllerState ( ) . keyguardShowing ) ; launchActivity ( "BroadcastReceiverActivity" ) ; launchActivity ( "TestActivity" ) ; executeShellCommand ( "am broadcast -a trigger_broadcast --ez dismissKeyguardMethod true" ) ; assertOnDismissErrorInLogcat ( logSeparator ) ; }

Target:
public void testDismissKeyguardActivity_method_notTop ( ) throws java.lang.Exception { if ( ( ! ( isHandheld ( ) ) ) || ( isUiModeLockedToVrHeadset ( ) ) ) { return ; } final java.lang.String logSeparator = clearLogcat ( ) ; gotoKeyguard ( ) ; mAmWmState.computeState ( mDevice , null ) ; assertTrue ( mAmWmState.getAmState ( ) . getKeyguardControllerState ( ) . keyguardShowing ) ; launchActivity ( "BroadcastReceiverActivity" ) ; launchActivity ( "TestActivity" ) ; executeShellCommand ( "am broadcast -a trigger_broadcast --ez dismissKeyguardMethod true" ) ; assertOnDismissErrorInLogcat ( logSeparator ) ; }
Source:
private void loadStoppedAuthorities ( ) { final android.content.ContentResolver resolver = mContext.getContentResolver ( ) ; synchronized ( mLock ) { for ( java.lang.String authority : mStoppedAuthorities ) { mRoots.putAll ( authority , loadRootsForAuthority ( resolver , authority , true ) ) ; } mStoppedAuthorities.clear ( ) ; } }

Target:
private void loadStoppedAuthorities ( ) { final android.content.ContentResolver resolver = mContext.getContentResolver ( ) ; synchronized ( mLock ) { for ( java.lang.String authority : mStoppedAuthorities ) { mRoots.replaceValues ( authority , loadRootsForAuthority ( resolver , authority , true ) ) ; } mStoppedAuthorities.clear ( ) ; } }
Source:
public void test_needsDictionary ( ) { java.util.zip.Deflater inf = new java.util.zip.Deflater ( ) ; assertEquals ( 0 , inf.getTotalIn ( ) ) ; assertEquals ( 0 , inf.getTotalOut ( ) ) ; assertEquals ( 0 , inf.getBytesRead ( ) ) ; assertEquals ( 0 , inf.getBytesWritten ( ) ) ; }

Target:
public void test_needsDictionary ( ) { java.util.zip.Deflater inf = new java.util.zip.Deflater ( ) ; assertEquals ( 0 , inf.getTotalIn ( ) ) ; assertEquals ( 0 , inf.getTotalOut ( ) ) ; assertEquals ( 0 , inf.getBytesRead ( ) ) ; assertEquals ( 0 , inf.getBytesWritten ( ) ) ; inf.end ( ) ; }
Source:
public void onClick ( android.view.View v ) { mZoomButtonsController.setVisible ( false ) ; zoomScrollOut ( ) ; if ( android.webkit.WebView.mLogEvent ) { android.provider.Checkin.updateStats ( mContext.getContentResolver ( ) , Checkin.Stats.Tag.BROWSER_ZOOM_OVERVIEW , 1 , 0.0 ) ; } }

Target:
public boolean onScaleBegin ( android.view.ScaleGestureDetector detector ) { cancelTouch ( ) ; if ( mZoomButtonsController.isVisible ( ) ) { mZoomButtonsController.setVisible ( false ) ; } mInZoomOverview = false ; if ( ( inEditingMode ( ) ) && ( nativeFocusCandidateIsPassword ( ) ) ) { mWebTextView.setInPassword ( false ) ; } return true ; }
Source:
protected void addFailuresTab ( ) { if ( ! ( results.getFailures ( ) . isEmpty ( ) ) ) { addTab ( "Failed tests" , new org.gradle.api.Action < org.w3c.dom.Element > ( ) { @ java.lang.Override public void execute ( org.w3c.dom.Element element ) { renderFailures ( element ) ; } } ) ; } }

Target:
protected void addFailuresTab ( ) { if ( ! ( results.getFailures ( ) . isEmpty ( ) ) ) { addTab ( "Failed tests" , new org.gradle.api.internal.ErroringAction < org.gradle.api.internal.html.SimpleHtmlWriter > ( ) { @ java.lang.Override public void doExecute ( org.gradle.api.internal.html.SimpleHtmlWriter writer ) throws java.io.IOException { renderFailures ( writer ) ; } } ) ; } }