rem
stringlengths
1
226k
add
stringlengths
0
227k
context
stringlengths
6
326k
meta
stringlengths
143
403
input_ids
listlengths
256
256
attention_mask
listlengths
256
256
labels
listlengths
128
128
annotation = ProxyFactory.newAnnotationProxy( (AnnotationElement.Annotation)m_classAnnotationElements.get(annotationName), ((Class)m_classRef.get()).getClassLoader() ); m_classAnnotationCache.put(annotationName, annotation); return annotation;
final AnnotationElement.Annotation annotationInfo = (AnnotationElement.Annotation)m_classAnnotationElements.get(annotationName); if (annotationInfo != null) { annotation = ProxyFactory.newAnnotationProxy( annotationInfo, ((Class)m_classRef.get()).getClassLoader() ); m_classAnnotationCache.put(annotationName, annotation); return annotation; } else { return null; }
public Annotation getAnnotation(final String annotationName) { Object cachedAnnotation = m_classAnnotationCache.get(annotationName); if (cachedAnnotation != null) { return (Annotation)cachedAnnotation; } else { final Annotation annotation; annotation = ProxyFactory.newAnnotationProxy( (AnnotationElement.Annotation)m_classAnnotationElements.get(annotationName), ((Class)m_classRef.get()).getClassLoader() ); m_classAnnotationCache.put(annotationName, annotation); return annotation; } }
7955 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/7955/820e83fd1b30026a51b96d7771f8db4a77c3bbdd/AnnotationReader.java/clean/backport175/src/main/org/codehaus/backport175/reader/bytecode/AnnotationReader.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 6090, 9887, 12, 6385, 514, 3204, 461, 13, 288, 3639, 1033, 3472, 3257, 273, 312, 67, 1106, 3257, 1649, 18, 588, 12, 11495, 461, 1769, 3639, 309, 261, 7097, 3257, 480, 446, 13, 288...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 6090, 9887, 12, 6385, 514, 3204, 461, 13, 288, 3639, 1033, 3472, 3257, 273, 312, 67, 1106, 3257, 1649, 18, 588, 12, 11495, 461, 1769, 3639, 309, 261, 7097, 3257, 480, 446, 13, 288...
out.writeInt(origttl);
out.writeUnsignedInt(origttl);
rrToWire(DataByteOutputStream out, Compression c, boolean canonical) { if (signature == null) return; out.writeShort((short)covered); out.writeByte(alg); out.writeByte(labels); out.writeInt(origttl); out.writeInt((int)(expire.getTime() / 1000)); out.writeInt((int)(timeSigned.getTime() / 1000)); out.writeShort(footprint); signer.toWire(out, null, canonical); out.writeArray(signature);}
4227 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/4227/81370f62d73bebd8d1008ff1fe16b14a1b81732c/SIGRecord.java/clean/org/xbill/DNS/SIGRecord.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 8354, 774, 15249, 12, 751, 3216, 4632, 596, 16, 21139, 276, 16, 1250, 7378, 13, 288, 202, 430, 261, 8195, 422, 446, 13, 202, 202, 2463, 31, 202, 659, 18, 2626, 4897, 12443, 6620, 13, 16810, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 8354, 774, 15249, 12, 751, 3216, 4632, 596, 16, 21139, 276, 16, 1250, 7378, 13, 288, 202, 430, 261, 8195, 422, 446, 13, 202, 202, 2463, 31, 202, 659, 18, 2626, 4897, 12443, 6620, 13, 16810, ...
addText(project, task, buf, start, count);
ProjectHelper.addText(context.project, task, buf, start, count);
public void characters(char[] buf, int start, int count) throws SAXParseException { if (wrapper == null) { try { addText(project, task, buf, start, count); } catch (BuildException exc) { throw new SAXParseException(exc.getMessage(), locator, exc); } } else { wrapper.addText(buf, start, count); } }
17033 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/17033/5643f375e3d76a2422969536e06c3b3cf39721b8/ProjectHelperImpl2.java/clean/proposal/sandbox/embed/ProjectHelperImpl2.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 540, 1071, 918, 3949, 12, 3001, 8526, 1681, 16, 509, 787, 16, 509, 1056, 13, 1216, 10168, 13047, 288, 5411, 309, 261, 8376, 422, 446, 13, 288, 7734, 775, 288, 10792, 5420, 2276, 18, 1289, 15...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 3949, 12, 3001, 8526, 1681, 16, 509, 787, 16, 509, 1056, 13, 1216, 10168, 13047, 288, 5411, 309, 261, 8376, 422, 446, 13, 288, 7734, 775, 288, 10792, 5420, 2276, 18, 1289, 15...
public boolean booleanValueOf(Object node) throws JaxenException { Context context = getContext( node ); List result = selectNodesForContext( context ); if ( result == null ) return false; return BooleanFunction.evaluate( result, context.getNavigator() ).booleanValue(); }
47970 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/47970/733d09a9a4186bb783fb621a5d101839f5e09620/BaseXPath.java/clean/src/java/main/org/jaxen/BaseXPath.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1071, 6494, 6494, 620, 951, 12, 921, 2159, 13, 15069, 46, 651, 275, 503, 95, 1042, 2472, 33, 29120, 12, 2159, 1769, 682, 2088, 33, 4025, 3205, 1290, 1042, 12, 2472, 1769, 430, 12, 2088, 631,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 6494, 6494, 620, 951, 12, 921, 2159, 13, 15069, 46, 651, 275, 503, 95, 1042, 2472, 33, 29120, 12, 2159, 1769, 682, 2088, 33, 4025, 3205, 1290, 1042, 12, 2472, 1769, 430, 12, 2088, 631,...
formatClass = forName ("java.lang.Number");
formatClass = java.lang.Number.class;
void setLocale (Locale loc) { if (type == null) ; else if (type.equals("number")) { // FIXME: named class literal. // formatClass = Number.class; formatClass = forName ("java.lang.Number"); if (style == null) format = NumberFormat.getInstance(loc); else if (style.equals("currency")) format = NumberFormat.getCurrencyInstance(loc); else if (style.equals("percent")) format = NumberFormat.getPercentInstance(loc); else if (style.equals("integer")) { NumberFormat nf = NumberFormat.getNumberInstance(loc); nf.setMaximumFractionDigits(0); nf.setGroupingUsed(false); format = nf; } else { format = NumberFormat.getNumberInstance(loc); DecimalFormat df = (DecimalFormat) format; try { df.applyPattern(style); } catch (ParseException x) { throw new IllegalArgumentException (x.getMessage()); } } } else if (type.equals("time") || type.equals("date")) { // FIXME: named class literal. // formatClass = Date.class; formatClass = forName ("java.util.Date"); int val = DateFormat.DEFAULT; if (style == null) ; if (style.equals("short")) val = DateFormat.SHORT; else if (style.equals("medium")) val = DateFormat.MEDIUM; else if (style.equals("long")) val = DateFormat.LONG; else if (style.equals("full")) val = DateFormat.FULL; if (type.equals("time")) format = DateFormat.getTimeInstance(val, loc); else format = DateFormat.getDateInstance(val, loc); if (style != null && val == DateFormat.DEFAULT) { SimpleDateFormat sdf = (SimpleDateFormat) format; sdf.applyPattern(style); } } else if (type.equals("choice")) { // FIXME: named class literal. // formatClass = Number.class; formatClass = forName ("java.lang.Number"); if (style == null) throw new IllegalArgumentException ("style required for choice format"); format = new ChoiceFormat (style); } }
5916 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5916/810295ed9bb77d96e4fc59479d7e7e4d390a6212/MessageFormat.java/clean/libjava/java/text/MessageFormat.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 282, 918, 19848, 261, 3916, 1515, 13, 565, 288, 1377, 309, 261, 723, 422, 446, 13, 202, 31, 1377, 469, 309, 261, 723, 18, 14963, 2932, 2696, 6, 3719, 202, 95, 202, 225, 368, 9852, 30, 4141...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 918, 19848, 261, 3916, 1515, 13, 565, 288, 1377, 309, 261, 723, 422, 446, 13, 202, 31, 1377, 469, 309, 261, 723, 18, 14963, 2932, 2696, 6, 3719, 202, 95, 202, 225, 368, 9852, 30, 4141...
if (selectedRun == 1 || selectedRun == -1)
if (runCount == 1 || selectedRun == 1 || selectedRun == -1)
protected void rotateTabRuns(int tabPlacement, int selectedRun) { if (selectedRun == 1 || selectedRun == -1) return; int[] newTabRuns = new int[tabRuns.length]; int currentRun = selectedRun; int i = 1; do { newTabRuns[i] = tabRuns[currentRun]; currentRun = getNextTabRun(currentRun); i++; } while (i < runCount); if (runCount > 1) newTabRuns[0] = tabRuns[currentRun]; tabRuns = newTabRuns; BasicTabbedPaneUI.this.selectedRun = 1; }
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/50dc6879c9be89f646fdff68c58f785e3dc0b90e/BasicTabbedPaneUI.java/clean/core/src/classpath/javax/javax/swing/plaf/basic/BasicTabbedPaneUI.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 4750, 918, 8534, 5661, 9361, 12, 474, 3246, 12420, 16, 509, 3170, 1997, 13, 565, 288, 1377, 309, 261, 8109, 1997, 422, 404, 747, 3170, 1997, 422, 300, 21, 13, 202, 2463, 31, 1377, 509, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 8534, 5661, 9361, 12, 474, 3246, 12420, 16, 509, 3170, 1997, 13, 565, 288, 1377, 309, 261, 8109, 1997, 422, 404, 747, 3170, 1997, 422, 300, 21, 13, 202, 2463, 31, 1377, 509, ...
{ for (int i = 0; i < array.length; i++) if (array[i] == o) return i; return -1; }
{ for (int i = 0; i < array.length; i++) if (array[i] == o) return i; return -1; }
private static int arrayFind(Object[] array, Object o) { for (int i = 0; i < array.length; i++) if (array[i] == o) return i; return -1; }
4891 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/4891/b5b5168edc3af09cb74945a80b0c36e6630ed502/Walker.java/buggy/src/main/mondrian/olap/Walker.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 1152, 760, 509, 526, 3125, 12, 921, 8526, 526, 16, 1033, 320, 13, 202, 95, 202, 202, 1884, 261, 474, 277, 273, 374, 31, 277, 411, 526, 18, 2469, 31, 277, 27245, 1082, 202, 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, 225, 202, 1152, 760, 509, 526, 3125, 12, 921, 8526, 526, 16, 1033, 320, 13, 202, 95, 202, 202, 1884, 261, 474, 277, 273, 374, 31, 277, 411, 526, 18, 2469, 31, 277, 27245, 1082, 202, 430, ...
logger = new org.openscience.cdk.tools.LoggingTool(this.getClass().getName());
logger = new org.openscience.cdk.tools.LoggingTool(this.getClass().getName(), true); StructureDiagramGenerator sdg = new StructureDiagramGenerator();
public void setUp() { logger = new org.openscience.cdk.tools.LoggingTool(this.getClass().getName()); }
45254 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/45254/ea919dc709f9657326e0d73ccf1c8c78f7ed2016/OverlapResolverTest.java/buggy/src/org/openscience/cdk/test/layout/OverlapResolverTest.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 918, 24292, 1435, 202, 95, 202, 202, 4901, 273, 394, 2358, 18, 20346, 71, 6254, 18, 71, 2883, 18, 6642, 18, 7735, 6364, 12, 2211, 18, 588, 797, 7675, 17994, 10663, 202, 97, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 918, 24292, 1435, 202, 95, 202, 202, 4901, 273, 394, 2358, 18, 20346, 71, 6254, 18, 71, 2883, 18, 6642, 18, 7735, 6364, 12, 2211, 18, 588, 797, 7675, 17994, 10663, 202, 97, ...
if (srcLoc.getLocatorIndices().length != destLoc.getLocatorIndices().length) throw new IllegalArgumentException("Src and Dest locator indices differ in length!!"); for (int i = 0; i < srcLoc.getAttributeIndices().length; i++) { int instIndex = instSrcCompat ? srcLoc.getActualIndex(srcLoc.getAttributeIndices()[i]) : destLoc.getActualIndex(destLoc.getAttributeIndices()[i]); Attribute src = srcDataset.attribute(srcLoc.getActualIndex(srcLoc.getAttributeIndices()[i])); Attribute dest = destDataset.attribute(destLoc.getActualIndex(destLoc.getAttributeIndices()[i])); if (!instance.isMissing(instIndex)) { int valIndex = dest.addStringValue(src, (int)instance.value(instIndex)); instance.setValue(instIndex, (double)valIndex); } } int[] srcIndices = srcLoc.getLocatorIndices(); int[] destIndices = destLoc.getLocatorIndices(); for (int i = 0; i < srcIndices.length; i++) { Instances rel = instSrcCompat ? instance.relationalValue(srcLoc.getActualIndex(srcIndices[i])) : instance.relationalValue(destLoc.getActualIndex(destIndices[i])); AttributeLocator srcStrAttsNew = srcLoc.getLocator(srcIndices[i]); Instances srcDatasetNew = srcStrAttsNew.getData(); AttributeLocator destStrAttsNew = destLoc.getLocator(destIndices[i]); Instances destDatasetNew = destStrAttsNew.getData(); for (int n = 0; n < rel.numInstances(); n++) { copyStringValues(rel.instance(n), instSrcCompat, srcDatasetNew, srcStrAttsNew, destDatasetNew, destStrAttsNew); } }
if (inst.dataset() == null) { throw new IllegalArgumentException("Instance has no dataset assigned!!"); } else if (inst.dataset().numAttributes() != destDataset.numAttributes()) { throw new IllegalArgumentException("Src and Dest differ in # of attributes!!"); } copyStringValues(inst, true, inst.dataset(), strAtts, destDataset, strAtts);
public static void copyStringValues(Instance instance, boolean instSrcCompat, Instances srcDataset, AttributeLocator srcLoc, Instances destDataset, AttributeLocator destLoc) { if (srcDataset == destDataset) return; if (srcLoc.getAttributeIndices().length != destLoc.getAttributeIndices().length) throw new IllegalArgumentException("Src and Dest string indices differ in length!!"); if (srcLoc.getLocatorIndices().length != destLoc.getLocatorIndices().length) throw new IllegalArgumentException("Src and Dest locator indices differ in length!!"); for (int i = 0; i < srcLoc.getAttributeIndices().length; i++) { int instIndex = instSrcCompat ? srcLoc.getActualIndex(srcLoc.getAttributeIndices()[i]) : destLoc.getActualIndex(destLoc.getAttributeIndices()[i]); Attribute src = srcDataset.attribute(srcLoc.getActualIndex(srcLoc.getAttributeIndices()[i])); Attribute dest = destDataset.attribute(destLoc.getActualIndex(destLoc.getAttributeIndices()[i])); if (!instance.isMissing(instIndex)) { int valIndex = dest.addStringValue(src, (int)instance.value(instIndex)); instance.setValue(instIndex, (double)valIndex); } } // recurse if necessary int[] srcIndices = srcLoc.getLocatorIndices(); int[] destIndices = destLoc.getLocatorIndices(); for (int i = 0; i < srcIndices.length; i++) { Instances rel = instSrcCompat ? instance.relationalValue(srcLoc.getActualIndex(srcIndices[i])) : instance.relationalValue(destLoc.getActualIndex(destIndices[i])); AttributeLocator srcStrAttsNew = srcLoc.getLocator(srcIndices[i]); Instances srcDatasetNew = srcStrAttsNew.getData(); AttributeLocator destStrAttsNew = destLoc.getLocator(destIndices[i]); Instances destDatasetNew = destStrAttsNew.getData(); for (int n = 0; n < rel.numInstances(); n++) { copyStringValues(rel.instance(n), instSrcCompat, srcDatasetNew, srcStrAttsNew, destDatasetNew, destStrAttsNew); } } }
4773 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/4773/68f31232025796fb7850b87765dce9f3e3d99b89/StringLocator.java/buggy/weka/core/StringLocator.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 282, 1071, 760, 918, 1610, 780, 1972, 12, 1442, 791, 16, 1250, 1804, 7740, 13322, 16, 21394, 18357, 1705, 10656, 16, 3601, 5786, 1705, 1333, 16, 21394, 18357, 1570, 10656, 16, 3601, 5786, 1570, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 918, 1610, 780, 1972, 12, 1442, 791, 16, 1250, 1804, 7740, 13322, 16, 21394, 18357, 1705, 10656, 16, 3601, 5786, 1705, 1333, 16, 21394, 18357, 1570, 10656, 16, 3601, 5786, 1570, ...
public void endEntity(String name) throws XNIException {
public void endEntity(String name, Augmentations augs) throws XNIException {
public void endEntity(String name) throws XNIException { if (fInDocument && !fInDTD && fCreateEntityRefNodes) { if (!fDeferNodeExpansion) { if (fDocumentImpl != null && fDocumentType != null) { NamedNodeMap entities = fDocumentType.getEntities(); NodeImpl entity = (NodeImpl)entities.getNamedItem(name); if (entity != null && entity.getFirstChild() == null) { entity.setReadOnly(false, true); Node child = fCurrentNode.getFirstChild(); while (child != null) { Node copy = child.cloneNode(true); entity.appendChild(copy); child = child.getNextSibling(); } entity.setReadOnly(true, true); entities.setNamedItem(entity); } } fCurrentNode = fCurrentNode.getParentNode(); } else { int entityIndex = -1; int dtChildIndex = fDeferredDocumentImpl.getLastChild(fDocumentTypeIndex, false); while (dtChildIndex != -1) { short nodeType = fDeferredDocumentImpl.getNodeType(dtChildIndex, false); if (nodeType == Node.ENTITY_NODE) { String nodeName = fDeferredDocumentImpl.getNodeName(dtChildIndex, false); if (nodeName.equals(name)) { if (fDeferredDocumentImpl.getLastChild(dtChildIndex, false) == -1) { entityIndex = dtChildIndex; } break; } } dtChildIndex = fDeferredDocumentImpl.getRealPrevSibling(dtChildIndex, false); } if (entityIndex != -1) { int prevIndex = -1; int childIndex = fDeferredDocumentImpl.getLastChild(fCurrentNodeIndex, false); while (childIndex != -1) { int cloneIndex = fDeferredDocumentImpl.cloneNode(childIndex, true); fDeferredDocumentImpl.insertBefore(entityIndex, cloneIndex, prevIndex); prevIndex = cloneIndex; childIndex = fDeferredDocumentImpl.getRealPrevSibling(childIndex, false); } } fCurrentNodeIndex = fDeferredDocumentImpl.getParentNode(fCurrentNodeIndex, false); } } } // endEntity(String)
4434 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/4434/1281996de10d3af1b51f0b4d78cfcd75d8ade6fe/AbstractDOMParser.java/clean/src/org/apache/xerces/parsers/AbstractDOMParser.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 918, 679, 1943, 12, 780, 508, 16, 432, 14870, 1012, 279, 9024, 13, 1216, 1139, 50, 45, 503, 288, 3639, 309, 261, 74, 382, 2519, 597, 401, 74, 382, 25728, 597, 284, 1684, 1943, 1...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 679, 1943, 12, 780, 508, 16, 432, 14870, 1012, 279, 9024, 13, 1216, 1139, 50, 45, 503, 288, 3639, 309, 261, 74, 382, 2519, 597, 401, 74, 382, 25728, 597, 284, 1684, 1943, 1...
return logfile; }
return logfile; }
public static PrintWriter getLogFile( ) { PrintWriter logfile = (PrintWriter) System.getProperties().get(IZPACK_LOGFILE); return logfile; }
28044 /local/tlutelli/issta_data/temp/all_java2context/java/2006_temp/2006/28044/9926542eaee78822409cfde7e339113ef1dee9de/Debug.java/clean/src/lib/com/izforge/izpack/util/Debug.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 282, 1071, 760, 14071, 9189, 812, 12, 225, 262, 225, 288, 565, 14071, 15204, 273, 261, 5108, 2289, 13, 2332, 18, 588, 2297, 7675, 588, 12, 6867, 12231, 67, 4842, 3776, 1769, 565, 327, 15204, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 282, 1071, 760, 14071, 9189, 812, 12, 225, 262, 225, 288, 565, 14071, 15204, 273, 261, 5108, 2289, 13, 2332, 18, 588, 2297, 7675, 588, 12, 6867, 12231, 67, 4842, 3776, 1769, 565, 327, 15204, ...
resources.addAll(getCms().getSubFolders(currentTargetFolder, CmsResourceFilter.IGNORE_EXPIRATION));
resources.addAll(getCms().getSubFolders(currentTargetFolder, CmsResourceFilter.ONLY_VISIBLE_NO_DELETED));
public String getTree() { StringBuffer result = new StringBuffer(2048); String targetFolder = getTargetFolder(); String startFolder = getStartFolder(); List targetFolderList = new ArrayList(); boolean grey; List resources = new ArrayList(); CmsFolder folder = null; String oldSiteRoot = getCms().getRequestContext().getSiteRoot(); boolean restoreSiteRoot = false; if (targetFolder != null) { // check if there is more than one folder to update (e.g. move operation) StringTokenizer T = new StringTokenizer(targetFolder, "|"); while (T.hasMoreTokens()) { String currentFolder = T.nextToken().trim(); targetFolderList.add(currentFolder); } } else { targetFolderList.add(null); } Iterator targets = targetFolderList.iterator(); try { while (targets.hasNext()) { // iterate over all given target folders String currentTargetFolder = (String)targets.next(); if ("channelselector".equals(getTreeType())) { // change the site root for channel tree window restoreSiteRoot = true; getCms().getRequestContext().saveSiteRoot(); getCms().getRequestContext().setSiteRoot(I_CmsConstants.VFS_FOLDER_CHANNELS); } else if (getSettings().getTreeSite(getTreeType()) != null) { // change the site root for popup window with site selector restoreSiteRoot = true; getCms().getRequestContext().saveSiteRoot(); if (newTree() && currentTargetFolder == null) { currentTargetFolder = "/"; } getCms().getRequestContext().setSiteRoot(getSettings().getTreeSite(getTreeType())); try { // check presence of target folder getCms().readFolder(currentTargetFolder, CmsResourceFilter.IGNORE_EXPIRATION); } catch (CmsException e) { // target folder not found, set it to "/" if (OpenCms.getLog(this).isInfoEnabled()) { OpenCms.getLog(this).info(e); } currentTargetFolder = "/"; } } // read the selected folder try { folder = getCms().readFolder(currentTargetFolder, CmsResourceFilter.IGNORE_EXPIRATION); } catch (CmsException e) { // return with error return printError(e); } if ((startFolder == null) || (! currentTargetFolder.startsWith(startFolder))) { // no (valid) start folder given, just load current folder try { if (includeFiles()) { resources.addAll(getCms().getResourcesInFolder(currentTargetFolder, CmsResourceFilter.IGNORE_EXPIRATION)); } else { resources.addAll(getCms().getSubFolders(currentTargetFolder, CmsResourceFilter.IGNORE_EXPIRATION)); } } catch (CmsException e) { // return with error return printError(e); } } else { // valid start folder given, load all folders between start and current folder try { if (includeFiles()) { resources.addAll(getCms().getResourcesInFolder(startFolder, CmsResourceFilter.IGNORE_EXPIRATION)); } else { resources.addAll(getCms().getSubFolders(startFolder)); } StringTokenizer tok = new StringTokenizer(currentTargetFolder.substring(startFolder.length()), "/"); while (tok.hasMoreTokens()) { startFolder += tok.nextToken() + "/"; if (includeFiles()) { resources.addAll(getCms().getResourcesInFolder(startFolder, CmsResourceFilter.IGNORE_EXPIRATION)); } else { resources.addAll(getCms().getSubFolders(startFolder)); } } } catch (CmsException e) { // return with error return printError(e); } } } result.append("function init() {\n"); if (newTree()) { // new tree must be reloaded result.append("parent.initTree();\n"); result.append(getRootNode()); } // read the list of project resource to select which resource is "inside" or "outside" List projectResources; try { projectResources = getCms().readProjectResources(getCms().getRequestContext().currentProject()); } catch (CmsException e) { // use an empty list (all resources are "outside") if (OpenCms.getLog(this).isInfoEnabled()) { OpenCms.getLog(this).info(e); } projectResources = new ArrayList(); } // now output all the tree nodes Iterator i = resources.iterator(); while (i.hasNext()) { CmsResource resource = (CmsResource)i.next(); grey = !CmsProject.isInsideProject(projectResources, resource); if ((!grey) && (!getSettings().getResourceTypes().containsKey(new Integer(resource.getTypeId())))) { grey = true; } result.append(getNode(resource.getName(), resource.getTypeId(), resource.getStructureId(), resource.getParentStructureId(), grey)); } if (includeFiles()) { result.append("parent.setIncludeFiles(true);\n"); } if (getTreeType() != null) { // this is a popup window tree result.append("parent.setTreeType(\""); result.append(getTreeType()); result.append("\");\n"); String curSite = getSettings().getTreeSite(getTreeType()); if (curSite != null) { // add the current site as prefix if present result.append("parent.setSitePrefix(\""); result.append(getSitePrefix(curSite, oldSiteRoot)); result.append("\");\n"); } } // set the root folder in javascript result.append("parent.setRootFolder(\""); result.append(getRootFolder()); result.append("\");\n"); if (newTree()) { // new tree result.append("parent.showTree(parent.tree_display.document, \""); result.append(folder.getStructureId().hashCode()); result.append("\");\n"); } else { // update the current tree with the childs of the selected node if (resources.size() == 0) { // the node had no childs result.append("parent.setNoChilds(\""); result.append(folder.getStructureId().hashCode()); result.append("\");\n"); } result.append("parent.showLoadedNodes(parent.tree_display.document,\""); result.append(folder.getStructureId().hashCode()); result.append("\");\n"); } result.append("}\n"); } finally { if (restoreSiteRoot) { getCms().getRequestContext().restoreSiteRoot(); } } return result.toString(); }
8585 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/8585/f0e3cb28447c785c94d99b78261405c3fa88b2da/CmsTree.java/clean/src/org/opencms/workplace/explorer/CmsTree.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 514, 15867, 1435, 288, 3639, 6674, 563, 273, 394, 6674, 12, 21573, 28, 1769, 3639, 514, 1018, 3899, 273, 8571, 3899, 5621, 3639, 514, 787, 3899, 273, 8635, 3899, 5621, 3639, 987, 10...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 15867, 1435, 288, 3639, 6674, 563, 273, 394, 6674, 12, 21573, 28, 1769, 3639, 514, 1018, 3899, 273, 8571, 3899, 5621, 3639, 514, 787, 3899, 273, 8635, 3899, 5621, 3639, 987, 10...
bundles.add(new Bundle(ourContext,r));
bundles.add(new Bundle(ourContext, r));
Item(Context context, TableRow row) throws SQLException { ourContext = context; itemRow = row; dublinCoreChanged = false; dublinCore = new ArrayList(); bundlesChanged = false; bundles = new ArrayList(); // FIXME submitter = null; // Get bitstreams TableRowIterator tri = DatabaseManager.query(ourContext, "bundle", "select bundle.* from bundle, item2bundle where " + "item2bundle.bundle_id=bundle.bundle_id AND " + "item2bundle.item_id=" + itemRow.getIntColumn("item_id") + ";"); while (tri.hasNext()) { TableRow r = (TableRow) tri.next(); bundles.add(new Bundle(ourContext,r)); } // Get Dublin Core metadata tri = DatabaseManager.query(ourContext, "dcresult", "select * from dcresult where item_id=" + itemRow.getIntColumn("item_id")); while (tri.hasNext()) { TableRow resultRow = (TableRow) tri.next(); // Get the Dublin Core type TableRow typeRow = DatabaseManager.find(ourContext, "dctyperegistry", resultRow.getIntColumn("dc_type_id")); // Make a DCValue object DCValue dcv = new DCValue(); dcv.element = typeRow.getStringColumn("element"); dcv.qualifier = typeRow.getStringColumn("qualifier"); dcv.value = resultRow.getStringColumn("text_value"); dcv.language = resultRow.getStringColumn("text_lang"); // Add it to the list dublinCore.add(dcv); } }
1868 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1868/85c7430ba7691f831fafc420459d280408310eb9/Item.java/buggy/dspace/src/org/dspace/content/Item.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 4342, 12, 1042, 819, 16, 3555, 1999, 1027, 13, 3639, 1216, 6483, 565, 288, 3639, 3134, 1042, 273, 819, 31, 3639, 761, 1999, 273, 1027, 31, 3639, 302, 29056, 4670, 5033, 273, 629, 31, 36...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 4342, 12, 1042, 819, 16, 3555, 1999, 1027, 13, 3639, 1216, 6483, 565, 288, 3639, 3134, 1042, 273, 819, 31, 3639, 761, 1999, 273, 1027, 31, 3639, 302, 29056, 4670, 5033, 273, 629, 31, 36...
public void ruleAction(int ruleNumber) { if (bad_rule != 0) return; switch (ruleNumber) { // // Rule 1: identifier ::= IDENTIFIER // case 1: { if (prsStream.getKind(btParser.getToken(1)) != X10Parsersym.TK_IDENTIFIER) { System.out.println("Parser turning keyword " + prsStream.getName(btParser.getToken(1)) + " at " + prsStream.getLine(btParser.getToken(1)) + ":" + prsStream.getColumn(btParser.getToken(1)) + " into an identifier"); } break; } // // Rule 2: PrimitiveType ::= NumericType // case 2: break; // // Rule 3: PrimitiveType ::= boolean // case 3: { btParser.setSym1(nf.CanonicalTypeNode(pos(), ts.Boolean())); break; } // // Rule 4: NumericType ::= IntegralType // case 4: break; // // Rule 5: NumericType ::= FloatingPointType // case 5: break; // // Rule 6: IntegralType ::= byte // case 6: { btParser.setSym1(nf.CanonicalTypeNode(pos(), ts.Byte())); break; } // // Rule 7: IntegralType ::= char // case 7: { btParser.setSym1(nf.CanonicalTypeNode(pos(), ts.Char())); break; } // // Rule 8: IntegralType ::= short // case 8: { btParser.setSym1(nf.CanonicalTypeNode(pos(), ts.Short())); break; } // // Rule 9: IntegralType ::= int // case 9: { btParser.setSym1(nf.CanonicalTypeNode(pos(), ts.Int())); break; } // // Rule 10: IntegralType ::= long // case 10: { btParser.setSym1(nf.CanonicalTypeNode(pos(), ts.Long())); break; } // // Rule 11: FloatingPointType ::= float // case 11: { btParser.setSym1(nf.CanonicalTypeNode(pos(), ts.Float())); break; } // // Rule 12: FloatingPointType ::= double // case 12: { btParser.setSym1(nf.CanonicalTypeNode(pos(), ts.Double())); break; } // // Rule 13: ReferenceType ::= ClassOrInterfaceType // case 13: break; // // Rule 14: ReferenceType ::= ArrayType // case 14: break; // // Rule 15: ClassOrInterfaceType ::= ClassType // case 15: break; // // Rule 16: ClassType ::= TypeName // case 16: {//vj assert(btParser.getSym(2) == null); // generic not yet supported Name a = (Name) btParser.getSym(1); btParser.setSym1(a.toType()); break; } // // Rule 17: InterfaceType ::= TypeName // case 17: {//vj assert(btParser.getSym(2) == null); // generic not yet supported Name a = (Name) btParser.getSym(1); btParser.setSym1(a.toType()); break; } // // Rule 18: TypeName ::= identifier // case 18: { polyglot.lex.Identifier a = id(btParser.getToken(1)); btParser.setSym1(new Name(nf, ts, pos(), a.getIdentifier())); break; } // // Rule 19: TypeName ::= TypeName DOT identifier // case 19: { Name a = (Name) btParser.getSym(1); polyglot.lex.Identifier b = id(btParser.getToken(3)); btParser.setSym1(new Name(nf, ts, pos(btParser.getFirstToken(), btParser.getLastToken()), a, b.getIdentifier())); break; } // // Rule 20: ClassName ::= TypeName // case 20: break; // // Rule 21: TypeVariable ::= identifier // case 21: break; // // Rule 22: ArrayType ::= Type LBRACKET RBRACKET // case 22: { TypeNode a = (TypeNode) btParser.getSym(1); btParser.setSym1(array(a, pos(), 1)); break; } // // Rule 23: TypeParameter ::= TypeVariable TypeBoundopt // case 23: bad_rule = 23; break; // // Rule 24: TypeBound ::= extends ClassOrInterfaceType AdditionalBoundListopt // case 24: bad_rule = 24; break; // // Rule 25: AdditionalBoundList ::= AdditionalBound // case 25: bad_rule = 25; break; // // Rule 26: AdditionalBoundList ::= AdditionalBoundList AdditionalBound // case 26: bad_rule = 26; break; // // Rule 27: AdditionalBound ::= AND InterfaceType // case 27: bad_rule = 27; break; // // Rule 28: TypeArguments ::= LESS ActualTypeArgumentList GREATER // case 28: bad_rule = 28; break; // // Rule 29: ActualTypeArgumentList ::= ActualTypeArgument // case 29: bad_rule = 29; break; // // Rule 30: ActualTypeArgumentList ::= ActualTypeArgumentList COMMA ActualTypeArgument // case 30: bad_rule = 30; break; // // Rule 31: Wildcard ::= QUESTION WildcardBoundsOpt // case 31: bad_rule = 31; break; // // Rule 32: WildcardBounds ::= extends ReferenceType // case 32: bad_rule = 32; break; // // Rule 33: WildcardBounds ::= super ReferenceType // case 33: bad_rule = 33; break; // // Rule 34: PackageName ::= identifier // case 34: { polyglot.lex.Identifier a = id(btParser.getToken(1)); btParser.setSym1(new Name(nf, ts, pos(), a.getIdentifier())); break; } // // Rule 35: PackageName ::= PackageName DOT identifier // case 35: { Name a = (Name) btParser.getSym(1); polyglot.lex.Identifier b = id(btParser.getToken(3)); btParser.setSym1(new Name(nf, ts, pos(btParser.getFirstToken(), btParser.getLastToken()), a, b.getIdentifier())); break; } // // Rule 36: ExpressionName ::= identifier // case 36: { polyglot.lex.Identifier a = id(btParser.getToken(1)); btParser.setSym1(new Name(nf, ts, pos(), a.getIdentifier())); break; } // // Rule 37: ExpressionName ::= AmbiguousName DOT identifier // case 37: { Name a = (Name) btParser.getSym(1); polyglot.lex.Identifier b = id(btParser.getToken(3)); btParser.setSym1(new Name(nf, ts, pos(btParser.getFirstToken(), btParser.getLastToken()), a, b.getIdentifier())); break; } // // Rule 38: MethodName ::= identifier // case 38: { polyglot.lex.Identifier a = id(btParser.getToken(1)); btParser.setSym1(new Name(nf, ts, pos(), a.getIdentifier())); break; } // // Rule 39: MethodName ::= AmbiguousName DOT identifier // case 39: { Name a = (Name) btParser.getSym(1); polyglot.lex.Identifier b = id(btParser.getToken(3)); btParser.setSym1(new Name(nf, ts, pos(btParser.getFirstToken(), btParser.getLastToken()), a, b.getIdentifier())); break; } // // Rule 40: PackageOrTypeName ::= identifier // case 40: { polyglot.lex.Identifier a = id(btParser.getToken(1)); btParser.setSym1(new Name(nf, ts, pos(), a.getIdentifier())); break; } // // Rule 41: PackageOrTypeName ::= PackageOrTypeName DOT identifier // case 41: { Name a = (Name) btParser.getSym(1); polyglot.lex.Identifier b = id(btParser.getToken(3)); btParser.setSym1(new Name(nf, ts, pos(btParser.getFirstToken(), btParser.getLastToken()), a, b.getIdentifier())); break; } // // Rule 42: AmbiguousName ::= identifier // case 42: { polyglot.lex.Identifier a = id(btParser.getToken(1)); btParser.setSym1(new Name(nf, ts, pos(), a.getIdentifier())); break; } // // Rule 43: AmbiguousName ::= AmbiguousName DOT identifier // case 43: { Name a = (Name) btParser.getSym(1); polyglot.lex.Identifier b = id(btParser.getToken(3)); btParser.setSym1(new Name(nf, ts, pos(btParser.getFirstToken(), btParser.getLastToken()), a, b.getIdentifier())); break; } // // Rule 44: CompilationUnit ::= Commentsopt PackageDeclarationopt ImportDeclarationsopt TypeDeclarationsopt // case 44: { Object comment = btParser.getSym(1); PackageNode a = (PackageNode) btParser.getSym(2); List b = (List) btParser.getSym(3), c = (List) btParser.getSym(4); Node n = nf.SourceFile(pos(btParser.getFirstToken(), btParser.getLastToken()), a, b, c); if (comment != null) { n.setComment(comment.toString()); } btParser.setSym1(n); break; } // // Rule 45: Comments ::= Comment // case 45: { Object comment = comment(btParser.getToken(1)); btParser.setSym1(comment); break; } // // Rule 46: Comments ::= Comments Comment // case 46: { btParser.setSym1(btParser.getSym(2)); break; } // // Rule 47: ImportDeclarations ::= ImportDeclaration // case 47: { List l = new TypedList(new LinkedList(), Import.class, false); Import a = (Import) btParser.getSym(1); l.add(a); btParser.setSym1(l); break; } // // Rule 48: ImportDeclarations ::= ImportDeclarations ImportDeclaration // case 48: { List l = (TypedList) btParser.getSym(1); Import b = (Import) btParser.getSym(2); if (b != null) l.add(b); //btParser.setSym1(l); break; } // // Rule 49: TypeDeclarations ::= Commentsopt TypeDeclaration // case 49: { Object comment = btParser.getSym(1); List l = new TypedList(new LinkedList(), TopLevelDecl.class, false); TopLevelDecl a = (TopLevelDecl) btParser.getSym(2); if (a != null) l.add(a); if (comment != null) { a.setComment(comment.toString()); } btParser.setSym1(l); break; } // // Rule 50: TypeDeclarations ::= TypeDeclarations TypeDeclaration // case 50: { List l = (TypedList) btParser.getSym(1); TopLevelDecl b = (TopLevelDecl) btParser.getSym(2); if (b != null) l.add(b); //btParser.setSym1(l); break; } // // Rule 51: PackageDeclaration ::= package PackageName SEMICOLON // case 51: {//vj assert(btParser.getSym(1) == null); // generic not yet supported Name a = (Name) btParser.getSym(2); btParser.setSym1(a.toPackage()); break; } // // Rule 52: ImportDeclaration ::= SingleTypeImportDeclaration // case 52: break; // // Rule 53: ImportDeclaration ::= TypeImportOnDemandDeclaration // case 53: break; // // Rule 54: ImportDeclaration ::= SingleStaticImportDeclaration // case 54: break; // // Rule 55: ImportDeclaration ::= StaticImportOnDemandDeclaration // case 55: break; // // Rule 56: SingleTypeImportDeclaration ::= import TypeName SEMICOLON // case 56: { Name a = (Name) btParser.getSym(2); btParser.setSym1(nf.Import(pos(btParser.getFirstToken(), btParser.getLastToken()), Import.CLASS, a.toString())); break; } // // Rule 57: TypeImportOnDemandDeclaration ::= import PackageOrTypeName DOT MULTIPLY SEMICOLON // case 57: { Name a = (Name) btParser.getSym(2); btParser.setSym1(nf.Import(pos(btParser.getFirstToken(), btParser.getLastToken()), Import.PACKAGE, a.toString())); break; } // // Rule 58: SingleStaticImportDeclaration ::= import static TypeName DOT identifier SEMICOLON // case 58: bad_rule = 58; break; // // Rule 59: StaticImportOnDemandDeclaration ::= import static TypeName DOT MULTIPLY SEMICOLON // case 59: bad_rule = 59; break; // // Rule 60: TypeDeclaration ::= ClassDeclaration // case 60: break; // // Rule 61: TypeDeclaration ::= InterfaceDeclaration // case 61: break; // // Rule 62: TypeDeclaration ::= SEMICOLON // case 62: { btParser.setSym1(null); break; } // // Rule 63: ClassDeclaration ::= NormalClassDeclaration // case 63: break; // // Rule 64: NormalClassDeclaration ::= Commentsopt ClassModifiersopt class identifier Superopt Interfacesopt ClassBody // case 64: { Object comment = btParser.getSym(1); Flags a = (Flags) btParser.getSym(2); polyglot.lex.Identifier b = id(btParser.getToken(4));//vj assert(btParser.getSym(4) == null); TypeNode c = (TypeNode) btParser.getSym(5); // by default extend x10.lang.Object if (c == null) { c= new Name(nf, ts, pos(), "x10.lang.Object").toType(); } List d = (List) btParser.getSym(6); ClassBody e = (ClassBody) btParser.getSym(7); Node n = a.isValue() ? nf.ValueClassDecl(pos(btParser.getFirstToken(), btParser.getLastToken()), a, b.getIdentifier(), c, d, e) : nf.ClassDecl(pos(btParser.getFirstToken(), btParser.getLastToken()), a, b.getIdentifier(), c, d, e); if (comment != null) n.setComment(comment.toString()); btParser.setSym1(n); break; } // // Rule 65: ClassModifiers ::= ClassModifier // case 65: break; // // Rule 66: ClassModifiers ::= ClassModifiers ClassModifier // case 66: { Flags a = (Flags) btParser.getSym(1), b = (Flags) btParser.getSym(2); btParser.setSym1(a.set(b)); break; } // // Rule 67: ClassModifier ::= public // case 67: { btParser.setSym1(Flags.PUBLIC); break; } // // Rule 68: ClassModifier ::= protected // case 68: { btParser.setSym1(Flags.PROTECTED); break; } // // Rule 69: ClassModifier ::= private // case 69: { btParser.setSym1(Flags.PRIVATE); break; } // // Rule 70: ClassModifier ::= abstract // case 70: { btParser.setSym1(Flags.ABSTRACT); break; } // // Rule 71: ClassModifier ::= static // case 71: { btParser.setSym1(Flags.STATIC); break; } // // Rule 72: ClassModifier ::= final // case 72: { btParser.setSym1(Flags.FINAL); break; } // // Rule 73: ClassModifier ::= strictfp // case 73: { btParser.setSym1(Flags.STRICTFP); break; } // // Rule 74: TypeParameters ::= LESS TypeParameterList GREATER // case 74: bad_rule = 74; break; // // Rule 75: TypeParameterList ::= TypeParameter // case 75: bad_rule = 75; break; // // Rule 76: TypeParameterList ::= TypeParameterList COMMA TypeParameter // case 76: bad_rule = 76; break; // // Rule 77: Super ::= extends ClassType // case 77: { btParser.setSym1(btParser.getSym(2)); break; } // // Rule 78: Interfaces ::= implements InterfaceTypeList // case 78: { btParser.setSym1(btParser.getSym(2)); break; } // // Rule 79: InterfaceTypeList ::= InterfaceType // case 79: { List l = new TypedList(new LinkedList(), TypeNode.class, false); l.add(btParser.getSym(1)); btParser.setSym1(l); break; } // // Rule 80: InterfaceTypeList ::= InterfaceTypeList COMMA InterfaceType // case 80: { List l = (TypedList) btParser.getSym(1); l.add(btParser.getSym(2)); btParser.setSym1(l); break; } // // Rule 81: ClassBody ::= LBRACE ClassBodyDeclarationsopt RBRACE // case 81: { btParser.setSym1(nf.ClassBody(pos(btParser.getFirstToken(), btParser.getLastToken()), (List) btParser.getSym(2))); break; } // // Rule 82: ClassBodyDeclarations ::= ClassBodyDeclaration // case 82: break; // // Rule 83: ClassBodyDeclarations ::= ClassBodyDeclarations ClassBodyDeclaration // case 83: { List a = (List) btParser.getSym(1), b = (List) btParser.getSym(2); a.addAll(b); // btParser.setSym1(a); break; } // // Rule 84: ClassBodyDeclaration ::= ClassMemberDeclaration // case 84: break; // // Rule 85: ClassBodyDeclaration ::= InstanceInitializer // case 85: { List l = new TypedList(new LinkedList(), ClassMember.class, false); Block a = (Block) btParser.getSym(1); l.add(nf.Initializer(pos(), Flags.NONE, a)); btParser.setSym1(l); break; } // // Rule 86: ClassBodyDeclaration ::= StaticInitializer // case 86: { List l = new TypedList(new LinkedList(), ClassMember.class, false); Block a = (Block) btParser.getSym(1); l.add(nf.Initializer(pos(), Flags.STATIC, a)); btParser.setSym1(l); break; } // // Rule 87: ClassBodyDeclaration ::= ConstructorDeclaration // case 87: { List l = new TypedList(new LinkedList(), ClassMember.class, false); l.add(btParser.getSym(1)); btParser.setSym1(l); break; } // // Rule 88: ClassMemberDeclaration ::= FieldDeclaration // case 88: break; // // Rule 89: ClassMemberDeclaration ::= MethodDeclaration // case 89: { List l = new TypedList(new LinkedList(), ClassMember.class, false); l.add(btParser.getSym(1)); btParser.setSym1(l); break; } // // Rule 90: ClassMemberDeclaration ::= ClassDeclaration // case 90: { List l = new TypedList(new LinkedList(), ClassMember.class, false); l.add(btParser.getSym(1)); btParser.setSym1(l); break; } // // Rule 91: ClassMemberDeclaration ::= InterfaceDeclaration // case 91: { List l = new TypedList(new LinkedList(), ClassMember.class, false); l.add(btParser.getSym(1)); btParser.setSym1(l); break; } // // Rule 92: ClassMemberDeclaration ::= SEMICOLON // case 92: { List l = new TypedList(new LinkedList(), ClassMember.class, false); btParser.setSym1(l); break; } // // Rule 93: FieldDeclaration ::= Commentsopt FieldModifiersopt Type VariableDeclarators SEMICOLON // case 93: { Object comment = btParser.getSym(1); List l = new TypedList(new LinkedList(), ClassMember.class, false); Flags a = (Flags) btParser.getSym(2); TypeNode b = (TypeNode) btParser.getSym(3); List c = (List) btParser.getSym(4); for (Iterator i = c.iterator(); i.hasNext();) { VarDeclarator d = (VarDeclarator) i.next(); l.add(nf.FieldDecl(pos(btParser.getFirstToken(2), btParser.getLastToken()), a, array(b, pos(btParser.getFirstToken(2), btParser.getLastToken(2)), d.dims), d.name, d.init)); } if (comment != null) ((Node) l.get(0)).setComment(comment.toString()); btParser.setSym1(l); break; } // // Rule 94: VariableDeclarators ::= VariableDeclarator // case 94: { List l = new TypedList(new LinkedList(), VarDeclarator.class, false); l.add(btParser.getSym(1)); btParser.setSym1(l); break; } // // Rule 95: VariableDeclarators ::= VariableDeclarators COMMA VariableDeclarator // case 95: { List l = (List) btParser.getSym(1); l.add(btParser.getSym(3)); // btParser.setSym1(l); break; } // // Rule 96: VariableDeclarator ::= VariableDeclaratorId // case 96: break; // // Rule 97: VariableDeclarator ::= VariableDeclaratorId EQUAL VariableInitializer // case 97: { VarDeclarator a = (VarDeclarator) btParser.getSym(1); Expr b = (Expr) btParser.getSym(3); a.init = b; // btParser.setSym1(a); break; } // // Rule 98: VariableDeclaratorId ::= identifier // case 98: { polyglot.lex.Identifier a = id(btParser.getToken(1)); btParser.setSym1(new VarDeclarator(pos(), a.getIdentifier())); break; } // // Rule 99: VariableDeclaratorId ::= VariableDeclaratorId LBRACKET RBRACKET // case 99: { VarDeclarator a = (VarDeclarator) btParser.getSym(1); a.dims++; // btParser.setSym1(a); break; } // // Rule 100: VariableInitializer ::= Expression // case 100: break; // // Rule 101: VariableInitializer ::= ArrayInitializer // case 101: break; // // Rule 102: FieldModifiers ::= FieldModifier // case 102: break; // // Rule 103: FieldModifiers ::= FieldModifiers FieldModifier // case 103: { Flags a = (Flags) btParser.getSym(1), b = (Flags) btParser.getSym(2); btParser.setSym1(a.set(b)); break; } // // Rule 104: FieldModifier ::= public // case 104: { btParser.setSym1(Flags.PUBLIC); break; } // // Rule 105: FieldModifier ::= protected // case 105: { btParser.setSym1(Flags.PROTECTED); break; } // // Rule 106: FieldModifier ::= private // case 106: { btParser.setSym1(Flags.PRIVATE); break; } // // Rule 107: FieldModifier ::= static // case 107: { btParser.setSym1(Flags.STATIC); break; } // // Rule 108: FieldModifier ::= final // case 108: { btParser.setSym1(Flags.FINAL); break; } // // Rule 109: FieldModifier ::= transient // case 109: { btParser.setSym1(Flags.TRANSIENT); break; } // // Rule 110: FieldModifier ::= volatile // case 110: { btParser.setSym1(Flags.VOLATILE); break; } // // Rule 111: MethodDeclaration ::= Commentsopt MethodHeader MethodBody // case 111: { Object comment = btParser.getSym(1); MethodDecl a = (MethodDecl) btParser.getSym(2); Block b = (Block) btParser.getSym(3); if (comment != null) a.setComment(comment.toString()); btParser.setSym1(a.body(b)); break; } // // Rule 112: MethodHeader ::= MethodModifiersopt ResultType MethodDeclarator Throwsopt // case 112: { Flags a = (Flags) btParser.getSym(1);//vj assert(btParser.getSym(2) == null); TypeNode b = (TypeNode) btParser.getSym(2); Object[] o = (Object []) btParser.getSym(3); Name c = (Name) o[0]; List d = (List) o[1]; Integer e = (Integer) o[2]; List f = (List) btParser.getSym(4); if (b.type() == ts.Void() && e.intValue() > 0) { // TODO: error!!! } btParser.setSym1(nf.MethodDecl(pos(btParser.getFirstToken(2), btParser.getLastToken(3)), a, array((TypeNode) b, pos(btParser.getFirstToken(2), btParser.getLastToken(2)), e.intValue()), c.toString(), d, f, null)); break; } // // Rule 113: ResultType ::= Type // case 113: break; // // Rule 114: ResultType ::= void // case 114: { btParser.setSym1(nf.CanonicalTypeNode(pos(), ts.Void())); break; } // // Rule 115: MethodDeclarator ::= identifier LPAREN FormalParameterListopt RPAREN // case 115: { Object[] a = new Object[3]; a[0] = new Name(nf, ts, pos(), id(btParser.getToken(1)).getIdentifier()); a[1] = btParser.getSym(3); a[2] = new Integer(0); btParser.setSym1(a); break; } // // Rule 116: MethodDeclarator ::= MethodDeclarator LBRACKET RBRACKET // case 116: { Object[] a = (Object []) btParser.getSym(1); a[2] = new Integer(((Integer) a[2]).intValue() + 1); // btParser.setSym1(a); break; } // // Rule 117: FormalParameterList ::= LastFormalParameter // case 117: { List l = new TypedList(new LinkedList(), Formal.class, false); l.add(btParser.getSym(1)); btParser.setSym1(l); break; } // // Rule 118: FormalParameterList ::= FormalParameters COMMA LastFormalParameter // case 118: { List l = (List) btParser.getSym(1); l.add(btParser.getSym(3)); // btParser.setSym1(l); break; } // // Rule 119: FormalParameters ::= FormalParameter // case 119: { List l = new TypedList(new LinkedList(), Formal.class, false); l.add(btParser.getSym(1)); btParser.setSym1(l); break; } // // Rule 120: FormalParameters ::= FormalParameters COMMA FormalParameter // case 120: { List l = (List) btParser.getSym(1); l.add(btParser.getSym(3)); // btParser.setSym1(l); break; } // // Rule 121: FormalParameter ::= VariableModifiersopt Type VariableDeclaratorId // case 121: { Flags f = (Flags) btParser.getSym(1); TypeNode a = (TypeNode) btParser.getSym(2); VarDeclarator b = (VarDeclarator) btParser.getSym(3); btParser.setSym1(nf.Formal(pos(), f, array(a, pos(btParser.getFirstToken(2), btParser.getLastToken(2)), b.dims), b.name)); break; } // // Rule 123: VariableModifiers ::= VariableModifiers VariableModifier // case 123: { Flags a = (Flags) btParser.getSym(1), b = (Flags) btParser.getSym(2); btParser.setSym1(a.set(b)); break; } // // Rule 124: VariableModifier ::= final // case 124: { btParser.setSym1(Flags.FINAL); break; } // // Rule 125: LastFormalParameter ::= VariableModifiersopt Type ...opt VariableDeclaratorId // case 125: { Flags f = (Flags) btParser.getSym(1); TypeNode a = (TypeNode) btParser.getSym(2); assert(btParser.getSym(3) == null); VarDeclarator b = (VarDeclarator) btParser.getSym(4); btParser.setSym1(nf.Formal(pos(), f, array(a, pos(btParser.getFirstToken(2), btParser.getLastToken(2)), b.dims), b.name)); break; } // // Rule 126: MethodModifiers ::= MethodModifier // case 126: break; // // Rule 127: MethodModifiers ::= MethodModifiers MethodModifier // case 127: { Flags a = (Flags) btParser.getSym(1), b = (Flags) btParser.getSym(2); btParser.setSym1(a.set(b)); break; } // // Rule 128: MethodModifier ::= public // case 128: { btParser.setSym1(Flags.PUBLIC); break; } // // Rule 129: MethodModifier ::= protected // case 129: { btParser.setSym1(Flags.PROTECTED); break; } // // Rule 130: MethodModifier ::= private // case 130: { btParser.setSym1(Flags.PRIVATE); break; } // // Rule 131: MethodModifier ::= abstract // case 131: { btParser.setSym1(Flags.ABSTRACT); break; } // // Rule 132: MethodModifier ::= static // case 132: { btParser.setSym1(Flags.STATIC); break; } // // Rule 133: MethodModifier ::= final // case 133: { btParser.setSym1(Flags.FINAL); break; } // // Rule 134: MethodModifier ::= synchronized // case 134: { btParser.setSym1(Flags.SYNCHRONIZED); break; } // // Rule 135: MethodModifier ::= native // case 135: { btParser.setSym1(Flags.NATIVE); break; } // // Rule 136: MethodModifier ::= strictfp // case 136: { btParser.setSym1(Flags.STRICTFP); break; } // // Rule 137: Throws ::= throws ExceptionTypeList // case 137: { btParser.setSym1(btParser.getSym(2)); break; } // // Rule 138: ExceptionTypeList ::= ExceptionType // case 138: { List l = new TypedList(new LinkedList(), TypeNode.class, false); l.add(btParser.getSym(1)); btParser.setSym1(l); break; } // // Rule 139: ExceptionTypeList ::= ExceptionTypeList COMMA ExceptionType // case 139: { List l = (List) btParser.getSym(1); l.add(btParser.getSym(3)); // btParser.setSym1(l); break; } // // Rule 140: ExceptionType ::= ClassType // case 140: break; // // Rule 141: ExceptionType ::= TypeVariable // case 141: break; // // Rule 142: MethodBody ::= Block // case 142: break; // // Rule 143: MethodBody ::= SEMICOLON // case 143: btParser.setSym1(null); break; // // Rule 144: InstanceInitializer ::= Block // case 144: break; // // Rule 145: StaticInitializer ::= static Block // case 145: { btParser.setSym1(btParser.getSym(2)); break; } // // Rule 146: ConstructorDeclaration ::= ConstructorModifiersopt ConstructorDeclarator Throwsopt ConstructorBody // case 146: { Flags m = (Flags) btParser.getSym(1); Object[] o = (Object []) btParser.getSym(2); Name a = (Name) o[1]; List b = (List) o[2]; List c = (List) btParser.getSym(3); Block d = (Block) btParser.getSym(4); btParser.setSym1(nf.ConstructorDecl(pos(), m, a.toString(), b, c, d)); break; } // // Rule 147: ConstructorDeclarator ::= SimpleTypeName LPAREN FormalParameterListopt RPAREN // case 147: {//vj assert(btParser.getSym(1) == null); Object[] a = new Object[3];//vj a[0] = btParser.getSym(1); a[1] = btParser.getSym(1); a[2] = btParser.getSym(3); btParser.setSym1(a); break; } // // Rule 148: SimpleTypeName ::= identifier // case 148: { polyglot.lex.Identifier a = id(btParser.getToken(1)); btParser.setSym1(new Name(nf, ts, pos(), a.getIdentifier())); break; } // // Rule 149: ConstructorModifiers ::= ConstructorModifier // case 149: break; // // Rule 150: ConstructorModifiers ::= ConstructorModifiers ConstructorModifier // case 150: { Flags a = (Flags) btParser.getSym(1), b = (Flags) btParser.getSym(2); btParser.setSym1(a.set(b)); break; } // // Rule 151: ConstructorModifier ::= public // case 151: { btParser.setSym1(Flags.PUBLIC); break; } // // Rule 152: ConstructorModifier ::= protected // case 152: { btParser.setSym1(Flags.PROTECTED); break; } // // Rule 153: ConstructorModifier ::= private // case 153: { btParser.setSym1(Flags.PRIVATE); break; } // // Rule 154: ConstructorBody ::= LBRACE ExplicitConstructorInvocationopt BlockStatementsopt RBRACE // case 154: { Stmt a = (Stmt) btParser.getSym(2); List l; if (a == null) l = (List) btParser.getSym(3); else { l = new TypedList(new LinkedList(), Stmt.class, false); List l2 = (List) btParser.getSym(3); l.add(a); l.addAll(l2); } btParser.setSym1(nf.Block(pos(), l)); break; } // // Rule 155: ExplicitConstructorInvocation ::= this LPAREN ArgumentListopt RPAREN SEMICOLON // case 155: {//vj assert(btParser.getSym(1) == null); List b = (List) btParser.getSym(3); btParser.setSym1(nf.ThisCall(pos(), b)); break; } // // Rule 156: ExplicitConstructorInvocation ::= super LPAREN ArgumentListopt RPAREN SEMICOLON // case 156: {//vj assert(btParser.getSym(1) == null); List b = (List) btParser.getSym(3); btParser.setSym1(nf.SuperCall(pos(), b)); break; } // // Rule 157: ExplicitConstructorInvocation ::= Primary DOT this LPAREN ArgumentListopt RPAREN SEMICOLON // case 157: { Expr a = (Expr) btParser.getSym(1);//vj assert(btParser.getSym(2) == null); List b = (List) btParser.getSym(5); btParser.setSym1(nf.ThisCall(pos(), a, b)); break; } // // Rule 158: ExplicitConstructorInvocation ::= Primary DOT super LPAREN ArgumentListopt RPAREN SEMICOLON // case 158: { Expr a = (Expr) btParser.getSym(1);//vj assert(btParser.getSym(2) == null); List b = (List) btParser.getSym(5); btParser.setSym1(nf.SuperCall(pos(), a, b)); break; } // // Rule 159: EnumDeclaration ::= ClassModifiersopt enum identifier Interfacesopt EnumBody // case 159: bad_rule = 159; break; // // Rule 160: EnumBody ::= LBRACE EnumConstantsopt ,opt EnumBodyDeclarationsopt RBRACE // case 160: bad_rule = 160; break; // // Rule 161: EnumConstants ::= EnumConstant // case 161: bad_rule = 161; break; // // Rule 162: EnumConstants ::= EnumConstants COMMA EnumConstant // case 162: bad_rule = 162; break; // // Rule 163: EnumConstant ::= identifier Argumentsopt ClassBodyopt // case 163: bad_rule = 163; break; // // Rule 164: Arguments ::= LPAREN ArgumentListopt RPAREN // case 164: { btParser.setSym1(btParser.getSym(2)); break; } // // Rule 165: EnumBodyDeclarations ::= SEMICOLON ClassBodyDeclarationsopt // case 165: bad_rule = 165; break; // // Rule 166: InterfaceDeclaration ::= NormalInterfaceDeclaration // case 166: break; // // Rule 167: NormalInterfaceDeclaration ::= Commentsopt InterfaceModifiersopt interface identifier ExtendsInterfacesopt InterfaceBody // case 167: { Object comment = btParser.getSym(1); Flags a = (Flags) btParser.getSym(2); polyglot.lex.Identifier b = id(btParser.getToken(4));//vj assert(btParser.getSym(4) == null); List c = (List) btParser.getSym(5); ClassBody d = (ClassBody) btParser.getSym(6); Node n = nf.ClassDecl(pos(), a.Interface(), b.getIdentifier(), null, c, d); if (comment != null) n.setComment( comment.toString() ); btParser.setSym1(n); break; } // // Rule 168: InterfaceModifiers ::= InterfaceModifier // case 168: break; // // Rule 169: InterfaceModifiers ::= InterfaceModifiers InterfaceModifier // case 169: { Flags a = (Flags) btParser.getSym(1), b = (Flags) btParser.getSym(2); btParser.setSym1(a.set(b)); break; } // // Rule 170: InterfaceModifier ::= public // case 170: { btParser.setSym1(Flags.PUBLIC); break; } // // Rule 171: InterfaceModifier ::= protected // case 171: { btParser.setSym1(Flags.PROTECTED); break; } // // Rule 172: InterfaceModifier ::= private // case 172: { btParser.setSym1(Flags.PRIVATE); break; } // // Rule 173: InterfaceModifier ::= abstract // case 173: { btParser.setSym1(Flags.ABSTRACT); break; } // // Rule 174: InterfaceModifier ::= static // case 174: { btParser.setSym1(Flags.STATIC); break; } // // Rule 175: InterfaceModifier ::= strictfp // case 175: { btParser.setSym1(Flags.STRICTFP); break; } // // Rule 176: ExtendsInterfaces ::= extends InterfaceType // case 176: { List l = new TypedList(new LinkedList(), TypeNode.class, false); l.add(btParser.getSym(2)); btParser.setSym1(l); break; } // // Rule 177: ExtendsInterfaces ::= ExtendsInterfaces COMMA InterfaceType // case 177: { List l = (List) btParser.getSym(1); l.add(btParser.getSym(3)); // btParser.setSym1(l); break; } // // Rule 178: InterfaceBody ::= LBRACE InterfaceMemberDeclarationsopt RBRACE // case 178: { List a = (List)btParser.getSym(2); btParser.setSym1(nf.ClassBody(pos(), a)); break; } // // Rule 179: InterfaceMemberDeclarations ::= InterfaceMemberDeclaration // case 179: break; // // Rule 180: InterfaceMemberDeclarations ::= InterfaceMemberDeclarations InterfaceMemberDeclaration // case 180: { List l = (List) btParser.getSym(1), l2 = (List) btParser.getSym(2); l.addAll(l2); // btParser.setSym1(l); break; } // // Rule 181: InterfaceMemberDeclaration ::= ConstantDeclaration // case 181: break; // // Rule 182: InterfaceMemberDeclaration ::= AbstractMethodDeclaration // case 182: { List l = new TypedList(new LinkedList(), ClassMember.class, false); l.add(btParser.getSym(1)); btParser.setSym1(l); break; } // // Rule 183: InterfaceMemberDeclaration ::= ClassDeclaration // case 183: { List l = new TypedList(new LinkedList(), ClassMember.class, false); l.add(btParser.getSym(1)); btParser.setSym1(l); break; } // // Rule 184: InterfaceMemberDeclaration ::= InterfaceDeclaration // case 184: { List l = new TypedList(new LinkedList(), ClassMember.class, false); l.add(btParser.getSym(1)); btParser.setSym1(l); break; } // // Rule 185: InterfaceMemberDeclaration ::= SEMICOLON // case 185: { btParser.setSym1(Collections.EMPTY_LIST); break; } // // Rule 186: ConstantDeclaration ::= ConstantModifiersopt Type VariableDeclarators // case 186: { List l = new TypedList(new LinkedList(), ClassMember.class, false); Flags a = (Flags) btParser.getSym(1); TypeNode b = (TypeNode) btParser.getSym(2); List c = (List) btParser.getSym(3); for (Iterator i = c.iterator(); i.hasNext();) { VarDeclarator d = (VarDeclarator) i.next(); l.add(nf.FieldDecl(pos(btParser.getFirstToken(2), btParser.getLastToken()), a, array(b, pos(btParser.getFirstToken(2), btParser.getLastToken(2)), d.dims), d.name, d.init)); } btParser.setSym1(l); break; } // // Rule 187: ConstantModifiers ::= ConstantModifier // case 187: break; // // Rule 188: ConstantModifiers ::= ConstantModifiers ConstantModifier // case 188: { Flags a = (Flags) btParser.getSym(1), b = (Flags) btParser.getSym(2); btParser.setSym1(a.set(b)); break; } // // Rule 189: ConstantModifier ::= public // case 189: { btParser.setSym1(Flags.PUBLIC); break; } // // Rule 190: ConstantModifier ::= static // case 190: { btParser.setSym1(Flags.STATIC); break; } // // Rule 191: ConstantModifier ::= final // case 191: { btParser.setSym1(Flags.FINAL); break; } // // Rule 192: AbstractMethodDeclaration ::= AbstractMethodModifiersopt ResultType MethodDeclarator Throwsopt SEMICOLON // case 192: { Flags a = (Flags) btParser.getSym(1);//vj assert(btParser.getSym(2) == null); TypeNode b = (TypeNode) btParser.getSym(2); Object[] o = (Object []) btParser.getSym(3); Name c = (Name) o[0]; List d = (List) o[1]; Integer e = (Integer) o[2]; List f = (List) btParser.getSym(4); if (b.type() == ts.Void() && e.intValue() > 0) { // TODO: error!!! } btParser.setSym1(nf.MethodDecl(pos(btParser.getFirstToken(2), btParser.getLastToken(3)), a, array((TypeNode) b, pos(btParser.getFirstToken(2), btParser.getLastToken(2)), e.intValue()), c.toString(), d, f, null)); break; } // // Rule 193: AbstractMethodModifiers ::= AbstractMethodModifier // case 193: break; // // Rule 194: AbstractMethodModifiers ::= AbstractMethodModifiers AbstractMethodModifier // case 194: { Flags a = (Flags) btParser.getSym(1), b = (Flags) btParser.getSym(2); btParser.setSym1(a.set(b)); break; } // // Rule 195: AbstractMethodModifier ::= public // case 195: { btParser.setSym1(Flags.PUBLIC); break; } // // Rule 196: AbstractMethodModifier ::= abstract // case 196: { btParser.setSym1(Flags.ABSTRACT); break; } // // Rule 197: AnnotationTypeDeclaration ::= InterfaceModifiersopt AT interface identifier AnnotationTypeBody // case 197: bad_rule = 197; break; // // Rule 198: AnnotationTypeBody ::= LBRACE AnnotationTypeElementDeclarationsopt RBRACE // case 198: bad_rule = 198; break; // // Rule 199: AnnotationTypeElementDeclarations ::= AnnotationTypeElementDeclaration // case 199: bad_rule = 199; break; // // Rule 200: AnnotationTypeElementDeclarations ::= AnnotationTypeElementDeclarations AnnotationTypeElementDeclaration // case 200: bad_rule = 200; break; // // Rule 201: AnnotationTypeElementDeclaration ::= AbstractMethodModifiersopt Type identifier LPAREN RPAREN DefaultValueopt SEMICOLON // case 201: bad_rule = 201; break; // // Rule 202: AnnotationTypeElementDeclaration ::= ConstantDeclaration // case 202: bad_rule = 202; break; // // Rule 203: AnnotationTypeElementDeclaration ::= ClassDeclaration // case 203: bad_rule = 203; break; // // Rule 204: AnnotationTypeElementDeclaration ::= InterfaceDeclaration // case 204: bad_rule = 204; break; // // Rule 205: AnnotationTypeElementDeclaration ::= EnumDeclaration // case 205: bad_rule = 205; break; // // Rule 206: AnnotationTypeElementDeclaration ::= AnnotationTypeDeclaration // case 206: bad_rule = 206; break; // // Rule 207: AnnotationTypeElementDeclaration ::= SEMICOLON // case 207: bad_rule = 207; break; // // Rule 208: DefaultValue ::= default ElementValue // case 208: bad_rule = 208; break; // // Rule 209: Annotations ::= Annotation // case 209: bad_rule = 209; break; // // Rule 210: Annotations ::= Annotations Annotation // case 210: bad_rule = 210; break; // // Rule 211: Annotation ::= NormalAnnotation // case 211: bad_rule = 211; break; // // Rule 212: Annotation ::= MarkerAnnotation // case 212: bad_rule = 212; break; // // Rule 213: Annotation ::= SingleElementAnnotation // case 213: bad_rule = 213; break; // // Rule 214: NormalAnnotation ::= AT TypeName LPAREN ElementValuePairsopt RPAREN // case 214: bad_rule = 214; break; // // Rule 215: ElementValuePairs ::= ElementValuePair // case 215: bad_rule = 215; break; // // Rule 216: ElementValuePairs ::= ElementValuePairs COMMA ElementValuePair // case 216: bad_rule = 216; break; // // Rule 217: ElementValuePair ::= SimpleName EQUAL ElementValue // case 217: bad_rule = 217; break; // // Rule 218: SimpleName ::= identifier // case 218: { polyglot.lex.Identifier a = id(btParser.getToken(1)); btParser.setSym1(new Name(nf, ts, pos(), a.getIdentifier())); break; } // // Rule 219: ElementValue ::= ConditionalExpression // case 219: bad_rule = 219; break; // // Rule 220: ElementValue ::= Annotation // case 220: bad_rule = 220; break; // // Rule 221: ElementValue ::= ElementValueArrayInitializer // case 221: bad_rule = 221; break; // // Rule 222: ElementValueArrayInitializer ::= LBRACE ElementValuesopt ,opt RBRACE // case 222: bad_rule = 222; break; // // Rule 223: ElementValues ::= ElementValue // case 223: bad_rule = 223; break; // // Rule 224: ElementValues ::= ElementValues COMMA ElementValue // case 224: bad_rule = 224; break; // // Rule 225: MarkerAnnotation ::= AT TypeName // case 225: bad_rule = 225; break; // // Rule 226: SingleElementAnnotation ::= AT TypeName LPAREN ElementValue RPAREN // case 226: bad_rule = 226; break; // // Rule 227: ArrayInitializer ::= LBRACE VariableInitializersopt ,opt RBRACE // case 227: { List a = (List) btParser.getSym(2); if (a == null) btParser.setSym1(nf.ArrayInit(pos())); else btParser.setSym1(nf.ArrayInit(pos(), a)); break; } // // Rule 228: VariableInitializers ::= VariableInitializer // case 228: { List l = new TypedList(new LinkedList(), Expr.class, false); l.add(btParser.getSym(1)); btParser.setSym1(l); break; } // // Rule 229: VariableInitializers ::= VariableInitializers COMMA VariableInitializer // case 229: { List l = (List) btParser.getSym(1); l.add(btParser.getSym(3)); //btParser.setSym1(l); break; } // // Rule 230: Block ::= LBRACE BlockStatementsopt RBRACE // case 230: { List l = (List) btParser.getSym(2); btParser.setSym1(nf.Block(pos(), l)); break; } // // Rule 231: BlockStatements ::= BlockStatement // case 231: { List l = new TypedList(new LinkedList(), Stmt.class, false), l2 = (List) btParser.getSym(1); l.addAll(l2); btParser.setSym1(l); break; } // // Rule 232: BlockStatements ::= BlockStatements BlockStatement // case 232: { List l = (List) btParser.getSym(1), l2 = (List) btParser.getSym(2); l.addAll(l2); //btParser.setSym1(l); break; } // // Rule 233: BlockStatement ::= LocalVariableDeclarationStatement // case 233: break; // // Rule 234: BlockStatement ::= ClassDeclaration // case 234: { ClassDecl a = (ClassDecl) btParser.getSym(1); List l = new TypedList(new LinkedList(), Stmt.class, false); l.add(nf.LocalClassDecl(pos(), a)); btParser.setSym1(l); break; } // // Rule 235: BlockStatement ::= Statement // case 235: { List l = new TypedList(new LinkedList(), Stmt.class, false); l.add(btParser.getSym(1)); btParser.setSym1(l); break; } // // Rule 236: LocalVariableDeclarationStatement ::= LocalVariableDeclaration SEMICOLON // case 236: break; // // Rule 237: LocalVariableDeclaration ::= VariableModifiersopt Type VariableDeclarators // case 237: { Flags flags = (Flags) btParser.getSym(1); TypeNode a = (TypeNode) btParser.getSym(2); List b = (List) btParser.getSym(3); List l = new TypedList(new LinkedList(), LocalDecl.class, false); for (Iterator i = b.iterator(); i.hasNext(); ) { VarDeclarator d = (VarDeclarator) i.next(); l.add(nf.LocalDecl(pos(d), flags, array(a, pos(d), d.dims), d.name, d.init)); } btParser.setSym1(l); break; } // // Rule 238: Statement ::= StatementWithoutTrailingSubstatement // case 238: break; // // Rule 239: Statement ::= LabeledStatement // case 239: break; // // Rule 240: Statement ::= IfThenStatement // case 240: break; // // Rule 241: Statement ::= IfThenElseStatement // case 241: break; // // Rule 242: Statement ::= WhileStatement // case 242: break; // // Rule 243: Statement ::= ForStatement // case 243: break; // // Rule 244: StatementWithoutTrailingSubstatement ::= Block // case 244: break; // // Rule 245: StatementWithoutTrailingSubstatement ::= EmptyStatement // case 245: break; // // Rule 246: StatementWithoutTrailingSubstatement ::= ExpressionStatement // case 246: break; // // Rule 247: StatementWithoutTrailingSubstatement ::= AssertStatement // case 247: break; // // Rule 248: StatementWithoutTrailingSubstatement ::= SwitchStatement // case 248: break; // // Rule 249: StatementWithoutTrailingSubstatement ::= DoStatement // case 249: break; // // Rule 250: StatementWithoutTrailingSubstatement ::= BreakStatement // case 250: break; // // Rule 251: StatementWithoutTrailingSubstatement ::= ContinueStatement // case 251: break; // // Rule 252: StatementWithoutTrailingSubstatement ::= ReturnStatement // case 252: break; // // Rule 253: StatementWithoutTrailingSubstatement ::= SynchronizedStatement // case 253: break; // // Rule 254: StatementWithoutTrailingSubstatement ::= ThrowStatement // case 254: break; // // Rule 255: StatementWithoutTrailingSubstatement ::= TryStatement // case 255: break; // // Rule 256: StatementNoShortIf ::= StatementWithoutTrailingSubstatement // case 256: break; // // Rule 257: StatementNoShortIf ::= LabeledStatementNoShortIf // case 257: break; // // Rule 258: StatementNoShortIf ::= IfThenElseStatementNoShortIf // case 258: break; // // Rule 259: StatementNoShortIf ::= WhileStatementNoShortIf // case 259: break; // // Rule 260: StatementNoShortIf ::= ForStatementNoShortIf // case 260: break; // // Rule 261: IfThenStatement ::= if LPAREN Expression RPAREN Statement // case 261: { Expr a = (Expr) btParser.getSym(3); Stmt b = (Stmt) btParser.getSym(5); btParser.setSym1(nf.If(pos(), a, b)); break; } // // Rule 262: IfThenElseStatement ::= if LPAREN Expression RPAREN StatementNoShortIf else Statement // case 262: { Expr a = (Expr) btParser.getSym(3); Stmt b = (Stmt) btParser.getSym(5); Stmt c = (Stmt) btParser.getSym(7); btParser.setSym1(nf.If(pos(), a, b, c)); break; } // // Rule 263: IfThenElseStatementNoShortIf ::= if LPAREN Expression RPAREN StatementNoShortIf else StatementNoShortIf // case 263: { Expr a = (Expr) btParser.getSym(3); Stmt b = (Stmt) btParser.getSym(5); Stmt c = (Stmt) btParser.getSym(7); btParser.setSym1(nf.If(pos(), a, b, c)); break; } // // Rule 264: EmptyStatement ::= SEMICOLON // case 264: { btParser.setSym1(nf.Empty(pos())); break; } // // Rule 265: LabeledStatement ::= identifier COLON Statement // case 265: { polyglot.lex.Identifier a = id(btParser.getToken(1)); Stmt b = (Stmt) btParser.getSym(3); btParser.setSym1(nf.Labeled(pos(), a.getIdentifier(), b)); break; } // // Rule 266: LabeledStatementNoShortIf ::= identifier COLON StatementNoShortIf // case 266: { polyglot.lex.Identifier a = id(btParser.getToken(1)); Stmt b = (Stmt) btParser.getSym(3); btParser.setSym1(nf.Labeled(pos(), a.getIdentifier(), b)); break; } // // Rule 267: ExpressionStatement ::= StatementExpression SEMICOLON // case 267: { Expr a = (Expr) btParser.getSym(1); btParser.setSym1(nf.Eval(pos(), a)); break; } // // Rule 268: StatementExpression ::= Assignment // case 268: break; // // Rule 269: StatementExpression ::= PreIncrementExpression // case 269: break; // // Rule 270: StatementExpression ::= PreDecrementExpression // case 270: break; // // Rule 271: StatementExpression ::= PostIncrementExpression // case 271: break; // // Rule 272: StatementExpression ::= PostDecrementExpression // case 272: break; // // Rule 273: StatementExpression ::= MethodInvocation // case 273: break; // // Rule 274: StatementExpression ::= ClassInstanceCreationExpression // case 274: break; // // Rule 275: AssertStatement ::= assert Expression SEMICOLON // case 275: { Expr a = (Expr) btParser.getSym(2); btParser.setSym1(nf.Assert(pos(), a)); break; } // // Rule 276: AssertStatement ::= assert Expression COLON Expression SEMICOLON // case 276: { Expr a = (Expr) btParser.getSym(2), b = (Expr) btParser.getSym(4); btParser.setSym1(nf.Assert(pos(), a, b)); break; } // // Rule 277: SwitchStatement ::= switch LPAREN Expression RPAREN SwitchBlock // case 277: { Expr a = (Expr) btParser.getSym(3); List b = (List) btParser.getSym(5); btParser.setSym1(nf.Switch(pos(), a, b)); break; } // // Rule 278: SwitchBlock ::= LBRACE SwitchBlockStatementGroupsopt SwitchLabelsopt RBRACE // case 278: { List l = (List) btParser.getSym(2), l2 = (List) btParser.getSym(3); l.addAll(l2); // btParser.setSym1(l); break; } // // Rule 279: SwitchBlockStatementGroups ::= SwitchBlockStatementGroup // case 279: break; // // Rule 280: SwitchBlockStatementGroups ::= SwitchBlockStatementGroups SwitchBlockStatementGroup // case 280: { List l = (List) btParser.getSym(1), l2 = (List) btParser.getSym(2); l.addAll(l2); // btParser.setSym1(l); break; } // // Rule 281: SwitchBlockStatementGroup ::= SwitchLabels BlockStatements // case 281: { List l = new TypedList(new LinkedList(), SwitchElement.class, false); List l1 = (List) btParser.getSym(1), l2 = (List) btParser.getSym(2); l.addAll(l1); l.add(nf.SwitchBlock(pos(), l2)); btParser.setSym1(l); break; } // // Rule 282: SwitchLabels ::= SwitchLabel // case 282: { List l = new TypedList(new LinkedList(), Case.class, false); l.add(btParser.getSym(1)); btParser.setSym1(l); break; } // // Rule 283: SwitchLabels ::= SwitchLabels SwitchLabel // case 283: { List l = (List) btParser.getSym(1); l.add(btParser.getSym(2)); //btParser.setSym1(l); break; } // // Rule 284: SwitchLabel ::= case ConstantExpression COLON // case 284: { Expr a = (Expr) btParser.getSym(2); btParser.setSym1(nf.Case(pos(), a)); break; } // // Rule 285: SwitchLabel ::= case EnumConstant COLON // case 285: bad_rule = 285; break; // // Rule 286: SwitchLabel ::= default COLON // case 286: { btParser.setSym1(nf.Default(pos())); break; } // // Rule 287: EnumConstant ::= identifier // case 287: bad_rule = 287; break; // // Rule 288: WhileStatement ::= while LPAREN Expression RPAREN Statement // case 288: { Expr a = (Expr) btParser.getSym(3); Stmt b = (Stmt) btParser.getSym(5); btParser.setSym1(nf.While(pos(), a, b)); break; } // // Rule 289: WhileStatementNoShortIf ::= while LPAREN Expression RPAREN StatementNoShortIf // case 289: { Expr a = (Expr) btParser.getSym(3); Stmt b = (Stmt) btParser.getSym(5); btParser.setSym1(nf.While(pos(), a, b)); break; } // // Rule 290: DoStatement ::= do Statement while LPAREN Expression RPAREN SEMICOLON // case 290: { Stmt a = (Stmt) btParser.getSym(2); Expr b = (Expr) btParser.getSym(5); btParser.setSym1(nf.Do(pos(), a, b)); break; } // // Rule 291: ForStatement ::= BasicForStatement // case 291: break; // // Rule 292: ForStatement ::= EnhancedForStatement // case 292: break; // // Rule 293: BasicForStatement ::= for LPAREN ForInitopt SEMICOLON Expressionopt SEMICOLON ForUpdateopt RPAREN Statement // case 293: { List a = (List) btParser.getSym(3); Expr b = (Expr) btParser.getSym(5); List c = (List) btParser.getSym(7); Stmt d = (Stmt) btParser.getSym(9); btParser.setSym1(nf.For(pos(), a, b, c, d)); break; } // // Rule 294: ForStatementNoShortIf ::= for LPAREN ForInitopt SEMICOLON Expressionopt SEMICOLON ForUpdateopt RPAREN StatementNoShortIf // case 294: { List a = (List) btParser.getSym(3); Expr b = (Expr) btParser.getSym(5); List c = (List) btParser.getSym(7); Stmt d = (Stmt) btParser.getSym(9); btParser.setSym1(nf.For(pos(), a, b, c, d)); break; } // // Rule 295: ForInit ::= StatementExpressionList // case 295: break; // // Rule 296: ForInit ::= LocalVariableDeclaration // case 296: { List l = new TypedList(new LinkedList(), ForInit.class, false), l2 = (List) btParser.getSym(1); l.addAll(l2); //btParser.setSym1(l); break; } // // Rule 297: ForUpdate ::= StatementExpressionList // case 297: break; // // Rule 298: StatementExpressionList ::= StatementExpression // case 298: { List l = new TypedList(new LinkedList(), Eval.class, false); Expr a = (Expr) btParser.getSym(1); l.add(nf.Eval(pos(), a)); btParser.setSym1(l); break; } // // Rule 299: StatementExpressionList ::= StatementExpressionList COMMA StatementExpression // case 299: { List l = (List) btParser.getSym(1); Expr a = (Expr) btParser.getSym(3); l.add(nf.Eval(pos(), a)); //btParser.setSym1(l); break; } // // Rule 300: BreakStatement ::= break identifieropt SEMICOLON // case 300: { Name a = (Name) btParser.getSym(2); if (a == null) btParser.setSym1(nf.Break(pos())); else btParser.setSym1(nf.Break(pos(), a.toString())); break; } // // Rule 301: ContinueStatement ::= continue identifieropt SEMICOLON // case 301: { Name a = (Name) btParser.getSym(2); if (a == null) btParser.setSym1(nf.Continue(pos())); else btParser.setSym1(nf.Continue(pos(), a.toString())); break; } // // Rule 302: ReturnStatement ::= return Expressionopt SEMICOLON // case 302: { Expr a = (Expr) btParser.getSym(2); btParser.setSym1(nf.Return(pos(), a)); break; } // // Rule 303: ThrowStatement ::= throw Expression SEMICOLON // case 303: { Expr a = (Expr) btParser.getSym(2); btParser.setSym1(nf.Throw(pos(), a)); break; } // // Rule 304: SynchronizedStatement ::= synchronized LPAREN Expression RPAREN Block // case 304: { Expr a = (Expr) btParser.getSym(3); Block b = (Block) btParser.getSym(5); btParser.setSym1(nf.Synchronized(pos(), a, b)); break; } // // Rule 305: TryStatement ::= try Block Catches // case 305: { Block a = (Block) btParser.getSym(2); List b = (List) btParser.getSym(3); btParser.setSym1(nf.Try(pos(), a, b)); break; } // // Rule 306: TryStatement ::= try Block Catchesopt Finally // case 306: { Block a = (Block) btParser.getSym(2); List b = (List) btParser.getSym(3); Block c = (Block) btParser.getSym(4); btParser.setSym1(nf.Try(pos(), a, b, c)); break; } // // Rule 307: Catches ::= CatchClause // case 307: { List l = new TypedList(new LinkedList(), Catch.class, false); l.add(btParser.getSym(1)); btParser.setSym1(l); break; } // // Rule 308: Catches ::= Catches CatchClause // case 308: { List l = (List) btParser.getSym(1); l.add(btParser.getSym(2)); //btParser.setSym1(l); break; } // // Rule 309: CatchClause ::= catch LPAREN FormalParameter RPAREN Block // case 309: { Formal a = (Formal) btParser.getSym(3); Block b = (Block) btParser.getSym(5); btParser.setSym1(nf.Catch(pos(), a, b)); break; } // // Rule 310: Finally ::= finally Block // case 310: { btParser.setSym1(btParser.getSym(2)); break; } // // Rule 311: Primary ::= PrimaryNoNewArray // case 311: break; // // Rule 312: Primary ::= ArrayCreationExpression // case 312: break; // // Rule 313: PrimaryNoNewArray ::= Literal // case 313: break; // // Rule 314: PrimaryNoNewArray ::= Type DOT class // case 314: { Object o = btParser.getSym(1); if (o instanceof Name) { Name a = (Name) o; btParser.setSym1(nf.ClassLit(pos(), a.toType())); } else if (o instanceof TypeNode) { TypeNode a = (TypeNode) o; btParser.setSym1(nf.ClassLit(pos(), a)); } else if (o instanceof CanonicalTypeNode) { CanonicalTypeNode a = (CanonicalTypeNode) o; btParser.setSym1(nf.ClassLit(pos(), a)); } else assert(false); break; } // // Rule 315: PrimaryNoNewArray ::= void DOT class // case 315: { btParser.setSym1(nf.ClassLit(pos(), nf.CanonicalTypeNode(pos(btParser.getToken(1)), ts.Void()))); break; } // // Rule 316: PrimaryNoNewArray ::= this // case 316: { btParser.setSym1(nf.This(pos())); break; } // // Rule 317: PrimaryNoNewArray ::= ClassName DOT this // case 317: { Name a = (Name) btParser.getSym(1); btParser.setSym1(nf.This(pos(), a.toType())); break; } // // Rule 318: PrimaryNoNewArray ::= LPAREN Expression RPAREN // case 318: { btParser.setSym1(btParser.getSym(2)); break; } // // Rule 319: PrimaryNoNewArray ::= ClassInstanceCreationExpression // case 319: break; // // Rule 320: PrimaryNoNewArray ::= FieldAccess // case 320: break; // // Rule 321: PrimaryNoNewArray ::= MethodInvocation // case 321: break; // // Rule 322: PrimaryNoNewArray ::= ArrayAccess // case 322: break; // // Rule 323: Literal ::= IntegerLiteral // case 323: { // TODO: remove any prefix (such as 0x) polyglot.lex.IntegerLiteral a = int_lit(btParser.getToken(1), 10); btParser.setSym1(nf.IntLit(pos(), IntLit.INT, a.getValue().intValue())); break; } // // Rule 324: Literal ::= LongLiteral // case 324: { // TODO: remove any suffix (such as L) or prefix (such as 0x) polyglot.lex.LongLiteral a = long_lit(btParser.getToken(1), 10); btParser.setSym1(nf.IntLit(pos(), IntLit.LONG, a.getValue().longValue())); break; } // // Rule 325: Literal ::= FloatingPointLiteral // case 325: { // TODO: remove any suffix (such as F) polyglot.lex.FloatLiteral a = float_lit(btParser.getToken(1)); btParser.setSym1(nf.FloatLit(pos(), FloatLit.FLOAT, a.getValue().floatValue())); break; } // // Rule 326: Literal ::= DoubleLiteral // case 326: { // TODO: remove any suffix (such as D) polyglot.lex.DoubleLiteral a = double_lit(btParser.getToken(1)); btParser.setSym1(nf.FloatLit(pos(), FloatLit.DOUBLE, a.getValue().doubleValue())); break; } // // Rule 327: Literal ::= BooleanLiteral // case 327: { polyglot.lex.BooleanLiteral a = boolean_lit(btParser.getToken(1)); btParser.setSym1(nf.BooleanLit(pos(), a.getValue().booleanValue())); break; } // // Rule 328: Literal ::= CharacterLiteral // case 328: { polyglot.lex.CharacterLiteral a = char_lit(btParser.getToken(1)); btParser.setSym1(nf.CharLit(pos(), a.getValue().charValue())); break; } // // Rule 329: Literal ::= StringLiteral // case 329: { String s = prsStream.getName(btParser.getToken(1)); btParser.setSym1(nf.StringLit(pos(), s.substring(1, s.length() - 2))); break; } // // Rule 330: Literal ::= null // case 330: { btParser.setSym1(nf.NullLit(pos())); break; } // // Rule 331: BooleanLiteral ::= true // case 331: break; // // Rule 332: BooleanLiteral ::= false // case 332: break; // // Rule 333: ClassInstanceCreationExpression ::= new ClassOrInterfaceType LPAREN ArgumentListopt RPAREN ClassBodyopt // case 333: {//vj assert(btParser.getSym(2) == null); TypeNode a = (TypeNode) btParser.getSym(2);//vj assert(btParser.getSym(4) == null); List b = (List) btParser.getSym(4); ClassBody c = (ClassBody) btParser.getSym(6); if (c == null) btParser.setSym1(nf.New(pos(), a, b)); else btParser.setSym1(nf.New(pos(), a, b, c)); break; } // // Rule 334: ClassInstanceCreationExpression ::= Primary DOT new identifier LPAREN ArgumentListopt RPAREN ClassBodyopt // case 334: { Expr a = (Expr) btParser.getSym(1);//vj assert(btParser.getSym(2) == null); Name b = new Name(nf, ts, pos(), id(btParser.getToken(4)).getIdentifier());//vj assert(btParser.getSym(4) == null); List c = (List) btParser.getSym(6); ClassBody d = (ClassBody) btParser.getSym(8); if (d == null) btParser.setSym1(nf.New(pos(), a, b.toType(), c)); else btParser.setSym1(nf.New(pos(), a, b.toType(), c, d)); break; } // // Rule 335: ClassInstanceCreationExpression ::= AmbiguousName DOT new identifier LPAREN ArgumentListopt RPAREN ClassBodyopt // case 335: { Name a = (Name) btParser.getSym(1);//vj assert(btParser.getSym(4) == null); Name b = new Name(nf, ts, pos(), id(btParser.getToken(4)).getIdentifier());//vj assert(btParser.getSym(6) == null); List c = (List) btParser.getSym(6); ClassBody d = (ClassBody) btParser.getSym(8); if (d == null) btParser.setSym1(nf.New(pos(), a.toExpr(), b.toType(), c)); else btParser.setSym1(nf.New(pos(), a.toExpr(), b.toType(), c, d)); break; } // // Rule 336: ArgumentList ::= Expression // case 336: { List l = new TypedList(new LinkedList(), Expr.class, false); l.add(btParser.getSym(1)); btParser.setSym1(l); break; } // // Rule 337: ArgumentList ::= ArgumentList COMMA Expression // case 337: { List l = (List) btParser.getSym(1); l.add(btParser.getSym(3)); //btParser.setSym1(l); break; } // // Rule 338: DimExprs ::= DimExpr // case 338: { List l = new TypedList(new LinkedList(), Expr.class, false); l.add(btParser.getSym(1)); btParser.setSym1(l); break; } // // Rule 339: DimExprs ::= DimExprs DimExpr // case 339: { List l = (List) btParser.getSym(1); l.add(btParser.getSym(2)); //btParser.setSym1(l); break; } // // Rule 340: DimExpr ::= LBRACKET Expression RBRACKET // case 340: { Expr a = (Expr) btParser.getSym(2); btParser.setSym1(a.position(pos())); break; } // // Rule 341: Dims ::= LBRACKET RBRACKET // case 341: { btParser.setSym1(new Integer(1)); break; } // // Rule 342: Dims ::= Dims LBRACKET RBRACKET // case 342: { Integer a = (Integer) btParser.getSym(1); btParser.setSym1(new Integer(a.intValue() + 1)); break; } // // Rule 343: FieldAccess ::= Primary DOT identifier // case 343: { Expr a = (Expr) btParser.getSym(1); polyglot.lex.Identifier b = id(btParser.getToken(3)); btParser.setSym1(nf.Field(pos(), a, b.getIdentifier())); break; } // // Rule 344: FieldAccess ::= super DOT identifier // case 344: { polyglot.lex.Identifier a = id(btParser.getToken(3)); btParser.setSym1(nf.Field(pos(btParser.getLastToken()), nf.Super(pos(btParser.getFirstToken())), a.getIdentifier())); break; } // // Rule 345: FieldAccess ::= ClassName DOT super DOT identifier // case 345: { Name a = (Name) btParser.getSym(1); polyglot.lex.Identifier b = id(btParser.getToken(3)); btParser.setSym1(nf.Field(pos(btParser.getLastToken()), nf.Super(pos(btParser.getFirstToken(3)), a.toType()), b.getIdentifier())); break; } // // Rule 346: MethodInvocation ::= MethodName LPAREN ArgumentListopt RPAREN // case 346: { Name a = (Name) btParser.getSym(1); List b = (List) btParser.getSym(3); btParser.setSym1(nf.Call(pos(), a.prefix == null ? null : a.prefix.toReceiver(), a.name, b)); break; } // // Rule 347: MethodInvocation ::= Primary DOT identifier LPAREN ArgumentListopt RPAREN // case 347: { Expr a = (Expr) btParser.getSym(1);//vj assert(btParser.getSym(3) == null); polyglot.lex.Identifier b = id(btParser.getToken(3)); List c = (List) btParser.getSym(5); btParser.setSym1(nf.Call(pos(), a, b.getIdentifier(), c)); break; } // // Rule 348: MethodInvocation ::= super DOT identifier LPAREN ArgumentListopt RPAREN // case 348: {//vj assert(btParser.getSym(3) == null); polyglot.lex.Identifier b = id(btParser.getToken(3)); List c = (List) btParser.getSym(5); btParser.setSym1(nf.Call(pos(), nf.Super(pos(btParser.getFirstToken())), b.getIdentifier(), c)); break; } // // Rule 349: MethodInvocation ::= ClassName DOT super DOT identifier LPAREN ArgumentListopt RPAREN // case 349: { Name a = (Name) btParser.getSym(1);//vj assert(btParser.getSym(5) == null); polyglot.lex.Identifier b = id(btParser.getToken(5)); List c = (List) btParser.getSym(7); btParser.setSym1(nf.Call(pos(), nf.Super(pos(btParser.getFirstToken(3)), a.toType()), b.getIdentifier(), c)); break; } // // Rule 350: PostfixExpression ::= Primary // case 350: break; // // Rule 351: PostfixExpression ::= ExpressionName // case 351: { Name a = (Name) btParser.getSym(1); btParser.setSym1(a.toExpr()); break; } // // Rule 352: PostfixExpression ::= PostIncrementExpression // case 352: break; // // Rule 353: PostfixExpression ::= PostDecrementExpression // case 353: break; // // Rule 354: PostIncrementExpression ::= PostfixExpression PLUS_PLUS // case 354: { Expr a = (Expr) btParser.getSym(1); btParser.setSym1(nf.Unary(pos(), a, Unary.POST_INC)); break; } // // Rule 355: PostDecrementExpression ::= PostfixExpression MINUS_MINUS // case 355: { Expr a = (Expr) btParser.getSym(1); btParser.setSym1(nf.Unary(pos(), a, Unary.POST_DEC)); break; } // // Rule 356: UnaryExpression ::= PreIncrementExpression // case 356: break; // // Rule 357: UnaryExpression ::= PreDecrementExpression // case 357: break; // // Rule 358: UnaryExpression ::= PLUS UnaryExpression // case 358: { Expr a = (Expr) btParser.getSym(2); btParser.setSym1(nf.Unary(pos(), Unary.POS, a)); break; } // // Rule 359: UnaryExpression ::= MINUS UnaryExpression // case 359: { Expr a = (Expr) btParser.getSym(2); btParser.setSym1(nf.Unary(pos(), Unary.NEG, a)); break; } // // Rule 361: PreIncrementExpression ::= PLUS_PLUS UnaryExpression // case 361: { Expr a = (Expr) btParser.getSym(2); btParser.setSym1(nf.Unary(pos(), Unary.PRE_INC, a)); break; } // // Rule 362: PreDecrementExpression ::= MINUS_MINUS UnaryExpression // case 362: { Expr a = (Expr) btParser.getSym(2); btParser.setSym1(nf.Unary(pos(), Unary.PRE_DEC, a)); break; } // // Rule 363: UnaryExpressionNotPlusMinus ::= PostfixExpression // case 363: break; // // Rule 364: UnaryExpressionNotPlusMinus ::= TWIDDLE UnaryExpression // case 364: { Expr a = (Expr) btParser.getSym(2); btParser.setSym1(nf.Unary(pos(), Unary.BIT_NOT, a)); break; } // // Rule 365: UnaryExpressionNotPlusMinus ::= NOT UnaryExpression // case 365: { Expr a = (Expr) btParser.getSym(2); btParser.setSym1(nf.Unary(pos(), Unary.NOT, a)); break; } // // Rule 367: MultiplicativeExpression ::= UnaryExpression // case 367: break; // // Rule 368: MultiplicativeExpression ::= MultiplicativeExpression MULTIPLY UnaryExpression // case 368: { Expr a = (Expr) btParser.getSym(1), b = (Expr) btParser.getSym(3); btParser.setSym1(nf.Binary(pos(), a, Binary.MUL, b)); break; } // // Rule 369: MultiplicativeExpression ::= MultiplicativeExpression DIVIDE UnaryExpression // case 369: { Expr a = (Expr) btParser.getSym(1), b = (Expr) btParser.getSym(3); btParser.setSym1(nf.Binary(pos(), a, Binary.DIV, b)); break; } // // Rule 370: MultiplicativeExpression ::= MultiplicativeExpression REMAINDER UnaryExpression // case 370: { Expr a = (Expr) btParser.getSym(1), b = (Expr) btParser.getSym(3); btParser.setSym1(nf.Binary(pos(), a, Binary.MOD, b)); break; } // // Rule 371: AdditiveExpression ::= MultiplicativeExpression // case 371: break; // // Rule 372: AdditiveExpression ::= AdditiveExpression PLUS MultiplicativeExpression // case 372: { Expr a = (Expr) btParser.getSym(1), b = (Expr) btParser.getSym(3); btParser.setSym1(nf.Binary(pos(), a, Binary.ADD, b)); break; } // // Rule 373: AdditiveExpression ::= AdditiveExpression MINUS MultiplicativeExpression // case 373: { Expr a = (Expr) btParser.getSym(1), b = (Expr) btParser.getSym(3); btParser.setSym1(nf.Binary(pos(), a, Binary.SUB, b)); break; } // // Rule 374: ShiftExpression ::= AdditiveExpression // case 374: break; // // Rule 375: ShiftExpression ::= ShiftExpression LEFT_SHIFT AdditiveExpression // case 375: { Expr a = (Expr) btParser.getSym(1), b = (Expr) btParser.getSym(3); btParser.setSym1(nf.Binary(pos(), a, Binary.SHL, b)); break; } // // Rule 376: ShiftExpression ::= ShiftExpression GREATER GREATER AdditiveExpression // case 376: { // TODO: make sure that there is no space between the ">" signs Expr a = (Expr) btParser.getSym(1), b = (Expr) btParser.getSym(4); btParser.setSym1(nf.Binary(pos(), a, Binary.SHR, b)); break; } // // Rule 377: ShiftExpression ::= ShiftExpression GREATER GREATER GREATER AdditiveExpression // case 377: { // TODO: make sure that there is no space between the ">" signs Expr a = (Expr) btParser.getSym(1), b = (Expr) btParser.getSym(5); btParser.setSym1(nf.Binary(pos(), a, Binary.USHR, b)); break; } // // Rule 378: RelationalExpression ::= ShiftExpression // case 378: break; // // Rule 379: RelationalExpression ::= RelationalExpression LESS ShiftExpression // case 379: { Expr a = (Expr) btParser.getSym(1), b = (Expr) btParser.getSym(3); btParser.setSym1(nf.Binary(pos(), a, Binary.LT, b)); break; } // // Rule 380: RelationalExpression ::= RelationalExpression GREATER ShiftExpression // case 380: { Expr a = (Expr) btParser.getSym(1), b = (Expr) btParser.getSym(3); btParser.setSym1(nf.Binary(pos(), a, Binary.GT, b)); break; } // // Rule 381: RelationalExpression ::= RelationalExpression LESS_EQUAL ShiftExpression // case 381: { Expr a = (Expr) btParser.getSym(1), b = (Expr) btParser.getSym(3); btParser.setSym1(nf.Binary(pos(), a, Binary.LE, b)); break; } // // Rule 382: RelationalExpression ::= RelationalExpression GREATER EQUAL ShiftExpression // case 382: { Expr a = (Expr) btParser.getSym(1), b = (Expr) btParser.getSym(4); btParser.setSym1(nf.Binary(pos(), a, Binary.GE, b)); break; } // // Rule 383: EqualityExpression ::= RelationalExpression // case 383: break; // // Rule 384: EqualityExpression ::= EqualityExpression EQUAL_EQUAL RelationalExpression // case 384: { Expr a = (Expr) btParser.getSym(1), b = (Expr) btParser.getSym(3); btParser.setSym1(nf.Binary(pos(), a, Binary.EQ, b)); break; } // // Rule 385: EqualityExpression ::= EqualityExpression NOT_EQUAL RelationalExpression // case 385: { Expr a = (Expr) btParser.getSym(1), b = (Expr) btParser.getSym(3); btParser.setSym1(nf.Binary(pos(), a, Binary.NE, b)); break; } // // Rule 386: AndExpression ::= EqualityExpression // case 386: break; // // Rule 387: AndExpression ::= AndExpression AND EqualityExpression // case 387: { Expr a = (Expr) btParser.getSym(1), b = (Expr) btParser.getSym(3); btParser.setSym1(nf.Binary(pos(), a, Binary.BIT_AND, b)); break; } // // Rule 388: ExclusiveOrExpression ::= AndExpression // case 388: break; // // Rule 389: ExclusiveOrExpression ::= ExclusiveOrExpression XOR AndExpression // case 389: { Expr a = (Expr) btParser.getSym(1), b = (Expr) btParser.getSym(3); btParser.setSym1(nf.Binary(pos(), a, Binary.BIT_XOR, b)); break; } // // Rule 390: InclusiveOrExpression ::= ExclusiveOrExpression // case 390: break; // // Rule 391: InclusiveOrExpression ::= InclusiveOrExpression OR ExclusiveOrExpression // case 391: { Expr a = (Expr) btParser.getSym(1), b = (Expr) btParser.getSym(3); btParser.setSym1(nf.Binary(pos(), a, Binary.BIT_OR, b)); break; } // // Rule 392: ConditionalAndExpression ::= InclusiveOrExpression // case 392: break; // // Rule 393: ConditionalAndExpression ::= ConditionalAndExpression AND_AND InclusiveOrExpression // case 393: { Expr a = (Expr) btParser.getSym(1), b = (Expr) btParser.getSym(3); btParser.setSym1(nf.Binary(pos(), a, Binary.COND_AND, b)); break; } // // Rule 394: ConditionalOrExpression ::= ConditionalAndExpression // case 394: break; // // Rule 395: ConditionalOrExpression ::= ConditionalOrExpression OR_OR ConditionalAndExpression // case 395: { Expr a = (Expr) btParser.getSym(1), b = (Expr) btParser.getSym(3); btParser.setSym1(nf.Binary(pos(), a, Binary.COND_OR, b)); break; } // // Rule 396: ConditionalExpression ::= ConditionalOrExpression // case 396: break; // // Rule 397: ConditionalExpression ::= ConditionalOrExpression QUESTION Expression COLON ConditionalExpression // case 397: { Expr a = (Expr) btParser.getSym(1), b = (Expr) btParser.getSym(3), c = (Expr) btParser.getSym(5); btParser.setSym1(nf.Conditional(pos(), a, b, c)); break; } // // Rule 398: AssignmentExpression ::= ConditionalExpression // case 398: break; // // Rule 399: AssignmentExpression ::= Assignment // case 399: break; // // Rule 400: Assignment ::= LeftHandSide AssignmentOperator AssignmentExpression // case 400: { Expr a = (Expr) btParser.getSym(1); Assign.Operator b = (Assign.Operator) btParser.getSym(2); Expr c = (Expr) btParser.getSym(3); btParser.setSym1(nf.Assign(pos(), a, b, c)); break; } // // Rule 401: LeftHandSide ::= ExpressionName // case 401: { Name a = (Name) btParser.getSym(1); btParser.setSym1(a.toExpr()); break; } // // Rule 402: LeftHandSide ::= FieldAccess // case 402: break; // // Rule 403: LeftHandSide ::= ArrayAccess // case 403: break; // // Rule 404: AssignmentOperator ::= EQUAL // case 404: { btParser.setSym1(Assign.ASSIGN); break; } // // Rule 405: AssignmentOperator ::= MULTIPLY_EQUAL // case 405: { btParser.setSym1(Assign.MUL_ASSIGN); break; } // // Rule 406: AssignmentOperator ::= DIVIDE_EQUAL // case 406: { btParser.setSym1(Assign.DIV_ASSIGN); break; } // // Rule 407: AssignmentOperator ::= REMAINDER_EQUAL // case 407: { btParser.setSym1(Assign.MOD_ASSIGN); break; } // // Rule 408: AssignmentOperator ::= PLUS_EQUAL // case 408: { btParser.setSym1(Assign.ADD_ASSIGN); break; } // // Rule 409: AssignmentOperator ::= MINUS_EQUAL // case 409: { btParser.setSym1(Assign.SUB_ASSIGN); break; } // // Rule 410: AssignmentOperator ::= LEFT_SHIFT_EQUAL // case 410: { btParser.setSym1(Assign.SHL_ASSIGN); break; } // // Rule 411: AssignmentOperator ::= GREATER GREATER EQUAL // case 411: { // TODO: make sure that there is no space between the ">" signs btParser.setSym1(Assign.SHR_ASSIGN); break; } // // Rule 412: AssignmentOperator ::= GREATER GREATER GREATER EQUAL // case 412: { // TODO: make sure that there is no space between the ">" signs btParser.setSym1(Assign.USHR_ASSIGN); break; } // // Rule 413: AssignmentOperator ::= AND_EQUAL // case 413: { btParser.setSym1(Assign.BIT_AND_ASSIGN); break; } // // Rule 414: AssignmentOperator ::= XOR_EQUAL // case 414: { btParser.setSym1(Assign.BIT_XOR_ASSIGN); break; } // // Rule 415: AssignmentOperator ::= OR_EQUAL // case 415: { btParser.setSym1(Assign.BIT_OR_ASSIGN); break; } // // Rule 416: Expression ::= AssignmentExpression // case 416: break; // // Rule 417: ConstantExpression ::= Expression // case 417: break; // // Rule 418: Dimsopt ::= // case 418: { btParser.setSym1(new Integer(0)); break; } // // Rule 419: Dimsopt ::= Dims // case 419: break; // // Rule 420: Catchesopt ::= // case 420: { btParser.setSym1(new TypedList(new LinkedList(), Catch.class, false)); break; } // // Rule 421: Catchesopt ::= Catches // case 421: break; // // Rule 422: identifieropt ::= // case 422: btParser.setSym1(null); break; // // Rule 423: identifieropt ::= identifier // case 423: { polyglot.lex.Identifier a = id(btParser.getToken(1)); btParser.setSym1(new Name(nf, ts, pos(), a.getIdentifier())); break; } // // Rule 424: ForUpdateopt ::= // case 424: { btParser.setSym1(new TypedList(new LinkedList(), ForUpdate.class, false)); break; } // // Rule 425: ForUpdateopt ::= ForUpdate // case 425: break; // // Rule 426: Expressionopt ::= // case 426: btParser.setSym1(null); break; // // Rule 427: Expressionopt ::= Expression // case 427: break; // // Rule 428: ForInitopt ::= // case 428: { btParser.setSym1(new TypedList(new LinkedList(), ForInit.class, false)); break; } // // Rule 429: ForInitopt ::= ForInit // case 429: break; // // Rule 430: SwitchLabelsopt ::= // case 430: { btParser.setSym1(new TypedList(new LinkedList(), Case.class, false)); break; } // // Rule 431: SwitchLabelsopt ::= SwitchLabels // case 431: break; // // Rule 432: SwitchBlockStatementGroupsopt ::= // case 432: { btParser.setSym1(new TypedList(new LinkedList(), SwitchElement.class, false)); break; } // // Rule 433: SwitchBlockStatementGroupsopt ::= SwitchBlockStatementGroups // case 433: break; // // Rule 434: VariableModifiersopt ::= // case 434: { btParser.setSym1(Flags.NONE); break; } // // Rule 435: VariableModifiersopt ::= VariableModifiers // case 435: break; // // Rule 436: VariableInitializersopt ::= // case 436: btParser.setSym1(null); break; // // Rule 437: VariableInitializersopt ::= VariableInitializers // case 437: break; // // Rule 438: ElementValuesopt ::= // case 438: btParser.setSym1(null); break; // // Rule 439: ElementValuesopt ::= ElementValues // case 439: bad_rule = 439; break; // // Rule 440: ElementValuePairsopt ::= // case 440: btParser.setSym1(null); break; // // Rule 441: ElementValuePairsopt ::= ElementValuePairs // case 441: bad_rule = 441; break; // // Rule 442: DefaultValueopt ::= // case 442: btParser.setSym1(null); break; // // Rule 443: DefaultValueopt ::= DefaultValue // case 443: break; // // Rule 444: AnnotationTypeElementDeclarationsopt ::= // case 444: btParser.setSym1(null); break; // // Rule 445: AnnotationTypeElementDeclarationsopt ::= AnnotationTypeElementDeclarations // case 445: bad_rule = 445; break; // // Rule 446: AbstractMethodModifiersopt ::= // case 446: { btParser.setSym1(Flags.NONE); break; } // // Rule 447: AbstractMethodModifiersopt ::= AbstractMethodModifiers // case 447: break; // // Rule 448: ConstantModifiersopt ::= // case 448: { btParser.setSym1(Flags.NONE); break; } // // Rule 449: ConstantModifiersopt ::= ConstantModifiers // case 449: break; // // Rule 450: InterfaceMemberDeclarationsopt ::= // case 450: { btParser.setSym1(new TypedList(new LinkedList(), ClassMember.class, false)); break; } // // Rule 451: InterfaceMemberDeclarationsopt ::= InterfaceMemberDeclarations // case 451: break; // // Rule 452: ExtendsInterfacesopt ::= // case 452: { btParser.setSym1(new TypedList(new LinkedList(), TypeNode.class, false)); break; } // // Rule 453: ExtendsInterfacesopt ::= ExtendsInterfaces // case 453: break; // // Rule 454: InterfaceModifiersopt ::= // case 454: { btParser.setSym1(Flags.NONE); break; } // // Rule 455: InterfaceModifiersopt ::= InterfaceModifiers // case 455: break; // // Rule 456: ClassBodyopt ::= // case 456: btParser.setSym1(null); break; // // Rule 457: ClassBodyopt ::= ClassBody // case 457: break; // // Rule 458: Argumentsopt ::= // case 458: btParser.setSym1(null); break; // // Rule 459: Argumentsopt ::= Arguments // case 459: bad_rule = 459; break; // // Rule 460: EnumBodyDeclarationsopt ::= // case 460: btParser.setSym1(null); break; // // Rule 461: EnumBodyDeclarationsopt ::= EnumBodyDeclarations // case 461: bad_rule = 461; break; // // Rule 462: ,opt ::= // case 462: btParser.setSym1(null); break; // // Rule 463: ,opt ::= COMMA // case 463: break; // // Rule 464: EnumConstantsopt ::= // case 464: btParser.setSym1(null); break; // // Rule 465: EnumConstantsopt ::= EnumConstants // case 465: bad_rule = 465; break; // // Rule 466: ArgumentListopt ::= // case 466: { btParser.setSym1(new TypedList(new LinkedList(), Catch.class, false)); break; } // // Rule 467: ArgumentListopt ::= ArgumentList // case 467: break; // // Rule 468: BlockStatementsopt ::= // case 468: { btParser.setSym1(new TypedList(new LinkedList(), Stmt.class, false)); break; } // // Rule 469: BlockStatementsopt ::= BlockStatements // case 469: break; // // Rule 470: ExplicitConstructorInvocationopt ::= // case 470: btParser.setSym1(null); break; // // Rule 471: ExplicitConstructorInvocationopt ::= ExplicitConstructorInvocation // case 471: break; // // Rule 472: ConstructorModifiersopt ::= // case 472: { btParser.setSym1(Flags.NONE); break; } // // Rule 473: ConstructorModifiersopt ::= ConstructorModifiers // case 473: break; // // Rule 474: ...opt ::= // case 474: btParser.setSym1(null); break; // // Rule 475: ...opt ::= ELLIPSIS // case 475: break; // // Rule 476: FormalParameterListopt ::= // case 476: { btParser.setSym1(new TypedList(new LinkedList(), Formal.class, false)); break; } // // Rule 477: FormalParameterListopt ::= FormalParameterList // case 477: break; // // Rule 478: Throwsopt ::= // case 478: { btParser.setSym1(new TypedList(new LinkedList(), TypeNode.class, false)); break; } // // Rule 479: Throwsopt ::= Throws // case 479: break; // // Rule 480: MethodModifiersopt ::= // case 480: { btParser.setSym1(Flags.NONE); break; } // // Rule 481: MethodModifiersopt ::= MethodModifiers // case 481: break; // // Rule 482: FieldModifiersopt ::= // case 482: { btParser.setSym1(Flags.NONE); break; } // // Rule 483: FieldModifiersopt ::= FieldModifiers // case 483: break; // // Rule 484: ClassBodyDeclarationsopt ::= // case 484: { btParser.setSym1(new TypedList(new LinkedList(), ClassMember.class, false)); break; } // // Rule 485: ClassBodyDeclarationsopt ::= ClassBodyDeclarations // case 485: break; // // Rule 486: Interfacesopt ::= // case 486: { btParser.setSym1(new TypedList(new LinkedList(), TypeNode.class, false)); break; } // // Rule 487: Interfacesopt ::= Interfaces // case 487: break; // // Rule 488: Superopt ::= // case 488: btParser.setSym1(null); break; // // Rule 489: Superopt ::= Super // case 489: break; // // Rule 490: TypeParametersopt ::= // case 490: btParser.setSym1(null); break; // // Rule 491: TypeParametersopt ::= TypeParameters // case 491: break; // // Rule 492: ClassModifiersopt ::= // case 492: { btParser.setSym1(Flags.NONE); break; } // // Rule 493: ClassModifiersopt ::= ClassModifiers // case 493: break; // // Rule 494: Annotationsopt ::= // case 494: btParser.setSym1(null); break; // // Rule 495: Annotationsopt ::= Annotations // case 495: bad_rule = 495; break; // // Rule 496: TypeDeclarationsopt ::= // case 496: { btParser.setSym1(new TypedList(new LinkedList(), TopLevelDecl.class, false)); break; } // // Rule 497: TypeDeclarationsopt ::= TypeDeclarations // case 497: break; // // Rule 498: ImportDeclarationsopt ::= // case 498: { btParser.setSym1(new TypedList(new LinkedList(), Import.class, false)); break; } // // Rule 499: ImportDeclarationsopt ::= ImportDeclarations // case 499: break; // // Rule 500: PackageDeclarationopt ::= // case 500: btParser.setSym1(null); break; // // Rule 501: PackageDeclarationopt ::= PackageDeclaration // case 501: break; // // Rule 502: WildcardBoundsOpt ::= // case 502: btParser.setSym1(null); break; // // Rule 503: WildcardBoundsOpt ::= WildcardBounds // case 503: bad_rule = 503; break; // // Rule 504: AdditionalBoundListopt ::= // case 504: btParser.setSym1(null); break; // // Rule 505: AdditionalBoundListopt ::= AdditionalBoundList // case 505: bad_rule = 505; break; // // Rule 506: TypeBoundopt ::= // case 506: btParser.setSym1(null); break; // // Rule 507: TypeBoundopt ::= TypeBound // case 507: bad_rule = 507; break; // // Rule 508: TypeArgumentsopt ::= // case 508: btParser.setSym1(null); break; // // Rule 509: TypeArgumentsopt ::= TypeArguments // case 509: bad_rule = 509; break; // // Rule 510: Commentsopt ::= // case 510: btParser.setSym1(null); break; // // Rule 511: Commentsopt ::= Comments // case 511: break; // // Rule 512: Type ::= DataType PlaceTypeSpecifieropt // case 512: { assert(btParser.getSym(2) == null); //btParser.setSym1(); break; } // // Rule 513: Type ::= nullable LESS Type GREATER // case 513: { TypeNode a = (TypeNode) btParser.getSym(3); btParser.setSym1(nf.Nullable(pos(), a)); break; } // // Rule 514: Type ::= future LESS Type GREATER // case 514: { TypeNode a = (TypeNode) btParser.getSym(3); btParser.setSym1(nf.Future(pos(), a)); break; } // // Rule 515: Type ::= boxed LESS Type GREATER // case 515: bad_rule = 515; break; // // Rule 516: Type ::= fun LESS Type COMMA Type GREATER // case 516: bad_rule = 516; break; // // Rule 517: DataType ::= PrimitiveType // case 517: break; // // Rule 518: DataType ::= ClassOrInterfaceType // case 518: break; // // Rule 519: DataType ::= ArrayType // case 519: break; // // Rule 520: PlaceTypeSpecifier ::= AT PlaceType // case 520: bad_rule = 520; break; // // Rule 521: PlaceType ::= place // case 521: break; // // Rule 522: PlaceType ::= activity // case 522: break; // // Rule 523: PlaceType ::= method // case 523: break; // // Rule 524: PlaceType ::= current // case 524: break; // // Rule 525: PlaceType ::= PlaceExpression // case 525: break; // // Rule 526: ClassOrInterfaceType ::= TypeName DepParametersopt // case 526: { Name a = (Name) btParser.getSym(1); TypeNode t = a.toType(); DepParameterExpr b = (DepParameterExpr) btParser.getSym(2); btParser.setSym1(nf.ParametricTypeNode(pos(), t, b)); break; } // // Rule 527: DepParameters ::= LPAREN DepParameterExpr RPAREN // case 527: break; // // Rule 528: DepParameterExpr ::= ArgumentList WhereClauseopt // case 528: { List a = (List) btParser.getSym(1); Expr b = (Expr) btParser.getSym(2); btParser.setSym1(nf.DepParameterExpr(pos(),a,b)); break; } // // Rule 529: DepParameterExpr ::= WhereClause // case 529: { Expr b = (Expr) btParser.getSym(1); btParser.setSym1(nf.DepParameterExpr(pos(), null, b)); break; } // // Rule 530: WhereClause ::= COLON Expression // case 530: break; // // Rule 532: X10ArrayType ::= Type LBRACKET DOT RBRACKET // case 532: { TypeNode a = (TypeNode) btParser.getSym(1); TypeNode t = nf.X10ArrayTypeNode(pos(), a, false, null); btParser.setSym1(t); break; } // // Rule 533: X10ArrayType ::= Type reference LBRACKET DOT RBRACKET // case 533: { TypeNode a = (TypeNode) btParser.getSym(1); btParser.setSym1(nf.X10ArrayTypeNode(pos(), a, false, null)); break; } // // Rule 534: X10ArrayType ::= Type value LBRACKET DOT RBRACKET // case 534: { TypeNode a = (TypeNode) btParser.getSym(1); btParser.setSym1(nf.X10ArrayTypeNode(pos(), a, true, null)); break; } // // Rule 535: X10ArrayType ::= Type LBRACKET DepParameterExpr RBRACKET // case 535: { TypeNode a = (TypeNode) btParser.getSym(1); DepParameterExpr b = (DepParameterExpr) btParser.getSym(2); btParser.setSym1(nf.X10ArrayTypeNode(pos(), a, false, b)); break; } // // Rule 536: X10ArrayType ::= Type reference LBRACKET DepParameterExpr RBRACKET // case 536: { TypeNode a = (TypeNode) btParser.getSym(1); DepParameterExpr b = (DepParameterExpr) btParser.getSym(2); btParser.setSym1(nf.X10ArrayTypeNode(pos(), a, false, b)); break; } // // Rule 537: X10ArrayType ::= Type value LBRACKET DepParameterExpr RBRACKET // case 537: { TypeNode a = (TypeNode) btParser.getSym(1); DepParameterExpr b = (DepParameterExpr) btParser.getSym(2); btParser.setSym1(nf.X10ArrayTypeNode(pos(), a, true, b)); break; } // // Rule 538: ObjectKind ::= value // case 538: bad_rule = 538; break; // // Rule 539: ObjectKind ::= reference // case 539: bad_rule = 539; break; // // Rule 540: MethodModifier ::= atomic // case 540: { btParser.setSym1(Flags.ATOMIC); break; } // // Rule 541: MethodModifier ::= extern // case 541: { btParser.setSym1(Flags.NATIVE); break; } // // Rule 542: ClassDeclaration ::= ValueClassDeclaration // case 542: break; // // Rule 543: ValueClassDeclaration ::= ClassModifiersopt value identifier Superopt Interfacesopt ClassBody // case 543: { Flags a = (Flags) btParser.getSym(1); polyglot.lex.Identifier b = id(btParser.getToken(3)); TypeNode c = (TypeNode) btParser.getSym(4); List d = (List) btParser.getSym(5); ClassBody e = (ClassBody) btParser.getSym(6); btParser.setSym1(nf.ValueClassDecl(pos(btParser.getFirstToken(), btParser.getLastToken()), a, b.getIdentifier(), c, d, e)); break; } // // Rule 544: ValueClassDeclaration ::= ClassModifiersopt value class identifier Superopt Interfacesopt ClassBody // case 544: { Flags a = (Flags) btParser.getSym(1); polyglot.lex.Identifier b = id(btParser.getToken(4)); TypeNode c = (TypeNode) btParser.getSym(5); List d = (List) btParser.getSym(6); ClassBody e = (ClassBody) btParser.getSym(7); btParser.setSym1(nf.ValueClassDecl(pos(btParser.getFirstToken(), btParser.getLastToken()), a, b.getIdentifier(), c, d, e)); break; } // // Rule 545: ArrayCreationExpression ::= new ArrayBaseType Unsafeopt LBRACKET RBRACKET ArrayInitializer // case 545: { TypeNode a = (TypeNode) btParser.getSym(2); ArrayInit d = (ArrayInit) btParser.getSym(6); // btParser.setSym1(nf.ArrayConstructor(pos(), a, false, null, d)); btParser.setSym1(nf.NewArray(pos(), a, 1, d)); break; } // // Rule 546: ArrayCreationExpression ::= new ArrayBaseType Unsafeopt LBRACKET Expression RBRACKET // case 546: { TypeNode a = (TypeNode) btParser.getSym(2); boolean unsafe = (btParser.getSym(3) != null); Expr c = (Expr) btParser.getSym(5); btParser.setSym1(nf.ArrayConstructor(pos(), a, unsafe, false, c, null)); break; } // // Rule 547: ArrayCreationExpression ::= new ArrayBaseType Unsafeopt LBRACKET Expression RBRACKET Expression // case 547: { TypeNode a = (TypeNode) btParser.getSym(2); boolean unsafe = (btParser.getSym(3) != null); Expr c = (Expr) btParser.getSym(5); Expr d = (Expr) btParser.getSym(7); btParser.setSym1(nf.ArrayConstructor(pos(), a, unsafe, false, c, d)); break; } // // Rule 548: ArrayCreationExpression ::= new ArrayBaseType value Unsafeopt LBRACKET Expression RBRACKET // case 548: { TypeNode a = (TypeNode) btParser.getSym(2); boolean unsafe = (btParser.getSym(3) != null); Expr c = (Expr) btParser.getSym(5); btParser.setSym1(nf.ArrayConstructor(pos(), a, unsafe, true, c, null)); break; } // // Rule 549: ArrayCreationExpression ::= new ArrayBaseType value Unsafeopt LBRACKET Expression RBRACKET Expression // case 549: { TypeNode a = (TypeNode) btParser.getSym(2); boolean unsafe = (btParser.getSym(3) != null); Expr c = (Expr) btParser.getSym(5); Expr d = (Expr) btParser.getSym(7); btParser.setSym1(nf.ArrayConstructor(pos(), a, unsafe, true, c, d)); break; } // // Rule 550: ArrayBaseType ::= PrimitiveType // case 550: break; // // Rule 551: ArrayBaseType ::= ClassOrInterfaceType // case 551: break; // // Rule 552: ArrayAccess ::= ExpressionName LBRACKET ArgumentList RBRACKET // case 552: { Name e = (Name) btParser.getSym(1); List b = (List) btParser.getSym(3); if (b.size() == 1) btParser.setSym1(nf.X10ArrayAccess1(pos(), e.toExpr(), (Expr) b.get(0))); else btParser.setSym1(nf.X10ArrayAccess(pos(), e.toExpr(), b)); break; } // // Rule 553: ArrayAccess ::= PrimaryNoNewArray LBRACKET ArgumentList RBRACKET // case 553: { Expr a = (Expr) btParser.getSym(1); List b = (List) btParser.getSym(3); if (b.size() == 1) btParser.setSym1(nf.X10ArrayAccess1(pos(), a, (Expr) b.get(0))); else btParser.setSym1(nf.X10ArrayAccess(pos(), a, b)); break; } // // Rule 554: Statement ::= NowStatement // case 554: break; // // Rule 555: Statement ::= ClockedStatement // case 555: break; // // Rule 556: Statement ::= AsyncStatement // case 556: break; // // Rule 557: Statement ::= AtomicStatement // case 557: break; // // Rule 558: Statement ::= WhenStatement // case 558: break; // // Rule 559: Statement ::= ForEachStatement // case 559: break; // // Rule 560: Statement ::= AtEachStatement // case 560: break; // // Rule 561: Statement ::= FinishStatement // case 561: break; // // Rule 562: StatementWithoutTrailingSubstatement ::= NextStatement // case 562: break; // // Rule 563: StatementWithoutTrailingSubstatement ::= AwaitStatement // case 563: break; // // Rule 564: StatementNoShortIf ::= NowStatementNoShortIf // case 564: break; // // Rule 565: StatementNoShortIf ::= ClockedStatementNoShortIf // case 565: break; // // Rule 566: StatementNoShortIf ::= AsyncStatementNoShortIf // case 566: break; // // Rule 567: StatementNoShortIf ::= AtomicStatementNoShortIf // case 567: break; // // Rule 568: StatementNoShortIf ::= WhenStatementNoShortIf // case 568: break; // // Rule 569: StatementNoShortIf ::= ForEachStatementNoShortIf // case 569: break; // // Rule 570: StatementNoShortIf ::= AtEachStatementNoShortIf // case 570: break; // // Rule 571: StatementNoShortIf ::= FinishStatementNoShortIf // case 571: break; // // Rule 572: NowStatement ::= now LPAREN Clock RPAREN Statement // case 572: { Name a = (Name) btParser.getSym(3); Stmt b = (Stmt) btParser.getSym(5); btParser.setSym1(nf.Now(pos(), a.toExpr(), b)); break; } // // Rule 573: ClockedStatement ::= clocked LPAREN ClockList RPAREN Statement // case 573: { List a = (List) btParser.getSym(3); Block b = (Block) btParser.getSym(5); btParser.setSym1(nf.Clocked(pos(), a, b)); break; } // // Rule 574: AsyncStatement ::= async PlaceExpressionSingleListopt Statement // case 574: { Expr e = (Expr) btParser.getSym(2); Stmt b = (Stmt) btParser.getSym(3); btParser.setSym1(nf.Async(pos(), (e == null ? nf.Here(pos(btParser.getFirstToken())) : e), b)); break; } // // Rule 575: AsyncStatement ::= async LPAREN here RPAREN Statement // case 575: { Stmt b = (Stmt) btParser.getSym(5); btParser.setSym1(nf.Async(pos(), nf.Here(pos(btParser.getFirstToken())), b)); break; } // // Rule 576: AtomicStatement ::= atomic PlaceExpressionSingleListopt Statement // case 576: { Expr e = (Expr) btParser.getSym(2); Stmt b = (Stmt) btParser.getSym(3); btParser.setSym1(nf.Atomic(pos(), (e == null ? nf.Here(pos(btParser.getFirstToken())) : e), b)); break; } // // Rule 577: AtomicStatement ::= atomic LPAREN here RPAREN Statement // case 577: { Stmt b = (Stmt) btParser.getSym(5); btParser.setSym1(nf.Atomic(pos(), nf.Here(pos(btParser.getFirstToken())), b)); break; } // // Rule 578: WhenStatement ::= when LPAREN Expression RPAREN Statement // case 578: { Expr e = (Expr) btParser.getSym(3); Stmt s = (Stmt) btParser.getSym(5); btParser.setSym1(nf.When(pos(), e,s)); break; } // // Rule 579: WhenStatement ::= WhenStatement or LPAREN Expression RPAREN Statement // case 579: { When w = (When) btParser.getSym(1); Expr e = (Expr) btParser.getSym(4); Stmt s = (Stmt) btParser.getSym(6); w.add(new When_c.Branch_c(e,s)); btParser.setSym1(w); break; } // // Rule 580: ForEachStatement ::= foreach LPAREN FormalParameter COLON Expression RPAREN Statement // case 580: { Formal f = (Formal) btParser.getSym(3); Expr e = (Expr) btParser.getSym(5); Stmt s = (Stmt) btParser.getSym(7); X10Loop x = nf.ForEach(pos(), f, e, s); btParser.setSym1(x); break; } // // Rule 581: AtEachStatement ::= ateach LPAREN FormalParameter COLON Expression RPAREN Statement // case 581: { Formal f = (Formal) btParser.getSym(3); Expr e = (Expr) btParser.getSym(5); Stmt s = (Stmt) btParser.getSym(7); X10Loop x = nf.AtEach(pos(), f, e, s); btParser.setSym1(x); break; } // // Rule 582: EnhancedForStatement ::= for LPAREN FormalParameter COLON Expression RPAREN Statement // case 582: { Formal f = (Formal) btParser.getSym(3); Expr e = (Expr) btParser.getSym(5); Stmt s = (Stmt) btParser.getSym(7); X10Loop x = nf.ForLoop(pos(), f, e, s); btParser.setSym1(x); break; } // // Rule 583: FinishStatement ::= finish Statement // case 583: { Stmt b = (Stmt) btParser.getSym(2); btParser.setSym1(nf.Finish(pos(), b)); break; } // // Rule 584: NowStatementNoShortIf ::= now LPAREN Clock RPAREN StatementNoShortIf // case 584: { Name a = (Name) btParser.getSym(3); Stmt b = (Stmt) btParser.getSym(5); btParser.setSym1(nf.Now(pos(), a.toExpr(), b)); break; } // // Rule 585: ClockedStatementNoShortIf ::= clocked LPAREN ClockList RPAREN StatementNoShortIf // case 585: { List a = (List) btParser.getSym(3); Stmt b = (Stmt) btParser.getSym(5); btParser.setSym1(nf.Clocked(pos(), a, b)); break; } // // Rule 586: AsyncStatementNoShortIf ::= async PlaceExpressionSingleListopt StatementNoShortIf // case 586: { Expr e = (Expr) btParser.getSym(2); Stmt b = (Stmt) btParser.getSym(3); btParser.setSym1(nf.Async(pos(), (e == null ? nf.Here(pos(btParser.getFirstToken())) : e), b)); break; } // // Rule 587: AsyncStatementNoShortIf ::= async LPAREN here RPAREN StatementNoShortIf // case 587: { Stmt b = (Stmt) btParser.getSym(5); btParser.setSym1(nf.Async(pos(), nf.Here(pos(btParser.getFirstToken())), b)); break; } // // Rule 588: AtomicStatementNoShortIf ::= atomic StatementNoShortIf // case 588: { Expr e = (Expr) btParser.getSym(2); Stmt b = (Stmt) btParser.getSym(3); btParser.setSym1(nf.Atomic(pos(), (e == null ? nf.Here(pos(btParser.getFirstToken())) : e), b)); break; } // // Rule 589: AtomicStatementNoShortIf ::= atomic LPAREN here RPAREN StatementNoShortIf // case 589: { Stmt b = (Stmt) btParser.getSym(5); btParser.setSym1(nf.Atomic(pos(), nf.Here(pos(btParser.getFirstToken())), b)); break; } // // Rule 590: WhenStatementNoShortIf ::= when LPAREN Expression RPAREN StatementNoShortIf // case 590: { Expr e = (Expr) btParser.getSym(3); Stmt s = (Stmt) btParser.getSym(5); btParser.setSym1(nf.When(pos(), e,s)); break; } // // Rule 591: WhenStatementNoShortIf ::= WhenStatement or LPAREN Expression RPAREN StatementNoShortIf // case 591: { When w = (When) btParser.getSym(1); Expr e = (Expr) btParser.getSym(4); Stmt s = (Stmt) btParser.getSym(6); w.add(new When_c.Branch_c(e,s)); btParser.setSym1(w); break; } // // Rule 592: ForEachStatementNoShortIf ::= foreach LPAREN FormalParameter COLON Expression RPAREN StatementNoShortIf // case 592: { Formal f = (Formal) btParser.getSym(3); Expr e = (Expr) btParser.getSym(5); Stmt s = (Stmt) btParser.getSym(7); X10Loop x = nf.ForEach(pos(), f, e, s); btParser.setSym1(x); break; } // // Rule 593: AtEachStatementNoShortIf ::= ateach LPAREN FormalParameter COLON Expression RPAREN StatementNoShortIf // case 593: { Formal f = (Formal) btParser.getSym(3); Expr e = (Expr) btParser.getSym(5); Stmt s = (Stmt) btParser.getSym(7); X10Loop x = nf.AtEach(pos(), f, e, s); btParser.setSym1(x); break; } // // Rule 594: FinishStatementNoShortIf ::= finish StatementNoShortIf // case 594: { Stmt b = (Stmt) btParser.getSym(2); btParser.setSym1(nf.Finish(pos(), b)); break; } // // Rule 595: PlaceExpressionSingleList ::= LPAREN PlaceExpression RPAREN // case 595: { btParser.setSym1(btParser.getSym(2)); break; } // // Rule 596: PlaceExpression ::= here // case 596: { btParser.setSym1(nf.Here(pos(btParser.getFirstToken()))); break; } // // Rule 597: PlaceExpression ::= this // case 597: { btParser.setSym1(nf.Field(pos(btParser.getFirstToken()), nf.This(pos(btParser.getFirstToken())), "place")); break; } // // Rule 598: PlaceExpression ::= Expression // case 598: break; // // Rule 599: PlaceExpression ::= ArrayAccess // case 599: bad_rule = 599; break; // // Rule 600: NextStatement ::= next SEMICOLON // case 600: { btParser.setSym1(nf.Next(pos())); break; } // // Rule 601: AwaitStatement ::= await Expression SEMICOLON // case 601: { Expr e = (Expr) btParser.getSym(2); btParser.setSym1(nf.Await(pos(), e)); break; } // // Rule 602: ClockList ::= Clock // case 602: { Name c = (Name) btParser.getSym(1); List l = new TypedList(new LinkedList(), Expr.class, false); l.add(c.toExpr()); btParser.setSym1(l); break; } // // Rule 603: ClockList ::= ClockList COMMA Clock // case 603: { List l = (List) btParser.getSym(1); Name c = (Name) btParser.getSym(3); l.add(c.toExpr()); // btParser.setSym1(l); break; } // // Rule 604: Clock ::= identifier // case 604: { polyglot.lex.Identifier a = id(btParser.getToken(1)); btParser.setSym1(new Name(nf, ts, pos(), a.getIdentifier())); break; } // // Rule 605: CastExpression ::= LPAREN Type RPAREN UnaryExpressionNotPlusMinus // case 605: { TypeNode a = (TypeNode) btParser.getSym(2); Expr b = (Expr) btParser.getSym(4); btParser.setSym1(nf.Cast(pos(), a, b)); break; } // // Rule 606: MethodInvocation ::= Primary ARROW identifier LPAREN ArgumentListopt RPAREN // case 606: { Expr a = (Expr) btParser.getSym(1); polyglot.lex.Identifier b = id(btParser.getToken(3)); List c = (List) btParser.getSym(5); btParser.setSym1(nf.RemoteCall(pos(), a, b.getIdentifier(), c)); break; } // // Rule 607: RelationalExpression ::= RelationalExpression instanceof Type // case 607: { Expr a = (Expr) btParser.getSym(1); TypeNode b = (TypeNode) btParser.getSym(3); btParser.setSym1(nf.Instanceof(pos(), a, b)); break; } // // Rule 608: ExpressionName ::= here // case 608: { btParser.setSym1(new Name(nf, ts, pos(), "here"){ public Expr toExpr() { return nf.Here(pos); } }); break; } // // Rule 609: Primary ::= FutureExpression // case 609: break; // // Rule 610: FutureExpression ::= future PlaceExpressionSingleListopt LBRACE Expression RBRACE // case 610: { Expr e1 = (Expr) btParser.getSym(2), e2 = (Expr) btParser.getSym(4); btParser.setSym1(nf.Future(pos(), (e1 == null ? nf.Here(pos(btParser.getFirstToken())) : e1), e2)); break; } // // Rule 611: FutureExpression ::= future LPAREN here RPAREN LBRACE Expression RBRACE // case 611: { Expr e2 = (Expr) btParser.getSym(6); btParser.setSym1(nf.Future(pos(), nf.Here(pos(btParser.getFirstToken(3))), e2)); break; } // // Rule 612: FunExpression ::= fun Type LPAREN FormalParameterListopt RPAREN LBRACE Expression RBRACE // case 612: bad_rule = 612; break; // // Rule 613: MethodInvocation ::= MethodName LPAREN ArgumentListopt RPAREN LPAREN ArgumentListopt RPAREN // case 613: bad_rule = 613; break; // // Rule 614: MethodInvocation ::= Primary DOT identifier LPAREN ArgumentListopt RPAREN LPAREN ArgumentListopt RPAREN // case 614: bad_rule = 614; break; // // Rule 615: MethodInvocation ::= super DOT identifier LPAREN ArgumentListopt RPAREN LPAREN ArgumentListopt RPAREN // case 615: bad_rule = 615; break; // // Rule 616: MethodInvocation ::= ClassName DOT super DOT identifier LPAREN ArgumentListopt RPAREN LPAREN ArgumentListopt RPAREN // case 616: bad_rule = 616; break; // // Rule 617: MethodInvocation ::= TypeName DOT identifier LPAREN ArgumentListopt RPAREN LPAREN ArgumentListopt RPAREN // case 617: bad_rule = 617; break; // // Rule 618: ClassInstanceCreationExpression ::= new ClassOrInterfaceType LPAREN ArgumentListopt RPAREN LPAREN ArgumentListopt RPAREN ClassBodyopt // case 618: bad_rule = 618; break; // // Rule 619: ClassInstanceCreationExpression ::= Primary DOT new identifier LPAREN ArgumentListopt RPAREN LPAREN ArgumentListopt RPAREN ClassBodyopt // case 619: bad_rule = 619; break; // // Rule 620: ClassInstanceCreationExpression ::= AmbiguousName DOT new identifier LPAREN ArgumentListopt RPAREN LPAREN ArgumentListopt RPAREN ClassBodyopt // case 620: bad_rule = 620; break; // // Rule 621: PlaceTypeSpecifieropt ::= // case 621: btParser.setSym1(null); break; // // Rule 622: PlaceTypeSpecifieropt ::= PlaceTypeSpecifier // case 622: break; // // Rule 623: DepParametersopt ::= // case 623: btParser.setSym1(null); break; // // Rule 624: DepParametersopt ::= DepParameters // case 624: break; // // Rule 625: WhereClauseopt ::= // case 625: btParser.setSym1(null); break; // // Rule 626: WhereClauseopt ::= WhereClause // case 626: break; // // Rule 627: ObjectKindopt ::= // case 627: btParser.setSym1(null); break; // // Rule 628: ObjectKindopt ::= ObjectKind // case 628: break; // // Rule 629: ArrayInitializeropt ::= // case 629: btParser.setSym1(null); break; // // Rule 630: ArrayInitializeropt ::= ArrayInitializer // case 630: break; // // Rule 631: ConcreteDistributionopt ::= // case 631: btParser.setSym1(null); break; // // Rule 632: ConcreteDistributionopt ::= ConcreteDistribution // case 632: break; // // Rule 633: PlaceExpressionSingleListopt ::= // case 633: btParser.setSym1(null); break; // // Rule 634: PlaceExpressionSingleListopt ::= PlaceExpressionSingleList // case 634: break; // // Rule 635: ArgumentListopt ::= // case 635: btParser.setSym1(null); break; // // Rule 636: ArgumentListopt ::= ArgumentList // case 636: break; // // Rule 637: DepParametersopt ::= // case 637: btParser.setSym1(null); break; // // Rule 638: DepParametersopt ::= DepParameters // case 638: break; // // Rule 639: Unsafeopt ::= // case 639: btParser.setSym1(null); break; // // Rule 640: Unsafeopt ::= unsafe // case 640: { btParser.setSym1(nf.Here(pos(btParser.getFirstToken(1)))); break; } default: break; } return; }
1769 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1769/10b0c7616a7abbf0fc08b5455c9818b3be9b7cbc/X10Parser.java/clean/x10.compiler/src/x10/parser/X10Parser.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 918, 1720, 1803, 12, 474, 1720, 1854, 13, 565, 288, 3639, 309, 261, 8759, 67, 5345, 480, 374, 13, 5411, 327, 31, 3639, 1620, 261, 5345, 1854, 13, 3639, 288, 2398, 368, 5411, 368, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 1720, 1803, 12, 474, 1720, 1854, 13, 565, 288, 3639, 309, 261, 8759, 67, 5345, 480, 374, 13, 5411, 327, 31, 3639, 1620, 261, 5345, 1854, 13, 3639, 288, 2398, 368, 5411, 368, ...
public String getLocalName() { String returnStr = null; if (parser != null) { returnStr = parser.getLocalName(); } else { if (currentEvent == START_ELEMENT || currentEvent == END_ELEMENT || currentEvent == ENTITY_REFERENCE) { returnStr = ((OMElement) lastNode).getLocalName(); } } return returnStr; }
49300 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/49300/af7717d39bf334b9910718812650d5561f1cbe1c/OMStAXWrapper.java/buggy/modules/om/src/java/org/apache/axis/om/impl/llom/OMStAXWrapper.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1071, 780, 588, 29583, 1435, 95, 780, 2463, 1585, 33, 2011, 31, 430, 12, 4288, 5, 33, 2011, 15329, 2463, 1585, 33, 4288, 18, 588, 29583, 5621, 97, 12107, 95, 430, 12, 2972, 1133, 631, 7570, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 780, 588, 29583, 1435, 95, 780, 2463, 1585, 33, 2011, 31, 430, 12, 4288, 5, 33, 2011, 15329, 2463, 1585, 33, 4288, 18, 588, 29583, 5621, 97, 12107, 95, 430, 12, 2972, 1133, 631, 7570, ...
} else centerPanel.add(new JLabel(parent.langpack.getString("FinishPanel.fail"), parent.icons.getImageIcon("information"), JLabel.TRAILING));
} else centerPanel.add( new JLabel( parent.langpack.getString("FinishPanel.fail"), parent.icons.getImageIcon("information"), JLabel.TRAILING));
public void panelActivate() { parent.lockNextButton(); parent.lockPrevButton(); if (idata.installSuccess) { // We set the information centerPanel.add(new JLabel(parent.langpack.getString("FinishPanel.success"), parent.icons.getImageIcon("information"), JLabel.TRAILING)); centerPanel.add(Box.createVerticalStrut(20)); if (idata.info.getWriteUninstaller()) { // We prepare a message for the uninstaller feature String path = translatePath("$INSTALL_PATH") + File.separator + "Uninstaller"; centerPanel.add(new JLabel(parent.langpack.getString("FinishPanel.uninst.info"), parent.icons.getImageIcon("information"), JLabel.TRAILING)); centerPanel.add(new JLabel(path, parent.icons.getImageIcon("empty"), JLabel.TRAILING)); } // We add the autoButton centerPanel.add(Box.createVerticalStrut(20)); autoButton = ButtonFactory.createButton(parent.langpack.getString("FinishPanel.auto"), parent.icons.getImageIcon("edit"), idata.buttonsHColor); autoButton.setToolTipText(parent.langpack.getString("FinishPanel.auto.tip")); autoButton.addActionListener(this); centerPanel.add(autoButton); } else centerPanel.add(new JLabel(parent.langpack.getString("FinishPanel.fail"), parent.icons.getImageIcon("information"), JLabel.TRAILING)); }
54145 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54145/6e8ab3930a21f787bcd0f3cf0b9937f9d50c80c0/FinishPanel.java/clean/src/lib/com/izforge/izpack/panels/FinishPanel.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 282, 1071, 918, 6594, 21370, 1435, 225, 288, 565, 982, 18, 739, 2134, 3616, 5621, 565, 982, 18, 739, 9958, 3616, 5621, 565, 309, 261, 350, 396, 18, 5425, 4510, 13, 565, 288, 1377, 368, 1660,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 6594, 21370, 1435, 225, 288, 565, 982, 18, 739, 2134, 3616, 5621, 565, 982, 18, 739, 9958, 3616, 5621, 565, 309, 261, 350, 396, 18, 5425, 4510, 13, 565, 288, 1377, 368, 1660,...
catch(Abort a) { }
private void doRequest(final Request request) { if(request.inAWT) { // this hack ensures that requestCount is zero only // when there are really no requests running Runnable r = new Runnable() { public void run() { Log.log(Log.DEBUG,WorkThread.class, "Running in AWT thread: " + request.run); try { request.run.run(); } catch(Abort a) { } catch(Throwable t) { Log.log(Log.ERROR,WorkThread.class,"Exception " + "in AWT thread:"); Log.log(Log.ERROR,WorkThread.class,t); } requestCount--; } }; SwingUtilities.invokeLater(r); } else { Log.log(Log.DEBUG,WorkThread.class,"Running in work thread: " + request.run); try { request.run.run(); } catch(Abort a) { } catch(Throwable t) { Log.log(Log.ERROR,WorkThread.class,"Exception " + "in work thread:"); Log.log(Log.ERROR,WorkThread.class,t); } requestCount--; } }
6564 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/6564/be991b415a7fd87d953c80cc61ebf1762aa1c909/WorkThread.java/clean/org/gjt/sp/util/WorkThread.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 1152, 918, 25801, 12, 6385, 1567, 590, 13, 202, 95, 202, 202, 430, 12, 2293, 18, 267, 37, 8588, 13, 202, 202, 95, 1082, 202, 759, 333, 11769, 11932, 716, 590, 1380, 353, 3634, 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, 225, 202, 1152, 918, 25801, 12, 6385, 1567, 590, 13, 202, 95, 202, 202, 430, 12, 2293, 18, 267, 37, 8588, 13, 202, 202, 95, 1082, 202, 759, 333, 11769, 11932, 716, 590, 1380, 353, 3634, 13...
releaseWordLocal(x); addByteCode(ByteCode.ALOAD_0); addByteCode(ByteCode.SWAP); classFile.add(ByteCode.PUTFIELD, "org/mozilla/javascript/NativeFunction", "names", "[Ljava/lang/String;");
private void generateInit(Context cx, String methodName, Node tree, String name, Node args) { trivialInit = true; boolean inCtor = false; VariableTable vars; if (tree instanceof OptFunctionNode) vars = ((OptFunctionNode)tree).getVariableTable(); else vars = (VariableTable) tree.getProp(Node.VARS_PROP); if (methodName.equals("<init>")) { inCtor = true; setNonTrivialInit(methodName); addByteCode(ByteCode.ALOAD_0); addSpecialInvoke(superClassSlashName, "<init>", "()", "V"); addByteCode(ByteCode.ALOAD_0); addByteCode(ByteCode.ALOAD_1); classFile.add(ByteCode.PUTFIELD, "org/mozilla/javascript/ScriptableObject", "parent", "Lorg/mozilla/javascript/Scriptable;"); } /* * Generate code to initialize names field with a * string array that is the names of the function, * the parameters and the vars. Initialize argCount * to the number of formal parameters. */ if (name.length() != 0 || (vars != null && vars.size() > 0)) { setNonTrivialInit(methodName); if (vars == null) vars = new OptVariableTable(); push(vars.size() + 1); addByteCode(ByteCode.ANEWARRAY, "java/lang/String"); addByteCode(ByteCode.DUP); short x = getNewWordLocal(); astore(x); addByteCode(ByteCode.DUP); push(0); classFile.addLoadConstant(name); addByteCode(ByteCode.AASTORE); if (vars != null) { for (int i = 0; i < vars.size(); i++) { aload(x); push(i + 1); push(vars.getName(i)); addByteCode(ByteCode.AASTORE); } } releaseWordLocal(x); addByteCode(ByteCode.ALOAD_0); addByteCode(ByteCode.SWAP); classFile.add(ByteCode.PUTFIELD, "org/mozilla/javascript/NativeFunction", "names", "[Ljava/lang/String;"); } int parmCount = vars == null ? 0 : vars.getParameterCount(); if (parmCount != 0) { setNonTrivialInit(methodName); addByteCode(ByteCode.ALOAD_0); push(parmCount); classFile.add(ByteCode.PUTFIELD, "org/mozilla/javascript/NativeFunction", "argCount", "S"); } // Initialize NativeFunction.version with Context's version. if (cx.getLanguageVersion() != 0) { setNonTrivialInit(methodName); addByteCode(ByteCode.ALOAD_0); push(cx.getLanguageVersion()); classFile.add(ByteCode.PUTFIELD, "org/mozilla/javascript/NativeFunction", "version", "S"); } // add the String representing the source. String source = (String) tree.getProp(Node.SOURCE_PROP); if ((source != null) && cx.isGeneratingSource() && (source.length() < 65536)) { setNonTrivialInit(methodName); addByteCode(ByteCode.ALOAD_0); push(source); classFile.add(ByteCode.PUTFIELD, "org/mozilla/javascript/NativeFunction", "source", "Ljava/lang/String;"); } // precompile all regexp literals Vector regexps = (Vector) tree.getProp(Node.REGEXP_PROP); if (regexps != null) { setNonTrivialInit(methodName); generateRegExpLiterals(regexps, inCtor); } Vector fns = (Vector) tree.getProp(Node.FUNCTION_PROP); if (fns != null) { setNonTrivialInit(methodName); generateFunctionInits(fns); } if (tree instanceof OptFunctionNode) { OptFunctionNode fnNode = (OptFunctionNode)tree; Vector directCallTargets = ((OptFunctionNode)tree).getDirectCallTargets(); if (directCallTargets != null) { setNonTrivialInit(methodName); classFile.addField("EmptyArray", "[Ljava/lang/Object;", (short)ClassFileWriter.ACC_PRIVATE); addByteCode(ByteCode.ALOAD_0); push(0); addByteCode(ByteCode.ANEWARRAY, "java/lang/Object"); classFile.add(ByteCode.PUTFIELD, classFile.fullyQualifiedForm(this.name), "EmptyArray", "[Ljava/lang/Object;"); } if (fnNode.isTargetOfDirectCall()) { setNonTrivialInit(methodName); String className = classFile.fullyQualifiedForm(fnNode.getClassName()); String fieldName = className.replace('/', '_'); classFile.addField(fieldName, "L" + className + ";", (short)(ClassFileWriter.ACC_PUBLIC + ClassFileWriter.ACC_STATIC)); addByteCode(ByteCode.ALOAD_0); classFile.add(ByteCode.PUTSTATIC, className, fieldName, "L" + className + ";"); } } if (!trivialInit) { addByteCode(ByteCode.RETURN); finishMethod(cx, null); } }
54155 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54155/49ee5104a9201354fbd63b6b9e1e0ea314785d03/Codegen.java/clean/js/rhino/src/org/mozilla/javascript/optimizer/Codegen.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 3238, 918, 2103, 2570, 12, 1042, 9494, 16, 514, 4918, 16, 17311, 2029, 2151, 16, 514, 508, 16, 2029, 833, 13, 565, 288, 3639, 433, 20109, 2570, 273, 638, 31, 3639, 1250, 14743, 13039, 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, 918, 2103, 2570, 12, 1042, 9494, 16, 514, 4918, 16, 17311, 2029, 2151, 16, 514, 508, 16, 2029, 833, 13, 565, 288, 3639, 433, 20109, 2570, 273, 638, 31, 3639, 1250, 14743, 13039, 2...
public XUpdateProcessor(BrokerPool pool, User user) throws ParserConfigurationException {
public XUpdateProcessor(BrokerPool pool, User user) throws ParserConfigurationException {
public XUpdateProcessor(BrokerPool pool, User user) throws ParserConfigurationException { DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance(); factory.setNamespaceAware(true); factory.setValidating(false); builder = factory.newDocumentBuilder(); this.pool = pool; this.user = user; }
2909 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/2909/3fbac7093568cbfd0f43cec9d16685fd69f6ce93/XUpdateProcessor.java/buggy/src/org/exist/xupdate/XUpdateProcessor.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 1139, 1891, 5164, 12, 11194, 2864, 2845, 16, 2177, 729, 13, 377, 1216, 6783, 10737, 288, 202, 202, 2519, 20692, 3272, 273, 30236, 18, 2704, 1442, 5621, 202, 202, 6848, 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, 482, 1139, 1891, 5164, 12, 11194, 2864, 2845, 16, 2177, 729, 13, 377, 1216, 6783, 10737, 288, 202, 202, 2519, 20692, 3272, 273, 30236, 18, 2704, 1442, 5621, 202, 202, 6848, 18, 542, ...
if (actionHandlers == null) return null; return (IAction) actionHandlers.get(actionID); }
if (actionHandlers == null) return null; return (IAction) actionHandlers.get(actionID); }
public IAction getGlobalActionHandler(String actionID) { if (actionHandlers == null) return null; return (IAction) actionHandlers.get(actionID); }
55805 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/55805/f1c8b0aa355c00a6c82a289c808984de6778bfca/SubActionBars.java/buggy/bundles/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/SubActionBars.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 467, 1803, 20591, 1803, 1503, 12, 780, 1301, 734, 13, 288, 3639, 309, 261, 1128, 6919, 422, 446, 13, 5411, 327, 446, 31, 3639, 327, 261, 45, 1803, 13, 1301, 6919, 18, 588, 12, 1...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 467, 1803, 20591, 1803, 1503, 12, 780, 1301, 734, 13, 288, 3639, 309, 261, 1128, 6919, 422, 446, 13, 5411, 327, 446, 31, 3639, 327, 261, 45, 1803, 13, 1301, 6919, 18, 588, 12, 1...
assertEquals( "Should have returned 4 modifications.",
assertEquals("Should have returned 4 modifications.",
public void testParseStreamBranch() throws IOException, ParseException { CVS cvs = new CVS(); Hashtable emailAliases = new Hashtable(); emailAliases.put("alden", "alden@users.sourceforge.net"); cvs.setMailAliases(emailAliases); cvs.setTag("BRANCH_TEST_BUILD"); BufferedInputStream input = new BufferedInputStream(loadTestLog("cvslog1-11branch.txt")); List modifications = cvs.parseStream(input); input.close(); Collections.sort(modifications); assertEquals( "Should have returned 4 modifications.", 4, modifications.size()); Modification mod1 = new Modification("cvs"); mod1.revision = "1.1.2.4"; mod1.modifiedTime = createDate("2002/10/03 16:05:23 GMT"); mod1.userName = "tim"; mod1.comment = "Test commit once more"; Modification.ModifiedFile mod1file = mod1.createModifiedFile("test.version", null); mod1file.action = "modified"; mod1file.revision = mod1.revision; Modification mod2 = new Modification("cvs"); mod2.revision = "1.1.2.3"; mod2.modifiedTime = createDate("2002/10/03 14:24:17 GMT"); mod2.userName = "tim"; mod2.comment = "Test commit"; Modification.ModifiedFile mod2file = mod2.createModifiedFile("test.version", null); mod2file.action = "modified"; mod2file.revision = mod2.revision; Modification mod3 = new Modification("cvs"); mod3.revision = "1.1.2.2"; mod3.modifiedTime = createDate("2002/10/02 21:54:44 GMT"); mod3.userName = "tim"; mod3.comment = "Update parameters for test"; Modification.ModifiedFile mod3file = mod3.createModifiedFile("test.version", null); mod3file.action = "modified"; mod3file.revision = mod3.revision; Modification mod4 = new Modification("cvs"); mod4.revision = "1.1.2.1"; mod4.modifiedTime = createDate("2002/10/02 21:49:31 GMT"); mod4.userName = "tim"; mod4.comment = "Add parameters for test"; Modification.ModifiedFile mod4file = mod4.createModifiedFile("test.version", null); mod4file.action = "modified"; mod4file.revision = mod4.revision; assertEquals(mod4, modifications.get(0)); assertEquals(mod3, modifications.get(1)); assertEquals(mod2, modifications.get(2)); assertEquals(mod1, modifications.get(3)); }
52149 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52149/fdc64098e18eb6b69a974b8a283a41d469f27fcf/CVSTest.java/clean/main/test/net/sourceforge/cruisecontrol/sourcecontrols/CVSTest.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 918, 1842, 3201, 1228, 7108, 1435, 1216, 1860, 16, 10616, 288, 3639, 385, 14640, 276, 6904, 273, 394, 385, 14640, 5621, 3639, 18559, 2699, 9667, 273, 394, 18559, 5621, 3639, 2699, 966...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 3201, 1228, 7108, 1435, 1216, 1860, 16, 10616, 288, 3639, 385, 14640, 276, 6904, 273, 394, 385, 14640, 5621, 3639, 18559, 2699, 9667, 273, 394, 18559, 5621, 3639, 2699, 966...
this.writePermanentRedirect(ctx, "Not enough meta-strings", '/' + URLEncoder.encode(key.toString(false)) + '/');
this.writePermanentRedirect(ctx, "Not enough meta-strings", '/' + key.toString(false) + '/' + override);
public void handleGet(URI uri, ToadletContext ctx) throws ToadletContextClosedException, IOException, RedirectException { //String ks = uri.toString(); String ks = uri.getPath(); HTTPRequest httprequest = new HTTPRequest(uri); if (ks.equals("/")) { if (httprequest.isParameterSet("key")) { MultiValueTable headers = new MultiValueTable(); String k = httprequest.getParam("key"); FreenetURI newURI; try { newURI = new FreenetURI(k); } catch (MalformedURLException e) { sendErrorPage(ctx, 404, "Not found", "Invalid key"); return; } headers.put("Location", "/"+newURI); ctx.sendReplyHeaders(302, "Found", headers, null, 0); return; } RedirectException re = new RedirectException(); try { String querystring = uri.getQuery(); if (querystring == null) { re.newuri = welcome; } else { // TODP possibly a proper URLEncode method querystring = querystring.replace(' ', '+'); re.newuri = new URI("/welcome/?"+querystring); } } catch (URISyntaxException e) { // HUH!?! } throw re; }else if(ks.equals("/favicon.ico")){ byte[] buf = new byte[1024]; int len; InputStream strm = getClass().getResourceAsStream("staticfiles/favicon.ico"); if (strm == null) { this.sendErrorPage(ctx, 404, "Path not found", "The specified path does not exist."); return; } ctx.sendReplyHeaders(200, "OK", null, "image/x-icon", strm.available()); while ( (len = strm.read(buf)) > 0) { ctx.writeData(buf, 0, len); } return; } if(ks.startsWith("/")) ks = ks.substring(1); long maxSize = httprequest.getLongParam("max-size", MAX_LENGTH); FreenetURI key; try { key = new FreenetURI(ks); } catch (MalformedURLException e) { HTMLNode pageNode = ctx.getPageMaker().getPageNode("Invalid key"); HTMLNode contentNode = ctx.getPageMaker().getContentNode(pageNode); HTMLNode errorInfobox = contentNode.addChild("div", "class", "infobox infobox-error"); errorInfobox.addChild("div", "class", "infobox-header", "Invalid key"); HTMLNode errorContent = errorInfobox.addChild("div", "class", "infobox-content"); errorContent.addChild("#", "Expected a freenet key, but got "); errorContent.addChild("code", ks); errorContent.addChild("br"); errorContent.addChild(ctx.getPageMaker().createBackLink(ctx)); errorContent.addChild("br"); errorContent.addChild("a", new String[] { "href", "title" }, new String[] { "/", "Node homepage" }, "Homepage"); StringBuffer pageBuffer = new StringBuffer(); pageNode.generate(pageBuffer); this.writeReply(ctx, 400, "text/html", "Invalid key", pageBuffer.toString()); return; } try { if(Logger.shouldLog(Logger.MINOR, this)) Logger.minor(this, "FProxy fetching "+key+" ("+maxSize+ ')'); FetchResult result = fetch(key, maxSize); // Now, is it safe? Bucket data = result.asBucket(); String mimeType = result.getMimeType(); String requestedMimeType = httprequest.getParam("type", null); handleDownload(ctx, data, ctx.getBucketFactory(), mimeType, requestedMimeType, httprequest.getParam("force", null), httprequest.isParameterSet("forcedownload"), "/", key, maxSize != MAX_LENGTH ? "&max-size="+maxSize : ""); } catch (FetchException e) { String msg = e.getMessage(); String extra = ""; if(e.mode == FetchException.NOT_ENOUGH_PATH_COMPONENTS) { this.writePermanentRedirect(ctx, "Not enough meta-strings", '/' + URLEncoder.encode(key.toString(false)) + '/'); } else if(e.newURI != null) { this.writePermanentRedirect(ctx, msg, '/' +e.newURI.toString()); } else if(e.mode == FetchException.TOO_BIG) { HTMLNode pageNode = ctx.getPageMaker().getPageNode("File information"); HTMLNode contentNode = ctx.getPageMaker().getContentNode(pageNode); HTMLNode infobox = contentNode.addChild("div", "class", "infobox infobox-information"); infobox.addChild("div", "class", "infobox-header", "Large file"); HTMLNode infoboxContent = infobox.addChild("div", "class", "infobox-content"); HTMLNode fileInformationList = infoboxContent.addChild("ul"); HTMLNode option = fileInformationList.addChild("li"); option.addChild("#", "Filename: "); option.addChild("a", "href", '/' + key.toString(false), getFilename(e, key, e.getExpectedMimeType())); boolean finalized = e.finalizedSize(); if(e.expectedSize > 0) { if (finalized) { fileInformationList.addChild("li", "Size: " + SizeUtil.formatSize(e.expectedSize)); } else { fileInformationList.addChild("li", "Size: " + SizeUtil.formatSize(e.expectedSize) + " (may change)"); } } else { fileInformationList.addChild("li", "Size: unknown"); } String mime = e.getExpectedMimeType(); if(mime != null) { if (finalized) { fileInformationList.addChild("li", "MIME type: " + mime); } else { fileInformationList.addChild("li", "Expected MIME type: " + mime); } } else { fileInformationList.addChild("li", "MIME type: unknown"); } infobox = contentNode.addChild("div", "class", "infobox infobox-information"); infobox.addChild("div", "class", "infobox-header", "Explanation"); infoboxContent = infobox.addChild("div", "class", "infobox-content"); infoboxContent.addChild("#", "The Freenet key you requested refers to a large file. Files of this size cannot generally be sent directly to your browser since they take too long for your Freenet node to retrieve. The following options are available:"); HTMLNode optionList = infoboxContent.addChild("ul"); option = optionList.addChild("li"); HTMLNode optionForm = option.addChild("form", new String[] { "action", "method" }, new String[] {'/' + key.toString(false), "get" }); optionForm.addChild("input", new String[] { "type", "name", "value" }, new String[] { "hidden", "max-size", String.valueOf(e.expectedSize == -1 ? Long.MAX_VALUE : e.expectedSize*2) }); optionForm.addChild("input", new String[] { "type", "name", "value" }, new String[] { "submit", "fetch", "Fetch anyway and display file in browser" }); option = optionList.addChild("li"); optionForm = option.addChild("form", new String[] { "action", "method" }, new String[] { "/queue/", "post" }); optionForm.addChild("input", new String[] { "type", "name", "value" }, new String[] { "hidden", "key", key.toString(false) }); optionForm.addChild("input", new String[] { "type", "name", "value" }, new String[] { "hidden", "return-type", "disk" }); optionForm.addChild("input", new String[] { "type", "name", "value" }, new String[] { "hidden", "persistence", "forever" }); optionForm.addChild("input", new String[] { "type", "name", "value" }, new String[] { "hidden", "formPassword", core.formPassword }); if (mime != null) { optionForm.addChild("input", new String[] { "type", "name", "value" }, new String[] { "hidden", "type", mime }); } optionForm.addChild("input", new String[] { "type", "name", "value" }, new String[] { "submit", "download", "Download in background and store in downloads directory" }); optionList.addChild("li").addChild("a", new String[] { "href", "title" }, new String[] { "/", "FProxy home page" }, "Abort and return to the FProxy home page"); StringBuffer pageBuffer = new StringBuffer(); pageNode.generate(pageBuffer); writeReply(ctx, 200, "text/html", "OK", pageBuffer.toString()); } else { if(e.errorCodes != null) extra = "<pre>"+e.errorCodes.toVerboseString()+"</pre>"; HTMLNode pageNode = ctx.getPageMaker().getPageNode(FetchException.getShortMessage(e.mode)); HTMLNode contentNode = ctx.getPageMaker().getContentNode(pageNode); HTMLNode infobox = contentNode.addChild("div", "class", "infobox infobox-error"); infobox.addChild("div", "class", "infobox-header", FetchException.getShortMessage(e.mode)); HTMLNode infoboxContent = infobox.addChild("div", "class", "infobox-content"); infoboxContent.addChild("#", "Error: " + msg + extra); infoboxContent.addChild("br"); infoboxContent.addChild(ctx.getPageMaker().createBackLink(ctx)); infoboxContent.addChild("br"); infoboxContent.addChild("a", new String[] { "href", "title" }, new String[] { "/", "Node homepage" }, "Homepage"); StringBuffer pageBuffer = new StringBuffer(); pageNode.generate(pageBuffer); this.writeReply(ctx, 500 /* close enough - FIXME probably should depend on status code */, "text/html", FetchException.getShortMessage(e.mode), pageBuffer.toString()); } } catch (Throwable t) { Logger.error(this, "Caught "+t, t); String msg = "<html><head><title>Internal Error</title></head><body><h1>Internal Error: please report</h1><pre>"; StringWriter sw = new StringWriter(); PrintWriter pw = new PrintWriter(sw); t.printStackTrace(pw); pw.flush(); msg = msg + sw.toString() + "</pre></body></html>"; this.writeReply(ctx, 500, "text/html", "Internal Error", msg); } }
48807 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/48807/58e844dc77aa5d1ee9f4952f22f0f7b6b8469457/FProxyToadlet.java/clean/src/freenet/clients/http/FProxyToadlet.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 918, 1640, 967, 12, 3098, 2003, 16, 2974, 361, 1810, 1042, 1103, 13, 1875, 202, 15069, 2974, 361, 1810, 1042, 7395, 503, 16, 1860, 16, 9942, 503, 288, 202, 202, 759, 780, 1165...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 918, 1640, 967, 12, 3098, 2003, 16, 2974, 361, 1810, 1042, 1103, 13, 1875, 202, 15069, 2974, 361, 1810, 1042, 7395, 503, 16, 1860, 16, 9942, 503, 288, 202, 202, 759, 780, 1165...
public void setAngleBendingSecondDerivative(GVector coord3d) { ddDeltav = new double[coord3d.getSize()][][]; Double forAtomNumber = null; int atomNumbern; int atomNumberm; int coordinaten; int coordinatem; double ddDeltav1; double ddDeltav2; double ddDeltav2a; double ddDeltav2b; double ddDeltav2a1; double ddDeltav2a2; double ddDeltav2a3; double ddDeltav2a4; double ddDeltav2a1a; double ddDeltav2a1b; double ddDeltav2a4a1; double ddDeltav2a4a1a; double ddDeltav2a4a1b; double ddDeltav2a4a1c; double ddDeltav2a4a2; double ddDeltav2a4b; double ddDeltav2a4c1; double ddDeltav2a4c1a; double ddDeltav2a4c1b; double ddDeltav2a4c1c; double ddDeltav2a4c2; double ddDeltav2a4d; setAngleBendingFirstDerivative(coord3d); for (int n=0; n<coord3d.getSize(); n++) { ddDeltav[n] = new double[coord3d.getSize()][]; forAtomNumber = new Double(n/3); coordinaten = n % 3; //System.out.println("coordinaten = " + coordinaten); atomNumbern = forAtomNumber.intValue(); //System.out.println("atomNumbern = " + atomNumbern); for (int m = 0; m < coord3d.getSize(); m++) { ddDeltav[n][m] = new double[angleNumber]; forAtomNumber = new Double(m/3); coordinatem = m % 3; //System.out.println("coordinatem = " + coordinatem); atomNumberm = forAtomNumber.intValue(); //System.out.println("atomNumberm = " + atomNumberm); for (int l = 0; l < angleNumber; l++) { if ((angleAtomPosition[l][0] == atomNumberm) | (angleAtomPosition[l][1] == atomNumberm) | (angleAtomPosition[l][2] == atomNumberm)) { if ((angleAtomPosition[l][0] == atomNumbern) | (angleAtomPosition[l][1] == atomNumbern) | (angleAtomPosition[l][2] == atomNumbern)) { Point3d xi = new Point3d(coord3d.getElement(3 * angleAtomPosition[l][0]), coord3d.getElement(3 * angleAtomPosition[l][0] + 1),coord3d.getElement( 3 * angleAtomPosition[l][0] + 2)); //System.out.println("xi = " + xi); Point3d xj = new Point3d(coord3d.getElement(3 * angleAtomPosition[l][1]), coord3d.getElement(3 * angleAtomPosition[l][1] + 1),coord3d.getElement( 3 * angleAtomPosition[l][1] + 2)); //System.out.println("xj = " + xj); Point3d xk = new Point3d(coord3d.getElement(3 * angleAtomPosition[l][2]), coord3d.getElement(3 * angleAtomPosition[l][2] + 1),coord3d.getElement( 3 * angleAtomPosition[l][2] + 2)); //System.out.println("xk = " + xk); Vector3d xij = new Vector3d(); xij.sub(xi,xj); //System.out.println("xij = " + xij); Vector3d xkj = new Vector3d(); xkj.sub(xk,xj); //System.out.println("xkj = " + xkj); double rij = xi.distance(xj); //System.out.println("rij = " + rij); double rkj = xk.distance(xj); //System.out.println("rkj = " + rkj); ddDeltav1 = (-1/Math.sqrt(Math.pow(1-Math.pow(xij.dot(xkj)/(rij * rkj),2),3))) * (xij.dot(xkj)/(rij * rkj)) * (1/(Math.pow(rij,2) * Math.pow(rkj,2))); ddDeltav2 = (-1/Math.sqrt(1-Math.pow(xij.dot(xkj)/(rij * rkj),2))) * (1/(Math.pow(rij,4) * Math.pow(rkj,4))); ddDeltav2a = Math.pow(rij,2) * Math.pow(rkj,2); ddDeltav2a1 = rij * rkj; ddDeltav2a1a = 0; ddDeltav2a1b = 0; ddDeltav2a2 = 0; ddDeltav2a3 = 0; ddDeltav2a4 = xij.dot(xkj); ddDeltav2a4a1a = 0; ddDeltav2a4a1b = 0; ddDeltav2a4a1c = 0; ddDeltav2a4a2 = 0; ddDeltav2b = 0; ddDeltav2a4a1 = 0; ddDeltav2a4b = 0; ddDeltav2a4c1 = 0; ddDeltav2a4c1a = 0; ddDeltav2a4c1b = 0; ddDeltav2a4c1c = 0; ddDeltav2a4c2 = 0; ddDeltav2a4d = 0; //System.out.println("OK: had d1 and have the atomNumbern"); if (angleAtomPosition[l][0] == atomNumberm) { switch (coordinatem) { case 0: ddDeltav1 = ddDeltav1 * ((xk.x-xj.x) * rij * rkj - (xij.dot(xkj)) * rkj * ((xi.x-xj.x)/rij)); ddDeltav2b = (xk.x-xj.x) * rij * rkj - (xij.dot(xkj)) * rkj * ((xi.x-xj.x)/rij); ddDeltav2a1a = 1; ddDeltav2a1b = 0; ddDeltav2a2 = xk.x-xj.x; ddDeltav2a3 = rkj * ((xi.x-xj.x)/rij); ddDeltav2a4a1a = 1; ddDeltav2a4a2 = xi.x-xj.x; ddDeltav2a4c1a = 0; ddDeltav2a4c2 = 0; ddDeltav2a4b = (xi.x-xj.x)/rij; ddDeltav2a4d = 0; break; case 1: ddDeltav1 = ddDeltav1 * ((xk.y-xj.y) * rij * rkj - (xij.dot(xkj)) * rkj * ((xi.y-xj.y)/rij)); ddDeltav2b = (xk.y-xj.y) * rij * rkj - (xij.dot(xkj)) * rkj * ((xi.y-xj.y)/rij); ddDeltav2a1a = 1; ddDeltav2a1b = 0; ddDeltav2a2 = xk.y-xj.y; ddDeltav2a3 = rkj * ((xi.y-xj.y)/rij); ddDeltav2a4a1b = 1; ddDeltav2a4a2 = xi.y-xj.y; ddDeltav2a4c1b = 0; ddDeltav2a4c2 = 0; ddDeltav2a4b = (xi.y-xj.y)/rij; ddDeltav2a4d = 0; break; case 2: ddDeltav1 = ddDeltav1 * ((xk.z-xj.z) * rij * rkj - (xij.dot(xkj)) * rkj * ((xi.z-xj.z)/rij)); ddDeltav2b = (xk.z-xj.z) * rij * rkj - (xij.dot(xkj)) * rkj * ((xi.z-xj.z)/rij); ddDeltav2a1a = 1; ddDeltav2a1b = 0; ddDeltav2a2 = xk.z-xj.z; ddDeltav2a3 = rkj * ((xi.z-xj.z)/rij); ddDeltav2a4a1c = 1; ddDeltav2a4a2 = xi.z-xj.z; ddDeltav2a4c1c = 0; ddDeltav2a4c2 = 0; ddDeltav2a4b = (xi.z-xj.z)/rij; ddDeltav2a4d = 0; break; } } if (angleAtomPosition[l][1] == atomNumberm) { switch (coordinatem) { case 0: ddDeltav1 = ddDeltav1 * ((2 * xj.x - xk.x - xi.x) * rij * rkj - (xij.dot(xkj)) * ((-(xi.x-xj.x)/rij) * rkj + (-(xk.x-xj.x)/rkj) * rij)); ddDeltav2b = (2 * xj.x - xk.x - xi.x) * rij * rkj - (xij.dot(xkj)) * ((-(xi.x-xj.x)/rij) * rkj + (-(xk.x-xj.x)/rkj) * rij); ddDeltav2a1a = -1; ddDeltav2a1b = -1; ddDeltav2a2 = 2 * xj.x - xk.x - xi.x; ddDeltav2a3 = (-(xi.x-xj.x)/rij) * rkj + (-(xk.x-xj.x)/rkj) * rij; ddDeltav2a4a1a = -1; ddDeltav2a4a2 = -(xi.x-xj.x); ddDeltav2a4c1a = -1; ddDeltav2a4c2 = -(xk.x-xj.x); ddDeltav2a4b = -(xi.x-xj.x)/rij; ddDeltav2a4d = -(xk.x-xj.x)/rkj; break; case 1: ddDeltav1 = ddDeltav1 * ((2 * xj.y - xk.y - xi.y) * rij * rkj - (xij.dot(xkj)) * ((-(xi.y-xj.y)/rij) * rkj + (-(xk.y-xj.y)/rkj) * rij)); ddDeltav2b = (2 * xj.y - xk.y - xi.y) * rij * rkj - (xij.dot(xkj)) * ((-(xi.y-xj.y)/rij) * rkj + (-(xk.y-xj.y)/rkj) * rij); ddDeltav2a1a = -1; ddDeltav2a1b = -1; ddDeltav2a2 = 2 * xj.y - xk.y - xi.y; ddDeltav2a3 = (-(xi.y-xj.y)/rij) * rkj + (-(xk.y-xj.y)/rkj) * rij; ddDeltav2a4a1b = -1; ddDeltav2a4a2 = -(xi.y-xj.y); ddDeltav2a4c1b = -1; ddDeltav2a4c2 = -(xk.y-xj.y); ddDeltav2a4b = -(xi.y-xj.y)/rij; ddDeltav2a4d = -(xk.y-xj.y)/rkj; break; case 2: ddDeltav1 = ddDeltav1 * ((2 * xj.z - xk.z - xi.z) * rij * rkj - (xij.dot(xkj)) * ((-(xi.z-xj.z)/rij) * rkj + (-(xk.z-xj.z)/rkj) * rij)); ddDeltav2b = (2 * xj.z - xk.z - xi.z) * rij * rkj - (xij.dot(xkj)) * ((-(xi.z-xj.z)/rij) * rkj + (-(xk.z-xj.z)/rkj) * rij); ddDeltav2a1a = -1; ddDeltav2a1b = -1; ddDeltav2a2 = 2 * xj.z - xk.z - xi.z; ddDeltav2a3 = (-(xi.z-xj.z)/rij) * rkj + (-(xk.z-xj.z)/rkj) * rij; ddDeltav2a4a1c = -1; ddDeltav2a4a2 = -(xi.z-xj.z); ddDeltav2a4c1c = -1; ddDeltav2a4c2 = -(xk.z-xj.z); ddDeltav2a4b = -(xi.z-xj.z)/rij; ddDeltav2a4d = -(xk.z-xj.z)/rkj; break; } } if (angleAtomPosition[l][2] == atomNumberm) { switch (coordinatem) { case 0: ddDeltav1 = ddDeltav1 * ((xi.x-xj.x) * rij * rkj - (xij.dot(xkj)) * rij * ((xk.x-xj.x)/rkj)); ddDeltav2b = (xi.x-xj.x) * rij * rkj - (xij.dot(xkj)) * rij * ((xk.x-xj.x)/rkj); ddDeltav2a1a = 0; ddDeltav2a1b = 1; ddDeltav2a2 = xi.x-xj.x; ddDeltav2a3 = rij * ((xk.x-xj.x)/rkj); ddDeltav2a4a1a = 0; ddDeltav2a4a2 = 0; ddDeltav2a4c1a = 1; ddDeltav2a4c2 = xk.x-xj.x; ddDeltav2a4b = 0; ddDeltav2a4d = (xk.x-xj.x)/rkj; break; case 1: ddDeltav1 = ddDeltav1 * ((xi.y-xj.y) * rij * rkj - (xij.dot(xkj)) * rij * ((xk.y-xj.y)/rkj)); ddDeltav2b = (xi.y-xj.y) * rij * rkj - (xij.dot(xkj)) * rij * ((xk.y-xj.y)/rkj); ddDeltav2a1a = 0; ddDeltav2a1b = 1; ddDeltav2a2 = xi.y-xj.y; ddDeltav2a3 = rij * ((xk.y-xj.y)/rkj); ddDeltav2a4a1b = 0; ddDeltav2a4a2 = 0; ddDeltav2a4c1b = 1; ddDeltav2a4c2 = xk.y-xj.y; ddDeltav2a4b = 0; ddDeltav2a4d = (xk.y-xj.y)/rkj; break; case 2: ddDeltav1 = ddDeltav1 * ((xi.z-xj.z) * rij * rkj - (xij.dot(xkj)) * rij * ((xk.z-xj.z)/rkj)); ddDeltav2b = (xi.z-xj.z) * rij * rkj - (xij.dot(xkj)) * rij * ((xk.z-xj.z)/rkj); ddDeltav2a1a = 0; ddDeltav2a1b = 1; ddDeltav2a2 = xi.z-xj.z; ddDeltav2a3 = rij * ((xk.z-xj.z)/rkj); ddDeltav2a4a1c = 0; ddDeltav2a4a2 = 0; ddDeltav2a4c1c = 1; ddDeltav2a4c2 = xk.z-xj.z; ddDeltav2a4b = 0; ddDeltav2a4d = (xk.z-xj.z)/rkj; break; } } if (angleAtomPosition[l][0] == atomNumbern) { switch (coordinaten) { case 0: ddDeltav1 = ddDeltav1 * ((xk.x-xj.x) * rij * rkj - (xij.dot(xkj)) * rkj * ((xi.x-xj.x)/rij)); ddDeltav2b = ddDeltav2b * 2 * rij * ((xi.x-xj.x)/rij) * Math.pow(rkj,2); ddDeltav2a1a = ddDeltav2a1a * 0; ddDeltav2a1b = ddDeltav2a1b * 1; ddDeltav2a2 = ddDeltav2a2 * rkj * ((xi.x-xj.x)/rij); ddDeltav2a3 = ddDeltav2a3 * (xk.x-xj.x); ddDeltav2a4a1a = ddDeltav2a4a1a * 1; ddDeltav2a4a2 = ddDeltav2a4a2 * ((xi.x-xj.x)/rij); ddDeltav2a4c1a = ddDeltav2a4c1a * 0; ddDeltav2a4c2 = ddDeltav2a4c2 * 0; ddDeltav2a4b = ddDeltav2a4b * 0; ddDeltav2a4d = ddDeltav2a4d * ((xi.x-xj.x)/rij); break; case 1: ddDeltav1 = ddDeltav1 * ((xk.y-xj.y) * rij * rkj - (xij.dot(xkj)) * rkj * ((xi.y-xj.y)/rij)); ddDeltav2b = ddDeltav2b * 2 * rij * ((xi.y-xj.y)/rij) * Math.pow(rkj,2); ddDeltav2a1a = ddDeltav2a1a * 0; ddDeltav2a1b = ddDeltav2a1b * 1; ddDeltav2a2 = ddDeltav2a2 * rkj * ((xi.y-xj.y)/rij); ddDeltav2a3 = ddDeltav2a3 * (xk.y-xj.y); ddDeltav2a4a1b = ddDeltav2a4a1b * 1; ddDeltav2a4a2 = ddDeltav2a4a2 * ((xi.y-xj.y)/rij); ddDeltav2a4c1b = ddDeltav2a4c1b * 0; ddDeltav2a4c2 = ddDeltav2a4c2 * 0; ddDeltav2a4b = ddDeltav2a4b * 0; ddDeltav2a4d = ddDeltav2a4d * ((xi.y-xj.y)/rij); break; case 2: ddDeltav1 = ddDeltav1 * ((xk.z-xj.z) * rij * rkj - (xij.dot(xkj)) * rkj * ((xi.z-xj.z)/rij)); ddDeltav2b = ddDeltav2b * 2 * rij * ((xi.z-xj.z)/rij) * Math.pow(rkj,2); ddDeltav2a1a = ddDeltav2a1a * 0; ddDeltav2a1b = ddDeltav2a1b * 1; ddDeltav2a2 = ddDeltav2a2 * rkj * ((xi.z-xj.z)/rij); ddDeltav2a3 = ddDeltav2a3 * (xk.z-xj.z); ddDeltav2a4a1c = ddDeltav2a4a1c * 1; ddDeltav2a4a2 = ddDeltav2a4a2 * ((xi.z-xj.z)/rij); ddDeltav2a4c1c = ddDeltav2a4c1c * 0; ddDeltav2a4c2 = ddDeltav2a4c2 * 0; ddDeltav2a4b = ddDeltav2a4b * 0; ddDeltav2a4d = ddDeltav2a4d * ((xi.z-xj.z)/rij); break; } } if (angleAtomPosition[l][1] == atomNumbern) { switch (coordinaten) { case 0: ddDeltav1 = ddDeltav1 * ((2 * xj.x - xk.x - xi.x) * rij * rkj - (xij.dot(xkj)) * ((-(xi.x-xj.x)/rij) * rkj + (-(xk.x-xj.x)/rkj) * rij)); ddDeltav2b = ddDeltav2b * (2 * rij * (-(xi.x-xj.x)/rij) * Math.pow(rkj,2) + Math.pow(rij,2) * 2 * rkj * (-(xk.x-xj.x)/rkj)); ddDeltav2a1a = ddDeltav2a1a * -1; ddDeltav2a1b = ddDeltav2a1b * -1; ddDeltav2a2 = ddDeltav2a2 * ((-(xi.x-xj.x)/rij) * rkj + (-(xk.x-xj.x)/rkj) * rij); ddDeltav2a3 = ddDeltav2a3 * (2 * xj.x - xk.x - xi.x); ddDeltav2a4a1a = ddDeltav2a4a1a * (-1); ddDeltav2a4a2 = ddDeltav2a4a2 * (-(xi.x-xj.x)/rij); ddDeltav2a4c1a = ddDeltav2a4c1a * (-1); ddDeltav2a4c2 = ddDeltav2a4c2 * (-(xk.x-xj.x)/rkj); ddDeltav2a4b = ddDeltav2a4b * (-(xk.x-xj.x)/rkj); ddDeltav2a4d = ddDeltav2a4d * (-(xi.x-xj.x)/rij); break; case 1: ddDeltav1 = ddDeltav1 * ((2 * xj.y - xk.y - xi.y) * rij * rkj - (xij.dot(xkj)) * ((-(xi.y-xj.y)/rij) * rkj + (-(xk.y-xj.y)/rkj) * rij)); ddDeltav2b = ddDeltav2b * (2 * rij * (-(xi.y-xj.y)/rij) * Math.pow(rkj,2) + Math.pow(rij,2) * 2 * rkj * (-(xk.y-xj.y)/rkj)); ddDeltav2a1a = ddDeltav2a1a * -1; ddDeltav2a1b = ddDeltav2a1b * -1; ddDeltav2a2 = ddDeltav2a2 * ((-(xi.y-xj.y)/rij) * rkj + (-(xk.y-xj.y)/rkj) * rij); ddDeltav2a3 = ddDeltav2a3 * (2 * xj.y - xk.y - xi.y); ddDeltav2a4a1b = ddDeltav2a4a1b * (-1); ddDeltav2a4a2 = ddDeltav2a4a2 * (-(xi.y-xj.y)/rij); ddDeltav2a4c1b = ddDeltav2a4c1b * (-1); ddDeltav2a4c2 = ddDeltav2a4c2 * (-(xk.y-xj.y)/rkj); ddDeltav2a4b = ddDeltav2a4b * (-(xk.y-xj.y)/rkj); ddDeltav2a4d = ddDeltav2a4d * (-(xi.y-xj.y)/rij); break; case 2: ddDeltav1 = ddDeltav1 * ((2 * xj.z - xk.z - xi.z) * rij * rkj - (xij.dot(xkj)) * ((-(xi.z-xj.z)/rij) * rkj + (-(xk.z-xj.z)/rkj) * rij)); ddDeltav2b = ddDeltav2b * (2 * rij * (-(xi.z-xj.z)/rij) * Math.pow(rkj,2) + Math.pow(rij,2) * 2 * rkj * (-(xk.z-xj.z)/rkj)); ddDeltav2a1a = ddDeltav2a1a * -1; ddDeltav2a1b = ddDeltav2a1b * -1; ddDeltav2a2 = ddDeltav2a2 * ((-(xi.z-xj.z)/rij) * rkj + (-(xk.z-xj.z)/rkj) * rij); ddDeltav2a3 = ddDeltav2a3 * (2 * xj.z - xk.z - xi.z); ddDeltav2a4a1c = ddDeltav2a4a1c * (-1); ddDeltav2a4a2 = ddDeltav2a4a2 * (-(xi.z-xj.z)/rij); ddDeltav2a4c1c = ddDeltav2a4c1c * (-1); ddDeltav2a4c2 = ddDeltav2a4c2 * (-(xk.z-xj.z)/rkj); ddDeltav2a4b = ddDeltav2a4b * (-(xk.z-xj.z)/rkj); ddDeltav2a4d = ddDeltav2a4d * (-(xi.z-xj.z)/rij); break; } } if (angleAtomPosition[l][2] == atomNumbern) { switch (coordinaten) { case 0: ddDeltav1 = ddDeltav1 * ((xi.x-xj.x) * rij * rkj - (xij.dot(xkj)) * rij * ((xk.x-xj.x)/rkj)); ddDeltav2b = ddDeltav2b * Math.pow(rij,2) * 2 * rkj * ((xk.x-xj.x)/rkj); ddDeltav2a1a = ddDeltav2a1a * 1; ddDeltav2a1b = ddDeltav2a1b * 0; ddDeltav2a2 = ddDeltav2a2 * rij * ((xk.x-xj.x)/rkj); ddDeltav2a3 = ddDeltav2a3 * (xi.x-xj.x); ddDeltav2a4a1a = ddDeltav2a4a1a * 0; ddDeltav2a4a2 = ddDeltav2a4a2 * 0; ddDeltav2a4c1a = ddDeltav2a4c1a * 1; ddDeltav2a4c2 = ddDeltav2a4c2 * ((xk.x-xj.x)/rkj); ddDeltav2a4b = ddDeltav2a4b * ((xk.x-xj.x)/rkj); ddDeltav2a4d = ddDeltav2a4d * 0; break; case 1: ddDeltav1 = ddDeltav1 * ((xi.y-xj.y) * rij * rkj - (xij.dot(xkj)) * rij * ((xk.y-xj.y)/rkj)); ddDeltav2b = ddDeltav2b * Math.pow(rij,2) * 2 * rkj * ((xk.y-xj.y)/rkj); ddDeltav2a1a = ddDeltav2a1a * 1; ddDeltav2a1b = ddDeltav2a1b * 0; ddDeltav2a2 = ddDeltav2a2 * rij * ((xk.y-xj.y)/rkj); ddDeltav2a3 = ddDeltav2a3 * (xi.y-xj.y); ddDeltav2a4a1b = ddDeltav2a4a1b * 0; ddDeltav2a4a2 = ddDeltav2a4a2 * 0; ddDeltav2a4c1b = ddDeltav2a4c1b * 1; ddDeltav2a4c2 = ddDeltav2a4c2 * ((xk.y-xj.y)/rkj); ddDeltav2a4b = ddDeltav2a4b * ((xk.y-xj.y)/rkj); ddDeltav2a4d = ddDeltav2a4d * 0; break; case 2: ddDeltav1 = ddDeltav1 * ((xi.z-xj.z) * rij * rkj - (xij.dot(xkj)) * rij * ((xk.z-xj.z)/rkj)); ddDeltav2b = ddDeltav2b * Math.pow(rij,2) * 2 * rkj * ((xk.z-xj.z)/rkj); ddDeltav2a1a = ddDeltav2a1a * 1; ddDeltav2a1b = ddDeltav2a1b * 0; ddDeltav2a2 = ddDeltav2a2 * rij * ((xk.z-xj.z)/rkj); ddDeltav2a3 = ddDeltav2a3 * (xi.z-xj.z); ddDeltav2a4a1c = ddDeltav2a4a1c * 0; ddDeltav2a4a2 = ddDeltav2a4a2 * 0; ddDeltav2a4c1c = ddDeltav2a4c1c * 1; ddDeltav2a4c2 = ddDeltav2a4c2 * ((xk.z-xj.z)/rkj); ddDeltav2a4b = ddDeltav2a4b * ((xk.z-xj.z)/rkj); ddDeltav2a4d = ddDeltav2a4d * 0; break; } } ddDeltav2a4a1 = (ddDeltav2a4a1a + ddDeltav2a4a1b + ddDeltav2a4a1c) * rij; ddDeltav2a4c1 = (ddDeltav2a4c1a + ddDeltav2a4c1b + ddDeltav2a4c1c) * rkj; ddDeltav2a4 = ddDeltav2a4 * (((ddDeltav2a4a1 - ddDeltav2a4a2) / Math.pow(rij,2)) * rkj + ddDeltav2a4b + ((ddDeltav2a4c1 + ddDeltav2a4c2) / Math.pow(rkj,2)) * rij + ddDeltav2a4d); ddDeltav2 = ddDeltav2 * (((ddDeltav2a1a + ddDeltav2a1b) * ddDeltav2a1 + ddDeltav2a2 - ddDeltav2a3 - ddDeltav2a4) * ddDeltav2a - ddDeltav2b); ddDeltav[n][m][l] = ddDeltav1 + ddDeltav2; } } else { ddDeltav[n][m][l] = 0; } //System.out.println("ddDeltav[" + n + "][" + m + "][" + l + "] = " + ddDeltav[n][m][l]); } } } }
45167 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/45167/9adcbd5769512fe518277f87ee5cc7c84de1ccb0/AngleBending.java/clean/src/org/openscience/cdk/modeling/forcefield/AngleBending.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 918, 444, 8467, 38, 2846, 8211, 26239, 1535, 12, 43, 5018, 2745, 23, 72, 13, 288, 9506, 202, 449, 2837, 88, 842, 273, 394, 1645, 63, 5732, 23, 72, 18, 588, 1225, 1435, 6362,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 444, 8467, 38, 2846, 8211, 26239, 1535, 12, 43, 5018, 2745, 23, 72, 13, 288, 9506, 202, 449, 2837, 88, 842, 273, 394, 1645, 63, 5732, 23, 72, 18, 588, 1225, 1435, 6362,...
asm.emitMOV_RegIdx_Reg_Word(T1, S0, asm.BYTE, 0, T0);
asm.emitMOV_RegIdx_Reg_Word(T1, S0, asm.BYTE, NO_SLOT, T0);
private final boolean genMagic (VM_MethodReference m) { VM_Atom methodName = m.getName(); if (m.getType() == VM_TypeReference.Address) { // Address magic VM_TypeReference[] types = m.getParameterTypes(); // Loads all take the form: // ..., Address, [Offset] -> ..., Value if (methodName == VM_MagicNames.loadAddress || methodName == VM_MagicNames.prepareAddress || methodName == VM_MagicNames.prepareObjectReference || methodName == VM_MagicNames.loadWord || methodName == VM_MagicNames.loadObjectReference || methodName == VM_MagicNames.prepareWord || methodName == VM_MagicNames.loadInt || methodName == VM_MagicNames.prepareInt || methodName == VM_MagicNames.loadFloat) { if (types.length == 0) { // No offset asm.emitPOP_Reg(T0); // address asm.emitPUSH_RegInd(T0); // pushes [T0+0] } else { // Load at offset asm.emitPOP_Reg (S0); // offset asm.emitPOP_Reg (T0); // object ref asm.emitPUSH_RegIdx(T0, S0, asm.BYTE, 0); // pushes [T0+S0] } return true; } if (methodName == VM_MagicNames.loadByte) { if (types.length == 0) { // No offset asm.emitPOP_Reg (T0); // base asm.emitMOVZX_Reg_RegInd_Byte(T0, T0) ; asm.emitPUSH_Reg (T0); } else { // Load at offset asm.emitPOP_Reg (S0); // offset asm.emitPOP_Reg (T0); // base asm.emitMOVZX_Reg_RegIdx_Byte(T0, T0, S0, asm.BYTE, 0); // load and zero extend byte [T0+S0] asm.emitPUSH_Reg (T0); } return true; } if (methodName == VM_MagicNames.loadShort || methodName == VM_MagicNames.loadChar) { if (types.length == 0) { // No offset asm.emitPOP_Reg (T0); // base asm.emitMOVZX_Reg_RegInd_Word(T0, T0); asm.emitPUSH_Reg (T0); } else { // Load at offset asm.emitPOP_Reg (S0); // offset asm.emitPOP_Reg (T0); // base asm.emitMOVZX_Reg_RegIdx_Word(T0, T0, S0, asm.BYTE, 0); // load and zero extend word [T0+S0] asm.emitPUSH_Reg (T0); } return true; } if (methodName == VM_MagicNames.loadLong || methodName == VM_MagicNames.loadDouble) { if (types.length == 0) { // No offset throw new RuntimeException("Magic not implemented"); } else { // Load at offset asm.emitPOP_Reg (S0); // offset asm.emitPOP_Reg (T0); // base asm.emitPUSH_RegIdx(T0, S0, asm.BYTE, 4); // pushes [T0+S0+4] asm.emitPUSH_RegIdx(T0, S0, asm.BYTE, 0); // pushes [T0+S0] } return true; } // Stores all take the form: // ..., Address, [Offset], Value -> ... if (methodName == VM_MagicNames.store) { // Always at least one parameter to a store. // First parameter is the type to be stored. VM_TypeReference storeType = types[0]; if (storeType == VM_TypeReference.Int || storeType == VM_TypeReference.Address || storeType == VM_TypeReference.ObjectReference || storeType == VM_TypeReference.Word || storeType == VM_TypeReference.Float) { if (types.length == 1) { // No offset asm.emitPOP_Reg(T0); // value asm.emitPOP_Reg(S0); // address asm.emitMOV_RegInd_Reg(S0,T0); // [S0+0] <- T0 } else { // Store at offset asm.emitPOP_Reg(S0); // offset asm.emitPOP_Reg(T0); // value asm.emitPOP_Reg(T1); // address asm.emitMOV_RegIdx_Reg(T1, S0, asm.BYTE, 0, T0); // [T1+S0] <- T0 } return true; } if (storeType == VM_TypeReference.Byte) { if (types.length == 1) { // No offset asm.emitPOP_Reg(T0); // value asm.emitPOP_Reg(T1); // base asm.emitMOV_RegInd_Reg_Byte(T1, T0); } else { // Store at offset asm.emitPOP_Reg(S0); // offset asm.emitPOP_Reg(T0); // value asm.emitPOP_Reg(T1); // base asm.emitMOV_RegIdx_Reg_Byte(T1, S0, asm.BYTE, 0, T0); // [T1+S0] <- (byte) T0 } return true; } if (storeType == VM_TypeReference.Short || storeType == VM_TypeReference.Char) { if (types.length == 1) { // No offset asm.emitPOP_Reg(T0); // value asm.emitPOP_Reg(T1); // base asm.emitMOV_RegInd_Reg_Word(T1, T0); } else { // Store at offset asm.emitPOP_Reg(S0); // offset asm.emitPOP_Reg(T0); // value asm.emitPOP_Reg(T1); // base asm.emitMOV_RegIdx_Reg_Word(T1, S0, asm.BYTE, 0, T0); // [T1+S0] <- (word) T0 } return true; } if (storeType == VM_TypeReference.Double || storeType == VM_TypeReference.Long) { if (types.length == 1) { // No offset throw new RuntimeException("Magic not implemented"); } else { // Store at offset asm.emitMOV_Reg_RegDisp(T0, SP, +4); // value high asm.emitMOV_Reg_RegInd (S0, SP); // offset asm.emitMOV_Reg_RegDisp(T1, SP, +12); // base asm.emitMOV_RegIdx_Reg (T1, S0, asm.BYTE, 0, T0); // [T1+S0] <- T0 asm.emitMOV_Reg_RegDisp(T0, SP, +8); // value low asm.emitMOV_RegIdx_Reg (T1, S0, asm.BYTE, 4, T0); // [T1+S0+4] <- T0 asm.emitADD_Reg_Imm (SP, WORDSIZE * 4); // pop stack locations } return true; } } else if (methodName == VM_MagicNames.attempt) { // All attempts are similar 32 bit values. if (types.length == 3) { // Offset passed asm.emitPOP_Reg (S0); // S0 = offset } asm.emitPOP_Reg (T1); // newVal asm.emitPOP_Reg (EAX); // oldVal (EAX is implicit arg to LCMPX if (types.length == 3) { asm.emitADD_Reg_RegInd(S0, SP); // S0 += base } else { // No offset asm.emitMOV_Reg_RegInd(S0, SP); // S0 = base } asm.emitLockNextInstruction(); asm.emitCMPXCHG_RegInd_Reg (S0, T1); // atomic compare-and-exchange asm.emitMOV_RegInd_Imm (SP, 0); // 'push' false (overwriting base) VM_ForwardReference fr = asm.forwardJcc(asm.NE); // skip if compare fails asm.emitMOV_RegInd_Imm (SP, 1); // 'push' true (overwriting base) fr.resolve(asm); return true; } } if (methodName == VM_MagicNames.attemptInt || methodName == VM_MagicNames.attemptObject || methodName == VM_MagicNames.attemptAddress || methodName == VM_MagicNames.attemptWord) { // attempt gets called with four arguments: base, offset, oldVal, newVal // returns ([base+offset] == oldVal) // if ([base+offset] == oldVal) [base+offset] := newVal // (operation on memory is atomic) asm.emitPOP_Reg (T1); // newVal asm.emitPOP_Reg (EAX); // oldVal (EAX is implicit arg to LCMPXCNG asm.emitPOP_Reg (S0); // S0 = offset asm.emitADD_Reg_RegInd(S0, SP); // S0 += base asm.emitLockNextInstruction(); asm.emitCMPXCHG_RegInd_Reg (S0, T1); // atomic compare-and-exchange asm.emitMOV_RegInd_Imm (SP, 0); // 'push' false (overwriting base) VM_ForwardReference fr = asm.forwardJcc(asm.NE); // skip if compare fails asm.emitMOV_RegInd_Imm (SP, 1); // 'push' true (overwriting base) fr.resolve(asm); return true; } if (methodName == VM_MagicNames.invokeMain) { // invokeMain gets "called" with two arguments: // String[] mainArgs // the arguments to the main method // INSTRUCTION[] mainCode // the code for the main method asm.emitPOP_Reg (S0); // genParameterRegisterLoad(1); // pass 1 parameter word asm.emitCALL_Reg(S0); // branches to mainCode with mainArgs on the stack return true; } if (methodName == VM_MagicNames.saveThreadState) { int offset = VM_Entrypoints.saveThreadStateInstructionsField.getOffsetAsInt(); genParameterRegisterLoad(1); // pass 1 parameter word asm.emitCALL_RegDisp(JTOC, offset); return true; } if (methodName == VM_MagicNames.threadSwitch) { int offset = VM_Entrypoints.threadSwitchInstructionsField.getOffsetAsInt(); genParameterRegisterLoad(2); // pass 2 parameter words asm.emitCALL_RegDisp(JTOC, offset); return true; } if (methodName == VM_MagicNames.restoreHardwareExceptionState) { int offset = VM_Entrypoints.restoreHardwareExceptionStateInstructionsField.getOffsetAsInt(); genParameterRegisterLoad(1); // pass 1 parameter word asm.emitCALL_RegDisp(JTOC, offset); return true; } if (methodName == VM_MagicNames.invokeClassInitializer) { asm.emitPOP_Reg (S0); asm.emitCALL_Reg(S0); // call address just popped return true; } if (m.getType() == VM_TypeReference.SysCall) { VM_TypeReference[] args = m.getParameterTypes(); VM_TypeReference rtype = m.getReturnType(); int offsetToJavaArg = 3*WORDSIZE; // the three regs saved in (2) int paramBytes = 0; // (1) save three RVM nonvolatile/special registers // we don't have to save EBP: the callee will // treat it as a framepointer and save/restore // it for us. asm.emitPUSH_Reg(EBX); asm.emitPUSH_Reg(ESI); asm.emitPUSH_Reg(EDI); // (2) Push args to target function (reversed) for (int i=args.length-1; i>=0; i--) { VM_TypeReference arg = args[i]; if (arg.isLongType() || arg.isDoubleType()) { asm.emitPUSH_RegDisp(SP, offsetToJavaArg + 4); asm.emitPUSH_RegDisp(SP, offsetToJavaArg + 4); offsetToJavaArg += 16; paramBytes += 8; } else { asm.emitPUSH_RegDisp(SP, offsetToJavaArg); offsetToJavaArg += 8; paramBytes += 4; } } // (3) invoke target function VM_Field ip = VM_Entrypoints.getSysCallField(m.getName().toString()); asm.emitMOV_Reg_RegDisp(S0, JTOC, VM_Entrypoints.the_boot_recordField.getOffsetAsInt()); asm.emitCALL_RegDisp(S0, ip.getOffsetAsInt()); // (4) pop space for arguments asm.emitADD_Reg_Imm(SP, paramBytes); // (5) restore RVM registers asm.emitPOP_Reg(EDI); asm.emitPOP_Reg(ESI); asm.emitPOP_Reg(EBX); // (6) pop expression stack asm.emitADD_Reg_Imm(SP, paramBytes); // (7) push return value if (rtype.isLongType()) { asm.emitPUSH_Reg(T1); asm.emitPUSH_Reg(T0); } else if (rtype.isDoubleType()) { asm.emitSUB_Reg_Imm(SP, 8); asm.emitFSTP_RegInd_Reg_Quad(SP, FP0); } else if (rtype.isFloatType()) { asm.emitSUB_Reg_Imm(SP, 4); asm.emitFSTP_RegInd_Reg(SP, FP0); } else if (!rtype.isVoidType()) { asm.emitPUSH_Reg(T0); } return true; } if (methodName == VM_MagicNames.getFramePointer) { asm.emitLEA_Reg_RegDisp(S0, SP, fp2spOffset(0)); asm.emitPUSH_Reg (S0); return true; } if (methodName == VM_MagicNames.getCallerFramePointer) { asm.emitPOP_Reg(T0); // Callee FP asm.emitPUSH_RegDisp(T0, STACKFRAME_FRAME_POINTER_OFFSET); // Caller FP return true; } if (methodName == VM_MagicNames.setCallerFramePointer) { asm.emitPOP_Reg(T0); // value asm.emitPOP_Reg(S0); // fp asm.emitMOV_RegDisp_Reg(S0, STACKFRAME_FRAME_POINTER_OFFSET, T0); // [S0+SFPO] <- T0 return true; } if (methodName == VM_MagicNames.getCompiledMethodID) { asm.emitPOP_Reg(T0); // Callee FP asm.emitPUSH_RegDisp(T0, STACKFRAME_METHOD_ID_OFFSET); // Callee CMID return true; } if (methodName == VM_MagicNames.setCompiledMethodID) { asm.emitPOP_Reg(T0); // value asm.emitPOP_Reg(S0); // fp asm.emitMOV_RegDisp_Reg(S0, STACKFRAME_METHOD_ID_OFFSET, T0); // [S0+SMIO] <- T0 return true; } if (methodName == VM_MagicNames.getReturnAddressLocation) { asm.emitPOP_Reg(T0); // Callee FP asm.emitADD_Reg_Imm(T0, STACKFRAME_RETURN_ADDRESS_OFFSET); // location containing callee return address asm.emitPUSH_Reg(T0); // Callee return address return true; } if (methodName == VM_MagicNames.getTocPointer || methodName == VM_MagicNames.getJTOC ) { asm.emitPUSH_Reg(JTOC); return true; } // get the processor register (PR) if (methodName == VM_MagicNames.getProcessorRegister) { asm.emitPUSH_Reg(PR); return true; } // set the processor register (PR) if (methodName == VM_MagicNames.setProcessorRegister) { asm.emitPOP_Reg(PR); return true; } // Get the value in ESI if (methodName == VM_MagicNames.getESIAsProcessor) { asm.emitPUSH_Reg(ESI); return true; } // Set the value in ESI if (methodName == VM_MagicNames.setESIAsProcessor) { asm.emitPOP_Reg(ESI); return true; } if (methodName == VM_MagicNames.getIntAtOffset || methodName == VM_MagicNames.getWordAtOffset || methodName == VM_MagicNames.getObjectAtOffset || methodName == VM_MagicNames.getObjectArrayAtOffset || methodName == VM_MagicNames.prepareInt || methodName == VM_MagicNames.prepareObject || methodName == VM_MagicNames.prepareAddress || methodName == VM_MagicNames.prepareWord) { asm.emitPOP_Reg (T0); // object ref asm.emitPOP_Reg (S0); // offset asm.emitPUSH_RegIdx(T0, S0, asm.BYTE, 0); // pushes [T0+S0] return true; } if (methodName == VM_MagicNames.getByteAtOffset) { asm.emitPOP_Reg (T0); // object ref asm.emitPOP_Reg (S0); // offset asm.emitMOVZX_Reg_RegIdx_Byte(T0, T0, S0, asm.BYTE, 0); // load and zero extend byte [T0+S0] asm.emitPUSH_Reg (T0); return true; } if (methodName == VM_MagicNames.getCharAtOffset) { asm.emitPOP_Reg (T0); // object ref asm.emitPOP_Reg (S0); // offset asm.emitMOVZX_Reg_RegIdx_Word(T0, T0, S0, asm.BYTE, 0); // load and zero extend char [T0+S0] asm.emitPUSH_Reg (T0); return true; } if (methodName == VM_MagicNames.setIntAtOffset || methodName == VM_MagicNames.setWordAtOffset || methodName == VM_MagicNames.setObjectAtOffset ) { if (m.getParameterTypes().length == 4) { // discard locationMetadata parameter asm.emitPOP_Reg(T0); // locationMetadata, not needed by baseline compiler. } asm.emitPOP_Reg(T0); // value asm.emitPOP_Reg(S0); // offset asm.emitPOP_Reg(T1); // obj ref asm.emitMOV_RegIdx_Reg(T1, S0, asm.BYTE, 0, T0); // [T1+S0] <- T0 return true; } if (methodName == VM_MagicNames.setByteAtOffset) { asm.emitPOP_Reg(T0); // value asm.emitPOP_Reg(S0); // offset asm.emitPOP_Reg(T1); // obj ref asm.emitMOV_RegIdx_Reg_Byte(T1, S0, asm.BYTE, 0, T0); // [T1+S0] <- (byte) T0 return true; } if (methodName == VM_MagicNames.setCharAtOffset) { asm.emitPOP_Reg(T0); // value asm.emitPOP_Reg(S0); // offset asm.emitPOP_Reg(T1); // obj ref asm.emitMOV_RegIdx_Reg_Word(T1, S0, asm.BYTE, 0, T0); // [T1+S0] <- (char) T0 return true; } if (methodName == VM_MagicNames.getLongAtOffset || methodName == VM_MagicNames.getDoubleAtOffset) { asm.emitPOP_Reg (T0); // object ref asm.emitPOP_Reg (S0); // offset asm.emitPUSH_RegIdx(T0, S0, asm.BYTE, 4); // pushes [T0+S0+4] asm.emitPUSH_RegIdx(T0, S0, asm.BYTE, 0); // pushes [T0+S0] return true; } if (methodName == VM_MagicNames.setLongAtOffset || methodName == VM_MagicNames.setDoubleAtOffset) { asm.emitMOV_Reg_RegInd (T0, SP); // value high asm.emitMOV_Reg_RegDisp(S0, SP, +8 ); // offset asm.emitMOV_Reg_RegDisp(T1, SP, +12); // obj ref asm.emitMOV_RegIdx_Reg (T1, S0, asm.BYTE, 0, T0); // [T1+S0] <- T0 asm.emitMOV_Reg_RegDisp(T0, SP, +4 ); // value low asm.emitMOV_RegIdx_Reg (T1, S0, asm.BYTE, 4, T0); // [T1+S0+4] <- T0 asm.emitADD_Reg_Imm (SP, WORDSIZE * 4); // pop stack locations return true; } if (methodName == VM_MagicNames.addressArrayCreate) { // no resolution problem possible. emit_resolved_newarray(m.getType().resolve().asArray()); return true; } if (methodName == VM_MagicNames.addressArrayLength) { emit_arraylength(); // argument order already correct return true; } if (methodName == VM_MagicNames.addressArrayGet) { if (m.getType() == VM_TypeReference.CodeArray) { emit_baload(); } else { if (VM.BuildFor32Addr) { emit_iaload(); } else if (VM.BuildFor64Addr) { emit_laload(); } else { VM._assert(NOT_REACHED); } } return true; } if (methodName == VM_MagicNames.addressArraySet) { if (m.getType() == VM_TypeReference.CodeArray) { emit_bastore(); } else { if (VM.BuildFor32Addr) { emit_iastore(); } else if (VM.BuildFor64Addr) { VM._assert(false); // not implemented } else { VM._assert(NOT_REACHED); } } return true; } if (methodName == VM_MagicNames.getMemoryInt || methodName == VM_MagicNames.getMemoryWord || methodName == VM_MagicNames.getMemoryAddress) { asm.emitPOP_Reg(T0); // address asm.emitPUSH_RegInd(T0); // pushes [T0+0] return true; } if (methodName == VM_MagicNames.setMemoryInt || methodName == VM_MagicNames.setMemoryWord || methodName == VM_MagicNames.setMemoryAddress) { if (m.getParameterTypes().length == 3) { // discard locationMetadata parameter asm.emitPOP_Reg(T0); // locationMetadata, not needed by baseline compiler. } asm.emitPOP_Reg(T0); // value asm.emitPOP_Reg(S0); // address asm.emitMOV_RegInd_Reg(S0,T0); // [S0+0] <- T0 return true; } if (methodName == VM_MagicNames.objectAsAddress || methodName == VM_MagicNames.addressAsByteArray || methodName == VM_MagicNames.addressAsIntArray || methodName == VM_MagicNames.addressAsObject || methodName == VM_MagicNames.addressAsObjectArray || methodName == VM_MagicNames.addressAsType || methodName == VM_MagicNames.objectAsType || methodName == VM_MagicNames.objectAsShortArray || methodName == VM_MagicNames.objectAsByteArray || methodName == VM_MagicNames.objectAsIntArray || methodName == VM_MagicNames.addressAsThread || methodName == VM_MagicNames.objectAsThread || methodName == VM_MagicNames.objectAsProcessor || methodName == VM_MagicNames.threadAsCollectorThread || methodName == VM_MagicNames.addressAsRegisters || methodName == VM_MagicNames.addressAsStack || methodName == VM_MagicNames.floatAsIntBits || methodName == VM_MagicNames.intBitsAsFloat || methodName == VM_MagicNames.doubleAsLongBits || methodName == VM_MagicNames.longBitsAsDouble) { // no-op (a type change, not a representation change) return true; } // code for VM_Type VM_Magic.getObjectType(Object object) if (methodName == VM_MagicNames.getObjectType) { asm.emitPOP_Reg (T0); // object ref VM_ObjectModel.baselineEmitLoadTIB(asm,S0,T0); asm.emitPUSH_RegDisp(S0, TIB_TYPE_INDEX<<LG_WORDSIZE); // push VM_Type slot of TIB return true; } if (methodName == VM_MagicNames.getArrayLength) { asm.emitPOP_Reg(T0); // object ref asm.emitPUSH_RegDisp(T0, VM_ObjectModel.getArrayLengthOffset().toInt()); return true; } if (methodName == VM_MagicNames.sync) { // nothing required on IA32 return true; } if (methodName == VM_MagicNames.isync) { // nothing required on IA32 return true; } // baseline compiled invocation only: all paramaters on the stack // hi mem // Code // GPRs // FPRs // Spills // low-mem if (methodName == VM_MagicNames.invokeMethodReturningVoid) { int offset = VM_Entrypoints.reflectiveMethodInvokerInstructionsField.getOffsetAsInt(); genParameterRegisterLoad(4); // pass 4 parameter words asm.emitCALL_RegDisp(JTOC, offset); return true; } if (methodName == VM_MagicNames.invokeMethodReturningInt) { int offset = VM_Entrypoints.reflectiveMethodInvokerInstructionsField.getOffsetAsInt(); genParameterRegisterLoad(4); // pass 4 parameter words asm.emitCALL_RegDisp(JTOC, offset); asm.emitPUSH_Reg(T0); return true; } if (methodName == VM_MagicNames.invokeMethodReturningLong) { int offset = VM_Entrypoints.reflectiveMethodInvokerInstructionsField.getOffsetAsInt(); genParameterRegisterLoad(4); // pass 4 parameter words asm.emitCALL_RegDisp(JTOC, offset); asm.emitPUSH_Reg(T0); // high half asm.emitPUSH_Reg(T1); // low half return true; } if (methodName == VM_MagicNames.invokeMethodReturningFloat) { int offset = VM_Entrypoints.reflectiveMethodInvokerInstructionsField.getOffsetAsInt(); genParameterRegisterLoad(4); // pass 4 parameter words asm.emitCALL_RegDisp(JTOC, offset); asm.emitSUB_Reg_Imm (SP, 4); asm.emitFSTP_RegInd_Reg(SP, FP0); return true; } if (methodName == VM_MagicNames.invokeMethodReturningDouble) { int offset = VM_Entrypoints.reflectiveMethodInvokerInstructionsField.getOffsetAsInt(); genParameterRegisterLoad(4); // pass 4 parameter words asm.emitCALL_RegDisp(JTOC, offset); asm.emitSUB_Reg_Imm (SP, 8); asm.emitFSTP_RegInd_Reg_Quad(SP, FP0); return true; } if (methodName == VM_MagicNames.invokeMethodReturningObject) { int offset = VM_Entrypoints.reflectiveMethodInvokerInstructionsField.getOffsetAsInt(); genParameterRegisterLoad(4); // pass 4 parameter words asm.emitCALL_RegDisp(JTOC, offset); asm.emitPUSH_Reg(T0); return true; } // baseline invocation // one paramater, on the stack -- actual code if (methodName == VM_MagicNames.dynamicBridgeTo) { if (VM.VerifyAssertions) VM._assert(klass.isDynamicBridge()); // save the branch address for later asm.emitPOP_Reg (S0); // S0<-code address asm.emitADD_Reg_Imm(SP, fp2spOffset(0) - 4); // just popped 4 bytes above. // restore FPU state asm.emitFRSTOR_RegDisp(SP, FPU_SAVE_OFFSET); // restore GPRs asm.emitMOV_Reg_RegDisp (T0, SP, T0_SAVE_OFFSET); asm.emitMOV_Reg_RegDisp (T1, SP, T1_SAVE_OFFSET); asm.emitMOV_Reg_RegDisp (EBX, SP, EBX_SAVE_OFFSET); asm.emitMOV_Reg_RegDisp (JTOC, SP, JTOC_SAVE_OFFSET); // pop frame asm.emitPOP_RegDisp (PR, VM_Entrypoints.framePointerField.getOffsetAsInt()); // FP<-previous FP // branch asm.emitJMP_Reg (S0); return true; } if (methodName == VM_MagicNames.returnToNewStack) { // SP gets frame pointer for new stack asm.emitPOP_Reg (SP); // restore nonvolatile registers asm.emitMOV_Reg_RegDisp (JTOC, SP, JTOC_SAVE_OFFSET); asm.emitMOV_Reg_RegDisp (EBX, SP, EBX_SAVE_OFFSET); // discard current stack frame asm.emitPOP_RegDisp (PR, VM_Entrypoints.framePointerField.getOffsetAsInt()); // return to caller- pop parameters from stack asm.emitRET_Imm(parameterWords << LG_WORDSIZE); return true; } if (methodName == VM_MagicNames.roundToZero) { // Store the FPU Control Word to a JTOC slot asm.emitFNSTCW_RegDisp(JTOC, VM_Entrypoints.FPUControlWordField.getOffsetAsInt()); // Set the bits in the status word that control round to zero. // Note that we use a 32-bit OR, even though we only care about the // low-order 16 bits asm.emitOR_RegDisp_Imm(JTOC,VM_Entrypoints.FPUControlWordField.getOffsetAsInt(), 0x00000c00); // Now store the result back into the FPU Control Word asm.emitFLDCW_RegDisp(JTOC,VM_Entrypoints.FPUControlWordField.getOffsetAsInt()); return true; } if (methodName == VM_MagicNames.clearFloatingPointState) { // Clear the hardware floating-point state asm.emitFNINIT(); return true; } if (methodName == VM_MagicNames.getTimeBase) { asm.emitRDTSC(); // read timestamp counter instruction asm.emitPUSH_Reg(EDX); // upper 32 bits asm.emitPUSH_Reg(EAX); // lower 32 bits return true; } if (methodName == VM_MagicNames.wordFromInt || methodName == VM_MagicNames.wordFromObject || methodName == VM_MagicNames.wordFromIntZeroExtend || methodName == VM_MagicNames.wordFromIntSignExtend || methodName == VM_MagicNames.wordToInt || methodName == VM_MagicNames.wordToAddress || methodName == VM_MagicNames.wordToOffset || methodName == VM_MagicNames.wordToObject || methodName == VM_MagicNames.wordToObjectReference || methodName == VM_MagicNames.wordToExtent || methodName == VM_MagicNames.wordToWord) { if (VM.BuildFor32Addr) return true; // no-op for 32-bit if (VM.VerifyAssertions) VM._assert(false); } if (methodName == VM_MagicNames.wordToLong) { if (VM.BuildFor32Addr) { asm.emitPOP_Reg(T0); asm.emitPUSH_Imm(0); // upper 32 bits asm.emitPUSH_Reg(T0); // lower 32 bits return true; } // else fill unused stackslot if (VM.VerifyAssertions) VM._assert(false); } if (methodName == VM_MagicNames.wordAnd) { asm.emitPOP_Reg(T0); asm.emitAND_RegInd_Reg(SP, T0); return true; } if (methodName == VM_MagicNames.wordOr) { asm.emitPOP_Reg(T0); asm.emitOR_RegInd_Reg(SP, T0); return true; } if (methodName == VM_MagicNames.wordXor) { asm.emitPOP_Reg(T0); asm.emitXOR_RegInd_Reg(SP, T0); return true; } if (methodName == VM_MagicNames.wordNot) { asm.emitNOT_RegInd (SP); return true; } if (methodName == VM_MagicNames.wordAdd) { asm.emitPOP_Reg(T0); asm.emitADD_RegInd_Reg(SP, T0); return true; } if (methodName == VM_MagicNames.wordSub || methodName == VM_MagicNames.wordDiff) { asm.emitPOP_Reg(T0); asm.emitSUB_RegInd_Reg(SP, T0); return true; } if (methodName == VM_MagicNames.wordZero || methodName == VM_MagicNames.wordNull) { asm.emitPUSH_Imm(0); return true; } if (methodName == VM_MagicNames.wordOne) { asm.emitPUSH_Imm(1); return true; } if (methodName == VM_MagicNames.wordMax) { asm.emitPUSH_Imm(-1); return true; } if (methodName == VM_MagicNames.wordLT) { generateAddrComparison(asm.LLT); return true; } if (methodName == VM_MagicNames.wordLE) { generateAddrComparison(asm.LLE); return true; } if (methodName == VM_MagicNames.wordGT) { generateAddrComparison(asm.LGT); return true; } if (methodName == VM_MagicNames.wordGE) { generateAddrComparison(asm.LGE); return true; } if (methodName == VM_MagicNames.wordsLT) { generateAddrComparison(asm.LT); return true; } if (methodName == VM_MagicNames.wordsLE) { generateAddrComparison(asm.LE); return true; } if (methodName == VM_MagicNames.wordsGT) { generateAddrComparison(asm.GT); return true; } if (methodName == VM_MagicNames.wordsGE) { generateAddrComparison(asm.GE); return true; } if (methodName == VM_MagicNames.wordEQ) { generateAddrComparison(asm.EQ); return true; } if (methodName == VM_MagicNames.wordNE) { generateAddrComparison(asm.NE); return true; } if (methodName == VM_MagicNames.wordIsZero) { asm.emitPUSH_Imm(0); generateAddrComparison(asm.EQ); return true; } if (methodName == VM_MagicNames.wordIsNull) { asm.emitPUSH_Imm(0); generateAddrComparison(asm.EQ); return true; } if (methodName == VM_MagicNames.wordIsMax) { asm.emitPUSH_Imm(-1); generateAddrComparison(asm.EQ); return true; } if (methodName == VM_MagicNames.wordLsh) { if (VM.BuildFor32Addr) { asm.emitPOP_Reg(ECX); asm.emitSHL_RegInd_Reg(SP, ECX); } else VM._assert(false); return true; } if (methodName == VM_MagicNames.wordRshl) { if (VM.BuildFor32Addr) { asm.emitPOP_Reg (ECX); asm.emitSHR_RegInd_Reg (SP, ECX); } else VM._assert(false); return true; } if (methodName == VM_MagicNames.wordRsha) { if (VM.BuildFor32Addr) { asm.emitPOP_Reg (ECX); asm.emitSAR_RegInd_Reg (SP, ECX); } else VM._assert(false); return true; } return false; }
5245 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5245/c19269673fcdd14e39a92c30e8ccef4cb7ce0402/VM_Compiler.java/clean/rvm/src/vm/arch/intel/compilers/baseline/VM_Compiler.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 282, 3238, 727, 1250, 3157, 19289, 261, 7397, 67, 1305, 2404, 312, 13, 288, 565, 8251, 67, 3641, 4918, 273, 312, 18, 17994, 5621, 565, 309, 261, 81, 18, 588, 559, 1435, 422, 8251, 67, 7534, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 282, 3238, 727, 1250, 3157, 19289, 261, 7397, 67, 1305, 2404, 312, 13, 288, 565, 8251, 67, 3641, 4918, 273, 312, 18, 17994, 5621, 565, 309, 261, 81, 18, 588, 559, 1435, 422, 8251, 67, 7534, ...
if(pos >= token.start && pos <= token.end)
if(pos >= token.getStart() && pos <= token.getEnd())
public Token getTokenAtPosition(int pos) { Iterator iterator = editor.getTokens().iterator(); while(iterator.hasNext()) { Token token = (Token)iterator.next(); if(pos >= token.start && pos <= token.end) return token; } return null; }
4430 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/4430/f13d59e2934691783709edc81c3eb7cea20d0849/MenuGrammar.java/buggy/src/org/antlr/works/editor/actions/MenuGrammar.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 3155, 9162, 861, 2555, 12, 474, 949, 13, 288, 3639, 4498, 2775, 273, 4858, 18, 588, 5157, 7675, 9838, 5621, 3639, 1323, 12, 9838, 18, 5332, 2134, 10756, 288, 5411, 3155, 1147, 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, 3155, 9162, 861, 2555, 12, 474, 949, 13, 288, 3639, 4498, 2775, 273, 4858, 18, 588, 5157, 7675, 9838, 5621, 3639, 1323, 12, 9838, 18, 5332, 2134, 10756, 288, 5411, 3155, 1147, 273, ...
jj_la1[23] = jj_gen;
jj_la1[24] = jj_gen;
static final public void MethodModifier() throws ParseException { /*@bgen(jjtree) Modifier */ ASTModifier jjtn000 = new ASTModifier(JJTMODIFIER); boolean jjtc000 = true; jjtree.openNodeScope(jjtn000); try { label_14: while (true) { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case METHOD_NOT: ; break; default: jj_la1[23] = jj_gen; break label_14; } jj_consume_token(METHOD_NOT); jjtn000.setNot(); } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case METHOD_PUBLIC: jj_consume_token(METHOD_PUBLIC); jjtree.closeNodeScope(jjtn000, true); jjtc000 = false; jjtn000.setModifier(Modifier.PUBLIC); break; case METHOD_PROTECTED: jj_consume_token(METHOD_PROTECTED); jjtree.closeNodeScope(jjtn000, true); jjtc000 = false; jjtn000.setModifier(Modifier.PROTECTED); break; case METHOD_PRIVATE: jj_consume_token(METHOD_PRIVATE); jjtree.closeNodeScope(jjtn000, true); jjtc000 = false; jjtn000.setModifier(Modifier.PRIVATE); break; case METHOD_STATIC: jj_consume_token(METHOD_STATIC); jjtree.closeNodeScope(jjtn000, true); jjtc000 = false; jjtn000.setModifier(Modifier.STATIC); break; case METHOD_ABSTRACT: jj_consume_token(METHOD_ABSTRACT); jjtree.closeNodeScope(jjtn000, true); jjtc000 = false; jjtn000.setModifier(Modifier.ABSTRACT); break; case METHOD_FINAL: jj_consume_token(METHOD_FINAL); jjtree.closeNodeScope(jjtn000, true); jjtc000 = false; jjtn000.setModifier(Modifier.FINAL); break; case METHOD_NATIVE: jj_consume_token(METHOD_NATIVE); jjtree.closeNodeScope(jjtn000, true); jjtc000 = false; jjtn000.setModifier(Modifier.NATIVE); break; case METHOD_SYNCHRONIZED: jj_consume_token(METHOD_SYNCHRONIZED); jjtree.closeNodeScope(jjtn000, true); jjtc000 = false; jjtn000.setModifier(Modifier.SYNCHRONIZED); break; default: jj_la1[24] = jj_gen; jj_consume_token(-1); throw new ParseException(); } } finally { if (jjtc000) { jjtree.closeNodeScope(jjtn000, true); } } }
7954 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/7954/773e62df340910756fa4992c37d1a6531e796a5c/ExpressionParser.java/clean/aspectwerkz3/src/main/org/codehaus/aspectwerkz/expression/ast/ExpressionParser.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 282, 760, 727, 1071, 918, 2985, 9829, 1435, 1216, 10616, 288, 4766, 282, 1748, 36, 70, 4507, 12, 78, 78, 3413, 13, 12832, 1195, 225, 9183, 9829, 10684, 5088, 3784, 273, 394, 9183, 9829, 12, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 282, 760, 727, 1071, 918, 2985, 9829, 1435, 1216, 10616, 288, 4766, 282, 1748, 36, 70, 4507, 12, 78, 78, 3413, 13, 12832, 1195, 225, 9183, 9829, 10684, 5088, 3784, 273, 394, 9183, 9829, 12, ...
final Roster roster = SparkManager.getConnection().getRoster(); RosterEntry entry = roster.getEntry(jid); if (entry != null && entry.getType() == RosterPacket.ItemType.TO) { Presence response = new Presence(Presence.Type.subscribed); response.setTo(jid); SparkManager.getConnection().sendPacket(response); return; } String message = Res.getString("message.approve.subscription", UserManager.unescapeJID(jid)); final JPanel layoutPanel = new JPanel(); layoutPanel.setBackground(Color.white); layoutPanel.setLayout(new GridBagLayout()); WrappedLabel messageLabel = new WrappedLabel(); messageLabel.setText(message); layoutPanel.add(messageLabel, new GridBagConstraints(0, 0, 5, 1, 1.0, 0.0, GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(5, 5, 5, 5), 0, 0)); RolloverButton acceptButton = new RolloverButton(); ResourceUtils.resButton(acceptButton, Res.getString("button.accept")); RolloverButton viewInfoButton = new RolloverButton(); ResourceUtils.resButton(viewInfoButton, Res.getString("button.profile")); RolloverButton denyButton = new RolloverButton(); ResourceUtils.resButton(denyButton, Res.getString("button.deny")); layoutPanel.add(acceptButton, new GridBagConstraints(2, 1, 1, 1, 1.0, 0.0, GridBagConstraints.NORTHEAST, GridBagConstraints.NONE, new Insets(5, 5, 5, 5), 0, 0)); layoutPanel.add(viewInfoButton, new GridBagConstraints(3, 1, 1, 1, 0.0, 0.0, GridBagConstraints.NORTHEAST, GridBagConstraints.NONE, new Insets(5, 5, 5, 5), 0, 0)); layoutPanel.add(denyButton, new GridBagConstraints(4, 1, 1, 1, 0.0, 1.0, GridBagConstraints.NORTHEAST, GridBagConstraints.NONE, new Insets(5, 5, 5, 5), 0, 0)); acceptButton.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { SparkManager.getWorkspace().removeAlert(layoutPanel); Presence response = new Presence(Presence.Type.subscribed); response.setTo(jid); SparkManager.getConnection().sendPacket(response); int ok = JOptionPane.showConfirmDialog(getGUI(), Res.getString("message.add.user"), Res.getString("message.add.to.roster"), JOptionPane.YES_NO_OPTION, JOptionPane.QUESTION_MESSAGE); if (ok == JOptionPane.OK_OPTION) { RosterDialog rosterDialog = new RosterDialog(); rosterDialog.setDefaultJID(UserManager.unescapeJID(jid)); rosterDialog.showRosterDialog(); } } }); denyButton.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { SparkManager.getWorkspace().removeAlert(layoutPanel); Presence response = new Presence(Presence.Type.unsubscribe); response.setTo(jid); SparkManager.getConnection().sendPacket(response); } }); viewInfoButton.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { SparkManager.getVCardManager().viewProfile(jid, getGUI()); } }); SparkManager.getWorkspace().addAlert(layoutPanel); SparkManager.getAlertManager().flashWindowStopOnFocus(SparkManager.getMainWindow());
final SubscriptionDialog subscriptionDialog = new SubscriptionDialog(); subscriptionDialog.invoke(jid);
private void subscriptionRequest(final String jid) { final Roster roster = SparkManager.getConnection().getRoster(); RosterEntry entry = roster.getEntry(jid); if (entry != null && entry.getType() == RosterPacket.ItemType.TO) { Presence response = new Presence(Presence.Type.subscribed); response.setTo(jid); SparkManager.getConnection().sendPacket(response); return; } String message = Res.getString("message.approve.subscription", UserManager.unescapeJID(jid)); final JPanel layoutPanel = new JPanel(); layoutPanel.setBackground(Color.white); layoutPanel.setLayout(new GridBagLayout()); WrappedLabel messageLabel = new WrappedLabel(); messageLabel.setText(message); layoutPanel.add(messageLabel, new GridBagConstraints(0, 0, 5, 1, 1.0, 0.0, GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(5, 5, 5, 5), 0, 0)); RolloverButton acceptButton = new RolloverButton(); ResourceUtils.resButton(acceptButton, Res.getString("button.accept")); RolloverButton viewInfoButton = new RolloverButton(); ResourceUtils.resButton(viewInfoButton, Res.getString("button.profile")); RolloverButton denyButton = new RolloverButton(); ResourceUtils.resButton(denyButton, Res.getString("button.deny")); layoutPanel.add(acceptButton, new GridBagConstraints(2, 1, 1, 1, 1.0, 0.0, GridBagConstraints.NORTHEAST, GridBagConstraints.NONE, new Insets(5, 5, 5, 5), 0, 0)); layoutPanel.add(viewInfoButton, new GridBagConstraints(3, 1, 1, 1, 0.0, 0.0, GridBagConstraints.NORTHEAST, GridBagConstraints.NONE, new Insets(5, 5, 5, 5), 0, 0)); layoutPanel.add(denyButton, new GridBagConstraints(4, 1, 1, 1, 0.0, 1.0, GridBagConstraints.NORTHEAST, GridBagConstraints.NONE, new Insets(5, 5, 5, 5), 0, 0)); acceptButton.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { SparkManager.getWorkspace().removeAlert(layoutPanel); Presence response = new Presence(Presence.Type.subscribed); response.setTo(jid); SparkManager.getConnection().sendPacket(response); int ok = JOptionPane.showConfirmDialog(getGUI(), Res.getString("message.add.user"), Res.getString("message.add.to.roster"), JOptionPane.YES_NO_OPTION, JOptionPane.QUESTION_MESSAGE); if (ok == JOptionPane.OK_OPTION) { RosterDialog rosterDialog = new RosterDialog(); rosterDialog.setDefaultJID(UserManager.unescapeJID(jid)); rosterDialog.showRosterDialog(); } } }); denyButton.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { SparkManager.getWorkspace().removeAlert(layoutPanel); // Send subscribed Presence response = new Presence(Presence.Type.unsubscribe); response.setTo(jid); SparkManager.getConnection().sendPacket(response); } }); viewInfoButton.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { SparkManager.getVCardManager().viewProfile(jid, getGUI()); } }); // show dialog SparkManager.getWorkspace().addAlert(layoutPanel); SparkManager.getAlertManager().flashWindowStopOnFocus(SparkManager.getMainWindow()); }
52006 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52006/d039de56513c7dd0e3c5c2762f184ca886fb4900/ContactList.java/buggy/src/java/org/jivesoftware/spark/ui/ContactList.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 3238, 918, 4915, 691, 12, 6385, 514, 14201, 13, 288, 3639, 727, 534, 29811, 721, 8190, 273, 21087, 1318, 18, 588, 1952, 7675, 588, 54, 29811, 5621, 3639, 534, 29811, 1622, 1241, 273, 721,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 4915, 691, 12, 6385, 514, 14201, 13, 288, 3639, 727, 534, 29811, 721, 8190, 273, 21087, 1318, 18, 588, 1952, 7675, 588, 54, 29811, 5621, 3639, 534, 29811, 1622, 1241, 273, 721,...
return b0.compareTo(b1) >= 0;
return v0 >= v1;
public boolean evaluateBoolean(Evaluator evaluator) { final String b0 = calc0.evaluateString(evaluator); final String b1 = calc1.evaluateString(evaluator); if (b0 == null || b1 == null) { return BooleanNull; } return b0.compareTo(b1) >= 0; }
4891 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/4891/759b141925c76c1aa0aaf89d93dc38bfe19d7c5a/BuiltinFunTable.java/clean/src/main/mondrian/olap/fun/BuiltinFunTable.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 5397, 1071, 1250, 5956, 5507, 12, 15876, 18256, 13, 288, 13491, 727, 514, 324, 20, 273, 7029, 20, 18, 21024, 780, 12, 14168, 639, 1769, 13491, 727, 514, 324, 21, 273, 7029, 21, 18, 21024, 78...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 5397, 1071, 1250, 5956, 5507, 12, 15876, 18256, 13, 288, 13491, 727, 514, 324, 20, 273, 7029, 20, 18, 21024, 780, 12, 14168, 639, 1769, 13491, 727, 514, 324, 21, 273, 7029, 21, 18, 21024, 78...
public ClientPut getParent() {
public ClientPutter getParent() {
public ClientPut getParent() { return parent; }
50915 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50915/d32229c02576d531c915059f111c468591f30e84/SplitFileInserter.java/clean/src/freenet/client/async/SplitFileInserter.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 2445, 6426, 5089, 1435, 288, 202, 202, 2463, 982, 31, 202, 97, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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, 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, 225, 202, 482, 2445, 6426, 5089, 1435, 288, 202, 202, 2463, 982, 31, 202, 97, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -10...
if ( !isSourceChanged && sourceHandle != null && !sourceHandle.getModuleHandle( ).isReadOnly( ) )
if ( !isSourceChanged && sourceHandle != null && !sourceHandle.getModuleHandle( ).isReadOnly( ) && !( new EcoreUtil.EqualityHelper( ).equals( createDataSourceDesign( sourceHandle ), sourceDesign ) ) )
public void updateDataSetHandle( DataSetDesign setDesign, OdaDataSetHandle setHandle, boolean isSourceChanged ) throws SemanticException { if ( setDesign == null || setHandle == null ) return; DesignUtil.validateObject( setDesign ); CommandStack stack = setHandle.getModuleHandle( ).getCommandStack( ); stack.startTrans( null ); try { // extension id is set without undo/redo support. setHandle.getElement( ).setProperty( OdaDataSourceHandle.EXTENSION_ID_PROP, setDesign.getOdaExtensionDataSetId( ) ); setHandle.setName( setDesign.getName( ) ); setHandle.setDisplayName( setDesign.getDisplayName( ) ); // set public properties. Properties props = setDesign.getPublicProperties( ); if ( props != null ) { EList propList = props.getProperties( ); for ( int i = 0; i < propList.size( ); i++ ) { Property prop = (Property) propList.get( i ); setHandle.setProperty( prop.getName( ), prop.getValue( ) ); } } // updateROMPropertyBindings( props, setHandle ); // set private properties. props = setDesign.getPrivateProperties( ); if ( props != null ) { EList propList = props.getProperties( ); for ( int i = 0; i < propList.size( ); i++ ) { Property prop = (Property) propList.get( i ); setHandle.setPrivateDriverProperty( prop.getName( ), prop .getValue( ) ); } } updateROMDataSetParamList( setHandle, new DataSetParameterAdapter( ) .newROMSetParams( setDesign.getParameters( ), setDesign .getOdaExtensionDataSourceId( ), setDesign .getOdaExtensionDataSetId( ), setHandle ) ); ResultSetDefinition resultDefn = setDesign.getPrimaryResultSet( ); if ( resultDefn == null ) { ResultSets resultSets = setDesign.getResultSets( ); if ( resultSets != null && !resultSets.getResultSetDefinitions( ).isEmpty( ) ) resultDefn = (ResultSetDefinition) resultSets .getResultSetDefinitions( ).get( 0 ); } updateROMStructureList( setHandle .getPropertyHandle( OdaDataSetHandle.RESULT_SET_PROP ), ResultSetsAdapter.newROMResultSets( resultDefn, setDesign .getOdaExtensionDataSourceId( ), setDesign .getOdaExtensionDataSetId( ) ) ); setHandle.setResultSetName( setDesign.getPrimaryResultSetName( ) ); setHandle.setQueryText( setDesign.getQueryText( ) ); DataSourceDesign sourceDesign = setDesign.getDataSourceDesign( ); if ( sourceDesign != null ) { OdaDataSourceHandle sourceHandle = (OdaDataSourceHandle) setHandle .getDataSource( ); // only the local data source can be used. if ( isSourceChanged && sourceHandle != null && !sourceHandle.getModuleHandle( ).isReadOnly( ) ) { setHandle.setDataSource( sourceDesign.getName( ) ); updateDataSourceHandle( sourceDesign, sourceHandle ); } // if the source is not changed, and it is not in the included // library, then we can update it. if ( !isSourceChanged && sourceHandle != null && !sourceHandle.getModuleHandle( ).isReadOnly( ) ) { updateDataSourceHandle( sourceDesign, sourceHandle ); } } else setHandle.setDataSource( null ); } catch ( SemanticException e ) { stack.rollback( ); throw e; } stack.commit( ); }
15160 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/15160/67f67c4168ab700dabbbf22f5342762d233df779/ModelOdaAdapter.java/buggy/model/org.eclipse.birt.report.model.adapter.oda/src/org/eclipse/birt/report/model/adapter/oda/ModelOdaAdapter.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 918, 1089, 13676, 3259, 12, 14065, 15478, 444, 15478, 16, 1082, 202, 51, 2414, 13676, 3259, 444, 3259, 16, 1250, 353, 1830, 5033, 262, 1082, 202, 15069, 24747, 503, 202, 95, 202...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 918, 1089, 13676, 3259, 12, 14065, 15478, 444, 15478, 16, 1082, 202, 51, 2414, 13676, 3259, 444, 3259, 16, 1250, 353, 1830, 5033, 262, 1082, 202, 15069, 24747, 503, 202, 95, 202...
worker.work(files);
Job updateJob = worker.workExecute(files); if (updateJob != null) updateJob.schedule();
protected IStatus run(IProgressMonitor monitor) { FindBugsWorker worker = new FindBugsWorker(resource .getProject(), monitor); try { worker.work(files); } catch (CoreException e) { e.printStackTrace(); return Status.CANCEL_STATUS; } return Status.OK_STATUS; }
7352 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/7352/ae628b8fa656b6d133bea79e903e6be5681d4579/FindBugsAction.java/clean/eclipsePlugin/src/de/tobject/findbugs/actions/FindBugsAction.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 4697, 202, 1117, 467, 1482, 1086, 12, 45, 5491, 7187, 6438, 13, 288, 6862, 202, 3125, 31559, 6671, 4322, 273, 394, 4163, 31559, 6671, 12, 3146, 6862, 1082, 202, 18, 588, 4109, 9334, 6438, 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, 4697, 202, 1117, 467, 1482, 1086, 12, 45, 5491, 7187, 6438, 13, 288, 6862, 202, 3125, 31559, 6671, 4322, 273, 394, 4163, 31559, 6671, 12, 3146, 6862, 1082, 202, 18, 588, 4109, 9334, 6438, 1769...
System.out.println("--[java]Utilities.callMethod "+method);
Debug.log("--[java]Utilities.callMethod "+method);
static Object callMethod(long oid, Method method, IID iid, long orb , Object[] args) { System.out.println("--[java]Utilities.callMethod "+method); int mid = InterfaceRegistry.getIndexByMethod(method, iid); if (mid < 0) { System.out.println("--[java]Utilities.callMethod we do not have implementation for "+method); return null; } System.out.println("--[java]Utilities.callMethod "+mid); return callMethodByIndex(oid,mid,iid.getString(), orb, args); }
7555 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/7555/0ec50a33d49e7e7182932acd9d83c0fb542f60a7/Utilities.java/buggy/java/xpcom/java/classes/org/mozilla/xpcom/Utilities.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 760, 1033, 745, 1305, 12, 5748, 7764, 16, 2985, 707, 16, 467, 734, 22819, 16, 1525, 16823, 269, 1033, 8526, 833, 13, 288, 3639, 4015, 18, 1330, 2932, 413, 63, 6290, 65, 11864, 18, 1991,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 745, 1305, 12, 5748, 7764, 16, 2985, 707, 16, 467, 734, 22819, 16, 1525, 16823, 269, 1033, 8526, 833, 13, 288, 3639, 4015, 18, 1330, 2932, 413, 63, 6290, 65, 11864, 18, 1991,...
return configuration.getInt( key, defaultValue );
return configuration.getInt( key );
public static int getInt( String key, int defaultValue ) { return configuration.getInt( key, defaultValue ); }
55820 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/55820/0e2e0ac5aeee10d1b290ef4aa2773c2e25725bd5/Runtime.java/buggy/src/java/org/apache/velocity/runtime/Runtime.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 760, 509, 8145, 12, 514, 498, 16, 509, 4593, 262, 565, 288, 3639, 327, 1664, 18, 588, 1702, 12, 498, 11272, 565, 289, 2, 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, 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, 377, 1071, 760, 509, 8145, 12, 514, 498, 16, 509, 4593, 262, 565, 288, 3639, 327, 1664, 18, 588, 1702, 12, 498, 11272, 565, 289, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
if (myIndex >= 0 && myIndex < myList.getModel().getSize()){ ListScrollingUtil.selectItem(myList, myIndex);
myCanceled = false; hide(); int lookupStart = myLookupStartMarker.getStartOffset(); LogicalPosition lookupPosition = myEditor.offsetToLogicalPosition(lookupStart); myEditor.getCaretModel().moveToLogicalPosition(lookupPosition); if (myEditor.getSelectionModel().hasSelection()){ myEditor.getDocument().deleteString(myEditor.getSelectionModel().getSelectionStart(), myEditor.getSelectionModel().getSelectionEnd()); } if (s.startsWith(myPrefix)){ myEditor.getDocument().insertString(lookupStart + prefixLength, s.substring(prefixLength)); } else{ if (prefixLength > 0){ FeatureUsageTracker.getInstance().triggerFeatureUsed("editing.completion.camelHumps"); myEditor.getDocument().deleteString(lookupStart, lookupStart + prefixLength);
public void run(){ if (myIndex >= 0 && myIndex < myList.getModel().getSize()){ ListScrollingUtil.selectItem(myList, myIndex); } else if(myItems.length > 0){ ListScrollingUtil.selectItem(myList, 0); } }
17306 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/17306/7fd1c7e15002812bc52c65b098861144be7f1417/LookupImpl.java/buggy/codeInsight/impl/com/intellij/codeInsight/lookup/impl/LookupImpl.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 6647, 1071, 918, 1086, 1435, 95, 5411, 309, 261, 4811, 1016, 1545, 374, 597, 3399, 1016, 411, 3399, 682, 18, 588, 1488, 7675, 588, 1225, 10756, 95, 2868, 987, 1541, 15742, 1304, 18, 4025, 1180...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 6647, 1071, 918, 1086, 1435, 95, 5411, 309, 261, 4811, 1016, 1545, 374, 597, 3399, 1016, 411, 3399, 682, 18, 588, 1488, 7675, 588, 1225, 10756, 95, 2868, 987, 1541, 15742, 1304, 18, 4025, 1180...
cp = normalLibs + ":" + systemLibs;
cp = normalLibs + File.pathSeparator + systemLibs;
public static void main(String argv[], Class applicationClass) { _wasERXApplicationMainInvoked = true; String cp = System.getProperty("java.class.path"); String parts[] = cp.split(":"); String normalLibs = ""; String systemLibs = ""; allFrameworks = new HashSet(); for (int i = 0; i < parts.length; i++) { String jar = parts[i]; // all patched frameworks here if(jar.matches(".*?Library[/\\\\]Frameworks[/\\\\]Java(Foundation|EOControl|EOAccess|WebObjects).*")) { systemLibs += jar + ":"; } else { normalLibs += jar + ":"; } String bundle = jar.replaceAll(".*?[/\\\\](\\w+)\\.framework.*", "$1"); if (bundle.matches("^\\w+$") && !"JavaVM".equals(bundle)) { allFrameworks.add(bundle); } } if (systemLibs.length() > 1) { systemLibs = systemLibs.substring(0, systemLibs.length() - 1); } if (normalLibs.length() > 1) { normalLibs = normalLibs.substring(0, normalLibs.length() - 1); } cp = normalLibs + ":" + systemLibs; // AK: this is pretty experimental for now. The classpath reordering // should actually be done in a WOLips bootstrap because as this time all // the static inits of WO app have already happened (which include NSMutableArray and _NSThreadSaveSet) if (true) { System.setProperty("java.class.path", cp); ClassLoader loader = AppClassLoader.getAppClassLoader(); Thread.currentThread().setContextClassLoader(loader); } Class arrayClass = NSMutableArray.class; try { Field f = arrayClass.getField("ERX_MARKER"); } catch (NoSuchFieldException e) { System.err.println("No ERX_MARKER field in NSMutableArray found. \nThis means your class path is incorrect. Adjust it so that ERExtensions come before JavaFoundation."); System.exit(1); } catch (Exception e) { e.printStackTrace(); } NSNotificationCenter.defaultCenter().addObserver(ERXApplication.class, new NSSelector("bundleDidLoad", new Class[] { NSNotification.class }), "NSBundleDidLoadNotification", null); ERXConfigurationManager.defaultManager().setCommandLineArguments(argv); ERXFrameworkPrincipal.setUpFrameworkPrincipalClass(ERXExtensions.class); WOApplication.main(argv, applicationClass); }
810 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/810/180e83f9c35bbcdbe015d5a73719e96e613636d2/ERXApplication.java/clean/Wonder/Common/Frameworks/ERExtensions/Sources/er/extensions/ERXApplication.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 760, 918, 2774, 12, 780, 5261, 63, 6487, 1659, 2521, 797, 13, 288, 377, 202, 67, 17416, 654, 60, 3208, 6376, 26215, 273, 638, 31, 377, 202, 780, 3283, 273, 2332, 18, 588, 1396, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 760, 918, 2774, 12, 780, 5261, 63, 6487, 1659, 2521, 797, 13, 288, 377, 202, 67, 17416, 654, 60, 3208, 6376, 26215, 273, 638, 31, 377, 202, 780, 3283, 273, 2332, 18, 588, 1396, ...
case 111:
case 113:
public final void kindTest() throws RecognitionException, TokenStreamException { returnAST = null; ASTPair currentAST = new ASTPair(); AST kindTest_AST = null; switch ( LA(1)) { case LITERAL_text: { textTest(); astFactory.addASTChild(currentAST, returnAST); kindTest_AST = (AST)currentAST.root; break; } case LITERAL_node: { anyKindTest(); astFactory.addASTChild(currentAST, returnAST); kindTest_AST = (AST)currentAST.root; break; } case LITERAL_element: { elementTest(); astFactory.addASTChild(currentAST, returnAST); kindTest_AST = (AST)currentAST.root; break; } case LITERAL_attribute: { attributeTest(); astFactory.addASTChild(currentAST, returnAST); kindTest_AST = (AST)currentAST.root; break; } case LITERAL_comment: { commentTest(); astFactory.addASTChild(currentAST, returnAST); kindTest_AST = (AST)currentAST.root; break; } case 110: { piTest(); astFactory.addASTChild(currentAST, returnAST); kindTest_AST = (AST)currentAST.root; break; } case 111: { documentTest(); astFactory.addASTChild(currentAST, returnAST); kindTest_AST = (AST)currentAST.root; break; } default: { throw new NoViableAltException(LT(1), getFilename()); } } returnAST = kindTest_AST; }
2909 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/2909/be23536931f66ed6f552941df1c272ed48eeb933/XPathParser2.java/buggy/src/org/exist/parser/XPathParser2.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 727, 918, 3846, 4709, 1435, 1216, 9539, 16, 3155, 1228, 503, 288, 9506, 202, 2463, 9053, 273, 446, 31, 202, 202, 9053, 4154, 783, 9053, 273, 394, 9183, 4154, 5621, 202, 202, 9...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 3846, 4709, 1435, 1216, 9539, 16, 3155, 1228, 503, 288, 9506, 202, 2463, 9053, 273, 446, 31, 202, 202, 9053, 4154, 783, 9053, 273, 394, 9183, 4154, 5621, 202, 202, 9...
if (!(child instanceof PartPlaceholder)) return;
if (!(child instanceof PartPlaceholder)) { return; }
public void add(LayoutPart child) { if (!(child instanceof PartPlaceholder)) return; realContainer.add(child); }
55805 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/55805/fa4a8cff0e027f8d3c6b1fcb92b30f46767dd191/ContainerPlaceholder.java/buggy/bundles/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal/ContainerPlaceholder.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 918, 527, 12, 3744, 1988, 1151, 13, 288, 3639, 309, 16051, 12, 3624, 1276, 6393, 14038, 3719, 5411, 327, 31, 3639, 2863, 2170, 18, 1289, 12, 3624, 1769, 565, 289, 2, 0, 0, 0, 0,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 918, 527, 12, 3744, 1988, 1151, 13, 288, 3639, 309, 16051, 12, 3624, 1276, 6393, 14038, 3719, 5411, 327, 31, 3639, 2863, 2170, 18, 1289, 12, 3624, 1769, 565, 289, 2, -100, -100, -...
setFinished(false);
if(resetPos == null) { setFinished(false); }
public void resetPosition(Position resetPos) { setFinished(false); }
5268 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5268/ee22d835b3a297e84b8dd26ea3d1c6a0797d2820/LeafNodeLayoutManager.java/buggy/src/org/apache/fop/layoutmgr/LeafNodeLayoutManager.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 918, 2715, 2555, 12, 2555, 2715, 1616, 13, 288, 540, 309, 12, 6208, 1616, 422, 446, 13, 288, 444, 10577, 12, 5743, 1769, 289, 565, 289, 2, 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, 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, 1071, 918, 2715, 2555, 12, 2555, 2715, 1616, 13, 288, 540, 309, 12, 6208, 1616, 422, 446, 13, 288, 444, 10577, 12, 5743, 1769, 289, 565, 289, 2, -100, -100, -100, -100, -100, -100, -100...
Logger.minor(this,"Sending packet of length "+output.length+" to "+kt.pn);
Logger.minor(this,"Sending packet of length "+output.length+" (" + Fields.hashCode(output) + " to "+kt.pn);
private void processOutgoingFullyFormatted(byte[] plaintext, KeyTracker kt, AsyncMessageCallback[] callbacks) { BlockCipher sessionCipher = kt.sessionCipher; if(Logger.shouldLog(Logger.DEBUG, this)) Logger.debug(this, "Encrypting with "+HexUtil.bytesToHex(kt.sessionKey)); if(sessionCipher == null) { Logger.error(this, "Dropping packet send - have not handshaked yet"); return; } int blockSize = sessionCipher.getBlockSize() >> 3; if(sessionCipher.getKeySize() != sessionCipher.getBlockSize()) throw new IllegalStateException("Block size must be half key size: blockSize="+ sessionCipher.getBlockSize()+", keySize="+sessionCipher.getKeySize()); MessageDigest md; try { md = MessageDigest.getInstance("SHA-256"); } catch (NoSuchAlgorithmException e) { throw new Error(e); } int digestLength = md.getDigestLength(); if(digestLength != blockSize) throw new IllegalStateException("Block size must be digest length!"); byte[] output = new byte[plaintext.length + digestLength]; System.arraycopy(plaintext, 0, output, digestLength, plaintext.length); md.update(plaintext); //Logger.minor(this, "Plaintext:\n"+HexUtil.bytesToHex(plaintext)); byte[] digestTemp; digestTemp = md.digest(); //Logger.minor(this, "\nHash: "+HexUtil.bytesToHex(digestTemp)); // Put plaintext in output System.arraycopy(digestTemp, 0, output, 0, digestLength); sessionCipher.encipher(digestTemp, digestTemp); // Now copy it back System.arraycopy(digestTemp, 0, output, 0, digestLength); // Yay, we have an encrypted hash //Logger.minor(this, "\nEncrypted: "+HexUtil.bytesToHex(digestTemp)+" ("+plaintext.length+" bytes plaintext)"); PCFBMode pcfb = new PCFBMode(sessionCipher, digestTemp); pcfb.blockEncipher(output, digestLength, plaintext.length); //Logger.minor(this, "Ciphertext:\n"+HexUtil.bytesToHex(output, digestLength, plaintext.length)); // We have a packet // Send it Logger.minor(this,"Sending packet of length "+output.length+" to "+kt.pn); // pn.getPeer() cannot be null usm.sendPacket(output, kt.pn.getPeer()); kt.pn.sentPacket(); }
50287 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50287/32291975fc543ab3b9ddc50a4bcd992394800348/FNPPacketMangler.java/buggy/src/freenet/node/FNPPacketMangler.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 3238, 918, 1207, 24866, 16999, 18298, 12, 7229, 8526, 11917, 16, 1929, 8135, 417, 88, 16, 9672, 1079, 2428, 8526, 6689, 13, 288, 3639, 3914, 13896, 1339, 13896, 273, 417, 88, 18, 3184, 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, 24866, 16999, 18298, 12, 7229, 8526, 11917, 16, 1929, 8135, 417, 88, 16, 9672, 1079, 2428, 8526, 6689, 13, 288, 3639, 3914, 13896, 1339, 13896, 273, 417, 88, 18, 3184, 13...
RubyArray ary = RubyArray.m_newArray(getRuby());
RubyArray ary = RubyArray.m_newArray(getRuby());
public RubyArray m_included_modules() { RubyArray ary = RubyArray.m_newArray(getRuby()); for (RubyModule p = getSuperClass(); p != null; p = p.getSuperClass()) { if (p.isIncluded()) { ary.push(p.getRubyClass()); } } return ary; }
45753 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/45753/0a7181933af700ea8025a4197f3a5ebcc08333c3/RubyModule.java/clean/org/jruby/RubyModule.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 19817, 1076, 312, 67, 20405, 67, 6400, 1435, 288, 202, 202, 54, 10340, 1076, 11841, 273, 19817, 1076, 18, 81, 67, 2704, 1076, 12, 588, 54, 10340, 10663, 202, 202, 1884, 261, 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, 225, 202, 482, 19817, 1076, 312, 67, 20405, 67, 6400, 1435, 288, 202, 202, 54, 10340, 1076, 11841, 273, 19817, 1076, 18, 81, 67, 2704, 1076, 12, 588, 54, 10340, 10663, 202, 202, 1884, 261, 5...
Token xsp; xsp = jj_scanpos; if (jj_3R_297()) { jj_scanpos = xsp; if (jj_3R_298()) { jj_scanpos = xsp; if (jj_3R_299()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; if (jj_3R_253()) return true;
if (jj_scan_token(LT)) return true;
final private boolean jj_3R_272() { Token xsp; xsp = jj_scanpos; if (jj_3R_297()) { jj_scanpos = xsp; if (jj_3R_298()) { jj_scanpos = xsp; if (jj_3R_299()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; if (jj_3R_253()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; }
45569 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/45569/83d81b076b32acdf3f82077c7f4c2a2e160aa32f/JavaParser.java/buggy/pmd/src/net/sourceforge/pmd/ast/JavaParser.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 282, 727, 3238, 1250, 10684, 67, 23, 54, 67, 5324, 22, 1435, 288, 565, 3155, 619, 1752, 31, 565, 619, 1752, 273, 10684, 67, 9871, 917, 31, 565, 309, 261, 78, 78, 67, 23, 54, 67, 5540, 27...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 727, 3238, 1250, 10684, 67, 23, 54, 67, 5324, 22, 1435, 288, 565, 3155, 619, 1752, 31, 565, 619, 1752, 273, 10684, 67, 9871, 917, 31, 565, 309, 261, 78, 78, 67, 23, 54, 67, 5540, 27...
}
}
void refreshInternal(final boolean recursive, final ModalityState modalityState, final boolean forceRefresh, final boolean asynchronous, final boolean noWatcher) { if (!asynchronous) { ApplicationManager.getApplication().assertWriteAccessAllowed(); } if (!isValid()) return; if (LOG.isDebugEnabled()) { LOG.debug("refreshInternal recursive = " + recursive + " asynchronous = " + asynchronous + " file = " + myName); } final PhysicalFile physicalFile = getPhysicalFile(); PhysicalFile[] childFiles = null; final boolean isDirectory; if (myChildren == null) { isDirectory = physicalFile.isDirectory(); } else { childFiles = physicalFile.listFiles(); isDirectory = childFiles != null; } if (isDirectory != myDirectoryFlag) { ourFileSystem.getManager().addEventToFireByRefresh( new Runnable() { public void run() { if (!isValid()) return; VirtualFileImpl parent = getParent(); if (parent == null) return; ourFileSystem.fireBeforeFileDeletion(null, VirtualFileImpl.this); parent.removeChild(VirtualFileImpl.this); ourFileSystem.fireFileDeleted(null, VirtualFileImpl.this, myName, myDirectoryFlag, parent); VirtualFileImpl newChild = new VirtualFileImpl(parent, physicalFile, isDirectory); parent.addChild(newChild); ourFileSystem.fireFileCreated(null, newChild); } }, asynchronous, modalityState ); return; } if (isDirectory) { if (myChildren == null) return; final int[] newIndices = new int[myChildren.length]; for (int i = 0; i < newIndices.length; i++) newIndices[i] = -1; VirtualFileImpl[] children = myChildren; for (int i = 0; i < childFiles.length; i++) { final PhysicalFile file = childFiles[i]; final String name = file.getName(); int index = -1; if (i < children.length && children[i].nameEquals(name)) { index = i; } else { for (int j = 0; j < children.length; j++) { VirtualFileImpl child = myChildren[j]; if (child.nameEquals(name)) index = j; } } if (index < 0) { ourFileSystem.getManager().addEventToFireByRefresh( new Runnable() { public void run() { if (VirtualFileImpl.this.isValid()) { if (findChild(file.getName()) != null) return; // was already created VirtualFileImpl newChild = new VirtualFileImpl( VirtualFileImpl.this, file, file.isDirectory() ); addChild(newChild); ourFileSystem.fireFileCreated(null, newChild); } } }, asynchronous, modalityState ); } else { newIndices[index] = i; } } for (int i = 0; i < children.length; i++) { final VirtualFileImpl child = children[i]; final int newIndex = newIndices[i]; if (newIndex >= 0) { final String oldName = child.getName(); final String newName = childFiles[newIndex].getName(); if (!oldName.equals(newName)) { ourFileSystem.getManager().addEventToFireByRefresh( new Runnable() { public void run() { if (child.isValid()) { ourFileSystem.fireBeforePropertyChange(null, child, VirtualFile.PROP_NAME, oldName, newName); child.setName(newName); ourFileSystem.firePropertyChanged(null, child, VirtualFile.PROP_NAME, oldName, newName); } } }, asynchronous, modalityState ); } if (recursive) { ourFileSystem.refreshInner(child, true, modalityState, asynchronous, false, noWatcher); } } else { ourFileSystem.getManager().addEventToFireByRefresh( new Runnable() { public void run() { if (child.isValid()) { ourFileSystem.fireBeforeFileDeletion(null, child); removeChild(child); ourFileSystem.fireFileDeleted(null, child, child.myName, child.myDirectoryFlag, VirtualFileImpl.this); } } }, asynchronous, modalityState ); } } } else { if (myTimeStamp > 0) { final long timeStamp = physicalFile.lastModified(); if (timeStamp != myTimeStamp || forceRefresh) { ourFileSystem.getManager().addEventToFireByRefresh( new Runnable() { public void run() { if (!forceRefresh && (timeStamp == myTimeStamp || !isValid())) return; ourFileSystem.fireBeforeContentsChange(null, VirtualFileImpl.this); long oldModificationStamp = getModificationStamp(); myTimeStamp = timeStamp; myModificationStamp = LocalTimeCounter.currentTime(); ourFileSystem.fireContentsChanged(null, VirtualFileImpl.this, oldModificationStamp); } }, asynchronous, modalityState ); } } } if (myWritableFlag != null) { final boolean isWritable = isWritable(physicalFile, isDirectory()); if (isWritable != myWritableFlag.booleanValue()) { ourFileSystem.getManager().addEventToFireByRefresh( new Runnable() { public void run() { if (!isValid()) return; ourFileSystem.fireBeforePropertyChange( null, VirtualFileImpl.this, PROP_WRITABLE, myWritableFlag, isWritable ? Boolean.TRUE : Boolean.FALSE ); myWritableFlag = isWritable ? Boolean.TRUE : Boolean.FALSE; ourFileSystem.firePropertyChanged( null, VirtualFileImpl.this, PROP_WRITABLE, isWritable ? Boolean.FALSE : Boolean.TRUE, myWritableFlag ); } }, asynchronous, modalityState ); } } }
56627 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/56627/0c50c62d516d7dbfd71cffd7cea061bd9613113a/VirtualFileImpl.java/buggy/source/com/intellij/openapi/vfs/impl/local/VirtualFileImpl.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 282, 918, 4460, 3061, 12, 6385, 1250, 5904, 16, 15604, 727, 3431, 7919, 1119, 681, 7919, 1119, 16, 15604, 727, 1250, 2944, 8323, 16, 15604, 727, 1250, 9007, 16, 15604, 727, 1250, 1158, 9918, 1...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 918, 4460, 3061, 12, 6385, 1250, 5904, 16, 15604, 727, 3431, 7919, 1119, 681, 7919, 1119, 16, 15604, 727, 1250, 2944, 8323, 16, 15604, 727, 1250, 9007, 16, 15604, 727, 1250, 1158, 9918, 1...
CPElement elem = (CPElement) getCPaths().get(i);
CPElement elem = (CPElement) elements.get(i);
private String getEncodedSettings() { StringBuffer buf = new StringBuffer(); int nElements = getCPaths().size(); buf.append('[').append(nElements).append(']'); for (int i = 0; i < nElements; i++) { CPElement elem = (CPElement) getCPaths().get(i); elem.appendEncodedSettings(buf); } return buf.toString(); }
6192 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/6192/9e55dcaf3675c6376913debc8ea86900deff59ae/AbstractPathOptionBlock.java/buggy/core/org.eclipse.cdt.ui/src/org/eclipse/cdt/internal/ui/dialogs/cpaths/AbstractPathOptionBlock.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 1152, 514, 28799, 2628, 1435, 288, 202, 202, 780, 1892, 1681, 273, 394, 6674, 5621, 202, 202, 474, 290, 3471, 273, 1927, 4466, 7675, 1467, 5621, 202, 202, 4385, 18, 6923, 2668, 3292,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 514, 28799, 2628, 1435, 288, 202, 202, 780, 1892, 1681, 273, 394, 6674, 5621, 202, 202, 474, 290, 3471, 273, 1927, 4466, 7675, 1467, 5621, 202, 202, 4385, 18, 6923, 2668, 3292,...
engine.say("I may be old, but I'm not senile! You don't have a " + text + "! What weapon do you really have for me?");
engine.say("I may be old, but I'm not senile, and you clearly don't have " + Grammar.a_noun(text) + ". What do you really have for me?");
private void step_1() { SpeakerNPC npc = npcs.get("Balduin"); // player says hi before starting the quest npc.add(ConversationStates.IDLE, SpeakerNPC.GREETING_MESSAGES, new SpeakerNPC.ChatCondition() { @Override public boolean fire(Player player, SpeakerNPC engine) { return !player.hasQuest("weapons_collector"); } }, ConversationStates.ATTENDING, "Greetings. I am Balduin. Are you interested in weapons? I certainly am, I have been collecting them since I was young. Maybe you can do a #task for me.", null); npc.add(ConversationStates.ATTENDING, SpeakerNPC.QUEST_MESSAGES, new SpeakerNPC.ChatCondition() { @Override public boolean fire(Player player, SpeakerNPC engine) { return !player.hasQuest("weapons_collector"); } }, ConversationStates.QUEST_OFFERED, null, new SpeakerNPC.ChatAction() { @Override public void fire(Player player, String text, SpeakerNPC engine) { if (!player.isQuestCompleted("weapons_collector")) { engine.say("Although I have collected weapons for such a long time, some are still missing in my collection. Do you think you can help me?"); } else { engine.say("My collection is now complete. Thanks again."); engine.setCurrentState(ConversationStates.ATTENDING); } } }); // player is willing to help npc.add(ConversationStates.QUEST_OFFERED, SpeakerNPC.YES_MESSAGES, null, ConversationStates.ATTENDING, null, new SpeakerNPC.ChatAction() { @Override public void fire(Player player, String text, SpeakerNPC engine) { engine.say("If you help me to complete my #collection, I will give you something nice in exchange."); player.setQuest("weapons_collector", ""); } }); // player is not willing to help npc.add(ConversationStates.QUEST_OFFERED, "no", null, ConversationStates.ATTENDING, "Too bad. You were my last hope to complete my collection.", null ); // player asks what exactly is missing npc.add(ConversationStates.ATTENDING, "collection", new SpeakerNPC.ChatCondition() { @Override public boolean fire(Player player, SpeakerNPC engine) { return player.hasQuest("weapons_collector") && !player.isQuestCompleted("weapons_collector"); } }, ConversationStates.QUESTION_1, null, new SpeakerNPC.ChatAction() { @Override public void fire(Player player, String text, SpeakerNPC engine) { List<String> needed = missingWeapons(player, true); engine.say("There are " + needed.size() + " weapons which are still missing in my collection: " + SpeakerNPC.enumerateCollection(needed) + ". Do you have any of them with you?"); } }); // player says he doesn't have required weapons with him npc.add(ConversationStates.QUESTION_1, "no", null, ConversationStates.IDLE, "Come back when you find them. Farewell.", null); // player says he has a required weapon with him npc.add(ConversationStates.QUESTION_1, SpeakerNPC.YES_MESSAGES, null, ConversationStates.QUESTION_1, "Which one?", null); for (String weapon: neededWeapons) { npc.add(ConversationStates.QUESTION_1, weapon, null, ConversationStates.QUESTION_1, null, new SpeakerNPC.ChatAction() { @Override public void fire(Player player, String text, SpeakerNPC engine) { List<String> missing = missingWeapons(player, false); if (missing.contains(text)) { if (player.drop(text)) { // register weapon as done String doneText = player.getQuest("weapons_collector"); player.setQuest("weapons_collector", doneText + ";" + text); // check if the player has brought all weapons missing = missingWeapons(player, true); if (missing.size() > 0) { engine.say("Thank you very much! Do you have any other weapon for me?"); } else { Item iceSword = StendhalRPWorld.get().getRuleManager().getEntityManager().getItem("ice_sword"); player.equip(iceSword, true); player.addXP(1000); engine.say("Yippie! My collection is complete! Thank you very much! Here, take this ice_sword in exchange!"); player.setQuest("weapons_collector", "done"); player.notifyWorldAboutChanges(); } } else { engine.say("I may be old, but I'm not senile! You don't have a " + text + "! What weapon do you really have for me?"); } } else { engine.say("I already have that one. Do you have any other weapon for me?"); } } }); } }
4438 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/4438/81b0f3d72482d33d1d9eab93ed20ed2ba6e4476c/WeaponsCollector.java/buggy/src/games/stendhal/server/maps/quests/WeaponsCollector.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 1152, 918, 2235, 67, 21, 1435, 288, 202, 202, 55, 347, 6388, 50, 3513, 1130, 71, 273, 1130, 2143, 18, 588, 2932, 38, 287, 2544, 267, 8863, 9506, 202, 759, 7291, 20185, 10118, 1865,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 2235, 67, 21, 1435, 288, 202, 202, 55, 347, 6388, 50, 3513, 1130, 71, 273, 1130, 2143, 18, 588, 2932, 38, 287, 2544, 267, 8863, 9506, 202, 759, 7291, 20185, 10118, 1865,...
myResult = getSpaceBeforeLBrace(mySettings.SPACE_BEFORE_WHILE_LBRACE, mySettings.BRACE_STYLE, new TextRange(myParent.getTextRange().getStartOffset(), myChild2.getTextRange().getStartOffset()),
myResult = getSpaceBeforeLBrace(mySettings.SPACE_BEFORE_WHILE_LBRACE, mySettings.BRACE_STYLE, new TextRange(myParent.getTextRange().getStartOffset(), myChild2.getTextRange().getStartOffset()),
public void visitWhileStatement(PsiWhileStatement statement) { if (myRole2 == ChildRole.LPARENTH) { createSpaceInCode(mySettings.SPACE_BEFORE_WHILE_PARENTHESES); } else if (myRole1 == ChildRole.LPARENTH || myRole2 == ChildRole.RPARENTH) { createSpaceInCode(mySettings.SPACE_WITHIN_WHILE_PARENTHESES); } else if (myRole2 == ChildRole.LOOP_BODY) { myResult = getSpaceBeforeLBrace(mySettings.SPACE_BEFORE_WHILE_LBRACE, mySettings.BRACE_STYLE, new TextRange(myParent.getTextRange().getStartOffset(), myChild2.getTextRange().getStartOffset()), mySettings.KEEP_SIMPLE_BLOCKS_IN_ONE_LINE); } }
56627 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/56627/1533398430214d8ae562ff3d8dcc5898351f8c45/JavaSpacePropertyProcessor.java/buggy/source/com/intellij/psi/formatter/java/JavaSpacePropertyProcessor.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 282, 1071, 918, 3757, 15151, 3406, 12, 52, 7722, 15151, 3406, 3021, 13, 288, 565, 309, 261, 4811, 2996, 22, 422, 7451, 2996, 18, 48, 14943, 44, 13, 288, 1377, 752, 3819, 382, 1085, 12, 4811,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 3757, 15151, 3406, 12, 52, 7722, 15151, 3406, 3021, 13, 288, 565, 309, 261, 4811, 2996, 22, 422, 7451, 2996, 18, 48, 14943, 44, 13, 288, 1377, 752, 3819, 382, 1085, 12, 4811,...
int argOffset = 2;
Offset argOffset = Offset.fromIntSignExtend(2*WORDSIZE);
public static void generateGlueCodeForJNIMethod(VM_Assembler asm, VM_NormalMethod method, int methodID) { // set 2nd word of header = return address already pushed by CALL // NOTE: C calling convention is that EBP contains the caller's framepointer. // Therefore our C to Java transition frames must follow this protocol, // not the RVM protocol in which the caller's framepointer is in // pr.framePointer and EBP is a nonvolatile register. asm.emitPUSH_Reg(EBP); // start new frame: set FP to point to the new frame asm.emitMOV_Reg_Reg (EBP, SP); // set first word of header: method ID asm.emitPUSH_Imm (methodID); // buy space for the rest of the header (values stored later) asm.emitSUB_Reg_Imm (SP, STACKFRAME_HEADER_SIZE - 2 * WORDSIZE); // save registers that will be used in RVM, to be restored on return to C // TODO: I don't think we need to do this: C has no nonvolatile registers on Linux/x86 --dave // TODO: DAVE asm.emitPUSH_Reg(JTOC); asm.emitPUSH_Reg(EBX); asm.emitPUSH_Reg(S0); VM_ProcessorLocalState.emitPushProcessor(asm); // Adjust first param from JNIEnv* to VM_JNIEnvironment. asm.emitSUB_RegDisp_Imm(EBP, (2*WORDSIZE), VM_Entrypoints.JNIExternalFunctionsField.getOffsetAsInt()); // copy the arguments in reverse order VM_TypeReference[] types = method.getParameterTypes(); // does NOT include implicit this or class ptr int numArguments = types.length; // number of arguments for this method int argOffset = 2; // add 2 to get to arg area in caller frame for (int i=0; i<numArguments; i++) { if (types[i].isLongType() || types[i].isDoubleType()) { // handle 2-words case: asm.emitMOV_Reg_RegDisp (EBX, EBP, ((argOffset+1)*WORDSIZE)); asm.emitPUSH_Reg(EBX); asm.emitMOV_Reg_RegDisp (EBX, EBP, (argOffset*WORDSIZE)); asm.emitPUSH_Reg(EBX); argOffset+=2; } else { // Handle 1-word case: asm.emitMOV_Reg_RegDisp (EBX, EBP, (argOffset*WORDSIZE)); asm.emitPUSH_Reg(EBX); argOffset++; } } // START of code sequence to atomically change processor status from IN_NATIVE // to IN_JAVA, looping in a call to sysVirtualProcessorYield if BLOCKED_IN_NATIVE int retryLabel = asm.getMachineCodeIndex(); // backward branch label // Restore PR from VM_JNIEnvironment asm.emitMOV_Reg_RegDisp (EBX, EBP, (2*WORDSIZE)); // pick up arg 0 (from callers frame) VM_ProcessorLocalState.emitSetProcessor(asm, EBX, VM_Entrypoints.JNIEnvSavedPRField.getOffsetAsInt()); // reload JTOC from vitual processor // NOTE: EDI saved in glue frame is just EDI (opt compiled code uses it as normal non-volatile) VM_ProcessorLocalState.emitMoveFieldToReg(asm, JTOC, VM_Entrypoints.jtocField.getOffsetAsInt()); // T0 gets PR.statusField VM_ProcessorLocalState.emitMoveFieldToReg(asm, T0, VM_Entrypoints.vpStatusField.getOffsetAsInt()); asm.emitCMP_Reg_Imm (T0, VM_Processor.IN_NATIVE); // jmp if still IN_NATIVE VM_ForwardReference fr = asm.forwardJcc(asm.EQ); // if so, skip 3 instructions // blocked in native, do pthread yield asm.emitMOV_Reg_RegDisp(T0, JTOC, VM_Entrypoints.the_boot_recordField.getOffsetAsInt()); // T0<-bootrecord addr asm.emitCALL_RegDisp(T0, VM_Entrypoints.sysVirtualProcessorYieldIPField.getOffsetAsInt()); asm.emitJMP_Imm (retryLabel); // retry from beginning fr.resolve(asm); // branch here if IN_NATIVE, attempt to go to IN_JAVA // T0 (EAX) contains "old value" (required for CMPXCNG instruction) // S0 contains address of status word to be swapped asm.emitMOV_Reg_Imm (T1, VM_Processor.IN_JAVA); // T1<-new value (IN_JAVA) VM_ProcessorLocalState.emitCompareAndExchangeField(asm, VM_Entrypoints.vpStatusField.getOffsetAsInt(), T1); // atomic compare-and-exchange asm.emitJCC_Cond_Imm(asm.NE,retryLabel); // END of code sequence to change state from IN_NATIVE to IN_JAVA // status is now IN_JAVA. GC can not occur while we execute on a processor // in this state, so it is safe to access fields of objects. // RVM JTOC and PR registers have been restored and EBX contains a pointer to // the thread's VM_JNIEnvironment. // done saving, bump SP to reserve room for the local variables // SP should now be at the point normally marked as emptyStackOffset int numLocalVariables = method.getLocalWords() - method.getParameterWords(); asm.emitSUB_Reg_Imm (SP, (numLocalVariables << LG_WORDSIZE)); // Retrieve -> preceeding "top" java FP from jniEnv and save in current // frame of JNIFunction asm.emitMOV_Reg_RegDisp (S0, EBX, VM_Entrypoints.JNITopJavaFPField.getOffsetAsInt()); // get offset from current FP and save in hdr of current frame asm.emitSUB_Reg_Reg (S0, EBP); asm.emitMOV_RegDisp_Reg (EBP, SAVED_JAVA_FP_OFFSET, S0); // put framePointer in VP following Jikes RVM conventions. VM_ProcessorLocalState.emitMoveRegToField(asm, VM_Entrypoints.framePointerField.getOffsetAsInt(), EBP); // at this point: JTOC and PR have been restored & // processor status = IN_JAVA, // arguments for the call have been setup, space on the stack for locals // has been acquired. // finally proceed with the normal Java compiled code // skip the thread switch test for now, see VM_Compiler.genThreadSwitchTest(true) asm.emitNOP(); // end of prologue marker }
5245 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5245/c19269673fcdd14e39a92c30e8ccef4cb7ce0402/VM_JNICompiler.java/clean/rvm/src/vm/arch/intel/jni/VM_JNICompiler.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 282, 1071, 760, 918, 2103, 21308, 344, 1085, 1290, 46, 50, 45, 1305, 12, 7397, 67, 1463, 5747, 749, 20415, 16, 8251, 67, 5506, 1305, 707, 16, 509, 707, 734, 13, 288, 565, 368, 444, 576, 48...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 918, 2103, 21308, 344, 1085, 1290, 46, 50, 45, 1305, 12, 7397, 67, 1463, 5747, 749, 20415, 16, 8251, 67, 5506, 1305, 707, 16, 509, 707, 734, 13, 288, 565, 368, 444, 576, 48...
url = new URL( "file:
url = new URL( "file:
public static Image getImage( String key ) { ImageRegistry imageRegistry = ReportPlugin.getDefault( ) .getImageRegistry( ); Image image = imageRegistry.get( key ); if ( image == null ) { URL url = ReportPlugin.getDefault( ).find( new Path( key ) ); if ( url == null ) { try { url = new URL( "file:///" + key ); } catch ( MalformedURLException e ) { } } if ( null != url ) { image = ImageDescriptor.createFromURL( url ).createImage( ); } if ( image == null ) { image = ImageDescriptor.getMissingImageDescriptor( ) .createImage( ); } imageRegistry.put( key, image ); } return image; }
5230 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5230/02592d02aa1066d3fcb7d374c14b7434ae94a419/ReportPlugin.java/buggy/UI/org.eclipse.birt.report.designer.ui/src/org/eclipse/birt/report/designer/ui/ReportPlugin.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 760, 3421, 10567, 12, 514, 498, 262, 202, 95, 202, 202, 2040, 4243, 1316, 4243, 273, 8706, 3773, 18, 588, 1868, 12, 262, 9506, 202, 18, 588, 2040, 4243, 12, 11272, 202, 202, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 760, 3421, 10567, 12, 514, 498, 262, 202, 95, 202, 202, 2040, 4243, 1316, 4243, 273, 8706, 3773, 18, 588, 1868, 12, 262, 9506, 202, 18, 588, 2040, 4243, 12, 11272, 202, 202, ...
StringBuffer sb = new StringBuffer(); sb.append("#<"); sb.append(rubyClass.getName()); sb.append(": "); sb.append(exception.getValue()); sb.append(">");
StringBuffer sb = new StringBuffer("#<"); sb.append(rubyClass.getName()).append(": ").append(exception.getValue()).append(">");
public IRubyObject inspect() { RubyModule rubyClass = getMetaClass(); RubyString exception = RubyString.stringValue(this); if (exception.getValue().length() == 0) { return getRuntime().newString(rubyClass.getName()); } StringBuffer sb = new StringBuffer(); sb.append("#<"); sb.append(rubyClass.getName()); sb.append(": "); sb.append(exception.getValue()); sb.append(">"); return getRuntime().newString(sb.toString()); }
1060 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1060/fe628a940467ceda783730ea34173dec3d365fa4/RubyException.java/buggy/src/org/jruby/RubyException.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 15908, 10340, 921, 5334, 1435, 288, 3639, 19817, 3120, 22155, 797, 273, 11312, 797, 5621, 3639, 19817, 780, 1520, 273, 19817, 780, 18, 1080, 620, 12, 2211, 1769, 3639, 309, 261, 4064,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 15908, 10340, 921, 5334, 1435, 288, 3639, 19817, 3120, 22155, 797, 273, 11312, 797, 5621, 3639, 19817, 780, 1520, 273, 19817, 780, 18, 1080, 620, 12, 2211, 1769, 3639, 309, 261, 4064,...
SwingUtilities.invokeLater(new NewInstRunner(fileName, useStdin));
SwingUtilities.invokeLater(new NewInstRunner(fileName, useStdin, adminMode));
public static void main(String[] args) { // parse command line String fileName = ""; boolean useStdin = false; for (int i = 0; i < args.length; i++) { if (args[i].startsWith("--")) { // command line argument if (args[i].equals("--stdin")) useStdin = true; else System.err.println(utils._("Unknown command line argument: ") + args[i]); } else if (args[i].startsWith("-")) System.err.println(utils._("Unknown command line argument: ") + args[i]); else // treat argument as file name to send fileName = args[i]; } Socket oldinst = checkLock(); if (oldinst == null) { SwingUtilities.invokeLater(new NewInstRunner(fileName, useStdin)); blockThread = new SockBlockAcceptor(); blockThread.start(); } else { try { if (useStdin) { BufferedOutputStream bufOut = new BufferedOutputStream(oldinst.getOutputStream()); BufferedInputStream bufIn = new BufferedInputStream(System.in); bufOut.write(codeSubmitStream); byte[] buf = new byte[16000]; int bytesRead = 0; do { bytesRead = bufIn.read(buf); if (bytesRead > 0) bufOut.write(buf, 0, bytesRead); } while (bytesRead >= 0); bufIn.close(); bufOut.close(); } else if ( fileName.length() > 0) { OutputStream outStream = oldinst.getOutputStream(); outStream.write(codeSubmitFile); BufferedWriter bufOut = new BufferedWriter(new OutputStreamWriter(outStream)); File f = new File(fileName); bufOut.write(f.getAbsolutePath() + "\n"); bufOut.close(); } else { System.err.println(utils._("There already is a running instance!")); System.exit(1); } oldinst.close(); } catch (IOException e) { System.err.println("An error occured communicating with the old instance: " + e.getMessage()); } } }
9845 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/9845/501caef152606724b38c4b135464ee58d6798d2d/Launcher.java/clean/yajhfc/yajhfc/Launcher.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 760, 918, 2774, 12, 780, 8526, 833, 13, 288, 3639, 368, 1109, 1296, 980, 3639, 514, 3968, 273, 1408, 31, 3639, 1250, 999, 10436, 267, 273, 629, 31, 7734, 364, 261, 474, 277, 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, 760, 918, 2774, 12, 780, 8526, 833, 13, 288, 3639, 368, 1109, 1296, 980, 3639, 514, 3968, 273, 1408, 31, 3639, 1250, 999, 10436, 267, 273, 629, 31, 7734, 364, 261, 474, 277, 273, ...
fireRequestMessage(new InfoDisplayEvent(this, event.getInformation()));
fireRequestMessage(new InfoDisplayEvent(this, event.getInformation()));
public void requestMessage(InfoDisplayEvent event) { fireRequestMessage(new InfoDisplayEvent(this, event.getInformation())); }
47208 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/47208/edbeffa6fb72058fbd5312d50c86c88fa8d47f6b/ScaleFilterLayer.java/buggy/src/openmap/com/bbn/openmap/layer/ScaleFilterLayer.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 918, 590, 1079, 12, 966, 4236, 1133, 871, 13, 288, 202, 12179, 691, 1079, 12, 2704, 3807, 4236, 1133, 12, 2211, 16, 871, 18, 588, 5369, 1435, 10019, 565, 289, 2, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 918, 590, 1079, 12, 966, 4236, 1133, 871, 13, 288, 202, 12179, 691, 1079, 12, 2704, 3807, 4236, 1133, 12, 2211, 16, 871, 18, 588, 5369, 1435, 10019, 565, 289, 2, -100, -100, -100,...
private void buildForm(String schema, String instance, String form, String root){
private void buildForm(String schema, String instance, String form, String root, String workItemID, String sessionHandle, String userID, String specID, String jsessionid){
private void buildForm(String schema, String instance, String form, String root){ Schema2XForms builder = new Schema2XForms(); ServletContext RP = getServletConfig().getServletContext(); String filePath = RP.getRealPath(File.separator+"forms"); // if schema != null etc. set directory to forms, not Tomcat/bin if (debug) System.out.println("YAWLServlet: setInputURI to "+schema); try{ builder.setInputURI(filePath+File.separator+schema); } catch(IOException e){ System.out.println("YAWLServlet IOException: "+e.toString()); } File f = new File(filePath+File.separator+form+".xhtml"); if (debug) System.out.println("YAWLServlet: setInstanceFile to "+instance); try{ builder.setInstanceFile(filePath+File.separator+instance); } catch(IOException e){ System.out.println("IOException: "+e.toString()); } builder.setInstanceHref("http://www.w3.org/2001/XMLSchema-instance"); // EG: YAWL = "http://localhost:8080/worklist/yawlFormServlet"; builder.setAction(RP.getInitParameter("YAWL")+"?userID="+userID+ "&sessionHandle="+sessionHandle+"&specID="+specID+ "&workItemID="+workItemID); // EG: FormBase = "http://localhost:8080/YAWLXForms/" builder.setBase(RP.getInitParameter("FormBase")); builder.setOutputFile(f); // goes in chiba forms directory builder.setRootTagName(root); builder.setStylesheet("html4yawl.xsl"); builder.setSubmitMethod("post"); builder.setWrapperType("XHTML"); builder.execute(); // TODO cleanup of temporary schema and instance files in forms directory (if existing) // an input param may be a root node for a complex type, meaning that all of its leaf nodes are input as well. if (s.size() > 0){ fixInputParams(f); } s.clear(); }
51637 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/51637/d57463b5298f76f58dfae0b6f344213d3574b499/YAWLServlet.java/buggy/yawl/build/yawlXForms/src/au/edu/qut/yawl/xformsupload/YAWLServlet.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 1152, 918, 19624, 12, 780, 1963, 16, 514, 791, 16, 514, 646, 16, 514, 1365, 15329, 9506, 202, 3078, 22, 60, 18529, 2089, 273, 394, 4611, 22, 60, 18529, 5621, 4697, 565, 22717, 534,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 19624, 12, 780, 1963, 16, 514, 791, 16, 514, 646, 16, 514, 1365, 15329, 9506, 202, 3078, 22, 60, 18529, 2089, 273, 394, 4611, 22, 60, 18529, 5621, 4697, 565, 22717, 534,...
int decision = JOptionPane.showConfirmDialog(this, Translator.getTranslation("QUESTION.COUNT_RUNNING_TASK", new String[] {task}), Translator.getTranslation("QUESTION.QUESTION_TITLE"), JOptionPane.YES_NO_OPTION, JOptionPane.QUESTION_MESSAGE);
String[] buttons = {Translator.getTranslation("QUESTION.BT_YES"), Translator.getTranslation("QUESTION.BT_NO")}; int decision = JOptionPane.showOptionDialog(this, Translator.getTranslation("QUESTION.COUNT_RUNNING_TASK", new String[] {task}), Translator.getTranslation("QUESTION.QUESTION_TITLE"), JOptionPane.YES_NO_OPTION, JOptionPane.QUESTION_MESSAGE, null, buttons, buttons[0]);
private void formWindowClosing(java.awt.event.WindowEvent evt) {//GEN-FIRST:event_formWindowClosing boolean warnHoursNotReaced = ((Boolean) Settings.getDefault().getSetting("warnHoursNotReached")).booleanValue(); if (warnHoursNotReaced) { double dayWorkHours = Double.parseDouble((String) Settings.getDefault().getSetting("dayWorkHours")); Day today = Plan.getDefault().getDay(new Date()); double totalTime = (double) today.getTotalTime()/(60 * 60 * 1000); if (totalTime < dayWorkHours) { int decision = JOptionPane.showConfirmDialog(this, Translator.getTranslation("WARNING.HOURS_NOT_REACHED"), Translator.getTranslation("WARNING.WARNING_TITLE"), JOptionPane.YES_NO_OPTION, JOptionPane.QUESTION_MESSAGE); if (decision == JOptionPane.NO_OPTION) return; } } Settings.getDefault().setSetting("size", "[" + (int) getBounds().getWidth() + "," + (int) getBounds().getHeight() + "]"); Settings.getDefault().setSetting("location", "[" + (int) getBounds().getLocation().getX() + "," + (int) getBounds().getLocation().getY() + "]"); Settings.saveSettings(); String task = (String) Settings.getDefault().getSetting("runningTask"); if ((task != null) && !task.equals("null")) { task = task.substring(0, task.indexOf("[")); int decision = JOptionPane.showConfirmDialog(this, Translator.getTranslation("QUESTION.COUNT_RUNNING_TASK", new String[] {task}), Translator.getTranslation("QUESTION.QUESTION_TITLE"), JOptionPane.YES_NO_OPTION, JOptionPane.QUESTION_MESSAGE); if (decision == JOptionPane.NO_OPTION) Settings.getDefault().setSetting("runningTask", null); Settings.saveSettings(); } int attempts = 0; while (true) { boolean planSaved = Plan.savePlan(); attempts++; if (planSaved) break; if (attempts == 10) { int decision = JOptionPane.showConfirmDialog(this, Translator.getTranslation("QUESTION.SELECT_LOCATION"), Translator.getTranslation("QUESTION.QUESTION_TITLE"), JOptionPane.YES_NO_OPTION, JOptionPane.QUESTION_MESSAGE); if (decision == JOptionPane.NO_OPTION) break; String location = (String) Settings.getDefault().getSetting("userdir"); JFileChooser fileChooser = new JFileChooser(location); fileChooser.setFileSelectionMode(JFileChooser.DIRECTORIES_ONLY); fileChooser.setApproveButtonText(Translator.getTranslation("HISTORYVIEW.BT_SELECT")); fileChooser.setApproveButtonMnemonic(Translator.getMnemonic("HISTORYVIEW.BT_SELECT")); decision = fileChooser.showOpenDialog(this); attempts = 0; if (decision == JFileChooser.APPROVE_OPTION) { File file = fileChooser.getSelectedFile(); Settings.getDefault().setSetting("userdir", file.getAbsolutePath()); } } } System.exit(0); }//GEN-LAST:event_formWindowClosing
4241 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/4241/34d60591c4394cd4a8eeca2e945382d14c99ceb1/MainWindow.java/buggy/src/org/cesilko/rachota/gui/MainWindow.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 3238, 918, 646, 3829, 15745, 12, 6290, 18, 2219, 88, 18, 2575, 18, 3829, 1133, 6324, 13, 288, 759, 16652, 17, 15354, 30, 2575, 67, 687, 3829, 15745, 3639, 1250, 1894, 14910, 1248, 426, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 646, 3829, 15745, 12, 6290, 18, 2219, 88, 18, 2575, 18, 3829, 1133, 6324, 13, 288, 759, 16652, 17, 15354, 30, 2575, 67, 687, 3829, 15745, 3639, 1250, 1894, 14910, 1248, 426, ...
double dXAxisLocation = adjustVerticalDueToHorizontal( dY, dH, aax );
double dXAxisLocation = adjustVerticalDueToHorizontalPlane( dY, dH, aax );
public void compute( Bounds bo ) throws ChartException, IllegalArgumentException { bo = bo.scaledInstance( dPointToPixel ); // CONVERSION // TODO compute seriesThickness as per rotation. // dSeriesThickness = // MAINTAIN IN LOCAL VARIABLES FOR PERFORMANCE/CONVENIENCE // TODO initial bounding box constraint, may compute as per the rotation // angle. double dX = bo.getLeft( ) + insCA.getLeft( ); double dY = bo.getTop( ) + insCA.getTop( ); double dW = bo.getWidth( ) - insCA.getLeft( ) - insCA.getRight( ); double dH = bo.getHeight( ) - insCA.getTop( ) - insCA.getBottom( ); // MUST BE 3-D DIMENSION ONLY HERE. iDimension = getDimension( cwa.getDimension( ) ); assert iDimension == IConstants.THREE_D; dXAxisPlotSpacing = cwa.getPlot( ).getHorizontalSpacing( ) * dPointToPixel; // CONVERSION dYAxisPlotSpacing = cwa.getPlot( ).getVerticalSpacing( ) * dPointToPixel; // CONVERSION dZAxisPlotSpacing = cwa.getPlot( ).getHorizontalSpacing( ) * dPointToPixel; // CONVERSION double dStart, dEnd; final Axis[] axa = cwa.getPrimaryBaseAxes( ); final Axis axPrimaryBase = axa[0]; final Axis axPrimaryOrthogonal = cwa.getPrimaryOrthogonalAxis( axPrimaryBase ); final Axis axAncillaryBase = cwa.getAncillaryBaseAxis( axPrimaryBase ); // COMPUTE PRIMARY-BASE-AXIS PROPERTIES AND ITS SCALE AutoScale scPrimaryBase = null; OneAxis oaxPrimaryBase = aax.getPrimaryBase( ); int iAxisType = getAxisType( axPrimaryBase ); Object oaData = null; if ( iAxisType == TEXT || oaxPrimaryBase.isCategoryScale( ) ) { oaData = getTypedDataSet( axPrimaryBase, iAxisType, 0 ); } else if ( ( iAxisType & NUMERICAL ) == NUMERICAL ) { oaData = getMinMax( axPrimaryBase, iAxisType ); } else if ( ( iAxisType & DATE_TIME ) == DATE_TIME ) { oaData = getMinMax( axPrimaryBase, iAxisType ); } DataSetIterator dsi = ( oaData instanceof DataSetIterator ) ? (DataSetIterator) oaData : new DataSetIterator( oaData, iAxisType ); oaData = null; // TODO compute 3d start end point. dStart = ( aax.areAxesSwapped( ) ) ? dY : dX; dEnd = ( aax.areAxesSwapped( ) ) ? dY + dH : dX + dW; Scale sc = axPrimaryBase.getScale( ); scPrimaryBase = AutoScale.computeScale( ids, oaxPrimaryBase, dsi, iAxisType, dStart, dEnd, sc.getMin( ), sc.getMax( ), sc.isSetStep( ) ? new Double( sc.getStep( ) ) : null, axPrimaryBase.getFormatSpecifier( ), rtc, true ); oaxPrimaryBase.set( scPrimaryBase ); // UPDATE SCALE ON PRIMARY-BASE // AXIS // COMPUTE ANCILLARY-BASE-AXIS PROPERTIES AND ITS SCALE AutoScale scAncillaryBase = null; OneAxis oaxAncillaryBase = aax.getAncillaryBase( ); iAxisType = getAxisType( axAncillaryBase ); oaData = null; if ( iAxisType == TEXT || oaxAncillaryBase.isCategoryScale( ) ) { oaData = getAncillaryDataSet( axAncillaryBase, axPrimaryOrthogonal, iAxisType ); } else if ( ( iAxisType & NUMERICAL ) == NUMERICAL ) { oaData = getMinMax( axAncillaryBase, iAxisType ); } else if ( ( iAxisType & DATE_TIME ) == DATE_TIME ) { oaData = getMinMax( axAncillaryBase, iAxisType ); } dsi = ( oaData instanceof DataSetIterator ) ? (DataSetIterator) oaData : new DataSetIterator( oaData, iAxisType ); oaData = null; // TODO compute 3d start end point, use the same setting as primary base // axis here. dStart = ( aax.areAxesSwapped( ) ) ? dY : dX; dEnd = ( aax.areAxesSwapped( ) ) ? dY + dH : dX + dW; sc = axAncillaryBase.getScale( ); scAncillaryBase = AutoScale.computeScale( ids, oaxAncillaryBase, dsi, iAxisType, dStart, dEnd, sc.getMin( ), sc.getMax( ), sc.isSetStep( ) ? new Double( sc.getStep( ) ) : null, axAncillaryBase.getFormatSpecifier( ), rtc, true ); oaxAncillaryBase.set( scAncillaryBase ); // UPDATE SCALE ON // ANCILLARY-BASE AXIS // COMPUTE PRIMARY-ORTHOGONAL-AXIS PROPERTIES AND ITS SCALE AutoScale scPrimaryOrthogonal = null; OneAxis oaxPrimaryOrthogonal = aax.getPrimaryOrthogonal( ); iAxisType = getAxisType( axPrimaryOrthogonal ); oaData = null; if ( ( iAxisType & NUMERICAL ) == NUMERICAL || ( iAxisType & DATE_TIME ) == DATE_TIME ) { dsi = new DataSetIterator( getMinMax( axPrimaryOrthogonal, iAxisType ), iAxisType ); } else { throw new ChartException( ChartEnginePlugin.ID, ChartException.DATA_FORMAT, "exception.orthogonal.axis.numerical.datetime", //$NON-NLS-1$ ResourceBundle.getBundle( Messages.ENGINE, rtc.getLocale( ) ) ); } // TODO compute 3d start end point. dStart = ( aax.areAxesSwapped( ) ) ? dX : dY; dEnd = ( aax.areAxesSwapped( ) ) ? dX + dW : dY + dH; sc = axPrimaryOrthogonal.getScale( ); scPrimaryOrthogonal = AutoScale.computeScale( ids, oaxPrimaryOrthogonal, dsi, iAxisType, dStart, dEnd, sc.getMin( ), sc.getMax( ), sc.isSetStep( ) ? new Double( sc.getStep( ) ) : null, axPrimaryOrthogonal.getFormatSpecifier( ), rtc, true ); oaxPrimaryOrthogonal.set( scPrimaryOrthogonal ); // UPDATE SCALE ON // PRIMARY-ORTHOGONAL AXIS // TODO here we should ignore the intersection Value/Max setting, always // use the Intersection.Min for 3D chart. the adjustVerticalXXX() should // return a double[] to // indicate a coordinate value. // ITERATIVELY ADJUST THE PRIMARY ORTHOGONAL AXIS POSITION DUE TO THE // SCALE, START/END LABELS double dYAxisLocationOnX = adjustHorizontal( dX, dW, aax ); // Iteratively adjust the ancillary base axis position due to the scale, // start/end // labels. double dYAxisLocationOnZ = adjustAncillary( dX, dW, aax ); // ITERATIVELY ADJUST THE PRIMARY BASE AXIS POSITION DUE TO THE SCALE, // START/END LABELS double dXAxisLocation = adjustVerticalDueToHorizontal( dY, dH, aax ); // TODO Just use XAxisLocation as the ZAxisLocation now. double dZAxisLocation = dXAxisLocation; // SETUP THE FULL DATASET FOR THE PRIMARY ORTHOGONAL AXIS iAxisType = getAxisType( axPrimaryOrthogonal ); oaData = getTypedDataSet( axPrimaryOrthogonal, iAxisType, 0 ); scPrimaryOrthogonal.setData( dsi ); // Setup the full dataset for the ancillary base axis. iAxisType = getAxisType( axAncillaryBase ); if ( iAxisType != IConstants.TEXT ) { scAncillaryBase.setData( getTypedDataSet( axAncillaryBase, iAxisType, 0 ) ); } // SETUP THE FULL DATASET FOR THE PRIMARY ORTHOGONAL AXIS iAxisType = getAxisType( axPrimaryBase ); if ( iAxisType != IConstants.TEXT ) { scPrimaryBase.setData( getTypedDataSet( axPrimaryBase, iAxisType, 0 ) ); } scPrimaryBase.resetShifts( ); scAncillaryBase.resetShifts( ); scPrimaryOrthogonal.resetShifts( ); // UPDATE FOR OVERLAYS final OneAxis axPH = aax.areAxesSwapped( ) ? aax.getPrimaryOrthogonal( ) : aax.getPrimaryBase( ); final OneAxis axPV = aax.areAxesSwapped( ) ? aax.getPrimaryBase( ) : aax.getPrimaryOrthogonal( ); final OneAxis axAB = aax.getAncillaryBase( ); // keep old invocation to ensure compatibility. axPH.setAxisCoordinate( dXAxisLocation ); axPV.setAxisCoordinate( dYAxisLocationOnX ); axAB.setAxisCoordinate( dZAxisLocation ); // set new 3D axis coordinate. this coordinate has been normalized to // Zero-coordinates. axPH.setAxisCoordinate3D( Location3DImpl.create( 0, dXAxisLocation - scPrimaryOrthogonal.getStart( ), 0 ) ); axPV.setAxisCoordinate3D( Location3DImpl.create( dYAxisLocationOnX - scPrimaryBase.getStart( ), 0, dYAxisLocationOnZ - scAncillaryBase.getStart( ) ) ); axAB.setAxisCoordinate3D( Location3DImpl.create( 0, dZAxisLocation - scPrimaryOrthogonal.getStart( ), 0 ) ); // !Always use Zero origin for 3D coordinates. // axPH.setAxisCoordinate3D( Location3DImpl.create( 0, 0, 0 ) ); // axPV.setAxisCoordinate3D( Location3DImpl.create( 0, 0, 0 ) ); // axAB.setAxisCoordinate3D( Location3DImpl.create( 0, 0, 0 ) ); boPlotBackground = (Bounds) EcoreUtil.copy( bo ); }
46013 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/46013/a6ca386b9ce6eac6f60e60625c07b65c23f0fb6a/PlotWith3DAxes.java/clean/chart/org.eclipse.birt.chart.engine/src/org/eclipse/birt/chart/computation/withaxes/PlotWith3DAxes.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 918, 3671, 12, 20382, 800, 262, 1216, 14804, 503, 16, 1082, 202, 31237, 202, 95, 202, 202, 1075, 273, 800, 18, 20665, 1442, 12, 302, 2148, 774, 9037, 11272, 368, 3492, 5757, 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, 482, 918, 3671, 12, 20382, 800, 262, 1216, 14804, 503, 16, 1082, 202, 31237, 202, 95, 202, 202, 1075, 273, 800, 18, 20665, 1442, 12, 302, 2148, 774, 9037, 11272, 368, 3492, 5757, 2...
public void setHearingRange ( double range ) { hearingRange = range; }
4438 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/4438/2fde1e280a947dddab3f2a402a2927ea6b087d81/Player.java/buggy/src/games/stendhal/client/entity/Player.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1071, 6459, 542, 44, 2091, 310, 2655, 12, 2896, 440, 264, 726, 15329, 580, 5968, 2655, 33, 3676, 31, 97, 2, 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, 1071, 6459, 542, 44, 2091, 310, 2655, 12, 2896, 440, 264, 726, 15329, 580, 5968, 2655, 33, 3676, 31, 97, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, ...
clearWarnings(); ExecSQL("show xactisolevel");
clearWarnings(); ExecSQL("show xactisolevel");
public int getTransactionIsolation() throws SQLException { clearWarnings(); ExecSQL("show xactisolevel"); SQLWarning warning = getWarnings(); if (warning != null) { String message = warning.getMessage(); clearWarnings(); if (message.indexOf("READ COMMITTED") != -1) return java.sql.Connection.TRANSACTION_READ_COMMITTED; else if (message.indexOf("READ UNCOMMITTED") != -1) return java.sql.Connection.TRANSACTION_READ_UNCOMMITTED; else if (message.indexOf("REPEATABLE READ") != -1) return java.sql.Connection.TRANSACTION_REPEATABLE_READ; else if (message.indexOf("SERIALIZABLE") != -1) return java.sql.Connection.TRANSACTION_SERIALIZABLE; } return java.sql.Connection.TRANSACTION_READ_COMMITTED; }
45454 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/45454/839b9bc0117946afd62ee385a4c8a36c01b3053b/Connection.java/buggy/src/interfaces/jdbc/org/postgresql/Connection.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 509, 15674, 22982, 1435, 1216, 6483, 288, 202, 8507, 4312, 5621, 202, 1905, 3997, 2932, 4500, 619, 621, 291, 790, 941, 8863, 202, 3997, 6210, 3436, 273, 336, 4312, 5621, 202, 430, 2...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 509, 15674, 22982, 1435, 1216, 6483, 288, 202, 8507, 4312, 5621, 202, 1905, 3997, 2932, 4500, 619, 621, 291, 790, 941, 8863, 202, 3997, 6210, 3436, 273, 336, 4312, 5621, 202, 430, 2...
BundleContext bundleContext = framework.getBundleContext(bundle);
BundleContext bundleContext = framework.getBundleContext(bundle);
public Object addingBundle(Bundle bundle) { List enableComponentDescriptions = new ArrayList(); PackageAdmin packageAdmin = (PackageAdmin) packageAdminTracker.getService(); if (packageAdmin.getBundleType(bundle) != 0) { return null; // don't process fragments. } Long bundleID = new Long(bundle.getBundleId()); // get the bundle's last modified date Long bundleLastModified = new Long(bundle.getLastModified()); // get the last saved value for the bundle's last modified date Long bundleOldLastModified = (Long) bundleToLastModified.get(bundleID); // compare the two and if changed ( or if first time ) update the maps if ((!bundleLastModified.equals(bundleOldLastModified)) || (bundleOldLastModified == null)) { // get the BundleContext for this bundle (framework impl dependent) BundleContext bundleContext = framework.getBundleContext(bundle); // get all ComponentDescriptions for this bundle List componentDescriptions = cache.getComponentDescriptions(bundleContext); // update map of bundle to ComponentDescriptions bundleToComponentDescriptions.put(bundleID, componentDescriptions); // update bundle:lastModifiedDate map bundleToLastModified.put(bundleID, bundleLastModified); // for each CD in bundle set enable flag based on autoenable Iterator it = componentDescriptions.iterator(); while (it.hasNext()) { ComponentDescription componentDescription = (ComponentDescription) it.next(); validate(componentDescription); if (componentDescription.isAutoenable() && componentDescription.isValid()) { componentDescription.setEnabled(true); enableComponentDescriptions.add(componentDescription); } } } // publish all CDs to be enabled, to resolver (add to the workqueue and // publish event) if (!enableComponentDescriptions.isEmpty()) { workQueue.enqueueWork(this, ADD, enableComponentDescriptions); } return bundleID; }
13530 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/13530/b720998dbe74e7a4c87f381fa780a881259f68c7/Activator.java/buggy/bundles/org.eclipse.equinox.ds/src/org/eclipse/equinox/ds/Activator.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 1033, 6534, 3405, 12, 3405, 3440, 13, 288, 202, 202, 682, 4237, 1841, 16844, 273, 394, 2407, 5621, 202, 202, 2261, 4446, 2181, 4446, 273, 261, 2261, 4446, 13, 2181, 4446, 8135, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 1033, 6534, 3405, 12, 3405, 3440, 13, 288, 202, 202, 682, 4237, 1841, 16844, 273, 394, 2407, 5621, 202, 202, 2261, 4446, 2181, 4446, 273, 261, 2261, 4446, 13, 2181, 4446, 8135, ...
for (RubyModule p = module.getSuperClass(); p != null; p = p.getSuperClass()) { includeModule(p); }
public synchronized void includeModule(IRubyObject arg) { testFrozen("module"); if (!isTaint()) { getRuntime().secure(4); } if (!(arg instanceof RubyModule)) { throw getRuntime().newTypeError("Wrong argument type " + arg.getMetaClass().getName() + " (expected Module)."); } RubyModule module = (RubyModule) arg; Map moduleMethods = module.getMethods(); // Make sure the module we include does not already exist for (RubyModule p = this; p != null; p = p.getSuperClass()) { // XXXEnebo - Lame equality check (cause: IncludedModule?) if (p.getMethods() == moduleMethods) { return; } } // Invalidate cache for all methods in the new included module in case a base class method // of the same name has already been cached. for (Iterator iter = moduleMethods.keySet().iterator(); iter.hasNext();) { String methodName = (String) iter.next(); getRuntime().getCacheMap().remove(methodName, searchMethod(methodName)); } // Include new module setSuperClass(module.newIncludeClass(getSuperClass())); // Try to include all included modules from module just added for (RubyModule p = module.getSuperClass(); p != null; p = p.getSuperClass()) { includeModule(p); } module.callMethod("included", this); }
50993 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50993/a1b8fc1d456e3d5c6e01579b88773383068aa85c/RubyModule.java/buggy/src/org/jruby/RubyModule.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 3852, 918, 2341, 3120, 12, 7937, 10340, 921, 1501, 13, 288, 3639, 1842, 42, 9808, 2932, 2978, 8863, 3639, 309, 16051, 291, 29048, 10756, 288, 5411, 18814, 7675, 8869, 12, 24, 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, 1071, 3852, 918, 2341, 3120, 12, 7937, 10340, 921, 1501, 13, 288, 3639, 1842, 42, 9808, 2932, 2978, 8863, 3639, 309, 16051, 291, 29048, 10756, 288, 5411, 18814, 7675, 8869, 12, 24, 1769, ...
if (explodePos >= explodeBuf.length()) { explodePos = EMPTY; explodeBuf.setLength(0); ch = DONE; } else { ch = explodeBuf.charAt(explodePos++); if (explodePos >= explodeBuf.length()) { explodePos = EMPTY; explodeBuf.setLength(0); } }
ch = explodeBuf.charAt(explodePos++); if (explodePos >= explodeBuf.length()) { explodePos = EMPTY; explodeBuf.setLength(0); }
private char nextCompose() { if (DEBUG) System.out.println("--------------- top of nextCompose() --------------------"); int explodePos = EMPTY; // Position in input buffer int basePos = 0; // Position of last base in output string int baseIndex = 0; // Index of last base in "actions" array int classesSeenL = 0; // Combining classes seen since last base int classesSeenH = 0; // 64-bit mask int action; char lastBase = 0; boolean chFromText = true; // Compatibility explosions have lower indices; skip them if necessary int minExplode = mode.compat() ? 0 : ComposeData.MAX_COMPAT; int minDecomp = mode.compat() ? 0 : DecompData.MAX_COMPAT; initBuffer(); if (explodeBuf == null) { explodeBuf = new StringBuffer(); } else { explodeBuf.setLength(0); } char ch = curForward(); while (ch != DONE) { // Get the basic info for the character int charInfo = composeLookup(ch); int type = charInfo & ComposeData.TYPE_MASK; int index = charInfo >>> ComposeData.INDEX_SHIFT; if (type == ComposeData.BASE || type == ComposeData.NON_COMPOSING_COMBINING && index < minExplode) { if (buffer.length() > 0 && chFromText && explodePos == EMPTY) { // When we hit a base char in the source text, we can return the text // that's been composed so far. We'll re-process this char next time through. if (DEBUG) System.out.println("returning early because we hit a new base"); break; } classesSeenL = classesSeenH = 0; baseIndex = index; basePos = buffer.length(); buffer.append(ch); if (DEBUG) System.out.println("got BASE char " + hex(ch) + ", type=" + type + ", index=" + index); lastBase = ch; } else if (type == ComposeData.COMBINING && index > 0) { int cclass = ComposeData.typeBit[index]; boolean seen = 0 != ((cclass < 32) ? (classesSeenL & (1 << cclass)) : (classesSeenH & (1 << (cclass & 31)))); if (DEBUG) System.out.println("got COMBINING char " + hex(ch) + ", type=" + type + ", index=" + index + ", class=" + cclass); // We can only combine a character with the base if we haven't // already seen a combining character with the same canonical class. if (index < ComposeData.COMBINING_COUNT && !seen && (action = composeAction(baseIndex, index)) > 0) { if (action > ComposeData.MAX_COMPOSED) { // Pairwise explosion. Actions above this value are really // indices into an array that in turn contains indices // into the exploding string table // TODO: What if there are unprocessed chars in the explode buffer? char newBase = pairExplode(explodeBuf, action); explodePos = 0; buffer.setCharAt(basePos, newBase); baseIndex = composeLookup(newBase) >>> ComposeData.INDEX_SHIFT; if (DEBUG) System.out.println("Pairwise explosion: " + hex(lastBase) + "," + hex(ch) + " --> " + hex(newBase) + "," + hex(explodeBuf)); lastBase = newBase; } else { // Normal pairwise combination. Replace the base char char newBase = (char) action; buffer.setCharAt(basePos, newBase); baseIndex = composeLookup(newBase) >>> ComposeData.INDEX_SHIFT; if (DEBUG) System.out.println("Pairwise combination: " + hex(lastBase) + "," + hex(ch) + " --> " + hex(newBase)); lastBase = newBase; } // // Since there are Unicode characters that cannot be combined in arbitrary // order, we have to re-process any combining marks that go with this // base character. There are only four characters in Unicode that have // this problem. If they are fixed in Unicode 3.0, this code can go away. // int len = buffer.length(); if (len - basePos > 1) { if (DEBUG) System.out.println("Reprocessing combining marks"); for (int j = basePos+1; j < len; j++) { explodeBuf.append(buffer.charAt(j)); } buffer.setLength(basePos+1); classesSeenL = classesSeenH = 0; if (explodePos == EMPTY) explodePos = 0; } } else { if (DEBUG) System.out.println("char doesn't combine"); // No combination with this character bubbleAppend(buffer, ch, cclass); if (cclass < 32) { classesSeenL |= 1 << cclass; } else { classesSeenH |= 1 << (cclass & 31); } } } else if (index > minExplode) { // Single exploding character explode(explodeBuf, index); explodePos = 0; if (DEBUG) System.out.println("explosion: " + hex(ch) + " --> " + hex(explodeBuf)); } else if (type == ComposeData.HANGUL && minExplode == 0) { // If we're in compatibility mode we need to decompose Hangul to Jamo, // because some of the Jamo might have compatibility decompositions. hangulToJamo(ch, explodeBuf, minDecomp); if (DEBUG) System.out.println("decomposed hangul " + hex(ch) + " to jamo " + hex(explodeBuf)); explodePos = 0; } else if (type == ComposeData.INITIAL_JAMO) { if (buffer.length() > 0 && chFromText && explodePos == EMPTY) { // When we hit a base char in the source text, we can return the text // that's been composed so far. We'll re-process this char next time through. if (DEBUG) System.out.println("returning early because we hit a new base"); break; } classesSeenL = classesSeenH = 0; baseIndex = ComposeData.INITIAL_JAMO_INDEX; basePos = buffer.length(); buffer.append(ch); if (DEBUG) System.out.println("got initial jamo " + hex(ch)); } else if (type == ComposeData.MEDIAL_JAMO && classesSeenL == 0 && classesSeenH == 0 && baseIndex == ComposeData.INITIAL_JAMO_INDEX) { // If the last character was an initial jamo, we can combine it with this // one to create a Hangul character. int l = buffer.charAt(basePos) - JAMO_LBASE; int v = ch - JAMO_VBASE; char newCh = (char)(HANGUL_BASE + (l*JAMO_VCOUNT + v) * JAMO_TCOUNT); buffer.setCharAt(basePos, newCh); if (DEBUG) System.out.println("got medial jamo " + hex(ch) + ", replacing with Hangul " + hex(newCh)); baseIndex = ComposeData.MEDIAL_JAMO_INDEX; } else if (type == ComposeData.FINAL_JAMO && classesSeenL == 0 && classesSeenH == 0 && baseIndex == ComposeData.MEDIAL_JAMO_INDEX) { // If the last character was a medial jamo that we turned into Hangul, // we can add this character too. char newCh = (char)(buffer.charAt(basePos) + (ch - JAMO_TBASE)); buffer.setCharAt(basePos, newCh); if (DEBUG) System.out.println("got final jamo " + hex(ch) + ", replacing with Hangul " + hex(newCh)); baseIndex = 0; basePos = -1; classesSeenL = classesSeenH = 0; } else { // TODO: deal with JAMO character types baseIndex = 0; basePos = -1; classesSeenL = classesSeenH = 0; buffer.append(ch); if (DEBUG) System.out.println("UNKNOWN char " + hex(ch)); } if (explodePos == EMPTY) { ch = text.next(); chFromText = true; } else { // NOTE: I added the following if() block to catch a case that was // happening during test runs. charAt() was being called (below) // with an out-of-range index. This fix makes the tests run and // pass, but this clearly isn't the right way to fix this. Someone // needs to come back and clean this up later. - liu 7/13/00 if (explodePos >= explodeBuf.length()) { // fix explodePos = EMPTY; // fix explodeBuf.setLength(0); // fix ch = DONE; // fix } else { // fix ch = explodeBuf.charAt(explodePos++); if (explodePos >= explodeBuf.length()) { explodePos = EMPTY; explodeBuf.setLength(0); } } // fix chFromText = false; } } if (buffer.length() > 0) { bufferLimit = buffer.length() - 1; ch = buffer.charAt(0); } else { ch = DONE; bufferLimit = 0; } return ch; }
5620 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5620/1c254cf440ab63dde02c1b18fbd8b7c64a1944d0/Normalizer.java/buggy/icu4j/src/com/ibm/icu/text/Normalizer.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 3238, 1149, 1024, 22375, 1435, 565, 288, 3639, 309, 261, 9394, 13, 2332, 18, 659, 18, 8222, 2932, 18753, 1760, 434, 1024, 22375, 1435, 12146, 6062, 8863, 3639, 509, 377, 3172, 1616, 273, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 3238, 1149, 1024, 22375, 1435, 565, 288, 3639, 309, 261, 9394, 13, 2332, 18, 659, 18, 8222, 2932, 18753, 1760, 434, 1024, 22375, 1435, 12146, 6062, 8863, 3639, 509, 377, 3172, 1616, 273, ...
}
}
public CAInfo getCAInfo(Admin admin, String name) { CAInfo cainfo = null; try{ CADataLocal cadata = cadatahome.findByName(name); if(cadata.getStatus() == SecConst.CA_ACTIVE && new Date(cadata.getExpireTime()).before(new Date())){ cadata.setStatus(SecConst.CA_EXPIRED); } authorizedToCA(admin,cadata.getCAId().intValue()); try{ cadata.getCA().getCAToken().getPublicKey(SecConst.CAKEYPURPOSE_CERTSIGN); }catch(CATokenOfflineException ctoe){ cadata.setStatus(SecConst.CA_OFFLINE); } cainfo = cadata.getCA().getCAInfo(); }catch(javax.ejb.FinderException fe) {} catch(Exception e){ throw new EJBException(e); } return cainfo; } // getCAInfo
4109 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/4109/6f27459e8db7a9efb8cf0588695ad6fd28539506/CAAdminSessionBean.java/clean/src/java/se/anatom/ejbca/ca/caadmin/CAAdminSessionBean.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 6425, 966, 1927, 37, 966, 12, 4446, 3981, 16, 514, 508, 13, 288, 3639, 6425, 966, 276, 28935, 273, 446, 31, 3639, 775, 95, 5411, 6425, 751, 2042, 28451, 396, 273, 28451, 396, 8712...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 6425, 966, 1927, 37, 966, 12, 4446, 3981, 16, 514, 508, 13, 288, 3639, 6425, 966, 276, 28935, 273, 446, 31, 3639, 775, 95, 5411, 6425, 751, 2042, 28451, 396, 273, 28451, 396, 8712...
if (isSearchRequest()) {
if (isScopeRequest()) { workingSetName = getDBCSParameter("workingSet"); } else if (isSearchRequest()) {
public String getScope() { if (workingSetName != null) return workingSetName; if (isSearchRequest()) { workingSetName = request.getParameter("scope"); // if we have already set the working set, then use it. if (workingSetName == null) workingSetName = getDBCSParameter("workingSet"); } else if (isScopeRequest()) { workingSetName = getDBCSParameter("workingSet"); } else { workingSetName = HelpPlugin.getDefault().getPluginPreferences().getString( HelpSystem.WORKING_SET); } if (workingSetName == null || workingSetName.length() == 0 || HelpSystem.getWorkingSetManager(getLocale()).getWorkingSet( workingSetName) == null) workingSetName = ServletResources.getString("All", request); return workingSetName; }
13822 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/13822/7184d20fde9a98097ec1d383b7e8d1ed3f84fe47/SearchData.java/clean/org.eclipse.help.webapp/src_servlets/org/eclipse/help/internal/webapp/data/SearchData.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 514, 19203, 1435, 288, 202, 202, 430, 261, 20478, 11924, 480, 446, 13, 1082, 202, 2463, 5960, 11924, 31, 202, 202, 430, 261, 291, 2979, 691, 10756, 288, 1082, 202, 20478, 11924,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 514, 19203, 1435, 288, 202, 202, 430, 261, 20478, 11924, 480, 446, 13, 1082, 202, 2463, 5960, 11924, 31, 202, 202, 430, 261, 291, 2979, 691, 10756, 288, 1082, 202, 20478, 11924,...
Job job= info.getJob(); if (job != null) setStatus(job);
if (jte instanceof JobInfo) { JobInfo ji= (JobInfo) jte; Job job= ji.getJob(); if (job != null) setStatus(job); }
public void finished(final JobInfo info) { final Display display= Display.getDefault(); display.asyncExec(new Runnable() { public void run() { Job job= info.getJob(); if (job != null) setStatus(job); } }); }
58148 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/58148/f52d6b94fa30f7dd2c2921a0ba5441c40e4c4f88/ProgressAnimationItem.java/clean/bundles/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal/progress/ProgressAnimationItem.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 918, 6708, 12, 6385, 3956, 966, 1123, 13, 288, 202, 565, 727, 9311, 2562, 33, 9311, 18, 588, 1868, 5621, 202, 565, 2562, 18, 3810, 1905, 12, 2704, 10254, 1435, 288, 202, 3639, 107...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 6708, 12, 6385, 3956, 966, 1123, 13, 288, 202, 565, 727, 9311, 2562, 33, 9311, 18, 588, 1868, 5621, 202, 565, 2562, 18, 3810, 1905, 12, 2704, 10254, 1435, 288, 202, 3639, 107...
name = name.substring( offset ); final char first = Character.toLowerCase( name.charAt( 0 ) ); name = first + name.substring( 1 ); return name;
if ( offset > 0 ) { name = name.substring( offset ); } String result = ( String ) this.fields.get( name.toLowerCase() ); if ( result == null ) { final char first = Character.toLowerCase( name.charAt( 0 ) ); result = first + name.substring( 1 ); } return result;
private String calcFieldName(String name, final int offset) { name = name.substring( offset ); final char first = Character.toLowerCase( name.charAt( 0 ) ); name = first + name.substring( 1 ); return name; }
6736 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/6736/6a00d1959cb09de1e6228ddc9541e74af2ed706b/ClassFieldInspector.java/buggy/drools-core/src/main/java/org/drools/util/asm/ClassFieldInspector.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 540, 3238, 514, 7029, 7287, 12, 780, 508, 16, 19694, 727, 509, 1384, 13, 288, 5411, 508, 273, 508, 18, 28023, 12, 1384, 11272, 5411, 727, 1149, 1122, 273, 6577, 18, 869, 5630, 12, 508, 18, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 540, 3238, 514, 7029, 7287, 12, 780, 508, 16, 19694, 727, 509, 1384, 13, 288, 5411, 508, 273, 508, 18, 28023, 12, 1384, 11272, 5411, 727, 1149, 1122, 273, 6577, 18, 869, 5630, 12, 508, 18, ...
/* ResolvedCritic(Critic, VectorSet) */
/* ResolvedCritic(Critic, VectorSet) */
public void testConstructors() { MClass testmc = CoreFactory.getFactory().buildClass(); Critic c = new Critic(); String crString = "class org.argouml.cognitive.critics.Critic"; ResolvedCritic rc; Vector vec = new Vector(); VectorSet set = new VectorSet(); /* ResolvedCritic(String, Vector) */ rc = new ResolvedCritic("rc", null); assertTrue("getCritic simple", "rc".equals(rc.getCritic())); assertTrue( "getOffenderList simple", rc.getOffenderList() == null || rc.getOffenderList().size() == 0); vec.add("str1"); rc = new ResolvedCritic("rc2", vec); assertTrue("getCritic 2nd", "rc2".equals(rc.getCritic())); assertTrue( "getOffenderList 2nd", rc.getOffenderList() != null && "str1".equals(rc.getOffenderList().get(0))); /* ResolvedCritic(Critic, VectorSet) */ try { rc = new ResolvedCritic(c, null); System.out.println(rc.getCritic()); assertTrue("getCritic 1", crString.equals(rc.getCritic())); assertTrue( "getOffenderList 1", rc.getOffenderList() == null || rc.getOffenderList().size() == 0); } catch (UnresolvableException ure1) { assertTrue("create 1 with MClass", false); } set.addElement(testmc); try { rc = new ResolvedCritic(c, set); assertTrue("getCritic 2", crString.equals(rc.getCritic())); assertTrue( "assigns id 2", ItemUID.getIDOfObject(testmc, false) != null); assertTrue( "getOffenderList 2", rc.getOffenderList() != null && ItemUID.getIDOfObject(testmc, false).equals( rc.getOffenderList().get(0))); } catch (UnresolvableException ure1) { assertTrue("create 2 with MClass", false); } /* ResolvedCritic(Critic, VectorSet, boolean) */ /* testmc should now have an ItemUID so we should be able to * create without adding a new ItemUID */ try { rc = new ResolvedCritic(c, set, false); assertTrue("getCritic 3", crString.equals(rc.getCritic())); assertTrue( "assigns id 3", ItemUID.getIDOfObject(testmc, false) != null); assertTrue( "getOffenderList 3", rc.getOffenderList() != null && ItemUID.getIDOfObject(testmc, false).equals( rc.getOffenderList().get(0))); } catch (UnresolvableException ure1) { assertTrue("create 3 with MClass", false); } set.remove(testmc); }
7166 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/7166/5f6191c876d7ba33373fe98de4e3c7d94a09c303/TestResolvedCritic.java/clean/tests/org/argouml/cognitive/TestResolvedCritic.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 918, 1842, 29590, 1435, 288, 202, 202, 49, 797, 1842, 13952, 273, 4586, 1733, 18, 588, 1733, 7675, 3510, 797, 5621, 202, 202, 39, 583, 335, 276, 273, 394, 385, 583, 335, 5621,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 29590, 1435, 288, 202, 202, 49, 797, 1842, 13952, 273, 4586, 1733, 18, 588, 1733, 7675, 3510, 797, 5621, 202, 202, 39, 583, 335, 276, 273, 394, 385, 583, 335, 5621,...
try { setMethod((String) evalAttr("method", getMethodExpr(), String.class)); } catch (NullAttributeException ex) { }
if ((string = EvalHelper.evalString("formName", getFormNameExpr(), this, pageContext)) != null) setFormName(string);
private void evaluateExpressions() throws JspException { try { setCdata((String) evalAttr("cdata", getCdataExpr(), String.class)); } catch (NullAttributeException ex) { } try { setDynamicJavascript((String) evalAttr("dynamicJavascript", getDynamicJavascriptExpr(), String.class)); } catch (NullAttributeException ex) { } try { setFormName((String) evalAttr("formName", getFormNameExpr(), String.class)); } catch (NullAttributeException ex) { } try { setMethod((String) evalAttr("method", getMethodExpr(), String.class)); } catch (NullAttributeException ex) { } try { setPage(((Integer) evalAttr("page", getPageExpr(), Integer.class)). intValue()); } catch (NullAttributeException ex) { } try { setSrc((String) evalAttr("src", getSrcExpr(), String.class)); } catch (NullAttributeException ex) { } try { setStaticJavascript((String) evalAttr("staticJavascript", getStaticJavascriptExpr(), String.class)); } catch (NullAttributeException ex) { } try { setHtmlComment((String) evalAttr("htmlComment", getHtmlCommentExpr(), String.class)); } catch (NullAttributeException ex) { } }
8610 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/8610/161d973cb8d39005faf380ea401e605000b8884b/ELJavascriptValidatorTag.java/clean/struts-el/src/share/org/apache/strutsel/taglib/html/ELJavascriptValidatorTag.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 3238, 918, 5956, 8927, 1435, 1216, 27485, 288, 3639, 775, 288, 5411, 11440, 892, 12443, 780, 13, 5302, 3843, 2932, 71, 892, 3113, 1927, 892, 4742, 9334, 4766, 4202, 514, 18, 1106, 10019, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 5956, 8927, 1435, 1216, 27485, 288, 3639, 775, 288, 5411, 11440, 892, 12443, 780, 13, 5302, 3843, 2932, 71, 892, 3113, 1927, 892, 4742, 9334, 4766, 4202, 514, 18, 1106, 10019, ...
zipOut = new ZipOutputStream(new BufferedOutputStream(new FileOutputStream(outFilename)));
bos = new BufferedOutputStream(new FileOutputStream(outFilename)); zipOut = new ZipOutputStream(bos);
public static void zipFolderContents(String outFilename, String folderToZip) { validateParams(outFilename, folderToZip); ZipOutputStream zipOut = null; try { zipOut = new ZipOutputStream(new BufferedOutputStream(new FileOutputStream(outFilename))); File folder = new File(folderToZip); String message = "Zipping files to: " + outFilename; LOG.info(message); System.out.println(message); zipFiles(folder, folder, zipOut); message = "Finished zipping files"; LOG.info(message); System.out.println(message); } catch (FileNotFoundException fnfe) { String message = "File not found while zipping files to: " + outFilename; LOG.error(message, fnfe); System.err.println(message + " - " + fnfe.getMessage()); throw new RuntimeException(message, fnfe); } finally { try { // TODO: Need to do a flush here? // zipOut.flush(); zipOut.close(); } catch (ZipException ze) { File file = new File(outFilename); if ((file.length() == 0) && (file.exists())) { String message = "Empty zip file created: " + outFilename; LOG.debug(message); System.out.println(message); } } catch (IOException ioe) { String message = "Error occured while closing zip file: " + outFilename; LOG.error(message, ioe); System.err.println(message); throw new RuntimeException(message, ioe); } } }
52149 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52149/9b048f956473546e22e03ac75ec93440e90e1086/ZipUtil.java/buggy/contrib/distributed/src/net/sourceforge/cruisecontrol/distributed/util/ZipUtil.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 760, 918, 3144, 3899, 6323, 12, 780, 596, 5359, 16, 514, 3009, 774, 9141, 13, 288, 3639, 1954, 1370, 12, 659, 5359, 16, 3009, 774, 9141, 1769, 3639, 8603, 4632, 3144, 1182, 273, 4...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 760, 918, 3144, 3899, 6323, 12, 780, 596, 5359, 16, 514, 3009, 774, 9141, 13, 288, 3639, 1954, 1370, 12, 659, 5359, 16, 3009, 774, 9141, 1769, 3639, 8603, 4632, 3144, 1182, 273, 4...
con = JDBC2Tests.openDB(); JDBC2Tests.dropTable(con, "poolingtest"); JDBC2Tests.closeDB(con);
con = TestUtil.openDB(); TestUtil.dropTable(con, "poolingtest"); TestUtil.closeDB(con);
protected void tearDown() throws Exception { con = JDBC2Tests.openDB(); JDBC2Tests.dropTable(con, "poolingtest"); JDBC2Tests.closeDB(con); }
45534 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/45534/d634a5903f615a45cb463155c04d3df904e1b91a/BaseDataSourceTest.java/buggy/src/interfaces/jdbc/org/postgresql/test/jdbc2/optional/BaseDataSourceTest.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 1117, 918, 268, 2091, 4164, 1435, 1216, 1185, 202, 95, 202, 202, 591, 273, 16364, 22, 14650, 18, 3190, 2290, 5621, 202, 202, 30499, 22, 14650, 18, 7285, 1388, 12, 591, 16, 315, 601...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 1117, 918, 268, 2091, 4164, 1435, 1216, 1185, 202, 95, 202, 202, 591, 273, 16364, 22, 14650, 18, 3190, 2290, 5621, 202, 202, 30499, 22, 14650, 18, 7285, 1388, 12, 591, 16, 315, 601...
public File getAbsoluteFile() { return new File(getAbsolutePath()); }
public File getAbsoluteFile () { return new File (getAbsolutePath()); }
public File getAbsoluteFile() { return new File(getAbsolutePath());}
45713 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/45713/af503bb72418d994f4439910bc3989d556fcdbd5/File.java/clean/libraries/javalib/java/io/File.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1071, 1387, 8469, 812, 1435, 288, 202, 2463, 394, 1387, 12, 588, 10368, 743, 10663, 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, ...
[ 1, 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, 0, 0, 0, 0...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1071, 1387, 8469, 812, 1435, 288, 202, 2463, 394, 1387, 12, 588, 10368, 743, 10663, 97, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, ...
if (fnCurrent != null && !codegen.itsUseDynamicScope && directParameterCount == -1)
if (fnCurrent != null && directParameterCount == -1 && (!codegen.itsUseDynamicScope || fnCurrent.getIgnoreDynamicScope()))
private void generatePrologue() { int directParameterCount = -1; if (inDirectCallFunction) { directParameterCount = scriptOrFn.getParamCount(); // 0 is reserved for function Object 'this' // 1 is reserved for context // 2 is reserved for parentScope // 3 is reserved for script 'this' short jReg = 4; for (int i = 0; i != directParameterCount; ++i) { OptLocalVariable lVar = fnCurrent.getVar(i); lVar.assignJRegister(jReg); jReg += 3; // 3 is 1 for Object parm and 2 for double parm } if (!fnCurrent.getParameterNumberContext()) { // make sure that all parameters are objects itsForcedObjectParameters = true; for (int i = 0; i != directParameterCount; ++i) { OptLocalVariable lVar = fnCurrent.getVar(i); cfw.addALoad(lVar.getJRegister()); cfw.add(ByteCode.GETSTATIC, "java/lang/Void", "TYPE", "Ljava/lang/Class;"); int isObjectLabel = cfw.acquireLabel(); cfw.add(ByteCode.IF_ACMPNE, isObjectLabel); cfw.add(ByteCode.NEW,"java/lang/Double"); cfw.add(ByteCode.DUP); cfw.addDLoad(lVar.getJRegister() + 1); addDoubleConstructor(); cfw.addAStore(lVar.getJRegister()); cfw.markLabel(isObjectLabel); } } } if (fnCurrent != null && !codegen.itsUseDynamicScope && directParameterCount == -1) { // Unless we're either using dynamic scope or we're in a // direct call, use the enclosing scope of the function as our // variable object. cfw.addALoad(funObjLocal); cfw.addInvoke(ByteCode.INVOKEINTERFACE, "org/mozilla/javascript/Scriptable", "getParentScope", "()Lorg/mozilla/javascript/Scriptable;"); cfw.addAStore(variableObjectLocal); } if (directParameterCount > 0) { for (int i = 0; i < (3 * directParameterCount); i++) reserveWordLocal(i + 4); // reserve 'args' } // reserve 'args[]' argsLocal = reserveWordLocal(directParameterCount <= 0 ? 4 : (3 * directParameterCount) + 4); // These locals are to be pre-allocated since they need function scope. // They are primarily used by the exception handling mechanism int localCount = scriptOrFn.getLocalCount(); if (localCount != 0) { itsLocalAllocationBase = (short)(argsLocal + 1); for (int i = 0; i < localCount; i++) { reserveWordLocal(itsLocalAllocationBase + i); } } if (fnCurrent == null) { // See comments in visitRegexp if (scriptOrFn.getRegexpCount() != 0) { scriptRegexpLocal = getNewWordLocal(); codegen.pushRegExpArray(cfw, scriptOrFn, contextLocal, variableObjectLocal); cfw.addAStore(scriptRegexpLocal); } } if (fnCurrent != null && fnCurrent.getCheckThis()) { // Nested functions must check their 'this' value to // insure it is not an activation object: // see 10.1.6 Activation Object cfw.addALoad(thisObjLocal); addScriptRuntimeInvoke("getThis", "(Lorg/mozilla/javascript/Scriptable;" +")Lorg/mozilla/javascript/Scriptable;"); cfw.addAStore(thisObjLocal); } if (hasVarsInRegs) { // No need to create activation. Pad arguments if need be. int parmCount = scriptOrFn.getParamCount(); if (parmCount > 0 && directParameterCount < 0) { // Set up args array // check length of arguments, pad if need be cfw.addALoad(argsLocal); cfw.add(ByteCode.ARRAYLENGTH); cfw.addPush(parmCount); int label = cfw.acquireLabel(); cfw.add(ByteCode.IF_ICMPGE, label); cfw.addALoad(argsLocal); cfw.addPush(parmCount); addScriptRuntimeInvoke("padArguments", "([Ljava/lang/Object;I" +")[Ljava/lang/Object;"); cfw.addAStore(argsLocal); cfw.markLabel(label); } // REMIND - only need to initialize the vars that don't get a value // before the next call and are used in the function short firstUndefVar = -1; for (int i = 0; i < fnCurrent.getVarCount(); i++) { OptLocalVariable lVar = fnCurrent.getVar(i); if (lVar.isNumber()) { lVar.assignJRegister(getNewWordPairLocal()); cfw.addPush(0.0); cfw.addDStore(lVar.getJRegister()); } else if (lVar.isParameter()) { if (directParameterCount < 0) { lVar.assignJRegister(getNewWordLocal()); cfw.addALoad(argsLocal); cfw.addPush(i); cfw.add(ByteCode.AALOAD); cfw.addAStore(lVar.getJRegister()); } } else { lVar.assignJRegister(getNewWordLocal()); if (firstUndefVar == -1) { Codegen.pushUndefined(cfw); firstUndefVar = lVar.getJRegister(); } else { cfw.addALoad(firstUndefVar); } cfw.addAStore(lVar.getJRegister()); } lVar.setStartPC(cfw.getCurrentCodeOffset()); } // Indicate that we should generate debug information for // the variable table. (If we're generating debug info at // all.) debugVars = fnCurrent.getVarsArray(); // Skip creating activation object. return; } if (directParameterCount > 0) { // We're going to create an activation object, so we // need to get an args array with all the arguments in it. cfw.addALoad(argsLocal); cfw.addPush(directParameterCount); addOptRuntimeInvoke("padStart", "([Ljava/lang/Object;I)[Ljava/lang/Object;"); cfw.addAStore(argsLocal); for (int i=0; i < directParameterCount; i++) { cfw.addALoad(argsLocal); cfw.addPush(i); // "3" is 1 for Object parm and 2 for double parm, and // "4" is to account for the context, etc. parms cfw.addALoad(3 * i + 4); cfw.add(ByteCode.AASTORE); } } String debugVariableName; if (fnCurrent != null) { cfw.addALoad(contextLocal); cfw.addALoad(variableObjectLocal); cfw.addALoad(funObjLocal); cfw.addALoad(thisObjLocal); cfw.addALoad(argsLocal); addScriptRuntimeInvoke("initVarObj", "(Lorg/mozilla/javascript/Context;" +"Lorg/mozilla/javascript/Scriptable;" +"Lorg/mozilla/javascript/NativeFunction;" +"Lorg/mozilla/javascript/Scriptable;" +"[Ljava/lang/Object;" +")Lorg/mozilla/javascript/Scriptable;"); debugVariableName = "activation"; } else { cfw.addALoad(contextLocal); cfw.addALoad(variableObjectLocal); cfw.addALoad(funObjLocal); cfw.addALoad(thisObjLocal); cfw.addPush(0); addScriptRuntimeInvoke("initScript", "(Lorg/mozilla/javascript/Context;" +"Lorg/mozilla/javascript/Scriptable;" +"Lorg/mozilla/javascript/NativeFunction;" +"Lorg/mozilla/javascript/Scriptable;" +"Z" +")Lorg/mozilla/javascript/Scriptable;"); debugVariableName = "global"; } cfw.addAStore(variableObjectLocal); int functionCount = scriptOrFn.getFunctionCount(); for (int i = 0; i != functionCount; i++) { OptFunctionNode fn = (OptFunctionNode)scriptOrFn.getFunctionNode(i); if (fn.getFunctionType() == FunctionNode.FUNCTION_STATEMENT) { visitFunction(fn, FunctionNode.FUNCTION_STATEMENT); } } // default is to generate debug info if (codegen.generateDebugInfo) { OptLocalVariable lv = new OptLocalVariable(debugVariableName, false); lv.assignJRegister(variableObjectLocal); lv.setStartPC(cfw.getCurrentCodeOffset()); debugVars = new OptLocalVariable[1]; debugVars[0] = lv; } if (fnCurrent == null) { // OPT: use dataflow to prove that this assignment is dead scriptResultLocal = getNewWordLocal(); Codegen.pushUndefined(cfw); cfw.addAStore(scriptResultLocal); int linenum = scriptOrFn.getEndLineno(); if (linenum != -1) cfw.addLineNumberEntry((short)linenum); } else { if (fnCurrent.itsContainsCalls0) { itsZeroArgArray = getNewWordLocal(); cfw.add(ByteCode.GETSTATIC, "org/mozilla/javascript/ScriptRuntime", "emptyArgs", "[Ljava/lang/Object;"); cfw.addAStore(itsZeroArgArray); } if (fnCurrent.itsContainsCalls1) { itsOneArgArray = getNewWordLocal(); cfw.addPush(1); cfw.add(ByteCode.ANEWARRAY, "java/lang/Object"); cfw.addAStore(itsOneArgArray); } } }
12904 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/12904/ce1bfbad95cdf018aee59e3604139c62130aaf53/Codegen.java/clean/js/rhino/src/org/mozilla/javascript/optimizer/Codegen.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 3238, 918, 2103, 626, 1330, 344, 1435, 565, 288, 3639, 509, 2657, 1662, 1380, 273, 300, 21, 31, 3639, 309, 261, 267, 5368, 1477, 2083, 13, 288, 5411, 2657, 1662, 1380, 273, 2728, 1162, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 2103, 626, 1330, 344, 1435, 565, 288, 3639, 509, 2657, 1662, 1380, 273, 300, 21, 31, 3639, 309, 261, 267, 5368, 1477, 2083, 13, 288, 5411, 2657, 1662, 1380, 273, 2728, 1162, ...
if (jj_3R_63()) return true;
if (jj_3R_68()) return true;
final private boolean jj_3R_72() { if (jj_scan_token(MINUS)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; if (jj_3R_63()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; }
9291 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/9291/983675edbbab0e381643fec9c2a3e765c2f88830/Parser.java/buggy/src/java/org/apache/velocity/runtime/parser/Parser.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 282, 727, 3238, 1250, 10684, 67, 23, 54, 67, 9060, 1435, 288, 565, 309, 261, 78, 78, 67, 9871, 67, 2316, 12, 6236, 3378, 3719, 327, 638, 31, 565, 309, 261, 78, 78, 67, 11821, 422, 374, 5...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 282, 727, 3238, 1250, 10684, 67, 23, 54, 67, 9060, 1435, 288, 565, 309, 261, 78, 78, 67, 9871, 67, 2316, 12, 6236, 3378, 3719, 327, 638, 31, 565, 309, 261, 78, 78, 67, 11821, 422, 374, 5...
String packageName = objectModel.getPackageName( false, null ) + ".io.xpp3";
String packageName; if ( isPackageWithVersion() ) { packageName = objectModel.getPackageName( true, getGeneratedVersion() ); } else { packageName = objectModel.getPackageName( false, null ); } packageName += ".io.xpp3";
private void generateXpp3Reader() throws ModelloException, IOException { Model objectModel = getModel(); String packageName = objectModel.getPackageName( false, null ) + ".io.xpp3"; String directory = packageName.replace( '.', '/' ); String unmarshallerName = getFileName( "Xpp3Reader" ); File f = new File( new File( getOutputDirectory(), directory ), unmarshallerName + ".java" ); if ( !f.getParentFile().exists() ) { f.getParentFile().mkdirs(); } FileWriter writer = new FileWriter( f ); JSourceWriter sourceWriter = new JSourceWriter( writer ); JClass jClass = new JClass( unmarshallerName ); jClass.setPackageName( packageName ); jClass.addImport( "org.xmlpull.v1.XmlPullParser" ); jClass.addImport( "org.xmlpull.v1.XmlPullParserException" ); jClass.addImport( "org.xmlpull.v1.XmlPullParserFactory" ); jClass.addImport( "java.io.Reader" ); jClass.addImport( "java.util.ArrayList" ); jClass.addImport( "java.util.List" ); addModelImports( jClass ); // Write the parse method which will do the unmarshalling. ModelClass root = objectModel.getClass( objectModel.getRoot( getGeneratedVersion() ), getGeneratedVersion() ); String rootElement = uncapitalise( root.getName() ); JMethod unmarshall = new JMethod( new JClass( root.getName() ), "read" ); unmarshall.addParameter( new JParameter( new JClass( "Reader" ), "reader" ) ); unmarshall.addException( new JClass( "Exception" ) ); JSourceCode sc = unmarshall.getSourceCode(); sc.add( root.getName() + " " + rootElement + " = new " + root.getName() + "();" ); sc.add( "XmlPullParserFactory factory = XmlPullParserFactory.newInstance();" ); sc.add( "XmlPullParser parser = factory.newPullParser();" ); sc.add( "parser.setInput( reader );" ); sc.add( "int eventType = parser.getEventType();" ); sc.add( "while ( eventType != XmlPullParser.END_DOCUMENT )" ); sc.add( "{" ); sc.indent(); writeClassParsing( root, sc, false, true ); sc.unindent(); sc.add( "}" ); sc.add( "return " + rootElement + ";" ); jClass.addMethod( unmarshall ); jClass.print( sourceWriter ); writer.flush(); writer.close(); }
47828 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/47828/32c2c8abf99a35ff6ed8b09667471e318e721611/Xpp3ReaderGenerator.java/clean/modello-plugins/modello-plugin-xpp3/src/main/java/org/codehaus/modello/plugin/xpp3/Xpp3ReaderGenerator.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 3238, 918, 2103, 60, 11858, 23, 2514, 1435, 3639, 1216, 3164, 383, 503, 16, 1860, 565, 288, 3639, 3164, 733, 1488, 273, 7454, 5621, 3639, 514, 9929, 31, 225, 309, 261, 353, 2261, 1190, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 2103, 60, 11858, 23, 2514, 1435, 3639, 1216, 3164, 383, 503, 16, 1860, 565, 288, 3639, 3164, 733, 1488, 273, 7454, 5621, 3639, 514, 9929, 31, 225, 309, 261, 353, 2261, 1190, ...
try { values0 = values1 = fields[zz].getFloats(false); }
try { if (fieldSamples[zz] == null) { fieldSamples[zz] = fields[zz].getFloats(false); } values0 = values1 = fieldSamples[zz]; }
public synchronized Data getData(int[] pos, int dim, DataCache cache) { if (dim != 3) { System.err.println(name + ": invalid dimensionality (" + dim + ")"); return null; } // get some info from the parent transform ImageTransform it = (ImageTransform) parent; int w = it.getImageWidth(); int h = it.getImageHeight(); int n = parent.getLengths()[axis]; RealType xType = it.getXType(); RealType yType = it.getYType(); RealType zType = it.getZType(); RealType[] range = it.getRangeTypes(); FunctionType imageType = it.getType(); Unit[] imageUnits = it.getImageUnits(); Unit zUnit = it.getZUnit(axis); Unit[] xyzUnits = {imageUnits[0], imageUnits[1], zUnit}; RealTupleType xy = null, xyz = null; try { xy = new RealTupleType(xType, yType); xyz = new RealTupleType(xType, yType, zType); } catch (VisADException exc) { exc.printStackTrace(); } // convert spherical polar coordinates to cartesian coordinates for line double yawRadians = Math.PI * yaw / 180; double yawCos = Math.cos(yawRadians); double yawSin = Math.sin(yawRadians); double pitchRadians = Math.PI * (90 - pitch) / 180; double pitchCos = Math.cos(pitchRadians); double pitchSin = Math.sin(pitchRadians); // Let P1 = (x, y, z), P2 = -P1 float x = (float) (RADIUS3 * pitchSin * yawCos); float y = (float) (RADIUS3 * pitchSin * yawSin); float z = (float) (RADIUS3 * pitchCos); // compute location along P1-P2 line float q = (loc - 50) / 50; float lx = q * x; float ly = q * y; float lz = q * z; // choose a point P which doesn't lie on the line through P1 and P2 float px = 1, py = 1, pz = 1; float ax = x < 0 ? -x : x; float ay = y < 0 ? -y : y; float az = z < 0 ? -z : z; if (ax - ay < 0.1) py = -1; if (ax - az < 0.1) pz = -1; // calculate the vector R as the cross product between P - P1 and P2 - P1 float pp1x = px - x, pp1y = py - y, pp1z = pz - z; float p2p1x = -x - x, p2p1y = -y - y, p2p1z = -z - z; float rz = pp1x * p2p1y - pp1y * p2p1x; float rx = pp1y * p2p1z - pp1z * p2p1y; float ry = pp1z * p2p1x - pp1x * p2p1z; // R is now perpendicular to P2 - P1 // calculate the vector S as the cross product between R and P2 - P1 float sz = rx * p2p1y - ry * p2p1x; float sx = ry * p2p1z - rz * p2p1y; float sy = rz * p2p1x - rx * p2p1z; // S is now perpendicular to both R and the P2 - P1 // normalize R and S float rlen = (float) Math.sqrt(rx * rx + ry * ry + rz * rz); rx /= rlen; ry /= rlen; rz /= rlen; float slen = (float) Math.sqrt(sx * sx + sy * sy + sz * sz); sx /= slen; sy /= slen; sz /= slen; // now R and S are an orthonormal basis for the plane Gridded3DSet line = null; if (showLine) { // convert x=[-1,1] y=[-1,1] z=[-1,1] to x=[0,w] y=[0,h] z=[0,n] float[][] lineSamples = { {w * (x + 1) / 2, w * (-x + 1) / 2}, {h * (y + 1) / 2, h * (-y + 1) / 2}, {n * (z + 1) / 2, n * (-z + 1) / 2} }; // construct line data object try { line = new Gridded3DSet(xyz, lineSamples, 2, null, xyzUnits, null, false); } catch (VisADException exc) { exc.printStackTrace(); } } // compute slice data Data slice = null; if (compute) { // interpolate from parent data // compute plane corners from orthonormal basis float q1x = w * (lx + T1COS * rx + T1SIN * sx + 1) / 2; float q1y = h * (ly + T1COS * ry + T1SIN * sy + 1) / 2; float q1z = n * (lz + T1COS * rz + T1SIN * sz + 1) / 2; float q2x = w * (lx + T2COS * rx + T2SIN * sx + 1) / 2; float q2y = h * (ly + T2COS * ry + T2SIN * sy + 1) / 2; float q2z = n * (lz + T2COS * rz + T2SIN * sz + 1) / 2; float q3x = w * (lx + T3COS * rx + T3SIN * sx + 1) / 2; float q3y = h * (ly + T3COS * ry + T3SIN * sy + 1) / 2; float q3z = n * (lz + T3COS * rz + T3SIN * sz + 1) / 2; float q4x = w * (lx + T4COS * rx + T4SIN * sx + 1) / 2; float q4y = h * (ly + T4COS * ry + T4SIN * sy + 1) / 2; float q4z = n * (lz + T4COS * rz + T4SIN * sz + 1) / 2; // retrieve parent data from data cache int[] npos = getParentPos(pos); FlatField[] fields = new FlatField[n]; for (int i=0; i<n; i++) { npos[axis] = i; Data data = parent.getData(npos, 2, cache); if (data == null || !(data instanceof FlatField)) { System.err.println(name + ": parent image plane #" + (i + 1) + " is not valid"); return null; } fields[i] = (FlatField) data; } try { // use image transform's recommended MathType and Units for (int i=0; i<n; i++) { fields[i] = DataUtil.switchType(fields[i], imageType, imageUnits); } } catch (VisADException exc) { exc.printStackTrace(); } catch (RemoteException exc) { exc.printStackTrace(); } // generate planar domain samples and corresponding interpolated values int res1 = res - 1; float[][] planeSamples = new float[3][res * res]; float[][] planeValues = new float[range.length][res * res]; for (int r=0; r<res; r++) { float rr = (float) r / res1; float xmin = (1 - rr) * q1x + rr * q3x; float ymin = (1 - rr) * q1y + rr * q3y; float zmin = (1 - rr) * q1z + rr * q3z; float xmax = (1 - rr) * q2x + rr * q4x; float ymax = (1 - rr) * q2y + rr * q4y; float zmax = (1 - rr) * q2z + rr * q4z; for (int c=0; c<res; c++) { float cc = (float) c / res1; int ndx = r * res + c; float xs = planeSamples[0][ndx] = (1 - cc) * xmin + cc * xmax; float ys = planeSamples[1][ndx] = (1 - cc) * ymin + cc * ymax; float zs = planeSamples[2][ndx] = (1 - cc) * zmin + cc * zmax; if (xs < 0 || ys < 0 || zs < 0 || xs > w - 1 || ys > h - 1 || zs > n - 1) { // this pixel is outside the range of the data (missing) for (int k=0; k<planeValues.length; k++) { planeValues[k][ndx] = Float.NaN; } } else { // interpolate the value of this pixel for each range component int xx = (int) xs, yy = (int) ys, zz = (int) zs; float wx = xs - xx, wy = ys - yy, wz = zs - zz; float[][] values0 = null, values1 = null; FlatField field0, field1; if (wz == 0) { // interpolate from a single field (z0 == z1) try { values0 = values1 = fields[zz].getFloats(false); } catch (VisADException exc) { exc.printStackTrace(); } } else { // interpolate between two fields try { values0 = fields[zz].getFloats(false); values1 = fields[zz + 1].getFloats(false); } catch (VisADException exc) { exc.printStackTrace(); } } int ndx00 = w * yy + xx; int ndx10 = w * yy + xx + 1; int ndx01 = w * (yy + 1) + xx; int ndx11 = w * (yy + 1) + xx + 1; for (int k=0; k<range.length; k++) { // tri-linear interpolation (x, then y, then z) float v000 = values0[k][ndx00]; float v100 = values0[k][ndx10]; float v010 = values0[k][ndx01]; float v110 = values0[k][ndx11]; float v001 = values1[k][ndx00]; float v101 = values1[k][ndx10]; float v011 = values1[k][ndx01]; float v111 = values1[k][ndx11]; float vx00 = (1 - wx) * v000 + wx * v100; float vx10 = (1 - wx) * v010 + wx * v110; float vx01 = (1 - wx) * v001 + wx * v101; float vx11 = (1 - wx) * v011 + wx * v111; float vxy0 = (1 - wy) * vx00 + wy * vx10; float vxy1 = (1 - wy) * vx01 + wy * vx11; float vxyz = (1 - wz) * vxy0 + wz * vxy1; planeValues[k][ndx] = vxyz; } } } } try { FunctionType planeType = new FunctionType(xyz, imageType.getRange()); Gridded3DSet planeSet = new Gridded3DSet(xyz, planeSamples, res, res, null, xyzUnits, null, false); FlatField ff = new FlatField(planeType, planeSet); ff.setSamples(planeValues, false); slice = ff; } catch (VisADException exc) { exc.printStackTrace(); } catch (RemoteException exc) { exc.printStackTrace(); } } else { // construct bounding circle // compute circle coordinates from orthonormal basis int num = 32; float[][] samples = new float[3][num]; for (int i=0; i<num; i++) { double theta = i * 2 * Math.PI / num; float tcos = (float) (RADIUS3 * Math.cos(theta)); float tsin = (float) (RADIUS3 * Math.sin(theta)); float qx = lx + tcos * rx + tsin * sx; float qy = ly + tcos * ry + tsin * sy; float qz = lz + tcos * rz + tsin * sz; int ndx = (i < num / 2) ? i : (3 * num / 2 - i - 1); samples[0][ndx] = w * (qx + 1) / 2; samples[1][ndx] = h * (qy + 1) / 2; samples[2][ndx] = n * (qz + 1) / 2; } // construct bounding circle data object try { slice = new Gridded3DSet(xyz, samples, num / 2, 2, null, xyzUnits, null, false); } catch (VisADException exc) { exc.printStackTrace(); } } Data[] data = showLine ? new Data[] {slice, line} : new Data[] {slice}; try { return new Tuple(data, false); } catch (VisADException exc) { exc.printStackTrace(); } catch (RemoteException exc) { exc.printStackTrace(); } return null; }
46826 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/46826/85dcfda5d52f780975ccee8d4c6d12de338cd3ad/ArbitrarySlice.java/buggy/loci/visbio/data/ArbitrarySlice.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 282, 1071, 3852, 1910, 4303, 12, 474, 8526, 949, 16, 509, 2464, 16, 1910, 1649, 1247, 13, 288, 565, 309, 261, 3509, 480, 890, 13, 288, 1377, 2332, 18, 370, 18, 8222, 12, 529, 397, 6398, 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, 282, 1071, 3852, 1910, 4303, 12, 474, 8526, 949, 16, 509, 2464, 16, 1910, 1649, 1247, 13, 288, 565, 309, 261, 3509, 480, 890, 13, 288, 1377, 2332, 18, 370, 18, 8222, 12, 529, 397, 6398, 20...
result.append("})");
result.append('}'); if (toplevel) { result.append(')'); }
protected String toSource(Context cx, Scriptable scope, Object[] args) throws JavaScriptException { StringBuffer result = new StringBuffer(256); result.append("({"); boolean toplevel, iterating; if (cx.iterating == null) { toplevel = true; iterating = false; cx.iterating = new ObjToIntMap(31); } else { toplevel = false; iterating = cx.iterating.has(this); } // Make sure cx.iterating is set to null when done // so we don't leak memory try { if (!iterating) { cx.iterating.intern(this); // stop recursion. Object[] ids = this.getIds(); for(int i=0; i < ids.length; i++) { if (i > 0) result.append(", "); Object id = ids[i]; result.append(id); result.append(':'); Object p = (id instanceof String) ? this.get((String) id, this) : this.get(((Integer) id).intValue(), this); result.append(ScriptRuntime.uneval(cx, scope, p)); } } } finally { if (toplevel) { cx.iterating = null; } } result.append("})"); return result.toString(); }
19042 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/19042/095aac131ad6a8eadb05131ed40d7c77d170fc49/ScriptableObject.java/clean/src/org/mozilla/javascript/ScriptableObject.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 4750, 514, 358, 1830, 12, 1042, 9494, 16, 22780, 2146, 16, 1033, 8526, 833, 13, 3639, 1216, 11905, 503, 565, 288, 3639, 6674, 563, 273, 394, 6674, 12, 5034, 1769, 3639, 563, 18, 6923, 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, 4750, 514, 358, 1830, 12, 1042, 9494, 16, 22780, 2146, 16, 1033, 8526, 833, 13, 3639, 1216, 11905, 503, 565, 288, 3639, 6674, 563, 273, 394, 6674, 12, 5034, 1769, 3639, 563, 18, 6923, 2...
MylarStatusHandler.fail(e, "Mylar: Bugzilla report element not known: " + e.getMessage().trim(), false); errorMessage = "Mylar: Bugzilla report element not known: " + e.getMessage().trim();
return;
public void endElement(String uri, String localName, String qName) throws SAXException { BugzillaReportElement tag = BugzillaReportElement.UNKNOWN; try { tag = BugzillaReportElement.valueOf(localName.trim().toUpperCase()); } catch (RuntimeException e) { if (e instanceof IllegalArgumentException) { MylarStatusHandler.fail(e, "Mylar: Bugzilla report element not known: " + e.getMessage().trim(), false); errorMessage = "Mylar: Bugzilla report element not known: " + e.getMessage().trim(); } return; } switch (tag) { case BUG_ID: { try { if (report.getId() != Integer.parseInt(characters.toString())) { errorMessage = "Requested report number does not match returned report number."; } } catch (NumberFormatException e) { errorMessage = "Bug id from server did not match requested id."; } AbstractRepositoryReportAttribute attr = report.getAttribute(tag); if (attr == null) { attr = new BugzillaReportAttribute(tag); report.addAttribute(tag, attr); } attr.setValue(characters.toString()); break; } // Comment attributes case WHO: case BUG_WHEN: case THETEXT: if (comment != null) { BugzillaReportAttribute attr = new BugzillaReportAttribute(tag); attr.setValue(characters.toString()); // System.err.println(">>> "+comment.getNumber()+" // "+characters.toString()); comment.addAttribute(tag, attr); } break; case LONG_DESC: if (comment != null) { report.addComment(comment); } break; // Attachment attributes case ATTACHID: case DATE: case DESC: case FILENAME: case CTYPE: case TYPE: if (attachment != null) { BugzillaReportAttribute attr = new BugzillaReportAttribute(tag); attr.setValue(characters.toString()); attachment.addAttribute(tag, attr); } break; case DATA: // TODO: Need to figure out under what circumstanceswhen attachments // are inline and // what to do with them. break; case ATTACHMENT: if (attachment != null) { report.addAttachment(attachment); } break; // IGNORED ELEMENTS case REPORTER_ACCESSIBLE: case CLASSIFICATION_ID: case CLASSIFICATION: case CCLIST_ACCESSIBLE: case EVERCONFIRMED: case BUGZILLA: break; case BUG: // Reached end of bug. Need to set LONGDESCLENGTH to number of // comments AbstractRepositoryReportAttribute numCommentsAttribute = report .getAttribute(BugzillaReportElement.LONGDESCLENGTH); if (numCommentsAttribute == null) { numCommentsAttribute = new BugzillaReportAttribute(BugzillaReportElement.LONGDESCLENGTH); numCommentsAttribute.setValue("" + report.getComments().size()); report.addAttribute(BugzillaReportElement.LONGDESCLENGTH, numCommentsAttribute); } else { numCommentsAttribute.setValue("" + report.getComments().size()); } break; // All others added as report attribute default: AbstractRepositoryReportAttribute attribute = report.getAttribute(tag); if (attribute == null) { // System.err.println(">>> Undeclared attribute added: " + // tag.toString()+" value: "+characters.toString()); attribute = new BugzillaReportAttribute(tag); attribute.setValue(characters.toString()); report.addAttribute(tag, attribute); } else { // System.err.println("Attr: " + attribute.getName() + " = " + // characters.toString()); attribute.addValue(characters.toString()); } break; } }
51151 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/51151/0510e51bff5fe263a82cbba10fa4a1525e88bf69/SaxBugReportContentHandler.java/clean/org.eclipse.mylyn.bugzilla.core/src/org/eclipse/mylyn/internal/bugzilla/core/internal/SaxBugReportContentHandler.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 918, 14840, 12, 780, 2003, 16, 514, 11927, 16, 514, 22914, 13, 1216, 14366, 288, 202, 202, 19865, 15990, 4820, 1046, 1047, 273, 16907, 15990, 4820, 1046, 18, 14737, 31, 202, 202...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 918, 14840, 12, 780, 2003, 16, 514, 11927, 16, 514, 22914, 13, 1216, 14366, 288, 202, 202, 19865, 15990, 4820, 1046, 1047, 273, 16907, 15990, 4820, 1046, 18, 14737, 31, 202, 202...
if (trace > 2)
if (verbose > 2)
public void run () throws VM_PragmaNoOptCompile, // refs stored in registers by opt compiler will not be relocated by GC VM_PragmaLogicallyUninterruptible, // due to call to snipObsoleteCompiledMethods VM_PragmaUninterruptible { for (int count = 0; ; count++) { // suspend this thread: it will resume when scheduled by VM_Handshake // initiateCollection(). while suspended, collector threads reside on // the schedulers collectorQueue // VM_Scheduler.collectorMutex.lock(); if (trace >= 1) { VM.sysWriteln("GC Message: VM_CT.run yielding"); VM_Interface.getPlan().show(); } if (count > 0) VM_Processor.getCurrentProcessor().enableThreadSwitching(); // resume normal scheduling VM_Thread.getCurrentThread().yield(VM_Scheduler.collectorQueue, VM_Scheduler.collectorMutex); // block mutators from running on the current processor VM_Processor.getCurrentProcessor().disableThreadSwitching(); if (trace >= 2) VM.sysWriteln("GC Message: VM_CT.run waking up"); gcOrdinal = VM_Synchronization.fetchAndAdd(participantCount, 0, 1) + 1; if (trace > 2) VM.sysWriteln("GC Message: VM_CT.run entering first rendezvous - gcOrdinal =", gcOrdinal); // the first RVM VP will wait for all the native VPs not blocked in native // to reach a SIGWAIT state // if( gcOrdinal == 1) { if (trace >= 2) VM.sysWriteln("GC Message: VM_CT.run quiescing native VPs"); for (int i = 1; i <= VM_Processor.numberNativeProcessors; i++) { if ( VM_Processor.vpStatus[VM_Processor.nativeProcessors[i].vpStatusIndex] != VM_Processor.BLOCKED_IN_NATIVE) { if (trace >= 2) VM.sysWriteln("GC Mesage: VM_CollectorThread.run found one not blocked in native"); while ( VM_Processor.vpStatus[VM_Processor.nativeProcessors[i].vpStatusIndex] != VM_Processor.IN_SIGWAIT) { if (trace >= 2) VM.sysWriteln("GC Message: VM_CT.run WAITING FOR NATIVE PROCESSOR", i, " with vpstatus = ", VM_Processor.vpStatus[VM_Processor.nativeProcessors[i].vpStatusIndex]); VM.sysVirtualProcessorYield(); } // Note: threads contextRegisters (ip & fp) are set by thread before // entering SIGWAIT, so nothing needs to be done here } else { // BLOCKED_IN_NATIVE - set context regs so that scan of threads stack // will start at the java to C transition frame. ip is not used for // these frames, so can be set to 0. // VM_Thread t = VM_Processor.nativeProcessors[i].activeThread; // t.contextRegisters.gprs[FRAME_POINTER] = t.jniEnv.JNITopJavaFP; t.contextRegisters.setInnermost( VM_Address.zero() /*ip*/, t.jniEnv.topJavaFP() ); } } // quiesce any attached processors, blocking then IN_NATIVE or IN_SIGWAIT // quiesceAttachedProcessors(); } // gcOrdinal==1 // wait for other collector threads to arrive or be made non-participants if (trace >= 2) VM.sysWriteln("GC Message: VM_CT.run initializing rendezvous"); gcBarrier.startupRendezvous(); if (trace >= 2) VM.sysWriteln("GC Message: VM_CT.run starting collection"); if (isActive) VM_Interface.getPlan().collect(); // gc if (trace >= 2) VM.sysWriteln("GC Message: VM_CT.run finished collection"); // wait for other collector threads to arrive here gcBarrier.rendezvous(5200); // Wake up mutators waiting for this gc cycle and create new collection // handshake object to be used for next gc cycle. // Note that mutators will not run until after thread switching is enabled, // so no mutators can possibly arrive at old handshake object: it's safe to // replace it with a new one. // if ( gcOrdinal == 1 ) { // Snip reference to any methods that are still marked obsolete after // we've done stack scans. This allows reclaiming them on next GC. VM_CompiledMethods.snipObsoleteCompiledMethods(); collectionCount += 1; // notify mutators waiting on previous handshake object - actually we // don't notify anymore, mutators are simply in processor ready queues // waiting to be dispatched. handshake.notifyCompletion(); handshake.reset(); // schedule the FinalizerThread, if there is work to do & it is idle VM_Interface.scheduleFinalizerThread(); } // wait for other collector threads to arrive here gcBarrier.rendezvous(5210); if (trace > 2) VM.sysWriteln("VM_CollectorThread: past rendezvous 1 after collection"); // final cleanup for initial collector thread if (gcOrdinal == 1) { // unblock any native processors executing in native that were blocked // in native at the start of GC // if (trace > 3) VM.sysWriteln("VM_CollectorThread: unblocking native procs"); for (int i = 1; i <= VM_Processor.numberNativeProcessors; i++) { VM_Processor vp = VM_Processor.nativeProcessors[i]; if (VM.VerifyAssertions) VM._assert(vp != null); if ( VM_Processor.vpStatus[vp.vpStatusIndex] == VM_Processor.BLOCKED_IN_NATIVE ) { VM_Processor.vpStatus[vp.vpStatusIndex] = VM_Processor.IN_NATIVE; if (trace >= 2) VM.sysWriteln("GC Message: VM_CT.run unblocking Native Processor", vp.id); } } // It is VERY unlikely, but possible that some RVM processors were // found in C, and were BLOCKED_IN_NATIVE, during the collection, and now // need to be unblocked. // if (trace >= 2) VM.sysWriteln("GC Message: VM_CT.run unblocking native procs blocked during GC"); for (int i = 1; i <= VM_Scheduler.numProcessors; i++) { VM_Processor vp = VM_Scheduler.processors[i]; if (VM.VerifyAssertions) VM._assert(vp != null); if ( VM_Processor.vpStatus[vp.vpStatusIndex] == VM_Processor.BLOCKED_IN_NATIVE ) { VM_Processor.vpStatus[vp.vpStatusIndex] = VM_Processor.IN_NATIVE; if (trace >= 2) VM.sysWriteln("GC Message: VM_CT.run unblocking RVM Processor", vp.id); } } if ( !VM.BuildForSingleVirtualProcessor ) { // if NativeDaemonProcessor was BLOCKED_IN_SIGWAIT, unblock it // VM_Processor ndvp = VM_Scheduler.processors[VM_Scheduler.nativeDPndx]; if ( ndvp!=null && VM_Processor.vpStatus[ndvp.vpStatusIndex] == VM_Processor.BLOCKED_IN_SIGWAIT ) { VM_Processor.vpStatus[ndvp.vpStatusIndex] = VM_Processor.IN_SIGWAIT; if (trace >= 2) VM.sysWriteln("GC Message: VM_CT.run unblocking Native Daemon Processor"); } // resume any attached Processors blocked prior to Collection // resumeAttachedProcessors(); } // clear the GC flag if (trace >= 2) VM.sysWriteln("GC Message: VM_CT.run clearing lock out field"); VM_Magic.setIntAtOffset(VM_BootRecord.the_boot_record, VM_Entrypoints.lockoutProcessorField.getOffset(), 0); } } // end of while(true) loop } // run
5245 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5245/9131b3297924bc92a03b492c09c47f1281a1d262/VM_CollectorThread.java/buggy/rvm/src/vm/memoryManagers/JMTk/vmInterface/VM_CollectorThread.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 565, 1071, 918, 1086, 1832, 4202, 1216, 8251, 67, 2050, 9454, 2279, 6179, 9937, 16, 368, 9047, 4041, 316, 10285, 635, 2153, 5274, 903, 486, 506, 283, 1829, 690, 635, 15085, 3196, 1377, 8251, 6...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 565, 1071, 918, 1086, 1832, 4202, 1216, 8251, 67, 2050, 9454, 2279, 6179, 9937, 16, 368, 9047, 4041, 316, 10285, 635, 2153, 5274, 903, 486, 506, 283, 1829, 690, 635, 15085, 3196, 1377, 8251, 6...
scopes = SLPUtil.parseScopes(scopeList);
scopes = SLPUtil.stringToVector(scopeList);
public void fromInputStream(SLPInputStream stream) throws ServiceLocationException { super.fromInputStream(stream); int scopeLen = 0; String scopeList = ""; int attrLen = 0; String attrList = ""; try { errorCode = stream.readShort(); // error timestamp = stream.readInt(); // timestamp int urlLen = stream.readShort(); // url length url = new ServiceURL(stream.readString(urlLen)); // url scopeLen = stream.readShort(); // scope list length scopeList = stream.readString(scopeLen); // scope list attrLen = stream.readShort(); // attr list length attrList = stream.readString(attrLen); // attr list. // SPI and Auth block are not implemented. // SPI is ignored. If an authentication block is included, // we can not handle the message, and throw an exception int len = stream.readShort(); stream.readString(len); // SPI list (ignored) len = stream.readByte(); for(int i=0; i<len; i++) { AuthBlock b = new AuthBlock(); b.fromInputStream(stream); authBlocks.add(b); } if(len != 0) { throw new ServiceLocationException(ServiceLocationException.AUTHENTICATION_FAILED); // does not support auth blocks } }catch(IOException ioe) { throw new ServiceLocationException(ServiceLocationException.PARSE_ERROR); } // create scope vector if(scopeLen != 0) { scopes = SLPUtil.parseScopes(scopeList); } // create attr. list if(attrLen != 0) { attributes = SLPUtil.parseAttributes(attrList); } }
4987 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/4987/62494642abc6a93b6938d8f940cf0aab6232c440/SLPDAAdvMessage.java/buggy/core/components/slp/src/org/smartfrog/services/comm/slp/messages/SLPDAAdvMessage.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 918, 628, 4348, 12, 4559, 52, 4348, 1407, 13, 1216, 1956, 2735, 503, 288, 3639, 2240, 18, 2080, 4348, 12, 3256, 1769, 3639, 509, 2146, 2891, 273, 374, 31, 3639, 514, 2146, 682, 27...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 628, 4348, 12, 4559, 52, 4348, 1407, 13, 1216, 1956, 2735, 503, 288, 3639, 2240, 18, 2080, 4348, 12, 3256, 1769, 3639, 509, 2146, 2891, 273, 374, 31, 3639, 514, 2146, 682, 27...
if (p.isSingleton()) { continue; }
public RubyArray ancestors() { RubyArray ary = getRuntime().newArray(); for (RubyModule p = this; p != null; p = p.getSuperClass()) { if (p.isSingleton()) { continue; } if (p.isIncluded()) { ary.append(((IncludedModuleWrapper) p).getDelegate()); } else { ary.append(p); } } return ary; }
50993 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50993/d166adca82dbf831b1e455c4d157b0033e10a6f1/RubyModule.java/clean/src/org/jruby/RubyModule.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 19817, 1076, 14322, 1435, 288, 3639, 19817, 1076, 11841, 273, 18814, 7675, 2704, 1076, 5621, 3639, 364, 261, 54, 10340, 3120, 293, 273, 333, 31, 293, 480, 446, 31, 293, 273, 293, 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, 19817, 1076, 14322, 1435, 288, 3639, 19817, 1076, 11841, 273, 18814, 7675, 2704, 1076, 5621, 3639, 364, 261, 54, 10340, 3120, 293, 273, 333, 31, 293, 480, 446, 31, 293, 273, 293, 18...
SwingUtilities.invokeLater(r);
invokeAndWait(r);
public void receivedStdErr(String s) { Runnable r = new UpdateStdErr(this, s); SwingUtilities.invokeLater(r); }
51310 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/51310/244dea79395ce64edcb9f803af5e0993085decce/GtpShell.java/buggy/src/gui/GtpShell.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 918, 5079, 10436, 2524, 12, 780, 272, 13, 565, 288, 3639, 10254, 436, 273, 394, 2315, 10436, 2524, 12, 2211, 16, 272, 1769, 3639, 4356, 1876, 5480, 12, 86, 1769, 565, 289, 2, 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, 1, 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, 918, 5079, 10436, 2524, 12, 780, 272, 13, 565, 288, 3639, 10254, 436, 273, 394, 2315, 10436, 2524, 12, 2211, 16, 272, 1769, 3639, 4356, 1876, 5480, 12, 86, 1769, 565, 289, 2, -100...
Vector recent = BufferHistory.getBufferHistory();
List recent = BufferHistory.getHistory();
private void construct() { Vector recent = BufferHistory.getBufferHistory(); JMenuItem item; File file; int max = recent.size(); int min = max - 20; if (max == 0) { item = new JMenuItem(jEdit.getProperty("MacOSPlugin.menu.recent.none")); item.setEnabled(false); add(item); return; } if (min < 0) min = 0; for (int i=max-1; i >= min ; i--) { file = new File(((BufferHistory.Entry)recent.get(i)).path); item = new ShowRecentMenuItem(file.getName(),file.getPath()); item.setIcon(FileCellRenderer.fileIcon); add(item); } } //}}}
8690 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/8690/d2bf676fd4cbad64f5fe5446a52a1474e8508c55/ShowRecentMenu.java/buggy/jars/MacOS/macos/menu/ShowRecentMenu.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 1152, 918, 4872, 1435, 202, 95, 202, 202, 5018, 8399, 273, 3525, 5623, 18, 588, 1892, 5623, 5621, 202, 202, 46, 12958, 761, 31, 202, 202, 812, 585, 31, 202, 202, 474, 943, 273, 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, 225, 202, 1152, 918, 4872, 1435, 202, 95, 202, 202, 5018, 8399, 273, 3525, 5623, 18, 588, 1892, 5623, 5621, 202, 202, 46, 12958, 761, 31, 202, 202, 812, 585, 31, 202, 202, 474, 943, 273, 8...
EMIT(MIR_Move.create(IA32_MOV, R(getEAX()), IC(-1))); EMIT(MIR_Multiply.create(IA32_MUL, R(getEDX()), R(getEAX()), R(lowlhsReg))); EMIT(MIR_Move.create(IA32_MOV, R(lowlhsReg), R(getEAX()))); EMIT(MIR_BinaryAcc.create(IA32_SUB, R(getEDX()), R(lhsReg))); EMIT(MIR_Move.create(IA32_MOV, R(lhsReg), R(getEDX())));
EMIT(MIR_Move.create(IA32_MOV, new OPT_RegisterOperand(getEAX(), VM_TypeReference.Int), IC(-1))); EMIT(MIR_Multiply.create(IA32_MUL, new OPT_RegisterOperand(getEDX(), VM_TypeReference.Int), new OPT_RegisterOperand(getEAX(), VM_TypeReference.Int), new OPT_RegisterOperand(lowlhsReg, VM_TypeReference.Int))); EMIT(MIR_Move.create(IA32_MOV, new OPT_RegisterOperand(lowlhsReg, VM_TypeReference.Int), new OPT_RegisterOperand(getEAX(), VM_TypeReference.Int))); EMIT(MIR_BinaryAcc.create(IA32_SUB, new OPT_RegisterOperand(getEDX(), VM_TypeReference.Int), new OPT_RegisterOperand(lhsReg, VM_TypeReference.Int))); EMIT(MIR_Move.create(IA32_MOV, new OPT_RegisterOperand(lhsReg, VM_TypeReference.Int), new OPT_RegisterOperand(getEDX(), VM_TypeReference.Int)));
protected final void LONG_MUL(OPT_Instruction s, OPT_RegisterOperand result, OPT_Operand value) { // In general, (a,b) * (c,d) = (l(a imul d)+l(b imul c)+u(b mul d), l(b mul d)) OPT_Register lhsReg = result.register; OPT_Register lowlhsReg = regpool.getSecondReg(lhsReg); if (value instanceof OPT_RegisterOperand) { OPT_Register rhsReg = ((OPT_RegisterOperand)value).register; OPT_Register lowrhsReg = regpool.getSecondReg(rhsReg); OPT_Register tmp = regpool.getInteger(); EMIT(MIR_BinaryAcc.create(IA32_IMUL2, R(lhsReg), R(lowrhsReg))); EMIT(MIR_Move.create(IA32_MOV, R(tmp), R(rhsReg))); EMIT(MIR_BinaryAcc.create(IA32_IMUL2, R(tmp), R(lowlhsReg))); EMIT(MIR_BinaryAcc.create(IA32_ADD, R(lhsReg), R(tmp))); EMIT(MIR_Move.create(IA32_MOV, R(getEAX()), R(lowlhsReg))); EMIT(MIR_Multiply.create(IA32_MUL, R(getEDX()), R(getEAX()), R(lowrhsReg))); EMIT(MIR_Move.create(IA32_MOV, R(lowlhsReg), R(getEAX()))); EMIT(MIR_BinaryAcc.create(IA32_ADD, R(lhsReg), R(getEDX()))); } else { OPT_LongConstantOperand rhs = (OPT_LongConstantOperand)value; int low = rhs.lower32(); int high = rhs.upper32(); // We only have to handle those cases that OPT_Simplifier wouldn't get. // OPT_Simplifier catches // high low // 0 0 (0L) // 0 1 (1L) // -1 -1 (-1L) // So, the possible cases we need to handle here: // -1 0 // -1 1 // -1 * // 0 -1 // 0 * // 1 -1 // 1 0 // 1 1 // 1 * // * -1 // * 0 // * 1 // * * // (where * is something other than -1,0,1) if (high == -1) { if (low == 0) { // -1, 0 // CLAIM: (x,y) * (-1,0) = (-y,0) EMIT(MIR_Move.create(IA32_MOV, R(lhsReg), R(lowlhsReg))); EMIT(MIR_UnaryAcc.create(IA32_NEG, R(lhsReg))); EMIT(MIR_Move.create(IA32_MOV, R(lowlhsReg), IC(0))); } else if (low == 1) { // -1, 1 // CLAIM: (x,y) * (-1,1) = (x-y,y) EMIT(MIR_BinaryAcc.create(IA32_SUB, R(lhsReg), R(lowlhsReg))); } else { // -1, * // CLAIM: (x,y) * (-1, z) = (l(x imul z)-y+u(y mul z)+, l(y mul z)) EMIT(MIR_BinaryAcc.create(IA32_IMUL2, R(lhsReg), IC(low))); EMIT(MIR_BinaryAcc.create(IA32_SUB, R(lhsReg), R(lowlhsReg))); EMIT(MIR_Move.create(IA32_MOV, R(getEAX()), IC(low))); EMIT(MIR_Multiply.create(IA32_MUL, R(getEDX()), R(getEAX()), R(lowlhsReg))); EMIT(MIR_Move.create(IA32_MOV, R(lowlhsReg), R(getEAX()))); EMIT(MIR_BinaryAcc.create(IA32_ADD, R(lhsReg), R(getEDX()))); } } else if (high == 0) { if (low == -1) { // 0, -1 // CLAIM: (x,y) * (0,-1) = (u(y mul -1)-x, l(y mul -1)) EMIT(MIR_Move.create(IA32_MOV, R(getEAX()), IC(-1))); EMIT(MIR_Multiply.create(IA32_MUL, R(getEDX()), R(getEAX()), R(lowlhsReg))); EMIT(MIR_Move.create(IA32_MOV, R(lowlhsReg), R(getEAX()))); EMIT(MIR_BinaryAcc.create(IA32_SUB, R(getEDX()), R(lhsReg))); EMIT(MIR_Move.create(IA32_MOV, R(lhsReg), R(getEDX()))); } else { // 0, * // CLAIM: (x,y) * (0,z) = (l(x imul z)+u(y mul z), l(y mul z)) EMIT(MIR_BinaryAcc.create(IA32_IMUL2, R(lhsReg), IC(low))); EMIT(MIR_Move.create(IA32_MOV, R(getEAX()), IC(low))); EMIT(MIR_Multiply.create(IA32_MUL, R(getEDX()), R(getEAX()), R(lowlhsReg))); EMIT(MIR_Move.create(IA32_MOV, R(lowlhsReg), R(getEAX()))); EMIT(MIR_BinaryAcc.create(IA32_ADD, R(lhsReg), R(getEDX()))); } } else if (high == 1) { if (low == -1) { // 1, -1 // CLAIM: (x,y) * (1,-1) = (-x+y+u(y mul -1), l(y mul -1)) EMIT(MIR_UnaryAcc.create(IA32_NEG, R(lhsReg))); EMIT(MIR_BinaryAcc.create(IA32_ADD, R(lhsReg), R(lowlhsReg))); EMIT(MIR_Move.create(IA32_MOV, R(getEAX()), IC(-1))); EMIT(MIR_Multiply.create(IA32_MUL, R(getEDX()), R(getEAX()), R(lowlhsReg))); EMIT(MIR_Move.create(IA32_MOV, R(lowlhsReg), R(getEAX()))); EMIT(MIR_BinaryAcc.create(IA32_ADD, R(lhsReg), R(getEDX()))); } else if (low == 0) { // 1, 0 // CLAIM: (x,y) * (1,0) = (y,0) EMIT(MIR_Move.create(IA32_MOV, R(lhsReg), R(lowlhsReg))); EMIT(MIR_Move.create(IA32_MOV, R(lowlhsReg), IC(0))); } else if (low == 1) { // 1, 1 // CLAIM: (x,y) * (1,1) = (x+y,y) EMIT(MIR_BinaryAcc.create(IA32_ADD, R(lhsReg), R(lowlhsReg))); } else { // 1, * // CLAIM: (x,y) * (1,z) = (l(x imul z)+y+u(y mul z), l(y mul z)) EMIT(MIR_BinaryAcc.create(IA32_IMUL2, R(lhsReg), IC(low))); EMIT(MIR_BinaryAcc.create(IA32_ADD, R(lhsReg), R(lowlhsReg))); EMIT(MIR_Move.create(IA32_MOV, R(getEAX()), IC(low))); EMIT(MIR_Multiply.create(IA32_MUL, R(getEDX()), R(getEAX()), R(lowlhsReg))); EMIT(MIR_Move.create(IA32_MOV, R(lowlhsReg), R(getEAX()))); EMIT(MIR_BinaryAcc.create(IA32_ADD, R(lhsReg), R(getEDX()))); } } else { if (low == -1) { // *, -1 // CLAIM: (x,y) * (z,-1) = (-x+l(y imul z)+u(y mul -1), l(y mul -1)) OPT_Register tmp = regpool.getInteger(); EMIT(MIR_UnaryAcc.create(IA32_NEG, R(lhsReg))); EMIT(MIR_Move.create(IA32_MOV, R(tmp), IC(high))); EMIT(MIR_BinaryAcc.create(IA32_IMUL2, R(tmp), R(lowlhsReg))); EMIT(MIR_BinaryAcc.create(IA32_ADD, R(lhsReg), R(tmp))); EMIT(MIR_Move.create(IA32_MOV, R(getEAX()), IC(low))); EMIT(MIR_Multiply.create(IA32_MUL, R(getEDX()), R(getEAX()), R(lowlhsReg))); EMIT(MIR_Move.create(IA32_MOV, R(lowlhsReg), R(getEAX()))); EMIT(MIR_BinaryAcc.create(IA32_ADD, R(lhsReg), R(getEDX()))); } else if (low == 0) { // *, 0 // CLAIM: (x,y) * (z,0) = (l(y imul z),0) EMIT(MIR_Move.create(IA32_MOV, R(lhsReg), IC(high))); EMIT(MIR_BinaryAcc.create(IA32_IMUL2, R(lhsReg), R(lowlhsReg))); EMIT(MIR_Move.create(IA32_MOV, R(lowlhsReg), IC(0))); } else if (low == 1) { // *, 1 // CLAIM: (x,y) * (z,1) = (l(y imul z)+x,y) OPT_Register tmp = regpool.getInteger(); EMIT(MIR_Move.create(IA32_MOV, R(tmp), R(lowlhsReg))); EMIT(MIR_BinaryAcc.create(IA32_IMUL2, R(tmp), IC(high))); EMIT(MIR_Move.create(IA32_ADD, R(lhsReg), R(tmp))); } else { // *, * (sigh, can't do anything interesting...) OPT_Register tmp = regpool.getInteger(); EMIT(MIR_BinaryAcc.create(IA32_IMUL2, R(lhsReg), IC(low))); EMIT(MIR_Move.create(IA32_MOV, R(tmp), IC(high))); EMIT(MIR_BinaryAcc.create(IA32_IMUL2, R(tmp), R(lowlhsReg))); EMIT(MIR_BinaryAcc.create(IA32_ADD, R(lhsReg), R(tmp))); EMIT(MIR_Move.create(IA32_MOV, R(getEAX()), IC(low))); EMIT(MIR_Multiply.create(IA32_MUL, R(getEDX()), R(getEAX()), R(lowlhsReg))); EMIT(MIR_Move.create(IA32_MOV, R(lowlhsReg), R(getEAX()))); EMIT(MIR_BinaryAcc.create(IA32_ADD, R(lhsReg), R(getEDX()))); } } } }
4011 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/4011/2c9d33f59b8f04d9f845caaa59a98fd196ed0f01/OPT_BURS_Helpers.java/clean/rvm/src/vm/arch/intel/compilers/optimizing/ir/conversions/lir2mir/OPT_BURS_Helpers.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 282, 4750, 727, 918, 14011, 67, 49, 1506, 12, 15620, 67, 11983, 272, 16, 27573, 16456, 67, 3996, 10265, 563, 16, 27573, 16456, 67, 10265, 460, 13, 288, 565, 368, 657, 7470, 16, 261, 69, 16, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 282, 4750, 727, 918, 14011, 67, 49, 1506, 12, 15620, 67, 11983, 272, 16, 27573, 16456, 67, 3996, 10265, 563, 16, 27573, 16456, 67, 10265, 460, 13, 288, 565, 368, 657, 7470, 16, 261, 69, 16, ...
Map attributeValuesByName = new HashMap(); attributeValuesByName.put(ATTRIBUTE_ENABLED, getMethodToExecute() == null ? Boolean.FALSE : Boolean.TRUE); attributeValuesByName.put(ATTRIBUTE_ID, null); return Collections.unmodifiableMap(attributeValuesByName); }
Map attributeValuesByName = new HashMap(); attributeValuesByName.put(ATTRIBUTE_ENABLED, getMethodToExecute() == null ? Boolean.FALSE : Boolean.TRUE); attributeValuesByName.put(ATTRIBUTE_ID, null); return Collections.unmodifiableMap(attributeValuesByName); }
public Map getAttributeValuesByName() { Map attributeValuesByName = new HashMap(); attributeValuesByName.put(ATTRIBUTE_ENABLED, getMethodToExecute() == null ? Boolean.FALSE : Boolean.TRUE); attributeValuesByName.put(ATTRIBUTE_ID, null); return Collections.unmodifiableMap(attributeValuesByName); }
58148 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/58148/8bf8b0f1adf992af9b8f2f2a573cdf0fa4225bc9/WidgetMethodHandler.java/buggy/bundles/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal/commands/ws/WidgetMethodHandler.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 1635, 4061, 1972, 5911, 1435, 288, 3639, 1635, 1566, 1972, 5911, 273, 394, 4317, 5621, 3639, 1566, 1972, 5911, 18, 458, 12, 11616, 67, 13560, 16, 7734, 6272, 774, 5289, 1435, 422, 4...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 1635, 4061, 1972, 5911, 1435, 288, 3639, 1635, 1566, 1972, 5911, 273, 394, 4317, 5621, 3639, 1566, 1972, 5911, 18, 458, 12, 11616, 67, 13560, 16, 7734, 6272, 774, 5289, 1435, 422, 4...
public void testAssertRetractNoloop() { try { //read in the source final Reader reader = new InputStreamReader( getClass().getResourceAsStream( "test_Assert_Retract_Noloop.drl" ) ); final DrlParser parser = new DrlParser(); final PackageDescr packageDescr = parser.parse( reader ); //pre build the package final PackageBuilder builder = new PackageBuilder(); builder.addPackage( packageDescr ); final Package pkg = builder.getPackage(); //add the package to a rulebase final RuleBase ruleBase = getRuleBase(); ruleBase.addPackage( pkg ); //load up the rulebase final WorkingMemory wm = ruleBase.newWorkingMemory(); wm.assertObject( new Cheese("stilton", 15) ); wm.fireAllRules(); } catch ( Exception e ) { e.printStackTrace(); fail("test should not throw exception"); } }
5490 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5490/8bf342687afa7ece5d554db21146984eff9076c8/IntegrationCases.java/clean/drools-compiler/src/test/java/org/drools/integrationtests/IntegrationCases.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 918, 1842, 8213, 7055, 14266, 50, 12854, 556, 1435, 288, 3639, 775, 288, 5411, 368, 896, 316, 326, 1084, 5411, 727, 5393, 2949, 273, 394, 15322, 12, 2900, 7675, 588, 1420, 17052, 12...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 918, 1842, 8213, 7055, 14266, 50, 12854, 556, 1435, 288, 3639, 775, 288, 5411, 368, 896, 316, 326, 1084, 5411, 727, 5393, 2949, 273, 394, 15322, 12, 2900, 7675, 588, 1420, 17052, 12...
compmiddle.setBackground(bg);
props.setLook(compmiddle);
public void createControl(Composite parent) { shell = parent.getShell(); int margin = Const.MARGIN; // create the composite to hold the widgets Composite composite = new Composite(parent, SWT.NONE); composite.setBackground(bg); composite.setFont(font); FormLayout compLayout = new FormLayout(); compLayout.marginHeight = Const.FORM_MARGIN; compLayout.marginWidth = Const.FORM_MARGIN; composite.setLayout(compLayout); // Put it all on the composite! //////////////////////////////////////////////////// // Top & Bottom regions. //////////////////////////////////////////////////// Composite top = new Composite(composite, SWT.NONE); FormLayout topLayout = new FormLayout(); topLayout.marginHeight = margin; topLayout.marginWidth = margin; top.setLayout(topLayout); FormData fdTop = new FormData(); fdTop.left = new FormAttachment(0, 0); fdTop.top = new FormAttachment(0, 0); fdTop.right = new FormAttachment(100, 0); fdTop.bottom = new FormAttachment(100, -50); top.setLayoutData(fdTop); top.setBackground(bg); Composite bottom = new Composite(composite, SWT.NONE); bottom.setLayout(new FormLayout()); FormData fdBottom = new FormData(); fdBottom.left = new FormAttachment(0, 0); fdBottom.top = new FormAttachment(top, 0); fdBottom.right = new FormAttachment(100, 0); fdBottom.bottom = new FormAttachment(100, 0); bottom.setLayoutData(fdBottom); bottom.setBackground(bg); //////////////////////////////////////////////////// // Sashform //////////////////////////////////////////////////// SashForm sashform = new SashForm(top, SWT.HORIZONTAL); sashform.setLayout(new FormLayout()); FormData fdSashform = new FormData(); fdSashform.left = new FormAttachment(0, 0); fdSashform.top = new FormAttachment(0, 0); fdSashform.right = new FormAttachment(100, 0); fdSashform.bottom = new FormAttachment(100, 0); sashform.setLayoutData(fdSashform); ////////////////////////// /// LEFT ////////////////////////// Composite leftsplit = new Composite(sashform, SWT.NONE); leftsplit.setLayout(new FormLayout()); FormData fdLeftsplit = new FormData(); fdLeftsplit.left = new FormAttachment(0, 0); fdLeftsplit.top = new FormAttachment(0, 0); fdLeftsplit.right = new FormAttachment(100, 0); fdLeftsplit.bottom = new FormAttachment(100, 0); leftsplit.setLayoutData(fdLeftsplit); leftsplit.setBackground(bg); // Source list to the left... wlListSource = new Label(leftsplit, SWT.NONE); wlListSource.setText("Available items:"); wlListSource.setBackground(bg); wlListSource.setFont(font); FormData fdlListSource = new FormData(); fdlListSource.left = new FormAttachment(0, 0); fdlListSource.top = new FormAttachment(0, 0); wlListSource.setLayoutData(fdlListSource); wListSource = new List(leftsplit, SWT.BORDER | SWT.MULTI | SWT.V_SCROLL | SWT.H_SCROLL); wListSource.setBackground(bg); wListSource.setFont(font); FormData fdListSource = new FormData(); fdListSource.left = new FormAttachment(0, 0); fdListSource.top = new FormAttachment(wlListSource, 0); fdListSource.right = new FormAttachment(100, 0); fdListSource.bottom = new FormAttachment(100, 0); wListSource.setLayoutData(fdListSource); /////////////////////////// // MIDDLE /////////////////////////// Composite compmiddle = new Composite(sashform, SWT.NONE); compmiddle.setLayout (new FormLayout()); FormData fdCompMiddle = new FormData(); fdCompMiddle.left = new FormAttachment(0, 0); fdCompMiddle.top = new FormAttachment(0, 0); fdCompMiddle.right = new FormAttachment(100, 0); fdCompMiddle.bottom = new FormAttachment(100, 0); compmiddle.setLayoutData(fdCompMiddle); compmiddle.setBackground(bg); wAddOne = new Button(compmiddle, SWT.PUSH); wAddOne .setText(" > "); wAddOne .setToolTipText("Add the selected items on the left."); wAddAll = new Button(compmiddle, SWT.PUSH); wAddAll .setText(" >> "); wAddAll .setToolTipText("Add all items on the left."); wRemoveOne = new Button(compmiddle, SWT.PUSH); wRemoveOne.setText(" < "); wRemoveOne.setToolTipText("Remove the selected items on the right."); wRemoveAll = new Button(compmiddle, SWT.PUSH); wRemoveAll.setText(" << "); wRemoveAll.setToolTipText("Add all items on the right."); FormData fdAddOne = new FormData(); fdAddOne.left = new FormAttachment(compmiddle, 0, SWT.CENTER); fdAddOne.top = new FormAttachment(30, 0); wAddOne.setLayoutData(fdAddOne); FormData fdAddAll = new FormData(); fdAddAll.left = new FormAttachment(compmiddle, 0, SWT.CENTER); fdAddAll.top = new FormAttachment(wAddOne, margin); wAddAll.setLayoutData(fdAddAll); FormData fdRemoveAll = new FormData(); fdRemoveAll.left = new FormAttachment(compmiddle, 0, SWT.CENTER); fdRemoveAll.top = new FormAttachment(wAddAll, margin); wRemoveAll.setLayoutData(fdRemoveAll); FormData fdRemoveOne = new FormData(); fdRemoveOne.left = new FormAttachment(compmiddle, 0, SWT.CENTER); fdRemoveOne.top = new FormAttachment(wRemoveAll, margin); wRemoveOne.setLayoutData(fdRemoveOne); ///////////////////////////////// // RIGHT ///////////////////////////////// Composite rightsplit = new Composite(sashform, SWT.NONE); rightsplit.setLayout(new FormLayout()); FormData fdRightsplit = new FormData(); fdRightsplit .left = new FormAttachment(0, 0); fdRightsplit .top = new FormAttachment(0, 0); fdRightsplit .right = new FormAttachment(100, 0); fdRightsplit .bottom = new FormAttachment(100, 0); rightsplit.setLayoutData(fdRightsplit ); rightsplit.setBackground(bg); wlListDest = new Label(rightsplit, SWT.NONE); wlListDest.setText("Your selection:"); wlListDest.setBackground(bg); wlListDest.setFont(font); FormData fdlListDest = new FormData(); fdlListDest.left = new FormAttachment(0, 0); fdlListDest.top = new FormAttachment(0, 0); wlListDest.setLayoutData(fdlListDest); wListDest = new List(rightsplit, SWT.BORDER | SWT.MULTI | SWT.V_SCROLL | SWT.H_SCROLL); wListDest.setBackground(bg); wListDest.setFont(font); FormData fdListDest = new FormData(); fdListDest .left = new FormAttachment(0, 0); fdListDest .top = new FormAttachment(wlListDest, 0); fdListDest .right = new FormAttachment(100, 0); fdListDest .bottom = new FormAttachment(100, 0); wListDest.setLayoutData(fdListDest ); sashform.setWeights(new int[] { 46, 8, 46 }); // Clean up used resources! composite.addDisposeListener(new DisposeListener() { public void widgetDisposed(DisposeEvent arg0) { bg.dispose(); font.dispose(); } } ); // Drag & Drop for steps Transfer[] ttypes = new Transfer[] {TextTransfer.getInstance() }; DragSource ddSource = new DragSource(wListSource, DND.DROP_MOVE | DND.DROP_COPY); ddSource.setTransfer(ttypes); ddSource.addDragListener(new DragSourceListener() { public void dragStart(DragSourceEvent event){ } public void dragSetData(DragSourceEvent event) { String ti[] = wListSource.getSelection(); String data = new String(); for (int i=0;i<ti.length;i++) data+=ti[i]+Const.CR; event.data = data; } public void dragFinished(DragSourceEvent event) {} } ); DropTarget ddTarget = new DropTarget(wListDest, DND.DROP_MOVE | DND.DROP_COPY); ddTarget.setTransfer(ttypes); ddTarget.addDropListener(new DropTargetListener() { public void dragEnter(DropTargetEvent event) { } public void dragLeave(DropTargetEvent event) { } public void dragOperationChanged(DropTargetEvent event) { } public void dragOver(DropTargetEvent event) { } public void drop(DropTargetEvent event) { if (event.data == null) { // no data to copy, indicate failure in event.detail event.detail = DND.DROP_NONE; return; } StringTokenizer strtok = new StringTokenizer((String)event.data, Const.CR); while (strtok.hasMoreTokens()) { String source = strtok.nextToken(); addToDestination(source); } } public void dropAccept(DropTargetEvent event) { } }); wListSource.addKeyListener(new KeyAdapter() { public void keyPressed(KeyEvent e) { if (e.character==SWT.CR) { addToSelection(wListSource.getSelection()); } } }); wListDest.addKeyListener(new KeyAdapter() { public void keyPressed(KeyEvent e) { if (e.character==SWT.CR) { delFromSelection(wListDest.getSelection()); } } }); // Double click adds to destination. wListSource.addSelectionListener(new SelectionAdapter() { public void widgetDefaultSelected(SelectionEvent e) { addToSelection(wListSource.getSelection()); } } ); // Double click adds to source wListDest.addSelectionListener(new SelectionAdapter() { public void widgetDefaultSelected(SelectionEvent e) { String sel[] = wListDest.getSelection(); delFromSelection(sel); } } ); wAddOne.addSelectionListener(new SelectionAdapter() { public void widgetSelected(SelectionEvent e) { addToSelection(wListSource.getSelection()); } } ); wRemoveOne.addSelectionListener(new SelectionAdapter() { public void widgetSelected(SelectionEvent e) { delFromSelection(wListDest.getSelection()); } } ); wAddAll.addSelectionListener(new SelectionAdapter() { public void widgetSelected(SelectionEvent e) { addAllToSelection(); } } ); wRemoveAll.addSelectionListener(new SelectionAdapter() { public void widgetSelected(SelectionEvent e) { removeAllFromSelection(); } } ); // set the composite as the control for this page setControl(composite); }
9547 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/9547/efd7d5821936bcc76d201024a2967f697e0c0d4b/RipDatabaseWizardPage2.java/buggy/src/be/ibridge/kettle/chef/wizards/RipDatabaseWizardPage2.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 918, 752, 3367, 12, 9400, 982, 13, 202, 95, 202, 202, 10304, 282, 273, 982, 18, 588, 13220, 5621, 202, 202, 474, 7333, 225, 273, 9333, 18, 19772, 7702, 31, 25083, 202, 759, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 918, 752, 3367, 12, 9400, 982, 13, 202, 95, 202, 202, 10304, 282, 273, 982, 18, 588, 13220, 5621, 202, 202, 474, 7333, 225, 273, 9333, 18, 19772, 7702, 31, 25083, 202, 759, ...
private boolean compareTypes(Type parmType, Type argType) { // XXX equality not implemented for GenericObjectType // if (parmType.equals(argType)) return true; // Compare type signatures instead String parmString = GenericUtilities.getString(parmType); String argString = GenericUtilities.getString(argType); if (parmString.equals(argString)) return true; // if either type is java.lang.Object, then automatically true! // again compare strings... String objString = GenericUtilities.getString(Type.OBJECT); if ( parmString.equals(objString) || argString.equals(objString) ) { return true; } // get a category for each type TypeCategory parmCat = GenericUtilities.getTypeCategory(parmType); TypeCategory argCat = GenericUtilities.getTypeCategory(argType); // -~- plain objects are easy if ( parmCat == TypeCategory.PLAIN_OBJECT_TYPE && argCat == TypeCategory.PLAIN_OBJECT_TYPE ) { try { String parmName = ((ObjectType)parmType).getClassName(); String argName = ((ObjectType)argType) .getClassName(); // e.g. List<String>.contains(CharSequence) if (Repository.instanceOf(parmName, argName)) return true; // e.g. List<CharSequence>.contains(String) return Repository.instanceOf(argName, parmName); } catch (ClassNotFoundException e) { return true; } } // -~- parmType is: "? extends Another Type" OR "? super Another Type" if ( parmCat == TypeCategory.WILDCARD_EXTENDS || parmCat == TypeCategory.WILDCARD_SUPER ) { return compareTypes( ((GenericObjectType)parmType).getExtension(), argType); } // -~- Not handling type variables if ( parmCat == TypeCategory.TYPE_VARIABLE || argCat == TypeCategory.TYPE_VARIABLE ) { return true; } // -~- Array Types: compare dimensions, then base type if ( parmCat == TypeCategory.ARRAY_TYPE && argCat == TypeCategory.ARRAY_TYPE ) { ArrayType parmArray = (ArrayType) parmType; ArrayType argArray = (ArrayType) argType; if (parmArray.getDimensions() != argArray.getDimensions()) return false; return compareTypes(parmArray.getBasicType(), argArray.getBasicType()); } // If one is an Array Type and the other is not, then they // are incompatible. (We already know neither is java.lang.Object) if ( parmCat == TypeCategory.ARRAY_TYPE ^ argCat == TypeCategory.ARRAY_TYPE ) { return false; } // -~- Parameter Types: compare base type then parameters if ( parmCat == TypeCategory.PARAMETERS && argCat == TypeCategory.PARAMETERS ) { GenericObjectType parmGeneric = (GenericObjectType) parmType; GenericObjectType argGeneric = (GenericObjectType) argType; // base types should be related if (!compareTypes( parmGeneric.getObjectType(), argGeneric.getObjectType()) ) return false; // XXX More to come } // If one is a Parameter Type and the other is not, then they // are incompatible. (We already know neither is java.lang.Object) if (false) { // not true. Consider class Foo extends ArrayList<String> if ( parmCat == TypeCategory.PARAMETERS ^ argCat == TypeCategory.PARAMETERS ) { return false; } } // -~- Wildcard e.g. List<*>.contains(...) if (parmCat == TypeCategory.WILDCARD) // No Way to know return true; // -~- Non Reference types // if ( parmCat == TypeCategory.NON_REFERENCE_TYPE || // argCat == TypeCategory.NON_REFERENCE_TYPE ) if (parmType instanceof BasicType || argType instanceof BasicType) { // this should not be possible, compiler will complain (pre 1.5) // or autobox primitive types (1.5 +) assert false; } return true; }
7352 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/7352/891e9bc8fa77cc43dba5928346909538565376e4/FindUnrelatedTypesInGenericContainer.java/clean/findbugs/src/java/edu/umd/cs/findbugs/detect/FindUnrelatedTypesInGenericContainer.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 1152, 1250, 3400, 2016, 12, 559, 19924, 559, 16, 1412, 1501, 559, 13, 288, 202, 202, 759, 11329, 14958, 486, 8249, 364, 7928, 17610, 202, 202, 759, 309, 261, 1065, 81, 559, 18, 149...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 1152, 1250, 3400, 2016, 12, 559, 19924, 559, 16, 1412, 1501, 559, 13, 288, 202, 202, 759, 11329, 14958, 486, 8249, 364, 7928, 17610, 202, 202, 759, 309, 261, 1065, 81, 559, 18, 149...
}
}
public String verifySqlText(String str ) { StringBuffer buf = new StringBuffer(str) ; // log("Innan: " + str) ; char apostrof = '\'' ; for(int i = 0 ; i < buf.length() ; i++) { //log(""+ buf.charAt(i)) ; if (buf.charAt(i) == apostrof ) { buf.insert(i,apostrof) ; i+=1 ; } } str = buf.toString() ; // log("Efter: " + str) ; return str ; } // End CreateAdminHtml
8781 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/8781/a270627916b37a677a391dd9f45c54d3d6f12503/Conference.java/clean/servlets/conf/Conference.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 514, 3929, 5101, 1528, 12, 780, 609, 262, 288, 202, 202, 780, 1892, 1681, 273, 225, 394, 6674, 12, 701, 13, 274, 202, 202, 759, 613, 2932, 382, 13569, 30, 315, 397, 609, 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, 225, 202, 482, 514, 3929, 5101, 1528, 12, 780, 609, 262, 288, 202, 202, 780, 1892, 1681, 273, 225, 394, 6674, 12, 701, 13, 274, 202, 202, 759, 613, 2932, 382, 13569, 30, 315, 397, 609, 13,...
{ listenerList.remove(TreeExpansionListener.class, listener); }
{ listenerList.remove(TreeExpansionListener.class, listener); }
public void removeTreeExpansionListener(TreeExpansionListener listener) { listenerList.remove(TreeExpansionListener.class, listener); }
45713 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/45713/363fe84fd732aa8ca3562fb0734fe48ee20c2c65/JTree.java/buggy/libraries/javalib/javax/swing/JTree.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 282, 1071, 918, 1206, 2471, 2966, 12162, 2223, 12, 2471, 2966, 12162, 2223, 2991, 13, 225, 288, 565, 2991, 682, 18, 4479, 12, 2471, 2966, 12162, 2223, 18, 1106, 16, 2991, 1769, 225, 289, 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, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 282, 1071, 918, 1206, 2471, 2966, 12162, 2223, 12, 2471, 2966, 12162, 2223, 2991, 13, 225, 288, 565, 2991, 682, 18, 4479, 12, 2471, 2966, 12162, 2223, 18, 1106, 16, 2991, 1769, 225, 289, 2, ...
private static String toSource(Context cx, Scriptable thisObj)
private static String toSource(Context cx, Scriptable scope, Scriptable thisObj, Object[] args) throws JavaScriptException
private static String toSource(Context cx, Scriptable thisObj) { StringBuffer result = new StringBuffer(256); result.append('{'); boolean toplevel, iterating; if (cx.iterating == null) { toplevel = true; iterating = false; cx.iterating = new ObjToIntMap(31); } else { toplevel = false; iterating = cx.iterating.has(thisObj); } // Make sure cx.iterating is set to null when done // so we don't leak memory try { if (!iterating) { cx.iterating.put(thisObj, 0); // stop recursion. Object[] ids = thisObj.getIds(); for(int i=0; i < ids.length; i++) { if (i > 0) result.append(", "); Object id = ids[i]; result.append(id); result.append(':'); Object p = (id instanceof String) ? thisObj.get((String) id, thisObj) : thisObj.get(((Integer) id).intValue(), thisObj); if (p instanceof String) { result.append('\"'); result.append(ScriptRuntime.escapeString((String)p)); result.append('\"'); } else { result.append(ScriptRuntime.toString(p)); } } } } finally { if (toplevel) { cx.iterating = null; } } result.append('}'); return result.toString(); }
47609 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/47609/2e75448c1343ae39cc50d0424de2982b9c2caec0/NativeObject.java/clean/js/rhino/src/org/mozilla/javascript/NativeObject.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 3238, 760, 514, 358, 1830, 12, 1042, 9494, 16, 22780, 2146, 16, 22780, 15261, 16, 1033, 8526, 833, 13, 1216, 11905, 503, 565, 288, 3639, 6674, 563, 273, 394, 6674, 12, 5034, 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, 3238, 760, 514, 358, 1830, 12, 1042, 9494, 16, 22780, 2146, 16, 22780, 15261, 16, 1033, 8526, 833, 13, 1216, 11905, 503, 565, 288, 3639, 6674, 563, 273, 394, 6674, 12, 5034, 1769, 3639, ...
if (isRunning() && !isCanceled() && getFraction() < 0.15 && myDialog!=null) { setFunComponent(cmp); } }
ProgressWindow.this.cancel(); }
public void run() { if (isRunning() && !isCanceled() && getFraction() < 0.15 && myDialog!=null) { setFunComponent(cmp); } }
17306 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/17306/bd2adb20a0dcacacfa56fe59390862b3f3cbac79/ProgressWindow.java/clean/source/com/intellij/openapi/progress/util/ProgressWindow.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 540, 1071, 918, 1086, 1435, 288, 1850, 309, 261, 291, 7051, 1435, 597, 401, 291, 23163, 1435, 597, 2812, 5738, 1435, 411, 374, 18, 3600, 597, 3399, 6353, 5, 33, 2011, 13, 288, 5411, 444, 227...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 540, 1071, 918, 1086, 1435, 288, 1850, 309, 261, 291, 7051, 1435, 597, 401, 291, 23163, 1435, 597, 2812, 5738, 1435, 411, 374, 18, 3600, 597, 3399, 6353, 5, 33, 2011, 13, 288, 5411, 444, 227...
commandIdsByTrigger.put(trigger, bindings);
bindingsByTrigger.put(trigger, bindings);
private final void computeBindings(final Map activeContextTree, final Map commandIdsByTrigger, final Map triggersByCommandId) { /* * FIRST PASS: Remove all of the bindings that are marking deletions. */ final Binding[] trimmedBindings = removeDeletions(bindings); /* * SECOND PASS: Just throw in bindings that match the current state. If * there is more than one match for a binding, then create a list. */ final Map possibleBindings = new HashMap(); final int length = trimmedBindings.length; for (int i = 0; i < length; i++) { final Binding binding = trimmedBindings[i]; boolean found; // Check the context. final String contextId = binding.getContextId(); if ((activeContextTree != null) && (!activeContextTree.containsKey(contextId))) { continue; } // Check the locale. if (!localeMatches(binding)) { continue; } // Check the platform. if (!platformMatches(binding)) { continue; } // Check the scheme ids. final String schemeId = binding.getSchemeId(); found = false; for (int j = 0; j < activeSchemeIds.length; j++) { if (Util.equals(schemeId, activeSchemeIds[j])) { found = true; break; } } if (!found) { continue; } // Insert the match into the list of possible matches. final TriggerSequence trigger = binding.getTriggerSequence(); final Object existingMatch = possibleBindings.get(trigger); if (existingMatch instanceof Binding) { possibleBindings.remove(trigger); final Collection matches = new ArrayList(); matches.add(existingMatch); matches.add(binding); possibleBindings.put(trigger, matches); } else if (existingMatch instanceof Collection) { final Collection matches = (Collection) existingMatch; matches.add(binding); } else { possibleBindings.put(trigger, binding); } } /* * THIRD PASS: In this pass, we move any non-conflicting bindings * directly into the map. In the case of conflicts, we apply some * further logic to try to resolve them. If the conflict can't be * resolved, then we log the problem. */ final Iterator possibleBindingItr = possibleBindings.entrySet() .iterator(); while (possibleBindingItr.hasNext()) { final Map.Entry entry = (Map.Entry) possibleBindingItr.next(); final TriggerSequence trigger = (TriggerSequence) entry.getKey(); final Object match = entry.getValue(); /* * What we do depends slightly on whether we are trying to build a * list of all possible bindings (disregarding context), or a flat * map given the currently active contexts. */ if (activeContextTree == null) { // We are building the list of all possible bindings. final Collection bindings = new ArrayList(); if (match instanceof Binding) { bindings.add(match); commandIdsByTrigger.put(trigger, bindings); addReverseLookup(triggersByCommandId, ((Binding) match) .getCommandId(), trigger); } else if (match instanceof Collection) { bindings.addAll(resolveConflicts((Collection) match)); commandIdsByTrigger.put(trigger, bindings); final Iterator matchItr = bindings.iterator(); while (matchItr.hasNext()) { addReverseLookup(triggersByCommandId, ((Binding) matchItr.next()).getCommandId(), trigger); } } } else { // We are building the flat map of trigger to commands. if (match instanceof Binding) { final String commandId = ((Binding) match).getCommandId(); commandIdsByTrigger.put(trigger, commandId); addReverseLookup(triggersByCommandId, commandId, trigger); } else if (match instanceof Collection) { final Binding winner = resolveConflicts((Collection) match, activeContextTree); if (winner == null) { if (DEBUG) { System.out .println("BINDINGS >> A conflict occurred for " + trigger); //$NON-NLS-1$ System.out.println("BINDINGS >> " + match); //$NON-NLS-1$ } } else { final String commandId = winner.getCommandId(); commandIdsByTrigger.put(trigger, commandId); addReverseLookup(triggersByCommandId, commandId, trigger); } } } } }
55805 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/55805/e61bf96d546738a5dfebc5feb8c2bcbe110e4371/BindingManager.java/buggy/bundles/org.eclipse.jface/src/org/eclipse/jface/bindings/BindingManager.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 1152, 727, 918, 3671, 10497, 12, 6385, 1635, 2695, 1042, 2471, 16, 1082, 202, 6385, 1635, 1296, 2673, 858, 6518, 16, 727, 1635, 11752, 858, 2189, 548, 13, 288, 202, 202, 20308, 1082,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 1152, 727, 918, 3671, 10497, 12, 6385, 1635, 2695, 1042, 2471, 16, 1082, 202, 6385, 1635, 1296, 2673, 858, 6518, 16, 727, 1635, 11752, 858, 2189, 548, 13, 288, 202, 202, 20308, 1082,...
setSeries(f0, i);
setSeries(currentId, i);
protected void initFile(String id) throws FormatException, IOException { currentId = id; fp = findPattern(id); // verify that file pattern is valid and matches existing files String msg = " Please rename your files or disable file stitching."; if (!fp.isValid()) { throw new FormatException("Invalid " + (patternIds ? "file pattern" : "filename") + " (" + currentId + "): " + fp.getErrorMessage() + msg); } files = fp.getFiles(); if (files == null) { throw new FormatException("No files matching pattern (" + fp.getPattern() + "). " + msg); } for (int i=0; i<files.length; i++) { if (!new File(getMappedId(files[i])).exists()) { throw new FormatException("File #" + i + " (" + files[i] + ") does not exist."); } } // determine reader type for these files; assume all are the same type Vector classes = new Vector(); IFormatReader r = reader; while (r instanceof ReaderWrapper) { classes.add(r.getClass()); r = ((ReaderWrapper) r).getReader(); } if (r instanceof ImageReader) r = ((ImageReader) r).getReader(files[0]); classes.add(r.getClass()); // construct list of readers for all files readers = new IFormatReader[files.length]; readers[0] = reader; Hashtable map = reader.getIdMap(); for (int i=1; i<readers.length; i++) { // use crazy reflection to instantiate a reader of the proper type try { r = null; for (int j=classes.size()-1; j>=0; j--) { Class c = (Class) classes.elementAt(j); if (r == null) r = (IFormatReader) c.newInstance(); else { r = (IFormatReader) c.getConstructor( new Class[] {IFormatReader.class}).newInstance(new Object[] {r}); } } readers[i] = (IFormatReader) r; // NB: ensure all readers share the same ID map readers[i].setIdMap(map); } catch (InstantiationException exc) { exc.printStackTrace(); } catch (IllegalAccessException exc) { exc.printStackTrace(); } catch (NoSuchMethodException exc) { exc.printStackTrace(); } catch (InvocationTargetException exc) { exc.printStackTrace(); } } String f0 = files[0]; int seriesCount = getSeriesCount(f0); ag = new AxisGuesser[seriesCount]; blankImage = new BufferedImage[seriesCount]; blankBytes = new byte[seriesCount][]; width = new int[seriesCount]; height = new int[seriesCount]; imagesPerFile = new int[seriesCount]; totalImages = new int[seriesCount]; order = new String[seriesCount]; sizeZ = new int[seriesCount]; sizeC = new int[seriesCount]; sizeT = new int[seriesCount]; totalSizeZ = new int[seriesCount]; totalSizeC = new int[seriesCount]; totalSizeT = new int[seriesCount]; lenZ = new int[seriesCount][]; lenC = new int[seriesCount][]; lenT = new int[seriesCount][]; // analyze first file; assume each file has the same parameters int oldSeries = getSeries(f0); for (int i=0; i<seriesCount; i++) { setSeries(f0, i); reader.setSeries(f0, i); width[i] = reader.getSizeX(f0); height[i] = reader.getSizeY(f0); imagesPerFile[i] = reader.getImageCount(f0); totalImages[i] = files.length * imagesPerFile[i]; /* debug */ System.out.println("setting image count to " + imagesPerFile[i] + " for series " + getSeries(f0)); order[i] = reader.getDimensionOrder(f0); sizeZ[i] = reader.getSizeZ(f0); sizeC[i] = reader.getSizeC(f0); sizeT[i] = reader.getSizeT(f0); } setSeries(f0, oldSeries); boolean certain = reader.isOrderCertain(f0); // guess at dimensions corresponding to file numbering for (int i=0; i<seriesCount; i++) { ag[i] = new AxisGuesser(fp, order[i], sizeZ[i], sizeT[i], sizeC[i], certain); } // order may need to be adjusted for (int i=0; i<seriesCount; i++) { setSeries(f0, i); order[i] = ag[i].getAdjustedOrder(); swapDimensions(currentId, order[i]); } setSeries(f0, oldSeries); }
55303 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/55303/5d59646c04b76fb2e9bc87fa889f4505bb04b2a7/FileStitcher.java/buggy/loci/formats/FileStitcher.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 282, 4750, 918, 1208, 812, 12, 780, 612, 13, 1216, 4077, 503, 16, 1860, 288, 565, 783, 548, 273, 612, 31, 565, 4253, 273, 1104, 3234, 12, 350, 1769, 565, 368, 3929, 716, 585, 1936, 353, 92...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 282, 4750, 918, 1208, 812, 12, 780, 612, 13, 1216, 4077, 503, 16, 1860, 288, 565, 783, 548, 273, 612, 31, 565, 4253, 273, 1104, 3234, 12, 350, 1769, 565, 368, 3929, 716, 585, 1936, 353, 92...
colors.add(new ColorRecord(0,Color.white)); colors.add(new ColorRecord(1,Color.red));
colors.add(new ColorRecord(0, Color.white)); colors.add(new ColorRecord(1, Color.red)); ArrayList curve = new ArrayList(); curve.add(new Vector2f(0.0f, 0.0f)); curve.add(new Vector2f(1.0f, 255.0f)); alpha = new LinearInterpolator(curve, 0, 255); curve = new ArrayList(); curve.add(new Vector2f(0.0f, 0.0f)); curve.add(new Vector2f(1.0f, 255.0f)); size = new LinearInterpolator(curve, 0, 255); curve = new ArrayList(); curve.add(new Vector2f(0.0f, 0.0f)); curve.add(new Vector2f(1.0f, 1.0f)); velocity = new LinearInterpolator(curve, 0, 1); curve = new ArrayList(); curve.add(new Vector2f(0.0f, 0.0f)); curve.add(new Vector2f(1.0f, 1.0f)); scaleY = new LinearInterpolator(curve, 0, 1);
public ConfigurableEmitter(String name) { this.name = name; leftToEmit = (int) emitCount.random(); timeout = (int) (length.random()); colors.add(new ColorRecord(0,Color.white)); colors.add(new ColorRecord(1,Color.red)); }
53247 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/53247/f800b9b946b87062c607162488b085aa7bf679f2/ConfigurableEmitter.java/buggy/Slick/src/org/newdawn/slick/particles/ConfigurableEmitter.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 29312, 13476, 12, 780, 508, 13, 288, 202, 202, 2211, 18, 529, 273, 508, 31, 202, 202, 4482, 774, 17982, 273, 261, 474, 13, 3626, 1380, 18, 9188, 5621, 202, 202, 4538, 273, 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, 482, 29312, 13476, 12, 780, 508, 13, 288, 202, 202, 2211, 18, 529, 273, 508, 31, 202, 202, 4482, 774, 17982, 273, 261, 474, 13, 3626, 1380, 18, 9188, 5621, 202, 202, 4538, 273, 2...
Cancel rcancel2 = new Cancel(); rcancel1.read(dis); rcancel2.read(dis);
deliveryId = dis.readLong(); deliveryCount = dis.readInt(); DefaultCancel rcancel2 = new DefaultCancel(deliveryId, deliveryCount);
public void testCancelDeliveries() throws Exception { long methodHash = 62365354; int objectId = 54321; List cancels = new ArrayList(); Cancel cancel1 = new Cancel(65654, 43); Cancel cancel2 = new Cancel(65765, 2); cancels.add(cancel1); cancels.add(cancel2); MethodInvocation mi = new MethodInvocation(null, methodHash, cancelDeliveriesMethod, cancelDeliveriesMethod, null); mi.getMetaData().addMetaData(Dispatcher.DISPATCHER, Dispatcher.OID, new Integer(objectId)); mi.setArguments(new Object[] {cancels}); MessagingMarshallable mm = new MessagingMarshallable((byte)77, mi); InvocationRequest ir = new InvocationRequest(null, null, mm, null, null, null); ByteArrayOutputStream bos = new ByteArrayOutputStream(); OutputStream oos = new DataOutputStream(bos); wf.write(ir, oos); oos.flush(); byte[] bytes = bos.toByteArray(); ByteArrayInputStream bis = new ByteArrayInputStream(bytes); DataInputStream dis = new DataInputStream(bis); //Check the bytes //First byte should be version assertEquals(77, dis.readByte()); //Next byte should be CANCEL_MESSAGES assertEquals(JMSWireFormat.CANCEL_DELIVERIES, dis.readByte()); //Next int should be objectId assertEquals(objectId, dis.readInt()); //Next long should be methodHash assertEquals(methodHash, dis.readLong()); //Next should the size of the list int size = dis.readInt(); assertEquals(2, size); //then the AckInfos Cancel rcancel1 = new Cancel(); Cancel rcancel2 = new Cancel(); rcancel1.read(dis); rcancel2.read(dis); assertEquals(cancel1.getDeliveryCount(), rcancel1.getDeliveryCount()); assertEquals(cancel1.getDeliveryId(), cancel1.getDeliveryId()); assertEquals(cancel2.getDeliveryCount(), rcancel2.getDeliveryCount()); assertEquals(cancel2.getDeliveryId(), cancel2.getDeliveryId()); //should be eos try { dis.readByte(); fail("End of stream expected"); } catch (EOFException e) { //Ok } bis.reset(); InputStream ois = new DataInputStream(bis); InvocationRequest ir2 = (InvocationRequest)wf.read(ois, null); mm = (MessagingMarshallable)ir2.getParameter(); assertEquals(77, mm.getVersion()); MethodInvocation mi2 = (MethodInvocation)mm.getLoad(); assertEquals(methodHash, mi2.getMethodHash()); assertEquals(objectId, ((Integer)mi2.getMetaData().getMetaData(Dispatcher.DISPATCHER, Dispatcher.OID)).intValue()); List list = (List)mi2.getArguments()[0]; assertEquals(2, list.size()); Cancel xack1 = (Cancel)list.get(0); Cancel xack2 = (Cancel)list.get(1); assertEquals(cancel1.getDeliveryId(), xack1.getDeliveryId()); assertEquals(cancel1.getDeliveryCount(), xack1.getDeliveryCount()); assertEquals(cancel2.getDeliveryId(), xack2.getDeliveryId()); assertEquals(cancel2.getDeliveryCount(), xack2.getDeliveryCount()); }
3806 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/3806/67a2ce6eee4fecacdc05a35652ffceb168cc2c14/WireFormatTest.java/clean/tests/src/org/jboss/test/messaging/jms/WireFormatTest.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 4202, 1071, 918, 1842, 6691, 20813, 606, 1435, 1216, 1185, 1377, 288, 19694, 1525, 707, 2310, 273, 1666, 4366, 9222, 4763, 24, 31, 5375, 509, 18010, 273, 22431, 1578, 21, 31, 5375, 987, 3755, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 1842, 6691, 20813, 606, 1435, 1216, 1185, 1377, 288, 19694, 1525, 707, 2310, 273, 1666, 4366, 9222, 4763, 24, 31, 5375, 509, 18010, 273, 22431, 1578, 21, 31, 5375, 987, 3755, ...
public boolean importData(ImportContext context, boolean isCollection, Node contentNode) throws IOException, RepositoryException { if (! super.importData(context, isCollection, contentNode)) { return false; } CosmoImportContext cosmoContext = (CosmoImportContext) context; Node resourceNode = contentNode; if (! isCollection) { resourceNode = contentNode.getParent(); } // add dav resource and ticketable mixin types for all resources if (! resourceNode.isNodeType(NT_DAV_RESOURCE)) { resourceNode.addMixin(NT_DAV_RESOURCE); } if (! resourceNode.isNodeType(NT_TICKETABLE)) { resourceNode.addMixin(NT_TICKETABLE); } if (resourceNode.getParent().isNodeType(NT_CALENDAR_COLLECTION)) { // calendar collections can only contain calendar object // resources if (! ((CosmoImportContext) context).isCalendarContent()) { throw new UnsupportedMediaTypeException(context.getMimeType()); } Calendar calendar = cosmoContext.getCalendar(); // 1) make sure that the calendar object contains at least // one supported component type boolean found = false; String[] types = ComponentTypes.getAllSupportedComponentTypeNames(); for (int i=0; i<types.length; i++) { if (! calendar.getComponents().getComponents(types[i]). isEmpty()) { found = true; break; } } if (! found) { throw new UnsupportedCalendarComponentException(); } // 2) make sure that the calendar object's uid is // unique with in the calendar collection Component event = (Component) calendar.getComponents().getComponents(Component.VEVENT). get(0); Property uid = (Property) event.getProperties().getProperty(Property.UID); if (! isUidUnique(resourceNode, uid.getValue())) { throw new UidConflictException(uid.getValue()); } // 3) add calendarv resource mixin type if (! resourceNode.isNodeType(NT_CALENDAR_RESOURCE)) { resourceNode.addMixin(NT_CALENDAR_RESOURCE); } // 4) add event mixin type if (! resourceNode.isNodeType(NT_EVENT_RESOURCE)) { resourceNode.addMixin(NT_EVENT_RESOURCE); } } return true; }
47226 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/47226/1ea2830cd6fa94de7199a14aef58e99a40937d03/CosmoHandler.java/buggy/src/main/java/org/osaf/cosmo/io/CosmoHandler.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 1250, 1930, 751, 12, 5010, 1042, 819, 16, 17311, 1250, 26506, 16, 17311, 2029, 913, 907, 13, 3639, 1216, 1860, 16, 13367, 288, 3639, 309, 16051, 2240, 18, 5666, 751, 12, 2472, 16, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 1250, 1930, 751, 12, 5010, 1042, 819, 16, 17311, 1250, 26506, 16, 17311, 2029, 913, 907, 13, 3639, 1216, 1860, 16, 13367, 288, 3639, 309, 16051, 2240, 18, 5666, 751, 12, 2472, 16, ...
private AtomContainer getPlacedAtoms(Atom atom) {
private AtomContainer getPlacedAtoms(Atom atom) {
private AtomContainer getPlacedAtoms(Atom atom) { AtomContainer placedAtoms = new AtomContainer(); Bond[] bonds = molecule.getConnectedBonds(atom); Atom connectedAtom = null; for (int f = 0; f < bonds.length; f++) { connectedAtom = bonds[f].getConnectedAtom(atom); if (connectedAtom.getFlag(CDKConstants.ISPLACED)) { placedAtoms.addAtom(connectedAtom); } } return placedAtoms; }
46046 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/46046/47adbfe1b0e320448dd43d5e8fa7731999240e31/StructureDiagramGenerator.java/buggy/src/org/openscience/cdk/layout/StructureDiagramGenerator.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 1152, 7149, 2170, 9774, 623, 72, 14280, 12, 3641, 3179, 13, 288, 202, 202, 3641, 2170, 15235, 14280, 273, 394, 7149, 2170, 5621, 202, 202, 9807, 8526, 15692, 273, 13661, 18, 588, 893...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 7149, 2170, 9774, 623, 72, 14280, 12, 3641, 3179, 13, 288, 202, 202, 3641, 2170, 15235, 14280, 273, 394, 7149, 2170, 5621, 202, 202, 9807, 8526, 15692, 273, 13661, 18, 588, 893...
mSuperClass = superClass; mInterfaces = interfaces; mProperties = jsObj.getIds(); }
mSuperClass = superClass; mInterfaces = interfaces; mProperties = ScriptableObject.getPropertyIds(jsObj); }
ClassSignature(Class superClass, Class[] interfaces, Scriptable jsObj) { mSuperClass = superClass; mInterfaces = interfaces; mProperties = jsObj.getIds(); }
7555 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/7555/f61a4fa629dd0699e1a2d0893806311ab8a9dfd1/JavaAdapter.java/clean/js/rhino/org/mozilla/javascript/JavaAdapter.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1377, 202, 797, 5374, 12, 797, 18846, 16, 1659, 8526, 7349, 16, 22780, 3828, 2675, 13, 288, 377, 202, 202, 81, 8051, 797, 273, 18846, 31, 377, 202, 202, 81, 10273, 273, 7349, 31, 377, 202, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1377, 202, 797, 5374, 12, 797, 18846, 16, 1659, 8526, 7349, 16, 22780, 3828, 2675, 13, 288, 377, 202, 202, 81, 8051, 797, 273, 18846, 31, 377, 202, 202, 81, 10273, 273, 7349, 31, 377, 202, ...
CmsFolder hashFolder = null;
CmsFolder hashFolder = null;
private void synchronizeVirtual(String resourceName) throws CmsException{ // read the resources from the server filesystem // and add the new resources to the virtual filesystem File sfsFile = new File(m_synchronizePath+resourceName); String sfsAbsolutePath = sfsFile.getPath().substring(m_synchronizePath.length()); String[] diskFiles = sfsFile.list(); File currentFile; CmsFile hashFile = null; CmsFolder hashFolder = null; for (int i = 0; i < diskFiles.length; i++){ currentFile = new File(sfsFile, diskFiles[i]); if (currentFile.isDirectory()){ hashFolder = (CmsFolder)m_vfsFolders.get(sfsFile.getPath()+currentFile.getName()+"/"); if (hashFolder == null){ // the folder does not exist in the VFS, so add it from SFS try { m_cms.createFolder(sfsAbsolutePath,currentFile.getName()); m_cms.lockResource(sfsAbsolutePath+currentFile.getName()+"/"); } catch (CmsException e){ // if the folder already exists do nothing if (e.getType() != CmsException.C_FILE_EXISTS){ throw e; } } } hashFolder = null; // now read the filelist of this folder synchronizeVirtual(sfsAbsolutePath+currentFile.getName()+"/"); } else { hashFile = (CmsFile)m_vfsFiles.get(sfsFile.getPath()+currentFile.getName()); if (hashFile == null){ // the file does not exist in the VFS, so add it from SFS try { byte[] content = getFileBytes(currentFile); String type = getFileType(currentFile.getName()); if (!currentFile.getName().startsWith("$")){ try { m_cms.createFile(sfsAbsolutePath, currentFile.getName(), content, type); m_cms.lockResource(sfsAbsolutePath+currentFile.getName()); m_synchronizeList.putDates(sfsAbsolutePath+currentFile.getName(), (long)System.currentTimeMillis(), currentFile.lastModified()); } catch (CmsException e) { if (e.getType() == CmsException.C_FILE_EXISTS){ // if the file exists try to update the file //try { // CmsFile updFile = m_cms.readFile(sfsAbsolutePath+currentFile.getName()); // updFile.setContents(content); // m_cms.writeFile(sfsAbsolutePath+currentFile.getName()); //} catch (CmsException e){ //} } else { throw e; } } } } catch (Exception e) { throw new CmsException("["+this.getClass().getName()+"]"+" Cannot create file in virtual filesystem",e); } } hashFile = null; } } }
8585 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/8585/e15b90a9c2c96d7882c429052aca6c143ec62109/CmsSynchronize.java/buggy/src/com/opencms/file/CmsSynchronize.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 1152, 918, 16978, 6466, 12, 780, 9546, 13, 202, 202, 15069, 11228, 95, 202, 202, 759, 855, 326, 2703, 628, 326, 1438, 6496, 202, 202, 759, 471, 527, 326, 394, 2703, 358, 326, 5024,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 16978, 6466, 12, 780, 9546, 13, 202, 202, 15069, 11228, 95, 202, 202, 759, 855, 326, 2703, 628, 326, 1438, 6496, 202, 202, 759, 471, 527, 326, 394, 2703, 358, 326, 5024,...
if (null != domViewer) {
if (null != currentDocument && null != domViewer) {
public void eventDispatched(WebclientEvent event){ boolean enabledState; if (event instanceof DocumentLoadEvent) { switch ((int) event.getType()) { case ((int) DocumentLoadEvent.START_DOCUMENT_LOAD_EVENT_MASK): stopButton.setEnabled(true); refreshButton.setEnabled(true); currentURL = (String) event.getEventData(); System.out.println("debug: edburns: Currently Viewing: " + currentURL); statusLabel.setText("Starting to load " + currentURL); urlField.setText(currentURL); currentDocument = null; break; case ((int) DocumentLoadEvent.END_DOCUMENT_LOAD_EVENT_MASK): stopButton.setEnabled(false); backButton.setEnabled(history.canBack()); forwardButton.setEnabled(history.canForward()); statusLabel.setText("Done."); currentDocument = currentPage.getDOM(); // add the new document to the domViewer if (null != domViewer) { domViewer.setDocument(currentDocument); } break; } }}
51275 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/51275/3ec9c393fb657c980d7d8ca55d00f5eadf610dc1/EMWindow.java/clean/java/webclient/classes_spec/org/mozilla/webclient/test/EMWindow.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1071, 918, 871, 5325, 329, 12, 4079, 2625, 1133, 871, 15329, 565, 1250, 3696, 1119, 31, 565, 309, 261, 2575, 1276, 4319, 2563, 1133, 13, 288, 3639, 1620, 14015, 474, 13, 871, 18, 588, 559, 1...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1071, 918, 871, 5325, 329, 12, 4079, 2625, 1133, 871, 15329, 565, 1250, 3696, 1119, 31, 565, 309, 261, 2575, 1276, 4319, 2563, 1133, 13, 288, 3639, 1620, 14015, 474, 13, 871, 18, 588, 559, 1...
PrintStream ps = new PrintStream(new FileOutputStream(outputFile), true); ps.print(getNumberDataPoints()); ps.print(' ');
PrintStream ps = new PrintStream(new FileOutputStream(outputFile), true); ps.print(getNumberDataPoints()); ps.print(' ');
public void dumpAscii(String outputFile) throws IOException { PrintStream ps = new PrintStream(new FileOutputStream(outputFile), true); ps.print(getNumberDataPoints()); ps.print(' '); for (Iterator i = allFeatures.iterator(); i.hasNext();) { double[] feature = (double[]) i.next(); for (int d = 0; d < feature.length; d++) { ps.print(feature[d]); ps.print(' '); } } ps.close(); }
52185 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52185/5e14d17f464e43c3672d8191de29850e50f35181/FeatureFileDumper.java/buggy/edu/cmu/sphinx/tools/feature/FeatureFileDumper.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 918, 4657, 21363, 12, 780, 15047, 13, 1216, 1860, 288, 3639, 21677, 4250, 273, 394, 21677, 12, 2704, 12942, 12, 2844, 812, 3631, 638, 1769, 3639, 4250, 18, 1188, 12, 588, 1854, 751,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 4657, 21363, 12, 780, 15047, 13, 1216, 1860, 288, 3639, 21677, 4250, 273, 394, 21677, 12, 2704, 12942, 12, 2844, 812, 3631, 638, 1769, 3639, 4250, 18, 1188, 12, 588, 1854, 751,...
} else if (matchedPatternElement.allowTrailingEdges()) {
} else if (currentMatch == null || currentMatch.allowTrailingEdges()) {
private void work(BasicBlock basicBlock, BasicBlock.InstructionIterator instructionIterator, PatternElement patternElement, int matchCount, PatternElementMatch currentMatch, BindingSet bindingSet, boolean canFork) throws DataflowAnalysisException { // Have we reached the end of the pattern? if (patternElement == null) { // This is a complete match. if (DEBUG) System.out.println("FINISHED A MATCH!"); resultList.add(new ByteCodePatternMatch(bindingSet, currentMatch)); return; } // If we've reached the minimum number of occurrences for this // pattern element, we can advance to the next pattern element without trying // to match this instruction again. We make sure that we only advance to // the next element once for this matchCount. if (canFork && matchCount >= patternElement.minOccur()) { work(basicBlock, instructionIterator.duplicate(), patternElement.getNext(), 0, currentMatch, bindingSet, true); canFork = false; } // If we've reached the maximum number of occurrences for this // pattern element, then we can't continue. if (matchCount >= patternElement.maxOccur()) return; InstructionHandle matchedInstruction = null; PatternElement matchedPatternElement = null; // Is there another instruction in this basic block? if (instructionIterator.hasNext()) { InstructionHandle handle = instructionIterator.next(); // Get the ValueNumberFrames before and after the instruction ValueNumberFrame before = vnaDataflow.getFactAtLocation(new Location(handle, basicBlock)); BasicBlock.InstructionIterator dupIter = instructionIterator.duplicate(); ValueNumberFrame after = dupIter.hasNext() ? vnaDataflow.getFactAtLocation(new Location(dupIter.next(), basicBlock)) : vnaDataflow.getResultFact(basicBlock); // Try to match the instruction against the pattern element. boolean isWild = patternElement instanceof Wild; if (DEBUG && (!isWild || SHOW_WILD)) System.out.println("Match " + patternElement + " against " + handle + " " + (bindingSet != null ? bindingSet.toString() : "[]") + "..."); MatchResult matchResult = patternElement.match(handle, cpg, before, after, bindingSet); if (DEBUG && (!isWild || SHOW_WILD)) System.out.println("\t" + ((matchResult != null) ? " ==> MATCH" : " ==> NOT A MATCH")); if (matchResult == null) // Not a match. return; // Successful match! matchedInstruction = handle; matchedPatternElement = matchResult.getPatternElement(); ++matchCount; canFork = true; currentMatch = new PatternElementMatch(matchedPatternElement, handle, matchCount, currentMatch); bindingSet = matchResult.getBindingSet(); } // Continue the match at each successor instruction, // using the same PatternElement. if (instructionIterator.hasNext()) { // Easy case; continue matching in the same basic block. work(basicBlock, instructionIterator, patternElement, matchCount, currentMatch, bindingSet, canFork); } else if (matchedPatternElement.allowTrailingEdges()) { // We've reached the end of the basic block. // Try to advance to the successors of this basic block, // ignoring loop backedges. Iterator<Edge> i = cfg.outgoingEdgeIterator(basicBlock); BitSet visitedSuccessorSet = new BitSet(); while (i.hasNext()) { Edge edge = i.next(); if (dfs.getDFSEdgeType(edge) == BACK_EDGE) continue; // If we have just matched an instruction, then we allow the // matching PatternElement to choose which edges are acceptable. // This allows PatternElements to select particular control edges; // for example, only continue the pattern on the true branch // of an "if" comparison. if (matchedInstruction == null || matchedPatternElement.acceptBranch(edge, matchedInstruction)) { BasicBlock destBlock = edge.getDest(); int destId = destBlock.getId(); // CFGs can have duplicate edges if (visitedSuccessorSet.get(destId)) continue; visitedSuccessorSet.set(destId, true); work(destBlock, destBlock.instructionIterator(), patternElement, matchCount, currentMatch, bindingSet, canFork); } } } }
10715 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/10715/9a93420175befc57065983476aa379ea3fd20e6d/PatternMatcher.java/buggy/findbugs/src/java/edu/umd/cs/findbugs/ba/bcp/PatternMatcher.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 1152, 918, 1440, 12, 8252, 1768, 5337, 1768, 16, 7651, 1768, 18, 11983, 3198, 7592, 3198, 16, 202, 202, 3234, 1046, 1936, 1046, 16, 509, 845, 1380, 16, 202, 202, 3234, 1046, 2060, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 1440, 12, 8252, 1768, 5337, 1768, 16, 7651, 1768, 18, 11983, 3198, 7592, 3198, 16, 202, 202, 3234, 1046, 1936, 1046, 16, 509, 845, 1380, 16, 202, 202, 3234, 1046, 2060, ...
Node selectNode = new SimpleResultNode("selectNode", Map.class);
Node startNode = new SimpleNode("start", Map.class); Node endNode = new SimpleNode("end", Map.class);
public static Query buildAgeQuery(int age, Node startNode) { QueryBuilder qb = new QueryBuilder(); Node selectNode = new SimpleResultNode("selectNode", Map.class); qb.addArc( new Arc(startNode, selectNode), new MapValueFilter("age", new Integer(age)) ); return qb.buildQuery(); }
50115 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50115/16e211b30f2de853621b0c083c1e7d659c54cfd1/TestQuery.java/clean/demos/query/TestQuery.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 282, 1071, 760, 2770, 1361, 9692, 1138, 12, 474, 9388, 16, 2029, 25467, 13, 288, 565, 14515, 7311, 273, 394, 14515, 5621, 565, 2029, 25467, 273, 394, 4477, 907, 2932, 1937, 3113, 1635, 18, 110...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 2770, 1361, 9692, 1138, 12, 474, 9388, 16, 2029, 25467, 13, 288, 565, 14515, 7311, 273, 394, 14515, 5621, 565, 2029, 25467, 273, 394, 4477, 907, 2932, 1937, 3113, 1635, 18, 110...
System.out.println( "DaemonLauncher: Starting up Phoenix" );
System.out.println( "DaemonLauncher: starting up." );
public Integer start( final String[] args ) { Integer exitCodeInteger = null; // This startup could take a while, so tell the wrapper to be patient. WrapperManager.signalStarting( 45000 ); final Hashtable data = new Hashtable(); data.put( Observer.class.getName(), this ); if( WrapperManager.isDebugEnabled() ) { System.out.println( "DaemonLauncher: Starting up Phoenix" ); } try { int exitCode = Main.startup( args, data, false ); if( exitCode != 0 ) { exitCodeInteger = new Integer( exitCode ); } if( WrapperManager.isDebugEnabled() ) { System.out.println( "DaemonLauncher: Phoenix startup completed" ); } } catch( final Exception e ) { e.printStackTrace(); exitCodeInteger = new Integer( 1 ); } // We are almost up now, so reset the wait time WrapperManager.signalStarting( 2000 ); return exitCodeInteger; }
2044 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/2044/20e17dc507f8b99207f9023e23c145ad23ff24af/DaemonLauncher.java/buggy/scm/loom/launcher/src/java/org/jcontainer/loom/launcher/DaemonLauncher.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 2144, 787, 12, 727, 514, 8526, 833, 262, 565, 288, 3639, 2144, 16067, 4522, 273, 446, 31, 3639, 368, 1220, 11850, 3377, 4862, 279, 1323, 16, 1427, 9276, 326, 4053, 358, 506, 18608, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 2144, 787, 12, 727, 514, 8526, 833, 262, 565, 288, 3639, 2144, 16067, 4522, 273, 446, 31, 3639, 368, 1220, 11850, 3377, 4862, 279, 1323, 16, 1427, 9276, 326, 4053, 358, 506, 18608, ...