auphong2707/dl4se-code-review-dataset huggingface dataset:
Source:
public java.nio.ByteBuffer putChar ( int index , char value ) { checkNotFreed ( ) ; if ( isReadOnly ) { throw new java.nio.ReadOnlyBufferException ( ) ; } checkIndex ( index , SizeOf.CHAR ) ; this . block.pokeShort ( ( ( offset ) + index ) , ( ( short ) ( value ) ) , order ) ; return this ; }

Target:
public java.nio.ByteBuffer putChar ( int index , char value ) { checkIsAccessible ( ) ; if ( isReadOnly ) { throw new java.nio.ReadOnlyBufferException ( ) ; } checkIndex ( index , SizeOf.CHAR ) ; this . block.pokeShort ( ( ( offset ) + index ) , ( ( short ) ( value ) ) , order ) ; return this ; }
Source:
public void testAesCbcHmacSha1Tcp4UdpEncap ( ) throws java.lang.Exception { android.net.IpSecAlgorithm crypt = new android.net.IpSecAlgorithm ( android.net.IpSecAlgorithm.CRYPT_AES_CBC , android.net.cts.IpSecManagerTest.CRYPT_KEY ) ; android.net.IpSecAlgorithm auth = new android.net.IpSecAlgorithm ( android.net.IpSecAlgorithm.AUTH_HMAC_SHA1 , getAuthKey ( 160 ) , 96 ) ; checkTransform ( android.system.OsConstants.IPPROTO_TCP , android.net.cts.IpSecManagerTest.IPV4_LOOPBACK , crypt , auth , true , 1 , false ) ; }

Target:
public void testAesCbcHmacSha384Udp4UdpEncap ( ) throws java.lang.Exception { android.net.IpSecAlgorithm crypt = new android.net.IpSecAlgorithm ( android.net.IpSecAlgorithm.CRYPT_AES_CBC , CRYPT_KEY ) ; android.net.IpSecAlgorithm auth = new android.net.IpSecAlgorithm ( android.net.IpSecAlgorithm.AUTH_HMAC_SHA384 , getKey ( 384 ) , 192 ) ; checkTransform ( android.system.OsConstants.IPPROTO_UDP , android.net.cts.IPV4_LOOPBACK , crypt , auth , null , true , 1 , false ) ; checkTransform ( android.system.OsConstants.IPPROTO_UDP , android.net.cts.IPV4_LOOPBACK , crypt , auth , null , true , 1 , true ) ; }
Source:
private void displayMissingClasses ( java.util.Set < java.lang.String > missingClasses ) { mErrorLabel.setText ( "" ) ; addText ( mErrorLabel , "The following classes could not be found:\n" ) ; for ( java.lang.String clazz : missingClasses ) { addText ( mErrorLabel , "- " ) ; addLink ( mErrorLabel , clazz ) ; addText ( mErrorLabel , "\n" ) ; } mSashError.setMaximizedControl ( null ) ; }

Target:
private void displayMissingClasses ( java.util.Set < java.lang.String > missingClasses ) { mErrorLabel.setText ( "" ) ; addText ( mErrorLabel , "The following classes could not be found:\n" ) ; for ( java.lang.String clazz : missingClasses ) { addText ( mErrorLabel , "- " ) ; addClassLink ( mErrorLabel , clazz ) ; addText ( mErrorLabel , "\n" ) ; } mSashError.setMaximizedControl ( null ) ; }
Source:
public static android.security.CryptoOperationException getCryptoOperationException ( android.security.KeymasterException e ) { switch ( e.getErrorCode ( ) ) { case android.security.keymaster.KeymasterDefs.KM_ERROR_KEY_USER_NOT_AUTHENTICATED : return new android.security.UserNotAuthenticatedException ( ) ; default : return new android.security.CryptoOperationException ( "Crypto operation failed" , e ) ; } }

Target:
public static android.security.CryptoOperationException getCryptoOperationException ( android.security.KeymasterException e ) { switch ( e.getErrorCode ( ) ) { case android.security.keymaster.KeymasterDefs.KM_ERROR_KEY_EXPIRED : return new android.security.KeyExpiredException ( ) ; case android.security.keymaster.KeymasterDefs.KM_ERROR_KEY_NOT_YET_VALID : return new android.security.KeyNotYetValidException ( ) ; case android.security.keymaster.KeymasterDefs.KM_ERROR_KEY_USER_NOT_AUTHENTICATED : return new android.security.UserNotAuthenticatedException ( ) ; default : return new android.security.CryptoOperationException ( "Crypto operation failed" , e ) ; } }
Source:
void clearUuids ( ) { for ( java.util.Iterator < com.android.bluetooth.gatt.ScanFilterQueue.Entry > it = mEntries.iterator ( ) ; it.hasNext ( ) ; ) { com.android.bluetooth.gatt.ScanFilterQueue.Entry entry = it.next ( ) ; if ( ( entry.type ) == ( com.android.bluetooth.gatt.ScanFilterQueue.TYPE_SERVICE_UUID ) ) it.remove ( ) ; } }

Target:
com.android.bluetooth.gatt.ScanFilterQueue.Entry [ ] toArray ( ) { return mEntries.toArray ( new com.android.bluetooth.gatt.ScanFilterQueue.Entry [ mEntries.size ( ) ] ) ; }
Source:
protected abstract void doRemoveFiles ( java.util.List < org.eclipse.core.resources.IFile > sources , org.eclipse.core.runtime.IProgressMonitor monitor ) throws org.eclipse.core.runtime.CoreException ;

Target:
protected void doRemoveFiles ( com.android.ide.eclipse.adt.internal.build.NonJavaFileBundle bundle ) throws org.eclipse.core.runtime.CoreException { java.util.List < org.eclipse.core.resources.IFile > outputFiles = bundle.getOutputFiles ( ) ; for ( org.eclipse.core.resources.IFile outputFile : outputFiles ) { if ( outputFile.exists ( ) ) { outputFile.getLocation ( ) . toFile ( ) . delete ( ) ; } } }
Source:
public void testEmbedded ( ) throws java.lang.Exception { java.io.File project = new java.io.File ( testDir , "embedded" ) ; runGradleTasks ( sdkDir , ndkDir , BasePlugin.GRADLE_MIN_VERSION , project , "clean" , ":main:assembleRelease" ) ; java.io.File mainApk = new java.io.File ( project , ( ( "main/build/" + ( com.android.builder.model.AndroidProject.FD_OUTPUTS ) ) + "/apk/main-release-unsigned.apk" ) ) ; com.android.build.gradle.ManualBuildTest.checkJar ( mainApk , java.util.Collections.< java.lang.String , java.lang.String > singletonMap ( "assets/embedded-release-unsigned.apk" , null ) ) ; }

Target:
public void testEmbedded ( ) throws java.lang.Exception { java.io.File project = new java.io.File ( testDir , "embedded" ) ; runGradleTasks ( sdkDir , ndkDir , BasePlugin.GRADLE_MIN_VERSION , project , java.util.Collections.< java.lang.String > emptyList ( ) , "clean" , ":main:assembleRelease" ) ; java.io.File mainApk = new java.io.File ( project , ( ( "main/build/" + ( com.android.builder.model.AndroidProject.FD_OUTPUTS ) ) + "/apk/main-release-unsigned.apk" ) ) ; com.android.build.gradle.ManualBuildTest.checkJar ( mainApk , java.util.Collections.< java.lang.String , java.lang.String > singletonMap ( "assets/embedded-release-unsigned.apk" , null ) ) ; }
Source:
private static android.telephony.SmsCbMessage createCmasSmsMessage ( int serviceCategory , int messageId , java.lang.String language , java.lang.String body , int cmasCategory , int responseType , int severity , int urgency , int certainty ) { int cmasMessageClass = com.android.cellbroadcastreceiver.tests.SendCdmaCmasMessages.serviceCategoryToCmasMessageClass ( serviceCategory ) ; android.telephony.SmsCbCmasInfo cmasInfo = new android.telephony.SmsCbCmasInfo ( cmasMessageClass , cmasCategory , responseType , severity , urgency , certainty ) ; return new android.telephony.SmsCbMessage ( android.telephony.SmsCbMessage.MESSAGE_FORMAT_3GPP2 , android.telephony.SmsCbMessage.GEOGRAPHICAL_SCOPE_PLMN_WIDE , messageId , new android.telephony.SmsCbLocation ( "123456" ) , serviceCategory , language , body , android.telephony.SmsCbMessage.MESSAGE_PRIORITY_EMERGENCY , null , cmasInfo ) ; }

Target:
private static android.telephony.SmsCbMessage createCmasSmsMessage ( int serviceCategory , int serialNumber , java.lang.String language , java.lang.String body , int cmasCategory , int responseType , int severity , int urgency , int certainty ) { int cmasMessageClass = com.android.cellbroadcastreceiver.tests.SendCdmaCmasMessages.serviceCategoryToCmasMessageClass ( serviceCategory ) ; android.telephony.SmsCbCmasInfo cmasInfo = new android.telephony.SmsCbCmasInfo ( cmasMessageClass , cmasCategory , responseType , severity , urgency , certainty ) ; return new android.telephony.SmsCbMessage ( android.telephony.SmsCbMessage.MESSAGE_FORMAT_3GPP2 , android.telephony.SmsCbMessage.GEOGRAPHICAL_SCOPE_PLMN_WIDE , serialNumber , new android.telephony.SmsCbLocation ( "123456" ) , serviceCategory , language , body , android.telephony.SmsCbMessage.MESSAGE_PRIORITY_EMERGENCY , null , cmasInfo ) ; }
Source:
public void test_generateCertificate ( ) throws java.lang.Exception { test_generateCertificate ( java.security.cert.CertificateFactory.getInstance ( "X509" ) ) ; test_generateCertificate ( java.security.cert.CertificateFactory.getInstance ( "X509" , "BC" ) ) ; test_generateCertificate ( java.security.cert.CertificateFactory.getInstance ( "X509" , "DRLCertFactory" ) ) ; }

Target:
public void test_generateCertificate ( ) throws java.lang.Exception { java.security.Provider [ ] providers = java.security.Security.getProviders ( "CertificateFactory.X509" ) ; for ( java.security.Provider p : providers ) { java.security.cert.CertificateFactory cf = java.security.cert.CertificateFactory.getInstance ( "X509" , p ) ; try { test_generateCertificate ( cf ) ; testGenerateCertificate_InputStream_Offset_Correct ( cf ) ; } catch ( java.lang.Exception e ) { throw new java.lang.Exception ( ( "Problem testing " + ( p.getName ( ) ) ) , e ) ; } } }
Source:
private void addSubPlan ( java.lang.String [ ] flatArgs ) { com.android.compatibility.common.tradefed.result.SubPlanCreator creator = new com.android.compatibility.common.tradefed.result.SubPlanCreator ( ) ; try { com.android.tradefed.config.ArgsOptionParser optionParser = new com.android.tradefed.config.ArgsOptionParser ( creator ) ; optionParser.parse ( java.util.Arrays.asList ( flatArgs ) ) ; creator.createAndSerializeSubPlan ( getBuildHelper ( ) ) ; } catch ( com.android.tradefed.config.ConfigurationException e ) { printLine ( ( "Error: " + ( e.getMessage ( ) ) ) ) ; printLine ( com.android.tradefed.config.ArgsOptionParser.getOptionHelp ( false , creator ) ) ; } }

Target:
private void addSubPlan ( java.lang.String [ ] flatArgs ) { com.android.compatibility.common.tradefed.result.SubPlanHelper creator = new com.android.compatibility.common.tradefed.result.SubPlanHelper ( ) ; try { com.android.tradefed.config.ArgsOptionParser optionParser = new com.android.tradefed.config.ArgsOptionParser ( creator ) ; optionParser.parse ( java.util.Arrays.asList ( flatArgs ) ) ; creator.createAndSerializeSubPlan ( getBuildHelper ( ) ) ; } catch ( com.android.tradefed.config.ConfigurationException e ) { printLine ( ( "Error: " + ( e.getMessage ( ) ) ) ) ; printLine ( com.android.tradefed.config.ArgsOptionParser.getOptionHelp ( false , creator ) ) ; } }
Source:
public void registerContentObservers ( android.content.Context appContext , com.android.dialer.calllog.datasources.systemcalllog.ContentObserverCallbacks contentObserverCallbacks ) { com.android.dialer.common.Assert.isMainThread ( ) ; com.android.dialer.common.LogUtil.enterBlock ( "SystemCallLogDataSource.registerContentObservers" ) ; if ( ! ( com.android.dialer.util.PermissionsUtil.hasCallLogReadPermissions ( appContext ) ) ) { com.android.dialer.common.LogUtil.i ( "SystemCallLogDataSource.registerContentObservers" , "no call log permissions" ) ; return ; } appContext.getContentResolver ( ) . registerContentObserver ( CallLog.Calls.CONTENT_URI , true , new com.android.dialer.calllog.datasources.systemcalllog.SystemCallLogDataSource.CallLogObserver ( com.android.dialer.common.concurrent.ThreadUtil.getUiThreadHandler ( ) , appContext , contentObserverCallbacks ) ) ; }

Target:
public void registerContentObservers ( android.content.Context appContext , com.android.dialer.calllog.datasources.systemcalllog.ContentObserverCallbacks contentObserverCallbacks ) { com.android.dialer.common.Assert.isMainThread ( ) ; com.android.dialer.common.LogUtil.enterBlock ( "SystemCallLogDataSource.registerContentObservers" ) ; if ( ! ( com.android.dialer.util.PermissionsUtil.hasCallLogReadPermissions ( appContext ) ) ) { com.android.dialer.common.LogUtil.i ( "SystemCallLogDataSource.registerContentObservers" , "no call log permissions" ) ; return ; } appContext.getContentResolver ( ) . registerContentObserver ( CallLog.Calls.CONTENT_URI_WITH_VOICEMAIL , true , new com.android.dialer.calllog.datasources.systemcalllog.SystemCallLogDataSource.CallLogObserver ( com.android.dialer.common.concurrent.ThreadUtil.getUiThreadHandler ( ) , appContext , contentObserverCallbacks ) ) ; }
Source:
public void exitEmergencyCallbackMode ( ) { if ( mWakeLock.isHeld ( ) ) { mWakeLock.release ( ) ; } if ( com.android.internal.telephony.imsphone.ImsPhone.DBG ) android.telephony.Rlog.d ( com.android.internal.telephony.imsphone.ImsPhone.LOG_TAG , "exitEmergencyCallbackMode()" ) ; com.android.ims.ImsEcbm ecbm ; try { ecbm = mCT.getEcbmInterface ( ) ; ecbm.exitEmergencyCallbackMode ( ) ; } catch ( com.android.ims.ImsException e ) { e.printStackTrace ( ) ; } }

Target:
public void exitEmergencyCallbackMode ( ) { if ( mWakeLock.isHeld ( ) ) { mWakeLock.release ( ) ; } if ( com.android.internal.telephony.imsphone.ImsPhone.DBG ) logd ( "exitEmergencyCallbackMode()" ) ; com.android.ims.ImsEcbm ecbm ; try { ecbm = mCT.getEcbmInterface ( ) ; ecbm.exitEmergencyCallbackMode ( ) ; } catch ( com.android.ims.ImsException e ) { e.printStackTrace ( ) ; } }
Source:
public static com.google.api.services.storage.model.Bucket createBucket ( java.lang.String projectId , java.lang.String bucketName ) { try { com.google.api.services.storage.model.Bucket bucket = new com.google.api.services.storage.model.Bucket ( ) . setName ( bucketName ) . setLocation ( "US" ) ; com.google.api.services.storage.Storage.Buckets.Insert insertBucket = getStorage ( ) . buckets ( ) . insert ( projectId , bucket ) ; return insertBucket.execute ( ) ; } catch ( java.io.IOException e ) { throw new java.lang.RuntimeException ( e ) ; } }

Target:
public static com.google.api.services.storage.model.Bucket createBucket ( java.lang.String projectId , java.lang.String bucketName ) { try { com.google.api.services.storage.model.Bucket bucket = new com.google.api.services.storage.model.Bucket ( ) . setName ( bucketName ) . setLocation ( "US" ) ; com.google.api.services.storage.Storage.Buckets.Insert insertBucket = com.google.gct.testing.launcher.CloudAuthenticator.getStorage ( ) . buckets ( ) . insert ( projectId , bucket ) ; return insertBucket.execute ( ) ; } catch ( java.io.IOException e ) { throw new java.lang.RuntimeException ( e ) ; } }
Source:
public int getJayceCount ( ) throws com.android.jack.library.LibraryIOException { int size = 0 ; com.android.jack.library.InputJackLibrary compilerStateLib = null ; try { compilerStateLib = com.android.jack.test.toolchain.AbstractTestTools.getInputJackLibraryFromDir ( compilerStateFolder ) ; java.util.Iterator < com.android.sched.vfs.InputVFile > jayceIter = compilerStateLib.iterator ( FileType.JAYCE ) ; while ( jayceIter.hasNext ( ) ) { size ++ ; jayceIter.next ( ) ; } } finally { if ( compilerStateLib != null ) { compilerStateLib.close ( ) ; } } return size ; }

Target:
public int getJayceCount ( ) throws com.android.jack.library.LibraryIOException { int size = 0 ; com.android.jack.library.InputJackLibrary compilerStateLib = null ; try { compilerStateLib = com.android.jack.test.toolchain.AbstractTestTools.getInputJackLibrary ( compilerStateFolder ) ; java.util.Iterator < com.android.sched.vfs.InputVFile > jayceIter = compilerStateLib.iterator ( FileType.JAYCE ) ; while ( jayceIter.hasNext ( ) ) { size ++ ; jayceIter.next ( ) ; } } finally { if ( compilerStateLib != null ) { compilerStateLib.close ( ) ; } } return size ; }
Source:
public static double nextDown ( float f ) { if ( ( sun.misc.FpUtils.isNaN ( f ) ) || ( f == ( java.lang.Float.NEGATIVE_INFINITY ) ) ) return f ; else { if ( f == 0.0F ) return - ( java.lang.Float.MIN_VALUE ) ; else return java.lang.Float.intBitsToFloat ( ( ( java.lang.Float.floatToRawIntBits ( f ) ) + ( f > 0.0F ? - 1 : + 1 ) ) ) ; } }

Target:
public static double nextDown ( float f ) { return java.lang.Math.nextDown ( f ) ; }
Source:
public void onRequestPermissionsResult ( int requestCode , java.lang.String [ ] permissions , int [ ] grantResults ) { if ( requestCode == ( com.android.dialer.contactsfragment.ContactsFragment.READ_CONTACTS_PERMISSION_REQUEST_CODE ) ) { if ( ( ( grantResults.length ) >= 1 ) && ( ( android.content.pm.PackageManager.PERMISSION_GRANTED ) == ( grantResults [ 0 ] ) ) ) { emptyContentView.setVisibility ( View.GONE ) ; getLoaderManager ( ) . initLoader ( 0 , null , this ) ; } } }

Target:
private void loadContacts ( ) { getLoaderManager ( ) . initLoader ( 0 , null , this ) ; recyclerView.setVisibility ( View.VISIBLE ) ; emptyContentView.setVisibility ( View.GONE ) ; }
Source:
public boolean onPreferenceTreeClick ( android.preference.PreferenceScreen preferenceScreen , android.preference.Preference preference ) { if ( preference == ( mPinToggle ) ) { mToState = mPinToggle.isChecked ( ) ; mPinToggle.setChecked ( ( ! ( mToState ) ) ) ; mDialogState = com.android.settings.SimLockSettings.SIM_LOCK_MODE ; showPinDialog ( ) ; } return true ; }

Target:
public boolean onPreferenceTreeClick ( android.preference.PreferenceScreen preferenceScreen , android.preference.Preference preference ) { if ( preference == ( mPinToggle ) ) { mToState = mPinToggle.isChecked ( ) ; mPinToggle.setChecked ( ( ! ( mToState ) ) ) ; mDialogState = com.android.settings.IccLockSettings.ICC_LOCK_MODE ; showPinDialog ( ) ; } return true ; }
Source:
public void testDhcpErrorEventSerialization ( ) { android.net.ConnectivityMetricsEvent ev = com.android.server.connectivity.MetricsTestUtil.describeIpEvent ( com.android.server.connectivity.MetricsTestUtil.aType ( android.net.metrics.DhcpErrorEvent.class ) , com.android.server.connectivity.MetricsTestUtil.aString ( "wlan0" ) , com.android.server.connectivity.MetricsTestUtil.anInt ( DhcpErrorEvent.L4_NOT_UDP ) ) ; java.lang.String want = com.android.server.connectivity.IpConnectivityEventBuilderTest.joinLines ( "dropped_events: 0" , "events <" , " time_ms: 1" , " transport: 0" , " dhcp_event <" , " duration_ms: 0" , " if_name: \"wlan0\"" , " error_code: 50397184" , " >" , ">" , "version: 2" ) ; com.android.server.connectivity.IpConnectivityEventBuilderTest.verifySerialization ( want , ev ) ; }

Target:
public void testDhcpErrorEventSerialization ( ) { android.net.ConnectivityMetricsEvent ev = com.android.server.connectivity.MetricsTestUtil.describeIpEvent ( com.android.server.connectivity.MetricsTestUtil.aType ( android.net.metrics.DhcpErrorEvent.class ) , com.android.server.connectivity.MetricsTestUtil.aString ( "wlan0" ) , com.android.server.connectivity.MetricsTestUtil.anInt ( DhcpErrorEvent.L4_NOT_UDP ) ) ; java.lang.String want = com.android.server.connectivity.IpConnectivityEventBuilderTest.joinLines ( "dropped_events: 0" , "events <" , " dhcp_event <" , " duration_ms: 0" , " error_code: 50397184" , " if_name: \"wlan0\"" , " state_transition: \"\"" , " >" , " time_ms: 1" , " transport: 0" , ">" , "version: 2" ) ; com.android.server.connectivity.IpConnectivityEventBuilderTest.verifySerialization ( want , ev ) ; }
Source:
public boolean hangupCall ( ) throws android.os.RemoteException { synchronized ( mLock ) { enforceModifyPermission ( ) ; com.android.server.telecom.Log.startSession ( "BPSI.hC" ) ; long token = android.os.Binder.clearCallingIdentity ( ) ; try { com.android.server.telecom.Log.i ( com.android.server.telecom.BluetoothPhoneServiceImpl.TAG , "BT - hanging up call" ) ; com.android.server.telecom.Call call = mCallsManager.getForegroundCall ( ) ; if ( call != null ) { mCallsManager.disconnectCall ( call ) ; return true ; } return false ; } finally { android.os.Binder.restoreCallingIdentity ( token ) ; com.android.server.telecom.Log.endSession ( ) ; } } }

Target:
public boolean hangupCall ( ) throws android.os.RemoteException { synchronized ( mLock ) { enforceModifyPermission ( ) ; android.telecom.Log.startSession ( "BPSI.hC" ) ; long token = android.os.Binder.clearCallingIdentity ( ) ; try { android.telecom.Log.i ( com.android.server.telecom.BluetoothPhoneServiceImpl.TAG , "BT - hanging up call" ) ; com.android.server.telecom.Call call = mCallsManager.getForegroundCall ( ) ; if ( call != null ) { mCallsManager.disconnectCall ( call ) ; return true ; } return false ; } finally { android.os.Binder.restoreCallingIdentity ( token ) ; android.telecom.Log.endSession ( ) ; } } }
Source:
public static org.jetbrains.io.HttpResponse response ( @ org.jetbrains.annotations.Nullable java.lang.String contentType , @ org.jetbrains.annotations.Nullable io.netty.buffer.ByteBuf content ) { org.jetbrains.io.HttpResponse response = new org.jetbrains.io.DefaultFullHttpResponse ( HttpVersion.HTTP_1_1 , HttpResponseStatus.OK , ( content == null ? io.netty.buffer.Unpooled.EMPTY_BUFFER : content ) ) ; if ( contentType != null ) { response.headers ( ) . add ( org.jetbrains.io.CONTENT_TYPE , contentType ) ; } return response ; }

Target:
public static org.jetbrains.io.HttpResponse response ( @ org.jetbrains.annotations.Nullable java.lang.String contentType , @ org.jetbrains.annotations.Nullable io.netty.buffer.ByteBuf content ) { org.jetbrains.io.HttpResponse response = new org.jetbrains.io.DefaultFullHttpResponse ( HttpVersion.HTTP_1_1 , HttpResponseStatus.OK , ( content == null ? io.netty.buffer.Unpooled.EMPTY_BUFFER : content ) ) ; if ( contentType != null ) { response.headers ( ) . add ( HttpHeaders.Names.CONTENT_TYPE , contentType ) ; } return response ; }
Source:
public void testLoadTzData_badZicLength ( ) throws java.lang.Exception { libcore.util.ZoneInfoTestHelper.TzDataBuilder builder = new libcore.util.ZoneInfoTestHelper.TzDataBuilder ( ) . initializeToValid ( ) ; builder.clearZicData ( ) ; byte [ ] invalidZicData = "This is too short" . getBytes ( ) ; builder.addZicData ( "Europe/London" , invalidZicData ) ; libcore.util.ZoneInfoDBTest.checkInvalidDataDetected ( builder.build ( ) ) ; }

Target:
public void testLoadTzData_badZicLength ( ) throws java.lang.Exception { libcore.tzdata.testing.ZoneInfoTestHelper.TzDataBuilder builder = new libcore.tzdata.testing.ZoneInfoTestHelper.TzDataBuilder ( ) . initializeToValid ( ) ; builder.clearZicData ( ) ; byte [ ] invalidZicData = "This is too short" . getBytes ( ) ; builder.addZicData ( "Europe/London" , invalidZicData ) ; libcore.util.ZoneInfoDBTest.checkInvalidDataDetected ( builder.build ( ) ) ; }
Source:
public void roundOut ( android.graphics.Rect dst ) { dst.set ( ( ( int ) ( android.util.FloatMath.floor ( left ) ) ) , ( ( int ) ( android.util.FloatMath.floor ( top ) ) ) , ( ( int ) ( android.util.FloatMath.ceil ( right ) ) ) , ( ( int ) ( android.util.FloatMath.ceil ( bottom ) ) ) ) ; }

Target:
public void roundOut ( android.graphics.Rect dst ) { dst.set ( ( ( int ) ( java.lang.Math.floor ( left ) ) ) , ( ( int ) ( java.lang.Math.floor ( top ) ) ) , ( ( int ) ( java.lang.Math.ceil ( right ) ) ) , ( ( int ) ( java.lang.Math.ceil ( bottom ) ) ) ) ; }
Source:
public void setHttpAuthUsernamePassword ( final java.lang.String host , final java.lang.String realm , final java.lang.String username , final java.lang.String password ) { if ( checkNeedsPost ( ) ) { mRunQueue.addTask ( new java.lang.Runnable ( ) { @ java.lang.Override public void run ( ) { setHttpAuthUsernamePassword ( host , realm , username , password ) ; } } ) ; return ; } mAwContents.setHttpAuthUsernamePassword ( host , realm , username , password ) ; }

Target:
public android.net.http.SslCertificate getCertificate ( ) { mFactory.startYourEngines ( true ) ; if ( checkNeedsPost ( ) ) { android.net.http.SslCertificate ret = runOnUiThreadBlocking ( new java.util.concurrent.Callable < android.net.http.SslCertificate > ( ) { @ java.lang.Override public android.net.http.SslCertificate call ( ) { return getCertificate ( ) ; } } ) ; return ret ; } return mAwContents.getCertificate ( ) ; }
Source:
public static libcore.Repository openJdkLegacy ( java.nio.file.Path upstreamRoot , java.lang.String upstreamName ) { java.util.List < java.lang.String > sourceDirs = java.util.Arrays.asList ( "jdk/src/share/classes" , "jdk/src/solaris/classes" , "build/linux-x86_64-normal-server-release/jdk/gensrc" ) ; return new libcore.Repository.OpenJdkRepository ( upstreamRoot , upstreamName , sourceDirs ) ; }

Target:
public static libcore.Repository openJdk9 ( java.nio.file.Path upstreamRoot , java.lang.String upstreamName ) { java.util.List < java.lang.String > sourceDirs = java.util.Arrays.asList ( "jdk/src/java.base/share/classes" , "jdk/src/java.logging/share/classes" , "jdk/src/java.prefs/share/classes" , "jdk/src/java.sql/share/classes" , "jdk/src/java.desktop/share/classes" , "jdk/src/java.base/solaris/classes" , "jdk/src/java.base/unix/classes" , "jdk/src/java.prefs/unix/classes" , "jdk/src/jdk.unsupported/share/classes" , "jdk/src/jdk.net/share/classes" , "jdk/src/java.base/linux/classes" , "build/linux-x86_64-normal-server-release/support/gensrc/java.base" , "jdk/src/java.base/unix/native/libjava" , "jdk/src/java.base/share/native/libjava" ) ; return new libcore.Repository.OpenJdkRepository ( upstreamRoot , upstreamName , sourceDirs ) ; }
Source:
public boolean resetLogHandler ( ) { synchronized ( com.android.server.wifi.WifiNative.sLock ) { if ( isHalStarted ( ) ) { if ( ( com.android.server.wifi.WifiNative.sLogCmdId ) == ( - 1 ) ) { android.util.Log.e ( com.android.server.wifi.WifiNative.TAG , "Can not reset handler Before set any handler" ) ; return false ; } com.android.server.wifi.WifiNative.sWifiLoggerEventHandler = null ; if ( com.android.server.wifi.WifiNative.resetLogHandlerNative ( com.android.server.wifi.WifiNative.sWlan0Index , com.android.server.wifi.WifiNative.sLogCmdId ) ) { com.android.server.wifi.WifiNative.sLogCmdId = - 1 ; return true ; } else { return false ; } } else { return false ; } } }

Target:
public boolean resetLogHandler ( ) { if ( com.android.server.wifi.WifiNative.HIDL_VENDOR_ENABLE ) { return mWifiVendorHal.resetLogHandler ( ) ; } else { synchronized ( com.android.server.wifi.WifiNative.sLock ) { if ( isHalStarted ( ) ) { if ( ( com.android.server.wifi.WifiNative.sLogCmdId ) == ( - 1 ) ) { android.util.Log.e ( com.android.server.wifi.WifiNative.TAG , "Can not reset handler Before set any handler" ) ; return false ; } com.android.server.wifi.WifiNative.sWifiLoggerEventHandler = null ; if ( com.android.server.wifi.WifiNative.resetLogHandlerNative ( com.android.server.wifi.WifiNative.sWlan0Index , com.android.server.wifi.WifiNative.sLogCmdId ) ) { com.android.server.wifi.WifiNative.sLogCmdId = - 1 ; return true ; } else { return false ; } } else { return false ; } } } }
Source:
public void TestKatakana ( ) throws java.io.IOException { long start = java.lang.System.currentTimeMillis ( ) ; new com.ibm.icu.dev.test.translit.RoundTripTest.Test ( "Latin-Katakana" ) . test ( "[a-zA-Z]" , com.ibm.icu.dev.test.translit.RoundTripTest.KATAKANA , ( ( ( "[" + ( com.ibm.icu.dev.test.translit.RoundTripTest.KATAKANA_ITERATION ) ) + ( com.ibm.icu.dev.test.translit.RoundTripTest.HALFWIDTH_KATAKANA ) ) + "]" ) , this , new com.ibm.icu.dev.test.translit.RoundTripTest.Legal ( ) ) ; showElapsed ( start , "TestKatakana" ) ; }

Target:
public void TestKatakana ( ) throws java.io.IOException { long start = java.lang.System.currentTimeMillis ( ) ; new com.ibm.icu.dev.test.translit.RoundTripTest.TransliterationTest ( "Latin-Katakana" ) . test ( "[a-zA-Z]" , com.ibm.icu.dev.test.translit.RoundTripTest.KATAKANA , ( ( ( "[" + ( com.ibm.icu.dev.test.translit.RoundTripTest.KATAKANA_ITERATION ) ) + ( com.ibm.icu.dev.test.translit.RoundTripTest.HALFWIDTH_KATAKANA ) ) + "]" ) , this , new com.ibm.icu.dev.test.translit.RoundTripTest.Legal ( ) ) ; showElapsed ( start , "TestKatakana" ) ; }
Source:
private static int convertHalState ( int halState ) { switch ( halState ) { case com.android.bluetooth.hid.HidService.CONN_STATE_CONNECTED : return android.bluetooth.BluetoothProfile.STATE_CONNECTED ; case com.android.bluetooth.hid.HidService.CONN_STATE_CONNECTING : return android.bluetooth.BluetoothProfile.STATE_CONNECTING ; case com.android.bluetooth.hid.HidService.CONN_STATE_DISCONNECTED : return android.bluetooth.BluetoothProfile.STATE_DISCONNECTED ; case com.android.bluetooth.hid.HidService.CONN_STATE_DISCONNECTING : return android.bluetooth.BluetoothProfile.STATE_DISCONNECTING ; default : android.util.Log.e ( com.android.bluetooth.hid.HidService.TAG , ( "bad hid connection state: " + halState ) ) ; return android.bluetooth.BluetoothProfile.STATE_DISCONNECTED ; } }

Target:
private static int convertHalState ( int halState ) { switch ( halState ) { case com.android.bluetooth.hid.HidHostService.CONN_STATE_CONNECTED : return android.bluetooth.BluetoothProfile.STATE_CONNECTED ; case com.android.bluetooth.hid.HidHostService.CONN_STATE_CONNECTING : return android.bluetooth.BluetoothProfile.STATE_CONNECTING ; case com.android.bluetooth.hid.HidHostService.CONN_STATE_DISCONNECTED : return android.bluetooth.BluetoothProfile.STATE_DISCONNECTED ; case com.android.bluetooth.hid.HidHostService.CONN_STATE_DISCONNECTING : return android.bluetooth.BluetoothProfile.STATE_DISCONNECTING ; default : android.util.Log.e ( com.android.bluetooth.hid.HidHostService.TAG , ( "bad hid connection state: " + halState ) ) ; return android.bluetooth.BluetoothProfile.STATE_DISCONNECTED ; } }
Source:
private java.lang.CharSequence getDialerTos ( ) { if ( ! ( isVoicemailTranscriptionEnabled ( ) ) ) { return "" ; } if ( isVvm3 ( ) ) { return context.getString ( R.string.dialer_terms_and_conditions_for_verizon_1_0 ) ; } else { java.lang.String learnMoreText = context.getString ( R.string.dialer_terms_and_conditions_learn_more ) ; return context.getString ( R.string.dialer_terms_and_conditions_1_0 , learnMoreText ) ; } }

Target:
private java.lang.CharSequence getVvmDialerTos ( ) { if ( ! ( isVoicemailTranscriptionEnabled ( ) ) ) { return "" ; } return context.getString ( R.string.dialer_terms_and_conditions_for_verizon_1_0 ) ; }
Source:
private com.android.hierarchyviewerlib.scene.DrawableViewNode.Point transformPoint ( double x , double y ) { float [ ] pt = new float [ ] { ( ( float ) ( x ) ) , ( ( float ) ( y ) ) } ; inverse.transform ( pt ) ; return new com.android.hierarchyviewerlib.scene.DrawableViewNode.Point ( pt [ 0 ] , pt [ 1 ] ) ; }

Target:
private com.android.hierarchyviewerlib.ui.util.DrawableViewNode.Point transformPoint ( double x , double y ) { float [ ] pt = new float [ ] { ( ( float ) ( x ) ) , ( ( float ) ( y ) ) } ; inverse.transform ( pt ) ; return new com.android.hierarchyviewerlib.ui.util.DrawableViewNode.Point ( pt [ 0 ] , pt [ 1 ] ) ; }
Source:
public boolean canUpgradeToRttCall ( ) { android.telecom.PhoneAccount phoneAccount = getPhoneAccount ( ) ; if ( phoneAccount == null ) { return false ; } if ( ! ( phoneAccount.hasCapabilities ( PhoneAccount.CAPABILITY_RTT ) ) ) { return false ; } if ( isActiveRttCall ( ) ) { return false ; } if ( isVideoCall ( ) ) { return false ; } if ( isConferenceCall ( ) ) { return false ; } if ( com.android.incallui.call.CallList.getInstance ( ) . hasActiveRttCall ( ) ) { return false ; } return true ; }

Target:
public boolean isPhoneAccountRttCapable ( ) { android.telecom.PhoneAccount phoneAccount = getPhoneAccount ( ) ; if ( phoneAccount == null ) { return false ; } if ( ! ( phoneAccount.hasCapabilities ( PhoneAccount.CAPABILITY_RTT ) ) ) { return false ; } return true ; }
Source:
private long getActiveQueueItemId ( @ android.annotation.Nullable com.android.bluetooth.avrcp.MediaController controller ) { if ( controller == null ) return android.media.session.MediaSession.QueueItem.UNKNOWN_ID ; android.media.session.PlaybackState state = controller.getPlaybackState ( ) ; if ( state == null ) return android.media.session.MediaSession.QueueItem.UNKNOWN_ID ; return state.getActiveQueueItemId ( ) ; }

Target:
private long getActiveQueueItemId ( @ android.annotation.Nullable com.android.bluetooth.avrcp.MediaController controller ) { if ( controller == null ) return android.media.session.MediaSession.QueueItem.UNKNOWN_ID ; android.media.session.PlaybackState state = controller.getPlaybackState ( ) ; if ( state == null ) return android.media.session.MediaSession.QueueItem.UNKNOWN_ID ; long qid = state.getActiveQueueItemId ( ) ; if ( qid != ( android.media.session.MediaSession.QueueItem.UNKNOWN_ID ) ) return qid ; if ( ( controller.getMetadata ( ) ) != null ) return com.android.bluetooth.avrcp.AddressedMediaPlayer.SINGLE_QID ; return android.media.session.MediaSession.QueueItem.UNKNOWN_ID ; }
Source:
private void onGetProtocolMode ( byte [ ] address , int mode ) { android.os.Message msg = mHandler.obtainMessage ( com.android.bluetooth.hid.HidService.MESSAGE_ON_GET_PROTOCOL_MODE ) ; msg.obj = address ; msg.arg1 = mode ; mHandler.sendMessage ( msg ) ; }

Target:
private void onGetProtocolMode ( byte [ ] address , int mode ) { if ( com.android.bluetooth.hid.HidService.DBG ) android.util.Log.d ( com.android.bluetooth.hid.HidService.TAG , "onGetProtocolMode()" ) ; android.os.Message msg = mHandler.obtainMessage ( com.android.bluetooth.hid.HidService.MESSAGE_ON_GET_PROTOCOL_MODE ) ; msg.obj = address ; msg.arg1 = mode ; mHandler.sendMessage ( msg ) ; }
Source:
public void setLayerType ( final int layerType , final android.graphics.Paint paint ) { if ( ( mAwContents ) == null ) return ; if ( checkNeedsPost ( ) ) { org.chromium.base.ThreadUtils.postOnUiThread ( new java.lang.Runnable ( ) { @ java.lang.Override public void run ( ) { setLayerType ( layerType , paint ) ; } } ) ; return ; } mAwContents.setLayerType ( layerType , paint ) ; }

Target:
public void setBackgroundColor ( final int color ) { mFactory.startYourEngines ( false ) ; if ( checkNeedsPost ( ) ) { org.chromium.base.ThreadUtils.postOnUiThread ( new java.lang.Runnable ( ) { @ java.lang.Override public void run ( ) { setBackgroundColor ( color ) ; } } ) ; return ; } mAwContents.setBackgroundColor ( color ) ; }
Source:
public void onRtlPropertiesChanged ( int layoutDirection ) { super . onRtlPropertiesChanged ( layoutDirection ) ; int max = getMax ( ) ; float scale = ( max > 0 ) ? ( ( float ) ( getProgress ( ) ) ) / ( ( float ) ( max ) ) : 0 ; android.graphics.drawable.Drawable thumb = mThumb ; if ( thumb != null ) { setThumbPos ( getWidth ( ) , thumb , scale , java.lang.Integer.MIN_VALUE ) ; invalidate ( ) ; } }

Target:
public void onRtlPropertiesChanged ( int layoutDirection ) { super . onRtlPropertiesChanged ( layoutDirection ) ; final android.graphics.drawable.Drawable thumb = mThumb ; if ( thumb != null ) { setThumbPos ( getWidth ( ) , thumb , getScale ( ) , java.lang.Integer.MIN_VALUE ) ; invalidate ( ) ; } }
Source:
public void setFocusedStack ( int stackId ) { if ( com.android.server.am.ActivityManagerService.DEBUG_FOCUS ) android.util.Slog.d ( com.android.server.am.ActivityManagerService.TAG , ( "setFocusedStack: stackId=" + stackId ) ) ; synchronized ( this ) { com.android.server.am.ActivityStack stack = mStackSupervisor.getStack ( stackId ) ; if ( stack != null ) { com.android.server.am.ActivityRecord r = stack.topRunningActivityLocked ( null ) ; if ( r != null ) { setFocusedActivityLocked ( r ) ; } } } }

Target:
public void registerTaskStackListener ( android.app.ITaskStackListener listener ) throws android.os.RemoteException { synchronized ( this ) { if ( listener != null ) { mTaskStackListeners.register ( listener ) ; } } }
Source:
public void connect ( java.net.SocketAddress remoteAddr , int timeout ) throws java.io.IOException { if ( ! ( channel.isBlocking ( ) ) ) { throw new java.nio.channels.IllegalBlockingModeException ( ) ; } if ( isConnected ( ) ) { throw new java.nio.channels.AlreadyConnectedException ( ) ; } super . connect ( remoteAddr , timeout ) ; channel.onBind ( false ) ; if ( super . isConnected ( ) ) { java.net.InetSocketAddress remoteInetAddress = ( ( java.net.InetSocketAddress ) ( remoteAddr ) ) ; channel.onConnect ( remoteInetAddress , java.nio.SocketChannelImpl.SOCKET_STATUS_CONNECTED , false ) ; } }

Target:
public void connect ( java.net.SocketAddress remoteAddr , int timeout ) throws java.io.IOException { if ( ! ( channel.isBlocking ( ) ) ) { throw new java.nio.channels.IllegalBlockingModeException ( ) ; } if ( isConnected ( ) ) { throw new java.nio.channels.AlreadyConnectedException ( ) ; } super . connect ( remoteAddr , timeout ) ; channel.onBind ( false ) ; if ( super . isConnected ( ) ) { java.net.InetSocketAddress remoteInetAddress = ( ( java.net.InetSocketAddress ) ( remoteAddr ) ) ; channel.onConnectStatusChanged ( remoteInetAddress , java.nio.SocketChannelImpl.SOCKET_STATUS_CONNECTED , false ) ; } }
Source:
private void sendCallChangedIntent ( android.bluetooth.BluetoothHeadsetClientCall c ) { android.content.Intent intent = new android.content.Intent ( android.bluetooth.BluetoothHeadsetClient.ACTION_CALL_CHANGED ) ; intent.putExtra ( BluetoothHeadsetClient.EXTRA_CALL , c ) ; mService.sendBroadcast ( intent , ProfileService.BLUETOOTH_PERM ) ; }

Target:
private void sendCallChangedIntent ( android.bluetooth.BluetoothHeadsetClientCall c ) { if ( com.android.bluetooth.hfpclient.HeadsetClientStateMachine.DBG ) { android.util.Log.d ( com.android.bluetooth.hfpclient.HeadsetClientStateMachine.TAG , ( "sendCallChangedIntent " + c ) ) ; } android.content.Intent intent = new android.content.Intent ( android.bluetooth.BluetoothHeadsetClient.ACTION_CALL_CHANGED ) ; intent.addFlags ( Intent.FLAG_RECEIVER_FOREGROUND ) ; intent.putExtra ( BluetoothHeadsetClient.EXTRA_CALL , c ) ; mService.sendBroadcast ( intent , ProfileService.BLUETOOTH_PERM ) ; }
Source:
public void pasteFromClipboard ( ) { android.content.ClipboardManager cm = ( ( android.content.ClipboardManager ) ( mContext.getSystemService ( Context.CLIPBOARD_SERVICE ) ) ) ; android.content.ClipData clipData = cm.getPrimaryClip ( ) ; if ( clipData != null ) { android.content.ClipData.Item clipItem = clipData.getItemAt ( 0 ) ; java.lang.CharSequence pasteText = clipItem.getText ( ) ; if ( ( mInputConnection ) != null ) { mInputConnection.replaceSelection ( pasteText ) ; } } }

Target:
public void pasteFromClipboard ( ) { android.content.ClipboardManager cm = ( ( android.content.ClipboardManager ) ( mContext.getSystemService ( Context.CLIPBOARD_SERVICE ) ) ) ; android.content.ClipData clipData = cm.getPrimaryClip ( ) ; if ( clipData != null ) { android.content.ClipData.Item clipItem = clipData.getItemAt ( 0 ) ; java.lang.CharSequence pasteText = clipItem.coerceToText ( mContext ) ; if ( ( mInputConnection ) != null ) { mInputConnection.replaceSelection ( pasteText ) ; } } }
Source:
public void testEndCallWithRingingForegroundCall ( ) throws java.lang.Exception { com.android.server.telecom.Call call = org.mockito.Mockito.mock ( com.android.server.telecom.Call.class ) ; org.mockito.Mockito.when ( call.getState ( ) ) . thenReturn ( CallState.RINGING ) ; org.mockito.Mockito.when ( mFakeCallsManager.getForegroundCall ( ) ) . thenReturn ( call ) ; assertTrue ( mTSIBinder.endCall ( ) ) ; org.mockito.Mockito.verify ( call ) . reject ( false , null ) ; }

Target:
public void testEndCallWithRingingForegroundCall ( ) throws java.lang.Exception { com.android.server.telecom.Call call = org.mockito.Mockito.mock ( com.android.server.telecom.Call.class ) ; org.mockito.Mockito.when ( call.getState ( ) ) . thenReturn ( CallState.RINGING ) ; org.mockito.Mockito.when ( mFakeCallsManager.getForegroundCall ( ) ) . thenReturn ( call ) ; org.junit.Assert.assertTrue ( mTSIBinder.endCall ( ) ) ; org.mockito.Mockito.verify ( call ) . reject ( false , null ) ; }
Source:
public int getUpdateOutputSize ( int len ) { int total = len + ( bufOff ) ; int leftOver = total % ( buf.length ) ; if ( leftOver == 0 ) { return total - ( buf.length ) ; } return total - leftOver ; }

Target:
public int getUpdateOutputSize ( int len ) { int total = len + ( bufOff ) ; int leftOver = total % ( buf.length ) ; if ( leftOver == 0 ) { return java.lang.Math.max ( 0 , ( total - ( buf.length ) ) ) ; } return total - leftOver ; }
Source:
synchronized void setDebugSelectedPort ( int port ) throws java.lang.IllegalStateException { if ( ( com.android.ddmlib.MonitorThread.mInstance ) == null ) { return ; } if ( ( com.android.ddmlib.AndroidDebugBridge.getClientSupport ( ) ) == false ) { return ; } if ( ( mDebugSelectedChan ) != null ) { com.android.ddmlib.Log.d ( "ddms" , ( "Changing debug-selected port to " + port ) ) ; mNewDebugSelectedPort = port ; wakeup ( ) ; } else { mNewDebugSelectedPort = port ; } }

Target:
synchronized void setDebugSelectedPort ( int port ) throws java.lang.IllegalStateException { if ( ( com.android.ddmlib.MonitorThread.sInstance ) == null ) { return ; } if ( ( com.android.ddmlib.AndroidDebugBridge.getClientSupport ( ) ) == false ) { return ; } if ( ( mDebugSelectedChan ) != null ) { com.android.ddmlib.Log.d ( "ddms" , ( "Changing debug-selected port to " + port ) ) ; mNewDebugSelectedPort = port ; wakeup ( ) ; } else { mNewDebugSelectedPort = port ; } }
Source:
public java.lang.String toHuman ( ) { return ( ( ( "InvokeDynamic(" + ( bootstrapMethodIndex ) ) + ", " ) + ( nat.toHuman ( ) ) ) + ")" ; }

Target:
public java.lang.String toHuman ( ) { java.lang.String klass = ( ( declaringClass ) != null ) ? declaringClass.toHuman ( ) : "Unknown" ; return ( ( ( ( ( "InvokeDynamic(" + klass ) + ":" ) + ( bootstrapMethodIndex ) ) + ", " ) + ( nat.toHuman ( ) ) ) + ")" ; }
Source:
public void testConferenceRemoveExtras2 ( ) { if ( ! ( mShouldTestTelecom ) ) { return ; } final android.telecom.Call conf = mInCallService.getLastConferenceCall ( ) ; assertCallState ( conf , Call.STATE_ACTIVE ) ; setupExtras ( ) ; mConferenceObject.removeExtras ( android.telecom.cts.ConferenceTest.TEST_EXTRA_KEY_1 , android.telecom.cts.ConferenceTest.TEST_EXTRA_KEY_2 ) ; mOnExtrasChangedCounter.waitForCount ( 2 ) ; android.os.Bundle extras = mConferenceObject.getExtras ( ) ; assertTrue ( ( ( extras == null ) || ( extras.isEmpty ( ) ) ) ) ; }

Target:
public void testConferenceRemoveExtras2 ( ) { if ( ! ( mShouldTestTelecom ) ) { return ; } final android.telecom.Call conf = mInCallService.getLastConferenceCall ( ) ; assertCallState ( conf , Call.STATE_ACTIVE ) ; setupExtras ( ) ; int startInvokeCount = mOnExtrasChangedCounter.getInvokeCount ( ) ; mConferenceObject.removeExtras ( android.telecom.cts.ConferenceTest.TEST_EXTRA_KEY_1 , android.telecom.cts.ConferenceTest.TEST_EXTRA_KEY_2 ) ; mOnExtrasChangedCounter.waitForCount ( ( startInvokeCount + 1 ) , android.telecom.cts.WAIT_FOR_STATE_CHANGE_TIMEOUT_MS ) ; android.os.Bundle extras = mConferenceObject.getExtras ( ) ; assertFalse ( extras.containsKey ( android.telecom.cts.ConferenceTest.TEST_EXTRA_KEY_1 ) ) ; assertFalse ( extras.containsKey ( android.telecom.cts.ConferenceTest.TEST_EXTRA_KEY_2 ) ) ; }
Source:
void copy2DRangeFromUnchecked ( int xoff , int yoff , int w , int h , float [ ] data ) { android.os.Trace.traceBegin ( RenderScript.TRACE_TAG , "copy2DRangeFromUnchecked" ) ; mRS.validate ( ) ; validate2DRange ( xoff , yoff , w , h ) ; mRS.nAllocationData2D ( getIDSafe ( ) , xoff , yoff , mSelectedLOD , mSelectedFace.mID , w , h , data , ( ( data.length ) * 4 ) , Element.DataType.FLOAT_32 ) ; android.os.Trace.traceEnd ( RenderScript.TRACE_TAG ) ; }

Target:
public void copy1DRangeFrom ( int off , int count , short [ ] d ) { validateIsInt16 ( ) ; copy1DRangeFromUnchecked ( off , count , d , Element.DataType.SIGNED_16 , d.length ) ; }
Source:
public static java.security.cert.CertPath fromEncoding ( java.io.InputStream inStream , java.lang.String encoding ) throws java.security.cert.CertificateException { org.apache.harmony.xnet.provider.jsse.OpenSSLX509CertPath.Encoding enc = org.apache.harmony.xnet.provider.jsse.OpenSSLX509CertPath.Encoding.findByApiName ( encoding ) ; if ( enc == null ) { throw new java.security.cert.CertificateException ( ( "Invalid encoding: " + encoding ) ) ; } return org.apache.harmony.xnet.provider.jsse.OpenSSLX509CertPath.fromEncoding ( inStream , enc ) ; }

Target:
public static java.security.cert.CertPath fromEncoding ( java.io.InputStream inStream , java.lang.String encoding ) throws java.security.cert.CertificateException { if ( inStream == null ) { throw new java.lang.NullPointerException ( "inStream == null" ) ; } org.apache.harmony.xnet.provider.jsse.OpenSSLX509CertPath.Encoding enc = org.apache.harmony.xnet.provider.jsse.OpenSSLX509CertPath.Encoding.findByApiName ( encoding ) ; if ( enc == null ) { throw new java.security.cert.CertificateException ( ( "Invalid encoding: " + encoding ) ) ; } return org.apache.harmony.xnet.provider.jsse.OpenSSLX509CertPath.fromEncoding ( inStream , enc ) ; }
Source:
public void testInterfaceCountersUdp4UdpEncap ( ) throws java.lang.Exception { android.net.IpSecAlgorithm crypt = new android.net.IpSecAlgorithm ( android.net.IpSecAlgorithm.CRYPT_AES_CBC , android.net.cts.IpSecManagerTest.CRYPT_KEY ) ; android.net.IpSecAlgorithm auth = new android.net.IpSecAlgorithm ( android.net.IpSecAlgorithm.AUTH_HMAC_MD5 , getAuthKey ( 128 ) , 96 ) ; checkTransform ( android.system.OsConstants.IPPROTO_UDP , android.net.cts.IpSecManagerTest.IPV4_LOOPBACK , crypt , auth , true , 1000 , false ) ; }

Target:
public void testAesCbcHmacSha384Tcp4UdpEncap ( ) throws java.lang.Exception { android.net.IpSecAlgorithm crypt = new android.net.IpSecAlgorithm ( android.net.IpSecAlgorithm.CRYPT_AES_CBC , android.net.cts.IpSecManagerTest.CRYPT_KEY ) ; android.net.IpSecAlgorithm auth = new android.net.IpSecAlgorithm ( android.net.IpSecAlgorithm.AUTH_HMAC_SHA384 , android.net.cts.IpSecManagerTest.getKey ( 384 ) , 192 ) ; checkTransform ( android.system.OsConstants.IPPROTO_TCP , android.net.cts.IpSecManagerTest.IPV4_LOOPBACK , crypt , auth , null , true , 1 , false ) ; checkTransform ( android.system.OsConstants.IPPROTO_TCP , android.net.cts.IpSecManagerTest.IPV4_LOOPBACK , crypt , auth , null , true , 1 , true ) ; }
Source:
public boolean isBetterMatchThan ( com.android.ide.eclipse.adt.internal.resources.configurations.ResourceQualifier compareTo , com.android.ide.eclipse.adt.internal.resources.configurations.ResourceQualifier reference ) { if ( compareTo == null ) { return true ; } com.android.ide.eclipse.adt.internal.resources.configurations.PixelDensityQualifier compareQ = ( ( com.android.ide.eclipse.adt.internal.resources.configurations.PixelDensityQualifier ) ( compareTo ) ) ; com.android.ide.eclipse.adt.internal.resources.configurations.PixelDensityQualifier referenceQ = ( ( com.android.ide.eclipse.adt.internal.resources.configurations.PixelDensityQualifier ) ( reference ) ) ; if ( ( ( mValue ) == ( referenceQ.mValue ) ) && ( ( compareQ.mValue ) != ( referenceQ.mValue ) ) ) { return true ; } else { return ( mValue.mDensity.getValue ( ) ) > ( compareQ.mValue.mDensity.getValue ( ) ) ; } }

Target:
public java.lang.String getStringValue ( ) { if ( ( mValue ) != null ) { return mValue.getDisplayValue ( ) ; } return "" ; }
Source:
private void showInterstitialAndProvision ( final com.android.managedprovisioning.ProvisioningParams params ) { if ( ( mUserConsented ) || ( params.mStartedByNfc ) ) { startDeviceOwnerProvisioningService ( params ) ; } else { com.android.managedprovisioning.UserConsentDialog.newInstance ( UserConsentDialog.DEVICE_OWNER ) . show ( getFragmentManager ( ) , "UserConsentDialogFragment" ) ; } }

Target:
private void showInterstitialAndProvision ( final com.android.managedprovisioning.ProvisioningParams params ) { boolean supportFrp = isFrpSupported ( ) ; if ( ( mUserConsented ) || ( ( ! supportFrp ) && ( params.mStartedByNfc ) ) ) { startDeviceOwnerProvisioningService ( params ) ; } else { com.android.managedprovisioning.UserConsentDialog.newInstance ( UserConsentDialog.DEVICE_OWNER , supportFrp ) . show ( getFragmentManager ( ) , "UserConsentDialogFragment" ) ; } }
Source:
public void takePersistableUriPermission ( android.net.Uri uri , int modeFlags ) { try { android.app.ActivityManagerNative.getDefault ( ) . takePersistableUriPermission ( uri , modeFlags ) ; } catch ( android.os.RemoteException e ) { } }

Target:
public void takePersistableUriPermission ( @ android.annotation.NonNull android.net.Uri uri , @ android.content.Intent.AccessUriMode int modeFlags ) { com.android.internal.util.Preconditions.checkNotNull ( uri , "uri" ) ; try { android.app.ActivityManagerNative.getDefault ( ) . takePersistableUriPermission ( android.content.ContentProvider.getUriWithoutUserId ( uri ) , modeFlags , resolveUserId ( uri ) ) ; } catch ( android.os.RemoteException e ) { } }
Source:
public void entering ( java.lang.String sourceClass , java.lang.String sourceMethod , java.lang.Object param1 ) { if ( ( java.util.logging.Level.FINER.intValue ( ) ) < ( levelValue ) ) { return ; } java.lang.Object [ ] params = new java.lang.Object [ ] { param1 } ; logp ( java.util.logging.Level.FINER , sourceClass , sourceMethod , "ENTRY {0}" , params ) ; }

Target:
public void info ( java.util.function.Supplier < java.lang.String > msgSupplier ) { log ( java.util.logging.Level.INFO , msgSupplier ) ; }