<nb> public interface Datastore {
 Mongo getMongo ( ) ;

 DBCollection getCollection ( Class < ? > c ) ;
 +
 + WriteConcern getDefaultWriteConcern ( ) ;
 + void setDefaultWriteConcern ( WriteConcern wc ) ;
 +
 }
 <nb> public class DatastoreImpl implements Datastore , AdvancedDatastore {
 Mapper mapper = morphia . getMapper ( ) ;
 return mapper . createEntityCache ( ) ;
 }
 +
 + public WriteConcern getDefaultWriteConcern ( ) { return defConcern ; }
 + public void setDefaultWriteConcern ( WriteConcern wc ) { defConcern = wc ; }
 +
 }

Added datastore WriteConcern property for defaults for methods without explicit WriteConcern option


<nb>
 - COMMENT
 - COMMENT
 - COMMENT
 package NAMESPACE ;

 COMMENT
 COMMENT
 - COMMENT
 - COMMENT
 - COMMENT
 COMMENT
 - public interface PigZombie extends Zombie { }
 + public interface PigZombie extends Zombie {
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + int getAnger ( ) ;
 +
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + void setAnger ( int level ) ;
 +
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + void setAngry ( boolean angry ) ;
 +
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + boolean isAngry ( ) ;
 + }

Added interface for setting and getting a pig zombie s anger level


<nb> import NAMESPACE ;
 COMMENT
 COMMENT
 COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 COMMENT
 COMMENT
 COMMENT

Add EBean interceptor injection to Rest JavaDoc


<nb> public class TwoDataSources extends DefaultTestCase {
 org . apache . tomcat . jdbc . pool . DataSource d1 = this . createDefaultDataSource ( ) ;
 org . apache . tomcat . jdbc . pool . DataSource d2 = this . createDefaultDataSource ( ) ;
 d1 . setRemoveAbandoned ( true ) ;
 - d1 . setRemoveAbandonedTimeout ( NUMBER0 ) ;
 + d1 . setRemoveAbandonedTimeout ( NUMBER1 ) ;
 d1 . setTimeBetweenEvictionRunsMillis ( NUMBER2 ) ;
 d2 . setRemoveAbandoned ( false ) ;
 Connection c1 = d1 . getConnection ( ) ;

Fix broken test it has been broken for a long time


<nb> public class AudioManager {
 STRING0 ;

 COMMENT
 - COMMENT
 + COMMENT
 COMMENT
 COMMENT
 COMMENT


<nb> public class InputMethodManagerService extends IInputMethodManager . Stub
 String id = pair . first ;
 ArrayList < String > subtypes = pair . second ;
 builder . append ( id ) ;
 - if ( subtypes . size ( ) > NUMBER0 ) {
 - builder . append ( subtypes . get ( NUMBER0 ) ) ;
 - for ( int i = NUMBER1 ; i < subtypes . size ( ) ; ++ i ) {
 - builder . append ( INPUT_METHOD_SUBTYPE_SEPARATER ) . append ( subtypes . get ( i ) ) ;
 - }
 + SINGLE
 + SINGLE
 + for ( String subtypeId : subtypes ) {
 + builder . append ( INPUT_METHOD_SUBTYPE_SEPARATER ) . append ( subtypeId ) ;
 }
 }

Fix a bug that enabled Subtype ID can t be saved propery


<nb> public class IOHook {
 String dexOrJarPath = params [ NUMBER0 ] ;
 String outputPath = params [ NUMBER1 ] ;
 VLog . d ( TAG , STRING0 , dexOrJarPath , outputPath ) ;
 - AppSetting info = sDexOverrideMap . get ( dexOrJarPath ) ;
 + String canonical = null ;
 + try {
 + canonical = new File ( dexOrJarPath ) . getCanonicalPath ( ) ;
 + } catch ( IOException e ) {
 + e . printStackTrace ( ) ;
 + }
 + AppSetting info = sDexOverrideMap . get ( canonical ) ;
 if ( info != null && ! info . dependSystem ) {
 outputPath = info . getOdexFile ( ) . getPath ( ) ;
 params [ NUMBER1 ] = outputPath ;

openDexFileNative s sDexOverrideMap uses canonical path


<nb> public class ScriptBuilder {
 return createMultiSigInputScriptBytes ( sigs ) ;
 }

 + COMMENT
 + public static Script createMultiSigInputScript ( TransactionSignature . . . signatures ) {
 + return createMultiSigInputScript ( Arrays . asList ( signatures ) ) ;
 + }
 +
 COMMENT
 public static Script createMultiSigInputScriptBytes ( List < byte [ ] > signatures ) {
 checkArgument ( signatures . size ( ) <= NUMBER0 ) ;


<nb> class OnesideDiffViewer extends TextDiffViewerBase {
 change . destroyHighlighter ( ) ;
 }
 myChangedBlockData = null ;
 +
 + myFoldingModel . destroy ( ) ;
 +
 myStatusPanel . update ( ) ;
 }

destroy folding model with other highlighters


<nb> public class ViewControllerRegistration {
 COMMENT
 COMMENT
 COMMENT
 - public ViewControllerRegistration setViewName ( String viewName ) {
 + public void setViewName ( String viewName ) {
 this . controller . setViewName ( viewName ) ;
 - return this ;
 }

Restore method signature in ViewControllerRegistration


<nb> public class XMLUtils {
 SINGLE
 Node prevNode = nodeList . item ( i ) . getPreviousSibling ( ) ;
 String prev = STRING0 ;
 - if ( prevNode . getPreviousSibling ( ) != null ) {
 - prev += prevNode . getPreviousSibling ( ) . getTextContent ( ) ;
 + if ( prevNode != null ) {
 + if ( prevNode . getPreviousSibling ( ) != null ) {
 + prev += prevNode . getPreviousSibling ( ) . getTextContent ( ) ;
 + }
 + prev += prevNode . getTextContent ( ) ;
 }
 - prev += prevNode . getTextContent ( ) ;

 Node nextNode = nodeList . item ( i ) . getNextSibling ( ) ;
 String next = STRING0 ;

fix xml utils add per sentence scoring produce quote xml for annotation


<nb> import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 - import NAMESPACE ;

 import NAMESPACE ;
 import NAMESPACE ;


<nb> public class Wallet implements Serializable {
 COMMENT
 COMMENT
 public static Wallet loadFromFile ( File f ) throws IOException {
 - return loadFromFileStream ( new FileInputStream ( f ) ) ;
 + FileInputStream stream = new FileInputStream ( f ) ;
 + try {
 + return loadFromFileStream ( stream ) ;
 + } finally {
 + stream . close ( ) ;
 + }
 }

 public boolean isConsistent ( ) {

Close the FileInputStream created in Wallet loadFromFile


<nb> import NAMESPACE ;
 COMMENT
 public class ModelResultMatchers {

 -
 COMMENT
 COMMENT
 COMMENT
 <nb> public class ModelResultMatchers {

 return new ResultMatcher ( ) {
 @ override
 - @ suppresswarnings ( STRING0 )
 public void match ( MvcResult mvcResult ) throws Exception {
 ModelAndView mav = getModelAndView ( mvcResult ) ;
 BindingResult result = getBindingResult ( mav , name ) ;

Remove unnecessary warning suppression in ModelResultMatchers


<nb> public class Main {
 LOG . info ( STRING0 ) ;
 LOG . info ( STRING1 ) ;
 LOG . info ( STRING2 ) ;
 - LOG . info ( STRING3 ) ;
 + LOG . info ( STRING4 ) ;
 }

 COMMENT


<nb> public class GestureImageView extends ImageView implements GestureView , ClipView
 @ override
 public void setImageDrawable ( Drawable dr ) {
 super . setImageDrawable ( dr ) ;
 +
 Settings settings = mController . getSettings ( ) ;
 + int oldW = settings . getImageW ( ) , oldH = settings . getImageH ( ) ;
 +
 if ( dr == null ) {
 settings . setImage ( NUMBER0 , NUMBER0 ) ;
 } else if ( dr . getIntrinsicWidth ( ) == - NUMBER1 || dr . getIntrinsicHeight ( ) == - NUMBER1 ) {
 <nb> public class GestureImageView extends ImageView implements GestureView , ClipView
 } else {
 settings . setImage ( dr . getIntrinsicWidth ( ) , dr . getIntrinsicHeight ( ) ) ;
 }
 - mController . resetState ( ) ;
 +
 + if ( oldW != settings . getImageW ( ) || oldH != settings . getImageH ( ) ) mController . resetState ( ) ;
 }

 protected void applyState ( State state ) {

Do not reset state if image size was not changed


<nb> public abstract class SemgrexPattern implements Serializable {
 treebank . loadPath ( treeFile ) ;
 for ( Tree tree : treebank ) {
 SINGLE
 - SemanticGraph graph = SemanticGraphFactory . makeFromTree ( tree , mode , useExtras ? GrammaticalStructure . Extras . MAXIMAL : GrammaticalStructure . Extras . NONE , true , null ) ;
 + SemanticGraph graph = SemanticGraphFactory . makeFromTree ( tree , mode , useExtras ? GrammaticalStructure . Extras . MAXIMAL : GrammaticalStructure . Extras . NONE , true ) ;
 graphs . add ( graph ) ;
 }
 }

fixed class to SemanticGraphFactory makeFromTree


<nb> public class MediaDriver implements AutoCloseable

 ensureDirectoriesAreRecreated ( ) ;

 - eventReader = new EventReader (
 - new EventReader . Context ( )
 - . idleStrategy ( Configuration . eventReaderIdleStrategy ( ) )
 - . deleteOnExit ( ctx . dirsDeleteOnExit ( ) )
 - . eventHandler ( ctx . eventConsumer ) ) ;
 -
 ctx . unicastSenderFlowControl ( UnicastSenderControlStrategy : : new )
 . multicastSenderFlowControl ( UnicastSenderControlStrategy : : new )
 . publications ( new AtomicArray < > ( ) )
 <nb> public class MediaDriver implements AutoCloseable
 . senderCommandQueue ( new OneToOneConcurrentArrayQueue < > ( Configuration . CMD_QUEUE_CAPACITY ) )
 . conclude ( ) ;

 + eventReader = new EventReader (
 + new EventReader . Context ( )
 + . idleStrategy ( Configuration . eventReaderIdleStrategy ( ) )
 + . deleteOnExit ( ctx . dirsDeleteOnExit ( ) )
 + . eventHandler ( ctx . eventConsumer ) ) ;
 +
 receiver = new Receiver ( ctx ) ;
 sender = new Sender ( ctx ) ;
 conductor = new DriverConductor ( ctx ) ;

Java Provide more logical ordering to MediaDriver Constructor flow


<nb> public final class AstValue extends SimpleNode {
 SINGLE
 if ( suffix == null ) {
 return null ;
 - } else {
 - ctx . setPropertyResolved ( false ) ;
 - base = resolver . getValue ( ctx , base , suffix ) ;
 }
 +
 + ctx . setPropertyResolved ( false ) ;
 + base = resolver . getValue ( ctx , base , suffix ) ;
 i ++ ;
 }
 }


<nb> import NAMESPACE ;

 interface BlurController {
 float DEFAULT_SCALE_FACTOR = FLOAT0 ;
 - float DEFAULT_BLUR_RADIUS = FLOAT0 ;
 + float DEFAULT_BLUR_RADIUS = NUMBER0 f ;

 COMMENT
 COMMENT


<nb> class ContextImpl extends Context {
 public Resources . Theme getTheme ( ) {
 if ( mTheme == null ) {
 if ( mThemeResource == NUMBER0 ) {
 - mThemeResource = com . android . internal . R . style . Theme ;
 + final Context outerContext = getOuterContext ( ) ;
 + mThemeResource = ( outerContext . getApplicationInfo ( ) . targetSdkVersion
 + >= Build . VERSION_CODES . HONEYCOMB )
 + ? com . android . internal . R . style . Theme_Holo
 + : com . android . internal . R . style . Theme ;
 }
 mTheme = mResources . newTheme ( ) ;
 mTheme . applyStyle ( mThemeResource , true ) ;

use the holo theme in more places for honeycomb apps


<nb> import NAMESPACE ;
 import NAMESPACE ;

 public final class EditorImpl extends UserDataHolderBase implements EditorEx , HighlighterClient , Queryable , Dumpable {
 - private static final boolean isOracleRetina = UIUtil . isRetina ( ) && SystemInfo . isOracleJvm ;
 + private static final boolean isOracleRetina = UIUtil . isRetina ( ) COMMENT ;
 private static final int MIN_FONT_SIZE = NUMBER0 ;
 private static final Logger LOG = Logger . getInstance ( STRING0 ) ;
 private static final Key DND_COMMAND_KEY = Key . create ( STRING1 ) ;
 <nb> public class UIUtil {
 return ourRetina . get ( ) ;
 }
 }
 - else if ( SystemInfo . isJavaVersionAtLeast ( STRING2 ) && SystemInfo . isOracleJvm ) {
 + else if ( SystemInfo . isJavaVersionAtLeast ( STRING2 ) COMMENT ) {
 try {
 GraphicsEnvironment env = GraphicsEnvironment . getLocalGraphicsEnvironment ( ) ;
 final GraphicsDevice device = env . getDefaultScreenDevice ( ) ;

make isRetina method work on Zulu and other JREs


<nb> public class BounceRecyclerView extends BaseBounceView < WXRecyclerView > {
 headComponentStack . push ( headComponent ) ;
 FrameLayout headerView = ( FrameLayout ) headComponent . getView ( ) . getChildAt ( NUMBER0 ) ;
 headerViewStack . push ( headerView ) ;
 - int headerViewOffsetX = getLeft ( ) ;
 + int [ ] location = new int [ NUMBER1 ] ;
 + int [ ] parentLocation = new int [ NUMBER1 ] ;
 + headComponent . getView ( ) . getLocationOnScreen ( location ) ;
 + headComponent . getParentScroller ( ) . getView ( ) . getLocationOnScreen ( parentLocation ) ;
 + int headerViewOffsetX = location [ NUMBER0 ] - parentLocation [ NUMBER0 ] ;
 int headerViewOffsetY = getTop ( ) ;
 headComponent . getView ( ) . removeView ( headerView ) ;
 FrameLayout tempView = new FrameLayout ( getContext ( ) ) ;


<nb> class GitCheckoutOperation extends GitBranchOperation {

 private static void refresh ( GitRepository . . . repositories ) {
 for ( GitRepository repository : repositories ) {
 + SINGLE
 + SINGLE
 + SINGLE
 + SINGLE
 + sleepABit ( ) ;
 refreshRoot ( repository ) ;
 SINGLE
 }
 }
 +
 + private static void sleepABit ( ) {
 + try {
 + Thread . sleep ( NUMBER0 ) ;
 + }
 + catch ( InterruptedException e ) {
 + throw new RuntimeException ( e ) ;
 + }
 + }
 }

sleep a bit to let file watcher report all changes for small repositories where refresh is too fast


<nb> import NAMESPACE ;
 @ suppresswarnings ( STRING0 )
 public class SessionDump extends HttpServlet
 {
 + COMMENT
 + COMMENT
 + COMMENT
 + public class ObjectAttributeValue implements java . io . Serializable
 + {
 + long l ;
 +
 + public ObjectAttributeValue ( long l )
 + {
 + this . l = l ;
 + }
 +
 + public long getValue ( )
 + {
 + return l ;
 + }
 + }

 int redirectCount = NUMBER0 ;
 COMMENT
 <nb> public class SessionDump extends HttpServlet
 {
 session = request . getSession ( true ) ;
 session . setAttribute ( STRING1 , STRING2 ) ;
 + session . setAttribute ( STRING3 , new ObjectAttributeValue ( System . currentTimeMillis ( ) ) ) ;
 }
 else if ( session != null )
 {

Add object as session attribute for SessionDump test servlet


<nb> import NAMESPACE ;
 COMMENT
 public class ModClassLoader extends URLClassLoader
 {
 - private static final List < String > STANDARD_LIBRARIES = ImmutableList . of ( STRING0 , STRING1 , STRING2 ) ;
 + private static final List < String > STANDARD_LIBRARIES = ImmutableList . of ( STRING0 , STRING1 , STRING2 , STRING3 ) ;
 private LaunchClassLoader mainClassLoader ;

 public ModClassLoader ( ClassLoader parent ) {

Finally fix stupid NPE error caused by FML trying to parse the super of Object in IDEA envs


<nb> public final class ContactsContract {

 COMMENT
 COMMENT
 - COMMENT
 + COMMENT
 COMMENT
 COMMENT
 COMMENT


<nb> import NAMESPACE ;
 COMMENT
 @ configuration
 @ conditionalonclass ( { EnableWebSecurity . class } )
 - SINGLE
 - @ enablewebsecurity
 + @ conditionalonmissingbean ( annotation = EnableWebSecurity . class )
 @ enableconfigurationproperties
 public class SecurityAutoConfiguration {

 <nb> public class SecurityAutoConfiguration {

 SINGLE
 @ order ( Ordered . HIGHEST_PRECEDENCE )
 + @ enablewebsecurity
 private static class IgnoredPathsWebSecurityConfigurerAdapter implements
 SecurityConfigurer < Filter , WebSecurity > {

 <nb>
 package NAMESPACE ;

 import NAMESPACE ;
 - import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 <nb> import NAMESPACE ;
 COMMENT
 COMMENT
 COMMENT
 - @ ignore ( STRING0 )
 public class SpringApplicationHierarchyTests {

 private ConfigurableApplicationContext context ;

Nest the EnableWebSecurity so it can be added to a condition


<nb> package 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 ;
 import NAMESPACE ;
 <nb> import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 - import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;


<nb> public abstract class ViewGroup extends View implements ViewParent , ViewManager
 COMMENT
 public void requestTransitionStart ( LayoutTransition transition ) {
 ViewRootImpl viewAncestor = getViewRootImpl ( ) ;
 - viewAncestor . requestTransitionStart ( transition ) ;
 + if ( viewAncestor != null ) {
 + viewAncestor . requestTransitionStart ( transition ) ;
 + }
 }

 @ override

Fix potential null deref in ViewGroup when running transition


<nb> public class HistoryReferencesTable extends ZapTable {
 return ;
 }

 + boolean focusOwner = isFocusOwner ( ) ;
 try {
 displayMessage ( hRef . getHttpMessage ( ) ) ;
 } catch ( HttpMalformedHeaderException | DatabaseException e ) {
 LOGGER . error ( e . getMessage ( ) , e ) ;
 + } finally {
 + if ( focusOwner ) {
 + requestFocusInWindow ( ) ;
 + }
 }
 }
 }

Set focus back to table after displaying a message


<nb> public abstract class JDBCTable < DATASOURCE extends DBPDataSource , CONTAINER exte
 {
 static final Log log = Log . getLog ( JDBCTable . class ) ;
 public static final String DEFAULT_TABLE_ALIAS = STRING0 ;
 - public static final int DEFAULT_READ_FETCH_SIZE = NUMBER0 ;
 + SINGLE

 private boolean persisted ;

 <nb> class ResultSetDataPumpJob extends DataSourceJob {
 private String progressMessage ;

 protected ResultSetDataPumpJob ( DBSDataContainer dataContainer , DBDDataFilter dataFilter , DBDDataReceiver dataReceiver , Composite progressControl ) {
 - super ( CoreMessages . controls_rs_pump_job_name , DBIcon . SQL_EXECUTE . getImageDescriptor ( ) , dataContainer . getDataSource ( ) ) ;
 + super ( CoreMessages . controls_rs_pump_job_name + STRING1 + dataContainer . getName ( ) + STRING2 , DBIcon . SQL_EXECUTE . getImageDescriptor ( ) , dataContainer . getDataSource ( ) ) ;
 progressMessage = CoreMessages . controls_rs_pump_job_name ;
 this . dataContainer = dataContainer ;
 this . dataFilter = dataFilter ;


<nb> final class GJMonthOfYearDateTimeField extends ImpreciseDateTimeField {
 ( subtrahendInstant , subtrahendYear , subtrahendMonth ) ;
 if ( subtrahendDom > minuendDom ) {
 SINGLE
 - SINGLE
 + SINGLE
 + SINGLE
 subtrahendInstant = iChronology . dayOfMonth ( ) . set ( subtrahendInstant , minuendDom ) ;
 }
 }
 <nb> final class GJWeekyearDateTimeField extends ImpreciseDateTimeField {
 SINGLE
 SINGLE
 SINGLE
 - SINGLE
 + SINGLE
 + SINGLE
 workInstant = iChronology . dayOfWeek ( ) . set ( workInstant , thisDow ) ;
 SINGLE
 SINGLE
 <nb> final class GJWeekyearDateTimeField extends ImpreciseDateTimeField {
 }

 public long roundFloor ( long instant ) {
 - SINGLE
 + SINGLE
 + SINGLE
 instant = iChronology . weekOfWeekyear ( ) . roundFloor ( instant ) ;
 int wow = iChronology . getWeekOfWeekyear ( instant ) ;
 if ( wow > NUMBER0 ) {


<nb> public class AimsicdService extends Service {
 mLocationTracker . stop ( ) ;
 mAccelerometerMonitor . stop ( ) ;
 mRilExecutor . stop ( ) ;
 - try {
 - if ( smsdetector . getSmsDetectionState ( ) ) {
 - smsdetector . stopSmsDetection ( ) ;
 - }
 - } catch ( Exception ee ) { Log . e ( TAG , STRING0 + ee . toString ( ) ) ; }
 + if ( smsdetector . getSmsDetectionState ( ) )
 + {
 + smsdetector . stopSmsDetection ( ) ;
 + }
 +
 Log . i ( TAG , STRING1 ) ;
 }


<nb> import NAMESPACE ;

 import NAMESPACE ;
 import NAMESPACE ;
 + import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 <nb> public abstract class BaseContactFragment extends DisplayListFragment < Contact , C
 addFooterAction ( R . drawable . ic_share_white_24dp , STRING0 , false , new Runnable ( ) {
 @ override
 public void run ( ) {
 -
 + String inviteMessage = getResources ( ) . getString ( R . string . invite_message ) ;
 + Intent sendIntent = new Intent ( Intent . ACTION_SEND ) ;
 + sendIntent . putExtra ( Intent . EXTRA_TEXT , inviteMessage ) ;
 + sendIntent . setType ( STRING1 ) ;
 + startActivity ( sendIntent ) ;
 }
 } ) ;

 addFooterAction ( R . drawable . ic_person_add_white_24dp , STRING2 , true , new Runnable ( ) {
 @ override
 public void run ( ) {
 -
 + startActivity ( new Intent ( getActivity ( ) , AddContactActivity . class ) ) ;
 }
 } ) ;


<nb> import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 - import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 <nb> public class ApiHelper {
 SINGLE
 int startPosition = NUMBER0 ;
 if ( loadMore && result . length > PostsListFragment . POSTS_REQUEST_COUNT ) {
 - startPosition = ( result . length - PostsListFragment . POSTS_REQUEST_COUNT ) ;
 + startPosition = result . length - PostsListFragment . POSTS_REQUEST_COUNT ;
 }

 for ( int ctr = startPosition ; ctr < result . length ; ctr ++ ) {

Removed some unneeded parenthesis and an unused import


<nb> public class DbSession {
 log . debug ( STRING0 ) ;

 List < SQLException > allsexs = null ;
 - for ( DbQueryBase query : queries ) {
 - List < SQLException > sexs = query . closeQuery ( ) ;
 - if ( sexs != null ) {
 - if ( allsexs == null ) {
 - allsexs = new ArrayList < SQLException > ( ) ;
 + if ( queries != null ) {
 + for ( DbQueryBase query : queries ) {
 + List < SQLException > sexs = query . closeQuery ( ) ;
 + if ( sexs != null ) {
 + if ( allsexs == null ) {
 + allsexs = new ArrayList < SQLException > ( ) ;
 + }
 + allsexs . addAll ( sexs ) ;
 }
 - allsexs . addAll ( sexs ) ;
 }
 }
 if ( connection != null ) {

prevent NPE on closing already closed sessions


<nb> import NAMESPACE ;
 COMMENT
 COMMENT
 COMMENT
 - COMMENT
 + COMMENT
 COMMENT
 COMMENT
 COMMENT
 <nb> import NAMESPACE ;
 COMMENT
 COMMENT
 COMMENT
 - COMMENT
 + COMMENT
 COMMENT
 COMMENT
 COMMENT
 <nb> public class JksOptions implements KeyCertOptions , TrustOptions , Cloneable {
 JksOptionsConverter . fromJson ( json , this ) ;
 }

 + public JsonObject toJson ( ) {
 + JsonObject json = new JsonObject ( ) ;
 + JksOptionsConverter . toJson ( this , json ) ;
 + return json ;
 + }
 +
 COMMENT
 COMMENT
 COMMENT


<nb>
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 +
 package NAMESPACE ;

 import NAMESPACE ;


<nb> public class DevicePolicyManagerService extends IDevicePolicyManager . Stub {
 long ident = Binder . clearCallingIdentity ( ) ;
 try {
 if ( ( flags & WIPE_RESET_PROTECTION_DATA ) != NUMBER0 ) {
 + boolean ownsInitialization = isDeviceInitializer ( admin . info . getPackageName ( ) )
 + && ! hasUserSetupCompleted ( userHandle ) ;
 if ( userHandle != UserHandle . USER_OWNER
 - || ! isDeviceOwner ( admin . info . getPackageName ( ) ) ) {
 + || ! ( isDeviceOwner ( admin . info . getPackageName ( ) )
 + || ownsInitialization ) ) {
 throw new SecurityException (
 STRING0 ) ;
 }

Allow initializers to clear reset protection data during device setup


<nb> public class DraggableListView extends ListView {

 mWindowParams . y = y - mDragPoint . y + mCoordOffset . y ;

 - if ( x > mTouchStartX + SWIPE_THRESHOLD )
 + if ( mDragPos == mFirstDragPos && x > mTouchStartX + SWIPE_THRESHOLD )
 mDragView . setPadding ( NUMBER0 , NUMBER1 , NUMBER2 , NUMBER1 ) ;
 - else if ( x < mTouchStartX - SWIPE_THRESHOLD )
 + else if ( mDragPos == mFirstDragPos && x < mTouchStartX - SWIPE_THRESHOLD )
 mDragView . setPadding ( - NUMBER0 , NUMBER3 , NUMBER2 , NUMBER3 ) ;
 else
 mDragView . setPadding ( NUMBER2 , NUMBER2 , NUMBER2 , NUMBER2 ) ;

Don t show padding when dragging a row and it s going a long distance


<nb> public final class ContactsContract {
 COMMENT
 COMMENT
 public static final String GROUP_VISIBLE = STRING0 ;
 +
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + public static final String DELETED = STRING1 ;
 }

 COMMENT
 <nb> public final class ContactsContract {
 COMMENT
 COMMENT
 public static final String CONTENT_ITEM_TYPE = STRING2 ;
 +
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + public static final String DELETE_PERMANENTLY = STRING3 ;
 }

 COMMENT

add the deleted flag to the Groups table


<nb> final class NotificationController {
 removedPrintJobs . remove ( printJobId ) ;
 mNotifications . add ( printJobId ) ;

 - Log . i ( STRING0 , STRING1 + printJobId . flattenToString ( ) ) ;
 -
 createSimpleNotification ( printJob ) ;
 }

 <nb> final class NotificationController {
 for ( int i = NUMBER0 ; i < numRemovedPrintJobs ; i ++ ) {
 PrintJobId removedPrintJob = removedPrintJobs . valueAt ( i ) ;

 - Log . i ( STRING0 , STRING2 + removedPrintJob . flattenToString ( ) ) ;
 -
 mNotificationManager . cancel ( removedPrintJob . flattenToString ( ) , NUMBER0 ) ;
 mNotifications . remove ( removedPrintJob ) ;
 }

Remove debugging from print notification code


<nb> public class PeopleTable {

 try {
 while ( c . moveToNext ( ) ) {
 - Person comment = getPersonFromCursor ( c , localTableBlogId ) ;
 - people . add ( comment ) ;
 + Person person = getPersonFromCursor ( c , localTableBlogId ) ;
 + people . add ( person ) ;
 }

 return people ;


<nb> public class TitanFactory {
 private static final Logger log =
 LoggerFactory . getLogger ( TitanFactory . class ) ;

 - private static boolean preloadedConfigOptions = false ;
 -
 COMMENT
 COMMENT
 COMMENT


<nb> public class TextEditingTarget implements EditingTarget
 withChooseEncoding (
 StringUtil . firstNotNullOrEmpty ( new String [ ] {
 docUpdateSentinel_ . getEncoding ( ) ,
 + prefs_ . defaultEncoding ( ) . getValue ( ) ,
 session_ . getSessionInfo ( ) . getSystemEncoding ( )
 } ) ,
 new CommandWithArg < String > ( )

Save with Encoding wasn t respecting preference


<nb> public class AceEditor implements DocDisplay , InputEditorDisplay
 @ override
 public void reindent ( )
 {
 + boolean emptySelection = getSelection ( ) . isEmpty ( ) ;
 getSession ( ) . reindent ( ) ;
 + if ( emptySelection )
 + moveSelectionToNextLine ( false ) ;
 }

 public ChangeTracker getChangeTracker ( )


<nb>
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 package NAMESPACE ;

 + import static NAMESPACE ;
 +
 import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 <nb> public class WeldJaxwsInjectionServices implements JaxwsInjectionServices {
 @ override
 public < T > ResourceReferenceFactory < T > registerWebServiceRefInjectionPoint ( final InjectionPoint injectionPoint ) {

 - WebServiceRef annotation = injectionPoint . getAnnotated ( ) . getAnnotation ( WebServiceRef . class ) ;
 + WebServiceRef annotation = getResourceAnnotated ( injectionPoint ) . getAnnotation ( WebServiceRef . class ) ;
 if ( annotation == null ) {
 return null ;
 }

WeldJaxwsInjectionServices add support for EE component resource


<nb> public class DbImportTest implements OCommandListener {
 OProfiler . getInstance ( ) . startRecording ( ) ;
 }

 - @ test ( dependsOnMethods = { STRING0 } )
 public void testDbImport ( ) throws IOException {
 File importDir = new File ( STRING1 ) ;


<nb> public class DBCursor implements Iterator < DBObject > , Iterable < DBObject > {
 }

 if ( _cursorType == CursorType . ARRAY ) {
 - _nums . add ( String . valueOf ( _all . size ( ) ) ) ;
 _all . add ( _cur ) ;
 }

 <nb> public class DBCursor implements Iterator < DBObject > , Iterable < DBObject > {
 private int _num = NUMBER0 ;

 private final ArrayList < DBObject > _all = new ArrayList < DBObject > ( ) ;
 - private final List < String > _nums = new ArrayList < String > ( ) ;
 -
 }

remove unused but allocated and populated _nums collection


<nb> public class DirectoriesTest
 for ( final String cf : CFS )
 {
 final Directories directories = Directories . create ( KS , cf ) ;
 - Assert . assertEquals ( cfDir ( cf ) , directories . getDirectoryForNewSSTables ( NUMBER0 ) ) ;
 + Assert . assertEquals ( cfDir ( cf ) , directories . getDirectoryForNewSSTables ( ) ) ;
 final String n = Long . toString ( System . nanoTime ( ) ) ;
 Callable < File > directoryGetter = new Callable < File > ( ) {
 public File call ( ) throws Exception {


<nb> public final class TSMeta {
 SINGLE
 final TSMeta meta = new TSMeta ( tsuid ,
 System . currentTimeMillis ( ) / NUMBER0 ) ;
 +
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + final class TreeCB implements Callback < Deferred < Long > , Boolean > {

 + @ override
 + public Deferred < Long > call ( Boolean success ) throws Exception {
 + return Deferred . fromResult ( incremented_value ) ;
 + }
 +
 + }
 +
 COMMENT
 COMMENT
 COMMENT
 <nb> public final class TSMeta {
 tsdb . indexTSMeta ( stored_meta ) ;

 SINGLE
 - return Deferred . fromResult ( incremented_value ) ;
 + return tsdb . processTSMetaThroughTrees ( stored_meta )
 + . addCallbackDeferring ( new TreeCB ( ) ) ;
 }

 }

Modify TSMeta incrementAndGetCounter to pass new TSMetas through tree builders


<nb> import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 + import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;

 <nb> public class ZenDiscoveryTests extends ElasticsearchIntegrationTest {
 }

 @ test
 + @ testlogging ( value = STRING0 )
 public void testNodeFailuresAreProcessedOnce ( ) throws ExecutionException , InterruptedException , IOException {
 Settings defaultSettings = ImmutableSettings . builder ( )
 . put ( FaultDetection . SETTING_PING_TIMEOUT , STRING1 )

add trace logging to testNodeFailuresAreProcessedOnce


<nb> public class JBossAsManagedConfiguration extends CommonContainerConfiguration {
 Validate . configurationDirectoryExists ( javaHome , STRING0 + javaHome ) ;
 }
 if ( controllerJavaHome != null ) {
 - Validate . configurationDirectoryExists ( javaHome , STRING1 + controllerJavaHome ) ;
 + Validate . configurationDirectoryExists ( controllerJavaHome , STRING1 + controllerJavaHome ) ;
 }
 }

JBossAsManagedConfiguration controllerJavaHome check fix


<nb> public class BufferSynchronizerService extends AbstractIdleService {
 }

 private ExecutorService executorService ( MetricRegistry metricRegistry ) {
 - final ThreadFactory threadFactory = new ThreadFactoryBuilder ( ) . setNameFormat ( STRING0 ) . build ( ) ;
 + final ThreadFactory threadFactory = new ThreadFactoryBuilder ( ) . setNameFormat ( STRING1 ) . build ( ) ;
 return new InstrumentedExecutorService (
 Executors . newFixedThreadPool ( NUMBER0 , threadFactory ) ,
 metricRegistry ,

Fix thread names for BufferSynchronizerService


<nb>

 package NAMESPACE ;

 - import NAMESPACE ;
 + import NAMESPACE ;
 import NAMESPACE ;

 import NAMESPACE ;


<nb> public class OObjectEntitySerializer {
 reloadSchema = true ;
 } else {
 oSuperClass = oSchema . getClass ( currentClass . getSimpleName ( ) ) ;
 - reloadSchema = true ;
 }

 if ( ! currentOClass . getSuperClasses ( ) . contains ( oSuperClass ) ) {


<nb> import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 + import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 <nb> public class GrChangeSignatureDialog extends RefactoringDialog {
 public GrChangeSignatureDialog ( @ notnull Project project , GrMethod method ) {
 super ( project , true ) ;
 myMethod = method ;
 + setTitle ( ChangeSignatureHandler . REFACTORING_NAME ) ;
 init ( ) ;
 updateSignature ( ) ;
 ActionListener listener = new ActionListener ( ) {

groovy change signature dialog misses title


<nb> public final class BloomFilter < T > implements Predicate < T > , Serializable {
 COMMENT
 public static < T > BloomFilter < T > create (
 Funnel < T > funnel , int expectedInsertions COMMENT , double fpp ) {
 - return create ( funnel , expectedInsertions , fpp , BloomFilterStrategies . MURMUR128_MITZ_32 ) ;
 + return create ( funnel , expectedInsertions , fpp , BloomFilterStrategies . MURMUR128_MITZ_64 ) ;
 }

 @ visiblefortesting

Switch default BloomFilter strategy from the broken MURMUR128_MITZ_32 to the


<nb> public final class GitHttpAdapter {
 private static boolean smartHttpPushNotSupported ( JGitInternalException e ) {
 if ( e . getCause ( ) instanceof NotSupportedException ) {
 NotSupportedException nse = ( NotSupportedException ) e . getCause ( ) ;
 - return nse . getMessage ( ) . toLowerCase ( ) . contains ( STRING0 ) ;
 + String message = nse . getMessage ( ) ;
 + return message != null && message . toLowerCase ( ) . contains ( STRING0 ) ;
 }
 return false ;
 }


<nb> public class LocalStore extends Store implements Serializable
 HEADERS_TO_SAVE . add ( STRING0 ) ;
 HEADERS_TO_SAVE . add ( STRING1 ) ;
 }
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + static private String GET_MESSAGES_COLS =
 + STRING2
 + + STRING3 ;
 +

 COMMENT
 COMMENT
 <nb> public class LocalStore extends Store implements Serializable
 private String prefId = null ;
 private String mPushState = null ;

 - COMMENT
 - COMMENT
 - COMMENT
 - COMMENT
 - private String GET_MESSAGES_COLS =
 -
 - STRING2
 - + STRING4 ;
 -

 public LocalFolder ( String name )
 {

Lift our column list for load messages out to the LocalStore as the


<nb> public class MaterialShowcaseView extends FrameLayout implements View . OnTouchLis
 return this ;
 }

 + public Builder setListener ( IShowcaseListener listener ) {
 + showcaseView . addShowcaseListener ( listener ) ;
 + return this ;
 + }
 +
 public Builder singleUse ( String showcaseID ) {
 showcaseView . singleUse ( showcaseID ) ;
 return this ;


<nb> public class MessagingController implements Runnable
 if ( K9 . DEBUG )
 {
 Log . i ( K9 . LOG_TAG , STRING0
 - + STRING1 + Utility . combine ( accountUuids , STRING2 )
 - + STRING3 + Utility . combine ( folderNames , STRING2 )
 + + STRING4 + Utility . combine ( accountUuids , STRING2 )
 + + STRING5 + Utility . combine ( folderNames , STRING2 )
 + STRING6 + ( messages != null ? messages . length : null )
 + STRING7 + query
 + STRING8 + integrate
 <nb> public class MessagingController implements Runnable
 tmpFoldersToSearch . add ( localFolder ) ;
 }
 }
 + if ( tmpFoldersToSearch . size ( ) < NUMBER0 )
 + {
 + continue ;
 + }
 foldersToSearch = tmpFoldersToSearch ;
 }
 catch ( MessagingException me )

If we re doing a folder involved search and an account has no folders


<nb> public class Constant {

 public static final int DESIRED_FAVICON_SIZE = NUMBER0 ;

 - public static final String WELCOME_MESSAGE_URL = STRING0 ;
 - public static final String WELCOME_MESSAGE_DISPLAY_URL = STRING1 ;
 + public static final String WELCOME_MESSAGE_URL = STRING2 ;
 + public static final String WELCOME_MESSAGE_DISPLAY_URL = STRING3 ;

 SINGLE
 SINGLE


<nb> public class ModuleNode extends ASTNode implements Constants {
 private List classes = new ArrayList ( ) ;
 private List methods = new ArrayList ( ) ;
 private List imports = new ArrayList ( ) ;
 + private List importPackages = new ArrayList ( ) ;
 private Map importIndex = new HashMap ( ) ;
 private CompileUnit unit ;
 private String packageName ;
 <nb> public class ModuleNode extends ASTNode implements Constants {
 return imports ;
 }

 + public List getImportPackages ( ) {
 + return importPackages ;
 + }
 +
 COMMENT
 COMMENT
 COMMENT
 <nb> public class ModuleNode extends ASTNode implements Constants {
 importIndex . put ( alias , className ) ;
 }

 + public void addImportPackage ( String packageName ) {
 + importPackages . add ( packageName ) ;
 + }
 +
 public void addStatement ( Statement node ) {
 statementBlock . addStatement ( node ) ;
 }

added support for packages to be added as import statements


<nb> import NAMESPACE ;
 public class EcIesParameterSpec implements AlgorithmParameterSpec {

 @ retention ( RetentionPolicy . SOURCE )
 - @ intdef ( value = { PointFormat . UNCOMPRESSED , PointFormat . COMPRESSED } )
 + @ intdef ( {
 + PointFormat . UNSPECIFIED ,
 + PointFormat . UNCOMPRESSED ,
 + PointFormat . COMPRESSED ,
 + } )
 public @ interface PointFormatEnum { }

 COMMENT

Add missing value for EcIesParameterSpec PointFormatEnum


<nb> import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 + import NAMESPACE ;
 import NAMESPACE ;

 COMMENT
 <nb> import NAMESPACE
 COMMENT
 COMMENT
 COMMENT
 + COMMENT
 COMMENT
 @ configuration
 - @ conditionalonclass ( AuthenticationManager . class )
 + @ conditionalonclass ( { AuthenticationManager . class ,
 + GlobalAuthenticationConfigurerAdapter . class } )
 @ enableconfigurationproperties
 @ import ( { SpringBootWebSecurityConfiguration . class ,
 AuthenticationManagerConfiguration . class } )

Make Security auto config conditional on spring security config


<nb> public class PSurfaceLWJGL implements PSurface {
 fullScreenRequested = true ;
 }

 + if ( graphics . is2X ( ) ) {
 + SINGLE
 + System . setProperty ( STRING0 , STRING1 ) ;
 + SINGLE
 + }
 +
 SINGLE
 SINGLE


<nb> public class AndroidServiceProxy extends ProcessProxy {
 @ override
 protected void performTask ( ) throws IOException {
 String svc = mServiceName ;
 + Log . d ( mTag , STRING0 + mServiceName ) ;
 + SystemProperties . set ( SVC_STOP_CMD , mServiceName ) ;
 + if ( ! blockUntil ( SVC_STATE_STOPPED , NUMBER0 ) ) {
 + throw new IOException ( STRING1 + svc
 + + STRING2 ) ;
 + }
 +
 Log . d ( mTag , STRING3 + svc ) ;
 SystemProperties . set ( SVC_START_CMD , svc ) ;

 <nb> public class VpnServiceBinder extends Service {
 public void onStart ( Intent intent , int startId ) {
 super . onStart ( intent , startId ) ;
 setForeground ( true ) ;
 + android . util . Log . d ( STRING4 , STRING5 ) ;
 }

 public IBinder onBind ( Intent intent ) {


<nb>

 package NAMESPACE ;

 - import NAMESPACE ;
 - import NAMESPACE ;
 + import NAMESPACE ;

 import NAMESPACE ;
 COMMENT
 <nb> import NAMESPACE ;
 COMMENT
 public class ServerStarter {

 - private static final Logger Log = LoggerFactory . getLogger ( ServerStarter . class ) ;
 -
 COMMENT
 COMMENT
 COMMENT

Prevent NoClassDefFoundError during Openfire start


<nb> public class MiroGuideChannelViewActivity extends SherlockActivity {
 if ( exception == null ) {
 txtvTitle . setText ( channel . getName ( ) ) ;
 txtVDescription . setText ( channel . getDescription ( ) ) ;
 - String [ ] entryNames = new String [ channel . getItems ( ) . size ( ) ] ;
 - for ( int i = NUMBER0 ; i < channel . getItems ( ) . size ( ) ; i ++ ) {
 - entryNames [ i ] = channel . getItems ( ) . get ( i ) . getName ( ) ;
 - }
 +
 MiroGuideItemlistAdapter listAdapter = new MiroGuideItemlistAdapter (
 MiroGuideChannelViewActivity . this , NUMBER0 ,
 channel . getItems ( ) ) ;


<nb> final class ActionBarHandlerWatson extends ActionBar {
 @ override
 void onMenuInflated ( Menu menu ) {
 int maxItems = MAX_ACTION_BAR_ITEMS_PORTRAIT ;
 - int orientation = getActivity ( ) . getWindowManager ( ) . getDefaultDisplay ( ) . getOrientation ( ) ;
 - if ( orientation == Configuration . ORIENTATION_LANDSCAPE ) {
 + if ( getActivity ( ) . getResources ( ) . getConfiguration ( ) . orientation == Configuration . ORIENTATION_LANDSCAPE ) {
 maxItems = MAX_ACTION_BAR_ITEMS_LANDSCAPE ;
 }


<nb> public class ConnectivityService extends IConnectivityManager . Stub {
 mTethering . getTetherableBluetoothRegexs ( ) . length != NUMBER0 ) &&
 mTethering . getUpstreamIfaceRegexs ( ) . length != NUMBER0 ) ;

 + try {
 + nmService . registerObserver ( mTethering ) ;
 + } catch ( RemoteException e ) {
 + loge ( STRING0 + e ) ;
 + }
 +
 if ( DBG ) {
 mInetLog = new ArrayList ( ) ;
 }
 <nb> public class Tethering extends INetworkManagementEventObserver . Stub {
 mNMService = nmService ;
 mLooper = looper ;

 - SINGLE
 - try {
 - mNMService . registerObserver ( this ) ;
 - } catch ( RemoteException e ) {
 - Log . e ( TAG , STRING0 + e ) ;
 - }
 -
 mIfaces = new HashMap < String , TetherInterfaceSM > ( ) ;

 SINGLE

Do not register the callbacks in the constructor


<nb> public class ZWaveConfiguration implements OpenHABConfigurationService , ZWaveEve
 } else if ( arg . equals ( STRING0 ) ) {
 SINGLE
 record = new OpenHABConfigurationRecord ( domain , STRING1 , STRING2 , true ) ;
 + record . type = OpenHABConfigurationRecord . TYPE . LIST ;
 record . value = zController . getControllerType ( ) . getLabel ( ) ;
 record . addValue ( ZWaveDeviceType . PRIMARY . toString ( ) , ZWaveDeviceType . PRIMARY . toString ( ) ) ;
 record . addValue ( ZWaveDeviceType . SECONDARY . toString ( ) , ZWaveDeviceType . SECONDARY . toString ( ) ) ;


<nb> public final class Configuration {
 @ suppresswarnings ( { STRING0 , STRING1 } )
 public < T > void set ( PreparedStatement stmt , Path < ? > path , int i , T value ) throws SQLException {
 if ( Null . class . isInstance ( value ) ) {
 - Integer sqlType = path != null ? ColumnMetadata . getColumnMetadata ( path ) . getJdbcType ( ) : null ;
 + Integer sqlType = null ;
 + if ( path != null ) {
 + ColumnMetadata columnMetadata = ColumnMetadata . getColumnMetadata ( path ) ;
 + if ( columnMetadata . hasJdbcType ( ) ) {
 + sqlType = columnMetadata . getJdbcType ( ) ;
 + }
 + }
 if ( sqlType != null ) {
 stmt . setNull ( i , sqlType ) ;
 } else {


<nb> public class LibraryTopLevelActivity extends LibraryBaseActivity {
 ) ;
 myItems . add ( NUMBER0 , mySearchResultsItem ) ;
 getListView ( ) . invalidateViews ( ) ;
 + ( ( LibraryAdapter ) getListAdapter ( ) ) . notifyDataSetChanged ( ) ;
 mySearchResultsItem . run ( ) ;
 }


<nb>
 package NAMESPACE ;

 import NAMESPACE ;
 - import NAMESPACE ;
 + import NAMESPACE ;
 + import NAMESPACE ;
 + import NAMESPACE ;
 + import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 <nb> public abstract class ConfiguredCommand < T extends Configuration > implements Comm
 }

 COMMENT
 - COMMENT
 + COMMENT
 COMMENT
 COMMENT
 COMMENT


<nb>

 package NAMESPACE ;

 + import NAMESPACE ;
 import NAMESPACE ;

 import NAMESPACE ;
 <nb> public class DefaultIdeaLanguageLevel implements IdeaLanguageLevel , Serializable
 return STRING0 + level + STRING1 ;
 }

 + public JavaVersion toJavaVersion ( ) {
 + if ( level != null ) {
 + String javaVersionString = level . replaceFirst ( STRING2 , STRING3 ) ;
 + try {
 + return JavaVersion . valueOf ( javaVersionString ) ;
 + } catch ( IllegalArgumentException e ) {
 + SINGLE
 + }
 + }
 + return null ;
 + }
 +
 @ override
 public boolean equals ( Object o ) {
 if ( this == o ) {
 <nb> public class DefaultIdeaLanguageLevel implements IdeaLanguageLevel , Serializable
 public int hashCode ( ) {
 return level != null ? level . hashCode ( ) : NUMBER0 ;
 }
 - }
 + }

Add function to convert DefaultIdeaLanguageLevel to JavaVersion


<nb> public class ContentView extends FrameLayout {
 }
 }

 + boolean fetchPageHtml = Settings . get ( ) . getArticleModeEnabled ( ) && ArticleContent . tryForArticleContent ( currentUrl ) ;
 + Log . d ( STRING0 , STRING1 + fetchPageHtml ) ;
 SINGLE
 - mWebRenderer . runPageInspector ( ArticleContent . tryForArticleContent ( currentUrl ) ) ;
 + mWebRenderer . runPageInspector ( fetchPageHtml ) ;

 if ( equalUrl ) {
 updateAppsForUrl ( currentUrl ) ;

Don t fetch ArticleMode content if setting is disable


<nb> public class CamelContextFactoryBean extends IdentifiedType implements RouteCont
 SINGLE
 public SpringCamelContext getContext ( ) throws Exception {
 if ( context == null ) {
 - context = new SpringCamelContext ( getApplicationContext ( ) ) ;
 + context = createContext ( ) ;
 }
 return context ;
 }
 <nb> public class CamelContextFactoryBean extends IdentifiedType implements RouteCont
 SINGLE

 COMMENT
 + COMMENT
 + COMMENT
 + protected SpringCamelContext createContext ( ) {
 + return new SpringCamelContext ( getApplicationContext ( ) ) ;
 + }
 +
 + COMMENT
 COMMENT
 COMMENT
 protected void installRoutes ( ) throws Exception {

Allow context customization at creation time


<nb> public class DirectComponent extends DefaultComponent {

 @ override
 protected void doStop ( ) throws Exception {
 - ServiceHelper . stopService ( consumers . values ( ) ) ;
 + ServiceHelper . stopServices ( consumers ) ;
 consumers . clear ( ) ;
 super . doStop ( ) ;
 }

Fixed exception during stopping about concurrent access to hash map


<nb> public class DiagnosticGroups {

 static {
 DiagnosticGroups . registerGroup ( STRING0 ,
 - JSTypeCreatorFromJSDoc . INVALID_GENERICS_INSTANTIATION ,
 NewTypeInference . NULLABLE_DEREFERENCE ) ;

 SINGLE

Remove invalid generics from warningsOverload group


<nb> import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 + import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 <nb> public class MavenServerFunction extends RepositoryFunction {
 try {
 for ( Map . Entry < String , FileValue > entry : settingsFiles . entrySet ( ) ) {
 fingerprint . addString ( entry . getKey ( ) ) ;
 - fingerprint . addBytes ( entry . getValue ( ) . realRootedPath ( ) . asPath ( ) . getMD5Digest ( ) ) ;
 + Path path = entry . getValue ( ) . realRootedPath ( ) . asPath ( ) ;
 + if ( path . exists ( ) ) {
 + fingerprint . addBoolean ( true ) ;
 + fingerprint . addBytes ( path . getMD5Digest ( ) ) ;
 + } else {
 + fingerprint . addBoolean ( false ) ;
 + }
 }
 } catch ( IOException e ) {
 throw new RepositoryFunctionException ( e , Transience . TRANSIENT ) ;

Fix fingerprinting of Maven settings file


<nb> public class ReaderPostDetailFragment extends Fragment
 . append ( STRING0 ) . append ( greyExtraLight ) . append ( STRING1 )
 . append ( STRING2 ) . append ( marginSmall ) . append ( STRING3 ) ;

 + SINGLE
 + sbHtml . append ( STRING4 ) . append ( marginSmall ) . append ( STRING5 )
 + . append ( STRING6 ) . append ( marginSmall ) . append ( STRING5 )
 + . append ( STRING7 ) . append ( greyLight ) . append ( STRING8 ) ;
 +
 SINGLE
 sbHtml . append ( STRING9 ) . append ( linkColor ) . append ( STRING8 ) ;

Added blockquote styling to ReaderPostDetailFragment


<nb> public class ReaderPostDetailFragment extends Fragment
 @ override
 public View onCreateView ( LayoutInflater inflater , ViewGroup container , Bundle savedInstanceState ) {
 final View view = inflater . inflate ( R . layout . reader_fragment_post_detail , container , false ) ;
 - final Context context = container . getContext ( ) ;

 SINGLE
 mListView = ( WPListView ) view . findViewById ( android . R . id . list ) ;

Removed unused context from previous merge


<nb> public class GLRM extends ModelBuilder < GLRMModel , GLRMModel . GLRMParameters , GLRMMo
 SVDModel . SVDParameters parms = new SVDModel . SVDParameters ( ) ;
 parms . _train = _parms . _train ;
 parms . _ignored_columns = _parms . _ignored_columns ;
 - parms . _drop_const_cols = _parms . _drop_const_cols ;
 + parms . _ignore_const_cols = _parms . _ignore_const_cols ;
 parms . _drop_na20_cols = _parms . _drop_na20_cols ;
 parms . _score_each_iteration = _parms . _score_each_iteration ;
 parms . _useAllFactorLevels = true ; SINGLE


<nb> public class UsageInfo {
 if ( startOffset < NUMBER0 ) {
 throw new IllegalArgumentException ( STRING0 + element + STRING1 + startOffset ) ;
 }
 - if ( startOffset >= endOffset ) {
 + if ( startOffset > endOffset ) {
 throw new IllegalArgumentException ( STRING0 + element + STRING2 + ( endOffset - startOffset ) ) ;
 }


<nb> package NAMESPACE ;
 COMMENT
 COMMENT
 COMMENT
 - COMMENT
 + COMMENT
 COMMENT
 COMMENT
 public interface Configurable
 <nb> import NAMESPACE ;
 COMMENT
 COMMENT
 COMMENT
 - COMMENT
 + COMMENT
 COMMENT
 COMMENT
 public interface Configuration extends Serializable
 <nb> package NAMESPACE ;
 COMMENT
 COMMENT
 COMMENT
 - COMMENT
 + COMMENT
 COMMENT
 COMMENT
 COMMENT
 <nb> package NAMESPACE ;
 COMMENT
 COMMENT
 COMMENT
 - COMMENT
 + COMMENT
 COMMENT
 COMMENT
 public interface Contextualizable

fixed avalon links patch by Peter Dobratz


<nb> public class TfsShellTest {
 Assert . assertEquals ( true , mTfs . getInfo ( file ) . isPinned ) ;
 }

 - COMMENT
 - COMMENT
 -
 COMMENT
 COMMENT
 COMMENT


<nb> public class EclipseImportBuilder extends ProjectImportBuilder < String > implement
 }
 final Element classpathElement = JDOMUtil . loadDocument ( new File ( path , EclipseXml . DOT_CLASSPATH_EXT ) ) . getRootElement ( ) ;
 final Module module = moduleModel . newModule ( modulesDirectory + STRING0 + EclipseProjectFinder . findProjectName ( path ) + IdeaXml . IML_EXT , StdModuleTypes . JAVA ) ;
 + result . add ( module ) ;
 final ModifiableRootModel rootModel = ModuleRootManager . getInstance ( module ) . getModifiableModel ( ) ;
 rootModels [ idx ++ ] = rootModel ;

add module to project structure on import


<nb> public class OverloadResolutionResultsImpl < D extends CallableDescriptor > impleme
 }

 public static < D extends CallableDescriptor > OverloadResolutionResultsImpl < D > nameNotFound ( ) {
 - return new OverloadResolutionResultsImpl < D > ( Code . NAME_NOT_FOUND , Collections . < ResolvedCallWithTrace < D > > emptyList ( ) ) ;
 + OverloadResolutionResultsImpl < D > results = new OverloadResolutionResultsImpl < D > (
 + Code . NAME_NOT_FOUND , Collections . < ResolvedCallWithTrace < D > > emptyList ( ) ) ;
 + results . setAllCandidates ( Collections . < ResolvedCall < D > > emptyList ( ) ) ;
 + return results ;
 }

 public static < D extends CallableDescriptor > OverloadResolutionResultsImpl < D > singleFailedCandidate ( ResolvedCallWithTrace < D > candidate ) {

Set all candidates empty collection if no candidates found


<nb> public abstract class Persist {

 private static StringBuilder escapeBytes ( byte [ ] bytes , int i , StringBuilder sb ) {
 for ( ; i < bytes . length ; i ++ ) {
 - byte b = bytes [ i ] ;
 - char c = NUMBER0 ;
 + char b = ( char ) bytes [ i ] , c = NUMBER0 ;
 switch ( b ) {
 case STRING0 : c = STRING0 ; break ;
 case STRING1 : c = STRING2 ; break ;


<nb>
 COMMENT
 package NAMESPACE ;

 - import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 <nb> public interface Promise < T > {
 }

 @ notnull
 - static < T > Promise < T > wrap ( @ notnull AsyncResult < T > asyncResult ) {
 - final AsyncPromise < T > promise = new AsyncPromise < > ( ) ;
 - asyncResult . doWhenDone ( ( Consumer < T > ) result - > promise . setResult ( result ) ) . doWhenRejected ( promise : : setError ) ;
 - return promise ;
 - }
 -
 - @ notnull
 Promise < T > done ( @ notnull Consumer < ? super T > done ) ;

 @ notnull


<nb>
 package NAMESPACE ;

 import NAMESPACE ;
 + import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 + import NAMESPACE ;

 import NAMESPACE ;
 import NAMESPACE ;
 <nb> public class FavouritesDbHelper extends SQLiteOpenHelper {

 private void checkFavoritePoints ( ) {
 if ( favoriteGroups == null ) {
 - favoriteGroups = new LinkedHashMap < String , List < FavouritePoint > > ( ) ;
 + favoriteGroups = new TreeMap < String , List < FavouritePoint > > ( Collator . getInstance ( ) ) ;
 SQLiteDatabase db = getWritableDatabase ( ) ;
 if ( db != null ) {
 Cursor query = db . rawQuery ( STRING0 + FAVOURITE_COL_NAME + STRING1 + FAVOURITE_COL_CATEGORY + STRING1 + FAVOURITE_COL_LAT + STRING2 + FAVOURITE_COL_LON + STRING3 + SINGLE


<nb> public class PropertyFileConfiguratorTest
 . build ( ) ;

 InMemoryAppender appender = new InMemoryAppender ( PropertyFileConfigurator . log ) ;
 - PropertyFileConfigurator configurator = new PropertyFileConfigurator ( emptyPropertyFile ) ;
 + new PropertyFileConfigurator ( emptyPropertyFile ) ;

 assertThat ( appender . toString ( ) , containsString ( String . format (
 STRING0 ,

Removed unused variable keeping side effect in log


<nb> public class XBooleanFilterTests extends ElasticsearchLuceneTestCase {
 rightResult . or ( rightIter ) ;
 }

 - assertThat ( leftResult . cardinality ( ) , equalTo ( leftResult . cardinality ( ) ) ) ;
 + assertThat ( leftResult . cardinality ( ) , equalTo ( rightResult . cardinality ( ) ) ) ;
 for ( int i = NUMBER0 ; i < reader . maxDoc ( ) ; i ++ ) {
 assertThat ( errorMsg ( clauses , topLevel ) + STRING0 + i , leftResult . get ( i ) , equalTo ( rightResult . get ( i ) ) ) ;
 }


<nb> public class MetricsServiceImpl implements MetricsService {
 NinjaProperties ninjaProps ) {

 this . ninjaProps = ninjaProps ;
 - this . metricRegistry = new MetricRegistry ( ) ;
 + this . metricRegistry = appMetrics ;

 }


<nb> public class JSFSubsystemTestCase extends AbstractSubsystemBaseTest {
 protected String getSubsystemXml ( ) throws IOException {
 return STRING0 ;
 }
 +
 + @ override
 + protected String getSubsystemXsdPath ( ) throws Exception {
 + return STRING1 ;
 + }
 +
 + @ override
 + protected String [ ] getSubsystemTemplatePaths ( ) throws IOException {
 + return new String [ ] {
 + STRING2
 + } ;
 + }
 }


<nb> public class BinaryFrame extends DataFrame
 @ override
 public Type getType ( )
 {
 + if ( getOpCode ( ) == OpCode . CONTINUATION )
 + return Type . CONTINUATION ;
 return Type . BINARY ;
 }
 }
 <nb> public class TextFrame extends DataFrame
 @ override
 public Type getType ( )
 {
 + if ( getOpCode ( ) == OpCode . CONTINUATION )
 + return Type . CONTINUATION ;
 return Type . TEXT ;
 }

permessage deflate extension causes protocol error in Firefox Chrome


<nb> public enum BlockStoreContext {
 COMMENT
 private void initializeLocalBlockWorkerClientPool ( ) {
 if ( ! mLocalBlockWorkerClientPoolInitialized . getAndSet ( true ) ) {
 - synchronized ( mLocalBlockWorkerClientPool ) {
 + synchronized ( mLocalBlockWorkerClientPoolInitialized ) {
 NetAddress localWorkerAddress =
 getWorkerAddress ( NetworkAddressUtils . getLocalHostName ( ClientContext . getConf ( ) ) ) ;
 SINGLE
 <nb> public enum BlockStoreContext {
 } else {
 mLocalBlockWorkerClientPool = new BlockWorkerClientPool ( localWorkerAddress ) ;
 }
 -
 }
 }
 }


<nb> public abstract class AbstractAuthenticationToken implements Authentication {
 public String toString ( ) {
 StringBuffer sb = new StringBuffer ( ) ;
 sb . append ( super . toString ( ) ) . append ( STRING0 ) ;
 - sb . append ( STRING1 ) . append ( this . getPrincipal ( ) ) . append ( STRING2 ) ;
 + sb . append ( STRING3 ) . append ( this . getPrincipal ( ) ) . append ( STRING2 ) ;
 sb . append ( STRING4 ) ;
 sb . append ( STRING5 ) . append ( this . isAuthenticated ( ) ) . append ( STRING2 ) ;
 sb . append ( STRING6 ) . append ( this . getDetails ( ) ) . append ( STRING2 ) ;

Corrected toString output using username instead of principal


<nb> import NAMESPACE ;
 import NAMESPACE ;

 COMMENT
 - COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 COMMENT

 public class TitanGraphConfiguration implements GraphConfiguration {


<nb>

 package NAMESPACE ;

 - import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 <nb> public class ShowInfoFragment extends SherlockFragment implements LoaderCallback
 }

 private void onRateOnTrakt ( ) {
 - Activity activity = getActivity ( ) ;
 - if ( ServiceUtils . isTraktCredentialsValid ( activity ) ) {
 + if ( ServiceUtils . isTraktCredentialsValid ( getActivity ( ) ) ) {
 TraktRateDialogFragment rateShow = TraktRateDialogFragment . newInstance ( getShowTvdbId ( ) ) ;
 rateShow . show ( getFragmentManager ( ) , STRING0 ) ;
 fireTrackerEvent ( STRING1 ) ;
 } else {
 - startActivity ( new Intent ( activity , ConnectTraktActivity . class ) ) ;
 + startActivity ( new Intent ( getActivity ( ) , ConnectTraktActivity . class ) ) ;
 }
 }


<nb> import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 - import NAMESPACE ;

 import NAMESPACE ;
 import NAMESPACE ;
 <nb> public class OCSVTransformer extends OAbstractTransformer {
 private boolean unicode = true ;

 public static boolean isFinite ( final float value ) {
 - return Math . abs ( value ) <= FloatConsts . MAX_VALUE ;
 + return Math . abs ( value ) <= Float . MAX_VALUE ;
 }

 @ override
 <nb> public class OCSVTransformer extends OAbstractTransformer {
 COMMENT
 COMMENT
 protected boolean isFinite ( Float f ) {
 - return Math . abs ( f ) <= FloatConsts . MAX_VALUE ;
 + return Math . abs ( f ) <= Float . MAX_VALUE ;
 }

 SINGLE


<nb> import NAMESPACE ;

 COMMENT
 COMMENT
 - COMMENT
 + COMMENT
 COMMENT
 COMMENT
 public class IncrementingFakeClock implements Clock {


<nb> package NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;

 + import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 <nb> public class ListAccounts implements Controller {
 public ModelAndView handleRequest ( HttpServletRequest request , HttpServletResponse response ) throws Exception {
 SINGLE
 SINGLE
 - SINGLE
 - SINGLE
 + SINGLE
 SINGLE

 SINGLE
 <nb> package NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;

 + import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 <nb> public class PostAccounts implements Controller {

 public ModelAndView handleRequest ( HttpServletRequest request , HttpServletResponse response ) throws Exception {
 SINGLE
 - SINGLE
 - SINGLE
 - SINGLE
 + SINGLE
 + SINGLE
 SINGLE

 SINGLE

Throw an exception instead of sending back a HTTP error code


<nb> class WebSocketClientProtocolHandshakeHandler extends ChannelInboundHandlerAdapt
 return ;
 }

 - if ( ! handshaker . isHandshakeComplete ( ) ) {
 - handshaker . finishHandshake ( ctx . channel ( ) , ( FullHttpResponse ) msg ) ;
 - ctx . fireUserEventTriggered (
 - WebSocketClientProtocolHandler . ClientHandshakeStateEvent . HANDSHAKE_COMPLETE ) ;
 - ctx . pipeline ( ) . remove ( this ) ;
 - return ;
 + FullHttpResponse response = ( FullHttpResponse ) msg ;
 + try {
 + if ( ! handshaker . isHandshakeComplete ( ) ) {
 + handshaker . finishHandshake ( ctx . channel ( ) , response ) ;
 + ctx . fireUserEventTriggered (
 + WebSocketClientProtocolHandler . ClientHandshakeStateEvent . HANDSHAKE_COMPLETE ) ;
 + ctx . pipeline ( ) . remove ( this ) ;
 + return ;
 + }
 + throw new IllegalStateException ( STRING0 ) ;
 + } finally {
 + response . release ( ) ;
 }
 - throw new IllegalStateException ( STRING0 ) ;
 }
 }

Fix the leak in the WebSocketClientProtocolHandshakeHandler


<nb> public class Ping

 private static CountDownLatch pongConnectionLatch = new CountDownLatch ( NUMBER0 ) ;

 - private static long numPongsReceived = NUMBER1 ;
 + private static long numPongsReceived ;

 public static void main ( final String [ ] args ) throws Exception
 {
 <nb> public class Ping

 warmup . get ( ) ;
 histogram . reset ( ) ;
 - numPongsReceived = NUMBER1 ;

 System . out . println ( STRING0 + NUMBER_OF_MESSAGES + STRING1 ) ;

 <nb> public class Ping
 {
 final IdleStrategy idleStrategy = new BusySpinIdleStrategy ( ) ;

 + numPongsReceived = NUMBER1 ; SINGLE
 do
 {
 final int fragmentsRead = pongSubscription . poll ( FRAGMENT_COUNT_LIMIT ) ;

cleaned up reset strategy for numPongsReceived for clarity and thread usage


<nb> public class ASTHelpers {
 COMMENT
 COMMENT
 public static Type getType ( Tree tree ) {
 - if ( tree instanceof JCFieldAccess ) {
 - return ( ( JCFieldAccess ) tree ) . sym . type ;
 - } else if ( tree instanceof JCTree ) {
 + if ( tree instanceof JCTree ) {
 return ( ( JCTree ) tree ) . type ;
 - } else {
 - return null ;
 }
 + return null ;
 }

 public static String getAnnotationName ( AnnotationTree tree ) {

Remove questionable handling of JCFieldAccess from ASTHelpers


<nb> public class NotificationStackScrollLayout extends ViewGroup
 }
 }
 }
 -
 - mActivePointerId = INVALID_POINTER ;
 - endDrag ( ) ;
 }
 +
 + mActivePointerId = INVALID_POINTER ;
 + endDrag ( ) ;
 }
 +
 break ;
 case MotionEvent . ACTION_CANCEL :
 if ( mIsBeingDragged && getChildCount ( ) > NUMBER0 ) {


<nb> import NAMESPACE ;

 import static NAMESPACE ;
 import static NAMESPACE ;
 - import static NAMESPACE ;
 + import static NAMESPACE ;
 import static NAMESPACE ;

 public class FromDataTableTest {
 <nb> import NAMESPACE ;
 import NAMESPACE ;

 import static NAMESPACE ;
 - import static NAMESPACE ;
 + import static NAMESPACE ;

 public class TableDifferTest {


<nb> public class SmackException extends Exception {
 sb . append ( STRING0 ) ;
 }
 SINGLE
 - sb . deleteCharAt ( sb . length ( ) ) ;
 + sb . deleteCharAt ( sb . length ( ) - NUMBER0 ) ;
 return new ConnectionException ( sb . toString ( ) , failedAddresses ) ;
 }

Fix StringIndexOutOfBoundsException in ConnectionException


<nb> public class RefParser {
 String [ ] longRefPaths = refPaths . split ( STRING0 ) ;
 List < Ref > refs = new ArrayList < Ref > ( ) ;
 for ( String longRefPatch : longRefPaths ) {
 - refs . add ( createRef ( hash , longRefPatch ) ) ;
 + Ref ref = createRef ( hash , longRefPatch ) ;
 + if ( ref . getType ( ) != Ref . RefType . STASH ) {
 + refs . add ( ref ) ;
 + }
 }
 return refs ;
 }


<nb> public class SessionSetting {
 }

 public void bindTo ( SocketServer server ) {
 + if ( isAnyResponse ( ) ) {
 + server . response ( getResponseHandler ( ) ) ;
 + return ;
 + }
 +
 server . request ( getRequestMatcher ( ) ) . response ( getResponseHandler ( ) ) ;
 }

added any response to socket json config


<nb> public class ShortcutManager implements NativePreviewHandler ,

 return filtered ;
 }
 -
 +
 private boolean handleKeyDown ( NativeEvent event )
 {
 SINGLE
 <nb> public class ShortcutManager implements NativePreviewHandler ,
 {
 NativeEvent event = ( NativeEvent ) object ;

 + SINGLE
 + SINGLE
 + SINGLE
 + if ( ! keyBuffer_ . isEmpty ( ) )
 + {
 + for ( Map . Entry < KeyMapType , KeyMap > entry : keyMaps_ . entrySet ( ) )
 + {
 + if ( entry . getValue ( ) . isPrefix ( keyBuffer_ ) )
 + {
 + event . stopPropagation ( ) ;
 + event . preventDefault ( ) ;
 + return ;
 + }
 + }
 + }
 +
 SINGLE
 KeyCombination keys = new KeyCombination ( event ) ;
 int keyCode = keys . getKeyCode ( ) ;


<nb> public class WeldApplication extends ForwardingApplication {
 synchronized ( this ) {
 if ( beanManager == null ) {
 try {
 + SINGLE
 beanManager = ( BeanManager ) new InitialContext ( ) . lookup ( STRING0 ) ;
 - } catch ( NamingException e ) {
 + } catch ( NamingException | IllegalArgumentException e ) {
 return null ;
 }
 }


<nb> public class ElasticSearchIndex implements IndexProvider {
 return value ;
 } else if ( value instanceof UUID ) {
 return value . toString ( ) ;
 - } else throw new IllegalArgumentException ( STRING0 + value ) ;
 + } else throw new IllegalArgumentException ( STRING0 + value . getClass ( ) + STRING1 + value + STRING2 ) ;
 }

 @ override

Add classname to ES s Unsupported type exception


<nb> import NAMESPACE ;
 import NAMESPACE ;

 COMMENT
 - COMMENT
 - COMMENT
 - COMMENT
 - COMMENT
 - COMMENT
 + COMMENT
 + COMMENT
 COMMENT
 public abstract class IncrementalTestCase extends TestCase {
 private static class RootStripper {
 <nb> public abstract class IncrementalTestCase extends TestCase {
 }
 }

 - static {
 - Logger . setFactory ( new MyFactory ( ) ) ;
 - }
 -
 private static RootStripper stripper = new RootStripper ( ) ;

 private final String groupName ;
 <nb> public abstract class IncrementalTestCase extends TestCase {
 private String baseDir ;
 private String workDir ;

 + @ suppresswarnings ( STRING0 )
 protected IncrementalTestCase ( final String name ) throws Exception {
 super ( name ) ;
 groupName = name ;

Restore log factory after JPS tests cleanup


<nb> class JBTerminalSystemSettingsProvider extends DefaultTabbedSettingsProvider imp

 @ override
 public boolean useAntialiasing ( ) {
 - return UISettings . getInstance ( ) . ANTIALIASING_IN_EDITOR ;
 + return true ; SINGLE
 }

 @ override


<nb> import NAMESPACE
 import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 + import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;

 <nb> public class ChunkOutputUi
 @ override
 public void onOutputHeightChanged ( int outputHeight , boolean ensureVisible )
 {
 + SINGLE
 + if ( ensureVisible )
 + {
 + Scope scope = getScope ( ) ;
 + if ( scope != null )
 + {
 + display_ . unfold ( Range . fromPoints ( scope . getPreamble ( ) ,
 + scope . getEnd ( ) ) ) ;
 + }
 + }
 +
 int height =
 outputWidget_ . getExpansionState ( ) == ChunkOutputWidget . COLLAPSED ?
 CHUNK_COLLAPSED_HEIGHT :

unfold chunk code region when output completes for correct layout


<nb> abstract class AbstractBuildConfigFields implements Iterable < Field > {
 }

 private static final Pattern VARIABLE_DEFINITION_PATTERN = Pattern . compile (
 - STRING0 +
 + STRING1 + Pattern . quote ( STRING2 ) + STRING3 +
 STRING4 +
 STRING5 +
 STRING6 +

Add support for arrays in AbstractBuildConfigFields


<nb> import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 - import NAMESPACE ;
 import NAMESPACE ;

 import NAMESPACE ;
 <nb> import NAMESPACE ;
 COMMENT
 COMMENT
 COMMENT
 - COMMENT
 + COMMENT
 COMMENT
 public final class MockMvcWebConnection implements WebConnection {

 <nb> package NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;

 - import NAMESPACE ;
 import NAMESPACE ;

 import NAMESPACE ;
 <nb> import NAMESPACE ;
 COMMENT
 COMMENT
 COMMENT
 - COMMENT
 - COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 COMMENT
 COMMENT
 COMMENT


<nb> public abstract class NineViewGroup extends ViewGroup {
 SINGLE
 SINGLE
 SINGLE
 - if ( visibility == GONE ) {
 - clearAnimation ( ) ;
 - } else if ( visibility == VISIBLE && mProxy != null ) {
 - setAnimation ( mProxy ) ;
 + if ( mProxy != null ) {
 + if ( visibility == GONE ) {
 + clearAnimation ( ) ;
 + } else if ( visibility == VISIBLE ) {
 + setAnimation ( mProxy ) ;
 + }
 }
 super . setVisibility ( visibility ) ;
 }


<nb> public final class ElementMatchers {
 }

 COMMENT
 + COMMENT
 COMMENT
 COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 COMMENT
 COMMENT
 COMMENT
 <nb> public final class ElementMatchers {
 }

 COMMENT
 + COMMENT
 COMMENT
 COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 COMMENT
 COMMENT
 COMMENT


<nb> import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 + import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 <nb> public class ChangeSignatureGestureTest extends LightCodeInsightFixtureTestCase

 myFixture . doHighlighting ( ) ;
 - final String hint = STRING0 ;
 + final String hint = ChangeSignatureDetectorAction . CHANGE_SIGNATURE ;
 if ( shouldShow ) {
 final IntentionAction intention = myFixture . findSingleIntention ( hint ) ;
 myFixture . launchAction ( intention ) ;


<nb>
 package NAMESPACE ;

 + import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 <nb> public class MeterMetric implements Metric {
 COMMENT
 public static MeterMetric newMeter ( long interval , TimeUnit intervalUnit , TimeUnit unit ) {
 final MeterMetric meter = new MeterMetric ( unit ) ;
 - final Runnable ticker = new Runnable ( ) {
 + final SoftReference < MeterMetric > reference = new SoftReference < MeterMetric > ( meter ) ;
 + final Runnable job = new Runnable ( ) {
 @ override
 public void run ( ) {
 - meter . tick ( ) ;
 + SINGLE
 + SINGLE
 + SINGLE
 + SINGLE
 + reference . get ( ) . tick ( ) ;
 }
 } ;
 - TICK_THREAD . scheduleAtFixedRate ( ticker , interval , interval , intervalUnit ) ;
 + TICK_THREAD . scheduleAtFixedRate ( job , interval , interval , intervalUnit ) ;
 return meter ;
 }

Fix a potential resource leak by letting MeterMetric instances get GC d


<nb> public class DisUnityWindow extends javax . swing . JFrame {

 try {
 AssetBundleUtils . extract ( bundlePath , outputPath , progress ) ;
 - } catch ( IOException ex ) {
 + } catch ( Exception ex ) {
 new DialogBuilder ( parent )
 . exception ( ex )
 . withMessage ( STRING0 + bundleFile )


<nb> public abstract class GwtApplication implements EntryPoint , Application {
 try {
 graphics = new GwtGraphics ( root , config ) ;
 } catch ( Throwable e ) {
 + root . clear ( ) ;
 root . add ( new Label ( STRING0 ) ) ;
 return ;
 }


<nb> public abstract class ParserBase extends ParserMinimalBase

 SINGLE
 @ override public Object getEmbeddedObject ( ) throws IOException { return null ; }
 -
 +
 + @ suppresswarnings ( STRING0 )
 + @ override SINGLE
 + public byte [ ] getBinaryValue ( Base64Variant variant ) throws IOException
 + {
 + if ( _binaryValue == null ) {
 + if ( _currToken != JsonToken . VALUE_STRING ) {
 + _reportError ( STRING1 + _currToken + STRING2 ) ;
 + }
 + ByteArrayBuilder builder = _getByteArrayBuilder ( ) ;
 + _decodeBase64 ( getText ( ) , builder , variant ) ;
 + _binaryValue = builder . toByteArray ( ) ;
 + }
 + return _binaryValue ;
 + }
 +
 COMMENT
 COMMENT
 COMMENT

Add base impl of getBinaryValue Base64Variant


<nb> public abstract class ORecordAbstract < T > implements ORecord < T > , ORecordInternal <
 public ORecordAbstract < T > reset ( ) {
 _status = ORecordElement . STATUS . LOADED ;
 _version = NUMBER0 ;
 + _size = NUMBER0 ;

 setDirty ( ) ;
 if ( _recordId != null )

Fixed issue with non english characters reported by Krisztian


<nb> import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 + import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;


<nb> public abstract class Vertex implements Serializable , Cloneable {
 for ( int i = NUMBER0 , j = NUMBER0 ; i < existing . length ; i ++ ) {
 if ( existing [ i ] == e ) continue ;
 copy [ j ++ ] = existing [ i ] ;
 - if ( j == existing . length ) {
 + if ( j == copy . length ) {
 SINGLE
 LOG . error ( STRING0 ) ;
 return existing ;
 }
 - }
 + }
 SINGLE
 for ( Edge edge : copy ) {
 if ( edge == e ) {

Check against length of copy not length of original


<nb> public interface HyperSpaceWalker < MP extends Model . Parameters , C extends HyperSp
 defaults = ( MP ) params . getClass ( ) . newInstance ( ) ;
 }
 catch ( Exception e ) {
 - throw new H2OIllegalArgumentException ( STRING0 ) ;
 + throw new H2OIllegalArgumentException ( STRING1 ) ;
 }

 SINGLE

fixed typo in error message in HyperSpaceWalker java


<nb>
 package NAMESPACE ;

 import NAMESPACE ;
 + import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 <nb> public class AsynchronousMergingProcessor extends AbstractMergingProcessor < Sessi
 final AsyncMethodsMetaData asyn = sessionBeanData . getAsyncMethods ( ) ;
 if ( asyn != null ) {
 for ( AsyncMethodMetaData method : asyn ) {
 - final Method m = MethodResolutionUtils . resolveMethod ( method . getMethodName ( ) , method . getMethodParams ( ) , componentClass , deploymentReflectionIndex ) ;
 - description . addAsynchronousMethod ( MethodIdentifier . getIdentifierForMethod ( m ) ) ;
 + final Collection < Method > methods = MethodResolutionUtils . resolveMethods ( method . getMethodName ( ) , method . getMethodParams ( ) , componentClass , deploymentReflectionIndex ) ;
 + for ( final Method m : methods ) {
 + description . addAsynchronousMethod ( MethodIdentifier . getIdentifierForMethod ( m ) ) ;
 + }
 }
 }
 }


<nb> public abstract class CamelServletContextListener < R extends Registry > implements
 COMMENT
 public static ServletCamelContext instance ;

 + COMMENT
 + COMMENT
 + COMMENT
 + public static final String CAMEL_CONTEXT_KEY = STRING0 ;
 +
 protected static final Logger LOG = LoggerFactory . getLogger ( CamelServletContextListener . class ) ;
 protected ServletCamelContext camelContext ;
 protected CamelContextLifecycle < R > camelContextLifecycle ;
 <nb> public abstract class CamelServletContextListener < R extends Registry > implements
 instance = camelContext ;
 }

 + SINGLE
 + sce . getServletContext ( ) . setAttribute ( CAMEL_CONTEXT_KEY , camelContext ) ;
 +
 LOG . info ( STRING1 ) ;
 }

 <nb> public abstract class CamelServletContextListener < R extends Registry > implements
 camelContext = null ;
 registry = null ;
 instance = null ;
 +
 + SINGLE
 + sce . getServletContext ( ) . removeAttribute ( CAMEL_CONTEXT_KEY ) ;
 +
 LOG . info ( STRING2 ) ;
 }

camel servletlistener Store created CamelContext on ServletContext attribute


<nb> import NAMESPACE ;
 public class CraftingHandler {

 @ subscribeevent
 - public void onCrafing ( PlayerEvent . ItemCraftedEvent event ) {
 + public void onCrafting ( PlayerEvent . ItemCraftedEvent event ) {
 Item item = event . crafting . getItem ( ) ;

 if ( item . equals ( BuildCraftCore . woodenGearItem ) ) {


<nb> public class Picasso {

 private static final String FILE_SCHEME = STRING0 ;
 private static final String CONTENT_SCHEME = STRING1 ;
 +
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 private static final Object DECODE_LOCK = new Object ( ) ;

 SINGLE


<nb> public class Advice implements AsmVisitorWrapper . ForDeclaredMethods . MethodVisito
 COMMENT
 COMMENT
 COMMENT
 - COMMENT
 - COMMENT
 - COMMENT
 - COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 COMMENT
 COMMENT
 protected abstract ForAdvice bind ( MethodDescription . InDefinedShape adviceMethod ,
 <nb> public class Advice implements AsmVisitorWrapper . ForDeclaredMethods . MethodVisito

 COMMENT
 COMMENT
 - COMMENT
 - COMMENT
 - COMMENT
 - COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 COMMENT
 COMMENT
 COMMENT

Added additional information to new origin patterns


<nb> public abstract class JCVideoPlayer extends FrameLayout implements JCMediaPlayer
 if ( ( System . currentTimeMillis ( ) - lastAutoFullscreenTime ) > NUMBER0
 && isCurrentMediaListener ( )
 && currentState == CURRENT_STATE_PLAYING
 - && currentScreen != SCREEN_WINDOW_FULLSCREEN ) {
 + && currentScreen != SCREEN_WINDOW_FULLSCREEN
 + && currentScreen != SCREEN_WINDOW_TINY ) {
 lastAutoFullscreenTime = System . currentTimeMillis ( ) ;
 startWindowFullscreen ( ) ;
 }


<nb> public class TankBucketHandler implements IBucketHandler {

 int qty = tank . empty ( BuildCraftAPI . BUCKET_VOLUME , false ) ;

 - ItemStack filledBucket = BuildCraftAPI . getFilledItemForLiquid ( tank . getLiquidId ( ) ) ;
 + ItemStack filledBucket = BuildCraftAPI . fillLiquidContainer ( tank . getLiquidId ( ) , new ItemStack ( Item . bucketEmpty ) ) ;

 if ( qty >= BuildCraftAPI . BUCKET_VOLUME && filledBucket != null ) {
 tank . empty ( BuildCraftAPI . BUCKET_VOLUME , true ) ;

Changed fill code to safer BuildcraftAPI fillLiquidContainer


<nb> public class StandardRoot extends LifecycleMBeanBase implements WebResourceRoot
 return result ;
 }

 + SINGLE
 + SINGLE

 @ override
 public void createWebResourceSet ( ResourceSetType type , String webAppMount ,


<nb> import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;

 - public class SampleActivity extends ActionBarActivity implements ActionBar . TabListener {
 + public class SampleActivity extends ActionBarActivity {
 private SectionsPagerAdapter mSectionsPagerAdapter ;
 private ViewPager mViewPager ;

 <nb> public class SampleActivity extends ActionBarActivity implements ActionBar . TabLi
 tabLayout . setViewPager ( mViewPager ) ;
 }

 - @ override
 - public void onTabSelected ( ActionBar . Tab tab , FragmentTransaction fragmentTransaction ) {
 - mViewPager . setCurrentItem ( tab . getPosition ( ) ) ;
 - }
 -
 - @ override
 - public void onTabUnselected ( ActionBar . Tab tab , FragmentTransaction fragmentTransaction ) {
 - }
 -
 - @ override
 - public void onTabReselected ( ActionBar . Tab tab , FragmentTransaction fragmentTransaction ) {
 - }
 -
 -
 public class SectionsPagerAdapter extends FragmentPagerAdapter {

 public SectionsPagerAdapter ( FragmentManager fm ) {


<nb> public class AndroidDatabaseResults implements DatabaseResults {

 public boolean getBoolean ( int columnIndex ) throws SQLException {
 int col = jdbcColumnIndexToAndroid ( columnIndex ) ;
 - if ( cursor . isNull ( col ) )
 + if ( cursor . isNull ( col ) || cursor . getShort ( col ) == NUMBER0 ) {
 return false ;
 - return cursor . getShort ( col ) != NUMBER0 ;
 + } else {
 + return true ;
 + }
 }

 public byte getByte ( int columnIndex ) throws SQLException {


<nb> package NAMESPACE ;

 import NAMESPACE ;
 import NAMESPACE ;
 + import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 <nb> public class SimpleTypesTest extends AbstractTest {

 long llong2 ;

 + BigInteger bigInteger ;
 +
 String sstring ;
 List < String > sstringList ;

 <nb> public class SimpleTypesTest extends AbstractTest {
 cl = QSimpleTypesTest_SimpleTypes . class ;
 match ( PNumber . class , STRING0 ) ;
 match ( PNumber . class , STRING1 ) ;
 + match ( PNumber . class , STRING2 ) ;
 match ( PNumber . class , STRING3 ) ;
 match ( PNumber . class , STRING4 ) ;
 match ( PNumber . class , STRING5 ) ;


<nb> public final class Settings {
 STRING0 ;

 COMMENT
 - COMMENT
 + COMMENT
 COMMENT
 public static final String GTALK_SERVICE_WIFI_MAX_HEARTBEAT_INTERVAL_MS =
 STRING1 ;
 <nb> public final class Settings {
 COMMENT
 public static final String PUSH_MESSAGING_REGISTRATION_URL =
 STRING2 ;
 -
 +
 + COMMENT
 + COMMENT
 + COMMENT
 + public static final String GTALK_PICASA_ALBUM_URL =
 + STRING3 ;
 +
 + COMMENT
 + COMMENT
 + COMMENT
 + public static final String GTALK_FLICKR_PHOTO_INFO_URL =
 + STRING4 ;
 +
 + COMMENT
 + COMMENT
 + COMMENT
 + public static final String GTALK_FLICKR_PHOTO_URL =
 + STRING5 ;
 +
 + COMMENT
 + COMMENT
 + COMMENT
 + public static final String GTALK_YOUTUBE_VIDEO_URL =
 + STRING6 ;
 +
 +
 + COMMENT
 + COMMENT
 + COMMENT
 + public static final String DATA_MESSAGE_GET_APP_TOKEN_URL =
 + STRING7 ;
 +
 COMMENT
 COMMENT
 COMMENT


<nb>
 COMMENT
 package NAMESPACE ;

 - import NAMESPACE ;
 import NAMESPACE ;
 - import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;


<nb> public class MessageList
 }
 }

 + private void onAccounts ( )
 + {
 + Accounts . listAccounts ( this ) ;
 + finish ( ) ;
 + }
 +
 private void onShowFolderList ( )
 {
 FolderList . actionHandleAccount ( this , mAccount , false ) ;
 <nb> public class MessageList

 }

 - private void onAccounts ( )
 - {
 - Accounts . listAccounts ( this ) ;
 - finish ( ) ;
 - }

 private void onCycleSort ( )
 {

Reorder methods for better logical grouping


<nb>
 COMMENT
 package NAMESPACE ;

 - import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 <nb> public class ChunkIconsManager
 editor . getRenderer ( ) . screenToTextCoordinates ( pageX , pageY ) ;

 String line = editor . getSession ( ) . getLine ( position . getRow ( ) ) ;
 - Debug . logObject ( line ) ;

 return line . contains ( STRING0 ) ;
 }


<nb> public final class ModelImporterVisualPanel1 extends JPanel implements AssetEven
 if ( data != null ) {
 ( ( AssetDataObject ) obj ) . getLookupContents ( ) . add ( manager ) ;
 mainKey = data . getAssetKey ( ) ;
 + currentModel = ( Spatial ) data . loadAsset ( ) ;
 }
 } catch ( DataObjectNotFoundException ex ) {
 Exceptions . printStackTrace ( ex ) ;
 mainKey = new ModelKey ( path . getName ( ) ) ;
 }
 }
 - currentModel = ( Spatial ) manager . loadAsset ( mainKey ) ;
 + SINGLE
 if ( currentModel != null ) {
 offPanel . attach ( currentModel ) ;
 updateProperties ( mainKey ) ;

use only SDK api for model loading in model import tool


<nb> import NAMESPACE ;

 COMMENT
 COMMENT
 + COMMENT
 + COMMENT
 COMMENT
 - public final class FileContentImpl extends UserDataHolderBase implements FileContent {
 - private final VirtualFile myFile ;
 - private final String myFileName ;
 - private final FileType myFileType ;
 - private final Charset myCharset ;
 - private byte [ ] myContent ;
 - private CharSequence myContentAsText ;
 - private final long myStamp ;
 - private byte [ ] myHash ;
 + public class FileContentImpl extends UserDataHolderBase implements FileContent {
 + protected final VirtualFile myFile ;
 + protected final String myFileName ;
 + protected final FileType myFileType ;
 + protected final Charset myCharset ;
 + protected byte [ ] myContent ;
 + protected CharSequence myContentAsText ;
 + protected final long myStamp ;
 + protected byte [ ] myHash ;

 @ override
 public Project getProject ( ) {

make FileContentImpl non final to be overridden in Upsource


<nb> public class TestEventLogger extends AbstractTestLogger implements TestOutputLis
 }

 private boolean shouldLogEvent ( TestDescriptor descriptor , TestLogEvent event ) {
 - return ( isLoggedGranularity ( descriptor ) && isLoggedEventType ( event ) ) ;
 + return isLoggedGranularity ( descriptor ) && isLoggedEventType ( event ) ;
 }

 private boolean shouldLogExceptions ( TestResult result ) {


<nb> public class AvatarView extends ImageView implements View . OnClickListener , LiveV
 }

 private void setImageWhenReady ( ) {
 + if ( isInEditMode ( ) ) {
 + return ;
 + }
 +
 if ( getWidth ( ) > NUMBER0 && getHeight ( ) > NUMBER0 ) {
 SINGLE
 if ( mOriginalDrawable != null ) {
 <nb> public class AvatarView extends ImageView implements View . OnClickListener , LiveV
 protected void onDraw ( Canvas canvas ) {
 super . onDraw ( canvas ) ;

 - if ( getDrawable ( ) == null ) {
 + if ( getDrawable ( ) == null && ! isInEditMode ( ) ) {
 int xPos = ( getWidth ( ) / NUMBER1 ) ;
 int yPos = ( int ) ( ( getHeight ( ) / NUMBER1 ) - ( ( mPaint . descent ( ) + mPaint . ascent ( ) ) / NUMBER1 ) ) ;
 canvas . drawText ( STRING0 + mInitial , xPos , yPos , mPaint ) ;

Make AvatarView compatible with layout editor preview


<nb> public class StringLiteralLexer extends LexerBase {
 SINGLE
 SINGLE
 if ( myState == AFTER_FIRST_QUOTE && myBuffer . charAt ( i ) == myQuoteChar ) {
 - myState = AFTER_LAST_QUOTE ;
 + if ( i + NUMBER0 == myBufferEnd ) myState = AFTER_LAST_QUOTE ;
 return i + NUMBER0 ;
 }
 i ++ ;

avoid StringLiteralLexer to skip content after quote if the quote is not the last one


<nb> public class FilteredRecyclerView extends RelativeLayout {
 }
 }

 - public RecyclerView getInternalRecyclerView ( ) {
 - return mRecyclerView ;
 - }
 -
 public void hideToolbar ( ) {
 mAppBarLayout . setExpanded ( false , true ) ;
 }
 <nb> public class ReaderPostListFragment extends Fragment
 if ( mWasPaused ) {
 AppLog . d ( T . READER , STRING0 ) ;
 mWasPaused = false ;
 - if ( getPostListType ( ) . equals ( ReaderPostListType . TAG_FOLLOWED ) ) {
 + if ( getPostListType ( ) == ReaderPostListType . TAG_FOLLOWED ) {
 resumeFollowedTag ( ) ;
 } else {
 refreshPosts ( ) ;
 }
 +
 + SINGLE
 + SINGLE
 + if ( getPostListType ( ) == ReaderPostListType . SEARCH_RESULTS ) {
 + mRecyclerView . showToolbar ( ) ;
 + }
 }
 }

Make sure toolbar showing search keyword is showing when returning to list view


<nb>
 COMMENT
 package NAMESPACE ;

 + import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 <nb> public class ExternalSystemStartupActivity implements StartupActivity {

 @ override
 public void runActivity ( @ notnull final Project project ) {
 + if ( ApplicationManager . getApplication ( ) . isUnitTestMode ( ) ) {
 + return ;
 + }
 Runnable task = new Runnable ( ) {
 @ suppresswarnings ( STRING0 )
 @ override

don t execute startup activities at unit test mode


<nb> import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;

 + @ suppresswarnings ( { STRING0 } )
 public class FileUtil {
 private static final Logger LOG = Logger . getInstance ( STRING1 ) ;
 private static final byte [ ] BUFFER = new byte [ NUMBER0 * NUMBER1 ] ;

 - private FileUtil ( ) {
 - }
 -
 public static String getRelativePath ( File base , File file ) {
 if ( base == null || file == null ) return null ;


<nb> import NAMESPACE ;
 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 NAMESPACE ;
 import NAMESPACE ;
 <nb> public class ConfigureProviderManager {

 SINGLE
 pm . addExtensionProvider ( STRING0 , STRING1 , new AttentionExtension . Provider ( ) ) ;
 +
 + SINGLE
 + pm . addExtensionProvider ( STRING2 , STRING3 , new Forwarded . Provider ( ) ) ;
 +
 + SINGLE
 + pm . addExtensionProvider ( STRING4 , STRING5 , new Carbon . Provider ( ) ) ;
 + pm . addExtensionProvider ( STRING6 , STRING5 , new Carbon . Provider ( ) ) ;
 +
 + SINGLE
 + pm . addIQProvider ( STRING7 , STRING8 , new PingProvider ( ) ) ;
 }
 }

Updated ConfigureProviderManager to support lastest smack development


<nb> public class NettyAsyncHttpProvider extends IdleStateHandler implements AsyncHtt
 if ( config . getMaxTotalConnections ( ) != - NUMBER0 ) {
 maxConnections . decrementAndGet ( ) ;
 }
 +
 + if ( log . isDebugEnabled ( ) ) {
 + log . debug ( String . format ( currentThread ( ) + STRING0 , future ) ) ;
 + log . debug ( t ) ;
 + }
 +
 future . abort ( t ) ;
 }

Improve logging when a Future gets aborded


<nb> public class NativeServices extends DefaultServiceRegistry implements ServiceReg
 COMMENT
 COMMENT
 COMMENT
 - public static void initialize ( File userHomeDir ) {
 + public static synchronized void initialize ( File userHomeDir ) {
 File nativeDir = new File ( userHomeDir , STRING0 ) ;
 if ( useNativePlatform ) {
 try {
 <nb> public class NativeServices extends DefaultServiceRegistry implements ServiceReg
 initialized = true ;
 }

 - public static NativeServices getInstance ( ) {
 + public static synchronized NativeServices getInstance ( ) {
 if ( ! initialized ) {
 SINGLE
 SINGLE


<nb> public final class Jid {
 return resourcepart . isEmpty ( ) ? this : fromParts ( localpart , domainpart , STRING0 ) ;
 } catch ( final InvalidJidException e ) {
 SINGLE
 - return null ;
 + throw new AssertionError ( STRING1 + this . toString ( ) + STRING2 ) ;
 }
 }

 <nb> public final class Jid {
 return resourcepart . isEmpty ( ) && localpart . isEmpty ( ) ? this : fromString ( getDomainpart ( ) ) ;
 } catch ( final InvalidJidException e ) {
 SINGLE
 - return null ;
 + throw new AssertionError ( STRING1 + this . toString ( ) + STRING2 ) ;
 }
 }

Improve InvalidJidException handling in Jid class


<nb> public final class Indexer {
 getopt . reset ( ) ;
 while ( ( cmd = getopt . getOpt ( ) ) != - NUMBER0 ) {
 switch ( cmd ) {
 - case STRING0 :
 - createDict = true ;
 - runIndex = false ;
 - break ;
 -
 case STRING1 :
 cfg . setVerbose ( false ) ;
 OpenGrokLogger . setOGConsoleLogLevel ( Level . WARNING ) ;


<nb> public class KeyboardUtil {

 SINGLE
 final View actionBarOverlayLayout = ( View ) contentView . getParent ( ) ;
 - final int actionBarOverlayLayoutHeight = actionBarOverlayLayout . getHeight ( ) ;
 + SINGLE
 + SINGLE
 + SINGLE
 + SINGLE
 + final int actionBarOverlayLayoutHeight = actionBarOverlayLayout . getHeight ( ) -
 + actionBarOverlayLayout . getPaddingTop ( ) ;

 if ( isFullScreen ) {
 if ( actionBarOverlayLayoutHeight - displayHeight == this . statusBarHeight ) {
 <nb> public class KeyboardUtil {
 } else {

 final int phoneDisplayHeight = contentView . getResources ( ) . getDisplayMetrics ( ) . heightPixels ;
 - if ( phoneDisplayHeight == actionBarOverlayLayoutHeight &&
 - actionBarOverlayLayout . getPaddingTop ( ) == NUMBER0 ) {
 + if ( phoneDisplayHeight == actionBarOverlayLayoutHeight ) {
 SINGLE
 SINGLE
 Log . w ( TAG , String . format ( STRING0 +

cover the case of the page is extends Activity or FragmentActivity not AppCompatActivity


<nb> public class VoldemortBuildAndPushJob extends AbstractJob {
 if ( ! build ) {
 buildOutputDir = dataDirs . get ( index ) ;
 }
 + SINGLE
 + SINGLE
 + if ( buildOutputDir == null ) {
 + continue ;
 + }
 runPushStore ( props , url , buildOutputDir ) ;
 informedResults . add ( this . informedExecutor . submit ( new InformedClient ( this . props ,
 STRING0 ,
 <nb> public class VoldemortBuildAndPushJob extends AbstractJob {
 }
 }
 }
 - if ( build && push && ! props . getBoolean ( STRING1 , false ) ) {
 + if ( build && push && buildOutputDir != null && ! props . getBoolean ( STRING1 , false ) ) {
 JobConf jobConf = new JobConf ( ) ;
 if ( props . containsKey ( STRING2 ) ) {
 jobConf . set ( STRING2 , props . getString ( STRING2 ) ) ;

Add null checks to make sure push doesn t get a null dir


<nb> public class RomanianTagger extends BaseTagger {

 @ override
 public final String getFileName ( ) {
 - return DEFAULT_BINARY_DICT ;
 + return binaryDictPath ;
 }

 @ override

getFileName should return the provided filename instead of a constant one


<nb> public class ScoSocket {
 COMMENT
 COMMENT
 public synchronized boolean connect ( String address ) {
 - if ( VDBG ) log ( STRING0 + this ) ;
 + if ( DBG ) log ( STRING0 + this ) ;
 if ( mState != STATE_READY ) {
 if ( DBG ) log ( STRING1 ) ;
 return false ;

Add one line of logging when SCO SOCKET connect starts


<nb> public class Editor {
 mSuggestionsPopupWindow . onParentLostFocus ( ) ;
 }

 - SINGLE
 - mTextView . onEndBatchEdit ( ) ;
 + SINGLE
 + ensureEndedBatchEdit ( ) ;
 }
 }

Ensure batch edit mode is ended on window focus loss


<nb> public class MappingUtil {
 continue ;
 }
 if ( cacheEntry . startOffset > offset ) {
 - if ( start == end ) {
 - return start - NUMBER0 ;
 - }
 end = i - NUMBER0 ;
 continue ;
 }


<nb> final class Primes {
 return sieve ( Stream . gen ( NUMBER0 ) ) ;
 }

 - SINGLE
 + SINGLE
 private static Stream < Integer > sieve ( Stream < Integer > numbers ) {
 return new Stream . Cons < > (
 numbers . head ( ) ,


<nb> public class XmppConnectionService extends Service {
 for ( Conversation conversation : getConversations ( ) ) {
 if ( conversation . getAccount ( ) == account ) {
 for ( Message message : conversation . getMessages ( ) ) {
 - if ( message . getStatus ( ) == Message . STATUS_UNSEND ) {
 + if ( message . getType ( ) != Message . TYPE_IMAGE
 + && message . getStatus ( ) == Message . STATUS_UNSEND ) {
 markMessage ( message , Message . STATUS_WAITING ) ;
 }
 }

don t reset images from sending to waiting


<nb> public class InputFileUtilsTest {

 static void write ( String content , File file ) throws IOException {
 file . getParentFile ( ) . mkdirs ( ) ;
 - Files . write ( STRING0 , file , Charsets . UTF_8 ) ;
 + Files . write ( content , file , Charsets . UTF_8 ) ;
 }

 static String read ( InputStream input ) throws IOException {


<nb> public class StackScrollAlgorithm {
 mTopStackIndentationFunctor = new PiecewiseLinearIndentationFunctor (
 MAX_ITEMS_IN_TOP_STACK ,
 mTopStackPeekSize ,
 - mTopStackTotalSize ,
 + mTopStackTotalSize - mTopStackPeekSize ,
 FLOAT0 ) ;
 mBottomStackIndentationFunctor = new PiecewiseLinearIndentationFunctor (
 MAX_ITEMS_IN_BOTTOM_STACK ,

Corrected top stack logic of notifications again


<nb> public class FieldTypeDatabase {
 }

 public void load ( ) {
 - L . info ( STRING0 ) ;
 + L . fine ( STRING0 ) ;

 SINGLE
 InputStream is = null ;
 <nb> public class FieldTypeDatabase {
 }

 public void save ( ) {
 - L . info ( STRING1 ) ;
 + L . fine ( STRING1 ) ;

 try (
 OutputStream os = Files . newOutputStream ( dbFile , WRITE , CREATE , TRUNCATE_EXISTING )

Reduced log level for loading saving logs


<nb> final public class AndrolibResources {
 }
 value = value . replace ( STRING0 , STRING1 ) ;
 value = value . replace ( STRING2 , STRING3 ) ;
 - value = value . replace ( STRING4 , STRING5 ) ;
 + value = value . replace ( STRING4 , STRING6 ) ;
 char c = value . charAt ( NUMBER0 ) ;
 if ( c == STRING7 || c == STRING8 || c == STRING9 ) {
 return STRING10 + value ;

don t insert new line char to XML output


<nb> public class InternalIndexShard extends AbstractIndexShardComponent implements I
 throw new IndexQueryParserMissingException ( queryParserName ) ;
 }
 }
 - Query query = queryParser . parse ( querySource ) . query ( ) ;
 + Query query = queryParser . parse ( querySource , querySourceOffset , querySourceLength ) . query ( ) ;
 SINGLE
 SINGLE
 SINGLE


<nb> public class PrincipalAttributeRegisteredServiceUsernameProvider implements Regi
 @ override
 public String resolveUsername ( final Principal principal , final Service service ) {
 String principalId = principal . getId ( ) ;
 + final Map < String , Object > originalPrincipalAttributes = principal . getAttributes ( ) ;
 final Map < String , Object > attributes = getPrincipalAttributes ( principal , service ) ;

 logger . debug ( STRING0 ,
 <nb> public class PrincipalAttributeRegisteredServiceUsernameProvider implements Regi

 if ( attributes . containsKey ( this . usernameAttribute ) ) {
 principalId = attributes . get ( this . usernameAttribute ) . toString ( ) ;
 + } else if ( originalPrincipalAttributes . containsKey ( this . usernameAttribute ) ) {
 + logger . warn ( STRING1
 + + STRING2
 + + STRING3
 + + STRING4 ,
 + this . usernameAttribute , service , this . usernameAttribute ) ;
 + principalId = originalPrincipalAttributes . get ( this . usernameAttribute ) . toString ( ) ;
 } else {
 logger . warn ( STRING5
 + STRING6

Allow the service username attribute to be retrieved as a principal attribute


<nb> import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 - import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 <nb> public class BasicErrorControllerSpecialIntegrationTests {
 }

 @ configuration
 - SINGLE
 - @ enableautoconfiguration ( exclude = ServerPropertiesAutoConfiguration . class )
 + @ enableautoconfiguration
 protected static class ParentConfiguration {

 }
 <nb> package NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 + import NAMESPACE ;
 + import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 <nb> import NAMESPACE ;
 COMMENT
 @ configuration
 @ enableconfigurationproperties
 + @ conditionalonwebapplication
 public class ServerPropertiesAutoConfiguration implements ApplicationContextAware ,
 EmbeddedServletContainerCustomizer {

 private ApplicationContext applicationContext ;

 @ bean ( name = STRING0 )
 - @ conditionalonmissingbean
 + @ conditionalonmissingbean ( search = SearchStrategy . CURRENT )
 public ServerProperties serverProperties ( ) {
 return new ServerProperties ( ) ;
 }

Prevent failure of web app with parent context


<nb> public class ONetworkProtocolBinary extends OBinaryNetworkProtocolAbstract {
 if ( connection != null ) {
 if ( ! Boolean . TRUE . equals ( tokenBased ) ) {
 if ( connection . database != null )
 - if ( ! connection . database . isClosed ( ) )
 + if ( ! connection . database . isClosed ( ) && connection . database . getLocalCache ( ) != null )
 connection . database . getLocalCache ( ) . clear ( ) ;
 } else {
 if ( connection . database != null && ! connection . database . isClosed ( ) )

fix null pointer on server response send end


<nb> public abstract class PullToRefreshBase < T extends View > extends LinearLayout {
 COMMENT
 COMMENT
 COMMENT
 - public void setDisableScrollingWhileRefreshing ( boolean disableScrollingWhileRefreshing ) {
 + public final void setDisableScrollingWhileRefreshing ( boolean disableScrollingWhileRefreshing ) {
 this . disableScrollingWhileRefreshing = disableScrollingWhileRefreshing ;
 }

 <nb> public abstract class PullToRefreshBase < T extends View > extends LinearLayout {
 }
 }

 - public void setRefreshing ( ) {
 + public final void setRefreshing ( ) {
 this . setRefreshing ( true ) ;
 }

 <nb> public abstract class PullToRefreshBase < T extends View > extends LinearLayout {
 COMMENT
 COMMENT
 COMMENT
 - public void setRefreshing ( boolean doScroll ) {
 + public final void setRefreshing ( boolean doScroll ) {
 if ( state == REFRESHING )
 return ;

Set the rest of the public methods to final


<nb> public abstract class AbstractDynamicMethodInvocation implements

 private String methodName = null ;

 - public AbstractDynamicMethodInvocation ( ) {
 + public AbstractDynamicMethodInvocation ( String methodName ) {
 super ( ) ;
 + this . methodName = methodName ;
 }

 public void setMethodName ( String methodName ) {
 <nb> public abstract class AbstractDynamicMethodInvocation implements
 public String getMethodName ( ) {
 return this . methodName ;
 }
 -
 +
 + public boolean isMethodMatch ( String methodName ) {
 + return getMethodName ( ) . equals ( methodName ) ;
 + }
 +
 public abstract Object invoke ( Object target , Object [ ] arguments ) ;
 }
 <nb> package NAMESPACE ;
 public interface DynamicMethodInvocation {

 COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + public boolean isMethodMatch ( String methodName ) ;
 + COMMENT
 COMMENT
 COMMENT
 COMMENT

Added a isMethodMethod method to be consistent with StaticMethodInvocation interface


<nb> public class MessageView extends K9Activity implements OnClickListener
 {
 mHandler . networkError ( ) ;
 }
 - if ( ! MessageView . this . mMessage . isSet ( Flag . X_DOWNLOADED_PARTIAL ) )
 + if ( ( MessageView . this . mMessage == null ) ||
 + ! MessageView . this . mMessage . isSet ( Flag . X_DOWNLOADED_PARTIAL ) )
 {
 mMessageContentView . loadUrl ( STRING0 ) ;
 }

Fix market reported NullPointerException


<nb> public interface GlobalOptions {
 String USE_MEMORY_TEMP_CACHE_OPTION = STRING0 ;
 String USE_EXTERNAL_JAVAC_OPTION = STRING1 ;
 String HOSTNAME_OPTION = STRING2 ;
 - String PING_INTERVAL_MS_OPTION = STRING3 ;
 String GENERATE_CLASSPATH_INDEX_OPTION = STRING4 ;
 - String MAX_SIMULTANEOUS_BUILDS_OPTION = STRING5 ;
 String COMPILE_PARALLEL_OPTION = STRING6 ;
 String COMPILE_PARALLEL_MAX_THREADS_OPTION = STRING7 ;
 }


<nb> public class SpringExpressionManager extends ExpressionManager {

 if ( beans != null ) {
 SINGLE
 - compositeElResolver . add ( new ReadonlyMapELResolver ( beans ) ) ;
 + compositeElResolver . add ( new ReadOnlyMapELResolver ( beans ) ) ;
 } else {
 SINGLE
 compositeElResolver . add ( new ApplicationContextElResolver ( applicationContext ) ) ;


<nb>
 COMMENT
 package NAMESPACE ;

 - import NAMESPACE ;
 -
 - import NAMESPACE ;
 - import NAMESPACE ;
 import NAMESPACE ;
 - import NAMESPACE ;
 import NAMESPACE ;
 - import NAMESPACE ;
 import NAMESPACE ;

 COMMENT
 <nb> public final class OperatorAll < T > implements Operator < Boolean , T > {

 @ override
 public Subscriber < ? super T > call ( final Subscriber < ? super Boolean > child ) {
 - Subscriber s = new Subscriber < T > ( ) {
 + return new Subscriber < T > ( child ) {
 boolean done ;
 +
 @ override
 public void onNext ( T t ) {
 boolean result = predicate . call ( t ) ;
 <nb> public final class OperatorAll < T > implements Operator < Boolean , T > {
 }
 }
 } ;
 - child . add ( s ) ;
 - return s ;
 }
 }


<nb> public interface MixinModContainer extends ModContainer {
 ModMetadata meta = getMetadata ( ) ;
 if ( meta != null ) {
 String path = ( ( IMixinModMetadata ) meta ) . getAssetDirectory ( ) ;
 - return ! path . isEmpty ( ) ? Optional . of ( Paths . get ( path ) ) : Optional . empty ( ) ;
 + return path != null && ! path . isEmpty ( ) ? Optional . of ( Paths . get ( path ) ) : Optional . empty ( ) ;
 }
 return Optional . empty ( ) ;
 }


<nb> public abstract class XBreakpointType < B extends XBreakpoint < P > , P extends XBreak
 }

 @ nullable
 + public XBreakpointCustomPropertiesPanel < B > createCustomPropertiesPanel ( @ notnull Project project ) {
 + return null ;
 + }
 +
 + @ nullable
 + @ deprecated
 public XBreakpointCustomPropertiesPanel < B > createCustomPropertiesPanel ( ) {
 return null ;
 }
 <nb> public class XLightBreakpointPropertiesPanel < B extends XBreakpointBase < ? , ? , ? > > i
 }
 }

 - XBreakpointCustomPropertiesPanel < B > customPropertiesPanel = breakpointType . createCustomPropertiesPanel ( ) ;
 + XBreakpointCustomPropertiesPanel < B > customPropertiesPanel = breakpointType . createCustomPropertiesPanel ( project ) ;
 + if ( customPropertiesPanel == null ) customPropertiesPanel = breakpointType . createCustomPropertiesPanel ( ) ;
 if ( customPropertiesPanel != null ) {
 myCustomPropertiesPanelWrapper . add ( customPropertiesPanel . getComponent ( ) , BorderLayout . CENTER ) ;
 myCustomPanels . add ( customPropertiesPanel ) ;

Introduced XBreakpointType createCustomPropertiesPanel Project method old variant deprecated


<nb> public class CheckinActivity extends BaseActivity implements LoaderCallbacks < Cur
 mCursor . getString ( CheckinQuery . AIRSDAYOFWEEK ) , mContext ) ;
 viewHolder . airsTime . setText ( values [ NUMBER0 ] + STRING0 + values [ NUMBER1 ] ) ;

 - SINGLE
 - SINGLE
 + SINGLE
 + SINGLE
 final String path = mCursor . getString ( CheckinQuery . POSTER ) ;
 - SINGLE
 - SINGLE
 Utils . setPosterBitmap ( viewHolder . poster , path , false , null ) ;
 -
 SINGLE
 viewHolder . poster . setTag ( null ) ;
 - SINGLE
 - SINGLE
 - SINGLE
 - SINGLE

 return convertView ;
 }


<nb> public class OperationSetBasicTelephonyJabberImpl

 if ( error != null )
 {
 + message += STRING0 + error . getCode ( )
 + + STRING1 + error . getMessage ( ) ;
 logger . error ( STRING2 + error . getCode ( )
 + STRING1 + error . getMessage ( ) ) ;
 -
 - if ( error . getMessage ( ) != null )
 - message = error . getMessage ( ) ;
 }

 if ( callPeer != null )

Provides error code and message to the GUI when a XMPP call failed


<nb> public class IrcStack

 COMMENT
 COMMENT
 + COMMENT
 + COMMENT
 COMMENT
 private IRCApi irc ;

Add marker for code improvement w r t IRCApi instance