id
int64
1
49k
buggy
stringlengths
34
37.5k
fixed
stringlengths
2
37k
43,801
medicamento.setQuantidade(new BigDecimal("9999999.999")); return medicamento; } public static NFNotaInfoItemProdutoDeclaracaoImportacao getNFNotaInfoItemProdutoDeclaracaoImportacao() { final NFNotaInfoItemProdutoDeclaracaoImportacao declaraoImportacao = new NFNotaInfoItemProdutoDeclaracaoImportacao(); <BUG>declaraoImpo...
declaraoImportacao.setAdicoes(Collections.singletonList(FabricaDeObjetosFake.getNFNotaInfoItemProdutoDeclaracaoImportacaoAdicao()));
43,802
public static NFNotaInfoVolume getNFNotaInfoVolume() { final NFNotaInfoVolume volume = new NFNotaInfoVolume(); volume.setEspecieVolumesTransportados("3Qf46HFs7FcWlhuQqLJ96vsrgJHu6B5ZXmmwMZ1RtvQVOV4Yp6M9VNqn5Ecb"); final NFNotaInfoLacre notaInfoLacre = new NFNotaInfoLacre(); notaInfoLacre.setNumeroLacre("gvmjb9BB2cmwsLb...
volume.setLacres(Collections.singletonList(notaInfoLacre));
43,803
public void deveGerarXMLDeAcordoComOPadraoEstabelecido() { final NFLoteConsultaRetorno retorno = new NFLoteConsultaRetorno(); retorno.setAmbiente(NFAmbiente.HOMOLOGACAO); retorno.setMotivo("8CwtnC5gWwUncMBYAZl9p4fvVx8RkCH2EKx2mtUNVA5tLoJsjNWL5CJ6DXNUHTWKpPl6fMKKxA0aXBu6IfmJLIHlPxtF0oZkKrNsGyGpwKqWxvDZ9HQGqscmhtTrp5NbNz...
retorno.setProtocolos(Collections.singletonList(FabricaDeObjetosFake.getNFProtocolo()));
43,804
import org.apache.hadoop.fs.FileSystem; import org.apache.hadoop.fs.LocalFileSystem; import org.apache.hadoop.fs.Path; import org.apache.hadoop.fs.permission.FsPermission; import org.apache.hadoop.util.Progressable; <BUG>import static org.apache.hadoop.fs.s3a.S3AConstants.*; public class S3AFileSystem extends FileSyste...
import static org.apache.hadoop.fs.s3a.Constants.*; public class S3AFileSystem extends FileSystem {
43,805
public void initialize(URI name, Configuration conf) throws IOException { super.initialize(name, conf); uri = URI.create(name.getScheme() + "://" + name.getAuthority()); workingDir = new Path("/user", System.getProperty("user.name")).makeQualified(this.uri, this.getWorkingDirectory()); <BUG>String accessKey = conf.get(...
String accessKey = conf.get(NEW_ACCESS_KEY, conf.get(OLD_ACCESS_KEY, null)); String secretKey = conf.get(NEW_SECRET_KEY, conf.get(OLD_SECRET_KEY, null));
43,806
} else { accessKey = userInfo; } } AWSCredentialsProviderChain credentials = new AWSCredentialsProviderChain( <BUG>new S3ABasicAWSCredentialsProvider(accessKey, secretKey), new InstanceProfileCredentialsProvider(), new S3AAnonymousAWSCredentialsProvider() );</BUG> bucket = name.getHost();
new BasicAWSCredentialsProvider(accessKey, secretKey), new AnonymousAWSCredentialsProvider()
43,807
awsConf.setSocketTimeout(conf.getInt(SOCKET_TIMEOUT, DEFAULT_SOCKET_TIMEOUT)); </BUG> s3 = new AmazonS3Client(credentials, awsConf); <BUG>maxKeys = conf.getInt(MAX_PAGING_KEYS, DEFAULT_MAX_PAGING_KEYS); partSize = conf.getLong(MULTIPART_SIZE, DEFAULT_MULTIPART_SIZE); partSizeThreshold = conf.getInt(MIN_MULTIPART_THR...
new InstanceProfileCredentialsProvider(), new AnonymousAWSCredentialsProvider() bucket = name.getHost(); ClientConfiguration awsConf = new ClientConfiguration(); awsConf.setMaxConnections(conf.getInt(NEW_MAXIMUM_CONNECTIONS, conf.getInt(OLD_MAXIMUM_CONNECTIONS, DEFAULT_MAXIMUM_CONNECTIONS))); awsConf.setProtocol(conf.g...
43,808
cannedACL = null; } if (!s3.doesBucketExist(bucket)) { throw new IOException("Bucket " + bucket + " does not exist"); } <BUG>boolean purgeExistingMultipart = conf.getBoolean(PURGE_EXISTING_MULTIPART, DEFAULT_PURGE_EXISTING_MULTIPART); long purgeExistingMultipartAge = conf.getLong(PURGE_EXISTING_MULTIPART_AGE, DEFAULT_...
boolean purgeExistingMultipart = conf.getBoolean(NEW_PURGE_EXISTING_MULTIPART, conf.getBoolean(OLD_PURGE_EXISTING_MULTIPART, DEFAULT_PURGE_EXISTING_MULTIPART)); long purgeExistingMultipartAge = conf.getLong(NEW_PURGE_EXISTING_MULTIPART_AGE, conf.getLong(OLD_PURGE_EXISTING_MULTIPART_AGE, DEFAULT_PURGE_EXISTING_MULTIPART...
43,809
import java.io.BufferedOutputStream; import java.io.File; import java.io.FileOutputStream; import java.io.IOException; import java.io.OutputStream; <BUG>import static org.apache.hadoop.fs.s3a.S3AConstants.*; public class S3AOutputStream extends OutputStream {</BUG> private OutputStream backupStream; private File backup...
import static org.apache.hadoop.fs.s3a.Constants.*; public class S3AOutputStream extends OutputStream {
43,810
this.client = client; this.progress = progress; this.fs = fs; this.cannedACL = cannedACL; this.statistics = statistics; <BUG>partSize = conf.getLong(MULTIPART_SIZE, DEFAULT_MULTIPART_SIZE); partSizeThreshold = conf.getInt(MIN_MULTIPART_THRESHOLD, DEFAULT_MIN_MULTIPART_THRESHOLD); </BUG> if (conf.get(BUFFER_DIR, null) ...
partSize = conf.getLong(OLD_MULTIPART_SIZE, DEFAULT_MULTIPART_SIZE); partSizeThreshold = conf.getInt(OLD_MIN_MULTIPART_THRESHOLD, DEFAULT_MIN_MULTIPART_THRESHOLD);
43,811
import edu.umd.cs.findbugs.BugInstance; import edu.umd.cs.findbugs.TigerSubstitutes; import edu.umd.cs.findbugs.annotations.CheckForNull; import edu.umd.cs.findbugs.plugin.eclipse.quickfix.exception.BugResolutionException; public abstract class BugResolution implements IMarkerResolution { <BUG>static private final Stri...
static private final String MISSING_BUG_INSTANCE = "This bug is no longer in the system. " + "The bugs somehow got out of sync with the memory representation. " private String label = TigerSubstitutes.getSimpleName(getClass());
43,812
FindbugsPlugin.getBugCollection(project, monitor).remove(bug); marker.delete(); MarkerUtil.redisplayMarkers(project, FindbugsPlugin.getShell()); } finally { originalUnit.discardWorkingCopy(); <BUG>} } catch (BugResolutionException e) { FindbugsPlugin.getDefault().logException(e, e.getMessage()); } catch (JavaModelExcep...
[DELETED]
43,813
if (element instanceof ICompilationUnit) { return (ICompilationUnit) element; } } return null; <BUG>} protected CompilationUnit createWorkingCopy(ICompilationUnit unit) throws JavaModelException { assert unit != null;</BUG> unit.becomeWorkingCopy(null, monitor);
protected void reportException(Exception e) { assert e != null; FindbugsPlugin.getDefault().logException(e, e.getLocalizedMessage()); MessageDialog.openError(FindbugsPlugin.getShell(), "BugResolution failed.", e.getLocalizedMessage()); private CompilationUnit createWorkingCopy(ICompilationUnit unit) throws JavaModelExc...
43,814
ASTParser parser = ASTParser.newParser(AST.JLS3); parser.setSource(unit); parser.setResolveBindings(resolveBindings()); return (CompilationUnit) parser.createAST(monitor); } <BUG>protected void rewriteCompilationUnit(ASTRewrite rewrite, IDocument doc, ICompilationUnit originalUnit) throws JavaModelException, BadLocatio...
private void rewriteCompilationUnit(ASTRewrite rewrite, IDocument doc, ICompilationUnit originalUnit) throws JavaModelException, BadLocationException {
43,815
try { IMarkerResolution resolution = resolutionClass.newInstance(); loadAttributes(resolution, attributes); return resolution; } catch (InstantiationException e) { <BUG>FindbugsPlugin.getDefault().logException(e, "Failed to instaniate Fixer '" + </BUG> TigerSubstitutes.getSimpleName(resolutionClass)+ "'."); return null...
FindbugsPlugin.getDefault().logException(e, "Failed to instaniate BugResolution '" +
43,816
import org.spongepowered.api.world.Locatable; import org.spongepowered.api.world.Location; import org.spongepowered.api.world.World; import javax.annotation.Nullable; import java.util.List; <BUG>import java.util.Optional; import static net.foxdenstudio.sponge.foxcore.plugin.util.Aliases.*;</BUG> public class CommandDel...
import java.util.stream.Stream; import static net.foxdenstudio.sponge.foxcore.plugin.util.Aliases.*;
43,817
.append(Text.of(TextColors.GREEN, "Usage: ")) .append(getUsage(source)) .build()); return CommandResult.empty(); } else if (isIn(REGIONS_ALIASES, parse.args[0])) { <BUG>if (parse.args.length < 2) throw new CommandException(Text.of("Must specify a name!")); IRegion region = FGManager.getInstance().getRegion(parse.args[1...
String regionName = parse.args[1]; IRegion region = FGManager.getInstance().getRegion(regionName).orElse(null);
43,818
</BUG> isWorldRegion = true; } if (region == null) <BUG>throw new CommandException(Text.of("No region exists with the name \"" + parse.args[1] + "\"!")); if (region instanceof GlobalWorldRegion) { </BUG> throw new CommandException(Text.of("You may not delete the global region!")); }
if (world == null) throw new CommandException(Text.of("No world exists with name \"" + worldName + "\"!")); if (world == null) throw new CommandException(Text.of("Must specify a world!")); region = FGManager.getInstance().getWorldRegion(world, regionName).orElse(null); throw new CommandException(Text.of("No region exis...
43,819
source.getName() + " deleted " + (isWorldRegion ? "world" : "") + "region" ); return CommandResult.success(); } else if (isIn(HANDLERS_ALIASES, parse.args[0])) { if (parse.args.length < 2) throw new CommandException(Text.of("Must specify a name!")); <BUG>IHandler handler = FGManager.getInstance().gethandler(parse.args[...
Optional<IHandler> handlerOpt = FGManager.getInstance().gethandler(parse.args[1]); if (!handlerOpt.isPresent()) IHandler handler = handlerOpt.get(); if (handler instanceof GlobalHandler)
43,820
.excludeCurrent(true) .autoCloseQuotes(true) .parse(); if (parse.current.type.equals(AdvCmdParser.CurrentElement.ElementType.ARGUMENT)) { if (parse.current.index == 0) <BUG>return ImmutableList.of("region", "handler").stream() .filter(new StartsWithPredicate(parse.current.token))</BUG> .map(args -> parse.current.prefix...
return Stream.of("region", "handler") .filter(new StartsWithPredicate(parse.current.token))
43,821
.excludeCurrent(true) .autoCloseQuotes(true) .parse(); if (parse.current.type.equals(AdvCmdParser.CurrentElement.ElementType.ARGUMENT)) { if (parse.current.index == 0) <BUG>return ImmutableList.of("region", "handler").stream() .filter(new StartsWithPredicate(parse.current.token))</BUG> .map(args -> parse.current.prefix...
return Stream.of("region", "handler") .filter(new StartsWithPredicate(parse.current.token))
43,822
@Dependency(id = "foxcore") }, description = "A world protection plugin built for SpongeAPI. Requires FoxCore.", authors = {"gravityfox"}, url = "https://github.com/FoxDenStudio/FoxGuard") <BUG>public final class FoxGuardMain { public final Cause pluginCause = Cause.builder().named("plugin", this).build(); private stat...
private static FoxGuardMain instanceField;
43,823
private UserStorageService userStorage; private EconomyService economyService = null; private boolean loaded = false; private FCCommandDispatcher fgDispatcher; public static FoxGuardMain instance() { <BUG>return instanceField; }</BUG> @Listener public void construct(GameConstructionEvent event) { instanceField = this;
} public static Cause getCause() { return instance().pluginCause; }
43,824
return configDirectory; } public boolean isLoaded() { return loaded; } <BUG>public static Cause getCause() { return instance().pluginCause; }</BUG> public EconomyService getEconomyService() { return economyService;
[DELETED]
43,825
import org.spongepowered.api.world.Locatable; import org.spongepowered.api.world.Location; import org.spongepowered.api.world.World; import javax.annotation.Nullable; import java.util.*; <BUG>import java.util.stream.Collectors; import static net.foxdenstudio.sponge.foxcore.plugin.util.Aliases.*;</BUG> public class Comm...
import java.util.stream.Stream; import static net.foxdenstudio.sponge.foxcore.plugin.util.Aliases.*;
43,826
.excludeCurrent(true) .autoCloseQuotes(true) .parse(); if (parse.current.type.equals(AdvCmdParser.CurrentElement.ElementType.ARGUMENT)) { if (parse.current.index == 0) <BUG>return ImmutableList.of("region", "handler").stream() .filter(new StartsWithPredicate(parse.current.token))</BUG> .map(args -> parse.current.prefix...
return Stream.of("region", "handler") .filter(new StartsWithPredicate(parse.current.token))
43,827
private static FGStorageManager instance; private final Logger logger = FoxGuardMain.instance().getLogger();</BUG> private final Set<LoadEntry> loaded = new HashSet<>(); private final Path directory = getDirectory(); private final Map<String, Path> worldDirectories; <BUG>private FGStorageManager() { defaultModifiedMap ...
public final HashMap<IFGObject, Boolean> defaultModifiedMap; private final UserStorageService userStorageService; private final Logger logger = FoxGuardMain.instance().getLogger(); userStorageService = FoxGuardMain.instance().getUserStorage(); defaultModifiedMap = new CacheMap<>((k, m) -> {
43,828
String name = fgObject.getName(); Path singleDir = dir.resolve(name.toLowerCase()); </BUG> boolean shouldSave = fgObject.shouldSave(); if (force || shouldSave) { <BUG>logger.info((shouldSave ? "S" : "Force s") + "aving handler \"" + name + "\" in directory: " + singleDir); </BUG> constructDirectory(singleDir); try { fg...
UUID owner = fgObject.getOwner(); boolean isOwned = !owner.equals(SERVER_UUID); Optional<User> userOwner = userStorageService.get(owner); String logName = (userOwner.isPresent() ? userOwner.get().getName() + ":" : "") + (isOwned ? owner + ":" : "") + name; if (fgObject.autoSave()) { Path singleDir = serverDir.resolve(n...
43,829
if (fgObject.autoSave()) { Path singleDir = dir.resolve(name.toLowerCase()); </BUG> boolean shouldSave = fgObject.shouldSave(); if (force || shouldSave) { <BUG>logger.info((shouldSave ? "S" : "Force s") + "aving world region \"" + name + "\" in directory: " + singleDir); </BUG> constructDirectory(singleDir); try { fgOb...
Path singleDir = serverDir.resolve(name.toLowerCase()); logger.info((shouldSave ? "S" : "Force s") + "aving world region " + logName + " in directory: " + singleDir);
43,830
public synchronized void loadRegionLinks() { logger.info("Loading region links"); try (DB mainDB = DBMaker.fileDB(directory.resolve("regions.foxdb").normalize().toString()).make()) { Map<String, String> linksMap = mainDB.hashMap("links", Serializer.STRING, Serializer.STRING).createOrOpen(); linksMap.entrySet().forEach(...
Optional<IRegion> regionOpt = FGManager.getInstance().getRegion(entry.getKey()); if (regionOpt.isPresent()) { IRegion region = regionOpt.get(); logger.info("Loading links for region \"" + region.getName() + "\"");
43,831
public synchronized void loadWorldRegionLinks(World world) { logger.info("Loading world region links for world \"" + world.getName() + "\""); try (DB mainDB = DBMaker.fileDB(worldDirectories.get(world.getName()).resolve("wregions.foxdb").normalize().toString()).make()) { Map<String, String> linksMap = mainDB.hashMap("l...
Optional<IWorldRegion> regionOpt = FGManager.getInstance().getWorldRegion(world, entry.getKey()); if (regionOpt.isPresent()) { IWorldRegion region = regionOpt.get(); logger.info("Loading links for world region \"" + region.getName() + "\"");
43,832
StringBuilder builder = new StringBuilder(); for (Iterator<IHandler> it = handlers.iterator(); it.hasNext(); ) { builder.append(it.next().getName()); if (it.hasNext()) builder.append(","); } <BUG>return builder.toString(); }</BUG> private final class LoadEntry { public final String name; public final Type type;
public enum Type { REGION, WREGION, HANDLER
43,833
.autoCloseQuotes(true) .leaveFinalAsIs(true) .parse(); if (parse.current.type.equals(AdvCmdParser.CurrentElement.ElementType.ARGUMENT)) { if (parse.current.index == 0) <BUG>return ImmutableList.of("region", "worldregion", "handler", "controller").stream() </BUG> .filter(new StartsWithPredicate(parse.current.token)) .co...
return Stream.of("region", "worldregion", "handler", "controller")
43,834
@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;
43,835
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));
43,836
package com.eucalyptus.blockstorage.entities; import javax.persistence.Column; import javax.persistence.Entity; import javax.persistence.PersistenceContext; import javax.persistence.Table; <BUG>import com.eucalyptus.entities.Entities; import com.eucalyptus.entities.TransactionResource;</BUG> import org.apache.log4j.Log...
[DELETED]
43,837
import com.eucalyptus.util.EucalyptusCloudException; import java.util.NoSuchElementException;</BUG> @Entity <BUG>@PersistenceContext(name="eucalyptus_storage") @Table( name = "das_info" ) @Cache( usage = CacheConcurrencyStrategy.TRANSACTIONAL ) @ConfigurableClass(root = "storage", alias = "das", description = "Basic ...
import com.eucalyptus.blockstorage.util.StorageProperties; import com.eucalyptus.configurable.ConfigurableClass; import com.eucalyptus.configurable.ConfigurableField; import com.eucalyptus.configurable.ConfigurableIdentifier; import com.eucalyptus.entities.AbstractPersistent; import com.eucalyptus.entities.Transactions...
43,838
int result = 1; result = prime * result + ((name == null) ? 0 : name.hashCode()); return result; } @Override <BUG>public String toString() {</BUG> return this.name; }
public String toString() {
43,839
LOG.error(e); } checkAndAddUser(); } private void checkAndAddUser() { <BUG>TransactionResource outter = Entities.transactionFor(CHAPUserInfo.class); try {</BUG> CHAPUserInfo userInfo = Entities.uniqueResult(new CHAPUserInfo("eucalyptus")); outter.commit();
try (TransactionResource outter = Entities.transactionFor(CHAPUserInfo.class)) {
43,840
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> {
43,841
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...
43,842
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;
43,843
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]
43,844
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]
43,845
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...
43,846
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...
43,847
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]
43,848
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...
43,849
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(() -> {
43,850
public VPC getVPC(int accountId, int vpcID); public void deleteVPC(int accountId, int vpcId) throws RuntimeException, VPCNotFoundException; public List<VPC> getVPC(int accountId);</BUG> public List<VPC> getVPC(String apiKey); <BUG>public int getActivationNonce(int id) throws RuntimeException; public int getActivationId...
public void deleteVPC(int accountId, int vpcId) throws VPCNotFoundException; public List<VPC> getVPC(int accountId); public int getActivationNonce(int id); public int getActivationId(int nonce) throws StaleNonceException; public int getSessionNonce(int id); public int getSessionId(int nonce) throws StaleNonceException;...
43,851
package org.rstudio.studio.client.workbench.views.console; import com.google.gwt.core.client.GWT; import com.google.gwt.user.client.ui.IsWidget; import com.google.inject.Inject; import org.rstudio.core.client.command.CommandBinder; <BUG>import org.rstudio.core.client.command.Handler; import org.rstudio.core.client.layo...
import org.rstudio.core.client.dom.WindowEx; import org.rstudio.core.client.layout.DelayFadeInHelper;
43,852
import com.google.gwt.user.client.ui.Widget; import com.google.inject.Inject; import com.google.inject.Provider; import com.google.inject.name.Named; import org.rstudio.core.client.Debug; <BUG>import org.rstudio.core.client.Triad; import org.rstudio.core.client.events.WindowStateChangeEvent;</BUG> import org.rstudio.co...
import org.rstudio.core.client.dom.WindowEx; import org.rstudio.core.client.events.WindowStateChangeEvent;
43,853
return new WorkbenchTab[] { workspaceTab_, historyTab_, filesTab_, plotsTab_, packagesTab_, helpTab_, vcsTab_, buildTab_}; } public void activateTab(Tab tab) <BUG>{ tabToPanel_.get(tab).selectTab(tabToIndex_.get(tab));</BUG> } public ConsolePane getConsole() {
WindowEx.get().focus(); tabToPanel_.get(tab).selectTab(tabToIndex_.get(tab));
43,854
import com.google.gwt.event.shared.HasHandlers; public class NativeKeyDownEvent extends GwtEvent<NativeKeyDownHandler> { public static final GwtEvent.Type<NativeKeyDownHandler> TYPE = new GwtEvent.Type<NativeKeyDownHandler>(); <BUG>protected NativeKeyDownEvent(NativeEvent event) </BUG> { event_ = event; }
public NativeKeyDownEvent(NativeEvent event)
43,855
void showHelp(String helpURL); void back() ; void forward() ; void print() ; void popout() ; <BUG>void refresh() ; LinkMenu getHistory() ;</BUG> boolean navigated(); } public interface LinkMenu extends HasSelectionHandlers<String>
void focus(); LinkMenu getHistory() ;
43,856
public interface SplitfileBlock { abstract int getNumber(); abstract boolean hasData(); abstract Bucket getData(); abstract void storeTo(ObjectContainer container); <BUG>abstract boolean trySetData(Bucket data); </BUG> abstract void assertSetData(Bucket data); abstract Bucket clearData(); abstract Bucket replaceData(Bu...
abstract Bucket trySetData(Bucket data);
43,857
return data != null; } public synchronized Bucket getData() { return data; } <BUG>public synchronized boolean trySetData(Bucket data) { if(this.data == data) return true; if(this.data != null) return false; </BUG> this.data = data;
public synchronized Bucket trySetData(Bucket data) { if(this.data != null) return this.data;
43,858
if(this.data == data) return true; if(this.data != null) return false; </BUG> this.data = data; <BUG>return true; </BUG> } public synchronized void assertSetData(Bucket data) { assert(this.data == null || this.data == data); this.data = data;
return data != null; public synchronized Bucket getData() { return data; public synchronized Bucket trySetData(Bucket data) { if(this.data != null) return this.data; return null;
43,859
import freenet.node.RequestStarter; import freenet.support.Executor; import freenet.support.Logger; import freenet.support.OOMHandler; import freenet.support.OOMHook; <BUG>import freenet.support.Logger.LogLevel; import freenet.support.io.NativeThread;</BUG> public class FECQueue implements OOMHook { private transient L...
import freenet.support.api.Bucket; import freenet.support.io.NativeThread;
43,860
job.bucketFactory); else { job.getCodec().realEncode(job.dataBlocks, job.checkBlocks, job.blockLength, job.bucketFactory); if ((job.dataBlockStatus != null) || (job.checkBlockStatus != null)) { for (int i = 0; i < job.dataBlocks.length; i++) { <BUG>if(!job.dataBlockStatus[i].trySetData(job.dataBlocks[i])) { job.dataBl...
Bucket existingData = job.dataBlockStatus[i].trySetData(job.dataBlocks[i]); if(existingData != null && existingData != job.dataBlocks[i]) { job.dataBlocks[i].free();
43,861
import java.io.IOException; import java.io.InputStream; import java.io.OutputStream; import java.security.DigestOutputStream; import java.security.MessageDigest; <BUG>import java.security.NoSuchAlgorithmException; import java.util.ArrayList; import java.util.Collections; import java.util.List;</BUG> public final class ...
import java.text.DateFormat; import java.util.Date; import java.util.List;
43,862
package org.jboss.as.patching.runner; <BUG>import org.jboss.as.boot.DirectoryStructure; import org.jboss.as.patching.LocalPatchInfo;</BUG> import org.jboss.as.patching.PatchInfo; import org.jboss.as.patching.PatchLogger; import org.jboss.as.patching.PatchMessages;
import static org.jboss.as.patching.runner.PatchUtils.generateTimestamp; import org.jboss.as.patching.CommonAttributes; import org.jboss.as.patching.LocalPatchInfo;
43,863
private static final String PATH_DELIMITER = "/"; public static final byte[] NO_CONTENT = PatchingTask.NO_CONTENT; enum Element { ADDED_BUNDLE("added-bundle"), ADDED_MISC_CONTENT("added-misc-content"), <BUG>ADDED_MODULE("added-module"), BUNDLES("bundles"),</BUG> CUMULATIVE("cumulative"), DESCRIPTION("description"), MIS...
APPLIES_TO_VERSION("applies-to-version"), BUNDLES("bundles"),
43,864
final int count = reader.getAttributeCount(); for (int i = 0; i < count; i++) { final String value = reader.getAttributeValue(i); final Attribute attribute = Attribute.forName(reader.getAttributeLocalName(i)); switch (attribute) { <BUG>case APPLIES_TO_VERSION: builder.addAppliesTo(value); break;</BUG> case RESULTING_VE...
[DELETED]
43,865
final StringBuilder path = new StringBuilder(); for(final String p : item.getPath()) { path.append(p).append(PATH_DELIMITER); } path.append(item.getName()); <BUG>writer.writeAttribute(Attribute.PATH.name, path.toString()); if(type != ModificationType.REMOVE) {</BUG> writer.writeAttribute(Attribute.HASH.name, bytesToHex...
if (item.isDirectory()) { writer.writeAttribute(Attribute.DIRECTORY.name, "true"); if(type != ModificationType.REMOVE) {
43,866
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;
43,867
chart.addYAxisLabels(AxisLabelsFactory.newAxisLabels(labels)); chart.addXAxisLabels(AxisLabelsFactory.newNumericRangeAxisLabels(0, max)); chart.setBarWidth(BarChart.AUTO_RESIZE); chart.setSize(600, 500); chart.setHorizontal(true); <BUG>chart.setTitle("Total Evaluations by User"); showChartImg(resp, chart.toURLString())...
chart.setDataEncoding(DataEncoding.TEXT); return chart; }
43,868
checkEvaluationsEqual(eval4, foundissueProto.getEvaluations(0)); checkEvaluationsEqual(eval5, foundissueProto.getEvaluations(1)); } public void testGetRecentEvaluationsNoneFound() throws Exception { DbIssue issue = createDbIssue("fad", persistenceHelper); <BUG>DbEvaluation eval1 = createEvaluation(issue, "someone", 100...
[DELETED]
43,869
public int read() throws IOException { return inputStream.read(); } }); } <BUG>} protected DbEvaluation createEvaluation(DbIssue issue, String who, long when) {</BUG> DbUser user; Query query = getPersistenceManager().newQuery("select from " + persistenceHelper.getDbUserClass().getName() + " where openid == :myopenid")...
@SuppressWarnings({"unchecked"}) protected DbEvaluation createEvaluation(DbIssue issue, String who, long when) {
43,870
eval.setComment("my comment"); eval.setDesignation("MUST_FIX"); eval.setIssue(issue); eval.setWhen(when); eval.setWho(user.createKeyObject()); <BUG>eval.setEmail(who); return eval;</BUG> } protected PersistenceManager getPersistenceManager() { return testHelper.getPersistenceManager();
issue.addEvaluation(eval); return eval;
43,871
import com.tremolosecurity.server.GlobalEntries; public class OpenUnisonServletFilter extends UnisonServletFilter { OpenUnisonConfigManager cfgMgr; static Logger logger = Logger.getLogger(OpenUnisonServletFilter.class.getName()); private SessionManager sessionManager; <BUG>public static final String version = "1.0.6-20...
public static final String version = "1.0.6-2016072602";
43,872
import android.widget.TextView; import android.widget.Toast; import com.woxthebox.draglistview.BoardView; import com.woxthebox.draglistview.DragItem; import java.util.ArrayList; <BUG>public class BoardFragment extends Fragment { private BoardView mBoardView;</BUG> private int mColumns; public static BoardFragment newIn...
private static int sCreatedItems = 0; private BoardView mBoardView;
43,873
((TextView) header.findViewById(R.id.text)).setText("Column " + (mColumns + 1)); ((TextView) header.findViewById(R.id.item_count)).setText("" + addItems); header.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View v) { <BUG>mItemArray.add(0, new Pair<>((long) mBoardView.getItemCount(), "T...
long id = sCreatedItems++; Pair item = new Pair<>(id, "Test " + id); mBoardView.addItem(column, 0, item, true);
43,874
import android.support.v7.widget.RecyclerView; import android.view.MotionEvent; import android.view.View; public abstract class DragItemAdapter<VH extends DragItemAdapter.ViewHolder> extends RecyclerView.Adapter<VH> { interface DragStartedListener { <BUG>public void onDragStarted(View itemView, long itemId); }</BUG> pr...
}
43,875
import android.support.v7.widget.RecyclerView; import android.util.AttributeSet; import android.view.View; class DragItemRecyclerView extends RecyclerView implements AutoScroller.AutoScrollListener { public interface DragItemListener { <BUG>public void onDragStarted(int itemPosition, float x, float y); public void onDr...
}
43,876
if (x >= child.getLeft() - params.leftMargin && x <= child.getRight() + params.rightMargin && y >= child.getTop() - params.topMargin && y <= child.getBottom() + params.bottomMargin) { return child; } } <BUG>if (count > 0) { return getChildAt(count - 1); }</BUG> return null; }
[DELETED]
43,877
mHoldChangePosition = false; } }, getItemAnimator().getMoveDuration()); invalidate(); } <BUG>Object removeDragItemAndEnd() { mAutoScroller.stopAutoScroll();</BUG> Object item = mAdapter.removeItem(mDragItemPosition); mAdapter.setDragItemId(-1); mDragState = DragState.DRAG_ENDED;
if (mDragItemPosition == -1) { return null; mAutoScroller.stopAutoScroll();
43,878
if (id == mItemList.get(i).first) { return i; } } return -1; <BUG>} @Override public void changeItemPosition(int fromPos, int toPos) { Pair<Long, String> pair = mItemList.remove(fromPos); mItemList.add(toPos, pair); notifyDataSetChanged();</BUG> }
[DELETED]
43,879
timeWarp = new OwnLabel(getFormattedTimeWrap(), skin, "warp"); timeWarp.setName("time warp"); Container wrapWrapper = new Container(timeWarp); wrapWrapper.width(60f * GlobalConf.SCALE_FACTOR); wrapWrapper.align(Align.center); <BUG>VerticalGroup timeGroup = new VerticalGroup().align(Align.left).space(3 * GlobalConf.SCAL...
VerticalGroup timeGroup = new VerticalGroup().align(Align.left).columnAlign(Align.left).space(3 * GlobalConf.SCALE_FACTOR).padTop(3 * GlobalConf.SCALE_FACTOR);
43,880
focusListScrollPane.setFadeScrollBars(false); focusListScrollPane.setScrollingDisabled(true, false); focusListScrollPane.setHeight(tree ? 200 * GlobalConf.SCALE_FACTOR : 100 * GlobalConf.SCALE_FACTOR); focusListScrollPane.setWidth(160); } <BUG>VerticalGroup objectsGroup = new VerticalGroup().align(Align.left).space(3 *...
VerticalGroup objectsGroup = new VerticalGroup().align(Align.left).columnAlign(Align.left).space(3 * GlobalConf.SCALE_FACTOR);
43,881
headerGroup.addActor(expandIcon); headerGroup.addActor(detachIcon); addActor(headerGroup); expandIcon.setChecked(expanded); } <BUG>public void expand() { </BUG> if (!expandIcon.isChecked()) { expandIcon.setChecked(true); }
public void expandPane() {
43,882
</BUG> if (!expandIcon.isChecked()) { expandIcon.setChecked(true); } } <BUG>public void collapse() { </BUG> if (expandIcon.isChecked()) { expandIcon.setChecked(false); }
headerGroup.addActor(expandIcon); headerGroup.addActor(detachIcon); addActor(headerGroup); expandIcon.setChecked(expanded); public void expandPane() { public void collapsePane() {
43,883
}); playstop.addListener(new TextTooltip(txt("gui.tooltip.playstop"), skin)); TimeComponent timeComponent = new TimeComponent(skin, ui); timeComponent.initialize(); CollapsiblePane time = new CollapsiblePane(ui, txt("gui.time"), timeComponent.getActor(), skin, true, playstop); <BUG>time.align(Align.left); mainActors.ad...
time.align(Align.left).columnAlign(Align.left); mainActors.add(time);
43,884
panes.put(visualEffectsComponent.getClass().getSimpleName(), visualEffects); ObjectsComponent objectsComponent = new ObjectsComponent(skin, ui); objectsComponent.setSceneGraph(sg); objectsComponent.initialize(); CollapsiblePane objects = new CollapsiblePane(ui, txt("gui.objects"), objectsComponent.getActor(), skin, fal...
objects.align(Align.left).columnAlign(Align.left); mainActors.add(objects);
43,885
if (Constants.desktop) { MusicComponent musicComponent = new MusicComponent(skin, ui); musicComponent.initialize(); Actor[] musicActors = MusicActorsManager.getMusicActors() != null ? MusicActorsManager.getMusicActors().getActors(skin) : null; CollapsiblePane music = new CollapsiblePane(ui, txt("gui.music"), musicCompo...
music.align(Align.left).columnAlign(Align.left); mainActors.add(music);
43,886
package org.dcm4chee.arc.audit; import org.dcm4che3.net.Device; <BUG>import org.dcm4che3.net.audit.AuditLogger; import org.dcm4che3.util.StringUtils;</BUG> import org.dcm4chee.arc.Scheduler; import org.dcm4chee.arc.conf.ArchiveDeviceExtension; import org.dcm4chee.arc.conf.Duration;
import org.dcm4che3.net.audit.AuditLoggerDeviceExtension; import org.dcm4che3.util.StringUtils;
43,887
log.info("Trying to schedule 24h reminder in the past ("+new Date(reminderTime)+"), no reminder will be sent for eval ("+eval.getTitle()+") ["+eval.getId()+"]"); reminderTime = 0; } else { log.info("Scheduling a reminder ("+new Date(reminderTime)+") for 24h before the end ("+new Date(dueTime)+") of the evaluation ("+ev...
} else if (reminderDays == -2) { reminderTime = System.currentTimeMillis() + (1000l * 60l * 5l); // reminders every 5 minutes log.warn("REMINDERS TESTING ONLY (-2): Scheduling a reminder in the near future ("+new Date(reminderTime)+") for testing: due date ("+new Date(dueTime)+") of the evaluation ("+eval.getTitle()+")...
43,888
} else { String[] stateList = statusStr.trim().split(" "); logger.info("GroupMembershipSync.execute() syncing " + statusStr); for(String state : stateList) { List<EvalEvaluation> evals = evaluationService.getEvaluationsByState(state); <BUG>int count = 0; if(evals != null) { count = evals.size(); }</BUG> if(logger.isIn...
int count = evals.size();
43,889
import java.text.DateFormat; import java.util.Calendar; import java.util.Date; import java.util.GregorianCalendar; import java.util.List; <BUG>import java.util.Locale; import org.sakaiproject.evaluation.constant.EvalConstants;</BUG> import org.sakaiproject.evaluation.logic.EvalAuthoringService; import org.sakaiproject....
import org.azeckoski.reflectutils.ArrayUtils; import org.sakaiproject.evaluation.constant.EvalConstants;
43,890
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;
43,891
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();
43,892
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: " +
43,893
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;
43,894
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()...
43,895
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;
43,896
CustomizationUtil.optimizeSchema(myActionsTree, mySelectedSchema); } final CustomizableActionsSchemas allSchemasComponent = CustomizableActionsSchemas.getInstance(); allSchemasComponent.clear(); for (int i = 0; i < myCustomizationSchemas.getSize(); i++){ <BUG>final CustomActionsSchema schema = (CustomActionsSchema)myCu...
if (schema.isModified()){ schema.resetMainActionGroups(); allSchemasComponent.addCustomActionsSchema(schema);
43,897
import java.util.Iterator; public class CustomActionsSchema implements JDOMExternalizable{ public String myName; public String myDescription; private ArrayList<ActionUrl> myActions = new ArrayList<ActionUrl>(); <BUG>private boolean myModified = false; private static final String GROUP = "group";</BUG> public CustomActi...
private ActionGroup myMainMenuActionGroup; private ActionGroup myMainToolabarActionGroup; private ActionGroup myEditorPopupActionGroup; private static final String GROUP = "group";
43,898
return myName; } public String getDescription() { return myDescription; } <BUG>public ActionGroup getMainMenuActionGroup(){ return CustomizationUtil.correctActionGroup((ActionGroup)ActionManager.getInstance().getAction(IdeActions.GROUP_MAIN_MENU), this, ActionsTreeUtil.MAIN_MENU_TITLE); }</BUG> public void readExterna...
if (myMainMenuActionGroup == null){ myMainMenuActionGroup = CustomizationUtil.correctActionGroup((ActionGroup)ActionManager.getInstance().getAction(IdeActions.GROUP_MAIN_MENU), this, ActionsTreeUtil.MAIN_MENU_TITLE); return myMainMenuActionGroup;
43,899
group.addGroup(subGroup); } } } } <BUG>private static Group createGroup(ActionGroup actionGroup, boolean ignore) { </BUG> final String name = actionGroup.getTemplatePresentation().getText(); return createGroup(actionGroup, name != null ? name : ActionManager.getInstance().getId(actionGroup), null, null, ignore); }
public static Group createGroup(ActionGroup actionGroup, boolean ignore) {
43,900
if (actionUrl.getActionType() == ActionUrl.ADDED) { reordableChildren.add(actionUrl.getAbsolutePosition(), componentAction); } else if (actionUrl.getActionType() == ActionUrl.DELETED) { final AnAction anAction = reordableChildren.get(actionUrl.getAbsolutePosition()); <BUG>if (anAction.getTemplatePresentation().getText(...
final Group eqGroup = ActionsTreeUtil.createGroup((ActionGroup)anAction, true);