diff
stringlengths
38
1.78k
msg_token
stringlengths
9
190
<nb> public final class Iterators { } COMMENT - COMMENT - COMMENT - COMMENT - COMMENT - COMMENT - COMMENT - COMMENT - COMMENT - @ beta - @ deprecated - public static int skip ( Iterator < ? > iterator , int numberToSkip ) { - return advance ( iterator , numberToSkip ) ; - } - - COMME...
Remove Iterators skip
<nb> public class BitcoinSerializerTest { STRING0 + STRING1 ; byte [ ] headersMessageBytes = HEX . decode ( headersMessageBytesHex ) ; - HeadersMessage hm = ( HeadersMessage ) bs . deserialize ( ByteBuffer . wrap ( HEX . decode ( headersMessageBytesHex ) ) ) ; + HeadersMessage hm = ( HeadersMessage ) bs . des...
Factored out a common sub expression
<nb> public class JsFacade implements Exportable { return messenger . getStickers ( ) . get ( ) ; } + public void bindStickers ( JsBindedValueCallback callback ) { + messenger . getStickers ( ) . subscribe ( callback ) ; + } + + public void unbindStickers ( JsBindedValueCallback callback ) { + messeng...
Added bind unbind Stickers
<nb> public class TestStandardContext extends TomcatBaseTest { SINGLE if ( enableDeny ) { - Assert . assertEquals ( STRING0 , bc . toString ( ) ) ; + SINGLE + Assert . assertTrue ( bc . toString ( ) . contains ( STRING1 ) ) ; Assert . assertEquals ( NUMBER0 , rc ) ; } else { Assert . assertEquals ( ST...
Fix broken test
<nb> import NAMESPACE ; COMMENT public class KeyguardTouchDelegate { SINGLE - static final String KEYGUARD_PACKAGE = STRING0 ; - static final String KEYGUARD_CLASS = STRING1 ; + static final String KEYGUARD_PACKAGE = STRING2 ; + static final String KEYGUARD_CLASS = STRING3 ; private static KeyguardTou...
Fix incoming phone calls on lockscreen
<nb> public class ErrorOldTest extends DatabaseTestCase { assertTrue ( database . getLastError ( ) . get ( STRING0 ) == null ) ; assertTrue ( database . getPreviousError ( ) . get ( STRING0 ) == null ) ; - } catch ( Exception e ) { + } finally { database . requestDone ( ) ; } }
fix driver compat make ErrorOldTest testPrevError to call requestDone on exit
<nb> public abstract class Flow extends Iced { public FlowGroupBy with ( GroupBy fr ) { return new FlowGroupBy ( fr , this ) ; } + public FlowFilter with ( Filter filter ) { + return new FlowFilter ( filter , this ) ; + } @ override Frame frame ( ) { return _ex . frame ( ) ; } @ override public String t...
Extend FlowFilter to include with for other filters
<nb> public class MtpDatabase { values . put ( Audio . Playlists . DATA , path ) ; values . put ( Audio . Playlists . NAME , name ) ; values . put ( Files . FileColumns . FORMAT , format ) ; + values . put ( Files . FileColumns . DATE_MODIFIED , System . currentTimeMillis ( ) / NUMBER0 ) ; values . put ( Medi...
Set modification date for abstract playlists
<nb> public class JsParser { return new JsParser ( ) . parseImpl ( rootSourceInfo , scope , r ) ; } - public static void parseInto ( - SourceInfo rootSourceInfo , JsScope scope , - JsBlock block , Reader r - ) throws IOException , JsParserException { - List < JsStatement > childStmts = parse ( rootSourc...
removed unused function
<nb> public final class OperatorZipIterable < T1 , T2 , R > implements Operator < R , T1 > { @ override public void onError ( Throwable e ) { if ( done ) { + Exceptions . throwIfFatal ( e ) ; return ; } done = true ;
Don t swallow fatal errors in OperatorZipIterable
<nb> public final class TabLayoutSelectionEvent extends ViewEvent < TabLayout > { } @ override public String toString ( ) { - return STRING0 + view ( ) + STRING1 + kind + STRING2 + tab + STRING3 ; + return STRING4 + view ( ) + STRING1 + kind + STRING2 + tab + STRING3 ; } }
Fix typo in TabLayoutSelectionEvent toString
<nb> public class Wallet implements Serializable , BlockChainListener { SINGLE private int version ; SINGLE - String description ; + private String description ; COMMENT COMMENT
Make wallet description private
<nb> public class Engine implements SensorEventListener , OnTouchListener , ITouchEvent } } - @ override public boolean onTouchEvent ( final TouchEvent pSurfaceTouchEvent ) { COMMENT <nb> public abstract class BaseOnScreenControl extends HUD implements IOnSceneTouchLi final int pointerID = pSceneTouch...
Fixed a bug in BaseOnScreenControls where the knob was locked in some rare multitouch conditions
<nb> public class ExecEndpointTest extends AbstractJUnit4SpringContextTests { ExecEndpoint e = createExecEndpoint ( STRING0 + args . replaceAll ( STRING1 , STRING2 ) ) ; assertEquals ( args , e . getArgs ( ) ) ; } - + @ test @ dirtiescontext public void testCreateEndpointWithArgs2 ( ) throws Exception {...
Added an unit test to show how to set the to the exec args option
<nb> COMMENT package NAMESPACE ; - import NAMESPACE ; import NAMESPACE ; import NAMESPACE ; - import NAMESPACE ; import NAMESPACE ; import NAMESPACE ;
Remove unused imports
<nb> public class ServiceState implements Parcelable { mOperatorNumeric = m . getString ( STRING0 ) ; mIsManualNetworkSelection = m . getBoolean ( STRING1 ) ; mRilVoiceRadioTechnology = m . getInt ( STRING2 ) ; - mRilVoiceRadioTechnology = m . getInt ( STRING3 ) ; + mRilDataRadioTechnology = m . getInt ( STRI...
Fix typo for radio technology
<nb> public class Http2Server content += STRING0 + request . getRequestURI ( ) + STRING1 ; content += STRING2 + session . getId ( ) + ( session . isNew ( ) ? STRING3 : STRING1 ) ; content += STRING4 + new Date ( ) + STRING1 ; + + for ( Cookie c : request . getCookies ( ) ) + content += STRING5 + c . getName...
AsyncNCSARequestLog blocks JVM exit after failure
<nb> public class TheTVDB { HttpURLConnection conn = AndroidUtils . buildHttpUrlConnection ( url ) ; conn . connect ( ) ; long imageSize = conn . getContentLength ( ) ; - SINGLE - SINGLE - if ( imageSize > NUMBER0 ) { + SINGLE + SINGLE + if ( imageSize > NUMBER1 ) { return null ; } else { inputS...
Allow bigger images
<nb> public class NodeCmd COMMENT public void printInfo ( PrintStream outs ) { + boolean gossipInitialized = probe . isInitialized ( ) ; outs . println ( probe . getToken ( ) ) ; - outs . printf ( STRING0 , STRING1 , probe . isInitialized ( ) ) ; + outs . printf ( STRING0 , STRING1 , gossipInitialized ) ;...
Fix NPE in nodetool when gossip isn t initialized
<nb> public class AppearanceUIModel { Method get = entry . getValue ( ) [ NUMBER0 ] ; Method set = entry . getValue ( ) [ NUMBER1 ] ; if ( ! ( get != null && set != null - && set . getParameterCount ( ) == NUMBER1 && get . getParameterCount ( ) == NUMBER0 + && set . getParameterTypes ( ) . length == NUMBER1 &...
Fix minor Java incompatibility
<nb> public class ArrayNode extends AbstractArrayNode { } COMMENT - COMMENT + COMMENT COMMENT COMMENT COMMENT COMMENT - public ArrayNode ( final Collection < ? extends IJsonNode > nodes ) { + public ArrayNode ( final Iterable < ? extends IJsonNode > nodes ) { this ( ) ; for ( final IJsonNode n...
Fixed ctor of ArrayNode thus tracing of Reduce and CoGroups
<nb> public class Base32String { return INSTANCE ; } - SINGLE + SINGLE private String ALPHABET ; private char [ ] DIGITS ; private int MASK ;
Fixed a misleading comment in Base32String java that claimed that letters I and O are not part of the alphabet
<nb> package NAMESPACE ; import NAMESPACE ; + import NAMESPACE ; import NAMESPACE ; import NAMESPACE ; <nb> public class EnumSerializer extends Serializer { if ( ordinal == - NUMBER0 ) return null ; T [ ] enumConstants = c . getEnumConstants ( ) ; + if ( enumConstants == null ) + throw new Ser...
A change from a while back that presents a slightly better
<nb> package NAMESPACE ; import NAMESPACE ; + import NAMESPACE ; import NAMESPACE ; - import NAMESPACE ; import NAMESPACE ; + import NAMESPACE ; import NAMESPACE ; COMMENT <nb> package NAMESPACE ; import NAMESPACE ; - import NAMESPACE ; - import NAMESPACE ; import NAMESPACE ; i...
Fixed some CS errors
<nb> public class HttpSession extends LocalClientSession { COMMENT Log . warn ( STRING0 ) ; } catch ( IOException e ) { - SINGLE + Log . warn ( STRING1 , e ) ; } } } <nb> public class HttpSession extends LocalClientSession { } catch ( HttpConnectionClosedException e ) { COMMENT } catch ( IOExcep...
Don t swallow exceptions log them instead
<nb> public final class BlockMaster extends MasterBase implements ContainerIdGenerabl if ( masterBlockInfo == null ) { continue ; } - ArrayList < Long > workersToRemove = new ArrayList < Long > ( ) ; - for ( long workerId : masterBlockInfo . getWorkers ( ) ) { - workersToRemove . add ( workerId ) ; + for ...
Write the logic in a simpler way
<nb> public class ItemStack implements ConfigurationSerializable { int amount = NUMBER0 ; if ( args . containsKey ( STRING0 ) ) { - damage = ( Short ) args . get ( STRING0 ) ; + damage = ( ( Number ) args . get ( STRING0 ) ) . shortValue ( ) ; } if ( args . containsKey ( STRING1 ) ) {
Bleeding Fixed class cast in ItemStack deserialization
<nb> import NAMESPACE ; import NAMESPACE ; import NAMESPACE ; + import static NAMESPACE ; + public class CCFromCourseArchive extends DumbAwareAction { private static final Logger LOG = Logger . getInstance ( CCFromCourseArchive . class . getName ( ) ) ; <nb> public class CCFromCourseArchive extends Du...
set course directory in from course archive action
<nb> public abstract class KeyguardPinBasedInputView extends KeyguardAbsKeyInputView SINGLE mPasswordEntry . setSelected ( true ) ; - SINGLE - mPasswordEntry . setOnClickListener ( new OnClickListener ( ) { - public void onClick ( View v ) { - onUserInput ( ) ; - } - } ) ; - mPasswordEntry . setUs...
Remove click listener from PIN views
<nb> public class ConversationActivity extends XmppActivity { break ; case R . id . action_attach_file : View menuAttachFile = findViewById ( R . id . action_attach_file ) ; + if ( menuAttachFile == null ) { + break ; + } PopupMenu attachFilePopup = new PopupMenu ( this , menuAttachFile ) ; attachFilePo...
fixed rare bug with attach image menu
<nb> public class StringUtils { int indexOf = buffer . indexOf ( partToMatch ) ; while ( indexOf != - NUMBER0 ) { buffer = buffer . replace ( indexOf , indexOf + partToMatch . length ( ) , replacement ) ; - indexOf = buffer . indexOf ( partToMatch ) ; + indexOf = buffer . indexOf ( partToMatch , indexOf + rep...
Fixed infinite loop in StringUtils replace
<nb> public class MediaRouter { for ( int i = NUMBER0 ; i < count ; i ++ ) { final CallbackInfo info = sStatic . mCallbacks . get ( i ) ; if ( info . cb == cb ) { - info . type &= types ; + info . type |= types ; return ; } } <nb> public class MediaRouter { if ( cat . isGroupable ( ) && ! ( info ins...
Fix MediaRouter bugs
<nb> public abstract class BitUtil public abstract byte [ ] fromBitString ( String str ) ; + COMMENT + COMMENT + COMMENT public final String toBitString ( long value ) { return toBitString ( value , NUMBER0 ) ; <nb> public abstract class BitUtil return ( int ) ( longValue > > NUMBER1 ) ; } -...
added comment to bitutil
<nb> import NAMESPACE ; import NAMESPACE ; import NAMESPACE ; import NAMESPACE ; - import NAMESPACE ; - import NAMESPACE ; import NAMESPACE ; import NAMESPACE ; import NAMESPACE ; <nb> public class PsiClassImpl extends JavaStubPsiElement < PsiClassStub < ? > > implements PsiElement parent = getPar...
decouple PsiClassImpl from JspClass
<nb> public class CompactionManager implements CompactionManagerMBean } else { + cfs . invalidateCachedRow ( row . getKey ( ) ) ; while ( row . hasNext ( ) ) { IColumn column = row . next ( ) ;
Make clean compactions cleanup the row cache
<nb> import NAMESPACE ; import NAMESPACE ; import NAMESPACE ; import NAMESPACE ; - import NAMESPACE ; import NAMESPACE ; import NAMESPACE ; import NAMESPACE ; <nb> public class DriverConductorTest private final ByteBuffer toEventBuffer = ByteBuffer . allocateDirect ( EventConfiguration . BUFFER_LENG...
Remove no longer needed dependencies from DriverConductorTest
<nb> public abstract class AbstractBeanFactory extends FactoryBeanRegistrySupport imp COMMENT protected void markBeanAsCreated ( String beanName ) { if ( ! this . alreadyCreated . contains ( beanName ) ) { - this . alreadyCreated . add ( beanName ) ; - SINGLE SINGLE clearMergedBeanDefinition ( beanName ...
AbstractBeanFactory markBeanAsCreated reliably clears merged bean definition first
<nb> public final class FBReader extends ZLApplication { private final BookTextView myBookTextView ; private final ContentsView myContentsView ; private final FootnoteView myFootnoteView ; + private final CollectionView myCollectionView ; private final RecentBooksView myRecentBooksView ; private BookModel...
added myCollectionView field
<nb> public class BluetoothMidiService extends Service { device = mDeviceServerMap . get ( bluetoothDevice ) ; if ( device == null ) { device = new BluetoothMidiDevice ( this , bluetoothDevice , this ) ; + mDeviceServerMap . put ( bluetoothDevice , device ) ; } } return device . getBinder ( ) ;
add new device to HashMap
<nb> import NAMESPACE ; COMMENT COMMENT COMMENT - COMMENT + COMMENT + COMMENT COMMENT COMMENT COMMENT <nb> public class CommandLineRunner extends private CompilerOptions . DevMode jscomp_dev_mode = CompilerOptions . DevMode . OFF ; - SINGLE @ option ( name = STRING0 , usage = STRING1 +...
Remove obsolete comment
<nb> public class Portuguese extends Language { new DoublePunctuationRule ( messages ) , new GenericUnpairedBracketsRule ( messages ) , new HunspellNoSuggestionRule ( messages , this ) , + new LongSentenceRule ( messages ) , new UppercaseSentenceStartRule ( messages , this ) , new WordRepeatRule ( messages ...
pt activate LongSentenceRule
<nb> public class JavaScriptCompressor { public void compress ( Writer out , int linebreak , boolean munge , boolean verbose , boolean preserveAllSemiColons , boolean disableOptimizations ) throws IOException { - compress ( out , null , linebreak , munge , verbose , preserveAllSemiColons , disableOptimizations ...
Preserve legacy constructor
<nb> package NAMESPACE ; public class Ssl { COMMENT - COMMENT + COMMENT COMMENT private ClientAuth clientAuth ; + COMMENT + COMMENT + COMMENT private String [ ] ciphers ; + COMMENT + COMMENT + COMMENT private String keyAlias ; + COMMENT + COMMENT + COMMENT private String keyP...
Add documentation for Ssl properties
<nb> package NAMESPACE ; import NAMESPACE ; import NAMESPACE ; + import NAMESPACE ; import NAMESPACE ; import NAMESPACE ; import NAMESPACE ; <nb> public abstract class ClsRepositoryPsiElement < T extends StubElement > extends Cls } public PsiManager getManager ( ) { - return getContainingFile ( ...
Replace NPE with PsiInvalidElementAccessException
<nb> public class ReaderTagTable { protected static void createTables ( SQLiteDatabase db ) { db . execSQL ( STRING0 - + STRING1 - + STRING2 - + STRING3 - + STRING4 - + STRING5 - + STRING6 - + STRING7 - + STRING8 ) ; + + STRING9 + + STRING10 + + STRING11 + + STRING12 + + STRING13 + + S...
Corrected ReaderTagTable spacing in createTables
<nb> public class MUCRoomAdminsService { MUCRoomController . getInstance ( ) . deleteAffiliation ( serviceName , roomName , jid ) ; return Response . status ( Status . OK ) . build ( ) ; } + + @ delete + @ path ( STRING0 ) + public Response deleteMUCRoomAdminGroup ( @ pathparam ( STRING1 ) String groupnam...
add missing change for deleting admin groups
<nb> public class ViewAsGroup extends ActionGroup implements DumbAware { final DebuggerContextImpl debuggerContext = DebuggerAction . getDebuggerContext ( event . getDataContext ( ) ) ; final List < JavaValue > values = getSelectedValues ( event ) ; if ( values . isEmpty ( ) ) { + event . getPresentation ( ) . ...
do not show view as for non java debuggers
<nb> package NAMESPACE ; COMMENT - COMMENT + COMMENT COMMENT COMMENT COMMENT
Fixed a typo in HazelcastOverloadException class javadoc
<nb> public class AndroidStudioInfoAspectTest extends BuildViewTestCase { STRING0 + STRING1 ) ; } + + public void testNonConformingPackageName ( ) throws Exception { + scratch . file ( + STRING2 , + STRING3 , + STRING4 , + STRING5 , + STRING6 + ) ; + String target = STRING7 ; + Map < String ...
Add Android aspect test for non conforming java package
<nb> import NAMESPACE ; import NAMESPACE ; import NAMESPACE ; import NAMESPACE ; + import NAMESPACE ; import NAMESPACE ; import NAMESPACE ; import NAMESPACE ; <nb> public class IndyInterface { } else if ( receiver instanceof GroovyObject ) { return ( ( GroovyObject ) receiver ) . getMetaClass ( ) ; ...
make meta class lookup respect per instance meta classes for java classes
<nb> public class HiveClient { try { Table table = metastore . getTable ( tableName . getSchemaName ( ) , tableName . getTableName ( ) ) ; + if ( table . getTableType ( ) . equals ( TableType . VIRTUAL_VIEW . name ( ) ) ) { + throw new TableNotFoundException ( tableName ) ; + } List < ColumnMetadata > col...
Fix listing columns from Presto views in Hive
<nb> COMMENT - COMMENT + COMMENT COMMENT COMMENT COMMENT <nb> public class EditorHeaderComponent extends JPanel { } public static void paintGradient ( Graphics g , JComponent c ) { - Color GRADIENT_C1 = new JBColor ( c . getBackground ( ) , JBColor . background ( ) ) ; + Color GRADIENT_C1 = JBCo...
editor top component has wrong gradient color
<nb> import NAMESPACE ; COMMENT COMMENT COMMENT - COMMENT - COMMENT - COMMENT - COMMENT - COMMENT - COMMENT - COMMENT COMMENT COMMENT @ incubating
Remove calculation description javadoc from EclipseJavaSourceSettings
<nb> public class AndroidBinaryRule extends DoNotUseAbstractBuildable implements nativeLibraryDirectories . add ( libSubdirectory ) ; commands . add ( new MakeCleanDirectoryStep ( libSubdirectory ) ) ; for ( String nativeLibDir : transitiveDependencies . nativeLibsDirectories ) { - SINGLE - if ( nativeLibDir ...
Remove unnecessary check to strip trailing from native library path
<nb> public class ImageWallpaper extends WallpaperService { } public void trimMemory ( int level ) { - if ( level >= ComponentCallbacks2 . TRIM_MEMORY_RUNNING_LOW && - mBackground != null ) { + if ( level >= ComponentCallbacks2 . TRIM_MEMORY_RUNNING_LOW + && level <= ComponentCallbacks2 . TRIM_MEMORY_RUNN...
Don t throw away wallpaper bitmap just because we are hidden
<nb> public abstract class ODatabasePoolAbstract < DB extends ODatabase > implements ORe OResourcePool < String , DB > pool = pools . get ( name ) ; if ( pool == null ) { synchronized ( pools ) { + pool = pools . get ( name ) ; if ( pool == null ) { pool = new OResourcePool < String , DB > ( maxSize , this ...
Fixed issue on concurrent access signaled by Ignacio dev xentient com on forum
<nb> public class RootAction < T extends Repository > extends ActionGroup { COMMENT COMMENT public RootAction ( @ notnull T repository , @ nullable T currentRepository , @ notnull ActionGroup actionsGroup , @ notnull String branchText ) { - super ( DvcsUtil . getShortRepositoryName ( repository ) , true ) ; +...
git prohibit mnemonics in root names
<nb> package NAMESPACE ; + import NAMESPACE ; import NAMESPACE ; + import NAMESPACE ; + import NAMESPACE ; import NAMESPACE ; + import NAMESPACE ; + import NAMESPACE ; + @ runwith ( HazelcastParallelClassRunner . class ) + @ category ( { QuickTest . class , ParallelTest . class } ) public clas...
Added missing RunWith and Category to ClientProtocolErrorCodesTest
<nb> public class SSLSocketHttpConnectionProvider extends SocketHttpConnectionProvide this . socketFactory = sslContext . getSocketFactory ( ) ; } - @ override protected SocketFactory getSSLSocketFactory ( ) throws Exception { return socketFactory ; }
Removes override notation for getSSLSocketFactory because of signature conflict
<nb> import NAMESPACE ; import NAMESPACE ; import NAMESPACE ; import NAMESPACE ; + import NAMESPACE ; import NAMESPACE ; import NAMESPACE ; import NAMESPACE ; <nb> public class PyPsiUtils { return QualifiedName . fromComponents ( componentNames ) ; } + COMMENT + COMMENT + COMMENT public st...
Using PyPsiUtils to prevent copy paste
<nb> public abstract class PsiFileImpl extends ElementBase implements PsiFileEx , PsiF private void switchFromStubToAst ( List < Pair < StubBasedPsiElementBase , AstPath > > bindings ) { if ( ! bindings . isEmpty ( ) && myUseStrongRefs ) { - LOG . error ( this + STRING0 + getClass ( ) + STRING1 + bindings ) ; ...
don t call psi toString to avoid SOE in cases it does getText
<nb> public class OpenStreetMapGraphBuilderImpl implements GraphBuilder { COMMENT @ setter private CustomNamer customNamer ; + + COMMENT + COMMENT + COMMENT + @ setter + private boolean ignoreWheelchairAccessibility = false ; COMMENT COMMENT <nb> public class OpenStreetMapGraphBuilderImpl impl...
Add option to ignore wheelchair accessibility
<nb> public class IabHelper { } logDebug ( STRING0 + packageName ) ; mSetupDone = true ; + + if ( listener != null ) { + listener . onIabSetupFinished ( new IabResult ( BILLING_RESPONSE_RESULT_OK , STRING1 ) ) ; + } } catch ( RemoteException e ) { if ( listener != null ) { <nb> public class IabHel...
Fix billing lib bug
<nb> public class Wallet extends BaseTaggableObject SINGLE builder . append ( STRING0 ) ; + builder . append ( STRING1 ) . append ( Utils . dateTimeFormat ( getEarliestKeyCreationTime ( ) * NUMBER0 ) ) + . append ( STRING2 ) ; final Date keyRotationTime = getKeyRotationTime ( ) ; if ( keyRotationTime != n...
Print earliest key creation time in toString
<nb> public abstract class AbstractTransportTest { SINGLE blockingStub . emptyCall ( Empty . getDefaultInstance ( ) ) ; TestServiceGrpc . newBlockingStub ( channel ) - . withDeadlineAfter ( NUMBER0 , TimeUnit . MILLISECONDS ) + . withDeadlineAfter ( NUMBER1 , TimeUnit . SECONDS ) . streamingOutputCall ( Str...
Fix flaky test
<nb> public abstract class SpringBootCondition implements Condition { return outcome . isMatch ( ) ; } catch ( NoClassDefFoundError ex ) { - throw new IllegalStateException ( - STRING0 - + STRING1 - + STRING2 - + STRING3 , ex ) ; + throw new IllegalStateException ( STRING4 + + classOrMethodName + ST...
Include condition s location class or method name in message
<nb> public class GCLoggingCollector implements DataCollector { public void beforeExecute ( File testProjectDir , GradleExecuter executer ) { logFile = new File ( testProjectDir , STRING0 ) ; + + SINGLE + SINGLE + SINGLE executer . withGradleOpts ( STRING1 + logFile . getAbsolutePath ( ) ) ; }
Documented a design choice
<nb> import NAMESPACE ; @ path ( STRING0 ) public class MyResource { @ get - @ produces ( { STRING1 , STRING2 } ) + @ produces ( { STRING3 , STRING4 } ) SINGLE public Person [ ] getList ( ) { Person [ ] list = new Person [ NUMBER0 ] ;
Adding qs attributes
<nb> package NAMESPACE ; import NAMESPACE ; - import NAMESPACE ; + import NAMESPACE ; + import NAMESPACE ; + import NAMESPACE ; import NAMESPACE ; import NAMESPACE ; import NAMESPACE ; import NAMESPACE ; - import NAMESPACE ; + import NAMESPACE ; + import NAMESPACE ; + import NAMESPACE ; ...
Fix maven tests
<nb> public abstract class WelcomeActivity extends AppCompatActivity { protected void onCreate ( Bundle savedInstanceState ) { mConfiguration = configuration ( ) ; SINGLE - super . setTheme ( mConfiguration . getThemeResId ( ) ) ; + if ( mConfiguration . getThemeResId ( ) != WelcomeConfiguration . NO_THEME_SE...
Don t apply theme if it isn t set
<nb> public class SitePickerActivity extends ActionBarActivity WordPress . wpDB . updateLastBlogId ( site . localId ) ; setResult ( RESULT_OK ) ; mDidUserSelectSite = true ; + hideSoftKeyboard ( ) ; finish ( ) ; } }
Hiding soft keyboard on site selection
<nb> import NAMESPACE ; COMMENT COMMENT + COMMENT + COMMENT + COMMENT + COMMENT + COMMENT COMMENT COMMENT COMMENT
Improve Double Checked Locking Javadoc
<nb> public class DevicePolicyManager { } COMMENT - COMMENT - COMMENT + COMMENT + COMMENT COMMENT - COMMENT + COMMENT + COMMENT COMMENT - COMMENT + COMMENT COMMENT public boolean isUninstallBlocked ( ComponentName admin , String packageName ) { if ( mService != null ) { <nb> public c...
Remove permission check in DevicePolicyManager isUninstallBlocked
<nb> public class PermissionCheckTest { public void setStateSuccessTest ( ) throws Exception { SINGLE Configuration conf = MasterContext . getConf ( ) ; - conf . set ( Constants . SECURITY_AUTHORIZATION_PERMISSIONS_UMASK , STRING0 ) ; + conf . set ( Constants . SECURITY_AUTHORIZATION_PERMISSIONS_UMASK , STRIN...
Fixing a failing test
<nb> public abstract class AbstractExcerpt implements Excerpt { @ suppresswarnings ( STRING0 ) @ override public < E > void writeEnum ( E e ) { - Class aClass = ( Class ) e . getClass ( ) ; - if ( aClass == null ) + Class aClass ; + if ( e == null ) aClass = String . class ; + else + aClass = ( Clas...
Handle null enum values
<nb> public class ScreenShot { Matrix matrix = new Matrix ( ) ; matrix . postScale ( widthScale , widthScale ) ; + Log . e ( STRING0 , STRING1 + widthScale + STRING2 + + STRING3 + sanpWidth * widthScale + STRING2 + + STRING4 + sanpWidth * snapHeight ) ; + b = Bitmap . createBitmap ( bitmap , NUMBER0 , N...
test log the real revolution of snapshot
<nb> public class ZooClient implements Watcher long tx = buf . getLong ( ) ; if ( tx >= highestTxId ) { - highestTxId = tx ; - if ( seq < lowestSeq ) + if ( tx > highestTxId || seq < lowestSeq ) { currentMasterId = id ; lowestSeq = seq ; } + highestTxId = tx ; } } catch ( KeeperException inn...
Fixed bug in master election
<nb> import NAMESPACE ; import NAMESPACE ; import NAMESPACE ; import NAMESPACE ; - import NAMESPACE ; - import NAMESPACE ; + import NAMESPACE ; + import NAMESPACE ; import NAMESPACE ; import NAMESPACE ;
Resolve import conflicts
<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 WorkerProcessIntegrationTest { execute ( worker ( ne...
Temporarily ignore int test
<nb> public class IpnbUtils { STRING0 ; private static final String ourPostfix = STRING1 ; - private static final MarkdownProcessor ourMarkdownProcessor = new MarkdownProcessor ( ) ; private static URL ourStyleUrl ; public static JComponent createLatexPane ( @ notnull final String source , int width ) { ...
do not use markdown processor blindly
<nb> public class TileSetLayout extends TileSet { int stopWidth = image . getWidth ( ) - tileSet . tileWidth ; int stopHeight = image . getHeight ( ) - tileSet . tileHeight ; - for ( y = tileSet . margin ; y < stopHeight ; y += tileSet . tileHeight + tileSet . spacing ) { - for ( x = tileSet . margin ; x < st...
The comparison should include the extreme limits rather than exclude them
<nb> public class HtmlUtil { tagName . equalsIgnoreCase ( STRING0 ) ) || attrName . equalsIgnoreCase ( STRING1 ) || - ( ( attrName . equals ( STRING2 ) || - attrName . equals ( STRING3 ) ) && + ( attrName . equals ( STRING3 ) && tag . getNamespacePrefix ( ) . length ( ) == NUMBER0 && ! ( tag instanceof ...
do not add self reference to id for html
<nb> public class AndroidCommon { . addRunfiles ( ruleContext , RunfilesProvider . DEFAULT_RUNFILES ) . build ( ) ; } - return javaCommon . getRunfiles ( asNeverLink ) ; + return JavaCommon . getRunfiles ( + ruleContext , javaCommon . getJavaSemantics ( ) , javaCommon . getJavaCompilationArtifacts ( ) , +...
Remove last non static call to JavaCommon getRunfiles and the method itself
<nb> public abstract class AbstractEmbeddedServletContainerFactory extends file = file != null ? file : getExplodedWarFileDocumentRoot ( ) ; SINGLE file = file != null ? file : getCommonDocumentRoot ( ) ; - if ( file == null && this . logger . isWarnEnabled ( ) ) { + if ( file == null && this . logger . isDeb...
Fix debug logging
<nb> public class Wallet extends BaseTaggableObject } catch ( ScriptException e ) { SINGLE } + if ( tx . hasConfidence ( ) ) + builder . append ( STRING0 ) . append ( tx . getConfidence ( ) ) . append ( STRING1 ) ; builder . append ( tx . toString ( chain ) ) ; } }
Add transaction confidence back to Wallet toString
<nb> final class NativeDaemonConnector implements Runnable { Slog . e ( TAG , String . format ( STRING0 , event ) , ex ) ; } - } - try { - mResponseQueue . put ( event ) ; - } catch ( InterruptedException ex ) { - Slog . e ( TAG , STRING1 , ex ) ; + } else { + try { + mResponseQueue . put ( event ...
Do not add unsolicited events to queue
<nb> import NAMESPACE ; public class GraphDbModule { - private static final CacheType DEFAULT_CACHE_TYPE = CacheType . weak ; + private static final CacheType DEFAULT_CACHE_TYPE = CacheType . soft ; private static Logger log = Logger . getLogger ( GraphDbModule . class . getName ( ) ) ; private boolean ...
Uses the soft reference cache as default instead of the weak type
<nb> public class CLIAccessControl { final ModelNode defaults = accessControl . get ( Util . DEFAULT ) ; if ( ! defaults . has ( Util . OPERATIONS ) ) { - log . warn ( STRING0 + accessControl ) ; + log . warn ( STRING0 + defaults ) ; return false ; }
Copy paste error fix in log message
<nb> import NAMESPACE ; import NAMESPACE ; COMMENT - class TreeLayoutAdaptor implements TreeForTreeLayout < Tree > { + public class TreeLayoutAdaptor implements TreeForTreeLayout < Tree > { private static class AntlrTreeChildrenIterable implements Iterable < Tree > { private final Tree tree ;
make public for use for plugins
<nb> public class Switch extends CompoundButton { final Rect bounds = thumbDrawable . getBounds ( ) ; cX = bounds . left + bounds . right ; } else { - cX = getWidth ( ) / NUMBER0 ; + cX = getWidth ( ) ; } final int left = cX / NUMBER0 - switchText . getWidth ( ) / NUMBER0 ;
Fix switch text position when thumb is null
<nb> public abstract class ConnectionProxy implements IHikariConnectionProxy private volatile long lastAccess ; private long uncloseTime ; - private StackTraceElement [ ] leakTrace ; private TimerTask leakTask ; private final int hashCode ; <nb> public abstract class ConnectionProxy implements IHikariCo...
Make leakTrace local as there is no need to make it an attribute
<nb> import NAMESPACE ; import NAMESPACE ; import NAMESPACE ; import NAMESPACE ; + import NAMESPACE ; import NAMESPACE ; import NAMESPACE ; <nb> class StatementAnalyzer return descriptor ; } - private List < FieldOrExpression > descriptorToFields ( TupleDescriptor tupleDescriptor ) + private s...
Fix warnings in StatementAnalyzer
<nb> package NAMESPACE ; import NAMESPACE ; import NAMESPACE ; + import NAMESPACE ; import NAMESPACE ; import NAMESPACE ; public class DeepLearningModelV2 extends ModelSchema < DeepLearningModel , DeepLearningModel . DeepLearningParameters , DeepLearningModel . DeepLearningOutput , DeepLearningModelV2 >...
Add API annotation
<nb> public class CustomTextActivity extends Activity { title . setTypeface ( Typeface . createFromAsset ( getAssets ( ) , STRING0 ) ) ; new ShowcaseView . Builder ( this ) + . withNewStyleShowcase ( ) . setTarget ( new ViewTarget ( R . id . imageView , this ) ) . setContentTitle ( R . string . custom_text_...
Remove deprecated API usage in sample
<nb> COMMENT - COMMENT + COMMENT COMMENT COMMENT COMMENT <nb> COMMENT - COMMENT + COMMENT COMMENT COMMENT COMMENT <nb> COMMENT - COMMENT + COMMENT COMMENT COMMENT COMMENT <nb> COMMENT - COMMENT + COMMENT COMMENT COMMENT COMMENT
license Caught outdated years on license files
<nb> public class SaveGame { } UUEncoder enc = new UUEncoder ( ) ; String dataString = enc . encodeBuffer ( out . toByteArray ( ) ) ; - System . out . println ( dataString ) ; + SINGLE if ( dataString . length ( ) > Preferences . MAX_VALUE_LENGTH ) { throw new IllegalStateException ( STRING0 ) ; }
remove System out println from SaveGame
<nb> public class Restarter { COMMENT COMMENT private void setEnabled ( boolean enabled ) { - this . enabled = false ; + this . enabled = enabled ; } COMMENT
Fix Restarter setEnabled to use parameter
<nb> public final class CasVersion { final File file = new File ( path . substring ( NUMBER0 , path . indexOf ( STRING0 ) ) ) ; return new DateTime ( file . lastModified ( ) ) ; } - throw new IllegalArgumentException ( STRING1 + - resource . getProtocol ( ) + STRING2 + - clazz . getName ( ) + STRING3 + reso...
fixed checkstyle issue
<nb> public class CxxLibraryDescription implements ImmutableList < String > linkerFlags , Optional < String > soname ) { - SINGLE + SINGLE ImmutableList < SourcePath > objects = requireObjects ( params , ruleResolver ,
Fix typo in comment
<nb> public class TerminalPane extends WorkbenchPane { addHandlerRegistration ( consoleProcess_ . addConsoleOutputHandler ( TerminalPane . this ) ) ; addHandlerRegistration ( consoleProcess_ . addProcessExitHandler ( TerminalPane . this ) ) ; - xterm_ . addResizeTerminalHandler ( TerminalPane . this ) ; + add...
capture the handler registration for resizing in TerminalPane