id int64 1 49k | buggy stringlengths 34 37.5k | fixed stringlengths 2 37k |
|---|---|---|
39,101 | original = TFSContentRevision.createRenameRevision(project, context, localPath,
SystemHelper.toInt(baseVersion.getValue(), 1), originalChange.getDate(), mergeConflict.getOldPath()).getContent();
</BUG>
serverChanges = TFSContentRevision.createRenameRevision(project, context, localPath,
<BUG>getMergeFromVersion(mergeCon... | SystemHelper.toInt(baseVersion.getValue(), 1), originalChange.getDate(), sourcePath).getContent();
getMergeFromVersion(mergeConflict), originalChange.getDate(), sourcePath).getContent();
|
39,102 | package com.microsoft.alm.plugin.external.models;
public class MergeConflict extends RenameConflict {
private final MergeMapping mapping;
public MergeConflict(final String localPath, final MergeMapping mapping) {
<BUG>super(localPath, mapping.getToServerItem(), mapping.getFromServerItem(), ConflictType.MERGE);
</BUG>
t... | super(localPath, mapping.getFromServerItem(), mapping.getToServerItem(), ConflictType.MERGE);
|
39,103 | import com.intellij.openapi.vfs.VirtualFileManager;
import com.intellij.openapi.vfs.newvfs.RefreshQueue;
import com.intellij.ui.GuiUtils;
import com.intellij.util.io.ReadOnlyAttributeUtil;
import com.microsoft.alm.common.utils.ArgumentHelper;
<BUG>import com.microsoft.alm.plugin.idea.tfvc.exceptions.TfsException;
impor... | import org.apache.commons.lang.StringUtils;
import org.jetbrains.annotations.NotNull;
|
39,104 | import java.util.List;
public class TfsFileUtil {
public static final Logger logger = LoggerFactory.getLogger(TfsFileUtil.class);
public interface ContentWriter {
void write(OutputStream outputStream) throws TfsException;
<BUG>}
public static List<FilePath> getFilePaths(@NotNull final VirtualFile[] files) {</BUG>
retur... | public static boolean isServerItem(final String itemPath) {
return StringUtils.startsWithIgnoreCase(itemPath, "$/");
public static List<FilePath> getFilePaths(@NotNull final VirtualFile[] files) {
|
39,105 | package org.jboss.as.patching;
import org.jboss.as.controller.OperationFailedException;
import org.jboss.as.patching.runner.PatchingException;
import org.jboss.logging.Messages;
import org.jboss.logging.annotations.Message;
<BUG>import org.jboss.logging.annotations.MessageBundle;
import java.io.IOException;</BUG>
impor... | import org.jboss.logging.annotations.Cause;
import java.io.IOException;
|
39,106 | }else if(programsSelected.size() == 1){
lytProgsPanel.setVisibility(View.VISIBLE);
lytProg2MAHAdsExtDlg.setVisibility(View.GONE);
prog1 = programsSelected.get(0);
((TextView)view.findViewById(R.id.tvProg1NameMAHAdsExtDlg)).setText(prog1.getName());
<BUG>if (prog1.getImg() != null && !prog1.getImg().trim().isEmpty()) {
... | Picasso.with(view.getContext())
.load(MAHAdsController.urlRootOnServer + prog1.getImg())
.placeholder(R.drawable.img_place_holder_normal)
.error(R.drawable.img_not_found)
.into((ImageView) view.findViewById(R.id.ivProg1ImgMAHAds));
AngledLinearLayout prog1LytNewText = (AngledLinearLayout)view.findViewById(R.id.lytProg1... |
39,107 | else if (t == ANY_CYPHER_OPTION) {
r = AnyCypherOption(b, 0);
}
else if (t == ANY_FUNCTION_INVOCATION) {
r = AnyFunctionInvocation(b, 0);
<BUG>}
else if (t == BULK_IMPORT_QUERY) {</BUG>
r = BulkImportQuery(b, 0);
}
else if (t == CALL) {
| else if (t == ARRAY) {
r = Array(b, 0);
else if (t == BULK_IMPORT_QUERY) {
|
39,108 | if (!r) r = MapLiteral(b, l + 1);
if (!r) r = MapProjection(b, l + 1);
if (!r) r = CountStar(b, l + 1);
if (!r) r = ListComprehension(b, l + 1);
if (!r) r = PatternComprehension(b, l + 1);
<BUG>if (!r) r = Expression1_12(b, l + 1);
if (!r) r = FilterFunctionInvocation(b, l + 1);</BUG>
if (!r) r = ExtractFunctionInvocat... | if (!r) r = Array(b, l + 1);
if (!r) r = FilterFunctionInvocation(b, l + 1);
|
39,109 | import java.awt.event.ActionListener;
import javax.swing.BorderFactory;
import javax.swing.Box;
import javax.swing.JCheckBox;
import javax.swing.JPanel;
<BUG>import org.apache.jmeter.assertions.XPathAssertion;
import org.apache.jmeter.util.JMeterUtils;</BUG>
public class XMLConfPanel extends JPanel {
private JCheckBox ... | import org.apache.jmeter.extractor.XPathExtractor;
import org.apache.jmeter.util.JMeterUtils;
|
39,110 | private static final String TOLERANT_KEY = "XPath.tolerant"; // $NON-NLS-1$
private static final String NEGATE_KEY = "XPath.negate"; // $NON-NLS-1$
private static final String NAMESPACE_KEY = "XPath.namespace"; // $NON-NLS-1$
private static final String QUIET_KEY = "XPath.quiet"; // $NON-NLS-1$
private static final Str... | private static final String DOWNLOAD_DTDS = "XPath.download_dtds"; // $NON-NLS-1$
public static final String DEFAULT_XPATH = "/";
|
39,111 | public static final String PackageName = "app.version.package_name";
}
public static final String VERSION_FILE_NAME = "version.json";
private static final long serialVersionUID = 6662721574596241247L;
public String packageName;
<BUG>public int major = -1;
public int minor = -1;
public VERSION_STAGE stage = null;
publ... | public String major = "";
public String minor = "";
public String build = "";
|
39,112 | <BUG>package com.jfixby.cmns.db.mysql;
import com.jfixby.cmns.api.debug.Debug;</BUG>
import com.jfixby.cmns.api.log.L;
import com.jfixby.cmns.db.api.DBComponent;
import com.mysql.jdbc.jdbc2.optional.MysqlDataSource;
| import java.sql.Connection;
import java.sql.SQLException;
import com.jfixby.cmns.api.debug.Debug;
|
39,113 | }
public MySQLTable getTable (final String name) {
return new MySQLTable(this, name);
}
public MySQLConnection obtainConnection () {
<BUG>final MySQLConnection connection = new MySQLConnection(this.dataSource);
connection.open();</BUG>
return connection;
}
public void releaseConnection (final MySQLConnection connection... | public String getDBName () {
return this.dbName;
final MySQLConnection connection = new MySQLConnection(this);
connection.open();
|
39,114 | <BUG>package org.sonar.api.resources;
import com.google.common.collect.Lists;</BUG>
import org.apache.commons.io.FileUtils;
import org.apache.commons.io.FilenameUtils;
import org.apache.commons.io.filefilter.*;
| import com.google.common.base.Predicate;
import com.google.common.collect.ImmutableList;
import com.google.common.collect.Iterables;
import com.google.common.collect.Lists;
|
39,115 | <BUG>package org.sonar.batch;
import org.apache.commons.io.FileUtils;</BUG>
import org.apache.maven.project.MavenProject;
import org.sonar.api.resources.DefaultProjectFileSystem;
import org.sonar.api.resources.Languages;
| import com.google.common.collect.ImmutableList;
import com.google.common.collect.Iterables;
import org.apache.commons.io.FileUtils;
|
39,116 | <BUG>package org.voltdb.planner;
import org.voltdb.plannodes.AbstractPlanNode;</BUG>
import org.voltdb.plannodes.LimitPlanNode;
import org.voltdb.plannodes.NestLoopPlanNode;
import org.voltdb.plannodes.OrderByPlanNode;
| import org.voltdb.expressions.AbstractExpression;
import org.voltdb.expressions.TupleValueExpression;
import org.voltdb.plannodes.AbstractPlanNode;
|
39,117 | assertTrue(pn != null);
assertTrue(pn instanceof OrderByPlanNode);
OrderByPlanNode opn = (OrderByPlanNode) pn;
assertEquals(columns.length, opn.getOutputSchema().size());
for(int i = 0; i < columns.length; ++i) {
<BUG>assertEquals(columns[i], opn.getOutputSchema().getColumns().get(i).getColumnAlias());
}</BUG>
}
privat... | SchemaColumn col = opn.getOutputSchema().getColumns().get(i);
assertEquals(columns[i], col.getColumnAlias());
AbstractExpression colExpr = col.getExpression();
assertEquals(ExpressionType.VALUE_TUPLE, colExpr.getExpressionType());
assertEquals(idxs[i], ((TupleValueExpression) colExpr).getColumnIndex());
|
39,118 | package org.voltdb.planner;
import java.util.ArrayList;
<BUG>import java.util.Collections;
import java.util.HashSet;
import java.util.List;
import java.util.Set;</BUG>
import org.hsqldb_voltpatches.VoltXMLElement;
| import java.util.HashMap;
import java.util.Map;
import java.util.Set;
|
39,119 | orderbyElement = child;
}
}
ParsedSelectStmt.parseLimitAndOffset(limitElement, offsetElement, m_limitOffset);
if (orderbyElement != null) {
<BUG>parseOrderColumns(orderbyElement);
}</BUG>
if (hasLimitOrOffset()) {
ParsedSelectStmt.prepareLimitPlanNode(this, m_limitOffset);
}
| placeTVEsForOrderby();
|
39,120 | package com.projecttango.examples.java.augmentedreality;
import com.google.atap.tangoservice.Tango;
import com.google.atap.tangoservice.Tango.OnTangoUpdateListener;
import com.google.atap.tangoservice.TangoCameraIntrinsics;
import com.google.atap.tangoservice.TangoConfig;
<BUG>import com.google.atap.tangoservice.TangoC... | import com.google.atap.tangoservice.TangoErrorException;
import com.google.atap.tangoservice.TangoEvent;
|
39,121 | super.onResume();
if (!mIsConnected) {
mTango = new Tango(AugmentedRealityActivity.this, new Runnable() {
@Override
public void run() {
<BUG>try {
connectTango();</BUG>
setupRenderer();
mIsConnected = true;
} catch (TangoOutOfDateException e) {
| TangoSupport.initialize();
connectTango();
|
39,122 | if (lastFramePose.statusCode == TangoPoseData.POSE_VALID) {
mRenderer.updateRenderCameraPose(lastFramePose, mExtrinsics);
mCameraPoseTimestamp = lastFramePose.timestamp;</BUG>
} else {
<BUG>Log.w(TAG, "Can't get device pose at time: " + mRgbTimestampGlThread);
}</BUG>
}
}
}
@Override
| mRenderer.updateRenderCameraPose(lastFramePose);
mCameraPoseTimestamp = lastFramePose.timestamp;
Log.w(TAG, "Can't get device pose at time: " +
|
39,123 | import org.rajawali3d.materials.Material;
import org.rajawali3d.materials.methods.DiffuseMethod;
import org.rajawali3d.materials.textures.ATexture;
import org.rajawali3d.materials.textures.StreamingTexture;
import org.rajawali3d.materials.textures.Texture;
<BUG>import org.rajawali3d.math.Matrix4;
import org.rajawali3d.... | import org.rajawali3d.math.Quaternion;
import org.rajawali3d.math.vector.Vector3;
|
39,124 | translationMoon.setRepeatMode(Animation.RepeatMode.INFINITE);
translationMoon.setTransformable3D(moon);
getCurrentScene().registerAnimation(translationMoon);
translationMoon.play();
}
<BUG>public void updateRenderCameraPose(TangoPoseData devicePose, DeviceExtrinsics extrinsics) {
Pose cameraPose = ScenePoseCalculator.t... | public void updateRenderCameraPose(TangoPoseData cameraPose) {
float[] rotation = cameraPose.getRotationAsFloats();
float[] translation = cameraPose.getTranslationAsFloats();
Quaternion quaternion = new Quaternion(rotation[3], rotation[0], rotation[1], rotation[2]);
getCurrentCamera().setRotation(quaternion.conjugate()... |
39,125 | package com.projecttango.examples.java.helloareadescription;
import com.google.atap.tangoservice.Tango;
<BUG>import com.google.atap.tangoservice.Tango.OnTangoUpdateListener;
import com.google.atap.tangoservice.TangoConfig;</BUG>
import com.google.atap.tangoservice.TangoCoordinateFramePair;
import com.google.atap.tangos... | import com.google.atap.tangoservice.TangoAreaDescriptionMetaData;
import com.google.atap.tangoservice.TangoConfig;
|
39,126 | } else {
updateMemo();
callback.updateMemo();
}
dismiss();
<BUG>}else{
</BUG>
Toast.makeText(getActivity(), getString(R.string.toast_memo_empty), Toast.LENGTH_SHORT).show();
}
}
| [DELETED] |
39,127 | }
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_memo);
<BUG>ChinaPhoneHelper.setStatusBar(this,true);
</BUG>
topicId = getIntent().getLongExtra("topicId", -1);
if (topicId == -1) {
finish();
| ChinaPhoneHelper.setStatusBar(this, true);
|
39,128 | MemoEntry.COLUMN_REF_TOPIC__ID + " = ?"
, new String[]{String.valueOf(topicId)});
}
public Cursor selectMemo(long topicId) {
Cursor c = db.query(MemoEntry.TABLE_NAME, null, MemoEntry.COLUMN_REF_TOPIC__ID + " = ?", new String[]{String.valueOf(topicId)}, null, null,
<BUG>MemoEntry._ID + " DESC", null);
</BUG>
if (c != nu... | MemoEntry.COLUMN_ORDER + " ASC", null);
|
39,129 | MemoEntry._ID + " = ?",
new String[]{String.valueOf(memoId)});
}
public long updateMemoContent(long memoId, String memoContent) {
ContentValues values = new ContentValues();
<BUG>values.put(MemoEntry.COLUMN_CONTENT, memoContent);
return db.update(</BUG>
MemoEntry.TABLE_NAME,
values,
MemoEntry._ID + " = ?",
| return db.update(
|
39,130 | import android.widget.RelativeLayout;
import android.widget.TextView;
import com.kiminonawa.mydiary.R;
import com.kiminonawa.mydiary.db.DBManager;
import com.kiminonawa.mydiary.shared.EditMode;
<BUG>import com.kiminonawa.mydiary.shared.ThemeManager;
import java.util.List;
public class MemoAdapter extends RecyclerView.A... | import com.marshalchen.ultimaterecyclerview.dragsortadapter.DragSortAdapter;
public class MemoAdapter extends DragSortAdapter<DragSortAdapter.ViewHolder> implements EditMode {
|
39,131 | private DBManager dbManager;
private boolean isEditMode = false;
private EditMemoDialogFragment.MemoCallback callback;
private static final int TYPE_HEADER = 0;
private static final int TYPE_ITEM = 1;
<BUG>public MemoAdapter(FragmentActivity activity, long topicId, List<MemoEntity> memoList, DBManager dbManager, EditMe... | public MemoAdapter(FragmentActivity activity, long topicId, List<MemoEntity> memoList, DBManager dbManager, EditMemoDialogFragment.MemoCallback callback, RecyclerView recyclerView) {
super(recyclerView);
this.mActivity = activity;
|
39,132 | this.memoList = memoList;
this.dbManager = dbManager;
this.callback = callback;
}
@Override
<BUG>public RecyclerView.ViewHolder onCreateViewHolder(ViewGroup parent, int viewType) {
</BUG>
View view;
if (isEditMode) {
if (viewType == TYPE_HEADER) {
| public DragSortAdapter.ViewHolder onCreateViewHolder(ViewGroup parent, int viewType) {
|
39,133 | editMemoDialogFragment.show(mActivity.getSupportFragmentManager(), "editMemoDialogFragment");
}
});
}
}
<BUG>protected class MemoViewHolder extends RecyclerView.ViewHolder implements View.OnClickListener {
private View rootView;
private TextView TV_memo_item_content;</BUG>
private ImageView IV_memo_item_delete;
| protected class MemoViewHolder extends DragSortAdapter.ViewHolder implements View.OnClickListener, View.OnLongClickListener {
private ImageView IV_memo_item_dot;
private TextView TV_memo_item_content;
|
39,134 | package org.neo4j.shell.kernel.apps;
import java.rmi.RemoteException;
import java.util.ArrayList;
<BUG>import java.util.Collection;
import java.util.List;</BUG>
import java.util.TreeSet;
import org.neo4j.graphdb.Node;
import org.neo4j.graphdb.NotFoundException;
| import java.util.Collections;
import java.util.List;
|
39,135 | maybeAddCompletionCandidate( result, "" + rel.getStartNode().getId(), lastWord );
maybeAddCompletionCandidate( result, "" + rel.getEndNode().getId(), lastWord );
}
return new ArrayList<String>( result );
}
<BUG>catch ( ShellException e )
{
e.printStackTrace();
return super.completionCandidates( partOfLine, session );
}... | [DELETED] |
39,136 | import org.neo4j.shell.ShellException;
@Service.Implementation( App.class )
public class Rmrel extends GraphDatabaseApp
{
public Rmrel()
<BUG>{
this.addOptionDefinition( "d", new OptionDefinition( OptionValueType.NONE,</BUG>
"Must be supplied if the affected other node gets decoupled " +
"after this operation so that i... | this.addOptionDefinition( "e", new OptionDefinition( OptionValueType.NONE,
"Ensure that nodes doesn't get disconnected from the rest of the graph" ) );
this.addOptionDefinition( "d", new OptionDefinition( OptionValueType.NONE,
|
39,137 | currentNode + " to be decoupled (no relationships left)" );
}
Node otherNode = rel.getOtherNode( currentNode );
if ( !otherNode.getRelationships().iterator().hasNext() )
{
<BUG>boolean deleteOtherNodeWhenEmpty = parser.options().containsKey(
"d" );</BUG>
if ( !deleteOtherNodeWhenEmpty )
{
| boolean deleteOtherNodeWhenEmpty = parser.options().containsKey( "d" );
|
39,138 | " -d (for delete-when-decoupled) so that the other node " +
"(" + otherNode + ") may be deleted" );
}
otherNode.delete();
}
<BUG>else
{</BUG>
if ( !this.hasPathToRefNode( otherNode ) )
{
throw new ShellException( "It would result in " + otherNode +
| else if ( parser.options().containsKey( "e" ) )
|
39,139 | public static boolean isCurrent( Session session, NodeOrRelationship thing )
{
String currentThing = ( String ) safeGet( session, CURRENT_KEY );
return currentThing != null && currentThing.equals(
thing.getTypedId().toString() );
<BUG>}
protected static void setCurrent( Session session,</BUG>
NodeOrRelationship current... | protected static void clearCurrent( Session session )
safeSet( session, CURRENT_KEY, new TypedId( NodeOrRelationship.TYPE_NODE, 0 ).toString() );
protected static void setCurrent( Session session,
|
39,140 | private static String getDisplayNameForCurrent(
GraphDatabaseShellServer server, Session session )
throws ShellException
{
NodeOrRelationship current = getCurrent( server, session );
<BUG>return current.isNode() ? "(me)" : "<me>";
}</BUG>
public static String getDisplayName( GraphDatabaseShellServer server,
Session ses... | }
public static String getDisplayNameForNonExistent()
return "(?)";
}
|
39,141 | customTokens.put("%%mlFinalForestsPerHost%%", hubConfig.finalForestsPerHost.toString());
customTokens.put("%%mlTraceAppserverName%%", hubConfig.traceHttpName);
customTokens.put("%%mlTracePort%%", hubConfig.tracePort.toString());
customTokens.put("%%mlTraceDbName%%", hubConfig.traceDbName);
customTokens.put("%%mlTraceFo... | customTokens.put("%%mlTriggersDbName%%", hubConfig.triggersDbName);
customTokens.put("%%mlSchemasDbName%%", hubConfig.schemasDbName);
}
|
39,142 | collector.add(new ReconcilingEpfTask(taskRef, header));
} else {
throw new IllegalStateException("Unsupported Task Type");
}
} catch(RuntimeException e) {
<BUG>log.logError(e, "Loading preferences from: %s", taskRef);
}</BUG>
}
}
private static final class ReconcilingEpfTask
| } catch (IOException e) {
|
39,143 | import java.io.IOException;
import java.net.InetAddress;
import java.net.ProtocolFamily;
import java.net.StandardProtocolFamily;
import java.nio.ByteBuffer;
<BUG>import java.util.Deque;
import java.util.LinkedList;</BUG>
import java.util.concurrent.Executor;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
| [DELETED] |
39,144 | import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import com.davfx.ninio.util.SerialExecutor;
public final class RawSocket implements Connecter {
private static final Logger LOGGER = LoggerFactory.getLogger(RawSocket.class);
<BUG>public static interface Builder extends NinioBuilder<RawSocket> {
</BUG>
Builder fa... | public static interface Builder extends NinioBuilder<Connecter> {
|
39,145 | import org.gedcomx.common.ResourceReference;
import org.gedcomx.common.URI;</BUG>
import org.gedcomx.conclusion.Relationship;
import org.gedcomx.conversion.GedcomxConversionResult;
<BUG>import org.gedcomx.contributor.Address;
import org.gedcomx.contributor.Agent;</BUG>
import org.gedcomx.source.CitationField;
import or... | import org.gedcomx.common.TextValue;
import org.gedcomx.common.URI;
|
39,146 | try {
boolean sourceDescriptionHasData = false;
boolean sourceReferenceHasData = false;
SourceDescription gedxSourceDescription = new SourceDescription();
org.gedcomx.source.SourceCitation citation = new org.gedcomx.source.SourceCitation();
<BUG>citation.setCitationTemplate(new ResourceReference(URI.create("http://gedc... | citation.setCitationTemplate(new ResourceReference(URI.create("gedcom5:citation-template")));
|
39,147 | citation.setFields(new ArrayList<CitationField>());
citation.setValue("");
if (dqSource.getRef() != null) {
gedxSourceDescription.setId(dqSource.getRef() + "-" + Long.toHexString(SequentialIdentifierGenerator.getNextId()));
SourceReference componentOf = new SourceReference();
<BUG>componentOf.setSourceDescriptionURI(UR... | componentOf.setDescriptionRef(URI.create(CommonMapper.getSourceDescriptionReference(dqSource.getRef())));
|
39,148 | citation.getFields().add(field);
citation.setValue(citation.getValue() + (citation.getValue().length() > 0 ? ", " + dqSource.getDate() : dqSource.getDate()));
}
if (dqSource.getPage() != null) {
CitationField field = new CitationField();
<BUG>field.setName(URI.create("http://gedcomx.org/gedcom5-conversion-v1-SOUR-mappi... | field.setName(URI.create("gedcom5:citation-template/page"));
field.setValue(dqSource.getPage());
|
39,149 | if (dqSource.getText() != null) {
logger.warn(ConversionContext.getContext(), "GEDCOM X does not currently support text extracted from a source.");
}
ConfidenceLevel gedxConfidenceLevel = toConfidenceLevel(dqSource.getQuality());
if (gedxConfidenceLevel != null) {
<BUG>Attribution attribution = new Attribution();
attri... | [DELETED] |
39,150 | int cntMedia = dqSource.getMedia().size() + dqSource.getMediaRefs().size();
if (cntMedia > 0) {
logger.warn(ConversionContext.getContext(), "Did not process {} media items or references to media items.", cntMedia);
}
if (sourceDescriptionHasData) {
<BUG>gedxSourceDescription.setCitation(citation);
result.addSourceDesc... | gedxSourceDescription.setCitations(Arrays.asList(citation));
result.addSourceDescription(gedxSourceDescription);
sourceReferenceHasData = true;
|
39,151 | relationship.setPerson2(toReference(personId2));
return relationship;
}
public static ResourceReference toReference(String gedxPersonId) {
ResourceReference reference = new ResourceReference();
<BUG>reference.setResource( new URI(getPersonEntryName(gedxPersonId)));
</BUG>
return reference;
}
public static boolean inCan... | reference.setResource( new URI(getPersonReference(gedxPersonId)));
|
39,152 | final Pattern pattern = Pattern.compile("^\\+[\\d \\.\\(\\)\\-/]+");
return pattern.matcher(telephoneNumber).matches();
}
public static void populateAgent(Agent agent, String id, String name, org.folg.gedcom.model.Address address, String phone, String fax, String email, String www) {
agent.setId(id);
<BUG>agent.setName... | agent.setNames(Arrays.asList(new TextValue(name)));
if(address != null) {
|
39,153 | @SideOnly(Side.CLIENT)
public class GuiSeedAnalyzer extends GuiContainer {
public static final ResourceLocation texture = new ResourceLocation(Reference.MOD_ID, "textures/gui/GuiSeedAnalyzer.png");
public TileEntitySeedAnalyzer seedAnalyzer;
private boolean journalOpen;
<BUG>private GuiJournal guiJournal;
</BUG>
public... | private AgriGuiWrapper guiJournal;
|
39,154 | return;
}
ItemStack journal = seedAnalyzer.getStackInSlot(ContainerSeedAnalyzer.journalSlotId);
if(journal != null) {
journalOpen = true;
<BUG>guiJournal = new GuiJournal(journal);
</BUG>
guiJournal.setWorldAndResolution(this.mc, this.width, this.height);
}
}
| guiJournal = new AgriGuiWrapper(new GuiJournal(journal));
|
39,155 | import com.liferay.portal.kernel.cal.DayAndPosition;
import com.liferay.portal.kernel.cal.TZSRecurrence;
import com.liferay.portal.kernel.dao.orm.ActionableDynamicQuery;
import com.liferay.portal.kernel.exception.PortalException;
import com.liferay.portal.kernel.exception.SystemException;
<BUG>import com.liferay.portal... | [DELETED] |
39,156 | AssetCategoryConstants.DEFAULT_PARENT_CATEGORY_ID, name,
assetVocabulary.getVocabularyId());
if (assetCategory != null) {
return assetCategory;
}
<BUG>ServiceContext serviceContext = new ServiceContext();
serviceContext.setScopeGroupId(groupId);
serviceContext.setUserId(userId);</BUG>
return assetCategoryLocalService.a... | [DELETED] |
39,157 | long threadId, long rootMessageId)
throws PortalException, SystemException {
MBThread mbThread = mbThreadPersistence.findByPrimaryKey(threadId);
mbThread.setRootMessageId(rootMessageId);
mbThreadPersistence.update(mbThread);
<BUG>}
private static Map<Integer, Frequency> _frequencyMap =</BUG>
new HashMap<Integer, Freque... | private static final String _CALENDAR_VOCABULARY_NAME =
"Calendar Event Types";
private static Map<Integer, Frequency> _frequencyMap =
|
39,158 | } else {
updateMemo();
callback.updateMemo();
}
dismiss();
<BUG>}else{
</BUG>
Toast.makeText(getActivity(), getString(R.string.toast_memo_empty), Toast.LENGTH_SHORT).show();
}
}
| [DELETED] |
39,159 | }
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_memo);
<BUG>ChinaPhoneHelper.setStatusBar(this,true);
</BUG>
topicId = getIntent().getLongExtra("topicId", -1);
if (topicId == -1) {
finish();
| ChinaPhoneHelper.setStatusBar(this, true);
|
39,160 | MemoEntry.COLUMN_REF_TOPIC__ID + " = ?"
, new String[]{String.valueOf(topicId)});
}
public Cursor selectMemo(long topicId) {
Cursor c = db.query(MemoEntry.TABLE_NAME, null, MemoEntry.COLUMN_REF_TOPIC__ID + " = ?", new String[]{String.valueOf(topicId)}, null, null,
<BUG>MemoEntry._ID + " DESC", null);
</BUG>
if (c != nu... | MemoEntry.COLUMN_ORDER + " ASC", null);
|
39,161 | MemoEntry._ID + " = ?",
new String[]{String.valueOf(memoId)});
}
public long updateMemoContent(long memoId, String memoContent) {
ContentValues values = new ContentValues();
<BUG>values.put(MemoEntry.COLUMN_CONTENT, memoContent);
return db.update(</BUG>
MemoEntry.TABLE_NAME,
values,
MemoEntry._ID + " = ?",
| return db.update(
|
39,162 | import android.widget.RelativeLayout;
import android.widget.TextView;
import com.kiminonawa.mydiary.R;
import com.kiminonawa.mydiary.db.DBManager;
import com.kiminonawa.mydiary.shared.EditMode;
<BUG>import com.kiminonawa.mydiary.shared.ThemeManager;
import java.util.List;
public class MemoAdapter extends RecyclerView.A... | import com.marshalchen.ultimaterecyclerview.dragsortadapter.DragSortAdapter;
public class MemoAdapter extends DragSortAdapter<DragSortAdapter.ViewHolder> implements EditMode {
|
39,163 | private DBManager dbManager;
private boolean isEditMode = false;
private EditMemoDialogFragment.MemoCallback callback;
private static final int TYPE_HEADER = 0;
private static final int TYPE_ITEM = 1;
<BUG>public MemoAdapter(FragmentActivity activity, long topicId, List<MemoEntity> memoList, DBManager dbManager, EditMe... | public MemoAdapter(FragmentActivity activity, long topicId, List<MemoEntity> memoList, DBManager dbManager, EditMemoDialogFragment.MemoCallback callback, RecyclerView recyclerView) {
super(recyclerView);
this.mActivity = activity;
|
39,164 | this.memoList = memoList;
this.dbManager = dbManager;
this.callback = callback;
}
@Override
<BUG>public RecyclerView.ViewHolder onCreateViewHolder(ViewGroup parent, int viewType) {
</BUG>
View view;
if (isEditMode) {
if (viewType == TYPE_HEADER) {
| public DragSortAdapter.ViewHolder onCreateViewHolder(ViewGroup parent, int viewType) {
|
39,165 | editMemoDialogFragment.show(mActivity.getSupportFragmentManager(), "editMemoDialogFragment");
}
});
}
}
<BUG>protected class MemoViewHolder extends RecyclerView.ViewHolder implements View.OnClickListener {
private View rootView;
private TextView TV_memo_item_content;</BUG>
private ImageView IV_memo_item_delete;
| protected class MemoViewHolder extends DragSortAdapter.ViewHolder implements View.OnClickListener, View.OnLongClickListener {
private ImageView IV_memo_item_dot;
private TextView TV_memo_item_content;
|
39,166 | customTokens.put("%%mlFinalForestsPerHost%%", hubConfig.finalForestsPerHost.toString());
customTokens.put("%%mlTraceAppserverName%%", hubConfig.traceHttpName);
customTokens.put("%%mlTracePort%%", hubConfig.tracePort.toString());
customTokens.put("%%mlTraceDbName%%", hubConfig.traceDbName);
customTokens.put("%%mlTraceFo... | customTokens.put("%%mlTriggersDbName%%", hubConfig.triggersDbName);
customTokens.put("%%mlSchemasDbName%%", hubConfig.schemasDbName);
}
|
39,167 | package com.easytoolsoft.easyreport.web.controller.common;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
@Controller
@RequestMapping(value = "/error")
<BUG>public class ErrorController extends AbstractController {
@RequestMapping(value = {"/404"})</BUG>... | public class ErrorController {
@RequestMapping(value = {"/404"})
|
39,168 | import ml.puredark.hviewer.ui.activities.BaseActivity;
import ml.puredark.hviewer.ui.dataproviders.ListDataProvider;
import ml.puredark.hviewer.ui.fragments.SettingFragment;
import ml.puredark.hviewer.ui.listeners.OnItemLongClickListener;
import ml.puredark.hviewer.utils.SharedPreferencesUtil;
<BUG>import static androi... | import static ml.puredark.hviewer.R.id.container;
public class PictureViewerAdapter extends RecyclerView.Adapter<PictureViewerAdapter.PictureViewerViewHolder> {
|
39,169 | final PictureViewHolder viewHolder = new PictureViewHolder(view);
if (pictures != null && position < pictures.size()) {
final Picture picture = pictures.get(getPicturePostion(position));
if (picture.pic != null) {
loadImage(container.getContext(), picture, viewHolder);
<BUG>} else if (site.hasFlag(Site.FLAG_SINGLE_PAGE... | } else if (site.hasFlag(Site.FLAG_SINGLE_PAGE_BIG_PICTURE) && site.extraRule != null) {
if(site.extraRule.pictureRule != null && site.extraRule.pictureRule.url != null)
getPictureUrl(container.getContext(), viewHolder, picture, site, site.extraRule.pictureRule.url, site.extraRule.pictureRule.highRes);
else if(site.extr... |
39,170 | import java.util.regex.Pattern;
import butterknife.BindView;
import butterknife.ButterKnife;
import ml.puredark.hviewer.R;
import ml.puredark.hviewer.beans.Category;
<BUG>import ml.puredark.hviewer.beans.CommentRule;
import ml.puredark.hviewer.beans.Rule;</BUG>
import ml.puredark.hviewer.beans.Selector;
import ml.pured... | import ml.puredark.hviewer.beans.PictureRule;
import ml.puredark.hviewer.beans.Rule;
|
39,171 | inputGalleryRulePictureUrlReplacement.setText(site.galleryRule.pictureUrl.replacement);
}
if (site.galleryRule.pictureHighRes != null) {
inputGalleryRulePictureHighResSelector.setText(joinSelector(site.galleryRule.pictureHighRes));
inputGalleryRulePictureHighResRegex.setText(site.galleryRule.pictureHighRes.regex);
<BUG... | [DELETED] |
39,172 | inputExtraRuleCommentDatetimeReplacement.setText(site.extraRule.commentDatetime.replacement);
}
if (site.extraRule.commentContent != null) {
inputExtraRuleCommentContentSelector.setText(joinSelector(site.extraRule.commentContent));
inputExtraRuleCommentContentRegex.setText(site.extraRule.commentContent.regex);
<BUG>inp... | [DELETED] |
39,173 | lastSite.galleryRule.cover = loadSelector(inputGalleryRuleCoverSelector, inputGalleryRuleCoverRegex, inputGalleryRuleCoverReplacement);
lastSite.galleryRule.category = loadSelector(inputGalleryRuleCategorySelector, inputGalleryRuleCategoryRegex, inputGalleryRuleCategoryReplacement);
lastSite.galleryRule.datetime = load... | lastSite.galleryRule.pictureRule = (lastSite.galleryRule.pictureRule == null) ? new PictureRule() : lastSite.galleryRule.pictureRule;
lastSite.galleryRule.pictureRule.thumbnail = loadSelector(inputGalleryRulePictureThumbnailSelector, inputGalleryRulePictureThumbnailRegex, inputGalleryRulePictureThumbnailReplacement);
l... |
39,174 | lastSite.extraRule.cover = loadSelector(inputExtraRuleCoverSelector, inputExtraRuleCoverRegex, inputExtraRuleCoverReplacement);
lastSite.extraRule.category = loadSelector(inputExtraRuleCategorySelector, inputExtraRuleCategoryRegex, inputExtraRuleCategoryReplacement);
lastSite.extraRule.datetime = loadSelector(inputExtr... | lastSite.extraRule.pictureRule = (lastSite.extraRule.pictureRule == null) ? new PictureRule() : lastSite.extraRule.pictureRule;
lastSite.extraRule.pictureRule.thumbnail = loadSelector(inputExtraRulePictureThumbnailSelector, inputExtraRulePictureThumbnailRegex, inputExtraRulePictureThumbnailReplacement);
lastSite.extraR... |
39,175 | notifyItemChanged(position);
if (mItemClickListener != null)
mItemClickListener.onItemClick(v, position);
}
});
<BUG>if (tag.selected)
label.getChildAt(0).setBackgroundResource(R.color.colorPrimary);
else
label.getChildAt(0).setBackgroundResource(R.color.dimgray);</BUG>
}
| [DELETED] |
39,176 | loadPicture(picture, task, null, true);
} else if (!TextUtils.isEmpty(picture.pic) && !highRes) {
picture.retries = 0;
loadPicture(picture, task, null, false);
} else if (task.collection.site.hasFlag(Site.FLAG_SINGLE_PAGE_BIG_PICTURE)
<BUG>&& task.collection.site.extraRule != null
&& task.collection.site.extraRule.pic... | && task.collection.site.extraRule != null) {
if(task.collection.site.extraRule.pictureRule != null && task.collection.site.extraRule.pictureRule.url != null)
getPictureUrl(picture, task, task.collection.site.extraRule.pictureRule.url, task.collection.site.extraRule.pictureRule.highRes);
else if(task.collection.site.ext... |
39,177 | if (Picture.hasPicPosfix(picture.url)) {
picture.pic = picture.url;
loadPicture(picture, task, null, false);
} else
if (task.collection.site.hasFlag(Site.FLAG_JS_NEEDED_ALL)) {
<BUG>new Handler(Looper.getMainLooper()).post(()->{
</BUG>
WebView webView = new WebView(HViewerApplication.mContext);
WebSettings mWebSettings... | new Handler(Looper.getMainLooper()).post(() -> {
|
39,178 | customTokens.put("%%mlFinalForestsPerHost%%", hubConfig.finalForestsPerHost.toString());
customTokens.put("%%mlTraceAppserverName%%", hubConfig.traceHttpName);
customTokens.put("%%mlTracePort%%", hubConfig.tracePort.toString());
customTokens.put("%%mlTraceDbName%%", hubConfig.traceDbName);
customTokens.put("%%mlTraceFo... | customTokens.put("%%mlTriggersDbName%%", hubConfig.triggersDbName);
customTokens.put("%%mlSchemasDbName%%", hubConfig.schemasDbName);
}
|
39,179 | package ru.noties.debug.out;
import java.io.BufferedWriter;
import java.io.File;
import java.io.FileWriter;
import java.io.IOException;
<BUG>import java.text.DateFormat;
import java.util.Date;
import java.util.concurrent.ExecutorService;</BUG>
import java.util.concurrent.Executors;
import ru.noties.debug.Level;
| import java.text.SimpleDateFormat;
import java.util.Locale;
import java.util.concurrent.ExecutorService;
|
39,180 | File newSession() throws UnableToObtainFileException;
}
public interface OutputConverter {
String convert(Level level, Throwable throwable, String tag, String message);
class DefaultOutputConverter implements OutputConverter {
<BUG>private static final String PATTERN = "%s %s %s/%s: %s";
private final DateFormat date... | private static final String DATE_PATTERN = "dd-MM HH:mm:ss.SSS";
dateFormat = new SimpleDateFormat(DATE_PATTERN, Locale.US);
|
39,181 | private static final String ARG_SAVED_STATE = "arg.SavedState";
private ListView mListView;
private BaseStormIteratorAdapter<LogItem> mAdapter;
private int[] mSavedState;
private boolean mIsInitialLoad;
public View onCreateView(LayoutInflater inflater, ViewGroup parent, Bundle sis) {</BUG>
final View view = inflater.in... | private static final String ARG_FILTER = "arg.Filter";
private OnFilterListener mOnFilterListener;
private LogItemFilter mFilter;
public View onCreateView(LayoutInflater inflater, ViewGroup parent, Bundle sis) {
mListView.setEmptyView(view.findViewById(R.id.debug_list_view_empty_view));
mAdapter = new UIFragmentAdapter... |
39,182 | mButton.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
onButtonClick();
}
<BUG>});
content.addView(mButton);</BUG>
}
@Override
public void onActivityResumed(Activity activity) {
| if (mButton.getParent() != null) {
((ViewGroup) mButton.getParent()).removeView(mButton);
content.addView(mButton);
|
39,183 | import android.os.Bundle;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import ru.noties.debug.ui.model.LogDatabase;
<BUG>import ru.noties.debug.ui.model.LogItem;
import ru.noties.debug.ui.model.LogLoader;</BUG>
import ru.noties.storm.StormIterator;
public class UIFragment... | import ru.noties.debug.ui.model.LogItemFilter;
import ru.noties.debug.ui.model.LogLoader;
|
39,184 | package com.projecttango.examples.java.augmentedreality;
import com.google.atap.tangoservice.Tango;
import com.google.atap.tangoservice.Tango.OnTangoUpdateListener;
import com.google.atap.tangoservice.TangoCameraIntrinsics;
import com.google.atap.tangoservice.TangoConfig;
<BUG>import com.google.atap.tangoservice.TangoC... | import com.google.atap.tangoservice.TangoErrorException;
import com.google.atap.tangoservice.TangoEvent;
|
39,185 | super.onResume();
if (!mIsConnected) {
mTango = new Tango(AugmentedRealityActivity.this, new Runnable() {
@Override
public void run() {
<BUG>try {
connectTango();</BUG>
setupRenderer();
mIsConnected = true;
} catch (TangoOutOfDateException e) {
| TangoSupport.initialize();
connectTango();
|
39,186 | if (lastFramePose.statusCode == TangoPoseData.POSE_VALID) {
mRenderer.updateRenderCameraPose(lastFramePose, mExtrinsics);
mCameraPoseTimestamp = lastFramePose.timestamp;</BUG>
} else {
<BUG>Log.w(TAG, "Can't get device pose at time: " + mRgbTimestampGlThread);
}</BUG>
}
}
}
@Override
| mRenderer.updateRenderCameraPose(lastFramePose);
mCameraPoseTimestamp = lastFramePose.timestamp;
Log.w(TAG, "Can't get device pose at time: " +
|
39,187 | import org.rajawali3d.materials.Material;
import org.rajawali3d.materials.methods.DiffuseMethod;
import org.rajawali3d.materials.textures.ATexture;
import org.rajawali3d.materials.textures.StreamingTexture;
import org.rajawali3d.materials.textures.Texture;
<BUG>import org.rajawali3d.math.Matrix4;
import org.rajawali3d.... | import org.rajawali3d.math.Quaternion;
import org.rajawali3d.math.vector.Vector3;
|
39,188 | translationMoon.setRepeatMode(Animation.RepeatMode.INFINITE);
translationMoon.setTransformable3D(moon);
getCurrentScene().registerAnimation(translationMoon);
translationMoon.play();
}
<BUG>public void updateRenderCameraPose(TangoPoseData devicePose, DeviceExtrinsics extrinsics) {
Pose cameraPose = ScenePoseCalculator.t... | public void updateRenderCameraPose(TangoPoseData cameraPose) {
float[] rotation = cameraPose.getRotationAsFloats();
float[] translation = cameraPose.getTranslationAsFloats();
Quaternion quaternion = new Quaternion(rotation[3], rotation[0], rotation[1], rotation[2]);
getCurrentCamera().setRotation(quaternion.conjugate()... |
39,189 | package com.projecttango.examples.java.helloareadescription;
import com.google.atap.tangoservice.Tango;
<BUG>import com.google.atap.tangoservice.Tango.OnTangoUpdateListener;
import com.google.atap.tangoservice.TangoConfig;</BUG>
import com.google.atap.tangoservice.TangoCoordinateFramePair;
import com.google.atap.tangos... | import com.google.atap.tangoservice.TangoAreaDescriptionMetaData;
import com.google.atap.tangoservice.TangoConfig;
|
39,190 | variant = new CompletionVariant(PsiAnnotationMethod.class, position);
variant.addCompletion(PsiKeyword.DEFAULT);
registerVariant(variant);
}
{
<BUG>final CompletionVariant variant = new CompletionVariant(new OrFilter(END_OF_BLOCK, new LeftNeighbour(new TextFilter(PsiKeyword.FINAL))));
variant.includeScopeClass(PsiCodeB... | [DELETED] |
39,191 | final ElementFilter position = INSTANCEOF_PLACE;
final CompletionVariant variant = new CompletionVariant(position);
variant.includeScopeClass(PsiExpression.class, true);
variant.includeScopeClass(PsiMethod.class);
variant.addCompletion(PsiKeyword.INSTANCEOF);
<BUG>registerVariant(variant);
}
{
final CompletionVariant v... | [DELETED] |
39,192 | ));
final CompletionVariant variant = new CompletionVariant(PsiMethod.class, position);
variant.addCompletion(PsiKeyword.ELSE);
registerVariant(variant);
}
<BUG>{
final CompletionVariant variant = new CompletionVariant(INSIDE_SWITCH);
variant.includeScopeClass(PsiElement.class, true);
variant.addCompletion(PsiKeyword.C... | [DELETED] |
39,193 | @Override
public void handleInsert(InsertionContext context, LookupElement item) {
if (context.shouldAddCompletionChar()) {
return;
}
<BUG>TailType type = analyzeItem(item.getObject(), context.getFile().findElementAt(context.getStartOffset()));
if (type == TailType.NONE) {
type = tailType;
}
if (type != TailType.NONE) ... | [DELETED] |
39,194 | });
myMap.put(new ClassFilter(PsiJavaFile.class), new String[][]{
new String[]{"public"},
new String[]{"final", "abstract"}
});
<BUG>myMap.put(new OrFilter(new ClassFilter(PsiStatement.class), new ClassFilter(PsiCodeBlock.class)), new String[][]{
new String[]{"final"}
});</BUG>
myMap.put(new ClassFilter(PsiParameterLis... | myMap.put(new InterfaceFilter(), new String[][]{
new String[]{"public", "protected"},
new String[]{"static"},
|
39,195 | final List<String> ret = new ArrayList<String>();
try{
</BUG>
PsiElement scope;
<BUG>if(position == null)
scope = context.file;
else
scope = position.getParent();
final PsiModifierList list = getModifierList(position);</BUG>
scopes:
| try {
if (position == null) {
}
else {
}
final PsiModifierList list = getModifierList(position);
|
39,196 | scope = scope.getContext();
}
if (scope instanceof PsiDirectory) break;
}
}
<BUG>catch(Exception e){}
return ArrayUtil.toStringArray(ret);</BUG>
}
private static PsiModifierList getModifierList(PsiElement element)
| catch (Exception e) {
return ArrayUtil.toStringArray(ret);
|
39,197 | adapter.notifyDataSetChanged();
}
});
HashMap<String, String> deviceDataMap = new HashMap<>();
deviceDataMap.put("Time (ms)", String.valueOf(easyDeviceInfo.getTime()));
<BUG>deviceDataMap.put("Formatted Time (24Hrs)", easyDeviceInfo.getFormatedTime());
deviceDataMap.put("Language", easyDeviceInfo.getLanguage());</BUG>
... | try {
deviceDataMap.put("Language", easyDeviceInfo.getLanguage());
|
39,198 | deviceDataMap.put("Longitude", lon);
deviceDataMap.put("Fingerprint", easyDeviceInfo.getFingerprint());
deviceDataMap.put("Screen Density", easyDeviceInfo.getDensity());
deviceDataMap.put("Installer Store", easyDeviceInfo.getStore());
deviceDataMap.put("Network Available", String.valueOf(easyDeviceInfo.isNetworkAvailab... | deviceDataMap.put("Running on emulator",
deviceDataMap.put("Build Brand", easyDeviceInfo.getBuildBrand());
|
39,199 | deviceDataMap.put("Build Version Increment", easyDeviceInfo.getBuildVersionIncremental());
deviceDataMap.put("Build Version SDK", String.valueOf(easyDeviceInfo.getBuildVersionSDK()));
deviceDataMap.put("Build ID", easyDeviceInfo.getBuildID());
deviceDataMap.put("Supported ABIS", easyDeviceInfo.getStringSupportedABIS())... | } catch (Exception e) {
e.printStackTrace();
}
switch (easyDeviceInfo.getDeviceRingerMode()) {
|
39,200 | package org.elasticsearch.index.store.fs;
<BUG>import org.apache.lucene.store.Directory;
import org.apache.lucene.store.FSDirectory;
import org.apache.lucene.store.MMapDirectory;</BUG>
import org.elasticsearch.env.Environment;
| import org.apache.lucene.store.*;
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.