diff stringlengths 38 1.78k | msg_token stringlengths 9 190 |
|---|---|
<nb> public class Array < T > implements Iterable < T > {
COMMENT
public T pop ( ) {
+ if ( size == NUMBER0 ) throw new IllegalStateException ( STRING0 ) ;
-- size ;
T item = items [ size ] ;
items [ size ] = null ;
<nb> public class Array < T > implements Iterable < T > {
COMMENT
public T peek ( ... | Add further precondition checks |
<nb> public final class AssetManager implements AutoCloseable {
COMMENT
COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
COMMENT
public native final String [ ] getLocales ( ) ; | Add detailed javadoc for AssetManager getLocales |
<nb> class MockMvcRequestSenderImpl implements MockMvcRequestSender {
}
private void logRequestIfApplicable ( HttpMethod method , String path , Object [ ] pathParams ) {
+ if ( requestLoggingFilter == null ) {
+ return ;
+ }
+
final RequestSpecificationImpl reqSpec = new RequestSpecificationImpl ( STRIN... | Fixed regression bug |
<nb> public class ImageView extends View {
if ( resizeWidth ) {
int newWidth = ( int ) ( desiredAspect * ( heightSize - ptop - pbottom ) ) +
pleft + pright ;
- widthSize = resolveAdjustedSize ( newWidth , mMaxWidth , widthMeasureSpec ) ;
if ( newWidth <= widthSize ) {
widthSize = newWidth ;
done = true ; ... | Revert Fix adjustViewBounds handling for ImageView |
<nb> import NAMESPACE ;
import static NAMESPACE ;
import static NAMESPACE ;
import static NAMESPACE ;
- import static NAMESPACE ;
import static NAMESPACE ;
public class FileStorageService
<nb> public class FileStorageService
public void createParents ( File file )
{
File dir = file . getParentFile... | Do not create directories that already exist |
<nb> public class OStorageRemote extends OStorageAbstract implements OStorageProxy {
try {
OStorageRemoteSession session = getCurrentSession ( ) ;
OStorageRemoteNodeSession nodeSession = session . getOrCreate ( network . getServerURL ( ) ) ;
- if ( nodeSession == null ) {
+ if ( nodeSession == null || ! nodeS... | fixed cross node retry missing check for valid sessions |
<nb> public class Verifier
COMMENT
public Verifier ( String value )
{
- this . value = URLUtils . percentDecode ( value ) ;
+ Preconditions . checkNotNull ( value , STRING0 ) ;
+ this . value = value ;
}
public String getValue ( ) | Removed encoding in Verifier constructor |
<nb> public class ProjectScopeServices extends DefaultServiceRegistry {
return new DefaultPluginContainer < Project > ( get ( PluginRegistry . class ) , project , allPluginApplyActions ) ;
}
- protected PluginApplicationAction createPluginApplicationAction ( ) {
+ protected PluginApplicationAction createPlugi... | rename service creation methods according to the implementations they provide |
<nb> class Clicker {
COMMENT
public ArrayList < TextView > clickInList ( int line , int index ) {
- if ( line == NUMBER0 )
+ if ( line < NUMBER1 )
line = NUMBER1 ;
+
boolean foundList = waiter . waitForView ( ListView . class , index ) ;
if ( ! foundList ) {
<nb> class Clicker {
try {
final Li... | Removed invincible views from clickInList |
<nb> public class WithingsAuthenticator implements ManagedService {
COMMENT
COMMENT
COMMENT
- private static final String DEFAULT_CONSUMER_KEY = STRING0 ;
+ private static final String DEFAULT_CONSUMER_KEY = STRING1 ;
COMMENT
COMMENT
COMMENT
- private static final String DEFAULT_CONSUMER_SECRET = STRI... | changed API key and secret to the official openHAB defaults |
<nb>
package NAMESPACE ;
- import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
<nb> public interface MetaClass extends MetaObjectProtocol {
COMMENT
COMMENT
COMMENT
- COMMENT
+ COMMENT
COMMENT
+ COMMENT
+ COMMENT
COMMENT
MetaMethod pickMethod ( String methodName , Class [ ] argum... | remove unused imports |
<nb> public final class DataOutput2 implements DataOutput {
this . buf = buf ;
}
- byte [ ] copyBytes ( ) {
+ public byte [ ] copyBytes ( ) {
return Arrays . copyOf ( buf , pos ) ;
}
COMMENT
COMMENT
COMMENT
- private void ensureAvail ( final int n ) {
+ public void ensureAvail ( final int n ) ... | Make some stuff in DataOutput2 public |
<nb> public class GuiCombustionEngine extends GuiEngine {
textureSheet = liquid . canonical ( ) . getTextureSheet ( ) ;
liquidIcon = liquid . canonical ( ) . getRenderingIcon ( ) ;
} else {
- if ( liquid . itemID < Block . blocksList . length && Block . blocksList [ liquid . itemID ] != null ) {
+ if ( liquid... | Fixed liquid icon check to actually catch that edge case |
<nb> import NAMESPACE ;
import NAMESPACE ;
COMMENT
+ COMMENT
COMMENT
COMMENT
COMMENT
COMMENT
COMMENT
COMMENT
- COMMENT
- COMMENT
COMMENT
COMMENT
COMMENT | tuned javadoc a bit |
<nb> public class LegacyRequestMapper {
private static final String TAG = STRING0 ;
private static final boolean VERBOSE = Log . isLoggable ( TAG , Log . VERBOSE ) ;
+ COMMENT
private static final byte DEFAULT_JPEG_QUALITY = NUMBER0 ;
COMMENT
<nb> public class LegacyRequestMapper {
SINGLE
{
- pa... | Fix jpeg thumbnail quality not being set |
<nb> final class DisplayPowerController {
mUsingScreenAutoBrightness = false ;
}
if ( mPowerRequest . screenState == DisplayPowerRequest . SCREEN_STATE_DIM ) {
- SINGLE
+ SINGLE
target = Math . min ( target - SCREEN_DIM_MINIMUM_REDUCTION ,
mScreenBrightnessDimConfig ) ;
- slow = true ;
+ slow = false ... | Dim the screen quickly in response to user activity timeout |
<nb>
COMMENT
- COMMENT
+ COMMENT
COMMENT
COMMENT
COMMENT
<nb>
package NAMESPACE ;
import NAMESPACE ;
- import NAMESPACE ;
import NAMESPACE ;
COMMENT
COMMENT
- COMMENT
+ COMMENT
COMMENT
COMMENT
COMMENT
<nb> public abstract class ResourcePatternUtils {
COMMENT
COMMENT
publi... | ResourcePatternUtils getResourcePatternResolver actually accepts null argument |
<nb> public class SemaphoreDetachMemberOperation extends SemaphoreBackupAwareOperatio
}
@ override
- public boolean returnsResponse ( ) {
- return false ;
- }
-
- @ override
public boolean shouldBackup ( ) {
final NodeEngine nodeEngine = getNodeEngine ( ) ;
IPartitionService partitionService = nod... | SemaphoreDetachMemberOperation should return response |
<nb> public class Request
COMMENT
protected boolean sslAttributesParsed = false ;
- COMMENT
- COMMENT
- COMMENT
- private final HashMap < String , Object > readOnlyAttributes = new HashMap < > ( ) ;
-
COMMENT
COMMENT
<nb> public class Request
@ override
public void removeAttribute ( String n... | Remove unused code |
<nb> public class PeerEurekaNode {
cancelProcessor . shutdown ( ) ;
statusProcessor . shutdown ( ) ;
asgStatusProcessor . shutdown ( ) ;
+ replicationClient . shutdown ( ) ;
}
COMMENT | Adding replication client shutdown in PeerEurekaNode |
<nb> import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
- import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ; | what the hell |
<nb> public final class MasterBlockInfoTests {
mInfo . removeWorker ( NUMBER0 ) ;
assertEquals ( NUMBER1 , mInfo . getWorkers ( ) . size ( ) ) ;
}
+
+ @ test
+ public void getNumLocationsTest ( ) {
+ mInfo . addWorker ( NUMBER0 , StorageLevelAlias . MEM . getValue ( ) ) ;
+ mInfo . addWorker ( NUMBER2 ,... | Added test case for getNumLocations |
<nb> public class TestSendFile extends TomcatBaseTest {
@ override
protected void doGet ( HttpServletRequest req , HttpServletResponse resp )
throws ServletException , IOException {
- if ( Boolean . valueOf ( req . getParameter ( Globals . SENDFILE_SUPPORTED_ATTR ) ) ) {
+ if ( Boolean . valueOf ( req . getPa... | Fix IDE nag |
<nb> public class NativeBitmapFactory {
return result ;
} catch ( Exception e ) {
return false ;
- } catch ( Error e ) { SINGLE
+ } catch ( Error e ) {
return false ;
} finally {
- if ( canvas != null ) {
- canvas . setBitmap ( null ) ;
- canvas = null ;
- }
if ( bitmap != null ) {
bitmap . re... | fix a strange NPE |
<nb> import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
+ import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
<nb> public class Note extends Syncable {
public Reply buildReply ( String content ) {
String restPath ;
if ( this . isCommentType ( ) ) {
- restPath = Stri... | Add explicit locale when constructing rest path |
<nb> public class CrashTest {
assertTrue ( dbSeed . get ( ) == getSeed ( seedStartDir , NUMBER0 ) || dbSeed . get ( ) == getSeed ( seedStartDir , NUMBER1 ) ) ;
}
+ if ( dbSeed . get ( ) != oldSeed )
+ commitCount ++ ;
Map < Long , byte [ ] > m = map ( p , db ) ;
SINGLE | fix commit count |
<nb> public class HeliosSoloDeployment implements HeliosDeployment {
private void pullIfAbsent ( final String image ) throws DockerException , InterruptedException {
try {
dockerClient . inspectImage ( image ) ;
- log . info ( STRING0 , image ) ;
+ log . info ( STRING1 , image ) ;
return ;
} catch ( Image... | Fix HeliosSoloDeployment pullIfAbsent |
<nb>
COMMENT
- COMMENT
+ COMMENT
COMMENT
COMMENT
COMMENT
<nb> import NAMESPACE ;
import NAMESPACE ;
COMMENT
- COMMENT
- COMMENT
+ COMMENT
+ COMMENT
COMMENT
COMMENT
COMMENT | Fix broken javadoc link to ROME tools project |
<nb> public class BottomBar extends FrameLayout implements View . OnClickListener , View
bottomBar . onRestoreInstanceState ( savedInstanceState ) ;
ViewGroup contentView = ( ViewGroup ) view . getParent ( ) ;
- View oldLayout = contentView . getChildAt ( NUMBER0 ) ;
- contentView . removeView ( oldLayout ) ;... | Fixed force close when the view has not parent such as in a Fragment |
<nb> public class GBM extends SharedTree < GBMModel , GBMModel . GBMParameters , GBMModel . GBM
for ( int row = NUMBER0 ; row < wk . _len ; row ++ ) {
if ( ys . isNA ( row ) ) continue ;
double f = tr . atd ( row ) + offset . atd ( row ) ;
- double y = ys . at8 ( row ) ;
+ double y = ys . atd ( row ) ;
if (... | was casting the response to a long instead of double was ok for classification |
<nb>
package NAMESPACE ;
+ import NAMESPACE ;
+ import NAMESPACE ;
import NAMESPACE ;
+ import NAMESPACE ;
+ import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
+ @ runwith ( HazelcastSerialClassRunner . class )
+ @ category ( QuickTest . class )
public class AddressTest {
@ test ( ... | Added test category runner |
<nb> class EditSignatureBalloon {
new WriteCommandAction ( project ) {
@ override
protected void run ( final Result result ) throws Throwable {
- ExternalAnnotationsManager
- . getInstance ( project ) . deannotate ( method , KotlinSignatureInJavaMarkerProvider . KOTLIN_SIGNATURE_ANNOTATION ) ;
- ExternalAnn... | Modifying external annotation within same XML |
<nb> package NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
- import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
<nb> public class ParsedGigawordReader implements Iterable < Annotation > {
new Function < File , BufferedReader > ( ) {
@ override
public... | Change method name to new name in IOUtils |
<nb> import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
- import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
<nb> public class SetPasswordCommand implements AdminCommand
new FileUserRepository ( new File ( authDir , STRING0 ) . toPath ( ) , NullLogProv... | Fix couple compilation errors |
<nb> public class AppUtils {
final Intent intent = new Intent ( Intent . ACTION_SEND ) ;
intent . setType ( STRING0 ) ;
intent . putExtra ( Intent . EXTRA_SUBJECT , subject ) ;
- intent . putExtra ( Intent . EXTRA_TEXT , text ) ;
+ intent . putExtra ( Intent . EXTRA_TEXT , ! TextUtils . isEmpty ( subject ) ? ... | Include both title and URL when sharing |
<nb> public class PSurfaceJOGL implements PSurface {
keyCode ) ;
sketch . postEvent ( ke ) ;
+
+ if ( ! isPCodedKey ( code ) && ! isHackyKey ( code ) ) {
+ if ( peAction == KeyEvent . PRESS ) {
+ SINGLE
+ SINGLE
+ KeyEvent tke = new KeyEvent ( nativeEvent , nativeEvent . getWhen ( ) ,
+ KeyEvent . T... | Emulate keyTyped for OpenGL sketches |
<nb> public class ProjectRootsTraversing {
state . getCurrentModuleManager ( ) . processOrder ( policy , state ) ;
}
- static class TraverseState implements UserDataHolder {
+ public static class TraverseState implements UserDataHolder {
private final UserDataHolderBase myUserData = new UserDataHolderBase (... | Extend JRuby interpreter classpath with java classes |
<nb> public class AppSettingsFragment extends PreferenceFragment implements OnPrefere
mLanguagePreference . setEntryValues ( sortedValues ) ;
mLanguagePreference . setDetails ( WPPrefUtils . createLanguageDetailDisplayStrings ( sortedValues ) ) ;
- mLanguagePreference . setValue ( languageCode . toLowerCase ( )... | Don t change the language code to lowercase anymore since available languages are not lowercase |
<nb> public class ResolveImportUtil {
@ notnull
private static List < PsiElement > resolveRelativeImportAsAbsolute ( @ notnull PsiFile foothold ,
@ notnull QualifiedName qualifiedName ) {
- final boolean inSource = FileIndexFacade . getInstance ( foothold . getProject ( ) ) . isInContent ( foothold . getVirtual... | do not resolve relative import as absolute if corresponding virtualFile is null |
<nb> public abstract class AbstractTest
case H2C :
case H2 :
{
- HTTP2Client http2Client = new HTTP2Client ( ) ;
- http2Client . setSelectors ( NUMBER0 ) ;
+ HTTP2Client http2Client = newHTTP2Client ( ) ;
return new HttpClientTransportOverHTTP2 ( http2Client ) ;
}
case FCGI :
<nb> public abstract cl... | Added factory method to create HTTP2Client |
<nb> public class DexMojo extends AbstractAndroidMojo {
COMMENT
COMMENT
private boolean coreLibrary ;
+
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ private boolean noLocals ;
public void execute ( ) throws MojoExecutionException , MojoFailureException {
<nb> public class DexMojo exte... | Added support for passing the optional flag no locals to dx |
<nb> import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
- import NAMESPACE ;
+ import NAMESPACE ;
+ import NAMESPACE ;
+ import NAMESPACE ;
+ import NAMESPACE ;
+ import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
<nb> public class InternalClusterInfoService extends AbstractCompone... | Manually synchronize listeners when iterating on them in InternalClusterInfoService |
<nb> public @ interface EqualsAndHashCode {
COMMENT
COMMENT
COMMENT
+ COMMENT
COMMENT
boolean callSuper ( ) default false ;
}
<nb> import NAMESPACE ;
COMMENT
COMMENT
COMMENT
- COMMENT
+ COMMENT
COMMENT
COMMENT
COMMENT
<nb> import NAMESPACE ;
@ target ( ElementType . TYPE )
@ retent... | Updated the javadoc of EqualsAndHashCode and ToString the annotation source files |
<nb> public class ResultSetModel {
SINGLE
continue ;
}
- filterConstraint . setOperator ( constraint . getOperator ( ) ) ;
- filterConstraint . setReverseOperator ( constraint . isReverseOperator ( ) ) ;
- filterConstraint . setValue ( constraint . getValue ( ) ) ;
- filterConstraint . setCriteria ( const... | Filter update fix |
<nb> public class ReaderPostPagerActivity extends AppCompatActivity
super . onPageSelected ( position ) ;
onShowHideToolbar ( true ) ;
trackPostAtPositionIfNeeded ( position ) ;
+ SINGLE
+ ReaderPostDetailFragment fragment = getDetailFragmentAtPosition ( position ) ;
+ if ( fragment != null ) {
+ fragment... | Resume paused webView when page becomes active |
<nb> import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
- import NAMESPACE ;
import NAMESPACE ;
- import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
<nb> import NAMESPACE ;
COMMENT
@ configuration
@ conditionalonclass ( EnableJms . class )
- ... | Don t import JmsBootstrapConfiguration directly |
<nb> import NAMESPACE ;
import NAMESPACE ;
import static NAMESPACE ;
+ import static NAMESPACE ;
public class HgUpdateCommand {
<nb> public class HgUpdateCommand {
. notifyImportantWarning ( STRING0 ,
HgVcsMessages . message ( STRING1 , repository . getPath ( ) ) ) ;
}
+ getRepositoryManager ( p... | update Repository info after update command |
<nb> final class BundleSupport {
. build ( ruleContext ) ) ;
}
- private CommandLine actoolzipCommandLine (
- final ObjcProvider provider ,
- final Artifact zipOutput ,
- final Artifact partialInfoPlist ) {
+ private CommandLine actoolzipCommandLine ( ObjcProvider provider , Artifact zipOutput ,
+ Art... | Remove unneeded final qualifiers from parameters |
<nb> package NAMESPACE ;
COMMENT
COMMENT
COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
COMMENT
public interface ExtensionAware { | Add details about how we search for properties in ExtensionAware |
<nb> public class SmsRestoreService extends ServiceBase {
lastError = e . getLocalizedMessage ( ) ;
publishProgress ( GENERAL_ERROR ) ;
return null ;
+ } catch ( IllegalStateException e ) {
+ SINGLE
+ lastError = e . getLocalizedMessage ( ) ;
+ publishProgress ( GENERAL_ERROR ) ;
+ return null ;
} fin... | Catch illegalstate exceptions |
<nb> implements OnRemoteOperationListener , ComponentsGetter {
private static final String DIALOG_WAIT_TAG = STRING0 ;
private static final String KEY_WAITING_FOR_OP_ID = STRING1 ; ;
+ protected static final long DELAY_TO_REQUEST_OPERATION_ON_ACTIVITY_RESULTS = NUMBER0 ;
+
COMMENT
private Account mAccou... | Fixed crash when selecting a folder to move file into after rotating the device in the selection view |
<nb> public final class BookInSeriesTree extends BookTree {
if ( tree instanceof BookInSeriesTree ) {
final BigDecimal index0 = Book . getSeriesInfo ( ) . Index ;
final BigDecimal index1 = ( ( BookTree ) tree ) . Book . getSeriesInfo ( ) . Index ;
+ final int cmp ;
if ( index0 == null ) {
- return index1 ==... | fixed books in series tree comparison |
<nb> public class MuzeiDocumentsProvider extends DocumentsProvider {
} else if ( BY_DATE_DOCUMENT_ID . equals ( parentDocumentId ) ) {
includeAllArtwork ( result , getContext ( ) . getContentResolver ( ) . query (
MuzeiContract . Artwork . CONTENT_URI , ARTWORK_PROJECTION , null , null ,
- MuzeiContract . Artwo... | Use Artwork DEFAULT_SORT_ORDER for ordering artwork |
<nb> import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
- import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
- import NAMESPACE ;
COMMENT
COMMENT
<nb> import NAMESPACE ;
COMMENT
COMMENT
public abstract class CallServiceProvider extends Service {
- COMMENT
... | Remove unused code comments and adding missing tags etc |
<nb> public class Util {
Method method = ( Method ) UserHandle . class . getDeclaredMethod ( STRING0 , int . class ) ;
uid = ( Integer ) method . invoke ( null , uid ) ;
} catch ( Throwable ex ) {
- Util . bug ( null , ex ) ;
+ Util . log ( null , Log . WARN , ex . toString ( ) ) ;
}
return uid ;
}
<n... | Make two errors two warnings support info |
<nb> import NAMESPACE ;
public class OptimisticLockRetryPolicyTest extends TestCase {
- private static long precision = NUMBER0 ; SINGLE
+ private static long precision = NUMBER1 ; SINGLE
public void testRandomBackOff ( ) throws Exception {
OptimisticLockRetryPolicy policy = new OptimisticLockRetryPolic... | Fixed test on slower boxes such as windows |
<nb> import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
- import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
<nb> public class OSGiIntegrationTest {
systemProperty ( STRING0 ) . value ( STRING1 ) ,
SINGLE
- SINGLE
+ mavenBundle ( ) . groupId ( STRING2 ) . artifac... | Fixed the build error of OSGiIntegrationTest |
<nb> public class PSurfaceAWT implements PSurface {
SINGLE
SINGLE
- setFrameSize ( ) ; SINGLE
+ if ( frame != null ) {
+ frame . setLocationRelativeTo ( null ) ;
+ }
setCanvasSize ( ) ;
- frame . setLocationRelativeTo ( null ) ;
- SINGLE
- SINGLE
- SINGLE
GraphicsConfiguration gc = canvas . ... | reset PSurfaceAWT to what it was |
<nb> public class ConditionQueryBuilder < ModelClass extends Model > extends QueryBuilde
COMMENT
COMMENT
COMMENT
- COMMENT
+ COMMENT
COMMENT
@ suppresswarnings ( STRING0 )
public String convertValueToString ( Object value ) {
<nb> import NAMESPACE ;
import NAMESPACE ;
COMMENT
- COMMENT
+ COM... | updated comments here |
<nb> public class MainActivity extends BaseActivity implements AsyncResponse {
openFragment ( deviceFragment ) ;
title = getString ( R . string . app_name_short ) ;
break ;
- case DrawerMenu . ID . MAIN . CURRENT_TREAT_LEVEL :
+ case DrawerMenu . ID . MAIN . NEIGHBOURING_CELLS :
openFragment ( cellInfoFragm... | Corrected missing symbol |
<nb> public class InterleavedBidirectionalHeuristic implements RemainingWeightHeurist
weights = Maps . newHashMapWithExpectedSize ( ( ( int ) Math . log ( nVertices ) ) + NUMBER0 ) ;
this . options = s . getOptions ( ) ;
this . origin = s . getVertex ( ) ;
+ SINGLE
+ options . setSoftWalkLimiting ( false ) ; ... | Use hard walk limiting in long distance mode |
<nb> public class GLM2 extends Job . ModelJobWithoutClassificationField {
SINGLE
}
toEnum = family == Family . binomial && ( ! response . isEnum ( ) && ( response . min ( ) < NUMBER0 || response . max ( ) > NUMBER1 ) ) ;
-
+ if ( source2 . numCols ( ) <= NUMBER1 && ! intercept )
+ throw new IllegalArgumentE... | throw IAE in case there are no predictor columns and no intercept |
<nb> package NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
-
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
<nb> import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
-
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ; | Revert whitespace changes |
<nb> public class AuthenticatingHttpConnector implements HttpConnector {
listBuilder . add ( identity ) ;
}
}
- } catch ( IOException e ) {
+ } catch ( Exception e ) {
+ SINGLE
+ SINGLE
log . debug ( STRING0 , e ) ;
}
} | Ignore all ssh agent errors |
<nb>
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
package NAMESPACE ;
import NAMESPACE ;
<nb>
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT... | Adding missing license headers |
<nb> public class XMPPException extends Exception {
wrappedThrowable . printStackTrace ( out ) ;
}
}
- }
+
+ public String toString ( ) {
+ StringBuffer buf = new StringBuffer ( ) ;
+ if ( wrappedThrowable != null ) {
+ buf . append ( wrappedThrowable ) ;
+ }
+ if ( error != null ) {
+ buf . app... | Added toString method |
<nb> public class WebSocketProcessor implements Serializable {
AtmosphereResponse wsr = new AtmosphereResponse ( webSocket , webSocketProtocol , request , destroyable ) ;
- request . header ( HeaderConfig . X_ATMOSPHERE_TRANSPORT ,
- HeaderConfig . WEBSOCKET_TRANSPORT )
- . headers ( configureHeader ( reque... | Avoid double header |
<nb> public class StreamManager implements StreamManagerMBean
COMMENT
public static RateLimiter getRateLimiter ( )
{
- double currentThroughput = DatabaseDescriptor . getStreamThroughputOutboundMegabitsPerSec ( ) * NUMBER0 * NUMBER0 / NUMBER1 / NUMBER2 ;
+ double currentThroughput = ( ( double ) DatabaseDescr... | use double math for currentThroughput |
<nb> public class EditPeopleControlSet extends PopupControlSet {
}
@ override
+ protected boolean onOkClick ( ) {
+ if ( ! TextUtils . isEmpty ( assignedCustom . getText ( ) ) ) {
+ JSONObject assigned = PeopleContainer . createUserJson ( assignedCustom ) ;
+ String email = assigned . optString ( STRING0 ... | Use the onOkClick hook in assignment picker to validate email before dismissing dialog |
<nb> package NAMESPACE ;
COMMENT
COMMENT
public interface Vocabulary {
-
COMMENT
COMMENT
- COMMENT
+ COMMENT
COMMENT
COMMENT
int getMaxTokenType ( ) ;
<nb> public class VocabularyImpl implements Vocabulary {
this . literalNames = literalNames != null ? literalNames : EMPTY_NAMES ;
this . sym... | add get max token type to vocab |
<nb>
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+
package NAMESPACE ;
import NAMESPACE ; | Adding a missing license header |
<nb> public class ImageDecoder {
COMMENT
COMMENT
COMMENT
- public synchronized CloseableStaticBitmap decodeStaticImage (
+ public CloseableStaticBitmap decodeStaticImage (
final EncodedImage encodedImage ) {
CloseableReference < Bitmap > bitmapReference =
mBitmapFactoryWithPool . decodeFromEncodedImage ... | Remove synchronization from ImageDecoder |
<nb> public class BitsCounterTest {
}
@ test public void numberOfBitsInTwoIsOne ( ) {
- assertEquals ( NUMBER0 , bitsCounter . countBitsToOneBasedOnString ( NUMBER1 ) ) ;
+ assertEquals ( NUMBER1 , bitsCounter . countBitsToOneBasedOnString ( NUMBER0 ) ) ;
}
@ test public void numberOfBitsInThreeIsTwo ( ... | Modify tests and add a new test case |
<nb> import static NAMESPACE
public class GithubNotifications {
private static final Logger LOG = GithubUtil . LOG ;
- private static final String GITHUB_NOTIFICATION_GROUP = STRING0 ;
-
public static void showInfo ( @ notnull Project project , @ notnull String title , @ notnull String message ) {
LOG . i... | remove deprecated string constant |
<nb> public class CoordinatorLayout extends ViewGroup implements NestedScrollingParen
SINGLE
SINGLE
if ( b != null ) {
- if ( cancelEvent != null ) {
+ if ( cancelEvent == null ) {
final long now = SystemClock . uptimeMillis ( ) ;
cancelEvent = MotionEvent . obtain ( now , now ,
MotionEvent . ACTION_CAN... | Fix crash in CoordinatorLayout DO NOT MERGE |
<nb>
COMMENT
- COMMENT
+ COMMENT
COMMENT
COMMENT
COMMENT
<nb> public interface PlatformIcons {
Icon WARNING_INTRODUCTION_ICON = AllIcons . Nodes . WarningIntroduction ;
Icon JAVA_OUTSIDE_SOURCE_ICON = AllIcons . FileTypes . JavaOutsideSource ;
Icon EXCLUDED_FROM_COMPILE_ICON = AllIcons . Nodes . Exc... | set proper project icon |
<nb> public abstract class OIndexMVRBTreeAbstract < T > extends OSharedResourceAdaptiveE
try {
map . commitChanges ( true ) ;
+ map . unload ( ) ;
Orient . instance ( ) . getMemoryWatchDog ( ) . removeListener ( watchDog ) ;
} finally { | Flushed out index memory on database close |
<nb> public class Tree extends WidgetGroup {
float ySpacing = this . ySpacing ;
for ( int i = NUMBER0 , n = nodes . size ; i < n ; i ++ ) {
Node node = nodes . get ( i ) ;
- Actor actor = node . actor ;
float x = indent ;
if ( node . icon != null ) x += node . icon . getMinWidth ( ) ;
y -= node . height ;... | Removed unused local |
<nb> public class PlaybackServiceMediaPlayer implements SharedPreferences . OnSharedPre
|| playerStatus == PlayerStatus . PREPARED
|| playerStatus == PlayerStatus . SEEKING ) {
retVal = mediaPlayer . getCurrentPosition ( ) ;
+ if ( retVal <= NUMBER0 && media != null && media . getPosition ( ) > NUMBER0 ) {
+ ... | If media player position makes no sense get position from media |
<nb> import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
+ import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
<nb> public class RStudio implements EntryPoint
PackratActionDialog . ensureStylesInjected ( ) ;
LocalRepositoriesWidget . ensureStylesInject... | inject styles for deploy dialog on startup |
<nb> public class NettyAsyncHttpProvider extends IdleStateHandler implements AsyncHtt
case DIGEST :
try {
nettyRequest . setHeader ( HttpHeaders . Names . AUTHORIZATION ,
- AuthenticatorUtils . computeDisgestAuthentication ( realm ) ) ;
+ AuthenticatorUtils . computeDigestAuthentication ( realm ) ) ;
} catc... | Fix typo in name |
<nb> public class NotificationsDetailActivity extends AppCompatActivity implements
}
}
- if ( isInstantReply ) {
- ( ( CommentDetailFragment ) fragment ) . enableShouldFocusReplyField ( ) ;
+ SINGLE
+ if ( fragment != null && fragment instanceof CommentDetailFragment ) {
+ if ( isInstantReply ) {
+ ( ... | Add additional type checkings |
<nb> import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
+ import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
- import NAMESPACE ;
-
COMMENT
COMMENT
COMMENT
<nb> public class PythonFoldingBuilder implements FoldingBuilder {
new TextRange ( colon . getStartOffs... | Prevent NPE if no identifer is entered yet after class |
<nb> public class Observable < T > {
COMMENT
COMMENT
COMMENT
+ COMMENT
COMMENT
public static < T > Observable < T > empty ( ) {
return from ( new ArrayList < T > ( ) ) ;
<nb> public class Observable < T > {
COMMENT
COMMENT
COMMENT
+ COMMENT
COMMENT
public static < T > Observable < T > empty ... | Added MSDN links |
<nb> public class MongoStorage extends StoreFunc implements StoreMetadata {
e . printStackTrace ( ) ;
}
- SINGLE
- for ( MongoStorageOptions . Index in : options . getIndexes ( ) ) {
- _recordWriter . ensureIndex ( in . index , in . options ) ;
+ if ( options != null ) {
+ SINGLE
+ for ( MongoStorageO... | Made options optional |
<nb> public abstract class SerializationManager {
}
}
+ public abstract String internString ( String string ) ;
}
<nb> public abstract class SerializationManagerEx extends SerializationManager {
public abstract void repairNameStorage ( ) ;
public abstract void flushNameStorage ( ) ;
-
- public abs... | pull up internString to base SerializationManager interface |
<nb> public class StemmerTokenFilterFactory extends AbstractTokenFilterFactory {
} else if ( STRING0 . equalsIgnoreCase ( language ) || STRING1 . equalsIgnoreCase ( language ) ) {
return new EnglishMinimalStemFilter ( tokenStream ) ;
} else if ( STRING2 . equalsIgnoreCase ( language ) || STRING3 . equalsIgnoreCas... | provide version in the english filter |
<nb> public class Color {
public static final Color BLACK = new Color ( NUMBER0 , NUMBER0 , NUMBER0 , NUMBER1 ) ;
public static final Color WHITE = new Color ( NUMBER2 ) ;
- public static final Color LIGHT_GRAY = new Color ( NUMBER3 ) ;
+ public static final Color LIGHT_GRAY = new Color ( NUMBER4 ) ;
public... | Fixed light gray |
<nb> public abstract class HystrixCommandMetrics extends HystrixMetrics {
COMMENT
COMMENT
COMMENT
- public final HealthCounts getHealthCounts ( ) {
+ SINGLE
+ public HealthCounts getHealthCounts ( ) {
SINGLE
SINGLE
long lastTime = lastHealthCountsSnapshot . get ( ) ; | Revert Made HystrixCommandMetrics getHealthCounts final |
<nb> package NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
+ import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
<nb> public class YeOldePlumberSchool implements PlumberSchool
IndexMerger . mergeMMapped ( indexes , schema . getAggregators ( ) , fileToUpload ) ;
}
- fi... | Populate dimension metadata in segment descriptor |
<nb>
COMMENT
- COMMENT
+ COMMENT
COMMENT
COMMENT
COMMENT
<nb> public class EditorComponentImpl extends JComponent implements Scrollable , DataP
}
}
+ @ override
+ public void revalidate ( ) {
+ myEditor . resetPaintersWidth ( ) ;
+ super . revalidate ( ) ;
+ }
+
public void repaintEdit... | reset line painters width in revalidate |
<nb> public class SceneLoader extends DefaultHandler implements AssetLoader {
SINGLE
materialList = materialLoader . load ( assetManager , folderName , info . openStream ( ) ) ;
- if ( materialList . isEmpty ( ) ) {
+ if ( materialList == null || materialList . isEmpty ( ) ) {
SINGLE
SINGLE
SINGLE | prevent issue when dotScene file is missing an externals section |
<nb> public class FileBackend {
frame = metadataRetriever . getFrameAtTime ( NUMBER0 ) ;
metadataRetriever . release ( ) ;
frame = resize ( frame , size ) ;
- } catch ( IllegalArgumentException e ) {
+ } catch ( IllegalArgumentException | NullPointerException e ) {
frame = Bitmap . createBitmap ( size , siz... | catch NPE in getVideoPreview because getFrame sometimes returns null |
<nb> public final class PowerManager {
COMMENT
COMMENT
COMMENT
+ COMMENT
+ COMMENT
COMMENT
COMMENT
COMMENT
<nb> public final class PowerManagerService extends IPowerManager . Stub
}
}
+ private static boolean isScreenLock ( final WakeLock wakeLock ) {
+ switch ( wakeLock . mFlags & PowerMana... | Ignore invalid combination of PowerManager flags |
<nb> import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
+
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
<nb> import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
- import static NAMESPACE ;
- import static NAMESPACE ;
- import static NAMESPACE ;
- im... | Removed star imports |
<nb> public class PinchZoomDetector extends BaseDetector {
COMMENT
COMMENT
private static float calculatePointerDistance ( final MotionEvent pMotionEvent ) {
- return MathUtils . distance ( pMotionEvent . getX ( NUMBER0 ) , pMotionEvent . getY ( NUMBER0 ) , pMotionEvent . getX ( NUMBER1 ) , pMotionEvent . getX ... | Fixed typo causing PinchZoomDetector to calculate the pinch distance wrong |
<nb> public class BindingContextUtils {
type = TypeUtils . makeNullable ( type ) ;
}
trace . record ( BindingContext . EXPRESSION_TYPE , expression , type ) ;
- trace . record ( BindingContext . PROCESSED , expression ) ;
return type ;
} | Remove set of PROCESSED flag in updateRecordedType |
<nb> public class Execution implements Runtime
SINGLE
executionSerializer . shutdown ( ) ;
- SINGLE
- Task . allOf ( extensions . stream ( ) . map ( v - > v . stop ( ) ) ) . join ( ) ;
-
SINGLE
messaging . stop ( ) ;
+ SINGLE
+ Task . allOf ( extensions . stream ( ) . map ( v - > v . stop ( ) ) ) ... | Shut down messaging before extensions |
<nb> public abstract class SPreferenceActivity extends PreferenceActivity implements
@ override
public void setContentView ( View view ) {
if ( isABSSupport ( ) ) {
- getSherlock ( ) . setContentView ( ( view ) ) ;
+ getSherlock ( ) . setContentView ( FontLoader . apply ( view ) ) ;
} else {
super . setCo... | Fix fonts in SPreferenceActivity |
<nb> public class OperationSetPersistentPresenceIrcImpl
void updateNick ( final String oldNick , final String newNick )
{
ContactIrcImpl contact = findContactByID ( oldNick ) ;
+ if ( contact == null )
+ {
+ SINGLE
+ return ;
+ }
contact . setAddress ( newNick ) ;
fireContactPropertyChangeEvent (
... | Do not update nick for users that have no corresponding contact |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.