diff stringlengths 38 1.78k | msg_token stringlengths 9 190 |
|---|---|
<nb> public class RCompletionManager implements CompletionManager
return STRING0 ;
SINGLE
- if ( currentToken . hasType ( STRING1 , STRING2 , STRING3 ) )
+ if ( currentToken . hasType ( STRING1 , STRING2 , STRING3 , STRING4 ) )
return STRING0 ;
String tokenValue = currentToken . getValue ( ) ; | add another exclusion type for completions |
<nb> public class FileConcurrentWriteAppendSameFileTest extends ContextTestSupport {
mock . expectsNoDuplicates ( body ( ) ) ;
mock . setResultWaitTime ( NUMBER0 ) ;
+ SINGLE
+ Thread . sleep ( NUMBER1 ) ;
context . startRoute ( STRING0 ) ;
assertMockEndpointsSatisfied ( ) ;
- SINGLE
+ SINGLE
St... | fixed unit test which fails randomly on our CI server |
<nb> public class ImApp extends Application {
}
}
- public boolean checkLocale ( )
+ public void checkLocale ( )
{
SharedPreferences settings = PreferenceManager . getDefaultSharedPreferences ( this ) ;
<nb> public class ImApp extends Application {
}
}
- boolean updatedLocale = false ;
-
i... | ImApp checkLocale removed unused return value |
<nb> import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
- import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
<nb> import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
- import NAMESPACE ;
import NAMESPACE ;
import NAMES... | Remove unused imports |
<nb> public class RefClassImpl extends RefElementImpl implements RefClass {
final RefFileImpl refFile = ( RefFileImpl ) getRefManager ( ) . getReference ( PsiUtil . getJspFile ( psiClass ) ) ;
LOG . assertTrue ( refFile != null ) ;
refFile . add ( this ) ;
- } else {
+ } else if ( psiParent instanceof PsiJava... | add defensive instanceof check to prevent CCE in mixed java groovy |
<nb> public final class InMemoryMemoizingEvaluator implements MemoizingEvaluator {
Maps . filterEntries ( graph . getAllValues ( ) , new Predicate < Entry < SkyKey , NodeEntry > > ( ) {
@ override
public boolean apply ( Entry < SkyKey , NodeEntry > input ) {
+ Preconditions . checkNotNull ( input . getKey ( ) ,... | Add debug preconditions guard for null skykeys to InMemoryMemoizingEvaluator delete |
<nb>
COMMENT
package NAMESPACE ;
- import NAMESPACE ;
-
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ; | FIX remove unused warning |
<nb> public class Switch extends CompoundButton {
if ( newState != oldState ) {
playSoundEffect ( SoundEffectConstants . CLICK ) ;
- setChecked ( newState ) ;
}
-
+ SINGLE
+ setChecked ( newState ) ;
cancelSuperTouch ( ev ) ;
} | Always set switch state following drag |
<nb> public abstract class AbstractBuildSettings {
COMMENT
COMMENT
public void addPluginDirectory ( File location , boolean isInline ) {
+ getPluginDirectories ( ) ;
if ( location != null ) {
Collection < File > directories = getPluginDirectories ( ) ;
if ( ! directories . contains ( location ) ) {
<nb>... | fixed failing test |
<nb> class ZoomManager {
if ( mWebView . getWebViewCore ( ) != null ) {
SINGLE
SINGLE
- setZoomScale ( Math . max ( mActualScale , getZoomOverviewScale ( ) ) ,
- mUpdateTextWrap , true ) ;
+ SINGLE
+ final float zoomOverviewScale = getZoomOverviewScale ( ) ;
+ final float newScale = ( mInZoomOverview ) ... | Keep overview mode when screen is rotated |
<nb>
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
package NAMESPACE ;
import NAMESPACE ;
<nb>
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT... | added copyright to new shutdown hook classes |
<nb> public class AhcTest extends OSGiIntegrationTestSupport {
}
@ test
- @ ignore ( STRING0 )
public void testAhcPost ( ) throws Exception {
String reply = template . requestBody ( STRING1 , STRING2 , String . class ) ;
assertEquals ( STRING3 , reply ) ;
<nb> public class HttpTest extends OSGiIntegrati... | Fixed osgi tests |
<nb> public class ExtensionAlert extends ExtensionAdaptor implements SessionChangedLi
for ( int j = i ; j < alerts . size ( ) ; j ++ ) {
SINGLE
Alert alert2 = alerts . get ( j ) ;
- if ( alert . getPluginId ( ) == alert2 . getPluginId ( ) ) {
+ if ( alert . getPluginId ( ) == alert2 . getPluginId ( ) &&
+ a... | Check risk and confidence when merging related issues |
<nb> import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
- import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
<nb> public class SynchronizeFolderOperation extends RemoteOperation {
return ( status == HttpStatus . SC_MULTI_STATUS ) ;
}
-
- COMMEN... | Remove fillOcFile from SyncronizeFolderOperation |
<nb> public class ActivityShare extends Activity {
restrictionName , methodName , restricted ) ;
}
} else
- Util . log ( null , Log . INFO , STRING0 ) ;
- notify ( getString ( R . string . msg_no_restrictions ) , false , NUMBER0 ) ; SINGLE
- SINGLE
- SINGLE
- SINGLE
- SINGLE
- SINGLE
- SINGLE
- ... | doInBackground cannot do UI work |
<nb> public class FAQDialog {
mActivity . startActivity ( i ) ;
} else if ( position == sFAQSize - NUMBER0 ) {
Intent emailIntent = new Intent ( Intent . ACTION_SENDTO ,
- Uri . fromParts ( STRING0 , STRING1 , null ) ) ;
+ Uri . fromParts ( STRING0 , STRING2 , null ) ) ;
String appVersion = BuildConfig . VE... | Changed mailto address |
<nb> public class AudioService extends IAudioService . Stub {
ensureValidDirection ( direction ) ;
float volume = AudioSystem . getMasterVolume ( ) ;
- Log . d ( TAG , STRING0 + volume ) ;
if ( volume >= FLOAT0 ) {
SINGLE
int oldVolume = getMasterVolume ( ) ;
<nb> public class AudioService extends IAudi... | remove logging from adjustMasterVolume that was left in by mistake |
<nb> public class XBinder extends XHook {
Binder binder = ( Binder ) param . thisObject ;
String descriptor = ( binder == null ? null : binder . getInterfaceDescriptor ( ) ) ;
if ( cServiceDescriptor . contains ( descriptor ) ) {
- Util . log ( this , Log . WARN , STRING0 + descriptor + STRING1 + uid + STRING2 ... | Change IPC logging to informational |
<nb> import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
+ import NAMESPACE ;
COMMENT
COMMENT
COMMENT
COMMENT
COMMENT
+ COMMENT
COMMENT
COMMENT
@ order ( Ordered . LOWEST_PRECEDENCE )
<nb> class EnableAutoConfigurationImportSelector implements DeferredImportSelector... | Improve error handling in EnableAutoConfigurationImportSelector |
<nb> public class ViewServer implements Runnable {
private static final String BUILD_TYPE_USER = STRING0 ;
SINGLE
- private static final String LOG_TAG = STRING1 ;
+ private static final String LOG_TAG = STRING2 ;
private static final String VALUE_PROTOCOL_VERSION = STRING3 ;
private static final String... | Prevent ViewServer from spamming the logs when a server is unavailable |
<nb> public class TraceFormatter {
String node = STRING0 ;
String result ;
+ if ( ! showBreadCrumb && ! showExchangeId && ! showNode ) {
+ return STRING0 ;
+ }
+
if ( showBreadCrumb || showExchangeId ) {
id = getBreadCrumbID ( exchange ) . toString ( ) ;
} | Fix tracer formatting issue when no node exchange id is shown |
<nb> public class App {
EnumIvoryTower enumIvoryTower1 = EnumIvoryTower . getInstance ( ) ;
EnumIvoryTower enumIvoryTower2 = EnumIvoryTower . getInstance ( ) ;
- System . out . println ( STRING0 + enumIvoryTower1 . getDeclaringClass ( ) . getCanonicalName ( ) + STRING1 + enumIvoryTower1 . hashCode ( ) ) ;
- S... | simplified the println |
<nb> public abstract class FakeActor < Message > extends ActorRefImpl < Message > {
@ override
protected void internalSendNonSuspendable ( Object message ) {
- if ( ! mailbox ( ) . trySend ( message ) )
+ record ( NUMBER0 , STRING0 , STRING1 , STRING2 , message , this ) ;
+ Message msg = filterMessage ( mes... | didn t call filterMessage in internalSendNonSuspendable |
<nb> public class QueryState
public int getStartedSplits ( )
{
- return Ints . min ( startedSplits . get ( ) , completedSplits . get ( ) , splits ) ;
+ return Ints . min ( startedSplits . get ( ) , splits ) ;
}
public int getCompletedSplits ( )
{
- return Ints . min ( completedSplits . get ( ) , spl... | Fix bug in reporting of running tasks |
<nb> public class WorldEditPlayer {
if ( free == NUMBER0 ) {
if ( y - NUMBER1 != origY ) {
setPosition ( new Vector ( x + FLOAT0 , y - NUMBER1 , z + FLOAT0 ) ) ;
- return ;
}
+
+ return ;
}
y ++ ; | Fixed WorldEditPlayer findFreePosition unstuck moving players up when the player was not stuck |
<nb> import NAMESPACE ;
COMMENT
COMMENT
COMMENT
- COMMENT
+ COMMENT
COMMENT
COMMENT
COMMENT | Adjust the name of the PImage object variable for reference |
<nb>
package NAMESPACE ;
- import NAMESPACE ;
- import NAMESPACE ;
-
import NAMESPACE ;
- import NAMESPACE ;
+
+ import NAMESPACE ;
+ import NAMESPACE ;
+ import NAMESPACE ;
+ import NAMESPACE ;
+ import NAMESPACE ;
COMMENT
<nb> public class DBCursor implements Iterator < DBObject > ... | Fixed see javadoc |
<nb> import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
+ import NAMESPACE ;
COMMENT
COMMENT
<nb> public class ZWaveApplicationStatusClass extends ZWaveCommandClass {
private static final Logger logger = LoggerFactory . getLogger ( ZWaveApplicationStatusClass . class ) ;
+ @ xstreamomitfie... | Omit serialising schedule into XML |
<nb> public class PersistentFS extends ManagingFS implements ApplicationComponent {
final NewVirtualFileSystem delegate = getDelegate ( file ) ;
delegate . renameFile ( requestor , file , newName ) ;
- if ( ! delegate . exists ( file ) ) {
+ if ( newName . equalsIgnoreCase ( file . getName ( ) ) || ! delegate... | Fix rename fallback |
<nb> public class HttpRequestDecoder extends HttpMessageDecoder {
COMMENT
COMMENT
- COMMENT
- COMMENT
+ COMMENT
+ COMMENT
COMMENT
public HttpRequestDecoder ( ) {
super ( ) ;
<nb> public class HttpResponseDecoder extends HttpMessageDecoder {
COMMENT
COMMENT
- COMMENT
- COMMENT
+ COMMENT... | Fixed documentation errors in HttpMessageDecoder s subclasses |
<nb> public final class EmbeddedNeo implements NeoService
public EmbeddedNeo ( String storeDir )
{
- SINGLE
+ this . shellServer = null ;
+ NeoJvmInstance . start ( null , storeDir , true ) ;
}
COMMENT | Implemented new constructor in EmbeddedNeo |
<nb> public final class MenuItemImpl implements MenuItem {
@ override
public boolean expandActionView ( ) {
- if ( hasCollapsibleActionView ( ) ) {
+ if ( ! hasCollapsibleActionView ( ) ) {
return false ;
} | Fix collapsible action views |
<nb> public class ShowcaseView extends RelativeLayout
COMMENT
COMMENT
COMMENT
- private void setFadeDurations ( long fadeInMillis , long fadeOutMillis ) {
+ public void setFadeDurations ( long fadeInMillis , long fadeOutMillis ) {
this . fadeInMillis = fadeInMillis ;
this . fadeOutMillis = fadeOutMillis ;... | Turn setFadeDurations public |
<nb> public class PluginManager implements FileFilter {
try {
Field mBase = ContextWrapper . class . getDeclaredField ( STRING0 ) ;
mBase . setAccessible ( true ) ;
- mBase . set ( app , new PluginContext ( app . getBaseContext ( ) , info ) ) ;
+ mBase . set ( app , new PluginContext ( context . getApplicatio... | Fix Application support |
<nb> public class BaseObject3D extends ATransformable3D implements Comparable < BaseObj
pickerMat . setModelMatrix ( mMMatrix ) ;
pickerMat . setViewMatrix ( vMatrix ) ;
GLES20 . glBindBuffer ( GLES20 . GL_ELEMENT_ARRAY_BUFFER , mGeometry . getIndexBufferInfo ( ) . bufferHandle ) ;
- GLES20 . glDrawElements ( m... | Changed the drawing mode to GL_TRIANGLES for colour picking |
<nb> public class PruneUnreferencedOutputs
ImmutableSet . Builder < Symbol > expectedInputs = ImmutableSet . < Symbol > builder ( )
. addAll ( node . getDistinctSymbols ( ) )
- . addAll ( context . get ( ) ) ;
+ . addAll ( context . get ( ) . stream ( )
+ . filter ( symbol - > ! symbol . equals ( node . get... | Remove marker symbol from required inputs of MarkDistinctNode |
<nb> public final class DefaultPassConfig extends PassConfig {
checks . add ( checkVars ) ;
}
+ if ( options . computeFunctionSideEffects ) {
+ checks . add ( checkRegExp ) ;
+ }
+
SINGLE
SINGLE
SINGLE
<nb> public final class DefaultPassConfig extends PassConfig {
checks . add ( inferConsts ) ; ... | Moving CheckRegExp before transpilation |
<nb> public class NotFoundScalaToolProvider implements ToolProvider {
private RuntimeException failure ( ) {
TreeFormatter formatter = new TreeFormatter ( ) ;
this . explain ( formatter ) ;
- return new GradleException ( formatter . toString ( ) ) ;
+ return new GradleException ( formatter . toString ( ) , ex... | Don t discard exception |
<nb> public final class Typeface_Delegate {
if ( familyName == null ) {
familyName = DEFAULT_FAMILY ;
}
+ if ( style < NUMBER0 ) {
+ style = Typeface . NORMAL ;
+ }
Typeface_Delegate newDelegate = new Typeface_Delegate ( familyName , style ) ;
if ( sFontLoader != null ) { | Set default text style in layoutlib as NORMAL |
<nb> public class RegistryBuilder implements RegistrySpec {
}
public static Registry join ( Registry parent , Registry child ) {
- return new CachingRegistry ( new HierarchicalRegistry ( parent , child ) ) ;
+ return new HierarchicalRegistry ( parent , child ) ;
}
} | Remove the registry caching for now |
<nb> import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
- import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
<nb> import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
- import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
<nb> imp... | Remove unnecessary import lines from IMM and IMMS |
<nb> public class MimeMappings {
defaultMappings . put ( STRING0 , STRING1 ) ;
defaultMappings . put ( STRING2 , STRING1 ) ;
defaultMappings . put ( STRING3 , STRING1 ) ;
+ defaultMappings . put ( STRING4 , STRING5 ) ;
defaultMappings . put ( STRING6 , STRING7 ) ;
defaultMappings . put ( STRING8 , STRING9 )... | Add javascript mime mapping |
<nb> class BrandedSupportFragment extends Fragment {
}
}
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
public final boolean isShowingTitle ( ) {
return mShowingTitle ;
}
<nb> public class BrowseFragment extends BaseFragment {
mMainFragment = getChildFragmentManager ( ) . findFragmentById (... | Fix NPE of null FragmentHostImpl |
<nb> class JUnit4Config {
@ visiblefortesting
static final String JUNIT_API_VERSION_PROPERTY = STRING0 ;
+ @ visiblefortesting
+ static final String SHOULD_INSTALL_SECURITY_MANAGER_PROPERTY
+ = STRING1 ;
+
private final String testIncludeFilterRegexp ;
private final String testExcludeFilterRegexp ;
... | Allow test targets to completely disable the test security manager via |
<nb> import static NAMESPACE
COMMENT
COMMENT
public abstract class TitanOutputFormat extends NoOpOutputFormat implements MapReduceFormat {
-
- public static final ConfigOption < Boolean > INFER_SCHEMA = new ConfigOption < Boolean > (
- TitanHadoopConfiguration . OUTPUT_NS , STRING0 ,
- STRING1 ,
- Confi... | Fix accidental double definition of INFER_SCHEMA |
<nb> public class GitCheckoutOperation extends GitBranchOperation {
catch ( VcsException e ) {
SINGLE
SINGLE
- LOG . warn ( String . format ( STRING0 , myPreviousBranch , myStartPointReference , repository . getRoot ( ) ) ) ;
+ LOG . warn ( String . format ( STRING0 , myPreviousBranch , myStartPointReference ... | log the exception |
<nb> public class JavadocStyleCheck
private String getCommentText ( String [ ] aComments )
{
final StringBuffer buffer = new StringBuffer ( ) ;
- boolean foundTag = false ;
-
for ( int i = NUMBER0 ; i < aComments . length ; i ++ ) {
String line = aComments [ i ] ;
final int textStart = findTextStart ( l... | remove unused variable |
<nb> public class FileInStream extends InputStream implements BoundedStream , Seekable
readCurrentBlockTill ( pos > mPos ? pos : mFileLength ) ;
}
- SINGLE
SINGLE
SINGLE
SINGLE | remove one unnecessary comment |
<nb> public class GreedyEvictor extends BlockStoreEventListenerBase implements Evicto
return new EvictionPlan ( toTransfer , toEvict ) ;
}
+ SINGLE
private boolean canEvictBlocksFromDir ( StorageDir dir , long availableBytes ) {
return dir . getAvailableBytes ( ) + dir . getCommittedBytes ( ) >= availableBy... | Add a TODO to address gpang s comments |
<nb> public class WebView extends AbsoluteLayout
}
void setGLRectViewport ( ) {
- View window = getRootView ( ) ;
- int [ ] location = new int [ NUMBER0 ] ;
- getLocationInWindow ( location ) ;
- mGLRectViewport = new Rect ( location [ NUMBER1 ] , window . getHeight ( )
- - ( location [ NUMBER2 ] + getH... | Properly set the viewport for WebView when using GL |
<nb> public abstract class AbstractLineageClient implements LineageClient {
COMMENT
COMMENT
private List < String > stripURIList ( List < AlluxioURI > uris ) {
- final List < String > pathStrings = new ArrayList < String > ( uris . size ( ) ) ;
+ final List < String > pathStrings = new ArrayList < > ( uris . ... | SMALLFIX Removed explicit parameter type in AbstractLineageClient |
<nb> public class Jedis extends BinaryJedis implements JedisCommands {
COMMENT
COMMENT
COMMENT
- COMMENT
+ COMMENT
COMMENT
public Boolean exists ( final String key ) {
checkIsInMulti ( ) ; | fix small typo in exists command |
<nb> public abstract class AbstractSchedulerTests {
List < String > strings = m . toList ( ) . toBlockingObservable ( ) . last ( ) ;
assertEquals ( NUMBER0 , strings . size ( ) ) ;
- assertEquals ( STRING0 , strings . get ( NUMBER1 ) ) ;
- assertEquals ( STRING1 , strings . get ( NUMBER2 ) ) ;
- assertEqual... | Remove Validation of Ordering |
<nb> public class TestReportDataCollector implements TestListener , TestOutputListener
classResult = new TestClassResult ( internalIdCounter ++ , className , result . getStartTime ( ) ) ;
results . put ( className , classResult ) ;
} else if ( classResult . getStartTime ( ) == NUMBER0 ) {
+ SINGLE
classResult... | Added a comment |
<nb> import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
- import NAMESPACE ;
+ import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ; | fix WinDef POINT references |
<nb> public class Intent implements Parcelable , Cloneable {
public static final String ACTION_PACKAGE_FULLY_REMOVED
= STRING0 ;
COMMENT
- COMMENT
- COMMENT
- COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
COMMENT
COMMENT
COMMENT
<nb> public class Intent implements Parcelable , Cloneable {
public sta... | Fix description line truncated by e g |
<nb> public class WebView extends AbsoluteLayout
switch ( mTouchMode ) {
case TOUCH_DOUBLE_TAP_MODE : SINGLE
mPrivateHandler . removeMessages ( SWITCH_TO_SHORTPRESS ) ;
+ mTouchMode = TOUCH_DONE_MODE ;
doDoubleTap ( ) ;
break ;
case TOUCH_INIT_MODE : SINGLE | Set touch mode to be TOUCH_DONE_MODE when calling doDoubleTap |
<nb> package NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
+ import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
<nb> public class TemplateLanguagePanel extends JPanel {
holder . setTemplateLanguage ( ( String ) templateLanguage ) ;
}
+ public void setTemplatesFolder ... | default for created templates directory should be related to inner project folder |
<nb>
package NAMESPACE ;
import NAMESPACE ;
+ import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
<nb> public class NeuralNetConfiguration implements Serializable , Cloneable {
ObjectMapper ret = new ObjectMapper ( ) ;
ret . configure ( DeserializationFeature . FAIL_ON_UNKNOW... | Switch NNC ObjectMapper to sort properties alphabetically |
<nb> public class TcpIncomingConnector implements IncomingConnector , AsyncStoppable {
InetSocketAddress remoteAddress = ( InetSocketAddress ) socket . socket ( ) . getRemoteSocketAddress ( ) ;
if ( ! localAddresses . contains ( remoteAddress . getAddress ( ) ) ) {
LOGGER . error ( STRING0 , remoteAddress . getAd... | Don t accept remote connections |
<nb> public class BeaconConfigFragment extends Fragment implements BeaconConfigHelper
Log . e ( TAG , STRING0 + status ) ;
} else {
UriBeacon uriBeacon = UriBeacon . parseFromBytes ( scanRecord ) ;
- final String url = ( uriBeacon != null ) ? uriBeacon . getUriString ( ) : STRING1 ;
+ String url = ( uriBeacon... | reinstated lengthened url in the edit urls card |
<nb> public class CAnalyzer extends PlainAnalyzer {
}
return super . tokenStream ( fieldName , reader ) ;
}
-
- public static String [ ] getMagics ( ) {
- return magics ;
- }
-
- public static String [ ] getSuffixes ( ) {
- return suffixes ;
- }
COMMENT
COMMENT
<nb> public class JavaAnalyz... | Removed dead code from the analyzers |
<nb> public class VMPluginFactory {
ClassLoader loader = VMPluginFactory . class . getClassLoader ( ) ;
loader . loadClass ( classNameCheck ) ;
return ( VMPlugin ) loader . loadClass ( pluginName ) . newInstance ( ) ;
- } catch ( Exception ex ) {
+ } catch ( Throwable ex ) {
return null ;
}
} | Catch Throwable because some runtimes may throw exceptions which do not extend Exception eg |
<nb> public abstract class NanoHTTPD {
}
} catch ( Exception e ) {
SINGLE
- SINGLE
- if ( ! ( e instanceof SocketException && STRING0 . equals ( e . getMessage ( ) ) ) ) {
+ SINGLE
+ SINGLE
+ SINGLE
+ if ( ! ( e instanceof SocketException && STRING0 . equals ( e . getMessage ( ) ) ) &&
+ ! ( e insta... | do not print stacktrace on SocketTimeoutException |
<nb> public abstract class LogEntry
@ override
public String toString ( TimeZone timeZone )
{
- SINGLE
return STRING0 + masterId + STRING1 + authorId + STRING2 +
timestamp ( timeWritten , timeZone ) + STRING3 +
- lastCommittedTxWhenTransactionStarted + STRING4 ;
+ lastCommittedTxWhenTransactionStarted +... | Resolves TODO in LogEntry by adding the extra header length in the toString of Start |
<nb> public abstract class AbstractCodecEmbedder < T > implements CodecEmbedder < T > {
private final ChannelPipeline pipeline ;
private final EmbeddedChannelSink sink = new EmbeddedChannelSink ( ) ;
- CodecEmbedderException exception ;
final Queue < Object > productQueue = new LinkedList < Object > ( ) ;
... | Removed unused member variable |
<nb> public class Client extends Connection implements EndPoint {
}
}
- public void setDiscoveryHandler ( ClientDiscoveryHandler newDiscoveryResponseHook ) {
- discoveryHandler = newDiscoveryResponseHook ;
+ public void setDiscoveryHandler ( ClientDiscoveryHandler newDiscoveryHandler ) {
+ discoveryHandle... | fixed the parameter name in the server and client setDiscoveryHandler |
<nb> public class MagicLinkSignInFragment extends SignInFragment {
public void run ( ) {
if ( userBlogList != null ) {
Intent intent = new Intent ( getActivity ( ) , WPMainActivity . class ) ;
- intent . setFlags ( Intent . FLAG_ACTIVITY_NEW_TASK ) ;
+ intent . setFlags ( Intent . FLAG_ACTIVITY_CLEAR_TASK | I... | Clearing the backstack as well |
<nb> public class InternalSettingsPreparerTests extends ElasticsearchTestCase {
SINGLE
Tuple < Settings , Environment > tuple = InternalSettingsPreparer . prepareSettings ( settingsBuilder ( )
. put ( STRING0 , true )
+ . put ( STRING1 , createTempDir ( ) . toString ( ) )
. build ( ) , true ) ;
assertThat... | TEST add path home to settings |
<nb>
COMMENT
- COMMENT
+ COMMENT
COMMENT
COMMENT
COMMENT
<nb>
package NAMESPACE ;
+ import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
<nb> public class DefaultListableBeanFactory extends AbstractAutowireCapableBeanFacto
return new SerializedBeanFactoryReference ... | throw NotSerializableException if no serialization id is available |
<nb> public class ReceiverActivity extends Activity {
JSONObject args = new JSONObject ( bundle . getString ( Receiver . OPTIONS ) ) ;
Options options = new Options ( getApplicationContext ( ) ) . parse ( args ) ;
- if ( LocalNotification . webView == null ) {
- launchMainIntent ( ) ;
- invokeBackgroundCall... | Simply launch the main intent as first and the invoke the callback in each case |
<nb> import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
- import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
<nb> public @ interface Default {
COMMENT
COMMENT
COMMENT
- COMMENT
+ COMMENT
COMMENT
COMMENT
COMMENT | Removed import that was required for javadoc as it fails checkstyle |
<nb>
package NAMESPACE ;
+ import NAMESPACE ;
+
import NAMESPACE ;
COMMENT
<nb> import NAMESPACE ;
public abstract class LeafNodeImpl extends NodeImpl {
SINGLE
+ @ weak
InnerNodeImpl parent ;
SINGLE | Fixed reference cycle |
<nb> import NAMESPACE ;
COMMENT
COMMENT
COMMENT
- abstract class AbstractBootstrap < B extends AbstractBootstrap < B , C > , C extends Channel > implements Cloneable {
+ public abstract class AbstractBootstrap < B extends AbstractBootstrap < B , C > , C extends Channel > implements Cloneable {
private vol... | Make AbstractBootstrap public |
<nb> public class TestNGDataProviderTest extends LightCodeInsightFixtureTestCase {
@ dataprovider
public Object [ ] [ ] data ( ) {
return new Object [ ] [ ] {
- new Object [ ] { STRING0 , ArrayUtil . EMPTY_STRING_ARRAY } ,
- new Object [ ] { STRING1 , ArrayUtil . EMPTY_STRING_ARRAY } ,
- new Object [ ] { ST... | convert testng junit |
<nb> import NAMESPACE ;
public class ReaderCommentList extends ArrayList < ReaderComment > {
- COMMENT
- if ( json == null )
- throw new IllegalArgumentException ( STRING0 ) ;
-
- ReaderCommentList comments = new ReaderCommentList ( ) ;
-
- JSONArray jsonComments = json . optJSONArray ( STRING1 ) ; ... | Removed unused ReaderCommentList fromJson |
<nb> public class Migrator {
outputSQLWriter . write ( STRING0 + changeLogFile + StreamUtil . getLineSeparator ( ) ) ;
outputSQLWriter . write ( STRING1 + DateFormat . getDateTimeInstance ( DateFormat . SHORT , DateFormat . SHORT ) . format ( new Date ( ) ) + StreamUtil . getLineSeparator ( ) ) ;
outputSQLWriter ... | include liquibase version in outputed sql |
<nb> public final class KotlinClassFileIndex extends ScalarIndexExtension < FqName > {
}
}
catch ( Throwable e ) {
- LOG . error ( STRING0 + inputData . getFileName ( ) , e ) ;
+ LOG . warn ( STRING0 + inputData . getFileName ( ) , e ) ;
}
return Collections . emptyMap ( ) ;
} | Replace LOG error with LOG warn when reading classfile with ASM |
<nb> import NAMESPACE ;
public interface BlurAlgorithm {
Bitmap blur ( Bitmap bitmap , int blurRadius ) ;
+
+ COMMENT
+ COMMENT
+ COMMENT
+ void destroy ( ) ;
+
+ boolean canReuseBitmap ( ) ;
} | Added destroy and canReuse methods |
<nb> public class IssuesTest {
}
}
+ @ test public void issue614 ( ) {
+ if ( TT . shortTest ( ) )
+ return ;
+
+
+ DBMaker . Maker dbMaker = DBMaker . memoryDB ( )
+ . fileMmapEnable ( )
+ . closeOnJvmShutdown ( ) ;
+ DB db = dbMaker . make ( ) ;
+
+ HTreeMap < Object , Object > nodeStats =... | add test case |
<nb> public class HighlightsExtractor {
if ( openTag == - NUMBER0 ) {
return null ;
}
- if ( text . charAt ( openTag + NUMBER0 ) == STRING0 ) {
+ while ( text . charAt ( openTag + NUMBER0 ) == STRING0 ) {
openTag ++ ;
}
if ( text . charAt ( openTag + NUMBER0 ) == STRING1 ) {
<nb> public class Highligh... | nik stack pop exception in |
<nb> public class CassandraServer extends FacebookBase implements Cassandra . Iface
public static void main ( String [ ] args ) throws Throwable
{
int port = DatabaseDescriptor . getThriftPort ( ) ;
+
+ Thread . setDefaultUncaughtExceptionHandler ( new Thread . UncaughtExceptionHandler ( )
+ {
+ public vo... | add defaultuncaughtexceptionhandler that logs runtime errors |
<nb> public class MySqlLexer extends Lexer {
token = LITERAL_CHARS ;
break ;
} else {
- initBuff ( bufPos ) ;
- arraycopy ( mark + NUMBER0 , buf , NUMBER1 , bufPos ) ;
- hasSpecial = true ;
+ if ( ! hasSpecial ) {
+ initBuff ( bufPos ) ;
+ arraycopy ( mark + NUMBER0 , buf , NUMBER1 , bufPos ) ;
+ ha... | Fixed a bug with scanning strings when there is more than one escaped single quote |
<nb> import NAMESPACE ;
COMMENT
SINGLE
@ converter
- public class CustomerTransformer {
+ public final class CustomerTransformer {
private static final Logger LOG = LoggerFactory . getLogger ( CustomerTransformer . class ) ;
+ private CustomerTransformer ( ) {
+ }
+
COMMENT
COMMENT
COMMENT | fixed CS error |
<nb> import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
+ import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
<nb> public class PhotoCropResultActivity extends BaseActivity {
setSupportActionBar ( toolbar ) ;
getSupportActionBar ( ) . setDisplayHomeAsUpEnabled ( true ) ;
+ int frameW ... | Crop result screen improvements |
<nb> public abstract class SharedTreeModelBuilder < TM extends DTree . TreeModel > extends
SINGLE
frs [ NUMBER0 ] . delete ( ) ;
SINGLE
+ res . delete ( ) ;
return this ;
}
<nb> public abstract class Model extends Lockable < Model > {
} else adaptedVec = frvecs [ c ] . makeTransf ( map [ c ] ) ;
ave... | Fixed key leaks in TreeModel scoring and model adaptation |
<nb> public class MapViewTrackingUtilities implements OsmAndLocationListener , IMapLoc
SINGLE
zdelta += NUMBER0 ;
}
- double targetZoom = Math . max ( tb . getZoom ( ) + tb . getZoomFloatPart ( ) + zdelta , settings . AUTO_ZOOM_MAP . get ( ) . maxZoom ) ;
+ double targetZoom = Math . min ( tb . getZoom ( ) + ... | Fix max min issue with autozoom |
<nb> public class BaseAppManager {
}
- public synchronized static BaseAppManager getInstance ( ) {
- if ( instance == null ) {
- instance = new BaseAppManager ( ) ;
+ public static BaseAppManager getInstance ( ) {
+ if ( null == instance ) {
+ synchronized ( BaseAppManager . class ) {
+ if ( null ==... | Optimize concurrent efficiency |
<nb> public abstract class AbstractModelStructSchema < T > extends AbstractModelSchema < T
for ( ModelProperty < ? > property : properties ) {
if ( ! builder . containsKey ( property . getName ( ) ) ) {
builder . put ( property . getName ( ) , property ) ;
+ } else {
+ ModelProperty < ? > modelProperty = buil... | Add guard to make sure only boolean properties are allowed to have duplicates |
<nb> final class Tokenizer {
private Token pullQuotedString ( ) throws ProblemException {
SINGLE
StringBuilder sb = new StringBuilder ( ) ;
- int c = STRING0 ; SINGLE
- do {
- c = nextCharRaw ( ) ;
+ while ( true ) {
+ int c = nextCharRaw ( ) ;
if ( c == - NUMBER0 )
throw problem ( STRING1 ) ;
i... | Avoid awkward do while in Tokenizer pullQuotedString |
<nb> public class SoloAssertion {
boolean found = false ;
assertCurrentActivity ( message , expectedClass ) ;
Activity activity = soloActivity . getCurrentActivity ( ) ;
- for ( int i = NUMBER0 ; i < soloActivity . getActivityList ( ) . size ( ) - NUMBER1 ; i ++ ) {
- String instanceString = soloActivity . ge... | Changed it so that it uses getAllOpenedActivities instead |
<nb> public interface Translog extends IndexShardComponent {
Snapshot snapshot ( Snapshot snapshot ) ;
COMMENT
+ COMMENT
+ COMMENT
+ void flush ( ) ;
+
+ COMMENT
COMMENT
COMMENT
void close ( boolean delete ) ;
<nb> public class FsTranslog extends AbstractIndexShardComponent implements Translog
... | add flush to gateway |
<nb>
package NAMESPACE ;
- import NAMESPACE ;
- import NAMESPACE ;
- import NAMESPACE ;
- import NAMESPACE ;
- import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ; | remove unused imports |
<nb> import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
+ import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
<nb> public class FileSystemMasterIntegrationTest {
mFsMaster =
mLocalTachyonClusterResource . get ( ) . getMaster ( ) . getInternalMaster ( ... | Add back defensive ttl setting |
<nb> public abstract class VideoCallProvider {
switch ( msg . what ) {
case MSG_SET_VIDEO_CALL_LISTENER :
mVideoCallListener = IVideoCallCallback . Stub . asInterface ( ( IBinder ) msg . obj ) ;
+ break ;
case MSG_SET_CAMERA :
onSetCamera ( ( String ) msg . obj ) ;
break ; | Adding missing break statement in VideoCallProvider |
<nb> import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
+ import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
+ import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
<nb> public class SWTVisualizationGUI implements SelectionListener , Runnable { ... | Visualization component now ignores the client s job and vertex events |
<nb>
package NAMESPACE ;
- import NAMESPACE ;
- import NAMESPACE ;
import NAMESPACE ;
- import NAMESPACE ;
-
- import NAMESPACE ;
COMMENT
- COMMENT
- COMMENT
- COMMENT
- COMMENT
- COMMENT
+ COMMENT
COMMENT
public interface JspElementDescriptor extends XmlElementDescriptor {
- @ nul... | don t expose JavaEE interfaces in jsp spi |
<nb> public class Transaction extends ChildMessage implements Serializable {
COMMENT
public boolean isFinal ( int height , long blockTimeSeconds ) {
SINGLE
- if ( lockTime == NUMBER0 )
+ long time = getLockTime ( ) ;
+ if ( time == NUMBER0 )
return true ;
- if ( lockTime < ( lockTime < LOCKTIME_THRESHOL... | Always use getLockTime in isFinal |
<nb> import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
+ import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
<nb> public class ConfigImpl {
}
}
+ private static Properties getSystemProperties ( ) {
+ SINGLE
+ final Properties systemProperties = System . getProp... | Fix ConcurrentModificationException that occurs when system properties are being modified during a call to ConfigImpl loadSystemProperties |
<nb> package NAMESPACE ;
import NAMESPACE ;
import static NAMESPACE ;
+ import static NAMESPACE ;
import static NAMESPACE ;
public class ExternalProcessRunnerTest {
<nb> public class ExternalProcessRunnerTest {
assertEquals ( NUMBER0 , result ) ;
SINGLE
- assertEquals ( runner . getErrorOutput (... | hotfix Relax test condition in ExternalProcessRunnerTest |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.