auphong2707/dl4se-code-review-dataset huggingface dataset:
Source:
public void run ( ) { for ( com.android.ide.eclipse.adt.internal.editors.layout.gle2.CanvasSelection cs : selection ) { com.android.ide.eclipse.adt.internal.editors.layout.gle2.CanvasViewInfo vi = cs.getViewInfo ( ) ; if ( vi != null ) { com.android.ide.eclipse.adt.internal.editors.layout.uimodel.UiViewElementNode ui = vi.getUiViewKey ( ) ; if ( ui != null ) { ui.deleteXmlNode ( ) ; } } } }

Target:
java.lang.String getDeleteLabel ( ) { return mDeleteAction.getText ( ) ; }
Source:
public void testNegateMathContextNegative ( ) { java.lang.String a = "-92948782094488478231212478987482988429808779810457634781384756794987" ; int aScale = 49 ; int precision = 46 ; java.math.RoundingMode rm = java.math.RoundingMode.CEILING ; java.math.MathContext mc = new java.math.MathContext ( precision , rm ) ; java.lang.String c = "9294878209448847823.121247898748298842980877981" ; int cScale = 27 ; java.math.BigDecimal aNumber = new java.math.BigDecimal ( new java.math.BigInteger ( a ) , aScale ) ; java.math.BigDecimal res = aNumber.negate ( mc ) ; assertEquals ( "incorrect value" , c , res.toString ( ) ) ; assertEquals ( "incorrect scale" , cScale , res.scale ( ) ) ; }

Target:
public void testNegateMathContextNegative ( ) { java.lang.String a = "-92948782094488478231212478987482988429808779810457634781384756794987" ; int aScale = 49 ; int precision = 46 ; java.math.RoundingMode rm = java.math.RoundingMode.CEILING ; java.math.MathContext mc = new java.math.MathContext ( precision , rm ) ; java.lang.String c = "9294878209448847823.121247898748298842980877982" ; int cScale = 27 ; java.math.BigDecimal aNumber = new java.math.BigDecimal ( new java.math.BigInteger ( a ) , aScale ) ; java.math.BigDecimal res = aNumber.negate ( mc ) ; assertEquals ( "incorrect value" , c , res.toString ( ) ) ; assertEquals ( "incorrect scale" , cScale , res.scale ( ) ) ; }
Source:
private void toString ( java.lang.StringBuilder sb ) { if ( ( mSubDomains ) != null ) { sb.append ( ".{" ) ; for ( java.util.Map.Entry < java.lang.String , com.android.server.wifi.hotspot2.pps.DomainMatcher.Label > entry : mSubDomains.entrySet ( ) ) { sb.append ( entry.getKey ( ) ) ; entry.getValue ( ) . toString ( sb ) ; } sb.append ( '}' ) ; } else { sb.append ( '=' ) . append ( mMatch ) ; } }

Target:
private void toString ( java.lang.StringBuilder sb ) { if ( ( mSubDomains ) != null ) { sb.append ( ".{" ) ; for ( java.util.Map.Entry < java.lang.String , com.android.server.wifi.hotspot2.DomainMatcher.Label > entry : mSubDomains.entrySet ( ) ) { sb.append ( entry.getKey ( ) ) ; entry.getValue ( ) . toString ( sb ) ; } sb.append ( '}' ) ; } else { sb.append ( '=' ) . append ( mMatch ) ; } }
Source:
public void onUpcomingConflictChange ( ) { com.android.tv.dvr.ConflictChecker checker = ( ( com.android.tv.MainActivity ) ( getContext ( ) ) ) . getDvrConflictChecker ( ) ; if ( ( checker == null ) || ( checker.getUpcomingConflicts ( ) . isEmpty ( ) ) ) { if ( com.android.tv.dvr.ui.DvrConflictFragment.DEBUG ) android.util.Log.d ( com.android.tv.dvr.ui.DvrConflictFragment.TAG , "onUpcomingConflictChange: There's no conflict." ) ; dismissDialog ( ) ; } }

Target:
public void onUpcomingConflictChange ( ) { com.android.tv.dvr.recorder.ConflictChecker checker = ( ( com.android.tv.MainActivity ) ( getContext ( ) ) ) . getDvrConflictChecker ( ) ; if ( ( checker == null ) || ( checker.getUpcomingConflicts ( ) . isEmpty ( ) ) ) { if ( com.android.tv.dvr.ui.DvrConflictFragment.DEBUG ) android.util.Log.d ( com.android.tv.dvr.ui.DvrConflictFragment.TAG , "onUpcomingConflictChange: There's no conflict." ) ; dismissDialog ( ) ; } }
Source:
public void dragFinished ( org.eclipse.swt.dnd.DragSourceEvent e ) { if ( ( e.detail ) == ( org.eclipse.swt.dnd.DND.DROP_MOVE ) ) { mLayoutEditor.wrapUndoEditXmlModel ( "Remove drag'n'drop source elements" , new java.lang.Runnable ( ) { public void run ( ) { deleteSelection ( "Remove" , mDragSelection ) ; } } ) ; } mDragSelection.clear ( ) ; mDragElements = null ; com.android.ide.eclipse.adt.internal.editors.layout.gle2.GlobalCanvasDragInfo.getInstance ( ) . stopDrag ( ) ; }

Target:
com.android.ide.eclipse.adt.internal.editors.layout.LayoutEditor getLayoutEditor ( ) { return mLayoutEditor ; }
Source:
private void setAndBroadcastNetworkSetTimeZone ( java.lang.String zoneId ) { if ( com.android.internal.telephony.NitzStateMachine.DBG ) { android.telephony.Rlog.d ( com.android.internal.telephony.NitzStateMachine.LOG_TAG , ( "setAndBroadcastNetworkSetTimeZone: setTimeZone=" + zoneId ) ) ; } mTimeServiceHelper.setDeviceTimeZone ( zoneId ) ; if ( com.android.internal.telephony.NitzStateMachine.DBG ) { android.telephony.Rlog.d ( com.android.internal.telephony.NitzStateMachine.LOG_TAG , ( ( "setAndBroadcastNetworkSetTimeZone: called setDeviceTimeZone()" + " zoneId=" ) + zoneId ) ) ; } }

Target:
private void setAndBroadcastNetworkSetTimeZone ( java.lang.String zoneId ) { if ( com.android.internal.telephony.NitzStateMachine.DBG ) { android.telephony.Rlog.d ( com.android.internal.telephony.NitzStateMachine.LOG_TAG , ( "setAndBroadcastNetworkSetTimeZone: zoneId=" + zoneId ) ) ; } mTimeServiceHelper.setDeviceTimeZone ( zoneId ) ; if ( com.android.internal.telephony.NitzStateMachine.DBG ) { android.telephony.Rlog.d ( com.android.internal.telephony.NitzStateMachine.LOG_TAG , ( ( "setAndBroadcastNetworkSetTimeZone: called setDeviceTimeZone()" + " zoneId=" ) + zoneId ) ) ; } }
Source:
private void runConfigTests ( int [ ] configIds , int contextClientVersion ) throws java.lang.InterruptedException { for ( int configId : configIds ) { android.os.Bundle extras = new android.os.Bundle ( ) ; extras.putInt ( EglConfigCtsActivity.CONFIG_ID_EXTRA , configId ) ; extras.putInt ( EglConfigCtsActivity.CONTEXT_CLIENT_VERSION_EXTRA , contextClientVersion ) ; android.opengl.cts.EglConfigCtsActivity activity = launchActivity ( "android.graphics.cts" , android.opengl.cts.EglConfigCtsActivity.class , extras ) ; activity.waitToFinishDrawing ( ) ; activity.finish ( ) ; mInstrumentation.waitForIdleSync ( ) ; } }

Target:
private void runConfigTests ( int [ ] configIds , int contextClientVersion ) throws java.lang.InterruptedException { for ( int configId : configIds ) { android.os.Bundle extras = new android.os.Bundle ( ) ; extras.putInt ( EglConfigCtsActivity.CONFIG_ID_EXTRA , configId ) ; extras.putInt ( EglConfigCtsActivity.CONTEXT_CLIENT_VERSION_EXTRA , contextClientVersion ) ; android.opengl.cts.EglConfigCtsActivity activity = launchActivity ( "android.graphics.cts" , android.opengl.cts.EglConfigCtsActivity.class , extras ) ; activity.waitToFinishDrawing ( ) ; java.lang.Thread.sleep ( 500 ) ; activity.finish ( ) ; mInstrumentation.waitForIdleSync ( ) ; } }
Source:
private void checkInputFile ( java.io.File file , boolean throwIfDoesntExist ) throws com.android.sdklib.build.ApkCreationException { if ( file.isDirectory ( ) ) { throw new com.android.sdklib.build.ApkCreationException ( "%s is a directory!" , file ) ; } if ( file.exists ( ) ) { if ( ( file.canRead ( ) ) == false ) { throw new com.android.sdklib.build.ApkCreationException ( "Cannot read %s" , file ) ; } } else if ( throwIfDoesntExist ) { throw new com.android.sdklib.build.ApkCreationException ( "%s does not exist" , file ) ; } }

Target:
private void checkInputFile ( java.io.File file ) throws com.android.sdklib.build.ApkCreationException , java.io.FileNotFoundException { if ( file.isDirectory ( ) ) { throw new com.android.sdklib.build.ApkCreationException ( "%s is a directory!" , file ) ; } if ( file.exists ( ) ) { if ( ( file.canRead ( ) ) == false ) { throw new com.android.sdklib.build.ApkCreationException ( "Cannot read %s" , file ) ; } } else { throw new java.io.FileNotFoundException ( java.lang.String.format ( "%s does not exist" , file ) ) ; } }
Source:
public void test_RAND_bytes_Success ( ) throws java.lang.Exception { byte [ ] output = new byte [ 128 ] ; org.conscrypt.NativeCrypto.RAND_bytes ( output ) ; boolean isZero = true ; for ( int i = 0 ; i < ( output.length ) ; i ++ ) { isZero &= ( output [ i ] ) == 0 ; } assertFalse ( ( "Random output was zero. This is a very low probability event (1 in 2^128) " + "and probably indicates an error." ) , isZero ) ; }

Target:
public void test_RAND_bytes_Success ( ) throws java.lang.Exception { byte [ ] output = new byte [ 128 ] ; org.conscrypt.NativeCrypto.RAND_bytes ( output ) ; boolean isZero = true ; for ( int i = 0 ; i < ( output.length ) ; i ++ ) { isZero &= ( output [ i ] ) == 0 ; } org.junit.Assert.assertFalse ( ( "Random output was zero. This is a very low probability event (1 in 2^128) " + "and probably indicates an error." ) , isZero ) ; }
Source:
private static java.lang.StringBuffer _appendToPat ( java.lang.StringBuffer buf , java.lang.String s , boolean escapeUnprintable ) { int cp ; for ( int i = 0 ; i < ( s.length ( ) ) ; i += java.lang.Character.charCount ( cp ) ) { cp = s.codePointAt ( i ) ; com.ibm.icu.text.UnicodeSet._appendToPat ( buf , cp , escapeUnprintable ) ; } return buf ; }

Target:
private static < T extends java.lang.Appendable > T _appendToPat ( T buf , java.lang.String s , boolean escapeUnprintable ) { int cp ; for ( int i = 0 ; i < ( s.length ( ) ) ; i += java.lang.Character.charCount ( cp ) ) { cp = s.codePointAt ( i ) ; com.ibm.icu.text.UnicodeSet._appendToPat ( buf , cp , escapeUnprintable ) ; } return buf ; }
Source:
public void test_init_and_run_for_SimpleTest2_limitting_to_1method_should_perform_test ( ) { java.lang.Class < ? > target = vogar.target.junit3.SimpleTest2.class ; java.lang.String actionName = "actionName" ; runner.init ( monitor , actionName , null , target , skipPastReference , testEnvironment , 0 , false ) ; runner.run ( "" , null , new java.lang.String [ ] { "testSimple2" } ) ; org.mockito.Mockito.verify ( monitor ) . outcomeStarted ( runner , ( ( target.getName ( ) ) + "#testSimple2" ) , actionName ) ; org.mockito.Mockito.verify ( monitor ) . outcomeFinished ( Result.SUCCESS ) ; }

Target:
public void test_limiting_to_1method_and_run_for_SimpleTest2_should_perform_test ( ) { java.lang.Class < ? > target = vogar.target.junit3.SimpleTest2.class ; java.lang.String actionName = "actionName" ; vogar.target.Runner runner = new vogar.target.junit.JUnitRunner ( monitor , actionName , "testSimple2" , target , skipPastReference , testEnvironment , 0 ) ; runner.run ( "" , null , null ) ; org.mockito.Mockito.verify ( monitor ) . outcomeStarted ( runner , ( ( target.getName ( ) ) + "#testSimple2" ) , actionName ) ; org.mockito.Mockito.verify ( monitor ) . outcomeFinished ( Result.SUCCESS ) ; }
Source:
public void ancestorMoved ( javax.swing.event.AncestorEvent event ) { viewer.setZoom ( com.android.draw9patch.ui.ImageEditorPanel.DEFAULT_ZOOM ) ; viewer.removeAncestorListener ( this ) ; }

Target:
private javax.swing.JComponent buildStretchesViewer ( ) { stretchesViewer = new com.android.draw9patch.ui.StretchesViewer ( this , viewer , texture ) ; javax.swing.JScrollPane scroller = new javax.swing.JScrollPane ( stretchesViewer ) ; scroller.setBorder ( null ) ; scroller.getViewport ( ) . setBorder ( null ) ; scroller.setHorizontalScrollBarPolicy ( javax.swing.JScrollPane.HORIZONTAL_SCROLLBAR_ALWAYS ) ; scroller.setVerticalScrollBarPolicy ( javax.swing.JScrollPane.VERTICAL_SCROLLBAR_ALWAYS ) ; return scroller ; }
Source:
public void TestT6844 ( ) { try { com.ibm.icu.util.UResourceBundle rb1 = com.ibm.icu.util.UResourceBundle.getBundleInstance ( "com.ibm.icu.dev.data.resources.TestMessages" ) ; assertEquals ( "bundleContainer in TestMessages" , "TestMessages.class" , rb1.getString ( "bundleContainer" ) ) ; com.ibm.icu.util.UResourceBundle rb2 = com.ibm.icu.util.UResourceBundle.getBundleInstance ( "com.ibm.icu.dev.data.resources.testmessages" ) ; assertEquals ( "bundleContainer in testmessages" , "testmessages.properties" , rb2.getString ( "bundleContainer" ) ) ; } catch ( java.lang.Throwable t ) { errln ( t.getMessage ( ) ) ; } }

Target:
public void TestT6844 ( ) { try { com.ibm.icu.util.UResourceBundle rb1 = com.ibm.icu.util.UResourceBundle.getBundleInstance ( "com.ibm.icu.dev.data.resources.TestMessages" , com.ibm.icu.util.ULocale.getDefault ( ) , com.ibm.icu.dev.test.util.ICUResourceBundleTest.testLoader ) ; assertEquals ( "bundleContainer in TestMessages" , "TestMessages.class" , rb1.getString ( "bundleContainer" ) ) ; com.ibm.icu.util.UResourceBundle rb2 = com.ibm.icu.util.UResourceBundle.getBundleInstance ( "com.ibm.icu.dev.data.resources.testmessages" , com.ibm.icu.util.ULocale.getDefault ( ) , com.ibm.icu.dev.test.util.ICUResourceBundleTest.testLoader ) ; assertEquals ( "bundleContainer in testmessages" , "testmessages.properties" , rb2.getString ( "bundleContainer" ) ) ; } catch ( java.lang.Throwable t ) { errln ( t.getMessage ( ) ) ; } }
Source:
void createAndroidTasks ( org.gradle.model.collection.CollectionBuilder < org.gradle.api.Task > tasks , com.android.build.gradle.model.AndroidComponentSpec androidSpec , com.android.build.gradle.internal.TaskManager taskManager , com.android.build.gradle.internal.SdkHandler sdkHandler , org.gradle.api.Project project , com.android.build.gradle.model.AndroidComponentModelSourceSet androidSources ) { com.android.build.gradle.model.DefaultAndroidComponentSpec spec = ( ( com.android.build.gradle.model.DefaultAndroidComponentSpec ) ( androidSpec ) ) ; for ( com.android.build.gradle.model.File file : sdkHandler.sdkLoader.repositories ) ; project.repositories.maven = $missing$ ; org.gradle.api.artifacts.repositories.MavenArtifactRepository repo ; repo.url = file.toURI ( ) ; }

Target:
public void execute ( org.gradle.api.artifacts.repositories.MavenArtifactRepository repo ) { repo.setUrl ( file.toURI ( ) ) ; }
Source:
protected void setUp ( ) throws java.lang.Exception { java.io.File tmpDir = libcore.io.IoUtils.createTemporaryDirectory ( "OldAbstractPreferencesTest" ) ; defaultFactory = java.util.prefs.Preferences.setPreferencesFactory ( new org.apache.harmony.tests.java.util.prefs.AbstractPreferencesTest.TestPreferencesFactory ( tmpDir.getAbsolutePath ( ) ) ) ; in = new java.io.ByteArrayInputStream ( org.apache.harmony.tests.java.util.prefs.PreferencesTest.PREFS.getBytes ( java.nio.charset.StandardCharsets.US_ASCII ) ) ; stream = new org.apache.harmony.tests.java.util.prefs.PreferencesTest.MockInputStream ( in ) ; }

Target:
protected void setUp ( ) throws java.lang.Exception { backendDir = libcore.io.IoUtils.createTemporaryDirectory ( "OldAbstractPreferencesTest" ) ; defaultFactory = java.util.prefs.Preferences.setPreferencesFactory ( new org.apache.harmony.tests.java.util.prefs.AbstractPreferencesTest.TestPreferencesFactory ( backendDir.getAbsolutePath ( ) ) ) ; in = new java.io.ByteArrayInputStream ( org.apache.harmony.tests.java.util.prefs.PreferencesTest.PREFS.getBytes ( java.nio.charset.StandardCharsets.US_ASCII ) ) ; stream = new org.apache.harmony.tests.java.util.prefs.PreferencesTest.MockInputStream ( in ) ; }
Source:
public boolean createBond ( android.bluetooth.BluetoothDevice device , int transport ) { if ( ! ( com.android.bluetooth.Utils.checkCaller ( ) ) ) { android.util.Log.w ( com.android.bluetooth.btservice.AdapterService.TAG , "createBond() - Not allowed for non-active user" ) ; return false ; } com.android.bluetooth.btservice.AdapterService service = getService ( ) ; if ( service == null ) return false ; return service.createBond ( device , transport , null ) ; }

Target:
public boolean createBond ( android.bluetooth.BluetoothDevice device , int transport ) { if ( ! ( com.android.bluetooth.Utils.checkCallerAllowManagedProfiles ( mService ) ) ) { android.util.Log.w ( com.android.bluetooth.btservice.AdapterService.TAG , "createBond() - Not allowed for non-active user" ) ; return false ; } com.android.bluetooth.btservice.AdapterService service = getService ( ) ; if ( service == null ) return false ; return service.createBond ( device , transport , null ) ; }
Source:
public final long getLong ( ) { int newPosition = ( position ) + ( libcore.io.SizeOf.LONG ) ; if ( newPosition > ( limit ) ) { throw new java.nio.BufferUnderflowException ( ) ; } long result = this . block.peekLong ( ( ( offset ) + ( position ) ) , order ) ; position = newPosition ; return result ; }

Target:
public java.nio.ByteBuffer putLong ( long value ) { if ( isReadOnly ) { throw new java.nio.ReadOnlyBufferException ( ) ; } int newPosition = ( position ) + ( libcore.io.SizeOf.LONG ) ; if ( newPosition > ( limit ) ) { throw new java.nio.BufferOverflowException ( ) ; } this . block.pokeLong ( ( ( offset ) + ( position ) ) , value , order ) ; position = newPosition ; return this ; }
Source:
private static void addSourceLevel ( @ javax.annotation.Nonnull com.android.jack.test.toolchain.SourceLevel level , @ javax.annotation.Nonnull java.util.List < java.lang.String > args ) { args.add ( "-source" ) ; switch ( level ) { case JAVA_6 : args.add ( "1.6" ) ; break ; case JAVA_7 : args.add ( "1.7" ) ; break ; default : throw new java.lang.AssertionError ( ( ( "Unkown level: '" + ( level.toString ( ) ) ) + "'" ) ) ; } }

Target:
private static void addSourceLevel ( @ javax.annotation.Nonnull com.android.jack.test.toolchain.SourceLevel level , @ javax.annotation.Nonnull java.util.List < java.lang.String > args ) { args.add ( "-source" ) ; switch ( level ) { case JAVA_6 : args.add ( "1.6" ) ; break ; case JAVA_7 : args.add ( "1.7" ) ; break ; case JAVA_8 : args.add ( "1.8" ) ; break ; default : throw new java.lang.AssertionError ( ( ( "Unkown level: '" + ( level.toString ( ) ) ) + "'" ) ) ; } }
Source:
private void handleAssociatedBSSIDEvent ( java.lang.String eventStr , java.lang.String iface ) { java.lang.String BSSID = null ; java.util.regex.Matcher match = com.android.server.wifi.WifiMonitor.mAssociatedPattern.matcher ( eventStr ) ; if ( match.find ( ) ) { BSSID = match.group ( 1 ) ; } sendMessage ( iface , WifiStateMachine.CMD_ASSOCIATED_BSSID , com.android.server.wifi.WifiMonitor.eventLogCounter , 0 , BSSID ) ; }

Target:
private void handleAssociatedBSSIDEvent ( java.lang.String eventStr , java.lang.String iface ) { java.lang.String BSSID = null ; java.util.regex.Matcher match = com.android.server.wifi.WifiMonitor.mAssociatedPattern.matcher ( eventStr ) ; if ( match.find ( ) ) { BSSID = match.group ( 1 ) ; } broadcastAssociationSuccesfulEvent ( iface , BSSID ) ; }
Source:
public void setUp ( ) throws java.lang.Exception { mDelivery = new com.android.volley.mock.MockResponseDelivery ( ) ; mNetworkQueue = new com.android.volley.mock.WaitableQueue ( ) ; mNetwork = new com.android.volley.mock.MockNetwork ( ) ; mCache = new com.android.volley.mock.MockCache ( ) ; mRequest = new com.android.volley.mock.MockRequest ( ) ; mDispatcher = new com.android.volley.NetworkDispatcher ( mNetworkQueue , mNetwork , mCache , mDelivery ) ; mDispatcher.start ( ) ; }

Target:
public void setUp ( ) throws java.lang.Exception { org.mockito.MockitoAnnotations.initMocks ( this ) ; mRequest = new com.android.volley.toolbox.StringRequest ( Request.Method.GET , "http://foo" , null , null ) ; mDispatcher = new com.android.volley.NetworkDispatcher ( mNetworkQueue , mNetwork , mCache , mDelivery ) ; }
Source:
public java.lang.Iterable < java.lang.String > getCFlags ( ) { }

Target:
public java.lang.Iterable < java.lang.String > getCFlags ( ) { return com.google.common.collect.Iterables.concat ( getTargetFlags ( ) , com.android.build.gradle.ndk.internal.ClangNativeToolSpecification.RELEASE_CFLAGS.get ( platform.getName ( ) ) , ( isDebugBuild ? com.android.build.gradle.ndk.internal.ClangNativeToolSpecification.DEBUG_CFLAGS.get ( platform.getName ( ) ) : com.google.common.collect.ImmutableList.< java.lang.String > of ( ) ) ) ; }
Source:
protected void onPause ( ) { super . onPause ( ) ; if ( ( mFileDescriptor ) != null ) { try { mFileDescriptor.close ( ) ; } catch ( java.io.IOException e ) { android.util.Log.e ( com.android.cts.verifier.usb.UsbAccessoryTestActivity.TAG , "Exception while closing file descriptor" , e ) ; } finally { mFileDescriptor = null ; } } }

Target:
private void closeAccessory ( ) { mAccessory = null ; if ( ( mFileDescriptor ) != null ) { try { mFileDescriptor.close ( ) ; } catch ( java.io.IOException e ) { android.util.Log.e ( com.android.cts.verifier.usb.UsbAccessoryTestActivity.TAG , "Exception while closing file descriptor" , e ) ; } finally { mFileDescriptor = null ; } } }
Source:
public int setAllowedCarriers ( int slotId , java.util.List < android.service.carrier.CarrierIdentifier > carriers ) { try { com.android.internal.telephony.ITelephony service = getITelephony ( ) ; if ( service != null ) { return service.setAllowedCarriers ( slotId , carriers ) ; } } catch ( android.os.RemoteException e ) { android.util.Log.e ( android.telephony.TelephonyManager.TAG , "Error calling ITelephony#setAllowedCarriers" , e ) ; } catch ( java.lang.NullPointerException e ) { android.util.Log.e ( android.telephony.TelephonyManager.TAG , "Error calling ITelephony#setAllowedCarriers" , e ) ; } return - 1 ; }

Target:
public java.util.List < android.service.carrier.CarrierIdentifier > getAllowedCarriers ( int slotIndex ) { try { com.android.internal.telephony.ITelephony service = getITelephony ( ) ; if ( service != null ) { return service.getAllowedCarriers ( slotIndex ) ; } } catch ( android.os.RemoteException e ) { android.util.Log.e ( android.telephony.TelephonyManager.TAG , "Error calling ITelephony#getAllowedCarriers" , e ) ; } catch ( java.lang.NullPointerException e ) { android.util.Log.e ( android.telephony.TelephonyManager.TAG , "Error calling ITelephony#getAllowedCarriers" , e ) ; } return new java.util.ArrayList < android.service.carrier.CarrierIdentifier > ( 0 ) ; }
Source:
public void testDropCdmaEnhancedPrivacyVoiceCall ( ) 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 ( ) ) ; mConnectionServiceFixtureA.mLatestConnection.setConnectionProperties ( 0 ) ; assertFalse ( Call.Details.hasProperty ( mInCallServiceFixtureX.getCall ( ids.mCallId ) . getProperties ( ) , Call.Details.PROPERTY_HAS_CDMA_VOICE_PRIVACY ) ) ; }

Target:
public void testDropCdmaEnhancedPrivacyVoiceCall ( ) 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 ( ) ) ; mConnectionServiceFixtureA.mLatestConnection.setConnectionProperties ( 0 ) ; org.junit.Assert.assertFalse ( Call.Details.hasProperty ( mInCallServiceFixtureX.getCall ( ids.mCallId ) . getProperties ( ) , Call.Details.PROPERTY_HAS_CDMA_VOICE_PRIVACY ) ) ; }
Source:
public java.lang.Object getParent ( java.lang.Object element ) { if ( element instanceof com.android.sdklib.internal.repository.SdkSource ) { return this ; } else if ( element instanceof java.lang.Package ) { return ( ( java.lang.Package ) ( element ) ) . getParentSource ( ) ; } else if ( element instanceof com.android.sdklib.internal.repository.Archive ) { return ( ( com.android.sdklib.internal.repository.Archive ) ( element ) ) . getParentPackage ( ) ; } return null ; }

Target:
public java.lang.Object getParent ( java.lang.Object element ) { if ( element instanceof com.android.sdklib.internal.repository.SdkSourceCategory ) { return this ; } else if ( element instanceof com.android.sdklib.internal.repository.SdkSource ) { return mUpdaterData.getSources ( ) . getCategory ( ( ( com.android.sdklib.internal.repository.SdkSource ) ( element ) ) ) ; } else if ( element instanceof java.lang.Package ) { return ( ( java.lang.Package ) ( element ) ) . getParentSource ( ) ; } else if ( element instanceof com.android.sdklib.internal.repository.Archive ) { return ( ( com.android.sdklib.internal.repository.Archive ) ( element ) ) . getParentPackage ( ) ; } return null ; }
Source:
public void startWithRttService ( android.content.Context context , android.os.Looper looper , android.net.wifi.IRttManager service ) { android.os.Messenger messenger ; try { messenger = service.getMessenger ( ) ; } catch ( android.os.RemoteException e ) { android.util.Log.e ( com.android.server.wifi.nan.WifiNanRttStateManager.TAG , "start(): not able to getMessenger() of WIFI_RTT_SERVICE" ) ; return ; } mAsyncChannel = new com.android.internal.util.AsyncChannel ( ) ; mAsyncChannel.connect ( context , new com.android.server.wifi.nan.WifiNanRttStateManager.NanRttHandler ( looper ) , messenger ) ; }

Target:
public void startWithRttService ( android.content.Context context , android.os.Looper looper , android.net.wifi.IRttManager service ) { android.os.Messenger messenger ; try { messenger = service.getMessenger ( ) ; } catch ( android.os.RemoteException e ) { android.util.Log.e ( com.android.server.wifi.aware.WifiAwareRttStateManager.TAG , "start(): not able to getMessenger() of WIFI_RTT_SERVICE" ) ; return ; } mAsyncChannel = new com.android.internal.util.AsyncChannel ( ) ; mAsyncChannel.connect ( context , new com.android.server.wifi.aware.WifiAwareRttStateManager.AwareRttHandler ( looper ) , messenger ) ; }
Source:
public void connect ( ) throws java.io.IOException { if ( ! ( connected ) ) { this . jarEntry = strictJarFile.findEntry ( getEntryName ( ) ) ; if ( ( jarEntry ) == null ) { throw new java.io.FileNotFoundException ( ( ( ( "URL does not correspond to an entry in the zip file. URL=" + ( url ) ) + ", zipfile=" ) + ( strictJarFile.getName ( ) ) ) ) ; } connected = true ; } }

Target:
public void connect ( ) throws java.io.IOException { if ( ! ( connected ) ) { this . jarEntry = libcore.io.ClassPathURLStreamHandler.findEntryWithDirectoryFallback ( strictJarFile , getEntryName ( ) ) ; if ( ( jarEntry ) == null ) { throw new java.io.FileNotFoundException ( ( ( ( "URL does not correspond to an entry in the zip file. URL=" + ( url ) ) + ", zipfile=" ) + ( strictJarFile.getName ( ) ) ) ) ; } connected = true ; } }
Source:
private static boolean isMultiArch ( com.android.server.pm.PackageSetting ps ) { return ( ( ps.pkgFlags ) & ( android.content.pm.ApplicationInfo.FLAG_MULTIARCH ) ) != 0 ; }

Target:
private void removeNativeBinariesLI ( com.android.server.pm.PackageSetting ps ) { if ( ps != null ) { com.android.internal.content.NativeLibraryHelper.removeNativeBinariesLI ( ps.legacyNativeLibraryPathString ) ; final int childCount = ( ( ps.childPackageNames ) != null ) ? ps.childPackageNames.size ( ) : 0 ; for ( int i = 0 ; i < childCount ; i ++ ) { com.android.server.pm.PackageSetting childPs = null ; synchronized ( mPackages ) { childPs = mSettings.peekPackageLPr ( ps.childPackageNames.get ( i ) ) ; } if ( childPs != null ) { com.android.internal.content.NativeLibraryHelper.removeNativeBinariesLI ( childPs.legacyNativeLibraryPathString ) ; } } } }
Source:
private void onPollNetworkTime ( int event ) { if ( ! ( isAutomaticTimeRequested ( ) ) ) return ; mWakeLock.acquire ( ) ; try { onPollNetworkTimeUnderWakeLock ( event ) ; } finally { mWakeLock.release ( ) ; } }

Target:
private void onPollNetworkTime ( int event ) { if ( ( ! ( isAutomaticTimeRequested ( ) ) ) || ( ( mDefaultNetwork ) == null ) ) return ; mWakeLock.acquire ( ) ; try { onPollNetworkTimeUnderWakeLock ( event ) ; } finally { mWakeLock.release ( ) ; } }
Source:
private java.lang.String getHeaderTitle ( ) { return getString ( R.string.action_bar_label ) ; }

Target:
private java.lang.String getHeaderTitle ( ) { android.net.NetworkInfo info = mCm.getNetworkInfo ( mNetwork ) ; if ( info == null ) { return getString ( R.string.action_bar_label ) ; } android.net.NetworkCapabilities nc = mCm.getNetworkCapabilities ( mNetwork ) ; if ( ! ( nc.hasTransport ( NetworkCapabilities.TRANSPORT_WIFI ) ) ) { return getString ( R.string.action_bar_label ) ; } return getString ( R.string.action_bar_title , info.getExtraInfo ( ) . replaceAll ( "^\"|\"$" , "" ) ) ; }
Source:
public void testPownF32_4 ( ) { android.renderscript.Allocation nAlloc = android.renderscript.Allocation.createSized ( mRS , android.renderscript.Element.I32_4 ( mRS ) , android.renderscript.cts.INPUTSIZE ) ; n = new int [ ( INPUTSIZE ) * 4 ] ; android.renderscript.cts.RSUtils.genRandom ( 4400074 , 32 , 1 , ( - 16 ) , n ) ; nAlloc.copyFrom ( n ) ; script_f32.set_n4 ( nAlloc ) ; doF32_4 ( 11145969 , 16 ) ; }

Target:
public void testPownF32_4 ( ) { android.renderscript.Allocation nAlloc = android.renderscript.Allocation.createSized ( mRS , android.renderscript.Element.I32_4 ( mRS ) , android.renderscript.cts.INPUTSIZE ) ; n = new int [ ( INPUTSIZE ) * 4 ] ; android.renderscript.cts.RSUtils.genRandomInts ( 4400074 , 32 , ( - 16 ) , n ) ; nAlloc.copyFrom ( n ) ; script_f32.set_n4 ( nAlloc ) ; doF32_4 ( 11145969 , 16 ) ; }
Source:
public void requestIsimAuthentication ( java.lang.String nonce , android.os.Message response ) { com.android.internal.telephony.RILRequest rr = com.android.internal.telephony.RILRequest.obtain ( com.android.internal.telephony.RIL_REQUEST_ISIM_AUTHENTICATION , response ) ; rr.mParcel.writeString ( nonce ) ; if ( com.android.internal.telephony.RIL.RILJ_LOGD ) riljLog ( ( ( ( rr.serialString ( ) ) + "> " ) + ( com.android.internal.telephony.RIL.requestToString ( rr.mRequest ) ) ) ) ; send ( rr ) ; }

Target:
public void getCellInfoList ( android.os.Message result , android.os.WorkSource workSource ) { workSource = getDeafultWorkSourceIfInvalid ( workSource ) ; com.android.internal.telephony.RILRequest rr = com.android.internal.telephony.RILRequest.obtain ( com.android.internal.telephony.RIL_REQUEST_GET_CELL_INFO_LIST , result , workSource ) ; if ( com.android.internal.telephony.RIL.RILJ_LOGD ) riljLog ( ( ( ( rr.serialString ( ) ) + "> " ) + ( com.android.internal.telephony.RIL.requestToString ( rr.mRequest ) ) ) ) ; send ( rr ) ; }
Source:
public void setMsisdnNumber ( java.lang.String alphaTag , java.lang.String number , android.os.Message onComplete ) { mNewMsisdn = number ; mNewMsisdnTag = alphaTag ; if ( DBG ) log ( ( ( ( "Set MSISDN: " + ( mNewMsisdnTag ) ) + " " ) + "xxxxxxx" ) ) ; com.android.internal.telephony.uicc.AdnRecord adn = new com.android.internal.telephony.uicc.AdnRecord ( mNewMsisdnTag , mNewMsisdn ) ; new com.android.internal.telephony.uicc.AdnRecordLoader ( mFh ) . updateEF ( adn , com.android.internal.telephony.uicc.EF_MSISDN , getExtFromEf ( com.android.internal.telephony.uicc.EF_MSISDN ) , 1 , null , obtainMessage ( com.android.internal.telephony.uicc.EVENT_SET_MSISDN_DONE , onComplete ) ) ; }

Target:
public void setMsisdnNumber ( java.lang.String alphaTag , java.lang.String number , android.os.Message onComplete ) { mNewMsisdn = number ; mNewMsisdnTag = alphaTag ; if ( DBG ) log ( ( ( ( "Set MSISDN: " + ( mNewMsisdnTag ) ) + " " ) + "xxxxxxx" ) ) ; com.android.internal.telephony.uicc.AdnRecord adn = new com.android.internal.telephony.uicc.AdnRecord ( mNewMsisdnTag , mNewMsisdn ) ; new com.android.internal.telephony.uicc.AdnRecordLoader ( mFh ) . updateEF ( adn , com.android.internal.telephony.uicc.EF_MSISDN , getExtFromEf ( com.android.internal.telephony.uicc.EF_MSISDN ) , 1 , null , obtainMessage ( com.android.internal.telephony.uicc.SIMRecords.EVENT_SET_MSISDN_DONE , onComplete ) ) ; }
Source:
private static void checkName ( @ com.android.annotations.NonNull java.lang.String name , @ com.android.annotations.NonNull java.lang.String displayName ) { if ( name.startsWith ( com.android.builder.BuilderConstants.ANDROID_TEST ) ) { throw new java.lang.RuntimeException ( java.lang.String.format ( "%1$s names cannot start with '%2$s'" , displayName , com.android.builder.BuilderConstants.ANDROID_TEST ) ) ; } if ( name.startsWith ( com.android.builder.BuilderConstants.UI_TEST ) ) { throw new java.lang.RuntimeException ( java.lang.String.format ( "%1$s names cannot start with %2$s" , displayName , com.android.builder.BuilderConstants.UI_TEST ) ) ; } if ( com.android.builder.BuilderConstants.LINT.equals ( name ) ) { throw new java.lang.RuntimeException ( java.lang.String.format ( "%1$s names cannot be %2$s" , displayName , com.android.builder.BuilderConstants.LINT ) ) ; } }

Target:
private static void checkName ( @ com.android.annotations.NonNull java.lang.String name , @ com.android.annotations.NonNull java.lang.String displayName ) { if ( name.startsWith ( com.android.builder.core.BuilderConstants.ANDROID_TEST ) ) { throw new java.lang.RuntimeException ( java.lang.String.format ( "%1$s names cannot start with '%2$s'" , displayName , com.android.builder.core.BuilderConstants.ANDROID_TEST ) ) ; } if ( name.startsWith ( com.android.builder.core.BuilderConstants.UI_TEST ) ) { throw new java.lang.RuntimeException ( java.lang.String.format ( "%1$s names cannot start with %2$s" , displayName , com.android.builder.core.BuilderConstants.UI_TEST ) ) ; } if ( com.android.builder.core.BuilderConstants.LINT.equals ( name ) ) { throw new java.lang.RuntimeException ( java.lang.String.format ( "%1$s names cannot be %2$s" , displayName , com.android.builder.core.BuilderConstants.LINT ) ) ; } }
Source:
public void testGetLocaleAndRegion ( ) throws java.lang.Exception { assertNull ( com.android.tools.lint.detector.api.LintUtils.getLocaleAndRegion ( "" ) ) ; assertNull ( com.android.tools.lint.detector.api.LintUtils.getLocaleAndRegion ( "values" ) ) ; assertNull ( com.android.tools.lint.detector.api.LintUtils.getLocaleAndRegion ( "values-xlarge-port" ) ) ; assertEquals ( "en" , com.android.tools.lint.detector.api.LintUtils.getLocaleAndRegion ( "values-en" ) ) ; assertEquals ( "pt-rPT" , com.android.tools.lint.detector.api.LintUtils.getLocaleAndRegion ( "values-pt-rPT-nokeys" ) ) ; assertEquals ( "zh-rCN" , com.android.tools.lint.detector.api.LintUtils.getLocaleAndRegion ( "values-zh-rCN-keyshidden" ) ) ; assertEquals ( "ms" , com.android.tools.lint.detector.api.LintUtils.getLocaleAndRegion ( "values-ms-keyshidden" ) ) ; }

Target:
public void testGetLocaleAndRegion ( ) throws java.lang.Exception { assertNull ( com.android.tools.lint.detector.api.LintUtils.getLocaleAndRegion ( "" ) ) ; assertNull ( com.android.tools.lint.detector.api.LintUtils.getLocaleAndRegion ( "values" ) ) ; assertNull ( com.android.tools.lint.detector.api.LintUtils.getLocaleAndRegion ( "values-xlarge-port" ) ) ; assertEquals ( "en" , com.android.tools.lint.detector.api.LintUtils.getLocaleAndRegion ( "values-en" ) ) ; assertEquals ( "pt-rPT" , com.android.tools.lint.detector.api.LintUtils.getLocaleAndRegion ( "values-pt-rPT-nokeys" ) ) ; assertEquals ( "b+pt+PT" , com.android.tools.lint.detector.api.LintUtils.getLocaleAndRegion ( "values-b+pt+PT-nokeys" ) ) ; assertEquals ( "zh-rCN" , com.android.tools.lint.detector.api.LintUtils.getLocaleAndRegion ( "values-zh-rCN-keyshidden" ) ) ; assertEquals ( "ms" , com.android.tools.lint.detector.api.LintUtils.getLocaleAndRegion ( "values-ms-keyshidden" ) ) ; }
Source:
public com.android.sdklib.repository.local.LocalPkgInfo getPkgInfo ( @ com.android.annotations.NonNull com.android.sdklib.repository.descriptors.PkgType filter , @ com.android.annotations.NonNull com.android.sdklib.AndroidVersion version ) { assert ( ( filter == ( com.android.sdklib.repository.descriptors.PkgType.PKG_PLATFORMS ) ) || ( filter == ( com.android.sdklib.repository.descriptors.PkgType.PKG_SAMPLES ) ) ) || ( filter == ( com.android.sdklib.repository.descriptors.PkgType.PKG_SOURCES ) ) ; for ( com.android.sdklib.repository.local.LocalPkgInfo pkg : getPkgsInfos ( filter ) ) { com.android.sdklib.repository.descriptors.IPkgDesc d = pkg.getDesc ( ) ; if ( ( d.hasAndroidVersion ( ) ) && ( d.getAndroidVersion ( ) . equals ( version ) ) ) { return pkg ; } } return null ; }

Target:
public com.android.sdklib.repository.local.LocalPkgInfo getPkgInfo ( @ com.android.annotations.NonNull com.android.sdklib.repository.descriptors.PkgType filter , @ com.android.annotations.NonNull com.android.sdklib.AndroidVersion version ) { assert ( ( filter == ( com.android.sdklib.repository.descriptors.PkgType.PKG_PLATFORM ) ) || ( filter == ( com.android.sdklib.repository.descriptors.PkgType.PKG_SAMPLE ) ) ) || ( filter == ( com.android.sdklib.repository.descriptors.PkgType.PKG_SOURCE ) ) ; for ( com.android.sdklib.repository.local.LocalPkgInfo pkg : getPkgsInfos ( filter ) ) { com.android.sdklib.repository.descriptors.IPkgDesc d = pkg.getDesc ( ) ; if ( ( d.hasAndroidVersion ( ) ) && ( d.getAndroidVersion ( ) . equals ( version ) ) ) { return pkg ; } } return null ; }
Source:
public void testHasActionDoesNotMatch ( ) { android.content.Intent intent = new android.content.Intent ( android.content.Intent.ACTION_VIEW ) . addCategory ( "category" ) . setDataAndType ( uri , Context.ACTIVITY_SERVICE ) . putExtra ( "key" , "value" ) ; assertFalse ( android.support.test.espresso.intent.matcher.IntentMatchers.hasAction ( Intent.ACTION_DIAL ) . matches ( intent ) ) ; assertFalse ( android.support.test.espresso.intent.matcher.IntentMatchers.hasAction ( org.hamcrest.Matchers.equalTo ( Intent.ACTION_DIAL ) ) . matches ( intent ) ) ; }

Target:
public void hasActionDoesNotMatch ( ) { android.content.Intent intent = new android.content.Intent ( android.content.Intent.ACTION_VIEW ) . addCategory ( "category" ) . setDataAndType ( uri , Context.ACTIVITY_SERVICE ) . putExtra ( "key" , "value" ) ; org.junit.Assert.assertFalse ( android.support.test.espresso.intent.matcher.IntentMatchers.hasAction ( Intent.ACTION_DIAL ) . matches ( intent ) ) ; org.junit.Assert.assertFalse ( android.support.test.espresso.intent.matcher.IntentMatchers.hasAction ( org.hamcrest.Matchers.equalTo ( Intent.ACTION_DIAL ) ) . matches ( intent ) ) ; }
Source:
private static < K , V > java.util.Map < K , V > filterFiltered ( com.google.common.collect.Maps.AbstractFilteredMap < K , V > map , com.google.common.base.Predicate < ? super java.util.Map.Entry < K , V > > entryPredicate ) { com.google.common.base.Predicate < java.util.Map.Entry < K , V > > predicate = com.google.common.base.Predicates.and ( map.predicate , entryPredicate ) ; return new com.google.common.collect.Maps.FilteredEntryMap < K , V > ( map.unfiltered , predicate ) ; }

Target:
private static < K , V > java.util.Map < K , V > filterFiltered ( com.google.common.collect.Maps.AbstractFilteredMap < K , V > map , com.google.common.base.Predicate < ? super java.util.Map.Entry < K , V > > entryPredicate ) { return new com.google.common.collect.Maps.FilteredEntryMap < K , V > ( map.unfiltered , com.google.common.base.Predicates.< java.util.Map.Entry < K , V > > and ( map.predicate , entryPredicate ) ) ; }
Source:
private void launchCallMsg ( ) { com.android.internal.telephony.cat.TextMessage msg = mCurrentCmd.getCallSettings ( ) . callMsg ; if ( ( ( msg.text ) == null ) || ( ( msg.text.length ( ) ) == 0 ) ) { return ; } msg.title = lastSelectedItem ; android.widget.Toast toast = android.widget.Toast.makeText ( mContext.getApplicationContext ( ) , msg.text , Toast.LENGTH_LONG ) ; toast.setGravity ( Gravity.BOTTOM , 0 , 0 ) ; toast.show ( ) ; }

Target:
private void launchEventMessage ( ) { launchEventMessage ( mCurrentCmd.geTextMessage ( ) ) ; }
Source:
public void testDependency011 ( ) throws java.lang.Exception { com.android.jack.test.helper.IncrementalTestHelper ite = new com.android.jack.test.helper.IncrementalTestHelper ( com.android.jack.TestTools.createTempDir ( "DependenciesTest_" , "_011" ) ) ; ite.addJavaFile ( "jack.incremental" , "A.java" , ( "package jack.incremental; \n" + "public class A { public boolean callTest(Object o) { return o instanceof B;} } \n" ) ) ; java.io.File f = ite.addJavaFile ( "jack.incremental" , "B.java" , ( "package jack.incremental; \n" + "public class B \n" ) ) ; ite.incrementalBuildFromFolder ( ) ; ite.snapshotJackFilesModificationDate ( ) ; ite.deleteJavaFile ( f ) ; try { ite.incrementalBuildFromFolder ( ) ; junit.framework.Assert.fail ( ) ; } catch ( com.android.jack.frontend.FrontendCompilationException e ) { } }

Target:
public void testDependency011 ( ) throws java.lang.Exception { com.android.jack.test.helper.IncrementalTestHelper ite = new com.android.jack.test.helper.IncrementalTestHelper ( com.android.jack.test.toolchain.AbstractTestTools.createTempDir ( ) ) ; ite.addJavaFile ( "jack.incremental" , "A.java" , ( "package jack.incremental; \n" + "public class A { public boolean callTest(Object o) { return o instanceof B;} } \n" ) ) ; java.io.File f = ite.addJavaFile ( "jack.incremental" , "B.java" , ( "package jack.incremental; \n" + "public class B \n" ) ) ; ite.incrementalBuildFromFolder ( ) ; ite.snapshotJackFilesModificationDate ( ) ; ite.deleteJavaFile ( f ) ; try { ite.incrementalBuildFromFolder ( ) ; junit.framework.Assert.fail ( ) ; } catch ( com.android.jack.frontend.FrontendCompilationException e ) { } }
Source:
public void testProviderService_supportsParameter_SupportedKeyClasses_NonKeyClass_Success ( ) throws java.lang.Exception { java.security.Provider provider = new libcore.java.security.ProviderTest.MockProvider ( "MockProvider" ) { public void setup ( ) { put ( "Signature.FOO" , libcore.java.security.ProviderTest.MockSpi.class . getName ( ) ) ; put ( "Signature.FOO SupportedKeyClasses" , libcore.java.security.ProviderTest.MockSpi.class . getName ( ) ) ; } } ; java.security.Security.addProvider ( provider ) ; try { java.security.Provider.Service service = provider.getService ( "Signature" , "FOO" ) ; assertFalse ( service.supportsParameter ( new libcore.javax.crypto.MockKey ( ) ) ) ; } finally { java.security.Security.removeProvider ( provider.getName ( ) ) ; } }

Target:
public void testProviderService_supportsParameter_TypeDoesNotSupportParameter_Failure ( ) throws java.lang.Exception { java.security.Provider provider = new libcore.java.security.ProviderTest.MockProvider ( "MockProvider" ) { public void setup ( ) { put ( "KeyFactory.FOO" , libcore.java.security.ProviderTest.MockSpi.class . getName ( ) ) ; } } ; java.security.Security.addProvider ( provider ) ; try { java.security.Provider.Service service = provider.getService ( "KeyFactory" , "FOO" ) ; try { service.supportsParameter ( new libcore.javax.crypto.MockKey ( ) ) ; fail ( "Should always throw exception" ) ; } catch ( java.security.InvalidParameterException expected ) { } } finally { java.security.Security.removeProvider ( provider.getName ( ) ) ; } }
Source:
public java.lang.StringBuffer format ( java.math.BigInteger number , java.lang.StringBuffer result , java.text.FieldPosition fieldPosition ) { return format ( number , result , fieldPosition , false ) ; }

Target:
public java.text.AttributedCharacterIterator formatToCharacterIterator ( java.lang.Object obj ) { if ( ! ( obj instanceof java.lang.Number ) ) throw new java.lang.IllegalArgumentException ( ) ; java.lang.Number number = ( ( java.lang.Number ) ( obj ) ) ; android.icu.impl.number.FormatQuantity4 fq = new android.icu.impl.number.FormatQuantity4 ( number ) ; java.text.AttributedCharacterIterator result = formatter.formatToCharacterIterator ( fq ) ; return result ; }
Source:
public com.android.jack.server.JackSimpleServer.JackRouter addContainer ( @ javax.annotation.Nonnull java.lang.String fragment , @ javax.annotation.Nonnull org.simpleframework.http.core.Container container ) { registry.put ( fragment , container ) ; return this ; }

Target:
public void handle ( @ javax.annotation.Nonnull org.simpleframework.http.Request request , @ javax.annotation.Nonnull org.simpleframework.http.Response response ) { java.lang.String normalizedPath = request.getPath ( ) . getPath ( ) ; com.android.jack.server.JackSimpleServer.logger.log ( java.util.logging.Level.INFO , ( ( "Route request from '" + normalizedPath ) + "'" ) ) ; org.simpleframework.http.core.Container container = registry.get ( normalizedPath ) ; if ( container != null ) { container.handle ( request , response ) ; } else { primary.handle ( request , response ) ; } }
Source:
public void shutdown ( boolean confirm , boolean wait ) { mContext.enforceCallingOrSelfPermission ( android.Manifest.permission.REBOOT , null ) ; final long ident = android.os.Binder.clearCallingIdentity ( ) ; try { shutdownOrRebootInternal ( true , confirm , null , wait ) ; } finally { android.os.Binder.restoreCallingIdentity ( ident ) ; } }

Target:
public void shutdown ( boolean confirm , java.lang.String reason , boolean wait ) { mContext.enforceCallingOrSelfPermission ( android.Manifest.permission.REBOOT , null ) ; final long ident = android.os.Binder.clearCallingIdentity ( ) ; try { shutdownOrRebootInternal ( true , confirm , reason , wait ) ; } finally { android.os.Binder.restoreCallingIdentity ( ident ) ; } }
Source:
public void test_forNameLString ( ) throws java.lang.Exception { java.lang.ClassLoader originalClassLoader = java.lang.Thread.currentThread ( ) . getContextClassLoader ( ) ; try { java.lang.Thread.currentThread ( ) . setContextClassLoader ( null ) ; assertNotNull ( java.nio.charset.Charset.forName ( "mockCharset00" ) ) ; } finally { java.lang.Thread.currentThread ( ) . setContextClassLoader ( originalClassLoader ) ; } }

Target:
public void testConstructor_IllegalAliases_Middle ( ) { try { new tests.api.java.nio.charset.CharsetTest.MockCharset ( "mockChar" , new java.lang.String [ ] { "mock" , "22##ab" } ) ; fail ( ) ; } catch ( java.nio.charset.IllegalCharsetNameException expected ) { } try { new tests.api.java.nio.charset.CharsetTest.MockCharset ( "mockChar" , new java.lang.String [ ] { "mock" , "22%%ab" } ) ; fail ( ) ; } catch ( java.nio.charset.IllegalCharsetNameException expected ) { } }
Source:
private void broadcastMetaDataChanged ( android.media.MediaMetadata metadata ) { android.content.Intent intent = new android.content.Intent ( AvrcpControllerService.ACTION_TRACK_EVENT ) ; intent.putExtra ( AvrcpControllerService.EXTRA_METADATA , metadata ) ; if ( com.android.bluetooth.avrcpcontroller.AvrcpControllerStateMachine.DBG ) { android.util.Log.d ( com.android.bluetooth.avrcpcontroller.AvrcpControllerStateMachine.TAG , ( " broadcastMetaDataChanged = " + ( metadata.getDescription ( ) ) ) ) ; } mContext.sendBroadcast ( intent , ProfileService.BLUETOOTH_PERM ) ; }

Target:
private void broadcastMetaDataChanged ( android.media.MediaMetadata metadata ) { android.content.Intent intent = new android.content.Intent ( AvrcpControllerService.ACTION_TRACK_EVENT ) ; intent.putExtra ( AvrcpControllerService.EXTRA_METADATA , metadata ) ; if ( com.android.bluetooth.avrcpcontroller.AvrcpControllerStateMachine.VDBG ) { android.util.Log.d ( com.android.bluetooth.avrcpcontroller.AvrcpControllerStateMachine.TAG , ( " broadcastMetaDataChanged = " + ( metadata.getDescription ( ) ) ) ) ; } mContext.sendBroadcast ( intent , ProfileService.BLUETOOTH_PERM ) ; }
Source:
private void doAdd ( ) { com.google.gct.testing.GoogleCloudTestingConfiguration newConfiguration = ( ( selectedConfiguration ) != null ) ? selectedConfiguration.copy ( "Copy of " ) : new com.google.gct.testing.GoogleCloudTestingConfiguration ( facet ) ; newConfiguration.setIcon ( GoogleCloudTestingConfigurationFactory.DEFAULT_ICON ) ; int addIndex = ( ( selectedConfiguration ) == null ) ? editableConfigurations.size ( ) : ( editableConfigurations.indexOf ( selectedConfiguration ) ) + 1 ; editableConfigurations.add ( addIndex , newConfiguration ) ; addConfigurationToTree ( addIndex , newConfiguration , true ) ; selectedConfiguration = newConfiguration ; updateConfigurationTree ( ) ; }

Target:
private void doAdd ( ) { com.google.gct.testing.GoogleCloudTestingConfigurationImpl newConfiguration = ( ( selectedConfiguration ) != null ) ? selectedConfiguration.copy ( "Copy of " ) : new com.google.gct.testing.GoogleCloudTestingConfigurationImpl ( facet ) ; newConfiguration.setIcon ( GoogleCloudTestingConfigurationFactoryImpl.DEFAULT_ICON ) ; int addIndex = ( ( selectedConfiguration ) == null ) ? editableConfigurations.size ( ) : ( editableConfigurations.indexOf ( selectedConfiguration ) ) + 1 ; editableConfigurations.add ( addIndex , newConfiguration ) ; addConfigurationToTree ( addIndex , newConfiguration , true ) ; selectedConfiguration = newConfiguration ; updateConfigurationTree ( ) ; }