auphong2707/dl4se-code-review-dataset huggingface dataset:
Source:
public void getAllowedCarriers ( android.os.Message result ) { android.hardware.radio.V1_0.IRadio radioProxy = getRadioProxy ( result ) ; if ( radioProxy != null ) { com.android.internal.telephony.RILRequest rr = obtainRequest ( com.android.internal.telephony.RIL_REQUEST_GET_ALLOWED_CARRIERS , result , mRILDefaultWorkSource ) ; if ( com.android.internal.telephony.RIL.RILJ_LOGD ) { riljLog ( ( ( ( rr.serialString ( ) ) + "> " ) + ( com.android.internal.telephony.RIL.requestToString ( rr.mRequest ) ) ) ) ; } try { radioProxy.getAllowedCarriers ( rr.mSerial ) ; } catch ( android.os.RemoteException | java.lang.RuntimeException e ) { handleRadioProxyExceptionForRR ( rr , "getAllowedCarriers" , e ) ; } } }

Target:
public void pullLceData ( android.os.Message response ) { android.hardware.radio.V1_0.IRadio radioProxy = getRadioProxy ( response ) ; if ( radioProxy != null ) { com.android.internal.telephony.RILRequest rr = obtainRequest ( com.android.internal.telephony.RIL_REQUEST_PULL_LCEDATA , response , mRILDefaultWorkSource ) ; if ( com.android.internal.telephony.RIL.RILJ_LOGD ) { riljLog ( ( ( ( rr.serialString ( ) ) + "> " ) + ( com.android.internal.telephony.RIL.requestToString ( rr.mRequest ) ) ) ) ; } try { radioProxy.pullLceData ( rr.mSerial ) ; } catch ( android.os.RemoteException | java.lang.RuntimeException e ) { handleRadioProxyExceptionForRR ( rr , "pullLceData" , e ) ; } } }
Source:
protected void replaceImpl ( @ javax.annotation.Nonnull com.android.jack.ir.ast.JNode existingNode , @ javax.annotation.Nonnull com.android.jack.ir.ast.JNode newNode ) throws java.lang.UnsupportedOperationException { if ( ( lhs ) == existingNode ) { lhs = ( ( com.android.jack.ir.ast.JSsaVariableRef ) ( newNode ) ) ; return ; } for ( com.android.jack.ir.ast.cfg.JBasicBlock pred : rhs.keySet ( ) ) { if ( ( rhs.get ( pred ) ) == existingNode ) { rhs.put ( pred , ( ( com.android.jack.ir.ast.JSsaVariableRef ) ( newNode ) ) ) ; return ; } } super . replaceImpl ( existingNode , newNode ) ; }

Target:
protected void replaceImpl ( @ javax.annotation.Nonnull com.android.jack.ir.ast.JNode existingNode , @ javax.annotation.Nonnull com.android.jack.ir.ast.JNode newNode ) throws java.lang.UnsupportedOperationException { if ( ( lhs ) == existingNode ) { lhs = ( ( com.android.jack.ir.ast.JSsaVariableDefRef ) ( newNode ) ) ; return ; } for ( com.android.jack.ir.ast.cfg.JBasicBlock pred : rhs.keySet ( ) ) { if ( ( rhs.get ( pred ) ) == existingNode ) { rhs.put ( pred , ( ( com.android.jack.ir.ast.JSsaVariableUseRef ) ( newNode ) ) ) ; return ; } } super . replaceImpl ( existingNode , newNode ) ; }
Source:
public static void setAdb ( java.lang.String adb , boolean startAdb ) { if ( adb != null ) { com.android.ide.eclipse.hierarchyviewer.HierarchyViewerPlugin.plugin.getPreferenceStore ( ) . setValue ( com.android.ide.eclipse.hierarchyviewer.HierarchyViewerPlugin.ADB_LOCATION , adb ) ; if ( startAdb ) { new java.lang.Thread ( ) { @ java.lang.Override public void run ( ) { com.android.hierarchyviewerlib.HierarchyViewerDirector.getDirector ( ) . initDebugBridge ( ) ; com.android.hierarchyviewerlib.HierarchyViewerDirector.getDirector ( ) . startListenForDevices ( ) ; com.android.hierarchyviewerlib.HierarchyViewerDirector.getDirector ( ) . populateDeviceSelectionModel ( ) ; } } . start ( ) ; } } }

Target:
public static void setAdb ( java.lang.String adb , boolean startAdb ) { if ( adb != null ) { com.android.ide.eclipse.hierarchyviewer.HierarchyViewerPlugin.sPlugin.getPreferenceStore ( ) . setValue ( com.android.ide.eclipse.hierarchyviewer.HierarchyViewerPlugin.ADB_LOCATION , adb ) ; if ( startAdb ) { new java.lang.Thread ( ) { @ java.lang.Override public void run ( ) { com.android.hierarchyviewerlib.HierarchyViewerDirector.getDirector ( ) . initDebugBridge ( ) ; com.android.hierarchyviewerlib.HierarchyViewerDirector.getDirector ( ) . startListenForDevices ( ) ; com.android.hierarchyviewerlib.HierarchyViewerDirector.getDirector ( ) . populateDeviceSelectionModel ( ) ; } } . start ( ) ; } } }
Source:
public void testConstructor_NullCanonicalName ( ) { try { tests.api.java.nio.charset.CharsetTest.MockCharset c = new tests.api.java.nio.charset.CharsetTest.MockCharset ( null , new java.lang.String [ ] { "mock" } ) ; fail ( "Should throw NullPointerException!" ) ; } catch ( java.lang.NullPointerException e ) { } }

Target:
public void test_UTF_16LE ( ) throws java.lang.Exception { java.nio.charset.Charset cs = java.nio.charset.Charset.forName ( "UTF-16LE" ) ; assertEncodes ( cs , "a٦" , 'a' , 0 , 102 , 6 ) ; assertDecodes ( cs , "﻿a٦" , 255 , 254 , 'a' , 0 , 102 , 6 ) ; assertDecodes ( cs , "�a٦" , 254 , 255 , 'a' , 0 , 102 , 6 ) ; assertDecodes ( cs , "a٦" , 'a' , 0 , 102 , 6 ) ; }
Source:
public void setMasterMute ( boolean state , int flags ) { android.media.IAudioService service = android.media.AudioManager.getService ( ) ; try { service.setMasterMute ( state , flags , mApplicationContext.getOpPackageName ( ) , mICallBack ) ; } catch ( android.os.RemoteException e ) { android.util.Log.e ( android.media.AudioManager.TAG , "Dead object in setMasterMute" , e ) ; } }

Target:
public void setMasterMute ( boolean state , int flags ) { android.media.IAudioService service = android.media.AudioManager.getService ( ) ; try { service.setMasterMute ( state , flags , getContext ( ) . getOpPackageName ( ) , mICallBack ) ; } catch ( android.os.RemoteException e ) { android.util.Log.e ( android.media.AudioManager.TAG , "Dead object in setMasterMute" , e ) ; } }
Source:
public void testUpdateRingBackTone ( ) { mMediaProfile.mAudioDirection = com.android.ims.ImsStreamMediaProfile.DIRECTION_INACTIVE ; mImsCallProfile.mMediaProfile = mMediaProfile ; mImsCallUT.update ( null , mImsCall , Call.State.ALERTING ) ; org.mockito.Mockito.verify ( mImsPhone , org.mockito.Mockito.times ( 1 ) ) . startRingbackTone ( ) ; org.junit.Assert.assertEquals ( Call.State.ALERTING , mImsCallUT.getState ( ) ) ; mImsCallUT.update ( null , mImsCall , Call.State.ACTIVE ) ; org.mockito.Mockito.verify ( mImsPhone , org.mockito.Mockito.times ( 1 ) ) . stopRingbackTone ( ) ; org.junit.Assert.assertEquals ( Call.State.ACTIVE , mImsCallUT.getState ( ) ) ; }

Target:
public void testUpdateRingBackTone ( ) { mMediaProfile.mAudioDirection = android.telephony.ims.ImsStreamMediaProfile.DIRECTION_INACTIVE ; mImsCallProfile.mMediaProfile = mMediaProfile ; mImsCallUT.update ( null , mImsCall , Call.State.ALERTING ) ; org.mockito.Mockito.verify ( mImsPhone , org.mockito.Mockito.times ( 1 ) ) . startRingbackTone ( ) ; org.junit.Assert.assertEquals ( Call.State.ALERTING , mImsCallUT.getState ( ) ) ; mImsCallUT.update ( null , mImsCall , Call.State.ACTIVE ) ; org.mockito.Mockito.verify ( mImsPhone , org.mockito.Mockito.times ( 1 ) ) . stopRingbackTone ( ) ; org.junit.Assert.assertEquals ( Call.State.ACTIVE , mImsCallUT.getState ( ) ) ; }
Source:
public static void main ( java.lang.String [ ] args ) throws java.lang.Exception { java.nio.file.Path dumpDirectory = com.google.devtools.build.android.desugar.Desugar.createAndRegisterLambdaDumpDirectory ( ) ; com.google.devtools.build.android.desugar.Desugar.verifyLambdaDumpDirectoryRegistered ( dumpDirectory ) ; com.google.devtools.build.android.desugar.Desugar.Options options = com.google.devtools.build.android.desugar.Desugar.parseCommandLineOptions ( args ) ; if ( options.verbose ) { java.lang.System.out.printf ( "Lambda classes will be written under %s%n" , dumpDirectory ) ; } new com.google.devtools.build.android.desugar.Desugar ( options , dumpDirectory ) . desugar ( ) ; }

Target:
public static void main ( java.lang.String [ ] args ) throws java.lang.Exception { java.nio.file.Path dumpDirectory = com.google.devtools.build.android.desugar.Desugar.createAndRegisterLambdaDumpDirectory ( ) ; com.google.devtools.build.android.desugar.Desugar.verifyLambdaDumpDirectoryRegistered ( dumpDirectory ) ; com.google.devtools.build.android.desugar.Desugar.DesugarOptions options = com.google.devtools.build.android.desugar.Desugar.parseCommandLineOptions ( args ) ; if ( options.verbose ) { java.lang.System.out.printf ( "Lambda classes will be written under %s%n" , dumpDirectory ) ; } new com.google.devtools.build.android.desugar.Desugar ( options , dumpDirectory ) . desugar ( ) ; }
Source:
public void testNewInstanceString_ByteArrayStringConstructor ( ) { runTestNewInstanceString ( "([BLjava/lang/String;)V" , new org.apache.harmony.jpda.tests.jdwp.ClassType.ConstructorArgumentsProvider ( ) { @ java.lang.Override public void provideConstructorArguments ( java.util.List < org.apache.harmony.jpda.tests.framework.jdwp.Value > constructorArguments ) { long debuggeeClassId = getClassIDBySignature ( getDebuggeeClassSignature ( ) ) ; org.apache.harmony.jpda.tests.framework.jdwp.Value byteArrayValue = getStaticFieldValue ( debuggeeClassId , "BYTE_ARRAY" ) ; org.apache.harmony.jpda.tests.framework.jdwp.Value stringCharsetValue = getStaticFieldValue ( debuggeeClassId , "STRING_CHARSET" ) ; constructorArguments.add ( byteArrayValue ) ; constructorArguments.add ( stringCharsetValue ) ; } } ) ; }

Target:
public void testNewInstanceString_ByteArrayStringConstructor ( ) { runTestNewInstanceString ( "([BLjava/lang/String;)V" , "my test string" , new org.apache.harmony.jpda.tests.jdwp.ClassType.ConstructorArgumentsProvider ( ) { @ java.lang.Override public void provideConstructorArguments ( java.util.List < org.apache.harmony.jpda.tests.framework.jdwp.Value > constructorArguments ) { long debuggeeClassId = getClassIDBySignature ( getDebuggeeClassSignature ( ) ) ; org.apache.harmony.jpda.tests.framework.jdwp.Value byteArrayValue = getStaticFieldValue ( debuggeeClassId , "BYTE_ARRAY" ) ; org.apache.harmony.jpda.tests.framework.jdwp.Value stringCharsetValue = getStaticFieldValue ( debuggeeClassId , "STRING_CHARSET" ) ; constructorArguments.add ( byteArrayValue ) ; constructorArguments.add ( stringCharsetValue ) ; } } ) ; }
Source:
public void cacheMiss ( ) throws java.lang.Exception { mCacheQueue.add ( mRequest ) ; mCacheQueue.waitUntilEmpty ( com.android.volley.CacheDispatcherTest.TIMEOUT_MILLIS ) ; assertFalse ( mDelivery.wasEitherResponseCalled ( ) ) ; assertTrue ( ( ( mNetworkQueue.size ( ) ) > 0 ) ) ; com.android.volley.Request request = mNetworkQueue.take ( ) ; assertNull ( request.getCacheEntry ( ) ) ; }

Target:
public void expiredCacheHit ( ) throws java.lang.Exception { com.android.volley.Cache.Entry entry = com.android.volley.utils.CacheTestUtils.makeRandomCacheEntry ( null , true , true ) ; org.mockito.Mockito.when ( mCache.get ( org.mockito.Matchers.anyString ( ) ) ) . thenReturn ( entry ) ; mDispatcher.processRequest ( mRequest ) ; com.android.volley.CacheDispatcherTest.verifyNoResponse ( mDelivery ) ; org.mockito.Mockito.verify ( mNetworkQueue ) . put ( mRequest ) ; org.junit.Assert.assertSame ( entry , mRequest.getCacheEntry ( ) ) ; }
Source:
public float getTextRunAdvances ( int start , int end , int contextStart , int contextEnd , int flags , float [ ] advances , int advancesIndex , android.graphics.Paint p ) { int count = end - start ; int contextCount = contextEnd - contextStart ; return p.getTextRunAdvances ( mChars , ( start + ( mStart ) ) , count , ( contextStart + ( mStart ) ) , contextCount , flags , advances , advancesIndex ) ; }

Target:
public void drawTextRun ( android.graphics.Canvas c , int start , int end , int contextStart , int contextEnd , float x , float y , boolean isRtl , android.graphics.Paint p ) { int count = end - start ; int contextCount = contextEnd - contextStart ; c.drawTextRun ( mChars , ( start + ( mStart ) ) , count , ( contextStart + ( mStart ) ) , contextCount , x , y , isRtl , p ) ; }
Source:
public void testReadAfterWriteWithNoUserStore ( ) throws java.lang.Exception { com.android.server.wifi.WifiConfigStoreData writeData = createSingleOpenNetworkStoreData ( ) ; mWifiConfigStore.write ( true , writeData ) ; com.android.server.wifi.WifiConfigStoreData readData = mWifiConfigStore.read ( ) ; com.android.server.wifi.WifiConfigStoreDataTest.assertConfigStoreDataEqual ( writeData , readData ) ; }

Target:
public void deserializeData ( org.xmlpull.v1.XmlPullParser in , int outerTagDepth , boolean shared ) throws java.io.IOException , org.xmlpull.v1.XmlPullParserException { if ( shared ) { mShareData = ( ( java.lang.String ) ( com.android.server.wifi.util.XmlUtil.readNextValueWithName ( in , com.android.server.wifi.WifiConfigStoreTest.MockStoreData.XML_TAG_TEST_DATA ) ) ) ; } else { mUserData = ( ( java.lang.String ) ( com.android.server.wifi.util.XmlUtil.readNextValueWithName ( in , com.android.server.wifi.WifiConfigStoreTest.MockStoreData.XML_TAG_TEST_DATA ) ) ) ; } }
Source:
public void testConstructor ( ) throws java.lang.Exception { libcore.tzdata.update2.DistroVersion distroVersion = new libcore.tzdata.update2.DistroVersion ( 1 , 2 , libcore.tzdata.update2.DistroVersionTest.VALID_RULES_VERSION , 3 ) ; assertEquals ( 1 , distroVersion.formatMajorVersion ) ; assertEquals ( 2 , distroVersion.formatMinorVersion ) ; assertEquals ( libcore.tzdata.update2.DistroVersionTest.VALID_RULES_VERSION , distroVersion.rulesVersion ) ; assertEquals ( 3 , distroVersion.revision ) ; }

Target:
public void testConstructor ( ) throws java.lang.Exception { libcore.tzdata.shared2.DistroVersion distroVersion = new libcore.tzdata.shared2.DistroVersion ( 1 , 2 , libcore.tzdata.shared2.DistroVersionTest.VALID_RULES_VERSION , 3 ) ; assertEquals ( 1 , distroVersion.formatMajorVersion ) ; assertEquals ( 2 , distroVersion.formatMinorVersion ) ; assertEquals ( libcore.tzdata.shared2.DistroVersionTest.VALID_RULES_VERSION , distroVersion.rulesVersion ) ; assertEquals ( 3 , distroVersion.revision ) ; }
Source:
protected synchronized java.io.InputStream getInputStream ( ) throws java.io.IOException { if ( isClosedOrPending ( ) ) { throw new java.io.IOException ( "Socket Closed" ) ; } if ( shut_rd ) { throw new java.io.IOException ( "Socket input is shutdown" ) ; } if ( ( socketInputStream ) == null ) { socketInputStream = new java.net.SocketInputStream ( this ) ; } return socketInputStream ; }

Target:
protected synchronized java.io.InputStream getInputStream ( ) throws java.io.IOException { synchronized ( fdLock ) { if ( isClosedOrPending ( ) ) throw new java.io.IOException ( "Socket Closed" ) ; if ( shut_rd ) throw new java.io.IOException ( "Socket input is shutdown" ) ; if ( ( socketInputStream ) == null ) socketInputStream = new java.net.SocketInputStream ( this ) ; } return socketInputStream ; }
Source:
public void setVoicemailDonationEnabled ( android.content.Context context , android.telecom.PhoneAccountHandle phoneAccountHandle , boolean enabled ) { com.android.voicemail.impl.settings.VisualVoicemailSettingsUtil.setVoicemailDonationEnabled ( context , phoneAccountHandle , enabled ) ; }

Target:
public void setVoicemailDonationEnabled ( android.content.Context context , android.telecom.PhoneAccountHandle phoneAccountHandle , boolean enabled ) { if ( enabled ) { com.android.dialer.common.Assert.checkArgument ( ( ( isVoicemailTranscriptionAvailable ( context , phoneAccountHandle ) ) && ( isVoicemailTranscriptionEnabled ( context , phoneAccountHandle ) ) ) , ( "should not be able to enable donation without transcription " + "available(value: %b) and enabled (value:%b) for account:%s" ) , isVoicemailTranscriptionAvailable ( context , phoneAccountHandle ) , isVoicemailTranscriptionEnabled ( context , phoneAccountHandle ) , phoneAccountHandle.toString ( ) ) ; } com.android.voicemail.impl.settings.VisualVoicemailSettingsUtil.setVoicemailDonationEnabled ( context , phoneAccountHandle , enabled ) ; }
Source:
public void visitConstructor ( @ com.android.annotations.NonNull com.android.tools.lint.detector.api.JavaContext context , @ com.android.annotations.Nullable lombok.ast.AstVisitor visitor , @ com.android.annotations.NonNull lombok.ast.ConstructorInvocation node , @ com.android.annotations.NonNull com.android.tools.lint.client.api.JavaParser.ResolvedMethod constructor ) { com.android.tools.lint.checks.CleanupDetector.checkRecycled ( context , node , constructor.getContainingClass ( ) . getSignature ( ) , com.android.tools.lint.checks.CleanupDetector.RELEASE ) ; }

Target:
public void visitConstructor ( @ com.android.annotations.NonNull com.android.tools.lint.detector.api.JavaContext context , @ com.android.annotations.Nullable com.intellij.psi.JavaElementVisitor visitor , @ com.android.annotations.NonNull com.intellij.psi.PsiNewExpression node , @ com.android.annotations.NonNull com.intellij.psi.PsiMethod constructor ) { com.intellij.psi.PsiClass containingClass = constructor.getContainingClass ( ) ; if ( containingClass != null ) { java.lang.String type = containingClass.getQualifiedName ( ) ; if ( type != null ) { com.android.tools.lint.checks.CleanupDetector.checkRecycled ( context , node , type , com.android.tools.lint.checks.CleanupDetector.RELEASE ) ; } } }
Source:
public void stopStreaming ( ) throws android.telephony.mbms.MbmsException { if ( ( mService ) == null ) { throw new java.lang.IllegalStateException ( "No streaming service attached" ) ; } try { mService.stopStreaming ( mSubscriptionId , mServiceInfo.getServiceId ( ) ) ; } catch ( android.os.RemoteException e ) { android.util.Log.w ( android.telephony.mbms.StreamingService.LOG_TAG , "Remote process died" ) ; mService = null ; throw new android.telephony.mbms.MbmsException ( MbmsException.ERROR_MIDDLEWARE_LOST ) ; } }

Target:
public void stopStreaming ( ) { if ( ( mService ) == null ) { throw new java.lang.IllegalStateException ( "No streaming service attached" ) ; } try { mService.stopStreaming ( mSubscriptionId , mServiceInfo.getServiceId ( ) ) ; } catch ( android.os.RemoteException e ) { android.util.Log.w ( android.telephony.mbms.StreamingService.LOG_TAG , "Remote process died" ) ; mService = null ; sendErrorToApp ( MbmsException.ERROR_MIDDLEWARE_LOST , null ) ; } finally { mParentSession.onStreamingServiceStopped ( this ) ; } }
Source:
private static void doFollowReferencesTestRoot ( ) { Main.A a = Main.createTree ( ) ; Main.doFollowReferencesTestImpl ( null , java.lang.Integer.MAX_VALUE , ( - 1 ) , a ) ; Main.doFollowReferencesTestImpl ( a , java.lang.Integer.MAX_VALUE , ( - 1 ) , a ) ; }

Target:
private static void doFollowReferencesTestRoot ( ) { Main.Verifier v = new Main.Verifier ( ) ; Main.tagClasses ( v ) ; Main.A a = Main.createTree ( v ) ; Main.doFollowReferencesTestImpl ( null , java.lang.Integer.MAX_VALUE , ( - 1 ) , a , v , null ) ; Main.doFollowReferencesTestImpl ( a.foo , java.lang.Integer.MAX_VALUE , ( - 1 ) , a , v , "2@1000" ) ; }
Source:
public void action ( com.android.ide.common.api.MenuAction action , final java.lang.String valueId , java.lang.Boolean newValue ) { java.lang.String actionId = action.getId ( ) ; final com.android.ide.common.api.INode node = selectedNode ; if ( actionId.equals ( "_orientation" ) ) { node.editXml ( ( "Change LinearLayout " + ( com.android.ide.common.layout.LinearLayoutRule.ATTR_ORIENTATION ) ) , new com.android.ide.common.api.INodeHandler ( ) { public void handle ( com.android.ide.common.api.INode n ) { node.setAttribute ( com.android.ide.common.layout.ANDROID_URI , com.android.ide.common.layout.LinearLayoutRule.ATTR_ORIENTATION , valueId ) ; } } ) ; } }

Target:
public void action ( com.android.ide.common.api.MenuAction action , final java.lang.String valueId , java.lang.Boolean newValue ) { java.lang.String actionId = action.getId ( ) ; final com.android.ide.common.api.INode node = selectedNode ; if ( actionId.equals ( "_orientation" ) ) { node.editXml ( ( "Change LinearLayout " + ( com.android.ide.common.layout.LayoutConstants.ATTR_ORIENTATION ) ) , new com.android.ide.common.api.INodeHandler ( ) { public void handle ( com.android.ide.common.api.INode n ) { node.setAttribute ( com.android.ide.common.layout.LayoutConstants.ANDROID_URI , com.android.ide.common.layout.LayoutConstants.ATTR_ORIENTATION , valueId ) ; } } ) ; } }
Source:
public java.util.Collection < com.android.ide.eclipse.adt.internal.resources.manager.ProjectResourceItem > getResources ( com.android.resources.ResourceType type , com.android.ide.eclipse.adt.internal.resources.manager.ProjectResources projectResources ) { com.android.ide.eclipse.adt.internal.resources.manager.ProjectResourceItem item = projectResources.findResourceItem ( type , mResourceName ) ; java.util.ArrayList < com.android.ide.eclipse.adt.internal.resources.manager.ProjectResourceItem > items = new java.util.ArrayList < com.android.ide.eclipse.adt.internal.resources.manager.ProjectResourceItem > ( ) ; if ( item == null ) { item = new com.android.ide.eclipse.adt.internal.resources.manager.ConfigurableResourceItem ( mResourceName ) ; items.add ( item ) ; } item.add ( this ) ; return items ; }

Target:
protected void dispose ( ) { getFolder ( ) . getRepository ( ) . removeFile ( mType , this ) ; }
Source:
public void testInnerClassTwoParameters ( ) throws java.lang.Exception { java.lang.reflect.Constructor < ? > constructor = libcore.java.lang.reflect.ParameterTest.InnerClass.class . getDeclaredConstructor ( libcore.java.lang.reflect.ParameterTest.class , java.lang.String.class ) ; libcore.java.lang.reflect.ParameterTest.ExecutableTestHelper helper = new libcore.java.lang.reflect.ParameterTest.ExecutableTestHelper ( constructor ) ; helper.checkStandardParametersBehavior ( ) . checkParametersToString ( "[libcore.java.lang.reflect.ParameterTest arg0, java.lang.String arg1]" ) . checkParametersMetadataNotAvailable ( ) . checkParametersNoVarArgs ( ) ; helper.getParameterTestHelper ( 0 ) . checkGetType ( libcore.java.lang.reflect.ParameterTest.class ) . checkGetParameterizedType ( "class libcore.java.lang.reflect.ParameterTest" ) ; helper.getParameterTestHelper ( 1 ) . checkGetType ( java.lang.String.class ) . checkGetParameterizedType ( "class java.lang.String" ) ; }

Target:
private static void checkSingleStringParameter_withMetadata ( java.lang.reflect.Executable executable ) { libcore.java.lang.reflect.ParameterTest.ExecutableTestHelper helper = new libcore.java.lang.reflect.ParameterTest.ExecutableTestHelper ( executable ) ; helper.checkStandardParametersBehavior ( ) . checkParametersToString ( "[java.lang.String p0]" ) . checkParametersNoVarArgs ( ) ; helper.getParameterTestHelper ( 0 ) . checkGetType ( java.lang.String.class ) . checkName ( true , "p0" ) . checkModifiers ( 0 ) . checkImplicitAndSynthetic ( false , false ) . checkGetParameterizedType ( "class java.lang.String" ) ; }
Source:
public int adjustSystemUiVisibilityLw ( int visibility ) { mStatusBarController.adjustSystemUiVisibilityLw ( mLastSystemUiFlags , visibility ) ; mNavigationBarController.adjustSystemUiVisibilityLw ( mLastSystemUiFlags , visibility ) ; mResettingSystemUiFlags &= visibility ; return ( visibility & ( ~ ( mResettingSystemUiFlags ) ) ) & ( ~ ( mForceClearedSystemUiFlags ) ) ; }

Target:
public int adjustSystemUiVisibilityLw ( int visibility ) { mStatusBarController.adjustSystemUiVisibilityLw ( mLastSystemUiFlags , visibility ) ; mNavigationBarController.adjustSystemUiVisibilityLw ( mLastSystemUiFlags , visibility ) ; mRecentsVisible = ( visibility & ( android.view.View.RECENT_APPS_VISIBLE ) ) > 0 ; mResettingSystemUiFlags &= visibility ; return ( visibility & ( ~ ( mResettingSystemUiFlags ) ) ) & ( ~ ( mForceClearedSystemUiFlags ) ) ; }
Source:
public boolean matchesName ( @ com.android.annotations.NonNull java.lang.String name ) { int length = name.length ( ) ; if ( ( mChars.length ) != length ) { return false ; } for ( int i = 0 ; i < length ; i ++ ) { if ( ( mChars [ i ] ) != ( name.charAt ( i ) ) ) { return false ; } } return true ; }

Target:
public boolean matchesName ( @ com.android.annotations.NonNull java.lang.String name ) { return com.android.tools.lint.EcjParser.sameChars ( name , mChars ) ; }
Source:
public static void setMultiprocessEnabled ( boolean enabled ) { synchronized ( android.webkit.WebViewZygote.sLock ) { android.webkit.WebViewZygote.sMultiprocessEnabled = enabled ; final java.lang.String serviceName = android.webkit.WebViewZygote.getServiceNameLocked ( ) ; if ( serviceName == null ) return ; if ( enabled ) { if ( ! ( android.webkit.WebViewZygote.sStartedService ) ) { android.os.SystemService.start ( serviceName ) ; android.webkit.WebViewZygote.sStartedService = true ; } } else { android.os.SystemService.stop ( serviceName ) ; android.webkit.WebViewZygote.sStartedService = false ; android.webkit.WebViewZygote.sZygote = null ; } } }

Target:
public static void setMultiprocessEnabled ( boolean enabled ) { synchronized ( android.webkit.WebViewZygote.sLock ) { android.webkit.WebViewZygote.sMultiprocessEnabled = enabled ; if ( enabled ) { android.webkit.WebViewZygote.connectToZygoteIfNeededLocked ( ) ; } else { android.webkit.WebViewZygote.stopZygoteLocked ( ) ; } } }
Source:
private static void addModuleForAccessingCallDetails ( android.content.Context context , com.android.dialer.dialercontact.DialerContact dialerContact , java.util.List < com.android.dialer.contactactions.ContactActionModule > modules ) { com.android.dialer.calldetails.CallDetailsEntries callDetailsEntries = com.android.dialer.calldetails.CallDetailsEntries.getDefaultInstance ( ) ; boolean canReportInaccurateNumber = false ; boolean canSupportAssistedDialing = false ; modules.add ( new com.android.dialer.contactactions.IntentModule ( context , com.android.dialer.calldetails.CallDetailsActivity.newInstance ( context , callDetailsEntries , dialerContact , canReportInaccurateNumber , canSupportAssistedDialing ) , R.string.call_details_menu_label , R.drawable.quantum_ic_info_outline_vd_theme_24 ) ) ; }

Target:
private static void addModuleForAccessingCallDetails ( android.content.Context context , com.android.dialer.calllog.model.CoalescedRow row , java.util.List < com.android.dialer.contactactions.ContactActionModule > modules ) { boolean canReportInaccurateNumber = false ; boolean canSupportAssistedDialing = false ; modules.add ( new com.android.dialer.contactactions.IntentModule ( context , com.android.dialer.calldetails.CallDetailsActivity.newInstance ( context , row.coalescedIds ( ) , com.android.dialer.calllog.ui.menu.Modules.createDialerContactFromRow ( row ) , canReportInaccurateNumber , canSupportAssistedDialing ) , R.string.call_details_menu_label , R.drawable.quantum_ic_info_outline_vd_theme_24 ) ) ; }
Source:
public void onReceive ( android.content.Context context , android.content.Intent intent ) { if ( Intent.ACTION_DOCK_EVENT.equals ( intent.getAction ( ) ) ) { mDockMode = intent.getIntExtra ( Intent.EXTRA_DOCK_STATE , Intent.EXTRA_DOCK_STATE_UNDOCKED ) ; } else { try { android.app.IUiModeManager uiModeService = IUiModeManager.Stub.asInterface ( android.os.ServiceManager.getService ( Context.UI_MODE_SERVICE ) ) ; mUiMode = uiModeService.getCurrentModeType ( ) ; } catch ( android.os.RemoteException e ) { } } updateRotation ( true ) ; synchronized ( mLock ) { updateOrientationListenerLp ( ) ; } }

Target:
public void goingToSleep ( int why ) { android.util.EventLog.writeEvent ( 70000 , 0 ) ; if ( com.android.internal.policy.impl.PhoneWindowManager.DEBUG_WAKEUP ) android.util.Slog.i ( com.android.internal.policy.impl.PhoneWindowManager.TAG , "Going to sleep..." ) ; synchronized ( mLock ) { mAwake = false ; mKeyguardDrawComplete = false ; updateWakeGestureListenerLp ( ) ; updateOrientationListenerLp ( ) ; updateLockScreenTimeout ( ) ; } if ( ( mKeyguardDelegate ) != null ) { mKeyguardDelegate.onScreenTurnedOff ( why ) ; } }
Source:
public static void setup ( ) throws java.lang.Exception { java.io.File coreOut = com.android.jack.TestTools.createTempFile ( "core" , ".zip" ) ; com.android.jack.TestTools.compileSourceToJack ( new com.android.jack.Options ( ) , com.android.jack.ToolchainTest.CORE_SOURCELIST , null , coreOut , true ) ; com.android.jack.ToolchainTest.corePath = coreOut ; }

Target:
public static void setup ( ) throws java.lang.Exception { com.android.jack.ToolchainTest.CORE_SOURCELIST = com.android.jack.TestTools.getTargetLibSourcelist ( "core" ) ; com.android.jack.ToolchainTest.BOUNCY_SOURCELIST = com.android.jack.TestTools.getTargetLibSourcelist ( "bouncycastle" ) ; com.android.jack.ToolchainTest.JUNIT_SOURCELIST = com.android.jack.TestTools.getHostLibSourcelist ( "junit4-jack" ) ; java.io.File coreOut = com.android.jack.TestTools.createTempFile ( "core" , ".zip" ) ; com.android.jack.TestTools.compileSourceToJack ( new com.android.jack.Options ( ) , com.android.jack.ToolchainTest.CORE_SOURCELIST , null , coreOut , true ) ; com.android.jack.ToolchainTest.corePath = coreOut ; }
Source:
public void removeAttachment ( boolean notify ) { mAttachmentType = com.android.mms.data.WorkingMessage.TEXT ; mSlideshow = null ; if ( ( mMessageUri ) != null ) { asyncDelete ( mMessageUri , null , null ) ; mMessageUri = null ; } updateState ( com.android.mms.data.WorkingMessage.HAS_ATTACHMENT , false , notify ) ; if ( notify ) { mStatusListener.onAttachmentChanged ( ) ; } }

Target:
public void removeAttachment ( boolean notify ) { com.android.mms.data.WorkingMessage.removeThumbnailsFromCache ( mSlideshow ) ; mAttachmentType = com.android.mms.data.WorkingMessage.TEXT ; mSlideshow = null ; if ( ( mMessageUri ) != null ) { asyncDelete ( mMessageUri , null , null ) ; mMessageUri = null ; } updateState ( com.android.mms.data.WorkingMessage.HAS_ATTACHMENT , false , notify ) ; if ( notify ) { mStatusListener.onAttachmentChanged ( ) ; } }
Source:
public void enter ( ) { super . enter ( ) ; if ( ( mConnectingTimestampMs ) == ( java.lang.Long.MIN_VALUE ) ) { mConnectingTimestampMs = android.os.SystemClock.uptimeMillis ( ) ; } mSystemInterface.getHeadsetPhoneState ( ) . listenForPhoneState ( true ) ; if ( ( mPrevState ) == ( mConnecting ) ) { processNoiseReductionEvent ( true ) ; mSystemInterface.queryPhoneState ( ) ; removeDeferredMessages ( com.android.bluetooth.hfp.HeadsetStateMachine.CONNECT ) ; } broadcastStateTransitions ( ) ; }

Target:
public void enter ( ) { super . enter ( ) ; if ( ( mConnectingTimestampMs ) == ( java.lang.Long.MIN_VALUE ) ) { mConnectingTimestampMs = android.os.SystemClock.uptimeMillis ( ) ; } updateAgIndicatorEnableState ( com.android.bluetooth.hfp.HeadsetStateMachine.DEFAULT_AG_INDICATOR_ENABLE_STATE ) ; if ( ( mPrevState ) == ( mConnecting ) ) { processNoiseReductionEvent ( true ) ; mSystemInterface.queryPhoneState ( ) ; removeDeferredMessages ( com.android.bluetooth.hfp.HeadsetStateMachine.CONNECT ) ; } broadcastStateTransitions ( ) ; }
Source:
public java.io.File getTestedApk ( int density , @ com.android.annotations.NonNull java.util.List < java.lang.String > abis ) { com.android.build.gradle.internal.variant.TestedVariantData testedVariantData = testVariantData.getTestedVariantData ( ) ; com.android.build.gradle.internal.variant.BaseVariantData < ? > testedVariantData2 = ( ( com.android.build.gradle.internal.variant.BaseVariantData ) ( testedVariantData ) ) ; com.android.build.SplitOutput output = com.android.ide.common.build.SplitOutputMatcher.computeBestOutput ( testedVariantData2.getOutputs ( ) , testedVariantData2.getVariantConfiguration ( ) . getSupportedAbis ( ) , density , abis ) ; if ( output != null ) { return output.getOutputFile ( ) ; } return null ; }

Target:
public java.io.File getTestedApk ( int density , @ com.android.annotations.NonNull java.util.List < java.lang.String > abis ) { com.android.build.gradle.internal.variant.TestedVariantData testedVariantData = testVariantData.getTestedVariantData ( ) ; com.android.build.gradle.internal.variant.BaseVariantData < ? > testedVariantData2 = ( ( com.android.build.gradle.internal.variant.BaseVariantData ) ( testedVariantData ) ) ; java.util.List < java.io.File > outputFiles = com.android.ide.common.build.SplitOutputMatcher.computeBestOutput ( testedVariantData2.getOutputs ( ) , testedVariantData2.getVariantConfiguration ( ) . getSupportedAbis ( ) , density , abis ) ; if ( ! ( outputFiles.isEmpty ( ) ) ) { return outputFiles.get ( 0 ) ; } return null ; }
Source:
public void write ( int b ) throws java.io.IOException { try { mSignature.update ( ( ( byte ) ( b ) ) ) ; } catch ( java.security.SignatureException e ) { throw new java.io.IOException ( ( "SignatureException: " + e ) ) ; } super . write ( b ) ; }

Target:
public void write ( int b ) throws java.io.IOException { try { mSignature.update ( ( ( byte ) ( b ) ) ) ; } catch ( java.security.SignatureException e ) { throw new java.io.IOException ( ( "SignatureException: " + e ) ) ; } super . write ( b ) ; ( mCount ) ++ ; }
Source:
public void testApplyingWithCriticalFiles ( ) throws java.lang.Exception { com.intellij.updater.PatchFileCreator.create ( "from" , "to" , myOlderDir , myNewerDir , myFile , java.util.Collections.< java.lang.String > emptyList ( ) , java.util.Arrays.asList ( "lib/annotations.jar" ) , java.util.Collections.< java.lang.String > emptyList ( ) , com.intellij.updater.TEST_UI ) ; com.intellij.updater.PatchFileCreator.PreparationResult preparationResult = com.intellij.updater.PatchFileCreator.prepareAndValidate ( myFile , myOlderDir , com.intellij.updater.TEST_UI ) ; assertTrue ( com.intellij.updater.PatchFileCreator.apply ( preparationResult , new java.util.HashMap < java.lang.String , com.intellij.updater.ValidationResult.Option > ( ) , com.intellij.updater.TEST_UI ) ) ; assertAppliedCorrectly ( ) ; }

Target:
public void testApplyingWithCriticalFiles ( ) throws java.lang.Exception { myPatchSpec.setCriticalFiles ( java.util.Arrays.asList ( "lib/annotations.jar" ) ) ; com.intellij.updater.PatchFileCreator.create ( myPatchSpec , myFile , com.intellij.updater.TEST_UI ) ; com.intellij.updater.PatchFileCreator.PreparationResult preparationResult = com.intellij.updater.PatchFileCreator.prepareAndValidate ( myFile , myOlderDir , com.intellij.updater.TEST_UI ) ; assertTrue ( com.intellij.updater.PatchFileCreator.apply ( preparationResult , new java.util.HashMap < java.lang.String , com.intellij.updater.ValidationResult.Option > ( ) , com.intellij.updater.TEST_UI ) ) ; assertAppliedCorrectly ( ) ; }
Source:
void run ( ) throws ZygoteInit.MethodAndArgsCaller { int loopCount = ZygoteInit.GC_LOOP_COUNT ; while ( true ) { if ( loopCount <= 0 ) { com.android.internal.os.ZygoteInit.gc ( ) ; loopCount = ZygoteInit.GC_LOOP_COUNT ; } else { loopCount -- ; } if ( runOnce ( ) ) { break ; } } }

Target:
private boolean handleAbiListQuery ( ) { try { final byte [ ] abiListBytes = abiList.getBytes ( java.nio.charset.StandardCharsets.US_ASCII ) ; mSocketOutStream.writeInt ( abiListBytes.length ) ; mSocketOutStream.write ( abiListBytes ) ; return false ; } catch ( java.io.IOException ioe ) { android.util.Log.e ( com.android.internal.os.ZygoteConnection.TAG , "Error writing to command socket" , ioe ) ; return true ; } }
Source:
public java.lang.String toShortString ( ) { java.lang.StringBuilder sb = new java.lang.StringBuilder ( ) ; sb.append ( mMajor ) ; if ( ( ( mMinor ) > 0 ) || ( ( mMicro ) > 0 ) ) { sb.append ( '.' ) . append ( mMinor ) ; } if ( ( mMicro ) > 0 ) { sb.append ( '.' ) . append ( mMicro ) ; } if ( ( mPreview ) != ( com.android.sdklib.repository.FullRevision.NOT_A_PREVIEW ) ) { sb.append ( " rc" ) . append ( mPreview ) ; } return sb.toString ( ) ; }

Target:
public java.lang.String toString ( ) { java.lang.StringBuilder sb = new java.lang.StringBuilder ( ) ; sb.append ( mMajor ) . append ( '.' ) . append ( mMinor ) . append ( '.' ) . append ( mMicro ) ; if ( ( mPreview ) != ( com.android.sdklib.repository.FullRevision.NOT_A_PREVIEW ) ) { sb.append ( mPreviewSeparator ) . append ( "rc" ) . append ( mPreview ) ; } return sb.toString ( ) ; }
Source:
public boolean getDataEnabled ( int subId ) { boolean retVal = false ; try { com.android.internal.telephony.ITelephony telephony = getITelephony ( ) ; if ( telephony != null ) retVal = telephony.getDataEnabled ( subId ) ; } catch ( android.os.RemoteException e ) { android.util.Log.e ( android.telephony.TelephonyManager.TAG , "Error calling ITelephony#getDataEnabled" , e ) ; } catch ( java.lang.NullPointerException e ) { } android.util.Log.d ( android.telephony.TelephonyManager.TAG , ( "getDataEnabled: retVal=" + retVal ) ) ; return retVal ; }

Target:
public java.util.List < java.lang.String > getPackagesWithCarrierPrivileges ( ) { try { com.android.internal.telephony.ITelephony telephony = getITelephony ( ) ; if ( telephony != null ) { return telephony.getPackagesWithCarrierPrivileges ( ) ; } } catch ( android.os.RemoteException ex ) { android.telephony.Rlog.e ( android.telephony.TelephonyManager.TAG , "getPackagesWithCarrierPrivileges RemoteException" , ex ) ; } catch ( java.lang.NullPointerException ex ) { android.telephony.Rlog.e ( android.telephony.TelephonyManager.TAG , "getPackagesWithCarrierPrivileges NPE" , ex ) ; } return java.util.Collections.EMPTY_LIST ; }
Source:
public void onFeatureReady ( ) { android.util.Log.i ( com.android.internal.telephony.ims.MmTelFeatureCompatAdapter.TAG , "onFeatureReady called!" ) ; android.content.IntentFilter intentFilter = new android.content.IntentFilter ( com.android.ims.ImsManager.ACTION_IMS_INCOMING_CALL ) ; mContext.registerReceiver ( mReceiver , intentFilter ) ; try { mSessionId = mCompatFeature.startSession ( createIncomingCallPendingIntent ( ) , null ) ; mCompatFeature.addRegistrationListener ( mListener ) ; mCompatFeature.addRegistrationListener ( mRegCompatAdapter.getRegistrationListener ( ) ) ; } catch ( android.os.RemoteException e ) { android.util.Log.e ( com.android.internal.telephony.ims.MmTelFeatureCompatAdapter.TAG , ( "Couldn't start compat feature: " + ( e.getMessage ( ) ) ) ) ; } }

Target:
public void onFeatureReady ( ) { android.util.Log.i ( com.android.internal.telephony.ims.MmTelFeatureCompatAdapter.TAG , "onFeatureReady called!" ) ; android.content.IntentFilter intentFilter = new android.content.IntentFilter ( com.android.ims.ImsManager.ACTION_IMS_INCOMING_CALL ) ; mContext.registerReceiver ( mReceiver , intentFilter ) ; try { mSessionId = mCompatFeature.startSession ( createIncomingCallPendingIntent ( ) , new com.android.internal.telephony.ims.MmTelFeatureCompatAdapter.ImsRegistrationListenerBase ( ) ) ; mCompatFeature.addRegistrationListener ( mListener ) ; mCompatFeature.addRegistrationListener ( mRegCompatAdapter.getRegistrationListener ( ) ) ; } catch ( android.os.RemoteException e ) { android.util.Log.e ( com.android.internal.telephony.ims.MmTelFeatureCompatAdapter.TAG , ( "Couldn't start compat feature: " + ( e.getMessage ( ) ) ) ) ; } }
Source:
public com.android.internal.telephony.gsm.DataActivityState getDataActivityState ( ) { com.android.internal.telephony.gsm.DataActivityState ret = DataActivityState.NONE ; if ( ( mSST.getCurrentGprsState ( ) ) == ( android.telephony.ServiceState.STATE_IN_SERVICE ) ) { switch ( mDataConnectionTracker.getActivity ( ) ) { case DATAIN : ret = DataActivityState.DATAIN ; break ; case DATAOUT : ret = DataActivityState.DATAOUT ; break ; case DATAINANDOUT : ret = DataActivityState.DATAINANDOUT ; break ; case DORMANT : ret = DataActivityState.DORMANT ; break ; } } return ret ; }

Target:
public android.telephony.ServiceState getServiceState ( ) { if ( ( mSST ) != null ) { return mSST.mSS ; } else { return new android.telephony.ServiceState ( ) ; } }
Source:
public void publicMethods ( ) throws java.lang.Exception { assertNotNull ( com.android.volley.toolbox.DiskBasedCache.class . getConstructor ( java.io.File.class , int . class ) ) ; assertNotNull ( com.android.volley.toolbox.DiskBasedCache.class . getConstructor ( java.io.File.class ) ) ; assertNotNull ( com.android.volley.toolbox.DiskBasedCache.class . getMethod ( "getFileForKey" , java.lang.String.class ) ) ; }

Target:
public void publicMethods ( ) throws java.lang.Exception { org.junit.Assert.assertNotNull ( com.android.volley.toolbox.DiskBasedCache.class . getConstructor ( java.io.File.class , int . class ) ) ; org.junit.Assert.assertNotNull ( com.android.volley.toolbox.DiskBasedCache.class . getConstructor ( java.io.File.class ) ) ; org.junit.Assert.assertNotNull ( com.android.volley.toolbox.DiskBasedCache.class . getMethod ( "getFileForKey" , java.lang.String.class ) ) ; }
Source:
public static void printVersion ( @ javax.annotation.Nonnull java.io.PrintStream printStream ) { printStream.println ( ( ( "Jack compiler: " + ( com.android.jack.Jack.getVersion ( ) . getVerboseVersion ( ) ) ) + '.' ) ) ; }

Target:
public static void printVersion ( @ javax.annotation.Nonnull java.io.PrintStream printStream , @ javax.annotation.Nonnull com.android.jack.Options options ) throws com.android.jack.IllegalOptionsException { options.ensurePluginManager ( ) ; printStream.println ( ( ( "Jack compiler: " + ( com.android.jack.Jack.getVersion ( ) . getVerboseVersion ( ) ) ) + '.' ) ) ; for ( com.android.jack.plugin.v01.Plugin plugin : options.getPluginManager ( ) . getPlugins ( ) ) { com.android.jack.CommandLine.printVersion ( printStream , plugin ) ; } }
Source:
public void run ( ) { com.android.ide.eclipse.adt.internal.launch.DeviceChooserDialog dialog = new com.android.ide.eclipse.adt.internal.launch.DeviceChooserDialog ( com.android.ide.eclipse.adt.AdtPlugin.getDisplay ( ) . getActiveShell ( ) , response , manifestData.getPackage ( ) , projectTarget ) ; if ( ( dialog.open ( ) ) == ( org.eclipse.jface.dialogs.Dialog.OK ) ) { com.android.ide.eclipse.adt.internal.launch.DeviceChoiceCache.put ( configName , response ) ; continueLaunch [ 0 ] = true ; } }

Target:
public void run ( ) { com.android.ide.eclipse.adt.internal.launch.DeviceChooserDialog dialog = new com.android.ide.eclipse.adt.internal.launch.DeviceChooserDialog ( com.android.ide.eclipse.adt.AdtPlugin.getDisplay ( ) . getActiveShell ( ) , response , manifestData.getPackage ( ) , projectTarget , minSdkVersion ) ; if ( ( dialog.open ( ) ) == ( org.eclipse.jface.dialogs.Dialog.OK ) ) { com.android.ide.eclipse.adt.internal.launch.DeviceChoiceCache.put ( configName , response ) ; continueLaunch [ 0 ] = true ; } }
Source:
public void testNetworkStatsWithSet ( ) throws java.lang.Exception { stageFile ( R.raw.xt_qtaguid_typical , new java.io.File ( mTestProc , "net/xt_qtaguid/stats" ) ) ; final android.net.NetworkStats stats = mFactory.readNetworkStatsDetail ( ) ; assertEquals ( 70 , stats.size ( ) ) ; com.android.internal.net.NetworkStatsFactoryTest.assertStatsEntry ( stats , "rmnet1" , 10021 , android.net.NetworkStats.SET_DEFAULT , 806354944 , 219110L , 578L , 227423L , 676L ) ; com.android.internal.net.NetworkStatsFactoryTest.assertStatsEntry ( stats , "rmnet1" , 10021 , android.net.NetworkStats.SET_FOREGROUND , 806354944 , 742L , 3L , 1265L , 3L ) ; }

Target:
public void testNetworkStatsWithSet ( ) throws java.lang.Exception { final android.net.NetworkStats stats = parseDetailedStats ( R.raw.xt_qtaguid_typical ) ; assertEquals ( 70 , stats.size ( ) ) ; com.android.internal.net.NetworkStatsFactoryTest.assertStatsEntry ( stats , "rmnet1" , 10021 , android.net.NetworkStats.SET_DEFAULT , 806354944 , 219110L , 578L , 227423L , 676L ) ; com.android.internal.net.NetworkStatsFactoryTest.assertStatsEntry ( stats , "rmnet1" , 10021 , android.net.NetworkStats.SET_FOREGROUND , 806354944 , 742L , 3L , 1265L , 3L ) ; }
Source:
public static final int getHeaderSize ( @ javax.annotation.Nonnegative int apiLevel ) { int headerSize = ( ( ( 8 * ( com.android.jack.dx.dex.SizeOf.UBYTE ) ) + ( com.android.jack.dx.dex.SizeOf.UINT ) ) + ( com.android.jack.dx.dex.SizeOf.SIGNATURE ) ) + ( 20 * ( com.android.jack.dx.dex.SizeOf.UINT ) ) ; if ( apiLevel >= ( DexFormat.API_ANDROID_O ) ) { headerSize += 4 * ( com.android.jack.dx.dex.SizeOf.UINT ) ; } return headerSize ; }

Target:
public static final int getHeaderSize ( @ javax.annotation.Nonnegative int dexVersion ) { int headerSize = ( ( ( 8 * ( com.android.jack.dx.dex.SizeOf.UBYTE ) ) + ( com.android.jack.dx.dex.SizeOf.UINT ) ) + ( com.android.jack.dx.dex.SizeOf.SIGNATURE ) ) + ( 20 * ( com.android.jack.dx.dex.SizeOf.UINT ) ) ; if ( dexVersion == ( DexFormat.O_BETA2_DEX_VERSION ) ) { headerSize += 4 * ( com.android.jack.dx.dex.SizeOf.UINT ) ; } return headerSize ; }
Source:
public void testIsLegalReplacement ( ) { try { encoder.isLegalReplacement ( null ) ; fail ( "should throw null pointer exception" ) ; } catch ( java.lang.NullPointerException e ) { } assertTrue ( encoder.isLegalReplacement ( specifiedReplacement ) ) ; assertTrue ( encoder.isLegalReplacement ( new byte [ 200 ] ) ) ; byte [ ] ba = getIllegalByteArray ( ) ; if ( ba != null ) { assertFalse ( encoder.isLegalReplacement ( ba ) ) ; } }

Target:
public void test_isLegalReplacement_null ( ) { try { encoder.isLegalReplacement ( null ) ; fail ( "should throw null pointer exception" ) ; } catch ( java.lang.NullPointerException e ) { } }
Source:
public void updatePublish ( @ android.annotation.NonNull android.net.wifi.nan.PublishConfig publishConfig ) { if ( mTerminated ) { android.util.Log.w ( android.net.wifi.nan.WifiNanPublishDiscoverySession.TAG , "updatePublish: called on terminated session" ) ; return ; } else { android.net.wifi.nan.WifiNanManager mgr = mMgr.get ( ) ; if ( mgr == null ) { android.util.Log.w ( android.net.wifi.nan.WifiNanPublishDiscoverySession.TAG , "updatePublish: called post GC on WifiNanManager" ) ; return ; } mgr.updatePublish ( mSessionId , publishConfig ) ; } }

Target:
public void updatePublish ( @ android.annotation.NonNull android.net.wifi.nan.PublishConfig publishConfig ) { if ( mTerminated ) { android.util.Log.w ( android.net.wifi.nan.WifiNanPublishDiscoverySession.TAG , "updatePublish: called on terminated session" ) ; return ; } else { android.net.wifi.nan.WifiNanManager mgr = mMgr.get ( ) ; if ( mgr == null ) { android.util.Log.w ( android.net.wifi.nan.WifiNanPublishDiscoverySession.TAG , "updatePublish: called post GC on WifiNanManager" ) ; return ; } mgr.updatePublish ( mClientId , mSessionId , publishConfig ) ; } }
Source:
public final java.nio.CharBuffer asCharBuffer ( ) { if ( ! ( memoryRef.isAccessible ) ) { throw new java.lang.IllegalStateException ( "buffer is inaccessible" ) ; } int off = this . position ( ) ; int lim = this . limit ( ) ; assert off <= lim ; int rem = ( off <= lim ) ? lim - off : 0 ; int size = rem > > 1 ; return new java.nio.ByteBufferAsCharBuffer ( this , ( - 1 ) , 0 , size , size , off , order ( ) ) ; }

Target:
void putCharUnchecked ( int i , char x ) { if ( ! ( memoryRef.isAccessible ) ) { throw new java.lang.IllegalStateException ( "buffer is inaccessible" ) ; } putChar ( ix ( i ) , x ) ; }
Source:
public void setCurrentFunction ( java.lang.String function ) { mContext.enforceCallingOrSelfPermission ( android.Manifest.permission.MANAGE_USB , null ) ; if ( ! ( com.android.server.usb.UsbService.isSupportedCurrentFunction ( function ) ) ) { android.util.Slog.w ( com.android.server.usb.UsbService.TAG , ( "Caller of setCurrentFunction() requested unsupported USB function: " + function ) ) ; function = android.hardware.usb.UsbManager.USB_FUNCTION_NONE ; } if ( ( mDeviceManager ) != null ) { mDeviceManager.setCurrentFunctions ( function ) ; } else { throw new java.lang.IllegalStateException ( "USB device mode not supported" ) ; } }

Target:
public void setCurrentFunction ( java.lang.String function , boolean usbDataUnlocked ) { mContext.enforceCallingOrSelfPermission ( android.Manifest.permission.MANAGE_USB , null ) ; if ( ! ( com.android.server.usb.UsbService.isSupportedCurrentFunction ( function ) ) ) { android.util.Slog.w ( com.android.server.usb.UsbService.TAG , ( "Caller of setCurrentFunction() requested unsupported USB function: " + function ) ) ; function = android.hardware.usb.UsbManager.USB_FUNCTION_NONE ; } if ( ( mDeviceManager ) != null ) { mDeviceManager.setCurrentFunctions ( function , usbDataUnlocked ) ; } else { throw new java.lang.IllegalStateException ( "USB device mode not supported" ) ; } }
Source:
void dispatchMediaKeyWithWakeLockToAudioService ( android.view.KeyEvent event ) { if ( android.app.ActivityManagerNative.isSystemReady ( ) ) { android.media.IAudioService audioService = com.android.internal.policy.impl.PhoneWindowManager.getAudioService ( ) ; if ( audioService != null ) { try { audioService.dispatchMediaKeyEventUnderWakelock ( event ) ; } catch ( android.os.RemoteException e ) { android.util.Log.e ( com.android.internal.policy.impl.PhoneWindowManager.TAG , ( "dispatchMediaKeyEvent threw exception " + e ) ) ; } } } }

Target:
void launchVoiceAssistWithWakeLock ( boolean keyguardActive ) { android.content.Intent voiceIntent = new android.content.Intent ( android.speech.RecognizerIntent.ACTION_VOICE_SEARCH_HANDS_FREE ) ; voiceIntent.putExtra ( RecognizerIntent.EXTRA_SECURE , keyguardActive ) ; mContext.startActivityAsUser ( voiceIntent , UserHandle.CURRENT_OR_SELF ) ; mBroadcastWakeLock.release ( ) ; }