auphong2707/dl4se-code-review-dataset huggingface dataset:
Source:
public void onDisconnect ( ) { android.util.Log.d ( com.android.bluetooth.hfpclient.connserv.HfpClientConnection.TAG , ( "onDisconnect " + ( mCurrentCall ) ) ) ; if ( ! ( mClosed ) ) { if ( ( ( mHeadsetProfile ) != null ) && ( ( mCurrentCall ) != null ) ) { mHeadsetProfile.terminateCall ( mDevice , ( mClientHasEcc ? mCurrentCall.getId ( ) : 0 ) ) ; mLocalDisconnect = true ; } else { close ( DisconnectCause.LOCAL ) ; } } }

Target:
public synchronized void onDisconnect ( ) { android.util.Log.d ( com.android.bluetooth.hfpclient.connserv.HfpClientConnection.TAG , ( "onDisconnect " + ( mCurrentCall ) ) ) ; mClosing = true ; if ( ! ( mClosed ) ) { if ( ( ( mHeadsetProfile ) != null ) && ( ( mCurrentCall ) != null ) ) { mHeadsetProfile.terminateCall ( mDevice , ( mClientHasEcc ? mCurrentCall.getId ( ) : 0 ) ) ; mLocalDisconnect = true ; } else if ( ( mCurrentCall ) == null ) { android.util.Log.w ( com.android.bluetooth.hfpclient.connserv.HfpClientConnection.TAG , "Call disconnected but call handle not received." ) ; } } }
Source:
private void loadClass ( ) throws java.io.IOException { mInput.readInt ( ) ; long id = readId ( ) ; mInput.readInt ( ) ; java.lang.String name = mStrings.get ( readId ( ) ) ; mClassNames.put ( id , name ) ; }

Target:
private void loadStackFrame ( ) throws java.io.IOException { long id = readId ( ) ; java.lang.String methodName = mStrings.get ( readId ( ) ) ; java.lang.String methodSignature = mStrings.get ( readId ( ) ) ; java.lang.String sourceFile = mStrings.get ( readId ( ) ) ; int serial = mInput.readInt ( ) ; int lineNumber = mInput.readInt ( ) ; com.android.tools.perflib.heap.StackFrame frame = new com.android.tools.perflib.heap.StackFrame ( id , methodName , methodSignature , sourceFile , serial , lineNumber ) ; mSnapshot.addStackFrame ( frame ) ; }
Source:
public void testAddAll ( ) { java.util.concurrent.CopyOnWriteArrayList full = jsr166.CopyOnWriteArrayListTest.populatedArray ( 3 ) ; java.util.Vector v = new java.util.Vector ( ) ; v.add ( three ) ; v.add ( four ) ; v.add ( five ) ; full.addAll ( v ) ; assertEquals ( 6 , full.size ( ) ) ; }

Target:
public void testAddAll ( ) { java.util.concurrent.CopyOnWriteArrayList full = jsr166.CopyOnWriteArrayListTest.populatedArray ( 3 ) ; assertTrue ( full.addAll ( java.util.Arrays.asList ( three , four , five ) ) ) ; assertEquals ( 6 , full.size ( ) ) ; assertTrue ( full.addAll ( java.util.Arrays.asList ( three , four , five ) ) ) ; assertEquals ( 9 , full.size ( ) ) ; }
Source:
public final short getShort ( ) { int newPosition = ( position ) + ( libcore.io.SizeOf.SHORT ) ; if ( newPosition > ( limit ) ) { throw new java.nio.BufferUnderflowException ( ) ; } short result = this . block.peekShort ( ( ( offset ) + ( position ) ) , order ) ; position = newPosition ; return result ; }

Target:
public final short getShort ( ) { checkNotFreed ( ) ; int newPosition = ( position ) + ( libcore.io.SizeOf.SHORT ) ; if ( newPosition > ( limit ) ) { throw new java.nio.BufferUnderflowException ( ) ; } short result = this . block.peekShort ( ( ( offset ) + ( position ) ) , order ) ; position = newPosition ; return result ; }
Source:
public boolean visit ( @ javax.annotation.Nonnull com.android.jack.ir.ast.JDefinedClass definedClass ) { com.android.jack.ir.ast.JClass superClass = definedClass.getSuperClass ( ) ; if ( superClass != null ) { addStructUsage ( superClass ) ; } for ( com.android.jack.ir.ast.JInterface interf : definedClass.getImplements ( ) ) { addStructUsage ( interf ) ; } return super . visit ( definedClass ) ; }

Target:
protected void collect ( @ javax.annotation.Nonnull com.android.jack.ir.ast.JType usedType ) { if ( usedType instanceof com.android.jack.ir.ast.JArrayType ) { usedType = ( ( com.android.jack.ir.ast.JArrayType ) ( usedType ) ) . getLeafType ( ) ; } if ( ( usedType.getSourceInfo ( ) ) == ( com.android.jack.ir.sourceinfo.SourceInfo.UNKNOWN ) ) { return ; } java.lang.String usedTypeFileName = usedType.getSourceInfo ( ) . getFileName ( ) ; if ( inBody ) { compilerState.addCodeUsage ( currentFileName , usedTypeFileName ) ; } else { compilerState.addStructUsage ( currentFileName , usedTypeFileName ) ; } }
Source:
public void exit ( ) { if ( ( mPhone ) != null ) { mPhone.mCi.unregisterForRilConnected ( getHandler ( ) ) ; mPhone.mCi.unregisterForDataNetworkStateChanged ( getHandler ( ) ) ; } if ( ( mDcTesterDeactivateAll ) != null ) { mDcTesterDeactivateAll.dispose ( ) ; } }

Target:
public void exit ( ) { if ( ( mPhone ) != null ) { mPhone.mCi.unregisterForRilConnected ( getHandler ( ) ) ; mPhone.mCi.unregisterForDataCallListChanged ( getHandler ( ) ) ; } if ( ( mDcTesterDeactivateAll ) != null ) { mDcTesterDeactivateAll.dispose ( ) ; } }
Source:
public void copy1DRangeFromUnchecked ( int off , int count , float [ ] d ) { int dataSize = ( mType.mElement.getBytesSize ( ) ) * count ; data1DChecks ( off , count , ( ( d.length ) * 4 ) , dataSize ) ; mRS.nAllocationData1D ( getIDSafe ( ) , off , mSelectedLOD , count , d , dataSize ) ; }

Target:
public void copyFromUnchecked ( float [ ] d ) { copyFromUnchecked ( d , Element.DataType.FLOAT_32 , d.length ) ; }
Source:
private void expireRequest ( android.net.NetworkCapabilities netCap , int sequenceNum ) { int ourSeqNum = - 1 ; synchronized ( android.net.ConnectivityManager.sLegacyRequests ) { android.net.ConnectivityManager.LegacyRequest l = android.net.ConnectivityManager.sLegacyRequests.get ( netCap ) ; if ( l == null ) return ; ourSeqNum = l.expireSequenceNumber ; if ( ( l.expireSequenceNumber ) == sequenceNum ) { unregisterNetworkCallback ( l.networkCallback ) ; android.net.ConnectivityManager.sLegacyRequests.remove ( netCap ) ; } } android.util.Log.d ( android.net.ConnectivityManager.TAG , ( ( ( "expireRequest with " + ourSeqNum ) + ", " ) + sequenceNum ) ) ; }

Target:
private boolean removeRequestForFeature ( android.net.NetworkCapabilities netCap ) { final android.net.ConnectivityManager.LegacyRequest l ; synchronized ( android.net.ConnectivityManager.sLegacyRequests ) { l = android.net.ConnectivityManager.sLegacyRequests.remove ( netCap ) ; } if ( l == null ) return false ; unregisterNetworkCallback ( l.networkCallback ) ; l.clearDnsBinding ( ) ; return true ; }
Source:
void systemReady ( ) { if ( com.android.server.NetworkScoreService.DBG ) android.util.Log.d ( com.android.server.NetworkScoreService.TAG , "systemReady" ) ; android.content.ContentResolver cr = mContext.getContentResolver ( ) ; if ( ( Settings.Global.getInt ( cr , Settings.Global.NETWORK_SCORING_PROVISIONED , 0 ) ) == 0 ) { java.lang.String defaultPackage = mContext.getResources ( ) . getString ( R.string.config_defaultNetworkScorerPackageName ) ; if ( ! ( android.text.TextUtils.isEmpty ( defaultPackage ) ) ) { android.net.NetworkScorerAppManager.setActiveScorer ( mContext , defaultPackage ) ; } Settings.Global.putInt ( cr , Settings.Global.NETWORK_SCORING_PROVISIONED , 1 ) ; } registerPackageMonitorIfNeeded ( ) ; }

Target:
void systemReady ( ) { if ( com.android.server.NetworkScoreService.DBG ) android.util.Log.d ( com.android.server.NetworkScoreService.TAG , "systemReady" ) ; android.content.ContentResolver cr = mContext.getContentResolver ( ) ; if ( ( Settings.Global.getInt ( cr , Settings.Global.NETWORK_SCORING_PROVISIONED , 0 ) ) == 0 ) { java.lang.String defaultPackage = mContext.getResources ( ) . getString ( R.string.config_defaultNetworkScorerPackageName ) ; if ( ! ( android.text.TextUtils.isEmpty ( defaultPackage ) ) ) { mNetworkScorerAppManager.setActiveScorer ( defaultPackage ) ; } Settings.Global.putInt ( cr , Settings.Global.NETWORK_SCORING_PROVISIONED , 1 ) ; } registerPackageMonitorIfNeeded ( ) ; }
Source:
public java.util.Set < java.lang.String > computeList ( @ com.android.annotations.NonNull java.util.Set < java.lang.String > fullList ) { java.util.Set < java.lang.String > list = super . computeList ( fullList ) ; if ( ( isEnable ( ) ) && ( universalApk ) ) { list.add ( null ) ; } return list ; }

Target:
public java.util.Set < java.lang.String > getApplicableFilters ( @ com.android.annotations.NonNull java.util.Set < java.lang.String > allFilters ) { java.util.Set < java.lang.String > list = super . getApplicableFilters ( allFilters ) ; if ( ( isEnable ( ) ) && ( universalApk ) ) { list.add ( null ) ; } return list ; }
Source:
public android.renderscript.cts.Floaty divide ( android.renderscript.cts.Floaty a ) { float num = java.lang.Math.abs ( mValue ) ; float den = java.lang.Math.abs ( a.mValue ) ; mError = ( ( num * ( a.mError ) ) + ( den * ( mError ) ) ) / ( den * ( den - ( a.mError ) ) ) ; mValue /= a.mValue ; return this ; }

Target:
public java.lang.String toString ( ) { return java.lang.String.format ( "%24.9g (%16x) +- %24.9g ulf %d (%d bits)" , mValue , java.lang.Double.doubleToRawLongBits ( mValue ) , mError , getUlf ( ) , mNumberOfBits ) ; }
Source:
public void enableAutoConnect ( boolean enable ) { if ( enable ) { doBooleanCommand ( "STA_AUTOCONNECT 1" ) ; } else { doBooleanCommand ( "STA_AUTOCONNECT 0" ) ; } }

Target:
public boolean startWpsPbc ( java.lang.String bssid ) { if ( com.android.server.wifi.WifiNative.HIDL_SUP_ENABLE ) { return mSupplicantStaIfaceHal.startWpsPbc ( bssid ) ; } else { if ( android.text.TextUtils.isEmpty ( bssid ) ) { return doBooleanCommand ( "WPS_PBC" ) ; } else { return doBooleanCommand ( ( "WPS_PBC " + bssid ) ) ; } } }
Source:
public void testLaunchToSideMultiple ( ) throws java.lang.Exception { HEAD ( ( ( android.server.cts.n ) ( launchActivityInDockStack ( android.server.cts.LAUNCHING_ACTIVITY ) ) ) ) ; mAmWmState.computeState ( mDevice , new java.lang.String [ ] { LAUNCHING_ACTIVITY } ) ; final java.lang.String [ ] waitForActivitiesVisible = new java.lang.String [ ] { android.server.cts.ActivityManagerDockedStackTests.TEST_ACTIVITY_NAME , LAUNCHING_ACTIVITY } ; }

Target:
public void testLaunchToSide ( ) throws java.lang.Exception { if ( ! ( supportsMultiWindowMode ( ) ) ) { com.android.tradefed.log.LogUtil.CLog.logAndDisplay ( LogLevel.INFO , "Skipping test: no multi-window support" ) ; return ; } launchActivityInDockStack ( android.server.cts.LAUNCHING_ACTIVITY ) ; mAmWmState.computeState ( mDevice , new java.lang.String [ ] { LAUNCHING_ACTIVITY } ) ; launchActivityToSide ( ) ; mAmWmState.computeState ( mDevice , new java.lang.String [ ] { LAUNCHING_ACTIVITY , android.server.cts.ActivityManagerDockedStackTests.TEST_ACTIVITY_NAME } ) ; mAmWmState.assertContainsStack ( "Must contain fullscreen stack." , android.server.cts.FULLSCREEN_WORKSPACE_STACK_ID ) ; mAmWmState.assertContainsStack ( "Must contain docked stack." , android.server.cts.DOCKED_STACK_ID ) ; }
Source:
void stop ( ) { if ( ( mDefaultNetworkCallback ) != null ) { getConnectivityManager ( ) . unregisterNetworkCallback ( mDefaultNetworkCallback ) ; mDefaultNetworkCallback = null ; } if ( ( mDunTetheringCallback ) != null ) { getConnectivityManager ( ) . unregisterNetworkCallback ( mDunTetheringCallback ) ; mDunTetheringCallback = null ; } mNetworkMap.clear ( ) ; }

Target:
public void stop ( ) { if ( ( mDefaultNetworkCallback ) != null ) { cm ( ) . unregisterNetworkCallback ( mDefaultNetworkCallback ) ; mDefaultNetworkCallback = null ; } if ( ( mDunTetheringCallback ) != null ) { cm ( ) . unregisterNetworkCallback ( mDunTetheringCallback ) ; mDunTetheringCallback = null ; } mNetworkMap.clear ( ) ; }
Source:
java.io.OutputStream openWrite ( @ javax.annotation.Nonnull com.android.sched.vfs.ParentVFile file , boolean append ) throws com.android.sched.util.file.WrongPermissionException { assert ! ( isClosed ( ) ) ; assert capabilities.contains ( Capabilities.WRITE ) ; VFSStatCategory.DIR_WRITE.getCounterStat ( getTracer ( ) , infoString ) . incValue ( ) ; java.io.File path = getNativeFile ( file.getPath ( ) ) ; try { return new java.io.FileOutputStream ( path , append ) ; } catch ( java.io.FileNotFoundException e ) { com.android.sched.util.file.FileOrDirectory.checkPermissions ( path , file.getLocation ( ) , Permission.WRITE ) ; throw new com.android.sched.util.ConcurrentIOException ( e ) ; } }

Target:
java.io.OutputStream openWrite ( @ javax.annotation.Nonnull com.android.sched.vfs.ParentVFile file , boolean append ) throws com.android.sched.util.file.WrongPermissionException { assert ! ( isClosed ( ) ) ; assert capabilities.contains ( Capabilities.WRITE ) ; VFSStatCategory.DIR_WRITE.getCounterStat ( getTracer ( ) , infoString ) . incValue ( ) ; java.io.File path = getNativeFile ( file.getPath ( ) ) ; try { return new java.io.FileOutputStream ( path , append ) ; } catch ( java.io.FileNotFoundException e ) { com.android.sched.vfs.DirectFS.checkPermissionsIfExists ( path , file.getLocation ( ) , Permission.WRITE ) ; throw new java.lang.AssertionError ( e ) ; } }
Source:
public void visitConstructor ( @ com.android.annotations.NonNull com.android.tools.lint.detector.api.JavaContext context , @ com.android.annotations.Nullable lombok.ast.AstVisitor visitor , @ com.android.annotations.NonNull lombok.ast.ConstructorInvocation node , @ com.android.annotations.NonNull com.android.tools.lint.client.api.JavaParser.ResolvedMethod constructor ) { if ( ! ( com.android.tools.lint.checks.DateFormatDetector.specifiesLocale ( constructor ) ) ) { com.android.tools.lint.detector.api.Location location = context.getLocation ( node ) ; java.lang.String message = "To get local formatting use `getDateInstance()`, `getDateTimeInstance()`, " + ( "or `getTimeInstance()`, or use `new SimpleDateFormat(String template, " + "Locale locale)` with for example `Locale.US` for ASCII dates." ) ; context.report ( com.android.tools.lint.checks.DateFormatDetector.DATE_FORMAT , node , location , message ) ; } }

Target:
public void visitConstructor ( @ com.android.annotations.NonNull com.android.tools.lint.detector.api.JavaContext context , @ com.android.annotations.Nullable com.intellij.psi.JavaElementVisitor visitor , @ com.android.annotations.NonNull com.intellij.psi.PsiNewExpression node , @ com.android.annotations.NonNull com.intellij.psi.PsiMethod constructor ) { if ( ! ( com.android.tools.lint.checks.DateFormatDetector.specifiesLocale ( constructor ) ) ) { com.android.tools.lint.detector.api.Location location = context.getLocation ( node ) ; java.lang.String message = "To get local formatting use `getDateInstance()`, `getDateTimeInstance()`, " + ( "or `getTimeInstance()`, or use `new SimpleDateFormat(String template, " + "Locale locale)` with for example `Locale.US` for ASCII dates." ) ; context.report ( com.android.tools.lint.checks.DateFormatDetector.DATE_FORMAT , node , location , message ) ; } }
Source:
public static void computeClamp ( android.renderscript.cts.TestClamp.ArgumentsUshortUshortUshortUshort args ) { args.ulf = 0 ; args.ulfRelaxed = 0 ; args.out = ( ( short ) ( java.lang.StrictMath.min ( ( ( args.inMaxValue ) & 65535 ) , java.lang.StrictMath.max ( ( ( args.inValue ) & 65535 ) , ( ( args.inMinValue ) & 65535 ) ) ) ) ) ; }

Target:
public static void computeConvert ( android.renderscript.cts.TestConvert.ArgumentsUintUchar args ) { args.out = android.renderscript.cts.CoreMathVerifier.convertUintToUchar ( args.inV ) ; }
Source:
com.android.builder.ProductFlavor mergeWith ( @ com.android.annotations.NonNull com.android.builder.ProductFlavor base ) { com.android.builder.ProductFlavor flavor = new com.android.builder.ProductFlavor ( "" ) ; flavor.mMinSdkVersion = chooseInt ( mMinSdkVersion , base.mMinSdkVersion ) ; flavor.mTargetSdkVersion = chooseInt ( mTargetSdkVersion , base.mTargetSdkVersion ) ; flavor.mVersionCode = chooseInt ( mVersionCode , base.mVersionCode ) ; flavor.mVersionName = chooseString ( mVersionName , base.mVersionName ) ; flavor.mPackageName = chooseString ( mPackageName , base.mPackageName ) ; flavor.mTestPackageName = chooseString ( mTestPackageName , base.mTestPackageName ) ; flavor.mTestInstrumentationRunner = chooseString ( mTestInstrumentationRunner , base.mTestInstrumentationRunner ) ; return flavor ; }

Target:
com.android.builder.ProductFlavor mergeOver ( @ com.android.annotations.NonNull com.android.builder.ProductFlavor base ) { com.android.builder.ProductFlavor flavor = new com.android.builder.ProductFlavor ( "" ) ; flavor.mMinSdkVersion = chooseInt ( mMinSdkVersion , base.mMinSdkVersion ) ; flavor.mTargetSdkVersion = chooseInt ( mTargetSdkVersion , base.mTargetSdkVersion ) ; flavor.mVersionCode = chooseInt ( mVersionCode , base.mVersionCode ) ; flavor.mVersionName = chooseString ( mVersionName , base.mVersionName ) ; flavor.mPackageName = chooseString ( mPackageName , base.mPackageName ) ; flavor.mTestPackageName = chooseString ( mTestPackageName , base.mTestPackageName ) ; flavor.mTestInstrumentationRunner = chooseString ( mTestInstrumentationRunner , base.mTestInstrumentationRunner ) ; return flavor ; }
Source:
public static com.ibm.icu.util.TimeZone getDefault ( ) { if ( ( com.ibm.icu.util.TimeZone.defaultZone ) == null ) { synchronized ( com.ibm.icu.util.TimeZone.class ) { if ( ( com.ibm.icu.util.TimeZone.defaultZone ) == null ) { if ( ( com.ibm.icu.util.TimeZone.TZ_IMPL ) == ( com.ibm.icu.util.TimeZone.TIMEZONE_JDK ) ) { com.ibm.icu.util.TimeZone.defaultZone = new com.ibm.icu.impl.JavaTimeZone ( ) ; } else { java.util.TimeZone temp = java.util.TimeZone.getDefault ( ) ; com.ibm.icu.util.TimeZone.defaultZone = com.ibm.icu.util.TimeZone.getFrozenTimeZone ( temp.getID ( ) ) ; } } } } return com.ibm.icu.util.TimeZone.defaultZone.cloneAsThawed ( ) ; }

Target:
public static com.ibm.icu.util.TimeZone getDefault ( ) { if ( ( com.ibm.icu.util.TimeZone.defaultZone ) == null ) { synchronized ( java.util.TimeZone.class ) { synchronized ( com.ibm.icu.util.TimeZone.class ) { if ( ( com.ibm.icu.util.TimeZone.defaultZone ) == null ) { if ( ( com.ibm.icu.util.TimeZone.TZ_IMPL ) == ( com.ibm.icu.util.TimeZone.TIMEZONE_JDK ) ) { com.ibm.icu.util.TimeZone.defaultZone = new com.ibm.icu.impl.JavaTimeZone ( ) ; } else { java.util.TimeZone temp = java.util.TimeZone.getDefault ( ) ; com.ibm.icu.util.TimeZone.defaultZone = com.ibm.icu.util.TimeZone.getFrozenTimeZone ( temp.getID ( ) ) ; } } } } } return com.ibm.icu.util.TimeZone.defaultZone.cloneAsThawed ( ) ; }
Source:
private static java.lang.String findValidPath ( java.lang.String ... names ) { for ( java.lang.String name : names ) { java.lang.String path ; if ( ( name.indexOf ( '.' ) ) != ( - 1 ) ) { path = java.lang.System.getProperty ( name ) ; } else { path = java.lang.System.getenv ( name ) ; } if ( path != null ) { java.io.File f = new java.io.File ( path ) ; if ( f.isDirectory ( ) ) { return path ; } } } return null ; }

Target:
private static java.lang.String checkPath ( java.lang.String path ) { if ( path != null ) { java.io.File f = new java.io.File ( path ) ; if ( f.isDirectory ( ) ) { return path ; } } return null ; }
Source:
public static java.lang.String getCurrentCountryIso ( android.content.Context context , @ android.support.annotation.Nullable android.telecom.PhoneAccountHandle phoneAccountHandle ) { android.os.Trace.beginSection ( "PhoneNumberHelper.getCurrentCountryIso" ) ; java.lang.String countryIso = com.android.dialer.compat.telephony.TelephonyManagerCompat.getNetworkCountryIsoForPhoneAccountHandle ( context , phoneAccountHandle ) ; if ( android.text.TextUtils.isEmpty ( countryIso ) ) { countryIso = com.android.dialer.compat.CompatUtils.getLocale ( context ) . getCountry ( ) ; com.android.dialer.common.LogUtil.i ( "PhoneNumberHelper.getCurrentCountryIso" , ( "No CountryDetector; falling back to countryIso based on locale: " + countryIso ) ) ; } countryIso = countryIso.toUpperCase ( ) ; android.os.Trace.endSection ( ) ; return countryIso ; }

Target:
public static java.lang.String getCurrentCountryIso ( android.content.Context context , @ android.support.annotation.Nullable android.telecom.PhoneAccountHandle phoneAccountHandle ) { android.os.Trace.beginSection ( "PhoneNumberHelper.getCurrentCountryIso" ) ; java.lang.String countryIso = com.android.dialer.compat.telephony.TelephonyManagerCompat.getNetworkCountryIsoForPhoneAccountHandle ( context , phoneAccountHandle ) ; if ( android.text.TextUtils.isEmpty ( countryIso ) ) { countryIso = com.android.dialer.i18n.LocaleUtils.getLocale ( context ) . getCountry ( ) ; com.android.dialer.common.LogUtil.i ( "PhoneNumberHelper.getCurrentCountryIso" , ( "No CountryDetector; falling back to countryIso based on locale: " + countryIso ) ) ; } countryIso = countryIso.toUpperCase ( ) ; android.os.Trace.endSection ( ) ; return countryIso ; }
Source:
public java.util.List < com.android.tv.dvr.ScheduledRecording > getScheduledRecordings ( long seriesRecordingId ) { java.util.List < com.android.tv.dvr.ScheduledRecording > result = new java.util.ArrayList < > ( ) ; for ( com.android.tv.dvr.ScheduledRecording r : mScheduledRecordings.values ( ) ) { if ( ( r.getSeriesRecordingId ( ) ) == seriesRecordingId ) { result.add ( r ) ; } } return result ; }

Target:
public java.util.List < com.android.tv.dvr.data.ScheduledRecording > getScheduledRecordings ( long seriesRecordingId ) { java.util.List < com.android.tv.dvr.data.ScheduledRecording > result = new java.util.ArrayList < > ( ) ; for ( com.android.tv.dvr.data.ScheduledRecording r : mScheduledRecordings.values ( ) ) { if ( ( r.getSeriesRecordingId ( ) ) == seriesRecordingId ) { result.add ( r ) ; } } return result ; }
Source:
private javax.sip.message.Request createRequest ( java.lang.String requestType , android.net.sip.SipProfile userProfile , java.lang.String tag ) throws java.text.ParseException , javax.sip.SipException { javax.sip.header.FromHeader fromHeader = createFromHeader ( userProfile , tag ) ; javax.sip.header.ToHeader toHeader = createToHeader ( userProfile ) ; javax.sip.address.SipURI requestURI = mAddressFactory.createSipURI ( userProfile.getUriString ( ) . replaceFirst ( ( ( userProfile.getUserName ( ) ) + "@" ) , "" ) ) ; java.util.List < javax.sip.header.ViaHeader > viaHeaders = createViaHeaders ( ) ; javax.sip.header.CallIdHeader callIdHeader = createCallIdHeader ( ) ; javax.sip.header.CSeqHeader cSeqHeader = createCSeqHeader ( requestType ) ; javax.sip.header.MaxForwardsHeader maxForwards = createMaxForwardsHeader ( ) ; javax.sip.message.Request request = mMessageFactory.createRequest ( requestURI , requestType , callIdHeader , cSeqHeader , fromHeader , toHeader , viaHeaders , maxForwards ) ; javax.sip.header.Header userAgentHeader = mHeaderFactory.createHeader ( "User-Agent" , "SIPAUA/0.1.001" ) ; request.addHeader ( userAgentHeader ) ; return request ; }

Target:
private javax.sip.message.Request createRequest ( java.lang.String requestType , android.net.sip.SipProfile userProfile , java.lang.String tag ) throws java.text.ParseException , javax.sip.SipException { javax.sip.header.FromHeader fromHeader = createFromHeader ( userProfile , tag ) ; javax.sip.header.ToHeader toHeader = createToHeader ( userProfile ) ; java.lang.String replaceStr = java.util.regex.Pattern.quote ( ( ( userProfile.getUserName ( ) ) + "@" ) ) ; javax.sip.address.SipURI requestURI = mAddressFactory.createSipURI ( userProfile.getUriString ( ) . replaceFirst ( replaceStr , "" ) ) ; java.util.List < javax.sip.header.ViaHeader > viaHeaders = createViaHeaders ( ) ; javax.sip.header.CallIdHeader callIdHeader = createCallIdHeader ( ) ; javax.sip.header.CSeqHeader cSeqHeader = createCSeqHeader ( requestType ) ; javax.sip.header.MaxForwardsHeader maxForwards = createMaxForwardsHeader ( ) ; javax.sip.message.Request request = mMessageFactory.createRequest ( requestURI , requestType , callIdHeader , cSeqHeader , fromHeader , toHeader , viaHeaders , maxForwards ) ; javax.sip.header.Header userAgentHeader = mHeaderFactory.createHeader ( "User-Agent" , "SIPAUA/0.1.001" ) ; request.addHeader ( userAgentHeader ) ; return request ; }
Source:
public void testUngrant_DoubleGrantUngrant_Failure ( ) throws java.lang.Exception { assertTrue ( "Password should work for keystore" , mKeyStore.password ( android.security.KeyStoreTest.TEST_PASSWD ) ) ; assertTrue ( "Should be able to generate key for testcase" , mKeyStore.generate ( android.security.KeyStoreTest.TEST_KEYNAME , KeyStore.UID_SELF , NativeCrypto.EVP_PKEY_RSA , android.security.KeyStoreTest.RSA_KEY_SIZE , KeyStore.FLAG_ENCRYPTED , null ) ) ; assertTrue ( "Should be able to grant key to other user" , mKeyStore.grant ( android.security.KeyStoreTest.TEST_KEYNAME , 0 ) ) ; assertTrue ( "Should be able to grant key to other user a second time" , mKeyStore.grant ( android.security.KeyStoreTest.TEST_KEYNAME , 0 ) ) ; assertTrue ( "Should be able to ungrant key to other user" , mKeyStore.ungrant ( android.security.KeyStoreTest.TEST_KEYNAME , 0 ) ) ; assertFalse ( "Should fail to ungrant key to other user second time" , mKeyStore.ungrant ( android.security.KeyStoreTest.TEST_KEYNAME , 0 ) ) ; }

Target:
public void testUngrant_DoubleGrantUngrant_Failure ( ) throws java.lang.Exception { assertTrue ( "Password should work for keystore" , mKeyStore.password ( android.security.KeyStoreTest.TEST_PASSWD ) ) ; assertTrue ( "Should be able to generate key for testcase" , mKeyStore.generate ( android.security.KeyStoreTest.TEST_KEYNAME , KeyStore.UID_SELF , NativeConstants.EVP_PKEY_RSA , android.security.KeyStoreTest.RSA_KEY_SIZE , KeyStore.FLAG_ENCRYPTED , null ) ) ; assertTrue ( "Should be able to grant key to other user" , mKeyStore.grant ( android.security.KeyStoreTest.TEST_KEYNAME , 0 ) ) ; assertTrue ( "Should be able to grant key to other user a second time" , mKeyStore.grant ( android.security.KeyStoreTest.TEST_KEYNAME , 0 ) ) ; assertTrue ( "Should be able to ungrant key to other user" , mKeyStore.ungrant ( android.security.KeyStoreTest.TEST_KEYNAME , 0 ) ) ; assertFalse ( "Should fail to ungrant key to other user second time" , mKeyStore.ungrant ( android.security.KeyStoreTest.TEST_KEYNAME , 0 ) ) ; }
Source:
private java.util.Set < java.lang.Integer > getProfileIdsLocked ( int userId ) { java.util.Set < java.lang.Integer > userIds = new java.util.HashSet < java.lang.Integer > ( ) ; final java.util.List < android.content.pm.UserInfo > profiles = getUserManagerLocked ( ) . getProfiles ( userId , false ) ; for ( android.content.pm.UserInfo user : profiles ) { userIds.add ( java.lang.Integer.valueOf ( user.id ) ) ; } return userIds ; }

Target:
public void suppressResizeConfigChanges ( boolean suppress ) throws android.os.RemoteException { enforceCallingPermission ( android.Manifest.permission.MANAGE_ACTIVITY_STACKS , "suppressResizeConfigChanges()" ) ; synchronized ( this ) { mSuppressResizeConfigChanges = suppress ; } }
Source:
public void isAvailable_throwException_shouldReturnFalse ( ) { org.mockito.Mockito.when ( mActivity.getSystemService ( Context.WIFI_P2P_SERVICE ) ) . thenThrow ( new java.lang.IllegalStateException ( ) ) ; com.google.common.truth.Truth.assertThat ( com.android.settings.wfd.WifiDisplaySettings.isAvailable ( mActivity ) ) . isFalse ( ) ; }

Target:
public void setUp ( ) { org.mockito.MockitoAnnotations.initMocks ( this ) ; org.mockito.Mockito.when ( mActivity.getSystemService ( Context.MEDIA_ROUTER_SERVICE ) ) . thenReturn ( mMediaRouter ) ; org.mockito.Mockito.when ( mActivity.getPackageManager ( ) ) . thenReturn ( mPackageManager ) ; org.mockito.Mockito.when ( mPackageManager.hasSystemFeature ( PackageManager.FEATURE_WIFI_DIRECT ) ) . thenReturn ( true ) ; mSummaryProvider = WifiDisplaySettings.SUMMARY_PROVIDER_FACTORY.createSummaryProvider ( mActivity , mSummaryLoader ) ; }
Source:
public void onPageFinished ( android.webkit.WebView view , java.lang.String url ) { mAlert.setTitle ( getString ( R.string.settings_license_activity_title ) ) ; }

Target:
public void handleMessage ( android.os.Message msg ) { super . handleMessage ( msg ) ; if ( ( msg.what ) == ( com.android.settings.SettingsLicenseActivity.LicenseFileLoader.STATUS_OK ) ) { java.lang.String text = ( ( java.lang.String ) ( msg.obj ) ) ; showPageOfText ( text ) ; } else { showErrorAndFinish ( ) ; } }
Source:
public void onIdentityChanged ( byte [ ] mac ) { if ( android.net.wifi.nan.WifiNanManager.VDBG ) android.util.Log.v ( android.net.wifi.nan.WifiNanManager.TAG , ( "onIdentityChanged: mac=" + ( new java.lang.String ( libcore.util.HexEncoding.encode ( mac ) ) ) ) ) ; android.os.Message msg = mHandler.obtainMessage ( android.net.wifi.nan.WifiNanManager.WifiNanEventCallbackProxy.CALLBACK_IDENTITY_CHANGED ) ; msg.obj = mac ; mHandler.sendMessage ( msg ) ; }

Target:
public void onIdentityChanged ( byte [ ] mac ) { if ( android.net.wifi.aware.WifiAwareManager.VDBG ) android.util.Log.v ( android.net.wifi.aware.WifiAwareManager.TAG , ( "onIdentityChanged: mac=" + ( new java.lang.String ( libcore.util.HexEncoding.encode ( mac ) ) ) ) ) ; android.os.Message msg = mHandler.obtainMessage ( android.net.wifi.aware.WifiAwareManager.WifiAwareEventCallbackProxy.CALLBACK_IDENTITY_CHANGED ) ; msg.obj = mac ; mHandler.sendMessage ( msg ) ; }
Source:
private com.android.jack.ir.ast.JMethod findMethod ( @ javax.annotation.Nonnull org.eclipse.jdt.internal.compiler.lookup.MethodBinding binding , @ javax.annotation.Nonnull com.android.jack.ir.ast.JDefinedClassOrInterface enclosingType ) { com.android.jack.ir.ast.JMethod method = null ; java.lang.String searchedSignature = ( new java.lang.String ( binding.selector ) ) + ( new java.lang.String ( binding.signature ( ) ) ) ; for ( com.android.jack.ir.ast.JMethod existing : enclosingType.getMethods ( ) ) { if ( equals ( binding , searchedSignature , existing ) ) { method = existing ; break ; } } return method ; }

Target:
private com.android.jack.ir.ast.JMethod findMethod ( @ javax.annotation.Nonnull org.eclipse.jdt.internal.compiler.lookup.MethodBinding binding , @ javax.annotation.Nonnull com.android.jack.ir.ast.JDefinedClassOrInterface enclosingType ) { com.android.jack.ir.ast.JMethod method = null ; java.lang.String searchedSignature = ( new java.lang.String ( binding.selector ) ) + ( new java.lang.String ( binding.signature ( ) ) ) ; for ( com.android.jack.ir.ast.JMethod existing : enclosingType.getMethods ( ) ) { if ( searchedSignature.equals ( com.android.jack.Jack.getLookupFormatter ( ) . getName ( existing ) ) ) { method = existing ; break ; } } return method ; }
Source:
public byte [ ] iccExchangeSimIO ( int fileID , int command , int p1 , int p2 , int p3 , java.lang.String filePath ) { try { com.android.internal.telephony.ITelephony telephony = getITelephony ( ) ; if ( telephony != null ) return telephony.iccExchangeSimIO ( fileID , command , p1 , p2 , p3 , filePath ) ; } catch ( android.os.RemoteException ex ) { } catch ( java.lang.NullPointerException ex ) { } return null ; }

Target:
public android.telephony.VisualVoicemailSmsFilterSettings getVisualVoicemailSmsFilterSettings ( int subId ) { try { com.android.internal.telephony.ITelephony telephony = getITelephony ( ) ; if ( telephony != null ) { return telephony.getVisualVoicemailSmsFilterSettings ( mContext.getOpPackageName ( ) , subId ) ; } } catch ( android.os.RemoteException ex ) { } catch ( java.lang.NullPointerException ex ) { } return null ; }
Source:
public void err ( @ com.android.annotations.Nullable java.lang.String line ) { super . err ( line ) ; }

Target:
private java.util.List < java.lang.String > getAaptOutput ( @ com.android.annotations.NonNull java.io.File apkFile ) throws com.android.ide.common.process.ProcessException { com.android.ide.common.process.ProcessInfoBuilder builder = new com.android.ide.common.process.ProcessInfoBuilder ( ) ; builder.setExecutable ( mAaptFile ) ; builder.addArgs ( "dump" , "badging" , apkFile.getPath ( ) ) ; com.android.ide.common.process.CachedProcessOutputHandler processOutputHandler = new com.android.ide.common.process.CachedProcessOutputHandler ( ) ; mProcessExecutor.execute ( builder.createProcess ( ) , processOutputHandler ) . rethrowFailure ( ) . assertNormalExitValue ( ) ; com.android.ide.common.process.BaseProcessOutputHandler.BaseProcessOutput output = processOutputHandler.getProcessOutput ( ) ; return com.google.common.base.Splitter.on ( '\n' ) . splitToList ( output.getStandardOutputAsString ( ) ) ; }
Source:
void test ( ) { if ( ( com.android.cts.verifier.notifications.MockListener.getInstance ( ) ) != null ) { status = com.android.cts.verifier.notifications.InteractiveVerifierActivity.PASS ; next ( ) ; } else { logFail ( ) ; status = com.android.cts.verifier.notifications.InteractiveVerifierActivity.RETEST ; delay ( ) ; } }

Target:
protected void test ( ) { if ( ( ( com.android.cts.verifier.notifications.MockListener.getInstance ( ) ) != null ) && ( com.android.cts.verifier.notifications.MockListener.getInstance ( ) . isConnected ) ) { status = com.android.cts.verifier.notifications.InteractiveVerifierActivity.PASS ; next ( ) ; } else { logFail ( ) ; status = com.android.cts.verifier.notifications.InteractiveVerifierActivity.RETEST ; delay ( ) ; } }
Source:
public void testAesCbcHmacSha1Tcp6 ( ) throws java.lang.Exception { android.net.IpSecAlgorithm crypt = new android.net.IpSecAlgorithm ( android.net.IpSecAlgorithm.CRYPT_AES_CBC , android.net.cts.IpSecManagerTest.CRYPT_KEY ) ; android.net.IpSecAlgorithm auth = new android.net.IpSecAlgorithm ( android.net.IpSecAlgorithm.AUTH_HMAC_SHA1 , getAuthKey ( 160 ) , 96 ) ; checkTransform ( android.system.OsConstants.IPPROTO_TCP , android.net.cts.IpSecManagerTest.IPV6_LOOPBACK , crypt , auth , false , 1 , false ) ; checkTransform ( android.system.OsConstants.IPPROTO_TCP , android.net.cts.IpSecManagerTest.IPV6_LOOPBACK , crypt , auth , false , 1 , true ) ; }

Target:
public void testAesCbcHmacMd5Tcp4 ( ) 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 , android.net.cts.IpSecManagerTest.getKey ( 128 ) , 96 ) ; checkTransform ( android.system.OsConstants.IPPROTO_TCP , android.net.cts.IpSecManagerTest.IPV4_LOOPBACK , crypt , auth , null , false , 1 , false ) ; checkTransform ( android.system.OsConstants.IPPROTO_TCP , android.net.cts.IpSecManagerTest.IPV4_LOOPBACK , crypt , auth , null , false , 1 , true ) ; }
Source:
public void testInitWith ( ) throws java.lang.Exception { com.android.build.gradle.internal.dsl.SigningConfigDsl debug = new com.android.build.gradle.internal.dsl.SigningConfigDsl ( com.android.builder.BuilderConstants.DEBUG ) ; com.android.build.gradle.internal.dsl.SigningConfigDsl foo = new com.android.build.gradle.internal.dsl.SigningConfigDsl ( "foo" ) . initWith ( debug ) ; assertEquals ( debug.getStoreFile ( ) , foo.getStoreFile ( ) ) ; assertEquals ( debug.getStorePassword ( ) , foo.getStorePassword ( ) ) ; assertEquals ( debug.getKeyAlias ( ) , foo.getKeyAlias ( ) ) ; assertEquals ( debug.getKeyPassword ( ) , foo.getKeyPassword ( ) ) ; }

Target:
public void testInitWith ( ) throws java.lang.Exception { com.android.build.gradle.internal.dsl.SigningConfigDsl debug = new com.android.build.gradle.internal.dsl.SigningConfigDsl ( com.android.builder.core.BuilderConstants.DEBUG ) ; com.android.build.gradle.internal.dsl.SigningConfigDsl foo = new com.android.build.gradle.internal.dsl.SigningConfigDsl ( "foo" ) . initWith ( debug ) ; assertEquals ( debug.getStoreFile ( ) , foo.getStoreFile ( ) ) ; assertEquals ( debug.getStorePassword ( ) , foo.getStorePassword ( ) ) ; assertEquals ( debug.getKeyAlias ( ) , foo.getKeyAlias ( ) ) ; assertEquals ( debug.getKeyPassword ( ) , foo.getKeyPassword ( ) ) ; }
Source:
private boolean endDataPathLocal ( short transactionId , int ndpId ) { if ( com.android.server.wifi.aware.WifiAwareStateManager.VDBG ) { android.util.Log.v ( com.android.server.wifi.aware.WifiAwareStateManager.TAG , ( ( ( "endDataPathLocal: transactionId=" + transactionId ) + ", ndpId=" ) + ndpId ) ) ; } return com.android.server.wifi.aware.WifiAwareNative.getInstance ( ) . endDataPath ( transactionId , ndpId ) ; }

Target:
private boolean endDataPathLocal ( short transactionId , int ndpId ) { if ( com.android.server.wifi.aware.WifiAwareStateManager.VDBG ) { android.util.Log.v ( com.android.server.wifi.aware.WifiAwareStateManager.TAG , ( ( ( "endDataPathLocal: transactionId=" + transactionId ) + ", ndpId=" ) + ndpId ) ) ; } return mWifiAwareNative.endDataPath ( transactionId , ndpId ) ; }
Source:
public final double getDouble ( ) { int newPosition = ( position ) + ( libcore.io.SizeOf.DOUBLE ) ; if ( newPosition > ( limit ) ) { throw new java.nio.BufferUnderflowException ( ) ; } double result = java.lang.Double.longBitsToDouble ( this . block.peekLong ( ( ( offset ) + ( position ) ) , order ) ) ; position = newPosition ; return result ; }

Target:
public final double getDouble ( ) { checkNotFreed ( ) ; int newPosition = ( position ) + ( libcore.io.SizeOf.DOUBLE ) ; if ( newPosition > ( limit ) ) { throw new java.nio.BufferUnderflowException ( ) ; } double result = java.lang.Double.longBitsToDouble ( this . block.peekLong ( ( ( offset ) + ( position ) ) , order ) ) ; position = newPosition ; return result ; }
Source:
public void testAbiOnlyWithUniversalMatch ( ) { com.android.build.SplitOutput match ; java.util.List < com.android.build.SplitOutput > list = com.google.common.collect.Lists.newArrayList ( ) ; list.add ( ( match = com.android.ide.common.build.SplitOutputMatcherTest.getUniversalOutput ( ) ) ) ; list.add ( com.android.ide.common.build.SplitOutputMatcherTest.getAbiOutput ( "foo" ) ) ; list.add ( com.android.ide.common.build.SplitOutputMatcherTest.getAbiOutput ( "bar" ) ) ; com.android.build.SplitOutput result = com.android.ide.common.build.SplitOutputMatcherTest.computeBestOutput ( list , 160 , "zzz" ) ; assertEquals ( match , result ) ; }

Target:
public void testAbiOnlyWithMatch ( ) { com.android.build.SplitOutput match ; java.util.List < com.android.build.SplitOutput > list = com.google.common.collect.Lists.newArrayList ( ) ; list.add ( com.android.ide.common.build.SplitOutputMatcherTest.getUniversalOutput ( 1 ) ) ; list.add ( ( match = com.android.ide.common.build.SplitOutputMatcherTest.getAbiOutput ( "foo" , 2 ) ) ) ; list.add ( com.android.ide.common.build.SplitOutputMatcherTest.getAbiOutput ( "bar" , 3 ) ) ; com.android.build.SplitOutput result = com.android.ide.common.build.SplitOutputMatcherTest.computeBestOutput ( list , 160 , "foo" ) ; assertEquals ( match , result ) ; }
Source:
public boolean processMessage ( android.os.Message message ) { if ( com.android.server.wifi.p2p.WifiP2pServiceImpl.DBG ) logd ( ( ( getName ( ) ) + ( message.toString ( ) ) ) ) ; switch ( message.what ) { case com.android.server.wifi.WifiMonitor.SUP_CONNECTION_EVENT : if ( com.android.server.wifi.p2p.WifiP2pServiceImpl.DBG ) logd ( "P2p socket connection successful" ) ; transitionTo ( mInactiveState ) ; break ; case com.android.server.wifi.WifiMonitor.SUP_DISCONNECTION_EVENT : loge ( "P2p socket connection failed" ) ; transitionTo ( mP2pDisabledState ) ; break ; case com.android.server.wifi.WifiStateMachine.CMD_ENABLE_P2P : case com.android.server.wifi.WifiStateMachine.CMD_DISABLE_P2P_REQ : deferMessage ( message ) ; break ; default : return NOT_HANDLED ; } return HANDLED ; }

Target:
public boolean processMessage ( android.os.Message message ) { if ( com.android.server.wifi.p2p.WifiP2pServiceImpl.DBG ) logd ( ( ( getName ( ) ) + ( message.toString ( ) ) ) ) ; switch ( message.what ) { case WifiP2pMonitor.SUP_CONNECTION_EVENT : if ( com.android.server.wifi.p2p.WifiP2pServiceImpl.DBG ) logd ( "P2p socket connection successful" ) ; transitionTo ( mInactiveState ) ; break ; case WifiP2pMonitor.SUP_DISCONNECTION_EVENT : loge ( "P2p socket connection failed" ) ; transitionTo ( mP2pDisabledState ) ; break ; case com.android.server.wifi.WifiStateMachine.CMD_ENABLE_P2P : case com.android.server.wifi.WifiStateMachine.CMD_DISABLE_P2P_REQ : deferMessage ( message ) ; break ; default : return NOT_HANDLED ; } return HANDLED ; }
Source:
private java.lang.String sanitizePaths ( java.lang.String str ) { if ( str != null ) { java.lang.String osPath = getSdkManager ( ) . getLocation ( ) ; str = str.replace ( osPath , "@SDK" ) ; try { osPath = getAvdManager ( ) . getBaseAvdFolder ( ) ; str = str.replace ( osPath , "@AVD" ) ; } catch ( com.android.prefs.AndroidLocation.AndroidLocationException ignore ) { } } return str ; }

Target:
private java.lang.String sanitizePaths ( java.lang.String str ) { if ( str != null ) { java.lang.String osPath = getSdkManager ( ) . getLocation ( ) ; str = str.replace ( osPath , "@SDK" ) ; try { osPath = getAvdManager ( ) . getBaseAvdFolder ( ) ; str = str.replace ( osPath , "@AVD" ) ; } catch ( com.android.prefs.AndroidLocation.AndroidLocationException ignore ) { } str = str.replace ( java.io.File.separatorChar , '/' ) ; } return str ; }
Source:
private void postMessage ( int messageCode ) { synchronized ( this ) { if ( ( mHandler ) == null ) { mHandler = getNewHandler ( ) ; } if ( ( mHandler ) == null ) { android.telecom.Log.d ( this , "Message %d skipped because there is no handler." , messageCode ) ; } else { mHandler.obtainMessage ( messageCode , null ) . sendToTarget ( ) ; } } }

Target:
public void startTone ( int toneType , int durationMs ) { if ( ( mToneGenerator ) != null ) { mToneGenerator.startTone ( toneType , durationMs ) ; } }
Source:
public void testGetEncodedContentsReturnsSlice ( ) { java.nio.ByteBuffer encoded = com.android.apksig.internal.asn1.ber.BerDataValueTest.TEST_VALUE1.getEncodedContents ( ) ; com.android.apksig.internal.test.MoreAsserts.assertByteBufferEquals ( com.android.apksig.internal.test.HexEncoding.decode ( "bb" ) , encoded ) ; encoded.position ( encoded.limit ( ) ) ; com.android.apksig.internal.test.MoreAsserts.assertByteBufferEquals ( com.android.apksig.internal.test.HexEncoding.decode ( "bb" ) , com.android.apksig.internal.asn1.ber.BerDataValueTest.TEST_VALUE1.getEncodedContents ( ) ) ; }

Target:
public void testGetEncodedContentsReturnsSlice ( ) { java.nio.ByteBuffer encoded = com.android.apksig.internal.asn1.ber.BerDataValueTest.TEST_VALUE1.getEncodedContents ( ) ; com.android.apksig.internal.test.MoreAsserts.assertByteBufferEquals ( com.android.apksig.internal.util.HexEncoding.decode ( "bb" ) , encoded ) ; encoded.position ( encoded.limit ( ) ) ; com.android.apksig.internal.test.MoreAsserts.assertByteBufferEquals ( com.android.apksig.internal.util.HexEncoding.decode ( "bb" ) , com.android.apksig.internal.asn1.ber.BerDataValueTest.TEST_VALUE1.getEncodedContents ( ) ) ; }
Source:
public void terminate ( ) { android.net.wifi.nan.WifiNanManager mgr = mMgr.get ( ) ; if ( mgr == null ) { android.util.Log.w ( android.net.wifi.nan.WifiNanDiscoveryBaseSession.TAG , "terminate: called post GC on WifiNanManager" ) ; return ; } mgr.terminateSession ( mSessionId ) ; mTerminated = true ; mMgr.clear ( ) ; mCloseGuard.close ( ) ; }

Target:
public void terminate ( ) { android.net.wifi.nan.WifiNanManager mgr = mMgr.get ( ) ; if ( mgr == null ) { android.util.Log.w ( android.net.wifi.nan.WifiNanDiscoveryBaseSession.TAG , "terminate: called post GC on WifiNanManager" ) ; return ; } mgr.terminateSession ( mClientId , mSessionId ) ; mTerminated = true ; mMgr.clear ( ) ; mCloseGuard.close ( ) ; }
Source:
public com.android.jack.dx.io.instructions.DecodedInstruction decode ( int opcodeUnit , com.android.jack.dx.io.instructions.CodeInput in ) throws java.io.EOFException { int opcode = com.android.jack.dx.io.instructions.InstructionCodec.byte0 ( opcodeUnit ) ; int a = com.android.jack.dx.io.instructions.InstructionCodec.byte1 ( opcodeUnit ) ; int literal = ( ( short ) ( in.read ( ) ) ) ; return new com.android.jack.dx.io.instructions.OneRegisterDecodedInstruction ( this , opcode , 0 , null , 0 , literal , a ) ; }

Target:
public com.android.jack.dx.io.instructions.DecodedInstruction decode ( int opcodeUnit , com.android.jack.dx.io.instructions.CodeInput in ) throws java.io.EOFException { int opcode = com.android.jack.dx.io.instructions.InstructionCodec.byte0 ( opcodeUnit ) ; int a = com.android.jack.dx.io.instructions.InstructionCodec.byte1 ( opcodeUnit ) ; int literal = ( ( short ) ( in.read ( ) ) ) ; return new com.android.jack.dx.io.instructions.OneRegisterDecodedInstruction ( this , opcode , 0 , com.android.jack.dx.io.IndexType.NONE , 0 , literal , a ) ; }
Source:
private void waitUserConfirmation ( ) { mPbapStateMachine.sendMessage ( PbapStateMachine.CREATE_NOTIFICATION ) ; mPbapStateMachine.sendMessageDelayed ( PbapStateMachine.REMOVE_NOTIFICATION , BluetoothPbapService.USER_CONFIRM_TIMEOUT_VALUE ) ; synchronized ( this ) { while ( ( ! ( mChallenged ) ) && ( ! ( mAuthCancelled ) ) ) { try { wait ( ) ; } catch ( java.lang.InterruptedException e ) { android.util.Log.e ( com.android.bluetooth.pbap.BluetoothPbapAuthenticator.TAG , "Interrupted while waiting on isChalled" ) ; } } } }

Target:
private void waitUserConfirmation ( ) { mPbapStateMachine.sendMessage ( PbapStateMachine.CREATE_NOTIFICATION ) ; mPbapStateMachine.sendMessageDelayed ( PbapStateMachine.REMOVE_NOTIFICATION , BluetoothPbapService.USER_CONFIRM_TIMEOUT_VALUE ) ; synchronized ( this ) { while ( ( ! ( mChallenged ) ) && ( ! ( mAuthCancelled ) ) ) { try { wait ( ) ; } catch ( java.lang.InterruptedException e ) { android.util.Log.e ( com.android.bluetooth.pbap.BluetoothPbapAuthenticator.TAG , "Interrupted while waiting on isChallenged or AuthCancelled" ) ; } } } }
Source:
public java.nio.charset.Charset charsetForName ( java.lang.String charsetName ) { if ( ( ( "MockCharset00" . equalsIgnoreCase ( charsetName ) ) || ( "MockCharset01" . equalsIgnoreCase ( charsetName ) ) ) || ( "MockCharset02" . equalsIgnoreCase ( charsetName ) ) ) { return tests.api.java.nio.charset.CharsetTest.charset1 ; } else if ( ( ( "MockCharset10" . equalsIgnoreCase ( charsetName ) ) || ( "MockCharset11" . equalsIgnoreCase ( charsetName ) ) ) || ( "MockCharset12" . equalsIgnoreCase ( charsetName ) ) ) { return tests.api.java.nio.charset.CharsetTest.charset2 ; } return null ; }

Target:
public java.nio.charset.Charset charsetForName ( java.lang.String charsetName ) { if ( ( ( "MockCharset00" . equalsIgnoreCase ( charsetName ) ) || ( "MockCharset01" . equalsIgnoreCase ( charsetName ) ) ) || ( "MockCharset02" . equalsIgnoreCase ( charsetName ) ) ) { return org.apache.harmony.tests.java.nio.charset.CharsetTest.charset1 ; } else if ( ( ( "MockCharset10" . equalsIgnoreCase ( charsetName ) ) || ( "MockCharset11" . equalsIgnoreCase ( charsetName ) ) ) || ( "MockCharset12" . equalsIgnoreCase ( charsetName ) ) ) { return org.apache.harmony.tests.java.nio.charset.CharsetTest.charset2 ; } return null ; }
Source:
private static dalvik.system.DexFile loadDexFile ( java.io.File file , java.io.File optimizedDirectory ) throws java.io.IOException { if ( optimizedDirectory == null ) { return new dalvik.system.DexFile ( file ) ; } else { java.lang.String optimizedPath = dalvik.system.DexPathList.optimizedPathFor ( file , optimizedDirectory ) ; return dalvik.system.DexFile.loadDex ( file.getPath ( ) , optimizedPath , 0 ) ; } }

Target:
private static dalvik.system.DexFile loadDexFile ( java.io.File file , java.io.File optimizedDirectory , java.lang.ClassLoader loader ) throws java.io.IOException { if ( optimizedDirectory == null ) { return new dalvik.system.DexFile ( file , loader ) ; } else { java.lang.String optimizedPath = dalvik.system.DexPathList.optimizedPathFor ( file , optimizedDirectory ) ; return dalvik.system.DexFile.loadDex ( file.getPath ( ) , optimizedPath , 0 , loader ) ; } }
Source:
public int beforeHandshake ( int context ) throws javax.net.ssl.SSLException { int s = org.apache.harmony.xnet.provider.jsse.NativeCrypto.SSL_new ( context ) ; org.apache.harmony.xnet.provider.jsse.NativeCrypto.SSL_set_cipher_lists ( s , new java.lang.String [ ] { "RC4-MD5" } ) ; return s ; }

Target:
public int beforeHandshake ( int context ) throws javax.net.ssl.SSLException { int s = org.apache.harmony.xnet.provider.jsse.NativeCrypto.SSL_new ( context ) ; org.apache.harmony.xnet.provider.jsse.NativeCrypto.SSL_set_cipher_lists ( s , new java.lang.String [ ] { "RC4-MD5" } ) ; if ( ( channelIdPrivateKey ) != null ) { org.apache.harmony.xnet.provider.jsse.NativeCrypto.SSL_set1_tls_channel_id ( s , channelIdPrivateKey ) ; } return s ; }
Source:
protected void engineSetMode ( java.lang.String mode ) throws java.security.NoSuchAlgorithmException { final java.lang.String modeUpper = mode.toUpperCase ( ) ; if ( ( "NONE" . equals ( modeUpper ) ) || ( "ECB" . equals ( modeUpper ) ) ) { return ; } throw new java.security.NoSuchAlgorithmException ( ( "mode not supported: " + mode ) ) ; }

Target:
protected void engineSetMode ( java.lang.String mode ) throws java.security.NoSuchAlgorithmException { final java.lang.String modeUpper = mode.toUpperCase ( java.util.Locale.ROOT ) ; if ( ( "NONE" . equals ( modeUpper ) ) || ( "ECB" . equals ( modeUpper ) ) ) { return ; } throw new java.security.NoSuchAlgorithmException ( ( "mode not supported: " + mode ) ) ; }