auphong2707/dl4se-code-review-dataset huggingface dataset:
Source:
public boolean processMessage ( android.os.Message msg ) { if ( com.android.server.wifi.nan.WifiNanStateManager.VDBG ) { android.util.Log.v ( com.android.server.wifi.nan.WifiNanStateManager.TAG , ( ( getName ( ) ) + ( msg.toString ( ) ) ) ) ; } switch ( msg.what ) { case com.android.server.wifi.nan.WifiNanStateManager.MESSAGE_TYPE_COMMAND : if ( processCommand ( msg ) ) { transitionTo ( mWaitForResponseState ) ; } return HANDLED ; case com.android.server.wifi.nan.WifiNanStateManager.MESSAGE_TYPE_RESPONSE : case com.android.server.wifi.nan.WifiNanStateManager.MESSAGE_TYPE_RESPONSE_TIMEOUT : deferMessage ( msg ) ; return HANDLED ; default : } return NOT_HANDLED ; }

Target:
public boolean processMessage ( android.os.Message msg ) { if ( com.android.server.wifi.aware.WifiAwareStateManager.VDBG ) { android.util.Log.v ( com.android.server.wifi.aware.WifiAwareStateManager.TAG , ( ( getName ( ) ) + ( msg.toString ( ) ) ) ) ; } switch ( msg.what ) { case com.android.server.wifi.aware.WifiAwareStateManager.MESSAGE_TYPE_COMMAND : if ( processCommand ( msg ) ) { transitionTo ( mWaitForResponseState ) ; } return HANDLED ; case com.android.server.wifi.aware.WifiAwareStateManager.MESSAGE_TYPE_RESPONSE : case com.android.server.wifi.aware.WifiAwareStateManager.MESSAGE_TYPE_RESPONSE_TIMEOUT : deferMessage ( msg ) ; return HANDLED ; default : } return NOT_HANDLED ; }
Source:
public void setComment ( java.lang.String comment ) { if ( ( comment.length ( ) ) > 65535 ) { throw new java.lang.IllegalArgumentException ( ( ( "Comment too long: " + ( comment.length ( ) ) ) + " characters" ) ) ; } this . comment = comment ; }

Target:
public void setComment ( java.lang.String comment ) { if ( comment == null ) { this . commentBytes = null ; return ; } byte [ ] newCommentBytes = comment.getBytes ( Charsets.UTF_8 ) ; if ( ( newCommentBytes.length ) > 65535 ) { throw new java.lang.IllegalArgumentException ( ( ( "Comment too long: " + ( newCommentBytes.length ) ) + " bytes" ) ) ; } this . commentBytes = newCommentBytes ; }
Source:
public static java.security.Signature getInstance ( java.lang.String algorithm , java.lang.String provider ) throws java.security.NoSuchAlgorithmException , java.security.NoSuchProviderException { if ( algorithm == null ) { throw new java.lang.NullPointerException ( "algorithm == null" ) ; } if ( ( provider == null ) || ( provider.isEmpty ( ) ) ) { throw new java.lang.IllegalArgumentException ( ) ; } java.security.Provider p = java.security.Security.getProvider ( provider ) ; if ( p == null ) { throw new java.security.NoSuchProviderException ( provider ) ; } return java.security.Signature.getSignatureInstance ( algorithm , p ) ; }

Target:
public static java.security.Signature getInstance ( java.lang.String algorithm , java.lang.String provider ) throws java.security.NoSuchAlgorithmException , java.security.NoSuchProviderException { if ( algorithm == null ) { throw new java.lang.NullPointerException ( "algorithm == null" ) ; } if ( ( provider == null ) || ( provider.isEmpty ( ) ) ) { throw new java.lang.IllegalArgumentException ( ) ; } java.security.Provider p = java.security.Security.getProvider ( provider ) ; if ( p == null ) { throw new java.security.NoSuchProviderException ( provider ) ; } return java.security.Signature.getSignature ( algorithm , p ) ; }
Source:
public void testCdmaEnhancedPrivacyVoiceCall ( ) throws java.lang.Exception { mConnectionServiceFixtureA.mConnectionServiceDelegate.mProperties = android.telecom.Connection.PROPERTY_HAS_CDMA_VOICE_PRIVACY ; com.android.server.telecom.tests.IdPair ids = startAndMakeActiveOutgoingCall ( "650-555-1212" , mPhoneAccountA0.getAccountHandle ( ) , mConnectionServiceFixtureA ) ; assertEquals ( Call.STATE_ACTIVE , mInCallServiceFixtureX.getCall ( ids.mCallId ) . getState ( ) ) ; assertTrue ( Call.Details.hasProperty ( mInCallServiceFixtureX.getCall ( ids.mCallId ) . getProperties ( ) , Call.Details.PROPERTY_HAS_CDMA_VOICE_PRIVACY ) ) ; }

Target:
public void testCdmaEnhancedPrivacyVoiceCall ( ) throws java.lang.Exception { mConnectionServiceFixtureA.mConnectionServiceDelegate.mProperties = android.telecom.Connection.PROPERTY_HAS_CDMA_VOICE_PRIVACY ; com.android.server.telecom.tests.IdPair ids = startAndMakeActiveOutgoingCall ( "650-555-1212" , mPhoneAccountA0.getAccountHandle ( ) , mConnectionServiceFixtureA ) ; org.junit.Assert.assertEquals ( Call.STATE_ACTIVE , mInCallServiceFixtureX.getCall ( ids.mCallId ) . getState ( ) ) ; org.junit.Assert.assertTrue ( Call.Details.hasProperty ( mInCallServiceFixtureX.getCall ( ids.mCallId ) . getProperties ( ) , Call.Details.PROPERTY_HAS_CDMA_VOICE_PRIVACY ) ) ; }
Source:
public java.lang.Void get ( ) throws java.lang.InterruptedException , java.util.concurrent.ExecutionException { try { return get ( 5 , java.util.concurrent.TimeUnit.SECONDS ) ; } catch ( java.util.concurrent.TimeoutException e ) { throw new java.lang.RuntimeException ( e ) ; } }

Target:
android.net.INetworkPolicyListener waitAndVerify ( ) { assertNotNull ( "waitAndVerify() called before expect()" , latch ) ; try { assertTrue ( "callback not called in 5 seconds" , latch.await ( 5 , java.util.concurrent.TimeUnit.SECONDS ) ) ; } catch ( java.lang.InterruptedException e ) { fail ( "Thread interrupted before callback called" ) ; } finally { latch = null ; } return org.mockito.Mockito.verify ( listener , org.mockito.Mockito.atLeastOnce ( ) ) ; }
Source:
public java.io.File getJarJarRuleFile ( ) { return ( mBuildType.getJarJarRuleFile ( ) ) != null ? mBuildType.getJarJarRuleFile ( ) : getMergedFlavor ( ) . getJarJarRuleFile ( ) ; }

Target:
public java.util.Map < java.lang.String , java.lang.String > getInstrumentationRunnerArguments ( ) { com.android.builder.core.VariantConfiguration config = this ; if ( mType.isForTesting ( ) ) { config = getTestedConfig ( ) ; com.google.common.base.Preconditions.checkState ( ( config != null ) ) ; } java.util.Map < java.lang.String , java.lang.String > runner = config.mMergedFlavor.getTestInstrumentationRunnerArguments ( ) ; return runner != null ? runner : com.google.common.collect.ImmutableMap.< java.lang.String , java.lang.String > of ( ) ; }
Source:
private static void assertImeiDeviceId ( java.lang.String deviceId ) { android.telephony.cts.TelephonyManagerTest.assertImeiFormat ( deviceId ) ; android.telephony.cts.TelephonyManagerTest.assertImeiCheckDigit ( deviceId ) ; android.telephony.cts.TelephonyManagerTest.assertReportingBodyIdentifier ( deviceId , true ) ; }

Target:
private static void assertGsmDeviceId ( java.lang.String deviceId ) { java.lang.String imeiPattern = "[0-9]{14,15}" ; assertTrue ( ( ( ( "IMEI device id " + deviceId ) + " does not match pattern " ) + imeiPattern ) , java.util.regex.Pattern.matches ( imeiPattern , deviceId ) ) ; if ( ( deviceId.length ( ) ) == 15 ) { android.telephony.cts.TelephonyManagerTest.assertImeiCheckDigit ( deviceId ) ; } }
Source:
public void goToUnlockScreen ( ) { final com.android.internal.telephony.IccCard.State simState = mUpdateMonitor.getSimState ( ) ; if ( ( stuckOnLockScreenBecauseSimMissing ( ) ) || ( simState == ( IccCard.State.PUK_REQUIRED ) ) ) { return ; } if ( ! ( isSecure ( ) ) ) { getCallback ( ) . keyguardDone ( true ) ; } else { updateScreen ( com.android.internal.policy.impl.LockPatternKeyguardView.Mode.UnlockScreen ) ; } }

Target:
public void forgotPattern ( boolean isForgotten ) { if ( mEnableFallback ) { mForgotPattern = isForgotten ; updateScreen ( com.android.internal.policy.impl.LockPatternKeyguardView.Mode.UnlockScreen ) ; } }
Source:
static void deadSequence ( ) { int dead = 0 ; for ( int i = 0 ; i < ( Main.a.length ) ; i ++ ) { Main.a [ i ] = 3 ; dead += i ; } }

Target:
static void deadSequence ( ) { int dead = 0 ; for ( int i = 0 ; i < ( Main.a.length ) ; i ++ ) { Main.a [ i ] = ( Main.novec [ ( 2 * i ) ] ) + 3 ; dead += i ; } }
Source:
public java.util.List < sun.security.x509.AVA > allAvas ( ) { java.util.List < sun.security.x509.AVA > list = allAvaList ; if ( list == null ) { list = new java.util.ArrayList < sun.security.x509.AVA > ( ) ; for ( int i = 0 ; i < ( names.length ) ; i ++ ) { list.addAll ( names [ i ] . avas ( ) ) ; } } return list ; }

Target:
public java.util.List < sun.security.x509.AVA > allAvas ( ) { java.util.List < sun.security.x509.AVA > list = allAvaList ; if ( list == null ) { list = new java.util.ArrayList < sun.security.x509.AVA > ( ) ; for ( int i = 0 ; i < ( names.length ) ; i ++ ) { list.addAll ( names [ i ] . avas ( ) ) ; } list = java.util.Collections.unmodifiableList ( list ) ; allAvaList = list ; } return list ; }
Source:
public void dataCallListChanged ( int indicationType , java.util.ArrayList < android.hardware.radio.V1_0.SetupDataCallResult > dcList ) { mRil.processIndication ( indicationType ) ; java.util.ArrayList < android.telephony.data.DataCallResponse > response = new java.util.ArrayList < > ( ) ; for ( android.hardware.radio.V1_0.SetupDataCallResult dcResult : dcList ) { response.add ( com.android.internal.telephony.RIL.convertDataCallResult ( dcResult ) ) ; } if ( RIL.RILJ_LOGD ) mRil.unsljLogRet ( com.android.internal.telephony.RILConstants.RIL_UNSOL_DATA_CALL_LIST_CHANGED , response ) ; mRil.mDataCallListChangedRegistrants.notifyRegistrants ( new android.os.AsyncResult ( null , response , null ) ) ; }

Target:
public void currentSignalStrength_1_2 ( int indicationType , com.android.internal.telephony.V1_2.SignalStrength signalStrength ) { mRil.processIndication ( indicationType ) ; android.telephony.SignalStrength ss = com.android.internal.telephony.RIL.convertHalSignalStrength_1_2 ( signalStrength ) ; if ( RIL.RILJ_LOGV ) mRil.unsljLogvRet ( com.android.internal.telephony.RILConstants.RIL_UNSOL_SIGNAL_STRENGTH , ss ) ; if ( ( mRil.mSignalStrengthRegistrant ) != null ) { mRil.mSignalStrengthRegistrant.notifyRegistrant ( new android.os.AsyncResult ( null , ss , null ) ) ; } }
Source:
public static void create ( android.content.Context context ) { context = context.getApplicationContext ( ) ; if ( ( org.chromium.base.PowerMonitor.sInstance ) == null ) { org.chromium.base.PowerMonitor.sInstance = org.chromium.base.PowerMonitor.LazyHolder.INSTANCE ; org.chromium.base.ApplicationStatus.registerApplicationStateListener ( org.chromium.base.PowerMonitor.sInstance ) ; android.content.IntentFilter ifilter = new android.content.IntentFilter ( android.content.Intent.ACTION_BATTERY_CHANGED ) ; android.content.Intent batteryStatusIntent = context.registerReceiver ( null , ifilter ) ; if ( batteryStatusIntent != null ) org.chromium.base.PowerMonitor.onBatteryChargingChanged ( batteryStatusIntent ) ; } }

Target:
private static void onBatteryChargingChanged ( android.content.Intent intent ) { assert ( org.chromium.base.PowerMonitor.sInstance ) != null ; int chargePlug = intent.getIntExtra ( BatteryManager.EXTRA_PLUGGED , ( - 1 ) ) ; org.chromium.base.PowerMonitor.sInstance.mIsBatteryPower = ( chargePlug != ( android.os.BatteryManager.BATTERY_PLUGGED_USB ) ) && ( chargePlug != ( android.os.BatteryManager.BATTERY_PLUGGED_AC ) ) ; org.chromium.base.PowerMonitor.nativeOnBatteryChargingChanged ( ) ; }
Source:
void copy2DRangeFromUnchecked ( int xoff , int yoff , int w , int h , int [ ] data ) { mRS.validate ( ) ; validate2DRange ( xoff , yoff , w , h ) ; mRS.nAllocationData2D ( getIDSafe ( ) , xoff , yoff , mSelectedLOD , mSelectedFace.mID , w , h , data , ( ( data.length ) * 4 ) ) ; }

Target:
public void copy2DRangeFrom ( int xoff , int yoff , int w , int h , short [ ] data ) { validateIsInt16 ( ) ; copy2DRangeFromUnchecked ( xoff , yoff , w , h , data , Element.DataType.SIGNED_16 , data.length ) ; }
Source:
protected void syncWithBuildFile ( ) { com.google.gct.idea.appengine.gradle.facet.AppEngineGradleFacet facet = com.google.gct.idea.appengine.gradle.facet.AppEngineGradleFacet.getInstance ( moduleSelector.getModule ( ) ) ; if ( facet != null ) { com.google.gct.idea.appengine.gradle.facet.AppEngineConfigurationProperties model = facet.getConfiguration ( ) . getState ( ) ; if ( model != null ) { myServerPortField.setText ( model.HTTP_PORT.toString ( ) ) ; myServerAddressField.setText ( model.HTTP_ADDRESS ) ; myAppEngineSdkField.setText ( model.APPENGINE_SDKROOT ) ; myWarPathField.setText ( model.WAR_DIR ) ; } } }

Target:
protected void syncWithBuildFile ( ) { com.google.gct.idea.appengine.gradle.facet.AppEngineGradleFacet facet = com.google.gct.idea.appengine.gradle.facet.AppEngineGradleFacet.getInstance ( moduleSelector.getModule ( ) ) ; if ( facet != null ) { com.google.gct.idea.appengine.gradle.facet.AppEngineConfigurationProperties model = facet.getConfiguration ( ) . getState ( ) ; if ( model != null ) { myServerPortField.setText ( model.HTTP_PORT.toString ( ) ) ; myServerAddressField.setText ( model.HTTP_ADDRESS ) ; myAppEngineSdkField.setText ( model.APPENGINE_SDKROOT ) ; myWarPathField.setText ( model.WAR_DIR ) ; myVmArgsField.setText ( model.getJvmFlags ( ) ) ; } } }
Source:
public org.apache.harmony.security.x509.Extension getExtensionByOID ( java.lang.String oid ) { if ( ( extensions ) == null ) { return null ; } if ( ( oidMap ) == null ) { oidMap = new java.util.HashMap < java.lang.String , org.apache.harmony.security.x509.Extension > ( ) ; for ( org.apache.harmony.security.x509.Extension extension : extensions ) { oidMap.put ( extension.getExtnID ( ) , extension ) ; } } return oidMap.get ( oid ) ; }

Target:
public org.apache.harmony.security.x509.Extension getExtensionByOID ( java.lang.String oid ) { if ( ( extensions ) == null ) { return null ; } java.util.HashMap < java.lang.String , org.apache.harmony.security.x509.Extension > localOidMap = oidMap ; if ( localOidMap == null ) { localOidMap = new java.util.HashMap < java.lang.String , org.apache.harmony.security.x509.Extension > ( ) ; for ( org.apache.harmony.security.x509.Extension extension : extensions ) { localOidMap.put ( extension.getExtnID ( ) , extension ) ; } this . oidMap = localOidMap ; } return localOidMap.get ( oid ) ; }
Source:
public static java.lang.Iterable < java.lang.Object [ ] > data ( ) { java.util.List < java.lang.Object [ ] > params = new java.util.ArrayList < > ( ) ; for ( com.android.graphics.benchmark.ApkInfo apk : com.android.graphics.benchmark.ApkInfo.values ( ) ) { params.add ( new java.lang.Object [ ] { apk.name ( ) , apk } ) ; } return params ; }

Target:
public static java.lang.Iterable < java.lang.Object [ ] > data ( ) throws java.io.IOException , javax.xml.parsers.ParserConfigurationException , org.xml.sax.SAXException { java.util.List < java.lang.Object [ ] > params = new java.util.ArrayList < > ( ) ; com.android.graphics.benchmark.ApkListXmlParser parser = new com.android.graphics.benchmark.ApkListXmlParser ( new java.io.File ( com.android.graphics.benchmark.ApkInfo.APK_LIST_LOCATION ) ) ; java.util.List < com.android.graphics.benchmark.ApkInfo > apks = parser.parse ( ) ; for ( com.android.graphics.benchmark.ApkInfo apk : apks ) { params.add ( new java.lang.Object [ ] { apk.getName ( ) , apk } ) ; } return params ; }
Source:
public static void assertArrayEquals ( java.lang.String message , long [ ] expecteds , long [ ] actuals ) { java.lang.String expectedString = java.util.Arrays.toString ( expecteds ) ; java.lang.String actualString = java.util.Arrays.toString ( actuals ) ; if ( ! ( expectedString.equals ( actualString ) ) ) { fail ( message , ( ( ( "expected " + expectedString ) + " but was " ) + actualString ) ) ; } }

Target:
public static void assertArrayEquals ( java.lang.String message , int [ ] expecteds , int [ ] actuals ) { java.lang.String expectedString = java.util.Arrays.toString ( expecteds ) ; java.lang.String actualString = java.util.Arrays.toString ( actuals ) ; if ( ! ( expectedString.equals ( actualString ) ) ) { org.junit.Assert.fail ( message , ( ( ( "expected " + expectedString ) + " but was " ) + actualString ) ) ; } }
Source:
private static java.lang.String normalizeAndValidateLanguage ( java.lang.String language ) { if ( ( language == null ) || ( language.isEmpty ( ) ) ) { return "" ; } 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 ) ) ; } return lowercaseLanguage ; }

Target:
private static java.lang.String normalizeAndValidateLanguage ( java.lang.String language , boolean strict ) { if ( ( language == null ) || ( language.isEmpty ( ) ) ) { return "" ; } final java.lang.String lowercaseLanguage = language.toLowerCase ( java.util.Locale.ROOT ) ; if ( ! ( java.util.Locale.isValidBcp47Alpha ( lowercaseLanguage , 2 , 3 ) ) ) { if ( strict ) { throw new java.util.IllformedLocaleException ( ( "Invalid language: " + language ) ) ; } else { return java.util.Locale.UNDETERMINED_LANGUAGE ; } } return lowercaseLanguage ; }
Source:
public void validateUserCredentialWithoutAuthMethod ( ) throws java.lang.Exception { android.net.wifi.hotspot2.pps.Credential cred = new android.net.wifi.hotspot2.pps.Credential ( ) ; cred.realm = "realm" ; cred.userCredential = new android.net.wifi.hotspot2.pps.Credential.UserCredential ( ) ; cred.userCredential.username = "username" ; cred.userCredential.password = "password" ; cred.userCredential.eapType = android.net.wifi.EAPConstants.EAP_TTLS ; cred.caCertificate = android.net.wifi.FakeKeys.CA_CERT0 ; org.junit.Assert.assertFalse ( cred.validate ( ) ) ; }

Target:
public void validateCertCredentialWithoutClientCertChain ( ) throws java.lang.Exception { android.net.wifi.hotspot2.pps.Credential cred = android.net.wifi.hotspot2.pps.CredentialTest.createCredentialWithCertificateCredential ( ) ; cred.setClientCertificateChain ( null ) ; org.junit.Assert.assertFalse ( cred.validate ( ) ) ; }
Source:
, @ dalvik.annotation.TestTargetNew ( level = dalvik.annotation.TestLevel.COMPLETE , method = "setBlockNetworkImage" , args = { boolean . class } ) } ) public void testAccessBlockNetworkImage ( ) throws java.lang.Exception { java.lang.String url = TestHtmlConstants.EMBEDDED_IMG_URL ; java.lang.String ext = android.webkit.MimeTypeMap.getFileExtensionFromUrl ( url ) ; mWebView.clearCache ( true ) ; assertFalse ( mSettings.getBlockNetworkImage ( ) ) ; assertTrue ( mSettings.getLoadsImagesAutomatically ( ) ) ; loadAssetUrl ( url ) ; assertFalse ( mWebServer.getLastRequestUrl ( ) . endsWith ( ext ) ) ; }

Target:
protected boolean check ( ) { return ! ( mWebServer.getLastRequestUrl ( ) . endsWith ( ext ) ) ; }
Source:
public < T > T [ ] toArray ( T [ ] array ) { return standardToArray ( array ) ; }

Target:
public static < K , V > java.util.Map < K , java.util.List < V > > asMap ( com.google.common.collect.ListMultimap < K , V > multimap ) { return ( ( java.util.Map < K , java.util.List < V > > ) ( ( java.util.Map < K , ? > ) ( multimap.asMap ( ) ) ) ) ; }
Source:
private android.hardware.cts.helpers.sensorverification.ISensorVerification getVerification ( double lowerThreshold , double upperThreshold , long ... timestamps ) { android.hardware.cts.helpers.sensorverification.ISensorVerification verification = new android.hardware.cts.helpers.sensorverification.FrequencyVerification ( lowerThreshold , upperThreshold ) ; for ( long timestamp : timestamps ) { verification.addSensorEvent ( new android.hardware.cts.helpers.TestSensorEvent ( null , timestamp , 0 , null ) ) ; } return verification ; }

Target:
private static android.hardware.cts.helpers.sensorverification.FrequencyVerification getVerification ( double lowerThreshold , double upperThreshold , long ... timestamps ) { java.util.Collection < android.hardware.cts.helpers.TestSensorEvent > events = new java.util.ArrayList < > ( timestamps.length ) ; for ( long timestamp : timestamps ) { events.add ( new android.hardware.cts.helpers.TestSensorEvent ( null , timestamp , 0 , null ) ) ; } android.hardware.cts.helpers.sensorverification.FrequencyVerification verification = new android.hardware.cts.helpers.sensorverification.FrequencyVerification ( lowerThreshold , upperThreshold ) ; verification.addSensorEvents ( events ) ; return verification ; }
Source:
java.lang.String getDefaultAttrs ( org.eclipse.core.resources.IProject project ) { com.android.ide.eclipse.adt.internal.sdk.Sdk currentSdk = com.android.ide.eclipse.adt.internal.sdk.Sdk.getCurrent ( ) ; if ( currentSdk != null ) { com.android.sdklib.IAndroidTarget target = currentSdk.getTarget ( project ) ; if ( ( target != null ) && ( ( target.getVersion ( ) . getApiLevel ( ) ) >= 8 ) ) { return "android:layout_width=\"match_parent\"\n" + "android:layout_height=\"match_parent\"" ; } } return "android:layout_width=\"fill_parent\"\n" + "android:layout_height=\"fill_parent\"" ; }

Target:
java.lang.String getDefaultAttrs ( org.eclipse.core.resources.IProject project ) { com.android.ide.eclipse.adt.internal.sdk.Sdk currentSdk = com.android.ide.eclipse.adt.internal.sdk.Sdk.getCurrent ( ) ; java.lang.String fill = com.android.ide.common.layout.LayoutConstants.VALUE_FILL_PARENT ; if ( currentSdk != null ) { com.android.sdklib.IAndroidTarget target = currentSdk.getTarget ( project ) ; if ( ( target != null ) && ( ( target.getVersion ( ) . getApiLevel ( ) ) >= 8 ) ) { fill = com.android.ide.common.layout.LayoutConstants.VALUE_MATCH_PARENT ; } } return java.lang.String.format ( ( "android:orientation=\"vertical\"\n" + ( "android:layout_width=\"%1$s\"\n" + "android:layout_height=\"%1$s\"" ) ) , fill , fill ) ; }
Source:
public void copy1DRangeFromUnchecked ( int off , int count , short [ ] d ) { int dataSize = ( mType.mElement.getBytesSize ( ) ) * count ; data1DChecks ( off , count , ( ( d.length ) * 2 ) , dataSize ) ; mRS.nAllocationData1D ( getIDSafe ( ) , off , mSelectedLOD , count , d , dataSize ) ; }

Target:
public void copy1DRangeFrom ( int off , int count , short [ ] d ) { validateIsInt16 ( ) ; copy1DRangeFromUnchecked ( off , count , d , Element.DataType.SIGNED_16 , d.length ) ; }
Source:
private void handleTimeout ( com.android.server.NotificationManagerService.ToastRecord record ) { if ( com.android.server.NotificationManagerService.DBG ) android.util.Log.d ( com.android.server.NotificationManagerService.TAG , ( ( ( "Timeout pkg=" + ( record.pkg ) ) + " callback=" ) + ( record.callback ) ) ) ; synchronized ( mToastQueue ) { int index = indexOfToastLocked ( record.pkg , record.callback ) ; if ( index >= 0 ) { cancelToastLocked ( index ) ; } } }

Target:
private void handleTimeout ( com.android.server.NotificationManagerService.ToastRecord record ) { if ( com.android.server.NotificationManagerService.DBG ) android.util.Slog.d ( com.android.server.NotificationManagerService.TAG , ( ( ( "Timeout pkg=" + ( record.pkg ) ) + " callback=" ) + ( record.callback ) ) ) ; synchronized ( mToastQueue ) { int index = indexOfToastLocked ( record.pkg , record.callback ) ; if ( index >= 0 ) { cancelToastLocked ( index ) ; } } }
Source:
public void add ( java.lang.String fileName , java.lang.String jarName ) { java.lang.String packageName ; int pos ; if ( ( pos = fileName.lastIndexOf ( "/" ) ) != ( - 1 ) ) { packageName = fileName.substring ( 0 , pos ) ; } else { packageName = fileName ; } addToList ( packageName , jarName , indexMap ) ; addToList ( jarName , packageName , jarMap ) ; }

Target:
private void addMapping ( java.lang.String jarItem , java.lang.String jarName ) { addToList ( jarItem , jarName , indexMap ) ; addToList ( jarName , jarItem , jarMap ) ; }
Source:
public boolean shouldOverrideKeyEvent ( android.view.KeyEvent event ) { if ( ! ( org.chromium.content.browser.ContentViewClient.shouldPropagateKey ( event.getKeyCode ( ) ) ) ) return true ; org.chromium.base.TraceEvent.begin ( ) ; if ( com.android.webview.chromium.WebViewContentsClientAdapter.TRACE ) android.util.Log.d ( com.android.webview.chromium.WebViewContentsClientAdapter.TAG , "shouldOverrideKeyEvent" ) ; boolean result = mWebViewClient.shouldOverrideKeyEvent ( mWebView , event ) ; org.chromium.base.TraceEvent.end ( ) ; return result ; }

Target:
public boolean shouldOverrideKeyEvent ( android.view.KeyEvent event ) { try { org.chromium.base.TraceEvent.begin ( "WebViewContentsClientAdapter.shouldOverrideKeyEvent" ) ; if ( ! ( org.chromium.content.browser.ContentViewClient.shouldPropagateKey ( event.getKeyCode ( ) ) ) ) return true ; if ( com.android.webview.chromium.WebViewContentsClientAdapter.TRACE ) android.util.Log.d ( com.android.webview.chromium.WebViewContentsClientAdapter.TAG , "shouldOverrideKeyEvent" ) ; boolean result = mWebViewClient.shouldOverrideKeyEvent ( mWebView , event ) ; return result ; } finally { org.chromium.base.TraceEvent.end ( "WebViewContentsClientAdapter.shouldOverrideKeyEvent" ) ; } }
Source:
private java.util.Vector < java.lang.ThreadGroup > buildRandomTreeUnder ( java.lang.ThreadGroup aGroup , int depth ) { java.util.Vector < java.lang.ThreadGroup > result = asyncBuildRandomTreeUnder ( aGroup , depth ) ; while ( true ) { int sizeBefore = result.size ( ) ; try { java.lang.Thread.sleep ( 1000 ) ; int sizeAfter = result.size ( ) ; if ( sizeBefore == sizeAfter ) { if ( ( aGroup.activeCount ( ) ) == 0 ) { break ; } } } catch ( java.lang.InterruptedException e ) { } } return result ; }

Target:
private static java.util.Vector < java.lang.ThreadGroup > buildRandomTreeUnder ( java.lang.ThreadGroup aGroup , int depth ) { java.util.Vector < java.lang.ThreadGroup > result = org.apache.harmony.tests.java.lang.ThreadGroupTest.asyncBuildRandomTreeUnder ( aGroup , depth ) ; while ( true ) { int sizeBefore = result.size ( ) ; try { java.lang.Thread.sleep ( 1000 ) ; int sizeAfter = result.size ( ) ; if ( sizeBefore == sizeAfter ) { if ( ( aGroup.activeCount ( ) ) == 0 ) { break ; } } } catch ( java.lang.InterruptedException e ) { } } return result ; }
Source:
private static dalvik.system.DexClassLoader createInstance ( dalvik.system.DexClassLoaderTest.Configuration config ) { return new dalvik.system.DexClassLoader ( config.path , config.optimizedDir.getAbsolutePath ( ) , null , java.lang.ClassLoader.getSystemClassLoader ( ) ) ; }

Target:
private java.lang.ClassLoader createLoader ( java.io.File ... files ) { assertNotNull ( files ) ; assertTrue ( ( ( files.length ) > 0 ) ) ; java.lang.String path = files [ 0 ] . getAbsolutePath ( ) ; for ( int i = 1 ; i < ( files.length ) ; i ++ ) { path += ( java.io.File.pathSeparator ) + ( files [ i ] . getAbsolutePath ( ) ) ; } return new dalvik.system.DexClassLoader ( path , optimizedDir.getAbsolutePath ( ) , null , java.lang.ClassLoader.getSystemClassLoader ( ) ) ; }
Source:
private static java.net.InetAddress getHostByAddrImpl ( java.net.InetAddress address ) throws java.net.UnknownHostException { dalvik.system.BlockGuard.getThreadPolicy ( ) . onNetwork ( ) ; try { java.lang.String hostname = Libcore.os.getnameinfo ( address , java.net.NI_NAMEREQD ) ; return java.net.InetAddress.makeInetAddress ( address.ipaddress.clone ( ) , hostname ) ; } catch ( libcore.io.GaiException gaiException ) { throw gaiException.rethrowAsUnknownHostException ( ) ; } }

Target:
private static java.net.InetAddress getHostByAddrImpl ( java.net.InetAddress address ) throws java.net.UnknownHostException { dalvik.system.BlockGuard.getThreadPolicy ( ) . onNetwork ( ) ; try { java.lang.String hostname = Libcore.os.getnameinfo ( address , java.net.NI_NAMEREQD ) ; return java.net.InetAddress.makeInetAddress ( address.ipaddress.clone ( ) , hostname ) ; } catch ( android.system.GaiException gaiException ) { throw gaiException.rethrowAsUnknownHostException ( ) ; } }
Source:
protected java.lang.String checkLint ( com.android.tools.lint.checks.AbstractCheckTest.TestLintClient lintClient , java.util.List < java.io.File > files ) throws java.lang.Exception { mOutput = new java.lang.StringBuilder ( ) ; java.lang.String result = lintClient.analyze ( files ) ; if ( ( java.io.File.separatorChar ) != '/' ) { result = result.replace ( java.io.File.separatorChar , '/' ) ; } for ( java.io.File f : files ) { deleteFile ( f ) ; } return result ; }

Target:
protected java.lang.String checkLint ( com.android.tools.lint.checks.AbstractCheckTest.TestLintClient lintClient , java.util.List < java.io.File > files ) throws java.lang.Exception { if ( ( java.lang.System.getenv ( "ANDROID_BUILD_TOP" ) ) != null ) { fail ( ( "Don't run the lint tests with $ANDROID_BUILD_TOP set; that enables lint's " + ( "special support for detecting AOSP projects (looking for .class " + "files in $ANDROID_HOST_OUT etc), and this confuses lint." ) ) ) ; } mOutput = new java.lang.StringBuilder ( ) ; java.lang.String result = lintClient.analyze ( files ) ; if ( ( java.io.File.separatorChar ) != '/' ) { result = result.replace ( java.io.File.separatorChar , '/' ) ; } for ( java.io.File f : files ) { deleteFile ( f ) ; } return result ; }
Source:
public void addStateMonitorCallback ( com.android.internal.policy.IKeyguardStateCallback callback ) { synchronized ( this ) { mKeyguardStateCallbacks.add ( callback ) ; try { callback.onSimSecureStateChanged ( mUpdateMonitor.isSimPinSecure ( ) ) ; callback.onShowingStateChanged ( mShowing ) ; } catch ( android.os.RemoteException e ) { android.util.Slog.w ( com.android.systemui.keyguard.KeyguardViewMediator.TAG , "Failed to call onShowingStateChanged or onSimSecureStateChanged" , e ) ; } } }

Target:
public void addStateMonitorCallback ( com.android.internal.policy.IKeyguardStateCallback callback ) { synchronized ( this ) { mKeyguardStateCallbacks.add ( callback ) ; try { callback.onSimSecureStateChanged ( mUpdateMonitor.isSimPinSecure ( ) ) ; callback.onShowingStateChanged ( mShowing ) ; callback.onInputRestrictedStateChanged ( mInputRestricted ) ; } catch ( android.os.RemoteException e ) { android.util.Slog.w ( com.android.systemui.keyguard.KeyguardViewMediator.TAG , "Failed to call onShowingStateChanged or onSimSecureStateChanged or onInputRestrictedStateChanged" , e ) ; } } }
Source:
protected void okPressed ( ) { mActivityToTrace = mActivityToTraceText.getText ( ) ; mTraceFilePath = mTraceFilePathText.getText ( ) ; mSelectedDevice = mDeviceCombo.getText ( ) ; savePreferences ( ) ; super . okPressed ( ) ; }

Target:
protected void okPressed ( ) { mAppPackageToTrace = mAppPackageToTraceText.getText ( ) . trim ( ) ; mActivityToTrace = mActivityToTraceText.getText ( ) . trim ( ) ; if ( mActivityToTrace.startsWith ( "." ) ) { mActivityToTrace = mActivityToTrace.substring ( 1 ) ; } mTraceFilePath = mTraceFilePathText.getText ( ) . trim ( ) ; mSelectedDevice = mDeviceCombo.getText ( ) ; savePreferences ( ) ; super . okPressed ( ) ; }
Source:
public java.lang.String getBuildGradleContent ( ) { return ( ( ( ( ( ( ( "apply plugin: \'com.android.model.library\'\n" + ( ( ( "\n" + "model {\n" ) + " android.config {\n" ) + " compileSdkVersion " ) ) + ( com.android.build.gradle.integration.common.fixture.GradleTestProject.DEFAULT_COMPILE_SDK_VERSION ) ) + "\n" ) + " buildToolsVersion '" ) + ( com.android.build.gradle.integration.common.fixture.GradleTestProject.DEFAULT_BUILD_TOOL_VERSION ) ) + "\'\n" ) + " }\n" ) + "}\n" ; }

Target:
public java.lang.String getBuildGradleContent ( ) { return ( ( ( ( ( ( ( ( ( ( ( ( "apply plugin: \'com.android.model.library\'\n" + ( ( ( "\n" + "model {\n" ) + " android.config {\n" ) + " compileSdkVersion " ) ) + ( com.android.build.gradle.integration.common.fixture.GradleTestProject.DEFAULT_COMPILE_SDK_VERSION ) ) + "\n" ) + " buildToolsVersion '" ) + ( com.android.build.gradle.integration.common.fixture.GradleTestProject.DEFAULT_BUILD_TOOL_VERSION ) ) + "\'\n" ) + " defaultConfig {\n" ) + " useJack " ) + ( com.android.build.gradle.integration.common.fixture.GradleTestProject.CUSTOM_JACK ) ) + "\n" ) + " }\n" ) + " }\n" ) + "}\n" ; }
Source:
private static void edgeSplitMoveExceptionsAndResults ( com.android.jack.ir.ast.cfg.JControlFlowGraph cfg ) { for ( com.android.jack.ir.ast.cfg.JBasicBlock block : cfg.getInternalBlocksUnordered ( ) ) { if ( ( ( ! ( block instanceof com.android.jack.ir.ast.cfg.JExitBasicBlock ) ) && ( ( block.getPredecessorCount ( ) ) > 1 ) ) && ( block instanceof com.android.jack.ir.ast.cfg.JCatchBasicBlock ) ) { for ( com.android.jack.ir.ast.cfg.JBasicBlock predecssor : block.getPredecessors ( ) ) { predecssor.split ( 0 ) ; } } } }

Target:
private static void edgeSplitMoveExceptionsAndResults ( com.android.jack.ir.ast.cfg.JControlFlowGraph cfg ) { for ( com.android.jack.ir.ast.cfg.JBasicBlock block : cfg.getInternalBlocksUnordered ( ) ) { if ( ( ( ! ( block instanceof com.android.jack.ir.ast.cfg.JExitBasicBlock ) ) && ( ( block.getPredecessorCount ( ) ) > 1 ) ) && ( block instanceof com.android.jack.ir.ast.cfg.JCatchBasicBlock ) ) { for ( com.android.jack.ir.ast.cfg.JBasicBlock predecessor : com.google.common.collect.Lists.newArrayList ( block.getPredecessors ( ) ) ) { com.android.jack.transformations.ssa.SsaBasicBlockSplitter.insertNewSimpleSuccessor ( predecessor , block ) ; } } } }
Source:
public long beforeHandshake ( long context ) throws javax.net.ssl.SSLException { long s = org.conscrypt.NativeCrypto.SSL_new ( context ) ; org.conscrypt.NativeCrypto.SSL_set_cipher_lists ( s , new java.lang.String [ ] { "RC4-MD5" } ) ; if ( ( channelIdPrivateKey ) != null ) { org.conscrypt.NativeCrypto.SSL_set1_tls_channel_id ( s , channelIdPrivateKey ) ; } return s ; }

Target:
public long beforeHandshake ( long context ) throws javax.net.ssl.SSLException { long s = org.conscrypt.NativeCrypto.SSL_new ( context ) ; org.conscrypt.NativeCrypto.SSL_set_cipher_lists ( s , new java.lang.String [ ] { "RC4-MD5" } ) ; if ( ( channelIdPrivateKey ) != null ) { org.conscrypt.NativeCrypto.SSL_set1_tls_channel_id ( s , channelIdPrivateKey.getPkeyContext ( ) ) ; } return s ; }
Source:
private void verifyNoInsertion ( ) { try { java.lang.Thread.sleep ( com.android.server.telecom.tests.CallLogManagerTest.TEST_TIMEOUT_MILLIS ) ; org.mockito.Mockito.verify ( mContentProvider , org.mockito.Mockito.never ( ) ) . insert ( org.mockito.Matchers.any ( java.lang.String.class ) , org.mockito.Matchers.any ( android.net.Uri.class ) , org.mockito.Matchers.any ( android.content.ContentValues.class ) ) ; } catch ( com.android.server.telecom.tests.android e ) { fail ( "Remote exception occurred during test execution" ) ; } catch ( java.lang.InterruptedException e ) { e.printStackTrace ( ) ; } }

Target:
private void verifyNoInsertion ( ) { try { java.lang.Thread.sleep ( com.android.server.telecom.tests.CallLogManagerTest.TEST_TIMEOUT_MILLIS ) ; org.mockito.Mockito.verify ( mContentProvider , org.mockito.Mockito.never ( ) ) . insert ( org.mockito.Matchers.any ( java.lang.String.class ) , org.mockito.Matchers.any ( android.net.Uri.class ) , org.mockito.Matchers.any ( android.content.ContentValues.class ) ) ; } catch ( com.android.server.telecom.tests.android e ) { org.junit.Assert.fail ( "Remote exception occurred during test execution" ) ; } catch ( java.lang.InterruptedException e ) { e.printStackTrace ( ) ; } }
Source:
public boolean onOptionsItemSelected ( android.view.MenuItem item ) { switch ( item.getItemId ( ) ) { case com.android.cellbroadcastreceiver.CellBroadcastListActivity.MENU_DELETE_ALL : confirmDeleteThread ( ( - 1 ) ) ; break ; case com.android.cellbroadcastreceiver.CellBroadcastListActivity.MENU_PREFERENCES : android.content.Intent intent = new android.content.Intent ( this , com.android.cellbroadcastreceiver.CellBroadcastSettings.class ) ; startActivityIfNeeded ( intent , ( - 1 ) ) ; break ; default : return true ; } return false ; }

Target:
public void onLoadFinished ( android.content.Loader < android.database.Cursor > loader , android.database.Cursor data ) { mAdapter.swapCursor ( data ) ; }
Source:
public java.util.List < T > waitForTasks ( ) throws java.lang.InterruptedException , java.util.concurrent.ExecutionException { java.util.List < T > results = com.google.common.collect.Lists.newArrayListWithCapacity ( mCount ) ; for ( int i = 0 ; i < ( mCount ) ; i ++ ) { java.util.concurrent.Future < T > result = mCompletionService.take ( ) ; results.add ( result.get ( ) ) ; } return results ; }

Target:
public java.util.List < T > waitForTasksWithQuickFail ( ) throws java.lang.InterruptedException , java.util.concurrent.ExecutionException { java.util.List < T > results = com.google.common.collect.Lists.newArrayListWithCapacity ( mCount ) ; for ( int i = 0 ; i < ( mCount ) ; i ++ ) { java.util.concurrent.Future < T > result = mCompletionService.take ( ) ; results.add ( result.get ( ) ) ; } return results ; }
Source:
private void setBigDecimalDigits ( java.lang.String stringDigits , int maximumDigits , boolean fixedPoint ) { set ( stringDigits , stringDigits.length ( ) ) ; round ( ( fixedPoint ? maximumDigits + ( decimalAt ) : maximumDigits == 0 ? - 1 : maximumDigits ) ) ; }

Target:
private void setBigDecimalDigits ( java.lang.String stringDigits , int maximumDigits , boolean fixedPoint ) { didRound = false ; set ( stringDigits , stringDigits.length ( ) ) ; round ( ( fixedPoint ? maximumDigits + ( decimalAt ) : maximumDigits == 0 ? - 1 : maximumDigits ) ) ; }
Source:
public int compare ( com.android.traceview.ThreadData td1 , com.android.traceview.ThreadData td2 ) { if ( ( td2.getCpuTime ( ) ) > ( td1.getCpuTime ( ) ) ) return 1 ; if ( ( td2.getCpuTime ( ) ) < ( td1.getCpuTime ( ) ) ) return - 1 ; return td2.getName ( ) . compareTo ( td1.getName ( ) ) ; }

Target:
public int compare ( com.android.traceview.MethodData md1 , com.android.traceview.MethodData md2 ) { if ( ( timeBase.getElapsedInclusiveTime ( md2 ) ) > ( timeBase.getElapsedInclusiveTime ( md1 ) ) ) return 1 ; if ( ( timeBase.getElapsedInclusiveTime ( md2 ) ) < ( timeBase.getElapsedInclusiveTime ( md1 ) ) ) return - 1 ; return md1.getName ( ) . compareTo ( md2.getName ( ) ) ; }
Source:
public void nulledDeletedDiffedFieldValues ( ) { com.android.ahat.heapdump.FieldValue nulled = new com.android.ahat.heapdump.FieldValue ( "name" , "type" , null ) ; com.android.ahat.heapdump.DiffedFieldValue x = com.android.ahat.heapdump.DiffedFieldValue.deleted ( nulled ) ; org.junit.Assert.assertEquals ( "name" , x.name ) ; org.junit.Assert.assertEquals ( "type" , x.type ) ; org.junit.Assert.assertNull ( x.baseline ) ; org.junit.Assert.assertEquals ( DiffedFieldValue.Status.DELETED , x.status ) ; }

Target:
public void nulledDeletedDiffedFieldValues ( ) { com.android.ahat.heapdump.FieldValue nulled = new com.android.ahat.heapdump.FieldValue ( "name" , com.android.ahat.DiffFieldsTest.t0 , null ) ; com.android.ahat.heapdump.DiffedFieldValue x = com.android.ahat.heapdump.DiffedFieldValue.deleted ( nulled ) ; org.junit.Assert.assertEquals ( "name" , x.name ) ; org.junit.Assert.assertEquals ( com.android.ahat.DiffFieldsTest.t0 , x.type ) ; org.junit.Assert.assertNull ( x.baseline ) ; org.junit.Assert.assertEquals ( DiffedFieldValue.Status.DELETED , x.status ) ; }
Source:
public static void debugRunningApp ( org.eclipse.core.resources.IProject project , int debugPort ) { org.eclipse.debug.core.ILaunchConfiguration config = com.android.ide.eclipse.adt.internal.launch.AndroidLaunchController.getLaunchConfig ( project ) ; if ( config != null ) { com.android.ide.eclipse.adt.internal.launch.AndroidLaunchController.setPortLaunchConfigAssociation ( config , debugPort ) ; org.eclipse.debug.ui.DebugUITools.launch ( config , ILaunchManager.DEBUG_MODE ) ; } }

Target:
public static void debugRunningApp ( org.eclipse.core.resources.IProject project , int debugPort ) { org.eclipse.debug.core.ILaunchConfiguration config = com.android.ide.eclipse.adt.internal.launch.AndroidLaunchController.getLaunchConfig ( project , LaunchConfigDelegate.ANDROID_LAUNCH_TYPE_ID ) ; if ( config != null ) { com.android.ide.eclipse.adt.internal.launch.AndroidLaunchController.setPortLaunchConfigAssociation ( config , debugPort ) ; org.eclipse.debug.ui.DebugUITools.launch ( config , ILaunchManager.DEBUG_MODE ) ; } }
Source:
public void testMissingRequiredBundleFile ( ) throws java.lang.Exception { libcore.tzdata.update2.ConfigBundle installedConfigBundle = createValidTzDataBundle ( "2030a" ) ; assertTrue ( install ( installedConfigBundle ) ) ; assertTzDataInstalled ( installedConfigBundle ) ; libcore.tzdata.update2.ConfigBundle incompleteUpdate = createValidTzDataBundleBuilder ( "2030b" ) . clearBionicTzData ( ) . buildUnvalidated ( ) ; assertFalse ( install ( incompleteUpdate ) ) ; assertTzDataInstalled ( installedConfigBundle ) ; }

Target:
public void testMissingRequiredBundleFile ( ) throws java.lang.Exception { libcore.tzdata.update2.ConfigBundle installedConfigBundle = createValidTzDataBundle ( libcore.tzdata.update2.TzDataBundleInstallerTest.NEW_RULES_VERSION ) ; assertTrue ( installer.install ( installedConfigBundle.getBundleBytes ( ) ) ) ; assertTzDataInstalled ( installedConfigBundle ) ; libcore.tzdata.update2.ConfigBundle incompleteUpdate = createValidTzDataBundleBuilder ( libcore.tzdata.update2.TzDataBundleInstallerTest.NEWER_RULES_VERSION ) . clearBionicTzData ( ) . buildUnvalidated ( ) ; assertFalse ( installer.install ( incompleteUpdate.getBundleBytes ( ) ) ) ; assertTzDataInstalled ( installedConfigBundle ) ; }
Source:
protected void postCreate ( ) { com.android.sdkuilib.internal.tasks.ProgressViewFactory factory = new com.android.sdkuilib.internal.tasks.ProgressViewFactory ( ) ; factory.setProgressView ( new com.android.sdkuilib.internal.tasks.ProgressView ( mStatusText , mProgressBar , null ) ) ; mUpdaterData.setTaskFactory ( factory ) ; setupSources ( ) ; initializeSettings ( ) ; if ( mUpdaterData.checkIfInitFailed ( ) ) { close ( ) ; return ; } mUpdaterData.broadcastOnSdkLoaded ( ) ; mPackageMananger = new com.android.sdkuilib.internal.repository.PackageManager ( mUpdaterData ) { @ java.lang.Override public void updatePackageTable ( ) { } } ; }

Target:
protected void postCreate ( ) { com.android.sdkuilib.internal.tasks.ProgressViewFactory factory = new com.android.sdkuilib.internal.tasks.ProgressViewFactory ( ) ; factory.setProgressView ( new com.android.sdkuilib.internal.tasks.ProgressView ( mStatusText , mProgressBar , null , mUpdaterData.getSdkLog ( ) ) ) ; mUpdaterData.setTaskFactory ( factory ) ; setupSources ( ) ; initializeSettings ( ) ; if ( mUpdaterData.checkIfInitFailed ( ) ) { close ( ) ; return ; } mUpdaterData.broadcastOnSdkLoaded ( ) ; mPackageMananger = new com.android.sdkuilib.internal.repository.PackageManager ( mUpdaterData ) { @ java.lang.Override public void updatePackageTable ( ) { } } ; }
Source:
public void testE3 ( ) { dot.junit.opcodes.aput.d.T_aput_1 t = new dot.junit.opcodes.aput.d.T_aput_1 ( ) ; int [ ] arr = new int [ 2 ] ; try { t.run ( arr , ( - 1 ) , 100000000 ) ; fail ( "expected ArrayIndexOutOfBoundsException" ) ; } catch ( java.lang.ArrayIndexOutOfBoundsException aie ) { } }

Target:
public void testE3 ( ) { loadAndRun ( "dot.junit.opcodes.aput.d.T_aput_1" , java.lang.ArrayIndexOutOfBoundsException.class , new int [ 2 ] , ( - 1 ) , 100000000 ) ; }
Source:
public E get ( int index ) { synchronized ( l.lock ) { rangeCheck ( index ) ; checkForComodification ( ) ; return l.get ( ( index + ( offset ) ) ) ; } }

Target:
public void add ( int index , E object ) { synchronized ( this ) { slice.checkPositionIndex ( index ) ; slice.checkConcurrentModification ( elements ) ; this . add ( ( index + ( slice.from ) ) , object ) ; slice = new java.util.concurrent.CopyOnWriteArrayList.Slice ( elements , slice.from , ( ( slice.to ) + 1 ) ) ; } }
Source:
public com.android.dx.io.Annotation readAnnotation ( ) { byte visibility = readByte ( ) ; int start = position ; new com.android.dx.io.EncodedValueReader ( this , EncodedValueReader.ENCODED_ANNOTATION ) . skipValue ( ) ; int end = position ; return new com.android.dx.io.Annotation ( this , visibility , new com.android.dx.io.EncodedValue ( java.util.Arrays.copyOfRange ( data , start , end ) ) ) ; }

Target:
public com.android.dex.Annotation readAnnotation ( ) { byte visibility = readByte ( ) ; int start = position ; new com.android.dex.EncodedValueReader ( this , EncodedValueReader.ENCODED_ANNOTATION ) . skipValue ( ) ; int end = position ; return new com.android.dex.Annotation ( this , visibility , new com.android.dex.EncodedValue ( java.util.Arrays.copyOfRange ( data , start , end ) ) ) ; }
Source:
public void compileServices ( ) throws java.lang.Exception { java.io.File out = com.android.jack.TestTools.createTempFile ( "services" , ".dex" ) ; java.lang.String classpath = com.android.jack.TestTools.getClasspathsAsString ( com.android.jack.compile.androidtree.services.ServicesCompilationTest.BOOTCLASSPATH , com.android.jack.compile.androidtree.services.ServicesCompilationTest.CLASSPATH ) ; com.android.jack.TestTools.compileSourceToDex ( new com.android.jack.Options ( ) , com.android.jack.compile.androidtree.services.ServicesCompilationTest.SOURCELIST , classpath , out , false ) ; }

Target:
public void compileServices ( ) throws java.lang.Exception { java.io.File outDexFolder = com.android.jack.TestTools.createTempDir ( "services" , ".dex" ) ; java.lang.String classpath = com.android.jack.TestTools.getClasspathsAsString ( com.android.jack.compile.androidtree.services.ServicesCompilationTest.BOOTCLASSPATH , com.android.jack.compile.androidtree.services.ServicesCompilationTest.CLASSPATH ) ; com.android.jack.TestTools.compileSourceToDex ( new com.android.jack.Options ( ) , com.android.jack.compile.androidtree.services.ServicesCompilationTest.SOURCELIST , classpath , outDexFolder , false ) ; }
Source:
public com.android.sched.vfs.OutputVFS checkString ( @ javax.annotation.Nonnull com.android.sched.util.codec.CodecContext context , @ javax.annotation.Nonnull final java.lang.String string ) throws com.android.sched.util.codec.ParsingException { try { return new com.android.sched.vfs.DirectVFS ( new com.android.sched.util.file.Directory ( string , context.getRunnableHooks ( ) , existence , permissions , change ) ) ; } catch ( java.io.IOException e ) { throw new com.android.sched.util.codec.ParsingException ( e.getMessage ( ) , e ) ; } }

Target:
public com.android.sched.vfs.OutputVFS checkString ( @ javax.annotation.Nonnull com.android.sched.util.codec.CodecContext context , @ javax.annotation.Nonnull final java.lang.String string ) throws com.android.sched.util.codec.ParsingException { try { return new com.android.sched.vfs.GenericOutputVFS ( new com.android.sched.vfs.DirectFS ( new com.android.sched.util.file.Directory ( string , context.getRunnableHooks ( ) , existence , permissions , change ) , permissions ) ) ; } catch ( java.io.IOException e ) { throw new com.android.sched.util.codec.ParsingException ( e.getMessage ( ) , e ) ; } }
Source:
public static java.lang.String getCurrentCountryIso ( android.content.Context context , java.util.Locale locale ) { final android.telephony.TelephonyManager telephonyManager = ( ( android.telephony.TelephonyManager ) ( context.getSystemService ( Context.TELEPHONY_SERVICE ) ) ) ; java.lang.String countryIso = telephonyManager.getNetworkCountryIso ( ) ; if ( android.text.TextUtils.isEmpty ( countryIso ) ) { countryIso = locale.getCountry ( ) ; com.android.dialer.common.LogUtil.i ( "PhoneNumberHelper.getCurrentCountryIso" , ( "No CountryDetector; falling back to countryIso based on locale: " + countryIso ) ) ; } countryIso = countryIso.toUpperCase ( ) ; return countryIso ; }

Target:
public static java.lang.String getCurrentCountryIso ( android.content.Context context , @ android.support.annotation.Nullable android.telecom.PhoneAccountHandle phoneAccountHandle ) { java.lang.String countryIso = com.android.dialer.compat.telephony.TelephonyManagerCompat.getNetworkCountryIsoForPhoneAccountHandle ( context , phoneAccountHandle ) ; if ( android.text.TextUtils.isEmpty ( countryIso ) ) { countryIso = com.android.dialer.compat.CompatUtils.getLocale ( context ) . getCountry ( ) ; com.android.dialer.common.LogUtil.i ( "PhoneNumberHelper.getCurrentCountryIso" , ( "No CountryDetector; falling back to countryIso based on locale: " + countryIso ) ) ; } countryIso = countryIso.toUpperCase ( ) ; return countryIso ; }
Source:
public static boolean retainAll ( java.util.Iterator < ? > removeFrom , java.util.Collection < ? > elementsToRetain ) { com.google.common.base.Preconditions.checkNotNull ( elementsToRetain ) ; boolean modified = false ; while ( removeFrom.hasNext ( ) ) { if ( ! ( elementsToRetain.contains ( removeFrom.next ( ) ) ) ) { removeFrom.remove ( ) ; modified = true ; } } return modified ; }

Target:
public static boolean retainAll ( java.util.Iterator < ? > removeFrom , java.util.Collection < ? > elementsToRetain ) { return com.google.common.collect.Iterators.removeIf ( removeFrom , com.google.common.base.Predicates.not ( com.google.common.base.Predicates.in ( elementsToRetain ) ) ) ; }