auphong2707/dl4se-code-review-dataset huggingface dataset:
Source:
public static com.google.gct.testing.results.GoogleCloudTestingConsoleView createConsoleWithCustomLocator ( @ org.jetbrains.annotations.NotNull final java.lang.String testFrameworkName , @ org.jetbrains.annotations.NotNull final com.intellij.execution.testframework.TestConsoleProperties consoleProperties , com.intellij.execution.runners.ExecutionEnvironment environment , @ org.jetbrains.annotations.Nullable final com.intellij.testIntegration.TestLocationProvider locator , final boolean idBasedTreeConstruction , @ org.jetbrains.annotations.Nullable final com.intellij.execution.testframework.sm.runner.TestProxyFilterProvider filterProvider ) { java.lang.String splitterPropertyName = com.google.gct.testing.results.GoogleCloudTestResultsConnectionUtil.getSplitterPropertyName ( testFrameworkName ) ; com.google.gct.testing.results.GoogleCloudTestingConsoleView consoleView = new com.google.gct.testing.results.GoogleCloudTestingConsoleView ( consoleProperties , environment , splitterPropertyName ) ; com.google.gct.testing.results.GoogleCloudTestResultsConnectionUtil.initConsoleView ( consoleView , testFrameworkName , locator , idBasedTreeConstruction , filterProvider ) ; return consoleView ; }

Target:
public static com.google.gct.testing.results.GoogleCloudTestingConsoleView createConsoleWithCustomLocator ( @ org.jetbrains.annotations.NotNull final java.lang.String testFrameworkName , @ org.jetbrains.annotations.NotNull final com.intellij.execution.testframework.TestConsoleProperties consoleProperties , com.intellij.execution.runners.ExecutionEnvironment environment , @ org.jetbrains.annotations.Nullable final com.intellij.testIntegration.TestLocationProvider locator , final boolean idBasedTreeConstruction , @ org.jetbrains.annotations.Nullable final com.intellij.execution.testframework.sm.runner.TestProxyFilterProvider filterProvider , @ org.jetbrains.annotations.NotNull final com.google.gct.testing.CloudMatrixExecutionCancellator matrixExecutionCancellator ) { java.lang.String splitterPropertyName = com.google.gct.testing.results.GoogleCloudTestResultsConnectionUtil.getSplitterPropertyName ( testFrameworkName ) ; com.google.gct.testing.results.GoogleCloudTestingConsoleView consoleView = new com.google.gct.testing.results.GoogleCloudTestingConsoleView ( consoleProperties , environment , splitterPropertyName ) ; com.google.gct.testing.results.GoogleCloudTestResultsConnectionUtil.initConsoleView ( consoleView , testFrameworkName , locator , idBasedTreeConstruction , filterProvider , matrixExecutionCancellator ) ; return consoleView ; }
Source:
private javax.swing.JComponent buildMainPanel ( ) { mainPanel = new javax.swing.JPanel ( ) ; mainPanel.setLayout ( new java.awt.BorderLayout ( ) ) ; mainPanel.add ( buildToolBar ( ) , java.awt.BorderLayout.PAGE_START ) ; mainPanel.add ( ( deviceSelector = buildDeviceSelector ( ) ) , java.awt.BorderLayout.CENTER ) ; mainPanel.add ( buildStatusPanel ( ) , java.awt.BorderLayout.SOUTH ) ; mainPanel.setPreferredSize ( new java.awt.Dimension ( 950 , 800 ) ) ; return mainPanel ; }

Target:
private javax.swing.JComponent buildMainPanel ( ) { mainPanel = new javax.swing.JPanel ( ) ; mainPanel.setLayout ( new java.awt.BorderLayout ( ) ) ; commandButtonsPanel = buildToolBar ( ) ; mainPanel.add ( commandButtonsPanel , java.awt.BorderLayout.PAGE_START ) ; mainPanel.add ( ( deviceSelector = buildDeviceSelector ( ) ) , java.awt.BorderLayout.CENTER ) ; mainPanel.add ( buildStatusPanel ( ) , java.awt.BorderLayout.SOUTH ) ; mainPanel.setPreferredSize ( new java.awt.Dimension ( 1200 , 800 ) ) ; return mainPanel ; }
Source:
private java.io.File getFullPath ( @ com.android.annotations.NonNull java.lang.String fromPath ) { if ( fromPath.startsWith ( com.android.ide.eclipse.adt.internal.wizards.templates.TemplateHandler.VALUE_TEMPLATE_DIR ) ) { return new java.io.File ( com.android.ide.eclipse.adt.internal.wizards.templates.TemplateHandler.getTemplateRootFolder ( ) , ( ( ( com.android.ide.eclipse.adt.internal.wizards.templates.TemplateHandler.RESOURCE_ROOT ) + ( java.io.File.separator ) ) + ( fromPath.substring ( ( ( com.android.ide.eclipse.adt.internal.wizards.templates.TemplateHandler.VALUE_TEMPLATE_DIR.length ( ) ) + 1 ) ) . replace ( '/' , java.io.File.separatorChar ) ) ) ) ; } return new java.io.File ( mRootPath , ( ( ( com.android.ide.eclipse.adt.internal.wizards.templates.TemplateHandler.DATA_ROOT ) + ( java.io.File.separator ) ) + fromPath ) ) ; }

Target:
private java.io.File getFullPath ( @ com.android.annotations.NonNull java.lang.String fromPath ) { if ( fromPath.startsWith ( com.android.ide.eclipse.adt.internal.wizards.templates.TemplateHandler.VALUE_TEMPLATE_DIR ) ) { return new java.io.File ( com.android.ide.eclipse.adt.internal.wizards.templates.TemplateManager.getTemplateRootFolder ( ) , ( ( ( com.android.ide.eclipse.adt.internal.wizards.templates.TemplateHandler.RESOURCE_ROOT ) + ( java.io.File.separator ) ) + ( fromPath.substring ( ( ( com.android.ide.eclipse.adt.internal.wizards.templates.TemplateHandler.VALUE_TEMPLATE_DIR.length ( ) ) + 1 ) ) . replace ( '/' , java.io.File.separatorChar ) ) ) ) ; } return new java.io.File ( mRootPath , ( ( ( com.android.ide.eclipse.adt.internal.wizards.templates.TemplateHandler.DATA_ROOT ) + ( java.io.File.separator ) ) + fromPath ) ) ; }
Source:
public java.util.Map < java.lang.String , java.lang.String > getNetworkExtra ( int netId , java.lang.String name ) { final java.lang.String extraString = getNetworkVariable ( netId , name ) ; return com.android.server.wifi.WifiNative.parseNetworkExtra ( extraString ) ; }

Target:
public java.util.Map < java.lang.String , java.lang.String > getNetworkExtra ( int netId , java.lang.String name ) { final java.lang.String extraString = getNetworkVariable ( netId , name ) ; if ( ( ( extraString == null ) || ( ! ( extraString.startsWith ( "\"" ) ) ) ) || ( ! ( extraString.endsWith ( "\"" ) ) ) ) { return null ; } return com.android.server.wifi.WifiNative.parseNetworkExtra ( com.android.server.wifi.util.NativeUtil.removeEnclosingQuotes ( extraString ) ) ; }
Source:
private android.app.PendingIntent createIncomingCallPendingIntent ( ) { android.content.Intent intent = new android.content.Intent ( com.android.ims.ImsManager.ACTION_IMS_INCOMING_CALL ) ; intent.addFlags ( Intent.FLAG_RECEIVER_FOREGROUND ) ; return android.app.PendingIntent.getBroadcast ( mPhone.getContext ( ) , 0 , intent , PendingIntent.FLAG_UPDATE_CURRENT ) ; }

Target:
private void sendConfigChangedIntent ( int item , java.lang.String value ) { log ( ( ( ( ( "sendConfigChangedIntent - [" + item ) + ", " ) + value ) + "]" ) ) ; android.content.Intent configChangedIntent = new android.content.Intent ( com.android.ims.ImsConfig.ACTION_IMS_CONFIG_CHANGED ) ; configChangedIntent.putExtra ( ImsConfig.EXTRA_CHANGED_ITEM , item ) ; configChangedIntent.putExtra ( ImsConfig.EXTRA_NEW_VALUE , value ) ; if ( ( ( mPhone ) != null ) && ( ( mPhone.getContext ( ) ) != null ) ) { mPhone.getContext ( ) . sendBroadcast ( configChangedIntent ) ; } }
Source:
public void nonExpiredCacheHit ( ) throws java.lang.Exception { com.android.volley.Cache.Entry entry = com.android.volley.utils.CacheTestUtils.makeRandomCacheEntry ( null , false , false ) ; mCache.setEntryToReturn ( entry ) ; mCacheQueue.add ( mRequest ) ; mCacheQueue.waitUntilEmpty ( com.android.volley.CacheDispatcherTest.TIMEOUT_MILLIS ) ; assertTrue ( mDelivery.postResponse_called ) ; assertFalse ( mDelivery.postError_called ) ; }

Target:
public void cancelledRequest ( ) throws java.lang.Exception { mRequest.cancel ( ) ; mDispatcher.processRequest ( mRequest ) ; org.mockito.Mockito.verify ( mCache , org.mockito.Mockito.never ( ) ) . get ( org.mockito.Matchers.anyString ( ) ) ; com.android.volley.CacheDispatcherTest.verifyNoResponse ( mDelivery ) ; }
Source:
protected java.lang.String lintFiles ( java.lang.String ... relativePaths ) throws java.lang.Exception { java.util.List < java.io.File > files = new java.util.ArrayList < java.io.File > ( ) ; for ( java.lang.String relativePath : relativePaths ) { java.io.File file = getTestfile ( relativePath ) ; assertNotNull ( file ) ; files.add ( file ) ; } addManifestFile ( getTargetDir ( ) ) ; return checkLint ( files ) ; }

Target:
private java.io.File makeTestFile ( java.lang.String name , java.lang.String relative , final java.io.InputStream contents ) throws java.io.IOException { return makeTestFile ( getTargetDir ( ) , name , relative , contents ) ; }
Source:
public void testDisplayEmptyAvdList ( ) { com.android.sdkmanager.Main main = new com.android.sdkmanager.Main ( ) ; main.setLogger ( getLog ( ) ) ; getLog ( ) . clear ( ) ; main.displayAvdList ( getAvdManager ( ) ) ; assertEquals ( "[P Available Android Virtual Devices:\n]" , getLog ( ) . toString ( ) ) ; }

Target:
public void testDisplayEmptyAvdList ( ) { com.android.sdkmanager.Main main = new com.android.sdkmanager.Main ( ) ; main.setLogger ( getLog ( ) ) ; getLog ( ) . clear ( ) ; main.displayAvdList ( getAvdManager ( ) ) ; assertEquals ( "P Available Android Virtual Devices:\n" , getLog ( ) . toString ( ) ) ; }
Source:
public com.google.common.collect.ImmutableMultimap < java.lang.Integer , com.android.manifmerger.Actions.Record > getResultingSourceMapping ( com.android.manifmerger.XmlDocument xmlDocument ) throws java.io.IOException , javax.xml.parsers.ParserConfigurationException , org.xml.sax.SAXException { com.android.manifmerger.XmlLoader.SourceLocation inMemory = XmlLoader.UNKNOWN ; com.android.manifmerger.XmlDocument loadedWithLineNumbers = com.android.manifmerger.XmlLoader.load ( inMemory , xmlDocument.prettyPrint ( ) ) ; com.google.common.collect.ImmutableMultimap.Builder < java.lang.Integer , com.android.manifmerger.Actions.Record > mappingBuilder = com.google.common.collect.ImmutableMultimap.builder ( ) ; for ( com.android.manifmerger.XmlElement xmlElement : loadedWithLineNumbers.getRootNode ( ) . getMergeableElements ( ) ) { parse ( xmlElement , mappingBuilder ) ; } return mappingBuilder.build ( ) ; }

Target:
public com.google.common.collect.ImmutableMultimap < java.lang.Integer , com.android.manifmerger.Actions.Record > getResultingSourceMapping ( com.android.manifmerger.XmlDocument xmlDocument ) throws java.io.IOException , javax.xml.parsers.ParserConfigurationException , org.xml.sax.SAXException { com.android.manifmerger.XmlLoader.SourceLocation inMemory = XmlLoader.UNKNOWN ; com.android.manifmerger.XmlDocument loadedWithLineNumbers = com.android.manifmerger.XmlLoader.load ( xmlDocument.getSelectors ( ) , inMemory , xmlDocument.prettyPrint ( ) ) ; com.google.common.collect.ImmutableMultimap.Builder < java.lang.Integer , com.android.manifmerger.Actions.Record > mappingBuilder = com.google.common.collect.ImmutableMultimap.builder ( ) ; for ( com.android.manifmerger.XmlElement xmlElement : loadedWithLineNumbers.getRootNode ( ) . getMergeableElements ( ) ) { parse ( xmlElement , mappingBuilder ) ; } return mappingBuilder.build ( ) ; }
Source:
private static com.google.doclava.ParamTagInfo convertParamTag ( com.google.doclava.ParamTag tag , com.google.doclava.ContainerInfo base ) { return new com.google.doclava.ParamTagInfo ( tag.name ( ) , tag.kind ( ) , tag.text ( ) , tag.isTypeParameter ( ) , tag.parameterComment ( ) , tag.parameterName ( ) , base , com.google.doclava.Converter.convertSourcePosition ( tag.position ( ) ) ) ; }

Target:
private static com.google.doclava.ThrowsTagInfo convertThrowsTag ( com.sun.javadoc.ThrowsTag tag , com.google.doclava.ContainerInfo base ) { return new com.google.doclava.ThrowsTagInfo ( tag.name ( ) , tag.text ( ) , tag.kind ( ) , com.google.doclava.Converter.obtainClass ( tag.exception ( ) ) , tag.exceptionComment ( ) , base , com.google.doclava.Converter.convertSourcePosition ( tag.position ( ) ) ) ; }
Source:
public void touch ( org.python.core.PyObject [ ] args , java.lang.String [ ] kws ) { org.python.core.ArgParser ap = com.android.monkeyrunner.JythonUtils.createArgParser ( args , kws ) ; com.google.common.base.Preconditions.checkNotNull ( ap ) ; com.android.monkeyrunner.easy.By selector = getSelector ( ap , 0 ) ; java.lang.String tmpType = ap.getString ( 1 ) ; com.android.monkeyrunner.core.IMonkeyDevice.TouchPressType type = MonkeyDevice.TOUCH_NAME_TO_ENUM.get ( tmpType ) ; if ( type == null ) type = com.android.monkeyrunner.core.IMonkeyDevice.TouchPressType.DOWN_AND_UP ; touch ( selector , type ) ; }

Target:
public void touch ( org.python.core.PyObject [ ] args , java.lang.String [ ] kws ) { org.python.core.ArgParser ap = com.android.monkeyrunner.JythonUtils.createArgParser ( args , kws ) ; com.google.common.base.Preconditions.checkNotNull ( ap ) ; com.android.monkeyrunner.easy.By selector = getSelector ( ap , 0 ) ; java.lang.String tmpType = ap.getString ( 1 ) ; com.android.monkeyrunner.core.TouchPressType type = com.android.monkeyrunner.core.TouchPressType.fromIdentifier ( tmpType ) ; com.google.common.base.Preconditions.checkNotNull ( type , ( "Invalid touch type: " + tmpType ) ) ; touch ( selector , type ) ; }
Source:
private static org.eclipse.ltk.core.refactoring.TextFileChange createTextChange ( org.eclipse.core.resources.IFile targetFile ) { java.lang.String fileName = targetFile.getName ( ) ; java.lang.String message ; if ( targetFile.exists ( ) ) { message = java.lang.String.format ( "Replace %1$s" , fileName ) ; } else { message = java.lang.String.format ( "Create %1$s" , fileName ) ; } org.eclipse.ltk.core.refactoring.TextFileChange change = new org.eclipse.ltk.core.refactoring.TextFileChange ( message , targetFile ) ; change.setTextType ( fileName.substring ( ( ( fileName.lastIndexOf ( '.' ) ) + 1 ) ) ) ; return change ; }

Target:
protected org.eclipse.jface.text.IDocument acquireDocument ( org.eclipse.core.runtime.IProgressMonitor pm ) throws org.eclipse.core.runtime.CoreException { org.eclipse.jface.text.IDocument document = super . acquireDocument ( pm ) ; if ( ( document.getLength ( ) ) > 0 ) { try { document.replace ( 0 , document.getLength ( ) , "" ) ; } catch ( org.eclipse.jface.text.BadLocationException e ) { } } return document ; }
Source:
public void testVFE15 ( ) { try { java.lang.Class.forName ( "dot.junit.opcodes.invoke_direct_range.d.T_invoke_direct_range_11" ) ; fail ( "expected a verification exception" ) ; } catch ( java.lang.Throwable t ) { dot.junit.DxUtil.checkVerifyException ( t ) ; } }

Target:
public void testVFE15 ( ) { try { java.lang.Class < ? > c = java.lang.Class.forName ( "dot.junit.opcodes.invoke_direct_range.d.T_invoke_direct_range_11" ) ; java.lang.Object o = c.newInstance ( ) ; java.lang.reflect.Method m = c.getDeclaredMethod ( "run" ) ; m.invoke ( o ) ; fail ( "expected an invocation target exception with an incompatible class change error" ) ; } catch ( java.lang.reflect.InvocationTargetException ite ) { if ( ! ( ( ite.getCause ( ) ) instanceof java.lang.IncompatibleClassChangeError ) ) { fail ( "expected an incompatible class change error" ) ; } } catch ( java.lang.Throwable t ) { throw new java.lang.RuntimeException ( t ) ; } }
Source:
public boolean setPermissionGrantState ( @ android.annotation.NonNull android.content.ComponentName admin , java.lang.String packageName , java.lang.String permission , int grantState ) { throwIfParentInstance ( "setPermissionGrantState" ) ; try { return mService.setPermissionGrantState ( admin , packageName , permission , grantState ) ; } catch ( android.os.RemoteException re ) { throw re.rethrowFromSystemServer ( ) ; } }

Target:
public boolean setPermissionGrantState ( @ android.annotation.NonNull android.content.ComponentName admin , java.lang.String packageName , java.lang.String permission , int grantState ) { throwIfParentInstance ( "setPermissionGrantState" ) ; try { return mService.setPermissionGrantState ( admin , mContext.getPackageName ( ) , packageName , permission , grantState ) ; } catch ( android.os.RemoteException re ) { throw re.rethrowFromSystemServer ( ) ; } }
Source:
public static java.util.List < com.google.gct.idea.appengine.wizard.AppEngineTemplates.TemplateInfo > getLocalTemplates ( ) { com.google.gct.idea.appengine.wizard.AppEngineTemplates.LOG.info ( "Populating built-in App Engine templates..." ) ; java.io.File jarPath = new java.io.File ( com.intellij.util.PathUtil.getJarPathForClass ( com.google.gct.idea.appengine.wizard.AppEngineTemplates.class ) ) ; if ( jarPath.isFile ( ) ) { jarPath = jarPath.getParentFile ( ) ; } java.io.File root = new java.io.File ( jarPath , com.google.gct.idea.appengine.wizard.AppEngineTemplates.TEMPLATES_DIR ) ; if ( ! ( root.exists ( ) ) ) { com.google.gct.idea.appengine.wizard.AppEngineTemplates.LOG.error ( "Failed to find templates directory, perhaps your cloud tools plugin is corrupt?" ) ; } return com.google.gct.idea.appengine.wizard.AppEngineTemplates.populateTemplates ( root ) ; }

Target:
public static java.util.List < com.google.gct.idea.appengine.wizard.AppEngineTemplates.TemplateInfo > getAppEngineTemplates ( java.util.List < java.lang.String > templateDirectories ) { java.io.File root = com.google.gct.idea.appengine.wizard.AppEngineTemplates.findTemplatesDirInPluginJar ( com.google.gct.idea.appengine.wizard.AppEngineTemplates.TEMPLATES_DIR ) ; return com.google.gct.idea.appengine.wizard.AppEngineTemplates.populateAppEngineTemplates ( root , templateDirectories ) ; }
Source:
public void clear ( java.lang.String timezone ) { if ( timezone == null ) { throw new java.lang.NullPointerException ( "timezone is null!" ) ; } this . timezone = timezone ; this . allDay = false ; this . second = 0 ; this . minute = 0 ; this . hour = 0 ; this . monthDay = 0 ; this . month = 0 ; this . year = 0 ; this . weekDay = 0 ; this . yearDay = 0 ; this . gmtoff = 0 ; this . isDst = - 1 ; }

Target:
public void clear ( java.lang.String timezoneId ) { if ( timezoneId == null ) { throw new java.lang.NullPointerException ( "timezone is null!" ) ; } this . timezone = timezoneId ; this . allDay = false ; this . second = 0 ; this . minute = 0 ; this . hour = 0 ; this . monthDay = 0 ; this . month = 0 ; this . year = 0 ; this . weekDay = 0 ; this . yearDay = 0 ; this . gmtoff = 0 ; this . isDst = - 1 ; }
Source:
private java.util.concurrent.ConcurrentSkipListMap.Node < K , V > loNode ( ) { if ( ( lo ) == null ) return m.findFirst ( ) ; else if ( loInclusive ) return m.findNear ( lo , ( ( m.GT ) | ( m.EQ ) ) ) ; else return m.findNear ( lo , m.GT ) ; }

Target:
private java.util.concurrent.ConcurrentSkipListMap.Node < K , V > loNode ( ) { if ( ( lo ) == null ) return m.findFirst ( ) ; else if ( loInclusive ) return m.findNear ( lo , ( ( java.util.concurrent.ConcurrentSkipListMap.GT ) | ( java.util.concurrent.ConcurrentSkipListMap.EQ ) ) ) ; else return m.findNear ( lo , java.util.concurrent.ConcurrentSkipListMap.GT ) ; }
Source:
public void testLaunchToSideAndBringToFront ( ) throws java.lang.Exception { launchActivityInDockStack ( android.server.cts.LAUNCHING_ACTIVITY ) ; final java.lang.String [ ] waitForFirstVisible = new java.lang.String [ ] { android.server.cts.ActivityManagerDockedStackTests.TEST_ACTIVITY_NAME } ; final java.lang.String [ ] waitForSecondVisible = new java.lang.String [ ] { android.server.cts.ActivityManagerDockedStackTests.NO_RELAUNCH_ACTIVITY_NAME } ; HEAD ( ( ( android.server.cts.n ) ( mAmWmState.computeState ) ) ) ; }

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:
protected com.intellij.updater.ValidationResult doValidate ( java.io.File toFile ) { com.intellij.updater.ValidationResult result = doValidateAccess ( toFile , ValidationResult.Action.CREATE ) ; if ( result != null ) return result ; if ( toFile.exists ( ) ) { com.intellij.updater.ValidationResult [ ] options = ( myPatch.isStrict ( ) ) ? new com.intellij.updater.ValidationResult.Option [ ] { ValidationResult.Option.REPLACE } : new com.intellij.updater.ValidationResult.Option [ ] { ValidationResult.Option.REPLACE , ValidationResult.Option.KEEP } ; return new com.intellij.updater.ValidationResult ( ValidationResult.Kind.CONFLICT , myPath , ValidationResult.Action.CREATE , ValidationResult.ALREADY_EXISTS_MESSAGE , options ) ; } return null ; }

Target:
public com.intellij.updater.ValidationResult validate ( java.io.File toDir ) { java.io.File toFile = getFile ( toDir ) ; com.intellij.updater.ValidationResult result = doValidateAccess ( toFile , ValidationResult.Action.CREATE ) ; if ( result != null ) return result ; if ( toFile.exists ( ) ) { com.intellij.updater.ValidationResult [ ] options = ( myPatch.isStrict ( ) ) ? new com.intellij.updater.ValidationResult.Option [ ] { ValidationResult.Option.REPLACE } : new com.intellij.updater.ValidationResult.Option [ ] { ValidationResult.Option.REPLACE , ValidationResult.Option.KEEP } ; return new com.intellij.updater.ValidationResult ( ValidationResult.Kind.CONFLICT , myPath , ValidationResult.Action.CREATE , ValidationResult.ALREADY_EXISTS_MESSAGE , options ) ; } return null ; }
Source:
public void getImsRegistrationState ( android.os.Message result ) { com.android.internal.telephony.RILRequest rr = com.android.internal.telephony.RILRequest.obtain ( com.android.internal.telephony.RIL_REQUEST_IMS_REGISTRATION_STATE , result ) ; if ( com.android.internal.telephony.RIL.RILJ_LOGD ) { riljLog ( ( ( ( rr.serialString ( ) ) + "> " ) + ( com.android.internal.telephony.RIL.requestToString ( rr.mRequest ) ) ) ) ; } send ( rr ) ; }

Target:
public void getVoiceRadioTechnology ( android.os.Message result ) { com.android.internal.telephony.RILRequest rr = com.android.internal.telephony.RILRequest.obtain ( com.android.internal.telephony.RIL_REQUEST_VOICE_RADIO_TECH , result , mRILDefaultWorkSource ) ; if ( com.android.internal.telephony.RIL.RILJ_LOGD ) riljLog ( ( ( ( rr.serialString ( ) ) + "> " ) + ( com.android.internal.telephony.RIL.requestToString ( rr.mRequest ) ) ) ) ; send ( rr ) ; }
Source:
private void stopDragging ( ) { if ( ( mDragView ) != null ) { android.view.WindowManager wm = ( ( android.view.WindowManager ) ( mContext.getSystemService ( "window" ) ) ) ; wm.removeView ( mDragView ) ; mDragView.setImageDrawable ( null ) ; mDragView = null ; } if ( ( mDragBitmap ) != null ) { mDragBitmap.recycle ( ) ; mDragBitmap = null ; } }

Target:
private void stopDragging ( ) { if ( ( mDragView ) != null ) { android.view.WindowManager wm = ( ( android.view.WindowManager ) ( mContext.getSystemService ( Context.WINDOW_SERVICE ) ) ) ; wm.removeView ( mDragView ) ; mDragView.setImageDrawable ( null ) ; mDragView = null ; } if ( ( mDragBitmap ) != null ) { mDragBitmap.recycle ( ) ; mDragBitmap = null ; } }
Source:
private native boolean mediaPlayerListRspNative ( byte [ ] address , int rsStatus , int uidCounter , byte item_type , int numItems , byte [ ] PlayerTypes , int [ ] PlayerSubTypes , byte [ ] playStatusValues , short [ ] FeatureBitMaskValues , java.lang.String [ ] textArray ) ;

Target:
private native boolean mediaPlayerListRspNative ( byte [ ] address , int rsStatus , int uidCounter , byte item_type , int numItems , int [ ] playerIds , byte [ ] playerTypes , int [ ] playerSubTypes , byte [ ] playStatusValues , short [ ] featureBitMaskValues , java.lang.String [ ] textArray ) ;
Source:
protected android.view.View getVideoLoadingProgressView ( ) { org.chromium.base.TraceEvent.begin ( ) ; android.view.View result ; if ( ( mWebChromeClient ) != null ) { if ( com.android.webview.chromium.WebViewContentsClientAdapter.TRACE ) android.util.Log.d ( com.android.webview.chromium.WebViewContentsClientAdapter.TAG , "getVideoLoadingProgressView" ) ; result = mWebChromeClient.getVideoLoadingProgressView ( ) ; } else { result = null ; } org.chromium.base.TraceEvent.end ( ) ; return result ; }

Target:
protected android.view.View getVideoLoadingProgressView ( ) { try { org.chromium.base.TraceEvent.begin ( "WebViewContentsClientAdapter.getVideoLoadingProgressView" ) ; android.view.View result ; if ( ( mWebChromeClient ) != null ) { if ( com.android.webview.chromium.WebViewContentsClientAdapter.TRACE ) android.util.Log.d ( com.android.webview.chromium.WebViewContentsClientAdapter.TAG , "getVideoLoadingProgressView" ) ; result = mWebChromeClient.getVideoLoadingProgressView ( ) ; } else { result = null ; } return result ; } finally { org.chromium.base.TraceEvent.end ( "WebViewContentsClientAdapter.getVideoLoadingProgressView" ) ; } }
Source:
public com.android.jack.ir.ast.JSsaVariableUseRef getRhs ( @ javax.annotation.Nonnull com.android.jack.ir.ast.cfg.JBasicBlock pred ) { com.android.jack.ir.ast.JSsaVariableUseRef ref = rhs.get ( pred ) ; assert ref != null ; return ref ; }

Target:
public com.android.jack.ir.ast.JSsaVariableUseRef getRhs ( @ javax.annotation.Nonnull com.android.jack.ir.ast.cfg.JBasicBlock pred ) { for ( int i = 0 ; i < ( preds.length ) ; i ++ ) { if ( ( preds [ i ] ) == pred ) { return rhs [ i ] ; } } throw new java.lang.RuntimeException ( ) ; }
Source:
public boolean pageDown ( final boolean bottom ) { mFactory.startYourEngines ( true ) ; if ( checkNeedsPost ( ) ) { java.lang.Boolean ret = runOnUiThreadBlocking ( new java.util.concurrent.Callable < java.lang.Boolean > ( ) { @ java.lang.Override public java.lang.Boolean call ( ) { return pageDown ( bottom ) ; } } ) ; return ret ; } return mAwContents.pageDown ( bottom ) ; }

Target:
public android.graphics.Picture capturePicture ( ) { mFactory.startYourEngines ( true ) ; if ( checkNeedsPost ( ) ) { android.graphics.Picture ret = runOnUiThreadBlocking ( new java.util.concurrent.Callable < android.graphics.Picture > ( ) { @ java.lang.Override public android.graphics.Picture call ( ) { return capturePicture ( ) ; } } ) ; return ret ; } return mAwContents.capturePicture ( ) ; }
Source:
private void propagateVarRef ( com.android.jack.ir.ast.JSsaVariableDefRef lhs , com.android.jack.ir.ast.JSsaVariableUseRef rhs , com.android.jack.transformations.request.TransformationRequest tr ) { com.android.jack.ir.ast.JSsaVariableDefRef def = rhs.getDef ( ) ; for ( com.android.jack.ir.ast.JSsaVariableRef oldUse : lhs.getUses ( ) ) { com.android.jack.ir.ast.JSsaVariableRef newUse = def.makeRef ( oldUse.getSourceInfo ( ) ) ; newUse.addAllMarkers ( oldUse.getAllMarkers ( ) ) ; tr.append ( new com.android.jack.transformations.request.Replace ( oldUse , newUse ) ) ; } }

Target:
private void propagateVarRef ( com.android.jack.ir.ast.JSsaVariableDefRef lhs , com.android.jack.ir.ast.JSsaVariableUseRef rhs , com.android.jack.transformations.request.TransformationRequest tr ) { com.android.jack.ir.ast.JSsaVariableDefRef def = rhs.getDef ( ) ; for ( com.android.jack.ir.ast.JSsaVariableRef oldUse : com.google.common.collect.Lists.newArrayList ( lhs.getUses ( ) ) ) { com.android.jack.ir.ast.JSsaVariableRef newUse = def.makeRef ( oldUse.getSourceInfo ( ) ) ; newUse.addAllMarkers ( oldUse.getAllMarkers ( ) ) ; tr.append ( new com.android.jack.transformations.request.Replace ( oldUse , newUse ) ) ; } }
Source:
private void handleSupplicantConnectionLoss ( boolean killSupplicant ) { if ( killSupplicant ) { mWifiMonitor.stopAllMonitoring ( ) ; try { if ( ! ( mClientInterface.disableSupplicant ( ) ) ) { loge ( "Failed to disable supplicant after connection loss" ) ; } } catch ( android.os.RemoteException e ) { } } mWifiNative.closeSupplicantConnection ( ) ; sendSupplicantConnectionChangedBroadcast ( false ) ; setWifiState ( android.net.wifi.WifiManager.WIFI_STATE_DISABLED ) ; }

Target:
private void reportConnectionAttemptStart ( android.net.wifi.WifiConfiguration config , java.lang.String targetBSSID , int roamType ) { mWifiMetrics.startConnectionEvent ( config , targetBSSID , roamType ) ; mDiagsConnectionStartMillis = mClock.getElapsedSinceBootMillis ( ) ; mWifiDiagnostics.reportConnectionEvent ( mDiagsConnectionStartMillis , WifiDiagnostics.CONNECTION_EVENT_STARTED ) ; sendMessageDelayed ( com.android.server.wifi.WifiStateMachine.CMD_DIAGS_CONNECT_TIMEOUT , mDiagsConnectionStartMillis , com.android.server.wifi.WifiStateMachine.DIAGS_CONNECT_TIMEOUT_MILLIS ) ; }
Source:
public void test_zh_TW ( ) throws java.lang.Exception { libcore.icu.AlphabeticIndex zh_TW = new libcore.icu.AlphabeticIndex ( new java.util.Locale ( "zh" , "TW" ) ) ; libcore.icu.AlphabeticIndexTest.assertHasLabel ( zh_TW , "沈" , "傀" ) ; libcore.icu.AlphabeticIndexTest.assertHasLabel ( zh_TW , "瀋" , "叢" ) ; libcore.icu.AlphabeticIndexTest.assertHasLabel ( zh_TW , "贾" , "傀" ) ; }

Target:
public void test_zh_TW ( ) throws java.lang.Exception { libcore.icu.AlphabeticIndex zh_TW = new libcore.icu.AlphabeticIndex ( new java.util.Locale ( "zh" , "TW" ) ) ; libcore.icu.AlphabeticIndexTest.assertHasLabel ( zh_TW , "沈" , "串" ) ; libcore.icu.AlphabeticIndexTest.assertHasLabel ( zh_TW , "瀋" , "叢" ) ; libcore.icu.AlphabeticIndexTest.assertHasLabel ( zh_TW , "贾" , "乘" ) ; }
Source:
public void test4_anyInRange ( ) { int [ ] bits = new int [ 100 ] ; for ( int i = 0 ; i < ( bits.length ) ; i ++ ) { bits [ i ] = - 1 ; } for ( int i = 1 ; i < 100 ; i += 11 ) { assertTrue ( com.android.dx.util._tests.BitsTest.label ( i ) , com.android.dx.util.Bits.anyInRange ( bits , 0 , i ) ) ; } }

Target:
public void test4_anyInRange ( ) { int [ ] bits = new int [ 100 ] ; for ( int i = 0 ; i < ( bits.length ) ; i ++ ) { bits [ i ] = - 1 ; } for ( int i = 1 ; i < 100 ; i += 11 ) { assertTrue ( com.android.dx.util.BitsTest.label ( i ) , com.android.dx.util.Bits.anyInRange ( bits , 0 , i ) ) ; } }
Source:
private java.io.File findApk ( java.lang.String filename ) { java.io.File file = new java.io.File ( mApkDir , filename ) ; if ( file.exists ( ) ) { return file ; } file = new java.io.File ( mApkDir , ( ( ( com.google.common.io.Files.getNameWithoutExtension ( filename ) ) + "/" ) + filename ) ) ; if ( file.exists ( ) ) { return file ; } return null ; }

Target:
private java.lang.String getApkDir ( ) { if ( ( mApkDir ) == null ) { mApkDir = ( java.lang.System.getenv ( "ANDROID_PRODUCT_OUT" ) ) + "/data/app" ; } return mApkDir ; }
Source:
public void eventFollowupReceived ( android.hardware.wifi.V1_0.NanFollowupReceivedInd event ) { if ( com.android.server.wifi.aware.WifiAwareNativeCallback.VDBG ) { android.util.Log.v ( com.android.server.wifi.aware.WifiAwareNativeCallback.TAG , ( ( ( ( ( "eventFollowupReceived: discoverySessionId=" + ( event.discoverySessionId ) ) + ", peerId=" ) + ( event.peerId ) ) + ", addr=" ) + ( java.lang.String.valueOf ( libcore.util.HexEncoding.encode ( event.addr ) ) ) ) ) ; } mWifiAwareStateManager.onMessageReceivedNotification ( event.discoverySessionId , event.peerId , event.addr , convertUcByteToLcByteArray ( event.message ) ) ; }

Target:
public void eventFollowupReceived ( android.hardware.wifi.V1_0.NanFollowupReceivedInd event ) { if ( com.android.server.wifi.aware.WifiAwareNativeCallback.VDBG ) { android.util.Log.v ( com.android.server.wifi.aware.WifiAwareNativeCallback.TAG , ( ( ( ( ( "eventFollowupReceived: discoverySessionId=" + ( event.discoverySessionId ) ) + ", peerId=" ) + ( event.peerId ) ) + ", addr=" ) + ( java.lang.String.valueOf ( libcore.util.HexEncoding.encode ( event.addr ) ) ) ) ) ; } mWifiAwareStateManager.onMessageReceivedNotification ( event.discoverySessionId , event.peerId , event.addr , convertUcByteToLcByteArray ( event.serviceSpecificInfo ) ) ; }
Source:
public static void assertEquals ( java.lang.String message , double expected , double actual , double delta ) { if ( java.lang.Double.isInfinite ( expected ) ) { if ( ! ( expected == actual ) ) junit.framework.Assert.failNotEquals ( message , new java.lang.Double ( expected ) , new java.lang.Double ( actual ) ) ; } else if ( ! ( ( java.lang.Math.abs ( ( expected - actual ) ) ) <= delta ) ) junit.framework.Assert.failNotEquals ( message , new java.lang.Double ( expected ) , new java.lang.Double ( actual ) ) ; }

Target:
public static void assertEquals ( java.lang.String message , double expected , double actual , double delta ) { if ( ( java.lang.Double.compare ( expected , actual ) ) == 0 ) return ; if ( ! ( ( java.lang.Math.abs ( ( expected - actual ) ) ) <= delta ) ) junit.framework.Assert.failNotEquals ( message , new java.lang.Double ( expected ) , new java.lang.Double ( actual ) ) ; }
Source:
boolean equalNameAndParameters ( java.lang.reflect.Method m ) { return ( getName ( ) . equals ( m.getName ( ) ) ) && ( java.lang.reflect.ArtMethod.equalMethodParameters ( artMethod , m.getParameterTypes ( ) ) ) ; }

Target:
boolean equalNameAndParameters ( java.lang.reflect.Method m ) { java.lang.reflect.ArtMethod nonProxyThis = java.lang.Class.findOverriddenMethodIfProxy ( this . artMethod ) ; java.lang.reflect.ArtMethod nonProxyM = java.lang.Class.findOverriddenMethodIfProxy ( m.artMethod ) ; return ( java.lang.reflect.ArtMethod.getMethodName ( nonProxyThis ) . equals ( java.lang.reflect.ArtMethod.getMethodName ( nonProxyM ) ) ) && ( java.lang.reflect.ArtMethod.equalMethodParameters ( nonProxyThis , nonProxyM.getParameterTypes ( ) ) ) ; }
Source:
static int closedFormNested ( int n ) { int closed = 0 ; for ( int i = 0 ; i < n ; i ++ ) { for ( int j = 0 ; j < 10 ; j ++ ) { closed ++ ; } } return closed ; }

Target:
static int closedFormNestedN ( int n ) { int closed = 0 ; for ( int i = 0 ; i < n ; i ++ ) { for ( int j = 0 ; j < 10 ; j ++ ) { closed ++ ; } } return closed ; }
Source:
private com.android.jack.ir.ast.JMethod createSyntheticMethod ( com.android.jack.ir.sourceinfo.SourceInfo info , java.lang.String name , com.android.jack.ir.ast.JDefinedClassOrInterface enclosingType , com.android.jack.ir.ast.JType returnType , int modifier ) { com.android.jack.ir.ast.JMethod method = new com.android.jack.ir.ast.JMethod ( info , new com.android.jack.ir.ast.JMethodId ( name , com.android.jack.ir.impl.ReferenceMapper.getMethodKind ( modifier ) ) , enclosingType , returnType , com.android.jack.ir.impl.ReferenceMapper.removeSynchronizedOnBridge ( ( modifier | ( com.android.jack.ir.ast.JModifier.SYNTHETIC ) ) ) ) ; method.setBody ( new com.android.jack.ir.ast.JMethodBody ( info , new com.android.jack.ir.ast.JBlock ( info ) ) ) ; enclosingType.addMethod ( method ) ; method.updateParents ( enclosingType ) ; return method ; }

Target:
private com.android.jack.ir.ast.JMethod createSyntheticMethod ( com.android.jack.ir.sourceinfo.SourceInfo info , java.lang.String name , com.android.jack.ir.ast.JDefinedClassOrInterface enclosingType , com.android.jack.ir.ast.JType returnType , int modifier ) { com.android.jack.ir.ast.JMethod method = new com.android.jack.ir.ast.JMethod ( info , new com.android.jack.ir.ast.JMethodId ( new com.android.jack.ir.ast.JMethodIdWide ( name , com.android.jack.ir.impl.ReferenceMapper.getMethodKind ( modifier ) ) , returnType ) , enclosingType , com.android.jack.ir.impl.ReferenceMapper.removeSynchronizedOnBridge ( ( modifier | ( com.android.jack.ir.ast.JModifier.SYNTHETIC ) ) ) ) ; method.setBody ( new com.android.jack.ir.ast.JMethodBody ( info , new com.android.jack.ir.ast.JBlock ( info ) ) ) ; enclosingType.addMethod ( method ) ; method.updateParents ( enclosingType ) ; return method ; }
Source:
public void schedule ( java.util.TimerTask task , long delay ) { if ( delay < 0 ) { throw new java.lang.IllegalArgumentException ( ( "delay < 0: " + delay ) ) ; } scheduleImpl ( task , delay , ( - 1 ) , false ) ; }

Target:
private static java.lang.Long computeDelayUntilNextTask ( java.util.Timer.ScheduledTask scheduledTask ) { if ( scheduledTask == null ) { return null ; } long currentTimeMillis = java.lang.System.currentTimeMillis ( ) ; if ( ( scheduledTask.nextExecution ) < currentTimeMillis ) { return 0L ; } else { return ( scheduledTask.nextExecution ) - currentTimeMillis ; } }
Source:
public android.net.wifi.hotspot2.pps.Credential.UserCredential createFromParcel ( android.os.Parcel in ) { android.net.wifi.hotspot2.pps.Credential.UserCredential userCredential = new android.net.wifi.hotspot2.pps.Credential.UserCredential ( ) ; userCredential.username = in.readString ( ) ; userCredential.password = in.readString ( ) ; userCredential.eapType = in.readInt ( ) ; userCredential.nonEapInnerMethod = in.readString ( ) ; return userCredential ; }

Target:
public android.net.wifi.hotspot2.pps.Credential.UserCredential createFromParcel ( android.os.Parcel in ) { android.net.wifi.hotspot2.pps.Credential.UserCredential userCredential = new android.net.wifi.hotspot2.pps.Credential.UserCredential ( ) ; userCredential.username = in.readString ( ) ; userCredential.password = in.readString ( ) ; userCredential.machineManaged = ( in.readInt ( ) ) != 0 ; userCredential.softTokenApp = in.readString ( ) ; userCredential.ableToShare = ( in.readInt ( ) ) != 0 ; userCredential.eapType = in.readInt ( ) ; userCredential.nonEapInnerMethod = in.readString ( ) ; return userCredential ; }
Source:
public java.nio.FloatBuffer put ( java.nio.FloatBuffer src ) { if ( src == ( this ) ) { throw new java.lang.IllegalArgumentException ( ) ; } if ( ( src.remaining ( ) ) > ( remaining ( ) ) ) { throw new java.nio.BufferOverflowException ( ) ; } float [ ] contents = new float [ src.remaining ( ) ] ; src.get ( contents ) ; put ( contents ) ; return this ; }

Target:
public java.nio.FloatBuffer put ( java.nio.FloatBuffer src ) { if ( src == ( this ) ) { throw new java.lang.IllegalArgumentException ( "src == this" ) ; } if ( ( src.remaining ( ) ) > ( remaining ( ) ) ) { throw new java.nio.BufferOverflowException ( ) ; } float [ ] contents = new float [ src.remaining ( ) ] ; src.get ( contents ) ; put ( contents ) ; return this ; }
Source:
static boolean write ( java.nio.channels.SocketChannel chan , byte [ ] data ) { try { com.android.ddmlib.AdbHelper.write ( chan , data , ( - 1 ) , com.android.ddmlib.DdmPreferences.getTimeOut ( ) ) ; } catch ( java.io.IOException e ) { com.android.ddmlib.Log.e ( "ddms" , e ) ; return false ; } return true ; }

Target:
static void write ( java.nio.channels.SocketChannel chan , byte [ ] data ) throws com.android.ddmlib.TimeoutException , java.io.IOException { com.android.ddmlib.AdbHelper.write ( chan , data , ( - 1 ) , com.android.ddmlib.DdmPreferences.getTimeOut ( ) ) ; }
Source:
public void testMultiProject ( ) throws java.lang.Exception { java.io.File master = getProjectDir ( "MasterProject" , "multiproject/main-manifest.xml=>AndroidManifest.xml" , "multiproject/main.properties=>project.properties" , "multiproject/MainCode.java.txt=>src/foo/main/MainCode.java" ) ; java.io.File library = getProjectDir ( "LibraryProject" , "multiproject/library-manifest.xml=>AndroidManifest.xml" , "multiproject/library.properties=>project.properties" , "multiproject/LibraryCode.java.txt=>src/foo/library/LibraryCode.java" , "multiproject/strings.xml=>res/values/strings.xml" ) ; assertEquals ( "strings.xml:7: Warning: The resource R.string.string3 appears to be unused" , checkLint ( java.util.Arrays.asList ( master , library ) ) ) ; }

Target:
public void testMultiProject ( ) throws java.lang.Exception { java.io.File master = getProjectDir ( "MasterProject" , "multiproject/main-manifest.xml=>AndroidManifest.xml" , "multiproject/main.properties=>project.properties" , "multiproject/MainCode.java.txt=>src/foo/main/MainCode.java" ) ; java.io.File library = getProjectDir ( "LibraryProject" , "multiproject/library-manifest.xml=>AndroidManifest.xml" , "multiproject/library.properties=>project.properties" , "multiproject/LibraryCode.java.txt=>src/foo/library/LibraryCode.java" , "multiproject/strings.xml=>res/values/strings.xml" ) ; assertEquals ( ( "/TESTROOT/UnusedResourceDetectorTest_testMultiProject/LibraryProject/res/values/strings.xml:7: Warning: The resource R.string.string3 appears to be unused [UnusedResources]\n" + ( ( ( " <string name=\"string3\">String 3</string>\n" + " ~~~~~~~~~~~~~~\n" ) + "0 errors, 1 warnings\n" ) + "" ) ) , checkLint ( java.util.Arrays.asList ( master , library ) ) ) ; }
Source:
void init ( java.io.File codePath , java.io.File resourcePath , java.lang.String nativeLibraryPathString , java.lang.String requiredCpuAbiString , int pVersionCode ) { this . codePath = codePath ; this . codePathString = codePath.toString ( ) ; this . resourcePath = resourcePath ; this . resourcePathString = resourcePath.toString ( ) ; this . nativeLibraryPathString = nativeLibraryPathString ; this . requiredCpuAbiString = requiredCpuAbiString ; this . versionCode = pVersionCode ; }

Target:
void init ( java.io.File codePath , java.io.File resourcePath , java.lang.String nativeLibraryPathString , java.lang.String requiredCpuAbiString , int pVersionCode ) { this . codePath = codePath ; this . codePathString = codePath.toString ( ) ; this . resourcePath = resourcePath ; this . resourcePathString = resourcePath.toString ( ) ; this . nativeLibraryPathString = nativeLibraryPathString ; this . cpuAbiString = requiredCpuAbiString ; this . versionCode = pVersionCode ; }
Source:
public void testEnterSoftApModeActiveWhenAlreadyInSoftApMode ( ) throws java.lang.Exception { when ( mWifiInjector.makeWificond ( ) ) . thenReturn ( mWificond ) ; when ( mWificond.createApInterface ( ) ) . thenReturn ( null ) ; mWifiStateMachinePrime.enterSoftAPMode ( ) ; mLooper.dispatchNext ( ) ; org.junit.Assert.assertEquals ( "SoftAPModeState" , mWifiStateMachinePrime.getCurrentMode ( ) ) ; mLooper.dispatchNext ( ) ; org.junit.Assert.assertEquals ( "SoftAPModeState" , mWifiStateMachinePrime.getCurrentMode ( ) ) ; enterSoftApActiveMode ( ) ; verify ( mWificond ) . tearDownInterfaces ( ) ; }

Target:
public void testAPInterfaceFailedWhenSwitchingToApMode ( ) throws java.lang.Exception { when ( mWifiInjector.makeWificond ( ) ) . thenReturn ( mWificond ) ; when ( mWificond.createApInterface ( ) ) . thenReturn ( null ) ; mWifiStateMachinePrime.enterSoftAPMode ( null ) ; mLooper.dispatchAll ( ) ; org.junit.Assert.assertEquals ( com.android.server.wifi.WifiStateMachinePrimeTest.SOFT_AP_MODE_STATE_STRING , mWifiStateMachinePrime.getCurrentMode ( ) ) ; }
Source:
public boolean equals ( java.lang.Object x ) { if ( ( this ) == x ) { return true ; } if ( x instanceof java.math.BigDecimal ) { java.math.BigDecimal x1 = ( ( java.math.BigDecimal ) ( x ) ) ; return ( ( x1.scale ) == ( scale ) ) && ( ( bitLength ) < 64 ? ( x1.smallValue ) == ( smallValue ) : intVal.equals ( x1.intVal ) ) ; } return false ; }

Target:
public boolean equals ( java.lang.Object x ) { if ( ( this ) == x ) { return true ; } if ( x instanceof java.math.BigDecimal ) { java.math.BigDecimal x1 = ( ( java.math.BigDecimal ) ( x ) ) ; return ( ( ( x1.scale ) == ( scale ) ) && ( ( x1.bitLength ) == ( bitLength ) ) ) && ( ( bitLength ) < 64 ? ( x1.smallValue ) == ( smallValue ) : x1.intVal.equals ( intVal ) ) ; } return false ; }
Source:
public void run ( ) { org.eclipse.swt.graphics.ImageData imageData = new org.eclipse.swt.graphics.ImageData ( screenshot.width , screenshot.height , screenshot.bpp , new org.eclipse.swt.graphics.PaletteData ( screenshot.getRedMask ( ) , screenshot.getGreenMask ( ) , screenshot.getBlueMask ( ) ) , 1 , screenshot.data ) ; imageContainer.image = new org.eclipse.swt.graphics.Image ( org.eclipse.swt.widgets.Display.getDefault ( ) , imageData ) ; }

Target:
public void run ( ) { final org.eclipse.swt.graphics.Image image = loadCapture ( viewNode ) ; if ( image != null ) { org.eclipse.swt.widgets.Display.getDefault ( ) . syncExec ( new java.lang.Runnable ( ) { @ java.lang.Override public void run ( ) { com.android.hierarchyviewerlib.ui.CaptureDisplay.show ( shell , viewNode , image ) ; } } ) ; } }
Source:
protected void onResume ( ) { super . onResume ( ) ; getPreferenceScreen ( ) . setEnabled ( true ) ; mPhone.queryCdmaRoamingPreference ( mHandler.obtainMessage ( com.android.phone.CdmaOptions.MyHandler.MESSAGE_QUERY_ROAMING_PREFERENCE ) ) ; }

Target:
protected void onResume ( ) { super . onResume ( ) ; mPhone = com.android.internal.telephony.PhoneFactory.getDefaultPhone ( ) ; getPreferenceScreen ( ) . setEnabled ( true ) ; if ( mPhone.getPhoneName ( ) . equals ( "CDMA" ) ) { mPhone.queryCdmaRoamingPreference ( mHandler.obtainMessage ( com.android.phone.CdmaOptions.MyHandler.MESSAGE_QUERY_ROAMING_PREFERENCE ) ) ; } else { mButtonCdmaRoam.setEnabled ( false ) ; mButtonCdmaSubscription.setEnabled ( false ) ; mButtonCbSmsExpand.setEnabled ( false ) ; } }
Source:
public boolean isTest ( ) { return getChildren ( ) . isEmpty ( ) ; }

Target:
public java.lang.Class < ? > getTestClass ( ) { if ( ( fTestClass ) != null ) { return fTestClass ; } java.lang.String name = getClassName ( ) ; if ( name == null ) { return null ; } try { fTestClass = java.lang.Class.forName ( name , false , getClass ( ) . getClassLoader ( ) ) ; return fTestClass ; } catch ( java.lang.ClassNotFoundException e ) { return null ; } }
Source:
public void testAesCbcHmacSha1Udp4 ( ) throws java.lang.Exception { android.net.IpSecAlgorithm crypt = new android.net.IpSecAlgorithm ( android.net.IpSecAlgorithm.CRYPT_AES_CBC , android.net.cts.IpSecManagerTest.CRYPT_KEY ) ; android.net.IpSecAlgorithm auth = new android.net.IpSecAlgorithm ( android.net.IpSecAlgorithm.AUTH_HMAC_SHA1 , getAuthKey ( 256 ) , 128 ) ; checkTransform ( android.system.OsConstants.IPPROTO_UDP , android.net.cts.IpSecManagerTest.IPV4_LOOPBACK , crypt , auth ) ; }

Target:
public void testAesCbcHmacSha1Tcp4 ( ) throws java.lang.Exception { android.net.IpSecAlgorithm crypt = new android.net.IpSecAlgorithm ( android.net.IpSecAlgorithm.CRYPT_AES_CBC , android.net.cts.IpSecManagerTest.CRYPT_KEY ) ; android.net.IpSecAlgorithm auth = new android.net.IpSecAlgorithm ( android.net.IpSecAlgorithm.AUTH_HMAC_SHA1 , getAuthKey ( 160 ) , 96 ) ; checkTransform ( android.system.OsConstants.IPPROTO_TCP , android.net.cts.IpSecManagerTest.IPV4_LOOPBACK , crypt , auth , false , 1 ) ; }
Source:
public void testAesCbcHmacSha384Udp6 ( ) 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_SHA384 , android.net.cts.IpSecManagerTest.getKey ( 384 ) , 192 ) ; checkTransform ( android.system.OsConstants.IPPROTO_UDP , android.net.cts.IpSecManagerTest.IPV6_LOOPBACK , crypt , auth , null , false , 1 , false ) ; checkTransform ( android.system.OsConstants.IPPROTO_UDP , android.net.cts.IpSecManagerTest.IPV6_LOOPBACK , crypt , auth , null , false , 1 , true ) ; }

Target:
public void testAesCbcHmacSha512Tcp4 ( ) 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_TCP , android.net.cts.IpSecManagerTest.IPV4_LOOPBACK , crypt , auth , false , 1 , false ) ; checkTransform ( android.system.OsConstants.IPPROTO_TCP , android.net.cts.IpSecManagerTest.IPV4_LOOPBACK , crypt , auth , false , 1 , true ) ; }
Source:
public java.lang.String getIndent ( org.w3c.dom.Node xmlNode ) { assert ( xmlNode.getNodeType ( ) ) == ( org.w3c.dom.Node.ELEMENT_NODE ) ; if ( xmlNode instanceof org.eclipse.wst.sse.core.internal.provisional.IndexedRegion ) { org.eclipse.wst.sse.core.internal.provisional.IndexedRegion region = ( ( org.eclipse.wst.sse.core.internal.provisional.IndexedRegion ) ( xmlNode ) ) ; org.eclipse.jface.text.IDocument document = getStructuredSourceViewer ( ) . getDocument ( ) ; int startOffset = region.getStartOffset ( ) ; return com.android.ide.eclipse.adt.internal.editors.AndroidXmlEditor.getIndentAtOffset ( document , startOffset ) ; } return "" ; }

Target:
public static java.lang.String getIndent ( org.eclipse.wst.sse.core.internal.provisional.text.IStructuredDocument document , org.w3c.dom.Node xmlNode ) { assert ( xmlNode.getNodeType ( ) ) == ( org.w3c.dom.Node.ELEMENT_NODE ) ; if ( xmlNode instanceof org.eclipse.wst.sse.core.internal.provisional.IndexedRegion ) { org.eclipse.wst.sse.core.internal.provisional.IndexedRegion region = ( ( org.eclipse.wst.sse.core.internal.provisional.IndexedRegion ) ( xmlNode ) ) ; int startOffset = region.getStartOffset ( ) ; return com.android.ide.eclipse.adt.internal.editors.AndroidXmlEditor.getIndentAtOffset ( document , startOffset ) ; } return "" ; }