auphong2707/dl4se-code-review-dataset huggingface dataset:
Source:
public int getAllPhoneAccountsCount ( ) { synchronized ( mLock ) { try { com.android.server.telecom.Log.startSession ( "TSI.gAPAC" ) ; return getAllPhoneAccounts ( ) . size ( ) ; } catch ( java.lang.Exception e ) { com.android.server.telecom.Log.e ( this , e , "getAllPhoneAccountsCount" ) ; throw e ; } finally { com.android.server.telecom.Log.endSession ( ) ; } } }

Target:
public int getAllPhoneAccountsCount ( ) { synchronized ( mLock ) { try { android.telecom.Log.startSession ( "TSI.gAPAC" ) ; return getAllPhoneAccounts ( ) . size ( ) ; } catch ( java.lang.Exception e ) { android.telecom.Log.e ( this , e , "getAllPhoneAccountsCount" ) ; throw e ; } finally { android.telecom.Log.endSession ( ) ; } } }
Source:
public void setDataEnabled ( int subId , boolean enable ) { try { android.util.Log.d ( android.telephony.TelephonyManager.TAG , ( "setDataEnabled: enabled=" + enable ) ) ; com.android.internal.telephony.ITelephony telephony = getITelephony ( ) ; if ( telephony != null ) telephony.setDataEnabled ( subId , enable ) ; } catch ( android.os.RemoteException e ) { android.util.Log.e ( android.telephony.TelephonyManager.TAG , "Error calling ITelephony#setDataEnabled" , e ) ; } }

Target:
public boolean isMobileDataEnabled ( ) { boolean retVal = false ; try { int subId = getSubId ( android.telephony.SubscriptionManager.getDefaultDataSubscriptionId ( ) ) ; com.android.internal.telephony.ITelephony telephony = getITelephony ( ) ; if ( telephony != null ) retVal = telephony.isDataEnabled ( subId ) ; } catch ( android.os.RemoteException e ) { android.util.Log.e ( android.telephony.TelephonyManager.TAG , "Error calling ITelephony#isDataEnabled" , e ) ; } catch ( java.lang.NullPointerException e ) { } return retVal ; }
Source:
public boolean isAnonymous ( ) { boolean isAnonymous = false ; com.android.jack.ir.ast.marker.SimpleName simpleNameInfo = jDeclaredType.getMarker ( com.android.jack.ir.ast.marker.SimpleName.class ) ; if ( simpleNameInfo != null ) { isAnonymous = simpleNameInfo.getSimpleName ( ) . isEmpty ( ) ; } else { com.android.jack.ir.ast.JAnnotationLiteral enclosingAnnotation = com.android.jack.ecj.loader.jast.AnnotationUtils.getAnnotation ( jDeclaredType , AnnotationUtils.INNER_CLASS_ANNOTATION ) ; if ( enclosingAnnotation != null ) { com.android.jack.ir.ast.JNameValuePair pair = enclosingAnnotation.getNameValuePair ( AnnotationUtils.INNERCLASS_NAME_FIELD ) ; assert pair != null ; isAnonymous = ( pair.getValue ( ) ) instanceof com.android.jack.ir.ast.JNullLiteral ; } } return isAnonymous ; }

Target:
public boolean isAnonymous ( ) { boolean isAnonymous = false ; com.android.jack.ir.ast.marker.SimpleName simpleNameInfo = jDeclaredType.getMarker ( com.android.jack.ir.ast.marker.SimpleName.class ) ; if ( simpleNameInfo != null ) { isAnonymous = simpleNameInfo.getSimpleName ( ) . isEmpty ( ) ; } else { com.android.jack.ir.ast.JAnnotation enclosingAnnotation = com.android.jack.ecj.loader.jast.AnnotationUtils.getAnnotation ( jDeclaredType , AnnotationUtils.INNER_CLASS_ANNOTATION ) ; if ( enclosingAnnotation != null ) { com.android.jack.ir.ast.JNameValuePair pair = enclosingAnnotation.getNameValuePair ( AnnotationUtils.INNERCLASS_NAME_FIELD ) ; assert pair != null ; isAnonymous = ( pair.getValue ( ) ) instanceof com.android.jack.ir.ast.JNullLiteral ; } } return isAnonymous ; }
Source:
private boolean shouldScanFile ( int arrayPos ) { com.android.providers.downloads.DownloadInfo info = ( ( com.android.providers.downloads.DownloadInfo ) ( mDownloads.get ( arrayPos ) ) ) ; return ( ( ( ! ( info.mediaScanned ) ) && ( ( info.destination ) == ( android.provider.Downloads.DESTINATION_EXTERNAL ) ) ) && ( android.provider.Downloads.isStatusSuccess ( info.status ) ) ) && ( ! ( DrmRawContent.DRM_MIMETYPE_MESSAGE_STRING.equalsIgnoreCase ( info.mimetype ) ) ) ; }

Target:
private boolean shouldScanFile ( int arrayPos ) { com.android.providers.downloads.DownloadInfo info = ( ( com.android.providers.downloads.DownloadInfo ) ( mDownloads.get ( arrayPos ) ) ) ; return ( ( ( ! ( info.mMediaScanned ) ) && ( ( info.mDestination ) == ( android.provider.Downloads.DESTINATION_EXTERNAL ) ) ) && ( android.provider.Downloads.isStatusSuccess ( info.mStatus ) ) ) && ( ! ( DrmRawContent.DRM_MIMETYPE_MESSAGE_STRING.equalsIgnoreCase ( info.mMimeType ) ) ) ; }
Source:
public boolean cancelPairingUserInput ( ) { if ( ( android.bluetooth.BluetoothDevice.sService ) == null ) { android.util.Log.e ( android.bluetooth.BluetoothDevice.TAG , "BT not enabled. Cannot create pairing user input" ) ; return false ; } try { return android.bluetooth.BluetoothDevice.sService.cancelBondProcess ( this ) ; } catch ( android.os.RemoteException e ) { android.util.Log.e ( android.bluetooth.BluetoothDevice.TAG , "" , e ) ; } return false ; }

Target:
public boolean cancelPairingUserInput ( ) { final android.bluetooth.IBluetooth service = android.bluetooth.BluetoothDevice.sService ; if ( service == null ) { android.util.Log.e ( android.bluetooth.BluetoothDevice.TAG , "BT not enabled. Cannot create pairing user input" ) ; return false ; } try { return service.cancelBondProcess ( this ) ; } catch ( android.os.RemoteException e ) { android.util.Log.e ( android.bluetooth.BluetoothDevice.TAG , "" , e ) ; } return false ; }
Source:
public long digestFile ( java.io.File toFile ) throws java.io.IOException { if ( ( ! ( myIsBinary ) ) && ( com.intellij.updater.Utils.isZipFile ( toFile.getName ( ) ) ) ) { return com.intellij.updater.Digester.digestZipFile ( toFile ) ; } else { return com.intellij.updater.Digester.digestRegularFile ( toFile ) ; } }

Target:
public long digestFile ( java.io.File toFile , boolean normalize ) throws java.io.IOException { if ( ( ! ( myIsBinary ) ) && ( com.intellij.updater.Utils.isZipFile ( toFile.getName ( ) ) ) ) { return com.intellij.updater.Digester.digestZipFile ( toFile ) ; } else { return com.intellij.updater.Digester.digestRegularFile ( toFile , normalize ) ; } }
Source:
private int getSubId ( ) { if ( ( mSubId ) == ( SubscriptionManager.DEFAULT_SUBSCRIPTION_ID ) ) { return android.telephony.TelephonyManager.getDefaultSubscription ( ) ; } return mSubId ; }

Target:
public void sendVisualVoicemailSmsForSubscriber ( int subId , java.lang.String number , int port , java.lang.String text , android.app.PendingIntent sentIntent ) { try { com.android.internal.telephony.ITelephony telephony = getITelephony ( ) ; if ( telephony != null ) { telephony.sendVisualVoicemailSmsForSubscriber ( mContext.getOpPackageName ( ) , subId , number , port , text , sentIntent ) ; } } catch ( android.os.RemoteException ex ) { } }
Source:
public void addI32 ( android.support.v8.renderscript.Int2 v ) { if ( android.support.v8.renderscript.RenderScript.shouldThunk ( ) ) { mN.addI32 ( new android.support.v8.renderscript.Int2 ( v.x , v.y ) ) ; return ; } addI32 ( v.x ) ; addI32 ( v.y ) ; }

Target:
public void addU32 ( android.support.v8.renderscript.Long3 v ) { if ( android.support.v8.renderscript.RenderScript.shouldThunk ( ) ) { mN.addU32 ( v ) ; return ; } addU32 ( v.x ) ; addU32 ( v.y ) ; addU32 ( v.z ) ; }
Source:
public void animateExpandNotificationsPanel ( ) { if ( com.android.systemui.statusbar.phone.PhoneStatusBar.SPEW ) android.util.Slog.d ( com.android.systemui.statusbar.phone.PhoneStatusBar.TAG , ( "animateExpand: mExpandedVisible=" + ( mExpandedVisible ) ) ) ; if ( ( ( mDisabled ) & ( android.app.StatusBarManager.DISABLE_EXPAND ) ) != 0 ) { return ; } mNotificationPanel.expand ( ) ; if ( ( mHasFlipSettings ) && ( ( mScrollView.getVisibility ( ) ) != ( android.view.View.VISIBLE ) ) ) { flipToNotifications ( ) ; } if ( false ) postStartTracing ( ) ; }

Target:
public void animateExpandNotificationsPanel ( ) { if ( com.android.systemui.statusbar.phone.PhoneStatusBar.SPEW ) android.util.Log.d ( com.android.systemui.statusbar.phone.PhoneStatusBar.TAG , ( "animateExpand: mExpandedVisible=" + ( mExpandedVisible ) ) ) ; if ( ! ( panelsEnabled ( ) ) ) { return ; } mNotificationPanel.expand ( ) ; if ( ( mHasFlipSettings ) && ( ( mScrollView.getVisibility ( ) ) != ( android.view.View.VISIBLE ) ) ) { flipToNotifications ( ) ; } if ( false ) postStartTracing ( ) ; }
Source:
public void onReceive ( android.content.Context context , android.content.Intent intent ) { if ( ! ( BluetoothDevice.ACTION_BOND_STATE_CHANGED.equals ( intent.getAction ( ) ) ) ) { return ; } int state = intent.getIntExtra ( BluetoothDevice.EXTRA_BOND_STATE , BluetoothDevice.ERROR ) ; android.bluetooth.BluetoothDevice device = intent.getParcelableExtra ( BluetoothDevice.EXTRA_DEVICE ) ; if ( com.android.bluetooth.hearingaid.HearingAidService.DBG ) { android.util.Log.d ( com.android.bluetooth.hearingaid.HearingAidService.TAG , ( ( ( "Bond state changed for device: " + device ) + " state: " ) + state ) ) ; } if ( state != ( android.bluetooth.BluetoothDevice.BOND_NONE ) ) { return ; } }

Target:
public void onReceive ( android.content.Context context , android.content.Intent intent ) { if ( ! ( BluetoothDevice.ACTION_BOND_STATE_CHANGED.equals ( intent.getAction ( ) ) ) ) { return ; } int state = intent.getIntExtra ( BluetoothDevice.EXTRA_BOND_STATE , BluetoothDevice.ERROR ) ; android.bluetooth.BluetoothDevice device = intent.getParcelableExtra ( BluetoothDevice.EXTRA_DEVICE ) ; java.util.Objects.requireNonNull ( device , "ACTION_BOND_STATE_CHANGED with no EXTRA_DEVICE" ) ; bondStateChanged ( device , state ) ; }
Source:
public com.android.ahat.DocString render ( com.android.tools.perflib.heap.Instance element ) { if ( element == null ) { return com.android.ahat.DocString.link ( com.android.ahat.DocString.uri ( "roots" ) , com.android.ahat.DocString.text ( "ROOT" ) ) ; } else { return com.android.ahat.DocString.text ( "→ " ) . append ( com.android.ahat.Value.render ( element ) ) ; } }

Target:
public com.android.ahat.DocString render ( com.android.tools.perflib.heap.Instance element ) { if ( element == null ) { return com.android.ahat.DocString.link ( com.android.ahat.DocString.uri ( "rooted" ) , com.android.ahat.DocString.text ( "ROOT" ) ) ; } else { return com.android.ahat.DocString.text ( "→ " ) . append ( com.android.ahat.Value.render ( mSnapshot , element ) ) ; } }
Source:
void renderNow ( java.util.List < com.android.builder.dependency.LibraryDependency > libraries ) { if ( libraries.isEmpty ( ) ) { getTextOutput ( ) . withStyle ( org.gradle.logging.StyledTextOutput.Style.Info ) . text ( "No dependencies" ) ; getTextOutput ( ) . println ( ) ; return ; } renderChildren ( libraries ) ; }

Target:
void renderNow ( @ com.android.annotations.NonNull java.util.List < com.android.builder.dependency.LibraryDependency > libraries , @ com.android.annotations.Nullable java.util.List < com.android.builder.dependency.JarDependency > localJars ) { if ( ( libraries.isEmpty ( ) ) && ( ( localJars == null ) || ( localJars.isEmpty ( ) ) ) ) { getTextOutput ( ) . withStyle ( org.gradle.logging.StyledTextOutput.Style.Info ) . text ( "No dependencies" ) ; getTextOutput ( ) . println ( ) ; return ; } renderChildren ( libraries , localJars ) ; }
Source:
private static void doFollowReferencesTestRoot ( ) { Main.Verifier v = new Main.Verifier ( ) ; Main.tagClasses ( v ) ; Main.A a = Main.createTree ( v ) ; Main.doFollowReferencesTestImpl ( null , java.lang.Integer.MAX_VALUE , ( - 1 ) , a , v , null ) ; Main.doFollowReferencesTestImpl ( a.foo2 , java.lang.Integer.MAX_VALUE , ( - 1 ) , a , v , "3@1001" ) ; }

Target:
private void doFollowReferencesTestRoot ( ) { Main.Verifier v = new Main.Verifier ( ) ; Main.TestConfig.tagClasses ( v ) ; Main.A a = Main.TestConfig.createTree ( v ) ; doFollowReferencesTestImpl ( null , java.lang.Integer.MAX_VALUE , ( - 1 ) , a , v , null ) ; doFollowReferencesTestImpl ( a.foo2 , java.lang.Integer.MAX_VALUE , ( - 1 ) , a , v , "3@1001" ) ; }
Source:
private static android.net.Uri getUriForFile ( android.content.Context context , java.io.File file ) { java.lang.String path = ( ( android.net.Uri.encode ( "bugreports" ) ) + '/' ) + ( android.net.Uri.encode ( file.getName ( ) , "/" ) ) ; return new android.net.Uri.Builder ( ) . scheme ( "content" ) . authority ( com.google.android.traceur.FileSender.AUTHORITY ) . encodedPath ( path ) . build ( ) ; }

Target:
private static android.net.Uri getUriForFile ( android.content.Context context , java.io.File file ) { java.lang.String path = ( ( android.net.Uri.encode ( "bugreports" ) ) + '/' ) + ( android.net.Uri.encode ( file.getName ( ) , "/" ) ) ; return new android.net.Uri.Builder ( ) . scheme ( "content" ) . authority ( com.android.traceur.FileSender.AUTHORITY ) . encodedPath ( path ) . build ( ) ; }
Source:
public void answer ( int networkType , android.net.INetworkScoreCache scoreCache ) { mScoreCache = ( ( com.android.server.wifi.WifiNetworkScoreCache ) ( scoreCache ) ) ; }

Target:
public void setUp ( ) throws java.lang.Exception { mResource = getResource ( ) ; mScoreManager = mock ( android.net.NetworkScoreManager.class ) ; mContext = getContext ( ) ; mScoreCache = new android.net.wifi.WifiNetworkScoreCache ( mContext ) ; mWifiConfigManager = getWifiConfigManager ( ) ; when ( mClock.getElapsedSinceBootMillis ( ) ) . thenReturn ( android.os.SystemClock.elapsedRealtime ( ) ) ; mThresholdQualifiedRssi2G = mResource.getInteger ( R.integer.config_wifi_framework_wifi_score_low_rssi_threshold_24GHz ) ; mThresholdQualifiedRssi5G = mResource.getInteger ( R.integer.config_wifi_framework_wifi_score_low_rssi_threshold_5GHz ) ; mExternalScoreEvaluator = new com.android.server.wifi.ExternalScoreEvaluator ( mContext , mWifiConfigManager , mScoreCache , mClock , null ) ; }
Source:
static void testAddMethodToProfile ( java.io.File file , java.lang.reflect.Method m ) { Main.ensureProfilingInfo ( m ) ; Main.ensureProfileProcessing ( ) ; if ( ! ( Main.presentInProfile ( file.getPath ( ) , m ) ) ) { throw new java.lang.RuntimeException ( ( ( "Method with index " + m ) + " not in the profile" ) ) ; } }

Target:
static void testAddMethodToProfile ( java.io.File file , java.lang.reflect.Method m ) { Main.ensureProfilingInfo ( m ) ; Main.ensureProfileProcessing ( ) ; if ( ! ( Main.profileHasMethod ( true , file.getPath ( ) , m ) ) ) { throw new java.lang.RuntimeException ( ( ( "Method with index " + m ) + " not in the profile" ) ) ; } }
Source:
protected void setUp ( ) throws java.lang.Exception { super . setUp ( ) ; mContext = getInstrumentation ( ) . getContext ( ) ; mTelecomManager = ( ( android.telecom.TelecomManager ) ( mContext.getSystemService ( Context.TELECOM_SERVICE ) ) ) ; mShouldTestTelecom = shouldTestTelecom ( mContext ) ; if ( mShouldTestTelecom ) { mPreviousDefaultDialer = android.telecom.cts.TestUtils.TestUtils.getDefaultDialer ( getInstrumentation ( ) ) ; android.telecom.cts.TestUtils.TestUtils.setDefaultDialer ( getInstrumentation ( ) , android.telecom.cts.PACKAGE ) ; setupCallbacks ( ) ; } }

Target:
protected void setUp ( ) throws java.lang.Exception { super . setUp ( ) ; mContext = getInstrumentation ( ) . getContext ( ) ; mTelecomManager = ( ( android.telecom.TelecomManager ) ( mContext.getSystemService ( Context.TELECOM_SERVICE ) ) ) ; mShouldTestTelecom = android.telecom.cts.TestUtils.shouldTestTelecom ( mContext ) ; if ( mShouldTestTelecom ) { mPreviousDefaultDialer = android.telecom.cts.TestUtils.getDefaultDialer ( getInstrumentation ( ) ) ; android.telecom.cts.TestUtils.setDefaultDialer ( getInstrumentation ( ) , android.telecom.cts.TestUtils.PACKAGE ) ; setupCallbacks ( ) ; } }
Source:
public int getLastTetherError ( java.lang.String iface ) { synchronized ( mPublicSync ) { com.android.server.connectivity.Tethering.TetherState tetherState = mTetherStates.get ( iface ) ; if ( tetherState == null ) { android.util.Log.e ( com.android.server.connectivity.Tethering.TAG , ( ( "Tried to getLastTetherError on an unknown iface :" + iface ) + ", ignoring" ) ) ; return android.net.ConnectivityManager.TETHER_ERROR_UNKNOWN_IFACE ; } return tetherState.mLastError ; } }

Target:
public int getLastTetherError ( java.lang.String iface ) { synchronized ( mPublicSync ) { com.android.server.connectivity.Tethering.TetherState tetherState = mTetherStates.get ( iface ) ; if ( tetherState == null ) { android.util.Log.e ( com.android.server.connectivity.Tethering.TAG , ( ( "Tried to getLastTetherError on an unknown iface :" + iface ) + ", ignoring" ) ) ; return android.net.ConnectivityManager.TETHER_ERROR_UNKNOWN_IFACE ; } return tetherState.lastError ; } }
Source:
public void linkNativeLibraryDirectory ( java.lang.String uuid , java.lang.String packageName , java.lang.String nativeLibPath32 , int userId ) throws com.android.internal.os.InstallerConnection.InstallerException { if ( ! ( checkBeforeRemote ( ) ) ) return ; try { mInstalld.linkNativeLibraryDirectory ( uuid , packageName , nativeLibPath32 , userId ) ; } catch ( android.os.RemoteException | android.os.ServiceSpecificException e ) { throw new com.android.internal.os.InstallerConnection.InstallerException ( e.getMessage ( ) ) ; } }

Target:
public void createOatDir ( java.lang.String oatDir , java.lang.String dexInstructionSet ) throws com.android.server.pm.Installer.InstallerException { if ( ! ( checkBeforeRemote ( ) ) ) return ; try { mInstalld.createOatDir ( oatDir , dexInstructionSet ) ; } catch ( android.os.RemoteException | android.os.ServiceSpecificException e ) { throw com.android.server.pm.Installer.InstallerException.from ( e ) ; } }
Source:
private void showTranscriptionEnabledPreference ( ) { transcribeVoicemailPreference.setOnPreferenceChangeListener ( this ) ; transcribeVoicemailPreference.setChecked ( voicemailClient.isVoicemailTranscriptionEnabled ( getContext ( ) , phoneAccountHandle ) ) ; transcribeVoicemailPreference.setSummary ( R.string.voicemail_transcription_preference_summary_info ) ; transcribeVoicemailPreference.setEnabled ( true ) ; getPreferenceScreen ( ) . addPreference ( transcribeVoicemailPreference ) ; }

Target:
private void showTranscriptionEnabledPreference ( ) { transcribeVoicemailPreference.setOnPreferenceChangeListener ( this ) ; transcribeVoicemailPreference.setChecked ( voicemailClient.isVoicemailTranscriptionEnabled ( getContext ( ) , phoneAccountHandle ) ) ; transcribeVoicemailPreference.setSummary ( getVoicemailTranscriptionInformationalText ( ) ) ; transcribeVoicemailPreference.setEnabled ( true ) ; getPreferenceScreen ( ) . addPreference ( transcribeVoicemailPreference ) ; }
Source:
public void testReadTimeZone_TooManyTypes ( ) throws java.lang.Exception { libcore.util.ZoneInfoTestHelper.ZoneInfoDataBuilder builder = new libcore.util.ZoneInfoTestHelper.ZoneInfoDataBuilder ( ) ; builder.initializeToValid ( ) ; builder.setTypeCountOverride ( 257 ) ; byte [ ] bytes = builder.build ( ) ; try { createZoneInfo ( getName ( ) , java.lang.System.currentTimeMillis ( ) , bytes ) ; fail ( "Did not detect too many types" ) ; } catch ( java.io.IOException expected ) { } }

Target:
public void testReadTimeZone_TooManyTypes ( ) throws java.lang.Exception { libcore.tzdata.testing.ZoneInfoTestHelper.ZoneInfoDataBuilder builder = new libcore.tzdata.testing.ZoneInfoTestHelper.ZoneInfoDataBuilder ( ) ; builder.initializeToValid ( ) ; builder.setTypeCountOverride ( 257 ) ; byte [ ] bytes = builder.build ( ) ; try { createZoneInfo ( getName ( ) , java.lang.System.currentTimeMillis ( ) , bytes ) ; fail ( "Did not detect too many types" ) ; } catch ( java.io.IOException expected ) { } }
Source:
boolean equals ( ) { }

Target:
public boolean equals ( java.lang.Object o ) { if ( ( this ) == o ) return true ; if ( ! ( o instanceof com.android.build.gradle.internal.dsl.BuildType ) ) return false ; if ( ! ( super . equals ( o ) ) ) return false ; com.android.build.gradle.internal.dsl.BuildType other = ( ( com.android.build.gradle.internal.dsl.BuildType ) ( o ) ) ; if ( ( useJack ) != ( other.getUseJack ( ) ) ) return false ; if ( ( shrinkResources ) != ( other.isShrinkResources ( ) ) ) return false ; return true ; }
Source:
public void validateCopyConstructorFromValidSource ( ) throws java.lang.Exception { android.net.wifi.hotspot2.pps.HomeSP sourceSp = new android.net.wifi.hotspot2.pps.HomeSP ( ) ; sourceSp.fqdn = "fqdn" ; sourceSp.friendlyName = "friendlyName" ; sourceSp.roamingConsortiumOIs = new long [ ] { 85 , 102 } ; android.net.wifi.hotspot2.pps.HomeSP copySp = new android.net.wifi.hotspot2.pps.HomeSP ( sourceSp ) ; org.junit.Assert.assertTrue ( copySp.equals ( sourceSp ) ) ; }

Target:
public void validateCopyConstructorFromValidSource ( ) throws java.lang.Exception { android.net.wifi.hotspot2.pps.HomeSP sourceSp = android.net.wifi.hotspot2.pps.HomeSPTest.createHomeSpWithHomeNetworkIds ( ) ; android.net.wifi.hotspot2.pps.HomeSP copySp = new android.net.wifi.hotspot2.pps.HomeSP ( sourceSp ) ; org.junit.Assert.assertTrue ( copySp.equals ( sourceSp ) ) ; }
Source:
public void testRegisterDuplicates ( ) { android.support.test.espresso.IdlingResource r1 = new android.support.test.espresso.base.OnDemandIdlingResource ( "r1" ) ; android.support.test.espresso.IdlingResource r1dup = new android.support.test.espresso.base.OnDemandIdlingResource ( "r1" ) ; registry.registerResources ( com.google.common.collect.Lists.newArrayList ( r1 ) ) ; registry.registerResources ( com.google.common.collect.Lists.newArrayList ( r1 ) ) ; registry.registerResources ( com.google.common.collect.Lists.newArrayList ( r1dup ) ) ; }

Target:
public void registerDuplicates ( ) { android.support.test.espresso.IdlingResource r1 = new android.support.test.espresso.base.OnDemandIdlingResource ( "r1" ) ; android.support.test.espresso.IdlingResource r1dup = new android.support.test.espresso.base.OnDemandIdlingResource ( "r1" ) ; registry.registerResources ( com.google.common.collect.Lists.newArrayList ( r1 ) ) ; registry.registerResources ( com.google.common.collect.Lists.newArrayList ( r1 ) ) ; registry.registerResources ( com.google.common.collect.Lists.newArrayList ( r1dup ) ) ; }
Source:
public static java.util.List < com.google.gct.idea.appengine.wizard.AppEngineTemplates.TemplateInfo > getLocalTemplates ( ) { com.google.gct.idea.appengine.wizard.AppEngineTemplates.LOG.info ( "Populating built-in App Engine templates..." ) ; java.io.File jarPath = new java.io.File ( com.intellij.util.PathUtil.getJarPathForClass ( com.google.gct.idea.appengine.wizard.AppEngineTemplates.class ) ) ; if ( jarPath.isFile ( ) ) { jarPath = jarPath.getParentFile ( ) ; } java.io.File root = new java.io.File ( jarPath , com.google.gct.idea.appengine.wizard.AppEngineTemplates.TEMPLATES_DIR ) ; if ( ! ( root.exists ( ) ) ) { com.google.gct.idea.appengine.wizard.AppEngineTemplates.LOG.error ( "Failed to find templates directory, perhaps your cloud tools plugin is corrupt?" ) ; } return com.google.gct.idea.appengine.wizard.AppEngineTemplates.populateTemplates ( root ) ; }

Target:
public static com.android.tools.idea.templates.Template getClientModuleTemplate ( java.lang.String templateName ) { java.io.File root = com.google.gct.idea.appengine.wizard.AppEngineTemplates.findTemplatesDirInPluginJar ( com.google.gct.idea.appengine.wizard.AppEngineTemplates.CLIENT_TEMPLATES_DIR ) ; java.io.File templateFile = new java.io.File ( root , templateName ) ; if ( ! ( templateFile.exists ( ) ) ) { com.google.gct.idea.appengine.wizard.AppEngineTemplates.LOG.error ( ( "Failed to find client template " + templateName ) ) ; } return com.android.tools.idea.templates.Template.createFromPath ( templateFile ) ; }
Source:
public java.util.List < com.android.sdklib.devices.Device > getUserDevices ( ) { synchronized ( this ) { if ( ( mUserDevices ) == null ) { mUserDevices = new java.util.ArrayList < com.android.sdklib.devices.Device > ( ) ; try { java.io.File userDevicesFile = new java.io.File ( com.android.prefs.AndroidLocation.getFolder ( ) , com.android.sdklib.SdkConstants.FN_DEVICES_XML ) ; mUserDevices.addAll ( loadDevices ( userDevicesFile ) ) ; } catch ( com.android.prefs.AndroidLocation.AndroidLocationException e ) { mLog.warning ( "Couldn't load user devices: %1$s" , e.getMessage ( ) ) ; } } } return mUserDevices ; }

Target:
public void replaceUserDevice ( com.android.sdklib.devices.Device d ) { synchronized ( com.android.sdklib.devices.DeviceManager.lock ) { if ( ( com.android.sdklib.devices.DeviceManager.mUserDevices ) == null ) { getUserDevices ( ) ; } removeUserDevice ( d ) ; addUserDevice ( d ) ; } }
Source:
private void processAtCscs ( java.lang.String atString , int type , android.bluetooth.BluetoothDevice device ) { log ( ( "processAtCscs - atString = " + atString ) ) ; if ( ( mPhonebook ) != null ) { mPhonebook.handleCscsCommand ( atString , type , device ) ; } else { android.util.Log.e ( com.android.bluetooth.hfp.HeadsetStateMachine.TAG , "Phonebook handle null for At+CSCS" ) ; atResponseCodeNative ( HeadsetHalConstants.AT_RESPONSE_ERROR , 0 , getByteAddress ( device ) ) ; } }

Target:
private void processAtCpbr ( java.lang.String atString , int type , android.bluetooth.BluetoothDevice device ) { log ( ( "processAtCpbr - atString = " + atString ) ) ; if ( ( mPhonebook ) != null ) { mPhonebook.handleCpbrCommand ( atString , type , device ) ; } else { android.util.Log.e ( com.android.bluetooth.hfp.HeadsetStateMachine.TAG , "Phonebook handle null for At+CPBR" ) ; mNativeInterface.atResponseCode ( device , HeadsetHalConstants.AT_RESPONSE_ERROR , 0 ) ; } }
Source:
static boolean isValidModuleName ( @ org.jetbrains.annotations.NotNull java.lang.String moduleName ) { if ( ! ( moduleName.replaceAll ( com.google.gct.idea.appengine.wizard.NewCloudModuleDynamicWizardStep.INVALID_FILENAME_CHARS , "" ) . equals ( moduleName ) ) ) { return false ; } for ( java.lang.String s : com.google.common.base.Splitter.on ( '.' ) . split ( moduleName ) ) { if ( com.google.gct.idea.appengine.wizard.NewCloudModuleDynamicWizardStep.INVALID_MSFT_FILENAMES.contains ( s.toLowerCase ( ) ) ) { return false ; } } return true ; }

Target:
static boolean isValidModuleName ( @ org.jetbrains.annotations.NotNull java.lang.String moduleName ) { if ( ! ( moduleName.replaceAll ( WizardConstants.INVALID_FILENAME_CHARS , "" ) . equals ( moduleName ) ) ) { return false ; } for ( java.lang.String s : com.google.common.base.Splitter.on ( '.' ) . split ( moduleName ) ) { if ( WizardConstants.INVALID_WINDOWS_FILENAMES.contains ( s.toLowerCase ( ) ) ) { return false ; } } return true ; }
Source:
public void clear ( ) { mIfaceName = null ; mLinkAddresses.clear ( ) ; mDnses.clear ( ) ; mDomains = null ; mRoutes.clear ( ) ; mHttpProxy = null ; mStackedLinks.clear ( ) ; mMtu = 0 ; mTcpBufferSizes = null ; }

Target:
public void clear ( ) { mIfaceName = null ; mLinkAddresses.clear ( ) ; mDnses.clear ( ) ; mUsePrivateDns = false ; mPrivateDnsServerName = null ; mDomains = null ; mRoutes.clear ( ) ; mHttpProxy = null ; mStackedLinks.clear ( ) ; mMtu = 0 ; mTcpBufferSizes = null ; }
Source:
public static android.content.Intent newInstance ( android.content.Context context , com.android.dialer.CoalescedIds coalescedAnnotatedCallLogIds , com.android.dialer.dialercontact.DialerContact contact , boolean canReportCallerId , boolean canSupportAssistedDialing ) { android.content.Intent intent = new android.content.Intent ( context , com.android.dialer.calldetails.CallDetailsActivity.class ) ; com.android.dialer.protos.ProtoParsers.put ( intent , com.android.dialer.calldetails.CallDetailsActivity.EXTRA_CONTACT , com.android.dialer.common.Assert.isNotNull ( contact ) ) ; com.android.dialer.protos.ProtoParsers.put ( intent , com.android.dialer.calldetails.CallDetailsActivity.EXTRA_COALESCED_CALL_LOG_IDS , com.android.dialer.common.Assert.isNotNull ( coalescedAnnotatedCallLogIds ) ) ; intent.putExtra ( com.android.dialer.calldetails.EXTRA_CAN_REPORT_CALLER_ID , canReportCallerId ) ; intent.putExtra ( com.android.dialer.calldetails.EXTRA_CAN_SUPPORT_ASSISTED_DIALING , canSupportAssistedDialing ) ; return intent ; }

Target:
public static android.content.Intent newInstance ( android.content.Context context , com.android.dialer.CoalescedIds coalescedAnnotatedCallLogIds , com.android.dialer.calldetails.CallDetailsHeaderInfo callDetailsHeaderInfo , boolean canReportCallerId , boolean canSupportAssistedDialing ) { android.content.Intent intent = new android.content.Intent ( context , com.android.dialer.calldetails.CallDetailsActivity.class ) ; com.android.dialer.protos.ProtoParsers.put ( intent , com.android.dialer.calldetails.CallDetailsActivity.EXTRA_COALESCED_CALL_LOG_IDS , com.android.dialer.common.Assert.isNotNull ( coalescedAnnotatedCallLogIds ) ) ; com.android.dialer.protos.ProtoParsers.put ( intent , com.android.dialer.calldetails.CallDetailsActivity.EXTRA_HEADER_INFO , com.android.dialer.common.Assert.isNotNull ( callDetailsHeaderInfo ) ) ; intent.putExtra ( com.android.dialer.calldetails.EXTRA_CAN_REPORT_CALLER_ID , canReportCallerId ) ; intent.putExtra ( com.android.dialer.calldetails.EXTRA_CAN_SUPPORT_ASSISTED_DIALING , canSupportAssistedDialing ) ; return intent ; }
Source:
public void testCanReadPeersMacAddressCurrentUserAndAllPermissions ( ) throws java.lang.Exception { boolean output = false ; mThrowSecurityException = false ; mUid = com.android.server.wifi.util.WifiPermissionsUtilTest.MANAGED_PROFILE_UID ; mPermissionsList.put ( mMacAddressPermission , mUid ) ; mWifiScanAllowApps = android.app.AppOpsManager.MODE_ALLOWED ; mCurrentUser = android.os.UserHandle.USER_CURRENT_OR_SELF ; setupTestCase ( ) ; com.android.server.wifi.util.WifiPermissionsUtil codeUnderTest = new com.android.server.wifi.util.WifiPermissionsUtil ( mMockPermissionsWrapper , mMockContext , mMockWifiSettingsStore , mMockUserManager ) ; try { output = codeUnderTest.canAccessScanResults ( com.android.server.wifi.util.WifiPermissionsUtilTest.TEST_PACKAGE_NAME , mUid , mTargetVersion ) ; } catch ( java.lang.SecurityException e ) { throw e ; } org.junit.Assert.assertEquals ( output , true ) ; }

Target:
public void testCanReadPeersMacAddressCurrentUserAndAllPermissions ( ) throws java.lang.Exception { boolean output = false ; mThrowSecurityException = false ; mUid = com.android.server.wifi.util.WifiPermissionsUtilTest.MANAGED_PROFILE_UID ; mPermissionsList.put ( mMacAddressPermission , mUid ) ; mWifiScanAllowApps = android.app.AppOpsManager.MODE_ALLOWED ; mCurrentUser = android.os.UserHandle.USER_CURRENT_OR_SELF ; setupTestCase ( ) ; com.android.server.wifi.util.WifiPermissionsUtil codeUnderTest = new com.android.server.wifi.util.WifiPermissionsUtil ( mMockPermissionsWrapper , mMockContext , mMockWifiSettingsStore , mMockUserManager , mNetworkScorerAppManager ) ; try { output = codeUnderTest.canAccessScanResults ( com.android.server.wifi.util.WifiPermissionsUtilTest.TEST_PACKAGE_NAME , mUid , mTargetVersion ) ; } catch ( java.lang.SecurityException e ) { throw e ; } org.junit.Assert.assertEquals ( output , true ) ; }
Source:
public static java.lang.StringBuilder formatAndAppend ( java.lang.String compiledPattern , java.lang.StringBuilder appendTo , int [ ] offsets , java.lang.CharSequence ... values ) { int valuesLength = ( values != null ) ? values.length : 0 ; if ( valuesLength < ( com.ibm.icu.impl.SimplePatternFormatter.getPlaceholderCount ( compiledPattern ) ) ) { throw new java.lang.IllegalArgumentException ( "Too few values." ) ; } return com.ibm.icu.impl.SimplePatternFormatter.format ( compiledPattern , values , appendTo , null , true , offsets ) ; }

Target:
public static java.lang.String formatCompiledPattern ( java.lang.String compiledPattern , java.lang.CharSequence ... values ) { return com.ibm.icu.impl.SimpleFormatterImpl.formatAndAppend ( compiledPattern , new java.lang.StringBuilder ( ) , null , values ) . toString ( ) ; }
Source:
public java.util.Set < ? extends javax.lang.model.element.Element > process ( com.google.common.collect.SetMultimap < java.lang.Class < ? extends java.lang.annotation.Annotation > , javax.lang.model.element.Element > elementsByAnnotation ) { for ( javax.lang.model.element.Element element : elementsByAnnotation.get ( com.android.dialer.rootcomponentgenerator.annotation.DialerRootComponent.class ) ) { generateRootComponent ( com.google.auto.common.MoreElements.asType ( element ) ) ; } return java.util.Collections.emptySet ( ) ; }

Target:
public java.util.Set < ? extends javax.lang.model.element.Element > process ( com.google.common.collect.SetMultimap < java.lang.Class < ? extends java.lang.annotation.Annotation > , javax.lang.model.element.Element > elementsByAnnotation ) { for ( javax.lang.model.element.Element element : elementsByAnnotation.get ( com.android.dialer.inject.DialerRootComponent.class ) ) { generateRootComponent ( com.google.auto.common.MoreElements.asType ( element ) ) ; } return java.util.Collections.emptySet ( ) ; }
Source:
private void clearInternal ( ) { java.util.Set < android.net.INetworkScoreCache > cachesToClear = getScoreCaches ( ) ; for ( android.net.INetworkScoreCache scoreCache : cachesToClear ) { try { scoreCache.clearScores ( ) ; } catch ( android.os.RemoteException e ) { if ( android.util.Log.isLoggable ( com.android.server.NetworkScoreService.TAG , Log.VERBOSE ) ) { android.util.Log.v ( com.android.server.NetworkScoreService.TAG , "Unable to clear scores" , e ) ; } } } }

Target:
private void clearInternal ( ) { sendCallback ( new java.util.function.Consumer < android.net.INetworkScoreCache > ( ) { @ java.lang.Override public void accept ( android.net.INetworkScoreCache networkScoreCache ) { try { networkScoreCache.clearScores ( ) ; } catch ( android.os.RemoteException e ) { if ( android.util.Log.isLoggable ( com.android.server.NetworkScoreService.TAG , Log.VERBOSE ) ) { android.util.Log.v ( com.android.server.NetworkScoreService.TAG , "Unable to clear scores" , e ) ; } } } } , getScoreCacheLists ( ) ) ; }
Source:
private boolean xorEquals ( java.lang.String first , java.lang.String second ) { return ( ( java.util.Objects.equals ( first , second ) ) || ( android.text.TextUtils.isEmpty ( first ) ) ) || ( android.text.TextUtils.isEmpty ( second ) ) ; }

Target:
private boolean isPhoneStateIdle ( ) { for ( int i = 0 ; i < ( android.telephony.TelephonyManager.getDefault ( ) . getPhoneCount ( ) ) ; i ++ ) { com.android.internal.telephony.Phone phone = com.android.internal.telephony.PhoneFactory.getPhone ( i ) ; if ( ( phone != null ) && ( ( phone.getState ( ) ) != ( PhoneConstants.State.IDLE ) ) ) { log ( ( "isPhoneStateIdle false: Voice call active on phone " + i ) ) ; return false ; } } return true ; }
Source:
public java.lang.String getVersionName ( ) { java.lang.String versionName = mMergedFlavor.getVersionName ( ) ; java.lang.String versionSuffix = mBuildType.getVersionNameSuffix ( ) ; if ( ( versionSuffix != null ) && ( ( versionSuffix.length ( ) ) > 0 ) ) { if ( versionName == null ) { versionName = getVersionNameFromManifest ( ) ; } versionName = versionName + versionSuffix ; } return versionName ; }

Target:
public java.lang.String getVersionName ( ) { java.lang.String versionName = mMergedFlavor.getVersionName ( ) ; java.lang.String versionSuffix = mBuildType.getVersionNameSuffix ( ) ; if ( ( versionSuffix != null ) && ( ( versionSuffix.length ( ) ) > 0 ) ) { if ( versionName == null ) { if ( ( mType ) != ( com.android.builder.VariantConfiguration.Type.TEST ) ) { versionName = getVersionNameFromManifest ( ) ; } else { versionName = "" ; } } versionName = versionName + versionSuffix ; } return versionName ; }
Source:
public void testResValuesMerge ( ) { com.android.builder.model.ProductFlavor productFlavor = mCustom.mergeOver ( mCustom2 ) ; java.util.Map < java.lang.String , com.android.builder.model.ClassField > resValues = productFlavor.getResValues ( ) ; assertEquals ( 3 , resValues.size ( ) ) ; assertEquals ( "oneValue" , resValues.get ( "one" ) . getValue ( ) ) ; assertEquals ( "twoValue" , resValues.get ( "two" ) . getValue ( ) ) ; assertEquals ( "threeValue" , resValues.get ( "three" ) . getValue ( ) ) ; }

Target:
public void testResValuesMerge ( ) { com.android.builder.model.ProductFlavor flavor = com.android.builder.core.DefaultProductFlavor.mergeFlavors ( mCustom2 , mCustom ) ; java.util.Map < java.lang.String , com.android.builder.model.ClassField > resValues = flavor.getResValues ( ) ; assertEquals ( 3 , resValues.size ( ) ) ; assertEquals ( "oneValue" , resValues.get ( "one" ) . getValue ( ) ) ; assertEquals ( "twoValue" , resValues.get ( "two" ) . getValue ( ) ) ; assertEquals ( "threeValue" , resValues.get ( "three" ) . getValue ( ) ) ; }
Source:
public void onNetworkResumed ( android.net.Network network ) { com.googlecode.android_scripting.Log.d ( "NetworkCallback onNetworkResumed" ) ; if ( ( ( mEvents ) & ( com.googlecode.android_scripting.facade.ConnectivityManagerFacade.NetworkCallback.EVENT_RESUMED ) ) == ( com.googlecode.android_scripting.facade.ConnectivityManagerFacade.NetworkCallback.EVENT_RESUMED ) ) { mEventFacade.postEvent ( ConnectivityConstants.EventNetworkCallback , new com.googlecode.android_scripting.facade.ConnectivityEvents.NetworkCallbackEventBase ( mId , com.googlecode.android_scripting.facade.ConnectivityManagerFacade.getNetworkCallbackEventString ( com.googlecode.android_scripting.facade.ConnectivityManagerFacade.NetworkCallback.EVENT_RESUMED ) ) ) ; } }

Target:
public void onNetworkResumed ( android.net.Network network ) { com.googlecode.android_scripting.Log.d ( "NetworkCallback onNetworkResumed" ) ; if ( ( ( mEvents ) & ( com.googlecode.android_scripting.facade.ConnectivityManagerFacade.NetworkCallback.EVENT_RESUMED ) ) == ( com.googlecode.android_scripting.facade.ConnectivityManagerFacade.NetworkCallback.EVENT_RESUMED ) ) { mEventFacade.postEvent ( TelephonyConstants.EventNetworkCallback , new com.googlecode.android_scripting.facade.telephony.TelephonyEvents.NetworkCallbackEvent ( mId , com.googlecode.android_scripting.facade.ConnectivityManagerFacade.getNetworkCallbackEventString ( com.googlecode.android_scripting.facade.ConnectivityManagerFacade.NetworkCallback.EVENT_RESUMED ) , TelephonyEvents.NetworkCallbackEvent.INVALID_VALUE , TelephonyEvents.NetworkCallbackEvent.INVALID_VALUE ) ) ; } }
Source:
private void handleSetCdmaSubscriptionMode ( android.os.Message msg ) { android.os.AsyncResult ar = ( ( android.os.AsyncResult ) ( msg.obj ) ) ; if ( ( ar.exception ) == null ) { int cdmaSubscriptionMode = java.lang.Integer.valueOf ( mButtonCdmaSubscription.getValue ( ) ) . intValue ( ) ; android.provider.Settings.System.putInt ( mPhone.getContext ( ) . getContentResolver ( ) , android.provider.Settings.System.CDMA_SUBSCRIPTION_MODE , cdmaSubscriptionMode ) ; } }

Target:
private void handleSetCdmaSubscriptionMode ( android.os.Message msg ) { mPhone = com.android.internal.telephony.PhoneFactory.getDefaultPhone ( ) ; android.os.AsyncResult ar = ( ( android.os.AsyncResult ) ( msg.obj ) ) ; if ( ( ar.exception ) == null ) { int cdmaSubscriptionMode = java.lang.Integer.valueOf ( mButtonCdmaSubscription.getValue ( ) ) . intValue ( ) ; android.provider.Settings.System.putInt ( mPhone.getContext ( ) . getContentResolver ( ) , android.provider.Settings.System.CDMA_SUBSCRIPTION_MODE , cdmaSubscriptionMode ) ; } }
Source:
public java.util.List < ? extends com.android.tools.idea.run.CloudConfiguration > getAllCloudConfigurations ( @ org.jetbrains.annotations.NotNull org.jetbrains.android.facet.AndroidFacet facet ) { java.util.List < com.google.gct.testing.CloudPersistentConfiguration > cloudPersistentConfigurations = com.google.gct.testing.CloudCustomPersistentConfigurations.getInstance ( facet.getModule ( ) ) . getState ( ) . myCloudPersistentConfigurations ; return com.google.common.collect.Lists.newArrayList ( com.google.common.collect.Iterables.concat ( com.google.gct.testing.CloudConfigurationProviderImpl.deserializeConfigurations ( cloudPersistentConfigurations , true , facet ) , getDefaultConfigurations ( facet , com.android.tools.idea.run.CloudConfiguration.Kind.MATRIX ) ) ) ; }

Target:
public java.util.List < ? extends com.android.tools.idea.run.CloudConfiguration > getAllCloudConfigurations ( @ org.jetbrains.annotations.NotNull org.jetbrains.android.facet.AndroidFacet facet ) { java.util.List < com.google.gct.testing.CloudPersistentConfiguration > cloudPersistentConfigurations = com.google.gct.testing.CloudCustomPersistentConfigurations.getInstance ( facet.getModule ( ) ) . getState ( ) . myCloudPersistentConfigurations ; return com.google.common.collect.Lists.newArrayList ( com.google.common.collect.Iterables.concat ( com.google.gct.testing.CloudConfigurationProviderImpl.deserializeConfigurations ( cloudPersistentConfigurations , true , facet ) , getDefaultConfigurations ( facet , com.android.tools.idea.run.CloudConfiguration.Kind.MATRIX ) , getDefaultConfigurations ( facet , com.android.tools.idea.run.CloudConfiguration.Kind.SINGLE_DEVICE ) ) ) ; }
Source:
protected org.eclipse.core.runtime.IStatus run ( org.eclipse.core.runtime.IProgressMonitor monitor ) { try { if ( project.isAccessible ( ) ) { project.deleteMarkers ( markerType , true , IResource.DEPTH_INFINITE ) ; } } catch ( org.eclipse.core.runtime.CoreException e2 ) { return e2.getStatus ( ) ; } return org.eclipse.core.runtime.Status.OK_STATUS ; }

Target:
protected org.eclipse.core.runtime.IStatus run ( org.eclipse.core.runtime.IProgressMonitor monitor ) { try { if ( project.isAccessible ( ) ) { project.deleteMarkers ( markerType , true , IResource.DEPTH_INFINITE ) ; } } catch ( org.eclipse.core.runtime.CoreException e2 ) { com.android.ide.eclipse.adt.AdtPlugin.log ( e2 , null ) ; } return org.eclipse.core.runtime.Status.OK_STATUS ; }
Source:
public static void main ( java.lang.String [ ] args ) { Main.assertByteEquals ( Main.getByte1 ( ) , ( ( byte ) ( - 5 ) ) ) ; Main.assertByteEquals ( Main.getByte2 ( ) , ( ( byte ) ( - 201 ) ) ) ; }

Target:
public static void main ( java.lang.String [ ] args ) { Main.assertByteEquals ( Main.getByte1 ( ) , ( ( byte ) ( - 5 ) ) ) ; Main.assertByteEquals ( Main.getByte2 ( ) , ( ( byte ) ( - 201 ) ) ) ; Main.assertByteEquals ( Main.getByte3 ( ) , ( ( byte ) ( 205 + 205 ) ) ) ; }
Source:
private libcore.util.ZoneInfo createZoneInfo ( int [ ] [ ] transitionTimes , int [ ] [ ] transitionTypes ) throws java.lang.Exception { return createZoneInfo ( getName ( ) , transitionTimes , transitionTypes , java.lang.System.currentTimeMillis ( ) ) ; }

Target:
public void testReadTimeZone_TooManyTransitions ( ) throws java.lang.Exception { libcore.util.ZoneInfoTestHelper.ZoneInfoDataBuilder builder = new libcore.util.ZoneInfoTestHelper.ZoneInfoDataBuilder ( ) ; builder.initializeToValid ( ) ; builder.setTransitionCountOverride ( 2001 ) ; byte [ ] bytes = builder.build ( ) ; try { createZoneInfo ( getName ( ) , java.lang.System.currentTimeMillis ( ) , bytes ) ; fail ( "Did not detect too many transitions" ) ; } catch ( java.io.IOException expected ) { } }
Source:
public boolean requestAssistContextExtras ( int requestType , com.android.internal.os.IResultReceiver receiver , android.os.IBinder activityToken ) { return ( enqueueAssistContext ( requestType , null , null , receiver , activityToken , android.os.UserHandle.getCallingUserId ( ) , null , com.android.server.am.ActivityManagerService.PENDING_ASSIST_EXTRAS_LONG_TIMEOUT ) ) != null ; }

Target:
public boolean requestAssistContextExtras ( int requestType , com.android.internal.os.IResultReceiver receiver , android.os.Bundle receiverExtras , android.os.IBinder activityToken , boolean focused , boolean newSessionId ) { return ( enqueueAssistContext ( requestType , null , null , receiver , receiverExtras , activityToken , focused , newSessionId , android.os.UserHandle.getCallingUserId ( ) , null , com.android.server.am.ActivityManagerService.PENDING_ASSIST_EXTRAS_LONG_TIMEOUT ) ) != null ; }
Source:
public boolean reportError ( byte error ) { android.util.Log.v ( android.bluetooth.BluetoothInputHost.TAG , ( "reportError(): error = " + error ) ) ; boolean result = false ; if ( ( mService ) != null ) { try { result = mService.reportError ( error ) ; } catch ( android.os.RemoteException e ) { android.util.Log.e ( android.bluetooth.BluetoothInputHost.TAG , e.toString ( ) ) ; } } else { android.util.Log.w ( android.bluetooth.BluetoothInputHost.TAG , "Proxy not attached to service" ) ; } return result ; }

Target:
public boolean reportError ( android.bluetooth.BluetoothDevice device , byte error ) { android.util.Log.v ( android.bluetooth.BluetoothInputHost.TAG , ( ( ( "reportError(): device=" + device ) + " error=" ) + error ) ) ; boolean result = false ; if ( ( mService ) != null ) { try { result = mService.reportError ( device , error ) ; } catch ( android.os.RemoteException e ) { android.util.Log.e ( android.bluetooth.BluetoothInputHost.TAG , e.toString ( ) ) ; } } else { android.util.Log.w ( android.bluetooth.BluetoothInputHost.TAG , "Proxy not attached to service" ) ; } return result ; }
Source:
public java.lang.String getColumnText ( java.lang.Object element , int columnIndex ) { if ( element instanceof com.android.tools.lint.detector.api.Category ) { if ( columnIndex == 0 ) { return ( ( com.android.tools.lint.detector.api.Category ) ( element ) ) . getFullName ( ) ; } else { return null ; } } com.android.tools.lint.detector.api.Issue issue = ( ( com.android.tools.lint.detector.api.Issue ) ( element ) ) ; switch ( columnIndex ) { case 0 : return issue.getId ( ) ; case 1 : return issue.getDescription ( com.android.tools.lint.detector.api.Issue.OutputFormat.TEXT ) ; } return null ; }

Target:
public java.lang.String getColumnText ( java.lang.Object element , int columnIndex ) { if ( element instanceof com.android.tools.lint.detector.api.Category ) { if ( columnIndex == 0 ) { return ( ( com.android.tools.lint.detector.api.Category ) ( element ) ) . getFullName ( ) ; } else { return null ; } } com.android.tools.lint.detector.api.Issue issue = ( ( com.android.tools.lint.detector.api.Issue ) ( element ) ) ; switch ( columnIndex ) { case 0 : return issue.getId ( ) ; case 1 : return issue.getBriefDescription ( com.android.tools.lint.detector.api.TextFormat.TEXT ) ; } return null ; }
Source:
public void putAll ( java.util.Map < ? extends K , ? extends V > m ) { for ( java.util.Map.Entry < ? extends K , ? extends V > e : m.entrySet ( ) ) put ( e.getKey ( ) , e.getValue ( ) ) ; }

Target:
public boolean remove ( java.lang.Object key , java.lang.Object value ) { if ( key == null ) throw new java.lang.NullPointerException ( ) ; return ( value != null ) && ( ( replaceNode ( key , null , value ) ) != null ) ; }
Source:
public void dispose ( @ com.android.annotations.NonNull com.android.tools.lint.detector.api.JavaContext context , @ com.android.annotations.NonNull lombok.ast.Node compilationUnit ) { }

Target:
public void dispose ( @ com.android.annotations.NonNull com.android.tools.lint.detector.api.JavaContext context , @ com.android.annotations.NonNull lombok.ast.Node compilationUnit ) { if ( ( ( mSourceUnits ) != null ) && ( ( mCompiled ) != null ) ) { org.eclipse.jdt.internal.compiler.env.ICompilationUnit sourceUnit = mSourceUnits.get ( context.file ) ; if ( sourceUnit != null ) { mSourceUnits.remove ( context.file ) ; mCompiled.remove ( sourceUnit ) ; } } }
Source:
public void stopEditors ( ) { com.android.ide.eclipse.adt.AdtPlugin.sAndroidLogo.dispose ( ) ; com.android.ide.eclipse.adt.internal.editors.IconFactory.getInstance ( ) . dispose ( ) ; org.eclipse.core.resources.IWorkspace ws = org.eclipse.core.resources.ResourcesPlugin.getWorkspace ( ) ; com.android.ide.eclipse.adt.internal.resources.manager.GlobalProjectMonitor.stopMonitoring ( ws ) ; if ( ( mRed ) != null ) { mRed.dispose ( ) ; mRed = null ; } }

Target:
public void stopEditors ( ) { com.android.ide.eclipse.adt.AdtPlugin.sAndroidLogo.dispose ( ) ; com.android.ide.eclipse.adt.internal.editors.IconFactory.getInstance ( ) . dispose ( ) ; com.android.ide.eclipse.adt.internal.lint.LintDeltaProcessor.stopListening ( mResourceMonitor ) ; org.eclipse.core.resources.IWorkspace ws = org.eclipse.core.resources.ResourcesPlugin.getWorkspace ( ) ; com.android.ide.eclipse.adt.internal.resources.manager.GlobalProjectMonitor.stopMonitoring ( ws ) ; if ( ( mRed ) != null ) { mRed.dispose ( ) ; mRed = null ; } }