rem stringlengths 0 477k | add stringlengths 0 313k | context stringlengths 6 599k | meta stringlengths 141 403 |
|---|---|---|---|
} else if (current instanceof Date){ return new Timestamp(((Date)current).getTime()); } | public Object findTarget(Object current){ // IMMUTABLES if (null == current | current instanceof Integer | current instanceof String) // TODO can use findTarget then for these as well. { return current; } else // Special cases TODO put into doFindTarget if (current instanceof Date){ return new Timest... | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/0b36a8e77f5bacb7e122d76ffce01866205b09d7/ModelMapper.java/buggy/components/common/src/ome/util/ModelMapper.java | |
if (null != targetType){ | if (null != targetType){ | public Object findTarget(Object current){ // IMMUTABLES if (null == current | current instanceof Integer | current instanceof String) // TODO can use findTarget then for these as well. { return current; } else // Special cases TODO put into doFindTarget if (current instanceof Date){ return new Timest... | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/0b36a8e77f5bacb7e122d76ffce01866205b09d7/ModelMapper.java/buggy/components/common/src/ome/util/ModelMapper.java |
throw new RuntimeException("Internal error: could not instantiate object of type "+targetType+" while trying to map "+current,e); | throw new RuntimeException("Internal error: " + "could not instantiate object of type "+targetType+ " while trying to map "+current,e); | public Object findTarget(Object current){ // IMMUTABLES if (null == current | current instanceof Integer | current instanceof String) // TODO can use findTarget then for these as well. { return current; } else // Special cases TODO put into doFindTarget if (current instanceof Date){ return new Timest... | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/0b36a8e77f5bacb7e122d76ffce01866205b09d7/ModelMapper.java/buggy/components/common/src/ome/util/ModelMapper.java |
} else { throw new RuntimeException("Internal error: could not find target class type for "+current.getClass()); | } else { | public Object findTarget(Object current){ // IMMUTABLES if (null == current | current instanceof Integer | current instanceof String) // TODO can use findTarget then for these as well. { return current; } else // Special cases TODO put into doFindTarget if (current instanceof Date){ return new Timest... | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/0b36a8e77f5bacb7e122d76ffce01866205b09d7/ModelMapper.java/buggy/components/common/src/ome/util/ModelMapper.java |
public Object findTarget(Object current){ // IMMUTABLES if (null == current | current instanceof Integer | current instanceof String) // TODO can use findTarget then for these as well. { return current; } else // Special cases TODO put into doFindTarget if (current instanceof Date){ return new Timest... | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/0b36a8e77f5bacb7e122d76ffce01866205b09d7/ModelMapper.java/buggy/components/common/src/ome/util/ModelMapper.java | ||
public HTMLReport(ProjectData projectData, File outputDir, FileFinder finder) | public HTMLReport(ProjectData projectData, File outputDir, FileFinder finder, ComplexityCalculator complexity) | public HTMLReport(ProjectData projectData, File outputDir, FileFinder finder) throws Exception { this.destinationDir = outputDir; this.finder = finder; this.projectData = projectData; CopyFiles.copy(outputDir); generatePackageList(); generateSourceFileLists(); generateOverviews(); generateSourceFiles(); } | 50197 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50197/c26f5a170c752d9d1d5b884dd7eb60b982637269/HTMLReport.java/clean/cobertura/src/net/sourceforge/cobertura/reporting/html/HTMLReport.java |
this.complexity = complexity; | public HTMLReport(ProjectData projectData, File outputDir, FileFinder finder) throws Exception { this.destinationDir = outputDir; this.finder = finder; this.projectData = projectData; CopyFiles.copy(outputDir); generatePackageList(); generateSourceFileLists(); generateOverviews(); generateSourceFiles(); } | 50197 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50197/c26f5a170c752d9d1d5b884dd7eb60b982637269/HTMLReport.java/clean/cobertura/src/net/sourceforge/cobertura/reporting/html/HTMLReport.java | |
File sourceFile = finder.findFile(sourceFileData.getName()); | File sourceFile = finder.getFileForSource(sourceFileData.getName()); | private void generateSourceFile(SourceFileData sourceFileData) throws IOException { if (!sourceFileData.containsInstrumentationInfo()) { LOGGER.info("Data file does not contain instrumentation " + "information for the file " + sourceFileData.getName() + ". Ensure this class was instrumented, and this " ... | 50197 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50197/c26f5a170c752d9d1d5b884dd7eb60b982637269/HTMLReport.java/clean/cobertura/src/net/sourceforge/cobertura/reporting/html/HTMLReport.java |
double ccn = packageData.getCCN(finder); | double ccn = complexity.getCCNForPackage(packageData); | private String generateTableRowForPackage(PackageData packageData) { StringBuffer ret = new StringBuffer(); String url1 = "frame-summary-" + packageData.getName() + ".html"; String url2 = "frame-sourcefiles-" + packageData.getName() + ".html"; double lineCoverage = -1; double branchCoverage = -1; double cc... | 50197 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50197/c26f5a170c752d9d1d5b884dd7eb60b982637269/HTMLReport.java/clean/cobertura/src/net/sourceforge/cobertura/reporting/html/HTMLReport.java |
File file = finder.findFile(sourceFileData.getName()); if (file == null) { System.out.println("FILE IS NULL: " + sourceFileData.getName()); } double ccn = Util.getCCN(file, false); | double ccn = complexity.getCCNForSourceFile(sourceFileData); | private String generateTableRowForSourceFile(SourceFileData sourceFileData) { StringBuffer ret = new StringBuffer(); double lineCoverage = -1; double branchCoverage = -1; File file = finder.findFile(sourceFileData.getName()); if (file == null) { System.out.println("FILE IS NULL: " + sourceFileData.getName()); ... | 50197 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50197/c26f5a170c752d9d1d5b884dd7eb60b982637269/HTMLReport.java/clean/cobertura/src/net/sourceforge/cobertura/reporting/html/HTMLReport.java |
double ccnSum = 0; int count = 0; for (Iterator it = finder.getBaseDirectories().iterator(); it.hasNext(); ) { File basedir = (File) it.next(); ccnSum += Util.getCCN(basedir.getAbsoluteFile(), true); count++; } double ccn = ccnSum / (double) count; | private String generateTableRowForTotal() { StringBuffer ret = new StringBuffer(); double lineCoverage = -1; double branchCoverage = -1; double ccnSum = 0; int count = 0; for (Iterator it = finder.getBaseDirectories().iterator(); it.hasNext(); ) { File basedir = (File) it.next(); ccnSum += Util.getCCN(base... | 50197 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50197/c26f5a170c752d9d1d5b884dd7eb60b982637269/HTMLReport.java/clean/cobertura/src/net/sourceforge/cobertura/reporting/html/HTMLReport.java | |
String separator = getRuntime().getGlobalVariables().get("$/").asSymbol(); if (args.length > 0) { separator = args[0].asSymbol(); | String separator = (args.length == 0) ? getRuntime().getGlobalVariables().get("$/").asSymbol() : args[0].asSymbol(); if (separator.equals(DEFAULT_RS)) { int lastCharIndex = getValue().length() - 1; char lastChar = getValue().charAt(lastCharIndex); if (lastChar=='\n') { if (lastCharIndex > 0 && getValue().charAt(las... | public IRubyObject chomp_bang(IRubyObject[] args) { if (isEmpty()) { return getRuntime().getNil(); } String separator = getRuntime().getGlobalVariables().get("$/").asSymbol(); if (args.length > 0) { separator = args[0].asSymbol(); } if (getValue().endsWit... | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/918507aed1bf53ad95fefa25f3be76b4503d0f79/RubyString.java/clean/src/org/jruby/RubyString.java |
if (separator.length() == 0) { boolean modified = false; while(getValue().length() > 0 && getValue().charAt(getValue().length() - 1) == '\n') { modified = true; setValue(getValue().substring(0, getValue().length() - 1)); if (getValue().length() > 0 && getValue().charAt(getValue().length() - 1) == '\r') { setValue(get... | public IRubyObject chomp_bang(IRubyObject[] args) { if (isEmpty()) { return getRuntime().getNil(); } String separator = getRuntime().getGlobalVariables().get("$/").asSymbol(); if (args.length > 0) { separator = args[0].asSymbol(); } if (getValue().endsWit... | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/918507aed1bf53ad95fefa25f3be76b4503d0f79/RubyString.java/clean/src/org/jruby/RubyString.java | |
&& RosterPacket.ItemStatus.SUBSCRIPTION_PENDING == entry.getStatus()) { | && RosterPacket.ItemStatus.SUBSCRIPTION_PENDING == entry.getStatus()) { | private void buildContactList() { XMPPConnection con = SparkManager.getConnection(); final Roster roster = con.getRoster(); roster.addRosterListener(this); for (RosterGroup group : roster.getGroups()) { ContactGroup contactGroup = addContactGroup(group.getName()); f... | 52006 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52006/dd2c9f51cadc449a3f72355ffe47a06e4871d38d/ContactList.java/buggy/src/java/org/jivesoftware/spark/ui/ContactList.java |
&& RosterPacket.ItemStatus.SUBSCRIPTION_PENDING == rosterEntry.getStatus()) { | && RosterPacket.ItemStatus.SUBSCRIPTION_PENDING == rosterEntry.getStatus()) { | private synchronized void handleEntriesUpdated(final Collection addresses) { SwingUtilities.invokeLater(new Runnable() { public void run() { Roster roster = SparkManager.getConnection().getRoster(); Iterator jids = addresses.iterator(); while (jids.hasN... | 52006 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52006/dd2c9f51cadc449a3f72355ffe47a06e4871d38d/ContactList.java/buggy/src/java/org/jivesoftware/spark/ui/ContactList.java |
&& RosterPacket.ItemStatus.SUBSCRIPTION_PENDING == rosterEntry.getStatus()) { | && RosterPacket.ItemStatus.SUBSCRIPTION_PENDING == rosterEntry.getStatus()) { | public void run() { Roster roster = SparkManager.getConnection().getRoster(); Iterator jids = addresses.iterator(); while (jids.hasNext()) { String jid = (String)jids.next(); RosterEntry rosterEntry = roster.getEntry(jid); ... | 52006 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52006/dd2c9f51cadc449a3f72355ffe47a06e4871d38d/ContactList.java/buggy/src/java/org/jivesoftware/spark/ui/ContactList.java |
private void moveToOfflineGroup(String bareJID) { | private void moveToOfflineGroup(final String bareJID) { | private void moveToOfflineGroup(String bareJID) { final Iterator groupIterator = new ArrayList(groupList).iterator(); while (groupIterator.hasNext()) { final ContactGroup group = (ContactGroup)groupIterator.next(); final ContactItem item = group.getContactItemByJID(bareJID); ... | 52006 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52006/dd2c9f51cadc449a3f72355ffe47a06e4871d38d/ContactList.java/buggy/src/java/org/jivesoftware/spark/ui/ContactList.java |
Roster roster = SparkManager.getConnection().getRoster(); Presence userPresence = roster.getPresence(bareJID); if (userPresence != null) { return; } | private void moveToOfflineGroup(String bareJID) { final Iterator groupIterator = new ArrayList(groupList).iterator(); while (groupIterator.hasNext()) { final ContactGroup group = (ContactGroup)groupIterator.next(); final ContactItem item = group.getContactItemByJID(bareJID); ... | 52006 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52006/dd2c9f51cadc449a3f72355ffe47a06e4871d38d/ContactList.java/buggy/src/java/org/jivesoftware/spark/ui/ContactList.java | |
Roster roster = SparkManager.getConnection().getRoster(); Presence userPresence = roster.getPresence(bareJID); if (userPresence != null) { return; } | public void run() { item.setPresence(null); // Check for ContactItemHandler. group.removeContactItem(item); checkGroup(group); if (offlineGroup.getContactItemByJID(item.getFullJID()) ==... | 52006 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52006/dd2c9f51cadc449a3f72355ffe47a06e4871d38d/ContactList.java/buggy/src/java/org/jivesoftware/spark/ui/ContactList.java | |
&& RosterPacket.ItemStatus.SUBSCRIPTION_PENDING == entry.getStatus(); | && RosterPacket.ItemStatus.SUBSCRIPTION_PENDING == entry.getStatus(); | private void updateUserPresence(Presence presence) { if (presence == null) { return; } Roster roster = SparkManager.getConnection().getRoster(); final String bareJID = StringUtils.parseBareAddress(presence.getFrom()); RosterEntry entry = roster.getEntry(bareJID); ... | 52006 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52006/dd2c9f51cadc449a3f72355ffe47a06e4871d38d/ContactList.java/buggy/src/java/org/jivesoftware/spark/ui/ContactList.java |
public void searchContacts(String contact, JFrame parent) { | public void searchContacts(String contact, final JFrame parent) { if (parents.get(parent) == null) { parents.put(parent, parent.getGlassPane()); } final Component glassPane = (Component)parents.get(parent); parent.setGlassPane(glassPane); | public void searchContacts(String contact, JFrame parent) { final Map contactMap = new HashMap(); final Set contacts = new HashSet(); final ContactList contactList = SparkManager.getWorkspace().getContactList(); Iterator groups = contactList.getContactGroups().iterator(); while (g... | 52006 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52006/274dbf0ef077e2132bf5036ee54b9dbe4b819268/UserManager.java/buggy/src/java/org/jivesoftware/spark/UserManager.java |
if (window != null) { window.dispose(); } | public void searchContacts(String contact, JFrame parent) { final Map contactMap = new HashMap(); final Set contacts = new HashSet(); final ContactList contactList = SparkManager.getWorkspace().getContactList(); Iterator groups = contactList.getContactGroups().iterator(); while (g... | 52006 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52006/274dbf0ef077e2132bf5036ee54b9dbe4b819268/UserManager.java/buggy/src/java/org/jivesoftware/spark/UserManager.java | |
window = new JWindow(parent); | public void searchContacts(String contact, JFrame parent) { final Map contactMap = new HashMap(); final Set contacts = new HashSet(); final ContactList contactList = SparkManager.getWorkspace().getContactList(); Iterator groups = contactList.getContactGroups().iterator(); while (g... | 52006 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52006/274dbf0ef077e2132bf5036ee54b9dbe4b819268/UserManager.java/buggy/src/java/org/jivesoftware/spark/UserManager.java | |
window.setLayout(new BorderLayout()); | public void searchContacts(String contact, JFrame parent) { final Map contactMap = new HashMap(); final Set contacts = new HashSet(); final ContactList contactList = SparkManager.getWorkspace().getContactList(); Iterator groups = contactList.getContactGroups().iterator(); while (g... | 52006 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52006/274dbf0ef077e2132bf5036ee54b9dbe4b819268/UserManager.java/buggy/src/java/org/jivesoftware/spark/UserManager.java | |
layoutPanel.add(contactField, new GridBagConstraints(0, 1, 1, 1, 1.0, 0.0, GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(5, 5, 5, 5), 200, 0)); | layoutPanel.add(contactField, new GridBagConstraints(0, 1, 1, 1, 1.0, 0.0, GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(5, 5, 5, 5), 50, 0)); | public void searchContacts(String contact, JFrame parent) { final Map contactMap = new HashMap(); final Set contacts = new HashSet(); final ContactList contactList = SparkManager.getWorkspace().getContactList(); Iterator groups = contactList.getContactGroups().iterator(); while (g... | 52006 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52006/274dbf0ef077e2132bf5036ee54b9dbe4b819268/UserManager.java/buggy/src/java/org/jivesoftware/spark/UserManager.java |
window.add(layoutPanel); window.pack(); window.setLocationRelativeTo(parent); window.setVisible(true); window.addKeyListener(new KeyAdapter() { public void keyPressed(KeyEvent keyEvent) { if (keyEvent.getKeyChar() == KeyEvent.VK_ESCAPE) { window.dispose(); } } }); | public void searchContacts(String contact, JFrame parent) { final Map contactMap = new HashMap(); final Set contacts = new HashSet(); final ContactList contactList = SparkManager.getWorkspace().getContactList(); Iterator groups = contactList.getContactGroups().iterator(); while (g... | 52006 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52006/274dbf0ef077e2132bf5036ee54b9dbe4b819268/UserManager.java/buggy/src/java/org/jivesoftware/spark/UserManager.java | |
window.dispose(); | public void searchContacts(String contact, JFrame parent) { final Map contactMap = new HashMap(); final Set contacts = new HashSet(); final ContactList contactList = SparkManager.getWorkspace().getContactList(); Iterator groups = contactList.getContactGroups().iterator(); while (g... | 52006 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52006/274dbf0ef077e2132bf5036ee54b9dbe4b819268/UserManager.java/buggy/src/java/org/jivesoftware/spark/UserManager.java | |
window.dispose(); | parent.setGlassPane(glassPane); parent.getGlassPane().setVisible(false); contactField.dispose(); | public void searchContacts(String contact, JFrame parent) { final Map contactMap = new HashMap(); final Set contacts = new HashSet(); final ContactList contactList = SparkManager.getWorkspace().getContactList(); Iterator groups = contactList.getContactGroups().iterator(); while (g... | 52006 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52006/274dbf0ef077e2132bf5036ee54b9dbe4b819268/UserManager.java/buggy/src/java/org/jivesoftware/spark/UserManager.java |
parent.setGlassPane(mainPanel); parent.getGlassPane().setVisible(true); contactField.focus(); mainPanel.addMouseListener(new MouseAdapter() { public void mouseClicked(MouseEvent mouseEvent) { parent.setGlassPane(glassPane); parent.getGlassPane().setVisible(false); contactField.dispose(); } }); parent.addWindowListene... | public void searchContacts(String contact, JFrame parent) { final Map contactMap = new HashMap(); final Set contacts = new HashSet(); final ContactList contactList = SparkManager.getWorkspace().getContactList(); Iterator groups = contactList.getContactGroups().iterator(); while (g... | 52006 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52006/274dbf0ef077e2132bf5036ee54b9dbe4b819268/UserManager.java/buggy/src/java/org/jivesoftware/spark/UserManager.java | |
runtime.getModule("Kernel").callMethod(runtime.getCurrentContext(),"require",runtime.newString("digest.so")); | runtime.getLoadService().require("digest.so"); | public static void createDigestMD5(IRuby runtime) { runtime.getModule("Kernel").callMethod(runtime.getCurrentContext(),"require",runtime.newString("digest.so")); RubyModule mDigest = runtime.getModule("Digest"); RubyClass cDigestBase = mDigest.getClass("Base"); RubyClass cDigest_MD5 = mD... | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/fe11f82bc6236dc6746a228a50d4bac6d467618e/RubyDigest.java/clean/src/org/jruby/RubyDigest.java |
runtime.getModule("Kernel").callMethod(runtime.getCurrentContext(),"require",runtime.newString("digest.so")); | runtime.getLoadService().require("digest.so"); | public static void createDigestRMD160(IRuby runtime) { runtime.getModule("Kernel").callMethod(runtime.getCurrentContext(),"require",runtime.newString("digest.so")); RubyModule mDigest = runtime.getModule("Digest"); RubyClass cDigestBase = mDigest.getClass("Base"); RubyClass cDigest_RMD16... | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/fe11f82bc6236dc6746a228a50d4bac6d467618e/RubyDigest.java/clean/src/org/jruby/RubyDigest.java |
runtime.getModule("Kernel").callMethod(runtime.getCurrentContext(),"require",runtime.newString("digest.so")); | runtime.getLoadService().require("digest.so"); | public static void createDigestSHA1(IRuby runtime) { runtime.getModule("Kernel").callMethod(runtime.getCurrentContext(),"require",runtime.newString("digest.so")); RubyModule mDigest = runtime.getModule("Digest"); RubyClass cDigestBase = mDigest.getClass("Base"); RubyClass cDigest_SHA1 = ... | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/fe11f82bc6236dc6746a228a50d4bac6d467618e/RubyDigest.java/clean/src/org/jruby/RubyDigest.java |
runtime.getModule("Kernel").callMethod(runtime.getCurrentContext(),"require",runtime.newString("digest.so")); | runtime.getLoadService().require("digest.so"); | public static void createDigestSHA2(IRuby runtime) { try { MessageDigest.getInstance("SHA-256"); } catch(NoSuchAlgorithmException e) { throw runtime.newLoadError("SHA2 not supported"); } runtime.getModule("Kernel").callMethod(runtime.getCurrentContext(),"require",ru... | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/fe11f82bc6236dc6746a228a50d4bac6d467618e/RubyDigest.java/clean/src/org/jruby/RubyDigest.java |
if(factor != -1) | if (factor != -1) | public void setZoomFactor(double factor) { if(factor != -1) { if (factor > ZoomAction.MAX_ZOOM_FACTOR || factor < ZoomAction.MIN_ZOOM_FACTOR) throw new IllegalArgumentException("The zoom factor is value " + "between "+ZoomAction.MIN_ZOOM_FACTOR+" and "+ ... | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/54a6dc1cc81e06c2190546075a6c5a04f18d9bb5/BrowserComponent.java/buggy/SRC/org/openmicroscopy/shoola/agents/imviewer/browser/BrowserComponent.java |
return match.isNil() ? match : ((RubyMatchData) match).group(n); | IRubyObject nil = match.getRuntime().getNil(); if (match.isNil()) { return nil; } RubyMatchData rmd = (RubyMatchData) match; if (n > rmd.getSize()) { return nil; } if (n < 0) { n += rmd.getSize(); if (n <= 0) { return nil; } } return rmd.group(n); | public static IRubyObject nth_match(int n, IRubyObject match) { return match.isNil() ? match : ((RubyMatchData) match).group(n); } | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/ccaba8b36154afea86c2482886e84c7df5ddad99/RubyRegexp.java/buggy/src/org/jruby/RubyRegexp.java |
dispatcher.addLoadListener(treePanel); | public void modelChanged(HeatMapModel model) { if(model == null) { return; } this.model = model; setTitle("HeatMap: " + model.getInfoSource().getDataset().getName()); treePanel.setModel(model.getModel()); treePanel.removeListener(dispatcher); mod... | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/b50398c0db3353156748a8d1155216615e5ba5d0/HeatMapUI.java/clean/SRC/org/openmicroscopy/shoola/agents/browser/heatmap/HeatMapUI.java | |
setDatasets( new HashSet( i.eachLinkedDataset( block ))); setAllPixels( new HashSet( i.collectPixels( block ))); setAnnotations( new HashSet( i.collectAnnotations( block ))); | setDatasets( makeSet( i.sizeOfDatasetLinks(), i.eachLinkedDataset( block ))); setAllPixels( makeSet( i.sizeOfPixels(), i.collectPixels( block ))); setAnnotations( makeSet( i.sizeOfAnnotations(), i.collectAnnotations( block ))); | public void copy(IObject model, ModelMapper mapper) { if (model instanceof Image) { Image i = (Image) model; super.copy(model,mapper); // Details if (i.getDetails() != null){ Details d = i.getDetails(); this.setCreated(mapper.event2tim... | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/9638b50efec05ce0b3d19bbef1c149c757b964aa/ImageData.java/clean/components/shoola-adapter/src/pojos/ImageData.java |
imgsAnn1 = getPercentOfCollection(allImgs, percent); imgsAnn2 = getPercentOfCollection(allImgs, percent); dsAnn1 = getPercentOfCollection(allDss, percent); dsAnn2 = getPercentOfCollection(allDss, percent); | imgsAnn1 = getImageAnnotations(); imgsAnn2 = getImageAnnotations(); dsAnn1 = getDatasetAnnotations(); dsAnn2 = getDatasetAnnotations(); | public OMEData init() { // Test data : calculated before to not change times. if (!initialized) { super.init(); imgsPDI = getPercentOfCollection(allImgs, percent); imgsCGCI = getPercentOfCollection(allImgs, percent); imgsAnn1 = getPercentOfCollection(allImgs... | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/fe14dc19a3cb8aef0082070000d68b42a88ac770/OMEPerformanceData.java/buggy/components/common/src/org/openmicroscopy/omero/tests/OMEPerformanceData.java |
return Collections.EMPTY_LIST; | return EMPTY_LIST; | public List childNodes() { return Collections.EMPTY_LIST; } | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/b1293eda8454686e846e2a9837b348e2983bb423/RedoNode.java/buggy/src/org/jruby/ast/RedoNode.java |
setImages( new HashSet( d.collectFromImageLinks( block ))); setProjects( new HashSet( d.collectFromProjectLinks( block ))); setAnnotations( new HashSet( d.collectFromAnnotations( block ))); | setImages( new HashSet( d.eachLinkedImage( block ))); setProjects( new HashSet( d.eachLinkedProject( block ))); setAnnotations( new HashSet( d.collectAnnotations( block ))); | public void copy(IObject model, ModelMapper mapper) { if (model instanceof Dataset) { Dataset d = (Dataset) model; super.copy(model,mapper); // Details if (d.getDetails() != null){ Details details = d.getDetails(); this.setOwner((E... | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/7b5c704279f82fa929138305f70f2f5e6b462c69/DatasetData.java/clean/components/shoola-adapter/src/pojos/DatasetData.java |
return Character.toUpperCase(c) == c; | return Character.isUpperCase(c); | private boolean ISUPPER(char c) { return Character.toUpperCase(c) == c; } | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/234d6392b23389a9ae2098c62e66618404979d3c/RubyYaccLexer.java/clean/src/org/jruby/lexer/yacc/RubyYaccLexer.java |
System.out .println(" ***** HierarchyBrowsingTest.testFindCGCIHierarchies() *****"); Set ids = new HashSet(); ids.add(new Integer(19)); ids.add(new Integer(13)); ids.add(new Integer(11)); Set result = hb.findCGCIHierarchies(ids); | public void testFindCGCIHierarchies() { } | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/8442e37c365d8ade04f3bf94b6b000049c740d2a/HierarchyBrowsingTest.java/clean/components/wars/srv/src/test/org/ome/omero/tests/HierarchyBrowsingTest.java | |
.println("HierarchyBrowsingTest.testFindImageAnnotationsSet()"); | .println(" ***** HierarchyBrowsingTest.testFindImageAnnotationsSet()"); | public void testFindImageAnnotationsSet() { System.out .println("HierarchyBrowsingTest.testFindImageAnnotationsSet()"); Set ids = new HashSet(); ids.add(new Integer(11)); ids.add(new Integer(13)); Map map = hb.findImageAnnotations(ids); assertTrue(nonNull, ma... | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/8442e37c365d8ade04f3bf94b6b000049c740d2a/HierarchyBrowsingTest.java/clean/components/wars/srv/src/test/org/ome/omero/tests/HierarchyBrowsingTest.java |
Map map = hb.findImageAnnotations(ids,5); | Map map = hb.findImageAnnotationsForExperimenter(ids,5); | public void testFindImageAnnotationsSetint() { System.out.println(" ***** HierarchyBrowsingTest.testFindImageAnnotationsSetint()"); Set ids = new HashSet(); ids.add(new Integer(11)); ids.add(new Integer(13)); Map map = hb.findImageAnnotations(ids,5); assertTrue(nonNull, map... | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/8442e37c365d8ade04f3bf94b6b000049c740d2a/HierarchyBrowsingTest.java/clean/components/wars/srv/src/test/org/ome/omero/tests/HierarchyBrowsingTest.java |
assertTrue(emptyColl,hb.findDatasetAnnotations(test,nonExp).size()==0); assertTrue(emptyColl,hb.findDatasetAnnotations(new HashSet(),nonExp).size()==0); | assertTrue(emptyColl,hb.findDatasetAnnotationsForExperimenter(test,nonExp).size()==0); assertTrue(emptyColl,hb.findDatasetAnnotationsForExperimenter(new HashSet(),nonExp).size()==0); | public void testNulls(){ // Each method should return a null or an empty set as appropriate //TODO hb.findCGCIHierarchies( ); Set test = new HashSet(); test.add(new Integer(0)); // Non-existence set of ids int nonExp = 0; // Non-existence experimenter ID // a... | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/8442e37c365d8ade04f3bf94b6b000049c740d2a/HierarchyBrowsingTest.java/clean/components/wars/srv/src/test/org/ome/omero/tests/HierarchyBrowsingTest.java |
assertTrue(emptyColl,hb.findImageAnnotations(test,nonExp).size()==0); assertTrue(emptyColl,hb.findImageAnnotations(new HashSet(),nonExp).size()==0); | assertTrue(emptyColl,hb.findImageAnnotationsForExperimenter(test,nonExp).size()==0); assertTrue(emptyColl,hb.findImageAnnotationsForExperimenter(new HashSet(),nonExp).size()==0); | public void testNulls(){ // Each method should return a null or an empty set as appropriate //TODO hb.findCGCIHierarchies( ); Set test = new HashSet(); test.add(new Integer(0)); // Non-existence set of ids int nonExp = 0; // Non-existence experimenter ID // a... | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/8442e37c365d8ade04f3bf94b6b000049c740d2a/HierarchyBrowsingTest.java/clean/components/wars/srv/src/test/org/ome/omero/tests/HierarchyBrowsingTest.java |
public void setRefreshedHierarchy(Map set); | public void setRefreshedHierarchy(Map set, List expandedTopNodes); | public void setRefreshedHierarchy(Map set); | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/e14deebd64382fe7de32f39ea661a766a7294394/Browser.java/clean/SRC/org/openmicroscopy/shoola/agents/treeviewer/browser/Browser.java |
if (lastCategoryBox != null) lastCategoryBox.setHighlighted(false); | public void setLastCategoryBox(CategoryBox box) { lastCategoryBox=box; } | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/cb1fb5defd26379ab79c70ff78de6749a254d163/ModulePaletteEventHandler.java/buggy/SRC/org/openmicroscopy/shoola/agents/chainbuilder/piccolo/ModulePaletteEventHandler.java | |
super(name); | super(name); | public TestRubyHash(String name) { super(name); } | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/2f13ba47385b7584839c7f6f6f1abfee251cbe53/TestRubyHash.java/clean/org/jruby/test/TestRubyHash.java |
ruby = Ruby.getDefaultInstance(GNURegexpAdapter.class); eval("$h = {'foo' => 'bar'}"); | ruby = Ruby.getDefaultInstance(GNURegexpAdapter.class); eval("$h = {'foo' => 'bar'}"); | public void setUp() { ruby = Ruby.getDefaultInstance(GNURegexpAdapter.class); eval("$h = {'foo' => 'bar'}"); } | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/2f13ba47385b7584839c7f6f6f1abfee251cbe53/TestRubyHash.java/clean/org/jruby/test/TestRubyHash.java |
super.tearDown(); | super.tearDown(); | public void tearDown() { super.tearDown(); } | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/2f13ba47385b7584839c7f6f6f1abfee251cbe53/TestRubyHash.java/clean/org/jruby/test/TestRubyHash.java |
result = eval("hash = {'a', 100}; p hash"); assertEquals("{\"a\"=>100}", result); result = eval("hash = Hash['b', 200]; p hash"); assertEquals("{\"b\"=>200}", result); result = eval("hash = Hash.new(); p hash['test']"); assertEquals("nil", result); result = eval("hash = Hash.new('default'); p hash['test']"); assertEqua... | result = eval("hash = {'a', 100}; p hash"); assertEquals("{\"a\"=>100}", result); result = eval("hash = Hash['b', 200]; p hash"); assertEquals("{\"b\"=>200}", result); result = eval("hash = Hash.new(); p hash['test']"); assertEquals("nil", result); result = eval("hash = Hash.new('default'); p hash['test']"); assertEqua... | public void testConstructors() { result = eval("hash = {'a', 100}; p hash"); assertEquals("{\"a\"=>100}", result); result = eval("hash = Hash['b', 200]; p hash"); assertEquals("{\"b\"=>200}", result); result = eval("hash = Hash.new(); p hash['test']"); assertEquals("nil", result); result = eval("hash = Hash.new('de... | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/2f13ba47385b7584839c7f6f6f1abfee251cbe53/TestRubyHash.java/clean/org/jruby/test/TestRubyHash.java |
result = eval("p $h.to_s"); assertEquals("\"foobar\"", result); result = eval("p $h.to_a"); assertEquals("[[\"foo\", \"bar\"]]", result); result = eval("p $h.to_hash"); assertEquals("{\"foo\"=>\"bar\"}", result); | result = eval("p $h.to_s"); assertEquals("\"foobar\"", result); result = eval("p $h.to_a"); assertEquals("[[\"foo\", \"bar\"]]", result); result = eval("p $h.to_hash"); assertEquals("{\"foo\"=>\"bar\"}", result); | public void testConversions() { result = eval("p $h.to_s"); assertEquals("\"foobar\"", result); result = eval("p $h.to_a"); assertEquals("[[\"foo\", \"bar\"]]", result); result = eval("p $h.to_hash"); assertEquals("{\"foo\"=>\"bar\"}", result); } | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/2f13ba47385b7584839c7f6f6f1abfee251cbe53/TestRubyHash.java/clean/org/jruby/test/TestRubyHash.java |
result = eval("key = 'a'; hash = {key => 'one'}; hash.store('a', 'two'); puts hash[key]"); assertEquals("two", result); result = eval("key = [1,2]; hash = {key => 'one'}; hash[[1,2]] = 'two'; puts hash[key]"); assertEquals("two", result); result = eval("key = :a; hash = {key => 'one'}; hash[:a] = 'two'; puts hash[key]... | result = eval("key = 'a'; hash = {key => 'one'}; hash.store('a', 'two'); puts hash[key]"); assertEquals("two", result); result = eval("key = [1,2]; hash = {key => 'one'}; hash[[1,2]] = 'two'; puts hash[key]"); assertEquals("two", result); result = eval("key = :a; hash = {key => 'one'}; hash[:a] = 'two'; puts hash[key]... | public void testLookups() { // value equality result = eval("key = 'a'; hash = {key => 'one'}; hash.store('a', 'two'); puts hash[key]"); assertEquals("two", result); result = eval("key = [1,2]; hash = {key => 'one'}; hash[[1,2]] = 'two'; puts hash[key]"); assertEquals("two", result); result = eval("key = :a; hash =... | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/2f13ba47385b7584839c7f6f6f1abfee251cbe53/TestRubyHash.java/clean/org/jruby/test/TestRubyHash.java |
assertEquals("1", eval("p $h.size")); assertEquals("1", eval("p $h.length")); assertEquals("false", eval("p $h.empty?")); assertEquals("true", eval("p Hash.new().empty?")); | assertEquals("1", eval("p $h.size")); assertEquals("1", eval("p $h.length")); assertEquals("false", eval("p $h.empty?")); assertEquals("true", eval("p Hash.new().empty?")); | public void testSizeRelated() { assertEquals("1", eval("p $h.size")); assertEquals("1", eval("p $h.length")); assertEquals("false", eval("p $h.empty?")); assertEquals("true", eval("p Hash.new().empty?")); } | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/2f13ba47385b7584839c7f6f6f1abfee251cbe53/TestRubyHash.java/clean/org/jruby/test/TestRubyHash.java |
assertEquals("one", result); | assertEquals("two", result); | public void testLookups() throws Exception { // value equality result = eval("key = 'a'; hash = {key => 'one'}; hash.store('a', 'two'); puts hash[key]"); assertEquals("two", result); result = eval("key = [1,2]; hash = {key => 'one'}; hash[[1,2]] = 'two'; puts hash[key]"); assertEq... | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/0b86f0ad945c40a2e636cf5fb1fcd554ed1de38d/TestRubyHash.java/buggy/test/org/jruby/test/TestRubyHash.java |
getClasses().putClass(name, newModule); | getClasses().putClass(name, newModule, parentModule); | public RubyModule defineModuleUnder(String name, RubyModule parentModule) { RubyModule newModule = RubyModule.newModule(this, name, parentModule); getClasses().putClass(name, newModule); return newModule; } | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/750e66982e97bcb72545a39ceacf6ee32a52a135/Ruby.java/clean/src/org/jruby/Ruby.java |
runtime.getLoadService().init(runtime, commandline.loadPaths()); | runtime.getLoadService().init(commandline.loadPaths()); | private static void initializeRuntime(final Ruby runtime, String filename) { IRubyObject argumentArray = runtime.newArray(JavaUtil.convertJavaArrayToRuby(runtime, commandline.scriptArguments)); runtime.setVerbose(runtime.newBoolean(commandline.verbose)); // $VERBOSE can be true, false, or nil. ... | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/61503e7396c70acb6ed9f50922ff044d1fcc4bcc/Main.java/buggy/src/org/jruby/Main.java |
if (isNil()) { return getNilSingletonClass(); } | public MetaClass getSingletonClass() { if (isNil()) { return getNilSingletonClass(); } RubyClass type = getMetaClass(); if (!type.isSingleton()) { type = makeMetaClass(getMetaClass()); } assert type instanceof MetaClass; type.setTaint(isTaint(... | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/32d84ae899fd3c367ef3800d0984b69f53209031/RubyObject.java/clean/src/org/jruby/RubyObject.java | |
type = makeMetaClass(getMetaClass()); | type = makeMetaClass(type, getRuntime().getCurrentContext().getRubyClass()); | public MetaClass getSingletonClass() { if (isNil()) { return getNilSingletonClass(); } RubyClass type = getMetaClass(); if (!type.isSingleton()) { type = makeMetaClass(getMetaClass()); } assert type instanceof MetaClass; type.setTaint(isTaint(... | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/32d84ae899fd3c367ef3800d0984b69f53209031/RubyObject.java/clean/src/org/jruby/RubyObject.java |
type.setTaint(isTaint()); type.setFrozen(isFrozen()); | if (!isNil()) { type.setTaint(isTaint()); type.setFrozen(isFrozen()); } | public MetaClass getSingletonClass() { if (isNil()) { return getNilSingletonClass(); } RubyClass type = getMetaClass(); if (!type.isSingleton()) { type = makeMetaClass(getMetaClass()); } assert type instanceof MetaClass; type.setTaint(isTaint(... | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/32d84ae899fd3c367ef3800d0984b69f53209031/RubyObject.java/clean/src/org/jruby/RubyObject.java |
public MetaClass makeMetaClass(RubyClass type) { MetaClass metaClass = type.newSingletonClass(); setMetaClass(metaClass); | public MetaClass makeMetaClass(RubyClass type, RubyModule parentModule) { MetaClass metaClass = type.newSingletonClass(parentModule); if (!isNil()) { setMetaClass(metaClass); } | public MetaClass makeMetaClass(RubyClass type) { MetaClass metaClass = type.newSingletonClass(); setMetaClass(metaClass); metaClass.attachToObject(this); return metaClass; } | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/32d84ae899fd3c367ef3800d0984b69f53209031/RubyObject.java/clean/src/org/jruby/RubyObject.java |
suite.addTest(new TestSuite(TestRubyTime.class)); | public static Test suite() throws Throwable { TestSuite suite = new TestSuite(); suite.addTest(new TestSuite(TestRubyObject.class)); suite.addTest(new TestSuite(TestRubyNil.class)); suite.addTest(new TestSuite(TestRubyHash.class)); suite.addTest(new TestSuite(TestRubyTime.class));... | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/70d0ac3914a10ee21018f230c9b0bbf1910d47a3/MainTestSuite.java/buggy/test/org/jruby/test/MainTestSuite.java | |
suite.addTest(new TestSuite(TestRubyProxyFactory.class)); | suite.addTest(new TestSuite(TestBSF.class)); | public static Test suite() { TestSuite suite = new TestSuite(); suite.addTest(new TestSuite(TestRubyProxyFactory.class)); return suite; } | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/8c54b93def4895b998d669a089420d5925274ea0/JavaSupportTestSuite.java/buggy/test/org/jruby/javasupport/test/JavaSupportTestSuite.java |
setResourcePath(DEFAULT_RESOURCE_PATH); | setBaseFolderPath(DEFAULT_RESOURCE_PATH); | public ArticleListViewer() { super(); setBeanIdentifier(ARTICLE_LIST_BEAN); setResourcePath(DEFAULT_RESOURCE_PATH); } | 57000 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/57000/9dd8a7f9883fa3785baebfbed97ebf38eba1add9/ArticleListViewer.java/clean/src/java/com/idega/block/article/component/ArticleListViewer.java |
String name = constructorArgNames[i]; | Property name = new Property(constructorArgNames[i]); | private Object[] extractConstructorArgs(Map propertyValues, Class[] constructorArgTypes) { Object[] parameters = new Object[constructorArgNames.length]; for (int i = 0; i < constructorArgNames.length; i++) { String name = constructorArgNames[i]; Class type = constructorArgTypes[i... | 52533 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52533/8c27c0b6aebc5d1091ad9af5270f8fdd7d5ea487/ObjectRecipe.java/buggy/xbean-reflect/src/main/java/org/apache/xbean/recipe/ObjectRecipe.java |
if (name == null) throw new NullPointerException("name is null"); Object value = properties.get(name); | Object value = properties.get(new Property(name)); | public Object getProperty(String name) { if (name == null) throw new NullPointerException("name is null"); Object value = properties.get(name); return value; } | 52533 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52533/8c27c0b6aebc5d1091ad9af5270f8fdd7d5ea487/ObjectRecipe.java/buggy/xbean-reflect/src/main/java/org/apache/xbean/recipe/ObjectRecipe.java |
String str = arg.toString().trim(); double d = 0.0; int pos = str.length(); for (int i = 0; i < pos; i++) { if ("0123456789eE+-.".indexOf(str.charAt(i)) == -1) { pos = i + 1; break; } } for (; pos > 0; pos--) { try { d = Double.parseDouble(str.substring(0, pos)); } catch (NumberFormatException ex) { continue; } break; ... | return str2fnum(runtime,arg,false); | public static RubyFloat str2fnum(IRuby runtime, RubyString arg) { String str = arg.toString().trim(); double d = 0.0; int pos = str.length(); for (int i = 0; i < pos; i++) { if ("0123456789eE+-.".indexOf(str.charAt(i)) == -1) { pos = i + 1; break;... | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/a8583bc4b548ea3f09cf86cc0ce0b77670255f40/RubyNumeric.java/buggy/src/org/jruby/RubyNumeric.java |
StringBuffer sbuf = new StringBuffer(str.toString().trim()); if (sbuf.length() == 0) { return RubyFixnum.zero(runtime); } int pos = 0; int radix = (base != 0) ? base : 10; boolean digitsFound = false; if (sbuf.charAt(pos) == '-') { pos++; } else if (sbuf.charAt(pos) == '+') { sbuf.deleteCharAt(pos); } if (pos == sbuf.l... | return str2inum(runtime,str,base,false); | public static RubyInteger str2inum(IRuby runtime, RubyString str, int base) { StringBuffer sbuf = new StringBuffer(str.toString().trim()); if (sbuf.length() == 0) { return RubyFixnum.zero(runtime); } int pos = 0; int radix = (base != 0) ? base : 10; boolean digit... | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/a8583bc4b548ea3f09cf86cc0ce0b77670255f40/RubyNumeric.java/buggy/src/org/jruby/RubyNumeric.java |
RubyFixnum fn = (RubyFixnum) recv.funcall("<=>", other); return RubyBoolean.newBoolean(ruby, fn.getValue() >= 0); | return RubyNumeric.fix2int(recv.funcall("<=>", other)) >= 0 ? ruby.getTrue() : ruby.getFalse(); | public static RubyBoolean op_ge(Ruby ruby, RubyObject recv, RubyObject other) { RubyFixnum fn = (RubyFixnum) recv.funcall("<=>", other); return RubyBoolean.newBoolean(ruby, fn.getValue() >= 0); } | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/786cea08c1dd2092a02d1254b49fbee371ace5f9/RubyComparable.java/buggy/org/jruby/RubyComparable.java |
RubyFixnum fn = (RubyFixnum) recv.funcall("<=>", other); return RubyBoolean.newBoolean(ruby, fn.getValue() > 0); | return RubyNumeric.fix2int(recv.funcall("<=>", other)) > 0 ? ruby.getTrue() : ruby.getFalse(); | public static RubyBoolean op_gt(Ruby ruby, RubyObject recv, RubyObject other) { RubyFixnum fn = (RubyFixnum) recv.funcall("<=>", other); return RubyBoolean.newBoolean(ruby, fn.getValue() > 0); } | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/786cea08c1dd2092a02d1254b49fbee371ace5f9/RubyComparable.java/buggy/org/jruby/RubyComparable.java |
RubyFixnum fn = (RubyFixnum) recv.funcall("<=>", other); return RubyBoolean.newBoolean(ruby, fn.getValue() <= 0); | return RubyNumeric.fix2int(recv.funcall("<=>", other)) <= 0 ? ruby.getTrue() : ruby.getFalse(); | public static RubyBoolean op_le(Ruby ruby, RubyObject recv, RubyObject other) { RubyFixnum fn = (RubyFixnum) recv.funcall("<=>", other); return RubyBoolean.newBoolean(ruby, fn.getValue() <= 0); } | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/786cea08c1dd2092a02d1254b49fbee371ace5f9/RubyComparable.java/buggy/org/jruby/RubyComparable.java |
RubyFixnum fn = (RubyFixnum) recv.funcall("<=>", other); return RubyBoolean.newBoolean(ruby, fn.getValue() < 0); | return RubyNumeric.fix2int(recv.funcall("<=>", other)) < 0 ? ruby.getTrue() : ruby.getFalse(); | public static RubyBoolean op_lt(Ruby ruby, RubyObject recv, RubyObject other) { RubyFixnum fn = (RubyFixnum) recv.funcall("<=>", other); return RubyBoolean.newBoolean(ruby, fn.getValue() < 0); } | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/786cea08c1dd2092a02d1254b49fbee371ace5f9/RubyComparable.java/buggy/org/jruby/RubyComparable.java |
Class widestClass = returningMethod.getReturnType(); | private Class returnedObjectType(Object javaResult, Method returningMethod) { Class narrowestClass = javaResult.getClass(); Class widestClass = returningMethod.getReturnType(); if (narrowestClass.isPrimitive()) { return narrowestClass; } if (widestClass.isPrimitive()) {... | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/092ef8d477c373203f77b7d727ecd57bebff2cb7/JavaMethod.java/clean/org/jruby/javasupport/JavaMethod.java | |
} else if (List.class.isAssignableFrom(javaClass)) { return arg instanceof RubyArray; } else if (Map.class.isAssignableFrom(javaClass)) { return arg instanceof RubyHash; | public static boolean isCompatible(IRubyObject arg, Class javaClass) { if (arg.isNil()) { return true; } if (javaClass.isInstance(arg)) { // arg is already of the required jruby class (or subclass) return true; } if (javaClass == Object.class || ja... | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/05c7de156620b4e1926ea77f476287db1b42b4cc/JavaUtil.java/buggy/src/org/jruby/javasupport/JavaUtil.java | |
dup.setRubyClass(getInternalClass()); | dup.setInternalClass(getInternalClass()); | public IRubyObject dup() { RubyModule dup = (RubyModule) rbClone(); dup.setRubyClass(getInternalClass()); // +++ jpetersen // dup.setSingleton(isSingleton()); // --- jpetersen return dup; } | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/f235ab756f32ea9496f8f880066b46ad95ebb692/RubyModule.java/buggy/org/jruby/RubyModule.java |
Ruby ruby = input.getRuby(); | Ruby ruby = input.getRuntime(); | public static RubyModule unmarshalFrom(UnmarshalStream input) throws java.io.IOException { String name = input.unmarshalString(); Ruby ruby = input.getRuby(); RubyModule result = ruby.getClasses().getClassFromPath(name); if (result == null) { throw new NameError(ruby, "uniniti... | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/f235ab756f32ea9496f8f880066b46ad95ebb692/RubyModule.java/buggy/org/jruby/RubyModule.java |
ruby.setCBase(module); | public RubyObject setupModule(Ruby ruby, RubyModule module) { // Node node = n; String file = ruby.getSourceFile(); int line = ruby.getSourceLine(); // TMP_PROTECT; ruby.getRubyFrame().tmpPush(); ruby.pushClass(); ruby.setRubyClass(module); ruby.setCBase(modul... | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/d31a76ee29d5978a9bec41e3ac9134cee024bcab/ScopeNode.java/buggy/org/jruby/nodes/ScopeNode.java | |
loadService.addAutoload(symbol.asSymbol(), new IAutoloadMethod() { | final String baseName = symbol.asSymbol(); String nm = baseName; if(recv instanceof RubyModule) { nm = ((RubyModule)recv).getName() + "::" + nm; } loadService.addAutoload(nm, new IAutoloadMethod() { public String file() { return file.toString(); } | public static IRubyObject autoload(final IRubyObject recv, IRubyObject symbol, final IRubyObject file) { final LoadService loadService = recv.getRuntime().getLoadService(); loadService.addAutoload(symbol.asSymbol(), new IAutoloadMethod() { /** * @see org.jruby.runtime.load.IAuto... | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/3cd87a03d9ff599871bd14f49c218d1045bca20b/RubyKernel.java/clean/src/org/jruby/RubyKernel.java |
return ((RubyModule)recv).getConstant(name); | if(recv instanceof RubyModule) { return ((RubyModule)recv).getConstant(baseName); } return runtime.getObject().getConstant(baseName); | public static IRubyObject autoload(final IRubyObject recv, IRubyObject symbol, final IRubyObject file) { final LoadService loadService = recv.getRuntime().getLoadService(); loadService.addAutoload(symbol.asSymbol(), new IAutoloadMethod() { /** * @see org.jruby.runtime.load.IAuto... | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/3cd87a03d9ff599871bd14f49c218d1045bca20b/RubyKernel.java/clean/src/org/jruby/RubyKernel.java |
return ((RubyModule)recv).getConstant(name); | if(recv instanceof RubyModule) { return ((RubyModule)recv).getConstant(baseName); } return runtime.getObject().getConstant(baseName); | public IRubyObject load(IRuby runtime, String name) { loadService.require(file.toString()); return ((RubyModule)recv).getConstant(name); } | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/3cd87a03d9ff599871bd14f49c218d1045bca20b/RubyKernel.java/clean/src/org/jruby/RubyKernel.java |
module.definePublicModuleFunction("autoload?", callbackFactory.getSingletonMethod("autoload_p", IRubyObject.class)); | public static RubyModule createKernelModule(IRuby runtime) { RubyModule module = runtime.defineModule("Kernel"); CallbackFactory callbackFactory = runtime.callbackFactory(RubyKernel.class); CallbackFactory objectCallbackFactory = runtime.callbackFactory(RubyObject.class); module.defineMo... | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/3cd87a03d9ff599871bd14f49c218d1045bca20b/RubyKernel.java/clean/src/org/jruby/RubyKernel.java | |
{ if (null==c) { | { ds = (DataSource) applicationContext.getBean("dataSource"); if (null==c) { | protected void onSetUpInTransaction() throws Exception { if (null==c) { try { c = new DatabaseConnection(ds.getConnection()); DatabaseOperation.CLEAN_INSERT.execute(c,getData()); } catch (Exception e){ c = null; ... | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/59b11883b95c926d6706e6d30b4cdb898088683c/AbstractDbUnitTest.java/buggy/components/server/test/ome/server/dbtests/AbstractDbUnitTest.java |
protected void onSetUpInTransaction() throws Exception { if (null==c) { try { c = new DatabaseConnection(ds.getConnection()); DatabaseOperation.CLEAN_INSERT.execute(c,getData()); } catch (Exception e){ c = null; ... | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/59b11883b95c926d6706e6d30b4cdb898088683c/AbstractDbUnitTest.java/buggy/components/server/test/ome/server/dbtests/AbstractDbUnitTest.java | ||
return ACTION_ARRAY; | return super.getToolbarActions(); | public String[] getToolbarActions(){ return ACTION_ARRAY; } | 57000 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/57000/44c7553551d463f44b7cb7cf5d0a43b62412701b/ArticleItemBean.java/clean/src/java/com/idega/block/article/bean/ArticleItemBean.java |
if ((ignoreRegex != null) && (pm.matches(owner, ignoreRegex))) classData.removeLine(currentLine); | Iterator iter = ignoreRegexs.iterator(); while (iter.hasNext()) { Pattern ignoreRegex = (Pattern)iter.next(); if ((ignoreRegexs != null) && (pm.matches(owner, ignoreRegex))) { classData.removeLine(currentLine); return; } } | public void visitMethodInsn(int opcode, String owner, String name, String desc) { super.visitMethodInsn(opcode, owner, name, desc); if ((ignoreRegex != null) && (pm.matches(owner, ignoreRegex))) classData.removeLine(currentLine); } | 50197 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50197/8d76b07e3d230fcd0d3b233e7ffc80df6ca3ec82/MethodInstrumenter.java/clean/cobertura/src/net/sourceforge/cobertura/instrument/MethodInstrumenter.java |
public void addNoteTab(DisplayedNote displayedNote) { new NoteTab(tabFolder, l, displayedNote); | public NoteTab addNoteTab(DisplayedNote displayedNote) { return new NoteTab(tabFolder, l, displayedNote); | public void addNoteTab(DisplayedNote displayedNote) { new NoteTab(tabFolder, l, displayedNote); } | 57508 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/57508/a21e67d29e81a4038ecb2d55530f57396df4085c/NoteTabFolder.java/clean/trunk/src/de/berlios/koalanotes/display/NoteTabFolder.java |
text = new Text(parent, SWT.NONE); | tabItem.addDisposeListener(this); text = new Text(parent, SWT.MULTI | SWT.WRAP); | public NoteTab(final CTabFolder parent, Listener l, DisplayedNote displayedNote) { this.displayedNote = displayedNote; tabItem = new CTabItem(parent, SWT.NONE); tabItem.setText(displayedNote.getName()); tabItem.setData(this); text = new Text(parent, SWT.NONE); text.setText(displayedNote.getNote().getText()); ta... | 57508 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/57508/18ce9cf33f3e06fda4addd57f5ae5c9423a990fb/NoteTab.java/buggy/trunk/src/de/berlios/koalanotes/display/NoteTab.java |
l.mapEvent(tabItem, SWT.Dispose, MainController.CLOSE_TAB); | public NoteTab(final CTabFolder parent, Listener l, DisplayedNote displayedNote) { this.displayedNote = displayedNote; tabItem = new CTabItem(parent, SWT.NONE); tabItem.setText(displayedNote.getName()); tabItem.setData(this); text = new Text(parent, SWT.NONE); text.setText(displayedNote.getNote().getText()); ta... | 57508 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/57508/18ce9cf33f3e06fda4addd57f5ae5c9423a990fb/NoteTab.java/buggy/trunk/src/de/berlios/koalanotes/display/NoteTab.java | |
super(parameters); | super(defs, parameters); | public PojosCGCPathsQueryDefinition(QueryParameter... parameters) { super(parameters); } | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/f990a7d35ce265e182121d562725175896db41f4/PojosCGCPathsQueryDefinition.java/buggy/components/server/src/ome/services/query/PojosCGCPathsQueryDefinition.java |
WFTabBar tb = (WFTabBar) link.getParent().getParent().getParent().findComponent(MAIN_TASKBAR_ID); tb.setSelectedButtonId(TASK_ID_EDIT); | WFTabbedPane tb = (WFTabbedPane) link.getParent().getParent().getParent().findComponent(MAIN_TASKBAR_ID); tb.setSelectedMenuItemId(TASK_ID_EDIT); | public void processAction(ActionEvent event) { UIComponent link = event.getComponent(); String id = WFUtil.getParameter(link, "id"); WFTabBar tb = (WFTabBar) link.getParent().getParent().getParent().findComponent(MAIN_TASKBAR_ID); tb.setSelectedButtonId(TASK_ID_EDIT); ArticleBlock ab = (ArticleBlock) tb.findCompo... | 57000 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/57000/03557bc59a300e92911a58888cf6c73355c98f1c/ContentPerspective.java/buggy/src/java/com/idega/block/article/ContentPerspective.java |
WFTabBar tb = (WFTabBar) findComponent(MAIN_TASKBAR_ID); tb.setSelectedButtonId(TASK_ID_EDIT); | WFTabbedPane tb = (WFTabbedPane) findComponent(MAIN_TASKBAR_ID); tb.setSelectedMenuItemId(TASK_ID_EDIT); | public void setEditMode() { WFTabBar tb = (WFTabBar) findComponent(MAIN_TASKBAR_ID); tb.setSelectedButtonId(TASK_ID_EDIT); ArticleBlock ab = (ArticleBlock) tb.findComponent(ArticleBlock.ARTICLE_BLOCK_ID); ab.setEditMode(); } | 57000 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/57000/03557bc59a300e92911a58888cf6c73355c98f1c/ContentPerspective.java/buggy/src/java/com/idega/block/article/ContentPerspective.java |
ruby.getRuntime().callTraceFunction(event, file, line, self.toRubyObject(), name, type); | ruby.getRuntime().callTraceFunction(event, file, line, self, name, type); | private void callTraceFunction(String event, String file, int line, IRubyObject self, String name, IRubyObject type) { ruby.getRuntime().callTraceFunction(event, file, line, self.toRubyObject(), name, type); } | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/f235ab756f32ea9496f8f880066b46ad95ebb692/EvaluateVisitor.java/clean/org/jruby/evaluator/EvaluateVisitor.java |
result = receiver.getInternalClass().call(receiver.toRubyObject(), iVisited.getName(), args, 0); | result = receiver.getInternalClass().call(receiver, iVisited.getName(), args, 0); | public void visitCallNode(CallNode iVisited) { Block tmpBlock = ArgsUtil.beginCallArgs(ruby); IRubyObject receiver = eval(iVisited.getReceiverNode()); IRubyObject[] args = ArgsUtil.setupArgs(ruby, this, iVisited.getArgsNode()); ArgsUtil.endCallArgs(ruby, tmpBlock); result = receiv... | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/f235ab756f32ea9496f8f880066b46ad95ebb692/EvaluateVisitor.java/clean/org/jruby/evaluator/EvaluateVisitor.java |
if (expressions.entry(j).callMethod("===", expression.toRubyObject()).isTrue()) { | if (expressions.entry(j).callMethod("===", expression).isTrue()) { | public void visitCaseNode(CaseNode iVisited) { if (iVisited.getCaseNode() != null) { IRubyObject expression = eval(iVisited.getCaseNode()); Iterator iter = iVisited.getWhenNodes().iterator(); for (int i = 0, size = iVisited.getWhenNodes().size(); i < size; i++) { ... | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/f235ab756f32ea9496f8f880066b46ad95ebb692/EvaluateVisitor.java/clean/org/jruby/evaluator/EvaluateVisitor.java |
ruby.getCBase().setClassVar(iVisited.getName(), result.toRubyObject()); | ruby.getCBase().setClassVar(iVisited.getName(), result); | public void visitClassVarAsgnNode(ClassVarAsgnNode iVisited) { eval(iVisited.getValueNode()); ruby.getCBase().setClassVar(iVisited.getName(), result.toRubyObject()); } | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/f235ab756f32ea9496f8f880066b46ad95ebb692/EvaluateVisitor.java/clean/org/jruby/evaluator/EvaluateVisitor.java |
ruby.getCBase().declareClassVar(iVisited.getName(), result.toRubyObject()); | ruby.getCBase().declareClassVar(iVisited.getName(), result); | public void visitClassVarDeclNode(ClassVarDeclNode iVisited) { if (ruby.getCBase() == null) { throw new TypeError(ruby, "no class/module to define class variable"); } eval(iVisited.getValueNode()); ruby.getCBase().declareClassVar(iVisited.getName(), result.toRubyObject()); ... | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/f235ab756f32ea9496f8f880066b46ad95ebb692/EvaluateVisitor.java/clean/org/jruby/evaluator/EvaluateVisitor.java |
result = self.toRubyObject().getInternalClass().getClassVar(iVisited.getName()); | result = self.getInternalClass().getClassVar(iVisited.getName()); | public void visitClassVarNode(ClassVarNode iVisited) { if (ruby.getCBase() == null) { result = self.toRubyObject().getInternalClass().getClassVar(iVisited.getName()); } else if (!ruby.getCBase().isSingleton()) { result = ruby.getCBase().getClassVar(iVisited.getName()); } e... | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/f235ab756f32ea9496f8f880066b46ad95ebb692/EvaluateVisitor.java/clean/org/jruby/evaluator/EvaluateVisitor.java |
ruby.getRubyClass().setConstant(iVisited.getName(), eval(iVisited.getValueNode()).toRubyObject()); | ruby.getRubyClass().setConstant(iVisited.getName(), eval(iVisited.getValueNode())); | public void visitConstDeclNode(ConstDeclNode iVisited) { if (ruby.getRubyClass() == null) { throw new TypeError(ruby, "no class/module to define constant"); } ruby.getRubyClass().setConstant(iVisited.getName(), eval(iVisited.getValueNode()).toRubyObject()); } | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/f235ab756f32ea9496f8f880066b46ad95ebb692/EvaluateVisitor.java/clean/org/jruby/evaluator/EvaluateVisitor.java |
result = ruby.getCurrentFrame().getNamespace().getConstant(self.toRubyObject(), iVisited.getName()); | result = ruby.getCurrentFrame().getNamespace().getConstant(self, iVisited.getName()); | public void visitConstNode(ConstNode iVisited) { result = ruby.getCurrentFrame().getNamespace().getConstant(self.toRubyObject(), iVisited.getName()); } | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/f235ab756f32ea9496f8f880066b46ad95ebb692/EvaluateVisitor.java/clean/org/jruby/evaluator/EvaluateVisitor.java |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.