diff:
<nb> import NAMESPACE ;
 COMMENT
 COMMENT
 COMMENT
 - public class ServerBootstrap extends AbstractBootstrap < ServerBootstrap > {
 + public final class ServerBootstrap extends AbstractBootstrap < ServerBootstrap > {

 private static final InternalLogger logger = InternalLoggerFactory . getInstance ( ServerBootstrap . class ) ;

msg_token: Make ServerBootstrap final


diff:
<nb> public class CommentDetailFragment extends Fragment implements NotificationFragm

 final TextView txtPostTitle = ( TextView ) getView ( ) . findViewById ( R . id . text_post_title ) ;
 boolean postExists = ReaderPostTable . postExists ( blogId , postId ) ;
 +
 + SINGLE
 + SINGLE
 boolean isDotComOrJetpack = WordPress . wpDB . isRemoteBlogIdDotComOrJetpack ( mRemoteBlogId ) ;
 + boolean canRequestPost = isDotComOrJetpack && WordPress . hasValidWPComCredentials ( getActivity ( ) ) ;

 final String title ;
 final boolean hasTitle ;
 <nb> public class CommentDetailFragment extends Fragment implements NotificationFragm
 hasTitle = false ;
 }
 if ( hasTitle ) {
 - setPostTitle ( txtPostTitle , title , isDotComOrJetpack ) ;
 + setPostTitle ( txtPostTitle , title , canRequestPost ) ;
 } else {
 txtPostTitle . setText ( postExists ? R . string . untitled : R . string . loading ) ;
 }

 SINGLE
 SINGLE
 - if ( isDotComOrJetpack ) {
 + if ( canRequestPost ) {
 SINGLE
 SINGLE
 if ( ! postExists ) {

msg_token: Comment detail now only requests the post associated with the comment if valid


diff:
<nb> public final class SocksCmdResponse extends SocksResponse {
 }
 host = IDN . toASCII ( host ) ;
 }
 - if ( port <= NUMBER0 && port >= NUMBER1 ) {
 - throw new IllegalArgumentException ( port + STRING0 ) ;
 + if ( port < NUMBER0 || port > NUMBER2 ) {
 + throw new IllegalArgumentException ( port + STRING1 ) ;
 }
 this . cmdStatus = cmdStatus ;
 this . addressType = addressType ;

msg_token: Correctly handle SocksCmdResponse


diff:
<nb> public class PDFRenderTargetBuilder implements RenderTargetBuilder {
 double scale = ( float ) ( ratioWidth < ratioHeight ? ratioWidth : ratioHeight ) ;
 double translateX = ( marginLeft + pageWidth / FLOAT0 ) / scale ;
 double translateY = ( marginBottom + pageHeight / FLOAT0 ) / scale ;
 - cb . transform ( AffineTransform . getTranslateInstance ( - centerX * scale , - centerY * scale ) ) ;
 + cb . transform ( AffineTransform . getTranslateInstance ( - centerX * scale , centerY * scale ) ) ;
 cb . transform ( AffineTransform . getScaleInstance ( scale , scale ) ) ;
 cb . transform ( AffineTransform . getTranslateInstance ( translateX , translateY ) ) ;

 <nb> public class PreviewControllerImpl implements PreviewController {
 bottomRightY = y ;
 }
 }
 +
 float marginWidth = ( bottomRightX - topLeftX ) * ( margin / NUMBER0 f ) ;
 float marginHeight = ( bottomRightY - topLeftY ) * ( margin / NUMBER0 f ) ;
 topLeftX -= marginWidth ;

msg_token: Fix PDF export transformation on y


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

 import NAMESPACE ;

msg_token: Fixed the CS error of camel cxf transport


diff:
<nb>
 package NAMESPACE ;

 - import NAMESPACE ;
 -
 - public final class IdAllocation implements Serializable
 + public final class IdAllocation
 {
 - private static final long serialVersionUID = NUMBER0 ;
 -
 private final long [ ] ids ;
 private final long highestIdInUse ;
 private final long defragCount ;
 <nb> public enum LockStatus
 {
 OK_LOCKED ,
 NOT_LOCKED ,
 - DEAD_LOCKED ,
 + DEAD_LOCKED
 + {
 + @ override
 + public boolean hasMessage ( )
 + {
 + return true ;
 + }
 + } ;
 +
 + public boolean hasMessage ( )
 + {
 + return false ;
 + }
 }

msg_token: Added a hasMessage to LockStatus


diff:
<nb>
 package NAMESPACE ;

 import NAMESPACE ;
 + import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 <nb> public abstract class AbstractSimpleTranslogTests extends ElasticsearchTestCase
 }

 @ test
 + @ lucenetestcase.awaitsfix ( bugUrl = STRING0 )
 public void testTranslogChecksums ( ) throws Exception {
 List < Translog . Location > locations = newArrayList ( ) ;

msg_token: TEST add AwaitsFix for testTranslogChecksums since it may cause OOME


diff:
<nb> public class AnalyzeStacktraceUtil {
 public static void printStacktrace ( final ConsoleView consoleView , final String unscrambledTrace ) {
 consoleView . clear ( ) ;
 consoleView . print ( unscrambledTrace + STRING0 , ConsoleViewContentType . ERROR_OUTPUT ) ;
 - if ( consoleView instanceof ConsoleViewImpl ) {
 - ( ( ConsoleViewImpl ) consoleView ) . foldImmediately ( ) ;
 - }
 consoleView . scrollTo ( NUMBER0 ) ;
 }

msg_token: do not fold immediately as console now works async


diff:
<nb> public class NNModel extends Model {
 else err . valid_mse = validErr ;
 }

 + SINGLE
 + if ( errors . length > NUMBER0 ) {
 + if ( errors [ errors . length - NUMBER0 ] . trainAUC != null ) errors [ errors . length - NUMBER0 ] . trainAUC . thresholds = null ;
 + if ( errors [ errors . length - NUMBER0 ] . validAUC != null ) errors [ errors . length - NUMBER0 ] . validAUC . thresholds = null ;
 + }
 +
 SINGLE
 if ( err . train_confusion_matrix . cm != null
 && err . train_confusion_matrix . cm . length >= model_info ( ) . get_params ( ) . max_confusion_matrix_size ) {

msg_token: Only keep that latest AUC thresholds in the NN output JSON to keep it small


diff:
<nb> public final class Stopwatch {
 COMMENT
 COMMENT
 COMMENT
 - COMMENT
 + COMMENT
 + COMMENT
 COMMENT
 @ deprecated
 public Stopwatch ( ) {
 <nb> public final class Stopwatch {
 COMMENT
 COMMENT
 COMMENT
 - COMMENT
 + COMMENT
 + COMMENT
 COMMENT
 @ deprecated
 public Stopwatch ( Ticker ticker ) {
 <nb> public final class Stopwatch {
 COMMENT
 COMMENT
 COMMENT
 - COMMENT
 + COMMENT
 + COMMENT
 COMMENT
 @ deprecated
 public Stopwatch ( ) {
 <nb> public final class Stopwatch {
 COMMENT
 COMMENT
 COMMENT
 - COMMENT
 + COMMENT
 + COMMENT
 COMMENT
 @ deprecated
 public Stopwatch ( Ticker ticker ) {

msg_token: Give removal dates for Stopwatch ctors


diff:
<nb> public class PlainModuleTemplatesFactory implements ProjectTemplatesFactory {
 @ override
 public ProjectTemplate [ ] createTemplates ( final String group , WizardContext context ) {
 if ( OTHER_GROUP . equals ( group ) ) {
 - return context . isCreatingNewProject ( ) ? new ProjectTemplate [ ] { new PlainModuleTemplate ( new EmptyModuleBuilder ( ) {
 + if ( ! context . isCreatingNewProject ( ) ) {
 + return ProjectTemplate . EMPTY_ARRAY ;
 + }
 + return new ProjectTemplate [ ] { new PlainModuleTemplate ( new EmptyModuleBuilder ( ) {
 @ override
 public String getPresentableName ( ) {
 return STRING0 ;
 <nb> public class PlainModuleTemplatesFactory implements ProjectTemplatesFactory {
 public String getDescription ( ) {
 return STRING1 ;
 }
 - } ) } : ProjectTemplate . EMPTY_ARRAY ;
 + } ) } ;
 }
 ModuleBuilder [ ] builders = context . getAllBuilders ( ) ;
 return ContainerUtil . mapNotNull ( builders , new NullableFunction < ModuleBuilder , ProjectTemplate > ( ) {

msg_token: remove empty project from templates list


diff:
<nb> public class MatcherTest {
 @ datapoint
 public static Matcher < ? > ANY_FAILURE = hasFailureContaining ( STRING0 ) ;

 - SINGLE
 -
 @ datapoint
 public static PrintableResult TWO_FAILURES_ONE_CHEESE = new PrintableResult (
 - Arrays . asList ( new Failure ( Description . EMPTY , new Error ( STRING0 ) ) ,
 - new Failure ( Description . EMPTY , new Error ( STRING1 ) ) ) ) ;
 + Arrays . asList ( failure ( STRING0 ) , failure ( STRING1 ) ) ) ;

 @ theory
 public < T > void differentMatchersHaveDifferentDescriptions (
 <nb> public class MatcherTest {
 assertThat ( matcher1 . toString ( ) , not ( matcher2 . toString ( ) ) ) ;
 }

 + private static Failure failure ( String string ) {
 + return new Failure ( Description . EMPTY , new Error ( string ) ) ;
 + }
 }

msg_token: Remove duplication in test logic


diff:
<nb> public class JSR356AsyncSupport extends Servlet30CometSupport {
 ServerContainer container = ( ServerContainer ) config . getServletContext ( ) . getAttribute ( ServerContainer . class . getName ( ) ) ;

 if ( container == null ) {
 - throw new IllegalStateException ( STRING0 ) ;
 + throw new IllegalStateException ( STRING1 ) ;
 }

 int pathLength = NUMBER0 ;

msg_token: Improve error message


diff:
<nb> class MyDraggableSwipeableItemAdapter
 }

 SINGLE
 - holder . setSwipeItemSlideAmount (
 + holder . setSwipeItemHorizontalSlideAmount (
 item . isPinned ( ) ? RecyclerViewSwipeManager . OUTSIDE_OF_THE_WINDOW_LEFT : NUMBER0 ) ;
 }

 <nb> class MyExpandableDraggableSwipeableItemAdapter
 }

 SINGLE
 - holder . setSwipeItemSlideAmount (
 + holder . setSwipeItemHorizontalSlideAmount (
 item . isPinned ( ) ? RecyclerViewSwipeManager . OUTSIDE_OF_THE_WINDOW_LEFT : NUMBER0 ) ;
 }

 <nb> class MyExpandableDraggableSwipeableItemAdapter
 }

 SINGLE
 - holder . setSwipeItemSlideAmount (
 + holder . setSwipeItemHorizontalSlideAmount (
 item . isPinned ( ) ? RecyclerViewSwipeManager . OUTSIDE_OF_THE_WINDOW_LEFT : NUMBER0 ) ;
 }

 <nb> class MyUnderSwipeableItemAdapter
 SINGLE
 holder . setMaxLeftSwipeAmount ( - FLOAT0 ) ;
 holder . setMaxRightSwipeAmount ( NUMBER0 ) ;
 - holder . setSwipeItemSlideAmount (
 + holder . setSwipeItemHorizontalSlideAmount (
 item . isPinned ( ) ? - FLOAT0 : NUMBER0 ) ;
 }

msg_token: Replace SwipableItemViewHolder setSwipeItemSlideAmount method with SwipeableItemViewHolder setSwipeItemHorizontalSlideAmount


diff:
<nb> public class SeriesGuideContract {
 String GENRES = STRING0 ;

 COMMENT
 - COMMENT
 + COMMENT
 + COMMENT
 COMMENT
 COMMENT
 COMMENT
 <nb> public class TimeTools {
 if ( releaseDateTime == null || releaseDateTime . length ( ) == NUMBER0 ) {
 return null ;
 }
 - DateTime dateTime = DATE_TIME_FORMATTER_UTC . parseDateTime ( releaseDateTime ) ;
 +
 + DateTime dateTime ;
 +
 + try {
 + dateTime = DATE_TIME_FORMATTER_UTC . parseDateTime ( releaseDateTime ) ;
 + } catch ( IllegalArgumentException ignored ) {
 + SINGLE
 + try {
 + SINGLE
 + dateTime = TVDB_DATE_FORMATTER . parseDateTime ( releaseDateTime ) ;
 + } catch ( IllegalArgumentException e ) {
 + return null ;
 + }
 + }
 +
 return new SimpleDateFormat ( STRING1 , Locale . getDefault ( ) ) . format ( dateTime . toDate ( ) ) ;
 }

msg_token: Support legacy show first release date strings


diff:
<nb> public abstract class AbstractPrologCommandPlayer implements CommandPlayer {
 private final int [ ] sortedVoiceVersions ;
 private AudioFocusHelper mAudioFocusHelper ;

 - private int streamType ;
 + protected int streamType ;

 protected AbstractPrologCommandPlayer ( Context ctx , OsmandSettings settings , String voiceProvider , String configFile , int [ ] sortedVoiceVersions )
 throws CommandPlayerException
 <nb> public class MediaCommandPlayerImpl extends AbstractPrologCommandPlayer implemen
 private MediaPlayer mediaPlayer ;
 SINGLE
 private List < String > filesToPlay = Collections . synchronizedList ( new ArrayList < String > ( ) ) ;
 - private int streamType ;

 public MediaCommandPlayerImpl ( Context ctx , OsmandSettings settings , String voiceProvider )

msg_token: Fix audio stream type


diff:
<nb> public class BuildToolsWebsitePanel extends BuildToolsPanel
 chkPreviewAfterBuilding_ . addStyleName ( RES . styles ( ) . previewWebsite ( ) ) ;
 add ( chkPreviewAfterBuilding_ ) ;

 - chkLivePreviewSite_ = checkBox ( STRING0 ) ;
 + chkLivePreviewSite_ = checkBox ( STRING1 ) ;
 chkLivePreviewSite_ . addStyleName ( RES . styles ( ) . previewWebsite ( ) ) ;
 add ( chkLivePreviewSite_ ) ;
 }
 <nb> public class RmdOutput implements RmdRenderStartedEvent . Handler ,
 if ( ! file . getParentPathString ( ) . equals ( websiteDir ) )
 reRenderPreview ( ) ;

 - SINGLE
 - else
 + SINGLE
 + else
 reRenderPreview ( file . getPath ( ) ) ;
 }

msg_token: tweak live preview comments label


diff:
<nb> public class CollapsingToolbarLayout extends FrameLayout {
 COMMENT
 COMMENT
 public void setCollapsedTitleGravity ( int gravity ) {
 - mCollapsingTextHelper . setExpandedTextGravity ( gravity ) ;
 + mCollapsingTextHelper . setCollapsedTextGravity ( gravity ) ;
 }

 COMMENT


diff:
<nb> import NAMESPACE ;
 public final class BluetoothAdapter {
 private static final String TAG = STRING0 ;
 private static final boolean DBG = true ;
 + private static final boolean VDBG = false ;

 COMMENT
 COMMENT
 <nb> public final class BluetoothAdapter {
 if ( mService != null )
 {
 int state = mService . getState ( ) ;
 - if ( DBG ) Log . d ( TAG , STRING1 + hashCode ( ) + STRING2 + state ) ;
 + if ( VDBG ) Log . d ( TAG , STRING1 + hashCode ( ) + STRING2 + state ) ;
 return state ;
 }
 SINGLE

msg_token: Turn off verbose debug message in BluetoothAdapter


diff:
<nb> public final class HiveWriteUtils
 return isWritableType ( listTypeInfo . getListElementTypeInfo ( ) ) ;
 case STRUCT :
 StructTypeInfo structTypeInfo = checkType ( typeInfo , StructTypeInfo . class , STRING0 ) ;
 - return structTypeInfo . getAllStructFieldTypeInfos ( ) . stream ( ) . allMatch ( HiveType : : isSupportedType ) ;
 + return structTypeInfo . getAllStructFieldTypeInfos ( ) . stream ( ) . allMatch ( HiveWriteUtils : : isWritableType ) ;
 }
 return false ;
 }

msg_token: Fix check for Hive writable structs


diff:
<nb> public abstract class AbstractJavaBuilder extends AbstractLibraryBuilder {
 COMMENT
 protected boolean debug = false ;

 - @ override
 - protected boolean keepFileDuringCleanup ( File file ) {
 - return false ;
 - }
 -
 COMMENT
 COMMENT
 COMMENT
 <nb> public abstract class AbstractLibraryBuilder extends CommonJavaLibraryProcessor
 COMMENT
 COMMENT
 COMMENT
 - COMMENT
 - COMMENT
 - COMMENT
 + COMMENT
 + COMMENT
 COMMENT
 COMMENT
 COMMENT
 <nb> public abstract class AbstractLibraryBuilder extends CommonJavaLibraryProcessor
 } else if ( ! removeEverything && keepClassFilesDuringCleanup ( ) &&
 file . getName ( ) . endsWith ( STRING0 ) ) {
 isEmpty = false ;
 - } else if ( ! removeEverything && keepFileDuringCleanup ( file ) ) {
 - isEmpty = false ;
 } else {
 file . delete ( ) ;
 }
 <nb> public abstract class AbstractLibraryBuilder extends CommonJavaLibraryProcessor
 return isEmpty ;
 }

 - protected abstract boolean keepFileDuringCleanup ( File file ) ;
 -
 COMMENT
 COMMENT
 COMMENT

msg_token: Remove the callback that allowed excluding files from deletion


diff:
<nb> public class TextPanel extends JLabel {
 myText = text ;
 }

 + public void setDisplayedMnemonic ( int key ) {
 + SINGLE
 + }
 +
 + public void setDisplayedMnemonicIndex ( int index ) throws IllegalArgumentException {
 + SINGLE
 + super . setDisplayedMnemonicIndex ( - NUMBER0 ) ;
 + }
 +
 public final Dimension getPreferredSize ( ) {
 int max = NUMBER1 ;
 for ( String possibleString : myPossibleStrings ) {

msg_token: ignore attempts to set mnemonics on status bar label


diff:
<nb> public abstract class ComponentManagerImpl extends UserDataHolderBase implements
 }

 public < T > T getComponent ( Class < T > interfaceClass ) {
 - assert ! myDisposed ;
 + assert ! myDisposed : STRING0 ;
 return getComponent ( interfaceClass , null ) ;
 }

msg_token: Added assertion message


diff:
<nb> public class ExactMatcher implements StreamRuleMatcher {

 @ override
 public boolean match ( Message msg , StreamRule rule ) {
 - String field = msg . getField ( rule . getField ( ) ) . toString ( ) ;
 + String field = ( String ) msg . getField ( rule . getField ( ) ) ;

 if ( field == null ) {
 return false ;
 <nb> public class RegexMatcher implements StreamRuleMatcher {

 @ override
 public boolean match ( Message msg , StreamRule rule ) {
 + if ( msg . getField ( rule . getField ( ) ) == null )
 + return false ;
 return Pattern . compile ( rule . getValue ( ) , Pattern . DOTALL ) . matcher ( msg . getField ( rule . getField ( ) ) . toString ( ) ) . find ( ) ;
 }

msg_token: Preventing NullPointerExceptions in Matchers


diff:
<nb> public class DominantColorCalculator {
 COMMENT
 private int findPrimaryTextColor ( final ColorNode primary ) {
 SINGLE
 - for ( ColorNode color : mPalette ) {
 + for ( ColorNode color : mWeightedPalette ) {
 if ( ColorUtils . calculateContrast ( color , primary ) >= PRIMARY_TEXT_MIN_CONTRAST ) {
 return color . getRgb ( ) ;
 }

msg_token: Use weighted palette to calculate text color


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

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

 import NAMESPACE ;

msg_token: Added license header


diff:
<nb> public class DiffToChangeLog {
 STRING0 +
 STRING1 ;

 + SINGLE
 + sql += STRING2 +
 + STRING3 +
 + STRING4 ;
 +
 SINGLE
 sql += STRING5 +
 STRING6 +

msg_token: Improve sqlserver dependency query


diff:
<nb> public class Wallet extends BaseTaggableObject implements Serializable , BlockCha
 }
 if ( dead . size ( ) > NUMBER0 ) {
 builder . append ( STRING0 ) ;
 - toStringHelper ( builder , dead , chain , Transaction . SORT_TX_BY_HEIGHT ) ;
 + toStringHelper ( builder , dead , chain , Transaction . SORT_TX_BY_UPDATE_TIME ) ;
 }
 }
 if ( includeExtensions && extensions . size ( ) > NUMBER0 ) {

msg_token: Dead transaction does not contain confidence depth and should not fail when sorting


diff:
<nb> public class OsmandSettings {
 }

 + public final OsmandPreference < ApplicationMode > PREV_APPLICATION_MODE = new EnumIntPreference < ApplicationMode > (
 + STRING0 , ApplicationMode . DEFAULT , true , false , ApplicationMode . values ( ) ) ;
 +
 SINGLE
 SINGLE
 public final OsmandPreference < MetricsConstants > METRIC_SYSTEM = new EnumIntPreference < MetricsConstants > (
 <nb> public class MapActivityActions implements DialogProvider {
 }
 ApplicationMode mode = getAppMode ( buttons , settings ) ;
 SINGLE
 + settings . PREV_APPLICATION_MODE . set ( settings . APPLICATION_MODE . get ( ) ) ;
 boolean changed = settings . APPLICATION_MODE . set ( mode ) ;
 if ( changed ) {
 mapActivity . updateApplicationModeSettings ( ) ;

msg_token: Save previously selected application mode


diff:
<nb> public class ShadowResources {
 public Configuration getConfiguration ( ) {
 Configuration configuration = new Configuration ( ) ;
 configuration . setToDefaults ( ) ;
 + if ( configuration . locale == null ) {
 + configuration . locale = Locale . getDefault ( ) ;
 + }
 return configuration ;
 }

 <nb>
 package NAMESPACE ;

 import NAMESPACE ;
 + import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 <nb> public class ResourcesTest {

 @ test
 public void testConfiguration ( ) {
 - assertThat ( new Activity ( ) . getResources ( ) . getConfiguration ( ) , notNullValue ( ) ) ;
 + Configuration configuration = new Activity ( ) . getResources ( ) . getConfiguration ( ) ;
 + assertThat ( configuration , notNullValue ( ) ) ;
 + assertThat ( configuration . locale , notNullValue ( ) ) ;
 }

 @ test

msg_token: Added default locale when retrieving configuration


diff:
<nb> public class DSLContexts {
 try ( Connection conn = dataSource . getConnection ( ) ) {
 dialect = dialect ( conn ) ;
 }
 - return DSL . using ( dataSource , dialect , new Settings ( )
 - . withRenderSchema ( false )
 - . withRenderNameStyle ( RenderNameStyle . AS_IS ) ) ;
 + return DSL . using ( dataSource , dialect ,
 + new Settings ( )
 + . withRenderSchema ( false )
 + . withRenderNameStyle ( RenderNameStyle . AS_IS ) ) ;
 }
 }

msg_token: Keep formatting closer to original


diff:
<nb> public class DemoActivity extends ActionBarActivity {
 } ) ;

 TextView t = ( TextView ) findViewById ( R . id . main ) ;
 + t . setOnClickListener ( new OnClickListener ( ) {
 + @ override
 + public void onClick ( View v ) {
 + mLayout . collapsePanel ( ) ;
 + }
 + } ) ;
 +
 t = ( TextView ) findViewById ( R . id . name ) ;
 t . setText ( Html . fromHtml ( getString ( R . string . hello ) ) ) ;
 Button f = ( Button ) findViewById ( R . id . follow ) ;

msg_token: Updated demo to collapse the main when clicking on the main layout


diff:
<nb> public class I18nInspection extends BaseLocalInspectionTool {
 final Project project = manager . getProject ( ) ;
 final GlobalSearchScope scope = GlobalSearchScope . allScope ( project ) ;
 final PsiClass throwable = manager . findClass ( STRING0 , scope ) ;
 - return aClass . isInheritor ( throwable , true ) ;
 + return throwable != null && aClass . isInheritor ( throwable , true ) ;
 }

 private static boolean isArgOfSpecifiedExceptionConstructor ( PsiExpression expression , String [ ] specifiedExceptions ) {

msg_token: avoid exception on misconfigured JDK


diff:
<nb> public class OptimizeImportsRefactoringHelper implements RefactoringHelper < Set < P
 public Set < PsiJavaFile > prepareOperation ( final UsageInfo [ ] usages ) {
 Set < PsiJavaFile > javaFiles = new HashSet < PsiJavaFile > ( ) ;
 for ( UsageInfo usage : usages ) {
 + if ( usage . isNonCodeUsage ) continue ;
 final PsiElement element = usage . getElement ( ) ;
 if ( element != null ) {
 final PsiFile file = element . getContainingFile ( ) ;
 <nb> public class GroovyImportOptimizerRefactoringHelper implements RefactoringHelper
 public Set < GroovyFile > prepareOperation ( UsageInfo [ ] usages ) {
 Set < GroovyFile > files = new HashSet < GroovyFile > ( ) ;
 for ( UsageInfo usage : usages ) {
 + if ( usage . isNonCodeUsage ) continue ;
 final PsiElement element = usage . getElement ( ) ;
 if ( element != null ) {
 final PsiFile file = element . getContainingFile ( ) ;

msg_token: skip non code usages when collecting files for optimize imports


diff:
<nb> public final class NetworkUtils {
 public static String getLocalIpAddress ( ) {
 try {
 InetAddress address = InetAddress . getLocalHost ( ) ;
 - LOG . debug ( STRING0 + address . toString ( ) + STRING1 + address . isLoopbackAddress ( ) + STRING1
 - + address . getHostAddress ( ) + STRING1 + address . getHostName ( ) ) ;
 + if ( LOG . isDebugEnabled ( ) ) {
 + LOG . debug ( STRING0 + address . toString ( ) + STRING1 + address . isLoopbackAddress ( ) + STRING1
 + + address . getHostAddress ( ) + STRING1 + address . getHostName ( ) ) ;
 + }
 if ( address . isLoopbackAddress ( ) ) {
 Enumeration < NetworkInterface > networkInterfaces = NetworkInterface . getNetworkInterfaces ( ) ;
 while ( networkInterfaces . hasMoreElements ( ) ) {

msg_token: avoid unnecessary toString and concatenation


diff:
<nb> public interface Config extends ConfigMergeable {
 @ deprecated Long getNanoseconds ( String path ) ;

 COMMENT
 - COMMENT
 - COMMENT
 - COMMENT
 - COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 COMMENT
 COMMENT
 - COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 COMMENT
 COMMENT
 COMMENT
 - COMMENT
 + COMMENT
 COMMENT
 COMMENT
 COMMENT
 <nb> public interface Config extends ConfigMergeable {
 COMMENT
 @ deprecated List < Long > getNanosecondsList ( String path ) ;

 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 + COMMENT
 List < Long > getDurationList ( String path , TimeUnit unit ) ;

 COMMENT
 <nb> public interface Config extends ConfigMergeable {
 COMMENT
 COMMENT
 COMMENT
 - COMMENT
 + COMMENT
 COMMENT
 COMMENT
 COMMENT

msg_token: add since to getDuration and minor doc tweaks


diff:
<nb> public class CTConnectionFactory implements KeyedPoolableObjectFactory < String , C

 TSocket socket ;
 - if ( ! cfg . sslTruststoreLocation . isEmpty ( ) ) {
 + if ( null != cfg . sslTruststoreLocation && ! cfg . sslTruststoreLocation . isEmpty ( ) ) {
 TSSLTransportFactory . TSSLTransportParameters params = new TSSLTransportFactory . TSSLTransportParameters ( ) { {
 setKeyStore ( cfg . sslTruststoreLocation , cfg . sslTruststorePassword ) ;
 } } ;

msg_token: Fix NPE in SSL trust store configuration


diff:
<nb> public class AsmClassGenerator extends ClassGenerator {
 }

 public void visitBlockStatement ( BlockStatement block ) {
 - onLineNumber ( block , STRING0 ) ;
 visitStatement ( block ) ;

 int mark = controller . getOperandStack ( ) . getStackLength ( ) ;

msg_token: Rogue line number for method declarations confuses IDE debuggers


diff:
<nb> public class IndexCheck implements RecordCheck < IndexEntry , ConsistencyReport . Ind
 public void checkChange ( IndexEntry oldRecord , IndexEntry newRecord , CheckerEngine < IndexEntry , ConsistencyReport
 . IndexConsistencyReport > engine , DiffRecordAccess records )
 {
 + check ( newRecord , engine , records ) ;
 }
 }
 <nb> public class LabelScanCheck implements RecordCheck < LabelScanDocument , Consistenc
 CheckerEngine < LabelScanDocument ,
 ConsistencyReport . LabelScanConsistencyReport > engine , DiffRecordAccess records )
 {
 - throw new UnsupportedOperationException ( ) ;
 + check ( newRecord , engine , records ) ;
 }
 }

msg_token: delegate incremental checking to full checking


diff:
<nb> public class CorePlugin implements Plugin {

 SINGLE
 extensions . add ( TendencyDecorator . class ) ;
 + extensions . add ( PastSnapshotFinderByDate . class ) ;
 extensions . add ( PastSnapshotFinderByDays . class ) ;
 + extensions . add ( PastSnapshotFinderByLastAnalysis . class ) ;
 extensions . add ( PastSnapshotFinderByVersion . class ) ;
 extensions . add ( PastMeasuresLoader . class ) ;
 extensions . add ( PastSnapshotFinder . class ) ;

msg_token: Add missing extensions to CorePlugin


diff:
<nb> public class SJK {
 SINGLE
 jarFileName = URLDecoder . decode ( packageURL . getFile ( ) , STRING0 ) ;
 jarFileName = jarFileName . substring ( NUMBER0 , jarFileName . indexOf ( STRING1 ) ) ;
 - System . out . println ( STRING2 + jarFileName ) ;
 jf = new JarFile ( jarFileName ) ;
 jarEntries = jf . entries ( ) ;
 while ( jarEntries . hasMoreElements ( ) ) {

msg_token: Removed forgotten System out


diff:
<nb> import NAMESPACE ;
 COMMENT
 COMMENT
 @ modelcontainer
 - @ table ( database = TestDatabase . class )
 + @ table ( database = TestDatabase . class , cachingEnabled = true )
 public class AIContainerForeign extends AutoIncrementContainer {

 <nb> public class SqlUtils {
 }

 if ( cacheable != null ) {
 + instanceAdapter . reloadRelationships ( cacheable , cursor ) ;
 entities . add ( cacheable ) ;
 } else {
 cacheable = instanceAdapter . newInstance ( ) ;
 <nb> public class SqlUtils {
 if ( model == null ) {
 model = modelAdapter . newInstance ( ) ;
 modelAdapter . loadFromCursor ( cursor , model ) ;
 + } else {
 + modelAdapter . reloadRelationships ( model , cursor ) ;
 }
 }
 }

msg_token: reloading relationships in the sql methods


diff:
<nb> public abstract class MediaRouteProviderService extends Service {
 if ( mControllers . indexOfKey ( controllerId ) < NUMBER0 ) {
 MediaRouteProvider . RouteController controller =
 mProvider . onCreateRouteController ( routeId ) ;
 - mControllers . put ( controllerId , controller ) ;
 - return true ;
 + if ( controller != null ) {
 + mControllers . put ( controllerId , controller ) ;
 + return true ;
 + }
 }
 return false ;
 }

msg_token: Fix NPE when provider does not supply a route controller


diff:
<nb> public class BytecodeHelper implements Constants {
 cv . visitInsn ( ICONST_5 ) ;
 break ;
 default :
 - if ( value > Byte . MIN_VALUE && value < Byte . MAX_VALUE ) {
 + if ( value >= Byte . MIN_VALUE && value <= Byte . MAX_VALUE ) {
 cv . visitIntInsn ( BIPUSH , value ) ;
 }
 - else if ( value > Short . MIN_VALUE && value < Short . MAX_VALUE ) {
 + else if ( value >= Short . MIN_VALUE && value <= Short . MAX_VALUE ) {
 cv . visitIntInsn ( SIPUSH , value ) ;
 }
 else {

msg_token: applied Robert Fuller s patch DOH


diff:
<nb> public class PsiReferenceExpressionImpl extends PsiReferenceExpressionBase imple
 LOG . error ( STRING0 ) ;
 return JavaResolveResult . EMPTY_ARRAY ;
 }
 + if ( ! isValid ( ) ) {
 + LOG . error ( STRING1 ) ;
 + return JavaResolveResult . EMPTY_ARRAY ;
 + }
 ResolveResult [ ] results = ResolveCache . getInstance ( getProject ( ) ) . resolveWithCaching ( this , OurGenericsResolver . INSTANCE , true , incompleteCode ) ;
 return results . length == NUMBER0 ? JavaResolveResult . EMPTY_ARRAY : ( JavaResolveResult [ ] ) results ;
 }

msg_token: don t resolve invalid references


diff:
<nb> public class BeaconManager {
 }

 COMMENT
 - COMMENT
 + COMMENT
 COMMENT
 COMMENT
 COMMENT
 - COMMENT
 + COMMENT
 COMMENT
 COMMENT
 COMMENT
 <nb> public class BeaconManager {

 COMMENT
 COMMENT
 - COMMENT
 + COMMENT
 COMMENT
 COMMENT
 COMMENT
 <nb> public class BeaconManager {
 COMMENT
 COMMENT
 COMMENT
 - COMMENT
 + COMMENT
 COMMENT
 COMMENT
 COMMENT
 <nb> public class BeaconParser {
 return null ;
 }
 else {
 - BeaconManager . logDebug ( TAG , STRING0 + String . format ( STRING1 , getMatchingBeaconTypeCode ( ) ) + STRING2 ) ;
 + BeaconManager . logDebug ( TAG , STRING3 + String . format ( STRING1 , getMatchingBeaconTypeCode ( ) ) + STRING2 ) ;
 }

 ArrayList < Identifier > identifiers = new ArrayList < Identifier > ( ) ;

msg_token: Fix typos in docs and log messages


diff:
<nb> public interface SourceSet {
 String getCompileTaskName ( String language ) ;

 COMMENT
 - COMMENT
 + COMMENT
 COMMENT
 COMMENT
 COMMENT

msg_token: Updated javadoc information


diff:
<nb> package NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;
 - import NAMESPACE ;
 import NAMESPACE ;
 import NAMESPACE ;

msg_token: Remove unneeded import


diff:
<nb> public class StorageProxy implements StorageProxyMBean
 SINGLE
 if ( destination . equals ( FBUtilities . getLocalAddress ( ) ) )
 {
 - insertLocalMessage ( rm , responseHandler ) ;
 + insertLocal ( rm , responseHandler ) ;
 }
 else
 {
 <nb> public class StorageProxy implements StorageProxyMBean
 message . setHeader ( RowMutation . HINT , bos . toByteArray ( ) ) ;
 }

 - private static void insertLocalMessage ( final RowMutation rm , final IWriteResponseHandler responseHandler )
 + private static void insertLocal ( final RowMutation rm , final IWriteResponseHandler responseHandler )
 {
 if ( logger . isDebugEnabled ( ) )
 logger . debug ( STRING0 + rm . toString ( true ) ) ;

msg_token: rename insertLocalMessage insertLocal


diff:
<nb> public class TestingPrestoServer
 . put ( STRING0 , STRING1 )
 . put ( STRING2 , STRING3 )
 . put ( STRING4 , STRING3 )
 + . put ( STRING5 , STRING3 )
 . put ( STRING6 , STRING7 ) ;

 if ( ! properties . containsKey ( STRING8 ) ) {

msg_token: Reduce number of exchange client threads used in tests