rem
stringlengths
0
477k
add
stringlengths
0
313k
context
stringlengths
6
599k
meta
stringlengths
141
403
getRuntime().getClasses().putClass(name, newClass);
runtime.getClasses().putClass(name, newClass, parentModule);
public RubyClass newSubClass(String name, RubyModule parentModule) { RubyClass newClass = new RubyClass(getRuntime(), getRuntime().getClasses().getClassClass(), this, parentModule, name); newClass.makeMetaClass(getMetaClass()); newClass.inheritedBy(this); getRuntime().getClasses().putCla...
50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/750e66982e97bcb72545a39ceacf6ee32a52a135/RubyClass.java/clean/src/org/jruby/RubyClass.java
IconManager icons = IconManager.getInstance(); putValue(Action.SMALL_ICON, icons.getIcon(IconManager.FLAT_LAYOUT));
public FlatLayoutAction(HiViewer model) { super(model); setEnabled(true); putValue(Action.NAME, NAME); //String description = // LayoutFactory.getLayoutDescription(LayoutFactory.FLAT_LAYOUT); putValue(Action.SHORT_DESCRIPTION, ""); }
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/ea7509babe2344eb702969105eb77096cc5b6bcf/FlatLayoutAction.java/buggy/SRC/org/openmicroscopy/shoola/agents/hiviewer/actions/FlatLayoutAction.java
GroupData g = (GroupData) it.next(); e.linkExperimenterGroup((ExperimenterGroup) mapper.map(g));
GroupData gd = (GroupData) it.next(); ExperimenterGroup g = (ExperimenterGroup) mapper.map( gd ); if ( ! linked( g.findGroupExperimenterMap( e ))) e.linkExperimenterGroup( g );
public IObject fillIObject( IObject obj, ReverseModelMapper mapper) { if ( obj instanceof Experimenter) { Experimenter e = (Experimenter) obj; if (super.fill(e)) { e.setFirstName(this.getFirstName()); e.setLastName(this.getLastName()); ...
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/b7d44d4a82558acd2336a661072dda1f38cfc0b3/ExperimenterData.java/buggy/components/shoola-adapter/src/pojos/ExperimenterData.java
System.err.println(attributes.get(0)); getAnnotationManager().annotateAttributes(attributes);
getAnnotationManager().annotateAttributes(attributes);
void annotateAttributesData(List attributes) throws DSOutOfServiceException, DSAccessException { try { System.err.println(attributes.get(0)); getAnnotationManager().annotateAttributes(attributes); } catch (RemoteConnectionException rce) { throw new DSOutOfServiceException("Can't connect to OMEDS", rc...
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/f5113c7a4ff99bcbee06e1b48554259a952e1a44/OMEDSGateway.java/buggy/SRC/org/openmicroscopy/shoola/env/data/OMEDSGateway.java
rsee.printStackTrace();
Object retrieveData(Class dto, Criteria c) throws DSOutOfServiceException, DSAccessException { Object retVal; try { retVal = getDataFactory().retrieve(dto, c); } catch (RemoteConnectionException rce) { throw new DSOutOfServiceException("Can't connect to OMEDS", rce); } catch (RemoteAuth...
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/f5113c7a4ff99bcbee06e1b48554259a952e1a44/OMEDSGateway.java/buggy/SRC/org/openmicroscopy/shoola/env/data/OMEDSGateway.java
rsee.printStackTrace();
Object retrieveListSTSData(String semanticTypeName, Criteria c) throws DSOutOfServiceException, DSAccessException { Object retVal; try { retVal = getDataFactory().retrieveList(semanticTypeName, c); } catch (RemoteConnectionException rce) { throw new DSOutOfServiceException("Can't connect to OMEDS", rce); ...
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/f5113c7a4ff99bcbee06e1b48554259a952e1a44/OMEDSGateway.java/buggy/SRC/org/openmicroscopy/shoola/env/data/OMEDSGateway.java
rsee.printStackTrace();
Object retrieveSTSData(String semanticTypeName, Criteria c) throws DSOutOfServiceException, DSAccessException { Object retVal; try { retVal = getDataFactory().retrieve(semanticTypeName, c); } catch (RemoteConnectionException rce) { throw new DSOutOfServiceException("Can't connect to OMEDS", rce); } catch (...
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/f5113c7a4ff99bcbee06e1b48554259a952e1a44/OMEDSGateway.java/buggy/SRC/org/openmicroscopy/shoola/env/data/OMEDSGateway.java
public ImagePlate(Integer attributeId, String well, Integer sample, org.openmicroscopy.omero.model.Image image, org.openmicroscopy.omero.model.ModuleExecution moduleExecution) { this.attributeId = attributeId; this.well = well; this.sample = sample; this.image = image; this.moduleExecution = moduleExecution;
public ImagePlate() {
public ImagePlate(Integer attributeId, String well, Integer sample, org.openmicroscopy.omero.model.Image image, org.openmicroscopy.omero.model.ModuleExecution moduleExecution) { this.attributeId = attributeId; this.well = well; this.sample = sample; this.image = image; this.module...
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/9570ef74198a070d72e77c417c9d25244a942de2/ImagePlate.java/buggy/components/common/src/org/openmicroscopy/omero/model/ImagePlate.java
return new RangeDefinition(ruby).getType();
RubyClass result = ruby.defineClass("Range", ruby.getClasses().getObjectClass()); CallbackFactory callbackFactory = ruby.callbackFactory(); result.includeModule(ruby.getClasses().getEnumerableModule()); result.defineMethod("==", callbackFactory.getMethod(RubyRange.class, "equal", IRubyObject.class)); result.defineMet...
public static RubyClass createRangeClass(Ruby ruby) { return new RangeDefinition(ruby).getType(); }
50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/1c602493a83e2050f401fa6925ec7e9269b45e4e/RubyRange.java/clean/src/org/jruby/RubyRange.java
buf.append(sep.getValue());
buf.append(sep.toString());
public RubyString join(RubyString sep) { StringBuffer buf = new StringBuffer(); int length = getLength(); if (length == 0) { getRuntime().newString(""); } boolean taint = isTaint() || sep.isTaint(); RubyString str; IRubyObject tmp = null; for (long ...
50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/9f2efc63a858fa0507245b207025eab027840a04/RubyArray.java/clean/src/org/jruby/RubyArray.java
buf.append(((RubyString)tmp).getValue());
buf.append(((RubyString)tmp).toString());
public RubyString join(RubyString sep) { StringBuffer buf = new StringBuffer(); int length = getLength(); if (length == 0) { getRuntime().newString(""); } boolean taint = isTaint() || sep.isTaint(); RubyString str; IRubyObject tmp = null; for (long ...
50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/9f2efc63a858fa0507245b207025eab027840a04/RubyArray.java/clean/src/org/jruby/RubyArray.java
createFixnumCache();
private void callInits() { classes = new RubyClasses(this); classes.initCoreClasses(); exceptions = new RubyExceptions(this); exceptions.initDefaultExceptionClasses(); rubyTopSelf = new RubyObject(this, classes.getObjectClass()); /*rubyTopSelf.defineSingletonMethod("to_s", ...
50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/786cea08c1dd2092a02d1254b49fbee371ace5f9/Ruby.java/clean/org/jruby/Ruby.java
} catch (BreakException bExcptn) {
} catch (BreakJump bExcptn) {
public RubyObject iterate(Callback iterateMethod, RubyObject data1, Callback blockMethod, RubyObject data2) { Node node = new NodeFactory(this).newIFunc(blockMethod, data2); // VALUE self = ruby_top_self; getIter().push(RubyIter.ITER_PRE); getBlock().push(null, node, getRubyTopSelf()); ...
50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/786cea08c1dd2092a02d1254b49fbee371ace5f9/Ruby.java/clean/org/jruby/Ruby.java
sb.append(_content[i].toString());
sb.append(_content[i] == null ? "null" : _content[i].toString());
public String toString() { StringBuffer sb = new StringBuffer(); sb.append("("); for (int i = 0; i < _content.length; i++) { if (i != 0) { sb.append(", "); } sb.append(_content[i].toString()); } sb.append(")"); return sb.toString(); }
52513 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52513/8c5d4a5eb42f1bccebd7bbb160d17c0002a8e147/ListBuilder.java/buggy/webmacro/src/org/webmacro/engine/ListBuilder.java
private BufferedImage createBufferedImage(RGBBuffer buf, int sizeX, int sizeY)
private BufferedImage createBufferedImage(int[] buf, int sizeX, int sizeY)
private BufferedImage createBufferedImage(RGBBuffer buf, int sizeX, int sizeY) { RGBByteBuffer j2DBuf = new RGBByteBuffer(buf, sizeX, sizeY); BandedSampleModel csm = new BandedSampleModel(DataBuffer.TYPE_BYTE, sizeX, sizeY, 3); BufferedImage image = new BufferedImage(si...
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/64e6d912272b039f986c1a36d1ca930cc5578578/ThumbImpl.java/clean/components/server/src/ome/logic/ThumbImpl.java
RGBByteBuffer j2DBuf = new RGBByteBuffer(buf, sizeX, sizeY); BandedSampleModel csm = new BandedSampleModel(DataBuffer.TYPE_BYTE, sizeX, sizeY, 3);
DataBuffer j2DBuf = new DataBufferInt(buf, sizeX * sizeY, 0); SinglePixelPackedSampleModel sampleModel = new SinglePixelPackedSampleModel( DataBuffer.TYPE_INT, sizeX, sizeY, sizeX, new int[] { 0x00ff0000, 0x0000ff00, 0x000000ff, }); WritableRaster raster = new IntegerInterleavedRaster(sampleModel, j2DBuf, new P...
private BufferedImage createBufferedImage(RGBBuffer buf, int sizeX, int sizeY) { RGBByteBuffer j2DBuf = new RGBByteBuffer(buf, sizeX, sizeY); BandedSampleModel csm = new BandedSampleModel(DataBuffer.TYPE_BYTE, sizeX, sizeY, 3); BufferedImage image = new BufferedImage(si...
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/64e6d912272b039f986c1a36d1ca930cc5578578/ThumbImpl.java/clean/components/server/src/ome/logic/ThumbImpl.java
new BufferedImage(sizeX, sizeY, BufferedImage.TYPE_INT_RGB); image.setData(Raster.createWritableRaster(csm, j2DBuf, null));
new BufferedImage(colorModel, raster, false, null);
private BufferedImage createBufferedImage(RGBBuffer buf, int sizeX, int sizeY) { RGBByteBuffer j2DBuf = new RGBByteBuffer(buf, sizeX, sizeY); BandedSampleModel csm = new BandedSampleModel(DataBuffer.TYPE_BYTE, sizeX, sizeY, 3); BufferedImage image = new BufferedImage(si...
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/64e6d912272b039f986c1a36d1ca930cc5578578/ThumbImpl.java/clean/components/server/src/ome/logic/ThumbImpl.java
/* Unfortunately, the following creates "CUSTOM" buffered images which with some VM's cannot be used in the ImagingLib. Nasty. ColorModel cm = new ComponentColorModel( ColorSpace.getInstance(ColorSpace.CS_sRGB), null, false, false, Transparency.OPAQUE, DataBuffer.TYPE_BYTE); WritableRaster r = Raster.createWritableRa...
private BufferedImage createBufferedImage(RGBBuffer buf, int sizeX, int sizeY) { RGBByteBuffer j2DBuf = new RGBByteBuffer(buf, sizeX, sizeY); BandedSampleModel csm = new BandedSampleModel(DataBuffer.TYPE_BYTE, sizeX, sizeY, 3); BufferedImage image = new BufferedImage(si...
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/64e6d912272b039f986c1a36d1ca930cc5578578/ThumbImpl.java/clean/components/server/src/ome/logic/ThumbImpl.java
RGBBuffer buf = re.render(pd);
int[] buf = re.renderAsPackedInt(pd);
private BufferedImage createScaledImage(Pixels pixels, RenderingDef def, Integer sizeX, Integer sizeY) { // Original sizes and thumbnail metadata int origSizeX = pixels.getSizeX(); int origSizeY = pixels.getSizeY(); // Retrieve our rendered data and translate to a...
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/64e6d912272b039f986c1a36d1ca930cc5578578/ThumbImpl.java/clean/components/server/src/ome/logic/ThumbImpl.java
if (y != null && y > getSizeY())
if (y != null && (y > getSizeY() - 1 || y < 0))
private void checkBounds(Integer y, Integer z, Integer c, Integer t) throws DimensionsOutOfBoundsException { if (y != null && y > getSizeY()) throw new DimensionsOutOfBoundsException("Y '" + y + "' greater than height '" + getSizeY() + "'."); if (z != nu...
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/ece0c50ab6ed7bb25e80ce4af99ead35eda41b0d/PixelBuffer.java/buggy/components/omeio-nio/src/ome/io/nio/PixelBuffer.java
if (z != null && z > getSizeZ())
if (z != null && (z > getSizeZ() - 1 || z < 0))
private void checkBounds(Integer y, Integer z, Integer c, Integer t) throws DimensionsOutOfBoundsException { if (y != null && y > getSizeY()) throw new DimensionsOutOfBoundsException("Y '" + y + "' greater than height '" + getSizeY() + "'."); if (z != nu...
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/ece0c50ab6ed7bb25e80ce4af99ead35eda41b0d/PixelBuffer.java/buggy/components/omeio-nio/src/ome/io/nio/PixelBuffer.java
if (c != null && c > getSizeC())
if (c != null && (c > getSizeC() - 1 || c < 0))
private void checkBounds(Integer y, Integer z, Integer c, Integer t) throws DimensionsOutOfBoundsException { if (y != null && y > getSizeY()) throw new DimensionsOutOfBoundsException("Y '" + y + "' greater than height '" + getSizeY() + "'."); if (z != nu...
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/ece0c50ab6ed7bb25e80ce4af99ead35eda41b0d/PixelBuffer.java/buggy/components/omeio-nio/src/ome/io/nio/PixelBuffer.java
if (t != null && t > getSizeT())
if (t != null && (t > getSizeT() - 1 || t < 0))
private void checkBounds(Integer y, Integer z, Integer c, Integer t) throws DimensionsOutOfBoundsException { if (y != null && y > getSizeY()) throw new DimensionsOutOfBoundsException("Y '" + y + "' greater than height '" + getSizeY() + "'."); if (z != nu...
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/ece0c50ab6ed7bb25e80ce4af99ead35eda41b0d/PixelBuffer.java/buggy/components/omeio-nio/src/ome/io/nio/PixelBuffer.java
return RubyFixnum.newFixnum(getRuby(), symbol.hashCode());
return id();
public RubyFixnum hash() { return RubyFixnum.newFixnum(getRuby(), symbol.hashCode()); }
50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/0d05f52f4b20deb7938755dd220bb81c2c2b208e/RubySymbol.java/clean/org/jruby/RubySymbol.java
if (args != null && args.length == 0) {
if (args == null || args.length == 0) {
public IRubyObject insert(RubyNumeric index, IRubyObject[] args) { // ruby does not bother to bounds check index, if no elements are // to be added. if (args != null && args.length == 0) { return this; } // too negative of an offset will throw an IndexError long offset = index.getL...
50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/e0528a07eb03eecc6125079c5ce22e3246ea0358/RubyArray.java/buggy/src/org/jruby/RubyArray.java
public void unmarshal(HttpMethodBase response, HttpChannel context)
public void unmarshal(HttpMethod response, HttpChannel context)
public void unmarshal(HttpMethodBase response, HttpChannel context) throws ImageServiceException, IOException { //Make sure we actually got a binary stream. checkStatusCode(response); checkContentType(response, MIME_TYPE); //Read the stream into buffer. readRespo...
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/c0ee67611abddaf7c5a898ad8033ca4845e9d8fe/GetStackReply.java/clean/SRC/org/openmicroscopy/shoola/omeis/proxy/GetStackReply.java
loginUser( e1.getOmeName() ); iAdmin.changePermissions(i, Permissions.EMPTY); iAdmin.changePermissions(i, Permissions.DEFAULT); loginRoot(); iAdmin.changePermissions(i, Permissions.EMPTY); iAdmin.changePermissions(i, Permissions.DEFAULT);
public void testUserCanOnlySetDetailsOnOwnObject() throws Exception { Experimenter e1 = testExperimenter(); iAdmin.createUser( e1 ); loginUser( e1.getOmeName() ); Image i = new Image(); i.setName( "test" ); i = iUpdate.saveAndReturnObject( i ); // this user should not be able to change things Experimente...
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/7e7c45d25ea1bbef3485ae116b3eb108d9f6f5ef/AdminTest.java/buggy/components/server/test/ome/server/itests/sec/AdminTest.java
delegate = (RenderingEngine) applicationContext.getBean( RenderingEngine.class.getName());
delegate = serviceFactory.createRenderingEngine();
public void create() { super.create(); delegate = (RenderingEngine) applicationContext.getBean( RenderingEngine.class.getName()); }
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/dc8dde051a1e2b716514b3964c9222ce006ebea9/RenderingBean.java/clean/components/ejb/src/ome/ro/ejb/RenderingBean.java
return wrap( context, "&renderService" );
return wrap( context, RenderingEngine.class );
public Object invoke( InvocationContext context ) throws Exception { return wrap( context, "&renderService" ); }
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/dc8dde051a1e2b716514b3964c9222ce006ebea9/RenderingBean.java/clean/components/ejb/src/ome/ro/ejb/RenderingBean.java
fixnumClass.defineMethod("==", CallbackFactory.getMethod(RubyFixnum.class, "op_equal", RubyObject.class)); fixnumClass.defineMethod("eql?", CallbackFactory.getMethod(RubyFixnum.class, "op_equal", RubyObject.class)); fixnumClass.defineMethod("equal?", CallbackFactory.getMethod(RubyFixnum.class, "op_equal", RubyObject.cl...
fixnumClass.defineMethod("==", CallbackFactory.getMethod(RubyFixnum.class, "equal", RubyObject.class)); fixnumClass.defineMethod("eql?", CallbackFactory.getMethod(RubyFixnum.class, "equal", RubyObject.class)); fixnumClass.defineMethod("equal?", CallbackFactory.getMethod(RubyFixnum.class, "equal", RubyObject.class));
public static RubyClass createFixnumClass(Ruby ruby) { RubyClass fixnumClass = ruby.defineClass("Fixnum", ruby.getClasses().getIntegerClass()); fixnumClass.includeModule(ruby.getClasses().getPrecisionModule()); fixnumClass.defineSingletonMethod("induced_from", CallbackFactory.getSingletonMethod...
50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/06e8c0888351efa411cfdddbdf48771ce7f584c0/RubyFixnum.java/clean/org/jruby/RubyFixnum.java
public RubyBoolean equal(RubyObject obj) { return RubyBoolean.newBoolean(ruby, obj instanceof RubyFixnum && ((RubyFixnum)obj).getLongValue() == getLongValue());
public RubyBoolean equal(RubyObject other) { if (!(other instanceof RubyNumeric)) { return getRuby().getFalse(); } else { return RubyBoolean.newBoolean(getRuby(), compareValue((RubyNumeric) other) == 0); }
public RubyBoolean equal(RubyObject obj) { return RubyBoolean.newBoolean(ruby, obj instanceof RubyFixnum && ((RubyFixnum)obj).getLongValue() == getLongValue()); }
50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/06e8c0888351efa411cfdddbdf48771ce7f584c0/RubyFixnum.java/clean/org/jruby/RubyFixnum.java
void finish() { String s = doBasic.getNameText(); if (s == null || s.length() == 0) { doBasic.resetNameArea(); handleNameAreaRemove(0); return; } if (s.length() > 255) { UserNotifier un = TreeViewerAgent.getRegistry().getUserNotifier(); ...
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/95ab942c5bc5a0d5f1ca657d5fcd197d44c5f34c/EditorUI.java/clean/SRC/org/openmicroscopy/shoola/agents/treeviewer/editors/EditorUI.java
return args[0].eval( args[1], self.getRuntime().getNil(), ((RubyString) args[2]).getValue(), RubyNumeric.fix2int(args[3]));
IRubyObject under = args[0]; IRubyObject src = args[1]; IRubyObject file = args[2]; IRubyObject line = args[3]; return under.eval(src, self.getRuntime().getNil(), ((RubyString) file).getValue(), RubyNumeric.fix2int(line));
public IRubyObject evalUnder(RubyModule under, IRubyObject src, IRubyObject file, IRubyObject line) { /* if (ruby_safe_level >= 4) { Check_Type(src, T_STRING); } else { Check_SafeStr(src); } */ return under.executeUnder(new Callback() { public IR...
50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/0044a3b88a0afa22dcced1c8213002b0fb16faf4/RubyObject.java/clean/src/org/jruby/RubyObject.java
return args[0].eval( args[1], self.getRuntime().getNil(), ((RubyString) args[2]).getValue(), RubyNumeric.fix2int(args[3]));
IRubyObject under = args[0]; IRubyObject src = args[1]; IRubyObject file = args[2]; IRubyObject line = args[3]; return under.eval(src, self.getRuntime().getNil(), ((RubyString) file).getValue(), RubyNumeric.fix2int(line));
public IRubyObject execute(IRubyObject self, IRubyObject[] args) { return args[0].eval( args[1], self.getRuntime().getNil(), ((RubyString) args[2]).getValue(), RubyNumeric.fix2int(args[3])); }
50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/0044a3b88a0afa22dcced1c8213002b0fb16faf4/RubyObject.java/clean/src/org/jruby/RubyObject.java
Block savedBlock = runtime.getBlockStack().getCurrent().cloneBlock(); Namespace ns = runtime.getCurrentFrame().getNamespace(); runtime.getBlockStack().getCurrent().getFrame().setNamespace(ns); runtime.getBlockStack().getCurrent().getScope().setVisibility(Visibility.PUBLIC);
ThreadContext context = runtime.getCurrentContext(); Block currentBlock = context.getBlockStack().getCurrent(); Namespace savedNamespace = currentBlock.getFrame().getNamespace(); Visibility savedVisibility = currentBlock.getScope().getVisibility(); currentBlock.getFrame().setNamespace(context.getCurrentFrame().getNam...
private IRubyObject yieldUnder(RubyModule under) { return under.executeUnder(new Callback() { public IRubyObject execute(IRubyObject self, IRubyObject[] args) { // Fixme: What good is this copying, when it is referenced frame and scope objects // that are modified her...
50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/0044a3b88a0afa22dcced1c8213002b0fb16faf4/RubyObject.java/clean/src/org/jruby/RubyObject.java
return runtime.yield(args[0], args[0], runtime.getRubyClass(), false);
IRubyObject valueInYield = args[0]; IRubyObject selfInYield = args[0]; return context.yield(valueInYield, selfInYield, context.getRubyClass(), false);
private IRubyObject yieldUnder(RubyModule under) { return under.executeUnder(new Callback() { public IRubyObject execute(IRubyObject self, IRubyObject[] args) { // Fixme: What good is this copying, when it is referenced frame and scope objects // that are modified her...
50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/0044a3b88a0afa22dcced1c8213002b0fb16faf4/RubyObject.java/clean/src/org/jruby/RubyObject.java
runtime.getBlockStack().setCurrent(savedBlock);
currentBlock.getFrame().setNamespace(savedNamespace); currentBlock.getScope().setVisibility(savedVisibility);
private IRubyObject yieldUnder(RubyModule under) { return under.executeUnder(new Callback() { public IRubyObject execute(IRubyObject self, IRubyObject[] args) { // Fixme: What good is this copying, when it is referenced frame and scope objects // that are modified her...
50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/0044a3b88a0afa22dcced1c8213002b0fb16faf4/RubyObject.java/clean/src/org/jruby/RubyObject.java
Block savedBlock = runtime.getBlockStack().getCurrent().cloneBlock(); Namespace ns = runtime.getCurrentFrame().getNamespace(); runtime.getBlockStack().getCurrent().getFrame().setNamespace(ns); runtime.getBlockStack().getCurrent().getScope().setVisibility(Visibility.PUBLIC);
ThreadContext context = runtime.getCurrentContext(); Block currentBlock = context.getBlockStack().getCurrent(); Namespace savedNamespace = currentBlock.getFrame().getNamespace(); Visibility savedVisibility = currentBlock.getScope().getVisibility(); currentBlock.getFrame().setNamespace(context.getCurrentFrame().getNam...
public IRubyObject execute(IRubyObject self, IRubyObject[] args) { // Fixme: What good is this copying, when it is referenced frame and scope objects // that are modified here? Some other modifications? Block savedBlock = runtime.getBlockStack().getCurrent().clon...
50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/0044a3b88a0afa22dcced1c8213002b0fb16faf4/RubyObject.java/clean/src/org/jruby/RubyObject.java
return runtime.yield(args[0], args[0], runtime.getRubyClass(), false);
IRubyObject valueInYield = args[0]; IRubyObject selfInYield = args[0]; return context.yield(valueInYield, selfInYield, context.getRubyClass(), false);
public IRubyObject execute(IRubyObject self, IRubyObject[] args) { // Fixme: What good is this copying, when it is referenced frame and scope objects // that are modified here? Some other modifications? Block savedBlock = runtime.getBlockStack().getCurrent().clon...
50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/0044a3b88a0afa22dcced1c8213002b0fb16faf4/RubyObject.java/clean/src/org/jruby/RubyObject.java
runtime.getBlockStack().setCurrent(savedBlock);
currentBlock.getFrame().setNamespace(savedNamespace); currentBlock.getScope().setVisibility(savedVisibility);
public IRubyObject execute(IRubyObject self, IRubyObject[] args) { // Fixme: What good is this copying, when it is referenced frame and scope objects // that are modified here? Some other modifications? Block savedBlock = runtime.getBlockStack().getCurrent().clon...
50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/0044a3b88a0afa22dcced1c8213002b0fb16faf4/RubyObject.java/clean/src/org/jruby/RubyObject.java
RubyClass superClass = getSuperClassFromNode(context, iVisited.getSuperNode(), self);
Node superNode = iVisited.getSuperNode(); RubyClass superClass = superNode == null ? null : (RubyClass) evalInternal(context, superNode, self);
private static IRubyObject evalInternal(ThreadContext context, Node node, IRubyObject self) { IRuby runtime = context.getRuntime(); bigloop: do { if (node == null) return runtime.getNil(); switch (node.nodeId) { case NodeTypes.ALIASNODE: { AliasNode ...
50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/8bc77fd935108392c0bf8a671462f28f423e48c1/EvaluationState.java/clean/src/org/jruby/evaluator/EvaluationState.java
return "AnalysisChainLink"+(analysisChainLinkId==null ? ":Hash"+this.hashCode() : ":"+analysisChainLinkId);
return "AnalysisChainLink"+(analysisChainLinkId==null ? ":Hash_"+this.hashCode() : ":Id_"+analysisChainLinkId);
public String toString(){ return "AnalysisChainLink"+(analysisChainLinkId==null ? ":Hash"+this.hashCode() : ":"+analysisChainLinkId); }
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/51a3c546dfc7a7a98b29771a459df19094fc5b51/AnalysisChainLink.java/clean/components/common/src/ome/model/AnalysisChainLink.java
psrv = factory.getPojosService(); q = factory.getQueryService(); u = factory.getUpdateService();
iPojos = factory.getPojosService(); iQuery = factory.getQueryService(); iUpdate = factory.getUpdateService();
protected void setUp() throws Exception { DataSource dataSource = (DataSource) factory.ctx.getBean("dataSource"); data = new OMEData(); data.setDataSource(dataSource); psrv = factory.getPojosService(); q = factory.getQueryService(); u = factory.getUpdateService(); ...
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/0b36a8e77f5bacb7e122d76ffce01866205b09d7/PojosServiceTest.java/buggy/components/shoola-adapter/test/ome/adapters/pojos/itests/PojosServiceTest.java
Pixels pix = (Pixels) q.getByClass(Pixels.class).get(0);
Pixels pix = (Pixels) iQuery.getByClass(Pixels.class).get(0);
public void testAndForTheFunOfItLetsGetTheREWorking() throws Exception { Pixels pix = (Pixels) q.getByClass(Pixels.class).get(0); IPixels pixDB = factory.getPixelsService(); PixelsService pixFS = new PixelsService( PixelsService.ROOT_DEFAULT); PixelBuffer pixBF = pixFS....
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/0b36a8e77f5bacb7e122d76ffce01866205b09d7/PojosServiceTest.java/buggy/components/shoola-adapter/test/ome/adapters/pojos/itests/PojosServiceTest.java
img = (Image) u.saveAndReturnObject(img);
img = (Image) iUpdate.saveAndReturnObject(img);
public void testAndSaveSomtheingWithParents() throws Exception { DatasetData dd = simpleDatasetData(); Set dss = new HashSet(); dss.add(dd); imgData = simpleImageData(); imgData.setDatasets(dss); img = (Image) reverse.map(imgData); img = (Image) u.saveAndR...
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/0b36a8e77f5bacb7e122d76ffce01866205b09d7/PojosServiceTest.java/buggy/components/shoola-adapter/test/ome/adapters/pojos/itests/PojosServiceTest.java
Image img2 = (Image) q.queryUnique(
Image img2 = (Image) iQuery.queryUnique(
public void testAndSaveSomtheingWithParents() throws Exception { DatasetData dd = simpleDatasetData(); Set dss = new HashSet(); dss.add(dd); imgData = simpleImageData(); imgData.setDatasets(dss); img = (Image) reverse.map(imgData); img = (Image) u.saveAndR...
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/0b36a8e77f5bacb7e122d76ffce01866205b09d7/PojosServiceTest.java/buggy/components/shoola-adapter/test/ome/adapters/pojos/itests/PojosServiceTest.java
List l = q.getListByExample(new Experimenter());
List l = iQuery.getListByExample(new Experimenter());
public void testGetSomethingThatsAlwaysThere() throws Exception { List l = q.getListByExample(new Experimenter()); assertTrue("Root has to exist.",l.size()>0); Experimenter exp = (Experimenter) l.get(0); assertNotNull("Must have an id",exp.getId()); assertNotNull("And a name",e...
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/0b36a8e77f5bacb7e122d76ffce01866205b09d7/PojosServiceTest.java/buggy/components/shoola-adapter/test/ome/adapters/pojos/itests/PojosServiceTest.java
ILink test = psrv.link(new ILink[]{link},null)[0];
ILink test = iPojos.link(new ILink[]{link},null)[0];
public void testLetsTryToLinkTwoThingsTogether() throws Exception { imgData = simpleImageData(); dsData = simpleDatasetData(); img = (Image) reverse.map(imgData); ds = (Dataset) reverse.map(dsData); DatasetImageLink link = new DatasetImageLink(); link.lin...
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/0b36a8e77f5bacb7e122d76ffce01866205b09d7/PojosServiceTest.java/buggy/components/shoola-adapter/test/ome/adapters/pojos/itests/PojosServiceTest.java
img = (Image) psrv.createDataObject(img,null);
img = (Image) iPojos.createDataObject(img,null);
public void testNowLetsTryToSaveSomething() throws Exception { imgData = simpleImageData(); img = (Image) reverse.map(imgData); img = (Image) psrv.createDataObject(img,null); assertNotNull("We should get something back",img); assertNotNull("Should have an id",img.getId(...
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/0b36a8e77f5bacb7e122d76ffce01866205b09d7/PojosServiceTest.java/buggy/components/shoola-adapter/test/ome/adapters/pojos/itests/PojosServiceTest.java
Image img2 = (Image) q.getById(Image.class,img.getId().longValue());
Image img2 = (Image) iQuery.getById(Image.class,img.getId().longValue());
public void testNowLetsTryToSaveSomething() throws Exception { imgData = simpleImageData(); img = (Image) reverse.map(imgData); img = (Image) psrv.createDataObject(img,null); assertNotNull("We should get something back",img); assertNotNull("Should have an id",img.getId(...
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/0b36a8e77f5bacb7e122d76ffce01866205b09d7/PojosServiceTest.java/buggy/components/shoola-adapter/test/ome/adapters/pojos/itests/PojosServiceTest.java
img = (Image) psrv.createDataObject(img,null);
img = (Image) iPojos.createDataObject(img,null);
public void testNowOnToSavingAndDeleting() throws Exception { imgData = simpleImageData(); img = (Image) reverse.map(imgData); assertNull("Image doesn't have an id.",img.getId()); img = (Image) psrv.createDataObject(img,null); assertNotNull("Presto change-o, now it does...
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/0b36a8e77f5bacb7e122d76ffce01866205b09d7/PojosServiceTest.java/buggy/components/shoola-adapter/test/ome/adapters/pojos/itests/PojosServiceTest.java
psrv.deleteDataObject(img,null);
iPojos.deleteDataObject(img,null);
public void testNowOnToSavingAndDeleting() throws Exception { imgData = simpleImageData(); img = (Image) reverse.map(imgData); assertNull("Image doesn't have an id.",img.getId()); img = (Image) psrv.createDataObject(img,null); assertNotNull("Presto change-o, now it does...
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/0b36a8e77f5bacb7e122d76ffce01866205b09d7/PojosServiceTest.java/buggy/components/shoola-adapter/test/ome/adapters/pojos/itests/PojosServiceTest.java
img = (Image) q.getById(Image.class,img.getId().longValue());
img = (Image) iQuery.getById(Image.class,img.getId().longValue());
public void testNowOnToSavingAndDeleting() throws Exception { imgData = simpleImageData(); img = (Image) reverse.map(imgData); assertNull("Image doesn't have an id.",img.getId()); img = (Image) psrv.createDataObject(img,null); assertNotNull("Presto change-o, now it does...
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/0b36a8e77f5bacb7e122d76ffce01866205b09d7/PojosServiceTest.java/buggy/components/shoola-adapter/test/ome/adapters/pojos/itests/PojosServiceTest.java
boolean[] la1tokens = new boolean[33]; for (int i = 0; i < 33; i++) {
boolean[] la1tokens = new boolean[35]; for (int i = 0; i < 35; i++) {
final public ParseException generateParseException() { jj_expentries.removeAllElements(); boolean[] la1tokens = new boolean[33]; for (int i = 0; i < 33; i++) { la1tokens[i] = false; } if (jj_kind >= 0) { la1tokens[jj_kind] = true; jj_kind = -1; } for (int i = 0; i < 2; i++) { ...
52513 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52513/2e6a5e583cccdc19c543caf9a1fb259181c98cb6/WikiParser.java/buggy/wiki/src/org/tcdi/opensource/wiki/parser/WikiParser.java
for (int i = 0; i < 33; i++) {
for (int i = 0; i < 35; i++) {
final public ParseException generateParseException() { jj_expentries.removeAllElements(); boolean[] la1tokens = new boolean[33]; for (int i = 0; i < 33; i++) { la1tokens[i] = false; } if (jj_kind >= 0) { la1tokens[jj_kind] = true; jj_kind = -1; } for (int i = 0; i < 2; i++) { ...
52513 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52513/2e6a5e583cccdc19c543caf9a1fb259181c98cb6/WikiParser.java/buggy/wiki/src/org/tcdi/opensource/wiki/parser/WikiParser.java
break; case LI: t = jj_consume_token(LI); builder.li();
final public WikiPage parse(WikiPageBuilder builder) throws ParseException { Token t; label_1: while (true) { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case QUOTED_BLOCK: case BOLD: case UNDERLINE: case ITALIC: case LT: case GT: c...
52513 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52513/2e6a5e583cccdc19c543caf9a1fb259181c98cb6/WikiParser.java/buggy/wiki/src/org/tcdi/opensource/wiki/parser/WikiParser.java
this.support = new ParserSupport(); this.lexer = new RubyYaccLexer(); this.lexer.setParserSupport(support);
support = new ParserSupport(); lexer = new RubyYaccLexer(); lexer.setParserSupport(support);
public DefaultRubyParser() { this.support = new ParserSupport(); this.lexer = new RubyYaccLexer(); // lame this.lexer.setParserSupport(support); }
50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/b1293eda8454686e846e2a9837b348e2983bb423/DefaultRubyParser.java/clean/src/org/jruby/parser/DefaultRubyParser.java
if (start != null) { return lexer.getPosition(start.getPosition()); } return lexer.getPosition(null);
return getPosition(start, false);
private ISourcePosition getPosition(ISourcePositionHolder start) { if (start != null) { return lexer.getPosition(start.getPosition()); } return lexer.getPosition(null); }
50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/b1293eda8454686e846e2a9837b348e2983bb423/DefaultRubyParser.java/clean/src/org/jruby/parser/DefaultRubyParser.java
support.setPositionFactory(lexer.getPositionFactory());
public RubyParserResult parse(LexerSource source) { support.reset(); support.setResult(new RubyParserResult()); lexer.reset(); lexer.setSource(source); try { //yyparse(lexer, new jay.yydebug.yyAnim("JRuby", 9)); //yyparse(lexer, new jay.yydebug.yyDebugAdapter()); ...
50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/b1293eda8454686e846e2a9837b348e2983bb423/DefaultRubyParser.java/clean/src/org/jruby/parser/DefaultRubyParser.java
int n = Integer.parseInt(args[0]);
public static void main(String args[]) throws IOException { //@START int n = Integer.parseInt(args[0]); String hello = "hello\n"; StringBuffer stringBuffer = new StringBuffer(32); for (int i=0; i<n; i++) { stringBuffer.append(hello); } System.out.println(stringBuffer.length()); //@END }
53330 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/53330/eb6c850277407b38bcaefb81155941da0f27b849/strcat.java/buggy/tests/shootout/java-start/strcat.java
ChatPreferences chatPref = (ChatPreferences)SparkManager.getPreferenceManager().getPreferenceData(ChatPreference.NAMESPACE); chatRoom.create(chatPref.getNickname());
LocalPreferences pref = SettingsManager.getLocalPreferences(); chatRoom.create(pref.getNickname());
public ChatRoom createConferenceRoom(String roomName, String serviceName) { final MultiUserChat chatRoom = new MultiUserChat(SparkManager.getConnection(), roomName + "@" + serviceName); final GroupChatRoom room = new GroupChatRoom(chatRoom); try { ChatPreferences chatPref = (ChatPref...
52006 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52006/f678f06c6fbc4a84079c230a0a7461759cb20755/ChatManager.java/buggy/src/java/org/jivesoftware/spark/ChatManager.java
private void initCoreClasses() { ObjectMetaClass objectMetaClass = new ObjectMetaClass(this); objectMetaClass.initializeClass(); objectClass = objectMetaClass; objectClass.setConstant("Object", objectClass); RubyClass moduleClass = new ModuleMetaClass(this, objectClass); ...
50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/d9e453ef8491a951e06ecccb3e27137fa7aaccee/Ruby.java/clean/src/org/jruby/Ruby.java
defineClass("Data",objectClass);
private void initCoreClasses() { ObjectMetaClass objectMetaClass = new ObjectMetaClass(this); objectMetaClass.initializeClass(); objectClass = objectMetaClass; objectClass.setConstant("Object", objectClass); RubyClass moduleClass = new ModuleMetaClass(this, objectClass); ...
50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/d9e453ef8491a951e06ecccb3e27137fa7aaccee/Ruby.java/clean/src/org/jruby/Ruby.java
flater = new Inflater(true);
flater = new Inflater(false);
public ZlibInflate(IRubyObject caller) { super(); flater = new Inflater(true); collected = new StringBuffer(); runtime = caller.getRuntime(); }
50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/c9e16f0d2d769c555189a2e11bfe3a4c8b098650/ZlibInflate.java/buggy/src/org/jruby/util/ZlibInflate.java
public JContactItemField(List items) {
public JContactItemField(List items, Window parentWindow) {
public JContactItemField(List items) { setLayout(new BorderLayout()); this.items = items; add(textField, BorderLayout.CENTER); textField.addKeyListener(new KeyAdapter() { public void keyReleased(KeyEvent keyEvent) { char ch = keyEvent.getKeyChar(); ...
52006 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52006/bb9bf59720a1ef585641bebe31110d3b4a034d3c/JContactItemField.java/clean/src/java/org/jivesoftware/spark/component/JContactItemField.java
popup = new JWindow(new JFrame());
list.addKeyListener(this); addKeyListener(this); popup = new JWindow(parentWindow);
public JContactItemField(List items) { setLayout(new BorderLayout()); this.items = items; add(textField, BorderLayout.CENTER); textField.addKeyListener(new KeyAdapter() { public void keyReleased(KeyEvent keyEvent) { char ch = keyEvent.getKeyChar(); ...
52006 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52006/bb9bf59720a1ef585641bebe31110d3b4a034d3c/JContactItemField.java/clean/src/java/org/jivesoftware/spark/component/JContactItemField.java
&& ch != '.' && ch != ',' && ch != ' ' && ch != KeyEvent.VK_BACK_SPACE && ch != KeyEvent.CTRL_DOWN_MASK && ch != KeyEvent.CTRL_MASK) {
&& ch != '.' && ch != ',' && ch != ' ' && ch != KeyEvent.VK_BACK_SPACE && ch != KeyEvent.CTRL_DOWN_MASK && ch != KeyEvent.CTRL_MASK) {
public boolean validateChar(char ch) { if (!Character.isLetterOrDigit(ch) && ch != '@' && ch != '-' && ch != '_' && ch != '.' && ch != ',' && ch != ' ' && ch != KeyEvent.VK_BACK_SPACE && ch != KeyEvent.CTRL_DOWN_MASK && ch != KeyEvent.CTRL_MASK) { return false; } ...
52006 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52006/bb9bf59720a1ef585641bebe31110d3b4a034d3c/JContactItemField.java/clean/src/java/org/jivesoftware/spark/component/JContactItemField.java
&& ch != '.' && ch != ',' && ch != ' ') {
&& ch != '.' && ch != ',' && ch != ' ') {
public boolean validateChars(String text) { if (!ModelUtil.hasLength(text)) { return false; } for (int i = 0; i < text.length(); i++) { char ch = text.charAt(i); if (!Character.isLetterOrDigit(ch) && ch != '@' && ch != '-' && ch != '_' && ch != '....
52006 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52006/bb9bf59720a1ef585641bebe31110d3b4a034d3c/JContactItemField.java/clean/src/java/org/jivesoftware/spark/component/JContactItemField.java
System.err.println(attribute);
public static double parseElement(Attribute attribute, String elementName) throws IllegalArgumentException { if(attribute == null || elementName == null) { throw new IllegalArgumentException("Null parameters at " + "AbstractHeatMapMode.parseElement(Attribute,String)...
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/28e98417641b00a2e12a791f10f204dc4562dec1/HeatMapUtils.java/clean/SRC/org/openmicroscopy/shoola/agents/browser/heatmap/HeatMapUtils.java
lensController = new LensController(lensModel , lens, zoomWindow);
lensController = new LensController(lensModel, lens, zoomWindow);
public LensComponent(JFrame parent, BufferedImage planeImage) { lensModel = new LensModel(planeImage); zoomWindow = new ZoomWindow(parent, this); lens = new LensUI(this, LENS_DEFAULT_WIDTH, LENS_DEFAULT_HEIGHT); lensController = new LensController(lensModel , lens, zoomWindow); lensModel.setWidth(LENS_DEFAULT_WID...
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/54a6dc1cc81e06c2190546075a6c5a04f18d9bb5/LensComponent.java/buggy/SRC/org/openmicroscopy/shoola/util/ui/lens/LensComponent.java
public void setLensSize(int lensSize)
void setLensSize(int lensSize)
public void setLensSize(int lensSize) { switch (lensSize) { case LensAction.LENSDEFAULTSIZE: lensController.setLensSize(LensComponent.LENS_DEFAULT_WIDTH, LensComponent.LENS_DEFAULT_HEIGHT); break; case LensAction.LENS40x40: lensContro...
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/54a6dc1cc81e06c2190546075a6c5a04f18d9bb5/LensComponent.java/buggy/SRC/org/openmicroscopy/shoola/util/ui/lens/LensComponent.java
try { currentDirectory = JRubyFile.getFileProperty("user.dir"); } catch (AccessControlException accessEx) { currentDirectory = "/"; }
private Ruby(InputStream in, PrintStream out, PrintStream err) { this.in = in; this.out = out; this.err = err; objectSpaceEnabled = true; }
50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/d38821551a58969cd2593b463d93df5f32bf3c14/Ruby.java/clean/src/org/jruby/Ruby.java
defineMethod("to_s", Arity.noArguments());
defineMethod("to_s", Arity.optional());
protected void initializeClass() { defineMethod("quo", Arity.singleArgument()); defineMethod("to_f", Arity.noArguments()); defineMethod("to_i", Arity.noArguments()); defineMethod("to_s", Arity.noArguments()); defineMethod("taint", Arity.noArguments()); defineMetho...
50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/5ab345ee94c86afde157cfadd32a78d5899d489f/FixnumMetaClass.java/buggy/src/org/jruby/runtime/builtin/meta/FixnumMetaClass.java
return buf == null ? getRuntime().newString("") : getRuntime().newString(buf);
if (buf == null) { if (args.length > 0) { return getRuntime().getNil(); } return getRuntime().newString(""); } return getRuntime().newString(buf);
public IRubyObject read(IRubyObject[] args) { try { String buf = args.length > 0 ? handler.read(RubyNumeric.fix2int(args[0])) : handler.getsEntireStream(); return buf == null ? getRuntime().newString("") : getRuntime().newString(buf); } catch (IOHandler.BadDescriptor...
50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/58ae97d80464087e7fd608ca0ec391c8cf84bce1/RubyIO.java/clean/src/org/jruby/RubyIO.java
protected DataLoader createHierarchyLoader()
protected DataLoader createHierarchyLoader(boolean refresh)
protected DataLoader createHierarchyLoader() { Set ids = new HashSet(images.size()); Iterator i = images.iterator(); while (i.hasNext()) ids.add(new Long(((ImageData) i.next()).getId())); switch (type) { case HiViewer.PDI_HIERARCHY: return...
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/fb3743d6f75abbf12f788b3b2925f4a6f4606dd6/HierarchyModel.java/clean/SRC/org/openmicroscopy/shoola/agents/hiviewer/view/HierarchyModel.java
return new PDILoader(component, ids);
return new PDILoader(component, ids, refresh);
protected DataLoader createHierarchyLoader() { Set ids = new HashSet(images.size()); Iterator i = images.iterator(); while (i.hasNext()) ids.add(new Long(((ImageData) i.next()).getId())); switch (type) { case HiViewer.PDI_HIERARCHY: return...
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/fb3743d6f75abbf12f788b3b2925f4a6f4606dd6/HierarchyModel.java/clean/SRC/org/openmicroscopy/shoola/agents/hiviewer/view/HierarchyModel.java
return new CGCILoader(component, ids);
return new CGCILoader(component, ids, refresh);
protected DataLoader createHierarchyLoader() { Set ids = new HashSet(images.size()); Iterator i = images.iterator(); while (i.hasNext()) ids.add(new Long(((ImageData) i.next()).getId())); switch (type) { case HiViewer.PDI_HIERARCHY: return...
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/fb3743d6f75abbf12f788b3b2925f4a6f4606dd6/HierarchyModel.java/clean/SRC/org/openmicroscopy/shoola/agents/hiviewer/view/HierarchyModel.java
symbolClass.defineMethod("hash", CallbackFactory.getMethod(RubySymbol.class, "hash"));
public static RubyClass createSymbolClass(Ruby ruby) { RubyClass symbolClass = ruby.defineClass("Symbol", ruby.getClasses().getObjectClass()); symbolClass.getRubyClass().undefMethod("new"); symbolClass.defineMethod("id", CallbackFactory.getMethod(RubySymbol.class, "id")); ...
50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/7f0907240b4b4a4379424377e971ed0ca23f1dcb/RubySymbol.java/clean/org/jruby/RubySymbol.java
if (response.getDrawingCanvas() != null) { if (control.getDrawingCanvas() == null) control.setDrawingCanvas(response.getDrawingCanvas());
control.setDrawingCanvas(response.getDrawingCanvas());
private void handleDisplayROI(DisplayROI response) { if (response.getDrawingCanvas() != null) { //close window if (control.getDrawingCanvas() == null) control.setDrawingCanvas(response.getDrawingCanvas()); if (presentation == null) buildPresentation(); prese...
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/975d69b756654b3d3810faba1b0e148d7fecd46d/ROIAgt.java/clean/SRC/org/openmicroscopy/shoola/agents/roi/ROIAgt.java
} else removePresentation();
private void handleDisplayROI(DisplayROI response) { if (response.getDrawingCanvas() != null) { //close window if (control.getDrawingCanvas() == null) control.setDrawingCanvas(response.getDrawingCanvas()); if (presentation == null) buildPresentation(); prese...
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/975d69b756654b3d3810faba1b0e148d7fecd46d/ROIAgt.java/clean/SRC/org/openmicroscopy/shoola/agents/roi/ROIAgt.java
pref.setHideChatHistory(panel.isChatHistoryHidden());
pref.setChatHistoryEnabled(!panel.isChatHistoryHidden());
public void commit() { LocalPreferences pref = SettingsManager.getLocalPreferences(); pref.setTimeDisplayedInChat(panel.getShowTime()); pref.setSpellCheckerEnabled(panel.isSpellCheckerOn()); pref.setChatRoomNotifications(panel.isGroupChatNotificationsOn()); pref.setHideChatHistory...
52006 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52006/741ee521da25f1d1608a575dbda0a84d216ed278/ChatPreference.java/clean/src/java/org/jivesoftware/sparkimpl/preference/chat/ChatPreference.java
boolean chatHistoryHidden = pref.isHideChatHistory();
boolean chatHistoryHidden = !pref.isChatHistoryEnabled();
public void load() { SwingWorker thread = new SwingWorker() { LocalPreferences pref; public Object construct() { pref = SettingsManager.getLocalPreferences(); return pref; } public void finished() { String nickname = pre...
52006 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52006/741ee521da25f1d1608a575dbda0a84d216ed278/ChatPreference.java/clean/src/java/org/jivesoftware/sparkimpl/preference/chat/ChatPreference.java
boolean chatHistoryHidden = pref.isHideChatHistory();
boolean chatHistoryHidden = !pref.isChatHistoryEnabled();
public void finished() { String nickname = pref.getDefaultNickname(); if (nickname == null) { nickname = SparkManager.getSessionManager().getUsername(); } boolean showTime = pref.isTimeDisplayedInChat(); boolean sp...
52006 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52006/741ee521da25f1d1608a575dbda0a84d216ed278/ChatPreference.java/clean/src/java/org/jivesoftware/sparkimpl/preference/chat/ChatPreference.java
return RubyString.newString(input.getRuntime(), input.unmarshalString());
RubyString result = RubyString.newString(input.getRuntime(), input.unmarshalString()); input.register(result); return result;
public static RubyString unmarshalFrom(UnmarshalStream input) throws java.io.IOException { return RubyString.newString(input.getRuntime(), input.unmarshalString()); }
50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/9db4d278a734c4fdfd9a83ed95575a45577f1e1b/RubyString.java/buggy/org/jruby/RubyString.java
protected void onPlayerStateChange() { switch (state) { case START: if (historyState == Player.PAUSE) { switch (index) { case ACROSS_Z: //if (movieType == BACKWARD) frameNumberZ = endZ; ...
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/10741ce22be9051166109de0c40e67fef675822e/MoviePlayer.java/clean/SRC/org/openmicroscopy/shoola/agents/imviewer/util/MoviePlayer.java
break; case PAUSE: parent.setMoviePlay(false); timer.stop();
protected void onPlayerStateChange() { switch (state) { case START: if (historyState == Player.PAUSE) { switch (index) { case ACROSS_Z: //if (movieType == BACKWARD) frameNumberZ = endZ; ...
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/10741ce22be9051166109de0c40e67fef675822e/MoviePlayer.java/clean/SRC/org/openmicroscopy/shoola/agents/imviewer/util/MoviePlayer.java
LOG_DIRECTORY = new File(workingDir, "logs").getAbsoluteFile();
if (!Spark.isWindows()) { LOG_DIRECTORY = new File(USER_HOME, "/Spark/logs").getAbsoluteFile(); } else { LOG_DIRECTORY = new File(workingDir, "logs").getAbsoluteFile(); }
public static void main(final String[] args) { /* * EnhancedDebuggerWindow.PERSISTED_DEBUGGER = true; * EnhancedDebuggerWindow.MAX_TABLE_ROWS = 10; * XMPPConnection.DEBUG_ENABLED = true; */ String current = System.getProperty("java.library.path"); String classPath = ...
52006 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52006/82176bff8d40a7851002b5e69ea1601964f06975/Spark.java/clean/src/java/org/jivesoftware/Spark.java
if (!(other instanceof RubyNumeric)) { return getRuntime().getNil(); } return getRuntime().newFixnum(compareValue((RubyNumeric) other));
if (other instanceof RubyNumeric) { return getRuntime().newFixnum(compareValue((RubyNumeric) other)); } return other.respondsTo("to_int") ? callCoerced("<=>", other) : getRuntime().getNil();
public IRubyObject cmp(IRubyObject other) { if (!(other instanceof RubyNumeric)) { return getRuntime().getNil(); } return getRuntime().newFixnum(compareValue((RubyNumeric) other)); }
50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/14d28170b3c3f50bc56c58974a99b52f44d23730/RubyNumeric.java/buggy/src/org/jruby/RubyNumeric.java
public HTMLReport(Coverage coverage, File outputDir, File sourceDir)
public HTMLReport(CoverageReport coverage, File outputDir, File sourceDir)
public HTMLReport(Coverage coverage, File outputDir, File sourceDir) throws Exception { this.outputDir = outputDir; this.sourceDir = sourceDir; this.coverage = coverage; removeNonexistantClasses(); CopyFiles.copy(outputDir); generatePackageList(); generateClassLists(); generateOverviews(); generateSourceFil...
50197 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50197/100512ee483a0d8eebc3eb78a5d8913b7b64ddb6/HTMLReport.java/clean/cobertura/src/net/sourceforge/cobertura/reporting/html/HTMLReport.java
public ImageCanvas(ViewerUIF view) { this.view = view;
public ImageCanvas(ViewerUIF view, ViewerCtrl control) { this.view = view; this.control = control; filters = new ArrayList(); manager = new ImageCanvasMng(this);
public ImageCanvas(ViewerUIF view) { this.view = view; magFactor = 1.0; setBackground(Viewer.BACKGROUND_COLOR); setDoubleBuffered(true); }
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/659f158c2dfd21d045b383412baa0586d50ef8d8/ImageCanvas.java/clean/SRC/org/openmicroscopy/shoola/agents/viewer/canvas/ImageCanvas.java
setBackground(Viewer.BACKGROUND_COLOR); setDoubleBuffered(true); }
setBackground(Viewer.BACKGROUND_COLOR); setDoubleBuffered(true); }
public ImageCanvas(ViewerUIF view) { this.view = view; magFactor = 1.0; setBackground(Viewer.BACKGROUND_COLOR); setDoubleBuffered(true); }
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/659f158c2dfd21d045b383412baa0586d50ef8d8/ImageCanvas.java/clean/SRC/org/openmicroscopy/shoola/agents/viewer/canvas/ImageCanvas.java
int sizeX = displayImage.getWidth(); int sizeY = displayImage.getHeight(); DataBufferByte buffer = new DataBufferByte(sizeX*sizeY, 3); DataBuffer dataBuf = displayImage.getRaster().getDataBuffer(); ColorModel cm = displayImage.getColorModel(); int v; for (int y = 0; y < sizeY; ++y) { for (int x = 0; x < sizeX; ++x) { ...
if (displayImage == null) return null; return ImageFactory.getImage(displayImage);
public BufferedImage getDisplayImage() { //Now we only need to tell Java2D how to handle the RGB buffer. int sizeX = displayImage.getWidth(); int sizeY = displayImage.getHeight(); DataBufferByte buffer = new DataBufferByte(sizeX*sizeY, 3); DataBuffer dataBuf = displayImage.ge...
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/659f158c2dfd21d045b383412baa0586d50ef8d8/ImageCanvas.java/clean/SRC/org/openmicroscopy/shoola/agents/viewer/canvas/ImageCanvas.java
{ super.paintComponent(g); Graphics2D g2D = (Graphics2D) g; setLocation(); paintXYFrame(g2D); g2D.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON); g2D.setRenderingHint(RenderingHints.KEY_RENDERING, RenderingHints.VALUE_RENDER_QUALITY);
{ super.paintComponent(g); Graphics2D g2D = (Graphics2D) g; setLocation(); control.setDrawingArea(x+ViewerUIF.START, y+ViewerUIF.START, (int)(image.getWidth()*magFactor), (int)(image.getHeight()*magFactor));
public void paint(Graphics g) { super.paintComponent(g); Graphics2D g2D = (Graphics2D) g; setLocation(); paintXYFrame(g2D); g2D.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON); g2D.setRenderingHint(RenderingHints.KEY_RENDERING, RenderingHints.VALUE_RENDER_QUALITY)...
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/659f158c2dfd21d045b383412baa0586d50ef8d8/ImageCanvas.java/clean/SRC/org/openmicroscopy/shoola/agents/viewer/canvas/ImageCanvas.java
g2D.setColor(Color.black);
paintXYFrame(g2D); g2D.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON); g2D.setRenderingHint(RenderingHints.KEY_RENDERING, RenderingHints.VALUE_RENDER_QUALITY); g2D.setRenderingHint(RenderingHints.KEY_INTERPOLATION, RenderingHints.VALUE_INTERPOLATION_BILINEAR); g2D.setColor(Color.bl...
public void paint(Graphics g) { super.paintComponent(g); Graphics2D g2D = (Graphics2D) g; setLocation(); paintXYFrame(g2D); g2D.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON); g2D.setRenderingHint(RenderingHints.KEY_RENDERING, RenderingHints.VALUE_RENDER_QUALITY)...
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/659f158c2dfd21d045b383412baa0586d50ef8d8/ImageCanvas.java/clean/SRC/org/openmicroscopy/shoola/agents/viewer/canvas/ImageCanvas.java
}
if (lensImage != null) g2D.drawImage(lensImage, null, xLens, yLens); }
public void paint(Graphics g) { super.paintComponent(g); Graphics2D g2D = (Graphics2D) g; setLocation(); paintXYFrame(g2D); g2D.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON); g2D.setRenderingHint(RenderingHints.KEY_RENDERING, RenderingHints.VALUE_RENDER_QUALITY)...
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/659f158c2dfd21d045b383412baa0586d50ef8d8/ImageCanvas.java/clean/SRC/org/openmicroscopy/shoola/agents/viewer/canvas/ImageCanvas.java
{ this.image = image;
{ this.image = image; resetLens();
public void paintImage(BufferedImage image) { this.image = image; if (image != null) { paintImage(magFactor, (int) (image.getWidth()*magFactor)+2*ViewerUIF.START, (int) (image.getHeight()*magFactor)+2*ViewerUIF.START); } }
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/659f158c2dfd21d045b383412baa0586d50ef8d8/ImageCanvas.java/clean/SRC/org/openmicroscopy/shoola/agents/viewer/canvas/ImageCanvas.java
}
}
public void paintImage(BufferedImage image) { this.image = image; if (image != null) { paintImage(magFactor, (int) (image.getWidth()*magFactor)+2*ViewerUIF.START, (int) (image.getHeight()*magFactor)+2*ViewerUIF.START); } }
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/659f158c2dfd21d045b383412baa0586d50ef8d8/ImageCanvas.java/clean/SRC/org/openmicroscopy/shoola/agents/viewer/canvas/ImageCanvas.java
{ FontMetrics fontMetrics = g2D.getFontMetrics(); int hFont = fontMetrics.getHeight()/4; int x1 = ViewerUIF.START-ViewerUIF.ORIGIN; int y1 = ViewerUIF.START-ViewerUIF.ORIGIN; g2D.drawLine(x1, y1, x1+ViewerUIF.LENGTH, y1); g2D.drawLine(x1-ViewerUIF.ARROW+ViewerUIF.LENGTH, y1-ViewerUIF.ARROW, x1+ViewerUIF.LENGTH, y1); g...
{ FontMetrics fontMetrics = g2D.getFontMetrics(); int hFont = fontMetrics.getHeight()/4; int x1 = ViewerUIF.START-ViewerUIF.ORIGIN; int y1 = ViewerUIF.START-ViewerUIF.ORIGIN; g2D.drawLine(x1, y1, x1+ViewerUIF.LENGTH, y1); g2D.drawLine(x1-ViewerUIF.ARROW+ViewerUIF.LENGTH, y1-ViewerUIF.ARROW, x1+ViewerUIF.LENGTH, y1); g...
private void paintXYFrame(Graphics2D g2D) { FontMetrics fontMetrics = g2D.getFontMetrics(); int hFont = fontMetrics.getHeight()/4; //x-axis int x1 = ViewerUIF.START-ViewerUIF.ORIGIN; int y1 = ViewerUIF.START-ViewerUIF.ORIGIN; g2D.drawLine(x1, y1, x1+ViewerUIF.LENGTH, y1); g2D.drawLine(x1-ViewerUIF.ARROW+ViewerU...
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/659f158c2dfd21d045b383412baa0586d50ef8d8/ImageCanvas.java/clean/SRC/org/openmicroscopy/shoola/agents/viewer/canvas/ImageCanvas.java
{ Rectangle r = view.getScrollPane().getViewportBorderBounds(); x = ((r.width-w)/2); y = ((r.height-h)/2); if (x < 0) x = 0; if (y < 0) y = 0;
{ Rectangle r = view.getScrollPane().getViewportBorderBounds(); x = ((r.width-w)/2); y = ((r.height-h)/2); if (x < 0) x = 0; if (y < 0) y = 0;
private void setLocation() { Rectangle r = view.getScrollPane().getViewportBorderBounds(); x = ((r.width-w)/2); y = ((r.height-h)/2); if (x < 0) x = 0; if (y < 0) y = 0; setBounds(x, y, w, h); }
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/659f158c2dfd21d045b383412baa0586d50ef8d8/ImageCanvas.java/clean/SRC/org/openmicroscopy/shoola/agents/viewer/canvas/ImageCanvas.java
}
}
private void setLocation() { Rectangle r = view.getScrollPane().getViewportBorderBounds(); x = ((r.width-w)/2); y = ((r.height-h)/2); if (x < 0) x = 0; if (y < 0) y = 0; setBounds(x, y, w, h); }
54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/659f158c2dfd21d045b383412baa0586d50ef8d8/ImageCanvas.java/clean/SRC/org/openmicroscopy/shoola/agents/viewer/canvas/ImageCanvas.java