diff stringlengths 38 1.78k | msg_token stringlengths 9 190 |
|---|---|
<nb> public class Url implements Serializable {
}
public void setScheme ( String s ) {
- if ( Protocol . valueOf ( s . toUpperCase ( ) ) == null ) {
- throw new IllegalArgumentException ( STRING0 + s + STRING1 ) ;
- }
+ Protocol . valueOf ( s . toUpperCase ( ) ) ;
this . scheme = s ;
} | enum s valueOf already throws IAE no need to do it ourselfs |
<nb> public class Entity {
return this ;
}
+ public Entity addImport ( String additionalImport ) {
+ additionalImportsEntity . add ( additionalImport ) ;
+ return this ;
+ }
+
COMMENT
Entity useProtobuf ( ) {
protobuf = true ;
<nb>
package NAMESPACE ;
+ import NAMESPACE ;
+
SINGLE
CO... | added addImport for entities |
<nb>
package NAMESPACE ;
- import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
<nb> public final class RPCErrorResponse extends RPCResponse {
COMMENT
COMMENT
public static RPCErrorResponse decode ( ByteBuf in ) {
- return new RPCErrorResponse ( Status . fromShort ( Preconditions . checkNotN... | Removed unnecessary null checking |
<nb>
COMMENT
COMMENT
-
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
... | Add the original copyright |
<nb>
package NAMESPACE ;
import NAMESPACE ;
- import NAMESPACE ;
+ SINGLE
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ; | remove unused import for now |
<nb> import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
+ import NAMESPACE ;
+
COMMENT
COMMENT
COMMENT
<nb> import NAMESPACE ;
COMMENT
COMMENT
COMMENT
+ @ threadsafe
public abstract class ResourcePool < T > {
private final ReentrantLock mTakeLock ;
private final Condition mNotEmpty... | Adding thread safety annotations for tachyon resource in common module |
<nb> public class Pep8ExternalAnnotator extends ExternalAnnotator < Pep8ExternalAnnotat
@ override
public void consume ( ModifiableModel model ) {
PyPep8Inspection tool = ( PyPep8Inspection ) model . getUnwrappedTool ( PyPep8Inspection . INSPECTION_SHORT_NAME , file ) ;
- tool . ignoredErrors . add ( myCode ) ;... | Add check if error not in ignoredError list |
<nb> import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
+ import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
<nb> public class IpnbFilePanel extends JPanel implements Scrollable , DataProvider , D
if ( project . isDisposed ( ) ) {
return ;
}
+ if... | fixed disposed error on run cell |
<nb> public class FragmentManager {
throw new SuperNotCalledException ( STRING0 + f
+ STRING1 ) ;
}
+ f . mActivity . mAllLoaderManagers . remove ( f . mIndex ) ;
f . mActivity = null ;
}
} | Fix bug where LoaderManager instances were not being removed |
<nb> public class BackgroundHiveSplitLoader
finally {
taskExecutionLock . readLock ( ) . unlock ( ) ;
}
+ SINGLE
+ if ( outstandingTasks . decrementAndGet ( ) == NUMBER0 ) {
+ invokeFinishedIfShould ( ) ;
+ }
if ( ! hiveSplitSource . isQueueFull ( ) ) {
SINGLE
startLoadSplits ( ) ;
SINGLE
startL... | Fix starvation in BackgroundHiveSplitLoader |
<nb> public class DataSetLossCalculator implements ScoreCalculator < MultiLayerNetwork >
int exCount = NUMBER0 ;
while ( dataSetIterator . hasNext ( ) ) {
DataSet dataSet = dataSetIterator . next ( ) ;
+ if ( dataSet == null ) break ;
int nEx = dataSet . getFeatureMatrix ( ) . size ( NUMBER0 ) ;
lossSum += ... | Fix break on calculateScore when dataSet null |
<nb> public class BazelCppRuleClasses {
new String [ ] {
STRING0 ,
STRING1 ,
+ STRING2 ,
} ;
COMMENT | Permit cc objc deps |
<nb> public class MongoRecordWriter < K , V > extends RecordWriter < K , V > {
if ( key instanceof MongoOutput )
( ( MongoOutput ) key ) . appendAsKey ( o ) ;
+ else if ( key instanceof BSONObject )
+ o . put ( STRING0 , ( BSONObject ) key ) ;
else
o . put ( STRING0 , toBSON ( key ) ) ;
if ( value ins... | Add support for BSONObjects in output writing |
<nb> public class FileSystemTreeFactoryImpl implements FileSystemTreeFactory {
action1 . registerCustomShortcutSet ( original . getShortcutSet ( ) , fileSystemTree . getTree ( ) ) ;
group . add ( action1 ) ;
group . addSeparator ( ) ;
+ group . add ( actionManager . getAction ( STRING0 ) ) ;
return group ; ... | add show hidden files toggle |
<nb> public class CheckEventfulObjectDisposal implements CompilerPass {
int lastPeriod = functionOrMethodName . lastIndexOf ( STRING0 ) ;
SINGLE
if ( lastPeriod >= NUMBER0 ) {
- potentiallyTypeName = functionOrMethodName . substring ( NUMBER0 , lastPeriod ) ;
+ potentiallyTypeName = functionOrMethodName . sub... | Fix dispose for custom disposables |
<nb> package NAMESPACE ;
import NAMESPACE ;
COMMENT
- COMMENT
+ COMMENT
COMMENT
COMMENT
COMMENT
<nb> final class H2EmbeddedDatabaseConfigurer extends AbstractEmbeddedDatabaseConfigu
private static H2EmbeddedDatabaseConfigurer INSTANCE ;
COMMENT
- COMMENT
+ COMMENT
COMMENT
- COMMENT
+ C... | fixed typo and JavaDocs |
<nb> public class PShape3D extends PShape {
render ( texture ) ;
}
- if ( matrix != null ) {
+ if ( matrix != null && applyMatrix ) {
g . popMatrix ( ) ;
}
}
<nb> public class PShape3D extends PShape {
render ( texture ) ;
}
- if ( matrix != null ) {
+ if ( matrix != null && applyMatrix ) { ... | Fixed popMatrix condition in PShape3D draw |
<nb> public class RemoteTaskRunner implements TaskRunner , TaskLogProvider
) ;
tasksToFail . addAll ( zkWorker . getRunningTaskIds ( ) ) ;
for ( String assignedTask : tasksToFail ) {
- RemoteTaskRunnerWorkItem taskRunnerWorkItem = runningTasks . get ( assignedTask ) ;
+ RemoteTaskRunnerWorkItem taskRunnerWork... | fix another bug with RTR to remove things correctly from running tasks |
<nb> public class PerforceRepository extends Repository {
try {
String argv [ ] = { System . getProperty ( STRING0 , STRING1 ) , STRING2 } ;
process = Runtime . getRuntime ( ) . exec ( argv ) ;
- process . waitFor ( ) ;
+ boolean done = false ;
+ do {
+ try {
+ process . waitFor ( ) ;
+ done = true ; ... | Fixed the test in PerforceChecker Removed findbugs warning |
<nb> public class Temperature {
}
COMMENT
+ COMMENT
+ COMMENT
+ public String getMinMax ( ) {
+ return UnitUtils . doubleToIntDisplayString ( min ) + STRING0 + UnitUtils . doubleToIntDisplayString ( max ) ;
+ }
+
+ COMMENT
+ COMMENT
+ COMMENT
+ public String getMinMaxF ( ) {
+ return UnitUti... | Added min max temperature in one string |
<nb> class ProcessClosurePrimitives extends AbstractPostOrderCallback
maybeAddStringNodeToSymbolTable ( arg ) ;
SINGLE
- SINGLE
- SINGLE
+ SINGLE
SINGLE
SINGLE
SINGLE
- if ( provided != null || requiresLevel . isOn ( ) ) {
+ if ( provided != null ) {
parent . detachFromParent ( ) ;
compiler . ... | The error level shouldn t effect compiler output |
<nb> public class TaskListActivity extends ListFragment implements OnScrollListener ,
getActivity ( ) . runOnUiThread ( new Runnable ( ) {
@ override
public void run ( ) {
- loadTaskListContent ( true ) ;
+ try {
+ loadTaskListContent ( true ) ;
+ } catch ( IllegalStateException e ) {
+ SINGLE
+ }
}... | Added a try catch to fix a background refresh crash |
<nb> public abstract class AbstractPollingReporterTest {
registry . add ( new MetricName ( Object . class , STRING0 ) , metric ) ;
reporter . run ( ) ;
out . flush ( ) ;
- final String [ ] lines = out . toString ( ) . split ( STRING1 ) ;
+ final String [ ] lines = out . toString ( ) . split ( STRING2 ) ;
SI... | Fixed a platform specific regex in AbstractPollingReporterTest |
<nb> public class AddFeedActivity extends SherlockActivity {
progDialog = new ProgressDialog ( this ) {
@ override
public void onBackPressed ( ) {
- requester . cancelDownload ( getContext ( ) , downloadId ) ;
+ if ( isWaitingForImage ) {
+ requester . cancelDownload ( getContext ( ) , imageDownloadId ) ;
... | Fixed several bugs in AddFeedActivity |
<nb> public class SiteSettingsFragment extends PreferenceFragment
private void setupPreferenceList ( ListView prefList , Resources res ) {
if ( prefList == null || res == null ) return ;
+ prefList . setDivider ( getResources ( ) . getDrawable ( R . drawable . preferences_divider ) ) ;
+ prefList . setDivider... | Setting list divider programmatically |
<nb> public class PackageObjectFactoryTest extends TestCase
STRING0 ) ;
assertNotNull ( check ) ;
}
-
+
public void testMakeObectFromList ( )
throws CheckstyleException
{
<nb> public class PackageObjectFactoryTest extends TestCase
STRING1 ) ;
assertNotNull ( checker ) ;
}
-
+
public void t... | removed dead code |
<nb>
COMMENT
package NAMESPACE ;
- import NAMESPACE ;
- import NAMESPACE ;
- import NAMESPACE ;
+ import NAMESPACE ;
+ import NAMESPACE ;
+ import NAMESPACE ;
+ import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
- import NAME... | vcs log optimize imports |
<nb> public class VcsLogUiImpl implements VcsLogUi , Disposable {
setModel ( newModel , myDataPack , previouslySelected ) ;
myMainFrame . updateDataPack ( myDataPack ) ;
setLongEdgeVisibility ( myUiProperties . areLongEdgesVisible ( ) ) ;
- setBek ( myUiProperties . isBek ( ) ) ;
+ myDataPack . getGraphFacade... | log set bek synchronously when applying filters to avoid locks |
<nb> public class DatabaseDescriptor
}
catch ( NoSuchFieldException e )
{
- ConfigurationException ex = new ConfigurationException ( e . getMessage ( ) ) ;
+ ConfigurationException ex = new ConfigurationException ( STRING0 ) ;
ex . initCause ( e ) ;
throw ex ;
}
catch ( IllegalAccessException e )
{ ... | add friendlier ConfigurationException for malformed AbstractTypes |
<nb> package NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
- import NAMESPACE ;
import NAMESPACE ; | Remove unused import |
<nb> public class IndexShard extends AbstractIndexShardComponent {
refreshMetric . inc ( System . nanoTime ( ) - time ) ;
} finally {
logger . debug ( STRING0 , new ByteSizeValue ( bytes ) , shardId ( ) ) ;
- SINGLE
writingBytes . addAndGet ( - bytes ) ;
}
} else {
<nb> public class IndexShard extends A... | remove nocommits fix test case |
<nb> public class ReadInteractionsService extends IntentService {
sharedPrefs . edit ( ) . putInt ( STRING0 , NUMBER0 ) . commit ( ) ;
sharedPrefs . edit ( ) . putInt ( STRING1 , NUMBER0 ) . commit ( ) ;
sharedPrefs . edit ( ) . putInt ( STRING2 , NUMBER0 ) . commit ( ) ;
+ sharedPrefs . edit ( ) . putInt ( STR... | Fix Clear interaction count for new quotes |
<nb> public abstract class ForwardingFileSystem
{
fileSystem . setTimes ( p , mtime , atime ) ;
}
+
+ @ override
+ public void setConf ( Configuration conf )
+ {
+ SINGLE
+ if ( fileSystem != null ) {
+ fileSystem . setConf ( conf ) ;
+ }
+ else {
+ Preconditions . checkArgument ( conf == null... | Add set getConf to ForwardingFileSystem |
<nb> public class Property
{
for ( char c : name . toCharArray ( ) )
{
- if ( ! Character . isLetterOrDigit ( c ) && Configuration . ALLOWED_CHARS . indexOf ( c ) == - NUMBER0 )
+ if ( ! Character . isLetterOrDigit ( c ) && Configuration . ALLOWED_CHARS . indexOf ( c ) == - NUMBER0 && ! Character . isWhitespa... | Allow white space in the property name |
<nb> public class SipToFlashAudioStream implements TranscodedAudioDataListener , RtpSt
startTimestamp = System . currentTimeMillis ( ) ;
audioBroadcastStream . start ( ) ;
- processAudioData = true ;
-
- audioDataProcessor = new Runnable ( ) {
- public void run ( ) {
- processAudioData ( ) ;
- }
- }... | use one thread to process rtp packets |
<nb> public class CamelContextFactoryBeanTest extends TestCase {
assertTrue ( modelJAXBContextFactory instanceof CustomModelJAXBContextFactory ) ;
}
- private static class CustomModelJAXBContextFactory extends DefaultModelJAXBContextFactory { }
+ private static class CustomModelJAXBContextFactory extends Defa... | Fixed the CS errors of camel spring and camel test blueprint |
<nb> package NAMESPACE ;
import static NAMESPACE ;
import static NAMESPACE ;
import static NAMESPACE ;
- import static NAMESPACE ;
import static NAMESPACE ;
import static NAMESPACE ;
import NAMESPACE ;
<nb>
package NAMESPACE ;
+ import static NAMESPACE ;
+ import static NAMESPACE ;
+ import st... | Remove unused imports |
<nb>
package NAMESPACE ;
- import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
<nb> import NAMESPACE ;
COMMENT
COMMENT
COMMENT
- @ vertxgen
public class PumpImpl < T > implements Pump {
private final ReadStream < T > readStream ; | Remove VertxGen on PumpImpl |
<nb> public class TestBeeLineWithArgs {
@ beforeclass
public static void preTests ( ) throws Exception {
HiveConf hiveConf = new HiveConf ( ) ;
+ SINGLE
+ hiveConf . setVar ( HiveConf . ConfVars . HIVE_LOCK_MANAGER , STRING0 ) ;
+
SINGLE
SINGLE
<nb> public class TestBeeLineWithArgs {
argList . add... | Investigate TestBeeLineWithArgs Jason Dere via Ashutosh Chauhan |
<nb> public class NotificationsUtils {
spannableStringBuilder . insert ( index , imagePlaceholder ) ;
index += imagePlaceholder . length ( ) - NUMBER0 ;
- spannableStringBuilder . setSpan ( noteImageSpan , index , index + NUMBER0 , Spannable . SPAN_INCLUSIVE_INCLUSIVE ) ;
+ spannableStringBuilder . setSpan ( ... | Matched up span exclusion types |
<nb> public abstract class PredictionContext implements Iterable < SingletonPredictionC
@ notnull PredictionContextCache contextCache ,
boolean rootIsWildcard )
{
- if ( ( a == null && b == null ) || a . equals ( b ) ) return a ; SINGLE
+ if ( ( a == null && b == null ) || a == b || a . equals ( b ) ) return ... | reduces a few equals calls |
<nb> package NAMESPACE ;
public class CuratorServiceUtils
{
- public static String makeCanonicalServiceName ( String serviceName ) {
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT... | make method protected to prevent accidental usage |
<nb> public class DBMaker {
protected boolean _syncOnCommitDisabled = false ;
+ protected boolean _snapshotDisabled = false ;
+
protected int _rafMode = NUMBER0 ;
protected boolean _appendStorage ;
<nb> public class DBMaker {
return this ;
}
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ CO... | Add DBMaker snapshotDisable option |
<nb> public class TagViewFragment extends TaskListFragment {
private Filter originalFilter ;
- private boolean justDeleted = false ;
+ protected boolean justDeleted = false ;
SINGLE
<nb> public class SubtasksTagListFragment extends TagViewFragment {
@ override
public void onResume ( ) {
super . ... | Fixed a crash when deleting list from list settings page |
<nb> import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
+ import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
<nb> public class RoutingContext implements Cloneable {
public final Map < AgencyAndId , Set < ServiceDate > > serviceDatesByServiceId = new Ha... | add timetable snapshot to routing context |
<nb> public abstract class MonitoredProcess implements ProcessMXBean {
public void run ( ) {
long time = System . currentTimeMillis ( ) ;
if ( time - lastPing > getTimeout ( ) ) {
- LoggerFactory . getLogger ( getClass ( ) ) . info ( String . format (
- STRING0 , getTimeout ( ) / NUMBER0 ) ) ;
if ( isMonito... | Display log on shutting down only in isMonitored mode |
<nb> public class FileBasedIndexImpl extends FileBasedIndex {
removeFileDataFromIndices ( ContainerUtil . intersection ( nontrivialFileIndexedStates , myRequiringContentIndices ) , file ) ;
}
else {
- doIndexFileContent ( project , fileContent ) ;
+ try {
+ doIndexFileContent ( project , fileContent ) ;
+... | PCE from running invalidation tasks should reschedule file processing |
<nb> import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
+ import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
<nb> public class StubZMessagingApiStore implements IZMessagingApiStore {
public ConnectionIndicator getConnectionIndicator ( ) {
return null... | Add getUserNames method to StubZMessagingApiStore |
<nb> import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
+ import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
<nb> public class NetworkDispatcher extends SimpleChannelInboundHandler < Packet > imple
NBTTagCompound playerNBT = scm . getPlayerNBT ( player... | Fix Client Login Issue when logging into a non existent dimension |
<nb> public class TestCatalogService extends CatalogTestSuiteNoDB {
final DefaultCatalogService service = new DefaultCatalogService ( new CatalogConfig ( ) {
@ override
public String getCatalogURI ( ) {
- return STRING0 ;
+ return STRING1 ;
}
} , tenantInternalApi , catalogCache , cacheInvalidationCallb... | fixing URI to have this test running |
<nb> package NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
+ import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
<nb> public class CUDAContext implements Context {
}
public CUDAContext ( GpuDevice device ) {
- exec = Executors . newCachedThreadPool ( ) ;
+ exec = Ex... | ThreadPool now uses daemon threads in CUDAContext |
<nb> package NAMESPACE ;
public enum AmenityType {
SINGLE
+ EMERGENCY ( STRING0 ) , SINGLE
+ HEALTHCARE ( STRING1 ) , SINGLE
+
TRANSPORTATION ( STRING1 ) , SINGLE
BARRIER ( STRING2 ) , SINGLE
- HEALTHCARE ( STRING1 ) , SINGLE
- EMERGENCY ( STRING0 ) , SINGLE
-
TOURISM ( STRING3 ) , SINGLE
EN... | put Emergency first |
<nb> public class CliClient
opts . append ( STRING0 ) ;
writeAttrRaw ( sb , false , STRING1 , opts . toString ( ) ) ;
}
+
+ writeAttr ( sb , false , STRING2 , ksDef . durable_writes ) ;
+
sb . append ( STRING3 + NEWLINE ) ;
sb . append ( NEWLINE ) ; | Fix missing fields in CLI show schema output |
<nb> class ZLColorPreference extends DialogPreference {
private SeekBar createSlider ( View view , int id , int value , String resourceKey ) {
final SeekBar slider = ( SeekBar ) view . findViewById ( id ) ;
- slider . setProgress ( value ) ;
slider . setProgressDrawable ( new SeekBarDrawable (
slider . getP... | fixed seek bar start view |
<nb> public class IndexedSet < T > implements Iterable < T > {
}
COMMENT
- COMMENT
- COMMENT
- COMMENT
+ COMMENT
COMMENT
public int size ( ) {
synchronized ( mLock ) { | Make getter s comment simpler |
<nb> public class LocalStore extends Store implements Serializable
@ override
public boolean create ( FolderType type ) throws MessagingException
{
- if ( exists ( ) )
- {
- throw new MessagingException ( STRING0 + mName + STRING1 ) ;
- }
- database . execute ( false , new DbCallback < Void > ( )
- { ... | remove a duplicate codepath for folder insert |
<nb>
package NAMESPACE ;
import NAMESPACE ;
+ import NAMESPACE ;
+ import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
<nb> public class GradleExecutionHelper {
}
if ( ttl > NUMBER0 && connector instanceof DefaultGradleConnector ) {
+
+ SINGLE
+ final Application ap... | do not spawn gradle daemons during test execution |
<nb> public interface OauthDataSource {
this . oauthClientId = oauthClientId ;
}
+ public String getClientId ( ) {
+ return oauthClientId ;
+ }
+
+ public void setClientId ( String oauthClientId ) {
+ this . oauthClientId = oauthClientId ;
+ }
+
public String getAccessToken ( ) {
return access... | Add clientId related methods |
<nb> import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
- import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
<nb> public class EmbeddedDrawerActivity extends AppCompatActivity {
. withSavedInstance ( savedInstanceState )
. build ( ) ;
- FrameLayout frameLayout = ( ... | clean up new EmbeddedDrawerActivity |
<nb> public class GoEnvironmentGoPathModificationTracker {
if ( goPath != null ) {
String home = SystemProperties . getUserHome ( ) ;
for ( String s : StringUtil . split ( goPath , File . pathSeparator ) ) {
- if ( home != null ) {
- pathsToTrack . add ( s . replaceAll ( STRING0 , home ) ) ;
+ if ( s . cont... | Do not ignore paths without HOME variable if home is not defined |
<nb> public class TvdbTools {
Show result = new Show ( ) ;
result . tvdb_id = showTvdbId ;
SINGLE
- result . title = series . seriesName ;
+ result . title = series . seriesName != null ? series . seriesName . trim ( ) : null ;
result . network = series . network ;
result . content_rating = series . ratin... | Trim fetched show titles |
<nb> import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
- import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ; | removed unused import |
<nb> public class ProfileRouter {
rr . setRoutingContext ( graph ) ;
SINGLE
rr . setBatch ( true ) ;
+ rr . setWalkSpeed ( request . walkSpeed ) ;
SINGLE
int worstElapsedTime = request . accessTime * NUMBER0 ; SINGLE
if ( back ) worstElapsedTime *= - NUMBER1 ;
<nb> public class ProfileRouter {
SINGLE ... | apply walk and bike speeds |
<nb> public class CommentActions {
COMMENT
COMMENT
COMMENT
- public enum ChangedFrom { COMMENT_DETAIL }
public enum ChangeType { EDITED , REPLIED }
public interface OnCommentChangeListener {
void onCommentChanged ( ChangeType changeType ) ; | Remove unused enum |
<nb> import static NAMESPACE ;
import static NAMESPACE ;
import static NAMESPACE ;
import static NAMESPACE ;
- import static NAMESPACE ;
import static NAMESPACE ;
import static NAMESPACE ;
<nb> public class TargetActionTest {
}
} ;
Picasso picasso = mock ( Picasso . class ) ;
+
TargetAction tr... | remove weird matcher abuse |
<nb> public class HeadersBodyParser extends BodyParser
{
return notifyConnectionFailure ( ErrorCode . PROTOCOL_ERROR , STRING0 ) ;
}
+
+ SINGLE
+ if ( ! hasFlag ( Flag . END_HEADERS ) )
+ {
+ return notifyConnectionFailure ( ErrorCode . INTERNAL_ERROR , STRING1 ) ;
+ }
+
length = getBodyLength ( )... | Closing the connection if frames that carry headers don t have the |
<nb> public class AioEventLoop extends MultithreadEventLoop {
return ch ;
}
}
- if ( f . getType ( ) == Object . class ) {
+ if ( AbstractAioChannel . class . isAssignableFrom ( f . getType ( ) ) ) {
f . setAccessible ( true ) ;
- Object candidate = f . get ( command ) ;
- if ( candidate instanceof Abst... | Don t call Field get |
<nb> public class ProjectCommand extends AbstractCommandRunner < ProjectCommandOptions >
return buildTargets ;
}
- private ActionGraphs createPartialGraphs ( ProjectCommandOptions options )
+ private ActionGraphs createPartialGraphs ( final ProjectCommandOptions options )
throws BuildFileParseException , Bu... | Fix Xcode project generation always generating all projects and workspaces |
<nb> public class Morphia {
public Datastore createDatastore ( Mongo mon , String dbName , String user , char [ ] pw ) {
return new DatastoreImpl ( this , mon , dbName , user , pw ) ;
}
+
+ public Datastore createDatastore ( Mongo mongo , String dbName ) {
+ return createDatastore ( mongo , dbName , null , ... | Added back removed method |
<nb> public class Term extends Activity {
super . onPause ( ) ;
mViewFlipper . pauseCurrentView ( ) ;
+
+ COMMENT
+ Otherwise , the soft keyboard could cover up whatever activity takes
+ COMMENT
+ final IBinder token = mViewFlipper . getWindowToken ( ) ;
+ new Thread ( ) {
+ @ override
+ public vo... | Hide the soft keyboard when pausing the activity |
<nb> public interface PConstants {
static final int DISABLE_KEY_REPEAT = NUMBER0 ;
static final int ENABLE_KEY_REPEAT = - NUMBER0 ;
- static final int HINT_COUNT = NUMBER1 ;
+ static final int DISABLE_ASYNC_SAVEFRAME = NUMBER1 ;
+ static final int ENABLE_ASYNC_SAVEFRAME = - NUMBER1 ;
+
+ static final in... | Add disable async saving hint |
<nb> public class ProfileData {
for ( int i = NUMBER0 ; i < nTrips ; ++ i ) {
TripTimes tt = ttp . getTripTimes ( i ) ;
int t0 = tt . getDepartureTime ( NUMBER0 ) ; SINGLE
- for ( int hop = NUMBER0 ; hop < nStops - NUMBER1 ; ++ hop ) { SINGLE
+ for ( int stop = NUMBER1 ; stop < nStops ; ++ stop ) { SINGLE
S... | fix broken travel time calculation hops vs stops |
<nb> public class GtasksLoginActivity extends ListActivity {
@ override
public void run ( ) {
try {
- Bundle bundle = future . getResult ( NUMBER0 , TimeUnit . SECONDS ) ;
+ Bundle bundle = future . getResult ( NUMBER1 , TimeUnit . SECONDS ) ;
if ( bundle . containsKey ( AccountManager . KEY_INTENT ) ) {
... | Tweaked gtasks auth timeout and logging |
<nb> public class AccessibilityManagerService extends IAccessibilityManager . Stub {
List < ResolveInfo > installedServices = mPackageManager . queryIntentServicesAsUser (
new Intent ( AccessibilityService . SERVICE_INTERFACE ) ,
- PackageManager . GET_SERVICES | PackageManager . GET_META_DATA ,
+ PackageMana... | Make talkback or other accessibility services updateable from playstore |
<nb> public abstract class TvInputService extends Service {
}
COMMENT
- COMMENT
- COMMENT
- COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
COMMENT
COMMENT
COMMENT
<nb> public abstract class TvInputService extends Service {
public abstract void onSetStreamVolume ( f... | Improve javadoc for onTune and notifyVideoAvailable |
<nb> public class AlgorithmOptions {
return traversalMode ;
}
+ public boolean hasWeighting ( ) {
+ return weighting != null ;
+ }
+
public Weighting getWeighting ( ) {
assertNotNull ( weighting , STRING0 ) ;
return weighting ;
<nb> public class AlgorithmOptions {
public Builder algorithm ( Stri... | added method to AlgorithmOptions |
<nb> public class SnackBar {
}
public SnackBar show ( int message , short duration ) {
- show ( message , duration ) ;
+ show ( message , NUMBER0 , duration ) ;
return this ;
} | Fixed no action button with resource string bug |
<nb> class SitePickerAdapter extends RecyclerView . Adapter < SitePickerAdapter . SiteViewH
public void onBindViewHolder ( final SiteViewHolder holder , int position ) {
SiteRecord site = getItem ( position ) ;
- holder . txtTitle . setText ( site . isRecentlyUsed + STRING0 + site . lastPickedTimeStamp + STRING... | Removed debug text from title |
<nb>
package NAMESPACE ;
+ import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
<nb> import NAMESPACE ;
COMMENT
COMMENT
COMMENT
- public class DefaultOAuth2ClientContext implements OAuth2ClientContext {
+ public class DefaultOAuth2ClientContext implements OAuth2ClientContext , Serializable {... | add Serializable to DefaultOAuth2ClientContext |
<nb> public class WindowManagerService extends IWindowManager . Stub
boolean configChanged ;
boolean surfaceChanged = false ;
boolean dragResizing = false ;
- boolean animating ;
boolean hasStatusBarPermission =
mContext . checkCallingOrSelfPermission ( android . Manifest . permission . STATUS_BAR )
== Pa... | Don t freeze the screen when resizing task or stack |
<nb> public final class TreeWalker
final String name = aChildConf . getName ( ) ;
final Object module = mModuleFactory . createModule ( name ) ;
if ( ! ( module instanceof Check ) ) {
- throw new CheckstyleException ( name + STRING0 ) ;
+ throw new CheckstyleException (
+ STRING1 + name ) ;
}
final Chec... | improved error message thanks to Paul Roebuck for complaining about the old one |
<nb> class ConnectionHandler implements MessageWriteTarget {
SINGLE
SINGLE
log . error ( STRING0 , e ) ;
- if ( handler != null )
- handler . closeConnection ( ) ;
+ handler . closeConnection ( ) ;
}
}
} | Remove a always true if condition |
<nb> public final class SQLiteDebug {
COMMENT
COMMENT
- COMMENT
- COMMENT
COMMENT
public static class DbStats {
COMMENT | remove myname accidentally included in one of the files |
<nb> public class Json {
return String . valueOf ( object ) ;
}
- private Object newInstance ( Class type ) {
+ protected Object newInstance ( Class type ) {
try {
return ClassReflection . newInstance ( type ) ;
} catch ( Exception ex ) { | Changed newInstance to protected in Json |
<nb>
COMMENT
- COMMENT
+ COMMENT
COMMENT
COMMENT
COMMENT
<nb> public class HiddenHttpMethodFilter extends OncePerRequestFilter {
this . methodParam = methodParam ;
}
+ @ override
protected void doFilterInternal ( HttpServletRequest request , HttpServletResponse response , FilterChain filterChain... | Added Override annotations |
<nb> import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
+ import NAMESPACE ;
+ import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
import NAMESPACE ;
<nb> public class ZincScalaCompiler implements Compiler < ScalaJavaJointCompileSpec > , S
private static final Logger LOGGER = Logging . ge... | added Java version check to ZincScalaComiler |
<nb> public class PTBTokenizerTest extends TestCase {
STRING0 ,
STRING1 ,
STRING2 ,
- STRING3
+ STRING3 ,
+ STRING4 ,
} ;
private final String [ ] [ ] ptbGold = {
<nb> public class PTBTokenizerTest extends TestCase {
{ STRING5 , STRING6 , STRING7 , STRING8 , STRING9 , STRING10 } ,
{ STRING11 , S... | Add Yahoo and lowercase v for legal cases |
<nb> public abstract class AbstractReplicatedMap < K , V >
Member [ ] members = mapMembers . keySet ( ) . toArray ( new Member [ mapMembers . size ( ) ] ) ;
long now = System . currentTimeMillis ( ) ;
for ( Member member : members ) {
- long access = mapMembers . get ( member ) ;
+ long access = mapMembers . ... | Fix unboxing warning |
<nb> public class MetaDataIndexUpgradeService extends AbstractComponent {
} else if ( indexMetaData . getCreationVersion ( ) . onOrAfter ( Version . V_2_0_0_beta1 ) ) {
if ( indexMetaData . getSettings ( ) . get ( IndexMetaData . SETTING_LEGACY_ROUTING_HASH_FUNCTION ) != null
|| indexMetaData . getSettings ( ) . ... | Add index name to the upgrade exception |
<nb> public class LocalMiniDFSCluster extends UnderFileSystemCluster {
SINGLE
SINGLE
- mDfsClient = mDfsCluster . getFileSystem ( ) ;
+ mDfsClient = ( DistributedFileSystem ) mDfsCluster . getFileSystem ( ) ;
mIsStarted = true ;
}
} | SMALLFIX Incorporated PR comment |
<nb> final class ActionBarHelperSherlock {
ViewGroup parent = ( ViewGroup ) v . getParent ( ) ;
final int upId = activity . getResources ( ) . getIdentifier ( STRING0 , STRING1 , appPackage ) ;
mUpIndicatorView = ( ImageView ) parent . findViewById ( upId ) ;
- Log . d ( TAG , STRING2 + upId ) ;
Class sherl... | Remove some logging |
<nb> public class OreDictionary
SINGLE
for ( Object obj : recipes )
{
- if ( obj instanceof ShapedRecipes )
+ if ( obj . getClass ( ) == ShapedRecipes . class )
{
ShapedRecipes recipe = ( ShapedRecipes ) obj ;
ItemStack output = recipe . getRecipeOutput ( ) ;
<nb> public class OreDictionary
recipesT... | Fixed map extension recipie |
<nb>
- package NAMESPACE ;
-
- import NAMESPACE ;
+ package NAMESPACE
COMMENT
COMMENT
COMMENT
- public abstract class MappingEntry {
- public abstract int getGeneratedColumn ( ) ;
+ interface MappingEntry {
+ val generatedColumn : Int
- public abstract int getGeneratedLine ( ) ;
+ val gene... | convert MappingEntry to kotlin |
<nb> package NAMESPACE ;
COMMENT
public class VersionAck extends EmptyMessage {
public VersionAck ( ) {
-
}
SINGLE
public VersionAck ( NetworkParameters params , byte [ ] payload ) {
-
}
-
} | Delete some whitespace |
<nb> public final class Ingest extends AbstractALSResource {
private static BufferedReader buildReader ( String contentEncoding ,
InputStream in ) throws IOException {
- switch ( contentEncoding ) {
- case STRING0 :
- in = new ZipInputStream ( in ) ;
- break ;
- case STRING1 :
- case STRING2 :
- in ... | Fix last minute problem with new IngestTest |
<nb> public interface ResultActions {
COMMENT
COMMENT
COMMENT
- COMMENT
+ COMMENT
COMMENT
COMMENT
COMMENT
<nb> public interface ResultActions {
COMMENT
MvcResult andReturn ( ) ;
- }
+ } | Fixed code example in JavaDoc |
<nb> public class EntityBinding {
return attributeBindingMap . get ( name ) ;
}
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ COMMENT
+ public int getAttributeBindingClosureSpan ( ) {
+ SINGLE
+ SINGLE
+ return attributeBindingMap . size ( ) ;
+ }
+
+ COMMENT
+ COMMEN... | Add EntityBinding getAttributeBindingClosureSpan and getAttributeBindingClosure |
<nb>
package NAMESPACE ;
COMMENT
- COMMENT
- COMMENT
+ COMMENT
+ COMMENT
COMMENT
public class SinglePresenterSelector extends PresenterSelector { | Fix javadoc for leanback |
<nb> public class MovieDetailsFragment extends Fragment {
}
} ) ;
mWatchedButton . setEnabled ( true ) ;
+ mWatchedButton . setVisibility ( View . VISIBLE ) ;
} else {
mWatchedButton . setVisibility ( View . GONE ) ;
} | Correctly show watched button after adding movie |
<nb> public class TestTextSearching extends TestBase {
Assert . assertEquals ( STRING0 , good . get ( NUMBER0 ) . value ) ;
Assert . assertEquals ( STRING1 , good . get ( NUMBER1 ) . value ) ;
- Assert . assertEquals ( NUMBER2 , getDs ( ) . createQuery ( Greeting . class )
- . search ( STRING2 , STRING3 )
-... | remove invalid test |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.