auphong2707/dl4se-code-review-dataset huggingface dataset:
Source:
public static java.lang.String formatCompiledPattern ( java.lang.String compiledPattern , java.lang.CharSequence ... values ) { return com.ibm.icu.impl.SimplePatternFormatter.formatAndAppend ( compiledPattern , new java.lang.StringBuilder ( ) , null , values ) . toString ( ) ; }

Target:
public static java.lang.StringBuilder formatAndAppend ( java.lang.String compiledPattern , java.lang.StringBuilder appendTo , int [ ] offsets , java.lang.CharSequence ... values ) { int valuesLength = ( values != null ) ? values.length : 0 ; if ( valuesLength < ( com.ibm.icu.impl.SimpleFormatterImpl.getArgumentLimit ( compiledPattern ) ) ) { throw new java.lang.IllegalArgumentException ( "Too few values." ) ; } return com.ibm.icu.impl.SimpleFormatterImpl.format ( compiledPattern , values , appendTo , null , true , offsets ) ; }
Source:
private java.lang.ref.Reference < ? extends T > reallyPollLocked ( ) { if ( ( head ) != null ) { java.lang.ref.Reference < ? extends T > r = head ; if ( ( head ) == ( tail ) ) { tail = null ; head = null ; } else { head = head.queueNext ; } r.queueNext = null ; return r ; } return null ; }

Target:
private java.lang.ref.Reference < ? extends T > reallyPollLocked ( ) { if ( ( head ) != null ) { java.lang.ref.Reference < ? extends T > r = head ; if ( ( head ) == ( tail ) ) { tail = null ; head = null ; } else { head = head.queueNext ; } r.queueNext = java.lang.ref.ReferenceQueue.sQueueNextUnenqueued ; return r ; } return null ; }
Source:
public boolean requestFocus ( final int direction , final android.graphics.Rect previouslyFocusedRect ) { mFactory.startYourEngines ( false ) ; if ( checkNeedsPost ( ) ) { boolean ret = runOnUiThreadBlocking ( new java.util.concurrent.Callable < java.lang.Boolean > ( ) { @ java.lang.Override public java.lang.Boolean call ( ) { return requestFocus ( direction , previouslyFocusedRect ) ; } } ) ; return ret ; } mAwContents.requestFocus ( ) ; return mWebViewPrivate.super_requestFocus ( direction , previouslyFocusedRect ) ; }

Target:
public int computeHorizontalScrollRange ( ) { mFactory.startYourEngines ( false ) ; if ( checkNeedsPost ( ) ) { int ret = runOnUiThreadBlocking ( new java.util.concurrent.Callable < java.lang.Integer > ( ) { @ java.lang.Override public java.lang.Integer call ( ) { return computeHorizontalScrollRange ( ) ; } } ) ; return ret ; } return mAwContents.computeHorizontalScrollRange ( ) ; }
Source:
public void testHandleUserSwitchAfterBootupBeforeLegacyStoreMigration ( ) throws java.lang.Exception { int user2 = ( com.android.server.wifi.WifiConfigManagerTest.TEST_DEFAULT_USER ) + 1 ; when ( mUserManager.isUserUnlockingOrUnlocked ( user2 ) ) . thenReturn ( false ) ; mWifiConfigManager.handleUserSwitch ( user2 ) ; mContextConfigStoreMockOrder.verify ( mWifiConfigStore , never ( ) ) . switchUserStoreAndRead ( any ( WifiConfigStore.StoreFile.class ) ) ; mContextConfigStoreMockOrder.verify ( mWifiConfigStore , never ( ) ) . write ( anyBoolean ( ) , any ( com.android.server.wifi.WifiConfigStoreData.class ) ) ; }

Target:
public void testHandleUserUnlockAfterBootupBeforeLegacyStoreMigration ( ) throws java.lang.Exception { int user1 = com.android.server.wifi.WifiConfigManagerTest.TEST_DEFAULT_USER ; mWifiConfigManager.handleUserUnlock ( user1 ) ; mContextConfigStoreMockOrder.verify ( mWifiConfigStore , never ( ) ) . switchUserStoreAndRead ( any ( WifiConfigStore.StoreFile.class ) ) ; mContextConfigStoreMockOrder.verify ( mWifiConfigStore , never ( ) ) . write ( anyBoolean ( ) ) ; }
Source:
private static org.bouncycastle.crypto.params.DHParameters fromPG ( java.lang.String hexP , java.lang.String hexG ) { java.math.BigInteger p = new java.math.BigInteger ( 1 , org.bouncycastle.util.encoders.Hex.decode ( hexP ) ) ; java.math.BigInteger g = new java.math.BigInteger ( 1 , org.bouncycastle.util.encoders.Hex.decode ( hexG ) ) ; return new org.bouncycastle.crypto.params.DHParameters ( p , g ) ; }

Target:
private static java.math.BigInteger fromHex ( java.lang.String hex ) { return new java.math.BigInteger ( 1 , org.bouncycastle.util.encoders.Hex.decode ( hex ) ) ; }
Source:
public java.security.PrivateKey getPrivateKey ( ) throws java.security.NoSuchAlgorithmException { switch ( org.conscrypt.NativeCrypto.EVP_PKEY_type ( ctx ) ) { case NativeCrypto.EVP_PKEY_RSA : return new org.conscrypt.OpenSSLRSAPrivateKey ( this ) ; case NativeCrypto.EVP_PKEY_DSA : return new org.conscrypt.OpenSSLDSAPrivateKey ( this ) ; case NativeCrypto.EVP_PKEY_EC : return new org.conscrypt.OpenSSLECPrivateKey ( this ) ; default : throw new java.security.NoSuchAlgorithmException ( "unknown PKEY type" ) ; } }

Target:
public java.security.PrivateKey getPrivateKey ( ) throws java.security.NoSuchAlgorithmException { switch ( org.conscrypt.NativeCrypto.EVP_PKEY_type ( ctx ) ) { case NativeCrypto.EVP_PKEY_RSA : return new org.conscrypt.OpenSSLRSAPrivateKey ( this ) ; case NativeCrypto.EVP_PKEY_DH : return new org.conscrypt.OpenSSLDHPrivateKey ( this ) ; case NativeCrypto.EVP_PKEY_DSA : return new org.conscrypt.OpenSSLDSAPrivateKey ( this ) ; case NativeCrypto.EVP_PKEY_EC : return new org.conscrypt.OpenSSLECPrivateKey ( this ) ; default : throw new java.security.NoSuchAlgorithmException ( "unknown PKEY type" ) ; } }
Source:
public void coreToJayceFromJar ( ) throws java.lang.Exception { com.android.jill.Options options = new com.android.jill.Options ( ) ; options.setBinaryFile ( new java.io.File ( ( ( com.android.jack.test.TestsProperties.getAndroidRootDir ( ) . getPath ( ) ) + "/out/target/common/obj/JAVA_LIBRARIES/core-libart_intermediates/classes.jar" ) ) ) ; options.setVerbose ( true ) ; options.output = com.android.jack.test.toolchain.AbstractTestTools.createTempFile ( "jillTest" , ".zip" ) ; com.android.jill.Jill.process ( options ) ; }

Target:
public void coreToJayceFromJar ( ) throws java.lang.Exception { com.android.jill.Options options = new com.android.jill.Options ( ) ; options.setBinaryFile ( new java.io.File ( ( ( com.android.jack.test.TestsProperties.getAndroidRootDir ( ) . getPath ( ) ) + "/out/target/common/obj/JAVA_LIBRARIES/core-libart_intermediates/classes.jar" ) ) ) ; options.setVerbose ( true ) ; options.output = com.android.jack.TestTools.createTempFile ( "jillTest" , ".zip" ) ; com.android.jill.Jill.process ( options ) ; }
Source:
static java.lang.String createRequest ( java.lang.String dnsName , int dnsType , int version ) { java.lang.StringBuffer sb = new java.lang.StringBuffer ( ) ; if ( dnsType == ( android.net.wifi.p2p.nsd.WifiP2pDnsSdServiceInfo.DNS_TYPE_TXT ) ) { dnsName = dnsName.toLowerCase ( ) ; } sb.append ( android.net.wifi.p2p.nsd.WifiP2pDnsSdServiceInfo.compressDnsName ( dnsName ) ) ; sb.append ( java.lang.String.format ( "%04x" , dnsType ) ) ; sb.append ( java.lang.String.format ( "%02x" , version ) ) ; return sb.toString ( ) ; }

Target:
static java.lang.String createRequest ( java.lang.String dnsName , int dnsType , int version ) { java.lang.StringBuffer sb = new java.lang.StringBuffer ( ) ; if ( dnsType == ( android.net.wifi.p2p.nsd.WifiP2pDnsSdServiceInfo.DNS_TYPE_TXT ) ) { dnsName = dnsName.toLowerCase ( java.util.Locale.ROOT ) ; } sb.append ( android.net.wifi.p2p.nsd.WifiP2pDnsSdServiceInfo.compressDnsName ( dnsName ) ) ; sb.append ( java.lang.String.format ( "%04x" , dnsType ) ) ; sb.append ( java.lang.String.format ( "%02x" , version ) ) ; return sb.toString ( ) ; }
Source:
public void dumpMemInfo ( java.io.FileDescriptor fd , android.os.Debug.MemoryInfo mem , boolean checkin , boolean dumpFullInfo , boolean dumpDalvik , boolean dumpSummaryOnly , java.lang.String [ ] args ) { java.io.FileOutputStream fout = new java.io.FileOutputStream ( fd ) ; java.io.PrintWriter pw = new com.android.internal.util.FastPrintWriter ( fout ) ; try { dumpMemInfo ( pw , mem , checkin , dumpFullInfo , dumpDalvik , dumpSummaryOnly ) ; } finally { pw.flush ( ) ; } }

Target:
public void dumpMemInfo ( java.io.FileDescriptor fd , android.os.Debug.MemoryInfo mem , boolean checkin , boolean dumpFullInfo , boolean dumpDalvik , boolean dumpSummaryOnly , boolean dumpUnreachable , java.lang.String [ ] args ) { java.io.FileOutputStream fout = new java.io.FileOutputStream ( fd ) ; java.io.PrintWriter pw = new com.android.internal.util.FastPrintWriter ( fout ) ; try { dumpMemInfo ( pw , mem , checkin , dumpFullInfo , dumpDalvik , dumpSummaryOnly , dumpUnreachable ) ; } finally { pw.flush ( ) ; } }
Source:
public void refreshIcons ( ) { getTreeViewer ( ) . refresh ( ) ; }

Target:
public void refreshIcons ( ) { org.eclipse.jface.viewers.TreeViewer treeViewer = getTreeViewer ( ) ; if ( treeViewer != null ) { org.eclipse.swt.widgets.Tree tree = treeViewer.getTree ( ) ; if ( ( tree != null ) && ( ! ( tree.isDisposed ( ) ) ) ) { treeViewer.refresh ( ) ; } } }
Source:
public void onCreate ( android.os.Bundle savedInstanceState ) { super . onCreate ( savedInstanceState ) ; mGLView = new com.android.graphics.benchmark.example.MyGLSurfaceView ( this ) ; setContentView ( mGLView ) ; mHandler = new android.os.Handler ( ) ; mTask = new java.lang.Runnable ( ) { @ java.lang.Override public void run ( ) { broadcastIntent ( ) ; mHandler.postDelayed ( this , com.android.graphics.benchmark.example.SampleActivity.LOOP_PERIOD_MS ) ; } } ; }

Target:
public void onCreate ( android.os.Bundle savedInstanceState ) { super . onCreate ( savedInstanceState ) ; mGLView = new com.android.game.qualification.example.MyGLSurfaceView ( this ) ; setContentView ( mGLView ) ; mHandler = new android.os.Handler ( ) ; mTask = new java.lang.Runnable ( ) { @ java.lang.Override public void run ( ) { broadcastIntent ( ) ; mHandler.postDelayed ( this , com.android.game.qualification.example.SampleActivity.LOOP_PERIOD_MS ) ; } } ; }
Source:
public int fixUid ( java.lang.String name , int uid , int gid ) { java.lang.StringBuilder builder = new java.lang.StringBuilder ( "fixuid" ) ; builder.append ( ' ' ) ; builder.append ( name ) ; builder.append ( ' ' ) ; builder.append ( uid ) ; builder.append ( ' ' ) ; builder.append ( gid ) ; return mInstaller.execute ( builder.toString ( ) ) ; }

Target:
public int fixUid ( java.lang.String uuid , java.lang.String name , int uid , int gid ) { java.lang.StringBuilder builder = new java.lang.StringBuilder ( "fixuid" ) ; builder.append ( ' ' ) ; builder.append ( com.android.server.pm.Installer.escapeNull ( uuid ) ) ; builder.append ( ' ' ) ; builder.append ( name ) ; builder.append ( ' ' ) ; builder.append ( uid ) ; builder.append ( ' ' ) ; builder.append ( gid ) ; return mInstaller.execute ( builder.toString ( ) ) ; }
Source:
private void responseLastCallFailCauseInfo ( android.hardware.radio.V1_0.RadioResponseInfo responseInfo , android.hardware.radio.V1_0.LastCallFailCauseInfo fcInfo ) { com.android.internal.telephony.RILRequest rr = mRil.processResponse ( responseInfo ) ; if ( rr != null ) { com.android.internal.telephony.LastCallFailCause ret = null ; if ( ( responseInfo.error ) == ( android.hardware.radio.V1_0.RadioError.NONE ) ) { ret = new com.android.internal.telephony.LastCallFailCause ( ) ; ret.causeCode = fcInfo.causeCode ; ret.vendorCause = fcInfo.vendorCause ; sendMessageResponse ( rr.mResult , ret ) ; } mRil.processResponseDone ( rr , responseInfo , ret ) ; } }

Target:
private void responseLastCallFailCauseInfo ( android.hardware.radio.V1_0.RadioResponseInfo responseInfo , android.hardware.radio.V1_0.LastCallFailCauseInfo fcInfo ) { com.android.internal.telephony.RILRequest rr = mRil.processResponse ( responseInfo ) ; if ( rr != null ) { com.android.internal.telephony.LastCallFailCause ret = null ; if ( ( responseInfo.error ) == ( android.hardware.radio.V1_0.RadioError.NONE ) ) { ret = new com.android.internal.telephony.LastCallFailCause ( ) ; ret.causeCode = fcInfo.causeCode ; ret.vendorCause = fcInfo.vendorCause ; com.android.internal.telephony.RadioResponse.sendMessageResponse ( rr.mResult , ret ) ; } mRil.processResponseDone ( rr , responseInfo , ret ) ; } }
Source:
public boolean isRinging ( java.lang.String callingPackage ) { try { com.android.server.telecom.Log.startSession ( "TSI.iR" ) ; if ( ! ( canReadPhoneState ( callingPackage , "isRinging" ) ) ) { return false ; } synchronized ( mLock ) { return mCallsManager.hasRingingCall ( ) ; } } finally { com.android.server.telecom.Log.endSession ( ) ; } }

Target:
public boolean isRinging ( java.lang.String callingPackage ) { try { android.telecom.Log.startSession ( "TSI.iR" ) ; if ( ! ( canReadPhoneState ( callingPackage , "isRinging" ) ) ) { return false ; } synchronized ( mLock ) { return mCallsManager.hasRingingCall ( ) ; } } finally { android.telecom.Log.endSession ( ) ; } }
Source:
public void TestGetters ( ) { com.ibm.icu.text.RelativeDateTimeFormatter fmt = com.ibm.icu.text.RelativeDateTimeFormatter.getInstance ( new com.ibm.icu.util.ULocale ( "en_US" ) , null , RelativeDateTimeFormatter.Style.SHORT , DisplayContext.CAPITALIZATION_FOR_BEGINNING_OF_SENTENCE ) ; assertEquals ( "" , RelativeDateTimeFormatter.Style.SHORT , fmt.getFormatStyle ( ) ) ; assertEquals ( "" , DisplayContext.CAPITALIZATION_FOR_BEGINNING_OF_SENTENCE , fmt.getCapitalizationContext ( ) ) ; }

Target:
public void TestGetters ( ) { com.ibm.icu.text.RelativeDateTimeFormatter fmt = com.ibm.icu.text.RelativeDateTimeFormatter.getInstance ( new com.ibm.icu.util.ULocale ( "en_US" ) , null , RelativeDateTimeFormatter.Style.SHORT , DisplayContext.CAPITALIZATION_FOR_BEGINNING_OF_SENTENCE ) ; assertEquals ( "" , RelativeDateTimeFormatter.Style.SHORT , fmt.getFormatStyle ( ) ) ; assertEquals ( "" , DisplayContext.CAPITALIZATION_FOR_BEGINNING_OF_SENTENCE , fmt.getCapitalizationContext ( ) ) ; com.ibm.icu.text.RelativeDateTimeFormatter fmt_default = com.ibm.icu.text.RelativeDateTimeFormatter.getInstance ( ) ; assertEquals ( "" , RelativeDateTimeFormatter.Style.LONG , fmt_default.getFormatStyle ( ) ) ; assertEquals ( "" , DisplayContext.CAPITALIZATION_NONE , fmt_default.getCapitalizationContext ( ) ) ; }
Source:
private void setSelectedApnKey ( java.lang.String key ) { mSelectedKey = key ; android.content.ContentResolver resolver = getContentResolver ( ) ; android.content.ContentValues values = new android.content.ContentValues ( ) ; values.put ( com.android.settings.ApnSettings.APN_ID , mSelectedKey ) ; resolver.update ( com.android.settings.ApnSettings.PREFERAPN_URI , values , null , null ) ; }

Target:
private void setSelectedApnKey ( java.lang.String key ) { mSelectedKey = key ; android.content.ContentResolver resolver = getContentResolver ( ) ; android.content.ContentValues values = new android.content.ContentValues ( ) ; values.put ( com.android.settings.ApnSettings.APN_ID , mSelectedKey ) ; resolver.update ( getUriForCurrSubId ( com.android.settings.ApnSettings.PREFERAPN_URI ) , values , null , null ) ; }
Source:
public int compareTo ( util.build.BuildStep o ) { return ( inputFile ) == ( o.inputFile ) ? 0 : ( inputFile ) != null ? ( o.inputFile ) != null ? inputFile.getPath ( ) . compareTo ( o.inputFile.getPath ( ) ) : 1 : - 1 ; }

Target:
public int compareTo ( util.build.BuildStep o ) { return ( outputFile ) == ( o.outputFile ) ? 0 : outputFile.getPath ( ) . compareTo ( o.outputFile.getPath ( ) ) ; }
Source:
public void testAppInstallAndLaunch ( ) throws java.lang.Exception { android.app.Instrumentation instrumentation = testFramework.getInstrumentation ( ) ; com.android.devtools.systemimage.uitest.utils.AppManager.installApp ( instrumentation , "HelloCompute.apk" ) ; com.android.devtools.systemimage.uitest.utils.AppLauncher.launch ( instrumentation , "RsHelloCompute" ) ; com.android.devtools.systemimage.uitest.utils.AppManager.uninstallApp ( instrumentation , "RsHelloCompute" , null ) ; }

Target:
public void testAppInstallAndLaunch ( ) throws java.lang.Exception { android.app.Instrumentation instrumentation = testFramework.getInstrumentation ( ) ; com.android.devtools.systemimage.uitest.utils.AppManager.installApp ( instrumentation , "HelloCompute.apk" ) ; com.android.devtools.systemimage.uitest.utils.AppLauncher.launch ( instrumentation , "RsHelloCompute" ) ; assertTrue ( testFramework.getDevice ( ) . findObject ( new android.support.test.uiautomator.UiSelector ( ) . resourceId ( com.android.devtools.systemimage.uitest.smoke.AppTest.APP_IMAGE_VIEW_ID ) ) . exists ( ) ) ; com.android.devtools.systemimage.uitest.utils.AppManager.uninstallApp ( instrumentation , "RsHelloCompute" , null ) ; }
Source:
private static java.lang.ref.WeakReference < java.lang.ClassLoader > setUpUnloadLoader ( java.lang.reflect.Constructor constructor , boolean waitForCompilation ) throws java.lang.Exception { java.lang.ClassLoader loader = ( ( java.lang.ClassLoader ) ( constructor.newInstance ( Main.DEX_FILE , java.lang.ClassLoader.getSystemClassLoader ( ) ) ) ) ; java.lang.Class intHolder = loader.loadClass ( "IntHolder" ) ; java.lang.reflect.Method setValue = intHolder.getDeclaredMethod ( "setValue" , java.lang.Integer.TYPE ) ; setValue.invoke ( intHolder , 2 ) ; if ( waitForCompilation ) { Main.waitForCompilation ( intHolder ) ; } return new java.lang.ref.WeakReference ( loader ) ; }

Target:
private static java.lang.ref.WeakReference < java.lang.ClassLoader > setUpUnloadLoader ( java.lang.reflect.Constructor constructor , boolean waitForCompilation ) throws java.lang.Exception { java.lang.ClassLoader loader = ( ( java.lang.ClassLoader ) ( constructor.newInstance ( Main.DEX_FILE , Main.LIBRARY_SEARCH_PATH , java.lang.ClassLoader.getSystemClassLoader ( ) ) ) ) ; java.lang.Class intHolder = loader.loadClass ( "IntHolder" ) ; java.lang.reflect.Method setValue = intHolder.getDeclaredMethod ( "setValue" , java.lang.Integer.TYPE ) ; setValue.invoke ( intHolder , 2 ) ; if ( waitForCompilation ) { Main.waitForCompilation ( intHolder ) ; } return new java.lang.ref.WeakReference ( loader ) ; }
Source:
public boolean addGpsStatusListener ( android.location.IGpsStatusListener listener ) { if ( ( mGpsLocationProvider ) == null ) { return false ; } try { mGpsLocationProvider.addGpsStatusListener ( listener ) ; } catch ( android.os.RemoteException e ) { android.util.Log.w ( com.android.server.LocationManagerService.TAG , "RemoteException in addGpsStatusListener" ) ; return false ; } return true ; }

Target:
public boolean addGpsStatusListener ( android.location.IGpsStatusListener listener ) { if ( ( mGpsLocationProvider ) == null ) { return false ; } if ( ( mContext.checkCallingPermission ( com.android.server.LocationManagerService.ACCESS_FINE_LOCATION ) ) != ( android.content.pm.PackageManager.PERMISSION_GRANTED ) ) { throw new java.lang.SecurityException ( "Requires ACCESS_FINE_LOCATION permission" ) ; } try { mGpsLocationProvider.addGpsStatusListener ( listener ) ; } catch ( android.os.RemoteException e ) { android.util.Log.w ( com.android.server.LocationManagerService.TAG , "RemoteException in addGpsStatusListener" ) ; return false ; } return true ; }
Source:
public void testDstZoneWithNonDstTimestampForNonHourDstZone ( ) throws java.lang.Exception { java.text.SimpleDateFormat format = new java.text.SimpleDateFormat ( "yyyy-MM-dd'T'HH:mm zzzz" ) ; java.util.Calendar calendar = new java.util.GregorianCalendar ( libcore.java.text.SimpleDateFormatTest.AUSTRALIA_LORD_HOWE ) ; calendar.setTime ( format.parse ( "2011-06-21T20:00 Lord Howe Daylight Time" ) ) ; assertEquals ( 19 , calendar.get ( java.util.Calendar.HOUR_OF_DAY ) ) ; assertEquals ( 30 , calendar.get ( java.util.Calendar.MINUTE ) ) ; }

Target:
public void testDstZoneWithNonDstTimestampForNonHourDstZone ( ) throws java.lang.Exception { java.text.SimpleDateFormat format = new java.text.SimpleDateFormat ( "yyyy-MM-dd'T'HH:mm zzzz" , java.util.Locale.US ) ; java.util.Calendar calendar = new java.util.GregorianCalendar ( libcore.java.text.SimpleDateFormatTest.AUSTRALIA_LORD_HOWE ) ; calendar.setTime ( format.parse ( "2011-06-21T20:00 Lord Howe Daylight Time" ) ) ; assertEquals ( 19 , calendar.get ( java.util.Calendar.HOUR_OF_DAY ) ) ; assertEquals ( 30 , calendar.get ( java.util.Calendar.MINUTE ) ) ; }
Source:
public void handleMessage ( android.os.Message msg ) { switch ( msg.what ) { case com.android.bluetooth.btservice.RemoteDevices.MESSAGE_UUID_INTENT : android.bluetooth.BluetoothDevice device = ( ( android.bluetooth.BluetoothDevice ) ( msg.obj ) ) ; if ( device != null ) { sendUuidIntent ( device ) ; } break ; } }

Target:
public void onReceive ( android.content.Context context , android.content.Intent intent ) { android.util.Log.d ( com.android.bluetooth.btservice.RemoteDevices.TAG , ( "Received intent: " + intent ) ) ; java.lang.String action = intent.getAction ( ) ; switch ( action ) { case android.bluetooth.BluetoothHeadset.ACTION_HF_INDICATORS_VALUE_CHANGED : onHfIndicatorValueChanged ( intent ) ; break ; default : android.util.Log.w ( com.android.bluetooth.btservice.RemoteDevices.TAG , ( "Unhandled intent: " + intent ) ) ; break ; } }
Source:
private void initializeMediaPlayerButtonsAndViews ( ) { playButton = findViewById ( R.id.playButton ) ; pauseButton = findViewById ( R.id.pauseButton ) ; currentSeekBarPosition = findViewById ( R.id.playback_position_text ) ; seekBarView = findViewById ( R.id.playback_seek ) ; speakerButton = findViewById ( R.id.speakerButton ) ; phoneButton = findViewById ( R.id.phoneButton ) ; deleteButton = findViewById ( R.id.deleteButton ) ; totalDurationView = findViewById ( R.id.playback_seek_total_duration ) ; }

Target:
private void initializeMediaPlayerButtonsAndViews ( ) { playButton = findViewById ( R.id.playButton ) ; pauseButton = findViewById ( R.id.pauseButton ) ; currentSeekBarPosition = findViewById ( R.id.playback_position_text ) ; seekBarView = findViewById ( R.id.playback_seek ) ; speakerButton = findViewById ( R.id.speakerButton ) ; phoneButton = findViewById ( R.id.phoneButton ) ; deleteButton = findViewById ( R.id.deleteButton ) ; totalDurationView = findViewById ( R.id.playback_seek_total_duration ) ; voicemailLoadingStatusView = findViewById ( R.id.playback_state_text ) ; }
Source:
private static void addModuleToListFromSingleTest ( java.util.List < com.android.tradefed.testtype.suite.ModuleDefinition > currentList , com.android.tradefed.testtype.IRemoteTest test , java.lang.String moduleName , com.android.tradefed.config.IConfiguration config ) { java.util.List < com.android.tradefed.testtype.IRemoteTest > testList = new java.util.ArrayList < > ( ) ; testList.add ( test ) ; com.android.tradefed.testtype.suite.ModuleDefinition module = new com.android.tradefed.testtype.suite.ModuleDefinition ( moduleName , testList , com.android.tradefed.testtype.suite.ModuleSplitter.clonePreparers ( config ) ) ; currentList.add ( module ) ; }

Target:
private static void addModuleToListFromSingleTest ( java.util.List < com.android.tradefed.testtype.suite.ModuleDefinition > currentList , com.android.tradefed.testtype.IRemoteTest test , java.lang.String moduleName , com.android.tradefed.config.IConfiguration config ) { java.util.List < com.android.tradefed.testtype.IRemoteTest > testList = new java.util.ArrayList < > ( ) ; testList.add ( test ) ; com.android.tradefed.testtype.suite.ModuleDefinition module = new com.android.tradefed.testtype.suite.ModuleDefinition ( moduleName , testList , com.android.tradefed.testtype.suite.ModuleSplitter.clonePreparers ( config ) , config.getConfigurationDescription ( ) ) ; currentList.add ( module ) ; }
Source:
private static com.android.dialer.historyitemactions.HistoryItemActionModule createModuleForBlockingNumberAndOptionallyReportingSpam ( android.content.Context context , java.lang.String normalizedNumber , java.lang.String countryIso , int callType , com.android.dialer.logging.ReportingLocation.Type reportingLocation ) { return new com.android.dialer.historyitemactions.HistoryItemActionModule ( ) { @ java.lang.Override public int getStringId ( ) { return R.string.block_and_optionally_report_spam ; } @ java.lang.Override public int getDrawableId ( ) { return R.drawable.quantum_ic_block_vd_theme_24 ; } @ java.lang.Override public boolean onClick ( ) { com.android.dialer.blockreportspam.ShowBlockReportSpamDialogNotifier.notifyShowDialogToBlockNumberAndOptionallyReportSpam ( context , normalizedNumber , countryIso , callType , reportingLocation ) ; return true ; } } ; }

Target:
private static com.android.dialer.historyitemactions.HistoryItemActionModule createModuleForBlockingNumberAndOptionallyReportingSpam ( android.content.Context context , com.android.dialer.blockreportspam.BlockReportSpamDialogInfo blockReportSpamDialogInfo ) { return new com.android.dialer.historyitemactions.HistoryItemActionModule ( ) { @ java.lang.Override public int getStringId ( ) { return R.string.block_and_optionally_report_spam ; } @ java.lang.Override public int getDrawableId ( ) { return R.drawable.quantum_ic_block_vd_theme_24 ; } @ java.lang.Override public boolean onClick ( ) { com.android.dialer.blockreportspam.ShowBlockReportSpamDialogNotifier.notifyShowDialogToBlockNumberAndOptionallyReportSpam ( context , blockReportSpamDialogInfo ) ; return true ; } } ; }
Source:
private java.lang.String format ( long number , com.ibm.icu.text.NFRuleSet ruleSet ) { java.lang.StringBuffer result = new java.lang.StringBuffer ( ) ; ruleSet.format ( number , result , 0 , 0 ) ; postProcess ( result , ruleSet ) ; return result.toString ( ) ; }

Target:
private java.lang.String format ( long number , com.ibm.icu.text.NFRuleSet ruleSet ) { java.lang.StringBuilder result = new java.lang.StringBuilder ( ) ; if ( number == ( java.lang.Long.MIN_VALUE ) ) { result.append ( getDecimalFormat ( ) . format ( java.lang.Long.MIN_VALUE ) ) ; } else { ruleSet.format ( number , result , 0 , 0 ) ; } postProcess ( result , ruleSet ) ; return result.toString ( ) ; }
Source:
public android.bluetooth.BluetoothDevice getClient ( ) { if ( com.android.bluetooth.pbap.BluetoothPbapService.DEBUG ) android.util.Log.d ( com.android.bluetooth.pbap.BluetoothPbapService.TAG , ( "getClient" + ( mRemoteDevice ) ) ) ; if ( ! ( com.android.bluetooth.Utils.checkCaller ( ) ) ) { android.util.Log.w ( com.android.bluetooth.pbap.BluetoothPbapService.TAG , "getClient(): not allowed for non-active user" ) ; return null ; } enforceCallingOrSelfPermission ( com.android.bluetooth.pbap.BluetoothPbapService.BLUETOOTH_PERM , "Need BLUETOOTH permission" ) ; if ( ( mState ) == ( android.bluetooth.BluetoothPbap.STATE_DISCONNECTED ) ) { return null ; } return mRemoteDevice ; }

Target:
public android.bluetooth.BluetoothDevice getClient ( ) { if ( com.android.bluetooth.pbap.BluetoothPbapService.DEBUG ) android.util.Log.d ( com.android.bluetooth.pbap.BluetoothPbapService.TAG , ( "getClient = " + ( mService.getRemoteDevice ( ) ) ) ) ; com.android.bluetooth.pbap.BluetoothPbapService service = getService ( com.android.bluetooth.pbap.BluetoothPbapService.BLUETOOTH_PERM ) ; if ( service == null ) return null ; return service.getRemoteDevice ( ) ; }
Source:
public void onImsResumed ( ) { if ( com.android.internal.telephony.imsphone.ImsPhoneCallTracker.DBG ) log ( "onImsResumed" ) ; mPhone.setServiceState ( ServiceState.STATE_IN_SERVICE ) ; mMetrics.writeOnImsConnectionState ( mPhone.getPhoneId ( ) , ImsConnectionState.State.RESUMED , null ) ; }

Target:
public void onDeregistered ( android.telephony.ims.ImsReasonInfo imsReasonInfo ) { if ( com.android.internal.telephony.imsphone.ImsPhoneCallTracker.DBG ) log ( ( "onImsDisconnected imsReasonInfo=" + imsReasonInfo ) ) ; resetImsCapabilities ( ) ; mPhone.setServiceState ( ServiceState.STATE_OUT_OF_SERVICE ) ; mPhone.setImsRegistered ( false ) ; mPhone.processDisconnectReason ( imsReasonInfo ) ; mMetrics.writeOnImsConnectionState ( mPhone.getPhoneId ( ) , ImsConnectionState.State.DISCONNECTED , imsReasonInfo ) ; }
Source:
public java.lang.String getPath ( ) { java.lang.String path = mPath ; if ( ( ( mVendor ) != null ) && ( ( mVendor.length ( ) ) > 0 ) ) { path = ( ( mVendor ) + "-" ) + ( mPath ) ; } int h = path.hashCode ( ) ; path = path.replaceAll ( "[^a-zA-Z0-9-]+" , "_" ) ; if ( ( path.length ( ) ) == 0 ) { path = java.lang.String.format ( "unknown_extra%08x" , h ) ; } return path ; }

Target:
public java.lang.String getVendor ( ) { if ( ( ( mVendor ) != null ) && ( ( mVendor.length ( ) ) > 0 ) ) { java.lang.String vendor = mVendor ; vendor = vendor.replaceAll ( "[^a-zA-Z0-9-]+" , "_" ) ; if ( vendor.equals ( "_" ) ) { int h = vendor.hashCode ( ) ; vendor = java.lang.String.format ( "vendor%08x" , h ) ; } return vendor ; } return "" ; }
Source:
public void startRanging ( android.net.wifi.RttManager [ ] params , android.net.wifi.RttManager.RttListener listener ) { if ( mTerminated ) { android.util.Log.w ( android.net.wifi.nan.WifiNanSession.TAG , "startRanging: called on terminated session" ) ; return ; } else { android.net.wifi.nan.WifiNanManager mgr = mMgr.get ( ) ; if ( mgr == null ) { android.util.Log.w ( android.net.wifi.nan.WifiNanSession.TAG , "startRanging: called post GC on WifiNanManager" ) ; return ; } mgr.startRanging ( mSessionId , params , listener ) ; } }

Target:
public void startRanging ( android.net.wifi.RttManager [ ] params , android.net.wifi.RttManager.RttListener listener ) { if ( mTerminated ) { android.util.Log.w ( android.net.wifi.nan.WifiNanDiscoveryBaseSession.TAG , "startRanging: called on terminated session" ) ; return ; } else { android.net.wifi.nan.WifiNanManager mgr = mMgr.get ( ) ; if ( mgr == null ) { android.util.Log.w ( android.net.wifi.nan.WifiNanDiscoveryBaseSession.TAG , "startRanging: called post GC on WifiNanManager" ) ; return ; } mgr.startRanging ( mSessionId , params , listener ) ; } }
Source:
private void stopRtt ( java.lang.String callId ) { android.telecom.Log.d ( this , "stopRtt(%s)" , callId ) ; if ( mConnectionById.containsKey ( callId ) ) { findConnectionForAction ( callId , "stopRtt" ) . onStopRtt ( ) ; findConnectionForAction ( callId , "stopRtt" ) . unsetRttProperty ( ) ; } else if ( mConferenceById.containsKey ( callId ) ) { android.telecom.Log.w ( this , "stopRtt called on a conference." ) ; } }

Target:
private void deflect ( java.lang.String callId , android.net.Uri address ) { android.telecom.Log.d ( this , "deflect %s" , callId ) ; findConnectionForAction ( callId , "deflect" ) . onDeflect ( address ) ; }
Source:
public boolean matchesObject ( java.lang.Object obj ) { android.hardware.camera2.TotalCaptureResult result = ( ( android.hardware.camera2.TotalCaptureResult ) ( obj ) ) ; java.lang.Long timeStamp = result.get ( CaptureResult.SENSOR_TIMESTAMP ) ; if ( ( timeStamp != null ) && ( ( timeStamp.longValue ( ) ) > 0L ) ) { return true ; } return false ; }

Target:
public boolean matches ( android.hardware.camera2.TotalCaptureResult obj ) { android.hardware.camera2.TotalCaptureResult result = obj ; java.lang.Long timeStamp = result.get ( CaptureResult.SENSOR_TIMESTAMP ) ; if ( ( timeStamp != null ) && ( ( timeStamp.longValue ( ) ) > 0L ) ) { return true ; } return false ; }
Source:
public void writeToParcel ( android.os.Parcel out , int flags ) { out.writeString ( profileFile ) ; if ( ( profileFd ) != null ) { out.writeInt ( 1 ) ; profileFd.writeToParcel ( out , flags ) ; } else { out.writeInt ( 0 ) ; } out.writeInt ( samplingInterval ) ; out.writeInt ( ( autoStopProfiler ? 1 : 0 ) ) ; }

Target:
public void writeToParcel ( android.os.Parcel out , int flags ) { out.writeString ( profileFile ) ; if ( ( profileFd ) != null ) { out.writeInt ( 1 ) ; profileFd.writeToParcel ( out , flags ) ; } else { out.writeInt ( 0 ) ; } out.writeInt ( samplingInterval ) ; out.writeInt ( ( autoStopProfiler ? 1 : 0 ) ) ; out.writeInt ( ( streamingOutput ? 1 : 0 ) ) ; }
Source:
private void handleShareItemSelected ( ) { android.content.Intent target = new android.content.Intent ( android.content.Intent.ACTION_SEND ) ; target.setType ( "text/plain" ) ; com.android.cts.verifier.TestResultsReport report = new com.android.cts.verifier.TestResultsReport ( this , getListAdapter ( ) ) ; target.putExtra ( Intent.EXTRA_SUBJECT , report.getSubject ( ) ) ; target.putExtra ( Intent.EXTRA_TEXT , report.getBody ( ) ) ; startActivity ( android.content.Intent.createChooser ( target , getString ( R.string.share_test_results ) ) ) ; }

Target:
private void handleCopyItemSelected ( ) { com.android.cts.verifier.TestResultsReport report = new com.android.cts.verifier.TestResultsReport ( this , mAdapter ) ; android.text.ClipboardManager clipboardManager = ( ( android.text.ClipboardManager ) ( getSystemService ( com.android.cts.verifier.CLIPBOARD_SERVICE ) ) ) ; clipboardManager.setText ( report.getBody ( ) ) ; android.widget.Toast.makeText ( this , R.string.test_results_copied , Toast.LENGTH_SHORT ) . show ( ) ; }
Source:
public void testAesCbcHmacSha512Udp4 ( ) throws java.lang.Exception { android.net.IpSecAlgorithm crypt = new android.net.IpSecAlgorithm ( android.net.IpSecAlgorithm.CRYPT_AES_CBC , android.net.cts.IpSecManagerTest.getKey ( 256 ) ) ; android.net.IpSecAlgorithm auth = new android.net.IpSecAlgorithm ( android.net.IpSecAlgorithm.AUTH_HMAC_SHA512 , android.net.cts.IpSecManagerTest.getKey ( 512 ) , 256 ) ; checkTransform ( android.system.OsConstants.IPPROTO_UDP , android.net.cts.IpSecManagerTest.IPV4_LOOPBACK , crypt , auth , null , false , 1 , false ) ; checkTransform ( android.system.OsConstants.IPPROTO_UDP , android.net.cts.IpSecManagerTest.IPV4_LOOPBACK , crypt , auth , null , false , 1 , true ) ; }

Target:
public void testAesCbcHmacSha512Udp6 ( ) 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_SHA512 , getAuthKey ( 512 ) , 256 ) ; checkTransform ( android.system.OsConstants.IPPROTO_UDP , android.net.cts.IpSecManagerTest.IPV6_LOOPBACK , crypt , auth , false , 1 , false ) ; checkTransform ( android.system.OsConstants.IPPROTO_UDP , android.net.cts.IpSecManagerTest.IPV6_LOOPBACK , crypt , auth , false , 1 , true ) ; }
Source:
public static double nextUp ( double d ) { return sun.misc.FpUtils.nextUp ( d ) ; }

Target:
public static double nextUp ( double d ) { if ( ( java.lang.Double.isNaN ( d ) ) || ( d == ( java.lang.Double.POSITIVE_INFINITY ) ) ) return d ; else { d += 0.0 ; return java.lang.Double.longBitsToDouble ( ( ( java.lang.Double.doubleToRawLongBits ( d ) ) + ( d >= 0.0 ? + 1L : - 1L ) ) ) ; } }
Source:
public void canUnrequestTethering ( ) throws java.lang.Exception { initTetheredStateMachine ( android.net.ConnectivityManager.TETHERING_BLUETOOTH , null ) ; dispatchCommand ( TetherInterfaceStateMachine.CMD_TETHER_UNREQUESTED ) ; org.mockito.InOrder inOrder = org.mockito.Mockito.inOrder ( mNMService , mStatsService , mTetherHelper ) ; inOrder.verify ( mNMService ) . untetherInterface ( com.android.server.connectivity.tethering.TetherInterfaceStateMachineTest.IFACE_NAME ) ; inOrder.verify ( mTetherHelper ) . notifyInterfaceStateChange ( com.android.server.connectivity.tethering.TetherInterfaceStateMachineTest.IFACE_NAME , mTestedSm , com.android.server.connectivity.tethering.IControlsTethering.STATE_AVAILABLE , android.net.ConnectivityManager.TETHER_ERROR_NO_ERROR ) ; org.mockito.Mockito.verifyNoMoreInteractions ( mNMService , mStatsService , mTetherHelper ) ; }

Target:
public void canBeTethered ( ) throws java.lang.Exception { initStateMachine ( android.net.ConnectivityManager.TETHERING_BLUETOOTH ) ; dispatchCommand ( TetherInterfaceStateMachine.CMD_TETHER_REQUESTED , com.android.server.connectivity.tethering.IControlsTethering.STATE_TETHERED ) ; org.mockito.InOrder inOrder = org.mockito.Mockito.inOrder ( mTetherHelper , mNMService ) ; inOrder.verify ( mNMService ) . tetherInterface ( com.android.server.connectivity.tethering.TetherInterfaceStateMachineTest.IFACE_NAME ) ; inOrder.verify ( mTetherHelper ) . updateInterfaceState ( mTestedSm , com.android.server.connectivity.tethering.IControlsTethering.STATE_TETHERED , android.net.ConnectivityManager.TETHER_ERROR_NO_ERROR ) ; inOrder.verify ( mTetherHelper ) . updateLinkProperties ( org.mockito.Matchers.eq ( mTestedSm ) , org.mockito.Matchers.any ( android.net.LinkProperties.class ) ) ; org.mockito.Mockito.verifyNoMoreInteractions ( mNMService , mStatsService , mTetherHelper ) ; }
Source:
public void setUp ( ) throws java.lang.Exception { super . setUp ( ) ; mTestImsServiceController = new com.android.internal.telephony.ims.ImsServiceController ( mMockContext , mTestComponentName , mMockCallbacks , mHandler , com.android.internal.telephony.ims.ImsServiceControllerTest.REBIND_RETRY ) ; mTestImsServiceController.addImsServiceFeatureListener ( mMockProxyCallbacks ) ; org.mockito.Mockito.when ( mMockContext.bindService ( org.mockito.Matchers.any ( ) , org.mockito.Matchers.any ( ) , org.mockito.Matchers.anyInt ( ) ) ) . thenReturn ( true ) ; }

Target:
public void setUp ( ) throws java.lang.Exception { super . setUp ( ) ; mTestImsServiceController = new com.android.internal.telephony.ims.ImsServiceController ( mMockContext , mTestComponentName , mMockCallbacks , mHandler , com.android.internal.telephony.ims.ImsServiceControllerTest.REBIND_RETRY ) ; mTestImsServiceController.addImsServiceFeatureCallback ( mMockProxyCallbacks ) ; org.mockito.Mockito.when ( mMockContext.bindService ( org.mockito.Matchers.any ( ) , org.mockito.Matchers.any ( ) , org.mockito.Matchers.anyInt ( ) ) ) . thenReturn ( true ) ; }
Source:
public int getCLIRMode ( ) { if ( ( ( mSc ) != null ) && ( mSc.equals ( com.android.internal.telephony.gsm.GsmMmiCode.SC_CLIR ) ) ) { if ( isActivate ( ) ) { return com.android.internal.telephony.CommandsInterface.CommandsInterface.CLIR_SUPPRESSION ; } else if ( isDeactivate ( ) ) { return com.android.internal.telephony.CommandsInterface.CommandsInterface.CLIR_INVOCATION ; } } return com.android.internal.telephony.CommandsInterface.CommandsInterface.CLIR_DEFAULT ; }

Target:
public int getCLIRMode ( ) { if ( ( ( mSc ) != null ) && ( mSc.equals ( com.android.internal.telephony.gsm.GsmMmiCode.SC_CLIR ) ) ) { if ( isActivate ( ) ) { return com.android.internal.telephony.CommandsInterface.CLIR_SUPPRESSION ; } else if ( isDeactivate ( ) ) { return com.android.internal.telephony.CommandsInterface.CLIR_INVOCATION ; } } return com.android.internal.telephony.CommandsInterface.CLIR_DEFAULT ; }
Source:
public void adjustStreamVolume ( int streamType , int direction , int flags ) { android.media.IAudioService service = android.media.AudioManager.getService ( ) ; try { if ( mUseMasterVolume ) { service.adjustMasterVolume ( direction , flags , mApplicationContext.getOpPackageName ( ) ) ; } else { service.adjustStreamVolume ( streamType , direction , flags , mApplicationContext.getOpPackageName ( ) ) ; } } catch ( android.os.RemoteException e ) { android.util.Log.e ( android.media.AudioManager.TAG , "Dead object in adjustStreamVolume" , e ) ; } }

Target:
public void adjustStreamVolume ( int streamType , int direction , int flags ) { android.media.IAudioService service = android.media.AudioManager.getService ( ) ; try { if ( mUseMasterVolume ) { service.adjustMasterVolume ( direction , flags , getContext ( ) . getOpPackageName ( ) ) ; } else { service.adjustStreamVolume ( streamType , direction , flags , getContext ( ) . getOpPackageName ( ) ) ; } } catch ( android.os.RemoteException e ) { android.util.Log.e ( android.media.AudioManager.TAG , "Dead object in adjustStreamVolume" , e ) ; } }
Source:
public final char getChar ( int index ) { checkIndex ( index , SizeOf.CHAR ) ; return ( ( char ) ( this . block.peekShort ( ( ( offset ) + index ) , order ) ) ) ; }

Target:
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 ; }
Source:
public void onStateChanged ( @ android.support.annotation.NonNull android.view.View bottomSheet , int newState ) { if ( newState == ( android.support.design.widget.BottomSheetBehavior.STATE_HIDDEN ) ) { cancel ( ) ; return ; } if ( ( background.getHeight ( ) ) == ( bottomSheet.getHeight ( ) ) ) { contactView.setElevation ( ( newState == ( android.support.design.widget.BottomSheetBehavior.STATE_EXPANDED ) ? getContext ( ) . getResources ( ) . getDimensionPixelSize ( R.dimen.contact_actions_header_elevation ) : 0 ) ) ; } }

Target:
public void onStateChanged ( @ android.support.annotation.NonNull android.view.View bottomSheet , int newState ) { if ( newState == ( android.support.design.bottomsheet.BottomSheetBehavior.STATE_HIDDEN ) ) { cancel ( ) ; return ; } if ( ( background.getHeight ( ) ) == ( bottomSheet.getHeight ( ) ) ) { contactView.setElevation ( ( newState == ( android.support.design.bottomsheet.BottomSheetBehavior.STATE_EXPANDED ) ? getContext ( ) . getResources ( ) . getDimensionPixelSize ( R.dimen.contact_actions_header_elevation ) : 0 ) ) ; } }
Source:
public com.android.build.gradle.internal.dsl.NdkConfigDsl setSrcDirs ( java.lang.Iterable < java.lang.String > filters ) { if ( filters != null ) { if ( ( abiFilters ) == null ) { abiFilters = com.google.common.collect.Sets.newHashSetWithExpectedSize ( 2 ) ; } else { abiFilters.clear ( ) ; } for ( java.lang.String filter : filters ) { abiFilters.add ( filter ) ; } } else { abiFilters = null ; } return this ; }

Target:
public com.android.build.gradle.internal.dsl.NdkConfigDsl setLdLibs ( java.util.Collection < java.lang.String > libs ) { if ( libs != null ) { if ( ( abiFilters ) == null ) { abiFilters = com.google.common.collect.Sets.newHashSetWithExpectedSize ( libs.size ( ) ) ; } else { abiFilters.clear ( ) ; } for ( java.lang.String filter : libs ) { abiFilters.add ( filter ) ; } } else { abiFilters = null ; } return this ; }
Source:
public void setWFDInfo ( android.net.wifi.p2p.WifiP2pManager.Channel c , android.net.wifi.p2p.WifiP2pWfdInfo wfdInfo , android.net.wifi.p2p.WifiP2pManager.ActionListener listener ) { android.net.wifi.p2p.WifiP2pManager.checkChannel ( c ) ; c.mAsyncChannel.sendMessage ( android.net.wifi.p2p.WifiP2pManager.SET_WFD_INFO , 0 , c.putListener ( listener ) , wfdInfo ) ; }

Target:
public void setWFDInfo ( android.net.wifi.p2p.WifiP2pManager.Channel c , android.net.wifi.p2p.WifiP2pWfdInfo wfdInfo , android.net.wifi.p2p.WifiP2pManager.ActionListener listener ) { android.net.wifi.p2p.WifiP2pManager.checkChannel ( c ) ; try { mService.checkConfigureWifiDisplayPermission ( ) ; } catch ( android.os.RemoteException e ) { e.rethrowFromSystemServer ( ) ; } c.mAsyncChannel.sendMessage ( android.net.wifi.p2p.WifiP2pManager.SET_WFD_INFO , 0 , c.putListener ( listener ) , wfdInfo ) ; }
Source:
private static java.util.List < java.lang.Integer > buildList ( int arrayListLength , boolean useArrayList ) { java.util.Random random = new java.util.Random ( ) ; random.setSeed ( 0 ) ; java.util.List < java.lang.Integer > list = ( useArrayList ) ? new java.util.ArrayList < java.lang.Integer > ( arrayListLength ) : new java.util.Vector < java.lang.Integer > ( arrayListLength ) ; for ( int i = 0 ; i < arrayListLength ; ++ i ) { list.add ( random.nextInt ( ) ) ; } return list ; }

Target:
private static < T extends java.util.List < java.lang.Integer > > java.util.List < java.lang.Integer > buildList ( int arrayListLength , java.lang.Class < T > listClass ) throws java.lang.Exception { java.util.Random random = new java.util.Random ( ) ; random.setSeed ( 0 ) ; java.util.List < java.lang.Integer > list = listClass.newInstance ( ) ; for ( int i = 0 ; i < arrayListLength ; ++ i ) { list.add ( random.nextInt ( ) ) ; } return list ; }
Source:
private static boolean isLocaleReference ( @ com.android.annotations.Nullable java.lang.String typeName ) { return ( typeName != null ) && ( ( typeName.equals ( "Locale" ) ) || ( typeName.equals ( "java.util.Locale" ) ) ) ; }

Target:
private static boolean isCharacterType ( com.intellij.psi.PsiType type ) { if ( type == ( com.intellij.psi.PsiType.CHAR ) ) { return true ; } if ( type instanceof com.intellij.psi.PsiClassType ) { java.lang.String fqn = type.getCanonicalText ( ) ; return com.android.tools.lint.client.api.JavaParser.TYPE_CHARACTER_WRAPPER.equals ( fqn ) ; } return false ; }
Source:
public static < E > java.util.HashSet < E > newHashSet ( java.util.Iterator < ? extends E > elements ) { java.util.HashSet < E > set = com.google.common.collect.Sets.newHashSet ( ) ; while ( elements.hasNext ( ) ) { set.add ( elements.next ( ) ) ; } return set ; }

Target:
public static < E > java.util.HashSet < E > newHashSet ( java.util.Iterator < ? extends E > elements ) { java.util.HashSet < E > set = com.google.common.collect.Sets.newHashSet ( ) ; com.google.common.collect.Iterators.addAll ( set , elements ) ; return set ; }
Source:
public org.intellij.plugins.intelliLang.inject.groovy.Result < java.util.List < org.intellij.plugins.intelliLang.inject.groovy.PsiElement > > compute ( ) { return new org.intellij.plugins.intelliLang.inject.groovy.Result < java.util.List < org.intellij.plugins.intelliLang.inject.groovy.PsiElement > > ( java.util.Collections.< org.intellij.plugins.intelliLang.inject.groovy.PsiElement > singletonList ( org.intellij.plugins.intelliLang.inject.groovy.PatternEditorContextMembersProvider.getRootByClasses ( org.intellij.plugins.intelliLang.inject.InjectorUtils.getPatternClasses ( injection.getSupportId ( ) ) , file.getProject ( ) ) ) , com.intellij.openapi.util.ModificationTracker.NEVER_CHANGED ) ; }

Target:
private static boolean processPatternContext ( @ org.jetbrains.annotations.NotNull org.intellij.plugins.intelliLang.inject.config.BaseInjection injection , @ org.jetbrains.annotations.NotNull org.intellij.plugins.intelliLang.inject.groovy.PsiFile file , @ org.jetbrains.annotations.NotNull com.intellij.util.Processor < org.intellij.plugins.intelliLang.inject.groovy.PsiElement > processor ) { return processor.process ( org.intellij.plugins.intelliLang.inject.groovy.PatternEditorContextMembersProvider.getRootByClasses ( file , org.intellij.plugins.intelliLang.inject.InjectorUtils.getPatternClasses ( injection.getSupportId ( ) ) ) ) ; }
Source:
public java.io.OutputStream openWrite ( ) throws com.android.sched.util.file.WrongPermissionException { synchronized ( this ) { digests.remove ( getPath ( ) ) ; digest = null ; } return new java.security.DigestOutputStream ( wrappedFile.openWrite ( ) , mdFactory.create ( ) ) { @ java.lang.Override public void close ( ) throws java.io.IOException { super . close ( ) ; synchronized ( com.android.sched.vfs.MessageDigestFS.this ) { digests.put ( getPath ( ) , getDigestString ( getMessageDigest ( ) . digest ( ) ) ) ; digest = null ; } } } ; }

Target:
public java.io.OutputStream getOutputStream ( ) throws com.android.sched.util.file.WrongPermissionException { synchronized ( this ) { digests.remove ( getPath ( ) ) ; digest = null ; } return new java.security.DigestOutputStream ( wrappedFile.getOutputStream ( ) , mdFactory.create ( ) ) { @ java.lang.Override public void close ( ) throws java.io.IOException { super . close ( ) ; synchronized ( com.android.sched.vfs.MessageDigestFS.this ) { digests.put ( getPath ( ) , getDigestString ( getMessageDigest ( ) . digest ( ) ) ) ; digest = null ; } } } ; }
Source:
public static boolean isApplicableFor ( @ org.jetbrains.annotations.NotNull com.intellij.openapi.vfs.VirtualFile file ) { if ( file.isDirectory ( ) ) return false ; com.intellij.openapi.fileTypes.FileType originalType = com.intellij.openapi.fileTypes.FileTypeManager.getInstance ( ) . getFileTypeByFileName ( file.getName ( ) ) ; return ( ( ! ( originalType.isBinary ( ) ) ) && ( originalType != ( com.intellij.openapi.fileTypes.FileTypes.PLAIN_TEXT ) ) ) && ( originalType != ( com.intellij.openapi.fileTypes.StdFileTypes.JAVA ) ) ; }

Target:
public static boolean isApplicableFor ( @ org.jetbrains.annotations.NotNull com.intellij.openapi.vfs.VirtualFile file ) { if ( ( file instanceof com.intellij.openapi.vfs.newvfs.impl.StubVirtualFile ) || ( file.isDirectory ( ) ) ) return false ; com.intellij.openapi.fileTypes.FileType originalType = com.intellij.openapi.fileTypes.FileTypeManager.getInstance ( ) . getFileTypeByFileName ( file.getName ( ) ) ; return ( ( ! ( originalType.isBinary ( ) ) ) && ( originalType != ( com.intellij.openapi.fileTypes.FileTypes.PLAIN_TEXT ) ) ) && ( originalType != ( com.intellij.openapi.fileTypes.StdFileTypes.JAVA ) ) ; }