rem stringlengths 1 226k | add stringlengths 0 227k | context stringlengths 6 326k | meta stringlengths 143 403 | input_ids listlengths 256 256 | attention_mask listlengths 256 256 | labels listlengths 128 128 |
|---|---|---|---|---|---|---|
public static void layoutContent(LayoutContext c, Box box, List contentList) { int maxAvailableWidth = c.getExtents().width; int remainingWidth = maxAvailableWidth; int minimumLineHeight = (int)c.getCurrentStyle().getLineHeight(c); LineBox currentLine = newLine(c, null, box); LineBox previousLine = null; InlineBox currentIB = null; InlineBox previousIB = null; List elementStack = new ArrayList(); if (box instanceof AnonymousBlockBox) { List pending = ((BlockBox)box.getParent()).getPendingInlineElements(); if (pending != null) { currentIB = addNestedInlineBoxes(currentLine, pending, maxAvailableWidth); elementStack = pending; } } CalculatedStyle parentStyle = c.getCurrentStyle(); int indent = (int)parentStyle.getFloatPropertyProportionalWidth(CSSName.TEXT_INDENT, maxAvailableWidth, c); remainingWidth -= indent; currentLine.x = indent; if (! box.getStyle().isCleared()) { remainingWidth -= c.getBlockFormattingContext().getFloatDistance( c, currentLine, remainingWidth); } List pendingFloats = new ArrayList(); int pendingLeftMBP = 0; int pendingRightMBP = 0; int start = pushPseudoClasses(c, contentList); if (c.getFirstLinesTracker().hasStyles()) { c.getFirstLinesTracker().pushStyles(c); } for (int i = start; i < contentList.size(); i++) { Object o = contentList.get(i); if (o instanceof StylePush) { StylePush sp = (StylePush) o; CascadedStyle cascaded = sp.getStyle(c); c.pushStyle(cascaded); CalculatedStyle style = c.getCurrentStyle(); previousIB = currentIB; currentIB = new InlineBox(sp.getElement(), style, maxAvailableWidth); currentIB.calculateHeight(c); elementStack.add(new InlineBoxInfo(cascaded, currentIB)); if (previousIB == null) { currentLine.addChild(currentIB); } else { previousIB.addInlineChild(currentIB); } //To break the line well, assume we don't just want to paint padding on next line pendingLeftMBP += style.getLeftMarginBorderPadding(c, maxAvailableWidth); pendingRightMBP += style.getRightMarginBorderPadding(c, maxAvailableWidth); continue; } if (o instanceof StylePop) { CalculatedStyle style = c.getCurrentStyle(); int rightMBP = style.getRightMarginBorderPadding(c, maxAvailableWidth); pendingRightMBP -= rightMBP; remainingWidth -= rightMBP; elementStack.remove(elementStack.size()-1); currentIB.setEndsHere(true); previousIB = currentIB; currentIB = currentIB.getParent() instanceof LineBox ? null : (InlineBox)currentIB.getParent(); c.popStyle(); continue; } Content content = (Content) o; if (mustBeTakenOutOfFlow(content)) { processOutOfFlowContent(c, content, currentLine, remainingWidth, pendingFloats); } else if (isInlineBlock(content)) { Box inlineBlock = Boxing.layout(c, content); if (inlineBlock.getWidth() > remainingWidth && currentLine.isContainsContent()) { saveLine(currentLine, previousLine, c, box, minimumLineHeight, maxAvailableWidth, elementStack, pendingFloats); inlineBlock = Boxing.layout(c, content); previousLine = currentLine; currentLine = newLine(c, previousLine, box); currentIB = addNestedInlineBoxes(currentLine, elementStack, maxAvailableWidth); previousIB = currentIB.getParent() instanceof LineBox ? null : (InlineBox)currentIB.getParent(); remainingWidth = maxAvailableWidth; if (!box.getStyle().isCleared()) { remainingWidth -= c.getBlockFormattingContext().getFloatDistance( c, currentLine, remainingWidth); } } if (currentIB == null) { currentLine.addChild(inlineBlock); } else { currentIB.addInlineChild(inlineBlock); } currentLine.setContainsContent(true); remainingWidth -= inlineBlock.getWidth(); } else { TextContent text = (TextContent)content; LineBreakContext lbContext = new LineBreakContext(); lbContext.setMaster(TextUtil.transformText(text.getText(), c.getCurrentStyle())); do { lbContext.reset(); int fit = 0; if (lbContext.getStart() == 0) { fit += pendingLeftMBP; } if (hasTrimmableLeadingSpace(currentLine, c.getCurrentStyle(), lbContext)) { lbContext.setStart(lbContext.getStart() + 1); } InlineText inlineText = layoutText(c, remainingWidth - fit, lbContext); if (! lbContext.isUnbreakable() || (lbContext.isUnbreakable() && currentLine.isContainsContent())) { currentIB.addInlineChild(inlineText); currentLine.setContainsContent(true); lbContext.setStart(lbContext.getEnd()); remainingWidth -= inlineText.getWidth(); } if (lbContext.isNeedsNewLine()) { saveLine(currentLine, previousLine, c, box, minimumLineHeight, maxAvailableWidth, elementStack, pendingFloats); previousLine = currentLine; currentLine = newLine(c, previousLine, box); currentIB = addNestedInlineBoxes(currentLine, elementStack, maxAvailableWidth); previousIB = currentIB.getParent() instanceof LineBox ? null : (InlineBox)currentIB.getParent(); remainingWidth = maxAvailableWidth; if (!box.getStyle().isCleared()) { remainingWidth -= c.getBlockFormattingContext().getFloatDistance( c, currentLine, remainingWidth); } } } while (! lbContext.isFinished()); } } saveLine(currentLine, previousLine, c, box, minimumLineHeight, maxAvailableWidth, elementStack, pendingFloats); if (box instanceof AnonymousBlockBox) { ((BlockBox)box.getParent()).setPendingInlineElements( elementStack.size() == 0 ? null : elementStack); } // XXX what does this do? if (!c.shrinkWrap()) box.contentWidth = maxAvailableWidth; box.setHeight(currentLine.y + currentLine.getHeight()); } | 52947 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52947/ceb21dee5f070c3ac63d70ae7b6eb22a7c0b4641/InlineBoxing.java/buggy/src/java/org/xhtmlrenderer/layout/InlineBoxing.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
760,
918,
3511,
1350,
12,
3744,
1042,
276,
16,
8549,
3919,
16,
987,
913,
682,
13,
288,
3639,
509,
943,
5268,
2384,
273,
276,
18,
588,
2482,
4877,
7675,
2819,
31,
3639,
509,
4463,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
760,
918,
3511,
1350,
12,
3744,
1042,
276,
16,
8549,
3919,
16,
987,
913,
682,
13,
288,
3639,
509,
943,
5268,
2384,
273,
276,
18,
588,
2482,
4877,
7675,
2819,
31,
3639,
509,
4463,
... | ||
msg.append(" -find <file> search for buildfile towards the root of the" + lSep); msg.append(" filesystem and use it" + lSep); | msg.append(" -find <file> (s)earch for buildfile towards the root of" + lSep); msg.append(" -s <file> the filesystem and use it" + lSep); | private static void printUsage() { String lSep = System.getProperty("line.separator"); StringBuffer msg = new StringBuffer(); msg.append("ant [options] [target [target2 [target3] ...]]" + lSep); msg.append("Options: " + lSep); msg.append(" -help print this message" + lSep); msg.append(" -projecthelp print project help information" + lSep); msg.append(" -version print the version information and exit" + lSep); msg.append(" -diagnostics print information that might be helpful to" + lSep); msg.append(" diagnose or report problems." + lSep); msg.append(" -quiet, -q be extra quiet" + lSep); msg.append(" -verbose, -v be extra verbose" + lSep); msg.append(" -debug print debugging information" + lSep); msg.append(" -emacs produce logging information without adornments" + lSep); msg.append(" -logfile <file> use given file for log" + lSep); msg.append(" -l <file> ''" + lSep); msg.append(" -logger <classname> the class which is to perform logging" + lSep); msg.append(" -listener <classname> add an instance of class as a project listener" + lSep); msg.append(" -noinput do not allow interactive input" + lSep); msg.append(" -buildfile <file> use given buildfile" + lSep); msg.append(" -file <file> ''" + lSep); msg.append(" -f <file> ''" + lSep); msg.append(" -D<property>=<value> use value for given property" + lSep); msg.append(" -keep-going, -k execute all targets that do not depend" + lSep); msg.append(" on failed target(s)" + lSep); msg.append(" -propertyfile <name> load all properties from file with -D" + lSep); msg.append(" properties taking precedence" + lSep); msg.append(" -inputhandler <class> the class which will handle input requests" + lSep); msg.append(" -find <file> search for buildfile towards the root of the" + lSep); msg.append(" filesystem and use it" + lSep); System.out.println(msg.toString()); } | 506 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/506/1fcc1b616775491d69f96edadb3a1ec62a7eb73f/Main.java/buggy/src/main/org/apache/tools/ant/Main.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
760,
918,
1172,
5357,
1435,
288,
3639,
514,
328,
5097,
273,
2332,
18,
588,
1396,
2932,
1369,
18,
11287,
8863,
3639,
6674,
1234,
273,
394,
6674,
5621,
3639,
1234,
18,
6923,
2932,
970... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
760,
918,
1172,
5357,
1435,
288,
3639,
514,
328,
5097,
273,
2332,
18,
588,
1396,
2932,
1369,
18,
11287,
8863,
3639,
6674,
1234,
273,
394,
6674,
5621,
3639,
1234,
18,
6923,
2932,
970... |
Type type = queryPart.getType(); if (type instanceof SetType) { type = ((SetType) type).getElementType(); | Type exprType = queryPart.getType(); if (exprType instanceof SetType) { exprType = ((SetType) exprType).getElementType(); | private Hierarchy[] collectHierarchies(Exp queryPart) { Type type = queryPart.getType(); if (type instanceof SetType) { type = ((SetType) type).getElementType(); } if (type instanceof TupleType) { final Type[] types = ((TupleType) type).elementTypes; ArrayList hierarchyList = new ArrayList(); for (int i = 0; i < types.length; i++) { final Hierarchy hierarchy = types[i].getHierarchy(); hierarchyList.add(hierarchy); } return (Hierarchy[]) hierarchyList.toArray(new Hierarchy[hierarchyList.size()]); } return new Hierarchy[] {type.getHierarchy()}; } | 51263 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/51263/c47c34fc2b9857bdd2bc8779f05b9f44abaf6a44/Query.java/clean/src/main/mondrian/olap/Query.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
670,
6000,
8526,
3274,
44,
5148,
606,
12,
2966,
843,
1988,
13,
288,
3639,
1412,
618,
273,
843,
1988,
18,
588,
559,
5621,
3639,
309,
261,
723,
1276,
1000,
559,
13,
288,
5411,
618,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
670,
6000,
8526,
3274,
44,
5148,
606,
12,
2966,
843,
1988,
13,
288,
3639,
1412,
618,
273,
843,
1988,
18,
588,
559,
5621,
3639,
309,
261,
723,
1276,
1000,
559,
13,
288,
5411,
618,
... |
( (GridData) name.getComboBoxControl( getFieldEditorParent( ) ) .getLayoutData( ) ).widthHint = 166; | ((GridData) name.getComboBoxControl(getFieldEditorParent()) .getLayoutData()).widthHint = 166; | protected void adjustGridLayout( ) { super.adjustGridLayout( ); ( (GridData) name.getComboBoxControl( getFieldEditorParent( ) ) .getLayoutData( ) ).widthHint = 166; ( (GridData) color.getColorSelector( ).getLayoutData( ) ).widthHint = 96; ( (GridData) size.getComboBoxControl( getFieldEditorParent( ) ) .getLayoutData( ) ).widthHint = 88; ( (GridData) size.getMeasureControl( getFieldEditorParent( ) ) .getLayoutData( ) ).widthHint = 50; ( (GridData) style.getComboBoxControl( getFieldEditorParent( ) ) .getLayoutData( ) ).widthHint = 170; ( (GridData) weight.getComboBoxControl( getFieldEditorParent( ) ) .getLayoutData( ) ).widthHint = 170; } | 12803 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/12803/4d78f7686771fae0403ed68a06a850b0f45d97fa/FontPreferencePage.java/buggy/UI/org.eclipse.birt.report.designer.ui/src/org/eclipse/birt/report/designer/internal/ui/dialogs/FontPreferencePage.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1117,
918,
5765,
6313,
3744,
12,
262,
202,
95,
202,
202,
9565,
18,
13362,
6313,
3744,
12,
11272,
202,
202,
12,
261,
6313,
751,
13,
508,
18,
588,
22199,
3367,
12,
5031,
6946,
3054,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1117,
918,
5765,
6313,
3744,
12,
262,
202,
95,
202,
202,
9565,
18,
13362,
6313,
3744,
12,
11272,
202,
202,
12,
261,
6313,
751,
13,
508,
18,
588,
22199,
3367,
12,
5031,
6946,
3054,
... |
return null; | checkIndex (parameterIndex); return result; | public Object getObject(int parameterIndex) throws SQLException { return null; } | 2413 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/2413/00ccc8e9b4c809d4a9e0fcd57f6e850f307d9224/CallableStatement.java/clean/org/postgresql/jdbc2/CallableStatement.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
1033,
6455,
12,
474,
25412,
13,
202,
15069,
6483,
202,
95,
202,
202,
2463,
446,
31,
202,
97,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
1033,
6455,
12,
474,
25412,
13,
202,
15069,
6483,
202,
95,
202,
202,
2463,
446,
31,
202,
97,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-... |
private String readLiteral (int flags) | private String readLiteral(int flags) | private String readLiteral (int flags) throws SAXException, IOException { char delim, c; int startLine = line; boolean saved = expandPE; boolean savedReport = doReport; // Find the first delimiter. delim = readCh (); if (delim != '"' && delim != '\'') { error ("expected '\"' or \"'\"", delim, null); return null; } inLiteral = true; if ((flags & LIT_DISABLE_PE) != 0) expandPE = false; doReport = false; // Each level of input source has its own buffer; remember // ours, so we won't read the ending delimiter from any // other input source, regardless of entity processing. char ourBuf [] = readBuffer; // Read the literal. try { c = readCh (); boolean ampRead = false;loop: while (! (c == delim && readBuffer == ourBuf)) { switch (c) { // attributes and public ids are normalized // in almost the same ways case '\n': case '\r': if ((flags & (LIT_ATTRIBUTE | LIT_PUBID)) != 0) c = ' '; break; case '\t': if ((flags & LIT_ATTRIBUTE) != 0) c = ' '; break; case '&': c = readCh (); // Char refs are expanded immediately, except for // all the cases where it's deferred. if (c == '#') { if ((flags & LIT_DISABLE_CREF) != 0) { dataBufferAppend ('&'); break; } parseCharRef (false /* Do not do flushDataBuffer */); // exotic WFness risk: this is an entity literal, // dataBuffer [dataBufferPos - 1] == '&', and // following chars are a _partial_ entity/char ref // It looks like an entity ref ... } else { unread (c); // Expand it? if ((flags & LIT_ENTITY_REF) > 0) { parseEntityRef (false); if (String.valueOf (readBuffer).equals("&")) ampRead = true; //Is it just data? } else if ((flags & LIT_DISABLE_EREF) != 0) { dataBufferAppend ('&'); // OK, it will be an entity ref -- expanded later. } else { String name = readNmtoken (true); require (';'); dataBufferAppend ('&'); dataBufferAppend (name); dataBufferAppend (';'); } } c = readCh (); continue loop; case '<': // and why? Perhaps so "&foo;" expands the same // inside and outside an attribute? if ((flags & LIT_ATTRIBUTE) != 0) error ("attribute values may not contain '<'"); break; // We don't worry about case '%' and PE refs, readCh does. default: break; } dataBufferAppend (c); c = readCh (); } } catch (EOFException e) { error ("end of input while looking for delimiter (started on line " + startLine + ')', null, new Character (delim).toString ()); } inLiteral = false; expandPE = saved; doReport = savedReport; // Normalise whitespace if necessary. if ((flags & LIT_NORMALIZE) > 0) { dataBufferNormalize (); } // Return the value. return dataBufferToString (); } | 25337 /local/tlutelli/issta_data/temp/all_java2context/java/2006_temp/2006/25337/7fb7568e63c3fe14af521de4699cb37898923ca7/XmlParser.java/buggy/libjava/gnu/xml/aelfred2/XmlParser.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
514,
855,
6177,
12,
474,
2943,
13,
565,
1216,
14366,
16,
1860,
565,
288,
202,
3001,
202,
23822,
16,
276,
31,
202,
474,
202,
1937,
1670,
273,
980,
31,
202,
6494,
202,
14077,
273,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
514,
855,
6177,
12,
474,
2943,
13,
565,
1216,
14366,
16,
1860,
565,
288,
202,
3001,
202,
23822,
16,
276,
31,
202,
474,
202,
1937,
1670,
273,
980,
31,
202,
6494,
202,
14077,
273,
... |
return; | doAttach(cycle); attached = true; | public final void attach(final RequestCycle cycle) { if (attached) { return; } doAttach(cycle); attached = true; } | 46434 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/46434/c115d7a37cdcba89f06d37acc5a9f346d51786cf/IdListAdapter.java/buggy/wicket/src/java/wicket/markup/html/form/IdListAdapter.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
727,
918,
3306,
12,
6385,
1567,
13279,
8589,
13,
565,
288,
3639,
309,
261,
24157,
13,
3639,
288,
5411,
741,
4761,
12,
13946,
1769,
7495,
273,
638,
31,
3639,
289,
3639,
741,
4761,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
727,
918,
3306,
12,
6385,
1567,
13279,
8589,
13,
565,
288,
3639,
309,
261,
24157,
13,
3639,
288,
5411,
741,
4761,
12,
13946,
1769,
7495,
273,
638,
31,
3639,
289,
3639,
741,
4761,
... |
InboundVariable iv = new InboundVariable(ctx, "type", "true"); | InboundVariable iv = new InboundVariable(ctx, null, "type", "true"); | public void testConvertInbound() throws Exception { InboundContext ctx = new InboundContext(); InboundVariable iv = new InboundVariable(ctx, "type", "true"); Object result = converter.convertInbound(Boolean.class, iv, ctx); assertNotNull(result); assertEquals(true, ((Boolean) result).booleanValue()); iv = new InboundVariable(ctx, "type", "8"); result = converter.convertInbound(Byte.class, iv, ctx); assertNotNull(result); assertTrue(result instanceof Byte); assertEquals(new Byte("8"), result); iv = new InboundVariable(ctx, "type", ""); result = converter.convertInbound(Byte.class, iv, ctx); assertNotNull(result); assertTrue(result instanceof Byte); assertEquals(new Byte("0"), result); iv = new InboundVariable(ctx, "type", "5"); result = converter.convertInbound(Short.class, iv, ctx); assertNotNull(result); assertTrue(result instanceof Short); assertEquals(new Short("5"), result); iv = new InboundVariable(ctx, "type", "t"); result = converter.convertInbound(Character.class, iv, ctx); assertNotNull(result); assertTrue(result instanceof Character); assertEquals('t', ((Character) result).charValue()); iv = new InboundVariable(ctx, "type", "2"); result = converter.convertInbound(Integer.class, iv, ctx); assertNotNull(result); assertTrue(result instanceof Integer); assertEquals(2, ((Integer) result).intValue()); iv = new InboundVariable(ctx, "type", "2"); result = converter.convertInbound(Long.class, iv, ctx); assertNotNull(result); assertTrue(result instanceof Long); assertEquals(new Long(2), result); iv = new InboundVariable(ctx, "type", "2"); result = converter.convertInbound(Float.class, iv, ctx); assertNotNull(result); assertTrue(result instanceof Float); assertEquals(new Float(2), result); iv = new InboundVariable(ctx, "type", "2"); result = converter.convertInbound(Double.class, iv, ctx); assertNotNull(result); assertTrue(result instanceof Double); assertEquals(new Double(2), result); iv = new InboundVariable(ctx, "type", "2"); result = converter.convertInbound(String.class, iv, ctx); assertNotNull(result); assertTrue(result instanceof String); assertEquals("2", result); } | 45384 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/45384/5036a4257c94dc7f3331ef721820289056906448/PrimitiveConverterTests.java/clean/test/uk/ltd/getahead/dwr/convert/PrimitiveConverterTests.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1842,
2723,
20571,
1435,
1216,
1185,
565,
288,
3639,
657,
3653,
1042,
1103,
273,
394,
657,
3653,
1042,
5621,
3639,
657,
3653,
3092,
4674,
273,
394,
657,
3653,
3092,
12,
5900,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1842,
2723,
20571,
1435,
1216,
1185,
565,
288,
3639,
657,
3653,
1042,
1103,
273,
394,
657,
3653,
1042,
5621,
3639,
657,
3653,
3092,
4674,
273,
394,
657,
3653,
3092,
12,
5900,
1... |
startsWithQuestionWord = true; break; | final char nextChar = name.charAt(prefix.length()); if(Character.isUpperCase(nextChar) || nextChar == '_') { startsWithQuestionWord = true; break; } | public void visitMethod(PsiMethod method){ super.visitMethod(method); final PsiType returnType = method.getReturnType(); if(returnType== null) { return; } if(returnType.equals(PsiType.BOOLEAN)) { return; } final String name = method.getName(); boolean startsWithQuestionWord = false; for(Iterator iterator = nameList.iterator(); iterator.hasNext();){ final String prefix = (String) iterator.next(); if(name.startsWith(prefix)) { startsWithQuestionWord = true; break; } } if(!startsWithQuestionWord) { return; } if(isOverrideOfLibraryMethod(method)){ return; } registerMethodError(method); } | 56627 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/56627/518b103ee7fb3bfbce7991c2b5970243827c57a2/NonBooleanMethodNameMayNotStartWithQuestionInspection.java/buggy/plugins/InspectionGadgets/src/com/siyeh/ig/naming/NonBooleanMethodNameMayNotStartWithQuestionInspection.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
540,
1071,
918,
25138,
12,
52,
7722,
1305,
707,
15329,
5411,
2240,
18,
11658,
1305,
12,
2039,
1769,
5411,
727,
453,
7722,
559,
9424,
273,
707,
18,
588,
9102,
5621,
5411,
309,
12,
2463,
559,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
540,
1071,
918,
25138,
12,
52,
7722,
1305,
707,
15329,
5411,
2240,
18,
11658,
1305,
12,
2039,
1769,
5411,
727,
453,
7722,
559,
9424,
273,
707,
18,
588,
9102,
5621,
5411,
309,
12,
2463,
559,
... |
Main.main.getMapFrame().mapView.repaint(); | Main.map.mapView.repaint(); | public void actionPerformed(ActionEvent e) { Layer l = layer == null ? (Layer)layers.getSelectedValue() : layer; l.visible = !l.visible; Main.main.getMapFrame().mapView.repaint(); layers.repaint(); } | 2204 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/2204/65d8ba1e1c7192a02b1c996304587a81a85155f1/LayerList.java/clean/src/org/openstreetmap/josm/gui/dialogs/LayerList.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
540,
1071,
918,
26100,
12,
1803,
1133,
425,
13,
288,
5411,
12112,
328,
273,
3018,
422,
446,
692,
261,
4576,
13,
10396,
18,
588,
7416,
620,
1435,
294,
3018,
31,
5411,
328,
18,
8613,
273,
401,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
540,
1071,
918,
26100,
12,
1803,
1133,
425,
13,
288,
5411,
12112,
328,
273,
3018,
422,
446,
692,
261,
4576,
13,
10396,
18,
588,
7416,
620,
1435,
294,
3018,
31,
5411,
328,
18,
8613,
273,
401,... |
case 25: return s85; | public DFA.State transition(IntStream input) throws RecognitionException { switch ( input.LA(1) ) { case 24: return s84; case 25: return s85; case EOL: case ID: case INT: case BOOL: case STRING: case FLOAT: case MISC: case WS: case SH_STYLE_SINGLE_LINE_COMMENT: case C_STYLE_SINGLE_LINE_COMMENT: case MULTI_LINE_COMMENT: case 15: case 16: case 17: case 18: case 19: case 20: case 21: case 22: case 23: case 26: case 27: case 28: case 29: case 30: case 31: case 32: case 33: case 34: case 35: case 36: case 37: case 38: case 39: case 40: case 41: case 42: case 43: case 44: case 45: case 46: case 47: case 48: case 49: case 50: case 51: case 52: case 53: case 54: case 55: case 56: case 57: return s86; default: NoViableAltException nvae = new NoViableAltException("", 4, 71, input); throw nvae; } } | 6736 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/6736/506adcf4556609ba2040aab4c53c1e38dbf7c80e/RuleParser.java/clean/drools-compiler/src/main/java/org/drools/lang/RuleParser.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
2398,
1071,
463,
2046,
18,
1119,
6007,
12,
1702,
1228,
810,
13,
1216,
9539,
288,
7734,
1620,
261,
810,
18,
2534,
12,
21,
13,
262,
288,
7734,
648,
4248,
30,
10792,
327,
272,
5193,
31,
7734,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
2398,
1071,
463,
2046,
18,
1119,
6007,
12,
1702,
1228,
810,
13,
1216,
9539,
288,
7734,
1620,
261,
810,
18,
2534,
12,
21,
13,
262,
288,
7734,
648,
4248,
30,
10792,
327,
272,
5193,
31,
7734,
... | |
RubyModule newModule = getRuby().defineModuleId(getRuby().intern(name)); | RubyModule newModule = getRuby().defineModuleId(getRuby().intern(name)); | public RubyModule defineModuleUnder(String name) { RubyModule newModule = getRuby().defineModuleId(getRuby().intern(name)); setConstant(getRuby().intern(name), newModule); newModule.setClassPath(this, name); return newModule; } | 45221 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/45221/0a7181933af700ea8025a4197f3a5ebcc08333c3/RubyModule.java/clean/org/jruby/RubyModule.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
19817,
3120,
4426,
3120,
14655,
12,
780,
508,
13,
288,
202,
202,
54,
10340,
3120,
394,
3120,
273,
4170,
10340,
7675,
11255,
3120,
548,
12,
588,
54,
10340,
7675,
267,
798,
12,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
19817,
3120,
4426,
3120,
14655,
12,
780,
508,
13,
288,
202,
202,
54,
10340,
3120,
394,
3120,
273,
4170,
10340,
7675,
11255,
3120,
548,
12,
588,
54,
10340,
7675,
267,
798,
12,
... |
JScrollPane treeScrollPane = createTreeScrollPane(); JTabbedPane editingTabbedPane = new RuleEditingTabbedPane(m_tree); JSplitPane splitPane = createSplitPane(treeScrollPane, editingTabbedPane); JPanel buttonPanel = createButtonPanel(); | JScrollPane treeScrollPane; JSplitPane splitPane; JPanel buttonPanel; treeScrollPane = createTreeScrollPane(); m_editingTabbedPane = new RuleEditingTabbedPane(m_tree); splitPane = createSplitPane(treeScrollPane, m_editingTabbedPane); buttonPanel = createButtonPanel(); | protected RulesEditor(PMDViewer pmdViewer) throws PMDException { super(pmdViewer, "Rules Editor", true); m_pmdViewer = pmdViewer; int windowWidth = 1200; int windowHeight = 900; int windowMargin = 10; Dimension screenSize = getToolkit().getScreenSize(); if (windowWidth >= screenSize.width) { windowWidth = screenSize.width - 10; } if (windowHeight >= screenSize.height) { windowHeight = screenSize.height - 20; } int windowLocationX = (screenSize.width - windowWidth) / 2; int windowLocationY = (screenSize.height - windowHeight) / 2; setLocation(windowLocationX, windowLocationY); setSize(windowWidth, windowHeight); setResizable(true); setDefaultCloseOperation(JDialog.DISPOSE_ON_CLOSE); buildTree(); JScrollPane treeScrollPane = createTreeScrollPane(); JTabbedPane editingTabbedPane = new RuleEditingTabbedPane(m_tree); JSplitPane splitPane = createSplitPane(treeScrollPane, editingTabbedPane); JPanel buttonPanel = createButtonPanel(); JPanel contentPanel = new JPanel(new BorderLayout()); contentPanel.add(splitPane, BorderLayout.CENTER); contentPanel.add(buttonPanel, BorderLayout.SOUTH); getContentPane().add(contentPanel); } | 45569 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/45569/43567bfc11ab6417f7dc5f2db496d3abafd70415/RulesEditor.java/clean/pmd/src/net/sourceforge/pmd/swingui/RulesEditor.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
4750,
15718,
6946,
12,
52,
6188,
18415,
293,
1264,
18415,
13,
3639,
1216,
453,
6188,
503,
565,
288,
3639,
2240,
12,
84,
1264,
18415,
16,
315,
4478,
18451,
3113,
638,
1769,
3639,
312,
67,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
4750,
15718,
6946,
12,
52,
6188,
18415,
293,
1264,
18415,
13,
3639,
1216,
453,
6188,
503,
565,
288,
3639,
2240,
12,
84,
1264,
18415,
16,
315,
4478,
18451,
3113,
638,
1769,
3639,
312,
67,
... |
public <T extends IObject> Map findAnnotations( | public <T extends IObject> Map<Long, Set<? extends IObject>> findAnnotations( | public <T extends IObject> Map findAnnotations( @NotNull Class<T> rootNodeType, @NotNull @Validate(Long.class) Set<Long> rootNodeIds, @Validate(Long.class) Set<Long> annotatorIds, Map options); | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/dc049d0769f78d30527024bfadfcc7adcbdc82cb/IPojos.java/clean/components/common/src/ome/api/IPojos.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
411,
56,
3231,
467,
921,
34,
1635,
32,
3708,
16,
1000,
12880,
3231,
467,
921,
9778,
1104,
5655,
12,
5411,
632,
5962,
1659,
32,
56,
34,
10181,
559,
16,
2398,
632,
5962,
632,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
411,
56,
3231,
467,
921,
34,
1635,
32,
3708,
16,
1000,
12880,
3231,
467,
921,
9778,
1104,
5655,
12,
5411,
632,
5962,
1659,
32,
56,
34,
10181,
559,
16,
2398,
632,
5962,
632,
... |
if (hasUnaryMinus) d = -d; | private ExpressionTreeNode parseFactor(Preprocessor p) throws IOException, MapyrusException { boolean hasUnaryMinus = false; boolean parsedDigit; StringBuffer buf = new StringBuffer(); ExpressionTreeNode expr; int c, lastC, quote; c = p.readNonSpace(); if (c == '\'' || c == '"') { /* * It's a quoted string. Keep reading up until matching quote. */ lastC = quote = c; while ((c = p.read()) != quote || lastC == '\\') { if (c == -1) { throw new MapyrusException(p.getCurrentFilenameAndLineNumber() + ": " + MapyrusMessages.get(MapyrusMessages.UNEXPECTED_EOF)); } if (lastC == '\\') { /* * '\\' compressed to single backslash, * '\n' converted to a newline, '\r' is stripped -- it * is not useful since we use Java's line separator internally. * Escaping of other characters is ignored. */ if (c == 'n') buf.append(Constants.LINE_SEPARATOR); else if (c != 'r') buf.append((char)c); } else if (c != '\\') { buf.append((char)c); } lastC = c; } return(new ExpressionTreeNode(new Argument(Argument.STRING, buf.toString()))); } if (c == '+') { /* * Skip unary plus. */ c = p.readNonSpace(); } if (c == '-') { /* * Note unary minus and continue. */ hasUnaryMinus = true; c = p.readNonSpace(); } if (Character.isDigit((char)c) || c == '.') { /* * Parse a decimal number and return it as a leaf node. */ parsedDigit = false; while (Character.isDigit((char)c)) { parsedDigit = true; buf.append((char)c); c = p.read(); } if (c == '.') { buf.append((char)c); c = p.read(); } while (Character.isDigit((char)c)) { parsedDigit = true; buf.append((char)c); c = p.read(); } if (!parsedDigit) { throw new MapyrusException(p.getCurrentFilenameAndLineNumber() + ": " + MapyrusMessages.get(MapyrusMessages.INVALID_NUMBER)); } if (c == 'e' || c == 'E') { buf.append((char)c); c = p.read(); if (c == '+' || c == '-') { buf.append((char)c); c = p.read(); } /* * Expect at least one digit for the exponent value. */ if (!Character.isDigit((char)c)) { throw new MapyrusException(p.getCurrentFilenameAndLineNumber() + ": " + MapyrusMessages.get(MapyrusMessages.INVALID_NUMBER)); } while (Character.isDigit((char)c)) { buf.append((char)c); c = p.read(); } } p.unread(c); double d = 0.0; try { d = Double.parseDouble(buf.toString()); } catch (NumberFormatException e) { /* * We parsed the number so it will * always be valid. */ } if (hasUnaryMinus) d = -d; return(new ExpressionTreeNode(new Argument(d))); } if (c == -1) { throw new MapyrusException(p.getCurrentFilenameAndLineNumber() + ": " + MapyrusMessages.get(MapyrusMessages.UNEXPECTED_EOF)); } if (c == '(') { expr = parseOrBoolean(p); c = p.readNonSpace(); if (c != ')') { throw new MapyrusException(p.getCurrentFilenameAndLineNumber() + ": " + MapyrusMessages.get(MapyrusMessages.UNMATCHED_BRACKET)); } } else if (Character.isLetter((char)c) || c == '$') { /* * It does not look like a numeric expression or a string * expression so maybe it is a variable name or function. */ buf.append((char)c); c = p.read(); while (c != -1 && (c == '.' || c == '_' || Character.isLetterOrDigit((char)c))) { buf.append((char)c); c = p.read(); } /* * Is this a function call like "round(3.14)"? */ Integer functionType = (Integer)(mFunctionTypeLookup.get(buf.toString())); if (functionType != null) { /* * Parse opening '(', arguments for this function, then closing ')'. */ if (Character.isWhitespace((char)c)) c = p.readNonSpace(); if (c != '(') { throw new MapyrusException(p.getCurrentFilenameAndLineNumber() + ": " + MapyrusMessages.get(MapyrusMessages.EXPECTED) + ": '('"); } int nArgs = mFunctionArgumentCount[functionType.intValue()]; ExpressionTreeNode functionExpressions[] = new ExpressionTreeNode[Math.max(nArgs, 3)]; /* * Parse expression for each function argument. */ for (int i = 0; i < functionExpressions.length; i++) functionExpressions[i] = null; for (int i = 0; i < nArgs; i++) { if (i > 0) { /* * Parse comma before next value. */ c = p.readNonSpace(); if (c != ',') { throw new MapyrusException(p.getCurrentFilenameAndLineNumber() + ": " + MapyrusMessages.get(MapyrusMessages.WRONG_FUNCTION_VALUES) + ": " + buf.toString()); } } functionExpressions[i] = parseOrBoolean(p); } c = p.readNonSpace(); if (c != ')') { throw new MapyrusException(p.getCurrentFilenameAndLineNumber() + ": " + MapyrusMessages.get(MapyrusMessages.WRONG_FUNCTION_VALUES) + ": " + buf.toString()); } expr = new ExpressionTreeNode(functionType.intValue(), functionExpressions[0], functionExpressions[1], functionExpressions[2]); } else { p.unread(c); expr = new ExpressionTreeNode(new Argument(Argument.VARIABLE, buf.toString())); } } else { /* * It's nothing that we understand. */ throw new MapyrusException(p.getCurrentFilenameAndLineNumber() + ": " + MapyrusMessages.get(MapyrusMessages.INVALID_EXPRESSION)); } if (hasUnaryMinus) { /* * Expand expression to negate value. */ ExpressionTreeNode left = new ExpressionTreeNode(Argument.numericMinusOne); expr = new ExpressionTreeNode(left, MULTIPLY_OPERATION, expr); } return(expr); } | 2501 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/2501/bffee09d58665e5275d5dd1c1a1de447af96a391/Expression.java/buggy/src/org/mapyrus/Expression.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
5371,
12513,
1109,
6837,
12,
1386,
8700,
293,
13,
1216,
1860,
16,
1635,
93,
8010,
503,
202,
95,
202,
202,
6494,
711,
15972,
18434,
273,
629,
31,
202,
202,
6494,
2707,
10907,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
5371,
12513,
1109,
6837,
12,
1386,
8700,
293,
13,
1216,
1860,
16,
1635,
93,
8010,
503,
202,
95,
202,
202,
6494,
711,
15972,
18434,
273,
629,
31,
202,
202,
6494,
2707,
10907,
... | |
( (BarSeries) series ).setRiserOutline( (ColorDefinition) event.data ); | if ( event.type == FillChooserComposite.FILL_CHANGED_EVENT ) { ( (BarSeries) series ).setRiserOutline( (ColorDefinition) event.data ); } | public void handleEvent( Event event ) { if ( event.widget.equals( fccRiserOutline ) ) { ( (BarSeries) series ).setRiserOutline( (ColorDefinition) event.data ); } } | 12803 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/12803/c996633e78e0adbdb5c29f63d3f3d7c52b2b3f76/BarSeriesAttributeComposite.java/buggy/chart/org.eclipse.birt.chart.ui.extension/src/org/eclipse/birt/chart/ui/swt/series/BarSeriesAttributeComposite.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
1640,
1133,
12,
2587,
871,
262,
202,
95,
202,
202,
430,
261,
871,
18,
6587,
18,
14963,
12,
284,
952,
54,
15914,
21805,
262,
262,
202,
202,
95,
1082,
202,
12,
261,
5190,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
1640,
1133,
12,
2587,
871,
262,
202,
95,
202,
202,
430,
261,
871,
18,
6587,
18,
14963,
12,
284,
952,
54,
15914,
21805,
262,
262,
202,
202,
95,
1082,
202,
12,
261,
5190,... |
return xmlLib.xmlPrimaryReference(xmlName, scope); | return xmlLib.xmlPrimaryReference(cx, xmlName, scope); | public static Object xmlReference(Object xmlName, Context cx, Scriptable scope) { XMLLib xmlLib = currentXMLLib(cx); return xmlLib.xmlPrimaryReference(xmlName, scope); } | 12904 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/12904/0bc442b668a85796112e6a1719b6befcabb17ea4/ScriptRuntime.java/buggy/js/rhino/src/org/mozilla/javascript/ScriptRuntime.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
760,
1033,
2025,
2404,
12,
921,
2025,
461,
16,
4766,
1377,
1772,
9494,
16,
4766,
1377,
22780,
2146,
13,
565,
288,
3639,
3167,
5664,
2025,
5664,
273,
783,
4201,
5664,
12,
71,
92,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
760,
1033,
2025,
2404,
12,
921,
2025,
461,
16,
4766,
1377,
1772,
9494,
16,
4766,
1377,
22780,
2146,
13,
565,
288,
3639,
3167,
5664,
2025,
5664,
273,
783,
4201,
5664,
12,
71,
92,
1... |
.buildRule()); | .buildRule(), ResourcesPlugin.FAMILY_MANUAL_BUILD); | public void run() { // Save all resources prior to doing build saveAllResources(); runInBackground(ResourcesPlugin.getWorkspace().getRuleFactory() .buildRule()); } | 56152 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/56152/e4f3f849dbf9b6f0963b417f68ecad8ddbfaf20c/BuildAction.java/clean/bundles/org.eclipse.ui.ide/extensions/org/eclipse/ui/actions/BuildAction.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1086,
1435,
288,
3639,
368,
7074,
777,
2703,
6432,
358,
9957,
1361,
3639,
1923,
1595,
3805,
5621,
3639,
1086,
382,
8199,
12,
3805,
3773,
18,
588,
8241,
7675,
588,
2175,
1733,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1086,
1435,
288,
3639,
368,
7074,
777,
2703,
6432,
358,
9957,
1361,
3639,
1923,
1595,
3805,
5621,
3639,
1086,
382,
8199,
12,
3805,
3773,
18,
588,
8241,
7675,
588,
2175,
1733,
1... |
protected Collection translateItem(Item srcItem) throws ObjectStoreException, InterMineException { Collection result = new HashSet(); String srcNs = XmlUtil.getNamespaceFromURI(srcItem.getClassName()); String className = XmlUtil.getFragmentFromURI(srcItem.getClassName()); Collection translated = super.translateItem(srcItem); if (translated != null) { for (Iterator i = translated.iterator(); i.hasNext();) { boolean storeTgtItem = true; Item tgtItem = (Item) i.next(); if ("karyotype".equals(className)) { tgtItem.addReference(getOrgRef()); addReferencedItem(tgtItem, getEnsemblDb(), "evidence", true, "", false); Item location = createLocation(srcItem, tgtItem, true); location.addAttribute(new Attribute("strand", "0")); result.add(location); } else if ("exon".equals(className)) { tgtItem.addReference(getOrgRef()); Item stableId = getStableId("exon", srcItem.getIdentifier(), srcNs); if (stableId != null) { moveField(stableId, tgtItem, "stable_id", "identifier"); } addReferencedItem(tgtItem, getEnsemblDb(), "evidence", true, "", false); Item location = createLocation(srcItem, tgtItem, true); result.add(location); } else if ("gene".equals(className)) { tgtItem.addReference(getOrgRef()); addReferencedItem(tgtItem, getEnsemblDb(), "evidence", true, "", false); Item location = createLocation(srcItem, tgtItem, true); result.add(location); Item anaResult = createAnalysisResult(srcItem, tgtItem); result.add(anaResult); List comments = getCommentIds(srcItem.getIdentifier(), srcNs); if (!comments.isEmpty()) { tgtItem.addCollection(new ReferenceList("comments", comments)); } // gene name should be its stable id (or identifier if none) Item stableId = null; stableId = getStableId("gene", srcItem.getIdentifier(), srcNs); if (stableId != null) { moveField(stableId, tgtItem, "stable_id", "identifier"); } else { tgtItem.addAttribute(new Attribute("identifier", srcItem.getIdentifier())); } // display_xref is gene name (?) //promoteField(tgtItem, srcItem, "name", "display_xref", "display_label"); result.addAll(setGeneSynonyms(srcItem, tgtItem, srcNs)); // if no organismDbId set to be same as identifier if (!tgtItem.hasAttribute("organismDbId")) { tgtItem.addAttribute(new Attribute("organismDbId", tgtItem.getAttribute("identifier").getValue())); } } else if ("transcript".equals(className)) { tgtItem.addReference(getOrgRef()); addReferencedItem(tgtItem, getEnsemblDb(), "evidence", true, "", false); Item geneRelation = createItem(tgtNs + "SimpleRelation", ""); addReferencedItem(tgtItem, geneRelation, "objects", true, "subject", false); moveField(srcItem, geneRelation, "gene", "object"); result.add(geneRelation); // if no identifier set the identifier as name (primary key) if (!tgtItem.hasAttribute("identifier")) { Item stableId = getStableId("transcript", srcItem.getIdentifier(), srcNs); if (stableId != null) { moveField(stableId, tgtItem, "stable_id", "identifier"); } else { tgtItem.addAttribute(new Attribute("identifier", srcItem.getIdentifier())); } } Item location = createLocation(srcItem, tgtItem, true); result.add(location); } else if ("translation".equals(className)) { Item protein = getProteinByPrimaryAccession(srcItem, srcNs); if (protein != null && srcItem.hasReference("transcript")) { String transcriptId = srcItem.getReference("transcript").getRefId(); Item transRelation = createItem(tgtNs + "SimpleRelation", ""); transRelation.addReference(new Reference("subject", transcriptId)); addReferencedItem(protein, transRelation, "subjects", true, "object", false); result.add(transRelation); } storeTgtItem = false; // stable_ids become syonyms, need ensembl Database as source } else if (className.endsWith("_stable_id")) { if (className.endsWith("translation_stable_id")) { storeTgtItem = false; } else { tgtItem.addReference(getEnsemblRef()); tgtItem.addAttribute(new Attribute("type", "identifier")); } // } else if ("prediction_transcript".equals(className)) { // tgtItem.addReference(getOrgRef()); // result.add(createLocation(srcItem, tgtItem, true)); } else if ("repeat_feature".equals(className)) { tgtItem.addReference(getOrgRef()); addReferencedItem(tgtItem, getEnsemblDb(), "evidence", true, "", false); result.add(createAnalysisResult(srcItem, tgtItem)); result.add(createLocation(srcItem, tgtItem, true)); promoteField(tgtItem, srcItem, "consensus", "repeat_consensus", "repeat_consensus"); promoteField(tgtItem, srcItem, "type", "repeat_consensus", "repeat_class"); promoteField(tgtItem, srcItem, "identifier", "repeat_consensus", "repeat_name"); } else if ("marker".equals(className)) { addReferencedItem(tgtItem, getEnsemblDb(), "evidence", true, "", false); Set locations = createLocations(srcItem, tgtItem, srcNs); List locationIds = new ArrayList(); for (Iterator j = locations.iterator(); j.hasNext(); ) { Item location = (Item) j.next(); locationIds.add(location.getIdentifier()); result.add(location); } //tgtItem.addCollection(new ReferenceList("locations", locationIds)); setNameAttribute(srcItem, tgtItem); //setSynonym } else if ("marker_synonym".equals(className)) { tgtItem.addAttribute(new Attribute("type", "identifier")); if (srcItem.hasAttribute("source")) { String source = srcItem.getAttribute("source").getValue(); if (source.equals("genbank")) { tgtItem.addReference(getGenbankRef()); } else if (source.equals("gdb")) { tgtItem.addReference(getGdbRef()); } else if (source.equals("unists")) { tgtItem.addReference(getUnistsRef()); } else { tgtItem.addReference(getEnsemblRef()); } } else { tgtItem.addReference(getEnsemblRef()); } } if (storeTgtItem) { result.add(tgtItem); } } // assembly maps to null but want to create location on a supercontig } else if ("assembly".equals(className)) { Item location = createAssemblyLocation(srcItem); result.add(location); // seq_region map to null, become Chromosome, Supercontig, Clone and Contig respectively } else if ("seq_region".equals(className)) { Item seq = getSeqItem(srcItem.getIdentifier()); result.add(seq); //simple_feature map to null, become TRNA/CpGIsland depending on analysis_id(logic_name) } else if ("simple_feature".equals(className)) { Item simpleFeature = createSimpleFeature(srcItem); result.add(simpleFeature); result.add(createLocation(srcItem, simpleFeature, true)); result.add(createAnalysisResult(srcItem, simpleFeature)); } return result; } | 7196 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/7196/75fa30e23d4ba676244e279242108e72c0f99d55/EnsemblHumanDataTranslator.java/clean/flymine/model/ensembl-human/src/java/org/flymine/dataconversion/EnsemblHumanDataTranslator.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
4750,
2532,
13929,
1180,
12,
3126,
1310,
1180,
13,
15069,
921,
21151,
16,
2465,
49,
558,
503,
95,
2532,
2088,
33,
2704,
13482,
5621,
780,
4816,
10386,
33,
4432,
1304,
18,
588,
3402,
1265,
3098... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
4750,
2532,
13929,
1180,
12,
3126,
1310,
1180,
13,
15069,
921,
21151,
16,
2465,
49,
558,
503,
95,
2532,
2088,
33,
2704,
13482,
5621,
780,
4816,
10386,
33,
4432,
1304,
18,
588,
3402,
1265,
3098... | ||
public void actionPerformed(AnActionEvent event) { log.debug("actionPerformed"); if (filter == null) { log.debug("no filter selected"); return; } long start = System.currentTimeMillis(); final Project project = (Project) event.getDataContext().getData(DataConstants.PROJECT); final ProjectRootManager projectRootManager = ProjectRootManager.getInstance(project); final ProjectFileIndex index = projectRootManager.getFileIndex(); // TODO: once a filter is defined we iterate over everything and see if it fits // if it does we add it to the list we're hopefully collecting // then sort the list and display it with the proper file status colors // and ICON indications of open or closed? // and also ICON indications of errors or not? // little endian camel case sort might be nice too VirtualFile[] roots = projectRootManager.getContentRoots(); log.debug("iterating content under roots"); XFilesContentIterator content = new XFilesContentIterator(filter); for (int i = 0; i < roots.length; i++) { VirtualFile root = roots[i]; log.debug("root " + root.getPath()); index.iterateContentUnderDirectory(root, content); } // TODO: FilterConfigurationPanel to edit configurations // TODO: FilterConfiguration to store individual configurations // TODO: XFilesFilter that uses selected FilterConfiguration to filter files // TODO: XFilesConfiguration class to hold FilterConfigurations and selected filter // TODO: the collected list should be run through the selected filter which should // define the sort order explicitly List included = content.getIncluded(); //Collections.sort(included, comparator); model.clear(); for (Iterator iterator = included.iterator(); iterator.hasNext();) { VirtualFile file = (VirtualFile) iterator.next(); model.addElement(file); } long finish = System.currentTimeMillis(); long delta = finish - start; WindowManager windowManager = WindowManager.getInstance(); StatusBar statusBar = windowManager.getStatusBar(project); statusBar.setInfo("filter refreshed in " + delta + "ms; " + content + " " + filter); // TODO: decide how to do logical combination of selection based on the information above // i.e. if two statuses and two file types are selected for inclusion what is the expected result // clearly, logical or between selections of the same type (file type, file status, etc.) // but logical and/or between selections of different types might both be useful // i.e. these statuses AND those types // vs these status OR those types } | 4589 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/4589/a095ca0e794a1a91a38297713e8880096f2686e9/RefreshAction.java/buggy/src/com/echologic/xfiles/RefreshAction.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
26100,
12,
979,
1803,
1133,
871,
13,
288,
225,
613,
18,
4148,
2932,
1128,
13889,
8863,
225,
309,
261,
2188,
422,
446,
13,
288,
1330,
18,
4148,
2932,
2135,
1034,
3170,
8863,
2... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
26100,
12,
979,
1803,
1133,
871,
13,
288,
225,
613,
18,
4148,
2932,
1128,
13889,
8863,
225,
309,
261,
2188,
422,
446,
13,
288,
1330,
18,
4148,
2932,
2135,
1034,
3170,
8863,
2... | ||
workingSetManager = null; | if (workingSetManager != null) { workingSetManager.dispose(); workingSetManager = null; } | void reset() { editorRegistry = null; if (decoratorManager != null) { decoratorManager.dispose(); decoratorManager = null; } ProgressManager.shutdownProgressManager(); themeRegistry = null; workingSetManager = null; workingSetRegistry = null; preferenceManager = null; if (viewRegistry != null) { viewRegistry.dispose(); viewRegistry = null; } if (perspRegistry != null) { perspRegistry.dispose(); perspRegistry = null; } actionSetRegistry = null; sharedImages = null; productInfo = null; introRegistry = null; DEBUG = false; } | 56152 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/56152/1dfd3d42d5b7ec993408e79c71c6db3f948172e2/WorkbenchPlugin.java/buggy/bundles/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal/WorkbenchPlugin.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
918,
2715,
1435,
288,
3639,
4858,
4243,
273,
446,
31,
3639,
309,
261,
19142,
1318,
480,
446,
13,
288,
5411,
7367,
1318,
18,
2251,
4150,
5621,
5411,
7367,
1318,
273,
446,
31,
3639,
289,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
918,
2715,
1435,
288,
3639,
4858,
4243,
273,
446,
31,
3639,
309,
261,
19142,
1318,
480,
446,
13,
288,
5411,
7367,
1318,
18,
2251,
4150,
5621,
5411,
7367,
1318,
273,
446,
31,
3639,
289,
... |
return new CASTArrayDesignator(); } | return new CASTArrayDesignator(); } | protected ICASTArrayDesignator createArrayDesignator() { return new CASTArrayDesignator(); } | 54911 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54911/8d833f012a81dac41a0d33c7e0f047c1dfe415f2/GNUCSourceParser.java/buggy/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/dom/parser/c/GNUCSourceParser.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
565,
4750,
467,
21871,
1076,
15478,
639,
752,
1076,
15478,
639,
1435,
288,
1377,
327,
394,
6425,
882,
1076,
15478,
639,
5621,
282,
289,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
565,
4750,
467,
21871,
1076,
15478,
639,
752,
1076,
15478,
639,
1435,
288,
1377,
327,
394,
6425,
882,
1076,
15478,
639,
5621,
282,
289,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
if(ext.equals("js")) { | if (ext.equals("js")) { | void init() { setJMenuBar(menubar = new Menubar(this)); toolBar = new JToolBar(); JButton button; JButton breakButton, goButton, stepIntoButton, stepOverButton, stepOutButton; String [] toolTips = {"Break (Pause)", "Go (F5)", "Step Into (F11)", "Step Over (F7)", "Step Out (F8)"}; int count = 0; button = breakButton = new JButton("Break"); JButton focusButton = button; button.setToolTipText("Break"); button.setActionCommand("Break"); button.addActionListener(menubar); button.setEnabled(true); button.setToolTipText(toolTips[count++]); button = goButton = new JButton("Go"); button.setToolTipText("Go"); button.setActionCommand("Go"); button.addActionListener(menubar); button.setEnabled(false); button.setToolTipText(toolTips[count++]); button = stepIntoButton = new JButton("Step Into"); button.setToolTipText("Step Into"); button.setActionCommand("Step Into"); button.addActionListener(menubar); button.setEnabled(false); button.setToolTipText(toolTips[count++]); button = stepOverButton = new JButton("Step Over"); button.setToolTipText("Step Over"); button.setActionCommand("Step Over"); button.setEnabled(false); button.addActionListener(menubar); button.setToolTipText(toolTips[count++]); button = stepOutButton = new JButton("Step Out"); button.setToolTipText("Step Out"); button.setActionCommand("Step Out"); button.setEnabled(false); button.addActionListener(menubar); button.setToolTipText(toolTips[count++]); Dimension dim = stepOverButton.getPreferredSize(); breakButton.setPreferredSize(dim); breakButton.setMinimumSize(dim); breakButton.setMaximumSize(dim); breakButton.setSize(dim); goButton.setPreferredSize(dim); goButton.setMinimumSize(dim); goButton.setMaximumSize(dim); stepIntoButton.setPreferredSize(dim); stepIntoButton.setMinimumSize(dim); stepIntoButton.setMaximumSize(dim); stepOverButton.setPreferredSize(dim); stepOverButton.setMinimumSize(dim); stepOverButton.setMaximumSize(dim); stepOutButton.setPreferredSize(dim); stepOutButton.setMinimumSize(dim); stepOutButton.setMaximumSize(dim); toolBar.add(breakButton); toolBar.add(goButton); toolBar.add(stepIntoButton); toolBar.add(stepOverButton); toolBar.add(stepOutButton); JPanel contentPane = new JPanel(); contentPane.setLayout(new BorderLayout()); getContentPane().add(toolBar, BorderLayout.NORTH); getContentPane().add(contentPane, BorderLayout.CENTER); desk = new JDesktopPane(); desk.setPreferredSize(new Dimension(600, 300)); desk.setMinimumSize(new Dimension(150, 50)); desk.add(console = new JSInternalConsole("JavaScript Console")); context = new ContextWindow(this); context.setPreferredSize(new Dimension(600, 120)); context.setMinimumSize(new Dimension(50, 50)); split1 = new JSplitPane(JSplitPane.VERTICAL_SPLIT, desk, context); split1.setOneTouchExpandable(true); Main.setResizeWeight(split1, 0.66); contentPane.add(split1, BorderLayout.CENTER); statusBar = new JLabel(); statusBar.setText("Thread: "); contentPane.add(statusBar, BorderLayout.SOUTH); dlg = new JFileChooser(); javax.swing.filechooser.FileFilter filter = new javax.swing.filechooser.FileFilter() { public boolean accept(File f) { if(f.isDirectory()) { return true; } String n = f.getName(); int i = n.lastIndexOf('.'); if(i > 0 && i < n.length() -1) { String ext = n.substring(i + 1).toLowerCase(); if(ext.equals("js")) { return true; } } return false; } public String getDescription() { return "JavaScript Files (*.js)"; } }; dlg.addChoosableFileFilter(filter); final Main self = this; addWindowListener(new WindowAdapter() { public void windowClosing(WindowEvent e) { self.Exit(); } }); } | 12564 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/12564/bebd557da53b74c60ab8525aa96904d4cee6224c/Main.java/clean/toolsrc/org/mozilla/javascript/tools/debugger/Main.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
918,
1208,
1435,
288,
3639,
444,
46,
4599,
5190,
12,
27617,
373,
297,
273,
394,
490,
275,
373,
297,
12,
2211,
10019,
3639,
5226,
5190,
273,
394,
804,
6364,
5190,
5621,
3639,
28804,
3568,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
918,
1208,
1435,
288,
3639,
444,
46,
4599,
5190,
12,
27617,
373,
297,
273,
394,
490,
275,
373,
297,
12,
2211,
10019,
3639,
5226,
5190,
273,
394,
804,
6364,
5190,
5621,
3639,
28804,
3568,
... |
if(lastInsertion == items.length) | if(lastInsertion == items.length) { | private void createAddedElements(Widget widget, Object[] elements) { if(elements.length == 1){ if (equals(elements[0], widget.getData())) return; } ViewerSorter sorter = getSorter (); TreePath parentPath = internalGetSorterParentPath(widget, sorter); Item[] items = getChildren(widget); //As the items are sorted already we optimize for a //start position int lastInsertion = 0; //Optimize for the empty case if(items.length == 0){ for (int i = 0; i < elements.length; i++) { createTreeItem(widget, elements[i], -1); } return; } for (int i = 0; i < elements.length; i++) { boolean newItem = true; Object element = elements[i]; int index; if(sorter == null){ if(itemExists(items,element)){ refresh(element); newItem = false; } index = -1; } else{ lastInsertion = insertionPosition(items,sorter,lastInsertion, element, parentPath); //As we are only searching the original array we keep track of those positions only if(lastInsertion == items.length) index = -1; else{//See if we should just refresh while(lastInsertion < items.length && internalCompare(sorter,parentPath,element,items[lastInsertion].getData()) == 0){ //As we cannot assume the sorter is consistent with equals() - therefore we can // just check against the item prior to this index (if any) if (items[lastInsertion].getData().equals(element)) { //refresh the element in case it has new children refresh(element); newItem = false; } lastInsertion ++;//We had an insertion so increment } //Did we get to the end? if(lastInsertion == items.length) index = -1; else index = lastInsertion + i; //Add the index as the array is growing } } if(newItem) createTreeItem(widget, element, index); } } | 58148 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/58148/391f2606b4ea2c1fb5052d938ca90877ee7631f6/AbstractTreeViewer.java/clean/bundles/org.eclipse.jface/src/org/eclipse/jface/viewers/AbstractTreeViewer.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
918,
752,
8602,
3471,
12,
4609,
3604,
16,
1033,
8526,
2186,
13,
288,
202,
202,
430,
12,
6274,
18,
2469,
422,
404,
15329,
1082,
202,
430,
261,
14963,
12,
6274,
63,
20,
6487,
3604,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
918,
752,
8602,
3471,
12,
4609,
3604,
16,
1033,
8526,
2186,
13,
288,
202,
202,
430,
12,
6274,
18,
2469,
422,
404,
15329,
1082,
202,
430,
261,
14963,
12,
6274,
63,
20,
6487,
3604,
... |
if(queryArgs != null) { | offset = retrieveOffsetValue(arguments); if(queryArgs != null) { | protected Object doInvokeInternal(final Class clazz, String methodName, final Object[] arguments) { if(arguments.length == 0) return getHibernateTemplate().loadAll(clazz); final Object arg = arguments[0] instanceof GString ? arguments[0].toString() :arguments[0]; // if the arg is an instance of the class find by example if(arg instanceof String) { final String query = (String)arg; if(!query.matches( "from "+clazz.getName()+".*" )) { throw new GrailsQueryException("Invalid query ["+query+"] for domain class ["+clazz+"]"); } return super.getHibernateTemplate().executeFind( new HibernateCallback() { public Object doInHibernate(Session session) throws HibernateException, SQLException { Query q = session.createQuery(query); Object[] queryArgs = null; int max = -1; if(arguments.length > 1) { if(arguments[1] instanceof List) { queryArgs = ((List)arguments[1]).toArray(); } else if(arguments[1].getClass().isArray()) { queryArgs = (Object[])arguments[1]; } } max = retrieveMaxValue(arguments); if(queryArgs != null) { for (int i = 0; i < queryArgs.length; i++) { if(queryArgs[0] instanceof GString) { q.setParameter(i,queryArgs[i].toString()); } else { q.setParameter(i, queryArgs[i]); } } } if(max > -1) { q.setMaxResults(max); } return q.list(); } private int retrieveMaxValue(Object[] arguments) { int max = -1; if(arguments.length > 1) { if(arguments[1] instanceof Integer) { max = ((Integer)arguments[1]).intValue(); } if(arguments.length > 2) { if(arguments[2] instanceof Integer) { max = ((Integer)arguments[2]).intValue(); } } } return max; } }); } if(clazz.isAssignableFrom( arg.getClass() )) { return super.getHibernateTemplate().executeFind( new HibernateCallback() { public Object doInHibernate(Session session) throws HibernateException, SQLException { Example example = Example.create(arg) .ignoreCase(); Criteria crit = session.createCriteria(clazz); crit.add(example); return crit.list(); } }); } throw new MissingMethodException(methodName,clazz,arguments); } | 26970 /local/tlutelli/issta_data/temp/all_java2context/java/2006_temp/2006/26970/eb420a51890989f6ca7f281725a19ebec728f77c/FindAllPersistentMethod.java/buggy/src/persistence/org/codehaus/groovy/grails/orm/hibernate/metaclass/FindAllPersistentMethod.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1117,
1033,
741,
10969,
3061,
12,
6385,
1659,
4003,
16,
514,
4918,
16,
1082,
202,
6385,
1033,
8526,
1775,
13,
288,
202,
202,
430,
12,
7099,
18,
2469,
422,
374,
13,
1082,
202,
2463,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1117,
1033,
741,
10969,
3061,
12,
6385,
1659,
4003,
16,
514,
4918,
16,
1082,
202,
6385,
1033,
8526,
1775,
13,
288,
202,
202,
430,
12,
7099,
18,
2469,
422,
374,
13,
1082,
202,
2463,... |
return this.name; | return name; | public String getFilename() { if(this.localFile != null) return this.localFile.getName(); else return this.name; } | 47012 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/47012/0458430a0dc8a713aa2b4d64f000cbbaaeb4adea/FCPClientPut.java/buggy/src/thaw/fcp/FCPClientPut.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
514,
14632,
1435,
288,
202,
202,
430,
12,
2211,
18,
3729,
812,
480,
446,
13,
1082,
202,
2463,
333,
18,
3729,
812,
18,
17994,
5621,
202,
202,
12107,
1082,
202,
2463,
333,
18,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
514,
14632,
1435,
288,
202,
202,
430,
12,
2211,
18,
3729,
812,
480,
446,
13,
1082,
202,
2463,
333,
18,
3729,
812,
18,
17994,
5621,
202,
202,
12107,
1082,
202,
2463,
333,
18,
... |
return _root; } | return _root; } | public Node getRootNode() { return _root; } | 47044 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/47044/1183932ca4a81d65d22482f0b44fb17eebce0f37/ExprEvaluationContextImpl.java/buggy/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/ExprEvaluationContextImpl.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
2029,
7656,
907,
1435,
288,
565,
327,
389,
3085,
31,
225,
289,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
2029,
7656,
907,
1435,
288,
565,
327,
389,
3085,
31,
225,
289,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-... |
GridInsertLocation getGridInsertLocation(final int x, final int y) { | GridInsertLocation getGridInsertLocation(final int x, final int y, final int dragColumnDelta) { | GridInsertLocation getGridInsertLocation(final int x, final int y) { final int EPSILON = 4; final RadContainer container = FormEditingUtil.getRadContainerAt(myEditor, x, y, EPSILON); if (container == null || !container.isGrid()) { return new GridInsertLocation(GridInsertMode.None); } final GridLayoutManager grid = (GridLayoutManager) container.getLayout(); final Point targetPoint = SwingUtilities.convertPoint(myEditor.getDragLayer(), x, y, container.getDelegee()); int[] xs = grid.getXs(); int[] ys = grid.getYs(); int[] widths = grid.getWidths(); int[] heights = grid.getHeights(); int row=ys.length-1, col=xs.length-1; for(int i=0; i<xs.length; i++) { if (targetPoint.getX() < xs [i]+widths [i]) { col=i; break; } } for(int i=0; i<ys.length; i++) { if (targetPoint.getY() < ys [i]+heights [i]) { row=i; break; } } GridInsertMode mode = GridInsertMode.None; int dx = (int)(targetPoint.getX() - xs [col]); if (dx < EPSILON) { mode = GridInsertMode.ColumnBefore; } else if (widths [col] - dx < EPSILON) { mode = GridInsertMode.ColumnAfter; } int dy = (int)(targetPoint.getY() - ys [row]); if (dy < EPSILON) { mode = GridInsertMode.RowBefore; } else if (heights [row] - dy < EPSILON) { mode = GridInsertMode.RowAfter; } if (mode != GridInsertMode.None) { Rectangle cellRect = new Rectangle(xs [col], ys [row], widths [col], heights [row]); return new GridInsertLocation(container, row, col, cellRect, mode); } return new GridInsertLocation(GridInsertMode.None); } | 56627 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/56627/4b6577aed3e1c2c292118646682bca5b00bcaf7d/GridInsertProcessor.java/buggy/ui-designer/impl/com/intellij/uiDesigner/GridInsertProcessor.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
7145,
4600,
2735,
336,
6313,
4600,
2735,
12,
6385,
509,
619,
16,
727,
509,
677,
16,
727,
509,
8823,
1494,
9242,
13,
288,
565,
727,
509,
24067,
30229,
273,
1059,
31,
565,
727,
16378,
217... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
7145,
4600,
2735,
336,
6313,
4600,
2735,
12,
6385,
509,
619,
16,
727,
509,
677,
16,
727,
509,
8823,
1494,
9242,
13,
288,
565,
727,
509,
24067,
30229,
273,
1059,
31,
565,
727,
16378,
217... |
delete(existing, subMonitor); | canMove = delete(existing, subMonitor); | protected void copy(IResource[] resources, IPath destination, IProgressMonitor subMonitor) throws CoreException { for (int i = 0; i < resources.length; i++) { IResource source = resources[i]; IPath destinationPath = destination.append(source.getName()); IWorkspace workspace = source.getWorkspace(); IWorkspaceRoot workspaceRoot = workspace.getRoot(); boolean isFolder = source.getType() == IResource.FOLDER; boolean exists = workspaceRoot.exists(destinationPath); if (isFolder && exists) { // the resource is a folder and it exists in the destination, copy the // children of the folder IResource[] children = ((IContainer) source).members(); copy(children, destinationPath, subMonitor); // need to explicitly delete the folder since we're not moving it delete(source, subMonitor); } else { // if we're merging folders, we could be overwriting an existing file IResource existing = workspaceRoot.findMember(destinationPath); if (existing != null) { delete(existing, subMonitor); } source.move(destinationPath, IResource.KEEP_HISTORY, new SubProgressMonitor(subMonitor, 0)); subMonitor.worked(1); if (subMonitor.isCanceled()) { throw new OperationCanceledException(); } } } } | 57470 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/57470/d30b2de66af61ce08c4f3d70227efd12da67d153/MoveFilesAndFoldersOperation.java/clean/bundles/org.eclipse.ui/Eclipse UI/org/eclipse/ui/actions/MoveFilesAndFoldersOperation.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1117,
918,
1610,
12,
45,
1420,
8526,
2703,
16,
467,
743,
2929,
16,
467,
5491,
7187,
720,
7187,
13,
1216,
30015,
288,
202,
202,
1884,
261,
474,
277,
273,
374,
31,
277,
411,
2703,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1117,
918,
1610,
12,
45,
1420,
8526,
2703,
16,
467,
743,
2929,
16,
467,
5491,
7187,
720,
7187,
13,
1216,
30015,
288,
202,
202,
1884,
261,
474,
277,
273,
374,
31,
277,
411,
2703,
... |
if (!isMarkerType(marker, IMarker.TASK)) return ""; | if (!isMarkerType(marker, IMarker.TASK)) { return ""; } | public static String getPriorityText(IMarker marker) { if (!isMarkerType(marker, IMarker.TASK)) return ""; //$NON-NLS-1$ switch (getPriority(marker)) { case IMarker.PRIORITY_HIGH: return TaskListMessages.TaskList_high; case IMarker.PRIORITY_NORMAL: return TaskListMessages.TaskList_normal; case IMarker.PRIORITY_LOW: return TaskListMessages.TaskList_low; } return ""; //$NON-NLS-1$ } | 58148 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/58148/e38d295ea613cf9f08aadb93a84a33d2e91abc5f/MarkerUtil.java/buggy/bundles/org.eclipse.ui.ide/src/org/eclipse/ui/views/tasklist/MarkerUtil.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
760,
514,
25332,
1528,
12,
3445,
1313,
264,
5373,
13,
288,
3639,
309,
16051,
291,
7078,
559,
12,
11145,
16,
467,
7078,
18,
15580,
3719,
5411,
327,
1408,
31,
4329,
3993,
17,
5106,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
760,
514,
25332,
1528,
12,
3445,
1313,
264,
5373,
13,
288,
3639,
309,
16051,
291,
7078,
559,
12,
11145,
16,
467,
7078,
18,
15580,
3719,
5411,
327,
1408,
31,
4329,
3993,
17,
5106,
... |
if((!prbWasNonNull) && prb != null) { | if((!prbWasNonNull) && (prb != null)) { | public synchronized boolean waitUntilStatusChange() { while(true) { if((!hadROLastTimeWaited) && hasForwardedRejectedOverload) { hadROLastTimeWaited = true; return true; } if((!prbWasNonNull) && prb != null) { prbWasNonNull = true; return false; } if(status != NOT_FINISHED) return false; try { wait(10000); } catch (InterruptedException e) { // Ignore } } } | 50915 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50915/ca136843ae9ecb30cadada58a33a5dc2cf8ad064/RequestSender.java/buggy/src/freenet/node/RequestSender.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
3852,
1250,
2529,
9716,
1482,
3043,
1435,
288,
3639,
1323,
12,
3767,
13,
288,
540,
202,
430,
12443,
5,
76,
361,
1457,
3024,
950,
5480,
329,
13,
597,
711,
22915,
19902,
4851,
945,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
3852,
1250,
2529,
9716,
1482,
3043,
1435,
288,
3639,
1323,
12,
3767,
13,
288,
540,
202,
430,
12443,
5,
76,
361,
1457,
3024,
950,
5480,
329,
13,
597,
711,
22915,
19902,
4851,
945,
... |
synchronized (username.intern()) { session = anonymousSessions.get(resource); if (session == null){ session = getSession(recipient); } | session = anonymousSessions.get(resource); if (session == null){ session = getSession(recipient); | public Session getBestRoute(JID recipient) { Session session = null; String resource = recipient.getResource(); String username = recipient.getNode(); if (username == null || "".equals(username)) { if (resource != null) { synchronized (username.intern()) { session = anonymousSessions.get(resource); if (session == null){ session = getSession(recipient); } } } } else { username = username.toLowerCase(); synchronized (username.intern()) { SessionMap sessionMap = sessions.get(username); if (sessionMap != null) { if (resource == null) { session = sessionMap.getDefaultSession(); } else { session = sessionMap.getSession(resource); if (session == null) { session = sessionMap.getDefaultSession(); } } } } } return session; } | 6312 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/6312/ead024c0fb571a575256e5837b6d95f127f061a2/SessionManager.java/clean/src/java/org/jivesoftware/messenger/SessionManager.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
3877,
28782,
3255,
12,
46,
734,
8027,
13,
288,
3639,
3877,
1339,
273,
446,
31,
3639,
514,
1058,
273,
8027,
18,
588,
1420,
5621,
3639,
514,
2718,
273,
8027,
18,
588,
907,
5621,
363... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
3877,
28782,
3255,
12,
46,
734,
8027,
13,
288,
3639,
3877,
1339,
273,
446,
31,
3639,
514,
1058,
273,
8027,
18,
588,
1420,
5621,
3639,
514,
2718,
273,
8027,
18,
588,
907,
5621,
363... |
if (length > 0) { char first = name.charAt(0); if( (! Character.isLetter(first) ) && (first != '_')){ | char c; if (length == 0) { return false; } c = name.charAt(0); if ((!Character.isLetter(c)) && (c != '_')) { return false; } for (int i = 1; i < length; ++i) { c = name.charAt(i); if ((!Character.isLetterOrDigit(c)) && (c != '_')) { | private static boolean isLegalIdentifier(String name) { if (name == null) { return false; } String trimmed = name.trim(); if ((!name.equals(trimmed)) || (name.indexOf(" ") != -1) ){ //$NON-NLS-1$ return false; } int length = name.length(); if (length > 0) { char first = name.charAt(0); if( (! Character.isLetter(first) ) && (first != '_')){ return false; } for (int i = 1; i < length; i++) { char c = name.charAt(i); if((! Character.isLetterOrDigit(c)) && (c != '_') ){ return false; } } } return true; } | 54911 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54911/3c4355b78d850284f3995401d54b190f81afb344/CConventions.java/buggy/core/org.eclipse.cdt.core/src/org/eclipse/cdt/core/CConventions.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
760,
1250,
353,
30697,
3004,
12,
780,
508,
13,
288,
202,
202,
430,
261,
529,
422,
446,
13,
288,
1082,
202,
2463,
629,
31,
202,
202,
97,
202,
202,
780,
12350,
273,
508,
18,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
760,
1250,
353,
30697,
3004,
12,
780,
508,
13,
288,
202,
202,
430,
261,
529,
422,
446,
13,
288,
1082,
202,
2463,
629,
31,
202,
202,
97,
202,
202,
780,
12350,
273,
508,
18,
... |
public boolean saveRepositories(String destinationPath) { if (!Platform.isRunning()) {// || TasksUiPlugin.getDefault() == null) { return false; } Set<TaskRepository> repositoriesToWrite = new HashSet<TaskRepository>(getAllRepositories()); // if for some reason a repository is added/changed to equal one in the // orphaned set the orphan is discarded for (TaskRepository repository : orphanedRepositories) { if (!repositoriesToWrite.contains(repository)) { repositoriesToWrite.add(repository); } } try {// String dataDirectory = TasksUiPlugin.getDefault().getDataDirectory();// File repositoriesFile = new File(dataDirectory + File.separator + TasksUiPlugin.DEFAULT_REPOSITORIES_FILE); File repositoriesFile = new File(destinationPath); externalizer.writeRepositoriesToXML(repositoriesToWrite, repositoriesFile); } catch (Throwable t) { MylarStatusHandler.fail(t, "could not save repositories", false); return false; } return true; } | 51989 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/51989/dc841c630afff6eea9fa48a58143d396d272fead/TaskRepositoryManager.java/buggy/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/tasks/core/TaskRepositoryManager.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
1250,
1923,
18429,
12,
780,
30617,
13,
288,
202,
202,
430,
16051,
8201,
18,
291,
7051,
10756,
288,
759,
747,
20350,
13943,
3773,
18,
588,
1868,
1435,
422,
446,
13,
288,
1082,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
1250,
1923,
18429,
12,
780,
30617,
13,
288,
202,
202,
430,
16051,
8201,
18,
291,
7051,
10756,
288,
759,
747,
20350,
13943,
3773,
18,
588,
1868,
1435,
422,
446,
13,
288,
1082,
... | ||
if(store) node.storeConfig(); | if(store && started) node.storeConfig(); | public void removeBookmark(Bookmark b, boolean store) { if (b.getKeyType().equals("USK")) { try { USK u = USK.create(b.key); this.node.uskManager.unsubscribe(u, this.uskcb, true); } catch (MalformedURLException mue) { } } this.bookmarks.remove(b); if(store) node.storeConfig(); } | 52909 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52909/8876d374f5982da70be8e0cbff4c65d9f2ff1278/BookmarkManager.java/buggy/src/freenet/clients/http/BookmarkManager.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
1206,
22966,
12,
22966,
324,
16,
1250,
1707,
13,
288,
202,
202,
430,
261,
70,
18,
588,
22100,
7675,
14963,
2932,
3378,
47,
6,
3719,
288,
1082,
202,
698,
288,
9506,
202,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
1206,
22966,
12,
22966,
324,
16,
1250,
1707,
13,
288,
202,
202,
430,
261,
70,
18,
588,
22100,
7675,
14963,
2932,
3378,
47,
6,
3719,
288,
1082,
202,
698,
288,
9506,
202,
... |
{ | { prepareForUIUninstall(); | public void uninstallUI(JComponent c) { uninstallDefaults(); uninstallKeyboardActions(); uninstallListeners(); tree = null; completeUIUninstall(); } | 50763 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50763/3826e72d9ebe31a854c4d01d6c8f1ec65a8d80fe/BasicTreeUI.java/clean/core/src/classpath/javax/javax/swing/plaf/basic/BasicTreeUI.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
16577,
5370,
12,
46,
1841,
276,
13,
202,
95,
2911,
1290,
5370,
31103,
5621,
565,
16577,
7019,
5621,
202,
202,
28872,
17872,
6100,
5621,
202,
202,
28872,
5583,
5621,
202,
20... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
16577,
5370,
12,
46,
1841,
276,
13,
202,
95,
2911,
1290,
5370,
31103,
5621,
565,
16577,
7019,
5621,
202,
202,
28872,
17872,
6100,
5621,
202,
202,
28872,
5583,
5621,
202,
20... |
return arrayType; | return this.arrayType; | public ArrayType getType() { if (arrayType == null) { preLazyInit(); this.arrayType = this.ast.newArrayType( this.ast.newPrimitiveType(PrimitiveType.INT)); postLazyInit(this.arrayType, TYPE_PROPERTY); } return arrayType; } | 10698 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/10698/f4baff4257d9b6f1bb97486c41210e6bbf680256/ArrayCreation.java/clean/org.eclipse.jdt.core/dom/org/eclipse/jdt/core/dom/ArrayCreation.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
29935,
3130,
1435,
288,
202,
202,
430,
261,
1126,
559,
422,
446,
13,
288,
1082,
202,
1484,
14443,
2570,
5621,
1082,
202,
2211,
18,
1126,
559,
273,
333,
18,
689,
18,
2704,
2718... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
29935,
3130,
1435,
288,
202,
202,
430,
261,
1126,
559,
422,
446,
13,
288,
1082,
202,
1484,
14443,
2570,
5621,
1082,
202,
2211,
18,
1126,
559,
273,
333,
18,
689,
18,
2704,
2718... |
PostProcessUtil.findLocations(os, Chromosome.class, Gene.class); | PostProcessUtil.findLocationAndObjects(os, Chromosome.class, Gene.class, false); | public void createIntergenicRegionFeatures() throws ObjectStoreException { Results results = PostProcessUtil.findLocations(os, Chromosome.class, Gene.class); results.setBatchSize(500); dataSet = (DataSet) DynamicUtil.createObject(Collections.singleton(DataSet.class)); dataSet.setTitle("FlyMine intergenic regions"); dataSet.setDescription("Intergenic regions created by FlyMine"); dataSet.setVersion("" + new Date()); // current time and date dataSet.setUrl("http://www.flymine.org"); dataSet.setDataSource(dataSource); Iterator resIter = results.iterator(); Integer previousChrId = null; Set locationSet = new HashSet(); while (resIter.hasNext()) { ResultsRow rr = (ResultsRow) resIter.next(); Integer chrId = (Integer) rr.get(0); Location loc = (Location) rr.get(1); if (previousChrId != null && !chrId.equals(previousChrId)) { Iterator irIter = createIntergenicRegionFeatures(locationSet, previousChrId); storeItergenicRegions(osw, irIter); locationSet = new HashSet(); } locationSet.add(loc); previousChrId = chrId; } if (previousChrId != null) { Iterator irIter = createIntergenicRegionFeatures(locationSet, previousChrId); storeItergenicRegions(osw, irIter); // we've created some IntergenicRegion objects so store() the DataSet osw.store(dataSet); } } | 7196 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/7196/0deea374f54d7613d8da940b1ad34da82ec540c1/IntergenicRegionUtil.java/clean/flymine/model/genomic/src/java/org/flymine/postprocess/IntergenicRegionUtil.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
752,
2465,
4507,
335,
5165,
8696,
1435,
1216,
1033,
21151,
288,
3639,
10351,
1686,
273,
5411,
5616,
2227,
1304,
18,
4720,
2735,
1876,
4710,
12,
538,
16,
1680,
520,
16958,
18,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
752,
2465,
4507,
335,
5165,
8696,
1435,
1216,
1033,
21151,
288,
3639,
10351,
1686,
273,
5411,
5616,
2227,
1304,
18,
4720,
2735,
1876,
4710,
12,
538,
16,
1680,
520,
16958,
18,
1... |
while (fields.hasNext()) { Field field = (Field) fields.next(); genOverrideHasMethod(field); } } | while (fields.hasNext()) { Field field = (Field) fields.next(); genOverrideHasMethod(field); } } | private void genOverrideHasMethods(Type type, Alternative alt) { Iterator fields = type.altFieldIterator(alt.getId()); while (fields.hasNext()) { Field field = (Field) fields.next(); genOverrideHasMethod(field); } } | 3664 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/3664/76875cdfe2af0d6de4ab58a245cce8bd703a86ab/AlternativeGenerator.java/clean/apigen/src/apigen/gen/java/AlternativeGenerator.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
918,
3157,
6618,
5582,
4712,
12,
559,
618,
16,
21498,
1535,
3770,
13,
288,
202,
202,
3198,
1466,
273,
618,
18,
2390,
974,
3198,
12,
2390,
18,
26321,
10663,
202,
202,
17523,
2... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
918,
3157,
6618,
5582,
4712,
12,
559,
618,
16,
21498,
1535,
3770,
13,
288,
202,
202,
3198,
1466,
273,
618,
18,
2390,
974,
3198,
12,
2390,
18,
26321,
10663,
202,
202,
17523,
2... |
System.out.println("Folder " + displayName + " closed."); | System.out.println("Store " + displayName + " closed."); | public void closed(ConnectionEvent e) { System.out.println("Folder " + displayName + " closed."); if (connected == true) { try { connectStore(); } catch (MessagingException me) { System.out.println("Disconnected from store " + displayName + " and unable to reconnect: " + me.getMessage()); } } } | 967 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/967/bfbbec2bbb7733358c92815b5dd6a247a35152fb/StoreNode.java/clean/net/suberic/pooka/gui/StoreNode.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
3196,
202,
482,
918,
4375,
12,
1952,
1133,
425,
13,
288,
1082,
565,
2332,
18,
659,
18,
8222,
2932,
3899,
315,
397,
16218,
397,
315,
4375,
1199,
1769,
1082,
565,
309,
261,
8537,
422,
638,
13,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
3196,
202,
482,
918,
4375,
12,
1952,
1133,
425,
13,
288,
1082,
565,
2332,
18,
659,
18,
8222,
2932,
3899,
315,
397,
16218,
397,
315,
4375,
1199,
1769,
1082,
565,
309,
261,
8537,
422,
638,
13,... |
jjmatchedKind = 107; | jjmatchedKind = 120; | private final int jjMoveStringLiteralDfa1_0(long active0, long active1){ try { curChar = input_stream.readChar(); } catch(java.io.IOException e) { jjStopStringLiteralDfa_0(0, active0, active1); return 1; } switch(curChar) { case 38: if ((active1 & 0x80000000L) != 0L) return jjStopAtPos(1, 95); break; case 42: if ((active0 & 0x100L) != 0L) return jjStartNfaWithStates_0(1, 8, 54); break; case 43: if ((active1 & 0x100000000L) != 0L) return jjStopAtPos(1, 96); break; case 45: if ((active1 & 0x200000000L) != 0L) return jjStopAtPos(1, 97); break; case 46: return jjMoveStringLiteralDfa2_0(active0, 0L, active1, 0x100000000000000L); case 60: if ((active1 & 0x40000000000L) != 0L) { jjmatchedKind = 106; jjmatchedPos = 1; } return jjMoveStringLiteralDfa2_0(active0, 0L, active1, 0x20000000000000L); case 61: if ((active1 & 0x4000000L) != 0L) return jjStopAtPos(1, 90); else if ((active1 & 0x8000000L) != 0L) return jjStopAtPos(1, 91); else if ((active1 & 0x10000000L) != 0L) return jjStopAtPos(1, 92); else if ((active1 & 0x20000000L) != 0L) return jjStopAtPos(1, 93); else if ((active1 & 0x200000000000L) != 0L) return jjStopAtPos(1, 109); else if ((active1 & 0x400000000000L) != 0L) return jjStopAtPos(1, 110); else if ((active1 & 0x800000000000L) != 0L) return jjStopAtPos(1, 111); else if ((active1 & 0x1000000000000L) != 0L) return jjStopAtPos(1, 112); else if ((active1 & 0x2000000000000L) != 0L) return jjStopAtPos(1, 113); else if ((active1 & 0x4000000000000L) != 0L) return jjStopAtPos(1, 114); else if ((active1 & 0x8000000000000L) != 0L) return jjStopAtPos(1, 115); else if ((active1 & 0x10000000000000L) != 0L) return jjStopAtPos(1, 116); break; case 62: if ((active1 & 0x80000000000L) != 0L) { jjmatchedKind = 107; jjmatchedPos = 1; } return jjMoveStringLiteralDfa2_0(active0, 0L, active1, 0xc0100000000000L); case 91: return jjMoveStringLiteralDfa2_0(active0, 0L, active1, 0x400000000000000L); case 97: return jjMoveStringLiteralDfa2_0(active0, 0x90008030000L, active1, 0L); case 98: return jjMoveStringLiteralDfa2_0(active0, 0x1000L, active1, 0L); case 101: return jjMoveStringLiteralDfa2_0(active0, 0x820000400000L, active1, 0L); case 102: if ((active0 & 0x200000000L) != 0L) return jjStartNfaWithStates_0(1, 33, 28); break; case 104: return jjMoveStringLiteralDfa2_0(active0, 0x20e1000000040000L, active1, 0L); case 105: return jjMoveStringLiteralDfa2_0(active0, 0x30000000L, active1, 0L); case 108: return jjMoveStringLiteralDfa2_0(active0, 0x42080000L, active1, 0L); case 109: return jjMoveStringLiteralDfa2_0(active0, 0xc00000000L, active1, 0L); case 110: return jjMoveStringLiteralDfa2_0(active0, 0x7000000000L, active1, 0L); case 111: if ((active0 & 0x800000L) != 0L) { jjmatchedKind = 23; jjmatchedPos = 1; } return jjMoveStringLiteralDfa2_0(active0, 0x1800008181302000L, active1, 0L); case 114: return jjMoveStringLiteralDfa2_0(active0, 0x700300000004000L, active1, 0L); case 116: return jjMoveStringLiteralDfa2_0(active0, 0x4002000000000000L, active1, 0L); case 117: return jjMoveStringLiteralDfa2_0(active0, 0x4440000000000L, active1, 0L); case 119: return jjMoveStringLiteralDfa2_0(active0, 0x8000000000000L, active1, 0L); case 120: return jjMoveStringLiteralDfa2_0(active0, 0x4000000L, active1, 0L); case 121: return jjMoveStringLiteralDfa2_0(active0, 0x10000000008000L, active1, 0L); case 124: if ((active1 & 0x40000000L) != 0L) return jjStopAtPos(1, 94); break; default : break; } return jjStartNfa_0(0, active0, active1);} | 41673 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/41673/1d8de6b34ea0ddb64fc94b478c0950c0d35de605/JavaParserTokenManager.java/buggy/pmd/src/net/sourceforge/pmd/ast/JavaParserTokenManager.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
3238,
727,
509,
10684,
7607,
28565,
40,
507,
21,
67,
20,
12,
5748,
2695,
20,
16,
1525,
2695,
21,
15329,
282,
775,
288,
662,
2156,
273,
810,
67,
3256,
18,
896,
2156,
5621,
289,
282,
1044,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
3238,
727,
509,
10684,
7607,
28565,
40,
507,
21,
67,
20,
12,
5748,
2695,
20,
16,
1525,
2695,
21,
15329,
282,
775,
288,
662,
2156,
273,
810,
67,
3256,
18,
896,
2156,
5621,
289,
282,
1044,
1... |
if (ChainBuilderAgent.DEBUG) | if (ChainBuilderAgent.DEBUG > 3 ) | public void mouseClicked(PInputEvent e) { if (timer.isRunning()) { if (ChainBuilderAgent.DEBUG) System.err.println("mouse double click"); // this is effectively a double click. timer.stop(); if (wasDoubleClick == true) wasDoubleClick = false; else doMouseDoubleClicked(e); } else { timer.restart(); if (ChainBuilderAgent.DEBUG) System.err.println("caching click event .."+e); cachedEvent = e; } } | 13273 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/13273/630a53d68f5d29c53d2485557b18599785befb83/ChainCreationEventHandler.java/clean/SRC/org/openmicroscopy/shoola/agents/chainbuilder/piccolo/ChainCreationEventHandler.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
7644,
27633,
12,
52,
1210,
1133,
425,
13,
288,
202,
202,
430,
261,
12542,
18,
291,
7051,
10756,
288,
1082,
202,
430,
261,
3893,
1263,
3630,
18,
9394,
13,
9506,
202,
3163,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
7644,
27633,
12,
52,
1210,
1133,
425,
13,
288,
202,
202,
430,
261,
12542,
18,
291,
7051,
10756,
288,
1082,
202,
430,
261,
3893,
1263,
3630,
18,
9394,
13,
9506,
202,
3163,... |
if ("toString".equals(method.getName())) { | if ("toString".equals(method.getName()) && (method.getParameterTypes()).length == 0) { | public Object invoke(Object proxy, Method method, Object[] args) throws Throwable { System.out.println("--[java]ProxyHandler.invoke "+method); if ("toString".equals(method.getName())) { return "ProxyObject@{oid = "+oid+" iid = "+iid+"}"; } return Utilities.callMethod(oid, method, iid, orb, args); } | 12376 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/12376/76df12a89570e7cdb108527228768943896e4f15/ProxyHandler.java/buggy/java/xpcom/java/classes/org/mozilla/xpcom/ProxyHandler.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
1033,
4356,
12,
921,
2889,
16,
9506,
2985,
707,
16,
9506,
1033,
8526,
833,
13,
1216,
4206,
288,
3639,
2332,
18,
659,
18,
8222,
2932,
413,
63,
6290,
65,
3886,
1503,
18,
14407,
1377... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
1033,
4356,
12,
921,
2889,
16,
9506,
2985,
707,
16,
9506,
1033,
8526,
833,
13,
1216,
4206,
288,
3639,
2332,
18,
659,
18,
8222,
2932,
413,
63,
6290,
65,
3886,
1503,
18,
14407,
1377... |
log.debug("Could not find resource: " + uri); | in = getClass().getClassLoader().getResourceAsStream(uri); if (in == null) { log.debug("Could not find resource: " + uri); } | protected InputStream loadResource(String uri) { if (System.getProperty("xbean.dir") != null) { File f = new File(System.getProperty("xbean.dir") + uri); try { return new FileInputStream(f); } catch (FileNotFoundException e) { // Ignore } } // lets try the thread context class loader first InputStream in = Thread.currentThread().getContextClassLoader().getResourceAsStream(uri); if (in == null) { in = getClass().getClassLoader().getResourceAsStream(uri); if (in == null) { log.debug("Could not find resource: " + uri); } } return in; } | 52533 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52533/c60ad9116626de2c6d3638075063ca9ed4876ccd/XBeanNamespaceHandler.java/buggy/xbean-spring-v2b/src/main/java/org/apache/xbean/spring/context/v2b/XBeanNamespaceHandler.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
4750,
5037,
1262,
1420,
12,
780,
2003,
13,
288,
3639,
309,
261,
3163,
18,
588,
1396,
2932,
92,
14496,
18,
1214,
7923,
480,
446,
13,
288,
5411,
1387,
284,
273,
394,
1387,
12,
3163,
18,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
4750,
5037,
1262,
1420,
12,
780,
2003,
13,
288,
3639,
309,
261,
3163,
18,
588,
1396,
2932,
92,
14496,
18,
1214,
7923,
480,
446,
13,
288,
5411,
1387,
284,
273,
394,
1387,
12,
3163,
18,
... |
Set<ITaskListElement> allRoots = manager.getTaskList().getRootElements(); System.err.println(">>> " + allRootTasks.size()); | Set<ITaskListElement> allRoots = manager.getTaskList().getRootElements(); | public void testLegacyTaskListReading() { File originalFile = manager.getTaskListFile(); File legacyListFile = TaskTestUtil.getLocalFile("testdata/legacy/tasklist_0_4_8.xml"); assertEquals(362445, legacyListFile.length()); assertTrue(legacyListFile.exists()); manager.setTaskListFile(legacyListFile); manager.readExistingOrCreateNewList(); manager.setTaskListFile(originalFile); Set<ITask> allTasks = manager.getTaskList().getAllTasks(); Set<ITask> allRootTasks = manager.getTaskList().getRootTasks(); Set<ITaskContainer> allCategories = manager.getTaskList().getCategories(); Set<ITaskListElement> allRoots = manager.getTaskList().getRootElements(); System.err.println(">>> " + allRootTasks.size()); assertEquals(0, allRootTasks.size()); manager.saveTaskList(); TaskList list = new TaskList(); manager.setTaskList(list); manager.readExistingOrCreateNewList(); assertEquals(allTasks, manager.getTaskList().getAllTasks()); assertEquals(allRootTasks.size(), manager.getTaskList().getRootTasks().size()); assertEquals(allCategories, manager.getTaskList().getCategories()); assertEquals(allRoots.size(), manager.getTaskList().getRootElements().size()); // rewrite and test again// manager.saveTaskList();// list = new TaskList();// manager.setTaskList(list);// manager.readExistingOrCreateNewList();// // assertEquals(allTasks, manager.getTaskList().getAllTasks());// assertEquals(allRootTasks, manager.getTaskList().getRootTasks());// assertEquals(allCategories, manager.getTaskList().getCategories());// assertEquals(allRoots.size(), manager.getTaskList().getRootElements().size()); } | 51989 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/51989/0b536a7add7019ec8ed51a919751d4ed2de9fa43/TaskListManagerTest.java/clean/org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasklist/tests/TaskListManagerTest.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
1842,
12235,
2174,
682,
15714,
1435,
288,
202,
202,
812,
2282,
812,
273,
3301,
18,
588,
2174,
682,
812,
5621,
202,
202,
812,
8866,
682,
812,
273,
3837,
4709,
1304,
18,
58... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
1842,
12235,
2174,
682,
15714,
1435,
288,
202,
202,
812,
2282,
812,
273,
3301,
18,
588,
2174,
682,
812,
5621,
202,
202,
812,
8866,
682,
812,
273,
3837,
4709,
1304,
18,
58... |
protected static final char[] encodeTypeEntry( char[] typeName, int classType) { int pos; //3 - 1 for SUFFIX letter, 2 Separators char[] result = new char[TYPE_DECL_LENGTH + typeName.length + 3]; System.arraycopy(TYPE_DECL, 0, result, 0, pos = TYPE_DECL_LENGTH); switch (classType) { case(CLASS): result[pos++] = CLASS_SUFFIX; break; case(STRUCT): result[pos++] = STRUCT_SUFFIX; break; case(UNION): result[pos++] = UNION_SUFFIX; break; } result[pos++] = SEPARATOR; System.arraycopy(typeName, 0, result, pos, typeName.length); pos += typeName.length; result[pos++] = SEPARATOR; return result; } | 6192 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/6192/bcf023a6c80bfaf770bd00081f423c21f3e149f8/AbstractIndexer.java/buggy/core/org.eclipse.cdt.core/index/org/eclipse/cdt/internal/core/search/indexing/AbstractIndexer.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1117,
3845,
6385,
3001,
8526,
3015,
559,
1622,
12,
3001,
8526,
723,
461,
16,
474,
1106,
559,
15329,
9506,
202,
474,
917,
31,
202,
202,
759,
23,
17,
21,
1884,
14964,
13449,
16,
22,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1117,
3845,
6385,
3001,
8526,
3015,
559,
1622,
12,
3001,
8526,
723,
461,
16,
474,
1106,
559,
15329,
9506,
202,
474,
917,
31,
202,
202,
759,
23,
17,
21,
1884,
14964,
13449,
16,
22,
... | ||
if (types == null) { | if (types == null || types.length == 0) { | public void setExceptionTypes(CtClass[] types) throws NotFoundException { declaringClass.checkModify(); if (types == null) { methodInfo.removeExceptionsAttribute(); return; } String[] names = new String[types.length]; for (int i = 0; i < types.length; ++i) names[i] = types[i].getName(); ExceptionsAttribute ea = methodInfo.getExceptionsAttribute(); if (ea == null) { ea = new ExceptionsAttribute(methodInfo.getConstPool()); methodInfo.setExceptionsAttribute(ea); } ea.setExceptions(names); } | 56357 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/56357/7b2f9feef79052893b40168b2b9c6d413971346b/CtBehavior.java/buggy/src/main/javassist/CtBehavior.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
29680,
2016,
12,
39,
88,
797,
8526,
1953,
13,
1216,
12323,
288,
3639,
3496,
14682,
18,
1893,
11047,
5621,
3639,
309,
261,
2352,
422,
446,
747,
1953,
18,
2469,
422,
374,
13,
2... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
29680,
2016,
12,
39,
88,
797,
8526,
1953,
13,
1216,
12323,
288,
3639,
3496,
14682,
18,
1893,
11047,
5621,
3639,
309,
261,
2352,
422,
446,
747,
1953,
18,
2469,
422,
374,
13,
2... |
throw new DomLSEx(LSException.PARSE_ERR, e); | throw new DomLSException(LSException.PARSE_ERR, e); | private XMLReader getXMLReader() throws LSException { if (reader == null) { factory.setNamespaceAware(namespaceAware); factory.setValidating(validating); factory.setXIncludeAware(xIncludeAware); try { SAXParser parser = factory.newSAXParser(); reader = parser.getXMLReader(); } catch (ParserConfigurationException e) { throw new DomLSEx(LSException.PARSE_ERR, e); } catch (SAXException e) { throw new DomLSEx(LSException.PARSE_ERR, e); } } return reader; } | 50763 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50763/bdd0bca7f46f1e8a19b790749e32f82de6de3685/DomLSParser.java/buggy/core/src/classpath/gnu/gnu/xml/dom/ls/DomLSParser.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
3238,
3167,
2514,
336,
4201,
2514,
1435,
565,
1216,
29204,
503,
225,
288,
565,
309,
261,
10530,
422,
446,
13,
1377,
288,
3639,
3272,
18,
542,
3402,
10155,
12,
4937,
10155,
1769,
3639,
327... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
3238,
3167,
2514,
336,
4201,
2514,
1435,
565,
1216,
29204,
503,
225,
288,
565,
309,
261,
10530,
422,
446,
13,
1377,
288,
3639,
3272,
18,
542,
3402,
10155,
12,
4937,
10155,
1769,
3639,
327... |
IDataServiceProvider idsp = ( (ChartWizardContext) super.getContext( ) ).getDataServiceProvider( ); | IDataServiceProvider idsp = getContext( ).getDataServiceProvider( ); | private void populateLists( ) { // POPULATE STYLE COMBO WITH AVAILABLE REPORT STYLES IDataServiceProvider idsp = ( (ChartWizardContext) super.getContext( ) ).getDataServiceProvider( ); if ( idsp != null ) { String[] styles = idsp.getAllStyles( ); // Add None option to remove style String[] selection = new String[styles.length + 1]; System.arraycopy( styles, 0, selection, 1, styles.length ); selection[0] = Messages.getString( "ChartSheetImpl.Label.None" ); //$NON-NLS-1$ cmbStyle.setItems( selection ); String sStyle = idsp.getCurrentStyle( ); cmbStyle.setText( ( sStyle == null ) ? selection[0] : sStyle ); NameSet nameSet = LiteralHelper.legendBehaviorTypeSet; cmbInteractivity.setItems( nameSet.getDisplayNames( ) ); cmbInteractivity.select( nameSet.getSafeNameIndex( getChart( ).getInteractivity( ) .getLegendBehavior( ) .getName( ) ) ); } } | 5230 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5230/ac26365eb54b9a10e69498a213cb6f605f15760b/ChartSheetImpl.java/clean/chart/org.eclipse.birt.chart.ui.extension/src/org/eclipse/birt/chart/ui/swt/wizard/format/chart/ChartSheetImpl.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
918,
6490,
7432,
12,
262,
202,
95,
202,
202,
759,
26839,
1506,
1777,
27449,
5423,
5315,
13601,
15068,
20027,
27711,
2347,
61,
11386,
202,
202,
734,
396,
16300,
612,
1752,
273,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
918,
6490,
7432,
12,
262,
202,
95,
202,
202,
759,
26839,
1506,
1777,
27449,
5423,
5315,
13601,
15068,
20027,
27711,
2347,
61,
11386,
202,
202,
734,
396,
16300,
612,
1752,
273,
... |
public IRubyObject execute(IRubyObject self, IRubyObject[] args) { IRubyObject source = args[1]; IRubyObject filename = args[2]; // FIXME: lineNumber is not supported //IRubyObject lineNumber = args[3]; return args[0].evalSimple(source.getRuntime().getCurrentContext(), source, ((RubyString) filename).toString()); } | 45827 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/45827/c8b66db475de1dc66f347884891dd70d9943689b/RubyObject.java/buggy/src/org/jruby/RubyObject.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
2398,
1071,
15908,
10340,
921,
1836,
12,
7937,
10340,
921,
365,
16,
15908,
10340,
921,
8526,
833,
13,
288,
7734,
15908,
10340,
921,
1084,
273,
833,
63,
21,
15533,
7734,
15908,
10340,
921,
1544,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
2398,
1071,
15908,
10340,
921,
1836,
12,
7937,
10340,
921,
365,
16,
15908,
10340,
921,
8526,
833,
13,
288,
7734,
15908,
10340,
921,
1084,
273,
833,
63,
21,
15533,
7734,
15908,
10340,
921,
1544,
... | ||
System.out.println("int (*func[15])()"); parser.parse("int (*func[15])()"); | System.out.println("int (*func[15])()"); parser.parse("int (*func[15])()"); | public static void main(String[] args) { GDBTypeParser parser = new GDBTypeParser(); System.out.println("struct link { int i; int j; struct link * next} *"); parser.parse("struct link { int i; int j; struct link * next} *"); System.out.println(parser.getGDBType().verbose()); System.out.println("char **argv"); parser.parse("unsigned long long int **argv"); System.out.println(parser.getGDBType().verbose()); System.out.println("int (*daytab)[13]"); parser.parse("int (*daytab)[13]"); System.out.println(parser.getGDBType().verbose()); System.out.println("int *daytab[13]"); parser.parse("int *daytab[13]"); System.out.println(parser.getGDBType().verbose()); System.out.println("void *comp()"); parser.parse("void *comp()"); System.out.println(parser.getGDBType().verbose()); System.out.println("void (*comp)()"); parser.parse("void (*comp)()"); System.out.println(parser.getGDBType().verbose()); System.out.println("int (*func[15])()"); parser.parse("int (*func[15])()"); System.out.println(parser.getGDBType().verbose()); System.out.println("char (*(*x())[])()"); parser.parse("char (*(*x())[])()"); System.out.println(parser.getGDBType().verbose()); System.out.println("char (*(*x[3])())[5]"); parser.parse("char (*(*x[3])())[5]"); System.out.println(parser.getGDBType().verbose()); } | 54911 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54911/f3a9fae6384fd8bb36474b1661bb6d0b65b38d5f/GDBTypeParser.java/buggy/debug/org.eclipse.cdt.debug.mi.core/src/org/eclipse/cdt/debug/mi/core/GDBTypeParser.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
760,
918,
2774,
12,
780,
8526,
833,
13,
288,
202,
202,
43,
2290,
559,
2678,
2082,
273,
394,
611,
2290,
559,
2678,
5621,
202,
202,
3163,
18,
659,
18,
8222,
2932,
1697,
1692,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
760,
918,
2774,
12,
780,
8526,
833,
13,
288,
202,
202,
43,
2290,
559,
2678,
2082,
273,
394,
611,
2290,
559,
2678,
5621,
202,
202,
3163,
18,
659,
18,
8222,
2932,
1697,
1692,
... |
setImageDescriptor(TasklistImages.TASK_INCOMPLETE); | setImageDescriptor(TaskListImages.TASK_INCOMPLETE); | public MarkTaskIncompleteAction(TaskListView view) { this.view = view; setText("Mark Incomplete"); setToolTipText("Mark Incomplete"); setId(ID); setImageDescriptor(TasklistImages.TASK_INCOMPLETE); } | 51989 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/51989/7434c54adb9b67993df3b0ee032cca0eaf5003f3/MarkTaskIncompleteAction.java/buggy/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasklist/ui/actions/MarkTaskIncompleteAction.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
6622,
2174,
27531,
1803,
12,
2174,
682,
1767,
1476,
13,
288,
202,
202,
2211,
18,
1945,
273,
1476,
31,
202,
202,
542,
1528,
2932,
3882,
657,
6226,
8863,
3639,
444,
29250,
1528,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
6622,
2174,
27531,
1803,
12,
2174,
682,
1767,
1476,
13,
288,
202,
202,
2211,
18,
1945,
273,
1476,
31,
202,
202,
542,
1528,
2932,
3882,
657,
6226,
8863,
3639,
444,
29250,
1528,
... |
public static void processSource(Context cx, String filename) { | public static void processSource(Context cx, String filename) { | public static void processSource(Context cx, String filename) { if (filename == null || filename.equals("-")) { if (filename == null) { // print implementation version getOut().println(cx.getImplementationVersion()); } // Use the interpreter for interactive input cx.setOptimizationLevel(-1); BufferedReader in = new BufferedReader (new InputStreamReader(global.getIn())); int lineno = 1; boolean hitEOF = false; while (!hitEOF) { int startline = lineno; if (filename == null) global.getErr().print("js> "); global.getErr().flush(); String source = ""; // Collect lines of source to compile. while (true) { String newline; try { newline = in.readLine(); } catch (IOException ioe) { global.getErr().println(ioe.toString()); break; } if (newline == null) { hitEOF = true; break; } source = source + newline + "\n"; lineno++; if (cx.stringIsCompilableUnit(source)) break; } Object result = evaluateScript(cx, global, null, source, "<stdin>", startline, null); if (result != cx.getUndefinedValue()) { try { global.getErr().println(cx.toString(result)); } catch (RhinoException rex) { errorReporter.reportException(rex); } } NativeArray h = global.history; h.put((int)h.getLength(), h, source); } global.getErr().println(); } else processFile(cx, global, filename); System.gc(); } | 19042 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/19042/fe1695149a5be9f5989e68d9eea04d2a3e60152f/Main.java/buggy/toolsrc/org/mozilla/javascript/tools/shell/Main.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
760,
918,
1207,
1830,
12,
1042,
9494,
16,
514,
1544,
13,
288,
3639,
309,
261,
3459,
422,
446,
747,
1544,
18,
14963,
2932,
10951,
3719,
288,
5411,
309,
261,
3459,
422,
446,
13,
288... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
760,
918,
1207,
1830,
12,
1042,
9494,
16,
514,
1544,
13,
288,
3639,
309,
261,
3459,
422,
446,
747,
1544,
18,
14963,
2932,
10951,
3719,
288,
5411,
309,
261,
3459,
422,
446,
13,
288... |
final int failedIndex = validateContent(info.childCount, info.curChildren); | final int failedIndex = validateContent(info.curChildren, 0, info.childCount); | public int whatCanGoHere(boolean fullyValid, InsertableElementsInfo info) throws Exception { // // For this one, having the empty slot at the insertion point is // a problem. So lets compress the array down. We know that it has // to have at least the empty slot at the insertion point. // for (int index = info.insertAt; index < info.childCount; index++) { info.curChildren[index].setValues(info.curChildren[index+1]); } info.childCount--; // // Check the validity of the existing contents. If this is less than // the insert at point, then return failure index right now // final int failedIndex = validateContent(info.childCount, info.curChildren); if ((failedIndex != -1) && (failedIndex < info.insertAt)) return failedIndex; // Set any stuff we can know right off the bat for all cases info.canHoldPCData = false; // See how many children we can possibly report if ((fOp == XMLContentSpec.CONTENTSPECNODE_LEAF) || (fOp == XMLContentSpec.CONTENTSPECNODE_ZERO_OR_ONE) || (fOp == XMLContentSpec.CONTENTSPECNODE_ZERO_OR_MORE) || (fOp == XMLContentSpec.CONTENTSPECNODE_ONE_OR_MORE)) { info.resultsCount = 1; } else if ((fOp == XMLContentSpec.CONTENTSPECNODE_CHOICE) || (fOp == XMLContentSpec.CONTENTSPECNODE_SEQ)) { info.resultsCount = 2; } else { throw new CMException(ImplementationMessages.VAL_CST); } // // If the outgoing arrays are too small or null, create new ones. These // have to be at least the size of the results count. // if ((info.results == null) || (info.results.length < info.resultsCount)) info.results = new boolean[info.resultsCount]; if ((info.possibleChildren == null) || (info.possibleChildren.length < info.resultsCount)) { info.possibleChildren = new QName[info.resultsCount]; for (int i = 0; i < info.possibleChildren.length; i++) { info.possibleChildren[i] = new QName(); } } // // Fill in the possible children array, and set all of the associated // results entries to defaults of false. // info.possibleChildren[0].setValues(fFirstChild); info.results[0] = false; if (info.resultsCount == 2) { info.possibleChildren[1].setValues(fSecondChild); info.results[1] = false; } // // Set some defaults so that it does not have to be done redundantly // below in each case. // info.isValidEOC = false; // // Now, for each spec type, lets do the grunt work required. Each of // them is pretty simple, its just making sure of corner cases. // // We know its valid up to the insert point at least and we know that // the insert point is never past the number of children, so this releaves // a lot of checking below. // switch(fOp) { case XMLContentSpec.CONTENTSPECNODE_LEAF : case XMLContentSpec.CONTENTSPECNODE_ZERO_OR_ONE : // // If there are no current children, then insert at has to be // zero, so we can have the one leaf element inserted here. // if (info.childCount == 0) { info.results[0] = true; } else if (info.childCount > 0) { // // If the child count is greater than zero, then inserting // anything cannot be fully valid. But, if not fully valid // checking, it is ok as long as inserting at zero. // if (!fullyValid && (info.insertAt == 0)) info.results[0] = true; } if (fOp == XMLContentSpec.CONTENTSPECNODE_LEAF) { // If the insert point is 1, then EOC is valid there if (info.insertAt == 0) info.isValidEOC = true; } else { // Its zero or one, so EOC is valid in either case info.isValidEOC = true; } break; case XMLContentSpec.CONTENTSPECNODE_ZERO_OR_MORE : case XMLContentSpec.CONTENTSPECNODE_ONE_OR_MORE : // // The one child is always possible to insert, regardless of // where. The fully valid flag never comes into play since it // cannot become invalid by inserting any number of new // instances of the one element. // info.results[0] = true; // // Its zero/one or more, so EOC is valid in either case but only // after the 0th index for one or more. // if ((fOp == XMLContentSpec.CONTENTSPECNODE_ZERO_OR_MORE) || (info.insertAt > 0)) { info.isValidEOC = true; } break; case XMLContentSpec.CONTENTSPECNODE_CHOICE : // // If the insert point is zero, then either of the two children // can be inserted, unless fully valid is set and there are // already any children. // if (info.insertAt == 0) { if (!fullyValid && (info.childCount == 0)) { info.results[0] = true; info.results[1] = true; } } // EOC is only valid at the end if (info.insertAt == 1) info.isValidEOC = true; break; case XMLContentSpec.CONTENTSPECNODE_SEQ : // // If the insert at is 0, then the first one valid. Else its // the second one. // if (info.insertAt == 0) { // // If fully valid check, then if there are two children, // it cannot be valid. If there is one child, it must be // equal to the second child of the pattern since it will // get pushed up (which means it was a pattern like (x|x) // which is kinda wierd.) // if (fullyValid) { if (info.childCount == 1) info.results[0] = info.curChildren[0].uri == fSecondChild.uri && info.curChildren[0].localpart == fSecondChild.localpart; } else { info.results[0] = true; } } else if (info.insertAt == 1) { // If fully valid, then there cannot be two existing children if (!fullyValid || (info.childCount == 1)) info.results[1] = true; } // EOC is only valid at the end if (info.insertAt == 2) info.isValidEOC = true; break; default : throw new CMException(ImplementationMessages.VAL_CST); } // We survived, so return success status return -1; } | 46079 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/46079/180a21ab6be790743f1c2668b2accf759abc2e41/SimpleContentModel.java/clean/src/org/apache/xerces/validators/common/SimpleContentModel.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
509,
4121,
2568,
5741,
26715,
12,
6494,
7418,
1556,
16,
8040,
429,
3471,
966,
1123,
13,
540,
1216,
1185,
288,
3639,
368,
3639,
368,
225,
2457,
333,
1245,
16,
7999,
326,
1008,
4694,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
509,
4121,
2568,
5741,
26715,
12,
6494,
7418,
1556,
16,
8040,
429,
3471,
966,
1123,
13,
540,
1216,
1185,
288,
3639,
368,
3639,
368,
225,
2457,
333,
1245,
16,
7999,
326,
1008,
4694,
... |
File store = assetStores[storeNumber]; | GeneralFile assetstore = assetStores[storeNumber]; | private static File getFile(TableRow bitstream) throws IOException { // Check that bitstream is not null if (bitstream == null) { return null; } // Get the store to use int storeNumber = bitstream.getIntColumn("store_number"); // Default to zero ('assetstore.dir') for backwards compatibility if (storeNumber == -1) { storeNumber = 0; } File store = assetStores[storeNumber]; // Turn the internal ID into a file path relative to the asset store // directory String id = bitstream.getStringColumn("internal_id"); BigInteger bigint = new BigInteger(id); StringBuffer result = new StringBuffer().append(store .getCanonicalPath()); // Split the id into groups for (int i = 0; i < directoryLevels; i++) { int digits = i * digitsPerLevel; result.append(File.separator).append( id.substring(digits, digits + digitsPerLevel)); } String theName = result.append(File.separator).append(id).toString(); if (log.isDebugEnabled()) { log.debug("Filename for " + id + " is " + theName); } return new File(theName); } | 52457 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52457/8f928e283b015ffda8b1f03f8899af8a09ba1ded/BitstreamStorageManager.java/buggy/dspace/src/org/dspace/storage/bitstore/BitstreamStorageManager.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
760,
1387,
6034,
12,
30650,
28640,
13,
1216,
1860,
565,
288,
3639,
368,
2073,
716,
28640,
353,
486,
446,
3639,
309,
261,
3682,
3256,
422,
446,
13,
3639,
288,
5411,
327,
446,
31,
3... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
760,
1387,
6034,
12,
30650,
28640,
13,
1216,
1860,
565,
288,
3639,
368,
2073,
716,
28640,
353,
486,
446,
3639,
309,
261,
3682,
3256,
422,
446,
13,
3639,
288,
5411,
327,
446,
31,
3... |
return (GCTrace)ActivePlan.global(); } | return (GCTrace) ActivePlan.global(); } | private static final GCTrace global() throws InlinePragma { return (GCTrace)ActivePlan.global(); } | 49871 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/49871/57a34fa3e6e607d84b46e06082997a4771a25a85/GCTraceCollector.java/buggy/MMTk/src/org/mmtk/plan/semispace/gctrace/GCTraceCollector.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
760,
727,
611,
1268,
9963,
2552,
1435,
1216,
16355,
2050,
9454,
288,
202,
202,
2463,
261,
43,
1268,
9963,
13,
3896,
5365,
18,
6347,
5621,
202,
97,
2,
0,
0,
0,
0,
0,
0,
0,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
760,
727,
611,
1268,
9963,
2552,
1435,
1216,
16355,
2050,
9454,
288,
202,
202,
2463,
261,
43,
1268,
9963,
13,
3896,
5365,
18,
6347,
5621,
202,
97,
2,
-100,
-100,
-100,
-100,
... |
throw new EOFError(runtime); | throw new EOFError(getRuntime()); | public IRubyObject readchar() { checkReadable(); int c = handler.getc(); if (c == -1) { throw new EOFError(runtime); } return RubyFixnum.newFixnum(getRuntime(), c); } | 50993 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50993/870e1da9b41bfdbae259e1fc5f18fc8b76686998/RubyIO.java/clean/src/org/jruby/RubyIO.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
15908,
10340,
921,
855,
3001,
1435,
288,
3639,
866,
14151,
5621,
7734,
509,
276,
273,
1838,
18,
588,
71,
5621,
7734,
309,
261,
71,
422,
300,
21,
13,
288,
5411,
604,
394,
6431,
668... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
15908,
10340,
921,
855,
3001,
1435,
288,
3639,
866,
14151,
5621,
7734,
509,
276,
273,
1838,
18,
588,
71,
5621,
7734,
309,
261,
71,
422,
300,
21,
13,
288,
5411,
604,
394,
6431,
668... |
sb.append("\t"); sb.append(dns.typeString(type)); | toStringNoData() { StringBuffer sb = new StringBuffer(); sb.append(name); sb.append("\t"); sb.append(ttl); sb.append("\t"); sb.append(dns.typeString(type)); if (dclass != dns.IN) { sb.append("\t"); sb.append(dns.classString(dclass)); } sb.append("\t"); return sb;} | 4227 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/4227/8a9755345c9c34f1168b16166d8283223ef1777e/dnsRecord.java/buggy/DNS/dnsRecord.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1762,
2279,
751,
1435,
288,
202,
780,
1892,
2393,
273,
394,
6674,
5621,
202,
18366,
18,
6923,
12,
529,
1769,
202,
18366,
18,
6923,
31458,
88,
8863,
202,
18366,
18,
6923,
12,
12546,
1769,
202,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1762,
2279,
751,
1435,
288,
202,
780,
1892,
2393,
273,
394,
6674,
5621,
202,
18366,
18,
6923,
12,
529,
1769,
202,
18366,
18,
6923,
31458,
88,
8863,
202,
18366,
18,
6923,
12,
12546,
1769,
202,
... | |
if(q == '\'' || q == '\"') { | if((q == '\'') || (q == '\"')) { | public DecodedStringThingy(String s) { if(s.startsWith("url(")) { s = s.substring("url(".length()); url = true; } char q = s.charAt(0); if(q == '\'' || q == '\"') { quote = q; s = s.substring(1); } else quote = ' '; StringBuffer buffer = new StringBuffer(); int x = 0; boolean justEscaping = false; boolean stillEscaping = false; StringBuffer hexEscape = new StringBuffer(); while(x < s.length()-1) { char c = s.charAt(x); x++; if(justEscaping) { if(c == '\n') { buffer.append(c); justEscaping = false; } else if(isHexDigit(c)) { hexEscape.append(c); justEscaping = false; stillEscaping = true; } else { buffer.append(c); // Will need to be reencoded if quote or \n justEscaping = false; } } else if(stillEscaping) { if(isHexDigit(c) && hexEscape.length() < 6) { hexEscape.append(c); } else if(Character.isWhitespace(c)) { // Ignore one whitespace char after an escape int d = Integer.parseInt(hexEscape.toString(), 16); if(d > 0xFFFF) { String error = "UCS-4 CHARACTERS OVER 0xFFFF NOT SUPPORTED!"; logError(error); try { w.write("/* "+error+"*/"); } catch (IOException e) {}; } else { c = (char)d; buffer.append(c); } stillEscaping = false; hexEscape = new StringBuffer(); } else { int d = Integer.parseInt(hexEscape.toString(), 16); if(d > 0xFFFF) { String error = "UCS-4 CHARACTERS OVER 0xFFFF NOT SUPPORTED!"; logError(error); try { w.write("/* "+error+"*/"); } catch (IOException e) {}; } else { char o = (char)d; buffer.append(o); } buffer.append(c); stillEscaping = false; hexEscape = new StringBuffer(); } } else { if(quote != ' ' && c == quote) { break; } else if (c == '\\') { justEscaping = true; } else { buffer.append(c); } } } data = buffer.toString(); if(s.length() > (x+1)) suffix = s.substring(x+1); else suffix = ""; } | 56348 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/56348/ca136843ae9ecb30cadada58a33a5dc2cf8ad064/CSSTokenizerFilter.java/clean/src/freenet/clients/http/filter/CSSTokenizerFilter.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
3196,
202,
482,
6209,
72,
780,
10193,
93,
12,
780,
272,
13,
288,
1082,
202,
430,
12,
87,
18,
17514,
1190,
2932,
718,
2932,
3719,
288,
9506,
202,
87,
273,
272,
18,
28023,
2932,
718,
2932,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
3196,
202,
482,
6209,
72,
780,
10193,
93,
12,
780,
272,
13,
288,
1082,
202,
430,
12,
87,
18,
17514,
1190,
2932,
718,
2932,
3719,
288,
9506,
202,
87,
273,
272,
18,
28023,
2932,
718,
2932,
1... |
public double getDouble(int field) throws FieldNotFound { String value = getField(field).getValue(); try { return DoubleConverter.convert(value); } catch (FieldConvertError e) { throw newIncorrectDataException(e, field); } } | 52526 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52526/ac62cdb33fe9cdcbdda5568204116691fedd13fb/FieldMap.java/buggy/src/quickfix/FieldMap.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1071,
9056,
588,
5265,
12,
474,
1518,
13,
15069,
974,
2768,
95,
780,
1132,
33,
588,
974,
12,
1518,
2934,
24805,
5621,
698,
95,
2463,
5265,
5072,
18,
6283,
12,
1132,
1769,
97,
14683,
12,
974,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1071,
9056,
588,
5265,
12,
474,
1518,
13,
15069,
974,
2768,
95,
780,
1132,
33,
588,
974,
12,
1518,
2934,
24805,
5621,
698,
95,
2463,
5265,
5072,
18,
6283,
12,
1132,
1769,
97,
14683,
12,
974,... | ||
private void executeSQL70(String sql, String procName, ParamInfo[] parameters, boolean noMetaData, boolean sendNow) throws IOException, SQLException { int prepareSql = connection.getPrepareSql(); if (parameters == null && (prepareSql == EXECUTE_SQL || prepareSql == PREPARE || prepareSql == PREPEXEC)) { // Downgrade EXECUTE_SQL, PREPARE and PREPEXEC to UNPREPARED // if there are no parameters. // // Should we downgrade TEMPORARY_STORED_PROCEDURES as well? // No it may be a complex select with no parameters but costly to // evaluate for each execution. prepareSql = UNPREPARED; } if (inBatch) { // For batch execution with parameters // we need to be consistant and use // execute SQL prepareSql = EXECUTE_SQL; } if (isPreparedProcedureName(procName)) { // If the procedure is a prepared handle then redefine the // procedure name as sp_execute with the handle as a parameter. ParamInfo params[]; if (parameters != null) { params = new ParamInfo[1 + parameters.length]; System.arraycopy(parameters, 0, params, 1, parameters.length); } else { params = new ParamInfo[1]; } params[0] = new ParamInfo(Types.INTEGER, new Integer(procName), ParamInfo.INPUT); TdsData.getNativeType(connection, params[0]); parameters = params; // Use sp_execute approach procName = "sp_execute"; } else if (procName == null) { if (prepareSql == PREPEXEC) { // TODO: Make this option work with batch execution! ParamInfo params[] = new ParamInfo[3 + parameters.length]; System.arraycopy(parameters, 0, params, 3, parameters.length); // Setup prepare handle param params[0] = new ParamInfo(Types.INTEGER, null, ParamInfo.OUTPUT); TdsData.getNativeType(connection, params[0]); // Setup parameter descriptor param params[1] = new ParamInfo(Types.LONGVARCHAR, Support.getParameterDefinitions(parameters), ParamInfo.UNICODE); TdsData.getNativeType(connection, params[1]); // Setup sql statemement param params[2] = new ParamInfo(Types.LONGVARCHAR, Support.substituteParamMarkers(sql, parameters), ParamInfo.UNICODE); TdsData.getNativeType(connection, params[2]); parameters = params; // Use sp_prepexec approach procName = "sp_prepexec"; } else if (prepareSql != TdsCore.UNPREPARED && parameters != null) { ParamInfo[] params; params = new ParamInfo[2 + parameters.length]; System.arraycopy(parameters, 0, params, 2, parameters.length); params[0] = new ParamInfo(Types.LONGVARCHAR, Support.substituteParamMarkers(sql, parameters), ParamInfo.UNICODE); TdsData.getNativeType(connection, params[0]); params[1] = new ParamInfo(Types.LONGVARCHAR, Support.getParameterDefinitions(parameters), ParamInfo.UNICODE); TdsData.getNativeType(connection, params[1]); parameters = params; // Use sp_executesql approach procName = "sp_executesql"; } } if (procName != null) { // RPC call out.setPacketType(RPC_PKT); Integer shortcut; if (tdsVersion >= Driver.TDS80 && (shortcut = (Integer) tds8SpNames.get(procName)) != null) { // Use the shortcut form of procedure name for TDS8 out.write((short) -1); out.write((short) shortcut.shortValue()); } else { out.write((short) procName.length()); out.write(procName); } out.write((short) (noMetaData ? 2 : 0)); if (parameters != null) { for (int i = nextParam + 1; i < parameters.length; i++) { if (parameters[i].name != null) { out.write((byte) parameters[i].name.length()); out.write(parameters[i].name); } else { out.write((byte) 0); } out.write((byte) (parameters[i].isOutput ? 1 : 0)); TdsData.writeParam(out, connection.getCharsetInfo(), connection.getCollation(), parameters[i]); } } if (!sendNow) { // Append RPC packets out.write((byte) DONE_END_OF_RESPONSE); } } else if (sql.length() > 0) { if (parameters != null) { sql = Support.substituteParameters(sql, parameters, tdsVersion); } // Simple query out.setPacketType(QUERY_PKT); out.write(sql); if (!sendNow) { // Append SQL packets out.write("\r\n"); } } } | 2029 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/2029/6a0dfa3ffdf166ddb9edef1347afb2909589185a/TdsCore.java/clean/src/main/net/sourceforge/jtds/jdbc/TdsCore.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
918,
1836,
3997,
7301,
12,
780,
1847,
16,
17311,
514,
5418,
461,
16,
17311,
3014,
966,
8526,
1472,
16,
17311,
1250,
1158,
6998,
16,
17311,
1250,
1366,
8674,
13,
3639,
1216,
1860,
16... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
918,
1836,
3997,
7301,
12,
780,
1847,
16,
17311,
514,
5418,
461,
16,
17311,
3014,
966,
8526,
1472,
16,
17311,
1250,
1158,
6998,
16,
17311,
1250,
1366,
8674,
13,
3639,
1216,
1860,
16... | ||
public Scorer scorer (IndexReader indexReader) throws IOException { | public Scorer scorer (IndexReader indexReader) throws IOException { | protected Weight createWeight (final Searcher searcher) throws IOException { final Weight weight = query.createWeight (searcher); final Similarity similarity = query.getSimilarity(searcher); return new Weight() { // pass these methods through to enclosed query's weight public float getValue() { return weight.getValue(); } public float sumOfSquaredWeights() throws IOException { return weight.sumOfSquaredWeights(); } public void normalize (float v) { weight.normalize(v); } public Explanation explain (IndexReader ir, int i) throws IOException { return weight.explain (ir, i); } // return this query public Query getQuery() { return FilteredQuery.this; } // return a scorer that overrides the enclosed query's score if // the given hit has been filtered out. public Scorer scorer (IndexReader indexReader) throws IOException { final Scorer scorer = weight.scorer (indexReader); final BitSet bitset = filter.bits (indexReader); return new Scorer (similarity) { // pass these methods through to the enclosed scorer public boolean next() throws IOException { return scorer.next(); } public int doc() { return scorer.doc(); } public boolean skipTo (int i) throws IOException { return scorer.skipTo(i); } // if the document has been filtered out, set score to 0.0 public float score() throws IOException { return (bitset.get(scorer.doc())) ? scorer.score() : 0.0f; } // add an explanation about whether the document was filtered public Explanation explain (int i) throws IOException { Explanation exp = scorer.explain (i); if (bitset.get(i)) exp.setDescription ("allowed by filter: "+exp.getDescription()); else exp.setDescription ("removed by filter: "+exp.getDescription()); return exp; } }; } }; } | 1514 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1514/d07f7eea12d6ab5068b07dd884d8202460beaef4/FilteredQuery.java/buggy/src/java/org/apache/lucene/search/FilteredQuery.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
4750,
15437,
752,
6544,
261,
6385,
5167,
264,
27349,
13,
1216,
1860,
288,
565,
727,
15437,
3119,
273,
843,
18,
2640,
6544,
261,
3072,
264,
1769,
565,
727,
22967,
560,
16416,
273,
843,
18,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
4750,
15437,
752,
6544,
261,
6385,
5167,
264,
27349,
13,
1216,
1860,
288,
565,
727,
15437,
3119,
273,
843,
18,
2640,
6544,
261,
3072,
264,
1769,
565,
727,
22967,
560,
16416,
273,
843,
18,... |
source.append((char)ts.PRIMARY); source.append((char)ts.getOp()); | sourceAdd((char)ts.PRIMARY); sourceAdd((char)ts.getOp()); | private Object primaryExpr(TokenStream ts, Source source) throws IOException, JavaScriptException { int tt; Object pn; ts.flags |= ts.TSF_REGEXP; tt = ts.getToken(); ts.flags &= ~ts.TSF_REGEXP; switch(tt) { case TokenStream.FUNCTION: return function(ts, source, true); case TokenStream.LB: { source.append((char)ts.LB); pn = nf.createLeaf(ts.ARRAYLIT); ts.flags |= ts.TSF_REGEXP; boolean matched = ts.matchToken(ts.RB); ts.flags &= ~ts.TSF_REGEXP; if (!matched) { boolean first = true; do { ts.flags |= ts.TSF_REGEXP; tt = ts.peekToken(); ts.flags &= ~ts.TSF_REGEXP; if (!first) source.append((char)ts.COMMA); else first = false; if (tt == ts.RB) { // to fix [,,,].length behavior... break; } if (tt == ts.COMMA) { nf.addChildToBack(pn, nf.createLeaf(ts.PRIMARY, ts.UNDEFINED)); } else { nf.addChildToBack(pn, assignExpr(ts, source, false)); } } while (ts.matchToken(ts.COMMA)); mustMatchToken(ts, ts.RB, "msg.no.bracket.arg"); } source.append((char)ts.RB); return nf.createArrayLiteral(pn); } case TokenStream.LC: { pn = nf.createLeaf(ts.OBJLIT); source.append((char)ts.LC); if (!ts.matchToken(ts.RC)) { boolean first = true; commaloop: do { Object property; if (!first) source.append((char)ts.COMMA); else first = false; tt = ts.getToken(); switch(tt) { // map NAMEs to STRINGs in object literal context. case TokenStream.NAME: case TokenStream.STRING: String s = ts.getString(); source.addString(ts.NAME, s); property = nf.createString(ts.getString()); break; case TokenStream.NUMBER: double n = ts.getNumber(); source.addNumber(n); property = nf.createNumber(n); break; case TokenStream.RC: // trailing comma is OK. ts.ungetToken(tt); break commaloop; default: reportError(ts, "msg.bad.prop"); break commaloop; } mustMatchToken(ts, ts.COLON, "msg.no.colon.prop"); // OBJLIT is used as ':' in object literal for // decompilation to solve spacing ambiguity. source.append((char)ts.OBJLIT); nf.addChildToBack(pn, property); nf.addChildToBack(pn, assignExpr(ts, source, false)); } while (ts.matchToken(ts.COMMA)); mustMatchToken(ts, ts.RC, "msg.no.brace.prop"); } source.append((char)ts.RC); return nf.createObjectLiteral(pn); } case TokenStream.LP: /* Brendan's IR-jsparse.c makes a new node tagged with * TOK_LP here... I'm not sure I understand why. Isn't * the grouping already implicit in the structure of the * parse tree? also TOK_LP is already overloaded (I * think) in the C IR as 'function call.' */ source.append((char)ts.LP); pn = expr(ts, source, false); source.append((char)ts.RP); mustMatchToken(ts, ts.RP, "msg.no.paren"); return pn; case TokenStream.NAME: String name = ts.getString(); source.addString(ts.NAME, name); return nf.createName(name); case TokenStream.NUMBER: double n = ts.getNumber(); source.addNumber(n); return nf.createNumber(n); case TokenStream.STRING: String s = ts.getString(); source.addString(ts.STRING, s); return nf.createString(s); case TokenStream.OBJECT: { String flags = ts.regExpFlags; ts.regExpFlags = null; String re = ts.getString(); source.addString(ts.OBJECT, '/' + re + '/' + flags); return nf.createRegExp(re, flags); } case TokenStream.PRIMARY: source.append((char)ts.PRIMARY); source.append((char)ts.getOp()); return nf.createLeaf(ts.PRIMARY, ts.getOp()); case TokenStream.RESERVED: reportError(ts, "msg.reserved.id"); break; case TokenStream.ERROR: /* the scanner or one of its subroutines reported the error. */ break; default: reportError(ts, "msg.syntax"); break; } return null; // should never reach here } | 12564 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/12564/92ccdd736e7a1516e4fb6d1eaf915e7021c8dc95/Parser.java/buggy/src/org/mozilla/javascript/Parser.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
1033,
3354,
4742,
12,
1345,
1228,
3742,
16,
4998,
1084,
13,
3639,
1216,
1860,
16,
11905,
503,
565,
288,
3639,
509,
3574,
31,
3639,
1033,
11059,
31,
3639,
3742,
18,
7133,
5626,
3742,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
1033,
3354,
4742,
12,
1345,
1228,
3742,
16,
4998,
1084,
13,
3639,
1216,
1860,
16,
11905,
503,
565,
288,
3639,
509,
3574,
31,
3639,
1033,
11059,
31,
3639,
3742,
18,
7133,
5626,
3742,... |
WorkbenchPlugin.log("Bad extension specification", status); | WorkbenchPlugin.log("Bad startup extension specification in plugin " + extension.getNamespace(), status); | public void run() throws Exception { Object executableExtension = getExecutableExtension(); // make sure the extension implements IStartup if (executableExtension != null && executableExtension instanceof IStartup) ((IStartup) executableExtension).earlyStartup(); else { IStatus status = new Status(IStatus.ERROR, extension .getNamespace(), 0, "startup class must implement org.eclipse.ui.IStartup", //$NON-NLS-1$ null); WorkbenchPlugin.log("Bad extension specification", status); //$NON-NLS-1$ } } | 55805 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/55805/0394ca91651ee8815ed6e88762c1f1b6579a2e02/Workbench.java/buggy/bundles/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal/Workbench.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
3196,
202,
482,
918,
1086,
1435,
1216,
1185,
288,
1082,
202,
921,
9070,
3625,
273,
336,
17709,
3625,
5621,
1082,
202,
759,
1221,
3071,
326,
2710,
4792,
467,
22178,
1082,
202,
430,
261,
17751,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
3196,
202,
482,
918,
1086,
1435,
1216,
1185,
288,
1082,
202,
921,
9070,
3625,
273,
336,
17709,
3625,
5621,
1082,
202,
759,
1221,
3071,
326,
2710,
4792,
467,
22178,
1082,
202,
430,
261,
17751,
... |
public org.quickfix.field.UnderlyingCountryOfIssue getUnderlyingCountryOfIssue() throws FieldNotFound { org.quickfix.field.UnderlyingCountryOfIssue value = new org.quickfix.field.UnderlyingCountryOfIssue(); | public quickfix.field.UnderlyingCountryOfIssue getUnderlyingCountryOfIssue() throws FieldNotFound { quickfix.field.UnderlyingCountryOfIssue value = new quickfix.field.UnderlyingCountryOfIssue(); | public org.quickfix.field.UnderlyingCountryOfIssue getUnderlyingCountryOfIssue() throws FieldNotFound { org.quickfix.field.UnderlyingCountryOfIssue value = new org.quickfix.field.UnderlyingCountryOfIssue(); getField(value); return value; } | 8803 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/8803/fecc27f98261270772ff182a1d4dfd94b5daa73d/PositionMaintenanceReport.java/buggy/src/java/src/quickfix/fix44/PositionMaintenanceReport.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
2358,
18,
19525,
904,
18,
1518,
18,
14655,
6291,
8142,
951,
12956,
10833,
765,
6291,
8142,
951,
12956,
1435,
1216,
2286,
2768,
225,
288,
2358,
18,
19525,
904,
18,
1518,
18,
14655,
6... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
2358,
18,
19525,
904,
18,
1518,
18,
14655,
6291,
8142,
951,
12956,
10833,
765,
6291,
8142,
951,
12956,
1435,
1216,
2286,
2768,
225,
288,
2358,
18,
19525,
904,
18,
1518,
18,
14655,
6... |
return fileName.substring( lastindex, fileName.length( ) ); | int lastindex = fileName.lastIndexOf( '.' ); if ( lastindex > fileName.lastIndexOf( separators[separatorFlag] ) ) { return fileName.substring( lastindex, fileName.length( ) ); } | public static String getExtFromFileName( String fileName, int separatorFlag ) { assert fileName != null; int lastindex = fileName.lastIndexOf( '.' ); if ( lastindex > fileName.lastIndexOf( separators[separatorFlag] ) ) { return fileName.substring( lastindex, fileName.length( ) ); } return null; } | 46013 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/46013/c2278fa505dfa5e564690c2a5748fe1fdb271bb8/FileUtil.java/buggy/engine/org.eclipse.birt.report.engine/src/org/eclipse/birt/report/engine/util/FileUtil.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
760,
514,
336,
2482,
1265,
4771,
12,
514,
3968,
16,
509,
4182,
4678,
262,
202,
95,
202,
202,
11231,
3968,
480,
446,
31,
202,
202,
474,
1142,
1615,
273,
3968,
18,
2722,
31985,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
760,
514,
336,
2482,
1265,
4771,
12,
514,
3968,
16,
509,
4182,
4678,
262,
202,
95,
202,
202,
11231,
3968,
480,
446,
31,
202,
202,
474,
1142,
1615,
273,
3968,
18,
2722,
31985,
... |
fCurrentScope, fCurrentSchemaURL, fSchemaRootElement, | fCurrentSchemaURL, fSchemaRootElement, | private void traverseInclude(Element includeDecl) throws Exception { // General Attribute Checking int scope = GeneralAttrCheck.ELE_CONTEXT_GLOBAL; Hashtable attrValues = fGeneralAttrCheck.checkAttributes(includeDecl, scope); checkContent(includeDecl, XUtil.getFirstChildElement(includeDecl), true); Attr locationAttr = includeDecl.getAttributeNode(SchemaSymbols.ATT_SCHEMALOCATION); if (locationAttr == null) { // REVISIT: Localize reportGenericSchemaError("a schemaLocation attribute must be specified on an <include> element"); return; } String location = locationAttr.getValue(); // expand it before passing it to the parser InputSource source = null; if (fEntityResolver != null) { source = fEntityResolver.resolveEntity("", location); } if (source == null) { location = expandSystemId(location, fCurrentSchemaURL); source = new InputSource(location); } else { // create a string for uniqueness of this included schema in fIncludeLocations if (source.getPublicId () != null) location = source.getPublicId (); location += (',' + source.getSystemId ()); } if (fIncludeLocations.contains((Object)location)) { return; } fIncludeLocations.addElement((Object)location); DOMParser parser = new IgnoreWhitespaceParser(); parser.setEntityResolver( new Resolver() ); parser.setErrorHandler( new ErrorHandler() { public void fatalError(SAXParseException ex) throws SAXException { StringBuffer str = new StringBuffer(); String systemId_ = ex.getSystemId(); if (systemId_ != null) { int index = systemId_.lastIndexOf('/'); if (index != -1) systemId_ = systemId_.substring(index + 1); str.append(systemId_); } str.append(':').append(ex.getLineNumber()).append(':').append(ex.getColumnNumber()); String message = ex.getMessage(); if(message.toLowerCase().trim().endsWith("not found.")) { System.err.println("[Warning] "+ str.toString()+": "+ message); } else { // do standard thing System.err.println("[Fatal Error] "+ str.toString()+":"+message); throw ex; } } }); try { parser.setFeature("http://xml.org/sax/features/validation", false); parser.setFeature("http://xml.org/sax/features/namespaces", true); parser.setFeature("http://apache.org/xml/features/dom/defer-node-expansion", false); }catch( org.xml.sax.SAXNotRecognizedException e ) { e.printStackTrace(); }catch( org.xml.sax.SAXNotSupportedException e ) { e.printStackTrace(); } try { parser.parse( source ); }catch( IOException e ) { e.printStackTrace(); }catch( SAXException e ) { //e.printStackTrace(); } Document document = parser.getDocument(); //Our Grammar Element root = null; if (document != null) { root = document.getDocumentElement(); } if (root != null) { String targetNSURI = getTargetNamespaceString(root); if (targetNSURI.length() > 0 && !targetNSURI.equals(fTargetNSURIString) ) { // REVISIT: Localize reportGenericSchemaError("included schema '"+location+"' has a different targetNameSpace '" +targetNSURI+"'"); } else { // We not creating another TraverseSchema object to compile // the included schema file, because the scope count, anon-type count // should not be reset for a included schema, this can be fixed by saving // the counters in the Schema Grammar, if (fSchemaInfoListRoot == null) { fSchemaInfoListRoot = new SchemaInfo(fElementDefaultQualified, fAttributeDefaultQualified, fBlockDefault, fFinalDefault, fCurrentScope, fCurrentSchemaURL, fSchemaRootElement, fNamespacesScope, null, null); fCurrentSchemaInfo = fSchemaInfoListRoot; } fSchemaRootElement = root; fCurrentSchemaURL = location; traverseIncludedSchemaHeader(root); // and now we'd better save this stuff! fCurrentSchemaInfo = new SchemaInfo(fElementDefaultQualified, fAttributeDefaultQualified, fBlockDefault, fFinalDefault, fCurrentScope, fCurrentSchemaURL, fSchemaRootElement, fNamespacesScope, fCurrentSchemaInfo.getNext(), fCurrentSchemaInfo); (fCurrentSchemaInfo.getPrev()).setNext(fCurrentSchemaInfo); traverseIncludedSchema(root); // there must always be a previous element! fCurrentSchemaInfo = fCurrentSchemaInfo.getPrev(); fCurrentSchemaInfo.restore(); } } } | 4434 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/4434/d0806790dfe287190760329fd8a6008ffffa0f01/TraverseSchema.java/clean/src/org/apache/xerces/validators/schema/TraverseSchema.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
918,
10080,
8752,
12,
1046,
2341,
3456,
13,
1216,
1185,
288,
3639,
368,
9544,
3601,
24471,
3639,
509,
2146,
273,
9544,
3843,
1564,
18,
41,
900,
67,
13181,
67,
20402,
31,
3639,
18559... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
918,
10080,
8752,
12,
1046,
2341,
3456,
13,
1216,
1185,
288,
3639,
368,
9544,
3601,
24471,
3639,
509,
2146,
273,
9544,
3843,
1564,
18,
41,
900,
67,
13181,
67,
20402,
31,
3639,
18559... |
write_header("Name", entry.getKey().toString(), pw); write_entry_attributes((Attributes) entry.getValue(), pw); pw.println(); | write_header("Name", entry.getKey().toString(), out); write_entry_attributes((Attributes) entry.getValue(), out); out.write(CRLF); | private static void write_individual_sections(Map entries, PrintWriter pw) throws JarException { Iterator it = entries.entrySet().iterator(); while (it.hasNext()) { Map.Entry entry = (Map.Entry) it.next(); write_header("Name", entry.getKey().toString(), pw); write_entry_attributes((Attributes) entry.getValue(), pw); pw.println(); } } | 50763 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50763/eea27f084742358ddb097f7118c05cd257029453/Manifest.java/buggy/core/src/classpath/java/java/util/jar/Manifest.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
3238,
760,
918,
1045,
67,
22032,
5557,
67,
11657,
12,
863,
3222,
16,
14071,
8772,
13,
565,
1216,
15644,
503,
225,
288,
202,
202,
3198,
518,
273,
3222,
18,
4099,
694,
7675,
9838,
5621,
5... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
3238,
760,
918,
1045,
67,
22032,
5557,
67,
11657,
12,
863,
3222,
16,
14071,
8772,
13,
565,
1216,
15644,
503,
225,
288,
202,
202,
3198,
518,
273,
3222,
18,
4099,
694,
7675,
9838,
5621,
5... |
clientGrabber.add(cr, req); | requestGrabber.add(cr, req); | private synchronized void addToGrabArray(short priorityClass, int retryCount, Object client, ClientRequester cr, SendableRequest req) { if((priorityClass > RequestStarter.MINIMUM_PRIORITY_CLASS) || (priorityClass < RequestStarter.MAXIMUM_PRIORITY_CLASS)) throw new IllegalStateException("Invalid priority: "+priorityClass+" - range is "+RequestStarter.MAXIMUM_PRIORITY_CLASS+" (most important) to "+RequestStarter.MINIMUM_PRIORITY_CLASS+" (least important)"); // Priority SortedVectorByNumber prio = priorities[priorityClass]; if(prio == null) { prio = new SortedVectorByNumber(); priorities[priorityClass] = prio; } // Client SectoredRandomGrabArrayWithInt clientGrabber = (SectoredRandomGrabArrayWithInt) prio.get(retryCount); if(clientGrabber == null) { clientGrabber = new SectoredRandomGrabArrayWithInt(random, retryCount); prio.add(clientGrabber); if(logMINOR) Logger.minor(this, "Registering retry count "+retryCount+" with prioclass "+priorityClass); } // Request SectoredRandomGrabArrayWithClient requestGrabber = (SectoredRandomGrabArrayWithClient) clientGrabber.getGrabber(client); if(requestGrabber == null) { requestGrabber = new SectoredRandomGrabArrayWithClient(client, random); clientGrabber.addGrabber(client, requestGrabber); } clientGrabber.add(cr, req); } | 49933 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/49933/fdaec8394c29d857afa2fe31e696f7a483c5ad99/ClientRequestScheduler.java/buggy/src/freenet/client/async/ClientRequestScheduler.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
3852,
918,
9604,
14571,
70,
1076,
12,
6620,
4394,
797,
16,
509,
30084,
16,
1033,
1004,
16,
2445,
30260,
4422,
16,
2479,
429,
691,
1111,
13,
288,
202,
202,
430,
12443,
8457,
7... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
3852,
918,
9604,
14571,
70,
1076,
12,
6620,
4394,
797,
16,
509,
30084,
16,
1033,
1004,
16,
2445,
30260,
4422,
16,
2479,
429,
691,
1111,
13,
288,
202,
202,
430,
12443,
8457,
7... |
return this.lengthPair; | return this; | public Object getObject() { return this.lengthPair; } | 5268 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5268/d9a8ac86719e48e941fde9f58e7e579fe67495ce/LengthPairProperty.java/clean/src/java/org/apache/fop/fo/LengthPairProperty.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
1033,
6455,
1435,
288,
3639,
327,
333,
31,
565,
289,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
1033,
6455,
1435,
288,
3639,
327,
333,
31,
565,
289,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
if (!canAddAxisObjToArray(fieldAxis)) | if (fieldAxis != null && !canAddAxisObjToArray(fieldAxis)) | public boolean setFieldAxis (FieldAxis fieldAxis) { if (!canAddAxisObjToArray(fieldAxis)) return false; hasFieldAxis = false; if (getFieldAxis() != null) { // replace or removal List axisList = getAxes(); axisList.remove(0); if (fieldAxis != null) { axisList.add(0, fieldAxis); //replace the old fieldAxis with the new one hasFieldAxis = true; } } else { //add a fieldAxis where none prev existed. if (fieldAxis != null) { // only if we have something to add getAxes().add(0, fieldAxis);// getDataCube().incrementDimension(fieldAxis); // increment dimension hasFieldAxis = true; getDataCube().reset(); // reset data within the datacube // since we no longer can guarente internal ordering // as the field axis goes in slot "0". } } // IF we had an object, update the locators if (fieldAxis != null) { updateChildLocators(fieldAxis, "add"); } updateNotesLocationOrder(); // reset to the current order of the axes // may not be needed, but we do for all cases anyways //array doenst hold a dataformat anymore //each field along the fieldAxis should have dataformat // IF fieldAxis exists if (hasFieldAxis) { setDataFormat(null); } return true; } | 4483 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/4483/f9ef49d85d2fd601e3c36c10a94473561db251a8/Array.java/clean/src/gov/nasa/gsfc/adc/xdf/Array.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
565,
1071,
1250,
16331,
6558,
261,
974,
6558,
652,
6558,
13,
288,
4202,
309,
261,
1518,
6558,
480,
446,
597,
401,
4169,
986,
6558,
2675,
11698,
12,
1518,
6558,
3719,
540,
327,
629,
31,
1850,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
565,
1071,
1250,
16331,
6558,
261,
974,
6558,
652,
6558,
13,
288,
4202,
309,
261,
1518,
6558,
480,
446,
597,
401,
4169,
986,
6558,
2675,
11698,
12,
1518,
6558,
3719,
540,
327,
629,
31,
1850,
... |
dim.width, dim.height); | dim.width, dim.height); | public void run() { if (progressivePaintThread == thisThread) { Dimension dim = getSize(); paintImmediately(0, 0, dim.width, dim.height); } } | 46680 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/46680/e850345f051e3b8e019c9c7e22e39cb95aeb5a31/JGVTComponent.java/buggy/sources/org/apache/batik/swing/gvt/JGVTComponent.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
19694,
1071,
918,
1086,
1435,
288,
4766,
3639,
309,
261,
8298,
688,
12699,
3830,
422,
333,
3830,
13,
288,
4766,
5411,
13037,
2464,
273,
9950,
5621,
4766,
5411,
12574,
1170,
7101,
12,
20,
16,
3... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
19694,
1071,
918,
1086,
1435,
288,
4766,
3639,
309,
261,
8298,
688,
12699,
3830,
422,
333,
3830,
13,
288,
4766,
5411,
13037,
2464,
273,
9950,
5621,
4766,
5411,
12574,
1170,
7101,
12,
20,
16,
3... |
public void setValue( Object object, Object value) | public void setValue( Object object, Object value) | public void setValue( Object object, Object value) throws IllegalStateException, IllegalArgumentException { try { KeyGeneratorDef target = (KeyGeneratorDef) object; target.setAlias( (java.lang.String) value); } catch (Exception ex) { throw new IllegalStateException(ex.toString()); } } | 3614 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/3614/d7fabc686ef68f29e8236fd9afc60109670d1fd4/KeyGeneratorDefDescriptor.java/clean/trunk/castor-2002/castor/src/main/org/exolab/castor/mapping/xml/KeyGeneratorDefDescriptor.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
2398,
1071,
918,
5524,
12,
1033,
733,
16,
1033,
460,
13,
1171,
1216,
5477,
16,
2754,
5411,
288,
7734,
775,
288,
10792,
1929,
3908,
3262,
1018,
273,
261,
653,
3908,
3262,
13,
733,
31,
10792,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
2398,
1071,
918,
5524,
12,
1033,
733,
16,
1033,
460,
13,
1171,
1216,
5477,
16,
2754,
5411,
288,
7734,
775,
288,
10792,
1929,
3908,
3262,
1018,
273,
261,
653,
3908,
3262,
13,
733,
31,
10792,
... |
public boolean isRemoved() { | protected boolean isRemoved() { | public boolean isRemoved() { return removed; } | 56152 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/56152/c6cdb64c69aa98d81cdbb14125043293310564cc/PendingUpdateAdapter.java/buggy/bundles/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/progress/PendingUpdateAdapter.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
4750,
1250,
353,
10026,
1435,
288,
3639,
327,
3723,
31,
565,
289,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
4750,
1250,
353,
10026,
1435,
288,
3639,
327,
3723,
31,
565,
289,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
FontSizeSection fontSizeSection = new FontSizeSection( fontFamilyProvider.getDisplayName( ), | FontSizeSection fontSizeSection = new FontSizeSection( fontSizeProvider.getDisplayName( ), | void buildContent( ) { // Defines providers. IDescriptorProvider nameProvider = new TextPropertyDescriptorProvider( ReportItemHandle.NAME_PROP, ReportDesignConstants.TEXT_ITEM ); IDescriptorProvider contentTypeProvider = new ComboPropertyDescriptorProvider( TextItemHandle.CONTENT_TYPE_PROP, ReportDesignConstants.TEXT_ITEM ); IDescriptorProvider styleProvider = new SimpleComboPropertyDescriptorProvider( ReportItemHandle.STYLE_PROP, ReportDesignConstants.REPORT_ITEM ); IDescriptorProvider fontFamilyProvider = new ComboPropertyDescriptorProvider( StyleHandle.FONT_FAMILY_PROP, ReportDesignConstants.STYLE_ELEMENT ); IDescriptorProvider fontSizeProvider = new FontSizePropertyDescriptorProvider( StyleHandle.FONT_SIZE_PROP, ReportDesignConstants.STYLE_ELEMENT ); IDescriptorProvider colorProvider = new ColorPropertyDescriptorProvider( StyleHandle.COLOR_PROP, ReportDesignConstants.STYLE_ELEMENT ); IDescriptorProvider bgColorProvider = new ColorPropertyDescriptorProvider( StyleHandle.BACKGROUND_COLOR_PROP, ReportDesignConstants.STYLE_ELEMENT ); IDescriptorProvider[] fontStyleProviders = createFontStyleProviders( ); // Defines sections. TextSection nameSection = new TextSection( nameProvider.getDisplayName( ), container, true ); Section seperator1Section = new SeperatorSection( container, SWT.HORIZONTAL ); ComboSection contentTypeSection = new ComboSection( contentTypeProvider.getDisplayName( ), container, true ); SimpleComboSection styleSection = new SimpleComboSection( styleProvider.getDisplayName( ), container, true ); Section seperator2Section = new SeperatorSection( container, SWT.HORIZONTAL ); ComboSection fontFamilySection = new ComboSection( fontFamilyProvider.getDisplayName( ), container, true ); FontSizeSection fontSizeSection = new FontSizeSection( fontFamilyProvider.getDisplayName( ), container, true ); ColorSection colorSection = new ColorSection( colorProvider.getDisplayName( ), container, true ); ColorSection bgColorSection = new ColorSection( bgColorProvider.getDisplayName( ), container, true ); FontStyleSection fontStyleSection = new FontStyleSection( container, true, true ); // Sets providers. nameSection.setProvider( nameProvider ); contentTypeSection.setProvider( contentTypeProvider ); styleSection.setProvider( styleProvider ); fontFamilySection.setProvider( fontFamilyProvider ); fontSizeSection.setProvider( fontSizeProvider ); colorSection.setProvider( colorProvider ); bgColorSection.setProvider( bgColorProvider ); fontStyleSection.setProviders( fontStyleProviders ); // Sets widths. nameSection.setWidth( 200 ); contentTypeSection.setWidth( 200 ); styleSection.setWidth( 200 ); fontFamilySection.setWidth( 200 ); fontSizeSection.setWidth( 200 ); colorSection.setWidth( 200 ); bgColorSection.setWidth( 200 ); fontStyleSection.setWidth( 200 ); // Sets layout num. nameSection.setLayoutNum( 6 ); contentTypeSection.setLayoutNum( 2 ); styleSection.setLayoutNum( 4 ); fontFamilySection.setLayoutNum( 2 ); fontSizeSection.setLayoutNum( 4 ); colorSection.setLayoutNum( 2 ); bgColorSection.setLayoutNum( 4 ); fontStyleSection.setLayoutNum( 6 ); // Sets fill grid num. nameSection.setGridPlaceholder( 4, true ); contentTypeSection.setGridPlaceholder( 0, true ); styleSection.setGridPlaceholder( 2, true ); fontFamilySection.setGridPlaceholder( 0, true ); fontSizeSection.setGridPlaceholder( 2, true ); colorSection.setGridPlaceholder( 0, true ); bgColorSection.setGridPlaceholder( 2, true ); fontStyleSection.setGridPlaceholder( 3, true ); // Adds sections into container page. addSection( PageSectionId.TEXT_NAME, nameSection ); //$NON-NLS-1$ addSection( PageSectionId.TEXT_SEPERATOR_1, seperator1Section ); //$NON-NLS-1$ addSection( PageSectionId.TEXT_CONTENT_TYPE, contentTypeSection ); //$NON-NLS-1$ addSection( PageSectionId.TEXT_STYLE, styleSection ); //$NON-NLS-1$ addSection( PageSectionId.TEXT_FONT_FAMILY, fontFamilySection ); //$NON-NLS-1$ addSection( PageSectionId.TEXT_FONT_SIZE, fontSizeSection ); //$NON-NLS-1$ addSection( PageSectionId.TEXT_COLOR, colorSection ); //$NON-NLS-1$ addSection( PageSectionId.TEXT_BACKGROUND_COLOR, bgColorSection ); //$NON-NLS-1$ addSection( PageSectionId.TEXT_FONT_STYLE, fontStyleSection ); //$NON-NLS-1$ createSections( ); layoutSections( ); } | 5230 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5230/69ae581d294eb85ae0d7af113b9ba34f46abfb72/TextPage.java/clean/UI/org.eclipse.birt.report.designer.ui.views/src/org/eclipse/birt/report/designer/internal/ui/views/attributes/page/TextPage.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
6459,
1361,
1350,
12,
262,
202,
95,
202,
202,
759,
18003,
281,
9165,
18,
202,
202,
734,
2263,
2249,
508,
2249,
273,
394,
3867,
1396,
3187,
2249,
12,
8706,
1180,
3259,
18,
1985,
67,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
6459,
1361,
1350,
12,
262,
202,
95,
202,
202,
759,
18003,
281,
9165,
18,
202,
202,
734,
2263,
2249,
508,
2249,
273,
394,
3867,
1396,
3187,
2249,
12,
8706,
1180,
3259,
18,
1985,
67,... |
private int switchDataSet( String datasetName ) throws ChartException { int bCancel = Window.OK; if ( getDataServiceProvider( ).getBoundDataSet( ) != null && getDataServiceProvider( ).getBoundDataSet( ) .equals( datasetName ) ) { return bCancel; } try { String oldDataSetName = getDataServiceProvider( ).getBoundDataSet( ); getDataServiceProvider( ).startDataBinding( ); // Clear old dataset and preview data getDataServiceProvider( ).setDataSet( datasetName ); tablePreview.clearContents( ); // Popup data binding if ( getDataServiceProvider( ).getBoundDataSet( ) != null || getDataServiceProvider( ).getReportDataSet( ) != null ) { bCancel = getDataServiceProvider( ).invoke( IDataServiceProvider.COMMAND_EDIT_BINDING ); } if ( bCancel == Window.CANCEL ) { getDataServiceProvider( ).rollbackDataBinding( ); datasetName = oldDataSetName; } else { getDataServiceProvider( ).commitDataBinding( ); } // Try to get report data set if ( datasetName == null ) { datasetName = getDataServiceProvider( ).getReportDataSet( ); } if ( datasetName != null ) { switchDataTable( ); } else { tablePreview.createDummyTable( ); } tablePreview.layout( ); } catch ( Throwable t ) { throw new ChartException( ChartEnginePlugin.ID, ChartException.DATA_BINDING, t ); } DataDefinitionTextManager.getInstance( ).refreshAll( ); doLivePreview( ); return bCancel; } | 5230 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5230/8005353d33409f5164b0bfcc523207bf2c5c497b/TaskSelectData.java/buggy/chart/org.eclipse.birt.chart.ui.extension/src/org/eclipse/birt/chart/ui/swt/wizard/TaskSelectData.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
509,
1620,
13676,
12,
514,
3709,
461,
262,
1216,
14804,
503,
202,
95,
202,
202,
474,
324,
6691,
273,
6076,
18,
3141,
31,
202,
202,
430,
261,
4303,
16300,
12,
262,
18,
588,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
509,
1620,
13676,
12,
514,
3709,
461,
262,
1216,
14804,
503,
202,
95,
202,
202,
474,
324,
6691,
273,
6076,
18,
3141,
31,
202,
202,
430,
261,
4303,
16300,
12,
262,
18,
588,
... | ||
cv.visitMethodInsn(INVOKESPECIAL, innerClassinternalName, "<init>", prototype + ")V"); | cv.visitMethodInsn(INVOKESPECIAL, innerClassinternalName, "<init>", BytecodeHelper.getMethodDescriptor("void", localVariableParams )); | public void visitClosureExpression(ClosureExpression expression) { ClassNode innerClass = createClosureClass(expression); addInnerClass(innerClass); String innerClassinternalName = helper.getClassInternalName(innerClass.getName()); ClassNode owner = innerClass.getOuterClass(); String ownerTypeName = owner.getName(); if (classNode.isStaticClass() || isStaticMethod()) { ownerTypeName = "java.lang.Class"; } passingClosureParams = true; List constructors = innerClass.getConstructors(); ConstructorNode node = (ConstructorNode) constructors.get(0); Parameter[] localVariableParams = node.getParameters(); for (int i = 2; i < localVariableParams.length; i++) { Parameter param = localVariableParams[i]; String name = param.getName(); if (variableStack.get(name) == null && classNode.getField(name) == null) { defineVariable(name, "java.lang.Object"); } } /* if (classNode instanceof InnerClassNode) { // lets load the outer this int paramIdx = defineVariable(createVariableName("iterator"), "java.lang.Object", false).getIndex(); cv.visitVarInsn(ALOAD, 0); cv.visitFieldInsn(GETFIELD, internalClassName, "owner", helper.getTypeDescription(ownerTypeName)); cv.visitVarInsn(ASTORE, paramIdx); cv.visitTypeInsn(NEW, innerClassinternalName); cv.visitInsn(DUP); cv.visitVarInsn(ALOAD, paramIdx); } else { */ cv.visitTypeInsn(NEW, innerClassinternalName); cv.visitInsn(DUP); if (isStaticMethod() || classNode.isStaticClass()) { visitClassExpression(new ClassExpression(ownerTypeName)); } else { cv.visitVarInsn(ALOAD, 0); } /* } */ if (innerClass.getSuperClass().equals("groovy.lang.Closure")) { if (isStaticMethod()) { /** * @todo could maybe stash this expression in a JVM variable * from previous statement above */ visitClassExpression(new ClassExpression(ownerTypeName)); } else { cv.visitVarInsn(ALOAD, 0); } } String prototype = "(L" + helper.getClassInternalName(ownerTypeName) + ";Ljava/lang/Object;"; // now lets load the various parameters we're passing for (int i = 2; i < localVariableParams.length; i++) { Parameter param = localVariableParams[i]; String name = param.getName(); if (variableStack.get(name) == null) { visitFieldExpression(new FieldExpression(classNode.getField(name))); } else { visitVariableExpression(new VariableExpression(name)); } prototype = prototype + "L" + helper.getClassInternalName(param.getType()) + ";"; } passingClosureParams = false; // we may need to pass in some other constructors cv.visitMethodInsn(INVOKESPECIAL, innerClassinternalName, "<init>", prototype + ")V"); } | 6462 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/6462/9411e347dd46bbc42695d463bec72ecaed0a490a/ClassGenerator.java/clean/src/main/org/codehaus/groovy/classgen/ClassGenerator.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
3757,
10573,
2300,
12,
10573,
2300,
2652,
13,
288,
3639,
19769,
3443,
797,
273,
752,
10573,
797,
12,
8692,
1769,
3639,
527,
2857,
797,
12,
7872,
797,
1769,
3639,
514,
3443,
797... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
3757,
10573,
2300,
12,
10573,
2300,
2652,
13,
288,
3639,
19769,
3443,
797,
273,
752,
10573,
797,
12,
8692,
1769,
3639,
527,
2857,
797,
12,
7872,
797,
1769,
3639,
514,
3443,
797... |
this.listElements = new Vector(); | public VueDPGraphe (DefinitionProcessus defProc ) { // la vue observe le modle defProc.addObserver (this) ; // le diagramme au dpart est vide this.setModele(new MDDiagramme()); this.setModel(Gmodele); this.setOpaque(true); this.setLayout(null); // initialiser les listes d'lments this.elements = new Vector(); this.liens = new Vector(); this.selection = new Vector(); // par dfault, on utilise l'outil de slection this.diagramTool = new OSelection(this); // ajouter les controleurs this.addMouseListener(this); this.addMouseMotionListener(this); this.zone_affichage = this.getSize(); this.setPreferredSize(this.zone_affichage); this.setAutoscrolls(true); // on met la couleur par dfaut au diagramme modele.setFillColor(new Color(Integer.parseInt(Application.getApplication().getConfigPropriete("couleur_fond_diagrmme")))); //on peut aussi dposer des objets dans l'arbre drop target new DropTarget(this, DnDConstants.ACTION_COPY_OR_MOVE, this, true); this.setFocusable(true); } | 9761 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/9761/599d625574482d45f40f2a723d91fbf758c8842d/VueDPGraphe.java/buggy/isinit/src/iepp/ui/iedition/VueDPGraphe.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
84,
440,
933,
76,
291,
18,
1098,
3471,
273,
394,
5589,
5621,
225,
26566,
8640,
4137,
546,
291,
18,
1098,
3471,
273,
394,
5589,
5621,
225,
261,
1852,
2227,
641,
76,
291,
18,
1098,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
84,
440,
933,
76,
291,
18,
1098,
3471,
273,
394,
5589,
5621,
225,
26566,
8640,
4137,
546,
291,
18,
1098,
3471,
273,
394,
5589,
5621,
225,
261,
1852,
2227,
641,
76,
291,
18,
1098,
... | |
if (!started) | if (!started && ((LifecycleStrategy) getDelegate()).hasLifecycle(comp.getClass())) | public void stop(PicoContainer container) { if ( delegateSupportsLifecycle() ){ if (disposed) throw new IllegalStateException("Already disposed"); if (!started) throw new IllegalStateException("Not started"); stop(getComponentInstance(container)); started = false; } } | 9344 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/9344/b132f9fddc08b2c04e00ff3cf50a53b13b978237/CachingComponentAdapter.java/clean/java/picocontainer/trunk/container/src/java/org/picocontainer/defaults/CachingComponentAdapter.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
2132,
12,
52,
10764,
2170,
1478,
13,
288,
3639,
309,
261,
7152,
27878,
9977,
1435,
262,
95,
5411,
309,
261,
2251,
7423,
13,
7734,
604,
394,
5477,
2932,
9430,
1015,
7423,
8863,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
2132,
12,
52,
10764,
2170,
1478,
13,
288,
3639,
309,
261,
7152,
27878,
9977,
1435,
262,
95,
5411,
309,
261,
2251,
7423,
13,
7734,
604,
394,
5477,
2932,
9430,
1015,
7423,
8863,
... |
Event(Locator location) { this.location = new LocatorImpl(location); | Event(Locator locator) { this.location = locator == null ? NULL_LOCATOR : new LocatorImpl(locator); | Event(Locator location) { this.location = new LocatorImpl(location); } | 46428 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/46428/a9caa46e9bdb31d9cff6301cc67811bf0253bd00/JXFormsGenerator.java/clean/src/scratchpad/src/org/apache/cocoon/generation/JXFormsGenerator.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
540,
2587,
12,
5786,
2117,
13,
288,
5411,
333,
18,
3562,
273,
394,
2851,
639,
2828,
12,
3562,
1769,
3639,
289,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
540,
2587,
12,
5786,
2117,
13,
288,
5411,
333,
18,
3562,
273,
394,
2851,
639,
2828,
12,
3562,
1769,
3639,
289,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
AccountManager.deleteToken(context, token); | if (token!=null) AccountManager.deleteToken(context, token); | private void processPersonalInfo(Context context, HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException, SQLException, AuthorizeException { // Get the token String token = request.getParameter("token"); // Get the email address String email = AccountManager.getEmail(context, token); // If the token isn't valid, show an error if (email == null) { log.info(LogManager.getHeader(context, "invalid_token", "token=" + token)); // Invalid token JSPManager .showJSP(request, response, "/register/invalid-token.jsp"); return; } // If the token is valid, we create an eperson record if need be EPerson eperson = EPerson.findByEmail(context, email); if (eperson == null) { // Need to create new eperson // FIXME: TEMPORARILY need to turn off authentication, as usually // only site admins can create e-people context.setIgnoreAuthorization(true); eperson = EPerson.create(context); eperson.setEmail(email); eperson.update(); context.setIgnoreAuthorization(false); } // Now set the current user of the context // to the user associated with the token, so they can update their // info context.setCurrentUser(eperson); // Set the user profile info boolean infoOK = EditProfileServlet.updateUserProfile(eperson, request); eperson.setCanLogIn(true); eperson.setSelfRegistered(true); // Give site auth a chance to set/override appropriate fields Authenticate.getSiteAuth().initEPerson(context, request, eperson); // If the user set a password, make sure it's OK boolean passwordOK = true; if ((eperson.getRequireCertificate() == false) && Authenticate.getSiteAuth().allowSetPassword(context, request, eperson.getEmail())) { passwordOK = EditProfileServlet.confirmAndSetPassword(eperson, request); } if (infoOK && passwordOK) { // All registered OK. log.info(LogManager.getHeader(context, "usedtoken_register", "email=" + eperson.getEmail())); // delete the token AccountManager.deleteToken(context, token); // Update user record eperson.update(); request.setAttribute("eperson", eperson); JSPManager.showJSP(request, response, "/register/registered.jsp"); context.complete(); } else { request.setAttribute("token", token); request.setAttribute("eperson", eperson); request.setAttribute("missing.fields", new Boolean(!infoOK)); request.setAttribute("password.problem", new Boolean(!passwordOK)); // Indicate if user can set password boolean setPassword = Authenticate.getSiteAuth().allowSetPassword( context, request, email); request.setAttribute("set.password", new Boolean(setPassword)); JSPManager.showJSP(request, response, "/register/registration-form.jsp"); // Changes to/creation of e-person in DB cancelled context.abort(); } } | 52457 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52457/a7b957e70e83ad3ff55ae5a4a75694921654db1d/RegisterServlet.java/clean/dspace/src/org/dspace/app/webui/servlet/RegisterServlet.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
918,
1207,
8346,
287,
966,
12,
1042,
819,
16,
5411,
9984,
590,
16,
12446,
766,
13,
5411,
1216,
16517,
16,
1860,
16,
6483,
16,
5411,
23859,
503,
565,
288,
3639,
368,
968,
326,
1147... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
918,
1207,
8346,
287,
966,
12,
1042,
819,
16,
5411,
9984,
590,
16,
12446,
766,
13,
5411,
1216,
16517,
16,
1860,
16,
6483,
16,
5411,
23859,
503,
565,
288,
3639,
368,
968,
326,
1147... |
(SpectrumAnalyzer.PROP_NUMBER_FFT_POINTS, 512); | (prefix + SpectrumAnalyzer.PROP_NUMBER_FFT_POINTS, 512); | public void setProperties(SphinxProperties props) { sampleRate = props.getInt(FrontEnd.PROP_SAMPLE_RATE, 16000); minFreq = props.getDouble(PROP_MIN_FREQ, 130); maxFreq = props.getDouble(PROP_MAX_FREQ, 6800); numberFilters = props.getInt(PROP_NUMBER_FILTERS, 40); numberFftPoints = props.getInt (SpectrumAnalyzer.PROP_NUMBER_FFT_POINTS, 512); } | 8350 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/8350/bda3644280238e1081bb45ccd0b754fd70a164ff/PLPFilterbank.java/buggy/edu/cmu/sphinx/frontend/plp/PLPFilterbank.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
23126,
12,
55,
15922,
2297,
3458,
13,
288,
3639,
27505,
273,
3458,
18,
588,
1702,
12,
9580,
1638,
18,
15811,
67,
55,
21373,
67,
24062,
16,
2872,
3784,
1769,
3639,
1131,
14485,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
23126,
12,
55,
15922,
2297,
3458,
13,
288,
3639,
27505,
273,
3458,
18,
588,
1702,
12,
9580,
1638,
18,
15811,
67,
55,
21373,
67,
24062,
16,
2872,
3784,
1769,
3639,
1131,
14485,
... |
if (isZoomed()) zoomOut(); | if (child == getZoomedPart()) childRequestZoomOut(); | public void remove(LayoutPart child) { if (isZoomed()) zoomOut(); if (!isChild(child)) return; children.remove(child); if (root != null) { root = root.remove(child); } childRemoved(child); if (active) { child.setVisible(false); child.setContainer(null); flushLayout(); } } | 57470 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/57470/7afcb4763561d68f708fb2e279b5b218cd7653b0/PartSashContainer.java/buggy/bundles/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal/PartSashContainer.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1206,
12,
3744,
1988,
1151,
13,
288,
3639,
309,
261,
291,
11497,
329,
10756,
5411,
7182,
1182,
5621,
3639,
309,
16051,
291,
1763,
12,
3624,
3719,
5411,
327,
31,
3639,
2325,
18,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1206,
12,
3744,
1988,
1151,
13,
288,
3639,
309,
261,
291,
11497,
329,
10756,
5411,
7182,
1182,
5621,
3639,
309,
16051,
291,
1763,
12,
3624,
3719,
5411,
327,
31,
3639,
2325,
18,... |
trailingIdx++; today++; } retCode = MA(0, outIdx - 1, tempBuffer, optInFastD_Period, optInFastD_MAType, outBegIdx, outNbElement, outFastD); | while( today <= endIdx ) { | public TA_RetCode STOCHF(int startIdx, int endIdx, double inHigh[], double inLow[], double inClose[], int optInFastK_Period, int optInFastD_Period, TA_MAType optInFastD_MAType, MInteger outBegIdx, MInteger outNbElement, double outFastK[], double outFastD[]) { TA_RetCode retCode; double lowest, highest, tmp, diff; double[] tempBuffer; int outIdx, lowestIdx, highestIdx; int lookbackTotal, lookbackK, lookbackFastD; int trailingIdx, today, i; if (startIdx < 0) return TA_RetCode.TA_OUT_OF_RANGE_START_INDEX; if ((endIdx < 0) || (endIdx < startIdx)) return TA_RetCode.TA_OUT_OF_RANGE_END_INDEX; if ((int) optInFastK_Period == (Integer.MIN_VALUE )) optInFastK_Period = 5; else if (((int) optInFastK_Period < 1) || ((int) optInFastK_Period > 100000)) return TA_RetCode.TA_BAD_PARAM; if ((int) optInFastD_Period == (Integer.MIN_VALUE )) optInFastD_Period = 3; else if (((int) optInFastD_Period < 1) || ((int) optInFastD_Period > 100000)) return TA_RetCode.TA_BAD_PARAM; lookbackK = optInFastK_Period - 1; lookbackFastD = MA_Lookback(optInFastD_Period, optInFastD_MAType); lookbackTotal = lookbackK + lookbackFastD; if (startIdx < lookbackTotal) startIdx = lookbackTotal; if (startIdx > endIdx) { outBegIdx.value = 0; outNbElement.value = 0; return TA_RetCode.TA_SUCCESS; } outIdx = 0; trailingIdx = startIdx - lookbackTotal; today = trailingIdx + lookbackK; lowestIdx = highestIdx = -1; diff = highest = lowest = 0.0; if ((outFastK == inHigh) || (outFastK == inLow) || (outFastK == inClose)) { tempBuffer = outFastK; } else if ((outFastD == inHigh) || (outFastD == inLow) || (outFastD == inClose)) { tempBuffer = outFastD; } else { tempBuffer = new double[endIdx - today + 1]; } while (today <= endIdx) { tmp = inLow[today]; if (lowestIdx < trailingIdx) { lowestIdx = trailingIdx; lowest = inLow[lowestIdx]; i = lowestIdx; while (++i <= today) { tmp = inLow[i]; if (tmp < lowest) { lowestIdx = i; lowest = tmp; } } diff = (highest - lowest) / 100.0; } else if (tmp <= lowest) { lowestIdx = today; lowest = tmp; diff = (highest - lowest) / 100.0; } tmp = inHigh[today]; if (highestIdx < trailingIdx) { highestIdx = trailingIdx; highest = inHigh[highestIdx]; i = highestIdx; while (++i <= today) { tmp = inHigh[i]; if (tmp > highest) { highestIdx = i; highest = tmp; } } diff = (highest - lowest) / 100.0; } else if (tmp >= highest) { highestIdx = today; highest = tmp; diff = (highest - lowest) / 100.0; } if (diff != 0.0) tempBuffer[outIdx++] = (inClose[today] - lowest) / diff; else tempBuffer[outIdx++] = 0.0; trailingIdx++; today++; } retCode = MA(0, outIdx - 1, tempBuffer, optInFastD_Period, optInFastD_MAType, outBegIdx, outNbElement, outFastD); if ((retCode != TA_RetCode.TA_SUCCESS) || ((int) outNbElement.value) == 0) { ; outBegIdx.value = 0; outNbElement.value = 0; return retCode; } System.arraycopy(tempBuffer, 0, outFastK, 0, (int) outNbElement.value); ; if (retCode != TA_RetCode.TA_SUCCESS) { outBegIdx.value = 0; outNbElement.value = 0; return retCode; } outBegIdx.value = startIdx; return TA_RetCode.TA_SUCCESS; } | 7231 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/7231/5df8081f2a7211016256c0f481213a987e02947a/Core.java/clean/ta-lib/java/src/TA/Lib/Core.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
399,
37,
67,
7055,
1085,
2347,
51,
1792,
42,
12,
474,
27108,
16,
509,
679,
4223,
16,
1645,
316,
8573,
63,
6487,
1082,
202,
9056,
316,
10520,
63,
6487,
1645,
316,
4605,
63,
6... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
399,
37,
67,
7055,
1085,
2347,
51,
1792,
42,
12,
474,
27108,
16,
509,
679,
4223,
16,
1645,
316,
8573,
63,
6487,
1082,
202,
9056,
316,
10520,
63,
6487,
1645,
316,
4605,
63,
6... |
public String getStatusString() { | public synchronized String getStatusString() { | public String getStatusString() { if(status == SUCCESS) return "SUCCESS"; if(status == ROUTE_NOT_FOUND) return "ROUTE NOT FOUND"; if(status == NOT_FINISHED) return "NOT FINISHED"; if(status == INTERNAL_ERROR) return "INTERNAL ERROR"; if(status == TIMED_OUT) return "TIMED OUT"; if(status == GENERATED_REJECTED_OVERLOAD) return "GENERATED REJECTED OVERLOAD"; if(status == ROUTE_REALLY_NOT_FOUND) return "ROUTE REALLY NOT FOUND"; return "UNKNOWN STATUS CODE: "+status; } | 49933 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/49933/18bdac5b045940cab8c77eb1e775cefcdda23e0a/CHKInsertSender.java/buggy/src/freenet/node/CHKInsertSender.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
3852,
514,
5870,
780,
1435,
288,
3639,
309,
12,
2327,
422,
16561,
13,
5411,
327,
315,
12778,
14432,
3639,
309,
12,
2327,
422,
6525,
9099,
67,
4400,
67,
9294,
13,
5411,
327,
315,
3... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
3852,
514,
5870,
780,
1435,
288,
3639,
309,
12,
2327,
422,
16561,
13,
5411,
327,
315,
12778,
14432,
3639,
309,
12,
2327,
422,
6525,
9099,
67,
4400,
67,
9294,
13,
5411,
327,
315,
3... |
if (!file.isWritable()) { | if (file != null && !file.isWritable()) { | private FileInfo[] createFileInfos(VirtualFile[] files) { List<FileInfo> fileInfos = new ArrayList<FileInfo>(); for (int i = 0; i < files.length; i++) { final VirtualFile file = files[i]; if (!file.isWritable()) { fileInfos.add(new FileInfo(file, myProject)); } } return fileInfos.toArray(new FileInfo[fileInfos.size()]); } | 17306 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/17306/c960e2c5d7f048a2889777d44d40aecf931eadc7/ReadonlyStatusHandlerImpl.java/buggy/source/com/intellij/openapi/vcs/readOnlyHandler/ReadonlyStatusHandlerImpl.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
3238,
14236,
8526,
21266,
7655,
12,
6466,
812,
8526,
1390,
13,
288,
565,
987,
32,
11995,
34,
585,
7655,
273,
394,
2407,
32,
11995,
34,
5621,
565,
364,
261,
474,
277,
273,
374,
31,
277,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
3238,
14236,
8526,
21266,
7655,
12,
6466,
812,
8526,
1390,
13,
288,
565,
987,
32,
11995,
34,
585,
7655,
273,
394,
2407,
32,
11995,
34,
5621,
565,
364,
261,
474,
277,
273,
374,
31,
277,
... |
suite.addTestSuite( QuantileNormalizerTest.class ); suite.addTestSuite( RMATest.class ); suite.addTestSuite( RMABackgroundAdjusterTest.class ); suite.addTestSuite( TwoColorArrayLoessNormalizerTest.class ); | public static Test suite() { TestSuite suite = new TestSuite( "Test for edu.columbia.gemma" ); // $JUnit-BEGIN$ // analysis suite.addTestSuite( QuantileNormalizerTest.class ); suite.addTestSuite( RMATest.class ); suite.addTestSuite( RMABackgroundAdjusterTest.class ); suite.addTestSuite( TwoColorArrayLoessNormalizerTest.class ); // common.auditAndSecurity suite.addTestSuite( AuditTrailDaoTest.class ); suite.addTestSuite( UserRoleServiceImplTest.class ); suite.addTestSuite( UserServiceImplTest.class ); suite.addTestSuite( UserDaoImplTest.class ); // common.description suite.addTestSuite( BibliographicReferenceDaoImplTest.class ); suite.addTestSuite( BibliographicReferenceServiceImplTest.class ); suite.addTestSuite( DatabaseEntryDaoImplTest.class ); suite.addTestSuite( ExternalDatabaseServiceImplTest.class ); suite.addTestSuite( LocalFileServiceImplTest.class ); // common.protocol suite.addTestSuite( ProtocolServiceTest.class ); // expression.experiment suite.addTestSuite( ExpressionExperimentServiceImplTest.class ); // externalDb -- test is in wrong place suite.addTestSuite( ExternalDatabaseTest.class ); // genome.gene suite.addTestSuite( CandidateGeneImplTest.class ); suite.addTestSuite( CandidateGeneListDAOImplTest.class ); suite.addTestSuite( CandidateGeneListImplTest.class ); suite.addTestSuite( CandidateGeneListServiceImplTest.class ); suite.addTestSuite( GeneServiceImplTest.class ); // genome.sequenceAnalysis suite.addTestSuite( BlatResultImplTest.class ); // loader.association suite.addTestSuite( Gene2GOAssociationParserTest.class ); // loader.description suite.addTestSuite( OntologyEntryLoaderIntegrationTest.class ); // loader.entrez.pubmed suite.addTestSuite( PubMedXMLFetcherTest.class ); suite.addTestSuite( PubMedXMLParserTest.class ); // loader.expression.arrayDesign suite.addTestSuite( AffyProbeReaderTest.class ); suite.addTestSuite( ArrayDesignParserIntegrationTest.class ); suite.addTestSuite( IlluminaProbeReaderTest.class ); // loader.expression.arrayExpress suite.addTestSuite( DataFileFetcherTest.class ); // loader.expression.geo // suite.addTestSuite( GeoDatasetServiceIntegrationTest.class ); suite.addTestSuite( GeoFamilyParserTest.class ); suite.addTestSuite( RawDataFetcherTest.class ); suite.addTestSuite( GeoConverterTest.class ); // loader.expression.mage suite.addTestSuite( MageMLParserTest.class ); suite.addTestSuite( MageLoadTest.class ); // loader.expression.smd suite.addTestSuite( SMDManagerImplTest.class ); // loader.expression.smd.model suite.addTestSuite( ExptMetaTest.class ); suite.addTestSuite( PublicationMetaTest.class ); // loader.genome.gene suite.addTestSuite( NCBIGeneParserTest.class ); // loader.loaderutils suite.addTestSuite( BeanPropertyCompleterTest.class ); // security suite.addTestSuite( SecurityIntegrationTest.class ); // security.interceptor suite.addTestSuite( PersistAclInterceptorTest.class ); suite.addTestSuite( AuditInterceptorTest.class ); // sequence suite.addTestSuite( QtlDaoImplTest.class ); // tools suite.addTestSuite( AffyBatchTest.class ); suite.addTestSuite( GoldenPathTest.class ); suite.addTestSuite( SequenceManipulationTest.class ); suite.addTestSuite( BlatTest.class ); suite.addTestSuite( MArrayRawTest.class ); // web.controller.common.auditAndSecurity suite.addTestSuite( SignupControllerTest.class ); // web.controller.entrez.pubmed suite.addTestSuite( ArrayDesignControllerTest.class ); // web.controller.flow.entrez.pubmed suite.addTestSuite( SearchPubMedFlowTests.class ); suite.addTestSuite( DetailBibRefFlowTests.class ); // $JUnit-END$ return suite; } | 4335 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/4335/1aa223c9442040d0cb2ce26afedeedff6105f5a2/AllTests.java/buggy/test/edu/columbia/gemma/AllTests.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
760,
7766,
11371,
1435,
288,
3639,
7766,
13587,
11371,
273,
394,
7766,
13587,
12,
315,
4709,
364,
1675,
89,
18,
1293,
3592,
1155,
18,
23465,
2540,
6,
11272,
3639,
368,
271,
46,
2802... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
760,
7766,
11371,
1435,
288,
3639,
7766,
13587,
11371,
273,
394,
7766,
13587,
12,
315,
4709,
364,
1675,
89,
18,
1293,
3592,
1155,
18,
23465,
2540,
6,
11272,
3639,
368,
271,
46,
2802... | |
else if (page.isRenderingStale(Integer.parseInt(request.getParameter("rendering")))) { onStaleRendering(page); return true; } | private boolean callComponentListener() { // Get any component parameter final String path = request.getParameter("component"); if (path != null) { // Get page from path log.debug("Getting page for path " + path); final Page page = session.getPage(path); // Does page exist? if (page != null) { // Is page stale? if (page.isStale()) { onStalePage(); return true; } else if (page.isRenderingStale(Integer.parseInt(request.getParameter("rendering")))) { onStaleRendering(page); return true; } else { invokeInterface(page, path, request.getParameter("interface")); return true; } } else { onExpiredPage(); return true; } } else { // Get path info final String pathInfo = ((WebRequest)request).getHttpServletRequest().getPathInfo(); if (pathInfo != null) { // Get resource for path final Resource resource = Resource.forPath(pathInfo.substring(1)); if (resource != null) { // Request resource resource.onResourceRequested(); return true; } } } return false; } | 46434 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/46434/027891be3bb07c2ea1ebbcb0f11d4d5ee82f6cf1/WebRequestCycle.java/buggy/wicket/src/java/wicket/protocol/http/WebRequestCycle.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
1250,
745,
1841,
2223,
1435,
202,
95,
202,
202,
759,
968,
1281,
1794,
1569,
202,
202,
6385,
514,
589,
273,
590,
18,
588,
1662,
2932,
4652,
8863,
202,
202,
430,
261,
803,
480,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
1250,
745,
1841,
2223,
1435,
202,
95,
202,
202,
759,
968,
1281,
1794,
1569,
202,
202,
6385,
514,
589,
273,
590,
18,
588,
1662,
2932,
4652,
8863,
202,
202,
430,
261,
803,
480,... | |
getEnclosingTypeName(), | isEnclosingTypeSelected() ? getEnclosingTypeName() : null, | public void createClass(IProgressMonitor monitor) { try { fCodeGenerator = new NewClassCodeGenerator( getHeaderFileFullPath(), getSourceFileFullPath(), getClassTypeName(),// isNamespaceButtonSelected() ? getEnclosingTypeName() : null, getEnclosingTypeName(), getBaseClasses(), getCheckedMethodStubs()); fCodeGenerator.createClass(monitor); } catch (CodeGeneratorException e) { // TODO Auto-generated catch block e.printStackTrace(); } catch (CoreException e) { // TODO Auto-generated catch block e.printStackTrace(); } catch (InterruptedException e) { // TODO Auto-generated catch block e.printStackTrace(); } } | 6192 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/6192/0feec5d746509786a6956197b6ef69891abf1347/NewClassCreationWizardPage.java/clean/core/org.eclipse.cdt.ui/src/org/eclipse/cdt/internal/ui/wizards/classwizard/NewClassCreationWizardPage.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
752,
797,
12,
45,
5491,
7187,
6438,
13,
288,
3639,
775,
288,
5411,
284,
1085,
3908,
273,
394,
1166,
797,
1085,
3908,
12,
10792,
7911,
812,
24173,
9334,
10792,
7889,
812,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
752,
797,
12,
45,
5491,
7187,
6438,
13,
288,
3639,
775,
288,
5411,
284,
1085,
3908,
273,
394,
1166,
797,
1085,
3908,
12,
10792,
7911,
812,
24173,
9334,
10792,
7889,
812,
... |
} | }*/ | protected RubyObject invokeMethod(RubyObject recv, Object[] methodArgs, Ruby ruby) { if (methodArgs == null) { methodArgs = new Object[0]; } if (restArgs) { RubyObject[] restArray = new RubyObject[methodArgs.length - (args.length - 1)]; Object[] newMethodArgs = new Object[args.length]; System.arraycopy(methodArgs, args.length - 1, restArray, 0, methodArgs.length - (args.length - 1)); System.arraycopy(methodArgs, 0, newMethodArgs, 0, args.length - 1); newMethodArgs[args.length - 1] = restArray; methodArgs = newMethodArgs; } if (staticMethod) { Object[] newMethodArgs = new Object[methodArgs.length + 1]; System.arraycopy(methodArgs, 0, newMethodArgs, 1, methodArgs.length); newMethodArgs[0] = ruby; methodArgs = newMethodArgs; } try { return (RubyObject)getMethod().invoke(staticMethod ? null : recv, methodArgs); } catch (IllegalAccessException iaExcptn) { throw new RuntimeException("IllegalAccessException: Cannot invoke method \"" + methodName + "\" in class \"" + klass.getName() + "\" by Reflection."); } catch (IllegalArgumentException iaExcptn) { throw new RuntimeException("IllegalArgumentException: Cannot invoke method \"" + methodName + "\" in class \"" + klass.getName() + "\" by Reflection."); } catch (InvocationTargetException itExcptn) { throw new RuntimeException("InvocationTargetException: Cannot invoke method \"" + methodName + "\" in class \"" + klass.getName() + "\" by Reflection."); } } | 52337 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52337/12847c6fd28fea4e223d132ced46eb1b4cb9de9a/ReflectionCallbackMethod.java/clean/org/jruby/core/ReflectionCallbackMethod.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
4750,
19817,
921,
27632,
12,
54,
10340,
921,
10665,
16,
1033,
8526,
707,
2615,
16,
19817,
22155,
13,
288,
3639,
309,
261,
2039,
2615,
422,
446,
13,
288,
5411,
707,
2615,
273,
394,
1033,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
4750,
19817,
921,
27632,
12,
54,
10340,
921,
10665,
16,
1033,
8526,
707,
2615,
16,
19817,
22155,
13,
288,
3639,
309,
261,
2039,
2615,
422,
446,
13,
288,
5411,
707,
2615,
273,
394,
1033,
... |
public PublicKey decodePublicKey(byte[] input) { log.entering(this.getClass().getName(), "decodePublicKey()", input); if (input == null) throw new InvalidParameterException("Input bytes MUST NOT be null"); BigInteger n, e; DERReader der = new DERReader(input); try { DERValue derSPKI = der.read(); DerUtil.checkIsConstructed(derSPKI, "Wrong SubjectPublicKeyInfo field"); DERValue derAlgorithmID = der.read(); DerUtil.checkIsConstructed(derAlgorithmID, "Wrong AlgorithmIdentifier field"); DERValue derOID = der.read(); if (! (derOID.getValue() instanceof OID)) throw new InvalidParameterException("Wrong Algorithm field"); OID algOID = (OID) derOID.getValue(); if (! algOID.equals(RSA_ALG_OID)) throw new InvalidParameterException("Unexpected OID: " + algOID); // rfc-2459 states that this field is OPTIONAL but NULL if/when present DERValue val = der.read(); if (val.getTag() == DER.NULL) val = der.read(); if (! (val.getValue() instanceof BitString)) throw new InvalidParameterException("Wrong SubjectPublicKey field"); byte[] spkBytes = ((BitString) val.getValue()).toByteArray(); der = new DERReader(spkBytes); val = der.read(); DerUtil.checkIsConstructed(derAlgorithmID, "Wrong subjectPublicKey field"); val = der.read(); DerUtil.checkIsBigInteger(val, "Wrong modulus field"); n = (BigInteger) val.getValue(); val = der.read(); DerUtil.checkIsBigInteger(val, "Wrong publicExponent field"); e = (BigInteger) val.getValue(); } catch (IOException x) { InvalidParameterException y = new InvalidParameterException(); y.initCause(x); throw y; } PublicKey result = new GnuRSAPublicKey(Registry.X509_ENCODING_ID, n, e); log.exiting(this.getClass().getName(), "decodePublicKey()", result); return result; } | 1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/b3a024d60c5143b61f97b230d24e7ea41f17a0fd/RSAKeyPairX509Codec.java/buggy/core/src/classpath/gnu/gnu/java/security/key/rsa/RSAKeyPairX509Codec.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1071,
9632,
3922,
9632,
12,
7229,
8526,
2630,
15329,
1330,
18,
2328,
310,
12,
2211,
18,
588,
797,
7675,
17994,
9334,
6,
3922,
9632,
1435,
3113,
2630,
1769,
430,
12,
2630,
631,
2011,
13,
12849,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1071,
9632,
3922,
9632,
12,
7229,
8526,
2630,
15329,
1330,
18,
2328,
310,
12,
2211,
18,
588,
797,
7675,
17994,
9334,
6,
3922,
9632,
1435,
3113,
2630,
1769,
430,
12,
2630,
631,
2011,
13,
12849,... | ||
private static String generateSql(QuerySpec spec, java.sql.Connection jdbcConnection) { | private static String generateSql(QuerySpec spec, java.sql.Connection jdbcConnection, boolean aggregate) { | private static String generateSql(QuerySpec spec, java.sql.Connection jdbcConnection) { final DatabaseMetaData metaData; try { metaData = jdbcConnection.getMetaData(); } catch (SQLException e) { throw Util.getRes().newInternal("while loading segment", e); } RolapStar star = spec.getStar(); // are there any distinct measures? int distinctCount = 0; for (int i = 0, measureCount = spec.getMeasureCount(); i < measureCount; i++) { RolapStar.Measure measure = spec.getMeasure(i); if (measure.aggregator.distinct) { distinctCount++; } } SqlQuery sqlQuery = new SqlQuery(metaData); final boolean wrapInDistinct = distinctCount > 0 && !sqlQuery.allowsCountDistinct(); if (wrapInDistinct) { // Generate something like // select d0, d1, count(m0) // from ( // select distinct x as d0, y as d1, z as m0 // from t) as foo // group by d0, d1 final SqlQuery innerSqlQuery = sqlQuery; innerSqlQuery.setDistinct(true); final SqlQuery outerSqlQuery = new SqlQuery(metaData); // add constraining dimensions RolapStar.Column[] columns = spec.getColumns(); int arity = columns.length; for (int i = 0; i < arity; i++) { RolapStar.Column column = columns[i]; RolapStar.Table table = column.table; if (table.isFunky()) { // this is a funky dimension -- ignore for now continue; } table.addToFrom(innerSqlQuery, false, true); String expr = column.getExpression(innerSqlQuery); Object[] constraints = spec.getConstraints(i); if (constraints != null) { innerSqlQuery.addWhere( expr + " in " + column.quoteValues(constraints)); } final String alias = "d" + i; innerSqlQuery.addSelect(expr, alias); outerSqlQuery.addSelect(alias); outerSqlQuery.addGroupBy(alias); } for (int i = 0, measureCount = spec.getMeasureCount(); i < measureCount; i++) { RolapStar.Measure measure = spec.getMeasure(i); Util.assertTrue(measure.table == star.factTable); star.factTable.addToFrom(innerSqlQuery, false, true); final String alias = "m" + i; innerSqlQuery.addSelect(measure.getExpression(outerSqlQuery), alias); outerSqlQuery.addSelect( measure.aggregator.getNonDistinctAggregator().getExpression( alias)); } outerSqlQuery.addFrom(innerSqlQuery, "foo", true); sqlQuery = outerSqlQuery; } else { // add constraining dimensions RolapStar.Column[] columns = spec.getColumns(); int arity = columns.length; for (int i = 0; i < arity; i++) { RolapStar.Column column = columns[i]; RolapStar.Table table = column.table; if (table.isFunky()) { // this is a funky dimension -- ignore for now continue; } table.addToFrom(sqlQuery, false, true); String expr = column.getExpression(sqlQuery); Object[] constraints = spec.getConstraints(i); if (constraints != null) { sqlQuery.addWhere( expr + " in " + column.quoteValues(constraints)); } sqlQuery.addSelect(expr); sqlQuery.addGroupBy(expr); } // add measures for (int i = 0, measureCount = spec.getMeasureCount(); i < measureCount; i++) { RolapStar.Measure measure = spec.getMeasure(i); Util.assertTrue(measure.table == star.factTable); star.factTable.addToFrom(sqlQuery, false, true); sqlQuery.addSelect( measure.aggregator.getExpression(measure.getExpression(sqlQuery))); } } return sqlQuery.toString(); } | 51263 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/51263/d09f5ca50f0aebe9865a143cb6018a3ce6e2652c/AggregationManager.java/buggy/src/main/mondrian/rolap/agg/AggregationManager.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
760,
514,
2103,
5101,
12,
1138,
1990,
857,
16,
2252,
18,
4669,
18,
1952,
16579,
1952,
16,
1250,
7047,
13,
288,
3639,
727,
5130,
6998,
11651,
31,
3639,
775,
288,
5411,
11651,
273,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
760,
514,
2103,
5101,
12,
1138,
1990,
857,
16,
2252,
18,
4669,
18,
1952,
16579,
1952,
16,
1250,
7047,
13,
288,
3639,
727,
5130,
6998,
11651,
31,
3639,
775,
288,
5411,
11651,
273,
... |
public org.quickfix.field.ExpireTime getExpireTime() throws FieldNotFound { org.quickfix.field.ExpireTime value = new org.quickfix.field.ExpireTime(); | public quickfix.field.ExpireTime getExpireTime() throws FieldNotFound { quickfix.field.ExpireTime value = new quickfix.field.ExpireTime(); | public org.quickfix.field.ExpireTime getExpireTime() throws FieldNotFound { org.quickfix.field.ExpireTime value = new org.quickfix.field.ExpireTime(); getField(value); return value; } | 5926 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5926/fecc27f98261270772ff182a1d4dfd94b5daa73d/QuoteRequestReject.java/buggy/src/java/src/quickfix/fix43/QuoteRequestReject.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
2358,
18,
19525,
904,
18,
1518,
18,
17033,
950,
336,
17033,
950,
1435,
1216,
2286,
2768,
225,
288,
2358,
18,
19525,
904,
18,
1518,
18,
17033,
950,
460,
273,
394,
2358,
18,
19525,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
2358,
18,
19525,
904,
18,
1518,
18,
17033,
950,
336,
17033,
950,
1435,
1216,
2286,
2768,
225,
288,
2358,
18,
19525,
904,
18,
1518,
18,
17033,
950,
460,
273,
394,
2358,
18,
19525,
... |
getSession().getUnitOfWork().registerDirty(this); | registerDirty(); | public synchronized OutputStream getOutputStream() throws RepositoryException { if (getLogger().isDebugEnabled()) getLogger().debug("Get OutputStream for " + getSourceURI()); try { if (!isLocked()) { throw new RuntimeException("Cannot write to source [" + getSourceURI() + "]: not locked!"); } if (getSession().getUnitOfWork() == null) { throw new RuntimeException("Cannot write to source outside of a transaction (UnitOfWork is null)!"); } getSession().getUnitOfWork().registerDirty(this); } catch (Exception e) { throw new RuntimeException(e); } return new NodeOutputStream(); } | 45951 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/45951/cc3f7dfe1d92a71fc566359639191acc6aed652e/SourceNode.java/clean/src/java/org/apache/lenya/cms/repository/SourceNode.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
3852,
8962,
22553,
1435,
1216,
13367,
288,
3639,
309,
261,
588,
3328,
7675,
291,
2829,
1526,
10756,
5411,
7156,
7675,
4148,
2932,
967,
8962,
364,
315,
397,
7889,
3098,
10663,
3639,
77... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
3852,
8962,
22553,
1435,
1216,
13367,
288,
3639,
309,
261,
588,
3328,
7675,
291,
2829,
1526,
10756,
5411,
7156,
7675,
4148,
2932,
967,
8962,
364,
315,
397,
7889,
3098,
10663,
3639,
77... |
prepareContent(false); | prepareContent(false); | protected void initWorkplaceRequestValues(CmsWorkplaceSettings settings, HttpServletRequest request) { // fill the parameter values in the get/set methods fillParamValues(request); // set the dialog type setParamDialogtype(EDITOR_TYPE); // Initialize a page object from the temporary file if (getParamTempfile() != null && !"null".equals(getParamTempfile())) { try { m_file = getCms().readFile(this.getParamTempfile(), CmsResourceFilter.ALL); m_page = CmsXmlPageFactory.unmarshal(getCms(), m_file); } catch (CmsException e) { // error during initialization try { showErrorPage(this, e); } catch (JspException exc) { // should usually never happen if (LOG.isInfoEnabled()) { LOG.info(exc); } } } } // set the action for the JSP switch if (EDITOR_SAVE.equals(getParamAction())) { setAction(ACTION_SAVE); } else if (EDITOR_SAVEEXIT.equals(getParamAction())) { setAction(ACTION_SAVEEXIT); } else if (EDITOR_SAVEACTION.equals(getParamAction())) { setAction(ACTION_SAVEACTION); try { actionDirectEdit(); } catch (Exception e) { // should usually never happen if (LOG.isInfoEnabled()) { LOG.info(e); } } setAction(ACTION_EXIT); } else if (EDITOR_EXIT.equals(getParamAction())) { setAction(ACTION_EXIT); } else if (EDITOR_CHANGE_ELEMENT.equals(getParamAction())) { setAction(ACTION_SHOW); actionChangeBodyElement(); // prepare the content String for the editor prepareContent(false); } else if (EDITOR_CLEANUP.equals(getParamAction())) { setAction(ACTION_SHOW); actionCleanupBodyElement(); // prepare the content String for the editor prepareContent(false); } else if (EDITOR_SHOW.equals(getParamAction())) { setAction(ACTION_SHOW); // prepare the content String for the editor prepareContent(false); } else if (EDITOR_PREVIEW.equals(getParamAction())) { setAction(ACTION_PREVIEW); } else { // initial call of editor, initialize page and page parameters setAction(ACTION_DEFAULT); try { // lock resource if autolock is enabled in configuration if ("true".equals(getParamDirectedit())) { // set a temporary lock in direct edit mode checkLock(getParamResource(), CmsLock.C_MODE_TEMP); } else { // set common lock checkLock(getParamResource()); } // create the temporary file setParamTempfile(createTempFile()); // initialize a page object from the created temporary file m_file = getCms().readFile(this.getParamTempfile(), CmsResourceFilter.ALL); m_page = CmsXmlPageFactory.unmarshal(getCms(), m_file); } catch (CmsException e) { // error during initialization try { showErrorPage(this, e); } catch (JspException exc) { // should usually never happen if (LOG.isInfoEnabled()) { LOG.info(exc); } } } // set the initial body language & name if not given in request parameters if (getParamElementlanguage() == null) { initBodyElementLanguage(); } if (getParamElementname() == null) { initBodyElementName(null); } // initialize the editor content initContent(); // prepare the content String for the editor prepareContent(false); } } | 51784 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/51784/2fa0efcae8f9aa5971c7763269a3b033e9256d4b/CmsSimplePageEditor.java/buggy/src/org/opencms/workplace/editors/CmsSimplePageEditor.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
4750,
918,
1208,
16514,
691,
1972,
12,
4747,
16514,
2628,
1947,
16,
9984,
590,
13,
288,
3639,
368,
3636,
326,
1569,
924,
316,
326,
336,
19,
542,
2590,
3639,
3636,
786,
1972,
12,
2293,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
4750,
918,
1208,
16514,
691,
1972,
12,
4747,
16514,
2628,
1947,
16,
9984,
590,
13,
288,
3639,
368,
3636,
326,
1569,
924,
316,
326,
336,
19,
542,
2590,
3639,
3636,
786,
1972,
12,
2293,
1... |
Field field = findField(refType); | Field field = findField(refType, context); | private Object evaluateField(Object object, EvaluationContextImpl context) throws EvaluateException { if (object instanceof ReferenceType) { ReferenceType refType = (ReferenceType)object; Field field = findField(refType); if (field == null || !field.isStatic()) { field = refType.fieldByName(myFieldName); } if (field == null || !field.isStatic()) { throw EvaluateExceptionUtil.createEvaluateException(DebuggerBundle.message("evaluation.error.no.static.field", myFieldName)); } myEvaluatedField = field; myEvaluatedQualifier = refType; return refType.getValue(field); } if (object instanceof ObjectReference) { ObjectReference objRef = (ObjectReference)object; ReferenceType refType = objRef.referenceType(); if (!(refType instanceof ClassType || refType instanceof ArrayType)) { throw EvaluateExceptionUtil.createEvaluateException(DebuggerBundle.message("evaluation.error.class.or.array.expected", myFieldName)); } // expressions like 'array.length' must be treated separately //noinspection HardCodedStringLiteral if (objRef instanceof ArrayReference && "length".equals(myFieldName)) { //noinspection HardCodedStringLiteral return DebuggerUtilsEx.createValue( context.getDebugProcess().getVirtualMachineProxy(), "int", ((ArrayReference)objRef).length() ); } Field field = findField(refType); if (field == null) { field = refType.fieldByName(myFieldName); } if (field == null) { throw EvaluateExceptionUtil.createEvaluateException(DebuggerBundle.message("evaluation.error.no.instance.field", myFieldName)); } myEvaluatedQualifier = field.isStatic()? (Object)refType : (Object)objRef; myEvaluatedField = field; return field.isStatic()? refType.getValue(field) : objRef.getValue(field); } if(object == null) { throw EvaluateExceptionUtil.createEvaluateException(new NullPointerException()); } throw EvaluateExceptionUtil.createEvaluateException(DebuggerBundle.message("evaluation.error.evaluating.field", myFieldName)); } | 12814 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/12814/d9d82a5455e33c5fbaa5b9ebd016d08c54249284/FieldEvaluator.java/buggy/debugger/impl/com/intellij/debugger/engine/evaluation/expression/FieldEvaluator.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
3238,
1033,
5956,
974,
12,
921,
733,
16,
17340,
1042,
2828,
819,
13,
1216,
18176,
503,
288,
565,
309,
261,
1612,
1276,
6268,
559,
13,
288,
1377,
6268,
559,
1278,
559,
273,
261,
2404,
55... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
3238,
1033,
5956,
974,
12,
921,
733,
16,
17340,
1042,
2828,
819,
13,
1216,
18176,
503,
288,
565,
309,
261,
1612,
1276,
6268,
559,
13,
288,
1377,
6268,
559,
1278,
559,
273,
261,
2404,
55... |
return null; } else { try { Field field = ref.getWrappedClass().getField(name); if (Modifier.isStatic(field.getModifiers()) && Modifier.isPublic(field.getModifiers()) && field.getType().equals(type)) { return field.get(ref.getWrappedInstance()); } } catch (NoSuchFieldException e) { } catch (IllegalAccessException e) { } | protected Object getPropertyValue(String name, Class type) { BeanWrapper ref = getReference(); if (ref.isReadableProperty(name) && ref.getPropertyType(name).isAssignableFrom(type)) { Object value = ref.getPropertyValue(name); if(value != null && type.isAssignableFrom(value.getClass())) { return value; } return null; } else { try { Field field = ref.getWrappedClass().getField(name); if (Modifier.isStatic(field.getModifiers()) && Modifier.isPublic(field.getModifiers()) && field.getType().equals(type)) { return field.get(ref.getWrappedInstance()); } } catch (NoSuchFieldException e) { // ignore } catch (IllegalAccessException e) { // ignore } } return null; } | 28089 /local/tlutelli/issta_data/temp/all_java2context/java/2006_temp/2006/28089/f3501a936fa4b7198a64ec638260a4d7cca023ba/AbstractGrailsClass.java/clean/src/commons/org/codehaus/groovy/grails/commons/AbstractGrailsClass.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1117,
1033,
21694,
12,
780,
508,
16,
1659,
618,
13,
288,
202,
202,
3381,
3611,
1278,
273,
13223,
5621,
202,
202,
430,
261,
1734,
18,
291,
14151,
1396,
12,
529,
13,
597,
1278,
18,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1117,
1033,
21694,
12,
780,
508,
16,
1659,
618,
13,
288,
202,
202,
3381,
3611,
1278,
273,
13223,
5621,
202,
202,
430,
261,
1734,
18,
291,
14151,
1396,
12,
529,
13,
597,
1278,
18,
... | |
for (Enumeration e = in.questions.elements(); e.hasMoreElements(); ) { DNSEntry entry = (DNSEntry) e.nextElement(); | for (Iterator i = in.questions.iterator(); i.hasNext(); ) { DNSEntry entry = (DNSEntry) i.next(); | public void start() { // According to draft-cheshire-dnsext-multicastdns.txt // chapter "8 Responding": // We respond immediately if we know for sure, that we are // the only one who can respond to the query. // In all other cases, we respond within 20-120 ms. // // According to draft-cheshire-dnsext-multicastdns.txt // chapter "7.2 Multi-Packet Known Answer Suppression": // We respond after 20-120 ms if the query is truncated. boolean iAmTheOnlyOne = true; for (Enumeration e = in.questions.elements(); e.hasMoreElements(); ) { DNSEntry entry = (DNSEntry) e.nextElement(); if (entry instanceof DNSQuestion) { DNSQuestion q = (DNSQuestion) entry; iAmTheOnlyOne &= (q.type == DNSConstants.TYPE_SRV || q.type == DNSConstants.TYPE_TXT || q.type == DNSConstants.TYPE_A || host.name.equalsIgnoreCase(q.name) || services.containsKey(q.name.toLowerCase())); if (! iAmTheOnlyOne) { break; } } } int delay = (iAmTheOnlyOne && ! in.isTruncated()) ? 0 : DNSConstants.RESPONSE_MIN_WAIT_INTERVAL + random.nextInt(DNSConstants.RESPONSE_MAX_WAIT_INTERVAL - DNSConstants.RESPONSE_MIN_WAIT_INTERVAL + 1); if (debug > 2) System.out.println("JmDNS.Responder chosen delay="+delay); timer.schedule(this, delay); } | 6848 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/6848/1e6f2e54fd57e639586c692aad031141bd691734/JmDNS.java/buggy/jmdns/src/javax/jmdns/JmDNS.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
540,
1071,
918,
787,
1435,
288,
5411,
368,
12848,
4643,
358,
12246,
17,
343,
4607,
577,
17,
5176,
307,
15239,
17,
5421,
12544,
14926,
18,
5830,
5411,
368,
23580,
315,
28,
25019,
310,
6877,
541... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
540,
1071,
918,
787,
1435,
288,
5411,
368,
12848,
4643,
358,
12246,
17,
343,
4607,
577,
17,
5176,
307,
15239,
17,
5421,
12544,
14926,
18,
5830,
5411,
368,
23580,
315,
28,
25019,
310,
6877,
541... |
som.addAtomContainer(new org.openscience.cdk.AtomContainer()); som.addAtomContainer(new org.openscience.cdk.AtomContainer()); | som.addAtomContainer(builder.newAtomContainer()); som.addAtomContainer(builder.newAtomContainer()); | public void testAddAtomContainer_AtomContainer() { SetOfAtomContainers som = new SetOfAtomContainers(); som.addAtomContainer(new org.openscience.cdk.AtomContainer()); som.addAtomContainer(new org.openscience.cdk.AtomContainer()); som.addAtomContainer(new org.openscience.cdk.AtomContainer()); som.addAtomContainer(new org.openscience.cdk.AtomContainer()); som.addAtomContainer(new org.openscience.cdk.AtomContainer()); assertEquals(5, som.getAtomContainerCount()); // now test it to make sure it properly grows the array som.addAtomContainer(new org.openscience.cdk.AtomContainer()); som.addAtomContainer(new org.openscience.cdk.AtomContainer()); assertEquals(7, som.getAtomContainerCount()); } | 1306 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1306/67261c8143759a6ee4feb79dc1687d6dcfa25f40/SetOfAtomContainersTest.java/clean/src/org/openscience/cdk/test/SetOfAtomContainersTest.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1842,
986,
3641,
2170,
67,
3641,
2170,
1435,
288,
3639,
1000,
951,
3641,
11177,
4737,
273,
394,
1000,
951,
3641,
11177,
5621,
3639,
4737,
18,
1289,
3641,
2170,
12,
2704,
2358,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1842,
986,
3641,
2170,
67,
3641,
2170,
1435,
288,
3639,
1000,
951,
3641,
11177,
4737,
273,
394,
1000,
951,
3641,
11177,
5621,
3639,
4737,
18,
1289,
3641,
2170,
12,
2704,
2358,
... |
parser.parse(getInputStream(document), createNodeOffsetHandler(this)); | parser.parse(getInputStream(document), createDocumentHandler(this, false)); | public void adjustOffsets(IDocument document) { try { SAXParserWrapper parser = new SAXParserWrapper(); parser.parse(getInputStream(document), createNodeOffsetHandler(this)); } catch (SAXException e) { } catch (IOException e) { } catch (ParserConfigurationException e) { } catch (FactoryConfigurationError e) { } } | 8783 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/8783/5f54aeb0c6b0dedbd16348f38c2089aa976e950f/XMLEditingModel.java/buggy/ui/org.eclipse.pde.core/text/org/eclipse/pde/internal/core/text/XMLEditingModel.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
5765,
13830,
12,
734,
504,
650,
1668,
13,
288,
202,
202,
698,
288,
1082,
202,
55,
2501,
2678,
3611,
2082,
273,
394,
10168,
2678,
3611,
5621,
1082,
202,
4288,
18,
2670,
12... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
5765,
13830,
12,
734,
504,
650,
1668,
13,
288,
202,
202,
698,
288,
1082,
202,
55,
2501,
2678,
3611,
2082,
273,
394,
10168,
2678,
3611,
5621,
1082,
202,
4288,
18,
2670,
12... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.