rem stringlengths 1 53.3k | add stringlengths 0 80.5k | context stringlengths 6 326k | meta stringlengths 141 403 | input_ids list | attention_mask list | labels list |
|---|---|---|---|---|---|---|
_sysTrayMenu.addItem(_itemSelectBrowser); | private void createSysTrayMenu() {// _itemShutdown.addSysTrayMenuListener(this); _itemSelectBrowser.addSysTrayMenuListener(this); _itemOpenConsole.addSysTrayMenuListener(this);// _sysTrayMenu.addItem(_itemShutdown);// _sysTrayMenu.addSeparator(); _sysTrayMenu.addItem(_itemSelectBrowser); _sysTrayMenu.addItem(_itemOpenConsole); refreshDisplay(); } | 27437 /local/tlutelli/issta_data/temp/all_java2context/java/2006_temp/2006/27437/c5aab8c75076dd9fddf68e3cabf21a71dcec310f/SysTray.java/buggy/apps/systray/java/src/net/i2p/apps/systray/SysTray.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
918,
752,
12712,
56,
435,
4599,
1435,
288,
759,
3639,
389,
1726,
10961,
18,
1289,
12712,
56,
435,
4599,
2223,
12,
2211,
1769,
3639,
389,
1726,
3391,
9132,
18,
1289,
12712,
56,
435,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
12712,
56,
435,
4599,
1435,
288,
759,
3639,
389,
1726,
10961,
18,
1289,
12712,
56,
435,
4599,
2223,
12,
2211,
1769,
3639,
389,
1726,
3391,
9132,
18,
1289,
12712,
56,
435,
... | |
return false; | if (nativeRequest != null) return nativeRequest.isPortletModeAllowed(portletMode); else return false; | public boolean isPortletModeAllowed(PortletMode portletMode) { return false;//TODO } | 51410 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/51410/b447ea4ac6670702574a1b3dc4d87ec4234e84f5/ExternalContextToPortletRenderRequestWrapper.java/buggy/src/java/org/orbeon/oxf/externalcontext/ExternalContextToPortletRenderRequestWrapper.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
1250,
353,
18566,
2309,
5042,
12,
18566,
2309,
13114,
2309,
13,
288,
3639,
327,
629,
31,
759,
6241,
565,
289,
2,
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,
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... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
1250,
353,
18566,
2309,
5042,
12,
18566,
2309,
13114,
2309,
13,
288,
3639,
327,
629,
31,
759,
6241,
565,
289,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
readDefault((String) data); | setRadioGroupIdentifier((String) data); setValue(Boolean.FALSE); setShouldPersist(true); | public final void setInitializationData( final IConfigurationElement configurationElement, final String propertyName, final Object data) { if (data instanceof String) { // This is the default value. readDefault((String) data); } else if (data instanceof Hashtable) { final Hashtable parameters = (Hashtable) data; final Object defaultObject = parameters.get("default"); //$NON-NLS-1$ if (defaultObject instanceof String) { readDefault((String) defaultObject); } final Object persistedObject = parameters.get("persisted"); //$NON-NLS-1$ if (persistedObject instanceof String) { readPersisted((String) persistedObject); } final Object idObject = parameters.get("id"); //$NON-NLS-1$ if (idObject instanceof String) { setRadioGroupIdentifier((String) idObject); } } } | 57470 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/57470/1af9c0f54ba5d8bc847aa6afdd3dc87c3d526d9d/RegistryRadioState.java/clean/bundles/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/handlers/RegistryRadioState.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
727,
918,
444,
17701,
751,
12,
1082,
202,
6385,
467,
1750,
1046,
1664,
1046,
16,
1082,
202,
6385,
514,
5470,
16,
727,
1033,
501,
13,
288,
202,
202,
430,
261,
892,
1276,
514,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
727,
918,
444,
17701,
751,
12,
1082,
202,
6385,
467,
1750,
1046,
1664,
1046,
16,
1082,
202,
6385,
514,
5470,
16,
727,
1033,
501,
13,
288,
202,
202,
430,
261,
892,
1276,
514,
... |
public org.quickfix.field.UnderlyingEndValue getUnderlyingEndValue() throws FieldNotFound { org.quickfix.field.UnderlyingEndValue value = new org.quickfix.field.UnderlyingEndValue(); | public quickfix.field.UnderlyingEndValue getUnderlyingEndValue() throws FieldNotFound { quickfix.field.UnderlyingEndValue value = new quickfix.field.UnderlyingEndValue(); | public org.quickfix.field.UnderlyingEndValue getUnderlyingEndValue() throws FieldNotFound { org.quickfix.field.UnderlyingEndValue value = new org.quickfix.field.UnderlyingEndValue(); getField(value); return value; } | 8803 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/8803/fecc27f98261270772ff182a1d4dfd94b5daa73d/SecurityStatusRequest.java/clean/src/java/src/quickfix/fix44/SecurityStatusRequest.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
2358,
18,
19525,
904,
18,
1518,
18,
14655,
6291,
1638,
620,
10833,
765,
6291,
1638,
620,
1435,
1216,
2286,
2768,
225,
288,
2358,
18,
19525,
904,
18,
1518,
18,
14655,
6291,
1638,
620... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1638,
620,
10833,
765,
6291,
1638,
620,
1435,
1216,
2286,
2768,
225,
288,
2358,
18,
19525,
904,
18,
1518,
18,
14655,
6291,
1638,
620... |
public static void expandSysCall(OPT_Instruction s, OPT_IR ir) { OPT_RegisterOperand ip = null; OPT_RegisterOperand t1 = OPT_ConvertToLowLevelIR.getStatic(s, ir, VM_Entrypoints.the_boot_recordField); OPT_RegisterOperand toc = OPT_ConvertToLowLevelIR.getField(s, ir, t1, VM_Entrypoints.sysTOCField); if (Call.getMethod(s) != null) { OPT_MethodOperand nat = Call.getClearMethod(s); VM_Field target = null; target = nat.getMemberRef().asFieldReference().resolve(); ip = OPT_ConvertToLowLevelIR.getField(s, ir, t1.copyRO(), target); } else { ip = (OPT_RegisterOperand)Call.getClearAddress(s); } /* compute the parameter space */ int numberParams = Call.getNumberOfParams(s); //-#if RVM_FOR_32_ADDR int parameterWords = 0; for (int i = 0; i < numberParams; i++) { parameterWords++; OPT_Operand op = Call.getParam(s, i); if (op instanceof OPT_RegisterOperand) { OPT_RegisterOperand reg = (OPT_RegisterOperand)op; if (reg.type.isLongType() || reg.type.isDoubleType()) parameterWords++; } else if ((op instanceof OPT_LongConstantOperand) || (op instanceof OPT_DoubleConstantOperand)) parameterWords++; } //-#endif //-#if RVM_FOR_64_ADDR int parameterWords = numberParams; //-#endif // see PowerPC Compiler Writer's Guide, pp. 162 ir.stackManager.allocateParameterSpace((6 + parameterWords)*BYTES_IN_ADDRESS); // IMPORTANT WARNING: as the callee C routine may destroy the cmid field // (it is the saved CR field of the callee in C convention) // we are restoring the methodID after a sysCall. OPT_Instruction s2 = Store.create(REF_STORE, ir.regpool.makeJTOCOp(ir,s), ir.regpool.makeFPOp(), I(20), null); // TODO: valid location? s.insertBack(s2); s.insertBack(Move.create(REF_MOVE, ir.regpool.makeJTOCOp(ir,s), toc)); Call.mutate0(s, SYSCALL, Call.getClearResult(s), ip, null); s2 = Load.create(REF_LOAD, ir.regpool.makeJTOCOp(ir,s), ir.regpool.makeFPOp(), I(20), null); // TODO: valid location? s.insertFront(s2); //-#if RVM_FOR_32_ADDR OPT_RegisterOperand temp = ir.regpool.makeTempInt(); s2 = Move.create(REF_MOVE, temp, I(ir.compiledMethod.getId())); //-#endif //-#if RVM_FOR_64_ADDR // KV: to get it stored in the right half: OPT_RegisterOperand temp = ir.regpool.makeTempLong(); s2 = Move.create(REF_MOVE, temp, LC(ir.compiledMethod.getId())); //-#endif OPT_Instruction s3 = Store.create(REF_STORE, temp.copy(), ir.regpool.makeFPOp(), I(STACKFRAME_METHOD_ID_OFFSET), null); // TODO: valid location? s.insertFront(s3); s.insertFront(s2); } | 4011 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/4011/2ef84c5520ea1004653ddee7480c87295d624ab0/OPT_CallingConvention.java/clean/rvm/src/vm/arch/powerPC/compilers/optimizing/regalloc/OPT_CallingConvention.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1071,
3845,
90,
11359,
561,
84,
464,
12712,
1477,
12,
15620,
67,
26712,
16,
15620,
67,
7937,
481,
15329,
15620,
67,
3996,
10265,
625,
33,
2011,
31,
15620,
67,
3996,
10265,
88,
21,
33,
15620,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
3845,
90,
11359,
561,
84,
464,
12712,
1477,
12,
15620,
67,
26712,
16,
15620,
67,
7937,
481,
15329,
15620,
67,
3996,
10265,
625,
33,
2011,
31,
15620,
67,
3996,
10265,
88,
21,
33,
15620,
... | ||
leftBounds.width = (int)(ratio * bounds.width); | leftBounds.width = left; rightBounds.width = right; int redistribute = bounds.width - SASH_WIDTH - total; leftBounds.x = bounds.x; leftBounds.width += Math.round(redistribute * wLeft / wTotal); | public void setBounds(Rectangle bounds) { if(!children[0].isVisible()) { children[1].setBounds(bounds); return; } if(!children[1].isVisible()) { children[0].setBounds(bounds); return; } Rectangle leftBounds = new Rectangle(bounds.x,bounds.y,bounds.width,bounds.height); Rectangle rightBounds = new Rectangle(bounds.x,bounds.y,bounds.width,bounds.height); Rectangle sashBounds = new Rectangle(bounds.x,bounds.y,bounds.width,bounds.height); float ratio = getSash().getRatio(); if(getSash().isVertical()) { //Work on x and width leftBounds.width = (int)(ratio * bounds.width); sashBounds.x = leftBounds.x + leftBounds.width; sashBounds.width = SASH_WIDTH; if (children[0].fixedHeight()) { leftBounds.height = children[0].getBounds().height; } rightBounds.x = sashBounds.x + sashBounds.width; rightBounds.width = bounds.width - leftBounds.width - sashBounds.width; if (children[1].fixedHeight()) { rightBounds.height = children[1].getBounds().height; } adjustWidths(bounds, leftBounds, rightBounds, sashBounds); } else { //Work on y and height if (children[0].fixedHeight()) { leftBounds.height = children[0].getBounds().height; } else { if (children[1].fixedHeight()) { leftBounds.height = bounds.height - children[1].getBounds().height - SASH_WIDTH; } else { leftBounds.height = (int)(ratio * bounds.height); } } sashBounds.y = leftBounds.y + leftBounds.height; sashBounds.height = SASH_WIDTH; rightBounds.y = sashBounds.y + sashBounds.height; if (children[1].fixedHeight()) { rightBounds.height = children[1].getBounds().height; } else { rightBounds.height = bounds.height - leftBounds.height - sashBounds.height; } adjustHeights(bounds, leftBounds, rightBounds, sashBounds); } getSash().setBounds(sashBounds); children[0].setBounds(leftBounds); children[1].setBounds(rightBounds);} | 55805 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/55805/9e4080d1657cb20809aedbb9d365ce2539cd459a/LayoutTreeNode.java/clean/bundles/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal/LayoutTreeNode.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1071,
918,
444,
5694,
12,
19463,
4972,
13,
288,
202,
430,
12,
5,
5906,
63,
20,
8009,
291,
6207,
10756,
288,
202,
202,
5906,
63,
21,
8009,
542,
5694,
12,
10576,
1769,
202,
202,
2463,
31,
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,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1071,
918,
444,
5694,
12,
19463,
4972,
13,
288,
202,
430,
12,
5,
5906,
63,
20,
8009,
291,
6207,
10756,
288,
202,
202,
5906,
63,
21,
8009,
542,
5694,
12,
10576,
1769,
202,
202,
2463,
31,
20... |
HttpServletResponse response = (HttpServletResponse)this.pageContext.getResponse(); | private GroovyObject getTagLib(String tagName) { if(this.application == null) initPageState(); HttpServletRequest request = (HttpServletRequest)this.pageContext.getRequest(); HttpServletResponse response = (HttpServletResponse)this.pageContext.getResponse(); Map tagLibs = (Map)pageContext.getAttribute(TAG_LIBS_ATTRIBUTE); if(tagLibs == null) { tagLibs = new HashMap(); pageContext.setAttribute(TAG_LIBS_ATTRIBUTE, tagLibs); } GrailsTagLibClass tagLibClass = application.getTagLibClassForTag(tagName); GroovyObject tagLib; if(tagLibs.containsKey(tagLibClass.getFullName())) { tagLib = (GroovyObject)tagLibs.get(tagLibClass.getFullName()); } else { tagLib = (GroovyObject)appContext.getBean(tagLibClass.getFullName()); try { new TagLibDynamicMethods(tagLib,grailsAttributes.getController(request)); } catch (IntrospectionException e) { throw new GrailsTagException("Error instantiating taglib ["+tagLibClass.getFullName()+"]: " + e.getMessage(),e); } tagLibs.put(tagLibClass.getFullName(),tagLib); } return tagLib; } | 55385 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/55385/e529b589e53240f9f957bcd808e22e4da8cc16c6/JspInvokeGrailsTagLibTag.java/clean/src/web/org/codehaus/groovy/grails/web/taglib/jsp/JspInvokeGrailsTagLibTag.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
20841,
921,
11362,
5664,
12,
780,
7196,
13,
288,
3639,
309,
12,
2211,
18,
3685,
422,
446,
13,
5411,
1208,
1964,
1119,
5621,
3639,
9984,
590,
273,
261,
2940,
18572,
13,
2211,
18,
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,
3238,
20841,
921,
11362,
5664,
12,
780,
7196,
13,
288,
3639,
309,
12,
2211,
18,
3685,
422,
446,
13,
5411,
1208,
1964,
1119,
5621,
3639,
9984,
590,
273,
261,
2940,
18572,
13,
2211,
18,
2... | |
PK11InternalCert(byte[] certPtr, byte[] slotPtr) { super(certPtr, slotPtr); | PK11InternalCert(byte[] certPtr, byte[] slotPtr, String nickname) { super(certPtr, slotPtr, nickname); | PK11InternalCert(byte[] certPtr, byte[] slotPtr) { super(certPtr, slotPtr); } | 47609 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/47609/a08b14e07e5b5bc1d8847f673cc9a514ea2775cd/PK11InternalCert.java/buggy/security/jss/org/mozilla/jss/pkcs11/PK11InternalCert.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
11327,
2499,
3061,
5461,
12,
7229,
8526,
3320,
5263,
16,
1160,
8526,
4694,
5263,
13,
288,
3639,
2240,
12,
7593,
5263,
16,
4694,
5263,
1769,
565,
289,
2,
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,
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... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
11327,
2499,
3061,
5461,
12,
7229,
8526,
3320,
5263,
16,
1160,
8526,
4694,
5263,
13,
288,
3639,
2240,
12,
7593,
5263,
16,
4694,
5263,
1769,
565,
289,
2,
-100,
-100,
-100,
-100,
-100,
-100... |
if (featAutos == null) { final List<String> ret = Collections.emptyList(); return Collections.unmodifiableList(ret); | List<String> returnList = new ArrayList<String>(); if (featAutos != null) { for (LevelProperty<String> autoFeat : featAutos) { if (autoFeat.getLevel() <= level) { returnList.add(autoFeat.getObject()); } } | public final Collection<String> getFeatAutos() { if (featAutos == null) { final List<String> ret = Collections.emptyList(); return Collections.unmodifiableList(ret); } return Collections.unmodifiableList(featAutos); } | 48301 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/48301/cc414c372c7503968a595d31613b89fb2950a441/PCClass.java/buggy/code/src/java/pcgen/core/PCClass.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
727,
2200,
32,
780,
34,
13683,
270,
21023,
1435,
288,
202,
202,
430,
261,
29735,
21023,
422,
446,
13,
288,
1082,
202,
6385,
987,
32,
780,
34,
325,
273,
5737,
18,
5531,
682,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
727,
2200,
32,
780,
34,
13683,
270,
21023,
1435,
288,
202,
202,
430,
261,
29735,
21023,
422,
446,
13,
288,
1082,
202,
6385,
987,
32,
780,
34,
325,
273,
5737,
18,
5531,
682,
... |
public Container init(Invoke remoteRef) { if (remoteThis == null && remoteRef instanceof Remote) { remoteThis = (Remote)remoteRef; | public Container init(Remote remoteRef) { if (remoteThis == null) { remoteThis = remoteRef; | public Container init(Invoke remoteRef) { if (remoteThis == null && remoteRef instanceof Remote) { remoteThis = (Remote)remoteRef; if (bundle != null) { java.util.ResourceBundle rb = java.util.ResourceBundle.getBundle(bundle); for (int i = 0; i < strings.length; i++) { try { strings[i] = rb.getString(strings[i]); } catch (java.util.MissingResourceException e) { strings[i] = e.getLocalizedMessage(); } } } thread = new Thread(runnable); thread.start(); } return container; } | 45303 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/45303/3b9f47df383c839690a538b3733a82dc2a5f4777/BaseProxy.java/buggy/javanet/gnu/cajo/utils/BaseProxy.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
565,
1071,
4039,
1208,
12,
10969,
2632,
1957,
13,
288,
1377,
309,
261,
7222,
2503,
422,
446,
597,
2632,
1957,
1276,
6304,
13,
288,
540,
2632,
2503,
273,
261,
5169,
13,
7222,
1957,
31,
540,
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,
565,
1071,
4039,
1208,
12,
10969,
2632,
1957,
13,
288,
1377,
309,
261,
7222,
2503,
422,
446,
597,
2632,
1957,
1276,
6304,
13,
288,
540,
2632,
2503,
273,
261,
5169,
13,
7222,
1957,
31,
540,
3... |
for(int j = 0; j < extendsElements.length; j++){ final PsiJavaCodeReferenceElement testImplementElement = extendsElements[j]; | for(final PsiJavaCodeReferenceElement testImplementElement : extendsElements){ | private void checkExtendedInterface(PsiClass implementedClass, PsiJavaCodeReferenceElement implementsElement, PsiJavaCodeReferenceElement[] extendsElements){ for(int j = 0; j < extendsElements.length; j++){ final PsiJavaCodeReferenceElement testImplementElement = extendsElements[j]; if(!testImplementElement.equals(implementsElement)){ final PsiElement implementsReferent = testImplementElement.resolve(); if(implementsReferent != null && implementsReferent instanceof PsiClass){ final PsiClass testImplementedClass = (PsiClass) implementsReferent; if(testImplementedClass.isInheritor(implementedClass, true)){ registerError(implementsElement); return; } } } } } | 56598 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/56598/2d46d291193579a7564649b4881c7ea8e02eda5b/RedundantImplementsInspection.java/clean/plugins/InspectionGadgets/src/com/siyeh/ig/verbose/RedundantImplementsInspection.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
540,
3238,
918,
866,
11456,
1358,
12,
52,
7722,
797,
8249,
797,
16,
4766,
5411,
453,
7722,
5852,
1085,
2404,
1046,
4792,
1046,
16,
4766,
5411,
453,
7722,
5852,
1085,
2404,
1046,
8526,
3231,
34... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
3238,
918,
866,
11456,
1358,
12,
52,
7722,
797,
8249,
797,
16,
4766,
5411,
453,
7722,
5852,
1085,
2404,
1046,
4792,
1046,
16,
4766,
5411,
453,
7722,
5852,
1085,
2404,
1046,
8526,
3231,
34... |
if (! (data[0] instanceof java.util.AbstractList)) { throw new PainterException("aload: wrong arguments"); | catch (EmptyStackException e) { throw new PainterException("Dictionary stack is empty"); | public void execute(PAContext context) throws PainterException { Object[] data; java.util.AbstractList list; data = context.popOperands(1); if (data[0] instanceof PAToken) { data[0] = ( (PAToken) data[0]).value; } if (! (data[0] instanceof java.util.AbstractList)) { throw new PainterException("aload: wrong arguments"); } list = (java.util.AbstractList) data[0]; Iterator iterator = list.iterator(); while (iterator.hasNext()) { context.operands.push(iterator.next()); } context.operands.push(data[0]); } | 3011 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/3011/3cd4a973dbdca1f7072d8e189d388c5a878cc9a6/PAContext.java/buggy/itext/src/com/lowagie/text/pdf/codec/postscript/PAContext.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
4202,
1071,
918,
1836,
12,
4066,
1042,
819,
13,
1216,
453,
11606,
503,
288,
3639,
1033,
8526,
501,
31,
3639,
2252,
18,
1367,
18,
7469,
682,
666,
31,
3639,
501,
273,
819,
18,
5120,
3542,
5708... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
4202,
1071,
918,
1836,
12,
4066,
1042,
819,
13,
1216,
453,
11606,
503,
288,
3639,
1033,
8526,
501,
31,
3639,
2252,
18,
1367,
18,
7469,
682,
666,
31,
3639,
501,
273,
819,
18,
5120,
3542,
5708... |
if (line.length == 0 && meta.stopOnEmpty()) | if (isLineEmpty(line) && meta.stopOnEmpty()) | public Row getRowFromWorkbooks() { // This procedure outputs a single Excel data row on the destination // rowsets... Row retval = new Row(); retval.setIgnore(); try { // First, see if a file has been opened? if (data.workbook == null) { // Open a new workbook.. data.file = data.files.getFile(data.filenr); data.filename = data.file.getPath(); ResultFile resultFile = new ResultFile(ResultFile.FILE_TYPE_GENERAL, data.file, getTransMeta().getName(), toString()); resultFile.setComment("File was read by an Excel input step"); addResultFile(resultFile); if (log.isDetailed()) logDetailed("Opening workbook #" + data.filenr + " : " + data.filename); data.workbook = Workbook.getWorkbook(data.file); data.errorHandler.handleFile(data.file); // Start at the first sheet again... data.sheetnr = 0; } boolean nextsheet = false; // What sheet were we handling? if (log.isDetailed()) logDetailed("Get sheet #" + data.filenr + "." + data.sheetnr); String sheetName = meta.getSheetName()[data.sheetnr]; Sheet sheet = data.workbook.getSheet(sheetName); if (sheet != null) { // at what row do we continue reading? if (data.rownr < 0) { data.rownr = meta.getStartRow()[data.sheetnr]; // Add an extra row if we have a header row to skip... if (meta.startsWithHeader()) { data.rownr++; } } // Start at the specified column data.colnr = meta.getStartColumn()[data.sheetnr]; // Build a new row and fill in the data from the sheet... try { Cell line[] = sheet.getRow(data.rownr); // Already increase cursor 1 row int lineNr = ++data.rownr; // Excel starts counting at 0 if (!data.filePlayList.isProcessingNeeded(data.file, lineNr, sheetName)) { retval.setIgnore(); } else { if (log.isRowLevel()) logRowlevel("Get line #" + lineNr + " from sheet #" + data.filenr + "." + data.sheetnr); if (log.isRowLevel()) logRowlevel("Read line with " + line.length + " cells"); ExcelInputRow excelInputRow = new ExcelInputRow(sheet.getName(), lineNr, line); Row r = fillRow(data.row, data.colnr, excelInputRow); if (log.isRowLevel()) logRowlevel("Converted line to row #" + lineNr + " : " + r); if (line.length > 0 || !meta.ignoreEmptyRows()) { // Put the row retval = r; } if (line.length == 0 && meta.stopOnEmpty()) { nextsheet = true; } } } catch (ArrayIndexOutOfBoundsException e) { if (log.isRowLevel()) logRowlevel("Out of index error: move to next sheet!"); // We tried to read below the last line in the sheet. // Go to the next sheet... nextsheet = true; } } else { nextsheet = true; } if (nextsheet) { // Go to the next sheet data.sheetnr++; // Reset the start-row: data.rownr = -1; // no previous row yet, don't take it from the previous sheet! // (that whould be plain wrong!) data.previousRow = null; // Perhaps it was the last sheet? if (data.sheetnr >= meta.getSheetName().length) { jumpToNextFile(); } } } catch (Exception e) { logError("Error processing row from Excel file [" + data.filename + "] : " + e.toString()); setErrors(1); stopAll(); return null; } return retval; } | 9547 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/9547/8f5cb9af72a47472eb2a610f665be4a19aa1aef4/ExcelInput.java/buggy/src/be/ibridge/kettle/trans/step/excelinput/ExcelInput.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
6556,
11835,
1265,
2421,
12567,
1435,
202,
95,
202,
202,
759,
1220,
12131,
6729,
279,
2202,
17674,
501,
1027,
603,
326,
2929,
202,
202,
759,
1027,
4424,
2777,
202,
202,
1999,
52... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
6556,
11835,
1265,
2421,
12567,
1435,
202,
95,
202,
202,
759,
1220,
12131,
6729,
279,
2202,
17674,
501,
1027,
603,
326,
2929,
202,
202,
759,
1027,
4424,
2777,
202,
202,
1999,
52... |
error ("Illegal character(':') in notation name ", nname, null); requireWhitespace (); | { error("Illegal character(':') in notation name ", nname, null); } requireWhitespace(); | private void parseNotationDecl () throws Exception { String nname, ids[]; requireWhitespace (); nname = readNmtoken (true); //NE08 if (nname.indexOf(':') >= 0) error ("Illegal character(':') in notation name ", nname, null); requireWhitespace (); // Read the external identifiers. ids = readExternalIds (true, false); // Register the notation. setNotation (nname, ids); skipWhitespace (); require ('>'); } | 50763 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50763/24330cfb4cc445da21a71a819ce54efe764fab6e/XmlParser.java/buggy/core/src/classpath/gnu/gnu/xml/aelfred2/XmlParser.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
918,
1109,
14818,
3456,
1832,
565,
1216,
1185,
565,
288,
202,
780,
290,
529,
16,
3258,
8526,
31,
202,
6528,
9431,
261,
1769,
202,
82,
529,
273,
855,
50,
1010,
969,
261,
3767,
1769... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1109,
14818,
3456,
1832,
565,
1216,
1185,
565,
288,
202,
780,
290,
529,
16,
3258,
8526,
31,
202,
6528,
9431,
261,
1769,
202,
82,
529,
273,
855,
50,
1010,
969,
261,
3767,
1769... |
UIDefaults defaults = UIManager.getLookAndFeelDefaults(); menuItem.setBackground(defaults.getColor("MenuItem.background")); menuItem.setBorder(defaults.getBorder("MenuItem.border")); menuItem.setFont(defaults.getFont("MenuItem.font")); menuItem.setForeground(defaults.getColor("MenuItem.foreground")); menuItem.setMargin(defaults.getInsets("MenuItem.margin")); menuItem.setOpaque(true); acceleratorFont = defaults.getFont("MenuItem.acceleratorFont"); acceleratorForeground = defaults.getColor("MenuItem.acceleratorForeground"); acceleratorSelectionForeground = defaults.getColor("MenuItem.acceleratorSelectionForeground"); selectionBackground = defaults.getColor("MenuItem.selectionBackground"); selectionForeground = defaults.getColor("MenuItem.selectionForeground"); acceleratorDelimiter = defaults.getString("MenuItem.acceleratorDelimiter"); | LookAndFeel.installBorder(menuItem, "MenuItem.border"); LookAndFeel.installColorsAndFont(menuItem, "MenuItem.background", "MenuItem.foreground", "MenuItem.font"); menuItem.setMargin(UIManager.getInsets("MenuItem.margin")); acceleratorFont = UIManager.getFont("MenuItem.acceleratorFont"); acceleratorForeground = UIManager.getColor("MenuItem.acceleratorForeground"); acceleratorSelectionForeground = UIManager.getColor("MenuItem.acceleratorSelectionForeground"); selectionBackground = UIManager.getColor("MenuItem.selectionBackground"); selectionForeground = UIManager.getColor("MenuItem.selectionForeground"); acceleratorDelimiter = UIManager.getString("MenuItem.acceleratorDelimiter"); | protected void installDefaults() { UIDefaults defaults = UIManager.getLookAndFeelDefaults(); menuItem.setBackground(defaults.getColor("MenuItem.background")); menuItem.setBorder(defaults.getBorder("MenuItem.border")); menuItem.setFont(defaults.getFont("MenuItem.font")); menuItem.setForeground(defaults.getColor("MenuItem.foreground")); menuItem.setMargin(defaults.getInsets("MenuItem.margin")); menuItem.setOpaque(true); acceleratorFont = defaults.getFont("MenuItem.acceleratorFont"); acceleratorForeground = defaults.getColor("MenuItem.acceleratorForeground"); acceleratorSelectionForeground = defaults.getColor("MenuItem.acceleratorSelectionForeground"); selectionBackground = defaults.getColor("MenuItem.selectionBackground"); selectionForeground = defaults.getColor("MenuItem.selectionForeground"); acceleratorDelimiter = defaults.getString("MenuItem.acceleratorDelimiter"); menuItem.setHorizontalTextPosition(SwingConstants.TRAILING); menuItem.setHorizontalAlignment(SwingConstants.LEADING); } | 1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/ae9ec43c5570a0f69e3d8c8b733283719f52a770/BasicMenuItemUI.java/buggy/core/src/classpath/javax/javax/swing/plaf/basic/BasicMenuItemUI.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
4750,
918,
3799,
7019,
1435,
225,
288,
565,
10034,
73,
643,
87,
3467,
273,
6484,
1318,
18,
588,
9794,
1876,
2954,
292,
7019,
5621,
565,
19711,
18,
542,
8199,
12,
7606,
18,
588,
2957,
29... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
918,
3799,
7019,
1435,
225,
288,
565,
10034,
73,
643,
87,
3467,
273,
6484,
1318,
18,
588,
9794,
1876,
2954,
292,
7019,
5621,
565,
19711,
18,
542,
8199,
12,
7606,
18,
588,
2957,
29... |
logger.debug( "Hand over Command EasyMock for interface java.lang.Runnable to pool \"mypool\" with delay=100 and interval=0" ); | logger.debug( "Executing command EasyMock for interface java.lang.Runnable in pool \"mypool\", schedule with interval=0" ); | public final void testExecuteStringRunnablelong( ) { final MockControl mainConfigControl = createStrictControl( Configuration.class ); final Configuration mainConfig = (Configuration)mainConfigControl.getMock( ); mainConfigControl.expectAndReturn( mainConfig.getChild( "thread-factory" ), createValueConfigMock( DefaultRunnableManager.DEFAULT_THREAD_FACTORY, DefaultRunnableManager.DEFAULT_THREAD_FACTORY ) ); mainConfigControl.expectAndReturn( mainConfig.getChild( "thread-pools" ), createChildrenConfigMock( "thread-pool", new Configuration[ 0 ] ) ); mainConfigControl.replay( ); final MockControl childLoggerDefaultControl = createStrictControl( Logger.class ); final Logger childLoggerDefault = (Logger)childLoggerDefaultControl.getMock( ); childLoggerDefaultControl.expectAndReturn( childLoggerDefault.isDebugEnabled( ), true ); childLoggerDefault.debug( "Executing Command: org.apache.cocoon.components.thread.DefaultRunnableManager" ); childLoggerDefaultControl.setMatcher( MockControl.ALWAYS_MATCHER ); childLoggerDefaultControl.replay( ); final MockControl childLoggerMyPoolControl = createStrictControl( Logger.class ); final Logger childLoggerMyPool = (Logger)childLoggerMyPoolControl.getMock( ); childLoggerMyPoolControl.expectAndReturn( childLoggerMyPool.isDebugEnabled( ), true ); childLoggerMyPool.debug( "Executing Command: EasyMock for interface java.lang.Runnable,pool=mypool" ); childLoggerMyPoolControl.replay( ); final MockControl loggerControl = createStrictControl( Logger.class ); final Logger logger = (Logger)loggerControl.getMock( ); loggerControl.expectAndReturn( logger.getChildLogger( "default" ), childLoggerDefault ); loggerControl.expectAndReturn( logger.isInfoEnabled( ), true ); logger.info( "ThreadPool named \"default\" created with maximum queue-size=2147483647,max-pool-size=5,min-pool-size=5,priority=5,isDaemon=false,keep-alive-time-ms=60000,block-policy=\"RUN\",shutdown-wait-time-ms=-1" ); loggerControl.expectAndReturn( logger.isDebugEnabled( ), true ); logger.debug( "starting heart" ); loggerControl.expectAndReturn( logger.isDebugEnabled( ), true ); logger.debug( "Entering loop" ); loggerControl.expectAndReturn( logger.isDebugEnabled( ), true ); logger.debug( "No commands available. Will just wait for one" ); loggerControl.expectAndReturn( logger.getChildLogger( "mypool" ), childLoggerMyPool ); loggerControl.expectAndReturn( logger.isInfoEnabled( ), true ); logger.info( "ThreadPool named \"mypool\" created with maximum queue-size=230,max-pool-size=15,min-pool-size=12,priority=1,isDaemon=false,keep-alive-time-ms=15500,block-policy=\"DISCARD\",shutdown-wait-time-ms=22200" ); loggerControl.expectAndReturn( logger.isDebugEnabled( ), true ); logger.debug( "Command entered: EasyMock for interface java.lang.Runnable,pool=mypool,delay=100,interval=0" ); loggerControl.expectAndReturn( logger.isDebugEnabled( ), true ); logger.debug( "Hand over Command EasyMock for interface java.lang.Runnable to pool \"mypool\" with delay=100 and interval=0" ); loggerControl.expectAndReturn( logger.isDebugEnabled( ), true ); logger.debug( "No commands available. Will just wait for one" ); loggerControl.expectAndReturn( logger.isDebugEnabled( ), true ); logger.debug( "Exiting loop" ); loggerControl.expectAndReturn( logger.isDebugEnabled( ), true ); logger.debug( "Disposing all thread pools" ); loggerControl.expectAndReturn( logger.isDebugEnabled( ), true ); logger.debug( "Disposing thread pool mypool" ); loggerControl.expectAndReturn( logger.isDebugEnabled( ), true ); logger.debug( "Thread pool mypool disposed" ); loggerControl.expectAndReturn( logger.isDebugEnabled( ), true ); logger.debug( "Disposing thread pool default" ); loggerControl.expectAndReturn( logger.isDebugEnabled( ), true ); logger.debug( "Thread pool default disposed" ); loggerControl.replay( ); final DefaultRunnableManager runnableManager = new DefaultRunnableManager( ); runnableManager.enableLogging( logger ); try { runnableManager.configure( mainConfig ); } catch( final ConfigurationException ce ) { assertTrue( "Throw unexpected ConfigurationException", false ); } final MockControl runnableControl = createStrictControl( Runnable.class ); final Runnable runnable = (Runnable)runnableControl.getMock( ); runnable.run( ); runnableControl.replay( ); try { runnableManager.start( ); Thread.yield( ); Thread.sleep( 20 ); runnableManager.createPool( "mypool", 230, 15, 12, Thread.MIN_PRIORITY, false, 15500, "DISCARD", false, 22200 ); runnableManager.execute( "mypool", runnable, 100, 0 ); Thread.yield( ); Thread.sleep( 200 ); runnableManager.stop( ); Thread.yield( ); Thread.sleep( 20 ); runnableManager.dispose( ); Thread.sleep( 20 ); } catch( final Throwable ex ) { ex.printStackTrace( ); assertTrue( "Unexpected Exception", false ); } verify( ); } | 46428 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/46428/f0f74af4d50bbf3663fb4c99ebd3f794a844926b/DefaultRunnableManagerTestCase.java/clean/src/test/org/apache/cocoon/components/thread/DefaultRunnableManagerTestCase.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
727,
918,
1842,
5289,
780,
1997,
82,
9237,
292,
932,
12,
225,
262,
565,
288,
3639,
727,
7867,
3367,
2774,
809,
3367,
273,
5411,
752,
14809,
3367,
12,
4659,
18,
1106,
11272,
3639,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
727,
918,
1842,
5289,
780,
1997,
82,
9237,
292,
932,
12,
225,
262,
565,
288,
3639,
727,
7867,
3367,
2774,
809,
3367,
273,
5411,
752,
14809,
3367,
12,
4659,
18,
1106,
11272,
3639,
... |
prob *= distributions[z][1]; | probs[i] = distributions[i - 1][1]; | public double [] distributionForInstance(Instance inst) throws Exception { if (m_Classifiers.length == 1) { return ((DistributionClassifier)m_Classifiers[0]) .distributionForInstance(inst); } double [] probs = new double[inst.numClasses()]; double [][] distributions = new double[m_ClassFilters.length][0]; for(int i = 0; i < m_ClassFilters.length; i++) { m_ClassFilters[i].input(inst); m_ClassFilters[i].batchFinished(); distributions[i] = ((DistributionClassifier)m_Classifiers[i]) .distributionForInstance(m_ClassFilters[i].output()); } int z = 0; for (int i = 0; i < inst.numClasses(); i++) { double prob = 1.0; if (i == 0) { prob *= distributions[0][0]; } else if (i == inst.numClasses() - 1) { prob *= distributions[z][1]; } else { prob *= distributions[z][1]; prob *= distributions[z+1][0]; z++; } probs[i] = prob; } // calculate the probability of each vector /*boolean [] bs = new boolean[distributions.length]; int z = 0; for (int i = 0; i < inst.numClasses(); i++) { double prob = 1.0; for (int j = 0; j < distributions.length; j++) { prob *= distributions[j][(bs[j] == true) ? 1 : 0]; } if (z < distributions.length) { bs[z] = true; } probs[z++] = prob; }*/ if (Utils.gr(Utils.sum(probs), 0)) { Utils.normalize(probs); return probs; } else { return m_ZeroR.distributionForInstance(inst); } } | 4773 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/4773/4a859497568491a49044b08f953d7223117183d5/OrdinalClassClassifier.java/buggy/weka/classifiers/OrdinalClassClassifier.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
1645,
5378,
7006,
1290,
1442,
12,
1442,
1804,
13,
1216,
1185,
288,
3639,
309,
261,
81,
67,
10469,
18,
2469,
422,
404,
13,
288,
1377,
327,
14015,
9003,
13860,
13,
81,
67,
10469,
63... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1645,
5378,
7006,
1290,
1442,
12,
1442,
1804,
13,
1216,
1185,
288,
3639,
309,
261,
81,
67,
10469,
18,
2469,
422,
404,
13,
288,
1377,
327,
14015,
9003,
13860,
13,
81,
67,
10469,
63... |
itm.reuse( la ); dMaxW = Math.max( dMaxW, itm.getFullWidth( ) ); dHeight += insCA.getTop( ) + dItemHeight | itm.reuse( la, maxWrappingSize ); dW = itm.getFullWidth( ); dDeltaHeight = insCA.getTop( ) + itm.getFullHeight( ) | public final Size compute( IDisplayServer xs, Chart cm, SeriesDefinition[] seda, RunTimeContext rtc ) throws ChartException { // THREE CASES: // 1. ALL SERIES IN ONE ARRAYLIST // 2. ONE SERIES PER ARRAYLIST // 3. ALL OTHERS Legend lg = cm.getLegend( ); if ( !lg.isSetOrientation( ) ) { throw new ChartException( ChartEnginePlugin.ID, ChartException.GENERATION, "exception.legend.orientation.horzvert", //$NON-NLS-1$ ResourceBundle.getBundle( Messages.ENGINE, xs.getLocale( ) ) ); } if ( !lg.isSetDirection( ) ) { throw new ChartException( ChartEnginePlugin.ID, ChartException.GENERATION, "exception.legend.direction.tblr", //$NON-NLS-1$ ResourceBundle.getBundle( Messages.ENGINE, xs.getLocale( ) ) ); } // INITIALIZATION OF VARS USED IN FOLLOWING LOOPS Orientation o = lg.getOrientation( ); Direction d = lg.getDirection( ); Label la = LabelImpl.create( ); la.setCaption( (Text) EcoreUtil.copy( lg.getText( ) ) ); ClientArea ca = lg.getClientArea( ); LineAttributes lia = ca.getOutline( ); double dSeparatorThickness = lia.getThickness( ); double dWidth = 0, dHeight = 0; la.getCaption( ).setValue( "X" ); //$NON-NLS-1$ final ITextMetrics itm = xs.getTextMetrics( la ); double dItemHeight = itm.getFullHeight( ); Series se; ArrayList al; Insets insCA = ca.getInsets( ) .scaledInstance( xs.getDpiResolution( ) / 72d ); final boolean bPaletteByCategory = ( cm.getLegend( ) .getItemType( ) .getValue( ) == LegendItemType.CATEGORIES ); Series seBase; // Calculate if minSlice applicable. boolean bMinSliceDefined = false; double dMinSlice = 0; boolean bPercentageMinSlice = false; String sMinSliceLabel = null; boolean bMinSliceApplied = false; if ( cm instanceof ChartWithoutAxes ) { bMinSliceDefined = ( (ChartWithoutAxes) cm ).isSetMinSlice( ); dMinSlice = ( (ChartWithoutAxes) cm ).getMinSlice( ); bPercentageMinSlice = ( (ChartWithoutAxes) cm ).isMinSlicePercent( ); sMinSliceLabel = ( (ChartWithoutAxes) cm ).getMinSliceLabel( ); if ( sMinSliceLabel == null || sMinSliceLabel.length( ) == 0 ) { sMinSliceLabel = IConstants.UNDEFINED_STRING; } else { sMinSliceLabel = rtc.externalizedMessage( sMinSliceLabel ); } } // calculate if need an extra legend item when minSlice defined. if ( bMinSliceDefined && bPaletteByCategory && cm instanceof ChartWithoutAxes ) { if ( !( (ChartWithoutAxes) cm ).getSeriesDefinitions( ).isEmpty( ) ) { // OK TO ASSUME THAT 1 BASE SERIES DEFINITION EXISTS SeriesDefinition sdBase = (SeriesDefinition) ( (ChartWithoutAxes) cm ).getSeriesDefinitions( ) .get( 0 ); SeriesDefinition[] sdOrtho = (SeriesDefinition[]) sdBase.getSeriesDefinitions( ) .toArray( ); DataSetIterator dsiOrtho = null; double dCurrentMinSlice = 0; for ( int i = 0; i < sdOrtho.length && !bMinSliceApplied; i++ ) { try { dsiOrtho = new DataSetIterator( ( (Series) sdOrtho[i].getRunTimeSeries( ) .get( 0 ) ).getDataSet( ) ); } catch ( Exception ex ) { throw new ChartException( ChartEnginePlugin.ID, ChartException.RENDERING, ex ); } // TODO Check dataSet type, throw exception or ignore?. if ( bPercentageMinSlice ) { double total = 0; while ( dsiOrtho.hasNext( ) ) { Object obj = dsiOrtho.next( ); if ( obj instanceof Number ) { total += ( (Number) obj ).doubleValue( ); } } dsiOrtho.reset( ); dCurrentMinSlice = total * dMinSlice / 100d; } else { dCurrentMinSlice = dMinSlice; } while ( dsiOrtho.hasNext( ) ) { Object obj = dsiOrtho.next( ); if ( obj instanceof Number ) { double val = ( (Number) obj ).doubleValue( ); if ( val < dCurrentMinSlice ) { bMinSliceApplied = true; break; } } } } } } // COMPUTATIONS HERE MUST BE IN SYNC WITH THE ACTUAL RENDERER if ( o.getValue( ) == Orientation.VERTICAL ) { double dW, dMaxW = 0; if ( bPaletteByCategory ) { SeriesDefinition sdBase = null; if ( cm instanceof ChartWithAxes ) { final Axis axPrimaryBase = ( (ChartWithAxes) cm ).getBaseAxes( )[0]; // ONLY // SUPPORT // 1 // BASE // AXIS // FOR // NOW if ( axPrimaryBase.getSeriesDefinitions( ).isEmpty( ) ) { return SizeImpl.create( 0, 0 ); } sdBase = (SeriesDefinition) axPrimaryBase.getSeriesDefinitions( ) .get( 0 ); // OK TO ASSUME THAT 1 BASE SERIES // DEFINITION EXISTS } else if ( cm instanceof ChartWithoutAxes ) { if ( ( (ChartWithoutAxes) cm ).getSeriesDefinitions( ) .isEmpty( ) ) { return SizeImpl.create( 0, 0 ); } sdBase = (SeriesDefinition) ( (ChartWithoutAxes) cm ).getSeriesDefinitions( ) .get( 0 ); // OK TO ASSUME THAT 1 BASE SERIES // DEFINITION EXISTS } seBase = (Series) sdBase.getRunTimeSeries( ).get( 0 ); // OK TO // ASSUME // THAT 1 // BASE // RUNTIME // SERIES // EXISTS DataSetIterator dsiBase = null; try { dsiBase = new DataSetIterator( seBase.getDataSet( ) ); } catch ( Exception ex ) { throw new ChartException( ChartEnginePlugin.ID, ChartException.GENERATION, ex ); } FormatSpecifier fs = null; if ( sdBase != null ) { fs = sdBase.getFormatSpecifier( ); } while ( dsiBase.hasNext( ) ) { // TODO filter the not-used legend. Object obj = dsiBase.next( ); String lgtext = String.valueOf( obj ); if ( fs != null ) { try { lgtext = ValueFormatter.format( obj, fs, Locale.getDefault( ), null ); } catch ( ChartException e ) { // ignore, use original text. } } la.getCaption( ).setValue( lgtext ); itm.reuse( la ); dWidth = Math.max( itm.getFullWidth( ), dWidth ); dHeight += insCA.getTop( ) + itm.getFullHeight( ) + insCA.getBottom( ); } // compute the extra MinSlice legend item if applicable. if ( bMinSliceDefined && bMinSliceApplied ) { la.getCaption( ).setValue( sMinSliceLabel ); itm.reuse( la ); dWidth = Math.max( itm.getFullWidth( ), dWidth ); dHeight += insCA.getTop( ) + itm.getFullHeight( ) + insCA.getBottom( ); } dWidth += insCA.getLeft( ) + ( 3 * dItemHeight ) / 2 + dHorizontalSpacing + insCA.getRight( ); } else if ( d.getValue( ) == Direction.TOP_BOTTOM ) // (VERTICAL => // TB) { dSeparatorThickness += dVerticalSpacing; for ( int j = 0; j < seda.length; j++ ) { al = seda[j].getRunTimeSeries( ); FormatSpecifier fs = seda[j].getFormatSpecifier( ); for ( int i = 0; i < al.size( ); i++ ) { se = (Series) al.get( i ); Object obj = se.getSeriesIdentifier( ); String lgtext = String.valueOf( obj ); if ( fs != null ) { try { lgtext = ValueFormatter.format( obj, fs, Locale.getDefault( ), null ); } catch ( ChartException e ) { // ignore, use original text. } } la.getCaption( ).setValue( lgtext ); itm.reuse( la ); dW = itm.getFullWidth( ); if ( dW > dMaxW ) { dMaxW = dW; } dHeight += insCA.getTop( ) + dItemHeight + insCA.getBottom( ); if ( lg.isShowValue( ) ) { DataSetIterator dsiBase = null; try { dsiBase = new DataSetIterator( se.getDataSet( ) ); } catch ( Exception ex ) { throw new ChartException( ChartEnginePlugin.ID, ChartException.GENERATION, ex ); } // Use first value for each series. if ( dsiBase.hasNext( ) ) { obj = dsiBase.next( ); String valueText = String.valueOf( obj ); if ( fs != null ) { try { lgtext = ValueFormatter.format( obj, fs, Locale.getDefault( ), null ); } catch ( ChartException e ) { // ignore, use original text. } } Label seLabel = (Label) EcoreUtil.copy( se.getLabel( ) ); seLabel.getCaption( ).setValue( valueText ); itm.reuse( seLabel ); dW = itm.getFullWidth( ); if ( dW > dMaxW ) { dMaxW = dW; } dHeight += itm.getFullHeight( ) + 2; } } } // SETUP HORIZONTAL SEPARATOR SPACING if ( j < seda.length - 1 ) { dHeight += dSeparatorThickness; } } // LEFT INSETS + LEGEND ITEM WIDTH + HORIZONTAL SPACING + MAX // ITEM WIDTH + RIGHT INSETS dWidth = insCA.getLeft( ) + ( 3 * dItemHeight ) / 2 + dHorizontalSpacing + dMaxW + insCA.getRight( ); } else if ( d.getValue( ) == Direction.LEFT_RIGHT ) // (VERTICAL => // LR) { double dMaxH = 0; dSeparatorThickness += dHorizontalSpacing; for ( int j = 0; j < seda.length; j++ ) { al = seda[j].getRunTimeSeries( ); FormatSpecifier fs = seda[j].getFormatSpecifier( ); for ( int i = 0; i < al.size( ); i++ ) { se = (Series) al.get( i ); Object obj = se.getSeriesIdentifier( ); String lgtext = String.valueOf( obj ); if ( fs != null ) { try { lgtext = ValueFormatter.format( obj, fs, Locale.getDefault( ), null ); } catch ( ChartException e ) { // ignore, use original text. } } la.getCaption( ).setValue( lgtext ); itm.reuse( la ); dMaxW = Math.max( dMaxW, itm.getFullWidth( ) ); dHeight += insCA.getTop( ) + dItemHeight + insCA.getBottom( ); if ( lg.isShowValue( ) ) { DataSetIterator dsiBase = null; try { dsiBase = new DataSetIterator( se.getDataSet( ) ); } catch ( Exception ex ) { throw new ChartException( ChartEnginePlugin.ID, ChartException.GENERATION, ex ); } // Use first value for each series. if ( dsiBase.hasNext( ) ) { obj = dsiBase.next( ); String valueText = String.valueOf( obj ); if ( fs != null ) { try { lgtext = ValueFormatter.format( obj, fs, Locale.getDefault( ), null ); } catch ( ChartException e ) { // ignore, use original text. } } Label seLabel = (Label) EcoreUtil.copy( se.getLabel( ) ); seLabel.getCaption( ).setValue( valueText ); itm.reuse( seLabel ); dMaxW = Math.max( dMaxW, itm.getFullWidth( ) ); dHeight += itm.getFullHeight( ) + 2; } } } // SETUP VERTICAL SEPARATOR SPACING if ( j < seda.length - 1 ) { dWidth += dSeparatorThickness; } // LEFT INSETS + LEGEND ITEM WIDTH + HORIZONTAL SPACING + // MAX ITEM WIDTH + RIGHT INSETS dWidth += insCA.getLeft( ) + ( 3 * dItemHeight / 2 ) + dHorizontalSpacing + dMaxW + insCA.getRight( ); if ( dHeight > dMaxH ) dMaxH = dHeight; dHeight = 0; dMaxW = 0; } dHeight = dMaxH; } else { throw new ChartException( ChartEnginePlugin.ID, ChartException.GENERATION, "exception.illegal.rendering.direction", //$NON-NLS-1$ new Object[]{ d.getName( ) }, ResourceBundle.getBundle( Messages.ENGINE, xs.getLocale( ) ) ); } } else if ( o.getValue( ) == Orientation.HORIZONTAL ) { if ( bPaletteByCategory ) { SeriesDefinition sdBase = null; if ( cm instanceof ChartWithAxes ) { final Axis axPrimaryBase = ( (ChartWithAxes) cm ).getBaseAxes( )[0]; // ONLY // SUPPORT // 1 // BASE // AXIS // FOR // NOW if ( axPrimaryBase.getSeriesDefinitions( ).isEmpty( ) ) { throw new ChartException( ChartEnginePlugin.ID, ChartException.GENERATION, "exception.base.axis.no.series.definitions", //$NON-NLS-1$ ResourceBundle.getBundle( Messages.ENGINE, xs.getLocale( ) ) ); //$NON-NLS-1$ } sdBase = (SeriesDefinition) axPrimaryBase.getSeriesDefinitions( ) .get( 0 ); // OK TO ASSUME // THAT 1 BASE // SERIES // DEFINITION // EXISTS } else if ( cm instanceof ChartWithoutAxes ) { if ( ( (ChartWithoutAxes) cm ).getSeriesDefinitions( ) .isEmpty( ) ) { throw new ChartException( ChartEnginePlugin.ID, ChartException.GENERATION, "exception.base.axis.no.series.definitions", //$NON-NLS-1$ ResourceBundle.getBundle( Messages.ENGINE, xs.getLocale( ) ) ); } sdBase = (SeriesDefinition) ( (ChartWithoutAxes) cm ).getSeriesDefinitions( ) .get( 0 ); // OK TO ASSUME // THAT 1 BASE // SERIES // DEFINITION // EXISTS } seBase = (Series) sdBase.getRunTimeSeries( ).get( 0 ); // OK TO // ASSUME // THAT 1 // BASE // RUNTIME // SERIES // EXISTS DataSetIterator dsiBase = null; try { dsiBase = new DataSetIterator( seBase.getDataSet( ) ); } catch ( Exception ex ) { throw new ChartException( ChartEnginePlugin.ID, ChartException.GENERATION, ex ); } FormatSpecifier fs = null; if ( sdBase != null ) { fs = sdBase.getFormatSpecifier( ); } double dMaxHeight = 0; while ( dsiBase.hasNext( ) ) { // TODO filter the not-used legend. Object obj = dsiBase.next( ); String lgtext = String.valueOf( obj ); if ( fs != null ) { try { lgtext = ValueFormatter.format( obj, fs, Locale.getDefault( ), null ); } catch ( ChartException e ) { // ignore, use original text. } } la.getCaption( ).setValue( lgtext ); itm.reuse( la ); dMaxHeight = Math.max( itm.getFullHeight( ), dMaxHeight ); dWidth += itm.getFullWidth( ); } // compute the extra MinSlice legend item if applicable. if ( bMinSliceDefined && bMinSliceApplied ) { la.getCaption( ).setValue( sMinSliceLabel ); itm.reuse( la ); dMaxHeight = Math.max( itm.getFullHeight( ), dMaxHeight ); dWidth += itm.getFullWidth( ); } dHeight = insCA.getTop( ) + dMaxHeight + insCA.getBottom( ); dWidth += ( dsiBase.size( ) + ( ( bMinSliceDefined && bMinSliceApplied ) ? 1 : 0 ) ) * ( insCA.getLeft( ) + ( 3 * dItemHeight ) / 2 + dHorizontalSpacing + insCA.getRight( ) ); } else if ( d.getValue( ) == Direction.TOP_BOTTOM ) // (HORIZONTAL // => // TB) { double dMaxW = 0; double tmpHeight = 0; dSeparatorThickness += dVerticalSpacing; for ( int j = 0; j < seda.length; j++ ) { dWidth = 0; al = seda[j].getRunTimeSeries( ); FormatSpecifier fs = seda[j].getFormatSpecifier( ); for ( int i = 0; i < al.size( ); i++ ) { se = (Series) al.get( i ); Object obj = se.getSeriesIdentifier( ); String lgtext = String.valueOf( obj ); if ( fs != null ) { try { lgtext = ValueFormatter.format( obj, fs, Locale.getDefault( ), null ); } catch ( ChartException e ) { // ignore, use original text. } } la.getCaption( ).setValue( lgtext ); itm.reuse( la ); // LEFT INSETS + LEGEND ITEM WIDTH + HORIZONTAL SPACING // + MAX ITEM WIDTH + RIGHT INSETS double tmpWidth = insCA.getLeft( ) + ( 3 * dItemHeight ) / 2 + dHorizontalSpacing + itm.getFullWidth( ) + insCA.getRight( ); if ( lg.isShowValue( ) ) { DataSetIterator dsiBase = null; try { dsiBase = new DataSetIterator( se.getDataSet( ) ); } catch ( Exception ex ) { throw new ChartException( ChartEnginePlugin.ID, ChartException.GENERATION, ex ); } // Use first value for each series. if ( dsiBase.hasNext( ) ) { obj = dsiBase.next( ); String valueText = String.valueOf( obj ); if ( fs != null ) { try { lgtext = ValueFormatter.format( obj, fs, Locale.getDefault( ), null ); } catch ( ChartException e ) { // ignore, use original text. } } Label seLabel = (Label) EcoreUtil.copy( se.getLabel( ) ); seLabel.getCaption( ).setValue( valueText ); itm.reuse( seLabel ); tmpWidth = Math.max( tmpWidth, itm.getFullWidth( ) ); tmpHeight = Math.max( tmpHeight, itm.getFullHeight( ) + 2 ); } } dWidth += tmpWidth; } // SETUP HORIZONTAL SEPARATOR SPACING if ( j < seda.length - 1 ) { dHeight += dSeparatorThickness; } // SET WIDTH TO MAXIMUM ROW WIDTH dMaxW = Math.max( dWidth, dMaxW ); dHeight += insCA.getTop( ) + dItemHeight + insCA.getRight( ) + tmpHeight; } dWidth = dMaxW; } else if ( d.getValue( ) == Direction.LEFT_RIGHT ) // (HORIZONTAL // => // LR) { double tmpHeight = 0; dSeparatorThickness += dHorizontalSpacing; for ( int j = 0; j < seda.length; j++ ) { al = seda[j].getRunTimeSeries( ); FormatSpecifier fs = seda[j].getFormatSpecifier( ); for ( int i = 0; i < al.size( ); i++ ) { se = (Series) al.get( i ); Object obj = se.getSeriesIdentifier( ); String lgtext = String.valueOf( obj ); if ( fs != null ) { try { lgtext = ValueFormatter.format( obj, fs, Locale.getDefault( ), null ); } catch ( ChartException e ) { // ignore, use original text. } } la.getCaption( ).setValue( lgtext ); itm.reuse( la ); // LEFT INSETS + LEGEND ITEM WIDTH + HORIZONTAL SPACING // + MAX ITEM WIDTH + RIGHT INSETS double tmpWidth = insCA.getLeft( ) + ( 3 * dItemHeight ) / 2 + dHorizontalSpacing + itm.getFullWidth( ) + insCA.getRight( ); if ( lg.isShowValue( ) ) { DataSetIterator dsiBase = null; try { dsiBase = new DataSetIterator( se.getDataSet( ) ); } catch ( Exception ex ) { throw new ChartException( ChartEnginePlugin.ID, ChartException.GENERATION, ex ); } // Use first value for each series. if ( dsiBase.hasNext( ) ) { obj = dsiBase.next( ); String valueText = String.valueOf( obj ); if ( fs != null ) { try { lgtext = ValueFormatter.format( obj, fs, Locale.getDefault( ), null ); } catch ( ChartException e ) { // ignore, use original text. } } Label seLabel = (Label) EcoreUtil.copy( se.getLabel( ) ); seLabel.getCaption( ).setValue( valueText ); itm.reuse( seLabel ); tmpWidth = Math.max( tmpWidth, itm.getFullWidth( ) ); tmpHeight = Math.max( tmpHeight, itm.getFullHeight( ) + 2 ); } } dWidth += tmpWidth; } // SETUP VERTICAL SEPARATOR SPACING if ( j < seda.length - 1 ) { dWidth += dSeparatorThickness; } } dHeight = insCA.getTop( ) + dItemHeight + insCA.getRight( ) + tmpHeight; } else { throw new ChartException( ChartEnginePlugin.ID, ChartException.GENERATION, "exception.illegal.rendering.direction", //$NON-NLS-1$ new Object[]{ d }, ResourceBundle.getBundle( Messages.ENGINE, xs.getLocale( ) ) ); } } else { throw new ChartException( ChartEnginePlugin.ID, ChartException.GENERATION, "exception.illegal.rendering.orientation", //$NON-NLS-1$ new Object[]{ o }, ResourceBundle.getBundle( Messages.ENGINE, xs.getLocale( ) ) ); } // consider legend title size. Label lgTitle = lg.getTitle( ); if ( lgTitle != null && lgTitle.isSetVisible( ) && lgTitle.isVisible( ) ) { BoundingBox bb = null; try { bb = Methods.computeBox( xs, IConstants.ABOVE, lgTitle, 0, 0 ); } catch ( IllegalArgumentException uiex ) { throw new ChartException( ChartEnginePlugin.ID, ChartException.RENDERING, uiex ); } switch ( lg.getTitlePosition( ).getValue( ) ) { case Position.ABOVE : case Position.BELOW : dHeight += bb.getHeight( ); dWidth = Math.max( dWidth, bb.getWidth( ) ); break; case Position.LEFT : case Position.RIGHT : dWidth += bb.getWidth( ); dHeight = Math.max( dHeight, bb.getHeight( ) ); break; } } itm.dispose( ); // DISPOSE RESOURCE AFTER USE sz = SizeImpl.create( dWidth, dHeight ); return sz; } | 5230 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5230/2d2a611b1bd993e5b8997aa31f661b8486b93a43/LegendBuilder.java/buggy/chart/org.eclipse.birt.chart.engine/src/org/eclipse/birt/chart/computation/LegendBuilder.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
727,
6321,
3671,
12,
1599,
291,
1601,
2081,
9280,
16,
14804,
5003,
16,
1082,
202,
6485,
1852,
8526,
24336,
69,
16,
1939,
950,
1042,
436,
5111,
262,
1216,
14804,
503,
202,
95,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
727,
6321,
3671,
12,
1599,
291,
1601,
2081,
9280,
16,
14804,
5003,
16,
1082,
202,
6485,
1852,
8526,
24336,
69,
16,
1939,
950,
1042,
436,
5111,
262,
1216,
14804,
503,
202,
95,
... |
source.println("class " + _name + "_Default {"); source.println(" inherit " + | source.println(indent + "class " + _name + "_Default {"); source.println(indent + " inherit " + | public void generateCode(PrintStream header, PrintStream source, String context) throws ParseException { LinkedList definedDefaultTransitions = null; LinkedList transList; ListIterator stateIt; ListIterator transIt; ListIterator paramIt; SmcState state; SmcTransition defaultTransition = new SmcTransitionTcl("Default", new LinkedList(), _line_number); SmcTransition trans; SmcParameter parameter; if (_default_state != null) { definedDefaultTransitions = _default_state.getTransitions(); } else { definedDefaultTransitions = new LinkedList(); } // Declare the map class. source.println("class " + _name + " {"); source.println("# Member data.\n"); // Print all the static state objects. for (stateIt = _states.listIterator(); stateIt.hasNext() == true; ) { state = (SmcState) stateIt.next(); source.println(" public common " + state.getClassName() + " \"\";"); } // End of map class. source.println("}\n"); // Declare the map's default state class. source.println("class " + _name + "_Default {"); source.println(" inherit " + context + "State;\n"); source.println("# Member functions.\n"); source.println(" constructor {name} {"); source.println(" ::" + context + "State::constructor $name;"); source.println(" } {}"); // Dump out the user-defined default transitions. if (_default_state != null) { for (transIt = _default_state.getTransitions().listIterator(); transIt.hasNext() == true; ) { trans = (SmcTransition) transIt.next(); trans.generateCode(header, source, context, _name, "", null); } } // End the map's default state class declaration. source.println("}\n"); // Have each state now generate itself. for (stateIt = _states.listIterator(); stateIt.hasNext() == true; ) { state = (SmcState) stateIt.next(); state.generateCode(header, source, _name, context); } // Now create each of the static states. for (stateIt = _states.listIterator(); stateIt.hasNext() == true; ) { state = (SmcState) stateIt.next(); source.println("set " + _name + "::" + state.getClassName() + " [" + _name + "_" + state.getClassName() + " #auto \"" + _name + "::" + state.getClassName() + "\"];"); } source.println(""); return; } | 50995 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50995/ffbfa44caa39de8d579429432aa3aca8bd077721/SmcMapTcl.java/buggy/net/sf/smc/SmcMapTcl.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
2103,
1085,
12,
5108,
1228,
1446,
16,
11794,
21677,
1084,
16,
11794,
514,
819,
13,
3639,
1216,
10616,
565,
288,
3639,
10688,
2553,
1868,
23299,
273,
446,
31,
3639,
10688,
906,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
2103,
1085,
12,
5108,
1228,
1446,
16,
11794,
21677,
1084,
16,
11794,
514,
819,
13,
3639,
1216,
10616,
565,
288,
3639,
10688,
2553,
1868,
23299,
273,
446,
31,
3639,
10688,
906,
... |
else { | else { | public void send(MessageContext context, OutMessage message) throws XFireException { if (message.getUri().equals(Channel.BACKCHANNEL_URI)) { final OutputStream out = (OutputStream)context.getProperty(Channel.BACKCHANNEL_URI); if (out != null) { final XMLStreamWriter writer = STAXUtils.createXMLStreamWriter(out, message .getEncoding(), context); message.getSerializer().writeMessage(message, writer, context); } else { throw new XFireRuntimeException("No backchannel exists for message"); } try { Attachments atts = message.getAttachments(); if (atts != null && atts.size() > 0) { writeAttachmentBody(context, message); // TODO response.setContentType(atts.getContentType()); atts.write(out); } else { // TODO response.setContentType(getSoapMimeType(message)); writeWithoutAttachments(context, message, out); } } catch (IOException e) { throw new XFireException("Couldn't send message.", e); } } else { try { sendViaClient(context, message); } catch (Exception e) { throw new XFireException("Failed to Send via MuleUniversalChnnel: " + e.getMessage(), e); } } } | 2370 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/2370/f9d13d4f668e210937190683e520b17bc8f275cb/MuleUniversalChannel.java/clean/providers/xfire/src/main/java/org/mule/providers/soap/xfire/transport/MuleUniversalChannel.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1366,
12,
1079,
1042,
819,
16,
2976,
1079,
883,
13,
1216,
1139,
9723,
503,
565,
288,
3639,
309,
261,
2150,
18,
588,
3006,
7675,
14963,
12,
2909,
18,
8720,
15814,
67,
3098,
37... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1366,
12,
1079,
1042,
819,
16,
2976,
1079,
883,
13,
1216,
1139,
9723,
503,
565,
288,
3639,
309,
261,
2150,
18,
588,
3006,
7675,
14963,
12,
2909,
18,
8720,
15814,
67,
3098,
37... |
if(logMINOR) Logger.minor(this, "No requests, adjusted retrycount "+rga.getNumber()+" ("+rga+")"); | if(logMINOR) Logger.minor(this, "No requests, adjusted retrycount "+rga.getNumber()+" ("+rga+ ')'); | public SendableRequest removeFirst() { // Priorities start at 0 if(logMINOR) Logger.minor(this, "removeFirst()"); int choosenPriorityClass = Integer.MAX_VALUE; choosenPriorityClass = removeFirstAccordingToPriorities(choosenPriorityClass); if(choosenPriorityClass == -1) return null; SortedVectorByNumber s = priorities[choosenPriorityClass]; if(s != null){ while(true) { SectoredRandomGrabArrayWithInt rga = (SectoredRandomGrabArrayWithInt) s.getFirst(); if(rga == null) { if(logMINOR) Logger.minor(this, "No retrycount's left"); break; } SendableRequest req = (SendableRequest) rga.removeRandom(); if(rga.isEmpty()) { if(logMINOR) Logger.minor(this, "Removing retrycount "+rga.getNumber()); s.remove(rga.getNumber()); if(s.isEmpty()) { if(logMINOR) Logger.minor(this, "Should remove priority "); } } if(req == null) { if(logMINOR) Logger.minor(this, "No requests, adjusted retrycount "+rga.getNumber()+" ("+rga+")"); break; } else if(req.getPriorityClass() != choosenPriorityClass) { // Reinsert it : shouldn't happen if we are calling reregisterAll, // maybe we should ask people to report that error if seen if(logMINOR) Logger.minor(this, "In wrong priority class: "+req+" (req.prio="+req.getPriorityClass()+" but chosen="+choosenPriorityClass+")"); innerRegister(req); continue; } if(logMINOR) Logger.minor(this, "removeFirst() returning "+req+" ("+rga.getNumber()+", prio "+ req.getPriorityClass()+", retries "+req.getRetryCount()+", client "+req.getClient()+", client-req "+req.getClientRequest()+")"); ClientRequester cr = req.getClientRequest(); HashSet v = (HashSet) allRequestsByClientRequest.get(cr); v.remove(req); if(v.isEmpty()) allRequestsByClientRequest.remove(cr); return req; } } if(logMINOR) Logger.minor(this, "No requests to run"); return null; } | 56348 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/56348/62fd59041864b4ed1f43adc676de6bfb5ea977f3/ClientRequestScheduler.java/clean/src/freenet/client/async/ClientRequestScheduler.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
2479,
429,
691,
1206,
3759,
1435,
288,
202,
202,
759,
30326,
1961,
787,
622,
374,
202,
202,
430,
12,
1330,
6236,
916,
13,
4242,
18,
17364,
12,
2211,
16,
315,
4479,
3759,
1435,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
2479,
429,
691,
1206,
3759,
1435,
288,
202,
202,
759,
30326,
1961,
787,
622,
374,
202,
202,
430,
12,
1330,
6236,
916,
13,
4242,
18,
17364,
12,
2211,
16,
315,
4479,
3759,
1435,... |
if (DEBUG && debuglevel > 4) | a = a.add(ONE); if (a.compareTo(bn) != 0) | public static boolean passEulerCriterion(final BigInteger w) { // first check if it's already a known prime WeakReference obj = (WeakReference) knownPrimes.get(w); if (obj != null && w.equals(obj.get())) { if (DEBUG && debuglevel > 4) { debug("found in known primes"); } return true; } BigInteger w_minus_one = w.subtract(ONE); BigInteger e = w_minus_one; // l is the 3 least-significant bits of e int l = e.and(BigInteger.valueOf(7L)).intValue(); int j = 1; // Where to start in prime array for strong prime tests BigInteger A; int k; if ((l & 7) != 0) { e = e.shiftRight(1); A = TWO.modPow(e, w); if ((l & 7) == 6) { // bn == 7 mod 8, expect +1 if (A.bitCount() != 1) { if (DEBUG && debuglevel > 4) { debug(w.toString(16) + " fails Euler criterion #1..."); } return false; // Not prime } k = 1; } else { // bn == 3 or 5 mod 8, expect -1 == bn-1 A = A.add(ONE); if (!A.equals(w)) { if (DEBUG && debuglevel > 4) { debug(w.toString(16) + " fails Euler criterion #2..."); } return false; // Not prime } k = 1; if ((l & 4) != 0) { // bn == 5 mod 8, make odd for strong tests e = e.shiftRight(1); k = 2; } } } else { // bn == 1 mod 8, expect 2^((bn-1)/4) == +/-1 mod bn e = e.shiftRight(2); A = TWO.modPow(e, w); if (A.bitCount() == 1) { j = 0; // Re-do strong prime test to base 2 } else { A = A.add(ONE); if (!A.equals(w)) { if (DEBUG && debuglevel > 4) { debug(w.toString(16) + " fails Euler criterion #3..."); } return false; // Not prime } } // bnMakeOdd(n) = d * 2^s. Replaces n with d and returns s. k = e.getLowestSetBit(); e = e.shiftRight(k); k += 2; } // It's prime! Now go on to confirmation tests // Now, e = (bn-1)/2^k is odd. k >= 1, and has a given value with // probability 2^-k, so its expected value is 2. j = 1 in the usual case // when the previous test was as good as a strong prime test, but 1/8 of // the time, j = 0 because the strong prime test to the base 2 needs to // be re-done. //for (int i = j; i < SMALL_PRIME_COUNT; i++) { for (int i = j; i < 13; i++) { // try only the first 13 primes A = SMALL_PRIME[i]; A = A.modPow(e, w); if (A.bitCount() == 1) { continue; // Passed this test } l = k; while (true) { // A = A.add(ONE); // if (A.equals(w)) { // Was result bn-1? if (A.equals(w_minus_one)) { // Was result bn-1? break; // Prime } if (--l == 0) { // Reached end, not -1? luck? if (DEBUG && debuglevel > 4) { debug(w.toString(16) + " fails Euler criterion #4..."); } return false; // Failed, not prime } // This portion is executed, on average, once // A = A.subtract(ONE); // Put a back where it was A = A.modPow(TWO, w); if (A.bitCount() == 1) { if (DEBUG && debuglevel > 4) { debug(w.toString(16) + " fails Euler criterion #5..."); } return false; // Failed, not prime } } // It worked (to the base primes[i]) } if (DEBUG && debuglevel > 4) { debug(w.toString(16) + " passes Euler criterion..."); } // store it in the known primes weak hash-map knownPrimes.put(w, new WeakReference(w)); return true; } | 50763 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50763/5806c07c3eeedb0f4f92b9fbacf30c0f55915c25/Prime2.java/clean/core/src/classpath/gnu/gnu/java/security/util/Prime2.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
760,
1250,
1342,
41,
17040,
13210,
12,
6385,
10246,
341,
13,
225,
288,
565,
368,
1122,
866,
309,
518,
1807,
1818,
279,
4846,
17014,
565,
23632,
2404,
1081,
273,
261,
3218,
581,
2404... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
760,
1250,
1342,
41,
17040,
13210,
12,
6385,
10246,
341,
13,
225,
288,
565,
368,
1122,
866,
309,
518,
1807,
1818,
279,
4846,
17014,
565,
23632,
2404,
1081,
273,
261,
3218,
581,
2404... |
private static boolean postfixExpressionMustRecurse(PsiPostfixExpression expression, PsiMethod method) { | private static boolean postfixExpressionMustRecurse( PsiPostfixExpression expression, PsiMethod method){ | private static boolean postfixExpressionMustRecurse(PsiPostfixExpression expression, PsiMethod method) { final PsiExpression operand = expression.getOperand(); return expressionMustRecurse(operand, method); } | 17306 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/17306/5d60670c94763ec336e534e66ee87700ab0d35be/RecursionUtils.java/clean/plugins/InspectionGadgets/src/com/siyeh/ig/psiutils/RecursionUtils.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
760,
1250,
18923,
2300,
10136,
426,
17682,
12,
453,
7722,
24505,
2300,
2652,
16,
453,
7722,
1305,
707,
15329,
3639,
727,
453,
7722,
2300,
9886,
273,
2652,
18,
588,
10265,
5621,
3639,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
377,
3238,
760,
1250,
18923,
2300,
10136,
426,
17682,
12,
453,
7722,
24505,
2300,
2652,
16,
453,
7722,
1305,
707,
15329,
3639,
727,
453,
7722,
2300,
9886,
273,
2652,
18,
588,
10265,
5621,
3639,
... |
return false; | return; | public boolean classpathChanged(IResourceDelta delta, IProgressMonitor monitor, Map _buildCache) { if (!Preferences.getPREF_WRITE_PB_DOT_PROJECT_ON_BUILD()) { return false; } IResource resource = delta.getResource(); handleClasspath(resource, monitor, _buildCache); return false; } | 50596 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50596/5644f6506a8f17f2b8311774090206457f13a78d/PBDotProjectBuilder.java/buggy/wolips/plugins/org.objectstyle.wolips.builder/java/org/objectstyle/wolips/builder/internal/PBDotProjectBuilder.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
1250,
10006,
5033,
12,
45,
1420,
9242,
3622,
16,
1082,
202,
45,
5491,
7187,
6438,
16,
1635,
389,
3510,
1649,
13,
288,
202,
202,
430,
16051,
12377,
18,
588,
3670,
42,
67,
11677... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
10006,
5033,
12,
45,
1420,
9242,
3622,
16,
1082,
202,
45,
5491,
7187,
6438,
16,
1635,
389,
3510,
1649,
13,
288,
202,
202,
430,
16051,
12377,
18,
588,
3670,
42,
67,
11677... |
throw new PainterException("ne: wrong arguments"); | throw new PainterException("gt: wrong arguments"); | public void execute(PAContext context) throws PainterException { Object data[]; data = context.popOperands(2); if (! (data[0] instanceof Number) && ! (data[0] instanceof String)) { throw new PainterException("ne: wrong arguments"); } if (data[0] instanceof Number) { if (! (data[1] instanceof Number)) { throw new PainterException("ne: wrong arguments"); } double d0, d1; d0 = ( (Number) data[0]).doubleValue(); d1 = ( (Number) data[1]).doubleValue(); if (d0 != d1) { context.operands.push(new Boolean(true)); } else { context.operands.push(new Boolean(false)); } } else { if (! (data[1] instanceof String)) { throw new PainterException("ne: wrong arguments"); } String s0, s1; s0 = (String) data[0]; s1 = (String) data[1]; if (s0.equals(s1)) { context.operands.push(new Boolean(false)); } else { context.operands.push(new Boolean(true)); } } } | 6653 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/6653/a70285238d45643e095fbf1c5a17749c92b693e7/PAContext.java/clean/src/com/lowagie/text/pdf/codec/postscript/PAContext.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
4202,
1071,
918,
1836,
12,
4066,
1042,
819,
13,
1216,
453,
11606,
503,
288,
3639,
1033,
501,
8526,
31,
3639,
501,
273,
819,
18,
5120,
3542,
5708,
12,
22,
1769,
3639,
309,
16051,
261,
892,
63... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
4202,
1071,
918,
1836,
12,
4066,
1042,
819,
13,
1216,
453,
11606,
503,
288,
3639,
1033,
501,
8526,
31,
3639,
501,
273,
819,
18,
5120,
3542,
5708,
12,
22,
1769,
3639,
309,
16051,
261,
892,
63... |
if (layoutMgr != null) layoutMgr.removeLayoutComponent(r); | if (layoutMgr != null) layoutMgr.removeLayoutComponent(r); | public void remove(int index) { Component r = component[index]; r.removeNotify(); System.arraycopy(component, index + 1, component, index, ncomponents - index - 1); component[--ncomponents] = null; invalidate(); if (layoutMgr != null) layoutMgr.removeLayoutComponent(r); // Post event to notify of adding the container. ContainerEvent ce = new ContainerEvent(this, ContainerEvent.COMPONENT_REMOVED, r); getToolkit().getSystemEventQueue().postEvent(ce); } | 25337 /local/tlutelli/issta_data/temp/all_java2context/java/2006_temp/2006/25337/47b8a95e33f15f8f7f754a990349584fe4134b05/Container.java/clean/libjava/java/awt/Container.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
918,
1206,
12,
474,
770,
13,
225,
288,
565,
5435,
436,
273,
1794,
63,
1615,
15533,
565,
436,
18,
4479,
9168,
5621,
565,
2332,
18,
1126,
3530,
12,
4652,
16,
770,
397,
404,
16,
17... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
918,
1206,
12,
474,
770,
13,
225,
288,
565,
5435,
436,
273,
1794,
63,
1615,
15533,
565,
436,
18,
4479,
9168,
5621,
565,
2332,
18,
1126,
3530,
12,
4652,
16,
770,
397,
404,
16,
17... |
switch (alt35) { | switch (alt36) { | public PatternDescr lhs_and() throws RecognitionException { PatternDescr d; PatternDescr left = null; PatternDescr right = null; d = null; try { // /Users/bob/Documents/workspace/jbossrules/drools-compiler/src/main/java/org/drools/lang/drl.g:405:17: (left= lhs_unary ( ('and'|'&&')right= lhs_unary )* ) // /Users/bob/Documents/workspace/jbossrules/drools-compiler/src/main/java/org/drools/lang/drl.g:405:17: left= lhs_unary ( ('and'|'&&')right= lhs_unary )* { AndDescr and = null; following.push(FOLLOW_lhs_unary_in_lhs_and1456); left=lhs_unary(); following.pop(); d = left; // /Users/bob/Documents/workspace/jbossrules/drools-compiler/src/main/java/org/drools/lang/drl.g:407:17: ( ('and'|'&&')right= lhs_unary )* loop35: do { int alt35=2; int LA35_0 = input.LA(1); if ( (LA35_0>=38 && LA35_0<=39) ) { int LA35_12 = input.LA(2); if ( !( expander != null ) ) { alt35=1; } } switch (alt35) { case 1 : // /Users/bob/Documents/workspace/jbossrules/drools-compiler/src/main/java/org/drools/lang/drl.g:407:25: ('and'|'&&')right= lhs_unary { if ( (input.LA(1)>=38 && input.LA(1)<=39) ) { input.consume(); errorRecovery=false; } else { MismatchedSetException mse = new MismatchedSetException(null,input); recoverFromMismatchedSet(input,mse,FOLLOW_set_in_lhs_and1465); throw mse; } following.push(FOLLOW_lhs_unary_in_lhs_and1476); right=lhs_unary(); following.pop(); if ( and == null ) { and = new AndDescr(); and.addDescr( left ); d = and; } and.addDescr( right ); } break; default : break loop35; } } while (true); } } catch (RecognitionException re) { reportError(re); recover(input,re); } finally { } return d; } | 6736 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/6736/59894e8a22b2183840bd9c2486282d6f4f6932d0/RuleParser.java/clean/drools-compiler/src/main/java/org/drools/lang/RuleParser.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
6830,
16198,
8499,
67,
464,
1435,
1216,
9539,
288,
6647,
6830,
16198,
302,
31,
3639,
6830,
16198,
2002,
273,
446,
31,
3639,
6830,
16198,
2145,
273,
446,
31,
540,
202,
202,
72,
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,
1071,
6830,
16198,
8499,
67,
464,
1435,
1216,
9539,
288,
6647,
6830,
16198,
302,
31,
3639,
6830,
16198,
2002,
273,
446,
31,
3639,
6830,
16198,
2145,
273,
446,
31,
540,
202,
202,
72,
273,
... |
public void mWS() throws RecognitionException { try { ruleNestingLevel++; int _type = WS; int _start = getCharIndex(); int _line = getLine(); int _charPosition = getCharPositionInLine(); int _channel = Token.DEFAULT_CHANNEL; // D:\\workspace\\jboss\\jbossrules\\drools-compiler\\src\\main\\resources\\org\\drools\\lang\\DRL.g:1312:17: ( ( ' ' | '\\t' | '\\f' | EOL ) ) // D:\\workspace\\jboss\\jbossrules\\drools-compiler\\src\\main\\resources\\org\\drools\\lang\\DRL.g:1312:17: ( ' ' | '\\t' | '\\f' | EOL ) { // D:\\workspace\\jboss\\jbossrules\\drools-compiler\\src\\main\\resources\\org\\drools\\lang\\DRL.g:1312:17: ( ' ' | '\\t' | '\\f' | EOL ) int alt3=4; switch ( input.LA(1) ) { case ' ': alt3=1; break; case '\t': alt3=2; break; case '\f': alt3=3; break; case '\n': case '\r': alt3=4; break; default: if (backtracking>0) {failed=true; return ;} NoViableAltException nvae = new NoViableAltException("1312:17: ( ' ' | '\\t' | '\\f' | EOL )", 3, 0, input); throw nvae; } switch (alt3) { case 1 : // D:\\workspace\\jboss\\jbossrules\\drools-compiler\\src\\main\\resources\\org\\drools\\lang\\DRL.g:1312:19: ' ' { match(' '); if (failed) return ; } break; case 2 : // D:\\workspace\\jboss\\jbossrules\\drools-compiler\\src\\main\\resources\\org\\drools\\lang\\DRL.g:1313:19: '\\t' { match('\t'); if (failed) return ; } break; case 3 : // D:\\workspace\\jboss\\jbossrules\\drools-compiler\\src\\main\\resources\\org\\drools\\lang\\DRL.g:1314:19: '\\f' { match('\f'); if (failed) return ; } break; case 4 : // D:\\workspace\\jboss\\jbossrules\\drools-compiler\\src\\main\\resources\\org\\drools\\lang\\DRL.g:1315:19: EOL { mEOL(); if (failed) return ; } break; } if ( backtracking==0 ) { _channel=HIDDEN; } } if ( backtracking==0 ) { if ( token==null && ruleNestingLevel==1 ) { emit(_type,_line,_charPosition,_channel,_start,getCharIndex()-1); } } } finally { ruleNestingLevel--; } } | 5490 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5490/63bc7036e62ae854cec463d59712c173f74e984c/DRLLexer.java/buggy/drools-compiler/src/main/java/org/drools/lang/DRLLexer.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
312,
2651,
1435,
1216,
9539,
288,
3639,
775,
288,
5411,
1720,
50,
10100,
2355,
9904,
31,
5411,
509,
389,
723,
273,
7649,
31,
5411,
509,
389,
1937,
273,
23577,
1016,
5621,
5411,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
312,
2651,
1435,
1216,
9539,
288,
3639,
775,
288,
5411,
1720,
50,
10100,
2355,
9904,
31,
5411,
509,
389,
723,
273,
7649,
31,
5411,
509,
389,
1937,
273,
23577,
1016,
5621,
5411,... | ||
private static String[] nextString(String from) { char[] cFrom = from.toCharArray(); String[] res = new String[2]; res[0] = ""; res[1] = ""; int quote = 0; char sep = ' '; int i=0; if(cFrom[0] == '\'') { quote = 1; } if(cFrom[0] == '"') { quote = 2; } if(quote != 0) { i++; sep = cFrom[0]; } for(;i<cFrom.length;i++) { switch(quote) { case 0: case 1: if(cFrom[i] == sep) { res[0] = from.substring(i+1); return res; } res[1] += cFrom[i]; break; case 2: if(cFrom[i]=='"') { res[0] = from.substring(i+1); return res; } else { i++; if(i==cFrom.length) { return null; } res[1] += cFrom[i]; } break; } } if(quote == 0) { return res; } return null; } | 4438 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/4438/2c5d8c48e540e0e8bdaf2b72c3edd55f8838d406/StendhalChatLineListener.java/clean/src/games/stendhal/client/gui/StendhalChatLineListener.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
6015,
270,
395,
2126,
780,
8526,
4285,
780,
12,
780,
2080,
15329,
3001,
8526,
71,
1265,
33,
2080,
18,
869,
15936,
5621,
780,
8526,
455,
33,
2704,
780,
63,
22,
15533,
455,
63,
20,
65,
1546,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
6015,
270,
395,
2126,
780,
8526,
4285,
780,
12,
780,
2080,
15329,
3001,
8526,
71,
1265,
33,
2080,
18,
869,
15936,
5621,
780,
8526,
455,
33,
2704,
780,
63,
22,
15533,
455,
63,
20,
65,
1546,
... | ||
SIRPipeline currentPipe = new SIRPipeline("LinearWrapper"+pipeCounter); | List childrenToWrap = new LinkedList(); | public void postVisitPipeline(SIRPipeline self, SIRPipelineIter iter) { this.pipelinesSeen++; LinearPrinter.println("Visiting pipeline: " + "(" + self + ")"); // This bit just goes and prints out the children of the pipeline. Iterator kidIter = self.getChildren().iterator(); LinearPrinter.println("Children: "); while(kidIter.hasNext()) { SIRStream currentKid = (SIRStream)kidIter.next(); String linearString = (this.hasLinearRepresentation(currentKid)) ? "linear" : "non-linear"; LinearPrinter.println(" " + currentKid + "(" + linearString + ")"); } // start going down the list of pipeline children. int pipeCounter = 0; kidIter = self.getChildren().iterator(); SIRPipeline currentPipe = new SIRPipeline("LinearWrapper"+pipeCounter); while(kidIter.hasNext()) { // grab the next child. If we have a linear rep, add the kid to the pipeline SIRStream currentKid = (SIRStream)kidIter.next(); LinearPrinter.println(" current child: " + currentKid); if (this.hasLinearRepresentation(currentKid)) { // add this kid to the current linear pipeline. currentPipe.add(currentKid); } else { // kid was non linear. Replace the children in self with the new pipeline // and update the mapping from filters to LinearFilterRepresentations. doPipelineAdd(self, currentPipe, this.filtersToLinearRepresentation); currentPipe = new SIRPipeline("LinearWrapper"+pipeCounter); pipeCounter++; } } // add the current pipeline (to catch the end of the pipeline) -- doens't add empty pipelines doPipelineAdd(self, currentPipe, this.filtersToLinearRepresentation); // check to make sure that we didn't foobar ourselves. checkRep(); } | 5955 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5955/aac78ba8cb316813a4a9ee138110b784b80b3a17/LinearAnalyzer.java/clean/streams/src/at/dms/kjc/sir/linear/LinearAnalyzer.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1603,
10432,
8798,
12,
2320,
54,
8798,
365,
16,
5705,
54,
8798,
2360,
1400,
13,
288,
202,
2211,
18,
16104,
14567,
15160,
9904,
31,
202,
15982,
12149,
18,
8222,
2932,
10432,
310... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1603,
10432,
8798,
12,
2320,
54,
8798,
365,
16,
5705,
54,
8798,
2360,
1400,
13,
288,
202,
2211,
18,
16104,
14567,
15160,
9904,
31,
202,
15982,
12149,
18,
8222,
2932,
10432,
310... |
fireListeners(event); | Object[] elements = event.getElements(); for(int i = 0; i < elements.length; i ++){ Object adapted = getResourceAdapter(elements[i]); scheduler.queueForDecoration(elements[i],adapted,true); } | public void labelProviderChanged(LabelProviderChangedEvent event) { fireListeners(event); } | 57470 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/57470/0f63f6784c32e6cd761b3a6bbb604826ee1c5aa7/DecoratorManager.java/clean/bundles/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal/decorators/DecoratorManager.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
1433,
2249,
5033,
12,
2224,
2249,
27553,
871,
13,
288,
202,
202,
12179,
5583,
12,
2575,
1769,
202,
97,
2,
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,
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... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
1433,
2249,
5033,
12,
2224,
2249,
27553,
871,
13,
288,
202,
202,
12179,
5583,
12,
2575,
1769,
202,
97,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
public void setNextNode(float x, float y) { //System.out.println("OverlayObject::setNextNode("+ x +","+ y +")"); if (numNodes >= maxNodes) { maxNodes *= 2; nodes = resizeNodeArray(nodes, maxNodes); //System.out.println("OverlayObject::resizeNodeArray("+nodes+","+maxNodes+")"); } Arrays.fill(nodes[0], numNodes, maxNodes, x); Arrays.fill(nodes[1], numNodes++, maxNodes, y); //i.e., set all remaining nodes (as per maxNodes) to next node coords /* //print the node array. System.out.println ("Printing nodes[] in method setNextNode"); System.out.println ("Array nodes[0].length = " + nodes[0].length); System.out.println ("numNodes = " + numNodes); for (int i = 0; i < numNodes; i++) { System.out.print("(" + nodes[0][i] + "," + nodes[1][i] + ")"); } System.out.println(); System.out.println("What's the nearest node to 0,0? Testing method computeNearestNode"); //TEMP //computeNearestNode(0, 0); // TEMP */ // all temp stuff } | 55415 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/55415/41c1602bc7463842ccdfb4279c7ff84620d2dbe7/OverlayObject.java/buggy/loci/visbio/overlays/OverlayObject.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1071,
6459,
542,
2134,
907,
12,
5659,
92,
16,
5659,
93,
15329,
759,
3163,
18,
659,
18,
8222,
2932,
11627,
921,
2866,
542,
2134,
907,
2932,
15,
92,
15,
15937,
15,
93,
9078,
2225,
1769,
430,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
6459,
542,
2134,
907,
12,
5659,
92,
16,
5659,
93,
15329,
759,
3163,
18,
659,
18,
8222,
2932,
11627,
921,
2866,
542,
2134,
907,
2932,
15,
92,
15,
15937,
15,
93,
9078,
2225,
1769,
430,
... | ||
statusGroup.setEnabled(filter.getSelectByDone()); statusGroup.setDone(filter.getDone()); | statusGroup.setEnabled(filter.getSelectByDone()); statusGroup.setDone(filter.getDone()); | protected void updateUIFromFilter() { TaskFilter filter = (TaskFilter) getFilter(); descriptionGroup.setContains(filter.getContains()); descriptionGroup.setDescription(filter.getDescription()); priorityGroup.setEnabled(filter.getSelectByPriority()); int priority = filter.getPriority(); priorityGroup .setHighSelected((priority & TaskFilter.PRIORITY_HIGH) > 0); priorityGroup .setNormalSelected((priority & TaskFilter.PRIORITY_NORMAL) > 0); priorityGroup.setLowSelected((priority & TaskFilter.PRIORITY_LOW) > 0); statusGroup.setEnabled(filter.getSelectByDone()); statusGroup.setDone(filter.getDone()); super.updateUIFromFilter(); } | 57470 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/57470/1ceb585b9b16047c6c580984b0c9962c41a22ba6/DialogTaskFilter.java/clean/bundles/org.eclipse.ui.ide/src/org/eclipse/ui/views/markers/internal/DialogTaskFilter.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
4750,
918,
1089,
5370,
1265,
1586,
1435,
288,
3639,
3837,
1586,
1034,
273,
261,
2174,
1586,
13,
12267,
5621,
3639,
2477,
1114,
18,
542,
10846,
12,
2188,
18,
588,
10846,
10663,
3639,
2477,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1089,
5370,
1265,
1586,
1435,
288,
3639,
3837,
1586,
1034,
273,
261,
2174,
1586,
13,
12267,
5621,
3639,
2477,
1114,
18,
542,
10846,
12,
2188,
18,
588,
10846,
10663,
3639,
2477,
... |
int version_index = moduleName.indexOf(version_seperator); | int version_index = moduleName.lastIndexOf(version_seperator); | public static String getModuleVersion(String moduleName) { char version_seperator = '-'; int version_index = moduleName.indexOf(version_seperator); if (version_index > 0) { return moduleName.substring(version_index + 1, moduleName.length()); } else { return null; } } | 49300 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/49300/d496da03ac4dba911dc785a2377a2b40cc7caa18/Utils.java/clean/modules/core/src/org/apache/axis2/util/Utils.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
760,
514,
11251,
1444,
12,
780,
9780,
13,
288,
3639,
1149,
1177,
67,
307,
457,
639,
273,
4014,
31,
3639,
509,
1177,
67,
1615,
273,
9780,
18,
2722,
31985,
12,
1589,
67,
307,
457,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
11251,
1444,
12,
780,
9780,
13,
288,
3639,
1149,
1177,
67,
307,
457,
639,
273,
4014,
31,
3639,
509,
1177,
67,
1615,
273,
9780,
18,
2722,
31985,
12,
1589,
67,
307,
457,
... |
AnnotationC.compile( m_verbose, (String[])srcDirs.toArray(new String[]{}), (String[])srcFiles.toArray(new String[]{}), (String[])classpathDirs.toArray(new String[]{}), m_destdir == null ? null : m_destdir.getAbsolutePath(), m_properties == null ? null : m_properties.getAbsolutePath() ); | public void execute() throws BuildException { try { if (m_classpath == null) { throw new BuildException("No classes specified [<classpath, classpath=.. classpathref=..]"); } if (m_destdir == null && m_classpath.list().length > 1) { throw new BuildException( "When using more than one classpath directory, it is mandatory to specify [destdir=..]" ); } if (m_filesets.size() == 0 && (m_src == null || m_src.size() == 0)) { throw new BuildException("No source specified [<include, <sourcepath, srcdir=..]"); } if (m_properties != null && !m_properties.exists() && !m_properties.isFile()) { throw new BuildException("properties file specified but not a valid file [" + m_properties + "]"); } // compute source directory list List srcDirs = getDirectories(m_src); List srcFiles = getFilesetFiles(m_filesets); List classpathDirs = getDirectories(m_classpath); if (m_verbose) { System.out.println("Source dir : " + dump(srcDirs)); System.out.println("Source files : " + dump(srcFiles)); System.out.println("Classpath : " + dump(classpathDirs)); System.out.println("Destdir : " + m_destdir); System.out.println("Properties : " + m_properties); System.out.println("Copytodest : " + m_includePattern); }// AnnotationC.compile(// m_verbose,// (String[])srcDirs.toArray(new String[]{}),// (String[])srcFiles.toArray(new String[]{}),// (String[])classpathDirs.toArray(new String[]{}),// m_destdir == null ? null : m_destdir.getAbsolutePath(),// m_properties == null ? null : m_properties.getAbsolutePath()// ); if (m_destdir != null) { if (m_verbose) { System.out.println("Copying residual files to dest dir..."); } copySourcesToDest(); } } catch (Exception e) { e.printStackTrace(); throw new BuildException(e); } } | 7954 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/7954/dcc0ea14b91da91e12dca712522031769a054b6c/AnnotationCTask.java/clean/aspectwerkz3/src/main/org/codehaus/aspectwerkz/annotation/AnnotationCTask.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1836,
1435,
1216,
18463,
288,
3257,
39,
18,
11100,
12,
312,
67,
11369,
16,
261,
780,
63,
5717,
4816,
9872,
18,
31447,
12,
2704,
514,
8526,
2916,
3631,
261,
780,
63,
5717,
481... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1836,
1435,
1216,
18463,
288,
3257,
39,
18,
11100,
12,
312,
67,
11369,
16,
261,
780,
63,
5717,
4816,
9872,
18,
31447,
12,
2704,
514,
8526,
2916,
3631,
261,
780,
63,
5717,
481... | |
if (trace != null && trace.length >= 4) { StackTraceElement caller = trace[3]; | if (trace != null && trace.length >= 3) { StackTraceElement caller = trace[2]; | private static final void traceMethod(boolean enter, Object detail) { String callingClass = "<unknown>"; String callingMethod = "<unknown>"; // Determine calling class and calling method, but only on Java 1.4+ if (getJavaVersion() >= 1.4) { // Create an exception so we can look at the stack trace Throwable exception = new Throwable(); // Get the stack trace StackTraceElement[] trace = exception.getStackTrace(); if (trace != null && trace.length >= 4) { StackTraceElement caller = trace[3]; if (caller != null) { // Determine class name String s = caller.getClassName(); if (! TextUtils.isEmpty(s)) { callingClass = s; } // Determine method name s = caller.getMethodName(); if (! TextUtils.isEmpty(s)) { callingMethod = s; } } } } // Determine detail message String detailString = (detail == null) ? null : detail.toString(); // Actually log if (enter) { Log.log_1003(callingClass, callingMethod, detailString); } else { Log.log_1005(callingClass, callingMethod, detailString); } } | 45757 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/45757/7f313e4686bfb0a266821b4aa0663e2f5e22f9e4/Utils.java/clean/src/java-common/org/xins/common/Utils.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
565,
3238,
760,
727,
918,
2606,
1305,
12,
6494,
6103,
16,
1033,
7664,
13,
288,
1377,
514,
4440,
797,
225,
273,
3532,
8172,
2984,
31,
1377,
514,
4440,
1305,
273,
3532,
8172,
2984,
31,
1377,
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,
565,
3238,
760,
727,
918,
2606,
1305,
12,
6494,
6103,
16,
1033,
7664,
13,
288,
1377,
514,
4440,
797,
225,
273,
3532,
8172,
2984,
31,
1377,
514,
4440,
1305,
273,
3532,
8172,
2984,
31,
1377,
3... |
if (_encloser instanceof FigNodeModelElement) ((FigNodeModelElement) _encloser)._enclosedFigs.removeElement(this); if (_encloser != null && f == null && getOwner() != null) { ProjectBrowser pb = ProjectBrowser.TheInstance; UMLDiagram diagram = (UMLDiagram) pb.getActiveDiagram(); MNamespace ns = diagram.getNamespace(); ns.addOwnedElement((MModelElement) getOwner()); | if (!(getOwner() instanceof MModelElement)) return; MModelElement elem = (MModelElement)getOwner(); if (f == null && getEnclosingFig() != null) { return; } if (f == null && getEnclosingFig() == null) { return; } Object fOwner = f.getOwner(); if (fOwner instanceof MNamespace) { if (CoreHelper.getHelper().isValidNamespace(elem, (MNamespace)fOwner)) ((MNamespace)fOwner).addOwnedElement(elem); return; | public void setEnclosingFig(Fig f) { super.setEnclosingFig(f); if (_encloser instanceof FigNodeModelElement) ((FigNodeModelElement) _encloser)._enclosedFigs.removeElement(this); if (_encloser != null && f == null && getOwner() != null) { // moved it from some package into the free wild ProjectBrowser pb = ProjectBrowser.TheInstance; UMLDiagram diagram = (UMLDiagram) pb.getActiveDiagram(); MNamespace ns = diagram.getNamespace(); ns.addOwnedElement((MModelElement) getOwner()); } _encloser = f; if (_encloser instanceof FigNodeModelElement) { ((FigNodeModelElement) _encloser)._enclosedFigs.addElement(this); if (_encloser.getOwner() != null && _encloser.getOwner() instanceof MNamespace) { if (CoreHelper .getHelper() .isValidNamespace( (MModelElement) getOwner(), (MNamespace) _encloser.getOwner())) { ((MNamespace) _encloser.getOwner()).addOwnedElement( (MModelElement) getOwner()); } } } } | 7166 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/7166/3faa105da99205b4cf59b2cb68e138ffbf2046fa/FigNodeModelElement.java/buggy/src_new/org/argouml/uml/diagram/ui/FigNodeModelElement.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
444,
21594,
42,
360,
12,
42,
360,
284,
13,
288,
3639,
2240,
18,
542,
21594,
42,
360,
12,
74,
1769,
3639,
309,
261,
67,
1331,
383,
550,
1276,
478,
360,
907,
1488,
1046,
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,
377,
1071,
918,
444,
21594,
42,
360,
12,
42,
360,
284,
13,
288,
3639,
2240,
18,
542,
21594,
42,
360,
12,
74,
1769,
3639,
309,
261,
67,
1331,
383,
550,
1276,
478,
360,
907,
1488,
1046,
13,
... |
public void unparse(XmlaResponse response) { throw new UnsupportedOperationException(); | public void unparse(XmlaResponse response) throws XmlaException { Connection connection = handler.getConnection(request); if (connection == null) { return; } final RolapSchema schema = (RolapSchema) connection.getSchema(); final String schemaName = schema.getName(); Cube[] cubes = schema.getCubes(); int ordinalPosition = 1; Row row = null; for (int i = 0; i < cubes.length; i++) { RolapCube cube = (RolapCube) cubes[i]; String cubeName = cube.getName(); /* Dimensions Store Time ... Measures:Unit Sales */ Dimension[] dims = cube.getDimensions(); for (int j = 1; j < dims.length; j++) { Dimension dimension = dims[j]; Hierarchy[] hierarchies = dimension.getHierarchies(); for (int h = 0; h < hierarchies.length; h++) { HierarchyBase hierarchy = (HierarchyBase) hierarchies[h]; ordinalPosition = emitHierarchy(response, connection, cube, hierarchy, ordinalPosition); } } RolapMember[] rms = cube.getMeasuresMembers(); for (int k = 1; k < rms.length; k++) { RolapMember member = rms[k]; String memberName = member.getName(); row = new Row(); row.set(TableCatalog.name, schemaName); row.set(TableName.name, cubeName); row.set(ColumnName.name, "Measures:" + memberName); row.set(OrdinalPosition.name, ordinalPosition++); row.set(ColumnHasDefault.name, false); row.set(ColumnFlags.name, 0); row.set(IsNullable.name, false); row.set(DataType.name, DBType.R8_ORDINAL); row.set(NumericPrecision.name, 16); row.set(NumericScale.name, 255); emit(row, response); } } | public void unparse(XmlaResponse response) { //TODO throw new UnsupportedOperationException(); } | 51263 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/51263/41e43f806f666da1ff483ebb20820e61433739e2/RowsetDefinition.java/buggy/src/main/mondrian/xmla/RowsetDefinition.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
540,
1071,
918,
640,
2670,
12,
4432,
69,
1064,
766,
13,
288,
5411,
368,
6241,
5411,
604,
394,
13172,
5621,
3639,
289,
2,
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,
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... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
540,
1071,
918,
640,
2670,
12,
4432,
69,
1064,
766,
13,
288,
5411,
368,
6241,
5411,
604,
394,
13172,
5621,
3639,
289,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,... |
"ASN.1 Named Bitstring: size contstrains"); | Messages.getString("security.97")); | public Object getDecodedObject(BerInputStream in) throws IOException { boolean[] value = null; int unusedBits = in.buffer[in.contentOffset]; int bitsNumber = (in.length - 1) * 8 - unusedBits; if (maxBits == INDEFINITE_SIZE) { if (minBits == INDEFINITE_SIZE) { value = new boolean[bitsNumber]; } else { if (bitsNumber > minBits) { value = new boolean[bitsNumber]; } else { value = new boolean[minBits]; } } } else { if (bitsNumber > maxBits) { throw new ASN1Exception( "ASN.1 Named Bitstring: size contstrains"); //FIXME message } value = new boolean[maxBits]; } if (bitsNumber == 0) { // empty bit string return value; } int i = 1; int j = 0; byte octet = in.buffer[in.contentOffset + i]; for (int size = in.length - 1; i < size; i++) { for (int k = 0; k < 8; k++, j++) { value[j] = (SET_MASK[k] & octet) != 0; } i++; octet = in.buffer[in.contentOffset + i]; } // final octet for (int k = 0; k < (8 - unusedBits); k++, j++) { value[j] = (SET_MASK[k] & octet) != 0; } return value; } | 54769 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54769/c7fdc88348ff6da63262b6309c2810876f42c6d8/ASN1BitString.java/buggy/modules/security/src/main/java/common/org/apache/harmony/security/asn1/ASN1BitString.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
540,
1071,
1033,
336,
24888,
921,
12,
38,
264,
4348,
316,
13,
1216,
1860,
288,
5411,
1250,
8526,
460,
273,
446,
31,
5411,
509,
10197,
6495,
273,
316,
18,
4106,
63,
267,
18,
1745,
2335,
15533... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1033,
336,
24888,
921,
12,
38,
264,
4348,
316,
13,
1216,
1860,
288,
5411,
1250,
8526,
460,
273,
446,
31,
5411,
509,
10197,
6495,
273,
316,
18,
4106,
63,
267,
18,
1745,
2335,
15533... |
dr= new RuleBasedDamagerRepairer(getSinglelineCommentScanner()); | dr= new DefaultDamagerRepairer(getSinglelineCommentScanner()); | public IPresentationReconciler getPresentationReconciler(ISourceViewer sourceViewer) { PresentationReconciler reconciler= new PresentationReconciler(); RuleBasedDamagerRepairer dr= new RuleBasedDamagerRepairer(getCodeScanner()); reconciler.setDamager(dr, IDocument.DEFAULT_CONTENT_TYPE); reconciler.setRepairer(dr, IDocument.DEFAULT_CONTENT_TYPE); dr= new RuleBasedDamagerRepairer(getJavaDocScanner()); reconciler.setDamager(dr, JavaPartitionScanner.JAVA_DOC); reconciler.setRepairer(dr, JavaPartitionScanner.JAVA_DOC); dr= new RuleBasedDamagerRepairer(getMultilineCommentScanner()); reconciler.setDamager(dr, JavaPartitionScanner.JAVA_MULTI_LINE_COMMENT); reconciler.setRepairer(dr, JavaPartitionScanner.JAVA_MULTI_LINE_COMMENT); dr= new RuleBasedDamagerRepairer(getSinglelineCommentScanner()); reconciler.setDamager(dr, JavaPartitionScanner.JAVA_SINGLE_LINE_COMMENT); reconciler.setRepairer(dr, JavaPartitionScanner.JAVA_SINGLE_LINE_COMMENT); dr= new RuleBasedDamagerRepairer(getStringScanner()); reconciler.setDamager(dr, JavaPartitionScanner.JAVA_STRING); reconciler.setRepairer(dr, JavaPartitionScanner.JAVA_STRING); return reconciler; } | 9698 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/9698/b4a0728afa1c16b9aa827d94c0360aa842d25f91/JavaSourceViewerConfiguration.java/clean/org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/text/JavaSourceViewerConfiguration.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
2971,
1581,
367,
426,
11504,
2895,
1689,
1581,
367,
426,
11504,
2895,
12,
45,
1830,
18415,
1084,
18415,
13,
288,
202,
202,
6351,
367,
426,
11504,
2895,
19078,
2895,
33,
394,
251... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
2971,
1581,
367,
426,
11504,
2895,
1689,
1581,
367,
426,
11504,
2895,
12,
45,
1830,
18415,
1084,
18415,
13,
288,
202,
202,
6351,
367,
426,
11504,
2895,
19078,
2895,
33,
394,
251... |
/** * @see org.eclipse.swt.events.KeyAdapter#keyReleased(org.eclipse.swt.events.KeyEvent) */ public void keyReleased( KeyEvent e ) | /** * @see org.eclipse.swt.events.KeyAdapter#keyReleased(org.eclipse.swt.events.KeyEvent) */ public void keyReleased( KeyEvent e ) { if ( e.keyCode == SWT.DEL && e.stateMask == 0 && !getSelection( ).isEmpty( ) ) { doRemove( ); } } } ); } tableViewer.addDoubleClickListener( new IDoubleClickListener( ) { public void doubleClick( DoubleClickEvent event ) | private void createTableViewer( int tableStyle ) { Table table = new Table( this, tableStyle | SWT.FULL_SELECTION | SWT.BORDER ); table.setLayoutData( new GridData( GridData.FILL_BOTH ) ); tableViewer = new TableViewer( table ); table.addKeyListener( new KeyAdapter( ) { /** * @see org.eclipse.swt.events.KeyAdapter#keyReleased(org.eclipse.swt.events.KeyEvent) */ public void keyReleased( KeyEvent e ) { if ( e.keyCode == SWT.DEL && e.stateMask == 0 && !getSelection( ).isEmpty( ) && modifier.removeItem( getSelection( ).toArray( ) ) ) { tableViewer.refresh( ); updateButtons( ); } } } ); } | 46013 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/46013/9def0d3f4770404bae8ad9c41d93b5cca9b94576/TableArea.java/buggy/UI/org.eclipse.birt.report.designer.ui/src/org/eclipse/birt/report/designer/internal/ui/swt/custom/TableArea.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
918,
19565,
18415,
12,
509,
1014,
2885,
262,
202,
95,
202,
202,
1388,
1014,
273,
394,
3555,
12,
333,
16,
1014,
2885,
9506,
202,
96,
348,
8588,
18,
18111,
67,
1090,
15445,
950... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
19565,
18415,
12,
509,
1014,
2885,
262,
202,
95,
202,
202,
1388,
1014,
273,
394,
3555,
12,
333,
16,
1014,
2885,
9506,
202,
96,
348,
8588,
18,
18111,
67,
1090,
15445,
950... |
int first_entity = game.getFirstEntityNum(getLocalPlayer()); | int first_entity = game.getFirstEntityNum(); | public void calculateFiringTurn() { int first_entity = game.getFirstEntityNum(getLocalPlayer()); int entity_num = first_entity; int best_entity = first_entity; double max = java.lang.Double.MIN_VALUE; int[] results = null; Vector winner = null; int arc = 0; boolean infMoveLast = game.getOptions().booleanOption("inf_move_last"); boolean infMoveMulti = game.getOptions().booleanOption("inf_move_multi"); if (entity_num == -1) { return; } do { Entity en = game.getEntity(entity_num); CEntity cen = this.enemies.get(en); // Are we firing a non-Infantry entity in // the middle of an Infantry block? if ( infMoveMulti && (turnInfMoved % Game.INF_MOVE_MULTI) > 0 && !(en instanceof Infantry) ) { // Does this player still have infantry to fire? if ( game.hasInfantry(this.local_pn) ) { // Yup. Ignore this entity and check the next one. entity_num = game.getNextEntityNum(getLocalPlayer(), entity_num); continue; } else { // Nope. Reset the infantry counter. turnInfMoved = 0; } } // End check-inf_move_multi //if (en.canFlipArms()) //more logic int attacks[] = new int[3]; Vector front = new Vector(); Vector left = new Vector(); Vector right = new Vector(); int o_facing = en.getFacing(); for (Enumeration i = en.getWeapons();i.hasMoreElements();) { Mounted mw = (Mounted)i.nextElement(); Vector c = this.calculateWeaponAttacks(en, mw); if (c.size() > 0) { front.add(c); attacks[0] = Math.max(attacks[0], c.size()); } en.setSecondaryFacing((o_facing + 5)%6); c = this.calculateWeaponAttacks(en, mw); if (c.size() > 0) { left.add(c); attacks[1] = Math.max(attacks[1], c.size()); } en.setSecondaryFacing((o_facing + 1)%6); c = this.calculateWeaponAttacks(en, mw); if (c.size() > 0) { right.add(c); attacks[2] = Math.max(attacks[2], c.size()); } en.setSecondaryFacing(o_facing); } Vector arcs = new Vector(); arcs.add(front); if (!cen.entity.isProne()){ arcs.add(left); arcs.add(right); } for (int i = 0; i < arcs.size(); i++) { Vector v = (Vector)arcs.elementAt(i); if (v.size() > 0) { try { GAAttack test = new GAAttack(game, this.enemies.get(en), v, Math.max((v.size()+attacks[i])*4,50), 100, en.isEnemyOf((Entity)getEntitiesOwned().elementAt(0))); Thread threadTest = new Thread(test); threadTest.start(); threadTest.join(); if (test.getFittestChromosomesFitness() > max) { max = test.getFittestChromosomesFitness(); results = test.getResultChromosome(); arc = i; best_entity = entity_num; winner = (Vector)arcs.elementAt(arc); } } catch (GAException gae) { System.out.println(gae.getMessage()); } catch (Exception e) { e.printStackTrace(); } } } entity_num = game.getNextEntityNum(getLocalPlayer(), entity_num); } while (entity_num != first_entity && entity_num != -1); java.util.Vector av = new java.util.Vector(); //maximum already selected (or default) Entity en = game.getEntity(best_entity); if (results != null) { Entity primary_target = (Entity)(Compute.vectorToArray(game.getEntitiesVector())[results[results.length - 1]]); TreeMap tm = new TreeMap(new TestBot.AttackOptionSorter(this.enemies.get(primary_target))); for (int i = 0; i < results.length - 1; i++) { AttackOption a = (AttackOption)((Vector)winner.elementAt(i)).elementAt(results[i]); if (a.target != null) { a.target.expected_damage[a.toHit.getSideTable()] += a.value; a.target.hasTakenDamage = true; tm.put(a, a); } } com.sun.java.util.collections.Iterator i = tm.values().iterator(); while (i.hasNext()) { AttackOption a = (AttackOption)i.next(); av.addElement(new WeaponAttackAction(en.getId(),a.target.entity.getId(), en.getEquipmentNum(a.weapon))); } } switch (arc) { case 1: av.insertElementAt(new TorsoTwistAction(en.getId(), (en.getFacing() + 5)%6),0); break; case 2: av.insertElementAt(new TorsoTwistAction(en.getId(), (en.getFacing() + 1)%6),0); break; } //System.out.println(max); sendAttackData(best_entity, av); } | 3464 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/3464/4477a26e4a82c5d3e8c4c6cf18a29b72cbfcba69/TestBot.java/buggy/megamek/src/megamek/client/bot/TestBot.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
918,
4604,
42,
11256,
15858,
1435,
288,
565,
509,
1122,
67,
1096,
273,
7920,
18,
588,
3759,
1943,
2578,
5621,
565,
509,
1522,
67,
2107,
273,
1122,
67,
1096,
31,
565,
509,
3796,
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,
282,
1071,
918,
4604,
42,
11256,
15858,
1435,
288,
565,
509,
1122,
67,
1096,
273,
7920,
18,
588,
3759,
1943,
2578,
5621,
565,
509,
1522,
67,
2107,
273,
1122,
67,
1096,
31,
565,
509,
3796,
67... |
if (!namespacesPrefix && !namespaces) { namespacesPrefix = true; } | if (!namespacesPrefix && !namespaces) { namespacesPrefix = true; } | protected void initialize() { if (this.parser == null) { this.parser = ParserBuilder.createDefaultParser(); } if (this.encoding == null) { this.encoding = DXFParser.DEFAULT_ENCODING; } if (!namespacesPrefix && !namespaces) { namespacesPrefix = true; } if (validation) { externalGeneralEntities = true; externalParameterEntities = true; } } | 4096 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/4096/97da13d420d72405018ba732b60712bffbfe3482/DXF2SVGReader.java/clean/src/java/org/kabeja/svg/DXF2SVGReader.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
4750,
918,
4046,
1435,
288,
3639,
309,
261,
2211,
18,
4288,
422,
446,
13,
288,
5411,
333,
18,
4288,
273,
6783,
1263,
18,
2640,
1868,
2678,
5621,
3639,
289,
3639,
309,
261,
2211,
18,
599... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
4046,
1435,
288,
3639,
309,
261,
2211,
18,
4288,
422,
446,
13,
288,
5411,
333,
18,
4288,
273,
6783,
1263,
18,
2640,
1868,
2678,
5621,
3639,
289,
3639,
309,
261,
2211,
18,
599... |
protected StandardCElementLabelProvider createLabelProvider() { return new StandardCElementLabelProvider(); | protected CElementLabelProvider createLabelProvider() { return new CViewLabelProvider(); | protected StandardCElementLabelProvider createLabelProvider() { return new StandardCElementLabelProvider(); } | 6192 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/6192/9b578a9f0c697b2f52cc44da59ec1182dc029186/CView.java/clean/core/org.eclipse.cdt.ui/src/org/eclipse/cdt/internal/ui/cview/CView.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1117,
8263,
39,
1046,
2224,
2249,
752,
2224,
2249,
1435,
288,
202,
202,
2463,
394,
8263,
39,
1046,
2224,
2249,
5621,
202,
97,
2,
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,
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... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1117,
8263,
39,
1046,
2224,
2249,
752,
2224,
2249,
1435,
288,
202,
202,
2463,
394,
8263,
39,
1046,
2224,
2249,
5621,
202,
97,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,... |
myFirstIndexLabel .setLabelFor(myFirstIndex); myLastIndexLabel .setLabelFor(myLastIndexLabel); | myFirstIndexLabel.setLabelFor(myFirstIndex); myLastIndexLabel.setLabelFor(myLastIndexLabel); | public ArrayRendererConfigurable(ArrayRenderer renderer) { myRenderer = renderer; myFirstIndexLabel .setLabelFor(myFirstIndex); myLastIndexLabel .setLabelFor(myLastIndexLabel); myEntriesLimitLabel.setLabelFor(myEntriesLimit); DocumentListener listener = new DocumentListener() { private void updateEntriesLimit() { myEntriesLimit.setText(String.valueOf(getInt(myEndIndex) - getInt(myFirstIndex) + 1)); } public void changedUpdate(DocumentEvent e) { updateEntriesLimit(); } public void insertUpdate (DocumentEvent e) { updateEntriesLimit(); } public void removeUpdate (DocumentEvent e) { updateEntriesLimit(); } }; myFirstIndex.getDocument().addDocumentListener(listener); myEndIndex.getDocument().addDocumentListener(listener); } | 17306 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/17306/bfe82dc83a75d544fa3ff4054e33414a2a195961/ArrayRendererConfigurable.java/buggy/source/com/intellij/debugger/settings/ArrayRendererConfigurable.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
1510,
6747,
31660,
12,
1076,
6747,
5690,
13,
288,
565,
3399,
6747,
273,
5690,
31,
565,
3399,
3759,
1016,
2224,
225,
263,
542,
2224,
1290,
12,
4811,
3759,
1016,
1769,
565,
3399,
3024... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1510,
6747,
31660,
12,
1076,
6747,
5690,
13,
288,
565,
3399,
6747,
273,
5690,
31,
565,
3399,
3759,
1016,
2224,
225,
263,
542,
2224,
1290,
12,
4811,
3759,
1016,
1769,
565,
3399,
3024... |
" 115 invokevirtual java.io.PrintStream.println(int) : void [27]\n" + | " 115 invokevirtual java.io.PrintStream.println(int) : void [22]\n" + | public void test021() { this.runConformTest( new String[] { "X.java", "public class X {\n" + " public static void main(String[] args) {\n" + " int[] tab = new int[] { 1, 2, 3, 4, 5, 6, 7, 8, 9 };\n" + " int sum = 0;\n" + " int i = 0;\n" + " loop1: while(true) {\n" + " i++;\n" + " loop: for (final int e : tab) {\n" + " sum += e;\n" + " if (i == 3) {\n" + " break loop1;\n" + " } else if (e == 5) {\n" + " break loop;\n" + " } else {\n" + " continue;\n" + " }\n" + " }\n" + " }\n" + " System.out.println(sum);\n" + " }\n" + "}", }, "31"); String expectedOutput = " // Method descriptor #15 ([Ljava/lang/String;)V\n" + " // Stack: 4, Locals: 8\n" + " public static void main(String[] args);\n" + " 0 bipush 9\n" + " 2 newarray int [10]\n" + " 4 dup\n" + " 5 iconst_0\n" + " 6 iconst_1\n" + " 7 iastore\n" + " 8 dup\n" + " 9 iconst_1\n" + " 10 iconst_2\n" + " 11 iastore\n" + " 12 dup\n" + " 13 iconst_2\n" + " 14 iconst_3\n" + " 15 iastore\n" + " 16 dup\n" + " 17 iconst_3\n" + " 18 iconst_4\n" + " 19 iastore\n" + " 20 dup\n" + " 21 iconst_4\n" + " 22 iconst_5\n" + " 23 iastore\n" + " 24 dup\n" + " 25 iconst_5\n" + " 26 bipush 6\n" + " 28 iastore\n" + " 29 dup\n" + " 30 bipush 6\n" + " 32 bipush 7\n" + " 34 iastore\n" + " 35 dup\n" + " 36 bipush 7\n" + " 38 bipush 8\n" + " 40 iastore\n" + " 41 dup\n" + " 42 bipush 8\n" + " 44 bipush 9\n" + " 46 iastore\n" + " 47 astore_1 [tab]\n" + " 48 iconst_0\n" + " 49 istore_2 [sum]\n" + " 50 iconst_0\n" + " 51 istore_3 [i]\n" + " 52 iinc 3 1 [i]\n" + " 55 aload_1 [tab]\n" + " 56 astore 7\n" + " 58 iconst_0\n" + " 59 istore 5\n" + " 61 aload 7\n" + " 63 arraylength\n" + " 64 istore 6\n" + " 66 goto 101\n" + " 69 aload 7\n" + " 71 iload 5\n" + " 73 iaload\n" + " 74 istore 4 [e]\n" + " 76 iload_2 [sum]\n" + " 77 iload 4 [e]\n" + " 79 iadd\n" + " 80 istore_2 [sum]\n" + " 81 iload_3 [i]\n" + " 82 iconst_3\n" + " 83 if_icmpne 89\n" + " 86 goto 111\n" + " 89 iload 4 [e]\n" + " 91 iconst_5\n" + " 92 if_icmpne 98\n" + " 95 goto 108\n" + " 98 iinc 5 1\n" + " 101 iload 5\n" + " 103 iload 6\n" + " 105 if_icmplt 69\n" + " 108 goto 52\n" + " 111 getstatic java.lang.System.out : java.io.PrintStream [21]\n" + " 114 iload_2 [sum]\n" + " 115 invokevirtual java.io.PrintStream.println(int) : void [27]\n" + " 118 return\n" + " Line numbers:\n" + " [pc: 0, line: 3]\n" + " [pc: 48, line: 4]\n" + " [pc: 50, line: 5]\n" + " [pc: 52, line: 7]\n" + " [pc: 55, line: 8]\n" + " [pc: 76, line: 9]\n" + " [pc: 81, line: 10]\n" + " [pc: 86, line: 11]\n" + " [pc: 89, line: 12]\n" + " [pc: 95, line: 13]\n" + " [pc: 101, line: 8]\n" + " [pc: 108, line: 6]\n" + " [pc: 111, line: 19]\n" + " [pc: 118, line: 20]\n" + " Local variable table:\n" + " [pc: 0, pc: 119] local: args index: 0 type: java.lang.String[]\n" + " [pc: 48, pc: 119] local: tab index: 1 type: int[]\n" + " [pc: 50, pc: 119] local: sum index: 2 type: int\n" + " [pc: 52, pc: 119] local: i index: 3 type: int\n" + " [pc: 76, pc: 108] local: e index: 4 type: int\n"; try { File f = new File(OUTPUT_DIR + File.separator + "X.class"); byte[] classFileBytes = org.eclipse.jdt.internal.compiler.util.Util.getFileByteContent(f); ClassFileBytesDisassembler disassembler = ToolFactory.createDefaultClassFileBytesDisassembler(); String result = disassembler.disassemble(classFileBytes, "\n", ClassFileBytesDisassembler.DETAILED); int index = result.indexOf(expectedOutput); if (index == -1 || expectedOutput.length() == 0) { System.out.println(Util.displayString(result, 3)); } if (index == -1) { assertEquals("Wrong contents", expectedOutput, result); } } catch (org.eclipse.jdt.core.util.ClassFormatException e) { assertTrue(false); } catch (IOException e) { assertTrue(false); }} | 10698 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/10698/c17970bb54810597f5d28802d36bfac65d844634/ForeachStatementTest.java/buggy/org.eclipse.jdt.core.tests.compiler/src/org/eclipse/jdt/core/tests/compiler/regression/ForeachStatementTest.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1071,
918,
1842,
3103,
21,
1435,
288,
225,
202,
2211,
18,
2681,
442,
687,
4709,
12,
202,
202,
2704,
514,
8526,
288,
1082,
202,
6,
60,
18,
6290,
3113,
1082,
202,
6,
482,
667,
1139,
18890,
8... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
918,
1842,
3103,
21,
1435,
288,
225,
202,
2211,
18,
2681,
442,
687,
4709,
12,
202,
202,
2704,
514,
8526,
288,
1082,
202,
6,
60,
18,
6290,
3113,
1082,
202,
6,
482,
667,
1139,
18890,
8... |
{ m_wizardPage = page; } | { DEFAULT_MESSAGE = JdbcPlugin.getResourceString( "wizard.message.createDataSource" ); m_wizardPage = page; } | JDBCSelectionPageHelper( WizardPage page ) { m_wizardPage = page; } | 5230 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5230/852b0cefc63f18aec11946d9ebc2ac81cec8aca0/JDBCSelectionPageHelper.java/buggy/data/org.eclipse.birt.report.data.oda.jdbc.ui/src/org/eclipse/birt/report/data/oda/jdbc/ui/profile/JDBCSelectionPageHelper.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
16364,
6233,
1964,
2276,
12,
678,
13412,
1964,
1363,
262,
565,
288,
3639,
312,
67,
31837,
1964,
273,
1363,
31,
565,
289,
2,
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,
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... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
16364,
6233,
1964,
2276,
12,
678,
13412,
1964,
1363,
262,
565,
288,
3639,
312,
67,
31837,
1964,
273,
1363,
31,
565,
289,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
return getElseNode().eval(ruby, self); | return self.eval(getElseNode()); | public RubyObject eval(Ruby ruby, RubyObject self) { ruby.setSourceLine(getLine()); if (getConditionNode().eval(ruby, self).isTrue()) { return getBodyNode().eval(ruby, self); } else { return getElseNode().eval(ruby, self); } } | 52337 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52337/12748a4b8db7fd4836cd04c81e3cf2343735bfb6/IfNode.java/buggy/org/jruby/nodes/IfNode.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
19817,
921,
5302,
12,
54,
10340,
22155,
16,
19817,
921,
365,
13,
288,
3639,
22155,
18,
542,
1830,
1670,
12,
588,
1670,
10663,
7734,
309,
261,
588,
3418,
907,
7675,
8622,
12,
27768,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
19817,
921,
5302,
12,
54,
10340,
22155,
16,
19817,
921,
365,
13,
288,
3639,
22155,
18,
542,
1830,
1670,
12,
588,
1670,
10663,
7734,
309,
261,
588,
3418,
907,
7675,
8622,
12,
27768,
... |
queryStatus.add(Status.OK_STATUS); return hits; | return Status.OK_STATUS; | public List<AbstractQueryHit> performQuery(AbstractRepositoryQuery repositoryQuery, final IProgressMonitor monitor, MultiStatus queryStatus) { List<AbstractQueryHit> hits = new ArrayList<AbstractQueryHit>(); final List<Issue> issues = new ArrayList<Issue>(); TaskRepository repository = TasksUiPlugin.getRepositoryManager().getRepository( MylarJiraPlugin.REPOSITORY_KIND, repositoryQuery.getRepositoryUrl()); JiraIssueCollector collector = new JiraIssueCollector(monitor, issues); try { JiraServer jiraServer = JiraServerFacade.getDefault().getJiraServer(repository); if (repositoryQuery instanceof JiraRepositoryQuery) { jiraServer.search(((JiraRepositoryQuery) repositoryQuery).getNamedFilter(), collector); } else if (repositoryQuery instanceof JiraCustomQuery) { jiraServer.search(((JiraCustomQuery) repositoryQuery).getFilterDefinition(), collector); } } catch (Throwable t) { queryStatus.add(new Status(IStatus.OK, TasksUiPlugin.PLUGIN_ID, IStatus.OK, "Could not log in to server: " + repositoryQuery.getRepositoryUrl() + "\n\nCheck network connection.", t)); return hits; } // TODO: work-around no other way of determining failure if (!collector.isDone()) { queryStatus.add(new Status(IStatus.OK, TasksUiPlugin.PLUGIN_ID, IStatus.OK, "Could not log in to server: " + repositoryQuery.getRepositoryUrl() + "\n\nCheck network connection.", new UnknownHostException())); return hits; } for (Issue issue : issues) { String issueId = issue.getId(); String handleIdentifier = AbstractRepositoryTask.getHandle(repository.getUrl(), issueId); ITask task = TasksUiPlugin.getTaskListManager().getTaskList().getTask(handleIdentifier); if (!(task instanceof JiraTask)) { task = createTask(issue, handleIdentifier); } updateTaskDetails(repository.getUrl(), (JiraTask) task, issue, false); JiraQueryHit hit = new JiraQueryHit((JiraTask) task, repositoryQuery.getRepositoryUrl(), issueId); hits.add(hit); } queryStatus.add(Status.OK_STATUS); return hits; } | 51151 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/51151/b7718da2b050618d6137478a5c240f368f3687e9/JiraRepositoryConnector.java/buggy/org.eclipse.mylyn.jira.ui/src/org/eclipse/mylyn/internal/jira/JiraRepositoryConnector.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
987,
32,
7469,
1138,
13616,
34,
3073,
1138,
12,
7469,
3305,
1138,
3352,
1138,
16,
727,
467,
5491,
7187,
6438,
16,
1082,
202,
5002,
1482,
843,
1482,
13,
288,
202,
202,
682,
32,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
987,
32,
7469,
1138,
13616,
34,
3073,
1138,
12,
7469,
3305,
1138,
3352,
1138,
16,
727,
467,
5491,
7187,
6438,
16,
1082,
202,
5002,
1482,
843,
1482,
13,
288,
202,
202,
682,
32,... |
ReflectionMetaDataMaker.createClassMetaData(declaringClass), ReflectionMetaDataMaker.createFieldMetaData(field), | MetaDataMaker.getReflectionMetaDataMaker(declaringClass.getClassLoader()).createClassMetaData(declaringClass), MetaDataMaker.getReflectionMetaDataMaker(declaringClass.getClassLoader()).createFieldMetaData(field), | private static RttiInfo setRttiInfo( final int joinPointType, final int joinPointHash, final Class declaringClass, final AspectSystem system, final Object thisInstance, final Object targetInstance) { RttiInfo tuple = new RttiInfo(); switch (joinPointType) { case JoinPointType.METHOD_EXECUTION: MethodTuple methodTuple = AspectRegistry.getMethodTuple(declaringClass, joinPointHash); MethodSignatureImpl methodSignature = new MethodSignatureImpl(methodTuple.getDeclaringClass(), methodTuple); tuple.signature = methodSignature; tuple.rtti = new MethodRttiImpl(methodSignature, thisInstance, targetInstance); tuple.cflowExpressions = new ArrayList(); for (int i = 0; i < system.getAspectManagers().length; i++) { tuple.cflowExpressions.addAll(system.getAspectManager(i).getCFlowExpressions( ReflectionMetaDataMaker.createClassMetaData(declaringClass), ReflectionMetaDataMaker.createMethodMetaData(methodTuple.getWrapperMethod()), null, PointcutType.EXECUTION //TODO CAN BE @CALL - see proceedWithCallJoinPoint )); } break; case JoinPointType.METHOD_CALL: methodTuple = AspectRegistry.getMethodTuple(declaringClass, joinPointHash); methodSignature = new MethodSignatureImpl(methodTuple.getDeclaringClass(), methodTuple); tuple.signature = methodSignature; tuple.rtti = new MethodRttiImpl(methodSignature, thisInstance, targetInstance); tuple.cflowExpressions = new ArrayList(); for (int i = 0; i < system.getAspectManagers().length; i++) { tuple.cflowExpressions.addAll(system.getAspectManager(i).getCFlowExpressions( ReflectionMetaDataMaker.createClassMetaData(declaringClass), ReflectionMetaDataMaker.createMethodMetaData(methodTuple.getWrapperMethod()), null, PointcutType.CALL //TODO CAN BE @CALL - see proceedWithCallJoinPoint )); } break; case JoinPointType.CONSTRUCTOR_CALL: ConstructorTuple constructorTuple = AspectRegistry.getConstructorTuple( declaringClass, joinPointHash ); ConstructorSignatureImpl constructorSignature = new ConstructorSignatureImpl( constructorTuple.getDeclaringClass(), constructorTuple ); tuple.signature = constructorSignature; tuple.rtti = new ConstructorRttiImpl(constructorSignature, thisInstance, targetInstance); tuple.cflowExpressions = new ArrayList(); for (int i = 0; i < system.getAspectManagers().length; i++) { tuple.cflowExpressions.addAll(system.getAspectManager(i).getCFlowExpressions( ReflectionMetaDataMaker.createClassMetaData(declaringClass), ReflectionMetaDataMaker.createConstructorMetaData(constructorTuple.getWrapperConstructor()), null, PointcutType.CALL )); } break; case JoinPointType.CONSTRUCTOR_EXECUTION: constructorTuple = AspectRegistry.getConstructorTuple(declaringClass, joinPointHash); constructorSignature = new ConstructorSignatureImpl( constructorTuple.getDeclaringClass(), constructorTuple ); tuple.signature = constructorSignature; tuple.rtti = new ConstructorRttiImpl(constructorSignature, thisInstance, targetInstance); tuple.cflowExpressions = new ArrayList(); for (int i = 0; i < system.getAspectManagers().length; i++) { tuple.cflowExpressions.addAll(system.getAspectManager(i).getCFlowExpressions( ReflectionMetaDataMaker.createClassMetaData(declaringClass), ReflectionMetaDataMaker.createConstructorMetaData(constructorTuple.getWrapperConstructor()), null, PointcutType.EXECUTION )); } break; case JoinPointType.FIELD_SET: Field field = AspectRegistry.getField(declaringClass, joinPointHash); FieldSignatureImpl fieldSignature = new FieldSignatureImpl(field.getDeclaringClass(), field); tuple.signature = fieldSignature; tuple.rtti = new FieldRttiImpl(fieldSignature, thisInstance, targetInstance); tuple.cflowExpressions = new ArrayList(); for (int i = 0; i < system.getAspectManagers().length; i++) { tuple.cflowExpressions.addAll(system.getAspectManager(i).getCFlowExpressions( ReflectionMetaDataMaker.createClassMetaData(declaringClass), ReflectionMetaDataMaker.createFieldMetaData(field), null, PointcutType.SET )); } break; case JoinPointType.FIELD_GET: field = AspectRegistry.getField(declaringClass, joinPointHash); fieldSignature = new FieldSignatureImpl(field.getDeclaringClass(), field); tuple.signature = fieldSignature; tuple.rtti = new FieldRttiImpl(fieldSignature, thisInstance, targetInstance); tuple.cflowExpressions = new ArrayList(); for (int i = 0; i < system.getAspectManagers().length; i++) { tuple.cflowExpressions.addAll(system.getAspectManager(i).getCFlowExpressions( ReflectionMetaDataMaker.createClassMetaData(declaringClass), ReflectionMetaDataMaker.createFieldMetaData(field), null, PointcutType.GET )); } break; case JoinPointType.HANDLER: // TODO: enable cflow for catch clauses// tuple.cflowExpressions = m_system.getAspectManager().getCFlowExpressions(// ReflectionMetaDataMaker.createClassMetaData(declaringClass),// ReflectionMetaDataMaker.createCatchClauseMetaData(methodSignature)// ); throw new UnsupportedOperationException("handler is not support yet"); case JoinPointType.STATIC_INITALIZATION: throw new UnsupportedOperationException("static initialization is not support yet"); } if (tuple.cflowExpressions == null) { tuple.cflowExpressions = EMTPTY_ARRAY_LIST; } return tuple; } | 7954 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/7954/6f8616a2dc12a90f3e05e2c8ffea567dda54b5cb/JitCompiler.java/buggy/aspectwerkz2/src/main/org/codehaus/aspectwerkz/joinpoint/management/JitCompiler.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
760,
534,
748,
77,
966,
444,
54,
748,
77,
966,
12,
5411,
727,
509,
1233,
2148,
559,
16,
5411,
727,
509,
1233,
2148,
2310,
16,
5411,
727,
1659,
3496,
14682,
16,
5411,
727,
2970,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
534,
748,
77,
966,
444,
54,
748,
77,
966,
12,
5411,
727,
509,
1233,
2148,
559,
16,
5411,
727,
509,
1233,
2148,
2310,
16,
5411,
727,
1659,
3496,
14682,
16,
5411,
727,
2970,
... |
if (bindings instanceof Symbol) | if (bindings instanceof String) | public LambdaExp (Object formals, Object body, Translator tr) { /* Count formals, while checking that the syntax is OK. */ Object bindings = formals; int opt_args = -1; int rest_args = -1; int key_args = -1; Pair pair; for (; bindings instanceof Pair; bindings = pair.cdr) { pair = (Pair) bindings; if (pair.car == Special.optional) { if (opt_args >= 0) { tr.syntaxError ("multiple #!optional in parameter list"); return; } else if (rest_args >= 0 || key_args >= 0) { tr.syntaxError ("#!optional after #!rest or #!key"); return; } opt_args = 0; } else if (pair.car == Special.rest) { if (rest_args >= 0) { tr.syntaxError ("multiple #!rest in parameter list"); return; } else if (key_args >= 0) { tr.syntaxError ("#!rest after #!key"); return; } rest_args = 0; } else if (pair.car == Special.key) { if (key_args >= 0) { tr.syntaxError ("multiple #!key in parameter list"); return; } key_args = 0; } else if (key_args >= 0) key_args++; else if (rest_args >= 0) rest_args++; else if (opt_args >= 0) opt_args++; else min_args++; bindings = pair.cdr; } if (bindings instanceof Symbol) { if (opt_args >= 0 || key_args >= 0 || rest_args >= 0) { tr.syntaxError ("dotted rest-arg after #!optional, #!rest, or #!key"); return; } rest_args = 1; } else if (bindings != List.Empty) { tr.syntaxError ("misformed formals in lambda"); return; } if (rest_args > 1) { tr.syntaxError ("multiple #!rest parameters"); return; } if (opt_args < 0) opt_args = 0; if (rest_args < 0) rest_args = 0; if (key_args < 0) key_args = 0; if (rest_args > 0) max_args = -1; else max_args = min_args + opt_args + 2 * key_args; // Is this useful? if (opt_args + key_args > 0) defaultArgs = new Expression[opt_args + key_args]; if (key_args > 0) keywords = new Keyword[key_args]; Variable var; var = addDeclaration (Symbol.make ("this")); var.setParameter (true); var.setArtificial (true); if (min_args != max_args || min_args > 4) { // Compilation.compile depends on the "argsArray" variable // being the second one created for this scope. argsArray = addDeclaration (Symbol.make ("argsArray"), Compilation.objArrayType); argsArray.setParameter (true); argsArray.setArtificial (true); } push (tr); bindings = formals; int i = 0; opt_args = 0; key_args = 0; Object mode = null; for (; bindings instanceof Pair; bindings = pair.cdr) { pair = (Pair) bindings; if (pair.car == Special.optional || pair.car == Special.rest || pair.car == Special.key) { mode = pair.car; continue; } Symbol name; Object defaultValue; if (pair.car instanceof Symbol) { name = (Symbol) pair.car; defaultValue = null; } else if (pair.car instanceof Pair && ((Pair) pair.car).car instanceof Symbol && ((Pair) pair.car).cdr instanceof Pair) { Pair pair_car = (Pair) pair.car; name = (Symbol) pair_car.car; defaultValue = ((Pair) pair_car.cdr).car; if (mode == null || mode == Special.rest) { tr.syntaxError ("default value for required or #!rest parameter"); return; } } else { tr.syntaxError ("parameter is neither name nor (name default)"); return; } if (mode == Special.optional || mode == Special.key) { defaultArgs[opt_args++] = defaultValue == null ? QuoteExp.falseExp : tr.rewrite(defaultValue); } if (mode == Special.key) keywords[key_args++] = Keyword.make(name.toString()); Declaration decl = addDeclaration (name); decl.setParameter(true); decl.noteValue(null); // Does not have a known value. decl.push(tr); } if (bindings instanceof Symbol) { Declaration decl = addDeclaration ((Symbol) bindings); decl.setParameter (true); decl.noteValue (null); // Does not have a known value. decl.push(tr); } this.body = tr.rewrite_body (body); pop (tr); } | 36870 /local/tlutelli/issta_data/temp/all_java3context/java/2006_temp/2006/36870/9933571afc04a317d6c4f5d01a969d3b5695a14e/LambdaExp.java/clean/kawa/lang/LambdaExp.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
12801,
2966,
261,
921,
646,
1031,
16,
1033,
1417,
16,
18669,
433,
13,
225,
288,
565,
1748,
6974,
646,
1031,
16,
1323,
6728,
716,
326,
6279,
353,
7791,
18,
1195,
565,
1033,
7394,
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,
282,
1071,
12801,
2966,
261,
921,
646,
1031,
16,
1033,
1417,
16,
18669,
433,
13,
225,
288,
565,
1748,
6974,
646,
1031,
16,
1323,
6728,
716,
326,
6279,
353,
7791,
18,
1195,
565,
1033,
7394,
2... |
log(pAnnotationType, annotationType); | log(2, pAnnotationType, annotationType); | public static AnnotationTypeEnum valueOf(String pAnnotationType) { if (pAnnotationType == null) { throw new IllegalArgumentException("pAnnotationType is null"); } AnnotationTypeEnum annotationType; if (pAnnotationType.equals(JAVADOC_ANNOTATION_TYPE)) { annotationType = JAVADOC; } else if (pAnnotationType.equals(JDK_ANNOTATION_TYPE)) { annotationType = JDK; } else if (pAnnotationType.equals("1.4") || pAnnotationType.toLowerCase().equals(JAVADOC_ANNOTATION_TYPE.toLowerCase())) { // For backward compatibility only annotationType = JAVADOC; log(pAnnotationType, annotationType); } else if ("1.5".equals(pAnnotationType) || pAnnotationType.toLowerCase().equals(JDK_ANNOTATION_TYPE.toLowerCase())) { // For backward compatibility only annotationType = JDK; log(pAnnotationType, annotationType); } else if ("jdk1.5".equals(pAnnotationType.toLowerCase()) || "jdk5".equals(pAnnotationType.toLowerCase())) { // For backward compatibility only annotationType = JDK; log(pAnnotationType, annotationType); } else { // For backward compatibility only // TODO should we make this an error? annotationType = VersionInfo.getDefaultAnnotationType(); log(pAnnotationType, annotationType); } if (VersionInfo.IS_JDK14 && annotationType == JDK) { throw new IllegalArgumentException( "Cannot specify \"" + pAnnotationType + "\" with 1.4 version of TestNG"); } return annotationType; } | 50994 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50994/fd3d62963585c7d537041ba7ed53ebda5eef31c4/AnnotationTypeEnum.java/buggy/src/main/org/testng/internal/AnnotationTypeEnum.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
760,
6090,
10549,
4323,
12,
780,
293,
3257,
559,
13,
288,
565,
309,
261,
84,
3257,
559,
422,
446,
13,
288,
1377,
604,
394,
2754,
2932,
84,
3257,
559,
353,
446,
8863,
565,
289,
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,
282,
1071,
760,
6090,
10549,
4323,
12,
780,
293,
3257,
559,
13,
288,
565,
309,
261,
84,
3257,
559,
422,
446,
13,
288,
1377,
604,
394,
2754,
2932,
84,
3257,
559,
353,
446,
8863,
565,
289,
3... |
node.setInTheModel(true); | node.setXMLTagName("extension"); | private PluginExtensionNode createExtension(IDocumentNode parent) { PluginExtensionNode node = new PluginExtensionNode(); node.setParentNode(parent); node.setModel(fModel); node.setInTheModel(true); return node; } | 14404 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/14404/5f54aeb0c6b0dedbd16348f38c2089aa976e950f/PluginDocumentNodeFactory.java/buggy/ui/org.eclipse.pde.core/text/org/eclipse/pde/internal/core/text/plugin/PluginDocumentNodeFactory.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
6258,
3625,
907,
752,
3625,
12,
734,
504,
650,
907,
982,
13,
288,
202,
202,
3773,
3625,
907,
756,
273,
394,
6258,
3625,
907,
5621,
202,
202,
2159,
18,
542,
3054,
907,
12,
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,
6258,
3625,
907,
752,
3625,
12,
734,
504,
650,
907,
982,
13,
288,
202,
202,
3773,
3625,
907,
756,
273,
394,
6258,
3625,
907,
5621,
202,
202,
2159,
18,
542,
3054,
907,
12,
2... |
String sql = txtCommand.getText(); | private void executeSQL() { String[] g = new String[1]; String sql = txtCommand.getText(); try { lTime = System.currentTimeMillis(); sStatement.execute(sql); int r = sStatement.getUpdateCount(); if (r == -1) { formatResultSet(sStatement.getResultSet()); } else { g[0] = "update count"; gResult.setHead(g); g[0] = "" + r; gResult.addRow(g); } lTime = System.currentTimeMillis() - lTime; addToRecent(sql); } catch (SQLException e) { lTime = System.currentTimeMillis() - lTime; g[0] = "SQL Error"; gResult.setHead(g); String s = e.getMessage(); s += " / Error Code: " + e.getErrorCode(); s += " / State: " + e.getSQLState(); g[0] = s; gResult.addRow(g); // Added: (weconsultants@users) CommonSwing.errorMessage(e); return; } if (autoRefresh) { // We're already running in a "busy" thread. Just update the // status text. setStatusLine("Refreshing object tree", 0); String upper = sql.toUpperCase(Locale.ENGLISH); // This test can be very liberal. Too liberal will just do // some extra refreshes. Too conservative will display // obsolete info. if (upper.indexOf("ALTER") > -1 || upper.indexOf("DROP") > -1 || upper.indexOf("CREATE") > -1) { directRefreshTree(); } } } | 49087 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/49087/90ee16014e0dc24a18b92afcee521b6a38c86718/DatabaseManagerSwing.java/clean/base-one/trunk/src/org/hsqldb/util/DatabaseManagerSwing.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
918,
1836,
3997,
1435,
288,
3639,
514,
8526,
314,
282,
273,
394,
514,
63,
21,
15533,
9079,
775,
288,
5411,
328,
950,
273,
2332,
18,
2972,
28512,
5621,
5411,
272,
3406,
18,
8837,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1435,
288,
3639,
514,
8526,
314,
282,
273,
394,
514,
63,
21,
15533,
9079,
775,
288,
5411,
328,
950,
273,
2332,
18,
2972,
28512,
5621,
5411,
272,
3406,
18,
8837,
1... | |
wasSelected = (lvItem.state & OS.LVIS_SELECTED) != 0; if (wasSelected) ignoreSelect = true; | if ((lvItem.state & OS.LVIS_SELECTED) != 0) wasSelected = true; | LRESULT sendMouseDownEvent (int type, int button, int msg, int wParam, int lParam) { /* * Feature in Windows. Inside WM_LBUTTONDOWN and WM_RBUTTONDOWN, * the widget starts a modal loop to determine if the user wants * to begin a drag/drop operation or marque select. Unfortunately, * this modal loop eats the corresponding mouse up. The fix is to * detect the cases when the modal loop has eaten the mouse up and * issue a fake mouse up. * * By observation, when the mouse is clicked anywhere but the check * box, the widget eats the mouse up. When the mouse is dragged, * the widget does not eat the mouse up. */ LVHITTESTINFO pinfo = new LVHITTESTINFO (); pinfo.x = (short) (lParam & 0xFFFF); pinfo.y = (short) (lParam >> 16); OS.SendMessage (handle, OS.LVM_HITTEST, 0, pinfo); sendMouseEvent (type, button, handle, msg, wParam, lParam); /* * Force the table to have focus so that when the user * reselects the focus item, the LVIS_FOCUSED state bits * for the item will be set. These bits are used when * the table is multi-select to issue the selection * event. If the user did not click on an item, then * set focus to the table so that it will come to the * front and take focus in the work around below. */ OS.SetFocus (handle); /* * Feature in Windows. When the user selects outside of * a table item, Windows deselects all the items, even * when the table is multi-select. While not strictly * wrong, this is unexpected. The fix is to detect the * case and avoid calling the window proc. */ if (pinfo.iItem == -1) { if (OS.GetCapture () != handle) OS.SetCapture (handle); return LRESULT.ZERO; } /* * Feature in Windows. When a table item is reselected * in a single-select table, Windows does not issue a * WM_NOTIFY because the item state has not changed. * This is strictly correct but is inconsistent with the * list widget and other widgets in Windows. The fix is * to detect the case when an item is reselected and issue * the notification. * * NOTE: This code runs for multi-select as well, ignoring * the selection that is issed from WM_NOTIFY. */ boolean wasSelected = false; int count = OS.SendMessage (handle, OS.LVM_GETSELECTEDCOUNT, 0, 0); if (count == 1 && pinfo.iItem != -1) { LVITEM lvItem = new LVITEM (); lvItem.mask = OS.LVIF_STATE; lvItem.stateMask = OS.LVIS_SELECTED; lvItem.iItem = pinfo.iItem; OS.SendMessage (handle, OS.LVM_GETITEM, 0, lvItem); wasSelected = (lvItem.state & OS.LVIS_SELECTED) != 0; if (wasSelected) ignoreSelect = true; } dragStarted = false; int code = callWindowProc (handle, msg, wParam, lParam); if (wasSelected) { ignoreSelect = false; Event event = new Event (); event.item = _getItem (pinfo.iItem); postEvent (SWT.Selection, event); } if (dragStarted) { if (OS.GetCapture () != handle) OS.SetCapture (handle); } else { int flags = OS.LVHT_ONITEMLABEL | OS.LVHT_ONITEMICON; boolean fakeMouseUp = (pinfo.flags & flags) != 0; if (!fakeMouseUp && (style & SWT.MULTI) != 0) { fakeMouseUp = (pinfo.flags & OS.LVHT_ONITEMSTATEICON) == 0; } if (fakeMouseUp) { mouseDown = false; sendMouseEvent (SWT.MouseUp, button, handle, msg, wParam, lParam); } } dragStarted = false; return new LRESULT (code);} | 12413 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/12413/14be55c4cbe46a16b7300921fd246420e99a1bad/Table.java/buggy/bundles/org.eclipse.swt/Eclipse SWT/win32/org/eclipse/swt/widgets/Table.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
511,
12289,
1366,
9186,
4164,
1133,
261,
474,
618,
16,
509,
3568,
16,
509,
1234,
16,
509,
341,
786,
16,
509,
328,
786,
13,
288,
202,
20308,
202,
14,
7881,
316,
8202,
18,
225,
657,
5564,
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,
511,
12289,
1366,
9186,
4164,
1133,
261,
474,
618,
16,
509,
3568,
16,
509,
1234,
16,
509,
341,
786,
16,
509,
328,
786,
13,
288,
202,
20308,
202,
14,
7881,
316,
8202,
18,
225,
657,
5564,
67... |
private void resolveExtendsElement( ) { DesignElement element = getElement( ); Module module = handler.getModule( ); ElementDefn defn = (ElementDefn) element.getDefn( ); // Resolve extends int id = defn.getNameSpaceID( ); assert id != MetaDataConstants.NO_NAME_SPACE; String extendsName = element.getExtendsName( ); if ( StringUtil.isBlank( extendsName ) ) return; DesignElement parent = module.resolveElement( extendsName, id, element .getPropertyDefn( IDesignElementModel.EXTENDS_PROP ) ); // IModuleNameSpace moduleNameSpace = module.getModuleNameSpace( id ); // ElementRefValue refValue = moduleNameSpace.resolve( extendsName ); if ( parent == null ) { handler.getErrorHandler( ).semanticWarning( new ExtendsException( element, extendsName, ExtendsException.DESIGN_EXCEPTION_NOT_FOUND ) ); return; } try { // DesignElement parent = refValue.getElement( ); assert parent != null; element.checkExtends( parent ); } catch ( ExtendsException ex ) { handler.getErrorHandler( ).semanticError( ex ); } // element.setExtendsElement( refValue.getElement( ) ); element.setExtendsElement( parent ); element.refreshStructureFromParent( module ); addTheVirualElementsToNamesapce( element ); } | 5230 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5230/a8937a9a1e743bcb615bf2260c23a1bfb7363384/ReportElementState.java/clean/model/org.eclipse.birt.report.model/src/org/eclipse/birt/report/model/parser/ReportElementState.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
6459,
10828,
19581,
1046,
1435,
202,
95,
202,
202,
15478,
1046,
2956,
33,
21336,
5621,
202,
202,
3120,
2978,
33,
4176,
18,
588,
3120,
5621,
202,
202,
1046,
3262,
82,
536,
82,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
6459,
10828,
19581,
1046,
1435,
202,
95,
202,
202,
15478,
1046,
2956,
33,
21336,
5621,
202,
202,
3120,
2978,
33,
4176,
18,
588,
3120,
5621,
202,
202,
1046,
3262,
82,
536,
82,
... | ||
public org.quickfix.field.StrikePrice getStrikePrice() throws FieldNotFound { org.quickfix.field.StrikePrice value = new org.quickfix.field.StrikePrice(); | public quickfix.field.StrikePrice getStrikePrice() throws FieldNotFound { quickfix.field.StrikePrice value = new quickfix.field.StrikePrice(); | public org.quickfix.field.StrikePrice getStrikePrice() throws FieldNotFound { org.quickfix.field.StrikePrice value = new org.quickfix.field.StrikePrice(); getField(value); return value; } | 5926 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5926/fecc27f98261270772ff182a1d4dfd94b5daa73d/PositionMaintenanceRequest.java/clean/src/java/src/quickfix/fix44/PositionMaintenanceRequest.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
2358,
18,
19525,
904,
18,
1518,
18,
1585,
2547,
5147,
24017,
2547,
5147,
1435,
1216,
2286,
2768,
225,
288,
2358,
18,
19525,
904,
18,
1518,
18,
1585,
2547,
5147,
460,
273,
394,
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,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
2358,
18,
19525,
904,
18,
1518,
18,
1585,
2547,
5147,
24017,
2547,
5147,
1435,
1216,
2286,
2768,
225,
288,
2358,
18,
19525,
904,
18,
1518,
18,
1585,
2547,
5147,
460,
273,
394,
2358,... |
} else if (fieldName.equals("VM_TypeDictionary.chains")) { | } else if (fieldName.equals("com.ibm.JikesRVM.VM_TypeDictionary.chains")) { | static void init() { if (initialized) return; else initialized = true; try { mapClass = Class.forName("mapVM"); // to test if an object is of this class // mapVMClass = InterpreterBase.forName("mapVM"); // save the offset values for VM_Field object to be used later VM_Field field = BootMap.findVMField("com.ibm.JikesRVM.VM_Field", "offset"); VMFieldOffset_offset = field.getOffset(); field = BootMap.findVMField("com.ibm.JikesRVM.VM_Field", "type"); VMFieldType_offset = field.getOffset(); // save the offset values for VM_Class object to be used later field = BootMap.findVMField("com.ibm.JikesRVM.VM_Class", "constantPool"); VMClassConstantPool_offset = field.getOffset(); field = BootMap.findVMField("Lcom/ibm/JikesRVM/VM_Class;", "superClass"); VMClassSuper_offset = field.getOffset(); field = BootMap.findVMField("Lcom/ibm/JikesRVM/VM_Class;", "descriptor"); VMClassName_offset = field.getOffset(); // save the offset values for VM_Atom object to be used later field = BootMap.findVMField("Lcom/ibm/JikesRVM/VM_Atom;", "val"); VMAtomVal_offset = field.getOffset(); // save the offset values for VM_Type object to be used later field = BootMap.findVMField("Lcom/ibm/JikesRVM/VM_Type;", "descriptor"); VMTypeDescriptor_offset = field.getOffset(); // } catch (VM_ResolutionException e) { // VM.sysWrite(e + "\n"); // e.printStackTrace(); // VM.sysExit(1); } catch (ClassNotFoundException e1) { VM.sysWrite(e1 + "\n"); e1.printStackTrace(); VM.sysExit(1); } catch (BmapNotFoundException e2) { VM.sysWrite(e2 + "\n"); e2.printStackTrace(); VM.sysExit(1); } /* set to 0 so the compiler won't complain */ TypeDictionary_keys_index = 0; TypeDictionary_values_index = 0; TypeDictionary_nextId_index = 0; TypeDictionary_chains_index = 0; AtomDictionary_keys_index = 0; AtomDictionary_values_index = 0; AtomDictionary_nextId_index = 0; AtomDictionary_chains_index = 0; MethodDictionary_keys_index = 0; MethodDictionary_values_index = 0; MethodDictionary_nextId_index = 0; MethodDictionary_chains_index = 0; try { Reader in = new FileReader(RemoteInterpreter.jbiFileName); LineNumberReader lines = new LineNumberReader(in); System.out.println("Scanning "+ RemoteInterpreter.jbiFileName + " for dictionary bases . . . "); /* In RVM.map, entries for JTOC map has a number in the first field, format: * slotIndex hexOffset textDescription hexContents fullAsciiName * decimalIndex == 0x.. hexvalue fieldname type * decimalIndex == 0x.. hexvalue null * Scan the table, look for the entries for the dictionaries */ while (true) { //loop over input lines String line = lines.readLine(); if (line == null) break; // done StringTokenizer z = new StringTokenizer(line); try { int offset = Integer.parseInt(z.nextToken()); // get the slotIndex z.nextToken(); // skip the hexOffset field z.nextToken(); // skip the textDescription field String hexAddress = z.nextToken(); // get the hexContents field String fieldName = z.nextToken(); // get the fullAsciiName // initialize the JTOC value if (fieldName.equals("VM_Statics.slots")) { try { cachedJTOC = Integer.parseInt(hexAddress.substring(2), 16); } catch (NumberFormatException e) { System.out.println("mapVM: cannot read VM_Statics.slots address"); } // look for dictionary entries } else if (fieldName.equals("VM_AtomDictionary.keys")) { AtomDictionary_keys_index = offset; } else if (fieldName.equals("VM_AtomDictionary.values")) { AtomDictionary_values_index = offset; } else if (fieldName.equals("VM_AtomDictionary.nextId")) { AtomDictionary_nextId_index = offset; } else if (fieldName.equals("VM_AtomDictionary.chains")) { AtomDictionary_chains_index = offset; } else if (fieldName.equals("VM_MethodDictionary.keys")) { MethodDictionary_keys_index = offset; } else if (fieldName.equals("VM_MethodDictionary.values")) { MethodDictionary_values_index = offset; } else if (fieldName.equals("VM_MethodDictionary.nextId")) { MethodDictionary_nextId_index = offset; } else if (fieldName.equals("VM_MethodDictionary.chains")) { MethodDictionary_chains_index = offset; } else if (fieldName.equals("VM_TypeDictionary.keys")) { TypeDictionary_keys_index = offset; } else if (fieldName.equals("VM_TypeDictionary.values")) { TypeDictionary_values_index = offset; } else if (fieldName.equals("VM_TypeDictionary.nextId")) { TypeDictionary_nextId_index = offset; } else if (fieldName.equals("VM_TypeDictionary.chains")) { TypeDictionary_chains_index = offset; } else if (fieldName.equals("VM_FieldDictionary.keys")) { FieldDictionary_keys_index = offset; } else if (fieldName.equals("VM_FieldDictionary.values")) { FieldDictionary_values_index = offset; } else if (fieldName.equals("VM_FieldDictionary.nextId")) { FieldDictionary_nextId_index = offset; } else if (fieldName.equals("VM_FieldDictionary.chains")) { FieldDictionary_chains_index = offset; } } catch (NumberFormatException e) { // skip this line if the first field is not a decimal number } catch (NoSuchElementException e1) { // this line is blank } } } catch (FileNotFoundException e) { System.out.println("File " + RemoteInterpreter.jbiFileName + " not found, this is required for the interpreter. "); System.exit(1); // String sourcePath = System.getProperty("java.class.path"); // System.out.println("Classpath was: " + sourcePath); } catch (IOException e1) { System.out.println("Error reading file RemoteInterpreter.jbiFileName"); System.exit(1); } // dumpCache(); } | 49871 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/49871/4849256bce7ddcef7bbe9225922e4b64543e0877/mapVM.java/buggy/rvm/src/tools/jdp/interpreter/mapVM.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
760,
918,
1208,
1435,
288,
565,
309,
261,
13227,
13,
1377,
327,
31,
565,
469,
1377,
6454,
273,
638,
31,
565,
775,
288,
1377,
852,
797,
273,
1659,
18,
1884,
461,
2932,
1458,
7397,
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,
282,
760,
918,
1208,
1435,
288,
565,
309,
261,
13227,
13,
1377,
327,
31,
565,
469,
1377,
6454,
273,
638,
31,
565,
775,
288,
1377,
852,
797,
273,
1659,
18,
1884,
461,
2932,
1458,
7397,
8863,
... |
public PaletteToolbarLayout() { | public PaletteToolbarLayout(DrawerAnimationController controller) { | public PaletteToolbarLayout() { super();} | 11225 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/11225/ca9444369631a61178364f7a2df80dc986896284/PaletteToolbarLayout.java/buggy/org.eclipse.gef/src/org/eclipse/gef/ui/palette/editparts/PaletteToolbarLayout.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1071,
453,
8786,
17907,
3744,
1435,
288,
202,
9565,
5621,
97,
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,
0... | [
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,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1071,
453,
8786,
17907,
3744,
1435,
288,
202,
9565,
5621,
97,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
private boolean performCopyOperation(boolean isFolder) throws CmsException { // on folder copy display "please wait" screen, not for simple file copy if (isFolder && ! DIALOG_WAIT.equals(getParamAction())) { // return false, this will trigger the "please wait" screen return false; } // get the copy mode from request parameter int copyMode = I_CmsConstants.C_COPY_PRESERVE_SIBLING; try { copyMode = Integer.parseInt(getParamCopymode()); } catch (Exception e) { // can usually be ignored if (LOG.isInfoEnabled()) { LOG.info(e.getLocalizedMessage()); } } // calculate the target name String target = getParamTarget(); if (target == null) { target = ""; } boolean restoreSiteRoot = false; try { // check if a site root was added to the target name String sitePrefix = ""; if (CmsSiteManager.getSiteRoot(target) != null) { String siteRootFolder = getCms().getRequestContext().getSiteRoot(); if (siteRootFolder.endsWith("/")) { siteRootFolder = siteRootFolder.substring(0, siteRootFolder.length()-1); } sitePrefix = siteRootFolder; getCms().getRequestContext().saveSiteRoot(); getCms().getRequestContext().setSiteRoot("/"); restoreSiteRoot = true; } // calculate the target name target = CmsLinkManager.getAbsoluteUri(target, CmsResource.getParentFolder(getParamResource())); if (target.equals(getParamResource())) { throw new CmsVfsException(Messages.get().container(Messages.ERR_COPY_ONTO_ITSELF_1, target)); } try { CmsResource res = getCms().readResource(target, CmsResourceFilter.ALL); if (res.isFolder()) { // target folder already exists, so we add the current folder name if (! target.endsWith("/")) { target += "/"; } target = target + CmsResource.getName(getParamResource()); } } catch (CmsVfsResourceNotFoundException e) { // target folder does not already exist, so target name is o.k. if (LOG.isInfoEnabled()) { LOG.info(e.getLocalizedMessage()); } } // set the target parameter value setParamTarget(target); // delete existing target resource if confirmed by the user if (DIALOG_CONFIRMED.equals(getParamAction())) { getCms().deleteResource(target, I_CmsConstants.C_DELETE_OPTION_PRESERVE_SIBLINGS); } // copy the resource getCms().copyResource(sitePrefix + getParamResource(), target, copyMode); } finally { if (restoreSiteRoot) { getCms().getRequestContext().restoreSiteRoot(); } } return true; } | 51784 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/51784/2fa0efcae8f9aa5971c7763269a3b033e9256d4b/CmsCopy.java/buggy/src/org/opencms/workplace/commons/CmsCopy.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
1250,
3073,
2951,
2988,
12,
6494,
31137,
13,
1216,
11228,
288,
3639,
368,
603,
3009,
1610,
2562,
315,
1802,
448,
2529,
6,
5518,
16,
486,
364,
4143,
585,
1610,
3639,
309,
261,
291,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1250,
3073,
2951,
2988,
12,
6494,
31137,
13,
1216,
11228,
288,
3639,
368,
603,
3009,
1610,
2562,
315,
1802,
448,
2529,
6,
5518,
16,
486,
364,
4143,
585,
1610,
3639,
309,
261,
291,
... | ||
if (e.getSource() == VAJAntToolGUI.this.getShowLogMenuItem()) | } if (e.getSource() == VAJAntToolGUI.this.getShowLogMenuItem()) { | public void actionPerformed(ActionEvent e) { try { /* #### Main App-Frame #### */ // browse XML-File with filechooser if (e.getSource() == VAJAntToolGUI.this.getBrowseButton()) { getFileDialog().setDirectory(getBuildFileTextField().getText().substring(0, getBuildFileTextField().getText().lastIndexOf('\\') + 1)); getFileDialog().setFile("*.xml"); getFileDialog().show(); if (!getFileDialog().getFile().equals("") ) { getBuildFileTextField().setText(getFileDialog().getDirectory() + getFileDialog().getFile()); } } // dispose and exit application if (e.getSource() == VAJAntToolGUI.this.getCloseButton()) { dispose(); System.exit(0); } // start build-process if (e.getSource() == VAJAntToolGUI.this.getBuildButton()) { executeTarget(); } if (e.getSource() == VAJAntToolGUI.this.getStopButton()) { getBuildInfo().cancelBuild(); } if (e.getSource() == VAJAntToolGUI.this.getReloadButton()) { try { getBuildInfo().updateTargetList(); fillList(); } catch (Throwable fileNotFound) { handleException(fileNotFound); getTargetList().removeAll(); getBuildButton().setEnabled(false); } } // MenuItems if (e.getSource() == VAJAntToolGUI.this.getSaveMenuItem()) saveBuildInfo(); if (e.getSource() == VAJAntToolGUI.this.getAboutMenuItem()) getAboutDialog().show(); if (e.getSource() == VAJAntToolGUI.this.getShowLogMenuItem()) getMessageFrame().show(); /* #### About dialog #### */ if (e.getSource() == VAJAntToolGUI.this.getAboutOkButton()) getAboutDialog().dispose(); /* #### Log frame #### */ if (e.getSource() == VAJAntToolGUI.this.getMessageOkButton()) getMessageFrame().dispose(); if (e.getSource() == VAJAntToolGUI.this.getMessageClearLogButton()) getMessageTextArea().setText(""); if (e.getSource() == VAJAntToolGUI.this.getMessageOkButton()) getMessageFrame().dispose(); } catch (Throwable exc) { handleException(exc); } } | 17033 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/17033/055e230fd2fbc18e71a1addfc95c017e2d998ee1/VAJAntToolGUI.java/clean/src/main/org/apache/tools/ant/taskdefs/optional/ide/VAJAntToolGUI.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
540,
1071,
918,
26100,
12,
1803,
1133,
425,
13,
288,
5411,
775,
288,
7734,
1748,
11849,
7,
12740,
4677,
17,
3219,
11849,
7,
1195,
7734,
368,
21670,
3167,
17,
812,
598,
585,
2599,
13164,
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,
540,
1071,
918,
26100,
12,
1803,
1133,
425,
13,
288,
5411,
775,
288,
7734,
1748,
11849,
7,
12740,
4677,
17,
3219,
11849,
7,
1195,
7734,
368,
21670,
3167,
17,
812,
598,
585,
2599,
13164,
7734,
... |
for (int i = 0; i < stocks.length; ++i) { int price = market.getPrice(stocks[i]); if (price < cheapestPrice) { cheapestPrice = price; cheapestStock = stocks[i]; } } market.buyStock(cheapestStock, cost / cheapestPrice); } | for (int i = 0; i < stocks.length; ++i) { int price = market.getPrice(stocks[i]); if (price < cheapestPrice) { cheapestPrice = price; cheapestStock = stocks[i]; } } market.buyStock(cheapestStock, cost / cheapestPrice); } | public void buyLowestPriceStock( int cost ) { String[] stocks = market.listStocks(); int cheapestPrice = Integer.MAX_VALUE; String cheapestStock = null; for (int i = 0; i < stocks.length; ++i) { int price = market.getPrice(stocks[i]); if (price < cheapestPrice) { cheapestPrice = price; cheapestStock = stocks[i]; } } market.buyStock(cheapestStock, cost / cheapestPrice); } | 57371 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/57371/c26c57f3ac4851e6bc9c5df8515ac73f4045eebf/DynamicMockExample.java/clean/jmock/core/acceptance-tests/atest/jmock/DynamicMockExample.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
3196,
202,
482,
918,
30143,
10520,
395,
5147,
17821,
12,
509,
6991,
262,
288,
1082,
202,
780,
8526,
12480,
87,
273,
13667,
18,
1098,
17821,
87,
5621,
1082,
202,
474,
19315,
438,
395,
5147,
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,
3196,
202,
482,
918,
30143,
10520,
395,
5147,
17821,
12,
509,
6991,
262,
288,
1082,
202,
780,
8526,
12480,
87,
273,
13667,
18,
1098,
17821,
87,
5621,
1082,
202,
474,
19315,
438,
395,
5147,
273... |
ASTVariableDeclaratorId decl = (ASTVariableDeclaratorId) list.get(0); String name = decl.getImage(); String path = " " try { List nodes = node.findChildNodesWithXPath(path); if (nodes.size() == 1) { String method; if (nodes.get(0) instanceof ASTMethodDeclaration) { method = ((ASTMethodDeclarator) ((ASTMethodDeclaration) nodes.get(0)).findChildrenOfType(ASTMethodDeclarator.class).get(0)).getImage(); } else { ASTConstructorDeclaration astConstructorDeclaration = (ASTConstructorDeclaration) nodes.get(0); ASTClassOrInterfaceDeclaration astClassOrInterfaceDeclaration = (ASTClassOrInterfaceDeclaration) astConstructorDeclaration.getFirstParentOfType(ASTClassOrInterfaceDeclaration.class); if (astClassOrInterfaceDeclaration == null) { return data; } method = astClassOrInterfaceDeclaration.getImage(); | ASTVariableDeclaratorId declaration = (ASTVariableDeclaratorId) list.get(0); List usages = declaration.getUsages(); SimpleNode decl = null; boolean violation = true; for (int ix = 0; ix < usages.size(); ix++) { NameOccurrence no = (NameOccurrence) usages.get(ix); SimpleNode location = no.getLocation(); SimpleNode method = (SimpleNode) location.getFirstParentOfType(ASTMethodDeclaration.class); if (method == null) { method = (SimpleNode) location.getFirstParentOfType(ASTConstructorDeclaration.class); if (method == null) { continue; | public Object visit(ASTFieldDeclaration node, Object data) { if (node.isPrivate() && !node.isStatic()) { List list = node.findChildrenOfType(ASTVariableDeclaratorId.class); ASTVariableDeclaratorId decl = (ASTVariableDeclaratorId) list.get(0); String name = decl.getImage(); String path = "//MethodDeclaration[.//PrimaryExpression[.//Name[@Image = \"" + name + "\" or substring-before(@Image, \".\") = \"" + name + "\"] or .//PrimarySuffix[@Image = \"" + name + "\"]]] |" + "//ConstructorDeclaration[.//PrimaryExpression[.//Name[@Image = \"" + name + "\" or substring-before(@Image, \".\") = \"" + name + "\"] or .//PrimarySuffix[@Image = \"" + name + "\"]]]"; try { List nodes = node.findChildNodesWithXPath(path); if (nodes.size() == 1) { String method; if (nodes.get(0) instanceof ASTMethodDeclaration) { method = ((ASTMethodDeclarator) ((ASTMethodDeclaration) nodes.get(0)).findChildrenOfType(ASTMethodDeclarator.class).get(0)).getImage(); } else { ASTConstructorDeclaration astConstructorDeclaration = (ASTConstructorDeclaration) nodes.get(0); ASTClassOrInterfaceDeclaration astClassOrInterfaceDeclaration = (ASTClassOrInterfaceDeclaration) astConstructorDeclaration.getFirstParentOfType(ASTClassOrInterfaceDeclaration.class); if (astClassOrInterfaceDeclaration == null) { return data; } method = astClassOrInterfaceDeclaration.getImage(); } addViolation(data, decl, new Object[]{name, method}); } } catch (JaxenException je) { je.printStackTrace(); } } return data; } | 45569 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/45569/7f1359d2b8c388522e4979a96601a490e1802386/SingularField.java/clean/pmd/src/net/sourceforge/pmd/rules/SingularField.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
1033,
3757,
12,
9053,
974,
6094,
756,
16,
1033,
501,
13,
288,
3639,
309,
261,
2159,
18,
291,
6014,
1435,
597,
401,
2159,
18,
291,
5788,
10756,
288,
5411,
987,
666,
273,
756,
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,
1033,
3757,
12,
9053,
974,
6094,
756,
16,
1033,
501,
13,
288,
3639,
309,
261,
2159,
18,
291,
6014,
1435,
597,
401,
2159,
18,
291,
5788,
10756,
288,
5411,
987,
666,
273,
756,
18,
... |
iAdjust += (int)((double)(spaceRange.opt - spaceRange.min) * dSpaceAdjust); | iAdjust += (int)((double)(spaceRange.opt - spaceRange.min) * dSpaceAdjust); | protected void addSpace(Area parentArea, MinOptMax spaceRange, double dSpaceAdjust) { if (spaceRange != null) { int iAdjust = spaceRange.opt; if (dSpaceAdjust > 0.0) { // Stretch by factor iAdjust += (int)((double)(spaceRange.max - spaceRange.opt) * dSpaceAdjust); } else if (dSpaceAdjust < 0.0) { // Shrink by factor iAdjust += (int)((double)(spaceRange.opt - spaceRange.min) * dSpaceAdjust); } if (iAdjust != 0) { //getLogger().debug("Add leading space: " + iAdjust); Space ls = new Space(); ls.setWidth(iAdjust); parentArea.addChild(ls); } } } | 5268 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5268/eef12c894b3a6b778bd8cc21a0da2dc0faa4e00f/InlineStackingLayoutManager.java/clean/src/org/apache/fop/layoutmgr/InlineStackingLayoutManager.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
4750,
918,
527,
3819,
12,
5484,
982,
5484,
16,
5444,
6179,
2747,
3476,
2655,
16,
18701,
1645,
302,
3819,
10952,
13,
288,
3639,
309,
261,
2981,
2655,
480,
446,
13,
288,
5411,
509,
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... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
4750,
918,
527,
3819,
12,
5484,
982,
5484,
16,
5444,
6179,
2747,
3476,
2655,
16,
18701,
1645,
302,
3819,
10952,
13,
288,
3639,
309,
261,
2981,
2655,
480,
446,
13,
288,
5411,
509,
277,
1... |
cmp.setLayout( new GridLayout( 5, true ) ); | cmp.setLayout( new GridLayout( 4, false ) ); | private void createButtonGroup( Composite parent ) { Composite cmp = new Composite( parent, SWT.NONE ); { cmp.setLayout( new GridLayout( 5, true ) ); GridData gridData = new GridData( GridData.FILL_HORIZONTAL ); gridData.horizontalSpan = 2; gridData.grabExcessVerticalSpace = true; gridData.verticalAlignment = SWT.END; cmp.setLayoutData( gridData ); } btnAxisTitle = new Button( cmp, SWT.TOGGLE ); { GridData gd = new GridData( GridData.FILL_HORIZONTAL ); btnAxisTitle.setLayoutData( gd ); btnAxisTitle.setText( Messages.getString( "AxisXSheetImpl.Label.AxisText" ) ); //$NON-NLS-1$ btnAxisTitle.addSelectionListener( this ); } btnGridlines = new Button( cmp, SWT.TOGGLE ); { GridData gd = new GridData( GridData.FILL_HORIZONTAL ); btnGridlines.setLayoutData( gd ); btnGridlines.setText( Messages.getString( "AxisXSheetImpl.Label.Gridlines" ) ); //$NON-NLS-1$ btnGridlines.addSelectionListener( this ); } btnMarkers = new Button( cmp, SWT.TOGGLE ); { GridData gd = new GridData( GridData.FILL_HORIZONTAL ); btnMarkers.setLayoutData( gd ); btnMarkers.setText( Messages.getString( "AxisXSheetImpl.Label.Markers" ) ); //$NON-NLS-1$ btnMarkers.addSelectionListener( this ); } btnAxisData = new Button( cmp, SWT.TOGGLE ); { GridData gd = new GridData( GridData.FILL_HORIZONTAL ); btnAxisData.setLayoutData( gd ); btnAxisData.setText( Messages.getString( "AxisXSheetImpl.Label.AxisData" ) ); //$NON-NLS-1$ btnAxisData.addSelectionListener( this ); } } | 5230 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5230/978d95676effd7364e2b069a03cc2f90f4113717/AxisXSheetImpl.java/buggy/chart/org.eclipse.birt.chart.ui.extension/src/org/eclipse/birt/chart/ui/swt/wizard/format/axis/AxisXSheetImpl.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
918,
752,
3616,
1114,
12,
14728,
982,
262,
202,
95,
202,
202,
9400,
9411,
273,
394,
14728,
12,
982,
16,
348,
8588,
18,
9826,
11272,
202,
202,
95,
1082,
202,
9625,
18,
542,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
752,
3616,
1114,
12,
14728,
982,
262,
202,
95,
202,
202,
9400,
9411,
273,
394,
14728,
12,
982,
16,
348,
8588,
18,
9826,
11272,
202,
202,
95,
1082,
202,
9625,
18,
542,
... |
String folderName = propertyInheritedFrom(propName, propVal); if (CmsStringUtil.isNotEmpty(folderName)) { return new StringBuffer(key("label.inherit")).append(' ').append(propVal).append(' ').append( | String folderName = CmsResource.getParentFolder(getParamResource()); String folderPropVal = null; while (CmsStringUtil.isNotEmpty(folderName)) { CmsProperty prop = getCms().readPropertyObject(folderName, propName, false); folderPropVal = prop.getValue(); if (CmsStringUtil.isNotEmpty(folderPropVal)) { break; } folderName = CmsResource.getParentFolder(folderName); } if (CmsStringUtil.isNotEmpty(folderPropVal)) { return new StringBuffer(key("label.inherit")).append(' ').append(folderPropVal).append(' ').append( | public String getPropertyInheritanceInfo(String propName, String propVal) throws CmsException { String folderName = propertyInheritedFrom(propName, propVal); if (CmsStringUtil.isNotEmpty(folderName)) { return new StringBuffer(key("label.inherit")).append(' ').append(propVal).append(' ').append( key("label.from")).append(' ').append(folderName).toString(); } else { return key("label.notset"); } } | 8585 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/8585/a268898df28c68d6295e16fceb82dcb9d0f2a2c7/CmsSecure.java/clean/src/org/opencms/workplace/commons/CmsSecure.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
514,
3911,
28255,
966,
12,
780,
9994,
16,
514,
2270,
3053,
13,
1216,
11228,
288,
3639,
514,
31814,
273,
1272,
29078,
1265,
12,
5986,
461,
16,
2270,
3053,
1769,
3639,
309,
261,
4747,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
514,
3911,
28255,
966,
12,
780,
9994,
16,
514,
2270,
3053,
13,
1216,
11228,
288,
3639,
514,
31814,
273,
1272,
29078,
1265,
12,
5986,
461,
16,
2270,
3053,
1769,
3639,
309,
261,
4747,... |
naturalKey = CharacterKey.getInstance((char) (accelerator & 0xFFFF)); | naturalKey = CharacterKey.getInstance((char) (accelerator & 0xFFFF)); | public static KeyStroke convertAcceleratorToKeyStroke(int accelerator) { final SortedSet modifierKeys = new TreeSet(); NaturalKey naturalKey = null; if ((accelerator & SWT.ALT) != 0) modifierKeys.add(ModifierKey.ALT); if ((accelerator & SWT.COMMAND) != 0) modifierKeys.add(ModifierKey.COMMAND); if ((accelerator & SWT.CTRL) != 0) modifierKeys.add(ModifierKey.CTRL); if ((accelerator & SWT.SHIFT) != 0) modifierKeys.add(ModifierKey.SHIFT); if (((accelerator & SWT.KEY_MASK) == 0) && (accelerator != 0)) { // There were only accelerators naturalKey = null; } else { // There were other keys. accelerator &= SWT.KEY_MASK; switch (accelerator) { case SWT.ARROW_DOWN : naturalKey = SpecialKey.ARROW_DOWN; break; case SWT.ARROW_LEFT : naturalKey = SpecialKey.ARROW_LEFT; break; case SWT.ARROW_RIGHT : naturalKey = SpecialKey.ARROW_RIGHT; break; case SWT.ARROW_UP : naturalKey = SpecialKey.ARROW_UP; break; case SWT.END : naturalKey = SpecialKey.END; break; case SWT.F1 : naturalKey = SpecialKey.F1; break; case SWT.F10 : naturalKey = SpecialKey.F10; break; case SWT.F11 : naturalKey = SpecialKey.F11; break; case SWT.F12 : naturalKey = SpecialKey.F12; break; case SWT.F2 : naturalKey = SpecialKey.F2; break; case SWT.F3 : naturalKey = SpecialKey.F3; break; case SWT.F4 : naturalKey = SpecialKey.F4; break; case SWT.F5 : naturalKey = SpecialKey.F5; break; case SWT.F6 : naturalKey = SpecialKey.F6; break; case SWT.F7 : naturalKey = SpecialKey.F7; break; case SWT.F8 : naturalKey = SpecialKey.F8; break; case SWT.F9 : naturalKey = SpecialKey.F9; break; case SWT.HOME : naturalKey = SpecialKey.HOME; break; case SWT.INSERT : naturalKey = SpecialKey.INSERT; break; case SWT.KEYPAD_0 : naturalKey = SpecialKey.NUMPAD_0; break; case SWT.KEYPAD_1 : naturalKey = SpecialKey.NUMPAD_1; break; case SWT.KEYPAD_2 : naturalKey = SpecialKey.NUMPAD_2; break; case SWT.KEYPAD_3 : naturalKey = SpecialKey.NUMPAD_3; break; case SWT.KEYPAD_4 : naturalKey = SpecialKey.NUMPAD_4; break; case SWT.KEYPAD_5 : naturalKey = SpecialKey.NUMPAD_5; break; case SWT.KEYPAD_6 : naturalKey = SpecialKey.NUMPAD_6; break; case SWT.KEYPAD_7 : naturalKey = SpecialKey.NUMPAD_7; break; case SWT.KEYPAD_8 : naturalKey = SpecialKey.NUMPAD_8; break; case SWT.KEYPAD_9 : naturalKey = SpecialKey.NUMPAD_9; break; case SWT.KEYPAD_ADD : naturalKey = SpecialKey.NUMPAD_ADD; break; case SWT.KEYPAD_CR : naturalKey = SpecialKey.NUMPAD_ENTER; break; case SWT.KEYPAD_DECIMAL : naturalKey = SpecialKey.NUMPAD_DECIMAL; break; case SWT.KEYPAD_DIVIDE : naturalKey = SpecialKey.NUMPAD_DIVIDE; break; case SWT.KEYPAD_EQUAL : naturalKey = SpecialKey.NUMPAD_EQUAL; break; case SWT.KEYPAD_MULTIPLY : naturalKey = SpecialKey.NUMPAD_MULTIPLY; break; case SWT.KEYPAD_SUBTRACT : naturalKey = SpecialKey.NUMPAD_SUBTRACT; break; case SWT.NUM_LOCK : naturalKey = SpecialKey.NUM_LOCK; break; case SWT.PAGE_DOWN : naturalKey = SpecialKey.PAGE_DOWN; break; case SWT.PAGE_UP : naturalKey = SpecialKey.PAGE_UP; break; default : naturalKey = CharacterKey.getInstance((char) (accelerator & 0xFFFF)); } } return KeyStroke.getInstance(modifierKeys, naturalKey); } | 58148 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/58148/fe38dd4a4ffd35cdf08f0f99290a0b2c13f559fd/KeySupport.java/clean/bundles/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal/keys/KeySupport.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
760,
1929,
14602,
1765,
28417,
774,
653,
14602,
12,
474,
15153,
7385,
13,
288,
202,
202,
6385,
22123,
9606,
2396,
273,
394,
19461,
5621,
202,
202,
23779,
3766,
653,
15145,
653,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1929,
14602,
1765,
28417,
774,
653,
14602,
12,
474,
15153,
7385,
13,
288,
202,
202,
6385,
22123,
9606,
2396,
273,
394,
19461,
5621,
202,
202,
23779,
3766,
653,
15145,
653,
... |
(System.getProperty("test.sql.dir") + "/com/arsdigita/persistence/teardown.sql"); | ("/com/arsdigita/persistence/teardown.sql"); | public static Test suite() { ProtoSuite suite = new ProtoSuite(); populateSuite(suite); BaseTestSetup wrapper = new CoreTestSetup(suite); wrapper.setSetupSQLScript (System.getProperty("test.sql.dir") + "/com/arsdigita/persistence/setup.sql"); wrapper.setTeardownSQLScript (System.getProperty("test.sql.dir") + "/com/arsdigita/persistence/teardown.sql"); return wrapper; } | 12196 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/12196/33c9aa96285e546f1fd55e56204c153934e1ac13/ProtoSuite.java/buggy/archive/core-platform/test/src/com/redhat/persistence/ProtoSuite.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
760,
7766,
11371,
1435,
288,
3639,
7440,
13587,
11371,
273,
394,
7440,
13587,
5621,
3639,
6490,
13587,
12,
30676,
1769,
3639,
3360,
4709,
7365,
4053,
273,
394,
4586,
4709,
7365,
12,
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,
760,
7766,
11371,
1435,
288,
3639,
7440,
13587,
11371,
273,
394,
7440,
13587,
5621,
3639,
6490,
13587,
12,
30676,
1769,
3639,
3360,
4709,
7365,
4053,
273,
394,
4586,
4709,
7365,
12,
3... |
super.processLowLevelEvent(action, values); | processKeyEvents(values); | public void processLowLevelEvent(String action, String[] values) { super.processLowLevelEvent(action, values); // delay events... getSelectionModel().setDelayEvents(true); getSelectionModel().setValueIsAdjusting(true); for (int i = 0; i < values.length; i++) { String value = values[i]; if (value.length() > 1) { char modus = value.charAt(0); value = value.substring(1); int colonIndex = value.indexOf(':'); if (colonIndex < 0) continue; // maybe next value fits ... try { int row = Integer.parseInt(value.substring(0, colonIndex)); int col = Integer.parseInt(value.substring(colonIndex + 1)); // editor event switch (modus) { case 'e': editCellAt(row, col, null); break; case 't': if (getSelectionModel().isSelectedIndex(row)) getSelectionModel().removeSelectionInterval(row, row); else getSelectionModel().addSelectionInterval(row, row); break; case 's': getSelectionModel().addSelectionInterval(row, row); break; case 'd': getSelectionModel().removeSelectionInterval(row, row); break; } } catch (NumberFormatException ex) { // hier loggen... ex.printStackTrace(); } } } getSelectionModel().setValueIsAdjusting(false); getSelectionModel().setDelayEvents(false); SForm.addArmedComponent(this); } | 3911 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/3911/106151072c6ae53bea4e19243f9af84ef2c32c6a/STable.java/clean/wings2/src/java/org/wings/STable.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1207,
10520,
2355,
1133,
12,
780,
1301,
16,
514,
8526,
924,
13,
288,
3639,
1207,
653,
3783,
12,
2372,
1769,
3639,
368,
4624,
2641,
2777,
3639,
23204,
1488,
7675,
542,
6763,
378... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1207,
10520,
2355,
1133,
12,
780,
1301,
16,
514,
8526,
924,
13,
288,
3639,
1207,
653,
3783,
12,
2372,
1769,
3639,
368,
4624,
2641,
2777,
3639,
23204,
1488,
7675,
542,
6763,
378... |
public String getJMSProviderName() throws JMSException { return "Apache Qpid"; } | public String getJMSProviderName() throws JMSException { return "Apache Qpid"; } | public String getJMSProviderName() throws JMSException { return "Apache Qpid"; } | 45585 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/45585/2a1ea737ef65377bd4b08b45d72d2df7f9fc6cfc/QpidConnectionMetaData.java/buggy/qpid/java/client/src/main/java/org/apache/qpid/client/QpidConnectionMetaData.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
514,
9285,
3537,
31192,
1435,
1216,
20343,
288,
202,
202,
2463,
315,
1294,
807,
2238,
6610,
14432,
202,
97,
2,
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,
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... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
514,
9285,
3537,
31192,
1435,
1216,
20343,
288,
202,
202,
2463,
315,
1294,
807,
2238,
6610,
14432,
202,
97,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
block = n.getCHK(chk); | block = n.getCHK(chk, false); | private void processLine(BufferedReader reader) throws UnsupportedEncodingException { String line; try { line = reader.readLine(); } catch (IOException e) { System.err.println("Bye... ("+e+")"); return; } if(line == null) line = "QUIT"; String uline = line.toUpperCase(); Logger.minor(this, "Command: "+line); if(uline.startsWith("GET:")) { // Should have a key next String key = line.substring("GET:".length()); while(key.length() > 0 && key.charAt(0) == ' ') key = key.substring(1); while(key.length() > 0 && key.charAt(key.length()-1) == ' ') key = key.substring(0, key.length()-2); Logger.normal(this, "Key: "+key); FreenetURI uri; ClientCHK chk; try { uri = new FreenetURI(key); chk = new ClientCHK(uri); } catch (MalformedURLException e2) { System.out.println("Malformed URI: "+key+" : "+e2); return; } CHKBlock block; // Fetch, possibly from other node. block = n.getCHK(chk); if(block == null) { System.out.println("Not found in store: "+chk.getURI()); } else { // Decode it byte[] decoded; try { decoded = block.decode(chk); } catch (CHKDecodeException e) { Logger.error(this, "Cannot decode: "+e, e); System.out.println("Cannot decode: "+e.getMessage()); return; } System.out.println("Decoded data:\n"); System.out.println(new String(decoded)); } } else if(uline.startsWith("GETFILE:")) { // Should have a key next String key = line.substring("GETFILE:".length()); while(key.length() > 0 && key.charAt(0) == ' ') key = key.substring(1); while(key.length() > 0 && key.charAt(key.length()-1) == ' ') key = key.substring(0, key.length()-2); Logger.normal(this, "Key: "+key); FreenetURI uri; ClientCHK chk; try { uri = new FreenetURI(key); chk = new ClientCHK(uri); } catch (MalformedURLException e2) { System.err.println("Malformed URI: "+key+" : "+e2); return; } CHKBlock block; // Fetch, possibly from other node. block = n.getCHK(chk); if(block == null) { System.out.println("Not found in store: "+chk.getURI()); } else { // Decode it byte[] decoded; try { decoded = block.decode(chk); } catch (CHKDecodeException e) { Logger.error(this, "Cannot decode: "+e, e); System.out.println("Cannot decode: "+e.getMessage()); return; } // Now calculate filename String fnam = uri.getDocName(); fnam = sanitize(fnam); if(fnam.length() == 0) { fnam = "freenet-download-"+System.currentTimeMillis(); } if(new File(fnam).exists()) { System.out.println("File exists already: "+fnam); fnam = "freenet-"+System.currentTimeMillis()+"-"+fnam; } FileOutputStream fos = null; try { fos = new FileOutputStream(fnam); fos.write(decoded); fos.close(); System.out.println("Written to "+fnam); } catch (IOException e) { System.out.println("Could not write file: caught "+e); e.printStackTrace(); } finally { if(fos != null) try { fos.close(); } catch (IOException e1) { // Ignore } } } } else if(uline.startsWith("QUIT")) { System.out.println("Goodbye."); System.exit(0); } else if(uline.startsWith("PUT:")) { // Just insert to local store line = line.substring("PUT:".length()); while(line.length() > 0 && line.charAt(0) == ' ') line = line.substring(1); while(line.length() > 0 && line.charAt(line.length()-1) == ' ') line = line.substring(0, line.length()-2); String content; if(line.length() > 0) { // Single line insert content = line; } else { // Multiple line insert content = readLines(reader, false); } // Insert byte[] data = content.getBytes(); ClientCHKBlock block; try { block = ClientCHKBlock.encode(data); } catch (CHKEncodeException e) { Logger.error(this, "Couldn't encode: "+e, e); return; } ClientCHK chk = block.getClientKey(); FreenetURI uri = chk.getURI(); n.putCHK(block); // Definitely interface System.out.println("URI: "+uri); } else if(uline.startsWith("PUTFILE:")) { // Just insert to local store line = line.substring("PUTFILE:".length()); while(line.length() > 0 && line.charAt(0) == ' ') line = line.substring(1); while(line.length() > 0 && line.charAt(line.length()-1) == ' ') line = line.substring(0, line.length()-2); File f = new File(line); System.out.println("Attempting to read file "+line); try { FileInputStream fis = new FileInputStream(line); DataInputStream dis = new DataInputStream(fis); int length = (int)f.length(); byte[] data = new byte[length]; dis.readFully(data); dis.close(); System.out.println("Inserting..."); ClientCHKBlock block; try { block = ClientCHKBlock.encode(data); } catch (CHKEncodeException e) { System.out.println("Couldn't encode: "+e.getMessage()); Logger.error(this, "Couldn't encode: "+e, e); return; } ClientCHK chk = block.getClientKey(); FreenetURI uri = chk.getURI(); uri = uri.setDocName(f.getName()); n.putCHK(block); System.out.println("URI: "+uri); } catch (FileNotFoundException e1) { System.out.println("File not found"); } catch (IOException e) { System.out.println("Could not read: "+e); e.printStackTrace(); } catch (Throwable t) { System.out.println("Threw: "+t); t.printStackTrace(); } } else if(uline.startsWith("STATUS")) { SimpleFieldSet fs = n.exportFieldSet(); System.out.println(fs.toString()); System.out.println(); System.out.println(n.getStatus()); } else if(uline.startsWith("CONNECT:")) { String key = line.substring("CONNECT:".length()); while(key.length() > 0 && key.charAt(0) == ' ') key = key.substring(1); while(key.length() > 0 && key.charAt(key.length()-1) == ' ') key = key.substring(0, key.length()-2); if(key.length() > 0) { // Filename System.out.println("Trying to connect to noderef in "+key); File f = new File(key); System.out.println("Attempting to read file "+key); try { FileInputStream fis = new FileInputStream(key); DataInputStream dis = new DataInputStream(fis); int length = (int)f.length(); byte[] data = new byte[length]; dis.readFully(data); dis.close(); connect(new String(data)); } catch (IOException e) { System.err.println("Could not read file: "+e); e.printStackTrace(System.err); } } else { String content = readLines(reader, true); if(content == null) return; if(content.equals("")) return; connect(content); } } else if(uline.startsWith("NAME:")) { System.out.println("Node name currently: "+n.myName); String key = line.substring("NAME:".length()); while(key.length() > 0 && key.charAt(0) == ' ') key = key.substring(1); while(key.length() > 0 && key.charAt(key.length()-1) == ' ') key = key.substring(0, key.length()-2); System.out.println("New name: "+key); n.setName(key); } else { } } | 46035 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/46035/1ce819493a56200ae19052c9b9845d62763cd1f6/TextModeClientInterface.java/buggy/src/freenet/node/TextModeClientInterface.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
918,
1207,
1670,
12,
17947,
2514,
2949,
13,
1216,
15367,
288,
3639,
514,
980,
31,
3639,
775,
288,
5411,
980,
273,
2949,
18,
896,
1670,
5621,
3639,
289,
1044,
261,
14106,
425,
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,
377,
3238,
918,
1207,
1670,
12,
17947,
2514,
2949,
13,
1216,
15367,
288,
3639,
514,
980,
31,
3639,
775,
288,
5411,
980,
273,
2949,
18,
896,
1670,
5621,
3639,
289,
1044,
261,
14106,
425,
13,
... |
NestedGraphModelNode node = (NestedGraphModelNode)model.getInternalNode(data); if ((node != null) && (node.getChildren().size() > 0) && !node.equals(model.getCurrentNode())) { | NestedGraphModelNode node = (NestedGraphModelNode) model.getInternalNode(data); if ((node != null) && (node.getChildren().size() > 0) && !node.equals(model.getCurrentNode())) { | public void doubleClick(DoubleClickEvent event) { ISelection selection = event.getSelection(); if (!selection.isEmpty() && (selection instanceof IStructuredSelection)) { List list = ((IStructuredSelection)selection).toList(); Object data = list.get(0); NestedGraphModelNode node = (NestedGraphModelNode)model.getInternalNode(data); if ((node != null) && (node.getChildren().size() > 0) && !node.equals(model.getCurrentNode())) { model.setCurrentNode(node); viewer.fireModelUpdate(); } } } | 11225 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/11225/35ad04f579a89259b2f797fafadd23ce4dcdd4fa/NestedGraphViewer.java/clean/org.eclipse.zest.core/src/org/eclipse/zest/core/viewers/NestedGraphViewer.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
1645,
6563,
12,
5265,
6563,
1133,
871,
13,
288,
202,
202,
45,
6233,
4421,
273,
871,
18,
588,
6233,
5621,
202,
202,
430,
16051,
10705,
18,
291,
1921,
1435,
597,
261,
10705... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1645,
6563,
12,
5265,
6563,
1133,
871,
13,
288,
202,
202,
45,
6233,
4421,
273,
871,
18,
588,
6233,
5621,
202,
202,
430,
16051,
10705,
18,
291,
1921,
1435,
597,
261,
10705... |
disabledCleaner.stopCleaning(); final Iterator disabledItr = disabledMap.entrySet().iterator(); while (disabledItr.hasNext()) { final Map.Entry entry = (Map.Entry) disabledItr.next(); | final WeakReference reference = (WeakReference) entry.getValue(); if (reference != null) { reference.clear(); } | public final void dispose() { // Clean up the missing image. if ((missingImage != null) && (!missingImage.isDisposed())) { missingImage.dispose(); missingImage = null; } // Stop the image cleaner thread, clear all of the weak references and // dispose of all of the images. imageCleaner.stopCleaning(); final Iterator imageItr = imageMap.entrySet().iterator(); while (imageItr.hasNext()) { final Map.Entry entry = (Map.Entry) imageItr.next(); final WeakReference reference = (WeakReference) entry.getKey(); reference.clear(); final Image image = (Image) entry.getValue(); if ((image != null) && (!image.isDisposed())) { image.dispose(); } } imageMap.clear(); // Stop the greyed image cleaner thread, clear all of the weak // references and dispose of all of the greyed images. greyCleaner.stopCleaning(); final Iterator greyItr = greyMap.entrySet().iterator(); while (greyItr.hasNext()) { final Map.Entry entry = (Map.Entry) greyItr.next(); final WeakReference reference = (WeakReference) entry.getKey(); reference.clear(); final Image image = (Image) entry.getValue(); if ((image != null) && (!image.isDisposed())) { image.dispose(); } } greyMap.clear(); // Stop the disabled image cleaner thread, clear all of the weak // references and dispose of all of the disabled images. disabledCleaner.stopCleaning(); final Iterator disabledItr = disabledMap.entrySet().iterator(); while (disabledItr.hasNext()) { final Map.Entry entry = (Map.Entry) disabledItr.next(); final WeakReference reference = (WeakReference) entry.getKey(); reference.clear(); final Image image = (Image) entry.getValue(); if ((image != null) && (!image.isDisposed())) { image.dispose(); } } disabledMap.clear(); } | 56152 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/56152/6c5958bfba832d137ae415473babfc58f2d9a845/ImageCache.java/buggy/bundles/org.eclipse.jface/src/org/eclipse/jface/resource/ImageCache.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
727,
918,
15825,
1435,
288,
3639,
368,
9645,
731,
326,
3315,
1316,
18,
3639,
309,
14015,
7337,
2040,
480,
446,
13,
597,
16051,
7337,
2040,
18,
291,
1669,
7423,
1435,
3719,
288,
5411... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
727,
918,
15825,
1435,
288,
3639,
368,
9645,
731,
326,
3315,
1316,
18,
3639,
309,
14015,
7337,
2040,
480,
446,
13,
597,
16051,
7337,
2040,
18,
291,
1669,
7423,
1435,
3719,
288,
5411... |
x = clob.getSubString(0, (int) clob.length()); | x = clob.getSubString(1, (int) clob.length()); | static Object convert(Object callerReference, Object x, int jdbcType, String charSet) throws SQLException { try { switch (jdbcType) { case java.sql.Types.TINYINT: case java.sql.Types.SMALLINT: case java.sql.Types.INTEGER: if (x == null) { return INTEGER_ZERO; } else if (x instanceof Byte) { return new Integer(((Byte)x).byteValue() & 0xFF); } else if (x instanceof Number) { return new Integer(((Number) x).intValue()); } else if (x instanceof String) { return new Integer(((String) x).trim()); } else if (x instanceof Boolean) { return ((Boolean) x).booleanValue() ? INTEGER_ONE : INTEGER_ZERO; } break; case java.sql.Types.BIGINT: if (x == null) { return LONG_ZERO; } else if (x instanceof Long) { return x; } else if (x instanceof Byte) { return new Long(((Byte)x).byteValue() & 0xFF); } else if (x instanceof Number) { return new Long(((Number) x).longValue()); } else if (x instanceof String) { return new Long(((String) x).trim()); } else if (x instanceof Boolean) { return ((Boolean) x).booleanValue() ? LONG_ONE : LONG_ZERO; } break; case java.sql.Types.REAL: if (x == null) { return FLOAT_ZERO; } else if (x instanceof Float) { return x; } else if (x instanceof Byte) { return new Float(((Byte)x).byteValue() & 0xFF); } else if (x instanceof Number) { return new Float(((Number) x).floatValue()); } else if (x instanceof String) { return new Float(((String) x).trim()); } else if (x instanceof Boolean) { return ((Boolean) x).booleanValue() ? FLOAT_ONE : FLOAT_ZERO; } break; case java.sql.Types.FLOAT: case java.sql.Types.DOUBLE: if (x == null) { return DOUBLE_ZERO; } else if (x instanceof Double) { return x; } else if (x instanceof Byte) { return new Double(((Byte)x).byteValue() & 0xFF); } else if (x instanceof Number) { return new Double(((Number) x).doubleValue()); } else if (x instanceof String) { return new Double(((String) x).trim()); } else if (x instanceof Boolean) { return ((Boolean) x).booleanValue() ? DOUBLE_ONE : DOUBLE_ZERO; } break; case java.sql.Types.NUMERIC: case java.sql.Types.DECIMAL: if (x == null) { return null; } else if (x instanceof BigDecimal) { return x; } else if (x instanceof Number) { return new BigDecimal(((Number) x).doubleValue()); } else if (x instanceof String) { return new BigDecimal((String) x); } else if (x instanceof Boolean) { return ((Boolean) x).booleanValue() ? BIG_DECIMAL_ONE : BIG_DECIMAL_ZERO; } break; case java.sql.Types.VARCHAR: case java.sql.Types.CHAR: if (x == null) { return null; } else if (x instanceof String) { return x; } else if (x instanceof BigDecimal) { return bigDecimalToString((BigDecimal) x); } else if (x instanceof Number) { return x.toString(); } else if (x instanceof Boolean) { return((Boolean) x).booleanValue() ? "1" : "0"; } else if (x instanceof Clob) { Clob clob = (Clob) x; long length = clob.length(); if (length > Integer.MAX_VALUE) { throw new SQLException(Messages.get("error.normalize.lobtoobig"), "22000"); } return clob.getSubString(1, (int) length); } else if (x instanceof Blob) { Blob blob = (Blob) x; long length = blob.length(); if (length > Integer.MAX_VALUE) { throw new SQLException(Messages.get("error.normalize.lobtoobig"), "22000"); } x = blob.getBytes(1, (int) length); } if (x instanceof byte[]) { try { return new String((byte[]) x, charSet); } catch (UnsupportedEncodingException e) { return new String((byte[]) x); } } return x.toString(); // Last hope! case java.sql.Types.BIT: case JtdsStatement.BOOLEAN: if (x == null) { return Boolean.FALSE; } else if (x instanceof Boolean) { return x; } else if (x instanceof Number) { return(((Number) x).intValue() == 0) ? Boolean.FALSE : Boolean.TRUE; } else if (x instanceof String) { String tmp = ((String) x).trim(); return (tmp.equals("1") || tmp.equalsIgnoreCase("true")) ? Boolean.TRUE : Boolean.FALSE; } break; case java.sql.Types.VARBINARY: case java.sql.Types.BINARY: if (x == null) { return null; } else if (x instanceof byte[]) { return x; } else if (x instanceof Blob) { Blob blob = (Blob) x; return blob.getBytes(1, (int) blob.length()); } else if (x instanceof Clob) { Clob clob = (Clob) x; long length = clob.length(); if (length > Integer.MAX_VALUE) { throw new SQLException(Messages.get("error.normalize.lobtoobig"), "22000"); } x = clob.getSubString(1, (int) length); } if (x instanceof String) { if (charSet == null) { charSet = "ISO-8859-1"; } try { return ((String) x).getBytes(charSet); } catch (UnsupportedEncodingException e) { return ((String) x).getBytes(); } } else if (x instanceof UniqueIdentifier) { return ((UniqueIdentifier) x).getBytes(); } break; case java.sql.Types.TIMESTAMP: if (x == null) { return null; } else if (x instanceof java.sql.Timestamp) { return x; } else if (x instanceof java.sql.Date) { return new java.sql.Timestamp(((java.sql.Date) x).getTime()); } else if (x instanceof java.sql.Time) { return new java.sql.Timestamp(((java.sql.Time) x).getTime()); } else if (x instanceof java.lang.String) { return java.sql.Timestamp.valueOf(((String)x).trim()); } break; case java.sql.Types.DATE: if (x == null) { return null; } else if (x instanceof java.sql.Date) { return x; } else if (x instanceof java.sql.Time) { return DATE_ZERO; } else if (x instanceof java.sql.Timestamp) { synchronized (cal) { cal.setTime((java.util.Date) x); cal.set(Calendar.HOUR_OF_DAY, 0); cal.set(Calendar.MINUTE, 0); cal.set(Calendar.SECOND, 0); cal.set(Calendar.MILLISECOND, 0);// VM1.4+ only return new java.sql.Date(cal.getTimeInMillis()); return new java.sql.Date(cal.getTime().getTime()); } } else if (x instanceof java.lang.String) { return java.sql.Date.valueOf(((String) x).trim()); } break; case java.sql.Types.TIME: if (x == null) { return null; } else if (x instanceof java.sql.Time) { return x; } else if (x instanceof java.sql.Date) { return TIME_ZERO; } else if (x instanceof java.sql.Timestamp) { synchronized (cal) {// VM 1.4+ only cal.setTimeInMillis(((java.sql.Timestamp)x).getTime()); cal.setTime((java.util.Date)x); cal.set(Calendar.YEAR, 1970); cal.set(Calendar.MONTH, 0); cal.set(Calendar.DAY_OF_MONTH,1);// VM 1.4+ only return new java.sql.Time(cal.getTimeInMillis());*/ return new java.sql.Time(cal.getTime().getTime()); } } else if (x instanceof java.lang.String) { return java.sql.Time.valueOf(((String) x).trim()); } break; case java.sql.Types.OTHER: return x; case java.sql.Types.JAVA_OBJECT: throw new SQLException( Messages.get("error.convert.badtypes", x.getClass().getName(), getJdbcTypeName(jdbcType)), "22005"); case java.sql.Types.LONGVARBINARY: case java.sql.Types.BLOB: if (x == null) { return null; } else if (x instanceof Blob) { return x; } else if (x instanceof byte[]) { return new BlobImpl(callerReference, (byte[]) x); } else if (x instanceof Clob) { Clob clob = (Clob) x; x = clob.getSubString(0, (int) clob.length()); // FIXME - Use reader to populate Blob } if (x instanceof String) { BlobImpl blob = new BlobImpl(callerReference); String data = (String) x; if (charSet == null) { charSet = "ISO-8859-1"; } try { blob.setBytes(1, data.getBytes(charSet)); } catch (UnsupportedEncodingException e) { blob.setBytes(1, data.getBytes()); } return blob; } break; case java.sql.Types.LONGVARCHAR: case java.sql.Types.CLOB: if (x == null) { return null; } else if (x instanceof Clob) { return x; } else if (x instanceof Blob) { Blob blob = (Blob) x; x = blob.getBytes(0, (int) blob.length()); // FIXME - Use input stream to populate Clob } else if (x instanceof BigDecimal) { x = bigDecimalToString((BigDecimal) x); } else if (x instanceof Boolean) { x = ((Boolean) x).booleanValue() ? "1" : "0"; } else if (!(x instanceof byte[])) { x = x.toString(); } if (x instanceof byte[]) { ClobImpl clob = new ClobImpl(callerReference); byte[] data = (byte[]) x; if (charSet == null) { charSet = "ISO-8859-1"; } try { clob.setString(1, new String(data, charSet)); } catch (UnsupportedEncodingException e) { clob.setString(1, new String(data)); } return clob; } else if (x instanceof String) { return new ClobImpl(callerReference, (String) x); } break; default: throw new SQLException( Messages.get("error.convert.badtypeconst", getJdbcTypeName(jdbcType)), "HY004"); } throw new SQLException( Messages.get("error.convert.badtypes", x.getClass().getName(), getJdbcTypeName(jdbcType)), "22005"); } catch (NumberFormatException nfe) { throw new SQLException( Messages.get("error.convert.badnumber", getJdbcTypeName(jdbcType)), "22000"); } } | 5753 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5753/4bc471ca6ac0660e505b20b3b018ff9714f2d71a/Support.java/clean/src/main/net/sourceforge/jtds/jdbc/Support.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
760,
1033,
1765,
12,
921,
4894,
2404,
16,
1033,
619,
16,
509,
16579,
559,
16,
514,
1149,
694,
13,
5411,
1216,
6483,
288,
3639,
775,
288,
5411,
1620,
261,
24687,
559,
13,
288,
7734,
648,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
760,
1033,
1765,
12,
921,
4894,
2404,
16,
1033,
619,
16,
509,
16579,
559,
16,
514,
1149,
694,
13,
5411,
1216,
6483,
288,
3639,
775,
288,
5411,
1620,
261,
24687,
559,
13,
288,
7734,
648,... |
connector.synchronize(query, null); | TasksUiPlugin.getSynchronizationManager().synchronize(connector, query, null); | public boolean performFinish() { AbstractRepositoryQuery query = queryPage.getQuery(); if (query != null) { TasksUiPlugin.getTaskListManager().getTaskList().addQuery(query); AbstractRepositoryConnector connector = TasksUiPlugin.getRepositoryManager().getRepositoryConnector( repository.getKind()); if (connector != null) { connector.synchronize(query, null); } } return true; } | 51989 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/51989/0e9216c5160dcb4bbfc03d2e326a3e5f9aa0e1cf/NewTracQueryWizard.java/clean/org.eclipse.mylyn.trac.ui/src/org/eclipse/mylyn/internal/trac/ui/wizard/NewTracQueryWizard.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
1250,
3073,
11641,
1435,
288,
202,
202,
7469,
3305,
1138,
843,
273,
843,
1964,
18,
588,
1138,
5621,
202,
202,
430,
261,
2271,
480,
446,
13,
288,
1082,
202,
6685,
13943,
3773,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
3073,
11641,
1435,
288,
202,
202,
7469,
3305,
1138,
843,
273,
843,
1964,
18,
588,
1138,
5621,
202,
202,
430,
261,
2271,
480,
446,
13,
288,
1082,
202,
6685,
13943,
3773,
... |
AtomTypeHandler handler = new AtomTypeHandler(); | AtomTypeHandler handler = new AtomTypeHandler(new ChemObject().getBuilder()); | public void testGetAtomTypes() { AtomTypeHandler handler = new AtomTypeHandler(); // nothing is read assertNull(handler.getAtomTypes()); } | 1306 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1306/13a1dde80ed28c205e325d7ac5ada2d3ead2c967/AtomTypeHandlerTest.java/clean/src/org/openscience/cdk/test/config/atomtypes/AtomTypeHandlerTest.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1842,
967,
3641,
2016,
1435,
288,
3639,
7149,
559,
1503,
1838,
273,
394,
7149,
559,
1503,
12,
2704,
26542,
921,
7675,
588,
1263,
10663,
3639,
368,
5083,
353,
855,
3639,
1815,
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,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1842,
967,
3641,
2016,
1435,
288,
3639,
7149,
559,
1503,
1838,
273,
394,
7149,
559,
1503,
12,
2704,
26542,
921,
7675,
588,
1263,
10663,
3639,
368,
5083,
353,
855,
3639,
1815,
2... |
cfw.stopMethod((short)20, null); | cfw.stopMethod((short)2, null); | private static void generateEmptyCtor(ClassFileWriter cfw, String adapterName, String superName, String scriptClassName) { cfw.startMethod("<init>", "()V", ClassFileWriter.ACC_PUBLIC); // Invoke base class constructor cfw.add(ByteCode.ALOAD_0); // this cfw.addInvoke(ByteCode.INVOKESPECIAL, superName, "<init>", "()V"); // Load script class cfw.add(ByteCode.NEW, scriptClassName); cfw.add(ByteCode.DUP); cfw.addInvoke(ByteCode.INVOKESPECIAL, scriptClassName, "<init>", "()V"); // Run script and save resulting scope cfw.addInvoke(ByteCode.INVOKESTATIC, "org/mozilla/javascript/ScriptRuntime", "runScript", "(Lorg/mozilla/javascript/Script;" +")Lorg/mozilla/javascript/Scriptable;"); cfw.add(ByteCode.ASTORE_1); // Save the Scriptable in instance variable "delegee" cfw.add(ByteCode.ALOAD_0); // this cfw.add(ByteCode.ALOAD_1); // the Scriptable cfw.add(ByteCode.PUTFIELD, adapterName, "delegee", "Lorg/mozilla/javascript/Scriptable;"); // create a wrapper object to be used as "this" in method calls cfw.add(ByteCode.ALOAD_1); // the Scriptable cfw.add(ByteCode.ALOAD_0); // this cfw.addInvoke(ByteCode.INVOKESTATIC, "org/mozilla/javascript/JavaAdapter", "setAdapterProto", "(Lorg/mozilla/javascript/Scriptable;" +"Ljava/lang/Object;" +")Lorg/mozilla/javascript/Scriptable;"); //save the wrapper cfw.add(ByteCode.ASTORE_1); cfw.add(ByteCode.ALOAD_0); // this cfw.add(ByteCode.ALOAD_1); // first arg cfw.add(ByteCode.PUTFIELD, adapterName, "self", "Lorg/mozilla/javascript/Scriptable;"); cfw.add(ByteCode.RETURN); cfw.stopMethod((short)20, null); // TODO: magic number "20" } | 12904 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/12904/22d09dcc1418990bbcdca43797688eb716ccb324/JavaAdapter.java/clean/js/rhino/src/org/mozilla/javascript/JavaAdapter.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
760,
918,
2103,
1921,
27425,
12,
797,
812,
2289,
6080,
91,
16,
4766,
1850,
514,
4516,
461,
16,
4766,
1850,
514,
2240,
461,
16,
4766,
1850,
514,
2728,
3834,
13,
565,
288,
3639,
608... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
2103,
1921,
27425,
12,
797,
812,
2289,
6080,
91,
16,
4766,
1850,
514,
4516,
461,
16,
4766,
1850,
514,
2240,
461,
16,
4766,
1850,
514,
2728,
3834,
13,
565,
288,
3639,
608... |
vg[4].setColor(new Color(0, 0, 0, 255)); | vg[4].setColor(new Color(51, 51, 51, 255)); | public static void paint(VectorGraphics[] vg) { vg[0].setColor(new Color(0, 0, 0, 255)); vg[0].setFont(new Font("Dialog", 0, 12)); vg[1] = (VectorGraphics)vg[0].create(); vg[1].setClip(0, 0, 600, 600); vg[2] = (VectorGraphics)vg[1].create(); vg[2].setColor(new Color(204, 204, 204, 255)); vg[2].fillRect(0, 0, 600, 600); vg[2].dispose(); vg[3] = (VectorGraphics)vg[1].create(); vg[4] = (VectorGraphics)vg[3].create(179, 5, 242, 38); vg[4].setColor(new Color(0, 0, 0, 255)); vg[4].setFont(new Font("Dialog", 0, 12)); vg[4].setColor(new Color(0, 0, 0, 255)); vg[4].setFont(new Font("Dialog", 0, 12)); vg[5] = (VectorGraphics)vg[4].create(); vg[6] = (VectorGraphics)vg[5].create(); vg[6].setColor(new Color(255, 255, 255, 255)); vg[6].fillRect(0, 0, 242, 38); vg[6].setColor(new Color(0, 0, 0, 255)); vg[6].setFont(new Font("Serif", 0, 14)); vg[6].drawChars(new char[] { '\n', '<', 'V', 'e', 'c', 't', 'o', 'r' }, 1, 7, 3, 25); vg[6].setColor(new Color(0, 0, 0, 255)); vg[6].setFont(new Font("Serif", 1, 12)); vg[6].drawChars(new char[] { '\n', '<', 'V', 'e', 'c', 't', 'o', 'r', 'G', 'r', 'a', 'p', 'h', 'i', 'c', 's' }, 8, 8, 49, 17); vg[6].setColor(new Color(0, 0, 0, 255)); vg[6].setFont(new Font("Serif", 0, 14)); vg[6].drawChars(new char[] { '\n', '<', 'V', 'e', 'c', 't', 'o', 'r', 'G', 'r', 'a', 'p', 'h', 'i', 'c', 's', ' ', '&', ' ', 'A', 'd', 'a', 'p', 't', 'e', 'r' }, 16, 10, 96, 25); vg[6].setColor(new Color(0, 0, 0, 255)); vg[6].setFont(new Font("Serif", 2, 12)); vg[6].drawChars(new char[] { '\n', '<', 'V', 'e', 'c', 't', 'o', 'r', 'G', 'r', 'a', 'p', 'h', 'i', 'c', 's', ' ', '&', ' ', 'A', 'd', 'a', 'p', 't', 'e', 'r', 'C', 'a', 'r', 'd' }, 26, 4, 159, 32); vg[6].setColor(new Color(0, 0, 0, 255)); vg[6].setFont(new Font("Serif", 0, 14)); vg[6].drawChars(new char[] { '\n', '<', 'V', 'e', 'c', 't', 'o', 'r', 'G', 'r', 'a', 'p', 'h', 'i', 'c', 's', ' ', '&', ' ', 'A', 'd', 'a', 'p', 't', 'e', 'r', 'C', 'a', 'r', 'd', ' ', '=', ' ', 'e' }, 30, 4, 184, 25); vg[6].setColor(new Color(0, 0, 0, 255)); vg[6].setFont(new Font("Serif", 0, 12)); vg[6].drawChars(new char[] { '\n', '<', 'V', 'e', 'c', 't', 'o', 'r', 'G', 'r', 'a', 'p', 'h', 'i', 'c', 's', ' ', '&', ' ', 'A', 'd', 'a', 'p', 't', 'e', 'r', 'C', 'a', 'r', 'd', ' ', '=', ' ', 'e', 'x' }, 34, 1, 206, 17); vg[6].setColor(new Color(0, 0, 0, 255)); vg[6].setFont(new Font("Serif", 0, 12)); vg[6].drawChars(new char[] { '\n', '<', 'V', 'e', 'c', 't', 'o', 'r', 'G', 'r', 'a', 'p', 'h', 'i', 'c', 's', ' ', '&', ' ', 'A', 'd', 'a', 'p', 't', 'e', 'r', 'C', 'a', 'r', 'd', ' ', '=', ' ', 'e', 'x', '2' }, 35, 1, 211, 17); vg[6].setColor(new Color(0, 0, 0, 255)); vg[6].setFont(new Font("Serif", 0, 12)); vg[6].drawChars(new char[] { '\n', '<', 'V', 'e', 'c', 't', 'o', 'r', 'G', 'r', 'a', 'p', 'h', 'i', 'c', 's', ' ', '&', ' ', 'A', 'd', 'a', 'p', 't', 'e', 'r', 'C', 'a', 'r', 'd', ' ', '=', ' ', 'e', 'x', '2', 'y' }, 36, 1, 217, 17); vg[6].setColor(new Color(0, 0, 0, 255)); vg[6].setFont(new Font("Serif", 0, 12)); vg[6].drawChars(new char[] { '\n', '<', 'V', 'e', 'c', 't', 'o', 'r', 'G', 'r', 'a', 'p', 'h', 'i', 'c', 's', ' ', '&', ' ', 'A', 'd', 'a', 'p', 't', 'e', 'r', 'C', 'a', 'r', 'd', ' ', '=', ' ', 'e', 'x', '2', 'y', '3' }, 37, 1, 224, 17); vg[6].setColor(new Color(0, 0, 0, 255)); vg[6].setFont(new Font("Serif", 0, 14)); vg[6].drawChars(new char[] { '\n', '<', 'V', 'e', 'c', 't', 'o', 'r', 'G', 'r', 'a', 'p', 'h', 'i', 'c', 's', ' ', '&', ' ', 'A', 'd', 'a', 'p', 't', 'e', 'r', 'C', 'a', 'r', 'd', ' ', '=', ' ', 'e', 'x', '2', 'y', '3', '>' }, 38, 1, 230, 25); vg[6].setColor(new Color(0, 0, 0, 255)); vg[6].setFont(new Font("Serif", 0, 14)); vg[6].dispose(); vg[5].dispose(); vg[4].dispose(); vg[3].dispose(); vg[1].dispose(); } // paint | 57341 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/57341/a285e1f74c830a5130099c3322f3a09dfe75f4c1/TestHTML.java/clean/freehep-graphicsio-java/src/test/resources/org/freehep/graphicsio/java/test/TestHTML.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
540,
1071,
760,
918,
12574,
12,
5018,
17558,
8526,
19524,
13,
288,
5411,
19524,
63,
20,
8009,
542,
2957,
12,
2704,
5563,
12,
20,
16,
374,
16,
374,
16,
4561,
10019,
5411,
19524,
63,
20,
8009,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
760,
918,
12574,
12,
5018,
17558,
8526,
19524,
13,
288,
5411,
19524,
63,
20,
8009,
542,
2957,
12,
2704,
5563,
12,
20,
16,
374,
16,
374,
16,
4561,
10019,
5411,
19524,
63,
20,
8009,... |
void initPlugins() { | protected void initPlugins() { | void initPlugins() { /* grab our 3rd party plugins and load them using security manager */ String[] files = new java.io.File(pluginDir).list(); for(int i= 0; i < files.length; i++) { if(files[i].endsWith(".jar")) { loadPlugin(files[i].substring(0,files[i].lastIndexOf(".jar"))); } else { loadPlugin(files[i]); } } } | 8150 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/8150/791b5cca75536f160ce06c9f90f61d6370c6faba/LockssDaemon.java/buggy/src/org/lockss/app/LockssDaemon.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
4750,
918,
1208,
9461,
1435,
288,
565,
1748,
11086,
3134,
890,
13623,
18285,
4799,
471,
1262,
2182,
1450,
4373,
3301,
1195,
565,
514,
8526,
1390,
273,
394,
2252,
18,
1594,
18,
812,
12,
40... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
918,
1208,
9461,
1435,
288,
565,
1748,
11086,
3134,
890,
13623,
18285,
4799,
471,
1262,
2182,
1450,
4373,
3301,
1195,
565,
514,
8526,
1390,
273,
394,
2252,
18,
1594,
18,
812,
12,
40... |
versionLabel.setBorder(javax.swing.BorderFactory.createEmptyBorder(5, 5, 5, 5)); | org.openide.awt.Mnemonics.setLocalizedText(versionLabel, OStrings.getString("ABOUTDIALOG_VERSION_PREFIX")); versionLabel.setBorder(new javax.swing.border.EmptyBorder(new java.awt.Insets(5, 5, 5, 5))); | private void initComponents() { buttonPanel = new javax.swing.JPanel(); jLabel2 = new javax.swing.JLabel(); jPanel1 = new javax.swing.JPanel(); licenseButton = new javax.swing.JButton(); okButton = new javax.swing.JButton(); versionLabel = new javax.swing.JLabel(); scroll = new javax.swing.JScrollPane(); abouttext = new javax.swing.JTextArea(); getContentPane().setLayout(new java.awt.BorderLayout(5, 5)); setTitle(OStrings.getString("ABOUTDIALOG_TITLE")); setModal(true); setResizable(false); addWindowListener(new java.awt.event.WindowAdapter() { public void windowClosing(java.awt.event.WindowEvent evt) { closeDialog(evt); } }); buttonPanel.setLayout(new java.awt.BorderLayout()); buttonPanel.setBorder(javax.swing.BorderFactory.createEmptyBorder(5, 5, 5, 5)); org.openide.awt.Mnemonics.setLocalizedText(jLabel2, OStrings.getString("ABOUTDIALOG_COPYRIGHT")); jLabel2.setBorder(javax.swing.BorderFactory.createEmptyBorder(5, 5, 5, 5)); buttonPanel.add(jLabel2, java.awt.BorderLayout.WEST); org.openide.awt.Mnemonics.setLocalizedText(licenseButton, OStrings.getString("ABOUTDIALOG_LICENSE_BUTTON")); licenseButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { licenseButtonActionPerformed(evt); } }); jPanel1.add(licenseButton); org.openide.awt.Mnemonics.setLocalizedText(okButton, OStrings.getString("BUTTON_OK")); okButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { okButtonActionPerformed(evt); } }); jPanel1.add(okButton); buttonPanel.add(jPanel1, java.awt.BorderLayout.EAST); getContentPane().add(buttonPanel, java.awt.BorderLayout.SOUTH); versionLabel.setIcon(new javax.swing.ImageIcon(getClass().getResource("/org/omegat/gui/resources/OmegaT.gif"))); versionLabel.setBorder(javax.swing.BorderFactory.createEmptyBorder(5, 5, 5, 5)); getContentPane().add(versionLabel, java.awt.BorderLayout.NORTH); scroll.setBorder(javax.swing.BorderFactory.createEmptyBorder(5, 5, 5, 5)); abouttext.setBackground(javax.swing.UIManager.getDefaults().getColor("Label.background")); abouttext.setEditable(false); abouttext.setFont(versionLabel.getFont()); abouttext.setLineWrap(true); abouttext.setText(OStrings.getString("ABOUTDIALOG_CONTRIBUTORS")); abouttext.setWrapStyleWord(true); scroll.setViewportView(abouttext); getContentPane().add(scroll, java.awt.BorderLayout.CENTER); java.awt.Dimension screenSize = java.awt.Toolkit.getDefaultToolkit().getScreenSize(); setBounds((screenSize.width-515)/2, (screenSize.height-451)/2, 515, 451); } | 8797 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/8797/10559d1d3c67d6ee0c6a286d92e33b564128d9f6/AboutDialog.java/clean/src/org/omegat/gui/dialogs/AboutDialog.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
918,
1208,
7171,
1435,
565,
288,
3639,
3568,
5537,
273,
394,
6863,
18,
5328,
310,
18,
46,
5537,
5621,
3639,
26538,
22,
273,
394,
6863,
18,
5328,
310,
18,
46,
2224,
5621,
3639,
178... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1208,
7171,
1435,
565,
288,
3639,
3568,
5537,
273,
394,
6863,
18,
5328,
310,
18,
46,
5537,
5621,
3639,
26538,
22,
273,
394,
6863,
18,
5328,
310,
18,
46,
2224,
5621,
3639,
178... |
if( !visitExpression( ((IASTFunctionCallExpression)expression).getParameterExpression(), action ) ) return false; | if( ((IASTFunctionCallExpression)expression).getParameterExpression() != null ) if( !visitExpression( ((IASTFunctionCallExpression)expression).getParameterExpression(), action ) ) return false; | public static boolean visitExpression(IASTExpression expression, CPPBaseVisitorAction action) { if( action.processExpressions ){ switch( action.processExpression( expression ) ){ case CPPBaseVisitorAction.PROCESS_ABORT : return false; case CPPBaseVisitorAction.PROCESS_SKIP : return true; default : break; } } if( expression instanceof IASTArraySubscriptExpression ){ if( !visitExpression( ((IASTArraySubscriptExpression)expression).getArrayExpression(), action ) ) return false; if( !visitExpression( ((IASTArraySubscriptExpression)expression).getSubscriptExpression(), action ) ) return false; } else if( expression instanceof IASTBinaryExpression ){ if( !visitExpression( ((IASTBinaryExpression)expression).getOperand1(), action ) ) return false; if( !visitExpression( ((IASTBinaryExpression)expression).getOperand2(), action ) ) return false; } else if( expression instanceof IASTConditionalExpression){ if( !visitExpression( ((IASTConditionalExpression)expression).getLogicalConditionExpression(), action ) ) return false; if( !visitExpression( ((IASTConditionalExpression)expression).getNegativeResultExpression(), action ) ) return false; if( !visitExpression( ((IASTConditionalExpression)expression).getPositiveResultExpression(), action ) ) return false; } else if( expression instanceof IASTExpressionList ){ IASTExpression[] list = ((IASTExpressionList)expression).getExpressions(); for( int i = 0; i < list.length; i++){ if( list[i] == null ) break; if( !visitExpression( list[i], action ) ) return false; } } else if( expression instanceof IASTFieldReference ){ if( !visitExpression( ((IASTFieldReference)expression).getFieldOwner(), action ) ) return false; if( !visitName( ((IASTFieldReference)expression).getFieldName(), action ) ) return false; } else if( expression instanceof IASTFunctionCallExpression ){ if( !visitExpression( ((IASTFunctionCallExpression)expression).getFunctionNameExpression(), action ) ) return false; if( !visitExpression( ((IASTFunctionCallExpression)expression).getParameterExpression(), action ) ) return false; } else if( expression instanceof IASTIdExpression ){ if( !visitName( ((IASTIdExpression)expression).getName(), action ) ) return false; } else if( expression instanceof IASTTypeIdExpression ){ if( !visitTypeId( ((IASTTypeIdExpression)expression).getTypeId(), action ) ) return false; } else if( expression instanceof IASTCastExpression ){ if( !visitTypeId( ((IASTCastExpression)expression).getTypeId(), action ) ) return false; if( !visitExpression( ((IASTCastExpression)expression).getOperand(), action ) ) return false; } else if( expression instanceof IASTUnaryExpression ){ if( !visitExpression( ((IASTUnaryExpression)expression).getOperand(), action ) ) return false; } else if( expression instanceof IGNUASTCompoundStatementExpression ){ if( !visitStatement( ((IGNUASTCompoundStatementExpression)expression).getCompoundStatement(), action ) ) return false; } else if( expression instanceof ICPPASTDeleteExpression ){ if( !visitExpression( ((ICPPASTDeleteExpression)expression).getOperand(), action ) ) return false; } else if( expression instanceof ICPPASTNewExpression ) { ICPPASTNewExpression newExp = (ICPPASTNewExpression) expression; if( newExp.getNewPlacement() != null ) if( !visitExpression( newExp.getNewPlacement(), action ) ) return false; if( newExp.getTypeId() != null ) if( !visitTypeId( newExp.getTypeId(), action ) ) return false; IASTExpression [] exps = newExp.getNewTypeIdArrayExpressions(); for( int i = 0; i < exps.length; i++ ){ if( !visitExpression( exps[i], action ) ) return false; } if( newExp.getNewInitializer() != null ) if( !visitExpression( newExp.getNewInitializer(), action ) ) return false; } else if( expression instanceof ICPPASTSimpleTypeConstructorExpression ){ if( !visitExpression( ((ICPPASTSimpleTypeConstructorExpression)expression).getInitialValue(), action ) ) return false; } else if( expression instanceof ICPPASTTypenameExpression ){ if( !visitName( ((ICPPASTTypenameExpression)expression).getName(), action ) ) return false; if( !visitExpression( ((ICPPASTTypenameExpression)expression).getInitialValue(), action ) ) return false; } return true; } | 54911 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54911/6ac6636352f18720a6f0fe83ec1f52da9fa6e77c/CPPVisitor.java/buggy/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/dom/parser/cpp/CPPVisitor.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
760,
1250,
3757,
2300,
12,
45,
9053,
2300,
2652,
16,
5181,
52,
2171,
7413,
1803,
1301,
13,
288,
202,
202,
430,
12,
1301,
18,
2567,
8927,
262,
95,
1082,
565,
1620,
12,
1301,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1250,
3757,
2300,
12,
45,
9053,
2300,
2652,
16,
5181,
52,
2171,
7413,
1803,
1301,
13,
288,
202,
202,
430,
12,
1301,
18,
2567,
8927,
262,
95,
1082,
565,
1620,
12,
1301,
... |
if (tok.charAt(i) != SPACE) { | tokSpaces += SPACE; if (tok.charAt(i) == ' ') { tokSpaces += ' '; } else if (tok.charAt(i) == '\t') { tokSpaces += '\t'; } else{ | public static String getDocToParseFromLine(IDocument doc, int lineOfOffset) { String wholeDoc = doc.get(); String newDoc = ""; try { IRegion lineInformation = doc.getLineInformation(lineOfOffset); int docLength = doc.getLength(); String before = wholeDoc.substring(0, lineInformation.getOffset()); String after = wholeDoc.substring(lineInformation.getOffset() + lineInformation.getLength(), docLength); String src = doc.get(lineInformation.getOffset(), lineInformation.getLength()); String spaces = ""; for (int i = 0; i < src.length(); i++) { if (src.charAt(i) != ' ') { break; } spaces += SPACE; } src = src.trim(); if (src.startsWith("class")){ //let's discover if we should put a pass or not... //e.g if we are declaring the class and no methods are put, we have //to put a pass, otherwise, the pass would ruin the indentation, therefore, //we cannot put it. // //so, search for another class or def after this line and discover if it has another indentation //or not. StringTokenizer tokenizer = new StringTokenizer(after, "\r\n"); String tokSpaces = null; while(tokenizer.hasMoreTokens()){ String tok = tokenizer.nextToken(); String t = tok.trim(); if(t.startsWith("class") || t.startsWith("def") ){ tokSpaces = ""; for (int i = 0; i < tok.length(); i++) { if (tok.charAt(i) != SPACE) { break; } tokSpaces += SPACE; } break; } } if(tokSpaces != null && tokSpaces.length() > spaces.length()){ if(src.indexOf(BEGIN_PARENTHESIS) != -1){ src = src.substring(0, src.indexOf(BEGIN_PARENTHESIS))+Character.toString(COLON); }else{ src = "class COMPLETION_HELPER_CLASS:"; } }else{ if(src.indexOf(BEGIN_PARENTHESIS) != -1){ src = src.substring(0, src.indexOf(BEGIN_PARENTHESIS))+":pass"; }else{ src = "class COMPLETION_HELPER_CLASS:pass"; } } }else{ src = "pass"; } newDoc = before; newDoc += spaces + src; newDoc += after; } catch (BadLocationException e1) { //that's ok... //e1.printStackTrace(); return null; } return newDoc; } | 1319 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1319/aeeba7e3328205f0d1aaf1ada088bd7913078765/DocUtils.java/buggy/org.python.pydev.core/src/org/python/pydev/core/docutils/DocUtils.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
760,
514,
17999,
774,
3201,
1265,
1670,
12,
734,
504,
650,
997,
16,
509,
980,
951,
2335,
13,
288,
3639,
514,
7339,
1759,
273,
997,
18,
588,
5621,
3639,
514,
394,
1759,
273,
1408,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
17999,
774,
3201,
1265,
1670,
12,
734,
504,
650,
997,
16,
509,
980,
951,
2335,
13,
288,
3639,
514,
7339,
1759,
273,
997,
18,
588,
5621,
3639,
514,
394,
1759,
273,
1408,
... |
PseudoAtom a = new PseudoAtom(label, point); | PseudoAtom a = builder.newPseudoAtom(label, point); | public void testPseudoAtom_String_Point3d() { Point3d point = new Point3d(1.0, 2.0, 3.0); String label = "Arg255"; PseudoAtom a = new PseudoAtom(label, point); assertEquals("R", a.getSymbol()); assertEquals(label, a.getLabel()); assertEquals(point, a.getPoint3d()); assertNull(a.getPoint2d()); assertNull(a.getFractionalPoint3d()); } | 45167 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/45167/67261c8143759a6ee4feb79dc1687d6dcfa25f40/PseudoAtomTest.java/buggy/src/org/openscience/cdk/test/PseudoAtomTest.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1842,
26716,
3641,
67,
780,
67,
2148,
23,
72,
1435,
288,
3639,
4686,
23,
72,
1634,
273,
394,
4686,
23,
72,
12,
21,
18,
20,
16,
576,
18,
20,
16,
890,
18,
20,
1769,
3639,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
26716,
3641,
67,
780,
67,
2148,
23,
72,
1435,
288,
3639,
4686,
23,
72,
1634,
273,
394,
4686,
23,
72,
12,
21,
18,
20,
16,
576,
18,
20,
16,
890,
18,
20,
1769,
3639,
... |
++curPos; if ((i = jjnewStateCnt) == (startsAt = 6 - (jjnewStateCnt = startsAt))) return curPos; try { curChar = input_stream.readChar(); } catch (java.io.IOException e) { return curPos; | } while(i != startsAt); } else { int i2 = (curChar & 0xff) >> 6; long l2 = 1L << (curChar & 077); MatchLoop: do { switch(jjstateSet[--i]) { case 1: case 2: if ((jjbitVec1[i2] & l2) == 0L) break; if (kind > 58) kind = 58; jjCheckNAdd(2); break; default : break; | private final int jjMoveNfa_11(int startState, int curPos) { int[] nextStates; int startsAt = 0; jjnewStateCnt = 6; int i = 1; jjstateSet[0] = startState; int j, kind = 0x7fffffff; for (; ;) { if (++jjround == 0x7fffffff) ReInitRounds(); if (curChar < 64) { long l = 1L << curChar; MatchLoop: do { switch (jjstateSet[--i]) { case 1: if ((0x100002600L & l) != 0L) { if (kind > 21) kind = 21; jjCheckNAdd(0); } else if (curChar == 33) jjCheckNAdd(3); else if (curChar == 36) { if (kind > 58) kind = 58; jjCheckNAdd(2); } else if (curChar == 63) jjCheckNAdd(3); break; case 0: if ((0x100002600L & l) == 0L) break; kind = 21; jjCheckNAdd(0); break; case 2: if ((0x7ff601000000000L & l) == 0L) break; if (kind > 58) kind = 58; jjCheckNAdd(2); break; case 3: if (curChar == 62) kind = 60; break; case 4: if (curChar == 63) jjCheckNAdd(3); break; case 5: if (curChar == 33) jjCheckNAdd(3); break; default : break; } } while (i != startsAt); } else if (curChar < 128) { long l = 1L << (curChar & 077); MatchLoop: do { switch (jjstateSet[--i]) { case 1: case 2: if ((0x7fffffe87fffffeL & l) == 0L) break; if (kind > 58) kind = 58; jjCheckNAdd(2); break; default : break; } } while (i != startsAt); } else { int i2 = (curChar & 0xff) >> 6; long l2 = 1L << (curChar & 077); MatchLoop: do { switch (jjstateSet[--i]) { case 1: case 2: if ((jjbitVec1[i2] & l2) == 0L) break; if (kind > 58) kind = 58; jjCheckNAdd(2); break; default : break; } } while (i != startsAt); } if (kind != 0x7fffffff) { jjmatchedKind = kind; jjmatchedPos = curPos; kind = 0x7fffffff; } ++curPos; if ((i = jjnewStateCnt) == (startsAt = 6 - (jjnewStateCnt = startsAt))) return curPos; try { curChar = input_stream.readChar(); } catch (java.io.IOException e) { return curPos; } } } | 41673 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/41673/bad9201cffeb6c6da295101be65bfa4924caa39e/JspParserTokenManager.java/clean/pmd/src/net/sourceforge/pmd/jsp/ast/JspParserTokenManager.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
727,
509,
10684,
7607,
50,
507,
67,
2499,
12,
474,
787,
1119,
16,
509,
662,
1616,
13,
288,
3639,
509,
8526,
1024,
7629,
31,
3639,
509,
2542,
861,
273,
374,
31,
3639,
10684,
2704,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
727,
509,
10684,
7607,
50,
507,
67,
2499,
12,
474,
787,
1119,
16,
509,
662,
1616,
13,
288,
3639,
509,
8526,
1024,
7629,
31,
3639,
509,
2542,
861,
273,
374,
31,
3639,
10684,
2704,
... |
if (parent instanceof TaskAdapter) { this.parent = ((TaskAdapter) parent).getProxy(); | if (parent instanceof TypeAdapter) { this.parent = ((TypeAdapter) parent).getProxy(); | public NestedElementHandler(ProjectHelperImpl helperImpl, DocumentHandler parentHandler, Object parent, RuntimeConfigurable parentWrapper, Target target) { super(helperImpl, parentHandler); if (parent instanceof TaskAdapter) { this.parent = ((TaskAdapter) parent).getProxy(); } else { this.parent = parent; } this.parentWrapper = parentWrapper; this.target = target; } | 506 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/506/8701272b2418d74536d09b289f118d1833d42217/ProjectHelperImpl.java/buggy/src/main/org/apache/tools/ant/helper/ProjectHelperImpl.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
540,
1071,
19071,
1046,
1503,
12,
4109,
2276,
2828,
4222,
2828,
16,
4766,
565,
4319,
1503,
982,
1503,
16,
4766,
565,
1033,
982,
16,
4766,
565,
2509,
31660,
982,
3611,
16,
4766,
565,
5916,
1018... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
19071,
1046,
1503,
12,
4109,
2276,
2828,
4222,
2828,
16,
4766,
565,
4319,
1503,
982,
1503,
16,
4766,
565,
1033,
982,
16,
4766,
565,
2509,
31660,
982,
3611,
16,
4766,
565,
5916,
1018... |
MethodGen methodGen = getMethodGen(method); | protected LiveLocalStoreDataflow analyze(Method method) throws DataflowAnalysisException, CFGBuilderException { CFG cfg = getCFG(method); MethodGen methodGen = getMethodGen(method); ReverseDepthFirstSearch rdfs = getReverseDepthFirstSearch(method); LiveLocalStoreAnalysis analysis = new LiveLocalStoreAnalysis(methodGen, rdfs); LiveLocalStoreDataflow dataflow = new LiveLocalStoreDataflow(cfg, analysis); dataflow.execute(); return dataflow; } | 10715 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/10715/1b864c21fda11ce7f691d8c1daca878f4bf4a0b7/ClassContext.java/clean/findbugs/src/java/edu/umd/cs/findbugs/ba/ClassContext.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
4697,
202,
1117,
21559,
2042,
2257,
751,
2426,
12375,
12,
1305,
707,
13,
6862,
202,
15069,
1910,
2426,
9418,
503,
16,
7577,
1263,
503,
288,
25083,
202,
19727,
2776,
273,
1927,
42,
43,
12,
2039... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
4697,
202,
1117,
21559,
2042,
2257,
751,
2426,
12375,
12,
1305,
707,
13,
6862,
202,
15069,
1910,
2426,
9418,
503,
16,
7577,
1263,
503,
288,
25083,
202,
19727,
2776,
273,
1927,
42,
43,
12,
2039... | |
il.append(classGen.loadTranslet()); il.append(new INVOKEVIRTUAL(cpg.addMethodref(TRANSLET_CLASS, POP_PARAM_FRAME, POP_PARAM_FRAME_SIG) )); | final int pop = cpg.addMethodref(TRANSLET_CLASS, POP_PARAM_FRAME, POP_PARAM_FRAME_SIG); il.append(classGen.loadTranslet()); il.append(new INVOKEVIRTUAL(pop)); | public void translate(ClassGenerator classGen, MethodGenerator methodGen) { final Stylesheet stylesheet = classGen.getStylesheet(); final ConstantPoolGen cpg = classGen.getConstantPool(); final InstructionList il = methodGen.getInstructionList(); // Push a new parameter frame if (stylesheet.hasLocalParams() || hasContents()) { il.append(classGen.loadTranslet()); // push param frame il.append(new INVOKEVIRTUAL(cpg.addMethodref(TRANSLET_CLASS, PUSH_PARAM_FRAME, PUSH_PARAM_FRAME_SIG) )); // translate with-params translateContents(classGen, methodGen); } final String className = stylesheet.getClassName(); // Generate a valid Java method name String methodName = _name.toString(); methodName = methodName.replace('.', '$'); methodName = methodName.replace('-', '$'); il.append(classGen.loadTranslet()); il.append(methodGen.loadDOM()); il.append(methodGen.loadIterator()); il.append(methodGen.loadHandler()); il.append(methodGen.loadCurrentNode()); il.append(new INVOKEVIRTUAL(cpg.addMethodref(className, methodName, "(" + DOM_INTF_SIG + NODE_ITERATOR_SIG + TRANSLET_OUTPUT_SIG + NODE_SIG +")V"))); // Pop parameter frame if (stylesheet.hasLocalParams() || hasContents()) { il.append(classGen.loadTranslet()); // pop param frame il.append(new INVOKEVIRTUAL(cpg.addMethodref(TRANSLET_CLASS, POP_PARAM_FRAME, POP_PARAM_FRAME_SIG) )); } } | 46591 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/46591/e3296098c50df9e4a5c3e7109a406fe731973984/CallTemplate.java/clean/src/org/apache/xalan/xsltc/compiler/CallTemplate.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
4204,
12,
797,
3908,
667,
7642,
16,
2985,
3908,
707,
7642,
13,
288,
202,
6385,
29483,
2963,
13820,
273,
667,
7642,
18,
588,
24656,
5621,
202,
6385,
10551,
2864,
7642,
3283,
75,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
4204,
12,
797,
3908,
667,
7642,
16,
2985,
3908,
707,
7642,
13,
288,
202,
6385,
29483,
2963,
13820,
273,
667,
7642,
18,
588,
24656,
5621,
202,
6385,
10551,
2864,
7642,
3283,
75,... |
VALUE rb_hash_aref(VALUE hash, VALUE key) {throw missing();} | RubyObject rb_hash_aref(VALUE hash, VALUE key) {throw missing();} | VALUE rb_hash_aref(VALUE hash, VALUE key) {throw missing();} | 47619 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/47619/a2024bddc1b8e83f4e8075d2080935c221a833fe/parse.java/clean/org/jruby/parser/parse.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
5848,
7138,
67,
2816,
67,
834,
74,
12,
4051,
1651,
16,
5848,
498,
13,
288,
12849,
3315,
5621,
97,
2,
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,
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... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
5848,
7138,
67,
2816,
67,
834,
74,
12,
4051,
1651,
16,
5848,
498,
13,
288,
12849,
3315,
5621,
97,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
if (!thread.isSuspended()) { throw new IllegalArgumentException("Thread must be suspended to set " + "as current. Given: " + thread); | if (! thread.isSuspended()) { throw new IllegalArgumentException("Thread must be suspended to set as current. Given: " + thread); | synchronized boolean setCurrentThread(ThreadReference thread) { if (!thread.isSuspended()) { throw new IllegalArgumentException("Thread must be suspended to set " + "as current. Given: " + thread); } try { if ((_suspendedThreads.isEmpty() || !_suspendedThreads.contains(thread.uniqueID())) && (thread.frameCount() > 0)) { _suspendedThreads.push(thread); return true; } else return false; } catch (IncompatibleThreadStateException itse) { // requesting stack frames should be fine, since the thread must be // suspended or frameCount() is not called throw new UnexpectedException(itse); } } | 11192 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/11192/fa54651cc7ac0d03884ebcafd7e8520df74651a1/JPDADebugger.java/clean/drjava/src/edu/rice/cs/drjava/model/debug/JPDADebugger.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
3852,
1250,
12589,
3830,
12,
3830,
2404,
2650,
13,
288,
565,
309,
16051,
5930,
18,
291,
55,
22942,
10756,
288,
1377,
604,
394,
2754,
2932,
3830,
1297,
506,
21850,
358,
444,
315,
397,
2915... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
3852,
1250,
12589,
3830,
12,
3830,
2404,
2650,
13,
288,
565,
309,
16051,
5930,
18,
291,
55,
22942,
10756,
288,
1377,
604,
394,
2754,
2932,
3830,
1297,
506,
21850,
358,
444,
315,
397,
2915... |
InetAddress getPrimaryIPAddress() { | FreenetInetAddress getPrimaryIPAddress() { | InetAddress getPrimaryIPAddress() { if(lastIPAddress == null) return detectPrimaryIPAddress(); return lastIPAddress; } | 49933 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/49933/474d190c633c367c5c3ff7fbe0f75a1ea669294b/Node.java/buggy/src/freenet/node/Node.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
478,
2842,
278,
382,
278,
1887,
11398,
22507,
1435,
288,
377,
202,
430,
12,
2722,
22507,
422,
446,
13,
327,
5966,
6793,
22507,
5621,
377,
202,
2463,
1142,
22507,
31,
565,
289,
2,
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,
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... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
478,
2842,
278,
382,
278,
1887,
11398,
22507,
1435,
288,
377,
202,
430,
12,
2722,
22507,
422,
446,
13,
327,
5966,
6793,
22507,
5621,
377,
202,
2463,
1142,
22507,
31,
565,
289,
2,
-100,
... |
Object[] args = { value.toString(), NativeJavaMethod.javaSignature(type) }; throw Context.reportRuntimeError( Context.getMessage("msg.conversion.not.allowed", args)); | throw Context.reportRuntimeError2 ("msg.conversion.not.allowed", value.toString(), NativeJavaMethod.javaSignature(type)); | static void reportConversionError(Object value, Class type) { Object[] args = { value.toString(), NativeJavaMethod.javaSignature(type) }; throw Context.reportRuntimeError( Context.getMessage("msg.conversion.not.allowed", args)); } | 54155 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54155/e737c6d867e82d4ba7fd00e7e388c9c8da824ff0/NativeJavaObject.java/buggy/js/rhino/src/org/mozilla/javascript/NativeJavaObject.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
760,
918,
2605,
6814,
668,
12,
921,
460,
16,
1659,
618,
13,
288,
3639,
1033,
8526,
833,
273,
288,
460,
18,
10492,
9334,
12900,
16717,
5852,
1305,
18,
6290,
5374,
12,
723,
13,
13491,
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,
760,
918,
2605,
6814,
668,
12,
921,
460,
16,
1659,
618,
13,
288,
3639,
1033,
8526,
833,
273,
288,
460,
18,
10492,
9334,
12900,
16717,
5852,
1305,
18,
6290,
5374,
12,
723,
13,
13491,
289... |
ConflictsDialog conflictsDialog = new ConflictsDialog(myProject); | ConflictsDialog conflictsDialog = new ConflictsDialog(myProject, conflicts); | protected boolean preprocessUsages(Ref<UsageInfo[]> refUsages) { UsageInfo[] usagesIn = refUsages.get(); Set<String> conflicts = new HashSet<String>(); conflicts.addAll(RenameUtil.getConflictDescriptions(usagesIn)); addExistingNameConflicts(conflicts); if (conflicts.size() > 0) { ConflictsDialog conflictsDialog = new ConflictsDialog(myProject); conflictsDialog.show(); if (!conflictsDialog.isOK()) { return false; } } Set<UsageInfo> usagesSet = new HashSet<UsageInfo>(Arrays.asList(usagesIn)); RenameUtil.removeConflictUsages(usagesSet); final List<UsageInfo> variableUsages = new ArrayList<UsageInfo>(); if (!myRenamers.isEmpty()) { if (!findRenamedVariables(variableUsages)) return false; } if (!variableUsages.isEmpty()) { usagesSet.addAll(variableUsages); refUsages.set(usagesSet.toArray(new UsageInfo[usagesSet.size()])); } prepareSuccessful(); return true; } | 56627 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/56627/413999cb6b9d69b19798528a6066ceba40f68c3c/RenameProcessor.java/buggy/refactoring/impl/com/intellij/refactoring/rename/RenameProcessor.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
4750,
1250,
17942,
3477,
1023,
12,
1957,
32,
5357,
966,
8526,
34,
1278,
3477,
1023,
13,
288,
565,
10858,
966,
8526,
584,
1023,
382,
273,
1278,
3477,
1023,
18,
588,
5621,
565,
1000,
32,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1250,
17942,
3477,
1023,
12,
1957,
32,
5357,
966,
8526,
34,
1278,
3477,
1023,
13,
288,
565,
10858,
966,
8526,
584,
1023,
382,
273,
1278,
3477,
1023,
18,
588,
5621,
565,
1000,
32,
... |
assertEquals(stateConverter .convertModelToTarget(account.getState()), col_state); | assertEquals(getValue((String)stateConverter .convertModelToTarget(account.getState())), col_state); | public void testScenario03() throws BindingException { // Show that converters work for table columns Account[] accounts = catalog.getAccounts(); TableViewerDescription tableViewerDescription = new TableViewerDescription( tableViewer); tableViewerDescription.addColumn("lastName"); tableViewerDescription.addColumn("phone", null, new PhoneConverter()); tableViewerDescription.addColumn("state", null, new StateConverter()); getDbc().bind(tableViewerDescription, new PropertyDescription(catalog, "accounts"), null); // Verify that the data in the the table columns matches the expected // What we are looking for is that the phone numbers are converterted to // nnn-nnn-nnnn and that // the state letters are converted to state names // Verify the data in the table columns matches the accounts PhoneConverter phoneConverter = new PhoneConverter(); StateConverter stateConverter = new StateConverter(); for (int i = 0; i < accounts.length; i++) { Account account = (Account) catalog.getAccounts()[i]; // Check the phone number String col_phone = ((ITableLabelProvider) tableViewer .getLabelProvider()).getColumnText(account, 1); assertEquals(phoneConverter .convertModelToTarget(account.getPhone()), col_phone); String col_state = ((ITableLabelProvider) tableViewer .getLabelProvider()).getColumnText(account, 2); assertEquals(stateConverter .convertModelToTarget(account.getState()), col_state); } } | 58148 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/58148/d8caa98900b185f0cfc43233bd835d291fa0a501/TableScenarios.java/clean/tests/org.eclipse.jface.tests.databinding/src/org/eclipse/jface/tests/databinding/scenarios/TableScenarios.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
1842,
21390,
4630,
1435,
1216,
15689,
503,
288,
202,
202,
759,
9674,
716,
19414,
1440,
364,
1014,
2168,
202,
202,
3032,
8526,
9484,
273,
6222,
18,
588,
13971,
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,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
1842,
21390,
4630,
1435,
1216,
15689,
503,
288,
202,
202,
759,
9674,
716,
19414,
1440,
364,
1014,
2168,
202,
202,
3032,
8526,
9484,
273,
6222,
18,
588,
13971,
5621,
202,
20... |
" expected >true< or >false< bot got >True<.", e.getMessage()); | " expected >true< or >false<, but got >True<.", e.getMessage()); | public void testSetPropertiesInitially() { final Properties mp = model.getProperties(); final Properties defaultProps = getProperties(); model.setPropertiesInitially(defaultProps); // TODO: use an extra model for the model test, then the following code can be removed final String defaultSource = defaultProps.getSource(); final int defaultSourceSpace = defaultSource.indexOf(' '); final File file = new File(defaultSource.substring(0, defaultSourceSpace)); final java.util.Properties newProps = Properties.loadProperties(file); newProps.setProperty("database.forcename.StringItem", "STRINGITEMS"); newProps.setProperty("database.forcename.STRINGITEMS.this", "STRINGITEM_ID"); newProps.setProperty("database.forcename.STRINGITEMS.any", "ANY"); newProps.setProperty("database.forcename.STRINGITEMS.mandatory", "MANDATORY"); newProps.setProperty("database.forcename.STRINGITEMS.min4", "MIN_4"); newProps.setProperty("database.forcename.STRINGITEMS.max4", "MAX_4"); newProps.setProperty("database.forcename.STRINGITEMS.min4Max8", "MIN4_MAX8"); newProps.setProperty("database.forcename.STRINGITEMS.exact6", "EXACT_6"); newProps.setProperty("database.forcename.ItemWithSingleUnique", "UNIQUE_ITEMS"); newProps.setProperty("database.forcename.UNIQUE_ITEMS.this", "UNIQUE_ITEM_ID"); newProps.setProperty("database.forcename.UNIQUE_ITEMS.uniqueString", "UNIQUE_STRING"); newProps.setProperty("database.forcename.UNIQUE_ITEMS.otherString", "OTHER_STRING"); newProps.setProperty("database.forcename.ItemWithSingleUnique_uniqueString_Unq", "IX_ITEMWSU_US"); { final java.util.Properties props = (java.util.Properties)newProps.clone(); props.setProperty(Properties.DATABASE_URL, "zack"); final String source = file.getAbsolutePath()+'/'+Properties.DATABASE_URL+"=zack"; try { model.setPropertiesInitially(new Properties(props, source)); } catch(RuntimeException e) { assertEquals( "inconsistent initialization for " + Properties.DATABASE_URL + " between " + mp.getSource() + " and " + source + ", expected " + mp.getDatabaseUrl() + " but got zack.", e.getMessage()); } } { final java.util.Properties props = (java.util.Properties)newProps.clone(); props.setProperty(Properties.DATABASE_USER, "zick"); final String source = file.getAbsolutePath()+'/'+Properties.DATABASE_USER+"=zick"; try { model.setPropertiesInitially(new Properties(props, source)); } catch(RuntimeException e) { assertEquals( "inconsistent initialization for " + Properties.DATABASE_USER + " between " + mp.getSource() + " and " + source + ", expected "+mp.getDatabaseUser()+" but got zick.", e.getMessage()); } } { final java.util.Properties props = (java.util.Properties)newProps.clone(); props.setProperty(Properties.DATABASE_PASSWORD, "zock"); final String source = file.getAbsolutePath()+'/'+Properties.DATABASE_PASSWORD+"=zock"; try { model.setPropertiesInitially(new Properties(props, source)); } catch(RuntimeException e) { assertEquals( "inconsistent initialization for " + Properties.DATABASE_PASSWORD + " between " + mp.getSource() + " and " + source + ".", e.getMessage()); } } { final java.util.Properties props = (java.util.Properties)newProps.clone(); final String newValue = mp.getDatabaseDontSupportEmptyStrings()?"false":"true"; props.setProperty(Properties.DATABASE_DONT_SUPPORT_EMPTY_STRINGS, newValue); final String source = file.getAbsolutePath()+'/'+Properties.DATABASE_PASSWORD+"=zock"; try { model.setPropertiesInitially(new Properties(props, source)); } catch(RuntimeException e) { assertEquals( "inconsistent initialization for " + Properties.DATABASE_DONT_SUPPORT_EMPTY_STRINGS + " between " + mp.getSource() + " and " + source + ", expected " + mp.getDatabaseDontSupportEmptyStrings() + " but got " + newValue + ".", e.getMessage()); } props.setProperty(Properties.DATABASE_DONT_SUPPORT_EMPTY_STRINGS, "True"); try { new Properties(props, "sourceTrue"); } catch(RuntimeException e) { assertEquals( "property " + Properties.DATABASE_DONT_SUPPORT_EMPTY_STRINGS + " in sourceTrue has invalid value," + " expected >true< or >false< bot got >True<.", e.getMessage()); } props.setProperty(Properties.DATABASE_DONT_SUPPORT_EMPTY_STRINGS, "falsE"); try { new Properties(props, "sourcefalsE"); } catch(RuntimeException e) { assertEquals( "property " + Properties.DATABASE_DONT_SUPPORT_EMPTY_STRINGS + " in sourcefalsE has invalid value," + " expected >true< or >false< bot got >falsE<.", e.getMessage()); } } { // TODO: reuse code for boolean properties final java.util.Properties props = (java.util.Properties)newProps.clone(); final String newValue = mp.getPkSourceButterfly()?"false":"true"; props.setProperty(Properties.PKSOURCE_BUTTERFLY, newValue); final String source = file.getAbsolutePath()+'/'+Properties.DATABASE_PASSWORD+"=zock"; try { model.setPropertiesInitially(new Properties(props, source)); } catch(RuntimeException e) { assertEquals( "inconsistent initialization for " + Properties.PKSOURCE_BUTTERFLY + " between " + mp.getSource() + " and " + source + ", expected " + mp.getPkSourceButterfly() + " but got " + newValue + ".", e.getMessage()); } props.setProperty(Properties.PKSOURCE_BUTTERFLY, "True"); try { new Properties(props, "sourceTrue"); } catch(RuntimeException e) { assertEquals( "property " + Properties.PKSOURCE_BUTTERFLY + " in sourceTrue has invalid value," + " expected >true< or >false< bot got >True<.", e.getMessage()); } props.setProperty(Properties.PKSOURCE_BUTTERFLY, "falsE"); try { new Properties(props, "sourcefalsE"); } catch(RuntimeException e) { assertEquals( "property " + Properties.PKSOURCE_BUTTERFLY + " in sourcefalsE has invalid value," + " expected >true< or >false< bot got >falsE<.", e.getMessage()); } } { final java.util.Properties props = (java.util.Properties)newProps.clone(); final String newValue = "88"; props.setProperty(Properties.CONNECTION_POOL_MAX_IDLE, newValue); final String source = file.getAbsolutePath()+'/'+Properties.CONNECTION_POOL_MAX_IDLE+"=88"; try { model.setPropertiesInitially(new Properties(props, source)); } catch(RuntimeException e) { assertEquals( "inconsistent initialization for " + Properties.CONNECTION_POOL_MAX_IDLE + " between " + mp.getSource() + " and " + source + ", expected " + mp.getConnectionPoolMaxIdle() + " but got " + newValue + ".", e.getMessage()); } props.setProperty(Properties.CONNECTION_POOL_MAX_IDLE, "-1"); try { new Properties(props, "minusOne"); } catch(RuntimeException e) { assertEquals( "property " + Properties.CONNECTION_POOL_MAX_IDLE + " in minusOne has invalid value," + " expected an integer greater 5, but got -1.", e.getMessage()); } props.setProperty(Properties.CONNECTION_POOL_MAX_IDLE, "88x"); try { new Properties(props, "wrongInt"); } catch(RuntimeException e) { assertEquals( "property " + Properties.CONNECTION_POOL_MAX_IDLE + " in wrongInt has invalid value," + " expected an integer greater 5, but got >88x<.", e.getMessage()); } } { final char SEP = File.separatorChar; final java.util.Properties props = (java.util.Properties)newProps.clone(); props.setProperty(Properties.DATADIR_PATH, props.getProperty(Properties.DATADIR_PATH)+SEP+"AttributeItem"); final String source = file.getAbsolutePath()+'/'+Properties.DATADIR_PATH+"=/AttributeItem"; try { model.setPropertiesInitially(new Properties(props, source)); } catch(RuntimeException e) { assertEquals( "inconsistent initialization for " + Properties.DATADIR_PATH + " between " + mp.getSource() + " and " + source + ", expected " + mp.getDatadirPath() + " but got " + mp.getDatadirPath() + SEP + "AttributeItem.", e.getMessage()); } } { final java.util.Properties props = (java.util.Properties)newProps.clone(); props.setProperty(Properties.MEDIA_ROOT_URL, "zosch"); final String source = file.getAbsolutePath()+'/'+Properties.MEDIA_ROOT_URL+"=zosch"; try { model.setPropertiesInitially(new Properties(props, source)); } catch(RuntimeException e) { assertEquals( "inconsistent initialization for " + Properties.MEDIA_ROOT_URL + " between " + mp.getSource() + " and " + source + ", expected " + mp.getMediaRootUrl() + " but got zosch.", e.getMessage()); } props.remove(Properties.MEDIA_ROOT_URL); assertEquals(Properties.MEDIA_ROOT_URL_DEFAULT, new Properties(props, "source").getMediaRootUrl()); props.setProperty(Properties.MEDIA_ROOT_URL, "klack"); assertEquals("klack", new Properties(props, "source").getMediaRootUrl()); } } | 50290 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50290/016d7e43e1f4e975705c8255959c38fd26e35f9e/ModelTest.java/buggy/lib/testsrc/com/exedio/cope/ModelTest.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
1842,
694,
2297,
2570,
6261,
1435,
202,
95,
202,
202,
6385,
6183,
6749,
273,
938,
18,
588,
2297,
5621,
202,
202,
6385,
6183,
805,
5047,
273,
9392,
5621,
202,
202,
2284,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
694,
2297,
2570,
6261,
1435,
202,
95,
202,
202,
6385,
6183,
6749,
273,
938,
18,
588,
2297,
5621,
202,
202,
6385,
6183,
805,
5047,
273,
9392,
5621,
202,
202,
2284,
1... |
oldParent = context.setRubyClass(getClasses().getObjectClass()); | oldParent = context.setRubyClass(objectClass); | public void loadNode(String scriptName, Node node, boolean wrap) { IRubyObject self = getTopSelf(); ThreadContext context = getCurrentContext(); context.pushDynamicVars(); RubyModule wrapper = context.getWrapper(); RubyModule oldParent; if (!wrap) { secure(4); /* should alter global state */ oldParent = context.setRubyClass(getClasses().getObjectClass()); context.setWrapper(null); } else { /* load in anonymous module as toplevel */ context.setWrapper(RubyModule.newModule(this, null)); oldParent = context.setRubyClass(context.getWrapper()); self = getTopSelf().rbClone(); self.extendObject(context.getRubyClass()); } context.getFrameStack().push(new Frame(context, self, IRubyObject.NULL_ARRAY, null, null)); context.getScopeStack().push(new Scope(this)); /* default visibility is private at loading toplevel */ setCurrentVisibility(Visibility.PRIVATE); try { self.eval(node); } catch (ReturnJump e) { // Make sure this does not bubble out to java caller. } finally { context.getScopeStack().pop(); context.getFrameStack().pop(); context.setRubyClass(oldParent); context.popDynamicVars(); context.setWrapper(wrapper); } } | 49476 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/49476/ca6b16e996ea9af83ce593594b9c69b9364a9924/Ruby.java/buggy/src/org/jruby/Ruby.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1262,
907,
12,
780,
31008,
16,
2029,
756,
16,
1250,
2193,
13,
288,
3639,
15908,
10340,
921,
365,
273,
13729,
10084,
5621,
3639,
4884,
1042,
819,
273,
5175,
1042,
5621,
3639,
81... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1262,
907,
12,
780,
31008,
16,
2029,
756,
16,
1250,
2193,
13,
288,
3639,
15908,
10340,
921,
365,
273,
13729,
10084,
5621,
3639,
4884,
1042,
819,
273,
5175,
1042,
5621,
3639,
81... |
!(e instanceof Mech || e instanceof Protomech)) { | !(e instanceof Mech || e instanceof Protomech || e instanceof MechWarrior)) { | private void resolveCrewWakeUp() { boolean anyRolls = false; for (Enumeration i = game.getEntities(); i.hasMoreElements();) { final Entity e = (Entity)i.nextElement(); // only unconscious pilots of mechs and proto's can roll to wake up if ( !e.isTargetable() || !e.crew.isUnconscious() || e.crew.isKoThisRound() || !(e instanceof Mech || e instanceof Protomech)) { continue; } anyRolls = true; int roll = Compute.d6(2); if ( e.getCrew().getOptions().booleanOption("pain_resistance") ) roll = Math.min(12, roll + 1); int rollTarget = Compute.getConsciousnessNumber( e.crew.getHits() ); roundReport.append("\nPilot of " ).append( e.getDisplayName() ).append( " \"" ).append( e.crew.getName() ).append( "\" needs a " ).append( rollTarget ).append( " to regain consciousness. Rolls " ).append( roll ).append( " : "); if (roll >= rollTarget) { roundReport.append("successful!"); e.crew.setUnconscious(false); } else { roundReport.append("fails."); } } if (anyRolls) { roundReport.append("\n"); } } | 3464 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/3464/4563696f268cd5cf44095a547aff0a1333c67d51/Server.java/clean/megamek/src/megamek/server/Server.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
918,
2245,
1996,
91,
59,
911,
1211,
1435,
288,
3639,
1250,
1281,
4984,
3251,
273,
629,
31,
3639,
364,
261,
21847,
277,
273,
7920,
18,
588,
8108,
5621,
277,
18,
5332,
7417,
3471,
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,
377,
3238,
918,
2245,
1996,
91,
59,
911,
1211,
1435,
288,
3639,
1250,
1281,
4984,
3251,
273,
629,
31,
3639,
364,
261,
21847,
277,
273,
7920,
18,
588,
8108,
5621,
277,
18,
5332,
7417,
3471,
5... |
int _cnt1345=0; _loop1345: | int _cnt1349=0; _loop1349: | public final void formatphrase(AST _t) throws RecognitionException { AST formatphrase_AST_in = (_t == ASTNULL) ? null : (AST)_t; AST __t1331 = _t; AST tmp2030_AST_in = (AST)_t; match(_t,Format_phrase); _t = _t.getFirstChild(); { int _cnt1345=0; _loop1345: do { if (_t==null) _t=ASTNULL; switch ( _t.getType()) { case AS: { AST __t1333 = _t; AST tmp2031_AST_in = (AST)_t; match(_t,AS); _t = _t.getFirstChild(); datatype_var(_t); _t = _retTree; _t = __t1333; _t = _t.getNextSibling(); break; } case AT: { atphrase(_t); _t = _retTree; break; } case ATTRSPACE: { AST tmp2032_AST_in = (AST)_t; match(_t,ATTRSPACE); _t = _t.getNextSibling(); break; } case NOATTRSPACE: { AST tmp2033_AST_in = (AST)_t; match(_t,NOATTRSPACE); _t = _t.getNextSibling(); break; } case AUTORETURN: { AST tmp2034_AST_in = (AST)_t; match(_t,AUTORETURN); _t = _t.getNextSibling(); break; } case BGCOLOR: case DCOLOR: case FGCOLOR: case PFCOLOR: { color_expr(_t); _t = _retTree; break; } case CONTEXTHELPID: { AST __t1334 = _t; AST tmp2035_AST_in = (AST)_t; match(_t,CONTEXTHELPID); _t = _t.getFirstChild(); expression(_t); _t = _retTree; _t = __t1334; _t = _t.getNextSibling(); break; } case BLANK: { AST tmp2036_AST_in = (AST)_t; match(_t,BLANK); _t = _t.getNextSibling(); break; } case COLON: { AST __t1335 = _t; AST tmp2037_AST_in = (AST)_t; match(_t,COLON); _t = _t.getFirstChild(); expression(_t); _t = _retTree; _t = __t1335; _t = _t.getNextSibling(); break; } case TO: { AST __t1336 = _t; AST tmp2038_AST_in = (AST)_t; match(_t,TO); _t = _t.getFirstChild(); expression(_t); _t = _retTree; _t = __t1336; _t = _t.getNextSibling(); break; } case DEBLANK: { AST tmp2039_AST_in = (AST)_t; match(_t,DEBLANK); _t = _t.getNextSibling(); break; } case DISABLEAUTOZAP: { AST tmp2040_AST_in = (AST)_t; match(_t,DISABLEAUTOZAP); _t = _t.getNextSibling(); break; } case FONT: { AST __t1337 = _t; AST tmp2041_AST_in = (AST)_t; match(_t,FONT); _t = _t.getFirstChild(); expression(_t); _t = _retTree; _t = __t1337; _t = _t.getNextSibling(); break; } case FORMAT: { AST __t1338 = _t; AST tmp2042_AST_in = (AST)_t; match(_t,FORMAT); _t = _t.getFirstChild(); expression(_t); _t = _retTree; _t = __t1338; _t = _t.getNextSibling(); break; } case HELP: { AST __t1339 = _t; AST tmp2043_AST_in = (AST)_t; match(_t,HELP); _t = _t.getFirstChild(); constant(_t); _t = _retTree; _t = __t1339; _t = _t.getNextSibling(); break; } case COLUMNLABEL: case LABEL: { label_constant(_t); _t = _retTree; break; } case LEXAT: { AST __t1340 = _t; AST tmp2044_AST_in = (AST)_t; match(_t,LEXAT); _t = _t.getFirstChild(); field(_t); _t = _retTree; { if (_t==null) _t=ASTNULL; switch ( _t.getType()) { case Format_phrase: { formatphrase(_t); _t = _retTree; break; } case 3: { break; } default: { throw new NoViableAltException(_t); } } } _t = __t1340; _t = _t.getNextSibling(); break; } case LIKE: { AST __t1342 = _t; AST tmp2045_AST_in = (AST)_t; match(_t,LIKE); _t = _t.getFirstChild(); field(_t); _t = _retTree; _t = __t1342; _t = _t.getNextSibling(); break; } case NOLABELS: { AST tmp2046_AST_in = (AST)_t; match(_t,NOLABELS); _t = _t.getNextSibling(); break; } case NOTABSTOP: { AST tmp2047_AST_in = (AST)_t; match(_t,NOTABSTOP); _t = _t.getNextSibling(); break; } case VALIDATE: { AST __t1343 = _t; AST tmp2048_AST_in = (AST)_t; match(_t,VALIDATE); _t = _t.getFirstChild(); funargs(_t); _t = _retTree; _t = __t1343; _t = _t.getNextSibling(); break; } case WHEN: { AST __t1344 = _t; AST tmp2049_AST_in = (AST)_t; match(_t,WHEN); _t = _t.getFirstChild(); expression(_t); _t = _retTree; _t = __t1344; _t = _t.getNextSibling(); break; } case VIEWAS: { viewasphrase(_t); _t = _retTree; break; } case WIDGETID: { widget_id(_t); _t = _retTree; break; } default: { if ( _cnt1345>=1 ) { break _loop1345; } else {throw new NoViableAltException(_t);} } } _cnt1345++; } while (true); } _t = __t1331; _t = _t.getNextSibling(); _retTree = _t; } | 13952 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/13952/daa15e07422d3491bbbb4d0060450c81983332a4/JPTreeParser.java/clean/trunk/org.prorefactor.core/src/org/prorefactor/treeparserbase/JPTreeParser.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
727,
918,
740,
9429,
12,
9053,
389,
88,
13,
1216,
9539,
288,
9506,
202,
9053,
740,
9429,
67,
9053,
67,
267,
273,
261,
67,
88,
422,
9183,
8560,
13,
692,
446,
294,
261,
9053,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
727,
918,
740,
9429,
12,
9053,
389,
88,
13,
1216,
9539,
288,
9506,
202,
9053,
740,
9429,
67,
9053,
67,
267,
273,
261,
67,
88,
422,
9183,
8560,
13,
692,
446,
294,
261,
9053,
... |
long committedRevision = updater.doCopy(srcURL, srcPegRevision, srcRevision, dstURL, dstPegRevision, true, commitMessage); if (committedRevision >= 0) { | SVNCommitInfo result = updater.doCopy(srcURL, srcPegRevision, srcRevision, dstURL, dstPegRevision, true, commitMessage); if (result != SVNCommitInfo.NULL) { | private void runRemote(PrintStream out, PrintStream err) throws SVNException { if (getCommandLine().getURLCount() != 2) { throw new SVNException("Please enter SRC and DST URL"); } String srcURL = getCommandLine().getURL(0); SVNRevision srcRevision = SVNRevision.parse((String) getCommandLine().getArgumentValue(SVNArgument.REVISION)); SVNRevision srcPegRevision = getCommandLine().getPegRevision(0); String dstURL = getCommandLine().getURL(1); SVNRevision dstPegRevision = getCommandLine().getPegRevision(1); if (matchTabsInPath(srcURL, err) || matchTabsInPath(dstURL, err)) { return; } String commitMessage = (String) getCommandLine().getArgumentValue(SVNArgument.MESSAGE); SVNCopyClient updater = new SVNCopyClient(getCredentialsProvider(), new SVNCommandEventProcessor(out, err, false)); long committedRevision = updater.doCopy(srcURL, srcPegRevision, srcRevision, dstURL, dstPegRevision, true, commitMessage); if (committedRevision >= 0) { out.println(); out.println("Committed revision " + committedRevision + "."); } } | 2776 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/2776/a4432e89c637c38420797cd6885caa05317a34c3/MoveCommand.java/buggy/javasvn/src/org/tmatesoft/svn/cli/command/MoveCommand.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
918,
1086,
5169,
12,
5108,
1228,
596,
16,
21677,
393,
13,
1216,
29537,
50,
503,
288,
3639,
309,
261,
588,
21391,
7675,
588,
1785,
1380,
1435,
480,
576,
13,
288,
5411,
604,
39... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1086,
5169,
12,
5108,
1228,
596,
16,
21677,
393,
13,
1216,
29537,
50,
503,
288,
3639,
309,
261,
588,
21391,
7675,
588,
1785,
1380,
1435,
480,
576,
13,
288,
5411,
604,
39... |
retEnv = SunRound2Client.sendMsg(util, url, soapAction); | retEnv = client.sendMsg(util, url, soapAction); | public void testR2BaseEchoFloatArray() throws AxisFault { url = "http://www.mssoapinterop.org/asmx/simple.asmx"; soapAction = "http://soapinterop.org/"; util = new Round2EchoFloatArrayClientUtil(); retEnv = SunRound2Client.sendMsg(util, url, soapAction); tempPath = resFilePath + "MSaxmsBaseFloatArrayRes.xml"; compareXML(retEnv, tempPath); } | 49300 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/49300/95f09abc768fee06d65b12836e31273ac0e15eb3/MSaxmsRound2InteropTest.java/clean/modules/integration/itest/test/interop/whitemesa/round2/MSaxmsRound2InteropTest.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1842,
54,
22,
2171,
19704,
4723,
1076,
1435,
1216,
15509,
7083,
288,
3639,
880,
273,
315,
2505,
2207,
5591,
18,
959,
19215,
30376,
18,
3341,
19,
345,
11023,
19,
9647,
18,
345,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
54,
22,
2171,
19704,
4723,
1076,
1435,
1216,
15509,
7083,
288,
3639,
880,
273,
315,
2505,
2207,
5591,
18,
959,
19215,
30376,
18,
3341,
19,
345,
11023,
19,
9647,
18,
345,
... |
public CmsUUID getLockstate() { | public CmsUUID getLockstate() { /* CmsUUID lockedByUserId = CmsUUID.getNullUUID(); | public CmsUUID getLockstate() { // CmsUUID lockedByUserId = CmsUUID.getNullUUID();// // try {// if(hasWriteAccess(m_cms)) {// lockedByUserId = m_dataSet.m_lockedBy;// }// } catch(CmsException exc) {// // NOOP// }// // return lockedByUserId; return m_dataSet.m_lockedBy; } | 51784 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/51784/fbba0b665bf88afa5ebd66f4a109c855846a0895/CmsMasterContent.java/clean/src/com/opencms/defaults/master/CmsMasterContent.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
15792,
22206,
2019,
1435,
288,
3639,
368,
3639,
15792,
8586,
858,
10502,
273,
15792,
18,
588,
2041,
5562,
5621,
759,
3639,
368,
3639,
775,
288,
759,
5411,
309,
12,
5332,
3067,
1862,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
15792,
22206,
2019,
1435,
288,
3639,
368,
3639,
15792,
8586,
858,
10502,
273,
15792,
18,
588,
2041,
5562,
5621,
759,
3639,
368,
3639,
775,
288,
759,
5411,
309,
12,
5332,
3067,
1862,
... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.