auphong2707/dl4se-code-review-dataset huggingface dataset:
Source:
public void onLosing ( android.net.Network network , int maxMsToLive ) { com.googlecode.android_scripting.Log.d ( "NetworkCallback onLosing" ) ; if ( ( ( mEvents ) & ( com.googlecode.android_scripting.facade.ConnectivityManagerFacade.NetworkCallback.EVENT_LOSING ) ) == ( com.googlecode.android_scripting.facade.ConnectivityManagerFacade.NetworkCallback.EVENT_LOSING ) ) { mEventFacade.postEvent ( TelephonyConstants.EventNetworkCallback , new com.googlecode.android_scripting.facade.telephony.TelephonyEvents.NetworkCallbackEvent ( mId , com.googlecode.android_scripting.facade.ConnectivityManagerFacade.getNetworkCallbackEventString ( com.googlecode.android_scripting.facade.ConnectivityManagerFacade.NetworkCallback.EVENT_LOSING ) , TelephonyEvents.NetworkCallbackEvent.INVALID_VALUE , maxMsToLive ) ) ; } }

Target:
public void onLosing ( android.net.Network network , int maxMsToLive ) { com.googlecode.android_scripting.Log.d ( "NetworkCallback onLosing" ) ; if ( ( ( mEvents ) & ( com.googlecode.android_scripting.facade.ConnectivityManagerFacade.NetworkCallback.EVENT_LOSING ) ) == ( com.googlecode.android_scripting.facade.ConnectivityManagerFacade.NetworkCallback.EVENT_LOSING ) ) { mEventFacade.postEvent ( ConnectivityConstants.EventNetworkCallback , new com.googlecode.android_scripting.facade.ConnectivityEvents.NetworkCallbackEventOnLosing ( mId , com.googlecode.android_scripting.facade.ConnectivityManagerFacade.getNetworkCallbackEventString ( com.googlecode.android_scripting.facade.ConnectivityManagerFacade.NetworkCallback.EVENT_LOSING ) , maxMsToLive ) ) ; } }
Source:
private static float distance ( float x1 , float y1 , float x2 , float y2 ) { float x = x2 - x1 ; float y = y2 - y1 ; return android.util.FloatMath.sqrt ( ( ( x * x ) + ( y * y ) ) ) ; }

Target:
private static double distance ( float x1 , float y1 , float x2 , float y2 ) { double x = x2 - x1 ; double y = y2 - y1 ; return java.lang.Math.hypot ( x , y ) ; }
Source:
boolean doBind ( ) { android.content.Intent intent = new android.content.Intent ( android.bluetooth.IBluetoothInputDevice.class . getName ( ) ) ; android.content.ComponentName comp = intent.resolveSystemService ( mContext.getPackageManager ( ) , 0 ) ; intent.setComponent ( comp ) ; if ( ( comp == null ) || ( ! ( mContext.bindServiceAsUser ( intent , mConnection , 0 , android.os.Process.myUserHandle ( ) ) ) ) ) { android.util.Log.e ( android.bluetooth.BluetoothInputDevice.TAG , ( "Could not bind to Bluetooth HID Service with " + intent ) ) ; return false ; } return true ; }

Target:
boolean doBind ( ) { android.content.Intent intent = new android.content.Intent ( android.bluetooth.IBluetoothHidHost.class . getName ( ) ) ; android.content.ComponentName comp = intent.resolveSystemService ( mContext.getPackageManager ( ) , 0 ) ; intent.setComponent ( comp ) ; if ( ( comp == null ) || ( ! ( mContext.bindServiceAsUser ( intent , mConnection , 0 , android.os.Process.myUserHandle ( ) ) ) ) ) { android.util.Log.e ( android.bluetooth.BluetoothHidHost.TAG , ( "Could not bind to Bluetooth HID Service with " + intent ) ) ; return false ; } return true ; }
Source:
void copy3DRangeFromUnchecked ( int xoff , int yoff , int zoff , int w , int h , int d , short [ ] data ) { mRS.validate ( ) ; validate3DRange ( xoff , yoff , zoff , w , h , d ) ; mRS.nAllocationData3D ( getIDSafe ( ) , xoff , yoff , zoff , mSelectedLOD , w , h , d , data , ( ( data.length ) * 2 ) , Element.DataType.SIGNED_16 ) ; }

Target:
public void copy2DRangeFrom ( int xoff , int yoff , int w , int h , int [ ] data ) { validateIsInt32 ( ) ; copy2DRangeFromUnchecked ( xoff , yoff , w , h , data , Element.DataType.SIGNED_32 , data.length ) ; }
Source:
public boolean visitImportDeclaration ( lombok.ast.ImportDeclaration node ) { java.lang.String fqn = node.asFullyQualifiedName ( ) ; if ( fqn.equals ( "android.R" ) ) { com.android.tools.lint.detector.api.Location location = mContext.getLocation ( node ) ; mContext.report ( com.android.tools.lint.checks.WrongImportDetector.ISSUE , node , location , ( "Don't include android.R here; use a fully qualified name for " + "each usage instead" ) , null ) ; } return false ; }

Target:
public boolean visitImportDeclaration ( lombok.ast.ImportDeclaration node ) { java.lang.String fqn = node.asFullyQualifiedName ( ) ; if ( fqn.equals ( "android.R" ) ) { com.android.tools.lint.detector.api.Location location = mContext.getLocation ( node ) ; mContext.report ( com.android.tools.lint.checks.WrongImportDetector.ISSUE , node , location , ( "Don't include `android.R` here; use a fully qualified name for " + "each usage instead" ) , null ) ; } return false ; }
Source:
public boolean setPriority ( android.bluetooth.BluetoothDevice device , int priority ) { enforceCallingOrSelfPermission ( com.android.bluetooth.hfp.BLUETOOTH_ADMIN_PERM , "Need BLUETOOTH_ADMIN permission" ) ; Settings.Global.putInt ( getContentResolver ( ) , Settings.Global.getBluetoothHeadsetPriorityKey ( device.getAddress ( ) ) , priority ) ; if ( com.android.bluetooth.hfp.HeadsetService.DBG ) { android.util.Log.d ( com.android.bluetooth.hfp.HeadsetService.TAG , ( ( ( "Saved priority " + device ) + " = " ) + priority ) ) ; } return true ; }

Target:
public boolean setPriority ( android.bluetooth.BluetoothDevice device , int priority ) { enforceCallingOrSelfPermission ( com.android.bluetooth.hfp.BLUETOOTH_ADMIN_PERM , "Need BLUETOOTH_ADMIN permission" ) ; Settings.Global.putInt ( getContentResolver ( ) , Settings.Global.getBluetoothHeadsetPriorityKey ( device.getAddress ( ) ) , priority ) ; com.android.bluetooth.hfp.HeadsetService.logD ( ( ( ( "Saved priority " + device ) + " = " ) + priority ) ) ; return true ; }
Source:
public static final void enforceTetherChangePermission ( android.content.Context context , java.lang.String callingPkg ) { if ( ( null == context ) || ( null == callingPkg ) ) { throw new java.lang.IllegalArgumentException ( "arguments should not be null" ) ; } if ( ( context.getResources ( ) . getStringArray ( com.android.internal.R.array.config_mobile_hotspot_provision_app ) . length ) == 2 ) { context.enforceCallingOrSelfPermission ( android.net.android.Manifest.permission.TETHER_PRIVILEGED , "ConnectivityService" ) ; } else { int uid = android.os.Binder.getCallingUid ( ) ; android.provider.Settings.checkAndNoteWriteSettingsOperation ( context , uid , callingPkg , true ) ; } }

Target:
public static final void enforceTetherChangePermission ( android.content.Context context , java.lang.String callingPkg ) { com.android.internal.util.Preconditions.checkNotNull ( context , "Context cannot be null" ) ; com.android.internal.util.Preconditions.checkNotNull ( callingPkg , "callingPkg cannot be null" ) ; if ( ( context.getResources ( ) . getStringArray ( com.android.internal.R.array.config_mobile_hotspot_provision_app ) . length ) == 2 ) { context.enforceCallingOrSelfPermission ( android.net.android.Manifest.permission.TETHER_PRIVILEGED , "ConnectivityService" ) ; } else { int uid = android.os.Binder.getCallingUid ( ) ; android.provider.Settings.checkAndNoteWriteSettingsOperation ( context , uid , callingPkg , true ) ; } }
Source:
private static com.intellij.ide.impl.DataProvider getDataProvider ( java.lang.Object component ) { com.intellij.ide.impl.DataProvider dataProvider = null ; if ( component instanceof com.intellij.ide.impl.DataProvider ) { dataProvider = ( ( com.intellij.ide.impl.DataProvider ) ( component ) ) ; } else if ( component instanceof com.intellij.ide.impl.TypeSafeDataProvider ) { dataProvider = new com.intellij.ide.impl.TypeSafeDataProviderAdapter ( ( ( com.intellij.ide.impl.TypeSafeDataProvider ) ( component ) ) ) ; } else if ( component instanceof javax.swing.JComponent ) { dataProvider = com.intellij.ide.impl.DataManagerImpl.getDataProvider ( ( ( javax.swing.JComponent ) ( component ) ) ) ; } return dataProvider ; }

Target:
public static com.intellij.ide.impl.DataProvider getDataProviderEx ( java.lang.Object component ) { com.intellij.ide.impl.DataProvider dataProvider = null ; if ( component instanceof com.intellij.ide.impl.DataProvider ) { dataProvider = ( ( com.intellij.ide.impl.DataProvider ) ( component ) ) ; } else if ( component instanceof com.intellij.ide.impl.TypeSafeDataProvider ) { dataProvider = new com.intellij.ide.impl.TypeSafeDataProviderAdapter ( ( ( com.intellij.ide.impl.TypeSafeDataProvider ) ( component ) ) ) ; } else if ( component instanceof javax.swing.JComponent ) { dataProvider = getDataProvider ( ( ( javax.swing.JComponent ) ( component ) ) ) ; } return dataProvider ; }
Source:
public void write ( java.lang.String filename , byte [ ] content ) throws java.io.IOException { com.google.common.base.Preconditions.checkArgument ( filename.endsWith ( ".class" ) ) ; com.google.devtools.build.android.desugar.ZipOutputFileProvider.writeStoredEntry ( out , filename , content ) ; }

Target:
public void write ( java.lang.String filename , byte [ ] content ) throws java.io.IOException { com.google.common.base.Preconditions.checkArgument ( ( ( filename.equals ( com.google.devtools.build.android.desugar.DESUGAR_DEPS_FILENAME ) ) || ( filename.endsWith ( ".class" ) ) ) , "Expect file to be copied: %s" , filename ) ; com.google.devtools.build.android.desugar.ZipOutputFileProvider.writeStoredEntry ( out , filename , content ) ; }
Source:
public static synchronized com.android.bluetooth.hfp.HeadsetService getHeadsetService ( ) { if ( ( com.android.bluetooth.hfp.HeadsetService.sHeadsetService ) == null ) { android.util.Log.w ( com.android.bluetooth.hfp.HeadsetService.TAG , "getHeadsetService(): service is NULL" ) ; return null ; } if ( ! ( com.android.bluetooth.hfp.HeadsetService.sHeadsetService.isAvailable ( ) ) ) { android.util.Log.w ( com.android.bluetooth.hfp.HeadsetService.TAG , "getHeadsetService(): service is not available" ) ; return null ; } com.android.bluetooth.hfp.HeadsetService.logD ( ( "getHeadsetService(): returning " + ( com.android.bluetooth.hfp.HeadsetService.sHeadsetService ) ) ) ; return com.android.bluetooth.hfp.HeadsetService.sHeadsetService ; }

Target:
boolean disconnect ( android.bluetooth.BluetoothDevice device ) { enforceCallingOrSelfPermission ( com.android.bluetooth.hfp.BLUETOOTH_ADMIN_PERM , "Need BLUETOOTH ADMIN permission" ) ; android.util.Log.d ( com.android.bluetooth.hfp.HeadsetService.TAG , ( "disconnect: device=" + device ) ) ; int connectionState = mStateMachine.getConnectionState ( device ) ; if ( ( connectionState != ( android.bluetooth.BluetoothProfile.STATE_CONNECTED ) ) && ( connectionState != ( android.bluetooth.BluetoothProfile.STATE_CONNECTING ) ) ) { android.util.Log.w ( com.android.bluetooth.hfp.HeadsetService.TAG , ( ( ( "disconnect: not connected/connecting, connectionState=" + connectionState ) + ", device=" ) + device ) ) ; return false ; } mStateMachine.sendMessage ( HeadsetStateMachine.DISCONNECT , device ) ; return true ; }
Source:
public void testStaging_uninstall_withCurrent ( ) throws java.lang.Exception { createSystemTzDataFileOnHost ( com.android.cts.tzdata.TzDataCheckTest.VALID_RULES_VERSION ) ; com.android.cts.tzdata.TzDataCheckTest.PathPair dataStagedDir = mDataDir.createSubPath ( com.android.cts.tzdata.TzDataCheckTest.STAGED_DIR_NAME ) ; com.android.cts.tzdata.TzDataCheckTest.createStagedUninstallOnHost ( dataStagedDir ) ; com.android.cts.tzdata.TzDataCheckTest.PathPair dataCurrentDir = mDataDir.createSubPath ( com.android.cts.tzdata.TzDataCheckTest.CURRENT_DIR_NAME ) ; libcore.tzdata.shared2.TimeZoneDistro distro = com.android.cts.tzdata.TzDataCheckTest.createValidDistroBuilder ( ) . build ( ) ; com.android.cts.tzdata.TzDataCheckTest.unpackOnHost ( dataCurrentDir , distro ) ; pushHostTestDirToDevice ( ) ; assertEquals ( 0 , runTzDataCheckOnDevice ( ) ) ; assertDevicePathDoesNotExist ( dataStagedDir ) ; assertDevicePathDoesNotExist ( dataCurrentDir ) ; }

Target:
public void testStaging_uninstall_withCurrent ( ) throws java.lang.Exception { createSystemTzDataFileOnHost ( com.android.cts.tzdata.TzDataCheckTest.VALID_RULES_VERSION ) ; com.android.cts.tzdata.TzDataCheckTest.PathPair dataStagedDir = mDataDir.createSubPath ( com.android.cts.tzdata.TzDataCheckTest.STAGED_DIR_NAME ) ; com.android.cts.tzdata.TzDataCheckTest.createStagedUninstallOnHost ( dataStagedDir ) ; com.android.cts.tzdata.TzDataCheckTest.PathPair dataCurrentDir = mDataDir.createSubPath ( com.android.cts.tzdata.TzDataCheckTest.CURRENT_DIR_NAME ) ; com.android.timezone.distro.TimeZoneDistro distro = com.android.cts.tzdata.TzDataCheckTest.createValidDistroBuilder ( ) . build ( ) ; com.android.cts.tzdata.TzDataCheckTest.unpackOnHost ( dataCurrentDir , distro ) ; pushHostTestDirToDevice ( ) ; assertEquals ( 0 , runTzDataCheckOnDevice ( ) ) ; assertDevicePathDoesNotExist ( dataStagedDir ) ; assertDevicePathDoesNotExist ( dataCurrentDir ) ; }
Source:
public boolean connect ( android.bluetooth.BluetoothDevice device ) { android.util.Log.v ( android.bluetooth.BluetoothInputHost.TAG , ( "connect(): device=" + device ) ) ; boolean result = false ; if ( ( mService ) != null ) { try { result = mService.connect ( device ) ; } catch ( android.os.RemoteException e ) { android.util.Log.e ( android.bluetooth.BluetoothInputHost.TAG , e.toString ( ) ) ; } } else { android.util.Log.w ( android.bluetooth.BluetoothInputHost.TAG , "Proxy not attached to service" ) ; } return result ; }

Target:
public boolean connect ( android.bluetooth.BluetoothDevice device ) { android.util.Log.v ( android.bluetooth.BluetoothInputHost.TAG , ( "connect(): device=" + device ) ) ; boolean result = false ; final android.bluetooth.IBluetoothInputHost service = mService ; if ( service != null ) { try { result = service.connect ( device ) ; } catch ( android.os.RemoteException e ) { android.util.Log.e ( android.bluetooth.BluetoothInputHost.TAG , e.toString ( ) ) ; } } else { android.util.Log.w ( android.bluetooth.BluetoothInputHost.TAG , "Proxy not attached to service" ) ; } return result ; }
Source:
public java.lang.String getDisplayNumber ( ) { if ( ( ( mProto.virtualMajor ) != 0 ) && ( ( mProto.virtualMinor ) != 0 ) ) { return java.lang.String.format ( "%d-%d" , mProto.virtualMajor , mProto.virtualMinor ) ; } else if ( ( mProto.virtualMajor ) != 0 ) { return java.lang.Integer.toString ( mProto.virtualMajor ) ; } else { return java.lang.Integer.toString ( mProto.programNumber ) ; } }

Target:
public java.lang.String getDisplayNumber ( boolean ignoreZeroMinorNumber ) { if ( ( ( mProto.virtualMajor ) != 0 ) && ( ( ( mProto.virtualMinor ) != 0 ) || ( ! ignoreZeroMinorNumber ) ) ) { return java.lang.String.format ( "%d%c%d" , mProto.virtualMajor , com.android.tv.tuner.data.TunerChannel.CHANNEL_NUMBER_SEPARATOR , mProto.virtualMinor ) ; } else if ( ( mProto.virtualMajor ) != 0 ) { return java.lang.Integer.toString ( mProto.virtualMajor ) ; } else { return java.lang.Integer.toString ( mProto.programNumber ) ; } }
Source:
public void setVisualVoicemailEnabled ( android.telecom.PhoneAccountHandle phoneAccountHandle , boolean enabled ) { try { com.android.internal.telephony.ITelephony telephony = getITelephony ( ) ; if ( telephony != null ) { telephony.setVisualVoicemailEnabled ( mContext.getOpPackageName ( ) , phoneAccountHandle , enabled ) ; } } catch ( android.os.RemoteException ex ) { } catch ( java.lang.NullPointerException ex ) { } }

Target:
public android.telephony.UiccSlotInfo [ ] getUiccSlotsInfo ( ) { try { com.android.internal.telephony.ITelephony telephony = getITelephony ( ) ; if ( telephony == null ) { return null ; } return telephony.getUiccSlotsInfo ( ) ; } catch ( android.os.RemoteException e ) { return null ; } }
Source:
public android.net.NetworkCapabilities removeTransportType ( int transportType ) { android.net.NetworkCapabilities.checkValidTransportType ( transportType ) ; mTransportTypes &= ~ ( 1 << transportType ) ; setNetworkSpecifier ( mNetworkSpecifier ) ; return this ; }

Target:
public android.net.NetworkCapabilities removeTransportType ( int transportType ) { if ( ( transportType < ( android.net.NetworkCapabilities.MIN_TRANSPORT ) ) || ( transportType > ( android.net.NetworkCapabilities.MAX_TRANSPORT ) ) ) { throw new java.lang.IllegalArgumentException ( "TransportType out of range" ) ; } mTransportTypes &= ~ ( 1 << transportType ) ; setNetworkSpecifier ( mNetworkSpecifier ) ; return this ; }
Source:
public static com.android.jack.library.InputJackLibrary getInputLibrary ( @ javax.annotation.Nonnull com.android.sched.vfs.InputRootVDir vdir ) throws com.android.jack.library.LibraryFormatException , com.android.jack.library.LibraryVersionException , com.android.jack.library.NotJackLibraryException { java.util.Properties libraryProperties = com.android.jack.library.JackLibraryFactory.loadLibraryProperties ( vdir ) ; java.lang.String majorVersion = com.android.jack.library.JackLibraryFactory.getMajorVersionAsString ( vdir , libraryProperties ) ; com.android.jack.library.InputJackLibrary inputJackLibrary = ( ( com.android.jack.library.InputJackLibrary ) ( com.android.jack.library.JackLibraryFactory.instantiateConstructorWithParameters ( vdir , ( ( "com.android.jack.library.v" + majorVersion ) + ".InputJackLibraryImpl" ) , new java.lang.Class [ ] { com.android.sched.vfs.InputRootVDir.class , java.util.Properties.class } , new java.lang.Object [ ] { vdir , libraryProperties } , java.lang.String.valueOf ( majorVersion ) ) ) ) ; return inputJackLibrary ; }

Target:
public static com.android.jack.library.InputJackLibrary getInputLibrary ( @ javax.annotation.Nonnull com.android.sched.vfs.InputVFS vdir ) throws com.android.jack.library.LibraryFormatException , com.android.jack.library.LibraryVersionException , com.android.jack.library.NotJackLibraryException { java.util.Properties libraryProperties = com.android.jack.library.JackLibraryFactory.loadLibraryProperties ( vdir ) ; java.lang.String majorVersion = com.android.jack.library.JackLibraryFactory.getMajorVersionAsString ( vdir , libraryProperties ) ; com.android.jack.library.InputJackLibrary inputJackLibrary = ( ( com.android.jack.library.InputJackLibrary ) ( com.android.jack.library.JackLibraryFactory.instantiateConstructorWithParameters ( vdir , ( ( "com.android.jack.library.v" + majorVersion ) + ".InputJackLibraryImpl" ) , new java.lang.Class [ ] { com.android.sched.vfs.InputVFS.class , java.util.Properties.class } , new java.lang.Object [ ] { vdir , libraryProperties } , java.lang.String.valueOf ( majorVersion ) ) ) ) ; return inputJackLibrary ; }
Source:
public void testDisableWifiFromSoftApModeState ( ) throws java.lang.Exception { when ( mWifiInjector.makeWificond ( ) ) . thenReturn ( null ) ; mWifiStateMachinePrime.enterSoftAPMode ( ) ; mLooper.dispatchNext ( ) ; org.junit.Assert.assertEquals ( "SoftAPModeState" , mWifiStateMachinePrime.getCurrentMode ( ) ) ; mLooper.dispatchNext ( ) ; org.junit.Assert.assertEquals ( "SoftAPModeState" , mWifiStateMachinePrime.getCurrentMode ( ) ) ; mWifiStateMachinePrime.disableWifi ( ) ; mLooper.dispatchNext ( ) ; org.junit.Assert.assertEquals ( "WifiDisabled" , mWifiStateMachinePrime.getCurrentMode ( ) ) ; }

Target:
public void testNullConfigFailsSecondCallWithConfigSuccessful ( ) throws java.lang.Exception { when ( mWifiInjector.makeWificond ( ) ) . thenReturn ( mWificond ) ; when ( mWificond.createApInterface ( ) ) . thenReturn ( null ) ; mWifiStateMachinePrime.enterSoftAPMode ( null ) ; mLooper.dispatchAll ( ) ; org.junit.Assert.assertEquals ( com.android.server.wifi.WifiStateMachinePrimeTest.SOFT_AP_MODE_STATE_STRING , mWifiStateMachinePrime.getCurrentMode ( ) ) ; android.net.wifi.WifiConfiguration config = new android.net.wifi.WifiConfiguration ( ) ; config.SSID = "ThisIsAConfig" ; enterSoftApActiveMode ( config ) ; }
Source:
private void combineSpecifiers ( android.net.NetworkCapabilities nc ) { java.lang.String otherSpecifier = nc.getNetworkSpecifier ( ) ; if ( android.text.TextUtils.isEmpty ( otherSpecifier ) ) return ; if ( ( android.text.TextUtils.isEmpty ( mNetworkSpecifier ) ) == false ) { throw new java.lang.IllegalStateException ( "Can't combine two networkSpecifiers" ) ; } setNetworkSpecifier ( otherSpecifier ) ; }

Target:
private void combineSpecifiers ( android.net.NetworkCapabilities nc ) { if ( ( ( mNetworkSpecifier ) != null ) && ( ! ( mNetworkSpecifier.equals ( nc.mNetworkSpecifier ) ) ) ) { throw new java.lang.IllegalStateException ( "Can't combine two networkSpecifiers" ) ; } setNetworkSpecifier ( nc.mNetworkSpecifier ) ; }
Source:
public java.lang.String toString ( ) { return ( ( ( ( ( ( ( ( ( ( "transactionType: " + ( getTransactionType ( ) ) ) + " uri: " ) + ( getUri ( ) ) ) + " pushData: " ) + ( getPushData ( ) ) ) + " mmscUrl: " ) + ( getMmscUrl ( ) ) ) + " proxyAddress: " ) + ( getProxyAddress ( ) ) ) + " proxyPort: " ) + ( getProxyPort ( ) ) ; }

Target:
public java.lang.String toString ( ) { return ( ( ( ( ( ( ( ( ( ( "transactionType: " + ( getTransactionType ( ) ) ) + " uri: " ) + ( getUri ( ) ) ) + " pushData: " ) + ( com.android.internal.telephony.IccUtils.bytesToHexString ( getPushData ( ) ) ) ) + " mmscUrl: " ) + ( getMmscUrl ( ) ) ) + " proxyAddress: " ) + ( getProxyAddress ( ) ) ) + " proxyPort: " ) + ( getProxyPort ( ) ) ; }
Source:
private java.util.ArrayList < java.lang.String > split ( java.lang.String str ) { if ( str == null ) return null ; java.util.StringTokenizer tokenizer = new java.util.StringTokenizer ( str , "," ) ; java.util.ArrayList < java.lang.String > substrings = new java.util.ArrayList < java.lang.String > ( ) ; while ( tokenizer.hasMoreElements ( ) ) { substrings.add ( tokenizer.nextToken ( ) ) ; } return substrings ; }

Target:
private java.util.ArrayList < java.lang.String > split ( java.lang.String str ) { if ( str == null ) return null ; android.text.TextUtils.StringSplitter splitter = new android.text.TextUtils.SimpleStringSplitter ( ',' ) ; splitter.setString ( str ) ; java.util.ArrayList < java.lang.String > substrings = new java.util.ArrayList < java.lang.String > ( ) ; for ( java.lang.String s : splitter ) { substrings.add ( s ) ; } return substrings ; }
Source:
public com.google.common.base.Optional < java.lang.Long > getTimestampMillis ( ) { return com.google.common.base.Optional.absent ( ) ; }

Target:
public com.google.common.util.concurrent.ListenableFuture < com.google.common.collect.ImmutableMap < com.android.dialer.DialerPhoneNumber , com.android.dialer.spam.SpamStatus > > batchCheckSpamStatus ( com.google.common.collect.ImmutableSet < com.android.dialer.DialerPhoneNumber > dialerPhoneNumbers ) { return backgroundExecutorService.submit ( ( ) -> { com.google.common.collect.ImmutableMap.Builder < com.android.dialer.DialerPhoneNumber , com.android.dialer.spam.SpamStatus > resultBuilder = new com.google.common.collect.ImmutableMap.Builder < > ( ) ; for ( com.android.dialer.DialerPhoneNumber dialerPhoneNumber : dialerPhoneNumbers ) { resultBuilder.put ( dialerPhoneNumber , com.android.dialer.spam.SimpleSpamStatus.notSpam ( ) ) ; } return resultBuilder.build ( ) ; } ) ; }
Source:
public void doF32_4_relaxed ( long seed , int ulp ) { baseTestHelper ( android.renderscript.cts.RSBaseCompute.TEST_RELAXED_F32_4 , android.renderscript.Element.F32_4 ( mRS ) , android.renderscript.Element.F32_4 ( mRS ) , seed , 1 , 0 , 1 , 0 , 4 , 4 , 4 , 0 , ulp ) ; }

Target:
public void doF32_4_relaxed ( long seed , int ulp ) { baseTestHelper ( android.renderscript.cts.RSBaseCompute.TEST_RELAXED_F32_4 , android.renderscript.Element.F32_4 ( mRS ) , android.renderscript.Element.F32_4 ( mRS ) , seed , 0.0F , 1.0F , 1 , 0 , 4 , 4 , 4 , 0 , ulp ) ; }
Source:
static boolean verify ( java.security.PublicKey key , byte [ ] input , byte [ ] signature , org.bouncycastle.asn1.x509.AlgorithmIdentifier algId ) throws java.lang.Exception { java.lang.String algName = com.android.verity.Utils.ID_TO_ALG.get ( algId.getObjectId ( ) . getId ( ) ) ; if ( algName == null ) { throw new java.lang.IllegalArgumentException ( ( "Unsupported algorithm " + ( algId.getObjectId ( ) ) ) ) ; } java.security.Signature verifier = java.security.Signature.getInstance ( algName ) ; verifier.initVerify ( key ) ; verifier.update ( input ) ; return verifier.verify ( signature ) ; }

Target:
static boolean verify ( java.security.PublicKey key , byte [ ] input , byte [ ] signature , org.bouncycastle.asn1.x509.AlgorithmIdentifier algId ) throws java.lang.Exception { java.lang.String algName = com.android.verity.Utils.ID_TO_ALG.get ( algId.getAlgorithm ( ) . getId ( ) ) ; if ( algName == null ) { throw new java.lang.IllegalArgumentException ( ( "Unsupported algorithm " + ( algId.getAlgorithm ( ) ) ) ) ; } java.security.Signature verifier = java.security.Signature.getInstance ( algName ) ; verifier.initVerify ( key ) ; verifier.update ( input ) ; return verifier.verify ( signature ) ; }
Source:
public void run ( ) { try { listener.onAccountsUpdated ( accountsCopy ) ; } catch ( android.database.SQLException e ) { android.util.Log.e ( android.accounts.AccountManager.TAG , "Can't update accounts" , e ) ; } }

Target:
public void run ( ) { synchronized ( mAccountsUpdatedListeners ) { try { if ( mAccountsUpdatedListeners.containsKey ( listener ) ) { listener.onAccountsUpdated ( accountsCopy ) ; } } catch ( android.database.SQLException e ) { android.util.Log.e ( android.accounts.AccountManager.TAG , "Can't update accounts" , e ) ; } } }
Source:
protected java.lang.String lintFiles ( java.lang.String ... relativePaths ) throws java.lang.Exception { java.util.List < java.io.File > files = new java.util.ArrayList < java.io.File > ( ) ; for ( java.lang.String relativePath : relativePaths ) { java.io.File file = getTestfile ( relativePath ) ; assertNotNull ( file ) ; files.add ( file ) ; } addManifestFile ( getTargetDir ( ) ) ; return checkLint ( files ) ; }

Target:
protected java.lang.String lintFiles ( java.lang.String ... relativePaths ) throws java.lang.Exception { java.util.List < java.io.File > files = new java.util.ArrayList < java.io.File > ( ) ; java.io.File targetDir = getTargetDir ( ) ; for ( java.lang.String relativePath : relativePaths ) { java.io.File file = getTestfile ( targetDir , relativePath ) ; assertNotNull ( file ) ; files.add ( file ) ; } addManifestFile ( targetDir ) ; return checkLint ( files ) ; }
Source:
public static void doTest ( art.Test947.Transform t ) { try { java.lang.reflect.Method say_hi_method = t.getClass ( ) . getDeclaredMethod ( "sayHi" ) ; say_hi_method.invoke ( t ) ; art.Redefinition.doCommonClassRedefinition ( art.Test947.Transform.class , art.Test947.CLASS_BYTES , art.Test947.DEX_BYTES ) ; say_hi_method.invoke ( t ) ; } catch ( java.lang.Exception e ) { e.printStackTrace ( ) ; } }

Target:
public static void doTest ( art.Test947.Transform t ) { try { java.lang.reflect.Method say_hi_method = t.getClass ( ) . getDeclaredMethod ( "sayHi" ) ; say_hi_method.invoke ( t ) ; art.Redefinition.doCommonClassRedefinition ( art.Test947.Transform.class , art.Test947.CLASS_BYTES , art.Test947.DEX_BYTES ) ; say_hi_method.invoke ( t ) ; } catch ( java.lang.Exception e ) { e.printStackTrace ( java.lang.System.out ) ; } }
Source:
public boolean onPreferenceChange ( android.support.v7.preference.Preference preference , java.lang.Object newValue ) { android.content.ComponentName name = new android.content.ComponentName ( getContext ( ) , com.android.traceur.QsService.class ) ; getContext ( ) . getPackageManager ( ) . setComponentEnabledSetting ( name , ( ( ( java.lang.Boolean ) ( newValue ) ) ? android.content.pm.PackageManager.COMPONENT_ENABLED_STATE_ENABLED : android.content.pm.PackageManager.COMPONENT_ENABLED_STATE_DISABLED ) , PackageManager.DONT_KILL_APP ) ; return true ; }

Target:
public void onReceive ( android.content.Context context , android.content.Intent intent ) { refresh ( ) ; }
Source:
public static final android.os.Process.ProcessStartResult startWebView ( final java.lang.String processClass , final java.lang.String niceName , int uid , int gid , int [ ] gids , int debugFlags , int mountExternal , int targetSdkVersion , java.lang.String seInfo , java.lang.String abi , java.lang.String instructionSet , java.lang.String appDataDir , java.lang.String invokeWith , java.lang.String [ ] zygoteArgs ) { return android.webkit.WebViewZygote.getProcess ( ) . start ( processClass , niceName , uid , gid , gids , debugFlags , mountExternal , targetSdkVersion , seInfo , abi , instructionSet , appDataDir , invokeWith , zygoteArgs ) ; }

Target:
public static final android.os.Process.ProcessStartResult startWebView ( final java.lang.String processClass , final java.lang.String niceName , int uid , int gid , int [ ] gids , int runtimeFlags , int mountExternal , int targetSdkVersion , java.lang.String seInfo , java.lang.String abi , java.lang.String instructionSet , java.lang.String appDataDir , java.lang.String invokeWith , java.lang.String [ ] zygoteArgs ) { return android.webkit.WebViewZygote.getProcess ( ) . start ( processClass , niceName , uid , gid , gids , runtimeFlags , mountExternal , targetSdkVersion , seInfo , abi , instructionSet , appDataDir , invokeWith , zygoteArgs ) ; }
Source:
public com.android.dx.io.DexBuffer.Section open ( int position ) { if ( ( position < 0 ) || ( position > ( length ) ) ) { throw new java.lang.IllegalArgumentException ( ( ( ( "position=" + position ) + " length=" ) + ( length ) ) ) ; } return new com.android.dx.io.DexBuffer.Section ( position ) ; }

Target:
public com.android.dex.Dex.Section open ( int position ) { if ( ( position < 0 ) || ( position > ( length ) ) ) { throw new java.lang.IllegalArgumentException ( ( ( ( "position=" + position ) + " length=" ) + ( length ) ) ) ; } return new com.android.dex.Dex.Section ( position ) ; }
Source:
public java.util.Collection < com.android.tools.perflib.heap.Instance > getInstances ( ) { return mInstances ; }

Target:
public java.util.List < com.android.tools.perflib.heap.Instance > getInstancesList ( ) { int count = getInstanceCount ( ) ; java.util.ArrayList < com.android.tools.perflib.heap.Instance > resultList = new java.util.ArrayList < com.android.tools.perflib.heap.Instance > ( count ) ; for ( int heapId : mInstances.keys ( ) ) { resultList.addAll ( getHeapInstances ( heapId ) ) ; } return resultList ; }
Source:
protected void verifyLaunchedConversationForId ( final java.lang.String id , final com.android.messaging.ui.conversationlist.ConversationListItemView conversationView ) { final org.mockito.ArgumentMatcher < com.android.messaging.datamodel.data.ConversationListItemData > itemDataIdMatcher = new org.mockito.ArgumentMatcher < com.android.messaging.datamodel.data.ConversationListItemData > ( ) { @ java.lang.Override public boolean matches ( final java.lang.Object arg ) { return android.text.TextUtils.equals ( id , ( ( com.android.messaging.datamodel.data.ConversationListItemData ) ( arg ) ) . getConversationId ( ) ) ; } } ; org.mockito.Mockito.verify ( mockHost ) . onConversationClicked ( org.mockito.Mockito.argThat ( itemDataIdMatcher ) , org.mockito.Mockito.eq ( false ) , org.mockito.Mockito.eq ( conversationView ) ) ; }

Target:
protected void verifyLaunchedConversationForId ( final java.lang.String id , final com.android.messaging.ui.conversationlist.ConversationListItemView conversationView ) { final org.mockito.compat.ArgumentMatcher < com.android.messaging.datamodel.data.ConversationListItemData > itemDataIdMatcher = new org.mockito.compat.ArgumentMatcher < com.android.messaging.datamodel.data.ConversationListItemData > ( ) { @ java.lang.Override public boolean matchesObject ( final java.lang.Object arg ) { return android.text.TextUtils.equals ( id , ( ( com.android.messaging.datamodel.data.ConversationListItemData ) ( arg ) ) . getConversationId ( ) ) ; } } ; org.mockito.Mockito.verify ( mockHost ) . onConversationClicked ( org.mockito.Mockito.argThat ( itemDataIdMatcher ) , org.mockito.Mockito.eq ( false ) , org.mockito.Mockito.eq ( conversationView ) ) ; }
Source:
public void factoryReset ( int subId ) { enforceConnectivityInternalPermission ( ) ; if ( mUserManager.hasUserRestriction ( UserManager.DISALLOW_NETWORK_RESET ) ) { return ; } final long identity = android.os.Binder.clearCallingIdentity ( ) ; try { if ( ( android.telephony.SubscriptionManager.isUsableSubIdValue ( subId ) ) && ( ! ( mUserManager.hasUserRestriction ( UserManager.DISALLOW_CONFIG_MOBILE_NETWORKS ) ) ) ) { setDataEnabled ( subId , true ) ; setNetworkSelectionModeAutomatic ( subId ) ; setPreferredNetworkType ( subId , Phone.PREFERRED_NT_MODE ) ; mPhone.setDataRoamingEnabled ( false ) ; } } finally { android.os.Binder.restoreCallingIdentity ( identity ) ; } }

Target:
public boolean isVideoCallingEnabled ( java.lang.String callingPackage ) { if ( ! ( canReadPhoneState ( callingPackage , "isVideoCallingEnabled" ) ) ) { return false ; } com.android.ims.ImsManager imsManager = com.android.ims.ImsManager.getInstance ( mPhone.getContext ( ) , mPhone.getPhoneId ( ) ) ; return ( ( imsManager.isVtEnabledByPlatform ( ) ) && ( imsManager.isEnhanced4gLteModeSettingEnabledByUser ( ) ) ) && ( imsManager.isVtEnabledByUser ( ) ) ; }
Source:
public void internalWorked ( double work ) { }

Target:
public void createConfigFile ( ) { com.android.ide.eclipse.adt.internal.editors.layout.configuration.LayoutCreatorDialog dialog = new com.android.ide.eclipse.adt.internal.editors.layout.configuration.LayoutCreatorDialog ( mConfigChooser.getShell ( ) , mEditedFile.getName ( ) , mConfigChooser.getConfiguration ( ) . getFullConfig ( ) ) ; if ( ( dialog.open ( ) ) != ( org.eclipse.jface.window.Window.OK ) ) { return ; } com.android.ide.common.resources.configuration.FolderConfiguration config = new com.android.ide.common.resources.configuration.FolderConfiguration ( ) ; dialog.getConfiguration ( config ) ; com.android.ide.eclipse.adt.internal.editors.layout.gle2.CreateNewConfigJob job = new com.android.ide.eclipse.adt.internal.editors.layout.gle2.CreateNewConfigJob ( this , mEditedFile , config ) ; job.schedule ( ) ; }
Source:
public void writeNewStateDescription ( android.os.ParcelFileDescriptor newState ) { com.android.launcher3.backup.BackupProtos.Journal out = new com.android.launcher3.backup.BackupProtos.Journal ( ) ; out.t = 0 ; out.key = mKeys.toArray ( BackupProtos.Key.EMPTY_ARRAY ) ; writeJournal ( newState , out ) ; android.util.Log.v ( com.android.launcher3.LauncherBackupHelper.TAG , ( ( "onRestore: read " + ( mKeys.size ( ) ) ) + " rows" ) ) ; mKeys.clear ( ) ; }

Target:
public void writeNewStateDescription ( android.os.ParcelFileDescriptor newState ) { com.android.launcher3.backup.BackupProtos.Journal out = new com.android.launcher3.backup.BackupProtos.Journal ( ) ; out.t = 0 ; out.key = mKeys.toArray ( BackupProtos.Key.emptyArray ( ) ) ; writeJournal ( newState , out ) ; android.util.Log.v ( com.android.launcher3.LauncherBackupHelper.TAG , ( ( "onRestore: read " + ( mKeys.size ( ) ) ) + " rows" ) ) ; mKeys.clear ( ) ; }
Source:
public boolean remove ( java.lang.Object o ) { java.util.Iterator < java.util.Map.Entry < K , V > > iterator = unfiltered.entrySet ( ) . iterator ( ) ; while ( iterator.hasNext ( ) ) { java.util.Map.Entry < K , V > entry = iterator.next ( ) ; if ( ( com.google.common.base.Objects.equal ( o , entry.getValue ( ) ) ) && ( predicate.apply ( entry ) ) ) { iterator.remove ( ) ; return true ; } } return false ; }

Target:
public V2 getValue ( ) { return transformer.transformEntry ( entry.getKey ( ) , entry.getValue ( ) ) ; }
Source:
public void setTargetPhoneAccount ( android.telecom.PhoneAccountHandle accountHandle ) { if ( ! ( java.util.Objects.equals ( mTargetPhoneAccountHandle , accountHandle ) ) ) { mTargetPhoneAccountHandle = accountHandle ; for ( com.android.server.telecom.Call.Listener l : mListeners ) { l.onTargetPhoneAccountChanged ( this ) ; } configureIsWorkCall ( ) ; } checkIfVideoCapable ( ) ; }

Target:
public void setConnectionManagerPhoneAccount ( android.telecom.PhoneAccountHandle accountHandle ) { if ( ! ( java.util.Objects.equals ( mConnectionManagerPhoneAccountHandle , accountHandle ) ) ) { mConnectionManagerPhoneAccountHandle = accountHandle ; for ( com.android.server.telecom.Call.Listener l : mListeners ) { l.onConnectionManagerPhoneAccountChanged ( this ) ; } } checkIfRttCapable ( ) ; }
Source:
public ViewPager.OnPageChangeListener createOnPageChangeListener ( ) { return new android.support.v4.view.ViewPager.SimpleOnPageChangeListener ( ) { @ java.lang.Override public void onPageScrolled ( int position , float positionOffset , int positionOffsetPixels ) { setScrollPosition ( position , positionOffset ) ; } @ java.lang.Override public void onPageSelected ( int position ) { getTabAt ( position ) . select ( ) ; } } ; }

Target:
public void onPageScrollStateChanged ( int state ) { mScrollState = state ; }
Source:
public void onServiceDisconnected ( android.content.ComponentName componentName ) { try { com.android.server.telecom.Log.startSession ( "SBC.oSD" ) ; synchronized ( mLock ) { logServiceDisconnected ( "onServiceDisconnected" ) ; mServiceConnection = null ; clearAbort ( ) ; handleServiceDisconnected ( ) ; } } finally { com.android.server.telecom.Log.endSession ( ) ; } }

Target:
public void onServiceDisconnected ( android.content.ComponentName componentName ) { try { android.telecom.Log.startSession ( "SBC.oSD" ) ; synchronized ( mLock ) { logServiceDisconnected ( "onServiceDisconnected" ) ; mServiceConnection = null ; clearAbort ( ) ; handleServiceDisconnected ( ) ; } } finally { android.telecom.Log.endSession ( ) ; } }
Source:
public void testEvaluateNetworks_untrustedNetworksAllowed_onlyDeletedEphemeral ( ) { org.mockito.Mockito.when ( mWifiConfigManager.wasEphemeralNetworkDeleted ( com.android.server.wifi.util.ScanResultUtil.createQuotedSSID ( com.android.server.wifi.RecommendedNetworkEvaluatorTest.UNTRUSTED_SCAN_DETAIL.getScanResult ( ) . SSID ) ) ) . thenReturn ( true ) ; android.net.wifi.WifiConfiguration result = mRecommendedNetworkEvaluator.evaluateNetworks ( com.google.android.collect.Lists.newArrayList ( com.android.server.wifi.RecommendedNetworkEvaluatorTest.UNTRUSTED_SCAN_DETAIL ) , null , null , false , true , null ) ; junit.framework.Assert.assertNull ( result ) ; org.mockito.Mockito.verifyZeroInteractions ( mNetworkScoreManager ) ; }

Target:
public void testEvaluateNetworks_untrustedNetworksAllowed_onlyDeletedEphemeral ( ) { org.mockito.Mockito.when ( mWifiConfigManager.wasEphemeralNetworkDeleted ( com.android.server.wifi.util.ScanResultUtil.createQuotedSSID ( mUntrustedScanDetail.getScanResult ( ) . SSID ) ) ) . thenReturn ( true ) ; android.net.wifi.WifiConfiguration result = mRecommendedNetworkEvaluator.evaluateNetworks ( com.google.android.collect.Lists.newArrayList ( mUntrustedScanDetail ) , null , null , false , true , null ) ; junit.framework.Assert.assertNull ( result ) ; org.mockito.Mockito.verifyZeroInteractions ( mNetworkScoreManager ) ; }
Source:
public void testAesCbcHmacSha1Udp6 ( ) 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 ( 256 ) , 128 ) ; checkTransform ( android.system.OsConstants.IPPROTO_UDP , android.net.cts.IpSecManagerTest.IPV6_LOOPBACK , crypt , auth ) ; }

Target:
public void testAesCbcHmacMd5Tcp6 ( ) 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_TCP , android.net.cts.IpSecManagerTest.IPV6_LOOPBACK , crypt , auth , false , 1 , false ) ; checkTransform ( android.system.OsConstants.IPPROTO_TCP , android.net.cts.IpSecManagerTest.IPV6_LOOPBACK , crypt , auth , false , 1 , true ) ; }
Source:
private void verifyCodecConfigIntent ( int timeoutMs , android.bluetooth.BluetoothDevice device , android.bluetooth.BluetoothCodecStatus codecStatus ) { android.content.Intent intent = waitForIntent ( timeoutMs , mCodecConfigChangedQueue ) ; org.junit.Assert.assertNotNull ( intent ) ; org.junit.Assert.assertEquals ( BluetoothA2dp.ACTION_CODEC_CONFIG_CHANGED , intent.getAction ( ) ) ; org.junit.Assert.assertEquals ( device , intent.getParcelableExtra ( BluetoothDevice.EXTRA_DEVICE ) ) ; org.junit.Assert.assertEquals ( codecStatus , intent.getParcelableExtra ( BluetoothCodecStatus.EXTRA_CODEC_STATUS ) ) ; }

Target:
private void verifyNoCodecConfigIntent ( int timeoutMs ) { android.content.Intent intent = com.android.bluetooth.TestUtils.waitForNoIntent ( timeoutMs , mCodecConfigChangedQueue ) ; org.junit.Assert.assertNull ( intent ) ; }
Source:
void freeStorage ( java.lang.String volumeUuid , long freeStorageSize ) throws java.io.IOException { synchronized ( mInstallLock ) { if ( ( mInstaller.freeCache ( volumeUuid , freeStorageSize ) ) < 0 ) { throw new java.io.IOException ( "Failed to free enough space" ) ; } } }

Target:
public void run ( ) { mHandler.removeCallbacks ( this ) ; boolean success = true ; synchronized ( mInstallLock ) { try { mInstaller.freeCache ( volumeUuid , freeStorageSize ) ; } catch ( com.android.internal.os.InstallerConnection.InstallerException e ) { android.util.Slog.w ( com.android.server.pm.PackageManagerService.TAG , ( "Couldn't clear application caches: " + e ) ) ; success = false ; } } if ( observer != null ) { try { observer.onRemoveCompleted ( null , success ) ; } catch ( android.os.RemoteException e ) { android.util.Slog.w ( com.android.server.pm.PackageManagerService.TAG , "RemoveException when invoking call back" ) ; } } }
Source:
void downloadCallLog ( java.lang.String path ) { try { com.android.bluetooth.pbapclient.BluetoothPbapRequestPullPhoneBook request = new com.android.bluetooth.pbapclient.BluetoothPbapRequestPullPhoneBook ( path , mAccount , 0 , com.android.bluetooth.pbapclient.PbapClientConnectionHandler.VCARD_TYPE_21 , 0 , 0 ) ; request.execute ( mObexSession ) ; com.android.bluetooth.pbapclient.CallLogPullRequest processor = new com.android.bluetooth.pbapclient.CallLogPullRequest ( mPbapClientStateMachine.getContext ( ) , path ) ; processor.setResults ( request.getList ( ) ) ; processor.onPullComplete ( ) ; } catch ( java.io.IOException e ) { android.util.Log.w ( com.android.bluetooth.pbapclient.PbapClientConnectionHandler.TAG , "Download call log failure" ) ; } }

Target:
void downloadCallLog ( java.lang.String path ) { try { com.android.bluetooth.pbapclient.BluetoothPbapRequestPullPhoneBook request = new com.android.bluetooth.pbapclient.BluetoothPbapRequestPullPhoneBook ( path , mAccount , 0 , com.android.bluetooth.pbapclient.PbapClientConnectionHandler.VCARD_TYPE_30 , 0 , 0 ) ; request.execute ( mObexSession ) ; com.android.bluetooth.pbapclient.CallLogPullRequest processor = new com.android.bluetooth.pbapclient.CallLogPullRequest ( mPbapClientStateMachine.getContext ( ) , path ) ; processor.setResults ( request.getList ( ) ) ; processor.onPullComplete ( ) ; } catch ( java.io.IOException e ) { android.util.Log.w ( com.android.bluetooth.pbapclient.PbapClientConnectionHandler.TAG , "Download call log failure" ) ; } }
Source:
public static void prependMessageToFileContent ( @ javax.annotation.Nonnull java.io.File file , @ javax.annotation.Nonnull java.io.File out , @ javax.annotation.Nonnull java.lang.String message ) throws java.io.IOException { java.io.PrintStream fos = new java.io.PrintStream ( new java.io.FileOutputStream ( out ) ) ; java.io.FileInputStream fis = new java.io.FileInputStream ( file ) ; fos.print ( message ) ; new com.android.sched.util.stream.ByteStreamSucker ( fis , fos , true ) . suck ( ) ; }

Target:
public com.android.jack.test.toolchain.JackApiV03Toolchain build ( ) { java.io.File jackPrebuilt = ( com.android.jack.test.toolchain.AbstractTestTools.isPrebuiltAvailable ( "jack" ) ) ? com.android.jack.test.toolchain.AbstractTestTools.getPrebuilt ( "jack" ) : null ; return new com.android.jack.test.toolchain.JackApiV03Toolchain ( jackPrebuilt ) ; }
Source:
public void setUninstallBlocked ( @ android.annotation.NonNull android.content.ComponentName admin , java.lang.String packageName , boolean uninstallBlocked ) { throwIfParentInstance ( "setUninstallBlocked" ) ; if ( ( mService ) != null ) { try { mService.setUninstallBlocked ( admin , packageName , uninstallBlocked ) ; } catch ( android.os.RemoteException re ) { throw re.rethrowFromSystemServer ( ) ; } } }

Target:
public void setUninstallBlocked ( @ android.annotation.Nullable android.content.ComponentName admin , java.lang.String packageName , boolean uninstallBlocked ) { throwIfParentInstance ( "setUninstallBlocked" ) ; if ( ( mService ) != null ) { try { mService.setUninstallBlocked ( admin , mContext.getPackageName ( ) , packageName , uninstallBlocked ) ; } catch ( android.os.RemoteException re ) { throw re.rethrowFromSystemServer ( ) ; } } }
Source:
private void add ( android.icu.util.ULocale language , java.lang.Double weight ) { language = canonicalize ( language ) ; android.icu.impl.Row.R2 < android.icu.util.ULocale , java.lang.Double > row = android.icu.impl.Row.of ( addLikelySubtags ( language ) , weight ) ; maximizedLanguageToWeight.put ( language , row ) ; }

Target:
private void add ( android.icu.util.ULocale language , java.lang.Double weight ) { language = canonicalize ( language ) ; android.icu.impl.Row.R3 < android.icu.util.ULocale , android.icu.util.ULocale , java.lang.Double > row = android.icu.impl.Row.of ( language , addLikelySubtags ( language ) , weight ) ; row.freeze ( ) ; localeToMaxLocaleAndWeight.add ( row ) ; }
Source:
private android.bluetooth.BluetoothGattDescriptor getDescriptor ( ) { android.bluetooth.BluetoothGattCharacteristic characteristic = getCharacteristic ( com.android.cts.verifier.bluetooth.BleClientService.CHARACTERISTIC_UUID ) ; if ( characteristic == null ) return null ; android.bluetooth.BluetoothGattDescriptor descriptor = characteristic.getDescriptor ( com.android.cts.verifier.bluetooth.BleClientService.DESCRIPTOR_UUID ) ; if ( descriptor == null ) { showMessage ( "Descriptor not found" ) ; return null ; } return descriptor ; }

Target:
private android.bluetooth.BluetoothGattDescriptor getDescriptor ( java.util.UUID uid ) { android.bluetooth.BluetoothGattDescriptor descriptor = null ; android.bluetooth.BluetoothGattCharacteristic characteristic = getCharacteristic ( com.android.cts.verifier.bluetooth.BleClientService.CHARACTERISTIC_UUID ) ; if ( characteristic != null ) { descriptor = characteristic.getDescriptor ( uid ) ; if ( descriptor == null ) { showMessage ( "Descriptor not found" ) ; } } return descriptor ; }
Source:
public void testOneSystemOneDeleted ( ) throws java.lang.Exception { org.conscrypt.TrustedCertificateStoreTest.install ( org.conscrypt.TrustedCertificateStoreTest.getCa1 ( ) , org.conscrypt.TrustedCertificateStoreTest.getAliasSystemCa1 ( ) ) ; store.deleteCertificateEntry ( org.conscrypt.TrustedCertificateStoreTest.getAliasSystemCa1 ( ) ) ; assertEmpty ( ) ; assertDeleted ( org.conscrypt.TrustedCertificateStoreTest.getCa1 ( ) , org.conscrypt.TrustedCertificateStoreTest.getAliasSystemCa1 ( ) ) ; }

Target:
public void testTwoSystemTwoDeleted ( ) throws java.lang.Exception { install ( org.conscrypt.TrustedCertificateStoreTest.getCa1 ( ) , org.conscrypt.TrustedCertificateStoreTest.getAliasSystemCa1 ( ) ) ; store.deleteCertificateEntry ( org.conscrypt.TrustedCertificateStoreTest.getAliasSystemCa1 ( ) ) ; install ( org.conscrypt.TrustedCertificateStoreTest.getCa2 ( ) , org.conscrypt.TrustedCertificateStoreTest.getAliasSystemCa2 ( ) ) ; store.deleteCertificateEntry ( org.conscrypt.TrustedCertificateStoreTest.getAliasSystemCa2 ( ) ) ; assertEmpty ( ) ; assertDeleted ( org.conscrypt.TrustedCertificateStoreTest.getCa1 ( ) , org.conscrypt.TrustedCertificateStoreTest.getAliasSystemCa1 ( ) ) ; assertDeleted ( org.conscrypt.TrustedCertificateStoreTest.getCa2 ( ) , org.conscrypt.TrustedCertificateStoreTest.getAliasSystemCa2 ( ) ) ; }